summaryrefslogtreecommitdiff
path: root/net-im
diff options
context:
space:
mode:
authorBertrand Jacquin <beber@meleeweb.net>2006-04-20 19:51:03 +0200
committerBertrand Jacquin <beber@meleeweb.net>2006-04-20 19:51:03 +0200
commit330dc88146bbdfd45ac2c892df17041df4e8417d (patch)
treebd03224b85b0723acfdc6fd3597b12127f827707 /net-im
parentadd usb-pwc-re new release (diff)
downloadportage-330dc88146bbdfd45ac2c892df17041df4e8417d.tar.xz
gaim2: delete cvs ebuild
Diffstat (limited to 'net-im')
-rw-r--r--net-im/gaim/Manifest9
-rw-r--r--net-im/gaim/files/digest-gaim-99990
-rw-r--r--net-im/gaim/files/gaim-to-gaim2.patch155201
-rw-r--r--net-im/gaim/gaim-9999.ebuild202
4 files changed, 0 insertions, 155412 deletions
diff --git a/net-im/gaim/Manifest b/net-im/gaim/Manifest
deleted file mode 100644
index dc5464e0..00000000
--- a/net-im/gaim/Manifest
+++ /dev/null
@@ -1,9 +0,0 @@
-MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-gaim-9999 0
-RMD160 9c1185a5c5e9fc54612808977ee8f548b2258d31 files/digest-gaim-9999 0
-SHA256 e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 files/digest-gaim-9999 0
-MD5 26f66f1d23f9e7e776b157dd02dc2e7f files/gaim-to-gaim2.patch 5425350
-RMD160 abf28b13236b8da80eec4c02be92706ec822f70d files/gaim-to-gaim2.patch 5425350
-SHA256 7ac4a1ee34743f89f2c02b2d8f5520019eb3d1458ca71107ff5ae3ce53c1c7be files/gaim-to-gaim2.patch 5425350
-MD5 a49ea49c43186f6d793c919f0c99a3af gaim-9999.ebuild 6456
-RMD160 491a0972f5289d52df661f13b64f569c7b530eb9 gaim-9999.ebuild 6456
-SHA256 b2e23c2e8652c5970581094a8658b83c3b5140cb9ac2b523ca63b2b57a267b57 gaim-9999.ebuild 6456
diff --git a/net-im/gaim/files/digest-gaim-9999 b/net-im/gaim/files/digest-gaim-9999
deleted file mode 100644
index e69de29b..00000000
--- a/net-im/gaim/files/digest-gaim-9999
+++ /dev/null
diff --git a/net-im/gaim/files/gaim-to-gaim2.patch b/net-im/gaim/files/gaim-to-gaim2.patch
deleted file mode 100644
index be87e862..00000000
--- a/net-im/gaim/files/gaim-to-gaim2.patch
+++ /dev/null
@@ -1,155201 +0,0 @@
-diff -prNu ./configure.ac ./configure.ac
---- ./configure.ac 2006-01-03 18:55:38.000000000 +0100
-+++ ./configure.ac 2006-01-05 14:04:15.000000000 +0100
-@@ -1,5 +1,5 @@
- dnl Process this file with autoconf to produce a configure script.
--AC_INIT([gaim], [2.0.0cvs], [gaim-devel@lists.sourceforge.net])
-+AC_INIT([gaim2], [2.0.0cvs], [gaim-devel@lists.sourceforge.net])
- AC_CANONICAL_SYSTEM
- AM_CONFIG_HEADER(config.h)
- AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION)
-@@ -1610,9 +1610,9 @@ AC_CONFIG_COMMANDS_POST([
-
- AC_OUTPUT([Makefile
- Doxyfile
-- gaim.apspec
-+ gaim2.apspec
- doc/Makefile
-- doc/gaim.1
-+ doc/gaim2.1
- intl/Makefile
- m4macros/Makefile
- pixmaps/Makefile
-@@ -1653,8 +1653,8 @@ AC_OUTPUT([Makefile
- src/protocols/toc/Makefile
- src/protocols/yahoo/Makefile
- src/protocols/zephyr/Makefile
-- gaim.pc
-- gaim.spec
-+ gaim2.pc
-+ gaim2.spec
- ])
-
- echo
-diff -prNu ./.cvsignore ./.cvsignore
---- ./.cvsignore 2005-11-09 10:02:43.000000000 +0100
-+++ ./.cvsignore 2006-01-05 13:37:50.000000000 +0100
-@@ -29,5 +29,5 @@ confdefs.h
- *.swp
- win32-install-dir
- .temp-gettextize
--gaim.pc
-+gaim2.pc
- *.apspec
-diff -prNu ./doc/gaim.1.in ./doc/gaim.1.in
---- ./doc/gaim.1.in 2005-12-24 04:23:13.000000000 +0100
-+++ ./doc/gaim.1.in 1970-01-01 01:00:00.000000000 +0100
-@@ -1,601 +0,0 @@
--.\" Copyright (c) 2000, Dennis Ristuccia <dennis@dennisr.net>
--.\"
--.\" This is free documentation; 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.
--.\"
--.\" The GNU General Public License's references to "object code"
--.\" and "executables" are to be interpreted as the output of any
--.\" document formatting or typesetting system, including
--.\" intermediate and printed output.
--.\"
--.\" This manual 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 manual; if not, write to the Free
--.\" Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,
--.\" USA.
--.TH gaim 1
--.SH NAME
--Gaim v@VERSION@ \- Instant Messaging client
--.SH SYNOPSIS
--.TP 5
--\fBgaim \fI[options]\fR
--
--.SH DESCRIPTION
--.PP
--\fBgaim\fR is a GTK2-based Instant Messaging (IM) application. It supports
--multiple protocols via modules, including AIM, ICQ, Yahoo!, MSN, Jabber,
--IRC, Napster, Gadu-Gadu and Zephyr. It has many common features found in
--other clients, as well as many unique features. Gaim is not endorsed by or
--affiliated with America Online, ICQ, Microsoft, or Yahoo.
--
--.SH OPTIONS
--The following options are provided by \fBgaim\fR using the standard GNU
--command line syntax:
--.TP
--.B \-d, \-\-debug
--Print debugging messages to stdout. These are the same debugging messages
--that are displayed in the \fBDebug\fR window.
--.TP
--.B \-c, \-\-config=\fIDIR\fB
--Use \fIDIR\fR as the directory for config files instead of \fI~/.gaim\fR.
--.TP
--.B \-h, \-\-help
--Print this help and exit.
--.TP
--.B \-n, \-\-loginwin
--Don't automatically login when \fBgaim\fR starts. Show the \fBLogin\fR
--window instead.
--.TP
--.B \-v, \-\-version
--Display the version information window.
--
--.SH BUDDY LIST
--The \fBBuddy List\fR window is \fBgaim\fR's main interface window. Using
--this window you can see which of your buddies is online, away, idle, etc.
--You can also add and remove buddies from your buddy list.
--
--The \fBBuddy List\fR window contains a list of your buddies who are online
--and have allowed you to be notified of their presence. The icon to the
--left of each buddy indicates the buddy's current state and the protocol
--they are using. Double clicking a buddy will open a new \fBConversation\fR
--window. Right clicking will pop up a menu:
--.TP
--.B Get Info
--Retrieves and displays information about the buddy. This information is
--also known as a Profile.
--.TP
--.B IM
--Opens a new \fBConversation\fR window to the selected buddy.
--.TP
--.B Send File
--Sends a file to the selected buddy (only available on protocols that support
--file transfer).
--.TP
--.B Add Buddy Pounce
--A Buddy Pounce is a configurable automated action to be performed when the
--buddy's state changes. This will open the \fBBuddy Pounce\fR dialog to be
--discussed later.
--.TP
--.B View Log
--\fBgaim\fR is capable of automatically log its activities. These logs are
--either plain text files (with a .log extension) or html files (with a
--\&.html extension) located under the \fI~/.gaim/logs\fR directory. This
--menu command will attempt to view this file with \fBgaim\fR's internal log
--viewer.
--.TP
--.B Alias
--Create an alias for this buddy. This will open up a new dialog in which
--one can give this buddy an alternate name to appear on the buddy list and
--in conversations.
--
--For example, if a buddy's name screen name was jsmith1281xx and his real
--name was 'John Q. Smith,' one could create an alias as to identify the
--buddy by his common name.
--.LP
--The remainder of the menu will consist of protocol specific commands.
--These commands vary depending on the protocol.
--.LP
--At the bottom of the \fBBuddy List\fR are several buttons (if enabled in
--\fBPreferences\fR):
--.TP
--.B IM
--Opens a new \fBConversation\fR window to to the selected buddy, or brings
--up the \fBNew Message\fR dialog box if no buddy is selected.
--.TP
--.B Info
--Retrieves and display information about the selected buddy, or brings up
--the \fBGet User Info\fR dialog box if no buddy is selected.
--.TP
--.B Chat
--Brings up the \fBJoin Chat\fR dialog box, prompting the user to select
--which username to use and what chat group to join.
--.TP
--.B Away
--Brings up a menu of all available \fBAway Messages\fR. If an item is
--selected, all online accounts will use this item as their away message.
--
--.SH ACCOUNT EDITOR
--The account editor consists of a list of accounts and information about
--them. Clicking \fIDelete\fR will delete the currently selected account.
--Clicking \fIAdd\fR or \fIModify\fR will invoke a \fBModify Account\fR
--window. Here, you can add or alter account information. When creating a
--new account, you will submit your screen name and password. You will also
--choose your protocol.
--
--If \fIRemember Password\fR is chosen, the password will be saved in
--\fBgaim\fR's configuration file.
--
--If \fIAuto-Login\fR is chosen, this account will automatically login upon
--starting \fBgaim\fR.
--
--Each protocol has it's own specific options that can be found in the
--modify screen.
--
--.SH PREFERENCES
--
--All options take effect immediately.
--
--.SH Interface
--
--\fIDisplay remote nicknames if no alias is set\fR: Toggles whether server
--nickname data should be used if no local alias exists.
--
--.SH Buddy List
--\fISorting\fR: Toggles the order in which buddies are shown in your
--\fBBuddy List\fR between none, alphabetical, by status and by log size.
--
--\fIShow buttons as\fR: Toggles between picture-only, text-only, picture and
--text or no buttons view of the buttons on the \fBBuddy List\fR.
--
--\fIRaise window on events\fR: Tells \fBgaim\fR to bring the \fBBuddy
--List\fR window to the top when buddies sign in or out.
--
--\fIShow numbers in groups\fR: The number of buddies from each group
--currently logged in will be shown along with the total number of buddies in
--the group.
--
--\fIShow buddy icons\fR: Toggles the display of buddies' custom icons.
--
--\fIShow warning levels\fR: Each buddy's warning level will be displayed
--next to the screen name. As a buddy's warning level increases, outgoing
--messages are more and more severely rate-limited.
--
--\fIShow idle times\fR: The amount of time each buddy has been idle will be
--displayed next to the screen name (if the buddy has opted to have their
--client report this information).
--
--\fIDim idle buddies\fR: If enabled, idle buddies will be displayed in grey
--text instead of black text.
--
--\fIAutomatically expand contacts\fR: If enabled, contacts will
--automatically expand to show the associated buddies when the mouse is held
--over the contact for a short period.
--
--.SH Conversations
--
--\fIShow buttons as...\fR: The selected item will determine whether
--picture-only, text-only, combined picture/text, or no buttons will be used
--for \fBConversation\fR windows.
--
--\fIEnable "slash" commands\fR: Determines whether messages starting with
--"slash" (eg. /help) will be interpreted as commands by \fBgaim\fR, or if they
--will just be sent as messages.
--
--\fIShow formatting toolbar\fR: Display the formatting toolbar between the
--upper and lower text boxes in conversations.
--
--\fIShow aliases in tabs/titles\fR: Displays buddy alias instead of screen
--name in window tabs and titles.
--
--\fIShow buddy icons\fR: For protocols that support it, buddy icons allow
--buddies to send small pictures to be displayed during the course of a
--conversation. Turning this option off hides those pictures.
--
--\fIEnable buddy icon animation\fR: If these pictures happen to be animated,
--this option will enable the animation, otherwise only the first frame will
--be displayed.
--
--\fINotify buddies that you are typing to them\fR: Some protocols allow
--clients to tell their buddies when they are typing. This option enables
--this feature for protocols that supports it.
--
--\fIRaise IM windows on events\fR: If enabled, IM \fBConversation\fR windows
--will be brought to the top when new messages are received.
--
--\fIRaise Chat windows on events\fR: If enabled, chat \fBConversation\fR windows
--will be brought to the top when new messages are received.
--
--\fIUse multi-colored screen names in chats\fR: Color code the screen names of
--users in chat rooms.
--
--.TP
--.B Tab Options
--\fIShow IMs and chats in tabbed windows\fR: Tabbed chatting allows one to
--have multiple conversations without multiple windows.
--
--\fIShow close buttons on tabs\fR: Adds a close button to each tab.
--
--\fITab Placement...\fR: Specifies where tabs are shown in the conversation
--window.
--
--\fI New conversation placement...\fR: Determines where new conversations will
--be placed (Last created window / New window / windows grouped by group or
--account / separate windows for IMs and Chats).
--
--.TP
--.B Message Text
--\fIShow timestamp on messages\fR: Toggles the timestamp behavior for
--conversations. Per-conversation behavior can be changed by pressing
--\fIF2\fR in the \fBConversation\fR window.
--
--\fIHighlight misspelled words\fR: Toggles highlighting of misspelled words
--as you type.
--
--\fIIgnore colors/font faces/font sizes\fR: Tells \fBgaim\fR to disregard
--buddies' color/font/size information in displaying IMs or Chats.
--
--\fIDefault Formatting\fR: Allows specifying the default formatting to apply
--to all outgoing messages (only applicable to protocols that support
--formatting in messages).
--
--.TP
--.B Shortcuts
--Allows the user to determine which keyboard shortcuts are available.
--
--.TP
--.B Smiley Themes
--Allows the user to choose between different smiley themes. The "none" theme
--will disable graphical emoticons - they will be displayed as text instead.
--
--.SH Sounds
--
--\fISounds while away\fR: Determines whether sounds are played when an away
--message is up.
--
--\fISound Method\fR lets the user choose between different playback methods.
--The user can also manually enter a command to be executed when a sound is
--to be played (\fI%s\fR expands to the full path to the file name).
--
--.TP
--.B Sound Events
--Lets the user choose when and what sounds are to be played.
--
--.SH Network
--
--.TP
--.B IP Address
--\fIAutodetect IP Address\fR: \fBGaim\fR will attempt to automatically determine
--your IP address for use in file transfers and Direct IMs.
--
--\fIPublic IP\fR: What IP address to use for file transfer and Direct IMs. This
--is mainly useful for users with multiple network interfaces or behind NAT.
--
--.TP
--.B Ports
--\fIManually specify range of ports to listen on\fR: Specify specific ports to
--listen on, overriding any defaults.
--
--.TP
--.B Proxy Server
--The configuration section to enable \fBgaim\fR to operate through a proxy
--server. \fBgaim\fR currently supports SOCKS 4/5 and HTTP proxies.
--
--.SH Browser
--
--Allows the user to select \fBgaim\fR's default web browser. Firefox, Galeon,
--Konqueror, Mozilla, Netscape and Opera are supported natively. The user
--can also manually enter a command to be executed when a link is clicked
--(\fI%s\fR expands to the URL). For example, \fIxterm -e lynx "%s"\fR will
--open the link with lynx. \fIOpen new window by default\fR makes the
--browser use a new window instead of using the current window (or spawning a
--new tab).
--
--.SH Logging
--
--\fIMessage Logs\fR lets the user choose whether \fBConversations\fR and/or
--\fBBuddy Chats\fR will be logged as well as whether logs will be in HTML or
--plain text format. \fISystem Logs\fR describes the types of events to be
--logged.
--
--.SH Away / Idle
--
--\fIQueue new messages when away\fR: Messages received since going Away will
--not be shown until away status is removed.
--
--\fISend auto-response\fR: If someone messages you while away, your
--auto-response will be sent.
--
--\fIOnly send auto-response when idle\fR: If someone messages you while
--away, your auto-response will only be sent if \fBgaim\fR decides that the
--connection is idle.
--
--\fIIdle time reporting\fR: If \fINone\fR is selected, account idle time
--will not be reported. \fIGaim usage\fR infers your idle time from your
--usage of \fBgaim\fR. \fIX usage\fR infers your idle time from \fBX\fR
--(this option may not be universally available).
--
--\fIAuto-away\fR: Determines if and under what conditions \fBgaim\fR will
--automatically turn on the Away status.
--
--.TP
--.B Away Messages
--Lets the user add/edit/remove available \fBAway Messages\fR.
--
--.SH Plugins
--
--Allows the user to enable add-on plugins for \fBgaim\fR. Several of these
--come with \fBgaim\fR, while others must be downloaded separately. The
--\fIDescription\fR field gives the plugin author's description of the
--plugin, while the \fIDetails\fR field gives the plugin's authorship, URL,
--and file name/location information.
--
--Some plugins can be configured. If you load such a plugin, its
--configuration preferences will appear as a submenu to \fBPlugins\fR, with
--the submenu title determined by the plugin's name.
--
--.SH Protocols
--
--Protocols provide protocol specific preferences here.
--
--.SH CONVERSATIONS
--When starting a new conversation, the user is presented with the
--\fBConversation\fR window. The conversation appears in the upper text box
--and the user types his/her message in the lower text box. Between the two
--is a row of settings, represented by icons. Some or all buttons may not be
--active if the protocol does not support the specific formatting. From left
--to right:
--.TP
--.B Bold
--Turns on/off bold.
--.TP
--.B Italics
--Turns on/off italics.
--.TP
--.B Underline
--Turns on/off underline.
--.TP
--.B Decrease font size
--Increases the size of the message text.
--.TP
--.B Increase font size
--Decreases the size of the message text.
--.TP
--.B Select a foreground color
--Changes the foreground color of the message text.
--.TP
--.B Select a background color
--Changes the background color of the message text.
--.TP
--.B Add image
--Inserts an in-line image in the message.
--.TP
--.B Add hyperlink
--Adds a clickable link to the message.
--.TP
--.B Add smiley
--Adds an emoticon (smiley) to your message.
--
--Beneath the lower text box is a row of buttons that execute commands:
--.TP
--.B Warn
--This issues a warning to the other person in the conversation (not
--available in all protocols).
--.TP
--.B Block
--This adds the other person to your deny list (not available in all
--protocols).
--.TP
--.B Send File
--Send a file to this user. This option is only available on protocols where
--\fBGaim\fR supports file transfer.
--.TP
--.B Add
--This adds this user to your buddy list. This option is not available if
--the user is already on your list.
--.TP
--.B Remove
--This removes this user from your buddy list. This option is not available
--if the user is not on your list.
--.TP
--.B Info
--This gets information (a profile) about the other person in the
--conversation (not available in all protocols).
--.TP
--.B Send
--This sends what's currently in the lower text box
--
--.SH BUDDY CHATS
--For protocols that allow it, \fBBuddy Chats\fR can be entered through the
--\fIFile\fR menu or the \fIChat\fR button at the bottom of the \fBBuddy
--List\fR's \fBOnline\fR tab.
--
--Additional commands available in chat, depending on the protocol are:
--.TP
--.B Whisper
--The text will appear in the chat conversation, but it will only be visible
--to the sender and the receiver.
--.TP
--.B Invite
--Invite other people to join the chat room.
--.TP
--.B Ignore
--Ignore anything said by the chosen person
--.TP
--.B Set Topic
--Set the topic of the chat room. This is usually a brief sentence
--describing the nature of the chat--an explanation of the chat room's name.
--
--.SH AWAY MESSAGES
--Most protocols allow for away messages. When a user is \fIAway\fR, he can
--leave an informative message for others to see. The \fBAway\fR submenu of
--the \fBTools\fR menu is used to add and remove away messages.
--
--\fINew Away Message\fR provides space for one to enter an away message and
--a title for that message. If \fISave\fR or \fISave & Use\fR are chosen,
--this message will be saved. It can later be referred to by the title given
--to it.
--
--\fIRemove Away Message\fR is a submenu containing the titles of saved away
--messages. Clicking on one of these titles will remove the away message
--associated with it.
--
--The rest of the \fIaway\fR menu provides the user with a way to assign
--different away messages to different connections. Choosing \fISet All
--Away\fR will set away all the connections capable of the away state.
--
--.SH BUDDY POUNCE
--A Buddy Pounce is an automated trigger that occurs when a buddy returns to
--a normal state from an away state. The \fBNew Buddy Pounce\fR dialog box
--can be activated by selecting the \fIBuddy Pounce\fR submenu from the
--\fBTools\fR menu. A pounce can be set to occur on any combination of the
--events listed, and any combination of actions can result. If \fISave this
--pounce after activation\fR is checked, the trigger will remain until it is
--removed from the \fIRemove Buddy Pounce\fR menu.
--
--.SH PLUGINS
--\fBGaim\fR allows for dynamic loading of plugins to add extra functionality
--to \fBgaim\fR. Plugins can be enabled and configured from the
--\fBPreferences\fR window. See \fIplugins/HOWTO\fR for more information on
--writing plugins.
--
--.SH PERL
--\fBGaim\fR allows for perl scripting. See \fIPerl Scripting HOWTO\fR in
--the Gaim documentation for more information about perl scripting.
--
--.SH TCL
--\fBGaim\fR allows for Tcl scripting. See \fIplugins/tcl/TCL-HOWTO\fR for
--more information about Tcl scripting.
--
--.SH FILES
--\fI@prefix@/bin/gaim\fR: \fBgaim\fR's location.
--.br
--\fI@prefix@/lib/gaim/\fR: \fBgaim\fR's plugins directory.
--.br
--\fI~/.gaim/prefs.xml\fR: \fBgaim\fR's configuration file.
--.br
--\fI~/.gaim/accounts.xml\fR: information about your accounts.
--.br
--\fI~/.gaim/status.xml\fR: stores your away messages.
--.br
--\fI~/.gaim/pounces.xml\fR: stores your buddy pounces.
--.br
--\fI~/.gaim/logs/PROTOCOL/ACCOUNT/SCREENNAME/DATE.log\fR: conversation logs.
--.br
--\fI~/.gaim/blist.xml\fR: the buddy list.
--.br
--\fI~/.gaim/plugins/\fR: users local plugins
--
--.SH BUGS
--Known bugs are listed at
--.br
--\fIhttp://sourceforge.net/tracker/?group_id=235&atid=100235\fR
--
--.SH PATCHES
--If you fix a bug in \fBgaim\fR (or otherwise enhance it), please submit a
--patch (using \fIcvs diff -up > my.diff\fR against the latest CVS version)
--at
--.br
--\fIhttp://sourceforge.net/tracker/?func=add&group_id=235&atid=300235\fR
--
--Before sending a bug report, please verify that you have the latest
--version of \fBgaim\fR. Many bugs (major and minor) are fixed
--at each release, and if yours is out of date, the problem may already
--have been solved.
--
--.SH SEE ALSO
--\fIhttp://gaim.sourceforge.net/\fR
--.br
--\fIhttp://www.sourceforge.net/projects/gaim/\fR
--
--.SH LICENSE
--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
--\fBWITHOUT ANY WARRANTY\fR; 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
--
--.SH AUTHORS
--\fBGaim\fR's active developers are:
--
-- Sean Egan (lead developer) <\fIseanegan@gmail.com\fR>
--.br
-- Daniel 'datallah' Atallah
--.br
-- Ethan 'Paco-Paco' Blanton (developer)
--.br
-- Herman Bloggs (win32 port) <\fIherman@bluedigits.com\fR>
--.br
-- Mark 'KingAnt' Doliner (developer) <\fIthekingant@users.sourceforge.net\fR>
--.br
-- Christian 'ChipX86' Hammond (developer & webmaster) <\fIchipx86@chipx86.com\fR>
--.br
-- Gary 'grim' Kramlich
--.br
-- Richard 'rlaager' Laager <\fIrlaager@users.sf.net\fR>
--.br
-- Christopher 'siege' O'Brien
--.br
-- Etan Reisner
--.br
-- Tim 'marv' Ringenbach <\fImarv_sf@users.sf.net\fR>
--.br
-- Luke 'LSchiere' Schierer (support)
--.br
-- Stu 'nosnilmot' Tomlinson
--.br
-- Nathan 'faceprint' Walp (developer)
--.br
--
--
--Our crazy patch writers include:
--
--Ka-Hing 'javabsp' Cheung
--.br
--Sadrul Habib Chowdhury
--.br
--Felipe 'shx' Contreras
--.br
--Decklin Foster
--.br
--Peter 'Bleeter' Lawler
--.br
--Robert 'Robot101' McQueen
--.br
--Benjamin Miller
--.br
--Kevin 'SimGuy' Stange
--.br
--
--
--The retired developers of \fBgaim\fR are:
--
-- Jim Duchek <\fIjim@linuxpimps.com\fR> (maintainer)
--.br
-- Rob Flynn <\fIgaim@robflynn.com\fR> (maintainer)
--.br
-- Adam Fritzler (libfaim maintainer)
--.br
-- Syd Logan (hacker and designated driver [lazy bum])
--.br
-- Jim Seymour (Jabber developer)
--.br
-- Mark Spencer (original author) <\fImarkster@marko.net\fR>
--.br
-- Eric Warmenhoven (former lead developer) <\fIeric@warmenhoven.org\fR>
--.br
--
--This manpage was originally written by Dennis Ristuccia <\fIdennis@dennisr.net\fR>. It has been updated and largely rewritten by Sean Egan <\fIseanegan@gmail.com\fR> and Ben Tegarden <\fItegarden@uclink.berkeley.edu\fR>.
-diff -prNu ./doc/gaim2.1.in ./doc/gaim2.1.in
---- ./doc/gaim2.1.in 1970-01-01 01:00:00.000000000 +0100
-+++ ./doc/gaim2.1.in 2006-01-05 13:47:52.000000000 +0100
-@@ -0,0 +1,601 @@
-+.\" Copyright (c) 2000, Dennis Ristuccia <dennis@dennisr.net>
-+.\"
-+.\" This is free documentation; 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.
-+.\"
-+.\" The GNU General Public License's references to "object code"
-+.\" and "executables" are to be interpreted as the output of any
-+.\" document formatting or typesetting system, including
-+.\" intermediate and printed output.
-+.\"
-+.\" This manual 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 manual; if not, write to the Free
-+.\" Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,
-+.\" USA.
-+.TH gaim 1
-+.SH NAME
-+Gaim v@VERSION@ \- Instant Messaging client
-+.SH SYNOPSIS
-+.TP 5
-+\fBgaim \fI[options]\fR
-+
-+.SH DESCRIPTION
-+.PP
-+\fBgaim\fR is a GTK2-based Instant Messaging (IM) application. It supports
-+multiple protocols via modules, including AIM, ICQ, Yahoo!, MSN, Jabber,
-+IRC, Napster, Gadu-Gadu and Zephyr. It has many common features found in
-+other clients, as well as many unique features. Gaim is not endorsed by or
-+affiliated with America Online, ICQ, Microsoft, or Yahoo.
-+
-+.SH OPTIONS
-+The following options are provided by \fBgaim\fR using the standard GNU
-+command line syntax:
-+.TP
-+.B \-d, \-\-debug
-+Print debugging messages to stdout. These are the same debugging messages
-+that are displayed in the \fBDebug\fR window.
-+.TP
-+.B \-c, \-\-config=\fIDIR\fB
-+Use \fIDIR\fR as the directory for config files instead of \fI~/.gaim\fR.
-+.TP
-+.B \-h, \-\-help
-+Print this help and exit.
-+.TP
-+.B \-n, \-\-loginwin
-+Don't automatically login when \fBgaim\fR starts. Show the \fBLogin\fR
-+window instead.
-+.TP
-+.B \-v, \-\-version
-+Display the version information window.
-+
-+.SH BUDDY LIST
-+The \fBBuddy List\fR window is \fBgaim\fR's main interface window. Using
-+this window you can see which of your buddies is online, away, idle, etc.
-+You can also add and remove buddies from your buddy list.
-+
-+The \fBBuddy List\fR window contains a list of your buddies who are online
-+and have allowed you to be notified of their presence. The icon to the
-+left of each buddy indicates the buddy's current state and the protocol
-+they are using. Double clicking a buddy will open a new \fBConversation\fR
-+window. Right clicking will pop up a menu:
-+.TP
-+.B Get Info
-+Retrieves and displays information about the buddy. This information is
-+also known as a Profile.
-+.TP
-+.B IM
-+Opens a new \fBConversation\fR window to the selected buddy.
-+.TP
-+.B Send File
-+Sends a file to the selected buddy (only available on protocols that support
-+file transfer).
-+.TP
-+.B Add Buddy Pounce
-+A Buddy Pounce is a configurable automated action to be performed when the
-+buddy's state changes. This will open the \fBBuddy Pounce\fR dialog to be
-+discussed later.
-+.TP
-+.B View Log
-+\fBgaim\fR is capable of automatically log its activities. These logs are
-+either plain text files (with a .log extension) or html files (with a
-+\&.html extension) located under the \fI~/.gaim/logs\fR directory. This
-+menu command will attempt to view this file with \fBgaim\fR's internal log
-+viewer.
-+.TP
-+.B Alias
-+Create an alias for this buddy. This will open up a new dialog in which
-+one can give this buddy an alternate name to appear on the buddy list and
-+in conversations.
-+
-+For example, if a buddy's name screen name was jsmith1281xx and his real
-+name was 'John Q. Smith,' one could create an alias as to identify the
-+buddy by his common name.
-+.LP
-+The remainder of the menu will consist of protocol specific commands.
-+These commands vary depending on the protocol.
-+.LP
-+At the bottom of the \fBBuddy List\fR are several buttons (if enabled in
-+\fBPreferences\fR):
-+.TP
-+.B IM
-+Opens a new \fBConversation\fR window to to the selected buddy, or brings
-+up the \fBNew Message\fR dialog box if no buddy is selected.
-+.TP
-+.B Info
-+Retrieves and display information about the selected buddy, or brings up
-+the \fBGet User Info\fR dialog box if no buddy is selected.
-+.TP
-+.B Chat
-+Brings up the \fBJoin Chat\fR dialog box, prompting the user to select
-+which username to use and what chat group to join.
-+.TP
-+.B Away
-+Brings up a menu of all available \fBAway Messages\fR. If an item is
-+selected, all online accounts will use this item as their away message.
-+
-+.SH ACCOUNT EDITOR
-+The account editor consists of a list of accounts and information about
-+them. Clicking \fIDelete\fR will delete the currently selected account.
-+Clicking \fIAdd\fR or \fIModify\fR will invoke a \fBModify Account\fR
-+window. Here, you can add or alter account information. When creating a
-+new account, you will submit your screen name and password. You will also
-+choose your protocol.
-+
-+If \fIRemember Password\fR is chosen, the password will be saved in
-+\fBgaim\fR's configuration file.
-+
-+If \fIAuto-Login\fR is chosen, this account will automatically login upon
-+starting \fBgaim\fR.
-+
-+Each protocol has it's own specific options that can be found in the
-+modify screen.
-+
-+.SH PREFERENCES
-+
-+All options take effect immediately.
-+
-+.SH Interface
-+
-+\fIDisplay remote nicknames if no alias is set\fR: Toggles whether server
-+nickname data should be used if no local alias exists.
-+
-+.SH Buddy List
-+\fISorting\fR: Toggles the order in which buddies are shown in your
-+\fBBuddy List\fR between none, alphabetical, by status and by log size.
-+
-+\fIShow buttons as\fR: Toggles between picture-only, text-only, picture and
-+text or no buttons view of the buttons on the \fBBuddy List\fR.
-+
-+\fIRaise window on events\fR: Tells \fBgaim\fR to bring the \fBBuddy
-+List\fR window to the top when buddies sign in or out.
-+
-+\fIShow numbers in groups\fR: The number of buddies from each group
-+currently logged in will be shown along with the total number of buddies in
-+the group.
-+
-+\fIShow buddy icons\fR: Toggles the display of buddies' custom icons.
-+
-+\fIShow warning levels\fR: Each buddy's warning level will be displayed
-+next to the screen name. As a buddy's warning level increases, outgoing
-+messages are more and more severely rate-limited.
-+
-+\fIShow idle times\fR: The amount of time each buddy has been idle will be
-+displayed next to the screen name (if the buddy has opted to have their
-+client report this information).
-+
-+\fIDim idle buddies\fR: If enabled, idle buddies will be displayed in grey
-+text instead of black text.
-+
-+\fIAutomatically expand contacts\fR: If enabled, contacts will
-+automatically expand to show the associated buddies when the mouse is held
-+over the contact for a short period.
-+
-+.SH Conversations
-+
-+\fIShow buttons as...\fR: The selected item will determine whether
-+picture-only, text-only, combined picture/text, or no buttons will be used
-+for \fBConversation\fR windows.
-+
-+\fIEnable "slash" commands\fR: Determines whether messages starting with
-+"slash" (eg. /help) will be interpreted as commands by \fBgaim\fR, or if they
-+will just be sent as messages.
-+
-+\fIShow formatting toolbar\fR: Display the formatting toolbar between the
-+upper and lower text boxes in conversations.
-+
-+\fIShow aliases in tabs/titles\fR: Displays buddy alias instead of screen
-+name in window tabs and titles.
-+
-+\fIShow buddy icons\fR: For protocols that support it, buddy icons allow
-+buddies to send small pictures to be displayed during the course of a
-+conversation. Turning this option off hides those pictures.
-+
-+\fIEnable buddy icon animation\fR: If these pictures happen to be animated,
-+this option will enable the animation, otherwise only the first frame will
-+be displayed.
-+
-+\fINotify buddies that you are typing to them\fR: Some protocols allow
-+clients to tell their buddies when they are typing. This option enables
-+this feature for protocols that supports it.
-+
-+\fIRaise IM windows on events\fR: If enabled, IM \fBConversation\fR windows
-+will be brought to the top when new messages are received.
-+
-+\fIRaise Chat windows on events\fR: If enabled, chat \fBConversation\fR windows
-+will be brought to the top when new messages are received.
-+
-+\fIUse multi-colored screen names in chats\fR: Color code the screen names of
-+users in chat rooms.
-+
-+.TP
-+.B Tab Options
-+\fIShow IMs and chats in tabbed windows\fR: Tabbed chatting allows one to
-+have multiple conversations without multiple windows.
-+
-+\fIShow close buttons on tabs\fR: Adds a close button to each tab.
-+
-+\fITab Placement...\fR: Specifies where tabs are shown in the conversation
-+window.
-+
-+\fI New conversation placement...\fR: Determines where new conversations will
-+be placed (Last created window / New window / windows grouped by group or
-+account / separate windows for IMs and Chats).
-+
-+.TP
-+.B Message Text
-+\fIShow timestamp on messages\fR: Toggles the timestamp behavior for
-+conversations. Per-conversation behavior can be changed by pressing
-+\fIF2\fR in the \fBConversation\fR window.
-+
-+\fIHighlight misspelled words\fR: Toggles highlighting of misspelled words
-+as you type.
-+
-+\fIIgnore colors/font faces/font sizes\fR: Tells \fBgaim\fR to disregard
-+buddies' color/font/size information in displaying IMs or Chats.
-+
-+\fIDefault Formatting\fR: Allows specifying the default formatting to apply
-+to all outgoing messages (only applicable to protocols that support
-+formatting in messages).
-+
-+.TP
-+.B Shortcuts
-+Allows the user to determine which keyboard shortcuts are available.
-+
-+.TP
-+.B Smiley Themes
-+Allows the user to choose between different smiley themes. The "none" theme
-+will disable graphical emoticons - they will be displayed as text instead.
-+
-+.SH Sounds
-+
-+\fISounds while away\fR: Determines whether sounds are played when an away
-+message is up.
-+
-+\fISound Method\fR lets the user choose between different playback methods.
-+The user can also manually enter a command to be executed when a sound is
-+to be played (\fI%s\fR expands to the full path to the file name).
-+
-+.TP
-+.B Sound Events
-+Lets the user choose when and what sounds are to be played.
-+
-+.SH Network
-+
-+.TP
-+.B IP Address
-+\fIAutodetect IP Address\fR: \fBGaim\fR will attempt to automatically determine
-+your IP address for use in file transfers and Direct IMs.
-+
-+\fIPublic IP\fR: What IP address to use for file transfer and Direct IMs. This
-+is mainly useful for users with multiple network interfaces or behind NAT.
-+
-+.TP
-+.B Ports
-+\fIManually specify range of ports to listen on\fR: Specify specific ports to
-+listen on, overriding any defaults.
-+
-+.TP
-+.B Proxy Server
-+The configuration section to enable \fBgaim\fR to operate through a proxy
-+server. \fBgaim\fR currently supports SOCKS 4/5 and HTTP proxies.
-+
-+.SH Browser
-+
-+Allows the user to select \fBgaim\fR's default web browser. Firefox, Galeon,
-+Konqueror, Mozilla, Netscape and Opera are supported natively. The user
-+can also manually enter a command to be executed when a link is clicked
-+(\fI%s\fR expands to the URL). For example, \fIxterm -e lynx "%s"\fR will
-+open the link with lynx. \fIOpen new window by default\fR makes the
-+browser use a new window instead of using the current window (or spawning a
-+new tab).
-+
-+.SH Logging
-+
-+\fIMessage Logs\fR lets the user choose whether \fBConversations\fR and/or
-+\fBBuddy Chats\fR will be logged as well as whether logs will be in HTML or
-+plain text format. \fISystem Logs\fR describes the types of events to be
-+logged.
-+
-+.SH Away / Idle
-+
-+\fIQueue new messages when away\fR: Messages received since going Away will
-+not be shown until away status is removed.
-+
-+\fISend auto-response\fR: If someone messages you while away, your
-+auto-response will be sent.
-+
-+\fIOnly send auto-response when idle\fR: If someone messages you while
-+away, your auto-response will only be sent if \fBgaim\fR decides that the
-+connection is idle.
-+
-+\fIIdle time reporting\fR: If \fINone\fR is selected, account idle time
-+will not be reported. \fIGaim usage\fR infers your idle time from your
-+usage of \fBgaim\fR. \fIX usage\fR infers your idle time from \fBX\fR
-+(this option may not be universally available).
-+
-+\fIAuto-away\fR: Determines if and under what conditions \fBgaim\fR will
-+automatically turn on the Away status.
-+
-+.TP
-+.B Away Messages
-+Lets the user add/edit/remove available \fBAway Messages\fR.
-+
-+.SH Plugins
-+
-+Allows the user to enable add-on plugins for \fBgaim\fR. Several of these
-+come with \fBgaim\fR, while others must be downloaded separately. The
-+\fIDescription\fR field gives the plugin author's description of the
-+plugin, while the \fIDetails\fR field gives the plugin's authorship, URL,
-+and file name/location information.
-+
-+Some plugins can be configured. If you load such a plugin, its
-+configuration preferences will appear as a submenu to \fBPlugins\fR, with
-+the submenu title determined by the plugin's name.
-+
-+.SH Protocols
-+
-+Protocols provide protocol specific preferences here.
-+
-+.SH CONVERSATIONS
-+When starting a new conversation, the user is presented with the
-+\fBConversation\fR window. The conversation appears in the upper text box
-+and the user types his/her message in the lower text box. Between the two
-+is a row of settings, represented by icons. Some or all buttons may not be
-+active if the protocol does not support the specific formatting. From left
-+to right:
-+.TP
-+.B Bold
-+Turns on/off bold.
-+.TP
-+.B Italics
-+Turns on/off italics.
-+.TP
-+.B Underline
-+Turns on/off underline.
-+.TP
-+.B Decrease font size
-+Increases the size of the message text.
-+.TP
-+.B Increase font size
-+Decreases the size of the message text.
-+.TP
-+.B Select a foreground color
-+Changes the foreground color of the message text.
-+.TP
-+.B Select a background color
-+Changes the background color of the message text.
-+.TP
-+.B Add image
-+Inserts an in-line image in the message.
-+.TP
-+.B Add hyperlink
-+Adds a clickable link to the message.
-+.TP
-+.B Add smiley
-+Adds an emoticon (smiley) to your message.
-+
-+Beneath the lower text box is a row of buttons that execute commands:
-+.TP
-+.B Warn
-+This issues a warning to the other person in the conversation (not
-+available in all protocols).
-+.TP
-+.B Block
-+This adds the other person to your deny list (not available in all
-+protocols).
-+.TP
-+.B Send File
-+Send a file to this user. This option is only available on protocols where
-+\fBGaim\fR supports file transfer.
-+.TP
-+.B Add
-+This adds this user to your buddy list. This option is not available if
-+the user is already on your list.
-+.TP
-+.B Remove
-+This removes this user from your buddy list. This option is not available
-+if the user is not on your list.
-+.TP
-+.B Info
-+This gets information (a profile) about the other person in the
-+conversation (not available in all protocols).
-+.TP
-+.B Send
-+This sends what's currently in the lower text box
-+
-+.SH BUDDY CHATS
-+For protocols that allow it, \fBBuddy Chats\fR can be entered through the
-+\fIFile\fR menu or the \fIChat\fR button at the bottom of the \fBBuddy
-+List\fR's \fBOnline\fR tab.
-+
-+Additional commands available in chat, depending on the protocol are:
-+.TP
-+.B Whisper
-+The text will appear in the chat conversation, but it will only be visible
-+to the sender and the receiver.
-+.TP
-+.B Invite
-+Invite other people to join the chat room.
-+.TP
-+.B Ignore
-+Ignore anything said by the chosen person
-+.TP
-+.B Set Topic
-+Set the topic of the chat room. This is usually a brief sentence
-+describing the nature of the chat--an explanation of the chat room's name.
-+
-+.SH AWAY MESSAGES
-+Most protocols allow for away messages. When a user is \fIAway\fR, he can
-+leave an informative message for others to see. The \fBAway\fR submenu of
-+the \fBTools\fR menu is used to add and remove away messages.
-+
-+\fINew Away Message\fR provides space for one to enter an away message and
-+a title for that message. If \fISave\fR or \fISave & Use\fR are chosen,
-+this message will be saved. It can later be referred to by the title given
-+to it.
-+
-+\fIRemove Away Message\fR is a submenu containing the titles of saved away
-+messages. Clicking on one of these titles will remove the away message
-+associated with it.
-+
-+The rest of the \fIaway\fR menu provides the user with a way to assign
-+different away messages to different connections. Choosing \fISet All
-+Away\fR will set away all the connections capable of the away state.
-+
-+.SH BUDDY POUNCE
-+A Buddy Pounce is an automated trigger that occurs when a buddy returns to
-+a normal state from an away state. The \fBNew Buddy Pounce\fR dialog box
-+can be activated by selecting the \fIBuddy Pounce\fR submenu from the
-+\fBTools\fR menu. A pounce can be set to occur on any combination of the
-+events listed, and any combination of actions can result. If \fISave this
-+pounce after activation\fR is checked, the trigger will remain until it is
-+removed from the \fIRemove Buddy Pounce\fR menu.
-+
-+.SH PLUGINS
-+\fBGaim\fR allows for dynamic loading of plugins to add extra functionality
-+to \fBgaim\fR. Plugins can be enabled and configured from the
-+\fBPreferences\fR window. See \fIplugins/HOWTO\fR for more information on
-+writing plugins.
-+
-+.SH PERL
-+\fBGaim\fR allows for perl scripting. See \fIPerl Scripting HOWTO\fR in
-+the Gaim documentation for more information about perl scripting.
-+
-+.SH TCL
-+\fBGaim\fR allows for Tcl scripting. See \fIplugins/tcl/TCL-HOWTO\fR for
-+more information about Tcl scripting.
-+
-+.SH FILES
-+\fI@prefix@/bin/gaim\fR: \fBgaim\fR's location.
-+.br
-+\fI@prefix@/lib/gaim/\fR: \fBgaim\fR's plugins directory.
-+.br
-+\fI~/.gaim/prefs.xml\fR: \fBgaim\fR's configuration file.
-+.br
-+\fI~/.gaim/accounts.xml\fR: information about your accounts.
-+.br
-+\fI~/.gaim/status.xml\fR: stores your away messages.
-+.br
-+\fI~/.gaim/pounces.xml\fR: stores your buddy pounces.
-+.br
-+\fI~/.gaim/logs/PROTOCOL/ACCOUNT/SCREENNAME/DATE.log\fR: conversation logs.
-+.br
-+\fI~/.gaim/blist.xml\fR: the buddy list.
-+.br
-+\fI~/.gaim/plugins/\fR: users local plugins
-+
-+.SH BUGS
-+Known bugs are listed at
-+.br
-+\fIhttp://sourceforge.net/tracker/?group_id=235&atid=100235\fR
-+
-+.SH PATCHES
-+If you fix a bug in \fBgaim\fR (or otherwise enhance it), please submit a
-+patch (using \fIcvs diff -up > my.diff\fR against the latest CVS version)
-+at
-+.br
-+\fIhttp://sourceforge.net/tracker/?func=add&group_id=235&atid=300235\fR
-+
-+Before sending a bug report, please verify that you have the latest
-+version of \fBgaim\fR. Many bugs (major and minor) are fixed
-+at each release, and if yours is out of date, the problem may already
-+have been solved.
-+
-+.SH SEE ALSO
-+\fIhttp://gaim.sourceforge.net/\fR
-+.br
-+\fIhttp://www.sourceforge.net/projects/gaim/\fR
-+
-+.SH LICENSE
-+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
-+\fBWITHOUT ANY WARRANTY\fR; 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
-+
-+.SH AUTHORS
-+\fBGaim\fR's active developers are:
-+
-+ Sean Egan (lead developer) <\fIseanegan@gmail.com\fR>
-+.br
-+ Daniel 'datallah' Atallah
-+.br
-+ Ethan 'Paco-Paco' Blanton (developer)
-+.br
-+ Herman Bloggs (win32 port) <\fIherman@bluedigits.com\fR>
-+.br
-+ Mark 'KingAnt' Doliner (developer) <\fIthekingant@users.sourceforge.net\fR>
-+.br
-+ Christian 'ChipX86' Hammond (developer & webmaster) <\fIchipx86@chipx86.com\fR>
-+.br
-+ Gary 'grim' Kramlich
-+.br
-+ Richard 'rlaager' Laager <\fIrlaager@users.sf.net\fR>
-+.br
-+ Christopher 'siege' O'Brien
-+.br
-+ Etan Reisner
-+.br
-+ Tim 'marv' Ringenbach <\fImarv_sf@users.sf.net\fR>
-+.br
-+ Luke 'LSchiere' Schierer (support)
-+.br
-+ Stu 'nosnilmot' Tomlinson
-+.br
-+ Nathan 'faceprint' Walp (developer)
-+.br
-+
-+
-+Our crazy patch writers include:
-+
-+Ka-Hing 'javabsp' Cheung
-+.br
-+Sadrul Habib Chowdhury
-+.br
-+Felipe 'shx' Contreras
-+.br
-+Decklin Foster
-+.br
-+Peter 'Bleeter' Lawler
-+.br
-+Robert 'Robot101' McQueen
-+.br
-+Benjamin Miller
-+.br
-+Kevin 'SimGuy' Stange
-+.br
-+
-+
-+The retired developers of \fBgaim\fR are:
-+
-+ Jim Duchek <\fIjim@linuxpimps.com\fR> (maintainer)
-+.br
-+ Rob Flynn <\fIgaim@robflynn.com\fR> (maintainer)
-+.br
-+ Adam Fritzler (libfaim maintainer)
-+.br
-+ Syd Logan (hacker and designated driver [lazy bum])
-+.br
-+ Jim Seymour (Jabber developer)
-+.br
-+ Mark Spencer (original author) <\fImarkster@marko.net\fR>
-+.br
-+ Eric Warmenhoven (former lead developer) <\fIeric@warmenhoven.org\fR>
-+.br
-+
-+This manpage was originally written by Dennis Ristuccia <\fIdennis@dennisr.net\fR>. It has been updated and largely rewritten by Sean Egan <\fIseanegan@gmail.com\fR> and Ben Tegarden <\fItegarden@uclink.berkeley.edu\fR>.
-diff -prNu ./doc/Makefile.am ./doc/Makefile.am
---- ./doc/Makefile.am 2005-12-08 03:59:44.000000000 +0100
-+++ ./doc/Makefile.am 2006-01-05 13:47:42.000000000 +0100
-@@ -1,4 +1,4 @@
--man_MANS = gaim.1
-+man_MANS = gaim2.1
-
- EXTRA_DIST = \
- C-HOWTO.dox \
-@@ -13,7 +13,7 @@ EXTRA_DIST = \
- conversation-signals.dox \
- core-signals.dox \
- dbus-server-signals.dox \
-- gaim.1.in \
-+ gaim2.1.in \
- gaims_funniest_home_convos.txt \
- gtkaccount-signals.dox \
- gtkblist-signals.dox \
-diff -prNu ./gaim2.apspec.in ./gaim2.apspec.in
---- ./gaim2.apspec.in 1970-01-01 01:00:00.000000000 +0100
-+++ ./gaim2.apspec.in 2005-09-01 05:32:52.000000000 +0200
-@@ -0,0 +1,66 @@
-+# -*-shell-script-*-
-+
-+[Meta]
-+RootName: @gaim.sourceforge.net/gaim:$SOFTWAREVERSION
-+DisplayName: Gaim Internet Messenger
-+ShortName: gaim
-+Maintainer: The Gaim Developers
-+URL: http://gaim.sourceforge.net/
-+Packager: Tim Ringenbach <marv_sf@users.sourceforge.net>
-+Summary: A GTK+ based multiprotocol instant messaging client
-+SoftwareVersion: @VERSION@
-+InterfaceVersion: 2.0
-+PackageVersion: 1
-+
-+[Description]
-+Gaim allows you to talk to anyone using a variety of messaging protocols,
-+including AIM (Oscar and TOC), ICQ, IRC, Yahoo!, MSN Messenger, Jabber,
-+Gadu-Gadu, Napster, and Zephyr. These protocols are implemented using a
-+modular, easy to use design. To use a protocol, just add an account using the
-+account editor.
-+
-+Gaim supports many common features of other clients, as well as many unique
-+features, such as perl scripting, TCL scripting and C plugins.
-+
-+Gaim is NOT affiliated with or endorsed by America Online, Inc., Microsoft
-+Corporation, Yahoo! Inc., or ICQ Inc.
-+
-+[BuildPrepare]
-+prepareBuild --enable-nss --enable-gnutls --enable-binreloc --disable-perl --disable-tcl --disable-gtktest
-+
-+[BuildUnprepare]
-+unprepareBuild
-+
-+[Imports]
-+rm -rf include
-+rm -rf lib/pkgconfig
-+find -name '*.la' | xargs rm
-+echo '*' | import
-+
-+[Prepare]
-+# Dependency checking
-+require @gtk.org/gtk 2.2
-+require @68k.org/libaudiofile 0.0
-+require @xiph.org/libao 2.0
-+require @gtkspell.sourceforge.net/gtkspell 0.0
-+require @gnutls.org/gnutls 11.0 || { require @mozilla.org/nspr 4 && require @mozilla.org/nss 3; }
-+
-+[Install]
-+# Put your installation script here
-+installExe ./bin/*
-+# do the plugins
-+copyFiles ./lib/gaim "$PREFIX/lib"
-+installMan 1 ./man/man1/gaim.1
-+installDesktop "Networking/Instant Messaging" ./share/applications/gaim.desktop
-+installLocale ./share/locale
-+copyFiles ./share/pixmaps "$PREFIX/share"
-+copyFiles ./share/sounds "$PREFIX/share"
-+installIcon ./share/pixmaps/gaim.png
-+# install and fix the .pc file
-+# move this to the -devel package when I make one
-+# copyFile ./lib/pkgconfig/gaim.pc "$PREFIX/lib/pkgconfig/gaim.pc"
-+# safeSed "$PREFIX/lib/pkgconfig/gaim.pc" "s|prefix=/usr/local|prefix=$PREFIX|"
-+
-+[Uninstall]
-+# Usually just the following line is enough to uninstall everything
-+uninstallFromLog
-diff -prNu ./gaim2.desktop ./gaim2.desktop
---- ./gaim2.desktop 1970-01-01 01:00:00.000000000 +0100
-+++ ./gaim2.desktop 2005-11-18 23:34:27.000000000 +0100
-@@ -0,0 +1,80 @@
-+[Desktop Entry]
-+Encoding=UTF-8
-+Categories=Application;Network;
-+Exec=gaim
-+Icon=gaim.png
-+StartupNotify=true
-+Terminal=false
-+Type=Application
-+
-+Name=Gaim Internet Messenger
-+Name[ca]=Missatger d'Internet Gaim
-+Name[cs]=Gaim Internet Messenger
-+Name[da]=Gaim - internet beskeder
-+Name[de]=Gaim Internet Messenger
-+Name[es]=Gaim - cliente de mensajería de Internet
-+Name[fr]=Gaim Messagerie Internet
-+Name[hu]=Gaim azonnali üzenetküldő
-+Name[it]=Gaim Internet Messenger
-+Name[ja]=Gaim インターãƒãƒƒãƒˆãƒ»ãƒ¡ãƒƒã‚»ãƒ³ã‚¸ãƒ£ãƒ¼
-+Name[ko]=게임 메신저
-+Name[nb]=Gaim lynmeldingsklient
-+Name[nl]=Gaim - Expresberichten
-+Name[pl]=Komunikator Internetowy Gaim
-+Name[pt_BR]=Mensageiro via Internet Gaim
-+Name[pt]=Mensageiro Internet Gaim
-+Name[ro]=Mesagerul Gaim
-+Name[ru]=Gaim - клиент обмена мгновенными ÑообщениÑми
-+Name[sl]=Gaim - spletni sel
-+Name[sq]=Lajmësjellësi Internet Gaim
-+Name[sv]=Gaim Internet Messenger
-+Name[zh_CN]=Gaim 互è”网通讯程åº
-+Name[zh_TW]=Gaim 網路å³æ™‚通
-+
-+GenericName=Internet Messenger
-+GenericName[ca]=Missatger d'Internet
-+GenericName[cs]=Internet Messenger
-+GenericName[da]=Internet beskeder
-+GenericName[de]=Internet Messenger
-+GenericName[es]=Cliente de mensajería de Internet
-+GenericName[fr]=Messagerie internet
-+GenericName[hu]=Azonnali üzenetküldő
-+GenericName[it]=Internet Messenger
-+GenericName[ja]=インターãƒãƒƒãƒˆãƒ»ãƒ¡ãƒƒã‚»ãƒ³ã‚¸ãƒ£ãƒ¼
-+GenericName[ko]=메신저
-+GenericName[nb]=Lynmeldingsklient
-+GenericName[nl]=Expresberichten
-+GenericName[pl]=Komunikator Internetowy
-+GenericName[pt_BR]=Mensageiro via Internet
-+GenericName[pt]=Mensageiro Internet
-+GenericName[ro]=Client de mesagerie
-+GenericName[ru]=Клиент обмена мгновенными ÑообщениÑми
-+GenericName[sl]=Spletni sel
-+GenericName[sq]=Lajmësjellës Internet
-+GenericName[sv]=Meddelandeklient
-+GenericName[zh_CN]=互è”网通讯程åº
-+GenericName[zh_TW]=網路å³æ™‚通
-+
-+Comment=Send instant messages over multiple protocols
-+Comment[ca]=Envieu missatges instantanis en múltiples protocols
-+Comment[cs]=Posílat instant message různými protokoly
-+Comment[da]=Send beskeder over flere protokoller
-+Comment[de]=Multi-Protokoll Instant Messenger Client
-+Comment[es]=Cliente de mensajería instantánea multiprotocolo
-+Comment[fr]=Envoie des messages instantanés en utilisant divers protocoles
-+Comment[hu]=Azonnali üzenetküldés többféle protokoll használatával
-+Comment[it]=Client multiprotocollo per messaggi immediati
-+Comment[ja]=複数ã®ãƒ—ロトコルを介ã—ã¦ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ãƒˆãƒ»ãƒ¡ãƒƒã‚»ãƒ¼ã‚¸ã‚’é€ä¿¡ã—ã¾ã™
-+Comment[ko]=다중 프로토콜 메신저
-+Comment[nb]=Send lynmeldinger over flere protokoller
-+Comment[nl]=Multi-protocol programma voor expresberichten
-+Comment[pl]=Komunikator internetowy obsługujący kilka protokołów
-+Comment[pt_BR]=Mande mensagens instantâneas por múltiplos protocolos
-+Comment[pt]=Envie mensagens instantâneas sobre vários protocolos
-+Comment[ro]=Trimiteţi mesaje instant în orice reţea
-+Comment[ru]=Обмен мгновенными ÑообщениÑми Ñ Ð¸Ñпользованием множеÑтва протоколов
-+Comment[sl]=PoÅ¡iljajte neposredna sporoÄila prek razliÄnih protokolovs
-+Comment[sq]=Dërgoni mesazhe të atypëratyshëm protokollesh të ndryshëm
-+Comment[sv]=Sänder snabbmeddelande över många protokoll
-+Comment[zh_CN]=通过多ç§åè®®å‘é€å³æ—¶æ¶ˆæ¯
-+Comment[zh_TW]=é€éŽå¤šç¨®é€šè¨Šå”定發é€å³æ™‚訊æ¯
-diff -prNu ./gaim2.pc.in ./gaim2.pc.in
---- ./gaim2.pc.in 1970-01-01 01:00:00.000000000 +0100
-+++ ./gaim2.pc.in 2006-01-05 13:42:37.000000000 +0100
-@@ -0,0 +1,13 @@
-+prefix=@prefix@
-+exec_prefix=@exec_prefix@
-+libdir=@libdir@
-+includedir=@includedir@
-+datadir=@datadir@
-+sysconfdir=@sysconfdir@
-+
-+Name: Gaim
-+Description: Gaim is a GTK2-based instant messenger application.
-+Version: @VERSION@
-+Requires: glib-2.0
-+Cflags: -I${includedir}/gaim2
-+
-diff -prNu ./gaim2.spec.in ./gaim2.spec.in
---- ./gaim2.spec.in 1970-01-01 01:00:00.000000000 +0100
-+++ ./gaim2.spec.in 2006-01-02 16:48:28.000000000 +0100
-@@ -0,0 +1,345 @@
-+# Older RPM doesn't define these by default
-+%{!?perl_vendorlib: %define perl_vendorlib %(eval "`%{__perl} -V:installvendorlib`"; echo $installvendorlib)}
-+%{!?perl_vendorarch: %define perl_vendorarch %(eval "`%{__perl} -V:installvendorarch`"; echo $installvendorarch)}
-+%{!?perl_archlib: %define perl_archlib %(eval "`%{__perl} -V:installarchlib`"; echo $installarchlib)}
-+
-+# When not doing betas set this to 0
-+%define beta 1
-+
-+%if 0%{beta}
-+%define gaimver %(echo "@VERSION@"|sed -e 's/cvs//; s/beta.*//')
-+%else
-+%define gaimver @VERSION@
-+%endif
-+
-+Summary: A Gtk+ based multiprotocol instant messaging client
-+Name: @PACKAGE@
-+Version: %gaimver
-+Release: 0%{?beta:.beta%{beta}}
-+Epoch: 1
-+License: GPL
-+Group: Applications/Internet
-+URL: http://gaim.sourceforge.net/
-+Packager: %{packager}
-+Source: %{name}-@VERSION@.tar.gz
-+BuildRoot: %{_tmppath}/%{name}-%{version}-root
-+
-+# Generic build requirements
-+BuildRequires: libtool, pkgconfig, libao-devel, audiofile-devel
-+%{?_with_howl:BuildRequires: howl-devel}
-+%{?_with_silc:BuildRequires: /usr/include/silc/silcclient.h}
-+%{?_with_meanwhile:BuildRequires: meanwhile-devel}
-+%{?_with_tcl:BuildRequires: tcl, tk, /usr/include/tcl.h}
-+%{?_with_mono:BuildRequires: mono-devel}
-+%{?_with_dbus:BuildRequires: dbus-devel >= 0.35}
-+%{!?_without_gtkspell:BuildRequires: gtkspell-devel}
-+%{?_with_sasl:BuildRequires: cyrus-sasl-devel >= 2}
-+# For some reason perl isn't always automatically detected as a requirement :(
-+Requires: perl
-+
-+# Mandrake 10.1 and lower || Mandrake 10.2 (and higher?)
-+%if "%{_vendor}" == "MandrakeSoft" || "%{_vendor}" == "Mandrakesoft" || "%{_vendor}" == "Mandriva"
-+# Mandrake/Mandriva requirements
-+BuildRequires: libgtk+2.0_0-devel, libnss3-devel, perl-devel
-+Obsoletes: libgaim-remote0
-+%else
-+
-+# SuSE & Red Hat / Fedora requirements
-+BuildRequires: gtk2-devel
-+
-+%if "%{_vendor}" == "suse"
-+BuildRequires: gnutls-devel
-+%else
-+BuildRequires: mozilla-nss-devel
-+%endif
-+%endif
-+
-+%if 0%{?_with_howl:1}
-+%package bonjour
-+Summary: Bonjour plugin for Gaim
-+Group: Applications/Internet
-+Requires: gaim = %{epoch}:%{version}
-+%endif
-+
-+%if 0%{?_with_silc:1}
-+%package silc
-+Summary: SILC (Secure Internet Live Conferencing) plugin for Gaim
-+Group: Applications/Internet
-+Requires: gaim = %{epoch}:%{version}
-+%endif
-+
-+%if 0%{?_with_meanwhile:1}
-+%package meanwhile
-+Summary: Lotus Sametime plugin for Gaim using the Meanwhile library
-+Group: Applications/Internet
-+Requires: gaim = %{epoch}:%{version}
-+%endif
-+
-+%if 0%{?_with_tcl:1}
-+%package tcl
-+Summary: Tcl scripting support for Gaim
-+Group: Applications/Internet
-+Requires: gaim = %{epoch}:%{version}
-+%endif
-+
-+%if 0%{?_with_mono:1}
-+%package mono
-+Summary: Mono .NET plugin support for Gaim
-+Group: Applications/Internet
-+Requires: gaim = %{epoch}:%{version}
-+%endif
-+
-+%package devel
-+Summary: Development headers, documentation, and libraries for Gaim.
-+Group: Applications/Internet
-+Requires: pkgconfig, gaim = %{epoch}:%{version}
-+
-+%description
-+Gaim allows you to talk to anyone using a variety of messaging
-+protocols, including AIM, ICQ, IRC, Yahoo!, Novell Groupwise, MSN
-+Messenger, Jabber, Gadu-Gadu, Napster, Lotus Sametime and Zephyr.
-+These protocols are implemented using a modular, easy to use design.
-+To use a protocol, just add an account using the account editor.
-+
-+Gaim supports many common features of other clients, as well as many
-+unique features, such as perl scripting, TCL scripting and C plugins.
-+
-+Gaim is NOT affiliated with or endorsed by America Online, Inc.,
-+Microsoft Corporation, Yahoo! Inc., or ICQ Inc.
-+
-+%if 0%{?_with_howl:1}
-+%description bonjour
-+Bonjour plugin for Gaim
-+%endif
-+
-+%if 0%{?_with_silc:1}
-+%description silc
-+SILC (Secure Internet Live Conferencing) plugin for Gaim
-+%endif
-+
-+%if 0%{?_with_meanwhile:1}
-+%description meanwhile
-+Lotus Sametime plugin for Gaim using the Meanwhile library
-+%endif
-+
-+%if 0%{?_with_tcl:1}
-+%description tcl
-+Tcl plugin loader for Gaim. This package will allow you to write or
-+use Gaim plugins written in the Tcl programming language.
-+%endif
-+
-+%if 0%{?_with_mono:1}
-+%description mono
-+Mono plugin loader for Gaim. This package will allow you to write or
-+use Gaim plugins written in the .NET programming language.
-+%endif
-+
-+%description devel
-+The gaim-devel package contains the header files, developer
-+documentation, and libraries required for development of gaim scripts
-+and plugins.
-+
-+%prep
-+%setup -q -n %{name}-@VERSION@
-+
-+%build
-+CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{_prefix} \
-+ --bindir=%{_bindir} \
-+ --datadir=%{_datadir} \
-+ --includedir=%{_includedir} \
-+ --libdir=%{_libdir} \
-+ --mandir=%{_mandir} \
-+ --sysconfdir=%{_sysconfdir} \
-+ --with-ao=%{_libdir} \
-+ --with-perl-lib=%{_prefix} \
-+ %{?_with_silc:--with-silc-includes=%{_includedir}/silc} \
-+ %{?_with_silc:--with-silc-libs=%{_libdir}/silc} \
-+ %{?_with_mono:--enable-mono} \
-+ %{!?_with_tcl:--disable-tcl} \
-+ %{!?_with_dbus:--disable-dbus} \
-+ %{?_without_gtkspell:--disable-gtkspell} \
-+ %{?_with_sasl:--enable-cyrus-sasl}
-+
-+make %{?_smp_mflags}
-+
-+%install
-+rm -rf %{buildroot}
-+make DESTDIR=$RPM_BUILD_ROOT install
-+
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/*.la
-+rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
-+rm -f $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
-+find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'
-+find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -exec rm -f {} ';'
-+
-+%if 0%{!?_with_howl:1}
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/libbonjour.so
-+%endif
-+
-+%if 0%{!?_with_silc:1}
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/libsilcgaim.so
-+%endif
-+
-+%if 0%{!?_with_meanwhile:1}
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/libsametime.so
-+%endif
-+
-+%if 0%{!?_with_tcl:1}
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/tcl.so
-+%endif
-+
-+%if 0%{!?_with_mono:1}
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/mono.so
-+rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/*.dll
-+%endif
-+
-+
-+find $RPM_BUILD_ROOT%{_libdir}/gaim -type f -print | \
-+ sed "s@^$RPM_BUILD_ROOT@@g" | \
-+ grep -v libbonjour.so | \
-+ grep -v libsilcgaim.so | \
-+ grep -v libsametime.so | \
-+ grep -v tcl.so | \
-+ grep -v mono.so | \
-+ grep -v ".dll$" | \
-+ grep -v ".tcl$" > %{name}-%{version}-coreplugins
-+
-+%clean
-+rm -rf %{buildroot}
-+
-+%files -f %{name}-%{version}-coreplugins
-+%defattr(-, root, root)
-+
-+%doc doc/the_penguin.txt doc/CREDITS NEWS COPYING AUTHORS COPYRIGHT
-+%doc README ChangeLog
-+%doc %{_mandir}/man1/*
-+%doc %{_mandir}/man3*/*
-+
-+%dir %{_libdir}/gaim
-+%attr(755, root, root) %{perl_vendorarch}/Gaim*
-+%attr(755, root, root) %{perl_vendorarch}/auto/Gaim
-+
-+%{_bindir}/*
-+%{_datadir}/locale/*/*/*
-+%{_datadir}/pixmaps/*
-+%dir %{_datadir}/sounds/gaim
-+%{_datadir}/sounds/gaim/*
-+%{_datadir}/applications/*
-+
-+%if 0%{?_with_dbus:1}
-+%{_libdir}/libgaim-client.so.*
-+%{_datadir}/dbus-1/services/gaim.service
-+%endif
-+
-+%if 0%{?_with_howl:1}
-+%files bonjour
-+%defattr(-, root, root)
-+
-+%{_libdir}/gaim/libbonjour.*
-+%endif
-+
-+%if 0%{?_with_silc:1}
-+%files silc
-+%defattr(-, root, root)
-+
-+%{_libdir}/gaim/libsilcgaim.*
-+%endif
-+
-+%if 0%{?_with_meanwhile:1}
-+%files meanwhile
-+%defattr(-, root, root)
-+
-+%{_libdir}/gaim/libsametime.*
-+%endif
-+
-+%if 0%{?_with_tcl:1}
-+%files tcl
-+%defattr(-, root, root)
-+
-+%{_libdir}/gaim/tcl.so
-+%endif
-+
-+%if 0%{?_with_mono:1}
-+%files mono
-+%defattr(-, root, root)
-+
-+%{_libdir}/gaim/mono.so
-+%{_libdir}/gaim/*.dll
-+%endif
-+
-+%files devel
-+%defattr(-, root, root)
-+
-+%doc plugins/HOWTO
-+%doc HACKING PROGRAMMING_NOTES
-+
-+%dir %{_includedir}/gaim
-+%{_includedir}/gaim/*.h
-+%{_libdir}/pkgconfig/gaim.pc
-+%{_datadir}/aclocal/gaim.m4
-+%if 0%{?_with_dbus:1}
-+%{_libdir}/libgaim-client.so
-+%endif
-+
-+%changelog
-+* Sat Dec 17 2005 <stu@nosnilmot.com>
-+- Add support for beta versions so the subsequent releases are seen as newer
-+ by RPM
-+- Split of sametime support to gaim-meanwhile
-+- Use make DESTDIR=... instead of overloading prefix etc. when installing
-+- Default build to include cyrus-sasl support in Jabber
-+- Add --with dbus to build with DBUS support
-+
-+* Sun Dec 04 2005 <siege@preoccupied.net>
-+- Added obsoletes gaim-meanwhile
-+
-+* Sun Oct 30 2005 <stu@nosnilmot.com>
-+- Add separate gaim-bonjour package if built with --with-howl
-+- Add separate gaim-mono package if built with --with-mono
-+- Exclude some unwanted perl files
-+
-+* Sat Aug 20 2005 <stu@nosnilmot.com>
-+- Include libgaimperl.so
-+- Include gaim.m4 in gaim-devel
-+
-+* Thu Apr 28 2005 <stu@nosnilmot.com>
-+- Use perl_vendorlib & perl_archlib for better 64bit compat (Jeff Mahoney)
-+- Clean up Requires, most should be auto-detected
-+- Restore gtkspell-devel build requirement (and add --without gtkspell option)
-+- Fix Tcl build requirements to work across more distros
-+- Fix SILC build requirements to work across more distros
-+
-+* Mon Oct 11 2004 John Jolly <john.jolly@gmail.com>
-+- Added if "%{_vendor}" == "suse" to handle GnuTLS libraries for SuSE
-+
-+* Sat Oct 2 2004 Stu Tomlinson <stu@nosnilmot.com>
-+- If --with tcl or silc are not specified, make sure the plugins don't
-+ exist to prevent RPM complaining about unpackaged files
-+
-+* Tue Jun 29 2004 Ethan Blanton <eblanton@cs.ohiou.edu>
-+- Change Tcl to use --with tcl, the same as SILC, and build a gaim-tcl
-+ package if specified.
-+
-+* Thu Jun 24 2004 Mark Doliner <thekingant@users.sourceforge.net>
-+- Add --with silc rebuild option for compiling a separate gaim-silc
-+ RPM containing the silc protocol plugin (Stu Tomlinson).
-+
-+* Wed Jun 23 2004 Ethan Blanton <eblanton@cs.ohiou.edu>
-+- Moved gaim headers and a pkgconfig configuration file into the
-+ gaim-devel RPM (Stu Tomlinson).
-+
-+* Thu Jan 15 2004 Ethan Blanton <eblanton@cs.ohiou.edu>
-+- Removed the manual strip command, as it seems to be unwarranted if
-+ the necessary programs are properly installed. (For me, this was
-+ elfutils.)
-+
-+* Sun Jul 20 2003 Bjoern Voigt <bjoern@cs.tu-berlin.de>
-+- Added pkgconfig build dependency.
-+- if "%{_vendor}" != "MandrakeSoft" now also works with rpm 3.x.
-+- Added Gaim-specific directories to list of Gaim's files.
-+
-+* Wed Jul 16 2003 Ethan Blanton <eblanton@cs.ohiou.edu>
-+- Complete spec file rewrite to take advantage of "new" RPM features
-+ and make things prettier.
-+- Use system-supplied %%{_prefix}, %%{_datadir}, etc. rather than
-+ attempt to define our own.
-diff -prNu ./gaim.apspec.in ./gaim.apspec.in
---- ./gaim.apspec.in 2005-09-01 05:32:52.000000000 +0200
-+++ ./gaim.apspec.in 1970-01-01 01:00:00.000000000 +0100
-@@ -1,66 +0,0 @@
--# -*-shell-script-*-
--
--[Meta]
--RootName: @gaim.sourceforge.net/gaim:$SOFTWAREVERSION
--DisplayName: Gaim Internet Messenger
--ShortName: gaim
--Maintainer: The Gaim Developers
--URL: http://gaim.sourceforge.net/
--Packager: Tim Ringenbach <marv_sf@users.sourceforge.net>
--Summary: A GTK+ based multiprotocol instant messaging client
--SoftwareVersion: @VERSION@
--InterfaceVersion: 2.0
--PackageVersion: 1
--
--[Description]
--Gaim allows you to talk to anyone using a variety of messaging protocols,
--including AIM (Oscar and TOC), ICQ, IRC, Yahoo!, MSN Messenger, Jabber,
--Gadu-Gadu, Napster, and Zephyr. These protocols are implemented using a
--modular, easy to use design. To use a protocol, just add an account using the
--account editor.
--
--Gaim supports many common features of other clients, as well as many unique
--features, such as perl scripting, TCL scripting and C plugins.
--
--Gaim is NOT affiliated with or endorsed by America Online, Inc., Microsoft
--Corporation, Yahoo! Inc., or ICQ Inc.
--
--[BuildPrepare]
--prepareBuild --enable-nss --enable-gnutls --enable-binreloc --disable-perl --disable-tcl --disable-gtktest
--
--[BuildUnprepare]
--unprepareBuild
--
--[Imports]
--rm -rf include
--rm -rf lib/pkgconfig
--find -name '*.la' | xargs rm
--echo '*' | import
--
--[Prepare]
--# Dependency checking
--require @gtk.org/gtk 2.2
--require @68k.org/libaudiofile 0.0
--require @xiph.org/libao 2.0
--require @gtkspell.sourceforge.net/gtkspell 0.0
--require @gnutls.org/gnutls 11.0 || { require @mozilla.org/nspr 4 && require @mozilla.org/nss 3; }
--
--[Install]
--# Put your installation script here
--installExe ./bin/*
--# do the plugins
--copyFiles ./lib/gaim "$PREFIX/lib"
--installMan 1 ./man/man1/gaim.1
--installDesktop "Networking/Instant Messaging" ./share/applications/gaim.desktop
--installLocale ./share/locale
--copyFiles ./share/pixmaps "$PREFIX/share"
--copyFiles ./share/sounds "$PREFIX/share"
--installIcon ./share/pixmaps/gaim.png
--# install and fix the .pc file
--# move this to the -devel package when I make one
--# copyFile ./lib/pkgconfig/gaim.pc "$PREFIX/lib/pkgconfig/gaim.pc"
--# safeSed "$PREFIX/lib/pkgconfig/gaim.pc" "s|prefix=/usr/local|prefix=$PREFIX|"
--
--[Uninstall]
--# Usually just the following line is enough to uninstall everything
--uninstallFromLog
-diff -prNu ./gaim.desktop ./gaim.desktop
---- ./gaim.desktop 2005-10-30 18:23:15.000000000 +0100
-+++ ./gaim.desktop 1970-01-01 01:00:00.000000000 +0100
-@@ -1,80 +0,0 @@
--[Desktop Entry]
--Encoding=UTF-8
--Categories=Application;Network;
--Exec=gaim
--Icon=gaim.png
--StartupNotify=true
--Terminal=false
--Type=Application
--
--Name=Gaim Internet Messenger
--Name[ca]=Missatger d'Internet Gaim
--Name[cs]=Gaim Internet Messenger
--Name[da]=Gaim - internet beskeder
--Name[de]=Gaim Internet Messenger
--Name[es]=Gaim - cliente de mensajería de Internet
--Name[fr]=Gaim Messagerie Internet
--Name[hu]=Gaim azonnali üzenetküldő
--Name[it]=Gaim Internet Messenger
--Name[ja]=Gaim インターãƒãƒƒãƒˆãƒ»ãƒ¡ãƒƒã‚»ãƒ³ã‚¸ãƒ£ãƒ¼
--Name[ko]=게임 메신저
--Name[nb]=Gaim lynmeldingsklient
--Name[nl]=Gaim - Expresberichten
--Name[pl]=Komunikator Internetowy Gaim
--Name[pt_BR]=Mensageiro via Internet Gaim
--Name[pt]=Mensageiro Internet Gaim
--Name[ro]=Mesagerul Gaim
--Name[ru]=Gaim - клиент обмена мгновенными ÑообщениÑми
--Name[sl]=Gaim - spletni sel
--Name[sq]=Lajmësjellësi Internet Gaim
--Name[sv]=Gaim Internet Messenger
--Name[zh_CN]=Gaim 互è”网通讯程åº
--Name[zh_TW]=Gaim 網路å³æ™‚通
--
--GenericName=Internet Messenger
--GenericName[ca]=Missatger d'Internet
--GenericName[cs]=Internet Messenger
--GenericName[da]=Internet beskeder
--GenericName[de]=Internet Messenger
--GenericName[es]=Cliente de mensajería de Internet
--GenericName[fr]=Messagerie internet
--GenericName[hu]=Azonnali üzenetküldő
--GenericName[it]=Internet Messenger
--GenericName[ja]=インターãƒãƒƒãƒˆãƒ»ãƒ¡ãƒƒã‚»ãƒ³ã‚¸ãƒ£ãƒ¼
--GenericName[ko]=메신저
--GenericName[nb]=Lynmeldingsklient
--GenericName[nl]=Expresberichten
--GenericName[pl]=Komunikator Internetowy
--GenericName[pt_BR]=Mensageiro via Internet
--GenericName[pt]=Mensageiro Internet
--GenericName[ro]=Client de mesagerie
--GenericName[ru]=Клиент обмена мгновенными ÑообщениÑми
--GenericName[sl]=Spletni sel
--GenericName[sq]=Lajmësjellës Internet
--GenericName[sv]=Meddelandeklient
--GenericName[zh_CN]=互è”网通讯程åº
--GenericName[zh_TW]=網路å³æ™‚通
--
--Comment=Send instant messages over multiple protocols
--Comment[ca]=Envieu missatges instantanis en múltiples protocols
--Comment[cs]=Posílat instant message různými protokoly
--Comment[da]=Send beskeder over flere protokoller
--Comment[de]=Multi-Protokoll Instant Messenger Client
--Comment[es]=Cliente de mensajería instantánea multiprotocolo
--Comment[fr]=Envoie des messages instantanés en utilisant divers protocoles
--Comment[hu]=Azonnali üzenetküldés többféle protokoll használatával
--Comment[it]=Client multiprotocollo per messaggi immediati
--Comment[ja]=複数ã®ãƒ—ロトコルを介ã—ã¦ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ãƒˆãƒ»ãƒ¡ãƒƒã‚»ãƒ¼ã‚¸ã‚’é€ä¿¡ã—ã¾ã™
--Comment[ko]=다중 프로토콜 메신저
--Comment[nb]=Send lynmeldinger over flere protokoller
--Comment[nl]=Multi-protocol programma voor expresberichten
--Comment[pl]=Komunikator internetowy obsługujący kilka protokołów
--Comment[pt_BR]=Mande mensagens instantâneas por múltiplos protocolos
--Comment[pt]=Envie mensagens instantâneas sobre vários protocolos
--Comment[ro]=Trimiteţi mesaje instant în orice reţea
--Comment[ru]=Обмен мгновенными ÑообщениÑми Ñ Ð¸Ñпользованием множеÑтва протоколов
--Comment[sl]=PoÅ¡iljajte neposredna sporoÄila prek razliÄnih protokolovs
--Comment[sq]=Dërgoni mesazhe të atypëratyshëm protokollesh të ndryshëm
--Comment[sv]=Sänder snabbmeddelande över många protokoll
--Comment[zh_CN]=通过多ç§åè®®å‘é€å³æ—¶æ¶ˆæ¯
--Comment[zh_TW]=é€éŽå¤šç¨®é€šè¨Šå”定發é€å³æ™‚訊æ¯
-diff -prNu ./gaim.pc.in ./gaim.pc.in
---- ./gaim.pc.in 2005-05-27 15:58:42.000000000 +0200
-+++ ./gaim.pc.in 1970-01-01 01:00:00.000000000 +0100
-@@ -1,13 +0,0 @@
--prefix=@prefix@
--exec_prefix=@exec_prefix@
--libdir=@libdir@
--includedir=@includedir@
--datadir=@datadir@
--sysconfdir=@sysconfdir@
--
--Name: Gaim
--Description: Gaim is a GTK2-based instant messenger application.
--Version: @VERSION@
--Requires: glib-2.0
--Cflags: -I${includedir}/gaim
--
-diff -prNu ./gaim.spec.in ./gaim.spec.in
---- ./gaim.spec.in 2005-12-18 20:03:05.000000000 +0100
-+++ ./gaim.spec.in 1970-01-01 01:00:00.000000000 +0100
-@@ -1,345 +0,0 @@
--# Older RPM doesn't define these by default
--%{!?perl_vendorlib: %define perl_vendorlib %(eval "`%{__perl} -V:installvendorlib`"; echo $installvendorlib)}
--%{!?perl_vendorarch: %define perl_vendorarch %(eval "`%{__perl} -V:installvendorarch`"; echo $installvendorarch)}
--%{!?perl_archlib: %define perl_archlib %(eval "`%{__perl} -V:installarchlib`"; echo $installarchlib)}
--
--# When not doing betas set this to 0
--%define beta 1
--
--%if 0%{beta}
--%define gaimver %(echo "@VERSION@"|sed -e 's/cvs//; s/beta.*//')
--%else
--%define gaimver @VERSION@
--%endif
--
--Summary: A Gtk+ based multiprotocol instant messaging client
--Name: @PACKAGE@
--Version: %gaimver
--Release: 0%{?beta:.beta%{beta}}
--Epoch: 1
--License: GPL
--Group: Applications/Internet
--URL: http://gaim.sourceforge.net/
--Packager: %{packager}
--Source: %{name}-@VERSION@.tar.gz
--BuildRoot: %{_tmppath}/%{name}-%{version}-root
--
--# Generic build requirements
--BuildRequires: libtool, pkgconfig, libao-devel, audiofile-devel
--%{?_with_howl:BuildRequires: howl-devel}
--%{?_with_silc:BuildRequires: /usr/include/silc/silcclient.h}
--%{?_with_meanwhile:BuildRequires: meanwhile-devel}
--%{?_with_tcl:BuildRequires: tcl, tk, /usr/include/tcl.h}
--%{?_with_mono:BuildRequires: mono-devel}
--%{?_with_dbus:BuildRequires: dbus-devel >= 0.35}
--%{!?_without_gtkspell:BuildRequires: gtkspell-devel}
--%{?_with_sasl:BuildRequires: cyrus-sasl-devel >= 2}
--# For some reason perl isn't always automatically detected as a requirement :(
--Requires: perl
--
--# Mandrake 10.1 and lower || Mandrake 10.2 (and higher?)
--%if "%{_vendor}" == "MandrakeSoft" || "%{_vendor}" == "Mandrakesoft" || "%{_vendor}" == "Mandriva"
--# Mandrake/Mandriva requirements
--BuildRequires: libgtk+2.0_0-devel, libnss3-devel, perl-devel
--Obsoletes: libgaim-remote0
--%else
--
--# SuSE & Red Hat / Fedora requirements
--BuildRequires: gtk2-devel
--
--%if "%{_vendor}" == "suse"
--BuildRequires: gnutls-devel
--%else
--BuildRequires: mozilla-nss-devel
--%endif
--%endif
--
--%if 0%{?_with_howl:1}
--%package bonjour
--Summary: Bonjour plugin for Gaim
--Group: Applications/Internet
--Requires: gaim = %{epoch}:%{version}
--%endif
--
--%if 0%{?_with_silc:1}
--%package silc
--Summary: SILC (Secure Internet Live Conferencing) plugin for Gaim
--Group: Applications/Internet
--Requires: gaim = %{epoch}:%{version}
--%endif
--
--%if 0%{?_with_meanwhile:1}
--%package meanwhile
--Summary: Lotus Sametime plugin for Gaim using the Meanwhile library
--Group: Applications/Internet
--Requires: gaim = %{epoch}:%{version}
--%endif
--
--%if 0%{?_with_tcl:1}
--%package tcl
--Summary: Tcl scripting support for Gaim
--Group: Applications/Internet
--Requires: gaim = %{epoch}:%{version}
--%endif
--
--%if 0%{?_with_mono:1}
--%package mono
--Summary: Mono .NET plugin support for Gaim
--Group: Applications/Internet
--Requires: gaim = %{epoch}:%{version}
--%endif
--
--%package devel
--Summary: Development headers, documentation, and libraries for Gaim.
--Group: Applications/Internet
--Requires: pkgconfig, gaim = %{epoch}:%{version}
--
--%description
--Gaim allows you to talk to anyone using a variety of messaging
--protocols, including AIM, ICQ, IRC, Yahoo!, Novell Groupwise, MSN
--Messenger, Jabber, Gadu-Gadu, Napster, Lotus Sametime and Zephyr.
--These protocols are implemented using a modular, easy to use design.
--To use a protocol, just add an account using the account editor.
--
--Gaim supports many common features of other clients, as well as many
--unique features, such as perl scripting, TCL scripting and C plugins.
--
--Gaim is NOT affiliated with or endorsed by America Online, Inc.,
--Microsoft Corporation, Yahoo! Inc., or ICQ Inc.
--
--%if 0%{?_with_howl:1}
--%description bonjour
--Bonjour plugin for Gaim
--%endif
--
--%if 0%{?_with_silc:1}
--%description silc
--SILC (Secure Internet Live Conferencing) plugin for Gaim
--%endif
--
--%if 0%{?_with_meanwhile:1}
--%description meanwhile
--Lotus Sametime plugin for Gaim using the Meanwhile library
--%endif
--
--%if 0%{?_with_tcl:1}
--%description tcl
--Tcl plugin loader for Gaim. This package will allow you to write or
--use Gaim plugins written in the Tcl programming language.
--%endif
--
--%if 0%{?_with_mono:1}
--%description mono
--Mono plugin loader for Gaim. This package will allow you to write or
--use Gaim plugins written in the .NET programming language.
--%endif
--
--%description devel
--The gaim-devel package contains the header files, developer
--documentation, and libraries required for development of gaim scripts
--and plugins.
--
--%prep
--%setup -q -n %{name}-@VERSION@
--
--%build
--CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{_prefix} \
-- --bindir=%{_bindir} \
-- --datadir=%{_datadir} \
-- --includedir=%{_includedir} \
-- --libdir=%{_libdir} \
-- --mandir=%{_mandir} \
-- --sysconfdir=%{_sysconfdir} \
-- --with-ao=%{_libdir} \
-- --with-perl-lib=%{_prefix} \
-- %{?_with_silc:--with-silc-includes=%{_includedir}/silc} \
-- %{?_with_silc:--with-silc-libs=%{_libdir}/silc} \
-- %{?_with_mono:--enable-mono} \
-- %{!?_with_tcl:--disable-tcl} \
-- %{!?_with_dbus:--disable-dbus} \
-- %{?_without_gtkspell:--disable-gtkspell} \
-- %{?_with_sasl:--enable-cyrus-sasl}
--
--make %{?_smp_mflags}
--
--%install
--rm -rf %{buildroot}
--make DESTDIR=$RPM_BUILD_ROOT install
--
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/*.la
--rm -f $RPM_BUILD_ROOT%{_libdir}/*.la
--rm -f $RPM_BUILD_ROOT%{perl_archlib}/perllocal.pod
--find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'
--find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -exec rm -f {} ';'
--
--%if 0%{!?_with_howl:1}
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/libbonjour.so
--%endif
--
--%if 0%{!?_with_silc:1}
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/libsilcgaim.so
--%endif
--
--%if 0%{!?_with_meanwhile:1}
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/libsametime.so
--%endif
--
--%if 0%{!?_with_tcl:1}
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/tcl.so
--%endif
--
--%if 0%{!?_with_mono:1}
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/mono.so
--rm -f $RPM_BUILD_ROOT%{_libdir}/gaim/*.dll
--%endif
--
--
--find $RPM_BUILD_ROOT%{_libdir}/gaim -type f -print | \
-- sed "s@^$RPM_BUILD_ROOT@@g" | \
-- grep -v libbonjour.so | \
-- grep -v libsilcgaim.so | \
-- grep -v libsametime.so | \
-- grep -v tcl.so | \
-- grep -v mono.so | \
-- grep -v ".dll$" | \
-- grep -v ".tcl$" > %{name}-%{version}-coreplugins
--
--%clean
--rm -rf %{buildroot}
--
--%files -f %{name}-%{version}-coreplugins
--%defattr(-, root, root)
--
--%doc doc/the_penguin.txt doc/CREDITS NEWS COPYING AUTHORS COPYRIGHT
--%doc README ChangeLog
--%doc %{_mandir}/man1/*
--%doc %{_mandir}/man3*/*
--
--%dir %{_libdir}/gaim
--%attr(755, root, root) %{perl_vendorarch}/Gaim*
--%attr(755, root, root) %{perl_vendorarch}/auto/Gaim
--
--%{_bindir}/*
--%{_datadir}/locale/*/*/*
--%{_datadir}/pixmaps/*
--%dir %{_datadir}/sounds/gaim
--%{_datadir}/sounds/gaim/*
--%{_datadir}/applications/*
--
--%if 0%{?_with_dbus:1}
--%{_libdir}/libgaim-client.so.*
--%{_datadir}/dbus-1/services/gaim.service
--%endif
--
--%if 0%{?_with_howl:1}
--%files bonjour
--%defattr(-, root, root)
--
--%{_libdir}/gaim/libbonjour.*
--%endif
--
--%if 0%{?_with_silc:1}
--%files silc
--%defattr(-, root, root)
--
--%{_libdir}/gaim/libsilcgaim.*
--%endif
--
--%if 0%{?_with_meanwhile:1}
--%files meanwhile
--%defattr(-, root, root)
--
--%{_libdir}/gaim/libsametime.*
--%endif
--
--%if 0%{?_with_tcl:1}
--%files tcl
--%defattr(-, root, root)
--
--%{_libdir}/gaim/tcl.so
--%endif
--
--%if 0%{?_with_mono:1}
--%files mono
--%defattr(-, root, root)
--
--%{_libdir}/gaim/mono.so
--%{_libdir}/gaim/*.dll
--%endif
--
--%files devel
--%defattr(-, root, root)
--
--%doc plugins/HOWTO
--%doc HACKING PROGRAMMING_NOTES
--
--%dir %{_includedir}/gaim
--%{_includedir}/gaim/*.h
--%{_libdir}/pkgconfig/gaim.pc
--%{_datadir}/aclocal/gaim.m4
--%if 0%{?_with_dbus:1}
--%{_libdir}/libgaim-client.so
--%endif
--
--%changelog
--* Sat Dec 17 2005 <stu@nosnilmot.com>
--- Add support for beta versions so the subsequent releases are seen as newer
-- by RPM
--- Split of sametime support to gaim-meanwhile
--- Use make DESTDIR=... instead of overloading prefix etc. when installing
--- Default build to include cyrus-sasl support in Jabber
--- Add --with dbus to build with DBUS support
--
--* Sun Dec 04 2005 <siege@preoccupied.net>
--- Added obsoletes gaim-meanwhile
--
--* Sun Oct 30 2005 <stu@nosnilmot.com>
--- Add separate gaim-bonjour package if built with --with-howl
--- Add separate gaim-mono package if built with --with-mono
--- Exclude some unwanted perl files
--
--* Sat Aug 20 2005 <stu@nosnilmot.com>
--- Include libgaimperl.so
--- Include gaim.m4 in gaim-devel
--
--* Thu Apr 28 2005 <stu@nosnilmot.com>
--- Use perl_vendorlib & perl_archlib for better 64bit compat (Jeff Mahoney)
--- Clean up Requires, most should be auto-detected
--- Restore gtkspell-devel build requirement (and add --without gtkspell option)
--- Fix Tcl build requirements to work across more distros
--- Fix SILC build requirements to work across more distros
--
--* Mon Oct 11 2004 John Jolly <john.jolly@gmail.com>
--- Added if "%{_vendor}" == "suse" to handle GnuTLS libraries for SuSE
--
--* Sat Oct 2 2004 Stu Tomlinson <stu@nosnilmot.com>
--- If --with tcl or silc are not specified, make sure the plugins don't
-- exist to prevent RPM complaining about unpackaged files
--
--* Tue Jun 29 2004 Ethan Blanton <eblanton@cs.ohiou.edu>
--- Change Tcl to use --with tcl, the same as SILC, and build a gaim-tcl
-- package if specified.
--
--* Thu Jun 24 2004 Mark Doliner <thekingant@users.sourceforge.net>
--- Add --with silc rebuild option for compiling a separate gaim-silc
-- RPM containing the silc protocol plugin (Stu Tomlinson).
--
--* Wed Jun 23 2004 Ethan Blanton <eblanton@cs.ohiou.edu>
--- Moved gaim headers and a pkgconfig configuration file into the
-- gaim-devel RPM (Stu Tomlinson).
--
--* Thu Jan 15 2004 Ethan Blanton <eblanton@cs.ohiou.edu>
--- Removed the manual strip command, as it seems to be unwarranted if
-- the necessary programs are properly installed. (For me, this was
-- elfutils.)
--
--* Sun Jul 20 2003 Bjoern Voigt <bjoern@cs.tu-berlin.de>
--- Added pkgconfig build dependency.
--- if "%{_vendor}" != "MandrakeSoft" now also works with rpm 3.x.
--- Added Gaim-specific directories to list of Gaim's files.
--
--* Wed Jul 16 2003 Ethan Blanton <eblanton@cs.ohiou.edu>
--- Complete spec file rewrite to take advantage of "new" RPM features
-- and make things prettier.
--- Use system-supplied %%{_prefix}, %%{_datadir}, etc. rather than
-- attempt to define our own.
-diff -prNu ./m4macros/gaim2.m4 ./m4macros/gaim2.m4
---- ./m4macros/gaim2.m4 1970-01-01 01:00:00.000000000 +0100
-+++ ./m4macros/gaim2.m4 2006-01-05 13:44:03.000000000 +0100
-@@ -0,0 +1,102 @@
-+dnl ###########################################################################
-+dnl # Configure paths for Gaim
-+dnl # Gary Kramlich 2005
-+dnl #
-+dnl # Based off of glib-2.0.m4 by Owen Taylor
-+dnl ###########################################################################
-+
-+dnl ###########################################################################
-+dnl # AM_PATH_GAIM([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
-+dnl #
-+dnl # Test for gaim and define GAIM_CFLAGS, GAIM_LIBS, GAIM_DATADIR, and
-+dnl # GAIM_LIBDIR
-+dnl ###########################################################################
-+AC_DEFUN([AM_PATH_GAIM],
-+[dnl
-+ AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
-+
-+ no_gaim=""
-+
-+ if test x"$PKG_CONFIG" != x"no" ; then
-+ if $PKG_CONFIG --atleast-pkgconfig-version 0.7 ; then
-+ :
-+ else
-+ echo "*** pkg-config is too old; version 0.7 or newer is required."
-+ no_gaim="yes"
-+ PKG_CONFIG="no"
-+ fi
-+ else
-+ no_gaim="yes"
-+ fi
-+
-+ min_version=ifelse([$1], ,2.0.0,$1)
-+ found_version=""
-+
-+ AC_MSG_CHECKING(for gaim - version >= $min_version)
-+
-+ if test x"$no_gaim" = x"" ; then
-+ GAIM_DATADIR=`$PKG_CONFIG --variable=datadir gaim2`
-+ GAIM_LIBDIR=`$PKG_CONFIG --variable=libdir gaim2`
-+
-+ GAIM_CFLAGS=`$PKG_CONFIG --cflags gaim2`
-+ GAIM_LIBS=`$PKG_CONFIG --libs gaim2`
-+
-+ gaim_version=`$PKG_CONFIG --modversion gaim2`
-+ gaim_major_version=`echo $gaim_version | cut -d. -f 1`
-+ gaim_minor_version=`echo $gaim_version | cut -d. -f 2`
-+
-+ dnl # stash the micro version in a temp variable. Then stash
-+ dnl # the numeric for it in gaim_micro_version and anything
-+ dnl # else in gaim_extra_version.
-+ gaim_micro_version_temp=`echo $gaim_version | cut -d. -f 3`
-+ gaim_micro_version=`echo $gaim_micro_version_temp | sed 's/[[^0-9]]//g'`
-+ gaim_extra_version=`echo $gaim_micro_version_temp | sed 's/[[0-9]]//g'`
-+
-+ dnl # get the major, minor, and macro that the user gave us
-+ min_major_version=`echo $min_version | cut -d. -f 1`
-+ min_minor_version=`echo $min_version | cut -d. -f 2`
-+ min_micro_version=`echo $min_version | cut -d. -f 3`
-+
-+ dnl # check the users version against the version from pkg-config
-+ if test $gaim_major_version -eq $min_major_version -a \
-+ $gaim_minor_version -ge $min_minor_version -a \
-+ $gaim_micro_version -ge $min_micro_version
-+ then
-+ :
-+ else
-+ no_gaim="yes"
-+ found_version="$gaim_major_version.$gaim_minor_version.$gaim_micro_version$gaim_extra_version"
-+ fi
-+
-+ dnl # Do we want a compile test here?
-+ fi
-+
-+ if test x"$no_gaim" = x"" ; then
-+ AC_MSG_RESULT(yes (version $gaim_major_version.$gaim_minor_version.$gaim_micro_version$gaim_extra_version))
-+ ifelse([$2], , :, [$2])
-+ else
-+ AC_MSG_RESULT(no)
-+ if test x"$PKG_CONFIG" = x"no" ; then
-+ echo "*** A new enough version of pkg-config was not found."
-+ echo "*** See http://www.freedesktop.org/software/pkgconfig/"
-+ fi
-+
-+ if test x"found_version" != x"" ; then
-+ echo "*** A new enough version of gaim was not found."
-+ echo "*** You have version $found_version"
-+ echo "*** See http://gaim.sf.net/"
-+ fi
-+
-+ GAIM_CFLAGS=""
-+ GAIM_LIBS=""
-+ GAIM_DATADIR=""
-+ GAIM_LIBDIR=""
-+
-+ ifelse([$3], , :, [$3])
-+ fi
-+
-+ AC_SUBST(GAIM_CFLAGS)
-+ AC_SUBST(GAIM_LIBS)
-+ AC_SUBST(GAIM_DATADIR)
-+ AC_SUBST(GAIM_LIBDIR)
-+])
-diff -prNu ./m4macros/gaim.m4 ./m4macros/gaim.m4
---- ./m4macros/gaim.m4 2005-07-23 22:28:17.000000000 +0200
-+++ ./m4macros/gaim.m4 1970-01-01 01:00:00.000000000 +0100
-@@ -1,102 +0,0 @@
--dnl ###########################################################################
--dnl # Configure paths for Gaim
--dnl # Gary Kramlich 2005
--dnl #
--dnl # Based off of glib-2.0.m4 by Owen Taylor
--dnl ###########################################################################
--
--dnl ###########################################################################
--dnl # AM_PATH_GAIM([MINIMUM-VERSION, [ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]])
--dnl #
--dnl # Test for gaim and define GAIM_CFLAGS, GAIM_LIBS, GAIM_DATADIR, and
--dnl # GAIM_LIBDIR
--dnl ###########################################################################
--AC_DEFUN([AM_PATH_GAIM],
--[dnl
-- AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
--
-- no_gaim=""
--
-- if test x"$PKG_CONFIG" != x"no" ; then
-- if $PKG_CONFIG --atleast-pkgconfig-version 0.7 ; then
-- :
-- else
-- echo "*** pkg-config is too old; version 0.7 or newer is required."
-- no_gaim="yes"
-- PKG_CONFIG="no"
-- fi
-- else
-- no_gaim="yes"
-- fi
--
-- min_version=ifelse([$1], ,2.0.0,$1)
-- found_version=""
--
-- AC_MSG_CHECKING(for gaim - version >= $min_version)
--
-- if test x"$no_gaim" = x"" ; then
-- GAIM_DATADIR=`$PKG_CONFIG --variable=datadir gaim`
-- GAIM_LIBDIR=`$PKG_CONFIG --variable=libdir gaim`
--
-- GAIM_CFLAGS=`$PKG_CONFIG --cflags gaim`
-- GAIM_LIBS=`$PKG_CONFIG --libs gaim`
--
-- gaim_version=`$PKG_CONFIG --modversion gaim`
-- gaim_major_version=`echo $gaim_version | cut -d. -f 1`
-- gaim_minor_version=`echo $gaim_version | cut -d. -f 2`
--
-- dnl # stash the micro version in a temp variable. Then stash
-- dnl # the numeric for it in gaim_micro_version and anything
-- dnl # else in gaim_extra_version.
-- gaim_micro_version_temp=`echo $gaim_version | cut -d. -f 3`
-- gaim_micro_version=`echo $gaim_micro_version_temp | sed 's/[[^0-9]]//g'`
-- gaim_extra_version=`echo $gaim_micro_version_temp | sed 's/[[0-9]]//g'`
--
-- dnl # get the major, minor, and macro that the user gave us
-- min_major_version=`echo $min_version | cut -d. -f 1`
-- min_minor_version=`echo $min_version | cut -d. -f 2`
-- min_micro_version=`echo $min_version | cut -d. -f 3`
--
-- dnl # check the users version against the version from pkg-config
-- if test $gaim_major_version -eq $min_major_version -a \
-- $gaim_minor_version -ge $min_minor_version -a \
-- $gaim_micro_version -ge $min_micro_version
-- then
-- :
-- else
-- no_gaim="yes"
-- found_version="$gaim_major_version.$gaim_minor_version.$gaim_micro_version$gaim_extra_version"
-- fi
--
-- dnl # Do we want a compile test here?
-- fi
--
-- if test x"$no_gaim" = x"" ; then
-- AC_MSG_RESULT(yes (version $gaim_major_version.$gaim_minor_version.$gaim_micro_version$gaim_extra_version))
-- ifelse([$2], , :, [$2])
-- else
-- AC_MSG_RESULT(no)
-- if test x"$PKG_CONFIG" = x"no" ; then
-- echo "*** A new enough version of pkg-config was not found."
-- echo "*** See http://www.freedesktop.org/software/pkgconfig/"
-- fi
--
-- if test x"found_version" != x"" ; then
-- echo "*** A new enough version of gaim was not found."
-- echo "*** You have version $found_version"
-- echo "*** See http://gaim.sf.net/"
-- fi
--
-- GAIM_CFLAGS=""
-- GAIM_LIBS=""
-- GAIM_DATADIR=""
-- GAIM_LIBDIR=""
--
-- ifelse([$3], , :, [$3])
-- fi
--
-- AC_SUBST(GAIM_CFLAGS)
-- AC_SUBST(GAIM_LIBS)
-- AC_SUBST(GAIM_DATADIR)
-- AC_SUBST(GAIM_LIBDIR)
--])
-diff -prNu ./m4macros/Makefile.am ./m4macros/Makefile.am
---- ./m4macros/Makefile.am 2005-08-20 22:17:06.000000000 +0200
-+++ ./m4macros/Makefile.am 2006-01-05 13:24:11.000000000 +0100
-@@ -1,4 +1,4 @@
--installed_m4=gaim.m4
-+installed_m4=gaim2.m4
-
- EXTRA_DIST=$(installed_m4)
-
-diff -prNu ./Makefile.am ./Makefile.am
---- ./Makefile.am 2005-12-03 04:55:04.000000000 +0100
-+++ ./Makefile.am 2006-01-05 14:02:55.000000000 +0100
-@@ -1,10 +1,10 @@
- EXTRA_DIST = \
- COPYRIGHT \
- Doxyfile.in \
-- gaim.pc.in \
-- gaim.spec.in \
-- gaim.apspec.in \
-- gaim.desktop \
-+ gaim2.pc.in \
-+ gaim2.spec.in \
-+ gaim2.apspec.in \
-+ gaim2.desktop \
- gaim-installer.nsi \
- HACKING \
- PROGRAMMING_NOTES \
-@@ -23,20 +23,20 @@ EXTRA_DIST = \
- plugins/win32/winprefs/winprefs.c \
- po/Makefile.mingw
-
--gaimincludedir=$(includedir)/gaim
--gaiminclude_HEADERS = config.h
-+gaim2includedir=$(includedir)/gaim2
-+gaim2include_HEADERS = config.h
-
- pkgconfigdir = $(libdir)/pkgconfig
--pkgconfig_DATA = gaim.pc
-+pkgconfig_DATA = gaim2.pc
-
--dist-hook: gaim.spec
-- cp gaim.spec $(distdir)
-+dist-hook: gaim2.spec
-+ cp gaim2.spec $(distdir)
-
- distcheck-hook: plugins/perl/common/Gaim.pm
- # cp plugins/perl/common/Gaim.pm $(distdir)/plugins/perl/common
-
- appsdir = $(datadir)/applications
--apps_DATA = gaim.desktop
-+apps_DATA = gaim2.desktop
-
- SUBDIRS = doc intl m4macros pixmaps plugins po sounds src
-
-@@ -53,7 +53,7 @@ endif
- # breaks "make distcheck" unless we ignore perl things
-
- distuninstallcheck_listfiles = \
-- find . -type f -print | grep -v perl | grep -v Gaim.3pm
-+ find . -type f -print | grep -v perl | grep -v Gaim2.3pm
-
- ACLOCAL_AMFLAGS = -I m4
-
-Les fichiers ./pixmaps/gaim2.png et ./pixmaps/gaim2.png sont différents.
-Les fichiers ./pixmaps/gaim.png et ./pixmaps/gaim.png sont différents.
-diff -prNu ./pixmaps/Makefile.am ./pixmaps/Makefile.am
---- ./pixmaps/Makefile.am 2005-12-17 23:31:22.000000000 +0100
-+++ ./pixmaps/Makefile.am 2006-01-05 13:22:27.000000000 +0100
-@@ -8,7 +8,7 @@ EXTRA_DIST = \
- change-fgcolor-small.png \
- connect.png \
- edit.png \
-- gaim.png \
-+ gaim2.png \
- gaim_auth.png \
- gaim_cool.png \
- gaim_error.png \
-@@ -71,18 +71,18 @@ EXTRA_DIST = \
- gaim_offline_4bit_16.ico
-
-
--gaimbuttonpixdir = $(datadir)/pixmaps/gaim/buttons
-+gaimbuttonpixdir = $(datadir)/pixmaps/gaim2/buttons
- gaimbuttonpix_DATA = about_menu.png accounts.png change-bgcolor-small.png change-fgcolor-small.png edit.png info.png insert-image-small.png insert-link-small.png insert-smiley-small.png pause.png text_bigger.png text_normal.png text_smaller.png send-im.png
-
--gaimdialogpixdir = $(datadir)/pixmaps/gaim/dialogs
-+gaimdialogpixdir = $(datadir)/pixmaps/gaim2/dialogs
- gaimdialogpix_DATA = gaim_error.png gaim_info.png gaim_question.png gaim_warning.png gaim_cool.png gaim_auth.png
-
--gaimiconpixdir = $(datadir)/pixmaps/gaim/icons
-+gaimiconpixdir = $(datadir)/pixmaps/gaim2/icons
- gaimiconpix_DATA = away.png connect.png msgpend.png offline.png online.png msgunread.png stock_connect_16.png stock_disconnect_16.png
-
--gaimdistpixdir = $(datadir)/pixmaps/gaim
-+gaimdistpixdir = $(datadir)/pixmaps/gaim2
- gaimdistpix_DATA = logo.png tb_drag_arrow_down.xpm tb_drag_arrow_left.xpm tb_drag_arrow_right.xpm tb_drag_arrow_up.xpm typed.png typing.png status-online.png status-offline.png status-away.png status-invisible.png status-typing0.png status-typing1.png status-typing2.png status-typing3.png status-connect0.png status-connect1.png status-connect2.png status-connect3.png phone.png
-
- distpixmapdir = $(datadir)/pixmaps
--distpixmap_DATA = gaim.png
-+distpixmap_DATA = gaim2.png
-
-diff -prNu ./pixmaps/smileys/default/Makefile.am ./pixmaps/smileys/default/Makefile.am
---- ./pixmaps/smileys/default/Makefile.am 2004-05-27 09:06:05.000000000 +0200
-+++ ./pixmaps/smileys/default/Makefile.am 2006-01-05 13:11:38.000000000 +0100
-@@ -190,7 +190,7 @@ YAHOO_SMILEYS = \
- yahoo_star.gif
-
-
--gaimsmileypixdir = $(datadir)/pixmaps/gaim/smileys/default
-+gaimsmileypixdir = $(datadir)/pixmaps/gaim2/smileys/default
- gaimsmileypix_DATA = \
- $(AIM_SMILEYS) \
- $(MSN_SMILEYS) \
-diff -prNu ./pixmaps/smileys/none/Makefile.am ./pixmaps/smileys/none/Makefile.am
---- ./pixmaps/smileys/none/Makefile.am 2004-04-28 03:45:06.000000000 +0200
-+++ ./pixmaps/smileys/none/Makefile.am 2006-01-05 13:11:51.000000000 +0100
-@@ -1,4 +1,4 @@
--gaimsmileypixdir = $(datadir)/pixmaps/gaim/smileys/none
-+gaimsmileypixdir = $(datadir)/pixmaps/gaim2/smileys/none
- gaimsmileypix_DATA = theme
-
- EXTRA_DIST = $(gaimsmileypix_DATA)
-diff -prNu ./pixmaps/status/default/Makefile.am ./pixmaps/status/default/Makefile.am
---- ./pixmaps/status/default/Makefile.am 2005-12-21 09:24:15.000000000 +0100
-+++ ./pixmaps/status/default/Makefile.am 2006-01-05 13:12:26.000000000 +0100
-@@ -42,6 +42,6 @@ EXTRA_DIST = \
- yahoo.png \
- zephyr.png
-
--gaimstatuspixdir = $(datadir)/pixmaps/gaim/status/default
-+gaimstatuspixdir = $(datadir)/pixmaps/gaim2/status/default
-
- gaimstatuspix_DATA = $(EXTRA_DIST)
-diff -prNu ./plugins/ciphertest.c ./plugins/ciphertest.c
---- ./plugins/ciphertest.c 2005-12-12 07:53:27.000000000 +0100
-+++ ./plugins/ciphertest.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * A plugin to test the ciphers that ship with gaim
-+ * A plugin to test the ciphers that ship with gaim2
- *
- * Copyright (C) 2004, Gary Kramlich <amc_grim@users.sf.net>
- *
-@@ -62,48 +62,48 @@ struct test md5_tests[8] = {
-
- static void
- cipher_test_md5() {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- gchar digest[33];
- gboolean ret;
- gint i = 0;
-
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
- if(!cipher) {
-- gaim_debug_info("cipher-test",
-+ gaim2_debug_info("cipher-test",
- "could not find md5 cipher, not testing\n");
- return;
- }
-
-- gaim_debug_info("cipher-test", "Running md5 tests\n");
-+ gaim2_debug_info("cipher-test", "Running md5 tests\n");
-
-- context = gaim_cipher_context_new(cipher, NULL);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
- while(md5_tests[i].answer) {
-- gaim_debug_info("cipher-test", "Test %02d:\n", i);
-- gaim_debug_info("cipher-test", "Testing '%s'\n", md5_tests[i].question);
-+ gaim2_debug_info("cipher-test", "Test %02d:\n", i);
-+ gaim2_debug_info("cipher-test", "Testing '%s'\n", md5_tests[i].question);
-
-- gaim_cipher_context_append(context, (guchar *)md5_tests[i].question,
-+ gaim2_cipher_context_append(context, (guchar *)md5_tests[i].question,
- strlen(md5_tests[i].question));
-
-- ret = gaim_cipher_context_digest_to_str(context, sizeof(digest),
-+ ret = gaim2_cipher_context_digest_to_str(context, sizeof(digest),
- digest, NULL);
-
- if(!ret) {
-- gaim_debug_info("cipher-test", "failed\n");
-+ gaim2_debug_info("cipher-test", "failed\n");
- } else {
-- gaim_debug_info("cipher-test", "\tGot: %s\n", digest);
-- gaim_debug_info("cipher-test", "\tWanted: %s\n",
-+ gaim2_debug_info("cipher-test", "\tGot: %s\n", digest);
-+ gaim2_debug_info("cipher-test", "\tWanted: %s\n",
- md5_tests[i].answer);
- }
-
-- gaim_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
- i++;
- }
-
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_destroy(context);
-
-- gaim_debug_info("cipher-test", "md5 tests completed\n\n");
-+ gaim2_debug_info("cipher-test", "md5 tests completed\n\n");
- }
-
- /**************************************************************************
-@@ -119,31 +119,31 @@ struct test sha1_tests[5] = {
-
- static void
- cipher_test_sha1() {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- gchar digest[41];
- gint i = 0;
- gboolean ret;
-
-- cipher = gaim_ciphers_find_cipher("sha1");
-+ cipher = gaim2_ciphers_find_cipher("sha1");
- if(!cipher) {
-- gaim_debug_info("cipher-test",
-+ gaim2_debug_info("cipher-test",
- "could not find sha1 cipher, not testing\n");
- return;
- }
-
-- gaim_debug_info("cipher-test", "Running sha1 tests\n");
-+ gaim2_debug_info("cipher-test", "Running sha1 tests\n");
-
-- context = gaim_cipher_context_new(cipher, NULL);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
- while(sha1_tests[i].answer) {
-- gaim_debug_info("cipher-test", "Test %02d:\n", i);
-- gaim_debug_info("cipher-test", "Testing '%s'\n",
-+ gaim2_debug_info("cipher-test", "Test %02d:\n", i);
-+ gaim2_debug_info("cipher-test", "Testing '%s'\n",
- (sha1_tests[i].question != NULL) ?
- sha1_tests[i].question : "'a'x1000, 1000 times");
-
- if(sha1_tests[i].question) {
-- gaim_cipher_context_append(context, (guchar *)sha1_tests[i].question,
-+ gaim2_cipher_context_append(context, (guchar *)sha1_tests[i].question,
- strlen(sha1_tests[i].question));
- } else {
- gint j;
-@@ -152,27 +152,27 @@ cipher_test_sha1() {
- memset(buff, 'a', 1000);
-
- for(j = 0; j < 1000; j++)
-- gaim_cipher_context_append(context, buff, 1000);
-+ gaim2_cipher_context_append(context, buff, 1000);
- }
-
-- ret = gaim_cipher_context_digest_to_str(context, sizeof(digest),
-+ ret = gaim2_cipher_context_digest_to_str(context, sizeof(digest),
- digest, NULL);
-
- if(!ret) {
-- gaim_debug_info("cipher-test", "failed\n");
-+ gaim2_debug_info("cipher-test", "failed\n");
- } else {
-- gaim_debug_info("cipher-test", "\tGot: %s\n", digest);
-- gaim_debug_info("cipher-test", "\tWanted: %s\n",
-+ gaim2_debug_info("cipher-test", "\tGot: %s\n", digest);
-+ gaim2_debug_info("cipher-test", "\tWanted: %s\n",
- sha1_tests[i].answer);
- }
-
-- gaim_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
- i++;
- }
-
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_destroy(context);
-
-- gaim_debug_info("cipher-test", "sha1 tests completed\n\n");
-+ gaim2_debug_info("cipher-test", "sha1 tests completed\n\n");
- }
-
- static void
-@@ -192,25 +192,25 @@ cipher_test_digest()
-
- gchar *session_key;
-
-- gaim_debug_info("cipher-test", "Running HTTP Digest tests\n");
-+ gaim2_debug_info("cipher-test", "Running HTTP Digest tests\n");
-
-- session_key = gaim_cipher_http_digest_calculate_session_key(
-+ session_key = gaim2_cipher_http_digest_calculate_session_key(
- algorithm, username, realm, password,
- nonce, client_nonce);
-
- if (session_key == NULL)
- {
-- gaim_debug_info("cipher-test",
-- "gaim_cipher_http_digest_calculate_session_key failed.\n");
-+ gaim2_debug_info("cipher-test",
-+ "gaim2_cipher_http_digest_calculate_session_key failed.\n");
- }
- else
- {
- gchar *response;
-
-- gaim_debug_info("cipher-test", "\tsession_key: Got: %s\n", session_key);
-- gaim_debug_info("cipher-test", "\tsession_key: Wanted: %s\n", "939e7578ed9e3c518a452acee763bce9");
-+ gaim2_debug_info("cipher-test", "\tsession_key: Got: %s\n", session_key);
-+ gaim2_debug_info("cipher-test", "\tsession_key: Wanted: %s\n", "939e7578ed9e3c518a452acee763bce9");
-
-- response = gaim_cipher_http_digest_calculate_response(
-+ response = gaim2_cipher_http_digest_calculate_response(
- algorithm, method, digest_uri, qop, entity,
- nonce, nonce_count, client_nonce, session_key);
-
-@@ -218,25 +218,25 @@ cipher_test_digest()
-
- if (response == NULL)
- {
-- gaim_debug_info("cipher-test",
-- "gaim_cipher_http_digest_calculate_session_key failed.\n");
-+ gaim2_debug_info("cipher-test",
-+ "gaim2_cipher_http_digest_calculate_session_key failed.\n");
- }
- else
- {
-- gaim_debug_info("cipher-test", "\tresponse: Got: %s\n", response);
-- gaim_debug_info("cipher-test", "\tresponse: Wanted: %s\n", "6629fae49393a05397450978507c4ef1");
-+ gaim2_debug_info("cipher-test", "\tresponse: Got: %s\n", response);
-+ gaim2_debug_info("cipher-test", "\tresponse: Wanted: %s\n", "6629fae49393a05397450978507c4ef1");
- g_free(response);
- }
- }
-
-- gaim_debug_info("cipher-test", "HTTP Digest tests completed\n\n");
-+ gaim2_debug_info("cipher-test", "HTTP Digest tests completed\n\n");
- }
-
- /**************************************************************************
- * Plugin stuff
- **************************************************************************/
- static gboolean
--plugin_load(GaimPlugin *plugin) {
-+plugin_load(Gaim2Plugin *plugin) {
- cipher_test_md5();
- cipher_test_sha1();
- cipher_test_digest();
-@@ -245,11 +245,11 @@ plugin_load(GaimPlugin *plugin) {
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin) {
-+plugin_unload(Gaim2Plugin *plugin) {
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -264,9 +264,9 @@ static GaimPluginInfo info =
- N_("Cipher Test"), /**< name */
- VERSION, /**< version */
- /** summary */
-- N_("Tests the ciphers that ship with gaim."),
-+ N_("Tests the ciphers that ship with gaim2."),
- /** description */
-- N_("Tests the ciphers that ship with gaim."),
-+ N_("Tests the ciphers that ship with gaim2."),
- "Gary Kramlich <amc_grim@users.sf.net>", /**< author */
- GAIM_WEBSITE, /**< homepage */
-
-@@ -281,7 +281,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin) {
-+init_plugin(Gaim2Plugin *plugin) {
- }
-
- GAIM_INIT_PLUGIN(cipher_test, init_plugin, info)
-diff -prNu ./plugins/codeinline.c ./plugins/codeinline.c
---- ./plugins/codeinline.c 2005-11-12 21:19:39.000000000 +0100
-+++ ./plugins/codeinline.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,9 +28,9 @@
- #include "gtkutils.h"
- #include "gtkimhtml.h"
-
--GaimPlugin *plugin_handle = NULL;
-+Gaim2Plugin *plugin_handle = NULL;
-
--static gboolean outgoing_msg_cb(GaimAccount *account, GaimConversation *conv, char **message)
-+static gboolean outgoing_msg_cb(Gaim2Account *account, Gaim2Conversation *conv, char **message)
- {
- char *m;
- char **ms = g_strsplit(*message, "<u>", -1);
-@@ -46,18 +46,18 @@ static gboolean outgoing_msg_cb(GaimAcco
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *handle = gaim_conversations_get_handle();
-+ void *handle = gaim2_conversations_get_handle();
- plugin_handle = plugin;
-- gaim_signal_connect(handle, "writing-im-msg", plugin,
-+ gaim2_signal_connect(handle, "writing-im-msg", plugin,
- GAIM_CALLBACK(outgoing_msg_cb), NULL);
-
- return TRUE;
- }
-
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -74,7 +74,7 @@ static GaimPluginInfo info =
- "Changes the formatting of any outgoing text such that "
- "anything underlined will be received green and monospace.",
- "Sean Egan <seanegan@gmail.com>",
-- "http://gaim.sourceforge.net",
-+ "http://gaim2.sourceforge.net",
- plugin_load,
- NULL,
- NULL,
-@@ -85,7 +85,7 @@ static GaimPluginInfo info =
- };
-
- static void
-- init_plugin(GaimPlugin *plugin)
-+ init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/contact_priority.c ./plugins/contact_priority.c
---- ./plugins/contact_priority.c 2006-01-05 04:14:51.000000000 +0100
-+++ ./plugins/contact_priority.c 2006-01-05 15:27:38.000000000 +0100
-@@ -19,7 +19,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkplugin.h"
- #include "gtkutils.h"
- #include "prefs.h"
-@@ -28,31 +28,31 @@
- #define CONTACT_PRIORITY_PLUGIN_ID "gtk-contact-priority"
-
- static void
--select_account(GtkWidget *widget, GaimAccount *account, gpointer data)
-+select_account(GtkWidget *widget, Gaim2Account *account, gpointer data)
- {
- gtk_spin_button_set_value(GTK_SPIN_BUTTON(data),
-- (gdouble)gaim_account_get_int(account, "score", 0));
-+ (gdouble)gaim2_account_get_int(account, "score", 0));
- }
-
- static void
- account_update(GtkWidget *widget, GtkOptionMenu *optmenu)
- {
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
-
- account = g_object_get_data(G_OBJECT(gtk_menu_get_active(GTK_MENU(gtk_option_menu_get_menu(optmenu)))), "account");
-- gaim_account_set_int(account, "score", gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget)));
-+ gaim2_account_set_int(account, "score", gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget)));
- }
-
- static void
- pref_update(GtkWidget *widget, char *pref)
- {
-- if (gaim_prefs_get_type(pref) == GAIM_PREF_INT)
-- gaim_prefs_set_int(pref, gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget)));
-- if (gaim_prefs_get_type(pref) == GAIM_PREF_BOOLEAN)
-- gaim_prefs_set_bool(pref, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget)));
-+ if (gaim2_prefs_get_type(pref) == GAIM_PREF_INT)
-+ gaim2_prefs_set_int(pref, gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget)));
-+ if (gaim2_prefs_get_type(pref) == GAIM_PREF_BOOLEAN)
-+ gaim2_prefs_set_bool(pref, gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget)));
- }
-
--static struct GaimContactPriorityStatuses
-+static struct Gaim2ContactPriorityStatuses
- {
- const char *id;
- const char *description;
-@@ -70,24 +70,24 @@ static struct GaimContactPriorityStatuse
- };
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret = NULL, *hbox = NULL, *frame = NULL, *vbox = NULL;
- GtkWidget *label = NULL, *spin = NULL, *check = NULL;
- GtkWidget *optmenu = NULL;
- GtkObject *adj = NULL;
- GtkSizeGroup *sg = NULL;
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- int i;
-
-- gboolean last_match = gaim_prefs_get_bool("/core/contact/last_match");
-+ gboolean last_match = gaim2_prefs_get_bool("/core/contact/last_match");
-
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
- ret = gtk_vbox_new(FALSE, 18);
- gtk_container_set_border_width(GTK_CONTAINER(ret), 12);
-
-- frame = gaim_gtk_make_frame(ret, _("Point values to use when..."));
-+ frame = gaim2_gtk_make_frame(ret, _("Point values to use when..."));
-
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(frame), vbox);
-@@ -105,7 +105,7 @@ get_config_frame(GaimPlugin *plugin)
- gtk_size_group_add_widget(sg, label);
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
-
-- adj = gtk_adjustment_new(gaim_prefs_get_int(pref), -500, 500, 1, 1, 1);
-+ adj = gtk_adjustment_new(gaim2_prefs_get_int(pref), -500, 500, 1, 1, 1);
- spin = gtk_spin_button_new((GtkAdjustment *)adj, 1, 0);
- g_signal_connect(G_OBJECT(spin), "value-changed", G_CALLBACK(pref_update), pref);
- gtk_box_pack_start(GTK_BOX(hbox), spin, FALSE, FALSE, 0);
-@@ -127,7 +127,7 @@ get_config_frame(GaimPlugin *plugin)
- g_signal_connect(G_OBJECT(check), "toggled", G_CALLBACK(pref_update), "/core/contact/last_match");
- gtk_box_pack_start(GTK_BOX(hbox), check, FALSE, FALSE, 0);
-
-- frame = gaim_gtk_make_frame(ret, _("Point values to use for account..."));
-+ frame = gaim2_gtk_make_frame(ret, _("Point values to use for account..."));
-
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(frame), vbox);
-@@ -141,7 +141,7 @@ get_config_frame(GaimPlugin *plugin)
- adj = gtk_adjustment_new(0, -500, 500, 1, 1, 1);
- spin = gtk_spin_button_new((GtkAdjustment *)adj, 1, 0);
-
-- optmenu = gaim_gtk_account_option_menu_new(NULL, TRUE,
-+ optmenu = gaim2_gtk_account_option_menu_new(NULL, TRUE,
- G_CALLBACK(select_account),
- NULL, spin);
- gtk_box_pack_start(GTK_BOX(hbox), optmenu, FALSE, FALSE, 0);
-@@ -150,7 +150,7 @@ get_config_frame(GaimPlugin *plugin)
- account = g_object_get_data(G_OBJECT(gtk_menu_get_active(GTK_MENU(gtk_option_menu_get_menu(GTK_OPTION_MENU(optmenu))))),
- "account");
- gtk_spin_button_set_value(GTK_SPIN_BUTTON(spin),
-- (gdouble)gaim_account_get_int(account, "score", 0));
-+ (gdouble)gaim2_account_get_int(account, "score", 0));
- gtk_spin_button_set_adjustment(GTK_SPIN_BUTTON(spin), GTK_ADJUSTMENT(adj));
- g_signal_connect(G_OBJECT(spin), "value-changed",
- G_CALLBACK(account_update), optmenu);
-@@ -161,13 +161,13 @@ get_config_frame(GaimPlugin *plugin)
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -198,7 +198,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/crazychat/cc_gaim_plugin.c ./plugins/crazychat/cc_gaim_plugin.c
---- ./plugins/crazychat/cc_gaim_plugin.c 2005-08-11 09:56:29.000000000 +0200
-+++ ./plugins/crazychat/cc_gaim_plugin.c 2006-01-05 15:27:38.000000000 +0100
-@@ -27,13 +27,13 @@ static struct crazychat cc_info;
- /* --- begin function declarations --- */
-
- /**
-- * Called by gaim plugin to start CrazyChat
-+ * Called by gaim2 plugin to start CrazyChat
- * @param cc the crazychat struct
- */
- static void cc_init(struct crazychat *cc);
-
- /**
-- * Called by gaim plugin to destroy CrazyChat
-+ * Called by gaim2 plugin to destroy CrazyChat
- * @param cc the crazychat struct
- */
- static void cc_destroy(struct crazychat *cc);
-@@ -44,14 +44,14 @@ static void cc_destroy(struct crazychat
- * @param menu the buddy menu widget
- * @param b the buddy whose menu this is
- */
--static gboolean cc_buddy_menu(GtkWidget *menu, GaimBuddy *b);
-+static gboolean cc_buddy_menu(GtkWidget *menu, Gaim2Buddy *b);
-
- /**
- * Buddy menu callback. Initiates the CrazyChat session.
- * @param item the gtk buddy menu item
- * @param b the buddy whose menu the item was in
- */
--static void cc_menu_cb(GtkMenuItem *item, GaimBuddy *b);
-+static void cc_menu_cb(GtkMenuItem *item, Gaim2Buddy *b);
-
- /**
- * IM callback. Handles receiving a CrazyChat session request.
-@@ -61,7 +61,7 @@ static void cc_menu_cb(GtkMenuItem *item
- * @param flags IM flags
- * @param data user data
- */
--static gboolean receive_im_cb(GaimAccount *account, char **sender,
-+static gboolean receive_im_cb(Gaim2Account *account, char **sender,
- char **message, int *flags, void *data);
-
- /**
-@@ -71,7 +71,7 @@ static gboolean receive_im_cb(GaimAccoun
- * @param message the message we are displaying
- * @param data user data
- */
--static gboolean display_im_cb(GaimAccount *account, GaimConversation *conv,
-+static gboolean display_im_cb(Gaim2Account *account, Gaim2Conversation *conv,
- char **message, void *data);
-
- /**
-@@ -79,7 +79,7 @@ static gboolean display_im_cb(GaimAccoun
- * @param plugin the plugin data
- * @return the configuration frame
- */
--static GtkWidget *get_config_frame(GaimPlugin *plugin);
-+static GtkWidget *get_config_frame(Gaim2Plugin *plugin);
-
- /**
- * TCP port callback. Changes the port used to listen for new CC sessions
-@@ -105,10 +105,10 @@ static void features_enable_cb(struct cr
- /**
- * User signed on callback. Now we have a buddy list to connect a signal
- * handler to.
-- * @param gc the gaim connection we are signed on
-+ * @param gc the gaim2 connection we are signed on
- * @param plugin our plugin struct
- */
--static gboolean cc_signed_on(GaimConnection *gc, void *plugin);
-+static gboolean cc_signed_on(Gaim2Connection *gc, void *plugin);
-
- /**
- * Plugin loading callback. If a buddy list exists, connect our buddy menu
-@@ -116,13 +116,13 @@ static gboolean cc_signed_on(GaimConnect
- * signal handler so we know when we get a buddy list.
- * @param plugin our plugin struct
- */
--static gboolean plugin_load(GaimPlugin *plugin);
-+static gboolean plugin_load(Gaim2Plugin *plugin);
-
- /**
- * Plugin unloading callback. Disconnect all handlers and free data.
- * @param plugin our plugin struct
- */
--static gboolean plugin_unload(GaimPlugin *plugin);
-+static gboolean plugin_unload(Gaim2Plugin *plugin);
-
-
- /* --- end function declarations --- */
-@@ -130,11 +130,11 @@ static gboolean plugin_unload(GaimPlugin
-
- #define CRAZYCHAT_PLUGIN_ID "gtk-crazychat"
-
--static GaimGtkPluginUiInfo ui_info = {
-+static Gaim2GtkPluginUiInfo ui_info = {
- get_config_frame /**< get_config_frame */
- };
-
--static GaimPluginInfo info = {
-+static Gaim2PluginInfo info = {
- 2, /**< api_version */
- GAIM_PLUGIN_STANDARD, /**< type */
- GAIM_GTK_PLUGIN_TYPE, /**< ui_requirement */
-@@ -148,7 +148,7 @@ static GaimPluginInfo info = {
- /** summary */
- N_("Plugin to establish a Crazychat session."),
- /** description */
-- N_("Uses Gaim to obtain buddy ips to connect for a Crazychat session"),
-+ N_("Uses Gaim2 to obtain buddy ips to connect for a Crazychat session"),
- "\n"
- "William Chan <chanman@stanford.edu>\n"
- "Ian Spiro <ispiro@stanford.edu>\n"
-@@ -195,7 +195,7 @@ static void cc_destroy(struct crazychat
- memset(cc, 0, sizeof(*cc));
- }
-
--static gboolean cc_buddy_menu(GtkWidget *menu, GaimBuddy *b)
-+static gboolean cc_buddy_menu(GtkWidget *menu, Gaim2Buddy *b)
- {
- GtkWidget *menuitem;
-
-@@ -206,7 +206,7 @@ static gboolean cc_buddy_menu(GtkWidget
- return FALSE;
- }
-
--static void cc_menu_cb(GtkMenuItem *item, GaimBuddy *b)
-+static void cc_menu_cb(GtkMenuItem *item, Gaim2Buddy *b)
- {
- assert(item);
- assert(b);
-@@ -215,7 +215,7 @@ static void cc_menu_cb(GtkMenuItem *item
- cc_net_send_invite(&cc_info, b->name, b->account);
- }
-
--static gboolean receive_im_cb(GaimAccount *account, char **sender,
-+static gboolean receive_im_cb(Gaim2Account *account, char **sender,
- char **message, int *flags, void *data)
- {
- struct crazychat *cc;
-@@ -247,7 +247,7 @@ static gboolean receive_im_cb(GaimAccoun
- return FALSE;
- }
-
--static gboolean display_im_cb(GaimAccount *account, GaimConversation *conv,
-+static gboolean display_im_cb(Gaim2Account *account, Gaim2Conversation *conv,
- char **message, void *data)
- {
- struct crazychat *cc;
-@@ -268,7 +268,7 @@ static gboolean display_im_cb(GaimAccoun
- return FALSE;
- }
-
--static GtkWidget *get_config_frame(GaimPlugin *plugin)
-+static GtkWidget *get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret;
- GtkWidget *frame;
-@@ -292,7 +292,7 @@ static GtkWidget *get_config_frame(GaimP
- gtk_container_set_border_width(GTK_CONTAINER(ret), 12);
-
- /* make the network configuration frame */
-- frame = gaim_gtk_make_frame(ret, _("Network Configuration"));
-+ frame = gaim2_gtk_make_frame(ret, _("Network Configuration"));
- gtk_widget_show(frame);
-
- /* add boxes for packing purposes */
-@@ -326,7 +326,7 @@ static GtkWidget *get_config_frame(GaimP
- gtk_widget_show(spinner);
-
- /* make the feature configuration frame */
-- frame = gaim_gtk_make_frame(ret, _("Feature Calibration"));
-+ frame = gaim2_gtk_make_frame(ret, _("Feature Calibration"));
- gtk_widget_show(frame);
-
- /* add hbox for packing purposes */
-@@ -402,51 +402,51 @@ static void features_enable_cb(struct cr
- }
- }
-
--static gboolean cc_signed_on(GaimConnection *gc, void *plugin)
-+static gboolean cc_signed_on(Gaim2Connection *gc, void *plugin)
- {
- struct crazychat *extra;
- void *conv_handle;
-
- assert(plugin);
-- extra = (struct crazychat*)((GaimPlugin*)plugin)->info->extra_info;
-- gaim_signal_disconnect
-- (gaim_connections_get_handle(), "signed-on",
-+ extra = (struct crazychat*)((Gaim2Plugin*)plugin)->info->extra_info;
-+ gaim2_signal_disconnect
-+ (gaim2_connections_get_handle(), "signed-on",
- plugin, GAIM_CALLBACK(cc_signed_on));
-- gaim_signal_connect(GAIM_GTK_BLIST
-- (gaim_get_blist()),
-+ gaim2_signal_connect(GAIM_GTK_BLIST
-+ (gaim2_get_blist()),
- "drawing-menu", plugin,
- GAIM_CALLBACK(cc_buddy_menu), NULL);
-- conv_handle = gaim_conversations_get_handle();
-- gaim_signal_connect(conv_handle, "received-im-msg", plugin,
-+ conv_handle = gaim2_conversations_get_handle();
-+ gaim2_signal_connect(conv_handle, "received-im-msg", plugin,
- GAIM_CALLBACK(receive_im_cb), extra);
-- gaim_signal_connect(conv_handle, "displaying-im-msg", plugin,
-+ gaim2_signal_connect(conv_handle, "displaying-im-msg", plugin,
- GAIM_CALLBACK(display_im_cb), extra);
- return FALSE;
- }
-
--static gboolean plugin_load(GaimPlugin *plugin)
-+static gboolean plugin_load(Gaim2Plugin *plugin)
- {
-- GaimBuddyList *buddy_list;
-+ Gaim2BuddyList *buddy_list;
- void *conv_handle;
-
- if (cc_init_gtk_gl())
- return FALSE;
-
- cc_init(&cc_info);
-- buddy_list = gaim_get_blist();
-+ buddy_list = gaim2_get_blist();
- if (buddy_list) {
-- gaim_signal_connect(GAIM_GTK_BLIST
-+ gaim2_signal_connect(GAIM_GTK_BLIST
- (buddy_list),
- "drawing-menu", plugin,
- GAIM_CALLBACK(cc_buddy_menu), NULL);
-- conv_handle = gaim_conversations_get_handle();
-- gaim_signal_connect(conv_handle, "received-im-msg", plugin,
-+ conv_handle = gaim2_conversations_get_handle();
-+ gaim2_signal_connect(conv_handle, "received-im-msg", plugin,
- GAIM_CALLBACK(receive_im_cb), &cc_info);
-- gaim_signal_connect(conv_handle, "displaying-im-msg", plugin,
-+ gaim2_signal_connect(conv_handle, "displaying-im-msg", plugin,
- GAIM_CALLBACK(display_im_cb), &cc_info);
- } else {
-- gaim_signal_connect
-- (gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect
-+ (gaim2_connections_get_handle(), "signed-on",
- plugin, GAIM_CALLBACK(cc_signed_on), plugin);
- }
-
-@@ -455,27 +455,27 @@ static gboolean plugin_load(GaimPlugin *
- return TRUE;
- }
-
--static gboolean plugin_unload(GaimPlugin *plugin)
-+static gboolean plugin_unload(Gaim2Plugin *plugin)
- {
- void *conv_handle;
- struct crazychat *extra;
- assert(plugin);
- extra = (struct crazychat*) plugin->info->extra_info;
- cc_destroy(extra);
-- conv_handle = gaim_conversations_get_handle();
-- gaim_signal_disconnect(GAIM_GTK_BLIST
-- (gaim_get_blist()),
-+ conv_handle = gaim2_conversations_get_handle();
-+ gaim2_signal_disconnect(GAIM_GTK_BLIST
-+ (gaim2_get_blist()),
- "drawing-menu", plugin,
- GAIM_CALLBACK(cc_buddy_menu));
-- gaim_signal_disconnect(conv_handle, "received-im", plugin,
-+ gaim2_signal_disconnect(conv_handle, "received-im", plugin,
- GAIM_CALLBACK(receive_im_cb));
-- gaim_signal_disconnect(conv_handle, "displaying-im-msg", plugin,
-+ gaim2_signal_disconnect(conv_handle, "displaying-im-msg", plugin,
- GAIM_CALLBACK(display_im_cb));
- Debug("CrazyChat plugin unloaded.\n");
- return TRUE;
- }
-
--static void init_plugin(GaimPlugin *plugin)
-+static void init_plugin(Gaim2Plugin *plugin)
- {
- gtk_gl_init(NULL, NULL);
- memset(&cc_info, 0, sizeof(cc_info));
-diff -prNu ./plugins/crazychat/cc_network.c ./plugins/crazychat/cc_network.c
---- ./plugins/crazychat/cc_network.c 2005-08-25 04:33:44.000000000 +0200
-+++ ./plugins/crazychat/cc_network.c 2006-01-05 15:27:38.000000000 +0100
-@@ -22,7 +22,7 @@
- /* --- begin type declarations --- */
-
- struct accept_args {
-- GaimAccount *account;
-+ Gaim2Account *account;
- struct crazychat *cc;
- char *name;
- guint32 peer_ip;
-@@ -30,7 +30,7 @@ struct accept_args {
- };
-
- struct sock_accept_args {
-- GaimAccount *account;
-+ Gaim2Account *account;
- struct cc_session *session;
- };
-
-@@ -38,10 +38,10 @@ struct sock_accept_args {
-
- /**
- * Creates a server socket and sends a response to the peer.
-- * @param account the gaim account sending the ready msg
-+ * @param account the gaim2 account sending the ready msg
- * @param session the peer CrazyChat session
- */
--static void cc_net_send_ready(GaimAccount *account, struct cc_session *session);
-+static void cc_net_send_ready(Gaim2Account *account, struct cc_session *session);
-
- /**
- * Handles responses from the CrazyChat session invite dialog box.
-@@ -65,7 +65,7 @@ static gboolean accept_cb(struct sock_ac
- * @param account the account the session is part of
- * @param session the CrazyChat network session
- */
--static void init_cc_net_session(GaimAccount *account,
-+static void init_cc_net_session(Gaim2Account *account,
- struct cc_session *session);
-
- /**
-@@ -93,34 +93,34 @@ static int __send(int s, char *buf, int
-
- /* --- begin function definitions --- */
-
--void cc_net_send_invite(struct crazychat *cc, char *name, GaimAccount *account)
-+void cc_net_send_invite(struct crazychat *cc, char *name, Gaim2Account *account)
- {
- struct cc_session *session;
-- GaimConversation *conv;
-- GaimConvIm *im;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvIm *im;
- char buf[BUFSIZ];
-
- session = cc_find_session(cc, name);
- if (session) return; /* already have a session with this guy */
- session = cc_add_session(cc, name);
- session->state = INVITE;
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, name, account);
- if (!conv) {
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, name);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, name);
- }
-- im = gaim_conversation_get_im_data(conv);
-+ im = gaim2_conversation_get_im_data(conv);
- snprintf(buf, BUFSIZ, "%s%s!%d", CRAZYCHAT_INVITE_CODE,
-- gaim_network_get_my_ip(-1), cc->tcp_port);
-+ gaim2_network_get_my_ip(-1), cc->tcp_port);
- Debug("Sent invite to %s for port: %d\n", name, cc->tcp_port);
-- gaim_conv_im_send(im, buf);
-+ gaim2_conv_im_send(im, buf);
- }
-
--void cc_net_recv_invite(GaimAccount *account, struct crazychat *cc, char *name,
-+void cc_net_recv_invite(Gaim2Account *account, struct crazychat *cc, char *name,
- const char *peer_ip, const char *peer_port)
- {
- struct cc_session *session;
-- GaimConversation *conv;
-- GaimConvWindow *convwin;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvWindow *convwin;
- char buf[BUFSIZ];
- struct accept_args *args;
-
-@@ -131,8 +131,8 @@ void cc_net_recv_invite(GaimAccount *acc
- session = cc_find_session(cc, name);
- if (!session) {
- Debug("Creating a CrazyChat session invite dialog box!\n");
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, name, account);
-- if (conv) convwin = gaim_conversation_get_window(conv);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, name, account);
-+ if (conv) convwin = gaim2_conversation_get_window(conv);
- else convwin = NULL;
- /* pop gtk window asking if want to accept */
- GtkWidget *dialog =
-@@ -163,7 +163,7 @@ void cc_net_recv_invite(GaimAccount *acc
- }
- }
-
--void cc_net_recv_accept(GaimAccount *account, struct crazychat *cc, char *name,
-+void cc_net_recv_accept(Gaim2Account *account, struct crazychat *cc, char *name,
- const char *peer_ip)
- {
- struct cc_session *session;
-@@ -181,7 +181,7 @@ void cc_net_recv_accept(GaimAccount *acc
- }
- }
-
--static void cc_net_send_ready(GaimAccount *account, struct cc_session *session)
-+static void cc_net_send_ready(Gaim2Account *account, struct cc_session *session)
- {
- struct sock_accept_args *args;
-
-@@ -196,7 +196,7 @@ static void cc_net_send_ready(GaimAccoun
- struct sockaddr_in my_addr;
- my_addr.sin_family = AF_INET;
- my_addr.sin_port = htons(session->cc->tcp_port);
-- assert(inet_aton(gaim_network_get_my_ip(-1),
-+ assert(inet_aton(gaim2_network_get_my_ip(-1),
- &my_addr.sin_addr));
- memset(&my_addr.sin_zero, 0, sizeof(my_addr.sin_zero));
- assert(bind(session->tcp_sock, (struct sockaddr*)&my_addr,
-@@ -205,16 +205,16 @@ static void cc_net_send_ready(GaimAccoun
- assert(listen(session->tcp_sock, 1) != -1);
-
- /* socket created, send the ready message */
-- GaimConversation *conv;
-- GaimConvIm *im;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvIm *im;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, session->name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, session->name, account);
- if (!conv) {
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account,
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account,
- session->name);
- }
-- im = gaim_conversation_get_im_data(conv);
-- gaim_conv_im_send(im, CRAZYCHAT_READY_CODE);
-+ im = gaim2_conversation_get_im_data(conv);
-+ gaim2_conv_im_send(im, CRAZYCHAT_READY_CODE);
-
- /* register timer callback for checking socket connection */
- args = (struct sock_accept_args*)malloc(sizeof(*args));
-@@ -225,7 +225,7 @@ static void cc_net_send_ready(GaimAccoun
- (GSourceFunc)accept_cb, args);
- }
-
--void cc_net_recv_ready(GaimAccount *account, struct crazychat *cc, char *name)
-+void cc_net_recv_ready(Gaim2Account *account, struct crazychat *cc, char *name)
- {
- struct cc_session *session;
- struct sockaddr_in server_addr, my_addr;
-@@ -259,8 +259,8 @@ static void invite_handler(GtkDialog *di
- {
- struct cc_session *session;
- char buf[BUFSIZ];
-- GaimConversation *conv;
-- GaimConvIm *im;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvIm *im;
-
- if (response == GTK_RESPONSE_ACCEPT) {
- assert(args);
-@@ -271,15 +271,15 @@ static void invite_handler(GtkDialog *di
- session->peer_ip = args->peer_ip;
- session->peer_port = args->peer_port;
- snprintf(buf, BUFSIZ, "%s%s", CRAZYCHAT_ACCEPT_CODE,
-- gaim_network_get_my_ip(-1));
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, args->name,
-+ gaim2_network_get_my_ip(-1));
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, args->name,
- args->account);
- if (!conv) {
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM,
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM,
- args->account, args->name);
- }
-- im = gaim_conversation_get_im_data(conv);
-- gaim_conv_im_send(im, buf);
-+ im = gaim2_conversation_get_im_data(conv);
-+ gaim2_conv_im_send(im, buf);
- }
- free(args->name);
- free(args);
-@@ -291,7 +291,7 @@ static gboolean accept_cb(struct sock_ac
- fd_set fds;
- struct timeval zero;
- int ret;
-- GaimAccount *account;
-+ Gaim2Account *account;
- struct cc_session *session;
-
- assert(args);
-@@ -348,7 +348,7 @@ static gboolean accept_cb(struct sock_ac
- return TRUE;
- }
-
--static void init_cc_net_session(GaimAccount *account,
-+static void init_cc_net_session(Gaim2Account *account,
- struct cc_session *session)
- {
- struct sockaddr_in my_addr;
-@@ -375,7 +375,7 @@ static void init_cc_net_session(GaimAcco
-
- my_addr.sin_family = AF_INET;
- my_addr.sin_port = htons(session->cc->udp_port);
-- assert(inet_aton(gaim_network_get_my_ip(-1),
-+ assert(inet_aton(gaim2_network_get_my_ip(-1),
- &my_addr.sin_addr));
- memset(my_addr.sin_zero, 0, sizeof(my_addr.sin_zero));
- assert(!bind(session->udp_sock, (struct sockaddr*)&my_addr,
-diff -prNu ./plugins/crazychat/cc_network.h ./plugins/crazychat/cc_network.h
---- ./plugins/crazychat/cc_network.h 2005-08-11 09:56:29.000000000 +0200
-+++ ./plugins/crazychat/cc_network.h 2006-01-05 15:27:48.000000000 +0100
-@@ -34,20 +34,20 @@
- * Creates a new CrazyChat session if one doesn't exist and sends the invite.
- * @param cc global crazychat data structure
- * @param name the peer name
-- * @param account the gaim account
-+ * @param account the gaim2 account
- */
--void cc_net_send_invite(struct crazychat *cc, char *name, GaimAccount *account);
-+void cc_net_send_invite(struct crazychat *cc, char *name, Gaim2Account *account);
-
- /**
- * Pops up the CrazyChat invitation accept window if a CrazyChat session does
- * not exist yet for this peer.
-- * @param account gaim account
-+ * @param account gaim2 account
- * @param cc global crazychat data structure
- * @param name the peer name
- * @param peer_ip the peer's ip address
- * @param peer_port the peer's tcp port
- */
--void cc_net_recv_invite(GaimAccount *account, struct crazychat *cc, char *name,
-+void cc_net_recv_invite(Gaim2Account *account, struct crazychat *cc, char *name,
- const char *peer_ip, const char *peer_port);
-
- /**
-@@ -59,20 +59,20 @@ void cc_net_send_accept(struct cc_sessio
- /**
- * Receives a CrazyChat accept message, and if appropriate, creates a server
- * socket and sends the ready message.
-- * @param account the gaim account which received the message
-+ * @param account the gaim2 account which received the message
- * @param cc global crazychat data structure
- * @param name the peer name
- * @param peer_ip the peer's ip address
- */
--void cc_net_recv_accept(GaimAccount *account, struct crazychat *cc, char *name,
-+void cc_net_recv_accept(Gaim2Account *account, struct crazychat *cc, char *name,
- const char *peer_ip);
-
- /**
- * Receives a CrazyChat ready message, and if appropriate, connects to peer
-- * @param account the gaim account which received the message
-+ * @param account the gaim2 account which received the message
- * @param cc global crazychat data structure
- * @param name the peer name
- */
--void cc_net_recv_ready(GaimAccount *account, struct crazychat *cc, char *name);
-+void cc_net_recv_ready(Gaim2Account *account, struct crazychat *cc, char *name);
-
- #endif
-diff -prNu ./plugins/crazychat/crazychat.h ./plugins/crazychat/crazychat.h
---- ./plugins/crazychat/crazychat.h 2005-08-11 09:56:29.000000000 +0200
-+++ ./plugins/crazychat/crazychat.h 2006-01-05 15:27:48.000000000 +0100
-@@ -7,7 +7,7 @@
- #include <netinet/in.h>
- #include <gtk/gtk.h>
- #include "filter.h"
--#include "gaim.h"
-+#include "gaim2.h"
-
- #ifdef HAVE_CONFIG_H
- # include "config.h"
-diff -prNu ./plugins/crazychat/Makefile.am ./plugins/crazychat/Makefile.am
---- ./plugins/crazychat/Makefile.am 2005-12-07 08:32:21.000000000 +0100
-+++ ./plugins/crazychat/Makefile.am 2006-01-05 13:15:04.000000000 +0100
-@@ -1,4 +1,4 @@
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- if ENABLE_DEBUG
- DEBUG_CPPFLAGS = -g -pg
-diff -prNu ./plugins/crazychat/util.h ./plugins/crazychat/util.h
---- ./plugins/crazychat/util.h 2005-08-11 09:56:29.000000000 +0200
-+++ ./plugins/crazychat/util.h 2006-01-05 15:27:48.000000000 +0100
-@@ -33,7 +33,7 @@
- #define Debug(x, args...) \
- do { \
- printf(x, ## args); \
-- gaim_debug(GAIM_DEBUG_INFO, "crazychat", x, ## args); \
-+ gaim2_debug(GAIM_DEBUG_INFO, "crazychat", x, ## args); \
- } while (0)
- #else
- #define Debug(x, args...) do{}while(0)
-diff -prNu ./plugins/dbus-example.c ./plugins/dbus-example.c
---- ./plugins/dbus-example.c 2005-08-08 03:40:39.000000000 +0200
-+++ ./plugins/dbus-example.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,18 +1,18 @@
- /*
-- This is an example of a gaim dbus plugin. After enabling this
-+ This is an example of a gaim2 dbus plugin. After enabling this
- plugin, the following commands should work from the command line:
-
-- prompt$ gaim-send DbusExampleGetHelloObject
-+ prompt$ gaim2-send DbusExampleGetHelloObject
-
- returns, say: int32 74
-
-- prompt$ gaim-send DbusExampleGetText int32:74
-+ prompt$ gaim2-send DbusExampleGetText int32:74
-
- returns: string "Hello."
-
-- prompt$ gaim-send DbusExampleSetText int32:74 string:Bye!
-+ prompt$ gaim2-send DbusExampleSetText int32:74 string:Bye!
-
-- prompt$ gaim-send DbusExampleGetText int32:74
-+ prompt$ gaim2-send DbusExampleGetText int32:74
-
- returns: string "Bye!"
-
-@@ -34,38 +34,38 @@
-
- typedef struct {
- char *text;
--} GaimText;
-+} Gaim2Text;
-
--/* This makes the structure GaimText visible to the gaim-dbus type
-- system. It defines GaimText as a type with no parent. From now
-+/* This makes the structure Gaim2Text visible to the gaim2-dbus type
-+ system. It defines Gaim2Text as a type with no parent. From now
- on, we will be able to register pointers to structures of this
- type. You to dbus-define types you want to be directly accessible
- by external applications. */
--GAIM_DBUS_DEFINE_TYPE(GaimText)
-+GAIM_DBUS_DEFINE_TYPE(Gaim2Text)
-
- /* Here we make four functions accessible to other applications by
-- DBus. These functions can access types defined in gaim proper
-- (GaimBuddy) as well as the types defined in the plugin (GaimText). */
--DBUS_EXPORT GaimText* dbus_example_get_hello_object(void);
--DBUS_EXPORT void dbus_example_set_text(GaimText *obj, const char *text);
--DBUS_EXPORT const char *dbus_example_get_text(GaimText *obj);
--DBUS_EXPORT const char *dbus_example_get_buddy_name(GaimBuddy *buddy);
-+ DBus. These functions can access types defined in gaim2 proper
-+ (Gaim2Buddy) as well as the types defined in the plugin (Gaim2Text). */
-+DBUS_EXPORT Gaim2Text* dbus_example_get_hello_object(void);
-+DBUS_EXPORT void dbus_example_set_text(Gaim2Text *obj, const char *text);
-+DBUS_EXPORT const char *dbus_example_get_text(Gaim2Text *obj);
-+DBUS_EXPORT const char *dbus_example_get_buddy_name(Gaim2Buddy *buddy);
-
- /* This file has been generated by the #dbus-analize-functions.py
- script. It contains dbus wrappers for the four functions declared
- above. */
- #include "dbus-example-bindings.c"
-
--/* This is the GaimText object we want to make publicly visible. */
--static GaimText hello;
-+/* This is the Gaim2Text object we want to make publicly visible. */
-+static Gaim2Text hello;
-
- /* Here come the definitions of the four exported functions. */
--GaimText* dbus_example_get_hello_object(void)
-+Gaim2Text* dbus_example_get_hello_object(void)
- {
- return &hello;
- }
-
--void dbus_example_set_text(GaimText *obj, const char *text)
-+void dbus_example_set_text(Gaim2Text *obj, const char *text)
- {
- if (obj != NULL) {
- g_free(obj->text);
-@@ -73,7 +73,7 @@ void dbus_example_set_text(GaimText *obj
- }
- }
-
--const char *dbus_example_get_text(GaimText *obj)
-+const char *dbus_example_get_text(Gaim2Text *obj)
- {
- if (obj != NULL)
- return obj->text;
-@@ -81,27 +81,27 @@ const char *dbus_example_get_text(GaimTe
- return NULL;
- }
-
--const char *dbus_example_get_buddy_name(GaimBuddy *buddy)
-+const char *dbus_example_get_buddy_name(Gaim2Buddy *buddy)
- {
-- return gaim_buddy_get_name(buddy);
-+ return gaim2_buddy_get_name(buddy);
- }
-
- /* And now standard plugin stuff */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- /* First, we have to register our four exported functions with the
-- main gaim dbus loop. Without this statement, the gaim dbus
-+ main gaim2 dbus loop. Without this statement, the gaim2 dbus
- code wouldn't know about our functions. */
- GAIM_DBUS_REGISTER_BINDINGS(plugin);
-
-- /* Then, we register the hello object of type GaimText. Note that
-+ /* Then, we register the hello object of type Gaim2Text. Note that
- pointer registrations / unregistrations are completely dynamic;
- they don't have to be made when the plugin is loaded /
-- unloaded. Without this statement the dbus gaim code wouldn't
-+ unloaded. Without this statement the dbus gaim2 code wouldn't
- know about the hello object. */
-- GAIM_DBUS_REGISTER_POINTER(&hello, GaimText);
-+ GAIM_DBUS_REGISTER_POINTER(&hello, Gaim2Text);
-
- hello.text = g_strdup("Hello.");
-
-@@ -110,7 +110,7 @@ plugin_load(GaimPlugin *plugin)
-
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- g_free(hello.text);
-
-@@ -120,7 +120,7 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -151,7 +151,7 @@ static GaimPluginInfo info =
- NULL
- };
-
--static void init_plugin(GaimPlugin *plugin)
-+static void init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/docklet/docklet.c ./plugins/docklet/docklet.c
---- ./plugins/docklet/docklet.c 2006-01-05 06:18:58.000000000 +0100
-+++ ./plugins/docklet/docklet.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * System tray icon (aka docklet) plugin for Gaim
-+ * System tray icon (aka docklet) plugin for Gaim2
- *
- * Copyright (C) 2002-3 Robert McQueen <robot101@debian.org>
- * Copyright (C) 2003 Herman Bloggs <hermanator12002@yahoo.com>
-@@ -22,7 +22,7 @@
- * 02111-1307, USA.
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "core.h"
- #include "conversation.h"
-@@ -44,7 +44,7 @@
- #include "gtkstock.h"
- #include "docklet.h"
-
--#include "gaim.h"
-+#include "gaim2.h"
- #include "gtkdialogs.h"
-
- #define DOCKLET_PLUGIN_ID "gtk-docklet"
-@@ -54,7 +54,7 @@
- #endif
-
- /* globals */
--GaimPlugin *handle = NULL;
-+Gaim2Plugin *handle = NULL;
- static struct docklet_ui_ops *ui_ops = NULL;
- static DockletStatus status = DOCKLET_STATUS_OFFLINE;
- static gboolean enable_join_chat = FALSE;
-@@ -96,27 +96,27 @@ docklet_blink_icon()
- static GList *
- get_pending_list(guint max)
- {
-- const char *im = gaim_prefs_get_string("/plugins/gtk/docklet/blink_im");
-- const char *chat = gaim_prefs_get_string("/plugins/gtk/docklet/blink_chat");
-+ const char *im = gaim2_prefs_get_string("/plugins/gtk/docklet/blink_im");
-+ const char *chat = gaim2_prefs_get_string("/plugins/gtk/docklet/blink_chat");
- GList *l_im = NULL;
- GList *l_chat = NULL;
-
- if (im != NULL && strcmp(im, "always") == 0) {
-- l_im = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM,
-+ l_im = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM,
- GAIM_UNSEEN_TEXT,
- FALSE, max);
- } else if (im != NULL && strcmp(im, "hidden") == 0) {
-- l_im = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM,
-+ l_im = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM,
- GAIM_UNSEEN_TEXT,
- TRUE, max);
- }
-
- if (chat != NULL && strcmp(chat, "always") == 0) {
-- l_chat = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_CHAT,
-+ l_chat = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_CHAT,
- GAIM_UNSEEN_TEXT,
- FALSE, max);
- } else if (chat != NULL && strcmp(chat, "nick") == 0) {
-- l_chat = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_CHAT,
-+ l_chat = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_CHAT,
- GAIM_UNSEEN_NICK,
- FALSE, max);
- }
-@@ -149,7 +149,7 @@ docklet_update_status()
- GString *tooltip_text = g_string_new("");
- for (l = convs, count = 0 ; l != NULL ; l = l->next, count++) {
- if (GAIM_IS_GTK_CONVERSATION(l->data)) {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION((GaimConversation *)l->data);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION((Gaim2Conversation *)l->data);
- if (count == DOCKLET_TOOLTIP_LINE_LIMIT - 1)
- g_string_append(tooltip_text, _("Right-click for more unread messages...\n"));
- else
-@@ -186,24 +186,24 @@ docklet_update_status()
- * 5) AWAY_PENDING
- * 6) CONNECTING
- */
-- for(l = gaim_accounts_get_all(); l != NULL; l = l->next) {
-+ for(l = gaim2_accounts_get_all(); l != NULL; l = l->next) {
- DockletStatus tmpstatus = DOCKLET_STATUS_OFFLINE;
-
-- GaimAccount *account = (GaimAccount*)l->data;
-- GaimStatus *account_status;
-+ Gaim2Account *account = (Gaim2Account*)l->data;
-+ Gaim2Status *account_status;
-
-- if (!gaim_account_get_enabled(account, GAIM_GTK_UI))
-+ if (!gaim2_account_get_enabled(account, GAIM_GTK_UI))
- continue;
-
-- if (gaim_account_is_disconnected(account))
-+ if (gaim2_account_is_disconnected(account))
- continue;
-
-- account_status = gaim_account_get_active_status(account);
-+ account_status = gaim2_account_get_active_status(account);
-
-- if (gaim_account_is_connecting(account)) {
-+ if (gaim2_account_is_connecting(account)) {
- tmpstatus = DOCKLET_STATUS_CONNECTING;
-- } else if (gaim_status_is_online(account_status)) {
-- if (!gaim_status_is_available(account_status)) {
-+ } else if (gaim2_status_is_online(account_status)) {
-+ if (!gaim2_status_is_available(account_status)) {
- if (pending)
- tmpstatus = DOCKLET_STATUS_AWAY_PENDING;
- else
-@@ -243,11 +243,11 @@ static gboolean
- online_account_supports_chat()
- {
- GList *c = NULL;
-- c = gaim_connections_get_all();
-+ c = gaim2_connections_get_all();
-
- while(c != NULL) {
-- GaimConnection *gc = c->data;
-- GaimPluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-+ Gaim2Connection *gc = c->data;
-+ Gaim2PluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
- if (prpl_info != NULL && prpl_info->chat_info != NULL)
- return TRUE;
- c = c->next;
-@@ -260,7 +260,7 @@ online_account_supports_chat()
- * callbacks and signal handlers
- **************************************************************************/
- static void
--gaim_quit_cb()
-+gaim2_quit_cb()
- {
- /* TODO: confirm quit while pending */
- }
-@@ -272,21 +272,21 @@ docklet_update_status_cb(void *data)
- }
-
- static void
--docklet_prefs_cb(const char *name, GaimPrefType type,
-+docklet_prefs_cb(const char *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
- docklet_update_status();
- }
-
- static void
--docklet_conv_updated_cb(GaimConversation *conv, GaimConvUpdateType type)
-+docklet_conv_updated_cb(Gaim2Conversation *conv, Gaim2ConvUpdateType type)
- {
- if (type == GAIM_CONV_UPDATE_UNSEEN)
- docklet_update_status();
- }
-
- static void
--docklet_signed_on_cb(GaimConnection *gc)
-+docklet_signed_on_cb(Gaim2Connection *gc)
- {
- if (!enable_join_chat) {
- if (GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)->chat_info != NULL)
-@@ -296,7 +296,7 @@ docklet_signed_on_cb(GaimConnection *gc)
- }
-
- static void
--docklet_signed_off_cb(GaimConnection *gc)
-+docklet_signed_off_cb(Gaim2Connection *gc)
- {
- if (enable_join_chat) {
- if (GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)->chat_info != NULL)
-@@ -311,13 +311,13 @@ docklet_signed_off_cb(GaimConnection *gc
- static void
- docklet_toggle_mute(GtkWidget *toggle, void *data)
- {
-- gaim_prefs_set_bool("/gaim/gtk/sound/mute", GTK_CHECK_MENU_ITEM(toggle)->active);
-+ gaim2_prefs_set_bool("/gaim2/gtk/sound/mute", GTK_CHECK_MENU_ITEM(toggle)->active);
- }
-
- static void
- docklet_toggle_blist(GtkWidget *toggle, void *data)
- {
-- gaim_blist_set_visible(GTK_CHECK_MENU_ITEM(toggle)->active);
-+ gaim2_blist_set_visible(GTK_CHECK_MENU_ITEM(toggle)->active);
- }
-
- #ifdef _WIN32
-@@ -338,18 +338,18 @@ docklet_menu_leave_enter(GtkWidget *menu
- {
- static guint hide_docklet_timer = 0;
- if (event->type == GDK_LEAVE_NOTIFY && event->detail == GDK_NOTIFY_ANCESTOR) {
-- gaim_debug(GAIM_DEBUG_INFO, "docklet", "menu leave-notify-event\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "docklet", "menu leave-notify-event\n");
- /* Add some slop so that the menu doesn't annoyingly disappear when mousing around */
- if (hide_docklet_timer == 0) {
-- hide_docklet_timer = gaim_timeout_add(500,
-+ hide_docklet_timer = gaim2_timeout_add(500,
- hide_docklet_menu, menu);
- }
- } else if (event->type == GDK_ENTER_NOTIFY && event->detail == GDK_NOTIFY_ANCESTOR) {
-- gaim_debug(GAIM_DEBUG_INFO, "docklet", "menu enter-notify-event\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "docklet", "menu enter-notify-event\n");
- if (hide_docklet_timer != 0) {
- /* Cancel the hiding if we reenter */
-
-- gaim_timeout_remove(hide_docklet_timer);
-+ gaim2_timeout_remove(hide_docklet_timer);
- hide_docklet_timer = 0;
- }
- }
-@@ -360,35 +360,35 @@ docklet_menu_leave_enter(GtkWidget *menu
- static void
- show_custom_status_editor_cb(GtkMenuItem *menuitem, gpointer user_data)
- {
-- gaim_gtk_status_editor_show(NULL);
-+ gaim2_gtk_status_editor_show(NULL);
- }
-
- static void
- activate_status_primitive_cb(GtkMenuItem *menuitem, gpointer user_data)
- {
-- GaimStatusPrimitive primitive;
-- GaimSavedStatus *saved_status;
-+ Gaim2StatusPrimitive primitive;
-+ Gaim2SavedStatus *saved_status;
-
- primitive = GPOINTER_TO_INT(user_data);
-
- /* Create a new transient saved status */
-- saved_status = gaim_savedstatus_new(NULL, primitive);
-- gaim_savedstatus_set_type(saved_status, primitive);
-+ saved_status = gaim2_savedstatus_new(NULL, primitive);
-+ gaim2_savedstatus_set_type(saved_status, primitive);
-
- /* Set the status for each account */
-- gaim_savedstatus_activate(saved_status);
-+ gaim2_savedstatus_activate(saved_status);
- }
-
- static void
- activate_saved_status_cb(GtkMenuItem *menuitem, gpointer user_data)
- {
- time_t creation_time;
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
-
- creation_time = GPOINTER_TO_INT(user_data);
-- saved_status = gaim_savedstatus_find_by_creation_time(creation_time);
-+ saved_status = gaim2_savedstatus_find_by_creation_time(creation_time);
- if (saved_status != NULL)
-- gaim_savedstatus_activate(saved_status);
-+ gaim2_savedstatus_activate(saved_status);
- }
-
- static GtkWidget *
-@@ -401,40 +401,40 @@ docklet_status_submenu()
- menuitem = gtk_menu_item_new_with_label(_("Change Status"));
- gtk_menu_item_set_submenu(GTK_MENU_ITEM(menuitem), submenu);
-
-- gaim_new_item_from_stock(submenu, _("Available"),
-+ gaim2_new_item_from_stock(submenu, _("Available"),
- GAIM_STOCK_ICON_AWAY, G_CALLBACK(activate_status_primitive_cb),
- GINT_TO_POINTER(GAIM_STATUS_AVAILABLE), 0, 0, NULL);
-
-- gaim_new_item_from_stock(submenu, _("Away"),
-+ gaim2_new_item_from_stock(submenu, _("Away"),
- GAIM_STOCK_ICON_AWAY, G_CALLBACK(activate_status_primitive_cb),
- GINT_TO_POINTER(GAIM_STATUS_AWAY), 0, 0, NULL);
-
-- gaim_new_item_from_stock(submenu, _("Invisible"),
-+ gaim2_new_item_from_stock(submenu, _("Invisible"),
- GAIM_STOCK_ICON_AWAY, G_CALLBACK(activate_status_primitive_cb),
- GINT_TO_POINTER(GAIM_STATUS_INVISIBLE), 0, 0, NULL);
-
-- gaim_new_item_from_stock(submenu, _("Offline"),
-+ gaim2_new_item_from_stock(submenu, _("Offline"),
- GAIM_STOCK_ICON_AWAY, G_CALLBACK(activate_status_primitive_cb),
- GINT_TO_POINTER(GAIM_STATUS_OFFLINE), 0, 0, NULL);
-
-- popular_statuses = gaim_savedstatuses_get_popular(6);
-+ popular_statuses = gaim2_savedstatuses_get_popular(6);
- if (popular_statuses != NULL)
-- gaim_separator(submenu);
-+ gaim2_separator(submenu);
- for (cur = popular_statuses; cur != NULL; cur = cur->next)
- {
-- GaimSavedStatus *saved_status = cur->data;
-- time_t creation_time = gaim_savedstatus_get_creation_time(saved_status);
-- gaim_new_item_from_stock(submenu,
-- gaim_savedstatus_get_title(saved_status),
-+ Gaim2SavedStatus *saved_status = cur->data;
-+ time_t creation_time = gaim2_savedstatus_get_creation_time(saved_status);
-+ gaim2_new_item_from_stock(submenu,
-+ gaim2_savedstatus_get_title(saved_status),
- GAIM_STOCK_ICON_AWAY, G_CALLBACK(activate_saved_status_cb),
- GINT_TO_POINTER(creation_time), 0, 0, NULL);
- }
- g_list_free(popular_statuses);
-
-- gaim_separator(submenu);
-+ gaim2_separator(submenu);
-
-- gaim_new_item_from_stock(submenu, _("Custom Status..."), GAIM_STOCK_ICON_AWAY, G_CALLBACK(show_custom_status_editor_cb), NULL, 0, 0, NULL);
-- gaim_new_item_from_stock(submenu, _("Saved Status..."), GAIM_STOCK_ICON_AWAY, G_CALLBACK(gaim_gtk_status_window_show), NULL, 0, 0, NULL);
-+ gaim2_new_item_from_stock(submenu, _("Custom Status..."), GAIM_STOCK_ICON_AWAY, G_CALLBACK(show_custom_status_editor_cb), NULL, 0, 0, NULL);
-+ gaim2_new_item_from_stock(submenu, _("Saved Status..."), GAIM_STOCK_ICON_AWAY, G_CALLBACK(gaim2_gtk_status_window_show), NULL, 0, 0, NULL);
-
- return menuitem;
- }
-@@ -451,7 +451,7 @@ docklet_menu() {
- menu = gtk_menu_new();
-
- menuitem = gtk_check_menu_item_new_with_label(_("Show Buddy List"));
-- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(menuitem), gaim_prefs_get_bool("/gaim/gtk/blist/list_visible"));
-+ gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(menuitem), gaim2_prefs_get_bool("/gaim2/gtk/blist/list_visible"));
- g_signal_connect(G_OBJECT(menuitem), "toggled", G_CALLBACK(docklet_toggle_blist), NULL);
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
-
-@@ -462,10 +462,10 @@ docklet_menu() {
- GList *l = get_pending_list(0);
- if (l == NULL) {
- gtk_widget_set_sensitive(menuitem, FALSE);
-- gaim_debug_warning("docklet",
-+ gaim2_debug_warning("docklet",
- "status indicates messages pending, but no conversations with unseen messages were found.");
- } else {
-- gaim_gtk_conversations_fill_menu(submenu, l);
-+ gaim2_gtk_conversations_fill_menu(submenu, l);
- g_list_free(l);
- gtk_menu_item_set_submenu(GTK_MENU_ITEM(menuitem), submenu);
- }
-@@ -474,37 +474,37 @@ docklet_menu() {
- }
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
-- menuitem = gaim_new_item_from_stock(menu, _("New Message..."), GAIM_STOCK_IM, G_CALLBACK(gaim_gtkdialogs_im), NULL, 0, 0, NULL);
-+ menuitem = gaim2_new_item_from_stock(menu, _("New Message..."), GAIM_STOCK_IM, G_CALLBACK(gaim2_gtkdialogs_im), NULL, 0, 0, NULL);
- if (status == DOCKLET_STATUS_OFFLINE)
- gtk_widget_set_sensitive(menuitem, FALSE);
-
- menuitem = docklet_status_submenu();
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
-- gaim_new_item_from_stock(menu, _("Accounts"), GAIM_STOCK_ACCOUNTS, G_CALLBACK(gaim_gtk_accounts_window_show), NULL, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("Plugins"), GAIM_STOCK_PLUGIN, G_CALLBACK(gaim_gtk_plugin_dialog_show), NULL, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("Preferences"), GTK_STOCK_PREFERENCES, G_CALLBACK(gaim_gtk_prefs_show), NULL, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("Accounts"), GAIM_STOCK_ACCOUNTS, G_CALLBACK(gaim2_gtk_accounts_window_show), NULL, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("Plugins"), GAIM_STOCK_PLUGIN, G_CALLBACK(gaim2_gtk_plugin_dialog_show), NULL, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("Preferences"), GTK_STOCK_PREFERENCES, G_CALLBACK(gaim2_gtk_prefs_show), NULL, 0, 0, NULL);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
- menuitem = gtk_check_menu_item_new_with_label(_("Mute Sounds"));
-- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(menuitem), gaim_prefs_get_bool("/gaim/gtk/sound/mute"));
-- if (!strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"), "none"))
-+ gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(menuitem), gaim2_prefs_get_bool("/gaim2/gtk/sound/mute"));
-+ if (!strcmp(gaim2_prefs_get_string("/gaim2/gtk/sound/method"), "none"))
- gtk_widget_set_sensitive(GTK_WIDGET(menuitem), FALSE);
- g_signal_connect(G_OBJECT(menuitem), "toggled", G_CALLBACK(docklet_toggle_mute), NULL);
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
- /* TODO: need a submenu to change status, this needs to "link"
- * to the status in the buddy list gtkstatusbox
- */
-
-- gaim_new_item_from_stock(menu, _("Quit"), GTK_STOCK_QUIT, G_CALLBACK(gaim_core_quit), NULL, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("Quit"), GTK_STOCK_QUIT, G_CALLBACK(gaim2_core_quit), NULL, 0, 0, NULL);
-
- #ifdef _WIN32
- g_signal_connect(menu, "leave-notify-event", G_CALLBACK(docklet_menu_leave_enter), NULL);
-@@ -527,11 +527,11 @@ docklet_clicked(int button_type)
- if (status == DOCKLET_STATUS_ONLINE_PENDING || status == DOCKLET_STATUS_AWAY_PENDING) {
- GList *l = get_pending_list(1);
- if (l != NULL) {
-- gaim_gtkconv_present_conversation((GaimConversation *)l->data);
-+ gaim2_gtkconv_present_conversation((Gaim2Conversation *)l->data);
- g_list_free(l);
- }
- } else {
-- gaim_gtk_blist_toggle_visibility();
-+ gaim2_gtk_blist_toggle_visibility();
- }
- break;
- case 3:
-@@ -544,7 +544,7 @@ void
- docklet_embedded()
- {
- if (!visibility_manager) {
-- gaim_gtk_blist_visibility_manager_add();
-+ gaim2_gtk_blist_visibility_manager_add();
- visibility_manager = TRUE;
- }
- docklet_update_status();
-@@ -556,7 +556,7 @@ void
- docklet_remove()
- {
- if (visibility_manager) {
-- gaim_gtk_blist_visibility_manager_remove();
-+ gaim2_gtk_blist_visibility_manager_remove();
- visibility_manager = FALSE;
- }
- }
-@@ -564,7 +564,7 @@ docklet_remove()
- void
- docklet_unload()
- {
-- gaim_plugin_unload(handle);
-+ gaim2_plugin_unload(handle);
- }
-
- void
-@@ -577,41 +577,41 @@ docklet_set_ui_ops(struct docklet_ui_ops
- * plugin glue
- **************************************************************************/
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *conn_handle = gaim_connections_get_handle();
-- void *conv_handle = gaim_conversations_get_handle();
-- void *accounts_handle = gaim_accounts_get_handle();
-- void *core_handle = gaim_get_core();
-+ void *conn_handle = gaim2_connections_get_handle();
-+ void *conv_handle = gaim2_conversations_get_handle();
-+ void *accounts_handle = gaim2_accounts_get_handle();
-+ void *core_handle = gaim2_get_core();
-
-- gaim_debug(GAIM_DEBUG_INFO, "docklet", "plugin loaded\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "docklet", "plugin loaded\n");
-
- handle = plugin;
-
- docklet_ui_init();
- if (ui_ops && ui_ops->create)
- ui_ops->create();
-- gaim_signal_connect(conn_handle, "signed-on",
-+ gaim2_signal_connect(conn_handle, "signed-on",
- plugin, GAIM_CALLBACK(docklet_signed_on_cb), NULL);
-- gaim_signal_connect(conn_handle, "signed-off",
-+ gaim2_signal_connect(conn_handle, "signed-off",
- plugin, GAIM_CALLBACK(docklet_signed_off_cb), NULL);
-- gaim_signal_connect(accounts_handle, "account-status-changed",
-+ gaim2_signal_connect(accounts_handle, "account-status-changed",
- plugin, GAIM_CALLBACK(docklet_update_status_cb), NULL);
-- gaim_signal_connect(conv_handle, "received-im-msg",
-+ gaim2_signal_connect(conv_handle, "received-im-msg",
- plugin, GAIM_CALLBACK(docklet_update_status_cb), NULL);
-- gaim_signal_connect(conv_handle, "conversation-created",
-+ gaim2_signal_connect(conv_handle, "conversation-created",
- plugin, GAIM_CALLBACK(docklet_update_status_cb), NULL);
-- gaim_signal_connect(conv_handle, "deleting-conversation",
-+ gaim2_signal_connect(conv_handle, "deleting-conversation",
- plugin, GAIM_CALLBACK(docklet_update_status_cb), NULL);
-- gaim_signal_connect(conv_handle, "conversation-updated",
-+ gaim2_signal_connect(conv_handle, "conversation-updated",
- plugin, GAIM_CALLBACK(docklet_conv_updated_cb), NULL);
-
-- gaim_signal_connect(core_handle, "quitting",
-- plugin, GAIM_CALLBACK(gaim_quit_cb), NULL);
-+ gaim2_signal_connect(core_handle, "quitting",
-+ plugin, GAIM_CALLBACK(gaim2_quit_cb), NULL);
-
-- gaim_prefs_connect_callback(plugin, "/plugins/gtk/docklet/blink_im",
-+ gaim2_prefs_connect_callback(plugin, "/plugins/gtk/docklet/blink_im",
- docklet_prefs_cb, NULL);
-- gaim_prefs_connect_callback(plugin, "/plugins/gtk/docklet/blink_chat",
-+ gaim2_prefs_connect_callback(plugin, "/plugins/gtk/docklet/blink_chat",
- docklet_prefs_cb, NULL);
-
- enable_join_chat = online_account_supports_chat();
-@@ -620,22 +620,22 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- if (ui_ops && ui_ops->destroy)
- ui_ops->destroy();
-
- /* remove callbacks */
-- gaim_signals_disconnect_by_handle(handle);
-- gaim_prefs_disconnect_by_handle(handle);
-+ gaim2_signals_disconnect_by_handle(handle);
-+ gaim2_prefs_disconnect_by_handle(handle);
-
-- gaim_debug(GAIM_DEBUG_INFO, "docklet", "plugin unloaded\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "docklet", "plugin unloaded\n");
-
- return TRUE;
- }
-
- static GtkWidget *
--plugin_config_frame(GaimPlugin *plugin)
-+plugin_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *frame;
- GtkWidget *vbox;
-@@ -645,10 +645,10 @@ plugin_config_frame(GaimPlugin *plugin)
- frame = gtk_vbox_new(FALSE, 18);
- gtk_container_set_border_width(GTK_CONTAINER(frame), 12);
-
-- vbox = gaim_gtk_make_frame(frame, _("Blink tray icon for unread..."));
-+ vbox = gaim2_gtk_make_frame(frame, _("Blink tray icon for unread..."));
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
-- dd = gaim_gtk_prefs_dropdown(vbox, _("_Instant Messages:"),
-+ dd = gaim2_gtk_prefs_dropdown(vbox, _("_Instant Messages:"),
- GAIM_PREF_STRING, "/plugins/gtk/docklet/blink_im",
- _("Never"), "never",
- _("In hidden conversations"), "hidden",
-@@ -656,7 +656,7 @@ plugin_config_frame(GaimPlugin *plugin)
- NULL);
- gtk_size_group_add_widget(sg, dd);
-
-- dd = gaim_gtk_prefs_dropdown(vbox, _("C_hat Messages:"),
-+ dd = gaim2_gtk_prefs_dropdown(vbox, _("C_hat Messages:"),
- GAIM_PREF_STRING, "/plugins/gtk/docklet/blink_chat",
- _("Never"), "never",
- _("When my nick is said"), "nick",
-@@ -668,13 +668,13 @@ plugin_config_frame(GaimPlugin *plugin)
- return frame;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- plugin_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -689,10 +689,10 @@ static GaimPluginInfo info =
- N_("System Tray Icon"), /**< name */
- VERSION, /**< version */
- /** summary */
-- N_("Displays an icon for Gaim in the system tray."),
-+ N_("Displays an icon for Gaim2 in the system tray."),
- /** description */
- N_("Displays a system tray icon (in GNOME, KDE, or Windows for example) "
-- "to show the current status of Gaim, allow fast access to commonly "
-+ "to show the current status of Gaim2, allow fast access to commonly "
- "used functions, and to toggle display of the buddy list. "
- "Also provides options to blink for unread messages."),
- /** author */
-@@ -711,11 +711,11 @@ static GaimPluginInfo info =
- };
-
- static void
--plugin_init(GaimPlugin *plugin)
-+plugin_init(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk/docklet");
-- gaim_prefs_add_string("/plugins/gtk/docklet/blink_im", "hidden");
-- gaim_prefs_add_string("/plugins/gtk/docklet/blink_chat", "never");
-+ gaim2_prefs_add_none("/plugins/gtk/docklet");
-+ gaim2_prefs_add_string("/plugins/gtk/docklet/blink_im", "hidden");
-+ gaim2_prefs_add_string("/plugins/gtk/docklet/blink_chat", "never");
- }
-
- GAIM_INIT_PLUGIN(docklet, plugin_init, info)
-diff -prNu ./plugins/docklet/docklet.h ./plugins/docklet/docklet.h
---- ./plugins/docklet/docklet.h 2005-12-16 10:16:14.000000000 +0100
-+++ ./plugins/docklet/docklet.h 2006-01-05 15:27:48.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * System tray icon (aka docklet) plugin for Gaim
-+ * System tray icon (aka docklet) plugin for Gaim2
- *
- * Copyright (C) 2002-3 Robert McQueen <robot101@debian.org>
- * Copyright (C) 2003 Herman Bloggs <hermanator12002@yahoo.com>
-@@ -46,7 +46,7 @@ struct docklet_ui_ops
- };
-
- /* useful for setting idle callbacks that will be cleaned up */
--extern GaimPlugin *handle;
-+extern Gaim2Plugin *handle;
-
- /* functions in docklet.c */
- void docklet_clicked(int);
-diff -prNu ./plugins/docklet/docklet-win32.c ./plugins/docklet/docklet-win32.c
---- ./plugins/docklet/docklet-win32.c 2005-12-16 10:16:14.000000000 +0100
-+++ ./plugins/docklet/docklet-win32.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * System tray icon (aka docklet) plugin for Gaim
-+ * System tray icon (aka docklet) plugin for Gaim2
- *
- * Copyright (C) 2002-3 Robert McQueen <robot101@debian.org>
- * Copyright (C) 2003 Herman Bloggs <hermanator12002@yahoo.com>
-@@ -31,7 +31,7 @@
- #include "gtkprefs.h"
- #include "debug.h"
-
--#include "gaim.h"
-+#include "gaim2.h"
- #include "gtkdialogs.h"
-
- #include "resource.h"
-@@ -53,7 +53,7 @@ static HICON sysicon_away=0;
- static HICON sysicon_pend=0;
- static HICON sysicon_awypend=0;
- static HICON sysicon_blank=0;
--static NOTIFYICONDATA wgaim_nid;
-+static NOTIFYICONDATA wgaim2_nid;
-
-
- static LRESULT CALLBACK systray_mainmsg_handler(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam) {
-@@ -61,16 +61,16 @@ static LRESULT CALLBACK systray_mainmsg_
-
- switch(msg) {
- case WM_CREATE:
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "WM_CREATE\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "WM_CREATE\n");
- taskbarRestartMsg = RegisterWindowMessage("TaskbarCreated");
- break;
-
- case WM_TIMER:
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "WM_TIMER\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "WM_TIMER\n");
- break;
-
- case WM_DESTROY:
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "WM_DESTROY\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "WM_DESTROY\n");
- break;
-
- case WM_TRAYMESSAGE:
-@@ -94,7 +94,7 @@ static LRESULT CALLBACK systray_mainmsg_
- if (msg == taskbarRestartMsg) {
- /* explorer crashed and left us hanging...
- This will put the systray icon back in it's place, when it restarts */
-- Shell_NotifyIcon(NIM_ADD,&wgaim_nid);
-+ Shell_NotifyIcon(NIM_ADD,&wgaim2_nid);
- }
- break;
- }/* end switch */
-@@ -107,7 +107,7 @@ static HWND systray_create_hiddenwin() {
- WNDCLASSEX wcex;
- TCHAR wname[32];
-
-- strcpy(wname, "GaimWin");
-+ strcpy(wname, "Gaim2Win");
-
- wcex.cbSize = sizeof(WNDCLASSEX);
-
-@@ -115,7 +115,7 @@ static HWND systray_create_hiddenwin() {
- wcex.lpfnWndProc = (WNDPROC)systray_mainmsg_handler;
- wcex.cbClsExtra = 0;
- wcex.cbWndExtra = 0;
-- wcex.hInstance = wgaim_hinstance();
-+ wcex.hInstance = wgaim2_hinstance();
- wcex.hIcon = NULL;
- wcex.hCursor = NULL,
- wcex.hbrBackground = NULL;
-@@ -126,32 +126,32 @@ static HWND systray_create_hiddenwin() {
- RegisterClassEx(&wcex);
-
- /* Create the window */
-- return (CreateWindow(wname, "", 0, 0, 0, 0, 0, GetDesktopWindow(), NULL, wgaim_hinstance(), 0));
-+ return (CreateWindow(wname, "", 0, 0, 0, 0, 0, GetDesktopWindow(), NULL, wgaim2_hinstance(), 0));
- }
-
- static void systray_init_icon(HWND hWnd, HICON icon) {
-- ZeroMemory(&wgaim_nid,sizeof(wgaim_nid));
-- wgaim_nid.cbSize=sizeof(NOTIFYICONDATA);
-- wgaim_nid.hWnd=hWnd;
-- wgaim_nid.uID=0;
-- wgaim_nid.uFlags=NIF_ICON | NIF_MESSAGE | NIF_TIP;
-- wgaim_nid.uCallbackMessage=WM_TRAYMESSAGE;
-- wgaim_nid.hIcon=icon;
-- lstrcpy(wgaim_nid.szTip, "");
-- Shell_NotifyIcon(NIM_ADD,&wgaim_nid);
-+ ZeroMemory(&wgaim2_nid,sizeof(wgaim2_nid));
-+ wgaim2_nid.cbSize=sizeof(NOTIFYICONDATA);
-+ wgaim2_nid.hWnd=hWnd;
-+ wgaim2_nid.uID=0;
-+ wgaim2_nid.uFlags=NIF_ICON | NIF_MESSAGE | NIF_TIP;
-+ wgaim2_nid.uCallbackMessage=WM_TRAYMESSAGE;
-+ wgaim2_nid.hIcon=icon;
-+ lstrcpy(wgaim2_nid.szTip, "");
-+ Shell_NotifyIcon(NIM_ADD,&wgaim2_nid);
- docklet_embedded();
- }
-
- static void systray_change_icon(HICON icon) {
-- wgaim_nid.hIcon = icon;
-- Shell_NotifyIcon(NIM_MODIFY,&wgaim_nid);
-+ wgaim2_nid.hIcon = icon;
-+ Shell_NotifyIcon(NIM_MODIFY,&wgaim2_nid);
- }
-
- static void systray_remove_nid(void) {
-- Shell_NotifyIcon(NIM_DELETE,&wgaim_nid);
-+ Shell_NotifyIcon(NIM_DELETE,&wgaim2_nid);
- }
-
--static void wgaim_tray_update_icon(DockletStatus icon) {
-+static void wgaim2_tray_update_icon(DockletStatus icon) {
- switch (icon) {
- case DOCKLET_STATUS_OFFLINE:
- systray_change_icon(sysicon_disconn);
-@@ -173,32 +173,32 @@ static void wgaim_tray_update_icon(Dockl
- }
- }
-
--static void wgaim_tray_blank_icon() {
-+static void wgaim2_tray_blank_icon() {
- systray_change_icon(sysicon_blank);
- }
-
--static void wgaim_tray_set_tooltip(gchar *tooltip) {
-+static void wgaim2_tray_set_tooltip(gchar *tooltip) {
- if (tooltip) {
- char *locenc = NULL;
- locenc = g_locale_from_utf8(tooltip, -1, NULL, NULL, NULL);
-- lstrcpyn(wgaim_nid.szTip, locenc, sizeof(wgaim_nid.szTip)/sizeof(TCHAR));
-+ lstrcpyn(wgaim2_nid.szTip, locenc, sizeof(wgaim2_nid.szTip)/sizeof(TCHAR));
- g_free(locenc);
- } else {
-- lstrcpy(wgaim_nid.szTip, "");
-+ lstrcpy(wgaim2_nid.szTip, "");
- }
-- Shell_NotifyIcon(NIM_MODIFY, &wgaim_nid);
-+ Shell_NotifyIcon(NIM_MODIFY, &wgaim2_nid);
- }
-
--void wgaim_tray_minimize(GaimGtkBuddyList *gtkblist) {
-+void wgaim2_tray_minimize(Gaim2GtkBuddyList *gtkblist) {
- MinimizeWndToTray(GDK_WINDOW_HWND(gtkblist->window->window));
- }
-
--void wgaim_tray_maximize(GaimGtkBuddyList *gtkblist) {
-+void wgaim2_tray_maximize(Gaim2GtkBuddyList *gtkblist) {
- RestoreWndFromTray(GDK_WINDOW_HWND(gtkblist->window->window));
- }
-
-
--static void wgaim_tray_create() {
-+static void wgaim2_tray_create() {
- OSVERSIONINFO osinfo;
- /* dummy window to process systray messages */
- systray_hwnd = systray_create_hiddenwin();
-@@ -212,49 +212,49 @@ static void wgaim_tray_create() {
- * but will scale it back to 4-bits for display.
- * That is why we use custom 4-bit icons for pre XP Windowses */
- if (osinfo.dwMajorVersion == 5 && osinfo.dwMinorVersion > 0) {
-- sysicon_disconn = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_OFFLINE_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-- sysicon_conn = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-- sysicon_away = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_AWAY_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-- sysicon_pend = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_PEND_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-- sysicon_awypend = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_AWAYPEND_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-+ sysicon_disconn = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_OFFLINE_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-+ sysicon_conn = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-+ sysicon_away = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_AWAY_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-+ sysicon_pend = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_PEND_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-+ sysicon_awypend = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_AWAYPEND_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
- } else {
-- sysicon_disconn = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_OFFLINE_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-- sysicon_conn = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-- sysicon_away = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_AWAY_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-- sysicon_pend = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_PEND_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-- sysicon_awypend = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_AWAYPEND_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-+ sysicon_disconn = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_OFFLINE_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-+ sysicon_conn = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-+ sysicon_away = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_AWAY_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-+ sysicon_pend = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_PEND_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
-+ sysicon_awypend = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_AWAYPEND_TRAY_ICON_4BIT), IMAGE_ICON, 16, 16, 0);
- }
-- sysicon_blank = (HICON)LoadImage(wgaim_hinstance(), MAKEINTRESOURCE(GAIM_BLANK_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-+ sysicon_blank = (HICON)LoadImage(wgaim2_hinstance(), MAKEINTRESOURCE(GAIM_BLANK_TRAY_ICON), IMAGE_ICON, 16, 16, 0);
-
- /* Create icon in systray */
- systray_init_icon(systray_hwnd, sysicon_disconn);
-
-- gaim_signal_connect(gaim_gtk_blist_get_handle(), "gtkblist-hiding",
-- &handle, GAIM_CALLBACK(wgaim_tray_minimize), NULL);
-- gaim_signal_connect(gaim_gtk_blist_get_handle(), "gtkblist-unhiding",
-- &handle, GAIM_CALLBACK(wgaim_tray_maximize), NULL);
-+ gaim2_signal_connect(gaim2_gtk_blist_get_handle(), "gtkblist-hiding",
-+ &handle, GAIM_CALLBACK(wgaim2_tray_minimize), NULL);
-+ gaim2_signal_connect(gaim2_gtk_blist_get_handle(), "gtkblist-unhiding",
-+ &handle, GAIM_CALLBACK(wgaim2_tray_maximize), NULL);
-
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "created\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "created\n");
- }
-
--static void wgaim_tray_destroy() {
-- gaim_signals_disconnect_by_handle(&handle);
-+static void wgaim2_tray_destroy() {
-+ gaim2_signals_disconnect_by_handle(&handle);
- systray_remove_nid();
- DestroyWindow(systray_hwnd);
- docklet_remove();
- }
-
--static struct docklet_ui_ops wgaim_tray_ops =
-+static struct docklet_ui_ops wgaim2_tray_ops =
- {
-- wgaim_tray_create,
-- wgaim_tray_destroy,
-- wgaim_tray_update_icon,
-- wgaim_tray_blank_icon,
-- wgaim_tray_set_tooltip,
-+ wgaim2_tray_create,
-+ wgaim2_tray_destroy,
-+ wgaim2_tray_update_icon,
-+ wgaim2_tray_blank_icon,
-+ wgaim2_tray_set_tooltip,
- NULL
- };
-
- /* Used by docklet's plugin load func */
- void docklet_ui_init() {
-- docklet_set_ui_ops(&wgaim_tray_ops);
-+ docklet_set_ui_ops(&wgaim2_tray_ops);
- }
-diff -prNu ./plugins/docklet/docklet-x11.c ./plugins/docklet/docklet-x11.c
---- ./plugins/docklet/docklet-x11.c 2005-12-17 18:35:54.000000000 +0100
-+++ ./plugins/docklet/docklet-x11.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * System tray icon (aka docklet) plugin for Gaim
-+ * System tray icon (aka docklet) plugin for Gaim2
- *
- * Copyright (C) 2002-3 Robert McQueen <robot101@debian.org>
- * Copyright (C) 2003 Herman Bloggs <hermanator12002@yahoo.com>
-@@ -23,11 +23,11 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "debug.h"
- #include "gtkstock.h"
-
--#include "gaim.h"
-+#include "gaim2.h"
- #include "gtkdialogs.h"
-
- #include "eggtrayicon.h"
-@@ -56,7 +56,7 @@ docklet_x11_create_cb()
- static void
- docklet_x11_embedded_cb(GtkWidget *widget, void *data)
- {
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "embedded\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "embedded\n");
-
- g_source_remove(embed_timeout);
- embed_timeout = 0;
-@@ -66,7 +66,7 @@ docklet_x11_embedded_cb(GtkWidget *widge
- static void
- docklet_x11_destroyed_cb(GtkWidget *widget, void *data)
- {
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "destroyed\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "destroyed\n");
-
- docklet_remove();
-
-@@ -222,7 +222,7 @@ docklet_x11_destroy()
-
- image = NULL;
-
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "destroyed\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "destroyed\n");
- }
-
- static gboolean
-@@ -233,7 +233,7 @@ docklet_x11_embed_timeout_cb()
- * loaded so that it can embed automatically if/when a notification
- * area becomes available.
- */
-- gaim_debug_info("tray icon", "failed to embed within timeout\n");
-+ gaim2_debug_info("tray icon", "failed to embed within timeout\n");
- docklet_remove();
-
- return FALSE;
-@@ -248,11 +248,11 @@ docklet_x11_create()
- /* if this is being called when a tray icon exists, it's because
- something messed up. try destroying it before we proceed,
- although docklet_refcount may be all hosed. hopefully won't happen. */
-- gaim_debug(GAIM_DEBUG_WARNING, "tray icon", "trying to create icon but it already exists?\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "tray icon", "trying to create icon but it already exists?\n");
- docklet_x11_destroy();
- }
-
-- docklet = egg_tray_icon_new("Gaim");
-+ docklet = egg_tray_icon_new("Gaim2");
- box = gtk_event_box_new();
- image = gtk_image_new();
-
-@@ -281,7 +281,7 @@ docklet_x11_create()
- docklet_embedded();
- embed_timeout = g_timeout_add(EMBED_TIMEOUT, docklet_x11_embed_timeout_cb, NULL);
-
-- gaim_debug(GAIM_DEBUG_INFO, "tray icon", "created\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "tray icon", "created\n");
- }
-
- static struct docklet_ui_ops ui_ops =
-diff -prNu ./plugins/docklet/Makefile.am ./plugins/docklet/Makefile.am
---- ./plugins/docklet/Makefile.am 2005-10-22 03:18:06.000000000 +0200
-+++ ./plugins/docklet/Makefile.am 2006-01-05 13:15:21.000000000 +0100
-@@ -4,7 +4,7 @@ EXTRA_DIST = \
- MinimizeToTray.c \
- MinimizeToTray.h
-
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- docklet_la_LDFLAGS = -module -avoid-version $(GTK_LIBS)
-
-diff -prNu ./plugins/extplacement.c ./plugins/extplacement.c
---- ./plugins/extplacement.c 2005-12-21 19:36:09.000000000 +0100
-+++ ./plugins/extplacement.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * Extra conversation placement options for Gaim
-+ * Extra conversation placement options for Gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -21,7 +21,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "conversation.h"
- #include "version.h"
- #include "gtkplugin.h"
-@@ -29,99 +29,99 @@
- #include "gtkconvwin.h"
-
- static void
--conv_placement_by_number(GaimGtkConversation *conv)
-+conv_placement_by_number(Gaim2GtkConversation *conv)
- {
-- GaimGtkWindow *win = NULL;
-+ Gaim2GtkWindow *win = NULL;
- GList *wins = NULL;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/extplacement/placement_number_separate"))
-- win = gaim_gtk_conv_window_last_with_type(gaim_conversation_get_type(conv->active_conv));
-- else if ((wins = gaim_gtk_conv_windows_get_list()) != NULL)
-+ if (gaim2_prefs_get_bool("/plugins/gtk/extplacement/placement_number_separate"))
-+ win = gaim2_gtk_conv_window_last_with_type(gaim2_conversation_get_type(conv->active_conv));
-+ else if ((wins = gaim2_gtk_conv_windows_get_list()) != NULL)
- win = g_list_last(wins)->data;
-
- if (win == NULL) {
-- win = gaim_gtk_conv_window_new();
-+ win = gaim2_gtk_conv_window_new();
-
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-- gaim_gtk_conv_window_show(win);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_show(win);
- } else {
-- int max_count = gaim_prefs_get_int("/plugins/gtk/extplacement/placement_number");
-- int count = gaim_gtk_conv_window_get_gtkconv_count(win);
-+ int max_count = gaim2_prefs_get_int("/plugins/gtk/extplacement/placement_number");
-+ int count = gaim2_gtk_conv_window_get_gtkconv_count(win);
-
- if (count < max_count)
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
- else {
- GList *l = NULL;
-
-- for (l = gaim_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
-+ for (l = gaim2_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
- win = l->data;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/extplacement/placement_number_separate") &&
-- gaim_conversation_get_type(gaim_gtk_conv_window_get_active_conversation(win)) != gaim_conversation_get_type(conv->active_conv))
-+ if (gaim2_prefs_get_bool("/plugins/gtk/extplacement/placement_number_separate") &&
-+ gaim2_conversation_get_type(gaim2_gtk_conv_window_get_active_conversation(win)) != gaim2_conversation_get_type(conv->active_conv))
- continue;
-
-- count = gaim_gtk_conv_window_get_gtkconv_count(win);
-+ count = gaim2_gtk_conv_window_get_gtkconv_count(win);
- if (count < max_count) {
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
- return;
- }
- }
-- win = gaim_gtk_conv_window_new();
-+ win = gaim2_gtk_conv_window_new();
-
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-- gaim_gtk_conv_window_show(win);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_show(win);
- }
- }
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- gaim_gtkconv_placement_add_fnc("number", _("By conversation count"),
-+ gaim2_gtkconv_placement_add_fnc("number", _("By conversation count"),
- &conv_placement_by_number);
-- gaim_prefs_trigger_callback("/gaim/gtk/conversations/placement");
-+ gaim2_prefs_trigger_callback("/gaim2/gtk/conversations/placement");
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
-- gaim_gtkconv_placement_remove_fnc("number");
-- gaim_prefs_trigger_callback("/gaim/gtk/conversations/placement");
-+ gaim2_gtkconv_placement_remove_fnc("number");
-+ gaim2_prefs_trigger_callback("/gaim2/gtk/conversations/placement");
- return TRUE;
- }
-
--static GaimPluginPrefFrame *
--get_plugin_pref_frame(GaimPlugin *plugin) {
-- GaimPluginPrefFrame *frame;
-- GaimPluginPref *ppref;
-+static Gaim2PluginPrefFrame *
-+get_plugin_pref_frame(Gaim2Plugin *plugin) {
-+ Gaim2PluginPrefFrame *frame;
-+ Gaim2PluginPref *ppref;
-
-- frame = gaim_plugin_pref_frame_new();
-+ frame = gaim2_plugin_pref_frame_new();
-
-- ppref = gaim_plugin_pref_new_with_label(_("Conversation Placement"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label(_("Conversation Placement"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/gtk/extplacement/placement_number",
- _("Number of conversations per window"));
-- gaim_plugin_pref_set_bounds(ppref, 1, 50);
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_set_bounds(ppref, 1, 50);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/gtk/extplacement/placement_number_separate",
- _("Separate IM and Chat windows when placing by number"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
- return frame;
- }
-
--static GaimPluginUiInfo prefs_info = {
-+static Gaim2PluginUiInfo prefs_info = {
- get_plugin_pref_frame,
- 0, /* page_num (Reserved) */
- NULL /* frame (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -150,11 +150,11 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk/extplacement");
-- gaim_prefs_add_int("/plugins/gtk/extplacement/placement_number", 4);
-- gaim_prefs_add_bool("/plugins/gtk/extplacement/placement_number_separate", FALSE);
-+ gaim2_prefs_add_none("/plugins/gtk/extplacement");
-+ gaim2_prefs_add_int("/plugins/gtk/extplacement/placement_number", 4);
-+ gaim2_prefs_add_bool("/plugins/gtk/extplacement/placement_number_separate", FALSE);
- }
-
- GAIM_INIT_PLUGIN(extplacement, init_plugin, info)
-diff -prNu ./plugins/filectl.c ./plugins/filectl.c
---- ./plugins/filectl.c 2005-12-08 21:55:48.000000000 +0100
-+++ ./plugins/filectl.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /**
-- * Send commands to Gaim via ~/.gaim/control
-+ * Send commands to Gaim2 via ~/.gaim2/control
- *
- * Originally by Eric Warmenhoven <eric@warmenhoven.org>
- * Compile fixes/mini hacks Alex Bennee <alex@bennee.com>
-@@ -45,7 +45,7 @@ run_commands()
- char *command, *arg1, *arg2;
- FILE *file;
-
-- sprintf(filename, "%s" G_DIR_SEPARATOR_S "control", gaim_user_dir());
-+ sprintf(filename, "%s" G_DIR_SEPARATOR_S "control", gaim2_user_dir());
-
- file = g_fopen(filename, "r+");
- while (fgets(buffer, sizeof(buffer), file)) {
-@@ -53,50 +53,50 @@ run_commands()
- /* Read the next command */
- if (buffer[strlen(buffer) - 1] == '\n')
- buffer[strlen(buffer) - 1] = 0;
-- gaim_debug_misc("filectl", "read: %s\n", buffer);
-+ gaim2_debug_misc("filectl", "read: %s\n", buffer);
- command = getarg(buffer, 0, 0);
-
- if (!strncasecmp(command, "login", 6)) {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- arg1 = getarg(buffer, 1, 0);
- arg2 = getarg(buffer, 2, 1);
-
-- account = gaim_accounts_find(arg1, arg2);
-+ account = gaim2_accounts_find(arg1, arg2);
- if (account != NULL) /* username found */
-- gaim_account_connect(account);
-+ gaim2_account_connect(account);
-
- free(arg1);
- free(arg2);
-
- } else if (!strncasecmp(command, "logout", 7)) {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- arg1 = getarg(buffer, 1, 1);
- arg2 = getarg(buffer, 2, 1);
-
-- account = gaim_accounts_find(arg1, arg2);
-+ account = gaim2_accounts_find(arg1, arg2);
- if (account != NULL)
- {
-- gaim_account_disconnect(account);
-+ gaim2_account_disconnect(account);
- }
- else if (arg1 == NULL)
-- gaim_connections_disconnect_all();
-+ gaim2_connections_disconnect_all();
-
- free(arg1);
- free(arg2);
-
- } else if (!strncasecmp(command, "send", 4)) {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- arg1 = getarg(buffer, 1, 0);
- arg2 = getarg(buffer, 2, 1);
-
-- conv = gaim_find_conversation(GAIM_CONV_TYPE_ANY, arg1);
-+ conv = gaim2_find_conversation(GAIM_CONV_TYPE_ANY, arg1);
- if (conv != NULL)
- {
- /*
-- gaim_conversation_write(conv, arg2, WFLAG_SEND, NULL, time(NULL), -1);
-+ gaim2_conversation_write(conv, arg2, WFLAG_SEND, NULL, time(NULL), -1);
- serv_send_im(conv->gc, arg1, arg2, 0);
- */
- }
-@@ -110,16 +110,16 @@ run_commands()
- free(arg1);
-
- } else if (!strncasecmp(command, "hide", 4)) {
-- gaim_blist_set_visible(FALSE);
-+ gaim2_blist_set_visible(FALSE);
-
- } else if (!strncasecmp(command, "unhide", 6)) {
-- gaim_blist_set_visible(TRUE);
-+ gaim2_blist_set_visible(TRUE);
-
- } else if (!strncasecmp(command, "back", 4)) {
- /* do_im_back(); */
-
- } else if (!strncasecmp(command, "quit", 4)) {
-- gaim_core_quit();
-+ gaim2_core_quit();
-
- }
-
-@@ -143,7 +143,7 @@ init_file()
- struct stat finfo;
- char filename[256];
-
-- sprintf(filename, "%s" G_DIR_SEPARATOR_S "control", gaim_user_dir());
-+ sprintf(filename, "%s" G_DIR_SEPARATOR_S "control", gaim2_user_dir());
-
- if ((g_stat(filename, &finfo) == 0) && (finfo.st_size > 0))
- run_commands();
-@@ -159,12 +159,12 @@ check_file()
- struct stat finfo;
- char filename[256];
-
-- sprintf(filename, "%s" G_DIR_SEPARATOR_S "control", gaim_user_dir());
-+ sprintf(filename, "%s" G_DIR_SEPARATOR_S "control", gaim2_user_dir());
-
- if ((g_stat(filename, &finfo) == 0) && (finfo.st_size > 0))
- {
- if (mtime != finfo.st_mtime) {
-- gaim_debug_info("filectl", "control changed, checking\n");
-+ gaim2_debug_info("filectl", "control changed, checking\n");
- run_commands();
- }
- }
-@@ -214,23 +214,23 @@ getarg(char *line, int which, int remain
- */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- init_file();
-- check = gaim_timeout_add(5000, (GSourceFunc)check_file, NULL);
-+ check = gaim2_timeout_add(5000, (GSourceFunc)check_file, NULL);
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
-- gaim_timeout_remove(check);
-+ gaim2_timeout_remove(check);
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -242,12 +242,12 @@ static GaimPluginInfo info =
- GAIM_PRIORITY_DEFAULT, /**< priority */
-
- FILECTL_PLUGIN_ID, /**< id */
-- N_("Gaim File Control"), /**< name */
-+ N_("Gaim2 File Control"), /**< name */
- VERSION, /**< version */
- /** summary */
-- N_("Allows you to control Gaim by entering commands in a file."),
-+ N_("Allows you to control Gaim2 by entering commands in a file."),
- /** description */
-- N_("Allows you to control Gaim by entering commands in a file."),
-+ N_("Allows you to control Gaim2 by entering commands in a file."),
- "Eric Warmenhoven <eric@warmenhoven.org>", /**< author */
- GAIM_WEBSITE, /**< homepage */
-
-@@ -260,7 +260,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/gaiminc.c ./plugins/gaiminc.c
---- ./plugins/gaiminc.c 2005-08-25 04:33:44.000000000 +0200
-+++ ./plugins/gaiminc.c 2006-01-05 15:27:38.000000000 +0100
-@@ -6,22 +6,22 @@
- #include "conversation.h"
- #include "version.h"
-
--/* include UI for gaim_gtkdialogs_about() */
-+/* include UI for gaim2_gtkdialogs_about() */
- #include "gtkplugin.h"
- #include "gtkdialogs.h"
-
--#define GAIMINC_PLUGIN_ID "core-gaiminc"
-+#define GAIMINC_PLUGIN_ID "core-gaim2inc"
-
- static void
--echo_hi(GaimConnection *gc)
-+echo_hi(Gaim2Connection *gc)
- {
- /* this doesn't do much, just lets you know who we are :) */
-- gaim_gtkdialogs_about(NULL, NULL);
-+ gaim2_gtkdialogs_about(NULL, NULL);
- }
-
- static gboolean
--reverse(GaimAccount *account, char **who, char **message,
-- GaimConversation *conv, int *flags)
-+reverse(Gaim2Account *account, char **who, char **message,
-+ Gaim2Conversation *conv, int *flags)
- {
- /* this will drive you insane. whenever you receive a message,
- * the text of the message (HTML and all) will be reversed. */
-@@ -34,7 +34,7 @@ reverse(GaimAccount *account, char **who
-
- l = strlen(*message);
-
-- if (!strcmp(*who, gaim_account_get_username(account)))
-+ if (!strcmp(*who, gaim2_account_get_username(account)))
- return FALSE;
-
- for (i = 0; i < l/2; i++) {
-@@ -46,12 +46,12 @@ reverse(GaimAccount *account, char **who
- }
-
- static void
--bud(GaimBuddy *who)
-+bud(Gaim2Buddy *who)
- {
-- GaimAccount *acct = who->account;
-- GaimConversation *conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, acct, who->name);
-+ Gaim2Account *acct = who->account;
-+ Gaim2Conversation *conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, acct, who->name);
-
-- gaim_conv_im_send(GAIM_CONV_IM(conv), "Hello!");
-+ gaim2_conv_im_send(GAIM_CONV_IM(conv), "Hello!");
- }
-
- /*
-@@ -59,24 +59,24 @@ bud(GaimBuddy *who)
- */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- /* this is for doing something fun when we sign on */
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- plugin, GAIM_CALLBACK(echo_hi), NULL);
-
- /* this is for doing something fun when we get a message */
-- gaim_signal_connect(gaim_conversations_get_handle(), "receiving-im-msg",
-+ gaim2_signal_connect(gaim2_conversations_get_handle(), "receiving-im-msg",
- plugin, GAIM_CALLBACK(reverse), NULL);
-
- /* this is for doing something fun when a buddy comes online */
-- gaim_signal_connect(gaim_blist_get_handle(), "buddy-signed-on",
-+ gaim2_signal_connect(gaim2_blist_get_handle(), "buddy-signed-on",
- plugin, GAIM_CALLBACK(bud), NULL);
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -88,7 +88,7 @@ static GaimPluginInfo info =
- GAIM_PRIORITY_DEFAULT, /**< priority */
-
- GAIMINC_PLUGIN_ID, /**< id */
-- N_("Gaim Demonstration Plugin"), /**< name */
-+ N_("Gaim2 Demonstration Plugin"), /**< name */
- VERSION, /**< version */
- /** summary */
- N_("An example plugin that does stuff - see the description."),
-@@ -110,8 +110,8 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
--GAIM_INIT_PLUGIN(gaiminc, init_plugin, info)
-+GAIM_INIT_PLUGIN(gaim2inc, init_plugin, info)
-diff -prNu ./plugins/gaimrc.c ./plugins/gaimrc.c
---- ./plugins/gaimrc.c 2005-12-21 19:36:09.000000000 +0100
-+++ ./plugins/gaimrc.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /**
-- * @file gaimrc.c Gaim gtk resource control plugin.
-+ * @file gaim2rc.c Gaim2 gtk resource control plugin.
- *
- * Copyright (C) 2005 Etan Reisner <deryni@eden.rutgers.edu>
- *
-@@ -28,14 +28,14 @@
- static guint pref_callback;
-
- static const char *color_prefs[] = {
-- "/plugins/gtk/gaimrc/color/GtkWidget::cursor-color",
-- "/plugins/gtk/gaimrc/color/GtkWidget::secondary-cursor-color",
-- "/plugins/gtk/gaimrc/color/GtkIMHtml::hyperlink-color"
-+ "/plugins/gtk/gaim2rc/color/GtkWidget::cursor-color",
-+ "/plugins/gtk/gaim2rc/color/GtkWidget::secondary-cursor-color",
-+ "/plugins/gtk/gaim2rc/color/GtkIMHtml::hyperlink-color"
- };
- static const char *color_prefs_set[] = {
-- "/plugins/gtk/gaimrc/set/color/GtkWidget::cursor-color",
-- "/plugins/gtk/gaimrc/set/color/GtkWidget::secondary-cursor-color",
-- "/plugins/gtk/gaimrc/set/color/GtkIMHtml::hyperlink-color"
-+ "/plugins/gtk/gaim2rc/set/color/GtkWidget::cursor-color",
-+ "/plugins/gtk/gaim2rc/set/color/GtkWidget::secondary-cursor-color",
-+ "/plugins/gtk/gaim2rc/set/color/GtkIMHtml::hyperlink-color"
- };
- static const char *color_names[] = {
- N_("Cursor Color"),
-@@ -45,14 +45,14 @@ static const char *color_names[] = {
- static GtkWidget *color_widgets[G_N_ELEMENTS(color_prefs)];
-
- static const char *widget_size_prefs[] = {
-- "/plugins/gtk/gaimrc/size/GtkTreeView::expander_size",
-- "/plugins/gtk/gaimrc/size/GtkTreeView::indent_expanders",
-- "/plugins/gtk/gaimrc/size/GtkTreeView::horizontal_separator"
-+ "/plugins/gtk/gaim2rc/size/GtkTreeView::expander_size",
-+ "/plugins/gtk/gaim2rc/size/GtkTreeView::indent_expanders",
-+ "/plugins/gtk/gaim2rc/size/GtkTreeView::horizontal_separator"
- };
- static const char *widget_size_prefs_set[] = {
-- "/plugins/gtk/gaimrc/set/size/GtkTreeView::expander_size",
-- "/plugins/gtk/gaimrc/set/size/GtkTreeView::indent_expanders",
-- "/plugins/gtk/gaimrc/set/size/GtkTreeView::horizontal_separator"
-+ "/plugins/gtk/gaim2rc/set/size/GtkTreeView::expander_size",
-+ "/plugins/gtk/gaim2rc/set/size/GtkTreeView::indent_expanders",
-+ "/plugins/gtk/gaim2rc/set/size/GtkTreeView::horizontal_separator"
- };
- static const char *widget_size_names[] = {
- N_("GtkTreeView Expander Size"),
-@@ -62,18 +62,18 @@ static const char *widget_size_names[] =
- static GtkWidget *widget_size_widgets[G_N_ELEMENTS(widget_size_prefs)];
-
- static const char *font_prefs[] = {
-- "/plugins/gtk/gaimrc/font/*gaim_gtkconv_entry",
-- "/plugins/gtk/gaimrc/font/*gaim_gtkconv_imhtml",
-- "/plugins/gtk/gaimrc/font/*gaim_gtklog_imhtml",
-- "/plugins/gtk/gaimrc/font/*gaim_gtkrequest_imhtml",
-- "/plugins/gtk/gaimrc/font/*gaim_gtknotify_imhtml",
-+ "/plugins/gtk/gaim2rc/font/*gaim2_gtkconv_entry",
-+ "/plugins/gtk/gaim2rc/font/*gaim2_gtkconv_imhtml",
-+ "/plugins/gtk/gaim2rc/font/*gaim2_gtklog_imhtml",
-+ "/plugins/gtk/gaim2rc/font/*gaim2_gtkrequest_imhtml",
-+ "/plugins/gtk/gaim2rc/font/*gaim2_gtknotify_imhtml",
- };
- static const char *font_prefs_set[] = {
-- "/plugins/gtk/gaimrc/set/font/*gaim_gtkconv_entry",
-- "/plugins/gtk/gaimrc/set/font/*gaim_gtkconv_imhtml",
-- "/plugins/gtk/gaimrc/set/font/*gaim_gtklog_imhtml",
-- "/plugins/gtk/gaimrc/set/font/*gaim_gtkrequest_imhtml",
-- "/plugins/gtk/gaimrc/set/font/*gaim_gtknotify_imhtml",
-+ "/plugins/gtk/gaim2rc/set/font/*gaim2_gtkconv_entry",
-+ "/plugins/gtk/gaim2rc/set/font/*gaim2_gtkconv_imhtml",
-+ "/plugins/gtk/gaim2rc/set/font/*gaim2_gtklog_imhtml",
-+ "/plugins/gtk/gaim2rc/set/font/*gaim2_gtkrequest_imhtml",
-+ "/plugins/gtk/gaim2rc/set/font/*gaim2_gtknotify_imhtml",
- };
- static const char *font_names[] = {
- N_("Conversation Entry"),
-@@ -85,56 +85,56 @@ static const char *font_names[] = {
- static GtkWidget *font_widgets[G_N_ELEMENTS(font_prefs)];
-
- static void
--gaimrc_make_changes()
-+gaim2rc_make_changes()
- {
- int i;
- GString *style_string = g_string_new("");
- char *prefbase = NULL;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/gaimrc/set/gtk-font-name")) {
-- const char *pref = gaim_prefs_get_string("/plugins/gtk/gaimrc/gtk-font-name");
-+ if (gaim2_prefs_get_bool("/plugins/gtk/gaim2rc/set/gtk-font-name")) {
-+ const char *pref = gaim2_prefs_get_string("/plugins/gtk/gaim2rc/gtk-font-name");
- g_string_append_printf(style_string, "gtk-font-name = \"%s\"\n", pref);
- }
-
-- if (gaim_prefs_get_bool("/plugins/gtk/gaimrc/set/gtk-key-theme-name")) {
-- const char *pref = gaim_prefs_get_string("/plugins/gtk/gaimrc/gtk-key-theme-name");
-+ if (gaim2_prefs_get_bool("/plugins/gtk/gaim2rc/set/gtk-key-theme-name")) {
-+ const char *pref = gaim2_prefs_get_string("/plugins/gtk/gaim2rc/gtk-key-theme-name");
- g_string_append_printf(style_string, "gtk-key-theme-name = \"%s\"\n", pref);
- }
-
-- g_string_append(style_string, "style \"gaimrc_style\" {\n");
-+ g_string_append(style_string, "style \"gaim2rc_style\" {\n");
-
- for (i = 0; i < G_N_ELEMENTS(color_prefs); i++) {
-- if (gaim_prefs_get_bool(color_prefs_set[i])) {
-+ if (gaim2_prefs_get_bool(color_prefs_set[i])) {
- prefbase = g_path_get_basename(color_prefs[i]);
- g_string_append_printf(style_string,
- "%s = \"%s\"\n", prefbase,
-- gaim_prefs_get_string(color_prefs[i]));
-+ gaim2_prefs_get_string(color_prefs[i]));
- g_free(prefbase);
- }
- }
-
- for (i = 0; i < G_N_ELEMENTS(widget_size_prefs); i++) {
-- if (gaim_prefs_get_bool(widget_size_prefs_set[i])) {
-+ if (gaim2_prefs_get_bool(widget_size_prefs_set[i])) {
- prefbase = g_path_get_basename(widget_size_prefs[i]);
- g_string_append_printf(style_string,
- "%s = %d\n", prefbase,
-- gaim_prefs_get_int(widget_size_prefs[i]));
-+ gaim2_prefs_get_int(widget_size_prefs[i]));
- g_free(prefbase);
- }
- }
-
- g_string_append(style_string, "}");
-- g_string_append(style_string, "widget_class \"*\" style \"gaimrc_style\"\n");
-+ g_string_append(style_string, "widget_class \"*\" style \"gaim2rc_style\"\n");
-
- for (i = 0; i < G_N_ELEMENTS(font_prefs); i++) {
-- if (gaim_prefs_get_bool(font_prefs_set[i])) {
-+ if (gaim2_prefs_get_bool(font_prefs_set[i])) {
- prefbase = g_path_get_basename(font_prefs[i]);
- g_string_append_printf(style_string,
- "style \"%s_style\"\n"
- "{font_name = \"%s\"}\n"
- "widget \"%s\""
- "style \"%s_style\"\n", prefbase,
-- gaim_prefs_get_string(font_prefs[i]),
-+ gaim2_prefs_get_string(font_prefs[i]),
- prefbase, prefbase);
- g_free(prefbase);
- }
-@@ -146,76 +146,76 @@ gaimrc_make_changes()
- }
-
- static void
--gaimrc_write(GtkWidget *widget, gpointer data)
-+gaim2rc_write(GtkWidget *widget, gpointer data)
- {
- int i;
- GString *style_string = g_string_new("");
- char *prefbase = NULL;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/gaimrc/set/gtk-font-name")) {
-- const char *pref = gaim_prefs_get_string("/plugins/gtk/gaimrc/gtk-font-name");
-+ if (gaim2_prefs_get_bool("/plugins/gtk/gaim2rc/set/gtk-font-name")) {
-+ const char *pref = gaim2_prefs_get_string("/plugins/gtk/gaim2rc/gtk-font-name");
- g_string_append_printf(style_string, "gtk-font-name = \"%s\"\n", pref);
- }
-
-- if (gaim_prefs_get_bool("/plugins/gtk/gaimrc/set/gtk-key-theme-name")) {
-- const char *pref = gaim_prefs_get_string("/plugins/gtk/gaimrc/gtk-key-theme-name");
-+ if (gaim2_prefs_get_bool("/plugins/gtk/gaim2rc/set/gtk-key-theme-name")) {
-+ const char *pref = gaim2_prefs_get_string("/plugins/gtk/gaim2rc/gtk-key-theme-name");
- g_string_append_printf(style_string, "gtk-key-theme-name = \"%s\"\n", pref);
- }
-
-- g_string_append(style_string, "style \"gaimrc_style\" {\n");
-+ g_string_append(style_string, "style \"gaim2rc_style\" {\n");
-
- for (i = 0; i < G_N_ELEMENTS(color_prefs); i++) {
-- if (gaim_prefs_get_bool(color_prefs_set[i])) {
-+ if (gaim2_prefs_get_bool(color_prefs_set[i])) {
- prefbase = g_path_get_basename(color_prefs[i]);
- g_string_append_printf(style_string,
- "%s = \"%s\"\n", prefbase,
-- gaim_prefs_get_string(color_prefs[i]));
-+ gaim2_prefs_get_string(color_prefs[i]));
- g_free(prefbase);
- }
- }
-
- for (i = 0; i < G_N_ELEMENTS(widget_size_prefs); i++) {
-- if (gaim_prefs_get_bool(widget_size_prefs_set[i])) {
-+ if (gaim2_prefs_get_bool(widget_size_prefs_set[i])) {
- prefbase = g_path_get_basename(widget_size_prefs[i]);
- g_string_append_printf(style_string,
- "%s = %d\n", prefbase,
-- gaim_prefs_get_int(widget_size_prefs[i]));
-+ gaim2_prefs_get_int(widget_size_prefs[i]));
- g_free(prefbase);
- }
- }
-
- g_string_append(style_string, "}");
-- g_string_append(style_string, "widget_class \"*\" style \"gaimrc_style\"\n");
-+ g_string_append(style_string, "widget_class \"*\" style \"gaim2rc_style\"\n");
-
- for (i = 0; i < G_N_ELEMENTS(font_prefs); i++) {
-- if (gaim_prefs_get_bool(font_prefs_set[i])) {
-+ if (gaim2_prefs_get_bool(font_prefs_set[i])) {
- prefbase = g_path_get_basename(font_prefs[i]);
- g_string_append_printf(style_string,
- "style \"%s_style\"\n"
- "{font_name = \"%s\"}\n"
- "widget \"%s\""
- "style \"%s_style\"\n", prefbase,
-- gaim_prefs_get_string(font_prefs[i]),
-+ gaim2_prefs_get_string(font_prefs[i]),
- prefbase, prefbase);
- g_free(prefbase);
- }
- }
-
-- gaim_util_write_data_to_file("gtkrc-2.0", style_string->str, -1);
-+ gaim2_util_write_data_to_file("gtkrc-2.0", style_string->str, -1);
-
- g_string_free(style_string, TRUE);
- }
-
- static void
--gaimrc_reread(GtkWidget *widget, gpointer data)
-+gaim2rc_reread(GtkWidget *widget, gpointer data)
- {
- gtk_rc_reparse_all();
- /* I don't know if this is necessary but it shouldn't hurt. */
-- gaimrc_make_changes();
-+ gaim2rc_make_changes();
- }
-
- static void
--gaimrc_pref_changed_cb(const char *name, GaimPrefType type, gpointer value,
-+gaim2rc_pref_changed_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GString *style_string = g_string_new("");
-@@ -223,24 +223,24 @@ gaimrc_pref_changed_cb(const char *name,
-
- prefbase = g_path_get_basename(name);
-
-- if (strncmp(name, "/plugins/gtk/gaimrc/color", 25) == 0) {
-+ if (strncmp(name, "/plugins/gtk/gaim2rc/color", 25) == 0) {
- g_string_printf(style_string,
-- "style \"gaimrc_style\" { %s = \"%s\" }"
-- "widget_class \"*\" style \"gaimrc_style\"",
-+ "style \"gaim2rc_style\" { %s = \"%s\" }"
-+ "widget_class \"*\" style \"gaim2rc_style\"",
- prefbase, (char *)value);
-- } else if (strncmp(name, "/plugins/gtk/gaimrc/size", 24) == 0) {
-+ } else if (strncmp(name, "/plugins/gtk/gaim2rc/size", 24) == 0) {
- g_string_printf(style_string,
-- "style \"gaimrc_style\" { %s = \"%d\" }"
-- "widget_class \"*\" style \"gaimrc_style\"",
-+ "style \"gaim2rc_style\" { %s = \"%d\" }"
-+ "widget_class \"*\" style \"gaim2rc_style\"",
- prefbase, GPOINTER_TO_INT(value));
-- } else if (strncmp(name, "/plugins/gtk/gaimrc/font", 24) == 0) {
-+ } else if (strncmp(name, "/plugins/gtk/gaim2rc/font", 24) == 0) {
- g_string_printf(style_string, "style \"%s_style\""
- "{ font_name = \"%s\" } widget \"%s\""
- "style \"%s_style\"",
- prefbase, (char *)value, prefbase, prefbase);
-- } else if (strncmp(name, "/plugins/gtk/gaimrc/set", 23) == 0) {
-+ } else if (strncmp(name, "/plugins/gtk/gaim2rc/set", 23) == 0) {
- if (value)
-- gaimrc_make_changes();
-+ gaim2rc_make_changes();
- g_string_free(style_string, TRUE);
- g_free(prefbase);
-
-@@ -256,7 +256,7 @@ gaimrc_pref_changed_cb(const char *name,
- }
-
- static void
--gaimrc_color_response(GtkDialog *color_dialog, gint response, gpointer data)
-+gaim2rc_color_response(GtkDialog *color_dialog, gint response, gpointer data)
- {
- int subscript = GPOINTER_TO_INT(data);
-
-@@ -270,13 +270,13 @@ gaimrc_color_response(GtkDialog *color_d
- g_snprintf(colorstr, sizeof(colorstr), "#%02X%02X%02X",
- color.red/256, color.green/256, color.blue/256);
-
-- gaim_prefs_set_string(color_prefs[subscript], colorstr);
-+ gaim2_prefs_set_string(color_prefs[subscript], colorstr);
- }
- gtk_widget_destroy(GTK_WIDGET(color_dialog));
- }
-
- static void
--gaimrc_set_color(GtkWidget *widget, gpointer data)
-+gaim2rc_set_color(GtkWidget *widget, gpointer data)
- {
- GtkWidget *color_dialog = NULL;
- GdkColor color;
-@@ -287,9 +287,9 @@ gaimrc_set_color(GtkWidget *widget, gpoi
- _(color_names[GPOINTER_TO_INT(data)]));
- color_dialog = gtk_color_selection_dialog_new(_("Select Color"));
- g_signal_connect(G_OBJECT(color_dialog), "response",
-- G_CALLBACK(gaimrc_color_response), data);
-+ G_CALLBACK(gaim2rc_color_response), data);
-
-- if (gdk_color_parse(gaim_prefs_get_string(color_prefs[subscript]),
-+ if (gdk_color_parse(gaim2_prefs_get_string(color_prefs[subscript]),
- &color)) {
- gtk_color_selection_set_current_color(GTK_COLOR_SELECTION(GTK_COLOR_SELECTION_DIALOG(color_dialog)->colorsel), &color);
- }
-@@ -298,7 +298,7 @@ gaimrc_set_color(GtkWidget *widget, gpoi
- }
-
- static void
--gaimrc_font_response(GtkDialog *font_dialog, gint response, gpointer data)
-+gaim2rc_font_response(GtkDialog *font_dialog, gint response, gpointer data)
- {
- int subscript = GPOINTER_TO_INT(data);
-
-@@ -307,14 +307,14 @@ gaimrc_font_response(GtkDialog *font_dia
-
- fontname = gtk_font_selection_dialog_get_font_name(GTK_FONT_SELECTION_DIALOG(font_dialog));
-
-- gaim_prefs_set_string(font_prefs[subscript], fontname);
-+ gaim2_prefs_set_string(font_prefs[subscript], fontname);
- g_free(fontname);
- }
- gtk_widget_destroy(GTK_WIDGET(font_dialog));
- }
-
- static void
--gaimrc_set_font(GtkWidget *widget, gpointer data)
-+gaim2rc_set_font(GtkWidget *widget, gpointer data)
- {
- GtkWidget *font_dialog = NULL;
- char title[128];
-@@ -324,12 +324,12 @@ gaimrc_set_font(GtkWidget *widget, gpoin
- _(font_names[subscript]));
- font_dialog = gtk_font_selection_dialog_new(title);
- g_signal_connect(G_OBJECT(font_dialog), "response",
-- G_CALLBACK(gaimrc_font_response), data);
-+ G_CALLBACK(gaim2rc_font_response), data);
-
- /* TODO Figure out a way to test for the presence of a value in the
- * actual pref
-- if (gaim_prefs_get_bool(font_prefs[subscript])) {
-- gtk_font_selection_set_font_name(GTK_FONT_SELECTION(GTK_FONT_SELECTION_DIALOG(font_dialog)->fontsel), gaim_prefs_get_string(font_prefs[subscript]));
-+ if (gaim2_prefs_get_bool(font_prefs[subscript])) {
-+ gtk_font_selection_set_font_name(GTK_FONT_SELECTION(GTK_FONT_SELECTION_DIALOG(font_dialog)->fontsel), gaim2_prefs_get_string(font_prefs[subscript]));
- }
- */
-
-@@ -337,7 +337,7 @@ gaimrc_set_font(GtkWidget *widget, gpoin
- }
-
- static void
--gaimrc_font_response_special(GtkDialog *font_dialog, gint response,
-+gaim2rc_font_response_special(GtkDialog *font_dialog, gint response,
- gpointer data)
- {
- if (response == GTK_RESPONSE_OK) {
-@@ -345,7 +345,7 @@ gaimrc_font_response_special(GtkDialog *
-
- fontname = gtk_font_selection_dialog_get_font_name(GTK_FONT_SELECTION_DIALOG(font_dialog));
-
-- gaim_prefs_set_string("/plugins/gtk/gaimrc/gtk-font-name",
-+ gaim2_prefs_set_string("/plugins/gtk/gaim2rc/gtk-font-name",
- fontname);
- g_free(fontname);
- }
-@@ -353,21 +353,21 @@ gaimrc_font_response_special(GtkDialog *
- }
-
- static void
--gaimrc_set_font_special(GtkWidget *widget, gpointer data)
-+gaim2rc_set_font_special(GtkWidget *widget, gpointer data)
- {
- GtkWidget *font_dialog = NULL;
- const char *font = NULL;
-
- font_dialog = gtk_font_selection_dialog_new(_("Select Interface Font"));
- g_signal_connect(G_OBJECT(font_dialog), "response",
-- G_CALLBACK(gaimrc_font_response_special), NULL);
-+ G_CALLBACK(gaim2rc_font_response_special), NULL);
-
-- font = gaim_prefs_get_string("/plugins/gtk/gaimrc/gtk-font-name");
-+ font = gaim2_prefs_get_string("/plugins/gtk/gaim2rc/gtk-font-name");
- /* TODO Figure out a way to test for the presence of a value in the
- * actual pref
- printf("font - %s.\n", font);
- if (font != NULL && font != "") {
-- gtk_font_selection_set_font_name(GTK_FONT_SELECTION(GTK_FONT_SELECTION_DIALOG(font_dialog)->fontsel), gaim_prefs_get_string("/plugins/gtk/gaimrc/gtk-font-name"));
-+ gtk_font_selection_set_font_name(GTK_FONT_SELECTION(GTK_FONT_SELECTION_DIALOG(font_dialog)->fontsel), gaim2_prefs_get_string("/plugins/gtk/gaim2rc/gtk-font-name"));
- }
- */
-
-@@ -375,29 +375,29 @@ gaimrc_set_font_special(GtkWidget *widge
- }
-
- static gboolean
--gaimrc_plugin_load(GaimPlugin *plugin)
-+gaim2rc_plugin_load(Gaim2Plugin *plugin)
- {
-- gaimrc_make_changes();
-+ gaim2rc_make_changes();
-
-- pref_callback = gaim_prefs_connect_callback(plugin, "/plugins/gtk/gaimrc",
-- gaimrc_pref_changed_cb, NULL);
-+ pref_callback = gaim2_prefs_connect_callback(plugin, "/plugins/gtk/gaim2rc",
-+ gaim2rc_pref_changed_cb, NULL);
-
- return TRUE;
- }
-
- static gboolean
--gaimrc_plugin_unload(GaimPlugin *plugin)
-+gaim2rc_plugin_unload(Gaim2Plugin *plugin)
- {
-- gaim_prefs_disconnect_callback(pref_callback);
-+ gaim2_prefs_disconnect_callback(pref_callback);
-
- return TRUE;
- }
-
- static GtkWidget *
--gaimrc_get_config_frame(GaimPlugin *plugin)
-+gaim2rc_get_config_frame(Gaim2Plugin *plugin)
- {
- /* Note: Intentionally not using the size group argument to the
-- * gaim_gtk_prefs_labeled_* functions they only add the text label to
-+ * gaim2_gtk_prefs_labeled_* functions they only add the text label to
- * the size group not the whole thing, which isn't what I want. */
- int i;
- char *tmp;
-@@ -411,145 +411,145 @@ gaimrc_get_config_frame(GaimPlugin *plug
- labelsg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
- widgetsg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
-- frame = gaim_gtk_make_frame(ret, "General");
-+ frame = gaim2_gtk_make_frame(ret, "General");
- /* interface font */
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_box_pack_start(GTK_BOX(frame), hbox, FALSE, FALSE, 0);
-
-- check = gaim_gtk_prefs_checkbox(_("GTK+ Interface Font"),
-- "/plugins/gtk/gaimrc/set/gtk-font-name",
-+ check = gaim2_gtk_prefs_checkbox(_("GTK+ Interface Font"),
-+ "/plugins/gtk/gaim2rc/set/gtk-font-name",
- hbox);
- gtk_size_group_add_widget(labelsg, check);
-
-- widget = gaim_pixbuf_button_from_stock("", GTK_STOCK_SELECT_FONT,
-+ widget = gaim2_pixbuf_button_from_stock("", GTK_STOCK_SELECT_FONT,
- GAIM_BUTTON_HORIZONTAL);
- gtk_box_pack_start(GTK_BOX(hbox), widget, FALSE, FALSE, 0);
- gtk_size_group_add_widget(widgetsg, widget);
- gtk_widget_set_sensitive(widget,
-- gaim_prefs_get_bool("/plugins/gtk/gaimrc/set/gtk-font-name"));
-+ gaim2_prefs_get_bool("/plugins/gtk/gaim2rc/set/gtk-font-name"));
- g_signal_connect(G_OBJECT(check), "toggled",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), widget);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), widget);
- g_signal_connect(G_OBJECT(widget), "clicked",
-- G_CALLBACK(gaimrc_set_font_special), NULL);
-+ G_CALLBACK(gaim2rc_set_font_special), NULL);
-
- /* key theme name */
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_box_pack_start(GTK_BOX(frame), hbox, FALSE, FALSE, 0);
-
-- check = gaim_gtk_prefs_checkbox(_("GTK+ Text Shortcut Theme"),
-- "/plugins/gtk/gaimrc/set/gtk-key-theme-name",
-+ check = gaim2_gtk_prefs_checkbox(_("GTK+ Text Shortcut Theme"),
-+ "/plugins/gtk/gaim2rc/set/gtk-key-theme-name",
- hbox);
- gtk_size_group_add_widget(labelsg, check);
-
-- widget = gaim_gtk_prefs_labeled_entry(hbox, "",
-- "/plugins/gtk/gaimrc/gtk-key-theme-name",
-+ widget = gaim2_gtk_prefs_labeled_entry(hbox, "",
-+ "/plugins/gtk/gaim2rc/gtk-key-theme-name",
- NULL);
- /*
- gtk_size_group_add_widget(widgetsg, widget);
- */
- gtk_widget_set_sensitive(widget,
-- gaim_prefs_get_bool("/plugins/gtk/gaimrc/set/gtk-key-theme-name"));
-+ gaim2_prefs_get_bool("/plugins/gtk/gaim2rc/set/gtk-key-theme-name"));
- g_signal_connect(G_OBJECT(check), "toggled",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), widget);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), widget);
-
-- frame = gaim_gtk_make_frame(ret, "Interface colors");
-+ frame = gaim2_gtk_make_frame(ret, "Interface colors");
- /* imhtml stuff */
- for (i = 0; i < G_N_ELEMENTS(color_prefs); i++) {
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_box_pack_start(GTK_BOX(frame), hbox, FALSE, FALSE, 0);
-
-- check = gaim_gtk_prefs_checkbox(_(color_names[i]),
-+ check = gaim2_gtk_prefs_checkbox(_(color_names[i]),
- color_prefs_set[i], hbox);
- gtk_size_group_add_widget(labelsg, check);
-
-- color_widgets[i] = gaim_pixbuf_button_from_stock("", GTK_STOCK_SELECT_COLOR, GAIM_BUTTON_HORIZONTAL);
-+ color_widgets[i] = gaim2_pixbuf_button_from_stock("", GTK_STOCK_SELECT_COLOR, GAIM_BUTTON_HORIZONTAL);
- gtk_size_group_add_widget(widgetsg, color_widgets[i]);
- gtk_box_pack_start(GTK_BOX(hbox), color_widgets[i], FALSE,
- FALSE, 0);
- gtk_widget_set_sensitive(color_widgets[i],
-- gaim_prefs_get_bool(color_prefs_set[i]));
-+ gaim2_prefs_get_bool(color_prefs_set[i]));
- g_signal_connect(G_OBJECT(check), "toggled",
-- G_CALLBACK(gaim_gtk_toggle_sensitive),
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive),
- color_widgets[i]);
- g_signal_connect(G_OBJECT(color_widgets[i]), "clicked",
-- G_CALLBACK(gaimrc_set_color),
-+ G_CALLBACK(gaim2rc_set_color),
- GINT_TO_POINTER(i));
- }
-
-- frame = gaim_gtk_make_frame(ret, "Widget Sizes");
-+ frame = gaim2_gtk_make_frame(ret, "Widget Sizes");
- /* widget size stuff */
- for (i = 0; i < G_N_ELEMENTS(widget_size_prefs); i++) {
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_box_pack_start(GTK_BOX(frame), hbox, FALSE, FALSE, 0);
-
-- check = gaim_gtk_prefs_checkbox(_(widget_size_names[i]),
-+ check = gaim2_gtk_prefs_checkbox(_(widget_size_names[i]),
- widget_size_prefs_set[i], hbox);
- gtk_size_group_add_widget(labelsg, check);
-
-- widget_size_widgets[i] = gaim_gtk_prefs_labeled_spin_button(hbox, "", widget_size_prefs[i], 0, 50, NULL);
-+ widget_size_widgets[i] = gaim2_gtk_prefs_labeled_spin_button(hbox, "", widget_size_prefs[i], 0, 50, NULL);
- /*
- gtk_size_group_add_widget(widgetsg, widget_size_widgets[i]);
- */
- gtk_widget_set_sensitive(widget_size_widgets[i],
-- gaim_prefs_get_bool(widget_size_prefs_set[i]));
-+ gaim2_prefs_get_bool(widget_size_prefs_set[i]));
- g_signal_connect(G_OBJECT(check), "toggled",
-- G_CALLBACK(gaim_gtk_toggle_sensitive),
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive),
- widget_size_widgets[i]);
- }
-
-- frame = gaim_gtk_make_frame(ret, "Fonts");
-+ frame = gaim2_gtk_make_frame(ret, "Fonts");
- /* imhtml font stuff */
- for (i = 0; i < G_N_ELEMENTS(font_prefs); i++) {
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_box_pack_start(GTK_BOX(frame), hbox, FALSE, FALSE, 0);
-
-- check = gaim_gtk_prefs_checkbox(_(font_names[i]),
-+ check = gaim2_gtk_prefs_checkbox(_(font_names[i]),
- font_prefs_set[i], hbox);
- gtk_size_group_add_widget(labelsg, check);
-
-- font_widgets[i] = gaim_pixbuf_button_from_stock("", GTK_STOCK_SELECT_FONT, GAIM_BUTTON_HORIZONTAL);
-+ font_widgets[i] = gaim2_pixbuf_button_from_stock("", GTK_STOCK_SELECT_FONT, GAIM_BUTTON_HORIZONTAL);
- gtk_size_group_add_widget(widgetsg, font_widgets[i]);
- gtk_box_pack_start(GTK_BOX(hbox), font_widgets[i], FALSE,
- FALSE, 0);
- gtk_widget_set_sensitive(font_widgets[i],
-- gaim_prefs_get_bool(font_prefs_set[i]));
-+ gaim2_prefs_get_bool(font_prefs_set[i]));
- g_signal_connect(G_OBJECT(check), "toggled",
-- G_CALLBACK(gaim_gtk_toggle_sensitive),
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive),
- font_widgets[i]);
- g_signal_connect(G_OBJECT(font_widgets[i]), "clicked",
-- G_CALLBACK(gaimrc_set_font), GINT_TO_POINTER(i));
-+ G_CALLBACK(gaim2rc_set_font), GINT_TO_POINTER(i));
- }
-
-- frame = gaim_gtk_make_frame(ret, "General");
-+ frame = gaim2_gtk_make_frame(ret, "General");
-
- vbox = gtk_vbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_box_pack_start(GTK_BOX(frame), vbox, FALSE, FALSE, 0);
-
-- tmp = g_strdup_printf(_("Write settings to %s%sgtkrc-2.0"), gaim_user_dir(), G_DIR_SEPARATOR_S);
-+ tmp = g_strdup_printf(_("Write settings to %s%sgtkrc-2.0"), gaim2_user_dir(), G_DIR_SEPARATOR_S);
- check = gtk_button_new_with_label(tmp);
- g_free(tmp);
- gtk_box_pack_start(GTK_BOX(vbox), check, FALSE, FALSE, 0);
- gtk_size_group_add_widget(labelsg, check);
-- g_signal_connect(G_OBJECT(check), "clicked", G_CALLBACK(gaimrc_write),
-+ g_signal_connect(G_OBJECT(check), "clicked", G_CALLBACK(gaim2rc_write),
- NULL);
-
- check = gtk_button_new_with_label(_("Re-read gtkrc files"));
- gtk_box_pack_start(GTK_BOX(vbox), check, FALSE, FALSE, 0);
- gtk_size_group_add_widget(labelsg, check);
-- g_signal_connect(G_OBJECT(check), "clicked", G_CALLBACK(gaimrc_reread),
-+ g_signal_connect(G_OBJECT(check), "clicked", G_CALLBACK(gaim2rc_reread),
- NULL);
-
- gtk_widget_show_all(ret);
- return ret;
- }
-
--static GaimGtkPluginUiInfo gaimrc_ui_info =
-+static Gaim2GtkPluginUiInfo gaim2rc_ui_info =
- {
-- gaimrc_get_config_frame,
-+ gaim2rc_get_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo gaimrc_info =
-+static Gaim2PluginInfo gaim2rc_info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -559,58 +559,58 @@ static GaimPluginInfo gaimrc_info =
- 0,
- NULL,
- GAIM_PRIORITY_DEFAULT,
-- "gaimrc",
-- N_("Gaim GTK+ Theme Control"),
-+ "gaim2rc",
-+ N_("Gaim2 GTK+ Theme Control"),
- VERSION,
- N_("Provides access to commonly used gtkrc settings."),
- N_("Provides access to commonly used gtkrc settings."),
- "Etan Reisner <deryni@eden.rutgers.edu>",
- GAIM_WEBSITE,
-- gaimrc_plugin_load,
-- gaimrc_plugin_unload,
-+ gaim2rc_plugin_load,
-+ gaim2rc_plugin_unload,
- NULL,
-- &gaimrc_ui_info,
-+ &gaim2rc_ui_info,
- NULL,
- NULL,
- NULL
- };
-
- static void
--gaimrc_init(GaimPlugin *plugin)
-+gaim2rc_init(Gaim2Plugin *plugin)
- {
- int i;
-
-- gaim_prefs_add_none("/plugins");
-- gaim_prefs_add_none("/plugins/gtk");
-- gaim_prefs_add_none("/plugins/gtk/gaimrc");
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/set");
-+ gaim2_prefs_add_none("/plugins");
-+ gaim2_prefs_add_none("/plugins/gtk");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/set");
-
-- gaim_prefs_add_string("/plugins/gtk/gaimrc/gtk-font-name", "");
-- gaim_prefs_add_bool("/plugins/gtk/gaimrc/set/gtk-font-name", FALSE);
-+ gaim2_prefs_add_string("/plugins/gtk/gaim2rc/gtk-font-name", "");
-+ gaim2_prefs_add_bool("/plugins/gtk/gaim2rc/set/gtk-font-name", FALSE);
-
-- gaim_prefs_add_string("/plugins/gtk/gaimrc/gtk-key-theme-name", "");
-- gaim_prefs_add_bool("/plugins/gtk/gaimrc/set/gtk-key-theme-name", FALSE);
-+ gaim2_prefs_add_string("/plugins/gtk/gaim2rc/gtk-key-theme-name", "");
-+ gaim2_prefs_add_bool("/plugins/gtk/gaim2rc/set/gtk-key-theme-name", FALSE);
-
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/color");
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/set/color");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/color");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/set/color");
- for (i = 0; i < G_N_ELEMENTS(color_prefs); i++) {
-- gaim_prefs_add_string(color_prefs[i], "");
-- gaim_prefs_add_bool(color_prefs_set[i], FALSE);
-+ gaim2_prefs_add_string(color_prefs[i], "");
-+ gaim2_prefs_add_bool(color_prefs_set[i], FALSE);
- }
-
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/size");
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/set/size");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/size");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/set/size");
- for (i = 0; i < G_N_ELEMENTS(widget_size_prefs); i++) {
-- gaim_prefs_add_int(widget_size_prefs[i], 0);
-- gaim_prefs_add_bool(widget_size_prefs_set[i], FALSE);
-+ gaim2_prefs_add_int(widget_size_prefs[i], 0);
-+ gaim2_prefs_add_bool(widget_size_prefs_set[i], FALSE);
- }
-
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/font");
-- gaim_prefs_add_none("/plugins/gtk/gaimrc/set/font");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/font");
-+ gaim2_prefs_add_none("/plugins/gtk/gaim2rc/set/font");
- for (i = 0; i < G_N_ELEMENTS(font_prefs); i++) {
-- gaim_prefs_add_string(font_prefs[i], "");
-- gaim_prefs_add_bool(font_prefs_set[i], FALSE);
-+ gaim2_prefs_add_string(font_prefs[i], "");
-+ gaim2_prefs_add_bool(font_prefs_set[i], FALSE);
- }
- }
-
--GAIM_INIT_PLUGIN(gaimrc, gaimrc_init, gaimrc_info)
-+GAIM_INIT_PLUGIN(gaim2rc, gaim2rc_init, gaim2rc_info)
-diff -prNu ./plugins/gestures/gestures.c ./plugins/gestures/gestures.c
---- ./plugins/gestures/gestures.c 2005-12-29 01:21:53.000000000 +0100
-+++ ./plugins/gestures/gestures.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Mouse gestures plugin for Gaim
-+ * Mouse gestures plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -19,7 +19,7 @@
- * 02111-1307, USA.
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "debug.h"
- #include "prefs.h"
-@@ -37,10 +37,10 @@
- static void
- stroke_close(GtkWidget *widget, void *data)
- {
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
-- conv = (GaimConversation *)data;
-+ conv = (Gaim2Conversation *)data;
-
- /* Double-check */
- if (!GAIM_IS_GTK_CONVERSATION(conv))
-@@ -49,18 +49,18 @@ stroke_close(GtkWidget *widget, void *da
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- gstroke_cleanup(gtkconv->imhtml);
-- gaim_conversation_destroy(conv);
-+ gaim2_conversation_destroy(conv);
- }
-
- static void
- stroke_prev_tab(GtkWidget *widget, void *data)
- {
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
- GList *conversations;
-
-- conv = (GaimConversation *)data;
-+ conv = (Gaim2Conversation *)data;
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- win = gtkconv->win;
-
-@@ -71,10 +71,10 @@ stroke_prev_tab(GtkWidget *widget, void
- if (conversations->data == gtkconv)
- {
- if (conversations->prev != NULL) {
-- gaim_gtk_conv_window_switch_gtkconv(win,
-+ gaim2_gtk_conv_window_switch_gtkconv(win,
- conversations->prev->data);
- } else {
-- gaim_gtk_conv_window_switch_gtkconv(win,
-+ gaim2_gtk_conv_window_switch_gtkconv(win,
- g_list_last(conversations)->data);
- }
-
-@@ -86,24 +86,24 @@ stroke_prev_tab(GtkWidget *widget, void
- static void
- stroke_next_tab(GtkWidget *widget, void *data)
- {
-- GaimConversation *conv;
-- GaimGtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkWindow *win;
- GList *conversations;
-
-- conv = (GaimConversation *)data;
-+ conv = (Gaim2Conversation *)data;
- win = GAIM_GTK_CONVERSATION(conv)->win;
-
- for (conversations = win->gtkconvs;
- conversations != NULL;
- conversations = conversations->next)
- {
-- if (((GaimGtkConversation *)conversations->data)->active_conv == conv)
-+ if (((Gaim2GtkConversation *)conversations->data)->active_conv == conv)
- {
- if (conversations->next != NULL) {
-- gaim_gtk_conv_window_switch_gtkconv(win,
-+ gaim2_gtk_conv_window_switch_gtkconv(win,
- conversations->next->data);
- } else {
-- gaim_gtk_conv_window_switch_gtkconv(win,
-+ gaim2_gtk_conv_window_switch_gtkconv(win,
- g_list_first(conversations)->data);
- }
-
-@@ -115,27 +115,27 @@ stroke_next_tab(GtkWidget *widget, void
- static void
- stroke_new_win(GtkWidget *widget, void *data)
- {
-- GaimGtkWindow *new_win, *old_win;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *new_win, *old_win;
-+ Gaim2Conversation *conv;
-
-- conv = (GaimConversation *)data;
-+ conv = (Gaim2Conversation *)data;
- old_win = GAIM_GTK_CONVERSATION(conv)->win;
-
-- if (gaim_gtk_conv_window_get_gtkconv_count(old_win) <= 1)
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(old_win) <= 1)
- return;
-
-- new_win = gaim_gtk_conv_window_new();
-+ new_win = gaim2_gtk_conv_window_new();
-
-- gaim_gtk_conv_window_remove_gtkconv(old_win, GAIM_GTK_CONVERSATION(conv));
-- gaim_gtk_conv_window_add_gtkconv(new_win, GAIM_GTK_CONVERSATION(conv));
-+ gaim2_gtk_conv_window_remove_gtkconv(old_win, GAIM_GTK_CONVERSATION(conv));
-+ gaim2_gtk_conv_window_add_gtkconv(new_win, GAIM_GTK_CONVERSATION(conv));
-
-- gaim_gtk_conv_window_show(new_win);
-+ gaim2_gtk_conv_window_show(new_win);
- }
-
- static void
--attach_signals(GaimConversation *conv)
-+attach_signals(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
-@@ -151,7 +151,7 @@ attach_signals(GaimConversation *conv)
- }
-
- static void
--new_conv_cb(GaimConversation *conv)
-+new_conv_cb(Gaim2Conversation *conv)
- {
- if (GAIM_IS_GTK_CONVERSATION(conv))
- attach_signals(conv);
-@@ -170,25 +170,25 @@ mouse_button_menu_cb(GtkMenuItem *item,
- static void
- toggle_draw_cb(GtkToggleButton *toggle, gpointer data)
- {
-- gaim_prefs_set_bool("/plugins/gtk/X11/gestures/visual",
-+ gaim2_prefs_set_bool("/plugins/gtk/X11/gestures/visual",
- gtk_toggle_button_get_active(toggle));
- }
-
- static void
--visual_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+visual_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- gstroke_set_draw_strokes((gboolean) GPOINTER_TO_INT(value) );
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- GList *l;
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next) {
-- conv = (GaimConversation *)l->data;
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next) {
-+ conv = (Gaim2Conversation *)l->data;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- continue;
-@@ -196,7 +196,7 @@ plugin_load(GaimPlugin *plugin)
- attach_signals(conv);
- }
-
-- gaim_signal_connect(gaim_conversations_get_handle(),
-+ gaim2_signal_connect(gaim2_conversations_get_handle(),
- "conversation-created",
- plugin, GAIM_CALLBACK(new_conv_cb), NULL);
-
-@@ -204,14 +204,14 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- GList *l;
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next) {
-- conv = (GaimConversation *)l->data;
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next) {
-+ conv = (Gaim2Conversation *)l->data;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- continue;
-@@ -226,7 +226,7 @@ plugin_unload(GaimPlugin *plugin)
- }
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret;
- GtkWidget *vbox;
-@@ -241,7 +241,7 @@ get_config_frame(GaimPlugin *plugin)
- gtk_container_set_border_width(GTK_CONTAINER(ret), 12);
-
- /* Configuration frame */
-- vbox = gaim_gtk_make_frame(ret, _("Mouse Gestures Configuration"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Mouse Gestures Configuration"));
-
- #if 0
- /* Mouse button drop-down menu */
-@@ -268,7 +268,7 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("_Visual gesture display"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/gestures/visual"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/gestures/visual"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(toggle_draw_cb), NULL);
-
-@@ -277,13 +277,13 @@ get_config_frame(GaimPlugin *plugin)
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -321,14 +321,14 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk");
-- gaim_prefs_add_none("/plugins/gtk/X11");
-- gaim_prefs_add_none("/plugins/gtk/X11/gestures");
-- gaim_prefs_add_bool("/plugins/gtk/X11/gestures/visual", FALSE);
-+ gaim2_prefs_add_none("/plugins/gtk");
-+ gaim2_prefs_add_none("/plugins/gtk/X11");
-+ gaim2_prefs_add_none("/plugins/gtk/X11/gestures");
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/gestures/visual", FALSE);
-
-- gaim_prefs_connect_callback(plugin, "/plugins/gtk/X11/gestures/visual",
-+ gaim2_prefs_connect_callback(plugin, "/plugins/gtk/X11/gestures/visual",
- visual_pref_cb, NULL);
- }
-
-diff -prNu ./plugins/gestures/Makefile.am ./plugins/gestures/Makefile.am
---- ./plugins/gestures/Makefile.am 2005-04-29 19:04:25.000000000 +0200
-+++ ./plugins/gestures/Makefile.am 2006-01-05 13:15:44.000000000 +0100
-@@ -1,4 +1,4 @@
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- gestures_la_LDFLAGS = -module -avoid-version $(GTK_LIBS)
-
-diff -prNu ./plugins/gestures/stroke-draw.c ./plugins/gestures/stroke-draw.c
---- ./plugins/gestures/stroke-draw.c 2005-12-29 01:21:53.000000000 +0100
-+++ ./plugins/gestures/stroke-draw.c 2006-01-05 15:27:38.000000000 +0100
-@@ -293,7 +293,7 @@ gstroke_execute (GtkWidget *widget, cons
- (GHashTable*)g_object_get_data(G_OBJECT(widget), GSTROKE_SIGNALS);
-
- #if 0
-- gaim_debug(GAIM_DEBUG_MISC, "gestures", "gstroke %s\n", name);
-+ gaim2_debug(GAIM_DEBUG_MISC, "gestures", "gstroke %s\n", name);
- #endif
-
- if (hash_table)
-diff -prNu ./plugins/gevolution/add_buddy_dialog.c ./plugins/gevolution/add_buddy_dialog.c
---- ./plugins/gevolution/add_buddy_dialog.c 2005-10-25 06:24:26.000000000 +0200
-+++ ./plugins/gevolution/add_buddy_dialog.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -20,7 +20,7 @@
- */
- #include "internal.h"
- #include "gtkblist.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkutils.h"
-
- #include "debug.h"
-@@ -160,7 +160,7 @@ static void
- add_ims(GevoAddBuddyDialog *dialog, EContact *contact, const char *name,
- GList *list, const char *id)
- {
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- GList *l;
- GtkTreeIter iter;
- GdkPixbuf *pixbuf, *icon = NULL;
-@@ -168,13 +168,13 @@ add_ims(GevoAddBuddyDialog *dialog, ECon
- if (list == NULL)
- return;
-
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- {
-- GaimConnection *gc = (GaimConnection *)l->data;
-+ Gaim2Connection *gc = (Gaim2Connection *)l->data;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- if (!strcmp(gaim_account_get_protocol_id(account), id))
-+ if (!strcmp(gaim2_account_get_protocol_id(account), id))
- break;
-
- account = NULL;
-@@ -183,7 +183,7 @@ add_ims(GevoAddBuddyDialog *dialog, ECon
- if (account == NULL)
- return;
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- icon = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
-@@ -196,7 +196,7 @@ add_ims(GevoAddBuddyDialog *dialog, ECon
- if (account_name == NULL)
- continue;
-
-- if (gaim_find_buddy(dialog->account, account_name) != NULL)
-+ if (gaim2_find_buddy(dialog->account, account_name) != NULL)
- continue;
-
- gtk_list_store_append(dialog->model, &iter);
-@@ -208,8 +208,8 @@ add_ims(GevoAddBuddyDialog *dialog, ECon
- COLUMN_DATA, contact,
- -1);
-
-- if (!strcmp(gaim_account_get_protocol_id(account),
-- gaim_account_get_protocol_id(dialog->account)) &&
-+ if (!strcmp(gaim2_account_get_protocol_id(account),
-+ gaim2_account_get_protocol_id(dialog->account)) &&
- dialog->username != NULL &&
- !strcmp(account_name, dialog->username))
- {
-@@ -255,7 +255,7 @@ populate_treeview(GevoAddBuddyDialog *di
-
- if (!gevo_load_addressbook(uri, &book, NULL))
- {
-- gaim_debug_error("evolution",
-+ gaim2_debug_error("evolution",
- "Error retrieving default addressbook\n");
-
- return;
-@@ -265,7 +265,7 @@ populate_treeview(GevoAddBuddyDialog *di
-
- if (query == NULL)
- {
-- gaim_debug_error("evolution", "Error in creating query\n");
-+ gaim2_debug_error("evolution", "Error in creating query\n");
-
- g_object_unref(book);
-
-@@ -278,7 +278,7 @@ populate_treeview(GevoAddBuddyDialog *di
-
- if (!status)
- {
-- gaim_debug_error("evolution", "Error %d in getting card list\n",
-+ gaim2_debug_error("evolution", "Error %d in getting card list\n",
- status);
-
- g_object_unref(book);
-@@ -417,7 +417,7 @@ clear_cb(GtkWidget *w, GevoAddBuddyDialo
- }
-
- void
--gevo_add_buddy_dialog_show(GaimAccount *account, const char *username,
-+gevo_add_buddy_dialog_show(Gaim2Account *account, const char *username,
- const char *group, const char *alias)
- {
- GevoAddBuddyDialog *dialog;
-@@ -436,7 +436,7 @@ gevo_add_buddy_dialog_show(GaimAccount *
- dialog->account =
- (account != NULL
- ? account
-- : gaim_connection_get_account(gaim_connections_get_all()->data));
-+ : gaim2_connection_get_account(gaim2_connections_get_all()->data));
-
- if (username != NULL)
- dialog->username = g_strdup(username);
-@@ -575,7 +575,7 @@ gevo_add_buddy_dialog_show(GaimAccount *
- gtk_widget_show(bbox);
-
- /* "New Person" button */
-- button = gaim_pixbuf_button_from_stock(_("New Person"), GTK_STOCK_NEW,
-+ button = gaim2_pixbuf_button_from_stock(_("New Person"), GTK_STOCK_NEW,
- GAIM_BUTTON_HORIZONTAL);
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
- gtk_widget_show(button);
-@@ -592,7 +592,7 @@ gevo_add_buddy_dialog_show(GaimAccount *
- G_CALLBACK(cancel_cb), dialog);
-
- /* "Select Buddy" button */
-- button = gaim_pixbuf_button_from_stock(_("Select Buddy"), GTK_STOCK_APPLY,
-+ button = gaim2_pixbuf_button_from_stock(_("Select Buddy"), GTK_STOCK_APPLY,
- GAIM_BUTTON_HORIZONTAL);
- dialog->select_button = button;
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
-@@ -609,12 +609,12 @@ gevo_add_buddy_dialog_show(GaimAccount *
- void
- gevo_add_buddy_dialog_add_person(GevoAddBuddyDialog *dialog,
- EContact *contact, const char *name,
-- GaimAccount *account, const char *screenname)
-+ Gaim2Account *account, const char *screenname)
- {
- GdkPixbuf *pixbuf, *icon = NULL;
- GtkTreeIter iter;
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- icon = gdk_pixbuf_scale_simple(pixbuf, 16, 16, GDK_INTERP_BILINEAR);
-diff -prNu ./plugins/gevolution/assoc-buddy.c ./plugins/gevolution/assoc-buddy.c
---- ./plugins/gevolution/assoc-buddy.c 2005-10-25 06:24:26.000000000 +0200
-+++ ./plugins/gevolution/assoc-buddy.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -21,7 +21,7 @@
- #include "internal.h"
- #include "gtkblist.h"
- #include "gtkexpander.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkutils.h"
- #include "gtkimhtml.h"
-
-@@ -152,7 +152,7 @@ populate_treeview(GevoAssociateBuddyDial
-
- if (!gevo_load_addressbook(uri, &book, NULL))
- {
-- gaim_debug_error("evolution",
-+ gaim2_debug_error("evolution",
- "Error retrieving addressbook\n");
-
- return;
-@@ -162,7 +162,7 @@ populate_treeview(GevoAssociateBuddyDial
-
- if (query == NULL)
- {
-- gaim_debug_error("evolution", "Error in creating query\n");
-+ gaim2_debug_error("evolution", "Error in creating query\n");
-
- g_object_unref(book);
-
-@@ -175,7 +175,7 @@ populate_treeview(GevoAssociateBuddyDial
-
- if (!status)
- {
-- gaim_debug_error("evolution", "Error %d in getting card list\n",
-+ gaim2_debug_error("evolution", "Error %d in getting card list\n",
- status);
-
- g_object_unref(book);
-@@ -183,7 +183,7 @@ populate_treeview(GevoAssociateBuddyDial
- return;
- }
-
-- prpl_id = gaim_account_get_protocol_id(dialog->buddy->account);
-+ prpl_id = gaim2_account_get_protocol_id(dialog->buddy->account);
-
- for (c = cards; c != NULL; c = c->next)
- {
-@@ -294,7 +294,7 @@ assoc_buddy_cb(GtkWidget *w, GevoAssocia
- e_contact_set(contact, protocol_field, list);
-
- if (!e_book_commit_contact(dialog->book, contact, NULL))
-- gaim_debug_error("evolution", "Error adding contact to book\n");
-+ gaim2_debug_error("evolution", "Error adding contact to book\n");
-
- /* Free the list. */
- g_list_foreach(list, (GFunc)g_free, NULL);
-@@ -304,7 +304,7 @@ assoc_buddy_cb(GtkWidget *w, GevoAssocia
- }
-
- GevoAssociateBuddyDialog *
--gevo_associate_buddy_dialog_new(GaimBuddy *buddy)
-+gevo_associate_buddy_dialog_new(Gaim2Buddy *buddy)
- {
- GevoAssociateBuddyDialog *dialog;
- GtkWidget *button;
-@@ -461,7 +461,7 @@ gevo_associate_buddy_dialog_new(GaimBudd
- gtk_widget_show(bbox);
-
- /* "New Person" button */
-- button = gaim_pixbuf_button_from_stock(_("New Person"), GTK_STOCK_NEW,
-+ button = gaim2_pixbuf_button_from_stock(_("New Person"), GTK_STOCK_NEW,
- GAIM_BUTTON_HORIZONTAL);
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
- gtk_widget_show(button);
-@@ -478,7 +478,7 @@ gevo_associate_buddy_dialog_new(GaimBudd
- G_CALLBACK(cancel_cb), dialog);
-
- /* "Associate Buddy" button */
-- button = gaim_pixbuf_button_from_stock(_("_Associate Buddy"),
-+ button = gaim2_pixbuf_button_from_stock(_("_Associate Buddy"),
- GTK_STOCK_APPLY,
- GAIM_BUTTON_HORIZONTAL);
- dialog->assoc_button = button;
-diff -prNu ./plugins/gevolution/eds-utils.c ./plugins/gevolution/eds-utils.c
---- ./plugins/gevolution/eds-utils.c 2005-12-04 19:19:51.000000000 +0100
-+++ ./plugins/gevolution/eds-utils.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2004 Henry Jen.
- *
-@@ -21,7 +21,7 @@
-
- #include "internal.h"
- #include "gtkblist.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkutils.h"
- #include "gtkimhtml.h"
-
-@@ -65,7 +65,7 @@ gevo_addrbooks_model_populate(GtkTreeMod
-
- if (!e_book_get_addressbooks(&addressbooks, &err))
- {
-- gaim_debug_error("evolution",
-+ gaim2_debug_error("evolution",
- "Unable to fetch list of address books.\n");
-
- gtk_list_store_append(list, &iter);
-@@ -122,7 +122,7 @@ gevo_run_query_in_uri(const gchar *uri,
-
- if (!gevo_load_addressbook(uri, &book, NULL))
- {
-- gaim_debug_error("evolution",
-+ gaim2_debug_error("evolution",
- "Error retrieving addressbook\n");
- return NULL;
- }
-@@ -130,7 +130,7 @@ gevo_run_query_in_uri(const gchar *uri,
- status = e_book_get_contacts(book, query, &cards, NULL);
- if (!status)
- {
-- gaim_debug_error("evolution", "Error %d in getting card list\n",
-+ gaim2_debug_error("evolution", "Error %d in getting card list\n",
- status);
- g_object_unref(book);
- return NULL;
-@@ -168,7 +168,7 @@ gevo_run_query_in_uri(const gchar *uri,
- * second reference) if they want to reuse @a query.
- */
- EContact *
--gevo_search_buddy_in_contacts(GaimBuddy *buddy, EBookQuery *query)
-+gevo_search_buddy_in_contacts(Gaim2Buddy *buddy, EBookQuery *query)
- {
- ESourceList *addressbooks;
- GError *err;
-@@ -188,7 +188,7 @@ gevo_search_buddy_in_contacts(GaimBuddy
- queries[1] = e_book_query_field_test(protocol_field, E_BOOK_QUERY_IS, buddy->name);
- if (queries[1] == NULL)
- {
-- gaim_debug_error("evolution", "Error in creating protocol query\n");
-+ gaim2_debug_error("evolution", "Error in creating protocol query\n");
- e_book_query_unref(query);
- return NULL;
- }
-@@ -200,14 +200,14 @@ gevo_search_buddy_in_contacts(GaimBuddy
- full_query = e_book_query_field_test(protocol_field, E_BOOK_QUERY_IS, buddy->name);
- if (full_query == NULL)
- {
-- gaim_debug_error("evolution", "Error in creating protocol query\n");
-+ gaim2_debug_error("evolution", "Error in creating protocol query\n");
- return NULL;
- }
- }
-
- if (!e_book_get_addressbooks(&addressbooks, &err))
- {
-- gaim_debug_error("evolution",
-+ gaim2_debug_error("evolution",
- "Unable to fetch list of address books.\n");
- e_book_query_unref(full_query);
- if (err != NULL)
-diff -prNu ./plugins/gevolution/gevolution.c ./plugins/gevolution/gevolution.c
---- ./plugins/gevolution/gevolution.c 2005-11-25 02:22:45.000000000 +0100
-+++ ./plugins/gevolution/gevolution.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -19,7 +19,7 @@
- * 02111-1307, USA.
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "connection.h"
- #include "debug.h"
-@@ -58,8 +58,8 @@ enum
- NUM_COLUMNS
- };
-
--static GaimBlistUiOps *backup_blist_ui_ops = NULL;
--static GaimBlistUiOps *blist_ui_ops = NULL;
-+static Gaim2BlistUiOps *backup_blist_ui_ops = NULL;
-+static Gaim2BlistUiOps *blist_ui_ops = NULL;
- static EBook *book = NULL;
- static gulong timer = 0;
- static gulong book_view_tag = 0;
-@@ -75,22 +75,22 @@ update_ims_from_contact(EContact *contac
- if (ims == NULL)
- return;
-
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- {
-- GaimConnection *gc = (GaimConnection *)l->data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- char *me = g_strdup(gaim_normalize(account, gaim_account_get_username(account)));
-+ Gaim2Connection *gc = (Gaim2Connection *)l->data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ char *me = g_strdup(gaim2_normalize(account, gaim2_account_get_username(account)));
-
-- if (strcmp(gaim_account_get_protocol_id(account), prpl_id))
-+ if (strcmp(gaim2_account_get_protocol_id(account), prpl_id))
- continue;
-
-- if (!gaim_account_get_bool(account, "gevo-autoadd", FALSE))
-+ if (!gaim2_account_get_bool(account, "gevo-autoadd", FALSE))
- continue;
-
- for (l2 = ims; l2 != NULL; l2 = l2->next)
- {
-- if (gaim_find_buddy(account, l2->data) != NULL ||
-- !strcmp(me, gaim_normalize(account, l2->data)))
-+ if (gaim2_find_buddy(account, l2->data) != NULL ||
-+ !strcmp(me, gaim2_normalize(account, l2->data)))
- continue;
-
- gevo_add_buddy(account, _("Buddies"), l2->data, name);
-@@ -122,7 +122,7 @@ contacts_changed_cb(EBookView *book_view
- {
- const GList *l;
-
-- if (gaim_connections_get_all() == NULL)
-+ if (gaim2_connections_get_all() == NULL)
- return;
-
- for (l = contacts; l != NULL; l = l->next)
-@@ -134,7 +134,7 @@ contacts_changed_cb(EBookView *book_view
- }
-
- static void
--request_add_buddy(GaimAccount *account, const char *username,
-+request_add_buddy(Gaim2Account *account, const char *username,
- const char *group, const char *alias)
- {
- if (book == NULL)
-@@ -156,7 +156,7 @@ got_book_view_cb(EBook *book, EBookStatu
-
- if (status != E_BOOK_ERROR_OK)
- {
-- gaim_debug_error("evolution", "Unable to retrieve book view! :(\n");
-+ gaim2_debug_error("evolution", "Unable to retrieve book view! :(\n");
-
- return;
- }
-@@ -175,7 +175,7 @@ got_book_view_cb(EBook *book, EBookStatu
- }
-
- static void
--signed_on_cb(GaimConnection *gc)
-+signed_on_cb(Gaim2Connection *gc)
- {
- EBookQuery *query;
- gboolean status;
-@@ -207,16 +207,16 @@ signed_on_cb(GaimConnection *gc)
- }
-
- static void
--menu_item_activate_cb(GaimBlistNode *node, gpointer user_data)
-+menu_item_activate_cb(Gaim2BlistNode *node, gpointer user_data)
- {
-- GaimBuddy *buddy = (GaimBuddy *)node;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)node;
- gevo_associate_buddy_dialog_new(buddy);
- }
-
- static void
--menu_item_send_mail_activate_cb(GaimBlistNode *node, gpointer user_data)
-+menu_item_send_mail_activate_cb(Gaim2BlistNode *node, gpointer user_data)
- {
-- GaimBuddy *buddy = (GaimBuddy *)node;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)node;
- EContact *contact;
- char *mail = NULL;
-
-@@ -229,19 +229,19 @@ menu_item_send_mail_activate_cb(GaimBlis
- }
- else
- {
-- GaimAccount *account = gaim_buddy_get_account(buddy);
-- const char *prpl_id = gaim_account_get_protocol_id(account);
-+ Gaim2Account *account = gaim2_buddy_get_account(buddy);
-+ const char *prpl_id = gaim2_account_get_protocol_id(account);
-
- if (!strcmp(prpl_id, "prpl-msn"))
- {
-- mail = g_strdup(gaim_normalize(account,
-- gaim_buddy_get_name(buddy)));
-+ mail = g_strdup(gaim2_normalize(account,
-+ gaim2_buddy_get_name(buddy)));
- }
- else if (!strcmp(prpl_id, "prpl-yahoo"))
- {
- mail = g_strdup_printf("%s@yahoo.com",
-- gaim_normalize(account,
-- gaim_buddy_get_name(buddy)));
-+ gaim2_normalize(account,
-+ gaim2_buddy_get_name(buddy)));
- }
- }
-
-@@ -259,35 +259,35 @@ menu_item_send_mail_activate_cb(GaimBlis
- }
- else
- {
-- gaim_notify_error(NULL, NULL, _("Unable to send e-mail"),
-+ gaim2_notify_error(NULL, NULL, _("Unable to send e-mail"),
- _("The evolution executable was not found in the PATH."));
- }
- }
- else
- {
-- gaim_notify_error(NULL, NULL, _("Unable to send e-mail"),
-+ gaim2_notify_error(NULL, NULL, _("Unable to send e-mail"),
- _("The specified buddy was not found in the Evolution Contacts."));
- }
- }
-
- static void
--blist_node_extended_menu_cb(GaimBlistNode *node, GList **menu)
-+blist_node_extended_menu_cb(Gaim2BlistNode *node, GList **menu)
- {
-- GaimBlistNodeAction *act;
-- GaimBuddy *buddy;
-+ Gaim2BlistNodeAction *act;
-+ Gaim2Buddy *buddy;
-
- if (!GAIM_BLIST_NODE_IS_BUDDY(node))
- return;
-
-- buddy = (GaimBuddy *)node;
-+ buddy = (Gaim2Buddy *)node;
-
- if (gevo_prpl_is_supported(buddy->account, buddy))
- {
-- act = gaim_blist_node_action_new(_("Add to Address Book"),
-+ act = gaim2_blist_node_action_new(_("Add to Address Book"),
- menu_item_activate_cb,
- NULL, NULL);
- *menu = g_list_append(*menu, act);
-- act = gaim_blist_node_action_new(_("Send E-Mail"),
-+ act = gaim2_blist_node_action_new(_("Send E-Mail"),
- menu_item_send_mail_activate_cb,
- NULL, NULL);
- *menu = g_list_append(*menu, act);
-@@ -298,7 +298,7 @@ blist_node_extended_menu_cb(GaimBlistNod
- static gboolean
- load_timeout(gpointer data)
- {
-- GaimPlugin *plugin = (GaimPlugin *)data;
-+ Gaim2Plugin *plugin = (Gaim2Plugin *)data;
- EBookQuery *query;
-
- timer = 0;
-@@ -315,25 +315,25 @@ load_timeout(gpointer data)
-
- e_book_query_unref(query);
-
-- gaim_signal_connect(gaim_blist_get_handle(), "blist-node-extended-menu",
-+ gaim2_signal_connect(gaim2_blist_get_handle(), "blist-node-extended-menu",
- plugin, GAIM_CALLBACK(blist_node_extended_menu_cb), NULL);
-
- return FALSE;
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- bonobo_activate();
-
-- backup_blist_ui_ops = gaim_blist_get_ui_ops();
-+ backup_blist_ui_ops = gaim2_blist_get_ui_ops();
-
-- blist_ui_ops = g_memdup(backup_blist_ui_ops, sizeof(GaimBlistUiOps));
-+ blist_ui_ops = g_memdup(backup_blist_ui_ops, sizeof(Gaim2BlistUiOps));
- blist_ui_ops->request_add_buddy = request_add_buddy;
-
-- gaim_blist_set_ui_ops(blist_ui_ops);
-+ gaim2_blist_set_ui_ops(blist_ui_ops);
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- plugin, GAIM_CALLBACK(signed_on_cb), NULL);
-
- timer = g_timeout_add(1, load_timeout, plugin);
-@@ -342,9 +342,9 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
-- gaim_blist_set_ui_ops(backup_blist_ui_ops);
-+ gaim2_blist_set_ui_ops(backup_blist_ui_ops);
-
- g_free(blist_ui_ops);
-
-@@ -368,7 +368,7 @@ plugin_unload(GaimPlugin *plugin)
- }
-
- static void
--plugin_destroy(GaimPlugin *plugin)
-+plugin_destroy(Gaim2Plugin *plugin)
- {
- bonobo_debug_shutdown();
- }
-@@ -377,7 +377,7 @@ static void
- autoadd_toggled_cb(GtkCellRendererToggle *renderer, gchar *path_str,
- gpointer data)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GtkTreeModel *model = (GtkTreeModel *)data;
- GtkTreeIter iter;
- gboolean autoadd;
-@@ -388,7 +388,7 @@ autoadd_toggled_cb(GtkCellRendererToggle
- COLUMN_AUTOADD, &autoadd,
- -1);
-
-- gaim_account_set_bool(account, "gevo-autoadd", !autoadd);
-+ gaim2_account_set_bool(account, "gevo-autoadd", !autoadd);
-
- gtk_list_store_set(GTK_LIST_STORE(model), &iter,
- COLUMN_AUTOADD, !autoadd,
-@@ -396,7 +396,7 @@ autoadd_toggled_cb(GtkCellRendererToggle
- }
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret;
- GtkWidget *vbox;
-@@ -414,7 +414,7 @@ get_config_frame(GaimPlugin *plugin)
- gtk_container_set_border_width(GTK_CONTAINER(ret), 12);
-
- /* Configuration frame */
-- vbox = gaim_gtk_make_frame(ret, _("Evolution Integration Configuration"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Evolution Integration Configuration"));
-
- /* Label */
- label = gtk_label_new(_("Select all accounts that buddies should be "
-@@ -474,33 +474,33 @@ get_config_frame(GaimPlugin *plugin)
-
-
- /* Populate */
-- for (l = gaim_accounts_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_accounts_get_all(); l != NULL; l = l->next)
- {
-- GaimAccount *account = (GaimAccount *)l->data;
-+ Gaim2Account *account = (Gaim2Account *)l->data;
- GtkTreeIter iter;
-
-- gaim_debug_info("evolution", "Adding account\n");
-+ gaim2_debug_info("evolution", "Adding account\n");
-
- gtk_list_store_append(model, &iter);
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
- GDK_INTERP_BILINEAR);
-
-- if (!gaim_account_is_connected(account))
-+ if (!gaim2_account_is_connected(account))
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.0, FALSE);
- }
-
- gtk_list_store_set(model, &iter,
- COLUMN_AUTOADD,
-- gaim_account_get_bool(account, "gevo-autoadd",
-+ gaim2_account_get_bool(account, "gevo-autoadd",
- FALSE),
- COLUMN_ICON, scale,
- COLUMN_SCREENNAME,
-- gaim_account_get_username(account),
-+ gaim2_account_get_username(account),
- COLUMN_DATA, account,
- -1);
-
-@@ -513,13 +513,13 @@ get_config_frame(GaimPlugin *plugin)
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame, /**< get_config_frame */
- 0 /**< page_num */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -551,7 +551,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- /* TODO: Change to core-remote when possible. */
- /* info.dependencies = g_list_append(info.dependencies, "gtk-remote"); */
-@@ -562,8 +562,8 @@ init_plugin(GaimPlugin *plugin)
- * For some reason, when we init bonobo from inside a plugin, it will
- * segfault when destroyed. The backtraces are within gmodule somewhere.
- * There's not much I can do, and I'm not sure where the bug lies.
-- * However, plugins are only destroyed when Gaim is shutting down. After
-- * destroying the plugins, gaim ends, and anything else is of course
-+ * However, plugins are only destroyed when Gaim2 is shutting down. After
-+ * destroying the plugins, gaim2 ends, and anything else is of course
- * freed. That includes this, if we make the module resident, which
- * prevents us from being able to actually unload it.
- *
-@@ -575,7 +575,7 @@ init_plugin(GaimPlugin *plugin)
- if (!bonobo_init_full(NULL, NULL, bonobo_activation_orb_get(),
- CORBA_OBJECT_NIL, CORBA_OBJECT_NIL))
- {
-- gaim_debug_error("evolution", "Unable to initialize bonobo.\n");
-+ gaim2_debug_error("evolution", "Unable to initialize bonobo.\n");
- }
- }
-
-diff -prNu ./plugins/gevolution/gevolution.h ./plugins/gevolution/gevolution.h
---- ./plugins/gevolution/gevolution.h 2005-07-18 09:26:08.000000000 +0200
-+++ ./plugins/gevolution/gevolution.h 2006-01-05 15:27:48.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -44,7 +44,7 @@ typedef struct
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *username;
-
- EBook *book;
-@@ -67,8 +67,8 @@ typedef struct
- {
- gboolean person_only;
-
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
-
- EBook *book;
- EContact *contact;
-@@ -88,7 +88,7 @@ typedef struct
-
- typedef struct
- {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- EBook *book;
-
-@@ -105,31 +105,31 @@ typedef struct
-
- } GevoAssociateBuddyDialog;
-
--void gevo_add_buddy_dialog_show(GaimAccount *account, const char *username,
-+void gevo_add_buddy_dialog_show(Gaim2Account *account, const char *username,
- const char *group, const char *alias);
- void gevo_add_buddy_dialog_add_person(GevoAddBuddyDialog *dialog,
- EContact *contact,
-- const char *name, GaimAccount *account,
-+ const char *name, Gaim2Account *account,
- const char *screenname);
-
- void gevo_new_person_dialog_show(EBook *book, EContact *contact,
-- GaimAccount *account, const char *username,
-- const char *group, GaimBuddy *buddy,
-+ Gaim2Account *account, const char *username,
-+ const char *group, Gaim2Buddy *buddy,
- gboolean person_only);
-
--void gevo_add_buddy(GaimAccount *account, const char *group_name,
-+void gevo_add_buddy(Gaim2Account *account, const char *group_name,
- const char *screenname, const char *alias);
- GList *gevo_get_groups(void);
-
--EContactField gevo_prpl_get_field(GaimAccount *account, GaimBuddy *buddy);
--gboolean gevo_prpl_is_supported(GaimAccount *account, GaimBuddy *buddy);
-+EContactField gevo_prpl_get_field(Gaim2Account *account, Gaim2Buddy *buddy);
-+gboolean gevo_prpl_is_supported(Gaim2Account *account, Gaim2Buddy *buddy);
- gboolean gevo_load_addressbook(const gchar *uri, EBook **book, GError **error);
-
--GevoAssociateBuddyDialog *gevo_associate_buddy_dialog_new(GaimBuddy *buddy);
-+GevoAssociateBuddyDialog *gevo_associate_buddy_dialog_new(Gaim2Buddy *buddy);
-
- GtkTreeModel *gevo_addrbooks_model_new(void);
- void gevo_addrbooks_model_unref(GtkTreeModel *model);
- void gevo_addrbooks_model_populate(GtkTreeModel *model);
--EContact *gevo_search_buddy_in_contacts(GaimBuddy *buddy, EBookQuery *query);
-+EContact *gevo_search_buddy_in_contacts(Gaim2Buddy *buddy, EBookQuery *query);
-
- #endif /* _GEVOLUTION_H_ */
-diff -prNu ./plugins/gevolution/gevo-util.c ./plugins/gevolution/gevo-util.c
---- ./plugins/gevolution/gevo-util.c 2005-10-12 04:47:28.000000000 +0200
-+++ ./plugins/gevolution/gevo-util.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -20,35 +20,35 @@
- */
- #include "internal.h"
- #include "gtkblist.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkutils.h"
-
- #include "gevolution.h"
-
- void
--gevo_add_buddy(GaimAccount *account, const char *group_name,
-+gevo_add_buddy(Gaim2Account *account, const char *group_name,
- const char *screenname, const char *alias)
- {
-- GaimConversation *conv = NULL;
-- GaimBuddy *buddy;
-- GaimGroup *group;
-+ Gaim2Conversation *conv = NULL;
-+ Gaim2Buddy *buddy;
-+ Gaim2Group *group;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, screenname, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, screenname, account);
-
-- if ((group = gaim_find_group(group_name)) == NULL)
-+ if ((group = gaim2_find_group(group_name)) == NULL)
- {
-- group = gaim_group_new(group_name);
-- gaim_blist_add_group(group, NULL);
-+ group = gaim2_group_new(group_name);
-+ gaim2_blist_add_group(group, NULL);
- }
-
-- buddy = gaim_buddy_new(account, screenname, alias);
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-- gaim_account_add_buddy(account, buddy);
-+ buddy = gaim2_buddy_new(account, screenname, alias);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
-+ gaim2_account_add_buddy(account, buddy);
-
- if (conv != NULL)
- {
-- gaim_buddy_icon_update(gaim_conv_im_get_icon(GAIM_CONV_IM(conv)));
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_ADD);
-+ gaim2_buddy_icon_update(gaim2_conv_im_get_icon(GAIM_CONV_IM(conv)));
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_ADD);
- }
- }
-
-@@ -56,22 +56,22 @@ GList *
- gevo_get_groups(void)
- {
- GList *list = NULL;
-- GaimGroup *g;
-- GaimBlistNode *gnode;
-+ Gaim2Group *g;
-+ Gaim2BlistNode *gnode;
-
-- if (gaim_get_blist()->root == NULL)
-+ if (gaim2_get_blist()->root == NULL)
- {
- list = g_list_append(list, _("Buddies"));
- }
- else
- {
-- for (gnode = gaim_get_blist()->root;
-+ for (gnode = gaim2_get_blist()->root;
- gnode != NULL;
- gnode = gnode->next)
- {
- if (GAIM_BLIST_NODE_IS_GROUP(gnode))
- {
-- g = (GaimGroup *)gnode;
-+ g = (Gaim2Group *)gnode;
- list = g_list_append(list, g->name);
- }
- }
-@@ -81,21 +81,21 @@ gevo_get_groups(void)
- }
-
- EContactField
--gevo_prpl_get_field(GaimAccount *account, GaimBuddy *buddy)
-+gevo_prpl_get_field(Gaim2Account *account, Gaim2Buddy *buddy)
- {
- EContactField protocol_field = 0;
- const char *protocol_id;
-
- g_return_val_if_fail(account != NULL, 0);
-
-- protocol_id = gaim_account_get_protocol_id(account);
-+ protocol_id = gaim2_account_get_protocol_id(account);
-
- if (!strcmp(protocol_id, "prpl-oscar"))
- {
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -119,7 +119,7 @@ gevo_prpl_get_field(GaimAccount *account
- }
-
- gboolean
--gevo_prpl_is_supported(GaimAccount *account, GaimBuddy *buddy)
-+gevo_prpl_is_supported(Gaim2Account *account, Gaim2Buddy *buddy)
- {
- return (gevo_prpl_get_field(account, buddy) != 0);
- }
-diff -prNu ./plugins/gevolution/new_person_dialog.c ./plugins/gevolution/new_person_dialog.c
---- ./plugins/gevolution/new_person_dialog.c 2005-12-15 23:59:05.000000000 +0100
-+++ ./plugins/gevolution/new_person_dialog.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Evolution integration plugin for Gaim
-+ * Evolution integration plugin for Gaim2
- *
- * Copyright (C) 2003 Christian Hammond.
- *
-@@ -19,7 +19,7 @@
- * 02111-1307, USA.
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkutils.h"
-
- #include "debug.h"
-@@ -136,7 +136,7 @@ add_cb(GtkWidget *w, GevoNewPersonDialog
- full_name = e_contact_name_to_string(name);
- e_contact_set(contact, E_CONTACT_FULL_NAME, full_name);
-
-- im_service = gaim_account_get_protocol_id(dialog->account);
-+ im_service = gaim2_account_get_protocol_id(dialog->account);
-
- if (*email)
- e_contact_set(contact, E_CONTACT_EMAIL_1, (gpointer)email);
-@@ -171,7 +171,7 @@ add_cb(GtkWidget *w, GevoNewPersonDialog
- {
- if (!e_book_add_contact(dialog->book, contact, NULL))
- {
-- gaim_debug_error("evolution", "Error adding contact to book\n");
-+ gaim2_debug_error("evolution", "Error adding contact to book\n");
-
- g_object_unref(contact);
- delete_win_cb(NULL, NULL, dialog);
-@@ -182,7 +182,7 @@ add_cb(GtkWidget *w, GevoNewPersonDialog
- {
- if (!e_book_commit_contact(dialog->book, contact, NULL))
- {
-- gaim_debug_error("evolution", "Error adding contact to book\n");
-+ gaim2_debug_error("evolution", "Error adding contact to book\n");
-
- g_object_unref(contact);
- delete_win_cb(NULL, NULL, dialog);
-@@ -213,7 +213,7 @@ add_cb(GtkWidget *w, GevoNewPersonDialog
- }
-
- static void
--select_account_cb(GObject *w, GaimAccount *account,
-+select_account_cb(GObject *w, Gaim2Account *account,
- GevoNewPersonDialog *dialog)
- {
- dialog->account = account;
-@@ -221,8 +221,8 @@ select_account_cb(GObject *w, GaimAccoun
-
- void
- gevo_new_person_dialog_show(EBook *book, EContact *contact,
-- GaimAccount *account, const char *username,
-- const char *group, GaimBuddy *buddy,
-+ Gaim2Account *account, const char *username,
-+ const char *group, Gaim2Buddy *buddy,
- gboolean person_only)
- {
- GevoNewPersonDialog *dialog;
-@@ -284,7 +284,7 @@ gevo_new_person_dialog_show(EBook *book,
- {
- /* Add the account type stuff. */
- dialog->accounts_menu =
-- gaim_gtk_account_option_menu_new(account, FALSE,
-+ gaim2_gtk_account_option_menu_new(account, FALSE,
- G_CALLBACK(select_account_cb),
- NULL, dialog);
- add_pref_box(sg, vbox, _("Account type:"), dialog->accounts_menu);
-diff -prNu ./plugins/gtk-signals-test.c ./plugins/gtk-signals-test.c
---- ./plugins/gtk-signals-test.c 2005-12-23 06:13:52.000000000 +0100
-+++ ./plugins/gtk-signals-test.c 2006-01-05 15:27:38.000000000 +0100
-@@ -35,115 +35,115 @@
- * Account subsystem signal callbacks
- **************************************************************************/
- static void
--account_modified_cb(GaimAccount *account, void *data) {
-- gaim_debug_info("gtk-signal-test", "account modified cb\n");
-+account_modified_cb(Gaim2Account *account, void *data) {
-+ gaim2_debug_info("gtk-signal-test", "account modified cb\n");
- }
-
- /**************************************************************************
- * Buddy List subsystem signal callbacks
- **************************************************************************/
- static void
--blist_created_cb(GaimBuddyList *blist, void *data) {
-- gaim_debug_info("gtk-signal-test", "buddy list created\n");
-+blist_created_cb(Gaim2BuddyList *blist, void *data) {
-+ gaim2_debug_info("gtk-signal-test", "buddy list created\n");
- }
-
- static void
--blist_drawing_tooltip_cb(GaimBlistNode *node, char **text, void *data) {
-- gaim_debug_info("gtk-signal-test", "drawing tooltip cb\n");
-+blist_drawing_tooltip_cb(Gaim2BlistNode *node, char **text, void *data) {
-+ gaim2_debug_info("gtk-signal-test", "drawing tooltip cb\n");
- }
-
- /**************************************************************************
- * Conversation subsystem signal callbacks
- **************************************************************************/
- static void
--conversation_dragging_cb(GaimGtkWindow *source, GaimGtkWindow *destination) {
-- gaim_debug_info("gtk-signal-test", "conversation dragging cb\n");
-+conversation_dragging_cb(Gaim2GtkWindow *source, Gaim2GtkWindow *destination) {
-+ gaim2_debug_info("gtk-signal-test", "conversation dragging cb\n");
- }
-
- static gboolean
--displaying_im_msg_cb(GaimAccount *account, GaimConversation *conv,
-+displaying_im_msg_cb(Gaim2Account *account, Gaim2Conversation *conv,
- char **buffer, int flags, void *data)
- {
-- gaim_debug_misc("gtk-signals test", "displaying-im-msg (%s, %s)\n",
-- gaim_conversation_get_name(conv), *buffer);
-+ gaim2_debug_misc("gtk-signals test", "displaying-im-msg (%s, %s)\n",
-+ gaim2_conversation_get_name(conv), *buffer);
-
- return FALSE;
- }
-
- static void
--displayed_im_msg_cb(GaimAccount *account, GaimConversation *conv, const char *buffer, int flags, void *data)
-+displayed_im_msg_cb(Gaim2Account *account, Gaim2Conversation *conv, const char *buffer, int flags, void *data)
- {
-- gaim_debug_misc("gtk-signals test", "displayed-im-msg (%s, %s)\n",
-- gaim_conversation_get_name(conv), buffer);
-+ gaim2_debug_misc("gtk-signals test", "displayed-im-msg (%s, %s)\n",
-+ gaim2_conversation_get_name(conv), buffer);
- }
-
- static gboolean
--displaying_chat_msg_cb(GaimAccount *account, GaimConversation *conv,
-+displaying_chat_msg_cb(Gaim2Account *account, Gaim2Conversation *conv,
- char **buffer, int flags, void *data)
- {
-- gaim_debug_misc("gtk-signals test", "displaying-chat-msg (%s, %s)\n",
-- gaim_conversation_get_name(conv), *buffer);
-+ gaim2_debug_misc("gtk-signals test", "displaying-chat-msg (%s, %s)\n",
-+ gaim2_conversation_get_name(conv), *buffer);
-
- return FALSE;
- }
-
- static void
--displayed_chat_msg_cb(GaimAccount *account, GaimConversation *conv, const char *buffer, int flags, void *data)
-+displayed_chat_msg_cb(Gaim2Account *account, Gaim2Conversation *conv, const char *buffer, int flags, void *data)
- {
-- gaim_debug_misc("gtk-signals test", "displayed-chat-msg (%s, %s)\n",
-- gaim_conversation_get_name(conv), buffer);
-+ gaim2_debug_misc("gtk-signals test", "displayed-chat-msg (%s, %s)\n",
-+ gaim2_conversation_get_name(conv), buffer);
- }
-
- static void
--conversation_switched_cb(GaimConversation *conv, void *data)
-+conversation_switched_cb(Gaim2Conversation *conv, void *data)
- {
-- gaim_debug_misc("gtk-signals test", "conversation-switched (%s)\n",
-- gaim_conversation_get_name(conv));
-+ gaim2_debug_misc("gtk-signals test", "conversation-switched (%s)\n",
-+ gaim2_conversation_get_name(conv));
- }
-
- /**************************************************************************
- * Plugin stuff
- **************************************************************************/
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *accounts_handle = gaim_gtk_account_get_handle();
-- void *blist_handle = gaim_gtk_blist_get_handle();
-- void *conv_handle = gaim_gtk_conversations_get_handle();
-+ void *accounts_handle = gaim2_gtk_account_get_handle();
-+ void *blist_handle = gaim2_gtk_blist_get_handle();
-+ void *conv_handle = gaim2_gtk_conversations_get_handle();
-
- /* Accounts subsystem signals */
-- gaim_signal_connect(accounts_handle, "account-modified",
-+ gaim2_signal_connect(accounts_handle, "account-modified",
- plugin, GAIM_CALLBACK(account_modified_cb), NULL);
-
- /* Buddy List subsystem signals */
-- gaim_signal_connect(blist_handle, "gtkblist-created",
-+ gaim2_signal_connect(blist_handle, "gtkblist-created",
- plugin, GAIM_CALLBACK(blist_created_cb), NULL);
-- gaim_signal_connect(blist_handle, "drawing-tooltip",
-+ gaim2_signal_connect(blist_handle, "drawing-tooltip",
- plugin, GAIM_CALLBACK(blist_drawing_tooltip_cb), NULL);
-
- /* Conversations subsystem signals */
-- gaim_signal_connect(conv_handle, "conversation-dragging",
-+ gaim2_signal_connect(conv_handle, "conversation-dragging",
- plugin, GAIM_CALLBACK(conversation_dragging_cb), NULL);
-- gaim_signal_connect(conv_handle, "displaying-im-msg",
-+ gaim2_signal_connect(conv_handle, "displaying-im-msg",
- plugin, GAIM_CALLBACK(displaying_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "displayed-im-msg",
-+ gaim2_signal_connect(conv_handle, "displayed-im-msg",
- plugin, GAIM_CALLBACK(displayed_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "displaying-chat-msg",
-+ gaim2_signal_connect(conv_handle, "displaying-chat-msg",
- plugin, GAIM_CALLBACK(displaying_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "displayed-chat-msg",
-+ gaim2_signal_connect(conv_handle, "displayed-chat-msg",
- plugin, GAIM_CALLBACK(displayed_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "conversation-switched",
-+ gaim2_signal_connect(conv_handle, "conversation-switched",
- plugin, GAIM_CALLBACK(conversation_switched_cb), NULL);
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin) {
-+plugin_unload(Gaim2Plugin *plugin) {
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -175,7 +175,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/history.c ./plugins/history.c
---- ./plugins/history.c 2005-12-23 00:06:43.000000000 +0100
-+++ ./plugins/history.c 2006-01-05 15:27:38.000000000 +0100
-@@ -2,7 +2,7 @@
- * stolen by Trillian "Pro") */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "conversation.h"
- #include "debug.h"
-@@ -29,23 +29,23 @@ static gboolean _scroll_imhtml_to_end(gp
- return FALSE;
- }
-
--static void historize(GaimConversation *c)
-+static void historize(Gaim2Conversation *c)
- {
-- GaimAccount *account = gaim_conversation_get_account(c);
-- const char *name = gaim_conversation_get_name(c);
-- GaimConversationType convtype;
-+ Gaim2Account *account = gaim2_conversation_get_account(c);
-+ const char *name = gaim2_conversation_get_name(c);
-+ Gaim2ConversationType convtype;
- GList *logs = NULL;
- const char *alias = name;
- guint flags;
- char *history;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GtkIMHtmlOptions options = GTK_IMHTML_NO_COLOURS;
- time_t tm;
- char day[64];
- char *header;
- char *protocol;
-
-- convtype = gaim_conversation_get_type(c);
-+ convtype = gaim2_conversation_get_type(c);
- gtkconv = GAIM_GTK_CONVERSATION(c);
- if (convtype == GAIM_CONV_TYPE_IM && g_list_length(gtkconv->convs) < 2)
- {
-@@ -54,34 +54,34 @@ static void historize(GaimConversation *
-
- /* If we're not logging, don't show anything.
- * Otherwise, we might show a very old log. */
-- if (!gaim_prefs_get_bool("/core/logging/log_ims"))
-+ if (!gaim2_prefs_get_bool("/core/logging/log_ims"))
- return;
-
- /* Find buddies for this conversation. */
-- buddies = gaim_find_buddies(account, name);
-+ buddies = gaim2_find_buddies(account, name);
-
- /* If we found at least one buddy, save the first buddy's alias. */
- if (buddies != NULL)
-- alias = gaim_buddy_get_contact_alias((GaimBuddy *)buddies->data);
-+ alias = gaim2_buddy_get_contact_alias((Gaim2Buddy *)buddies->data);
-
- for (cur = buddies; cur != NULL; cur = cur->next)
- {
-- GaimBlistNode *node = cur->data;
-+ Gaim2BlistNode *node = cur->data;
- if ((node != NULL) && ((node->prev != NULL) || (node->next != NULL)))
- {
-- GaimBlistNode *node2;
-+ Gaim2BlistNode *node2;
-
-- alias = gaim_buddy_get_contact_alias((GaimBuddy *)node);
-+ alias = gaim2_buddy_get_contact_alias((Gaim2Buddy *)node);
-
- /* We've found a buddy that matches this conversation. It's part of a
-- * GaimContact with more than one GaimBuddy. Loop through the GaimBuddies
-+ * Gaim2Contact with more than one Gaim2Buddy. Loop through the Gaim2Buddies
- * in the contact and get all the logs. */
- for (node2 = node->parent->child ; node2 != NULL ; node2 = node2->next)
- {
- logs = g_list_concat(
-- gaim_log_get_logs(GAIM_LOG_IM,
-- gaim_buddy_get_name((GaimBuddy *)node2),
-- gaim_buddy_get_account((GaimBuddy *)node2)),
-+ gaim2_log_get_logs(GAIM_LOG_IM,
-+ gaim2_buddy_get_name((Gaim2Buddy *)node2),
-+ gaim2_buddy_get_account((Gaim2Buddy *)node2)),
- logs);
- }
- break;
-@@ -90,34 +90,34 @@ static void historize(GaimConversation *
- g_slist_free(buddies);
-
- if (logs == NULL)
-- logs = gaim_log_get_logs(GAIM_LOG_IM, name, account);
-+ logs = gaim2_log_get_logs(GAIM_LOG_IM, name, account);
- else
-- logs = g_list_sort(logs, gaim_log_compare);
-+ logs = g_list_sort(logs, gaim2_log_compare);
- }
- else if (convtype == GAIM_CONV_TYPE_CHAT)
- {
- /* If we're not logging, don't show anything.
- * Otherwise, we might show a very old log. */
-- if (!gaim_prefs_get_bool("/core/logging/log_chats"))
-+ if (!gaim2_prefs_get_bool("/core/logging/log_chats"))
- return;
-
-- logs = gaim_log_get_logs(GAIM_LOG_CHAT, name, account);
-+ logs = gaim2_log_get_logs(GAIM_LOG_CHAT, name, account);
- }
-
- if (logs == NULL)
- return;
-
-- history = gaim_log_read((GaimLog*)logs->data, &flags);
-+ history = gaim2_log_read((Gaim2Log*)logs->data, &flags);
- gtkconv = GAIM_GTK_CONVERSATION(c);
- if (flags & GAIM_LOG_READ_NO_NEWLINE)
- options |= GTK_IMHTML_NO_NEWLINE;
-
- protocol = g_strdup(gtk_imhtml_get_protocol_name(GTK_IMHTML(gtkconv->imhtml)));
- gtk_imhtml_set_protocol_name(GTK_IMHTML(gtkconv->imhtml),
-- gaim_account_get_protocol_name(((GaimLog*)logs->data)->account));
-+ gaim2_account_get_protocol_name(((Gaim2Log*)logs->data)->account));
-
-- tm = ((GaimLog *)logs->data)->time;
-- gaim_strftime(day, sizeof(day), "%c", localtime(&tm));
-+ tm = ((Gaim2Log *)logs->data)->time;
-+ gaim2_strftime(day, sizeof(day), "%c", localtime(&tm));
- header = g_strdup_printf("<b>Conversation with %s on %s:</b><br>", alias, day);
- gtk_imhtml_append_text(GTK_IMHTML(gtkconv->imhtml), header, options);
- g_free(header);
-@@ -133,38 +133,38 @@ static void historize(GaimConversation *
- g_object_ref(G_OBJECT(gtkconv->imhtml));
- g_idle_add(_scroll_imhtml_to_end, gtkconv->imhtml);
-
-- g_list_foreach(logs, (GFunc)gaim_log_free, NULL);
-+ g_list_foreach(logs, (GFunc)gaim2_log_free, NULL);
- g_list_free(logs);
- }
-
- static void
--history_prefs_check(GaimPlugin *plugin)
-+history_prefs_check(Gaim2Plugin *plugin)
- {
-- if (!gaim_prefs_get_bool("/core/logging/log_ims") &&
-- !gaim_prefs_get_bool("/core/logging/log_chats"))
-+ if (!gaim2_prefs_get_bool("/core/logging/log_ims") &&
-+ !gaim2_prefs_get_bool("/core/logging/log_chats"))
- {
-- gaim_notify_warning(plugin, NULL, _("History Plugin Requires Logging"),
-+ gaim2_notify_warning(plugin, NULL, _("History Plugin Requires Logging"),
- _("Logging can be enabled from Tools -> Preferences -> Logging.\n\n"
- "Enabling logs for instant messages and/or chats will activate "
- "history for the same conversation type(s)."));
- }
- }
-
--static void history_prefs_cb(const char *name, GaimPrefType type, gpointer val, gpointer data)
-+static void history_prefs_cb(const char *name, Gaim2PrefType type, gpointer val, gpointer data)
- {
-- history_prefs_check((GaimPlugin *)data);
-+ history_prefs_check((Gaim2Plugin *)data);
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- gaim_signal_connect(gaim_conversations_get_handle(),
-+ gaim2_signal_connect(gaim2_conversations_get_handle(),
- "conversation-created",
- plugin, GAIM_CALLBACK(historize), NULL);
-
-- gaim_prefs_connect_callback(plugin, "/core/logging/log_ims",
-+ gaim2_prefs_connect_callback(plugin, "/core/logging/log_ims",
- history_prefs_cb, plugin);
-- gaim_prefs_connect_callback(plugin, "/core/logging/log_chats",
-+ gaim2_prefs_connect_callback(plugin, "/core/logging/log_chats",
- history_prefs_cb, plugin);
-
- history_prefs_check(plugin);
-@@ -172,7 +172,7 @@ plugin_load(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -200,7 +200,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/iconaway.c ./plugins/iconaway.c
---- ./plugins/iconaway.c 2005-12-28 10:01:41.000000000 +0100
-+++ ./plugins/iconaway.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,6 +1,6 @@
--/* gaim
-+/* gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -19,7 +19,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "conversation.h"
- #include "signals.h"
-@@ -31,24 +31,24 @@
- #define ICONAWAY_PLUGIN_ID "gtk-iconaway"
-
- static void
--iconify_windows(GaimAccount *account, GaimStatus *old, GaimStatus *newstatus)
-+iconify_windows(Gaim2Account *account, Gaim2Status *old, Gaim2Status *newstatus)
- {
-- GaimPresence *presence;
-- GaimGtkWindow *win;
-+ Gaim2Presence *presence;
-+ Gaim2GtkWindow *win;
- GList *windows;
-
-- presence = gaim_status_get_presence(newstatus);
-+ presence = gaim2_status_get_presence(newstatus);
-
-- if (gaim_presence_is_available(presence))
-+ if (gaim2_presence_is_available(presence))
- return;
-
-- gaim_blist_set_visible(FALSE);
-+ gaim2_blist_set_visible(FALSE);
-
-- for (windows = gaim_gtk_conv_windows_get_list();
-+ for (windows = gaim2_gtk_conv_windows_get_list();
- windows != NULL;
- windows = windows->next) {
-
-- win = (GaimGtkWindow *)windows->data;
-+ win = (Gaim2GtkWindow *)windows->data;
-
- gtk_window_iconify(GTK_WINDOW(win->window));
- }
-@@ -59,15 +59,15 @@ iconify_windows(GaimAccount *account, Ga
- */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-status-changed",
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-status-changed",
- plugin, GAIM_CALLBACK(iconify_windows), NULL);
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -99,7 +99,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/idle.c ./plugins/idle.c
---- ./plugins/idle.c 2005-12-03 20:39:40.000000000 +0100
-+++ ./plugins/idle.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,9 +1,9 @@
- /*
-- * idle.c - I'dle Mak'er plugin for Gaim
-+ * idle.c - I'dle Mak'er plugin for Gaim2
- *
-- * This file is part of Gaim.
-+ * This file is part of Gaim2.
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -40,7 +40,7 @@
- static GList *idled_accts = NULL;
-
- static gboolean
--idle_filter(GaimAccount *acct)
-+idle_filter(Gaim2Account *acct)
- {
- if (g_list_find(idled_accts, acct))
- return TRUE;
-@@ -49,37 +49,37 @@ idle_filter(GaimAccount *acct)
- }
-
- static void
--set_idle_time(GaimAccount *acct, int mins_idle)
-+set_idle_time(Gaim2Account *acct, int mins_idle)
- {
- time_t t;
-- GaimConnection *gc = gaim_account_get_connection(acct);
-- GaimPresence *presence = gaim_account_get_presence(acct);
-+ Gaim2Connection *gc = gaim2_account_get_connection(acct);
-+ Gaim2Presence *presence = gaim2_account_get_presence(acct);
-
- if (!gc)
- return;
-
-- gaim_debug_info("idle",
-+ gaim2_debug_info("idle",
- "setting idle time for %s to %d\n",
-- gaim_account_get_username(acct), mins_idle);
-+ gaim2_account_get_username(acct), mins_idle);
-
- t = time(NULL) - (60 * mins_idle); /* subtract seconds idle from current time */
-- gaim_idle_set(t);
-+ gaim2_idle_set(t);
-
-- gaim_presence_set_idle(presence, mins_idle ? TRUE : FALSE, t);
-+ gaim2_presence_set_idle(presence, mins_idle ? TRUE : FALSE, t);
- }
-
- static void
--idle_action_ok(void *ignored, GaimRequestFields *fields)
-+idle_action_ok(void *ignored, Gaim2RequestFields *fields)
- {
-- int tm = gaim_request_fields_get_integer(fields, "mins");
-- GaimAccount *acct = gaim_request_fields_get_account(fields, "acct");
-+ int tm = gaim2_request_fields_get_integer(fields, "mins");
-+ Gaim2Account *acct = gaim2_request_fields_get_account(fields, "acct");
-
- /* only add the account to the GList if it's not already been idled */
- if (!idle_filter(acct))
- {
-- gaim_debug_misc("idle",
-+ gaim2_debug_misc("idle",
- "%s hasn't been idled yet; adding to list.\n",
-- gaim_account_get_username(acct));
-+ gaim2_account_get_username(acct));
- idled_accts = g_list_append(idled_accts, acct);
- }
-
-@@ -87,9 +87,9 @@ idle_action_ok(void *ignored, GaimReques
- }
-
- static void
--unidle_action_ok(void *ignored, GaimRequestFields *fields)
-+unidle_action_ok(void *ignored, Gaim2RequestFields *fields)
- {
-- GaimAccount *acct = gaim_request_fields_get_account(fields, "acct");
-+ Gaim2Account *acct = gaim2_request_fields_get_account(fields, "acct");
-
- set_idle_time(acct, 0); /* unidle the account */
-
-@@ -99,27 +99,27 @@ unidle_action_ok(void *ignored, GaimRequ
-
-
- static void
--idle_action(GaimPluginAction *action)
-+idle_action(Gaim2PluginAction *action)
- {
- /* Use the super fancy request API */
-
-- GaimRequestFields *request;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *request;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
-- group = gaim_request_field_group_new(NULL);
-+ group = gaim2_request_field_group_new(NULL);
-
-- field = gaim_request_field_account_new("acct", _("Account"), NULL);
-- gaim_request_field_account_set_show_all(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_account_new("acct", _("Account"), NULL);
-+ gaim2_request_field_account_set_show_all(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_int_new("mins", _("Minutes"), 10);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_int_new("mins", _("Minutes"), 10);
-+ gaim2_request_field_group_add_field(group, field);
-
-- request = gaim_request_fields_new();
-- gaim_request_fields_add_group(request, group);
-+ request = gaim2_request_fields_new();
-+ gaim2_request_fields_add_group(request, group);
-
-- gaim_request_fields(action->plugin,
-+ gaim2_request_fields(action->plugin,
- N_("I'dle Mak'er"),
- _("Set Account Idle Time"),
- NULL,
-@@ -130,29 +130,29 @@ idle_action(GaimPluginAction *action)
- }
-
- static void
--unidle_action(GaimPluginAction *action)
-+unidle_action(Gaim2PluginAction *action)
- {
-- GaimRequestFields *request;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *request;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- if (idled_accts == NULL)
- {
-- gaim_notify_info(NULL, NULL, _("None of your accounts are idle."), NULL);
-+ gaim2_notify_info(NULL, NULL, _("None of your accounts are idle."), NULL);
- return;
- }
-
-- group = gaim_request_field_group_new(NULL);
-+ group = gaim2_request_field_group_new(NULL);
-
-- field = gaim_request_field_account_new("acct", _("Account"), NULL);
-- gaim_request_field_account_set_filter(field, idle_filter);
-- gaim_request_field_account_set_show_all(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_account_new("acct", _("Account"), NULL);
-+ gaim2_request_field_account_set_filter(field, idle_filter);
-+ gaim2_request_field_account_set_show_all(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- request = gaim_request_fields_new();
-- gaim_request_fields_add_group(request, group);
-+ request = gaim2_request_fields_new();
-+ gaim2_request_fields_add_group(request, group);
-
-- gaim_request_fields(action->plugin,
-+ gaim2_request_fields(action->plugin,
- N_("I'dle Mak'er"),
- _("Unset Account Idle Time"),
- NULL,
-@@ -163,7 +163,7 @@ unidle_action(GaimPluginAction *action)
- }
-
- static void
--unidle_all_action(GaimPluginAction *action)
-+unidle_all_action(Gaim2PluginAction *action)
- {
- GList *l;
-
-@@ -171,7 +171,7 @@ unidle_all_action(GaimPluginAction *acti
- * after the list is freed */
- for (l = idled_accts; l; l = l->next)
- {
-- GaimAccount *account = l->data;
-+ Gaim2Account *account = l->data;
- set_idle_time(account, 0);
- }
-
-@@ -180,20 +180,20 @@ unidle_all_action(GaimPluginAction *acti
- }
-
- static GList *
--actions(GaimPlugin *plugin, gpointer context)
-+actions(Gaim2Plugin *plugin, gpointer context)
- {
- GList *l = NULL;
-- GaimPluginAction *act = NULL;
-+ Gaim2PluginAction *act = NULL;
-
-- act = gaim_plugin_action_new(_("Set Account Idle Time"),
-+ act = gaim2_plugin_action_new(_("Set Account Idle Time"),
- idle_action);
- l = g_list_append(l, act);
-
-- act = gaim_plugin_action_new(_("Unset Account Idle Time"),
-+ act = gaim2_plugin_action_new(_("Unset Account Idle Time"),
- unidle_action);
- l = g_list_append(l, act);
-
-- act = gaim_plugin_action_new(
-+ act = gaim2_plugin_action_new(
- _("Unset Idle Time for All Idled Accounts"), unidle_all_action);
- l = g_list_append(l, act);
-
-@@ -201,14 +201,14 @@ actions(GaimPlugin *plugin, gpointer con
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- unidle_all_action(NULL);
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -236,7 +236,7 @@ static GaimPluginInfo info =
-
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/ipc-test-client.c ./plugins/ipc-test-client.c
---- ./plugins/ipc-test-client.c 2005-08-14 00:09:30.000000000 +0200
-+++ ./plugins/ipc-test-client.c 2006-01-05 15:27:38.000000000 +0100
-@@ -26,53 +26,53 @@
- #define IPC_TEST_CLIENT_PLUGIN_ID "core-ipc-test-client"
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- GaimPlugin *server_plugin;
-+ Gaim2Plugin *server_plugin;
- gboolean ok;
- int result;
-
-- server_plugin = gaim_plugins_find_with_id("core-ipc-test-server");
-+ server_plugin = gaim2_plugins_find_with_id("core-ipc-test-server");
-
- if (server_plugin == NULL)
- {
-- gaim_debug_error("ipc-test-client",
-+ gaim2_debug_error("ipc-test-client",
- "Unable to locate plugin core-ipc-test-server, "
- "needed for IPC.\n");
-
- return TRUE;
- }
-
-- result = (int)gaim_plugin_ipc_call(server_plugin, "add", &ok, 36, 6);
-+ result = (int)gaim2_plugin_ipc_call(server_plugin, "add", &ok, 36, 6);
-
- if (!ok)
- {
-- gaim_debug_error("ipc-test-client",
-+ gaim2_debug_error("ipc-test-client",
- "Unable to call IPC function 'add' in "
- "core-ipc-test-server plugin.");
-
- return TRUE;
- }
-
-- gaim_debug_info("ipc-test-client", "36 + 6 = %d\n", result);
-+ gaim2_debug_info("ipc-test-client", "36 + 6 = %d\n", result);
-
-- result = (int)gaim_plugin_ipc_call(server_plugin, "sub", &ok, 50, 8);
-+ result = (int)gaim2_plugin_ipc_call(server_plugin, "sub", &ok, 50, 8);
-
- if (!ok)
- {
-- gaim_debug_error("ipc-test-client",
-+ gaim2_debug_error("ipc-test-client",
- "Unable to call IPC function 'sub' in "
- "core-ipc-test-server plugin.");
-
- return TRUE;
- }
-
-- gaim_debug_info("ipc-test-client", "50 - 8 = %d\n", result);
-+ gaim2_debug_info("ipc-test-client", "50 - 8 = %d\n", result);
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -105,7 +105,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- info.dependencies = g_list_append(info.dependencies,
- "core-ipc-test-server");
-diff -prNu ./plugins/ipc-test-server.c ./plugins/ipc-test-server.c
---- ./plugins/ipc-test-server.c 2005-08-14 00:09:30.000000000 +0200
-+++ ./plugins/ipc-test-server.c 2006-01-05 15:27:38.000000000 +0100
-@@ -28,7 +28,7 @@
- static int
- add_func(int i1, int i2)
- {
-- gaim_debug_misc("ipc-test-server", "Got %d, %d, returning %d\n",
-+ gaim2_debug_misc("ipc-test-server", "Got %d, %d, returning %d\n",
- i1, i2, i1 + i2);
- return i1 + i2;
- }
-@@ -36,30 +36,30 @@ add_func(int i1, int i2)
- static int
- sub_func(int i1, int i2)
- {
-- gaim_debug_misc("ipc-test-server", "Got %d, %d, returning %d\n",
-+ gaim2_debug_misc("ipc-test-server", "Got %d, %d, returning %d\n",
- i1, i2, i1 - i2);
- return i1 - i2;
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- gaim_plugin_ipc_register(plugin, "add", GAIM_CALLBACK(add_func),
-- gaim_marshal_INT__INT_INT,
-- gaim_value_new(GAIM_TYPE_INT), 2,
-- gaim_value_new(GAIM_TYPE_INT),
-- gaim_value_new(GAIM_TYPE_INT));
--
-- gaim_plugin_ipc_register(plugin, "sub", GAIM_CALLBACK(sub_func),
-- gaim_marshal_INT__INT_INT,
-- gaim_value_new(GAIM_TYPE_INT), 2,
-- gaim_value_new(GAIM_TYPE_INT),
-- gaim_value_new(GAIM_TYPE_INT));
-+ gaim2_plugin_ipc_register(plugin, "add", GAIM_CALLBACK(add_func),
-+ gaim2_marshal_INT__INT_INT,
-+ gaim2_value_new(GAIM_TYPE_INT), 2,
-+ gaim2_value_new(GAIM_TYPE_INT),
-+ gaim2_value_new(GAIM_TYPE_INT));
-+
-+ gaim2_plugin_ipc_register(plugin, "sub", GAIM_CALLBACK(sub_func),
-+ gaim2_marshal_INT__INT_INT,
-+ gaim2_value_new(GAIM_TYPE_INT), 2,
-+ gaim2_value_new(GAIM_TYPE_INT),
-+ gaim2_value_new(GAIM_TYPE_INT));
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -92,7 +92,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/log_reader.c ./plugins/log_reader.c
---- ./plugins/log_reader.c 2006-01-05 04:14:51.000000000 +0100
-+++ ./plugins/log_reader.c 2006-01-05 15:27:38.000000000 +0100
-@@ -20,7 +20,7 @@
- #include "version.h"
- #include "xmlnode.h"
-
--/* This must be the last Gaim header included. */
-+/* This must be the last Gaim2 header included. */
- #ifdef _WIN32
- #include "win32dep.h"
- #endif
-@@ -45,7 +45,7 @@ enum name_guesses {
- * Adium logs in the log viewer transparently.
- */
-
--static GaimLogLogger *adium_logger;
-+static Gaim2LogLogger *adium_logger;
-
- enum adium_log_type {
- ADIUM_HTML,
-@@ -57,12 +57,12 @@ struct adium_logger_data {
- enum adium_log_type type;
- };
-
--static GList *adium_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *adium_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
- GList *list = NULL;
- const char *logdir;
-- GaimPlugin *plugin;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *plugin;
-+ Gaim2PluginProtocolInfo *prpl_info;
- char *prpl_name;
- char *temp;
- char *path;
-@@ -71,13 +71,13 @@ static GList *adium_logger_list(GaimLogT
- g_return_val_if_fail(sn != NULL, list);
- g_return_val_if_fail(account != NULL, list);
-
-- logdir = gaim_prefs_get_string("/plugins/core/log_reader/adium/log_directory");
-+ logdir = gaim2_prefs_get_string("/plugins/core/log_reader/adium/log_directory");
-
- /* By clearing the log directory path, this logger can be (effectively) disabled. */
- if (!*logdir)
- return list;
-
-- plugin = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ plugin = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
- if (!plugin)
- return NULL;
-
-@@ -106,7 +106,7 @@ static GList *adium_logger_list(GaimLogT
- if (sscanf(date, "%u|%u|%u",
- &tm.tm_year, &tm.tm_mon, &tm.tm_mday) != 3) {
-
-- gaim_debug(GAIM_DEBUG_ERROR, "Adium log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Adium log parse",
- "Filename timestamp parsing error\n");
- } else {
- char *filename = g_build_filename(path, file, NULL);
-@@ -114,7 +114,7 @@ static GList *adium_logger_list(GaimLogT
- char *contents;
- char *contents2;
- struct adium_logger_data *data;
-- GaimLog *log;
-+ Gaim2Log *log;
-
- if (!handle) {
- g_free(filename);
-@@ -141,7 +141,7 @@ static GList *adium_logger_list(GaimLogT
- if (sscanf(contents2, "%u.%u.%u",
- &tm.tm_hour, &tm.tm_min, &tm.tm_sec) != 3) {
-
-- gaim_debug(GAIM_DEBUG_ERROR, "Adium log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Adium log parse",
- "Contents timestamp parsing error\n");
- g_free(contents);
- g_free(filename);
-@@ -156,7 +156,7 @@ static GList *adium_logger_list(GaimLogT
- tm.tm_year -= 1900;
- tm.tm_mon -= 1;
-
-- log = gaim_log_new(GAIM_LOG_IM, sn, account, NULL, mktime(&tm));
-+ log = gaim2_log_new(GAIM_LOG_IM, sn, account, NULL, mktime(&tm));
- log->logger = adium_logger;
- log->logger_data = data;
-
-@@ -170,7 +170,7 @@ static GList *adium_logger_list(GaimLogT
- if (sscanf(date, "%u|%u|%u",
- &tm.tm_year, &tm.tm_mon, &tm.tm_mday) != 3) {
-
-- gaim_debug(GAIM_DEBUG_ERROR, "Adium log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Adium log parse",
- "Filename timestamp parsing error\n");
- } else {
- char *filename = g_build_filename(path, file, NULL);
-@@ -178,7 +178,7 @@ static GList *adium_logger_list(GaimLogT
- char *contents;
- char *contents2;
- struct adium_logger_data *data;
-- GaimLog *log;
-+ Gaim2Log *log;
-
- if (!handle) {
- g_free(filename);
-@@ -200,7 +200,7 @@ static GList *adium_logger_list(GaimLogT
- if (sscanf(contents2, "%u.%u.%u",
- &tm.tm_hour, &tm.tm_min, &tm.tm_sec) != 3) {
-
-- gaim_debug(GAIM_DEBUG_ERROR, "Adium log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Adium log parse",
- "Contents timestamp parsing error\n");
- g_free(contents);
- g_free(filename);
-@@ -216,7 +216,7 @@ static GList *adium_logger_list(GaimLogT
- data->path = filename;
- data->type = ADIUM_TEXT;
-
-- log = gaim_log_new(GAIM_LOG_IM, sn, account, NULL, mktime(&tm));
-+ log = gaim2_log_new(GAIM_LOG_IM, sn, account, NULL, mktime(&tm));
- log->logger = adium_logger;
- log->logger_data = data;
-
-@@ -233,7 +233,7 @@ static GList *adium_logger_list(GaimLogT
- return list;
- }
-
--static char *adium_logger_read (GaimLog *log, GaimLogReadFlags *flags)
-+static char *adium_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- struct adium_logger_data *data;
- GError *error = NULL;
-@@ -246,10 +246,10 @@ static char *adium_logger_read (GaimLog
-
- g_return_val_if_fail(data->path != NULL, g_strdup(""));
-
-- gaim_debug(GAIM_DEBUG_INFO, "Adium log read",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Adium log read",
- "Reading %s\n", data->path);
- if (!g_file_get_contents(data->path, &read, &length, &error)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "Adium log read",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Adium log read",
- "Error reading log\n");
- if (error)
- g_error_free(error);
-@@ -283,7 +283,7 @@ static char *adium_logger_read (GaimLog
- return read;
- }
-
--static int adium_logger_size (GaimLog *log)
-+static int adium_logger_size (Gaim2Log *log)
- {
- struct adium_logger_data *data;
- char *text;
-@@ -293,7 +293,7 @@ static int adium_logger_size (GaimLog *l
-
- data = log->logger_data;
-
-- if (gaim_prefs_get_bool("/plugins/core/log_reader/fast_sizes")) {
-+ if (gaim2_prefs_get_bool("/plugins/core/log_reader/fast_sizes")) {
- struct stat st;
-
- if (!data->path || stat(data->path, &st))
-@@ -309,7 +309,7 @@ static int adium_logger_size (GaimLog *l
- return size;
- }
-
--static void adium_logger_finalize(GaimLog *log)
-+static void adium_logger_finalize(Gaim2Log *log)
- {
- struct adium_logger_data *data;
-
-@@ -329,18 +329,18 @@ static void adium_logger_finalize(GaimLo
- * Fire logs in the log viewer transparently.
- */
-
--static GaimLogLogger *fire_logger;
-+static Gaim2LogLogger *fire_logger;
-
- struct fire_logger_data {
- };
-
--static GList *fire_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *fire_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
- /* TODO: Do something here. */
- return NULL;
- }
-
--static char * fire_logger_read (GaimLog *log, GaimLogReadFlags *flags)
-+static char * fire_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- struct fire_logger_data *data;
-
-@@ -352,18 +352,18 @@ static char * fire_logger_read (GaimLog
- return g_strdup("");
- }
-
--static int fire_logger_size (GaimLog *log)
-+static int fire_logger_size (Gaim2Log *log)
- {
- g_return_val_if_fail(log != NULL, 0);
-
-- if (gaim_prefs_get_bool("/plugins/core/log_reader/fast_sizes"))
-+ if (gaim2_prefs_get_bool("/plugins/core/log_reader/fast_sizes"))
- return 0;
-
- /* TODO: Do something here. */
- return 0;
- }
-
--static void fire_logger_finalize(GaimLog *log)
-+static void fire_logger_finalize(Gaim2Log *log)
- {
- g_return_if_fail(log != NULL);
-
-@@ -379,18 +379,18 @@ static void fire_logger_finalize(GaimLog
- * Messenger Plus! logs in the log viewer transparently.
- */
-
--static GaimLogLogger *messenger_plus_logger;
-+static Gaim2LogLogger *messenger_plus_logger;
-
- struct messenger_plus_logger_data {
- };
-
--static GList *messenger_plus_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *messenger_plus_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
- /* TODO: Do something here. */
- return NULL;
- }
-
--static char * messenger_plus_logger_read (GaimLog *log, GaimLogReadFlags *flags)
-+static char * messenger_plus_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- struct messenger_plus_logger_data *data = log->logger_data;
-
-@@ -402,18 +402,18 @@ static char * messenger_plus_logger_read
- return g_strdup("");
- }
-
--static int messenger_plus_logger_size (GaimLog *log)
-+static int messenger_plus_logger_size (Gaim2Log *log)
- {
- g_return_val_if_fail(log != NULL, 0);
-
-- if (gaim_prefs_get_bool("/plugins/core/log_reader/fast_sizes"))
-+ if (gaim2_prefs_get_bool("/plugins/core/log_reader/fast_sizes"))
- return 0;
-
- /* TODO: Do something here. */
- return 0;
- }
-
--static void messenger_plus_logger_finalize(GaimLog *log)
-+static void messenger_plus_logger_finalize(Gaim2Log *log)
- {
- g_return_if_fail(log != NULL);
-
-@@ -429,7 +429,7 @@ static void messenger_plus_logger_finali
- * MSN Messenger message histories in the log viewer transparently.
- */
-
--static GaimLogLogger *msn_logger;
-+static Gaim2LogLogger *msn_logger;
-
- struct msn_logger_data {
- xmlnode *root;
-@@ -450,24 +450,24 @@ static time_t msn_logger_parse_timestamp
-
- date = xmlnode_get_attrib(message, "Date");
- if (!(date && *date)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
- "Attribute missing: %s\n", "Date");
- return (time_t)0;
- }
-
- time = xmlnode_get_attrib(message, "Time");
- if (!(time && *time)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
- "Attribute missing: %s\n", "Time");
- return (time_t)0;
- }
-
- if (sscanf(date, "%u/%u/%u", &tm.tm_mon, &tm.tm_mday, &tm.tm_year) != 3)
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
- "%s parsing error\n", "Date");
-
- if (sscanf(time, "%u:%u:%u %c", &tm.tm_hour, &tm.tm_min, &tm.tm_sec, &am_pm) != 4)
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log timestamp parse",
- "%s parsing error\n", "Time");
-
- tm.tm_year -= 1900;
-@@ -485,11 +485,11 @@ static time_t msn_logger_parse_timestamp
- }
-
-
--static GList *msn_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *msn_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
- GList *list = NULL;
- char *username;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- const char *logdir;
- const char *savedfilename = NULL;
- char *logfile;
-@@ -508,15 +508,15 @@ static GList *msn_logger_list(GaimLogTyp
- if (strcmp(account->protocol_id, "prpl-msn"))
- return list;
-
-- logdir = gaim_prefs_get_string("/plugins/core/log_reader/msn/log_directory");
-+ logdir = gaim2_prefs_get_string("/plugins/core/log_reader/msn/log_directory");
-
- /* By clearing the log directory path, this logger can be (effectively) disabled. */
- if (!*logdir)
- return list;
-
-- buddy = gaim_find_buddy(account, sn);
-+ buddy = gaim2_find_buddy(account, sn);
-
-- if ((username = g_strdup(gaim_account_get_string(
-+ if ((username = g_strdup(gaim2_account_get_string(
- account, "log_reader_msn_log_folder", NULL)))) {
- /* As a special case, we allow the null string to kill the parsing
- * straight away. This would allow the user to deal with the case
-@@ -528,11 +528,11 @@ static GList *msn_logger_list(GaimLogTyp
- return list;
- }
- } else {
-- username = g_strdup(gaim_normalize(account, account->username));
-+ username = g_strdup(gaim2_normalize(account, account->username));
- }
-
- if (buddy)
-- savedfilename = gaim_blist_node_get_string(&buddy->node, "log_reader_msn_log_filename");
-+ savedfilename = gaim2_blist_node_get_string(&buddy->node, "log_reader_msn_log_filename");
-
- if (savedfilename) {
- /* As a special case, we allow the null string to kill the parsing
-@@ -547,7 +547,7 @@ static GList *msn_logger_list(GaimLogTyp
-
- logfile = g_strdup(savedfilename);
- } else {
-- logfile = g_strdup_printf("%s.xml", gaim_normalize(account, sn));
-+ logfile = g_strdup_printf("%s.xml", gaim2_normalize(account, sn));
- }
-
- path = g_build_filename(logdir, username, "History", logfile, NULL);
-@@ -602,7 +602,7 @@ static GList *msn_logger_list(GaimLogTyp
- char *history_path = g_build_filename(
- path, "History", NULL);
- if (g_file_test(history_path, G_FILE_TEST_IS_DIR)) {
-- gaim_account_set_string(account,
-+ gaim2_account_set_string(account,
- "log_reader_msn_log_folder", name);
- g_free(path);
- path = history_path;
-@@ -626,7 +626,7 @@ static GList *msn_logger_list(GaimLogTyp
-
- /* If we've reached this point, we've found a History folder. */
-
-- username = g_strdup(gaim_normalize(account, sn));
-+ username = g_strdup(gaim2_normalize(account, sn));
- at_sign = g_strrstr(username, "@");
- if (at_sign)
- *at_sign = '\0';
-@@ -675,11 +675,11 @@ static GList *msn_logger_list(GaimLogTyp
- logfile = NULL; /* No sense saving the obvious buddy@domain.com. */
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "MSN log read",
-+ gaim2_debug(GAIM_DEBUG_INFO, "MSN log read",
- "Reading %s\n", path);
- if (!g_file_get_contents(path, &contents, &length, &error)) {
- g_free(path);
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log read",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log read",
- "Error reading log\n");
- if (error)
- g_error_free(error);
-@@ -696,7 +696,7 @@ static GList *msn_logger_list(GaimLogTyp
- * I can't think of how buddy would be NULL.
- */
- if (buddy && logfile) {
-- gaim_blist_node_set_string(&buddy->node, "log_reader_msn_log_filename", logfile);
-+ gaim2_blist_node_set_string(&buddy->node, "log_reader_msn_log_filename", logfile);
- g_free(logfile);
- }
-
-@@ -711,7 +711,7 @@ static GList *msn_logger_list(GaimLogTyp
-
- session_id = xmlnode_get_attrib(message, "SessionID");
- if (!session_id) {
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log parse",
- "Error parsing message: %s\n", "SessionID missing");
- continue;
- }
-@@ -721,7 +721,7 @@ static GList *msn_logger_list(GaimLogTyp
- * The session ID differs from the last message.
- * Thus, this is the start of a new conversation.
- */
-- GaimLog *log;
-+ Gaim2Log *log;
-
- data = g_new0(struct msn_logger_data, 1);
- data->root = root;
-@@ -730,7 +730,7 @@ static GList *msn_logger_list(GaimLogTyp
- data->text = NULL;
- data->last_log = FALSE;
-
-- log = gaim_log_new(GAIM_LOG_IM, sn, account, NULL, msn_logger_parse_timestamp(message));
-+ log = gaim2_log_new(GAIM_LOG_IM, sn, account, NULL, msn_logger_parse_timestamp(message));
- log->logger = msn_logger;
- log->logger_data = data;
-
-@@ -745,7 +745,7 @@ static GList *msn_logger_list(GaimLogTyp
- return list;
- }
-
--static char * msn_logger_read (GaimLog *log, GaimLogReadFlags *flags)
-+static char * msn_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- struct msn_logger_data *data;
- GString *text = NULL;
-@@ -768,7 +768,7 @@ static char * msn_logger_read (GaimLog *
-
- if (!data->root || !data->message || !data->session_id) {
- /* Something isn't allocated correctly. */
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log parse",
- "Error parsing message: %s\n", "Internal variables inconsistent");
- data->text = text;
-
-@@ -795,7 +795,7 @@ static char * msn_logger_read (GaimLog *
-
- /* If this triggers, something is wrong with the XML. */
- if (!new_session_id) {
-- gaim_debug(GAIM_DEBUG_ERROR, "MSN log parse",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "MSN log parse",
- "Error parsing message: %s\n", "New SessionID missing");
- break;
- }
-@@ -837,13 +837,13 @@ static char * msn_logger_read (GaimLog *
- }
-
- their_name = from_name;
-- if (from_name && gaim_prefs_get_bool("/plugins/core/log_reader/use_name_heuristics")) {
-- const char *friendly_name = gaim_connection_get_display_name(log->account->gc);
-+ if (from_name && gaim2_prefs_get_bool("/plugins/core/log_reader/use_name_heuristics")) {
-+ const char *friendly_name = gaim2_connection_get_display_name(log->account->gc);
-
- if (friendly_name != NULL) {
- int friendly_name_length = strlen(friendly_name);
- int alias_length = strlen(log->account->alias);
-- GaimBuddy *buddy = gaim_find_buddy(log->account, log->name);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(log->account, log->name);
- gboolean from_name_matches;
- gboolean to_name_matches;
-
-@@ -998,14 +998,14 @@ static char * msn_logger_read (GaimLog *
- return text->str;
- }
-
--static int msn_logger_size (GaimLog *log)
-+static int msn_logger_size (Gaim2Log *log)
- {
- char *text;
- size_t size;
-
- g_return_val_if_fail(log != NULL, 0);
-
-- if (gaim_prefs_get_bool("/plugins/core/log_reader/fast_sizes"))
-+ if (gaim2_prefs_get_bool("/plugins/core/log_reader/fast_sizes"))
- return 0;
-
- text = msn_logger_read(log, NULL);
-@@ -1015,7 +1015,7 @@ static int msn_logger_size (GaimLog *log
- return size;
- }
-
--static void msn_logger_finalize(GaimLog *log)
-+static void msn_logger_finalize(Gaim2Log *log)
- {
- struct msn_logger_data *data;
-
-@@ -1039,22 +1039,22 @@ static void msn_logger_finalize(GaimLog
- * Trillian logs in the log viewer transparently.
- */
-
--static GaimLogLogger *trillian_logger;
--static void trillian_logger_finalize(GaimLog *log);
-+static Gaim2LogLogger *trillian_logger;
-+static void trillian_logger_finalize(Gaim2Log *log);
-
- struct trillian_logger_data {
-- char *path; /* FIXME: Change this to use GaimStringref like log.c:old_logger_list */
-+ char *path; /* FIXME: Change this to use Gaim2Stringref like log.c:old_logger_list */
- int offset;
- int length;
- char *their_nickname;
- };
-
--static GList *trillian_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *trillian_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
- GList *list = NULL;
- const char *logdir;
-- GaimPlugin *plugin;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *plugin;
-+ Gaim2PluginProtocolInfo *prpl_info;
- char *prpl_name;
- const char *buddy_name;
- char *filename;
-@@ -1068,13 +1068,13 @@ static GList *trillian_logger_list(GaimL
- g_return_val_if_fail(sn != NULL, list);
- g_return_val_if_fail(account != NULL, list);
-
-- logdir = gaim_prefs_get_string("/plugins/core/log_reader/trillian/log_directory");
-+ logdir = gaim2_prefs_get_string("/plugins/core/log_reader/trillian/log_directory");
-
- /* By clearing the log directory path, this logger can be (effectively) disabled. */
- if (!*logdir)
- return list;
-
-- plugin = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ plugin = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
- if (!plugin)
- return NULL;
-
-@@ -1084,13 +1084,13 @@ static GList *trillian_logger_list(GaimL
-
- prpl_name = g_ascii_strup(prpl_info->list_icon(account, NULL), -1);
-
-- buddy_name = gaim_normalize(account, sn);
-+ buddy_name = gaim2_normalize(account, sn);
-
- filename = g_strdup_printf("%s.log", buddy_name);
- path = g_build_filename(
- logdir, prpl_name, filename, NULL);
-
-- gaim_debug(GAIM_DEBUG_INFO, "Trillian log list",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Trillian log list",
- "Reading %s\n", path);
- /* FIXME: There's really no need to read the entire file at once.
- * See src/log.c:old_logger_list for a better approach.
-@@ -1104,7 +1104,7 @@ static GList *trillian_logger_list(GaimL
-
- path = g_build_filename(
- logdir, prpl_name, "Query", filename, NULL);
-- gaim_debug(GAIM_DEBUG_INFO, "Trillian log list",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Trillian log list",
- "Reading %s\n", path);
- if (!g_file_get_contents(path, &contents, &length, &error)) {
- if (error)
-@@ -1136,10 +1136,10 @@ static GList *trillian_logger_list(GaimL
- /* This log had no data, so we remove it. */
- GList *last = g_list_last(list);
-
-- gaim_debug(GAIM_DEBUG_INFO, "Trillian log list",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Trillian log list",
- "Empty log. Offset %i\n", data->offset);
-
-- trillian_logger_finalize((GaimLog *)last->data);
-+ trillian_logger_finalize((Gaim2Log *)last->data);
- list = g_list_delete_link(list, last);
- }
- } else if (line[0] && line[1] && line [3] &&
-@@ -1193,11 +1193,11 @@ static GList *trillian_logger_list(GaimL
- &tm.tm_min, &tm.tm_sec,
- &tm.tm_year) != 5) {
-
-- gaim_debug(GAIM_DEBUG_ERROR,
-+ gaim2_debug(GAIM_DEBUG_ERROR,
- "Trillian log timestamp parse",
- "Session Start parsing error\n");
- } else {
-- GaimLog *log;
-+ Gaim2Log *log;
-
- tm.tm_year -= 1900;
-
-@@ -1244,7 +1244,7 @@ static GList *trillian_logger_list(GaimL
- data->their_nickname =
- g_strdup(their_nickname);
-
-- log = gaim_log_new(GAIM_LOG_IM,
-+ log = gaim2_log_new(GAIM_LOG_IM,
- sn, account, NULL, mktime(&tm));
- log->logger = trillian_logger;
- log->logger_data = data;
-@@ -1267,12 +1267,12 @@ static GList *trillian_logger_list(GaimL
- return list;
- }
-
--static char * trillian_logger_read (GaimLog *log, GaimLogReadFlags *flags)
-+static char * trillian_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- struct trillian_logger_data *data;
- char *read;
- FILE *file;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- char *escaped;
- GString *formatted;
- char *c;
-@@ -1286,7 +1286,7 @@ static char * trillian_logger_read (Gaim
- g_return_val_if_fail(data->length > 0, g_strdup(""));
- g_return_val_if_fail(data->their_nickname != NULL, g_strdup(""));
-
-- gaim_debug(GAIM_DEBUG_INFO, "Trillian log read",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Trillian log read",
- "Reading %s\n", data->path);
-
- read = g_malloc(data->length + 2);
-@@ -1304,7 +1304,7 @@ static char * trillian_logger_read (Gaim
- }
-
- /* Load miscellaneous data. */
-- buddy = gaim_find_buddy(log->account, log->name);
-+ buddy = gaim2_find_buddy(log->account, log->name);
-
- escaped = g_markup_escape_text(read, -1);
- g_free(read);
-@@ -1387,7 +1387,7 @@ static char * trillian_logger_read (Gaim
- if (*timestamp == ']') {
- *timestamp = '\0';
- line++;
-- /* TODO: Parse the timestamp and convert it to Gaim's format. */
-+ /* TODO: Parse the timestamp and convert it to Gaim2's format. */
- g_string_append_printf(formatted,
- "<font size=\"2\">(%s)</font> ", line);
- line = timestamp;
-@@ -1523,7 +1523,7 @@ static char * trillian_logger_read (Gaim
- return read;
- }
-
--static int trillian_logger_size (GaimLog *log)
-+static int trillian_logger_size (Gaim2Log *log)
- {
- struct trillian_logger_data *data;
- char *text;
-@@ -1533,7 +1533,7 @@ static int trillian_logger_size (GaimLog
-
- data = log->logger_data;
-
-- if (gaim_prefs_get_bool("/plugins/core/log_reader/fast_sizes")) {
-+ if (gaim2_prefs_get_bool("/plugins/core/log_reader/fast_sizes")) {
- return data ? data->length : 0;
- }
-
-@@ -1544,7 +1544,7 @@ static int trillian_logger_size (GaimLog
- return size;
- }
-
--static void trillian_logger_finalize(GaimLog *log)
-+static void trillian_logger_finalize(Gaim2Log *log)
- {
- struct trillian_logger_data *data;
-
-@@ -1563,7 +1563,7 @@ static void trillian_logger_finalize(Gai
- *****************************************************************************/
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- char *path;
- #ifdef _WIN32
-@@ -1572,27 +1572,27 @@ init_plugin(GaimPlugin *plugin)
-
- g_return_if_fail(plugin != NULL);
-
-- gaim_prefs_add_none("/plugins/core/log_reader");
-+ gaim2_prefs_add_none("/plugins/core/log_reader");
-
-
- /* Add general preferences. */
-
-- gaim_prefs_add_bool("/plugins/core/log_reader/fast_sizes", FALSE);
-- gaim_prefs_add_bool("/plugins/core/log_reader/use_name_heuristics", TRUE);
-+ gaim2_prefs_add_bool("/plugins/core/log_reader/fast_sizes", FALSE);
-+ gaim2_prefs_add_bool("/plugins/core/log_reader/use_name_heuristics", TRUE);
-
-
- /* Add Adium log directory preference. */
-- gaim_prefs_add_none("/plugins/core/log_reader/adium");
-+ gaim2_prefs_add_none("/plugins/core/log_reader/adium");
-
- /* Calculate default Adium log directory. */
- #ifdef _WIN32
- path = "";
- #else
-- path = g_build_filename(gaim_home_dir(), "Library", "Application Support",
-+ path = g_build_filename(gaim2_home_dir(), "Library", "Application Support",
- "Adium 2.0", "Users", "Default", "Logs", NULL);
- #endif
-
-- gaim_prefs_add_string("/plugins/core/log_reader/adium/log_directory", path);
-+ gaim2_prefs_add_string("/plugins/core/log_reader/adium/log_directory", path);
-
- #ifndef _WIN32
- g_free(path);
-@@ -1600,17 +1600,17 @@ init_plugin(GaimPlugin *plugin)
-
-
- /* Add Fire log directory preference. */
-- gaim_prefs_add_none("/plugins/core/log_reader/fire");
-+ gaim2_prefs_add_none("/plugins/core/log_reader/fire");
-
- /* Calculate default Fire log directory. */
- #ifdef _WIN32
- path = "";
- #else
-- path = g_build_filename(gaim_home_dir(), "Library", "Application Support",
-+ path = g_build_filename(gaim2_home_dir(), "Library", "Application Support",
- "Fire", "Sessions", NULL);
- #endif
-
-- gaim_prefs_add_string("/plugins/core/log_reader/fire/log_directory", path);
-+ gaim2_prefs_add_string("/plugins/core/log_reader/fire/log_directory", path);
-
- #ifndef _WIN32
- g_free(path);
-@@ -1618,11 +1618,11 @@ init_plugin(GaimPlugin *plugin)
-
-
- /* Add Messenger Plus! log directory preference. */
-- gaim_prefs_add_none("/plugins/core/log_reader/messenger_plus");
-+ gaim2_prefs_add_none("/plugins/core/log_reader/messenger_plus");
-
- /* Calculate default Messenger Plus! log directory. */
- #ifdef _WIN32
-- folder = wgaim_get_special_folder(CSIDL_PERSONAL);
-+ folder = wgaim2_get_special_folder(CSIDL_PERSONAL);
- if (folder) {
- #endif
- path = g_build_filename(
-@@ -1639,16 +1639,16 @@ init_plugin(GaimPlugin *plugin)
- path = g_strdup("");
- #endif
-
-- gaim_prefs_add_string("/plugins/core/log_reader/messenger_plus/log_directory", path);
-+ gaim2_prefs_add_string("/plugins/core/log_reader/messenger_plus/log_directory", path);
- g_free(path);
-
-
- /* Add MSN Messenger log directory preference. */
-- gaim_prefs_add_none("/plugins/core/log_reader/msn");
-+ gaim2_prefs_add_none("/plugins/core/log_reader/msn");
-
- /* Calculate default MSN message history directory. */
- #ifdef _WIN32
-- folder = wgaim_get_special_folder(CSIDL_PERSONAL);
-+ folder = wgaim2_get_special_folder(CSIDL_PERSONAL);
- if (folder) {
- #endif
- path = g_build_filename(
-@@ -1665,12 +1665,12 @@ init_plugin(GaimPlugin *plugin)
- path = g_strdup("");
- #endif
-
-- gaim_prefs_add_string("/plugins/core/log_reader/msn/log_directory", path);
-+ gaim2_prefs_add_string("/plugins/core/log_reader/msn/log_directory", path);
- g_free(path);
-
-
- /* Add Trillian log directory preference. */
-- gaim_prefs_add_none("/plugins/core/log_reader/trillian");
-+ gaim2_prefs_add_none("/plugins/core/log_reader/trillian");
-
- #ifdef _WIN32
- /* XXX: While a major hack, this is the most reliable way I could
-@@ -1717,7 +1717,7 @@ init_plugin(GaimPlugin *plugin)
- }
-
- if (!path) {
-- char *folder = wgaim_get_special_folder(CSIDL_PROGRAM_FILES);
-+ char *folder = wgaim2_get_special_folder(CSIDL_PROGRAM_FILES);
- if (folder)
- path = g_build_filename(folder, "Trillian",
- "users", "default", "talk.ini", NULL);
-@@ -1734,24 +1734,24 @@ init_plugin(GaimPlugin *plugin)
- #if 0 && GTK_CHECK_VERSION(2,6,0) /* FIXME: Not tested yet. */
- GKeyFile *key_file;
-
-- gaim_debug(GAIM_DEBUG_INFO, "Trillian talk.ini read",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Trillian talk.ini read",
- "Reading %s\n", path);
- if (!g_key_file_load_from_file(key_file, path, G_KEY_FILE_NONE, GError &error)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "Trillian talk.ini read",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Trillian talk.ini read",
- "Error reading talk.ini\n");
- if (error)
- g_error_free(error);
- } else {
- char *logdir = g_key_file_get_string(key_file, "Logging", "Directory", &error);
- if (error) {
-- gaim_debug(GAIM_DEBUG_ERROR, "Trillian talk.ini read",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Trillian talk.ini read",
- "Error reading Directory value from Logging section\n");
- g_error_free(error);
- }
-
- if (logdir) {
- g_strchomp(logdir);
-- gaim_prefs_add_string(
-+ gaim2_prefs_add_string(
- "/plugins/core/log_reader/trillian/log_directory", logdir);
- found = TRUE;
- }
-@@ -1762,10 +1762,10 @@ init_plugin(GaimPlugin *plugin)
- GError *error = NULL;
- gsize length;
-
-- gaim_debug(GAIM_DEBUG_INFO, "Trillian talk.ini read",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Trillian talk.ini read",
- "Reading %s\n", path);
- if (!g_file_get_contents(path, &contents, &length, &error)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "Trillian talk.ini read",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Trillian talk.ini read",
- "Error reading talk.ini\n");
- if (error)
- g_error_free(error);
-@@ -1779,7 +1779,7 @@ init_plugin(GaimPlugin *plugin)
- if (g_str_has_prefix(line, "Directory=")) {
- line += (sizeof("Directory=") - 1);
- g_strchomp(line);
-- gaim_prefs_add_string(
-+ gaim2_prefs_add_string(
- "/plugins/core/log_reader/trillian/log_directory",
- line);
- found = TRUE;
-@@ -1801,7 +1801,7 @@ init_plugin(GaimPlugin *plugin)
-
- /* Calculate default Trillian log directory. */
- #ifdef _WIN32
-- folder = wgaim_get_special_folder(CSIDL_PROGRAM_FILES);
-+ folder = wgaim2_get_special_folder(CSIDL_PROGRAM_FILES);
- if (folder) {
- #endif
- path = g_build_filename(
-@@ -1817,7 +1817,7 @@ init_plugin(GaimPlugin *plugin)
- path = g_strdup("");
- #endif
-
-- gaim_prefs_add_string("/plugins/core/log_reader/trillian/log_directory", path);
-+ gaim2_prefs_add_string("/plugins/core/log_reader/trillian/log_directory", path);
- g_free(path);
-
- #ifdef _WIN32
-@@ -1826,132 +1826,132 @@ init_plugin(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-- adium_logger = gaim_log_logger_new("adium", "Adium", 6,
-+ adium_logger = gaim2_log_logger_new("adium", "Adium", 6,
- NULL,
- NULL,
- adium_logger_finalize,
- adium_logger_list,
- adium_logger_read,
- adium_logger_size);
-- gaim_log_logger_add(adium_logger);
-+ gaim2_log_logger_add(adium_logger);
-
-- fire_logger = gaim_log_logger_new("fire", "Fire", 6,
-+ fire_logger = gaim2_log_logger_new("fire", "Fire", 6,
- NULL,
- NULL,
- fire_logger_finalize,
- fire_logger_list,
- fire_logger_read,
- fire_logger_size);
-- gaim_log_logger_add(fire_logger);
-+ gaim2_log_logger_add(fire_logger);
-
-- messenger_plus_logger = gaim_log_logger_new("messenger_plus", "Messenger Plus!", 6,
-+ messenger_plus_logger = gaim2_log_logger_new("messenger_plus", "Messenger Plus!", 6,
- NULL,
- NULL,
- messenger_plus_logger_finalize,
- messenger_plus_logger_list,
- messenger_plus_logger_read,
- messenger_plus_logger_size);
-- gaim_log_logger_add(messenger_plus_logger);
-+ gaim2_log_logger_add(messenger_plus_logger);
-
-- msn_logger = gaim_log_logger_new("msn", "MSN Messenger", 6,
-+ msn_logger = gaim2_log_logger_new("msn", "MSN Messenger", 6,
- NULL,
- NULL,
- msn_logger_finalize,
- msn_logger_list,
- msn_logger_read,
- msn_logger_size);
-- gaim_log_logger_add(msn_logger);
-+ gaim2_log_logger_add(msn_logger);
-
-- trillian_logger = gaim_log_logger_new("trillian", "Trillian", 6,
-+ trillian_logger = gaim2_log_logger_new("trillian", "Trillian", 6,
- NULL,
- NULL,
- trillian_logger_finalize,
- trillian_logger_list,
- trillian_logger_read,
- trillian_logger_size);
-- gaim_log_logger_add(trillian_logger);
-+ gaim2_log_logger_add(trillian_logger);
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-- gaim_log_logger_remove(adium_logger);
-- gaim_log_logger_remove(fire_logger);
-- gaim_log_logger_remove(messenger_plus_logger);
-- gaim_log_logger_remove(msn_logger);
-- gaim_log_logger_remove(trillian_logger);
-+ gaim2_log_logger_remove(adium_logger);
-+ gaim2_log_logger_remove(fire_logger);
-+ gaim2_log_logger_remove(messenger_plus_logger);
-+ gaim2_log_logger_remove(msn_logger);
-+ gaim2_log_logger_remove(trillian_logger);
-
- return TRUE;
- }
-
--static GaimPluginPrefFrame *
--get_plugin_pref_frame(GaimPlugin *plugin)
-+static Gaim2PluginPrefFrame *
-+get_plugin_pref_frame(Gaim2Plugin *plugin)
- {
-- GaimPluginPrefFrame *frame;
-- GaimPluginPref *ppref;
-+ Gaim2PluginPrefFrame *frame;
-+ Gaim2PluginPref *ppref;
-
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-- frame = gaim_plugin_pref_frame_new();
-+ frame = gaim2_plugin_pref_frame_new();
-
-
- /* Add general preferences. */
-
-- ppref = gaim_plugin_pref_new_with_label(_("General Log Reading Configuration"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label(_("General Log Reading Configuration"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/fast_sizes", _("Fast size calculations"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/use_name_heuristics", _("Use name heuristics"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-
- /* Add Log Directory preferences. */
-
-- ppref = gaim_plugin_pref_new_with_label(_("Log Directory"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label(_("Log Directory"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/adium/log_directory", _("Adium"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/fire/log_directory", _("Fire"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/messenger_plus/log_directory", _("Messenger Plus!"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/msn/log_directory", _("MSN Messenger"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/log_reader/trillian/log_directory", _("Trillian"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
- return frame;
- }
-
--static GaimPluginUiInfo prefs_info = {
-+static Gaim2PluginUiInfo prefs_info = {
- get_plugin_pref_frame,
- 0, /* page_num (reserved) */
- NULL /* frame (reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-diff -prNu ./plugins/mailchk.c ./plugins/mailchk.c
---- ./plugins/mailchk.c 2005-10-12 04:27:32.000000000 +0200
-+++ ./plugins/mailchk.c 2006-01-05 15:27:38.000000000 +0100
-@@ -55,7 +55,7 @@ static gboolean
- check_timeout(gpointer data)
- {
- gint count = check_mail();
-- GaimBuddyList *list = gaim_get_blist();
-+ Gaim2BuddyList *list = gaim2_get_blist();
-
- if (count == -1)
- return FALSE;
-@@ -75,7 +75,7 @@ check_timeout(gpointer data)
- }
-
- if (count & NEW_MAIL)
-- gaim_sound_play_event(GAIM_SOUND_POUNCE_DEFAULT, NULL);
-+ gaim2_sound_play_event(GAIM_SOUND_POUNCE_DEFAULT, NULL);
-
- if (count & UNREAD_MAIL)
- gtk_label_set_text(GTK_LABEL(mail), "You have new mail!");
-@@ -88,9 +88,9 @@ check_timeout(gpointer data)
- }
-
- static void
--signon_cb(GaimConnection *gc)
-+signon_cb(Gaim2Connection *gc)
- {
-- GaimBuddyList *list = gaim_get_blist();
-+ Gaim2BuddyList *list = gaim2_get_blist();
- if (list && GAIM_IS_GTK_BLIST(list) && !timer) {
- check_timeout(NULL); /* we want the box to be drawn immediately */
- timer = g_timeout_add(2000, check_timeout, NULL);
-@@ -98,9 +98,9 @@ signon_cb(GaimConnection *gc)
- }
-
- static void
--signoff_cb(GaimConnection *gc)
-+signoff_cb(Gaim2Connection *gc)
- {
-- GaimBuddyList *list = gaim_get_blist();
-+ Gaim2BuddyList *list = gaim2_get_blist();
- if ((!list || !GAIM_IS_GTK_BLIST(list) || !GAIM_GTK_BLIST(list)->vbox) && timer) {
- g_source_remove(timer);
- timer = 0;
-@@ -112,29 +112,29 @@ signoff_cb(GaimConnection *gc)
- */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- GaimBuddyList *list = gaim_get_blist();
-- void *conn_handle = gaim_connections_get_handle();
-+ Gaim2BuddyList *list = gaim2_get_blist();
-+ void *conn_handle = gaim2_connections_get_handle();
-
- if (!check_timeout(NULL)) {
-- gaim_debug_warning("mailchk", "Could not read $MAIL or /var/spool/mail/$USER");
-+ gaim2_debug_warning("mailchk", "Could not read $MAIL or /var/spool/mail/$USER");
- return FALSE;
- }
-
- if (list && GAIM_IS_GTK_BLIST(list) && GAIM_GTK_BLIST(list)->vbox)
- timer = g_timeout_add(2000, check_timeout, NULL);
-
-- gaim_signal_connect(conn_handle, "signed-on",
-+ gaim2_signal_connect(conn_handle, "signed-on",
- plugin, GAIM_CALLBACK(signon_cb), NULL);
-- gaim_signal_connect(conn_handle, "signed-off",
-+ gaim2_signal_connect(conn_handle, "signed-off",
- plugin, GAIM_CALLBACK(signoff_cb), NULL);
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- if (timer)
- g_source_remove(timer);
-@@ -146,7 +146,7 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -174,7 +174,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/Makefile.am ./plugins/Makefile.am
---- ./plugins/Makefile.am 2005-11-03 14:43:04.000000000 +0100
-+++ ./plugins/Makefile.am 2006-01-05 13:14:52.000000000 +0100
-@@ -34,7 +34,7 @@ SUBDIRS = \
- $(TCL_DIR) \
- ticker
-
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- extplacement_la_LDFLAGS = -module -avoid-version $(GLIB_LIBS)
- gaimrc_la_LDFLAGS = -module -avoid-version $(GTK_LIBS)
-diff -prNu ./plugins/mono/loader/blist-glue.c ./plugins/mono/loader/blist-glue.c
---- ./plugins/mono/loader/blist-glue.c 2005-12-09 13:52:45.000000000 +0100
-+++ ./plugins/mono/loader/blist-glue.c 2006-01-05 15:27:37.000000000 +0100
-@@ -3,24 +3,24 @@
- #include "mono-helper.h"
- #include "mono-glue.h"
-
--MonoObject* gaim_blist_get_handle_glue(void)
-+MonoObject* gaim2_blist_get_handle_glue(void)
- {
-- void *handle = gaim_blist_get_handle();
-+ void *handle = gaim2_blist_get_handle();
-
- return mono_value_box(ml_get_domain(), mono_get_intptr_class(), &handle);
- }
-
--MonoObject* gaim_blist_build_buddy_object(void* data)
-+MonoObject* gaim2_blist_build_buddy_object(void* data)
- {
- MonoObject *obj = NULL;
-
-- GaimBuddy *buddy = (GaimBuddy*)data;
-+ Gaim2Buddy *buddy = (Gaim2Buddy*)data;
-
- obj = ml_create_api_object("Buddy");
- g_return_val_if_fail(obj != NULL, NULL);
-
-- ml_set_prop_string(obj, "Name", (char*)gaim_buddy_get_name(buddy));
-- ml_set_prop_string(obj, "Alias", (char*)gaim_buddy_get_alias(buddy));
-+ ml_set_prop_string(obj, "Name", (char*)gaim2_buddy_get_name(buddy));
-+ ml_set_prop_string(obj, "Alias", (char*)gaim2_buddy_get_alias(buddy));
-
- return obj;
- }
-diff -prNu ./plugins/mono/loader/debug-glue.c ./plugins/mono/loader/debug-glue.c
---- ./plugins/mono/loader/debug-glue.c 2005-10-14 07:00:16.000000000 +0200
-+++ ./plugins/mono/loader/debug-glue.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- #include "mono-glue.h"
- #include "debug.h"
-
--void gaim_debug_glue(int type, MonoString *cat, MonoString *str)
-+void gaim2_debug_glue(int type, MonoString *cat, MonoString *str)
- {
- char *ccat;
- char *cstr;
-@@ -9,7 +9,7 @@ void gaim_debug_glue(int type, MonoStrin
- ccat = mono_string_to_utf8(cat);
- cstr = mono_string_to_utf8(str);
-
-- gaim_debug(type, ccat, cstr);
-+ gaim2_debug(type, ccat, cstr);
-
- g_free(ccat);
- g_free(cstr);
-diff -prNu ./plugins/mono/loader/mono.c ./plugins/mono/loader/mono.c
---- ./plugins/mono/loader/mono.c 2005-11-07 00:09:07.000000000 +0100
-+++ ./plugins/mono/loader/mono.c 2006-01-05 15:27:37.000000000 +0100
-@@ -22,7 +22,7 @@
- * Loader Stuff
- *****************************************************************************/
- /* probes the given plugin to determine if its a plugin */
--static gboolean probe_mono_plugin(GaimPlugin *plugin)
-+static gboolean probe_mono_plugin(Gaim2Plugin *plugin)
- {
- MonoAssembly *assm;
- MonoMethod *m = NULL;
-@@ -31,8 +31,8 @@ static gboolean probe_mono_plugin(GaimPl
- gboolean found_load = FALSE, found_unload = FALSE, found_destroy = FALSE, found_info = FALSE;
- gpointer iter = NULL;
-
-- GaimPluginInfo *info;
-- GaimMonoPlugin *mplug;
-+ Gaim2PluginInfo *info;
-+ Gaim2MonoPlugin *mplug;
-
- char *file = plugin->path;
-
-@@ -42,15 +42,15 @@ static gboolean probe_mono_plugin(GaimPl
- return FALSE;
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "Probing plugin\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "Probing plugin\n");
-
- if (ml_is_api_dll(mono_assembly_get_image(assm))) {
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "Found our GaimAPI.dll\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "Found our Gaim2API.dll\n");
- return FALSE;
- }
-
-- info = g_new0(GaimPluginInfo, 1);
-- mplug = g_new0(GaimMonoPlugin, 1);
-+ info = g_new0(Gaim2PluginInfo, 1);
-+ mplug = g_new0(Gaim2MonoPlugin, 1);
-
- mplug->signal_data = NULL;
-
-@@ -58,13 +58,13 @@ static gboolean probe_mono_plugin(GaimPl
-
- mplug->klass = ml_find_plugin_class(mono_assembly_get_image(mplug->assm));
- if (!mplug->klass) {
-- gaim_debug(GAIM_DEBUG_ERROR, "mono", "no plugin class in \'%s\'\n", file);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "mono", "no plugin class in \'%s\'\n", file);
- return FALSE;
- }
-
- mplug->obj = mono_object_new(ml_get_domain(), mplug->klass);
- if (!mplug->obj) {
-- gaim_debug(GAIM_DEBUG_ERROR, "mono", "obj not valid\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "mono", "obj not valid\n");
- return FALSE;
- }
-
-@@ -87,7 +87,7 @@ static gboolean probe_mono_plugin(GaimPl
- }
-
- if (!(found_load && found_unload && found_destroy && found_info)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "mono", "did not find the required methods\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "mono", "did not find the required methods\n");
- return FALSE;
- }
-
-@@ -117,17 +117,17 @@ static gboolean probe_mono_plugin(GaimPl
-
- ml_add_plugin(mplug);
-
-- return gaim_plugin_register(plugin);
-+ return gaim2_plugin_register(plugin);
- }
-
- /* Loads a Mono Plugin by calling 'load' in the class */
--static gboolean load_mono_plugin(GaimPlugin *plugin)
-+static gboolean load_mono_plugin(Gaim2Plugin *plugin)
- {
-- GaimMonoPlugin *mplug;
-+ Gaim2MonoPlugin *mplug;
-
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "Loading plugin\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "Loading plugin\n");
-
-- mplug = (GaimMonoPlugin*)plugin->info->extra_info;
-+ mplug = (Gaim2MonoPlugin*)plugin->info->extra_info;
-
- ml_invoke(mplug->load, mplug->obj, NULL);
-
-@@ -135,15 +135,15 @@ static gboolean load_mono_plugin(GaimPlu
- }
-
- /* Unloads a Mono Plugin by calling 'unload' in the class */
--static gboolean unload_mono_plugin(GaimPlugin *plugin)
-+static gboolean unload_mono_plugin(Gaim2Plugin *plugin)
- {
-- GaimMonoPlugin *mplug;
-+ Gaim2MonoPlugin *mplug;
-
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "Unloading plugin\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "Unloading plugin\n");
-
-- mplug = (GaimMonoPlugin*)plugin->info->extra_info;
-+ mplug = (Gaim2MonoPlugin*)plugin->info->extra_info;
-
-- gaim_signals_disconnect_by_handle((gpointer)mplug->klass);
-+ gaim2_signals_disconnect_by_handle((gpointer)mplug->klass);
- g_list_foreach(mplug->signal_data, (GFunc)g_free, NULL);
- g_list_free(mplug->signal_data);
- mplug->signal_data = NULL;
-@@ -153,13 +153,13 @@ static gboolean unload_mono_plugin(GaimP
- return TRUE;
- }
-
--static void destroy_mono_plugin(GaimPlugin *plugin)
-+static void destroy_mono_plugin(Gaim2Plugin *plugin)
- {
-- GaimMonoPlugin *mplug;
-+ Gaim2MonoPlugin *mplug;
-
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "Destroying plugin\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "Destroying plugin\n");
-
-- mplug = (GaimMonoPlugin*)plugin->info->extra_info;
-+ mplug = (Gaim2MonoPlugin*)plugin->info->extra_info;
-
- ml_invoke(mplug->destroy, mplug->obj, NULL);
-
-@@ -185,12 +185,12 @@ static void destroy_mono_plugin(GaimPlug
- /******************************************************************************
- * Plugin Stuff
- *****************************************************************************/
--static void plugin_destroy(GaimPlugin *plugin)
-+static void plugin_destroy(Gaim2Plugin *plugin)
- {
- ml_uninit();
- }
-
--static GaimPluginLoaderInfo loader_info =
-+static Gaim2PluginLoaderInfo loader_info =
- {
- NULL,
- probe_mono_plugin,
-@@ -199,7 +199,7 @@ static GaimPluginLoaderInfo loader_info
- destroy_mono_plugin
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -225,7 +225,7 @@ static GaimPluginInfo info =
- NULL
- };
-
--static void init_plugin(GaimPlugin *plugin)
-+static void init_plugin(Gaim2Plugin *plugin)
- {
- ml_init();
-
-diff -prNu ./plugins/mono/loader/mono-glue.h ./plugins/mono/loader/mono-glue.h
---- ./plugins/mono/loader/mono-glue.h 2005-11-05 03:09:30.000000000 +0100
-+++ ./plugins/mono/loader/mono-glue.h 2006-01-05 15:27:48.000000000 +0100
-@@ -6,14 +6,14 @@
- #include <mono/metadata/environment.h>
- #include <mono/metadata/assembly.h>
-
--void gaim_debug_glue(int type, MonoString *cat, MonoString *str);
-+void gaim2_debug_glue(int type, MonoString *cat, MonoString *str);
-
--int gaim_signal_connect_glue(MonoObject *h, MonoObject *plugin, MonoString *signal, MonoObject *func);
-+int gaim2_signal_connect_glue(MonoObject *h, MonoObject *plugin, MonoString *signal, MonoObject *func);
-
--MonoObject* gaim_blist_get_handle_glue(void);
-+MonoObject* gaim2_blist_get_handle_glue(void);
-
--MonoObject* gaim_blist_build_buddy_object(void* buddy);
-+MonoObject* gaim2_blist_build_buddy_object(void* buddy);
-
--MonoObject* gaim_status_build_status_object(void* data);
-+MonoObject* gaim2_status_build_status_object(void* data);
-
- #endif
-diff -prNu ./plugins/mono/loader/mono-helper.c ./plugins/mono/loader/mono-helper.c
---- ./plugins/mono/loader/mono-helper.c 2005-11-07 00:09:07.000000000 +0100
-+++ ./plugins/mono/loader/mono-helper.c 2006-01-05 15:27:37.000000000 +0100
-@@ -25,7 +25,7 @@ gboolean ml_init()
-
- g_return_val_if_fail(_runtime_active == FALSE, TRUE);
-
-- d = mono_jit_init("gaim");
-+ d = mono_jit_init("gaim2");
-
- if (!d) {
- ml_set_domain(NULL);
-@@ -58,7 +58,7 @@ MonoObject* ml_delegate_invoke(MonoObjec
-
- ret = mono_runtime_delegate_invoke(method, params, &exception);
- if (exception) {
-- gaim_debug(GAIM_DEBUG_ERROR, "mono", "caught exception: %s\n", mono_class_get_name(mono_object_get_class(exception)));
-+ gaim2_debug(GAIM_DEBUG_ERROR, "mono", "caught exception: %s\n", mono_class_get_name(mono_object_get_class(exception)));
- }
-
- return ret;
-@@ -70,7 +70,7 @@ MonoObject* ml_invoke(MonoMethod *method
-
- ret = mono_runtime_invoke(method, obj, params, &exception);
- if (exception) {
-- gaim_debug(GAIM_DEBUG_ERROR, "mono", "caught exception: %s\n", mono_class_get_name(mono_object_get_class(exception)));
-+ gaim2_debug(GAIM_DEBUG_ERROR, "mono", "caught exception: %s\n", mono_class_get_name(mono_object_get_class(exception)));
- }
-
- return ret;
-@@ -86,7 +86,7 @@ MonoClass* ml_find_plugin_class(MonoImag
- klass = mono_class_get (image, MONO_TOKEN_TYPE_DEF | i);
- pklass = mono_class_get_parent(klass);
- if (pklass)
-- if (strcmp("GaimPlugin", mono_class_get_name(pklass)) == 0)
-+ if (strcmp("Gaim2Plugin", mono_class_get_name(pklass)) == 0)
- return klass;
- }
-
-@@ -135,7 +135,7 @@ gboolean ml_is_api_dll(MonoImage *image)
- for (i = 1; i <= total; ++i) {
- klass = mono_class_get (image, MONO_TOKEN_TYPE_DEF | i);
- if (strcmp(mono_class_get_name(klass), "Debug") == 0)
-- if (strcmp(mono_class_get_namespace(klass), "Gaim") == 0) {
-+ if (strcmp(mono_class_get_namespace(klass), "Gaim2") == 0) {
- ml_set_api_image(image);
- return TRUE;
- }
-@@ -144,21 +144,21 @@ gboolean ml_is_api_dll(MonoImage *image)
- return FALSE;
- }
-
--MonoObject* ml_object_from_gaim_type(GaimType type, gpointer data)
-+MonoObject* ml_object_from_gaim2_type(Gaim2Type type, gpointer data)
- {
- return NULL;
- }
-
--MonoObject* ml_object_from_gaim_subtype(GaimSubType type, gpointer data)
-+MonoObject* ml_object_from_gaim2_subtype(Gaim2SubType type, gpointer data)
- {
- MonoObject *obj = NULL;
-
- switch (type) {
- case GAIM_SUBTYPE_BLIST_BUDDY:
-- obj = gaim_blist_build_buddy_object(data);
-+ obj = gaim2_blist_build_buddy_object(data);
- break;
- case GAIM_SUBTYPE_STATUS:
-- obj = gaim_status_build_status_object(data);
-+ obj = gaim2_status_build_status_object(data);
- break;
- default:
- break;
-@@ -172,15 +172,15 @@ MonoObject* ml_create_api_object(char *c
- MonoObject *obj = NULL;
- MonoClass *klass = NULL;
-
-- klass = mono_class_from_name(ml_get_api_image(), "Gaim", class_name);
-+ klass = mono_class_from_name(ml_get_api_image(), "Gaim2", class_name);
- if (!klass) {
-- gaim_debug(GAIM_DEBUG_FATAL, "mono", "couldn't find the '%s' class\n", class_name);
-+ gaim2_debug(GAIM_DEBUG_FATAL, "mono", "couldn't find the '%s' class\n", class_name);
- return NULL;
- }
-
- obj = mono_object_new(ml_get_domain(), klass);
- if (!obj) {
-- gaim_debug(GAIM_DEBUG_FATAL, "mono", "couldn't create the object from class '%s'\n", class_name);
-+ gaim2_debug(GAIM_DEBUG_FATAL, "mono", "couldn't create the object from class '%s'\n", class_name);
- return NULL;
- }
-
-@@ -215,14 +215,14 @@ MonoImage* ml_get_api_image()
-
- void ml_init_internal_calls(void)
- {
-- mono_add_internal_call("Gaim.Debug::_debug", gaim_debug_glue);
-- mono_add_internal_call("Gaim.Signal::_connect", gaim_signal_connect_glue);
-- mono_add_internal_call("Gaim.BuddyList::_get_handle", gaim_blist_get_handle_glue);
-+ mono_add_internal_call("Gaim2.Debug::_debug", gaim2_debug_glue);
-+ mono_add_internal_call("Gaim2.Signal::_connect", gaim2_signal_connect_glue);
-+ mono_add_internal_call("Gaim2.BuddyList::_get_handle", gaim2_blist_get_handle_glue);
- }
-
- static GHashTable *plugins_hash = NULL;
-
--void ml_add_plugin(GaimMonoPlugin *plugin)
-+void ml_add_plugin(Gaim2MonoPlugin *plugin)
- {
- if (!plugins_hash)
- plugins_hash = g_hash_table_new(NULL, NULL);
-@@ -230,12 +230,12 @@ void ml_add_plugin(GaimMonoPlugin *plugi
- g_hash_table_insert(plugins_hash, plugin->klass, plugin);
- }
-
--gboolean ml_remove_plugin(GaimMonoPlugin *plugin)
-+gboolean ml_remove_plugin(Gaim2MonoPlugin *plugin)
- {
- return g_hash_table_remove(plugins_hash, plugin->klass);
- }
-
--gpointer ml_find_plugin(GaimMonoPlugin *plugin)
-+gpointer ml_find_plugin(Gaim2MonoPlugin *plugin)
- {
- return g_hash_table_lookup(plugins_hash, plugin->klass);
- }
-diff -prNu ./plugins/mono/loader/mono-helper.h ./plugins/mono/loader/mono-helper.h
---- ./plugins/mono/loader/mono-helper.h 2005-12-04 19:19:51.000000000 +0100
-+++ ./plugins/mono/loader/mono-helper.h 2006-01-05 15:27:48.000000000 +0100
-@@ -12,7 +12,7 @@
- #include "debug.h"
-
- typedef struct {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
-
- MonoAssembly *assm;
- MonoClass *klass;
-@@ -24,7 +24,7 @@ typedef struct {
- MonoMethod *destroy;
-
- GList *signal_data;
--} GaimMonoPlugin;
-+} Gaim2MonoPlugin;
-
- gboolean ml_init(void);
-
-@@ -48,9 +48,9 @@ void ml_set_domain(MonoDomain *d);
-
- void ml_init_internal_calls(void);
-
--MonoObject* ml_object_from_gaim_type(GaimType type, gpointer data);
-+MonoObject* ml_object_from_gaim2_type(Gaim2Type type, gpointer data);
-
--MonoObject* ml_object_from_gaim_subtype(GaimSubType type, gpointer data);
-+MonoObject* ml_object_from_gaim2_subtype(Gaim2SubType type, gpointer data);
-
- MonoObject* ml_create_api_object(char *class_name);
-
-@@ -60,11 +60,11 @@ MonoImage* ml_get_api_image(void);
-
- /* hash table stuff; probably don't need it anymore */
-
--void ml_add_plugin(GaimMonoPlugin *plugin);
-+void ml_add_plugin(Gaim2MonoPlugin *plugin);
-
--gboolean ml_remove_plugin(GaimMonoPlugin *plugin);
-+gboolean ml_remove_plugin(Gaim2MonoPlugin *plugin);
-
--gpointer ml_find_plugin(GaimMonoPlugin *plugin);
-+gpointer ml_find_plugin(Gaim2MonoPlugin *plugin);
-
- gpointer ml_find_plugin_by_class(MonoClass *klass);
-
-diff -prNu ./plugins/mono/loader/signal-glue.c ./plugins/mono/loader/signal-glue.c
---- ./plugins/mono/loader/signal-glue.c 2005-11-05 03:09:30.000000000 +0100
-+++ ./plugins/mono/loader/signal-glue.c 2006-01-05 15:27:37.000000000 +0100
-@@ -8,12 +8,12 @@
- typedef struct {
- MonoObject *func;
- char *signal;
-- GaimValue **values;
-- GaimValue *ret_value;
-+ Gaim2Value **values;
-+ Gaim2Value *ret_value;
- int num_vals;
- } SignalData;
-
--static GaimCallback get_callback(SignalData *sig_data);
-+static Gaim2Callback get_callback(SignalData *sig_data);
-
- static gpointer dispatch_callback(SignalData *sig_data, int num_vals, ...)
- {
-@@ -21,7 +21,7 @@ static gpointer dispatch_callback(Signal
- MonoObject *obj;
- int i;
- gpointer meth_args[1];
-- gpointer gaim_obj;
-+ gpointer gaim2_obj;
-
- va_list args;
-
-@@ -30,13 +30,13 @@ static gpointer dispatch_callback(Signal
- array = mono_array_new(ml_get_domain(), mono_get_object_class(), num_vals);
-
- for (i = 0; i < num_vals; i++) {
-- if (gaim_value_get_type(sig_data->values[i]) == GAIM_TYPE_SUBTYPE) {
-- gaim_obj = va_arg(args, gpointer);
-- obj = ml_object_from_gaim_subtype(gaim_value_get_subtype(sig_data->values[i]), gaim_obj);
-+ if (gaim2_value_get_type(sig_data->values[i]) == GAIM_TYPE_SUBTYPE) {
-+ gaim2_obj = va_arg(args, gpointer);
-+ obj = ml_object_from_gaim2_subtype(gaim2_value_get_subtype(sig_data->values[i]), gaim2_obj);
- mono_array_set(array, MonoObject*, i, obj);
- } else {
-- gaim_obj = va_arg(args, gpointer);
-- obj = ml_object_from_gaim_type(gaim_value_get_type(sig_data->values[i]), gaim_obj);
-+ gaim2_obj = va_arg(args, gpointer);
-+ obj = ml_object_from_gaim2_type(gaim2_value_get_type(sig_data->values[i]), gaim2_obj);
- mono_array_set(array, MonoObject*, i, obj);
- }
- }
-@@ -59,16 +59,16 @@ static void cb_void__pointer_pointer_poi
- }
-
-
--int gaim_signal_connect_glue(MonoObject* h, MonoObject *plugin, MonoString *signal, MonoObject *func)
-+int gaim2_signal_connect_glue(MonoObject* h, MonoObject *plugin, MonoString *signal, MonoObject *func)
- {
- char *sig;
- void **instance = NULL;
- SignalData *sig_data;
-- GaimMonoPlugin *mplug;
-+ Gaim2MonoPlugin *mplug;
- MonoClass *klass;
-
- sig = mono_string_to_utf8(signal);
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "connecting signal: %s\n", sig);
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "connecting signal: %s\n", sig);
-
- instance = (void*)mono_object_unbox(h);
-
-@@ -77,7 +77,7 @@ int gaim_signal_connect_glue(MonoObject*
- sig_data->func = func;
- sig_data->signal = sig;
-
-- gaim_signal_get_values(*instance, sig, &sig_data->ret_value, &sig_data->num_vals, &sig_data->values);
-+ gaim2_signal_get_values(*instance, sig, &sig_data->ret_value, &sig_data->num_vals, &sig_data->values);
-
- klass = mono_object_get_class(plugin);
-
-@@ -85,10 +85,10 @@ int gaim_signal_connect_glue(MonoObject*
-
- mplug->signal_data = g_list_append(mplug->signal_data, (gpointer)sig_data);
-
-- return gaim_signal_connect(*instance, sig, (gpointer)klass, get_callback(sig_data), (gpointer)sig_data);
-+ return gaim2_signal_connect(*instance, sig, (gpointer)klass, get_callback(sig_data), (gpointer)sig_data);
- }
-
--static int determine_index(GaimType type)
-+static int determine_index(Gaim2Type type)
- {
- switch (type) {
- case GAIM_TYPE_SUBTYPE:
-@@ -111,29 +111,29 @@ static gpointer callbacks[]= {
- cb_void__pointer_pointer_pointer
- };
-
--static int callbacks_array_size = sizeof(callbacks) / sizeof(GaimCallback);
-+static int callbacks_array_size = sizeof(callbacks) / sizeof(Gaim2Callback);
-
-
--static GaimCallback get_callback(SignalData *sig_data)
-+static Gaim2Callback get_callback(SignalData *sig_data)
- {
- int i, index = 0;
-
- if (sig_data->ret_value == NULL)
- index = 0;
- else
-- index = determine_index(gaim_value_get_type(sig_data->ret_value));
-+ index = determine_index(gaim2_value_get_type(sig_data->ret_value));
-
- for (i = 0; i < sig_data->num_vals; i++) {
-- index += determine_index(gaim_value_get_type(sig_data->values[i]));
-+ index += determine_index(gaim2_value_get_type(sig_data->values[i]));
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "mono", "get_callback index = %d\n", index);
-+ gaim2_debug(GAIM_DEBUG_INFO, "mono", "get_callback index = %d\n", index);
-
- if (index >= callbacks_array_size || callbacks[index] == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "mono", "couldn't find a callback function for signal: %s\n", sig_data->signal);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "mono", "couldn't find a callback function for signal: %s\n", sig_data->signal);
- return NULL;
- }
-
-- gaim_debug(GAIM_DEBUG_MISC, "mono", "using callback at index: %d\n", index);
-+ gaim2_debug(GAIM_DEBUG_MISC, "mono", "using callback at index: %d\n", index);
- return GAIM_CALLBACK(callbacks[index]);
- }
-diff -prNu ./plugins/mono/loader/status-glue.c ./plugins/mono/loader/status-glue.c
---- ./plugins/mono/loader/status-glue.c 2005-12-09 13:52:45.000000000 +0100
-+++ ./plugins/mono/loader/status-glue.c 2006-01-05 15:27:37.000000000 +0100
-@@ -2,15 +2,15 @@
- #include "mono-helper.h"
- #include "mono-glue.h"
-
--MonoObject* gaim_status_build_status_object(void* data)
-+MonoObject* gaim2_status_build_status_object(void* data)
- {
- MonoObject *obj = NULL;
-- GaimStatus *status = (GaimStatus*)data;
-+ Gaim2Status *status = (Gaim2Status*)data;
-
- obj = ml_create_api_object("Status");
- g_return_val_if_fail(obj != NULL, NULL);
-
-- ml_set_prop_string(obj, "Id", (char*)gaim_status_get_id(status));
-+ ml_set_prop_string(obj, "Id", (char*)gaim2_status_get_id(status));
-
- return obj;
- }
-diff -prNu ./plugins/mono/Makefile.am ./plugins/mono/Makefile.am
---- ./plugins/mono/Makefile.am 2005-10-30 18:24:37.000000000 +0100
-+++ ./plugins/mono/Makefile.am 2006-01-05 13:16:03.000000000 +0100
-@@ -5,7 +5,7 @@ mono_sources = GetBuddyBack.cs \
-
- EXTRA_DIST = $(mono_sources)
-
--monodir = $(libdir)/gaim
-+monodir = $(libdir)/gaim2
- mono_SCRIPTS = MPlugin.dll GetBuddyBack.dll
- mono_build_sources = $(addprefix $(srcdir)/, $(mono_sources))
-
-diff -prNu ./plugins/musicmessaging/Makefile.am ./plugins/musicmessaging/Makefile.am
---- ./plugins/musicmessaging/Makefile.am 2005-10-30 18:24:37.000000000 +0100
-+++ ./plugins/musicmessaging/Makefile.am 2006-01-05 13:16:23.000000000 +0100
-@@ -1,13 +1,13 @@
- EXTRA_DIST = \
- music.png
-
--musicmessagingdir = $(libdir)/gaim
-+musicmessagingdir = $(libdir)/gaim2
-
- musicmessaging_la_LDFLAGS = -module -avoid-version $(GTK_LIBS) $(DBUS_LIBS)
-
- if PLUGINS
-
--musicmessagingpixdir = $(datadir)/pixmaps/gaim/buttons
-+musicmessagingpixdir = $(datadir)/pixmaps/gaim2/buttons
- musicmessagingpix_DATA = music.png
-
- musicmessaging_LTLIBRARIES = musicmessaging.la
-diff -prNu ./plugins/musicmessaging/musicmessaging.c ./plugins/musicmessaging/musicmessaging.c
---- ./plugins/musicmessaging/musicmessaging.c 2005-12-22 19:28:07.000000000 +0100
-+++ ./plugins/musicmessaging/musicmessaging.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Music messaging plugin for Gaim
-+ * Music messaging plugin for Gaim2
- *
- * Copyright (C) 2005 Christian Muise.
- *
-@@ -20,7 +20,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "conversation.h"
-
-@@ -37,7 +37,7 @@
- #include "dbus-maybe.h"
- #include "dbus-bindings.h"
- #include "dbus-server.h"
--#include "dbus-gaim.h"
-+#include "dbus-gaim2.h"
-
- #define MUSICMESSAGING_PLUGIN_ID "gtk-hazure-musicmessaging"
- #define MUSICMESSAGING_PREFIX "##MM##"
-@@ -45,7 +45,7 @@
- #define MUSICMESSAGING_CONFIRM_MSG "Music messaging session confirmed."
-
- typedef struct {
-- GaimConversation *conv; /* pointer to the conversation */
-+ Gaim2Conversation *conv; /* pointer to the conversation */
- GtkWidget *seperator; /* seperator in the conversation */
- GtkWidget *button; /* button in the conversation */
- GPid pid; /* the pid of the score editor */
-@@ -61,10 +61,10 @@ static void run_editor(MMConversation *m
- static void kill_editor(MMConversation *mmconv);
- static void add_button (MMConversation *mmconv);
- static void remove_widget (GtkWidget *button);
--static void init_conversation (GaimConversation *conv);
--static void conv_destroyed(GaimConversation *conv);
--static gboolean intercept_sent(GaimAccount *account, GaimConversation *conv, char **message, void* pData);
--static gboolean intercept_received(GaimAccount *account, char **sender, char **message, GaimConversation *conv, int *flags);
-+static void init_conversation (Gaim2Conversation *conv);
-+static void conv_destroyed(Gaim2Conversation *conv);
-+static gboolean intercept_sent(Gaim2Account *account, Gaim2Conversation *conv, char **message, void* pData);
-+static gboolean intercept_received(Gaim2Account *account, char **sender, char **message, Gaim2Conversation *conv, int *flags);
- static gboolean send_change_request (const int session, const char *id, const char *command, const char *parameters);
- static gboolean send_change_confirmed (const int session, const char *command, const char *parameters);
- static void session_end (MMConversation *mmconv);
-@@ -74,7 +74,7 @@ static void session_end (MMConversation
- GList *conversations;
-
- /* Pointer to this plugin */
--GaimPlugin *plugin_pointer;
-+Gaim2Plugin *plugin_pointer;
-
- /* Define types needed for DBus */
- DBusGConnection *connection;
-@@ -111,9 +111,9 @@ void music_messaging_change_request(cons
- GString *to_send = g_string_new("");
- g_string_append_printf(to_send, "##MM## request %s %s##MM##", command, parameters);
-
-- gaim_conv_im_send(GAIM_CONV_IM(mmconv->conv), to_send->str);
-+ gaim2_conv_im_send(GAIM_CONV_IM(mmconv->conv), to_send->str);
-
-- gaim_debug_misc("Sent request: %s\n", to_send->str);
-+ gaim2_debug_misc("Sent request: %s\n", to_send->str);
- }
- }
-
-@@ -131,7 +131,7 @@ void music_messaging_change_confirmed(co
- GString *to_send = g_string_new("");
- g_string_append_printf(to_send, "##MM## confirm %s %s##MM##", command, parameters);
-
-- gaim_conv_im_send(GAIM_CONV_IM(mmconv->conv), to_send->str);
-+ gaim2_conv_im_send(GAIM_CONV_IM(mmconv->conv), to_send->str);
- } else
- {
- /* Do nothing. If they aren't the originator, then they can't confirm. */
-@@ -144,7 +144,7 @@ void music_messaging_change_failed(const
- {
- MMConversation *mmconv = (MMConversation *)g_list_nth_data(conversations, session);
-
-- gaim_notify_message(plugin_pointer, GAIM_NOTIFY_MSG_INFO, command,
-+ gaim2_notify_message(plugin_pointer, GAIM_NOTIFY_MSG_INFO, command,
- parameters, NULL, NULL, NULL);
-
- if (mmconv->started)
-@@ -154,7 +154,7 @@ void music_messaging_change_failed(const
- GString *to_send = g_string_new("");
- g_string_append_printf(to_send, "##MM## failed %s %s %s##MM##", id, command, parameters);
-
-- gaim_conv_im_send(GAIM_CONV_IM(mmconv->conv), to_send->str);
-+ gaim2_conv_im_send(GAIM_CONV_IM(mmconv->conv), to_send->str);
- } else
- {
- /* Do nothing. If they aren't the originator, then they can't confirm. */
-@@ -166,7 +166,7 @@ void music_messaging_done_session(const
- {
- MMConversation *mmconv = (MMConversation *)g_list_nth_data(conversations, session);
-
-- gaim_notify_message(plugin_pointer, GAIM_NOTIFY_MSG_INFO, "Session",
-+ gaim2_notify_message(plugin_pointer, GAIM_NOTIFY_MSG_INFO, "Session",
- "Session Complete", NULL, NULL, NULL);
-
- session_end(mmconv);
-@@ -175,7 +175,7 @@ void music_messaging_done_session(const
-
- /* DBus commands that can be sent to the editor */
- G_BEGIN_DECLS
--DBusConnection *gaim_dbus_get_connection(void);
-+DBusConnection *gaim2_dbus_get_connection(void);
- G_END_DECLS
-
- static gboolean send_change_request (const int session, const char *id, const char *command, const char *parameters)
-@@ -194,7 +194,7 @@ static gboolean send_change_request (con
- DBUS_TYPE_INVALID);
-
- /* Send the signal */
-- dbus_connection_send (gaim_dbus_get_connection(), message, NULL);
-+ dbus_connection_send (gaim2_dbus_get_connection(), message, NULL);
-
- /* Free the signal now we have finished with it */
- dbus_message_unref (message);
-@@ -220,7 +220,7 @@ static gboolean send_change_confirmed (c
- DBUS_TYPE_INVALID);
-
- /* Send the signal */
-- dbus_connection_send (gaim_dbus_get_connection(), message, NULL);
-+ dbus_connection_send (gaim2_dbus_get_connection(), message, NULL);
-
- /* Free the signal now we have finished with it */
- dbus_message_unref (message);
-@@ -233,7 +233,7 @@ static gboolean send_change_confirmed (c
-
-
- static int
--mmconv_from_conv_loc(GaimConversation *conv)
-+mmconv_from_conv_loc(Gaim2Conversation *conv)
- {
- MMConversation *mmconv_current = NULL;
- guint i;
-@@ -250,17 +250,17 @@ mmconv_from_conv_loc(GaimConversation *c
- }
-
- static MMConversation*
--mmconv_from_conv(GaimConversation *conv)
-+mmconv_from_conv(Gaim2Conversation *conv)
- {
- return (MMConversation *)g_list_nth_data(conversations, mmconv_from_conv_loc(conv));
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin) {
-+plugin_load(Gaim2Plugin *plugin) {
- void *conv_list_handle;
-
- /* First, we have to register our four exported functions with the
-- main gaim dbus loop. Without this statement, the gaim dbus
-+ main gaim2 dbus loop. Without this statement, the gaim2 dbus
- code wouldn't know about our functions. */
- GAIM_DBUS_REGISTER_BINDINGS(plugin);
-
-@@ -268,29 +268,29 @@ plugin_load(GaimPlugin *plugin) {
- plugin_pointer = plugin;
-
- /* Add the button to all the current conversations */
-- gaim_conversation_foreach (init_conversation);
-+ gaim2_conversation_foreach (init_conversation);
-
- /* Listen for any new conversations */
-- conv_list_handle = gaim_conversations_get_handle();
-+ conv_list_handle = gaim2_conversations_get_handle();
-
-- gaim_signal_connect(conv_list_handle, "conversation-created",
-+ gaim2_signal_connect(conv_list_handle, "conversation-created",
- plugin, GAIM_CALLBACK(init_conversation), NULL);
-
- /* Listen for conversations that are ending */
-- gaim_signal_connect(conv_list_handle, "deleting-conversation",
-+ gaim2_signal_connect(conv_list_handle, "deleting-conversation",
- plugin, GAIM_CALLBACK(conv_destroyed), NULL);
-
- /* Listen for sending/receiving messages to replace tags */
-- gaim_signal_connect(conv_list_handle, "writing-im-msg",
-+ gaim2_signal_connect(conv_list_handle, "writing-im-msg",
- plugin, GAIM_CALLBACK(intercept_sent), NULL);
-- gaim_signal_connect(conv_list_handle, "receiving-im-msg",
-+ gaim2_signal_connect(conv_list_handle, "receiving-im-msg",
- plugin, GAIM_CALLBACK(intercept_received), NULL);
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin) {
-+plugin_unload(Gaim2Plugin *plugin) {
- MMConversation *mmconv = NULL;
-
- while (g_list_length(conversations) > 0)
-@@ -304,33 +304,33 @@ plugin_unload(GaimPlugin *plugin) {
-
-
- static gboolean
--intercept_sent(GaimAccount *account, GaimConversation *conv, char **message, void* pData)
-+intercept_sent(Gaim2Account *account, Gaim2Conversation *conv, char **message, void* pData)
- {
-
- if (0 == strncmp(*message, MUSICMESSAGING_PREFIX, strlen(MUSICMESSAGING_PREFIX)))
- {
-- gaim_debug_misc("gaim-musicmessaging", "Sent MM Message: %s\n", *message);
-+ gaim2_debug_misc("gaim2-musicmessaging", "Sent MM Message: %s\n", *message);
- message = 0;
- }
- else if (0 == strncmp(*message, MUSICMESSAGING_START_MSG, strlen(MUSICMESSAGING_START_MSG)))
- {
-- gaim_debug_misc("gaim-musicmessaging", "Sent MM request.\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "Sent MM request.\n");
- return FALSE;
- }
- else if (0 == strncmp(*message, MUSICMESSAGING_CONFIRM_MSG, strlen(MUSICMESSAGING_CONFIRM_MSG)))
- {
-- gaim_debug_misc("gaim-musicmessaging", "Sent MM confirm.\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "Sent MM confirm.\n");
- return FALSE;
- }
- else if (0 == strncmp(*message, "test1", strlen("test1")))
- {
-- gaim_debug_misc("gaim-musicmessaging", "\n\nTEST 1\n\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "\n\nTEST 1\n\n");
- send_change_request(0, "test-id", "test-command", "test-parameters");
- return FALSE;
- }
- else if (0 == strncmp(*message, "test2", strlen("test2")))
- {
-- gaim_debug_misc("gaim-musicmessaging", "\n\nTEST 2\n\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "\n\nTEST 2\n\n");
- send_change_confirmed(1, "test-command", "test-parameters");
- return FALSE;
- }
-@@ -343,15 +343,15 @@ intercept_sent(GaimAccount *account, Gai
- }
-
- static gboolean
--intercept_received(GaimAccount *account, char **sender, char **message, GaimConversation *conv, int *flags)
-+intercept_received(Gaim2Account *account, char **sender, char **message, Gaim2Conversation *conv, int *flags)
- {
- MMConversation *mmconv = mmconv_from_conv(conv);
-
-- gaim_debug_misc("gaim-musicmessaging", "Intercepted: %s\n", *message);
-+ gaim2_debug_misc("gaim2-musicmessaging", "Intercepted: %s\n", *message);
- if (strstr(*message, MUSICMESSAGING_PREFIX))
- {
- char *parsed_message = strtok(strstr(*message, MUSICMESSAGING_PREFIX), "<");
-- gaim_debug_misc("gaim-musicmessaging", "Received an MM Message: %s\n", parsed_message);
-+ gaim2_debug_misc("gaim2-musicmessaging", "Received an MM Message: %s\n", parsed_message);
-
- if (mmconv->started)
- {
-@@ -364,7 +364,7 @@ intercept_received(GaimAccount *account,
- char *command;
- char *parameters;
-
-- gaim_debug_misc("gaim-musicmessaging", "Sending request to gscore.\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "Sending request to gscore.\n");
-
- /* Get past the first two terms - '##MM##' and 'request' */
- strtok(parsed_message, " "); /* '##MM##' */
-@@ -384,7 +384,7 @@ intercept_received(GaimAccount *account,
- char *command;
- char *parameters;
-
-- gaim_debug_misc("gaim-musicmessaging", "Sending confirmation to gscore.\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "Sending confirmation to gscore.\n");
-
- /* Get past the first two terms - '##MM##' and 'confirm' */
- strtok(parsed_message, " "); /* '##MM##' */
-@@ -410,7 +410,7 @@ intercept_received(GaimAccount *account,
-
- if ((mmconv->conv)->name == id)
- {
-- gaim_notify_message(plugin_pointer, GAIM_NOTIFY_MSG_ERROR, "Music Messaging",
-+ gaim2_notify_message(plugin_pointer, GAIM_NOTIFY_MSG_ERROR, "Music Messaging",
- "There was a conflict in running the command:", command, NULL, NULL);
- }
- }
-@@ -420,7 +420,7 @@ intercept_received(GaimAccount *account,
- }
- else if (strstr(*message, MUSICMESSAGING_START_MSG))
- {
-- gaim_debug_misc("gaim-musicmessaging", "Received MM request.\n");
-+ gaim2_debug_misc("gaim2-musicmessaging", "Received MM request.\n");
- if (!(mmconv->originator))
- {
- mmconv->requested = TRUE;
-@@ -430,7 +430,7 @@ intercept_received(GaimAccount *account,
- }
- else if (strstr(*message, MUSICMESSAGING_CONFIRM_MSG))
- {
-- gaim_debug_misc("gaim-musicmessagin", "Received MM confirm.\n");
-+ gaim2_debug_misc("gaim2-musicmessagin", "Received MM confirm.\n");
-
- if (mmconv->originator)
- {
-@@ -448,15 +448,15 @@ intercept_received(GaimAccount *account,
-
- static void send_request(MMConversation *mmconv)
- {
-- GaimConnection *connection = gaim_conversation_get_gc(mmconv->conv);
-- const char *convName = gaim_conversation_get_name(mmconv->conv);
-+ Gaim2Connection *connection = gaim2_conversation_get_gc(mmconv->conv);
-+ const char *convName = gaim2_conversation_get_name(mmconv->conv);
- serv_send_im(connection, convName, MUSICMESSAGING_START_MSG, GAIM_MESSAGE_SEND);
- }
-
- static void send_request_confirmed(MMConversation *mmconv)
- {
-- GaimConnection *connection = gaim_conversation_get_gc(mmconv->conv);
-- const char *convName = gaim_conversation_get_name(mmconv->conv);
-+ Gaim2Connection *connection = gaim2_conversation_get_gc(mmconv->conv);
-+ const char *convName = gaim2_conversation_get_name(mmconv->conv);
- serv_send_im(connection, convName, MUSICMESSAGING_CONFIRM_MSG, GAIM_MESSAGE_SEND);
- }
-
-@@ -499,7 +499,7 @@ static void music_button_toggled (GtkWid
- static void set_editor_path (GtkWidget *button, GtkWidget *text_field)
- {
- const char * path = gtk_entry_get_text((GtkEntry*)text_field);
-- gaim_prefs_set_string("/plugins/gtk/musicmessaging/editor_path", path);
-+ gaim2_prefs_set_string("/plugins/gtk/musicmessaging/editor_path", path);
-
- }
-
-@@ -508,7 +508,7 @@ static void run_editor (MMConversation *
- GError *spawn_error = NULL;
- GString *session_id;
- gchar * args[4];
-- args[0] = (gchar *)gaim_prefs_get_string("/plugins/gtk/musicmessaging/editor_path");
-+ args[0] = (gchar *)gaim2_prefs_get_string("/plugins/gtk/musicmessaging/editor_path");
-
- args[1] = "-session_id";
- session_id = g_string_new("");
-@@ -519,7 +519,7 @@ static void run_editor (MMConversation *
-
- if (!(g_spawn_async (".", args, NULL, 4, NULL, NULL, &(mmconv->pid), &spawn_error)))
- {
-- gaim_notify_error(plugin_pointer, "Error Running Editor",
-+ gaim2_notify_error(plugin_pointer, "Error Running Editor",
- "The following error has occured:", spawn_error->message);
- mmconv->started = FALSE;
- }
-@@ -538,7 +538,7 @@ static void kill_editor (MMConversation
- }
- }
-
--static void init_conversation (GaimConversation *conv)
-+static void init_conversation (Gaim2Conversation *conv)
- {
- MMConversation *mmconv;
- mmconv = g_malloc(sizeof(MMConversation));
-@@ -553,7 +553,7 @@ static void init_conversation (GaimConve
- conversations = g_list_append(conversations, mmconv);
- }
-
--static void conv_destroyed (GaimConversation *conv)
-+static void conv_destroyed (Gaim2Conversation *conv)
- {
- MMConversation *mmconv = mmconv_from_conv(conv);
-
-@@ -568,7 +568,7 @@ static void conv_destroyed (GaimConversa
-
- static void add_button (MMConversation *mmconv)
- {
-- GaimConversation *conv = mmconv->conv;
-+ Gaim2Conversation *conv = mmconv->conv;
-
- GtkWidget *button, *image, *sep;
- gchar *file_path;
-@@ -578,7 +578,7 @@ static void add_button (MMConversation *
-
- g_signal_connect(G_OBJECT(button), "toggled", G_CALLBACK(music_button_toggled), mmconv);
-
-- file_path = g_build_filename(DATADIR, "pixmaps", "gaim", "buttons",
-+ file_path = g_build_filename(DATADIR, "pixmaps", "gaim2", "buttons",
- "music.png", NULL);
- image = gtk_image_new_from_file(file_path);
- g_free(file_path);
-@@ -605,7 +605,7 @@ static void remove_widget (GtkWidget *bu
- }
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret;
- GtkWidget *vbox;
-@@ -619,7 +619,7 @@ get_config_frame(GaimPlugin *plugin)
- gtk_container_set_border_width(GTK_CONTAINER(ret), 10);
-
- /* Configuration frame */
-- vbox = gaim_gtk_make_frame(ret, _("Music Messaging Configuration"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Music Messaging Configuration"));
-
- /* Path to the score editor */
- editor_path = gtk_entry_new();
-@@ -640,13 +640,13 @@ get_config_frame(GaimPlugin *plugin)
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame,
- 0 /* page_num (reserved) */
- };
-
--static GaimPluginInfo info = {
-+static Gaim2PluginInfo info = {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
- GAIM_MINOR_VERSION,
-@@ -673,9 +673,9 @@ static GaimPluginInfo info = {
- };
-
- static void
--init_plugin(GaimPlugin *plugin) {
-- gaim_prefs_add_none("/plugins/gtk/musicmessaging");
-- gaim_prefs_add_string("/plugins/gtk/musicmessaging/editor_path", "/usr/local/bin/gscore");
-+init_plugin(Gaim2Plugin *plugin) {
-+ gaim2_prefs_add_none("/plugins/gtk/musicmessaging");
-+ gaim2_prefs_add_string("/plugins/gtk/musicmessaging/editor_path", "/usr/local/bin/gscore");
- }
-
- GAIM_INIT_PLUGIN(musicmessaging, init_plugin, info);
-diff -prNu ./plugins/notify.c ./plugins/notify.c
---- ./plugins/notify.c 2005-12-21 22:48:37.000000000 +0100
-+++ ./plugins/notify.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Gaim buddy notification plugin.
-+ * Gaim2 buddy notification plugin.
- *
- * Copyright (C) 2000-2001, Eric Warmenhoven (original code)
- * Copyright (C) 2002, Etan Reisner <deryni@eden.rutgers.edu> (rewritten code)
-@@ -31,7 +31,7 @@
- * 22:23:25 <deryni> seanegan: To what?
- * 22:23:42 <seanegan> deryni: I dunno. Flash it between the regular icon and
- * blank or something.
-- * 22:23:53 <deryni> Also I think gaim might re-set that sort of frequently,
-+ * 22:23:53 <deryni> Also I think gaim2 might re-set that sort of frequently,
- * but I'd have to look.
- * 22:25:16 <seanegan> deryni: I keep my conversations in one workspace and am
- * frequently in an another, and the icon flashing in the pager would be a
-@@ -80,11 +80,11 @@
- * react to focus-in events when the entry or history widgets are focused)
- *
- * Sean, 08 January, 2005:
-- * -Added Raise option, formally in Gaim proper
-+ * -Added Raise option, formally in Gaim2 proper
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkprefs.h"
-
- #include "conversation.h"
-@@ -102,13 +102,13 @@
-
- #define NOTIFY_PLUGIN_ID "gtk-x11-notify"
-
--static GaimPlugin *my_plugin = NULL;
-+static Gaim2Plugin *my_plugin = NULL;
-
- /* notification set/unset */
--static int notify(GaimConversation *conv, gboolean increment);
--static void notify_win(GaimGtkWindow *gaimwin);
--static void unnotify(GaimConversation *conv, gboolean reset);
--static int unnotify_cb(GtkWidget *widget, gpointer data, GaimConversation *conv);
-+static int notify(Gaim2Conversation *conv, gboolean increment);
-+static void notify_win(Gaim2GtkWindow *gaim2win);
-+static void unnotify(Gaim2Conversation *conv, gboolean reset);
-+static int unnotify_cb(GtkWidget *widget, gpointer data, Gaim2Conversation *conv);
-
- /* gtk widget callbacks for prefs panel */
- static void type_toggle_cb(GtkWidget *widget, gpointer data);
-@@ -119,30 +119,30 @@ static void apply_method(void);
- static void apply_notify(void);
-
- /* string function */
--static void handle_string(GaimGtkWindow *gaimwin);
-+static void handle_string(Gaim2GtkWindow *gaim2win);
-
- /* count function */
--static void handle_count(GaimGtkWindow *gaimwin);
-+static void handle_count(Gaim2GtkWindow *gaim2win);
-
- /* urgent function */
--static void handle_urgent(GaimGtkWindow *gaimwin, gboolean add);
-+static void handle_urgent(Gaim2GtkWindow *gaim2win, gboolean add);
-
- /* raise function */
--static void handle_raise(GaimGtkWindow *gaimwin);
-+static void handle_raise(Gaim2GtkWindow *gaim2win);
-
- /****************************************/
- /* Begin doing stuff below this line... */
- /****************************************/
- static int
--count_messages(GaimGtkWindow *gaimwin)
-+count_messages(Gaim2GtkWindow *gaim2win)
- {
- gint count = 0;
- GList *convs = NULL, *l;
-
-- for (convs = gaimwin->gtkconvs; convs != NULL; convs = convs->next) {
-- GaimGtkConversation *conv = convs->data;
-+ for (convs = gaim2win->gtkconvs; convs != NULL; convs = convs->next) {
-+ Gaim2GtkConversation *conv = convs->data;
- for (l = conv->convs; l != NULL; l = l->next) {
-- count += GPOINTER_TO_INT(gaim_conversation_get_data(l->data, "notify-message-count"));
-+ count += GPOINTER_TO_INT(gaim2_conversation_get_data(l->data, "notify-message-count"));
- }
- }
-
-@@ -150,9 +150,9 @@ count_messages(GaimGtkWindow *gaimwin)
- }
-
- static int
--notify(GaimConversation *conv, gboolean increment)
-+notify(Gaim2Conversation *conv, gboolean increment)
- {
-- GaimGtkWindow *gaimwin = NULL;
-+ Gaim2GtkWindow *gaim2win = NULL;
- gint count;
- gboolean has_focus;
-
-@@ -162,84 +162,84 @@ notify(GaimConversation *conv, gboolean
- /* We want to remove the notifications, but not reset the counter */
- unnotify(conv, FALSE);
-
-- gaimwin = GAIM_GTK_CONVERSATION(conv)->win;
-+ gaim2win = GAIM_GTK_CONVERSATION(conv)->win;
-
- /* If we aren't doing notifications for this type of conversation, return */
-- if (((gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) &&
-- !gaim_prefs_get_bool("/plugins/gtk/X11/notify/type_im")) ||
-- ((gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) &&
-- !gaim_prefs_get_bool("/plugins/gtk/X11/notify/type_chat")))
-+ if (((gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) &&
-+ !gaim2_prefs_get_bool("/plugins/gtk/X11/notify/type_im")) ||
-+ ((gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) &&
-+ !gaim2_prefs_get_bool("/plugins/gtk/X11/notify/type_chat")))
- return 0;
-
-- g_object_get(G_OBJECT(gaimwin->window),
-+ g_object_get(G_OBJECT(gaim2win->window),
- "has-toplevel-focus", &has_focus, NULL);
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/type_focused") ||
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/type_focused") ||
- !has_focus) {
- if (increment) {
-- count = GPOINTER_TO_INT(gaim_conversation_get_data(conv, "notify-message-count"));
-+ count = GPOINTER_TO_INT(gaim2_conversation_get_data(conv, "notify-message-count"));
- count++;
-- gaim_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(count));
-+ gaim2_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(count));
- }
-
-- notify_win(gaimwin);
-+ notify_win(gaim2win);
- }
-
- return 0;
- }
-
- static void
--notify_win(GaimGtkWindow *gaimwin)
-+notify_win(Gaim2GtkWindow *gaim2win)
- {
-- if (count_messages(gaimwin) <= 0)
-+ if (count_messages(gaim2win) <= 0)
- return;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_count"))
-- handle_count(gaimwin);
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_string"))
-- handle_string(gaimwin);
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_urgent"))
-- handle_urgent(gaimwin, TRUE);
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_raise"))
-- handle_raise(gaimwin);
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_count"))
-+ handle_count(gaim2win);
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_string"))
-+ handle_string(gaim2win);
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_urgent"))
-+ handle_urgent(gaim2win, TRUE);
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_raise"))
-+ handle_raise(gaim2win);
- }
-
- static void
--unnotify(GaimConversation *conv, gboolean reset)
-+unnotify(Gaim2Conversation *conv, gboolean reset)
- {
-- GaimConversation *active_conv = NULL;
-- GaimGtkWindow *gaimwin = NULL;
-+ Gaim2Conversation *active_conv = NULL;
-+ Gaim2GtkWindow *gaim2win = NULL;
-
- g_return_if_fail(conv != NULL);
-
-- gaimwin = GAIM_GTK_CONVERSATION(conv)->win;
-- active_conv = gaim_gtk_conv_window_get_active_conversation(gaimwin);
-+ gaim2win = GAIM_GTK_CONVERSATION(conv)->win;
-+ active_conv = gaim2_gtk_conv_window_get_active_conversation(gaim2win);
-
- /* reset the conversation window title */
-- gaim_conversation_autoset_title(active_conv);
-+ gaim2_conversation_autoset_title(active_conv);
-
- if (reset) {
- /* Only need to actually remove the urgent hinting here, since removing it
- * just to have it readded in re-notify is an unnecessary couple extra RTs
- * to the server */
-- handle_urgent(gaimwin, FALSE);
-- gaim_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-+ handle_urgent(gaim2win, FALSE);
-+ gaim2_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
- }
-
- return;
- }
-
- static int
--unnotify_cb(GtkWidget *widget, gpointer data, GaimConversation *conv)
-+unnotify_cb(GtkWidget *widget, gpointer data, Gaim2Conversation *conv)
- {
-- if (GPOINTER_TO_INT(gaim_conversation_get_data(conv, "notify-message-count")) != 0)
-+ if (GPOINTER_TO_INT(gaim2_conversation_get_data(conv, "notify-message-count")) != 0)
- unnotify(conv, TRUE);
-
- return 0;
- }
-
- static gboolean
--message_displayed_cb(GaimAccount *account, GaimConversation *conv, const char *message, GaimMessageFlags flags)
-+message_displayed_cb(Gaim2Account *account, Gaim2Conversation *conv, const char *message, Gaim2MessageFlags flags)
- {
- if ((flags & GAIM_MESSAGE_RECV) && !(flags & GAIM_MESSAGE_DELAYED))
- notify(conv, TRUE);
-@@ -248,43 +248,43 @@ message_displayed_cb(GaimAccount *accoun
- }
-
- static void
--im_sent_im(GaimAccount *account, char *receiver, const char *message) {
-- GaimConversation *conv = NULL;
-+im_sent_im(Gaim2Account *account, char *receiver, const char *message) {
-+ Gaim2Conversation *conv = NULL;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_send")) {
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, receiver, account);
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_send")) {
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, receiver, account);
- unnotify(conv, TRUE);
- }
- }
-
- static void
--chat_sent_im(GaimAccount *account, const char *message, int id)
-+chat_sent_im(Gaim2Account *account, const char *message, int id)
- {
-- GaimConversation *conv = NULL;
-+ Gaim2Conversation *conv = NULL;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_send")) {
-- conv = gaim_find_chat(gaim_account_get_connection(account), id);
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_send")) {
-+ conv = gaim2_find_chat(gaim2_account_get_connection(account), id);
- unnotify(conv, TRUE);
- }
- }
-
- static int
--attach_signals(GaimConversation *conv)
-+attach_signals(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv = NULL;
-- GaimGtkWindow *gtkwin = NULL;
-+ Gaim2GtkConversation *gtkconv = NULL;
-+ Gaim2GtkWindow *gtkwin = NULL;
- GSList *imhtml_ids = NULL, *entry_ids = NULL;
- guint id;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- if (!gtkconv) {
-- gaim_debug_misc("notify", "Failed to find gtkconv\n");
-+ gaim2_debug_misc("notify", "Failed to find gtkconv\n");
- return 0;
- }
-
- gtkwin = gtkconv->win;
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_focus")) {
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_focus")) {
- /* TODO should really find a way to make this work no matter where the
- * focus is inside the conv window, without having to bind to
- * focus-in-event on the g(d|t)kwindow */
-@@ -299,7 +299,7 @@ attach_signals(GaimConversation *conv)
- imhtml_ids = g_slist_append(imhtml_ids, GUINT_TO_POINTER(id));
- }
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_click")) {
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_click")) {
- /* TODO similarly should really find a way to allow for clicking in other
- * places of the window */
- id = g_signal_connect(G_OBJECT(gtkconv->entry), "button-press-event",
-@@ -311,23 +311,23 @@ attach_signals(GaimConversation *conv)
- imhtml_ids = g_slist_append(imhtml_ids, GUINT_TO_POINTER(id));
- }
-
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_type")) {
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_type")) {
- id = g_signal_connect(G_OBJECT(gtkconv->entry), "key-press-event",
- G_CALLBACK(unnotify_cb), conv);
- entry_ids = g_slist_append(entry_ids, GUINT_TO_POINTER(id));
- }
-
-- gaim_conversation_set_data(conv, "notify-imhtml-signals", imhtml_ids);
-- gaim_conversation_set_data(conv, "notify-entry-signals", entry_ids);
-+ gaim2_conversation_set_data(conv, "notify-imhtml-signals", imhtml_ids);
-+ gaim2_conversation_set_data(conv, "notify-entry-signals", entry_ids);
-
- return 0;
- }
-
- static void
--detach_signals(GaimConversation *conv)
-+detach_signals(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv = NULL;
-- GaimGtkWindow *gtkwin = NULL;
-+ Gaim2GtkConversation *gtkconv = NULL;
-+ Gaim2GtkWindow *gtkwin = NULL;
- GSList *ids = NULL, *l;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-@@ -335,26 +335,26 @@ detach_signals(GaimConversation *conv)
- return;
- gtkwin = gtkconv->win;
-
-- ids = gaim_conversation_get_data(conv, "notify-imhtml-signals");
-+ ids = gaim2_conversation_get_data(conv, "notify-imhtml-signals");
- for (l = ids; l != NULL; l = l->next)
- g_signal_handler_disconnect(gtkconv->imhtml, GPOINTER_TO_INT(l->data));
- g_slist_free(ids);
-
-- ids = gaim_conversation_get_data(conv, "notify-entry-signals");
-+ ids = gaim2_conversation_get_data(conv, "notify-entry-signals");
- for (l = ids; l != NULL; l = l->next)
- g_signal_handler_disconnect(gtkconv->entry, GPOINTER_TO_INT(l->data));
- g_slist_free(ids);
-
-- gaim_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-+ gaim2_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-
-- gaim_conversation_set_data(conv, "notify-imhtml-signals", NULL);
-- gaim_conversation_set_data(conv, "notify-entry-signals", NULL);
-+ gaim2_conversation_set_data(conv, "notify-imhtml-signals", NULL);
-+ gaim2_conversation_set_data(conv, "notify-entry-signals", NULL);
- }
-
- static void
--conv_created(GaimConversation *conv)
-+conv_created(Gaim2Conversation *conv)
- {
-- gaim_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-+ gaim2_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-
- /* always attach the signals, notify() will take care of conversation type
- * checking */
-@@ -362,137 +362,137 @@ conv_created(GaimConversation *conv)
- }
-
- static void
--conv_switched(GaimConversation *old_conv, GaimConversation *new_conv)
-+conv_switched(Gaim2Conversation *old_conv, Gaim2Conversation *new_conv)
- {
- #if 0
-- GaimGtkWindow *gaimwin = gaim_conversation_get_window(new_conv);
-+ Gaim2GtkWindow *gaim2win = gaim2_conversation_get_window(new_conv);
- #endif
-
- /*
- * If the conversation was switched, then make sure we re-notify
-- * because Gaim will have overwritten our custom window title.
-+ * because Gaim2 will have overwritten our custom window title.
- */
- notify(new_conv, FALSE);
-
- #if 0
- printf("conv_switched - %p - %p\n", old_conv, new_conv);
-- printf("count - %d\n", count_messages(gaimwin));
-- if (gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_switch"))
-+ printf("count - %d\n", count_messages(gaim2win));
-+ if (gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_switch"))
- unnotify(new_conv, FALSE);
- else {
- /* if we don't have notification on the window then we don't want to
- * re-notify it */
-- if (count_messages(gaimwin))
-- notify_win(gaimwin);
-+ if (count_messages(gaim2win))
-+ notify_win(gaim2win);
- }
- #endif
- }
-
- static void
--deleting_conv(GaimConversation *conv)
-+deleting_conv(Gaim2Conversation *conv)
- {
-- GaimGtkWindow *gaimwin = NULL;
-+ Gaim2GtkWindow *gaim2win = NULL;
-
- detach_signals(conv);
-
-- gaimwin = GAIM_GTK_CONVERSATION(conv)->win;
-+ gaim2win = GAIM_GTK_CONVERSATION(conv)->win;
-
-- handle_urgent(gaimwin, FALSE);
-- gaim_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-+ handle_urgent(gaim2win, FALSE);
-+ gaim2_conversation_set_data(conv, "notify-message-count", GINT_TO_POINTER(0));
-
- return;
-
- #if 0
- /* i think this line crashes */
-- if (count_messages(gaimwin))
-- notify_win(gaimwin);
-+ if (count_messages(gaim2win))
-+ notify_win(gaim2win);
- #endif
- }
-
- #if 0
- static void
--conversation_dragging(GaimConversation *active_conv,
-- GaimGtkWindow *old_gaimwin,
-- GaimGtkWindow *new_gaimwin)
-+conversation_dragging(Gaim2Conversation *active_conv,
-+ Gaim2GtkWindow *old_gaim2win,
-+ Gaim2GtkWindow *new_gaim2win)
- {
-- if (old_gaimwin != new_gaimwin) {
-- if (old_gaimwin == NULL) {
-+ if (old_gaim2win != new_gaim2win) {
-+ if (old_gaim2win == NULL) {
- /*
-- gaim_conversation_autoset_title(active_conv);
-- handle_urgent(new_gaimwin, FALSE);
-+ gaim2_conversation_autoset_title(active_conv);
-+ handle_urgent(new_gaim2win, FALSE);
- */
-
-- if (count_messages(new_gaimwin))
-- notify_win(new_gaimwin);
-+ if (count_messages(new_gaim2win))
-+ notify_win(new_gaim2win);
- } else {
-- printf("if else count = %d\n", count_messages(new_gaimwin));
-- printf("if else count = %d\n", count_messages(old_gaimwin));
-+ printf("if else count = %d\n", count_messages(new_gaim2win));
-+ printf("if else count = %d\n", count_messages(old_gaim2win));
- /*
-- GaimConversation *old_active_conv = NULL;
-- old_active_conv = gaim_conv_window_get_active_conversation(new_gaimwin);
-+ Gaim2Conversation *old_active_conv = NULL;
-+ old_active_conv = gaim2_conv_window_get_active_conversation(new_gaim2win);
-
-- gaim_conversation_autoset_title(old_active_conv);
-- handle_urgent(old_gaimwin, FALSE);
-+ gaim2_conversation_autoset_title(old_active_conv);
-+ handle_urgent(old_gaim2win, FALSE);
-
-- if (count_messages(old_gaimwin))
-- notify_win(old_gaimwin);
-+ if (count_messages(old_gaim2win))
-+ notify_win(old_gaim2win);
-
-- gaim_conversation_autoset_title(active_conv);
-- handle_urgent(new_gaimwin, FALSE);
-+ gaim2_conversation_autoset_title(active_conv);
-+ handle_urgent(new_gaim2win, FALSE);
-
-- if (count_messages(new_gaimwin))
-- notify_win(new_gaimwin);
-+ if (count_messages(new_gaim2win))
-+ notify_win(new_gaim2win);
- */
- }
- } else {
-- printf("else count = %d\n", count_messages(new_gaimwin));
-- printf("else count = %d\n", count_messages(old_gaimwin));
-+ printf("else count = %d\n", count_messages(new_gaim2win));
-+ printf("else count = %d\n", count_messages(old_gaim2win));
- /*
-- gaim_conversation_autoset_title(active_conv);
-- handle_urgent(old_gaimwin, FALSE);
-+ gaim2_conversation_autoset_title(active_conv);
-+ handle_urgent(old_gaim2win, FALSE);
-
-- if (count_messages(old_gaimwin))
-- notify_win(old_gaimwin);
-+ if (count_messages(old_gaim2win))
-+ notify_win(old_gaim2win);
- */
- }
- }
- #endif
-
- static void
--handle_string(GaimGtkWindow *gaimwin)
-+handle_string(Gaim2GtkWindow *gaim2win)
- {
- GtkWindow *window = NULL;
- gchar newtitle[256];
-
-- g_return_if_fail(gaimwin != NULL);
-+ g_return_if_fail(gaim2win != NULL);
-
-- window = GTK_WINDOW(gaimwin->window);
-+ window = GTK_WINDOW(gaim2win->window);
- g_return_if_fail(window != NULL);
-
- g_snprintf(newtitle, sizeof(newtitle), "%s%s",
-- gaim_prefs_get_string("/plugins/gtk/X11/notify/title_string"),
-+ gaim2_prefs_get_string("/plugins/gtk/X11/notify/title_string"),
- gtk_window_get_title(window));
- gtk_window_set_title(window, newtitle);
- }
-
- static void
--handle_count(GaimGtkWindow *gaimwin)
-+handle_count(Gaim2GtkWindow *gaim2win)
- {
- GtkWindow *window;
- char newtitle[256];
-
-- g_return_if_fail(gaimwin != NULL);
-+ g_return_if_fail(gaim2win != NULL);
-
-- window = GTK_WINDOW(gaimwin->window);
-+ window = GTK_WINDOW(gaim2win->window);
- g_return_if_fail(window != NULL);
-
- g_snprintf(newtitle, sizeof(newtitle), "[%d] %s",
-- count_messages(gaimwin), gtk_window_get_title(window));
-+ count_messages(gaim2win), gtk_window_get_title(window));
- gtk_window_set_title(window, newtitle);
- }
-
- static void
--handle_urgent(GaimGtkWindow *win, gboolean add)
-+handle_urgent(Gaim2GtkWindow *win, gboolean add)
- {
- XWMHints *hints;
-
-@@ -515,9 +515,9 @@ handle_urgent(GaimGtkWindow *win, gboole
- }
-
- static void
--handle_raise(GaimGtkWindow *gaimwin)
-+handle_raise(Gaim2GtkWindow *gaim2win)
- {
-- gaim_gtk_conv_window_raise(gaimwin);
-+ gaim2_gtk_conv_window_raise(gaim2win);
- }
-
- static void
-@@ -528,7 +528,7 @@ type_toggle_cb(GtkWidget *widget, gpoint
-
- g_snprintf(pref, sizeof(pref), "/plugins/gtk/X11/notify/%s", (char *)data);
-
-- gaim_prefs_set_bool(pref, on);
-+ gaim2_prefs_set_bool(pref, on);
- }
-
- static void
-@@ -539,13 +539,13 @@ method_toggle_cb(GtkWidget *widget, gpoi
-
- g_snprintf(pref, sizeof(pref), "/plugins/gtk/X11/notify/%s", (char *)data);
-
-- gaim_prefs_set_bool(pref, on);
-+ gaim2_prefs_set_bool(pref, on);
-
- if (!strcmp(data, "method_string")) {
- GtkWidget *entry = g_object_get_data(G_OBJECT(widget), "title-entry");
- gtk_widget_set_sensitive(entry, on);
-
-- gaim_prefs_set_string("/plugins/gtk/X11/notify/title_string", gtk_entry_get_text(GTK_ENTRY(entry)));
-+ gaim2_prefs_set_string("/plugins/gtk/X11/notify/title_string", gtk_entry_get_text(GTK_ENTRY(entry)));
- }
-
- apply_method();
-@@ -559,7 +559,7 @@ notify_toggle_cb(GtkWidget *widget, gpoi
-
- g_snprintf(pref, sizeof(pref), "/plugins/gtk/X11/notify/%s", (char *)data);
-
-- gaim_prefs_set_bool(pref, on);
-+ gaim2_prefs_set_bool(pref, on);
-
- apply_notify();
- }
-@@ -571,7 +571,7 @@ options_entry_cb(GtkWidget *widget, GdkE
- return FALSE;
-
- if (!strcmp(data, "method_string")) {
-- gaim_prefs_set_string("/plugins/gtk/X11/notify/title_string", gtk_entry_get_text(GTK_ENTRY(widget)));
-+ gaim2_prefs_set_string("/plugins/gtk/X11/notify/title_string", gtk_entry_get_text(GTK_ENTRY(widget)));
- }
-
- apply_method();
-@@ -581,17 +581,17 @@ options_entry_cb(GtkWidget *widget, GdkE
-
- static void
- apply_method() {
-- GList *convs = gaim_get_conversations();
-- GaimGtkWindow *gaimwin = NULL;
-+ GList *convs = gaim2_get_conversations();
-+ Gaim2GtkWindow *gaim2win = NULL;
-
-- for (convs = gaim_get_conversations(); convs != NULL; convs = convs->next) {
-- GaimConversation *conv = (GaimConversation *)convs->data;
-+ for (convs = gaim2_get_conversations(); convs != NULL; convs = convs->next) {
-+ Gaim2Conversation *conv = (Gaim2Conversation *)convs->data;
-
- /* remove notifications */
- unnotify(conv, FALSE);
-
-- gaimwin = GAIM_GTK_CONVERSATION(conv)->win;
-- if (GPOINTER_TO_INT(gaim_conversation_get_data(conv, "notify-message-count")) != 0)
-+ gaim2win = GAIM_GTK_CONVERSATION(conv)->win;
-+ if (GPOINTER_TO_INT(gaim2_conversation_get_data(conv, "notify-message-count")) != 0)
- /* reattach appropriate notifications */
- notify(conv, FALSE);
- }
-@@ -600,10 +600,10 @@ apply_method() {
- static void
- apply_notify()
- {
-- GList *convs = gaim_get_conversations();
-+ GList *convs = gaim2_get_conversations();
-
- while (convs) {
-- GaimConversation *conv = (GaimConversation *)convs->data;
-+ Gaim2Conversation *conv = (Gaim2Conversation *)convs->data;
-
- /* detach signals */
- detach_signals(conv);
-@@ -615,7 +615,7 @@ apply_notify()
- }
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret = NULL, *frame = NULL;
- GtkWidget *vbox = NULL, *hbox = NULL;
-@@ -625,33 +625,33 @@ get_config_frame(GaimPlugin *plugin)
- gtk_container_set_border_width(GTK_CONTAINER (ret), 12);
-
- /*---------- "Notify For" ----------*/
-- frame = gaim_gtk_make_frame(ret, _("Notify For"));
-+ frame = gaim2_gtk_make_frame(ret, _("Notify For"));
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(frame), vbox);
-
- toggle = gtk_check_button_new_with_mnemonic(_("_IM windows"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/type_im"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/type_im"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(type_toggle_cb), "type_im");
-
- toggle = gtk_check_button_new_with_mnemonic(_("C_hat windows"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/type_chat"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/type_chat"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(type_toggle_cb), "type_chat");
-
- toggle = gtk_check_button_new_with_mnemonic(_("_Focused windows"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/type_focused"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/type_focused"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(type_toggle_cb), "type_focused");
-
- /*---------- "Notification Methods" ----------*/
-- frame = gaim_gtk_make_frame(ret, _("Notification Methods"));
-+ frame = gaim2_gtk_make_frame(ret, _("Notification Methods"));
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(frame), vbox);
-
-@@ -660,16 +660,16 @@ get_config_frame(GaimPlugin *plugin)
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
- toggle = gtk_check_button_new_with_mnemonic(_("Prepend _string into window title:"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_string"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_string"));
- gtk_box_pack_start(GTK_BOX(hbox), toggle, FALSE, FALSE, 0);
-
- entry = gtk_entry_new();
- gtk_box_pack_start(GTK_BOX(hbox), entry, FALSE, FALSE, 0);
- gtk_entry_set_max_length(GTK_ENTRY(entry), 10);
- gtk_widget_set_sensitive(GTK_WIDGET(entry),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_string"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_string"));
- gtk_entry_set_text(GTK_ENTRY(entry),
-- gaim_prefs_get_string("/plugins/gtk/X11/notify/title_string"));
-+ gaim2_prefs_get_string("/plugins/gtk/X11/notify/title_string"));
- g_object_set_data(G_OBJECT(toggle), "title-entry", entry);
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(method_toggle_cb), "method_string");
-@@ -679,7 +679,7 @@ get_config_frame(GaimPlugin *plugin)
- /* Count method button */
- toggle = gtk_check_button_new_with_mnemonic(_("Insert c_ount of new messages into window title"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_count"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_count"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(method_toggle_cb), "method_count");
-@@ -688,7 +688,7 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("Set window manager \"_URGENT\" hint"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_urgent"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_urgent"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(method_toggle_cb), "method_urgent");
-
-@@ -696,12 +696,12 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("R_aise conversation window"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/method_raise"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/method_raise"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(method_toggle_cb), "method_raise");
-
- /*---------- "Notification Removals" ----------*/
-- frame = gaim_gtk_make_frame(ret, _("Notification Removal"));
-+ frame = gaim2_gtk_make_frame(ret, _("Notification Removal"));
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(frame), vbox);
-
-@@ -709,14 +709,14 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("Remove when conversation window _gains focus"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_focus"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_focus"));
- g_signal_connect(G_OBJECT(toggle), "toggled", G_CALLBACK(notify_toggle_cb), "notify_focus");
-
- /* Remove on click button */
- toggle = gtk_check_button_new_with_mnemonic(_("Remove when conversation window _receives click"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_click"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_click"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(notify_toggle_cb), "notify_click");
-
-@@ -724,7 +724,7 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("Remove when _typing in conversation window"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_type"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_type"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(notify_toggle_cb), "notify_type");
-
-@@ -732,7 +732,7 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("Remove when a _message gets sent"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_send"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_send"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(notify_toggle_cb), "notify_send");
-
-@@ -741,7 +741,7 @@ get_config_frame(GaimPlugin *plugin)
- toggle = gtk_check_button_new_with_mnemonic(_("Remove on switch to conversation ta_b"));
- gtk_box_pack_start(GTK_BOX(vbox), toggle, FALSE, FALSE, 0);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toggle),
-- gaim_prefs_get_bool("/plugins/gtk/X11/notify/notify_switch"));
-+ gaim2_prefs_get_bool("/plugins/gtk/X11/notify/notify_switch"));
- g_signal_connect(G_OBJECT(toggle), "toggled",
- G_CALLBACK(notify_toggle_cb), "notify_switch");
- #endif
-@@ -751,37 +751,37 @@ get_config_frame(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- GList *convs = gaim_get_conversations();
-- void *conv_handle = gaim_conversations_get_handle();
-- void *gtk_conv_handle = gaim_gtk_conversations_get_handle();
-+ GList *convs = gaim2_get_conversations();
-+ void *conv_handle = gaim2_conversations_get_handle();
-+ void *gtk_conv_handle = gaim2_gtk_conversations_get_handle();
-
- my_plugin = plugin;
-
-- gaim_signal_connect(gtk_conv_handle, "displayed-im-msg", plugin,
-+ gaim2_signal_connect(gtk_conv_handle, "displayed-im-msg", plugin,
- GAIM_CALLBACK(message_displayed_cb), NULL);
-- gaim_signal_connect(gtk_conv_handle, "displayed-chat-msg", plugin,
-+ gaim2_signal_connect(gtk_conv_handle, "displayed-chat-msg", plugin,
- GAIM_CALLBACK(message_displayed_cb), NULL);
-- gaim_signal_connect(conv_handle, "sent-im-msg", plugin,
-+ gaim2_signal_connect(conv_handle, "sent-im-msg", plugin,
- GAIM_CALLBACK(im_sent_im), NULL);
-- gaim_signal_connect(conv_handle, "sent-chat-msg", plugin,
-+ gaim2_signal_connect(conv_handle, "sent-chat-msg", plugin,
- GAIM_CALLBACK(chat_sent_im), NULL);
-- gaim_signal_connect(conv_handle, "conversation-created", plugin,
-+ gaim2_signal_connect(conv_handle, "conversation-created", plugin,
- GAIM_CALLBACK(conv_created), NULL);
-- gaim_signal_connect(conv_handle, "chat-joined", plugin,
-+ gaim2_signal_connect(conv_handle, "chat-joined", plugin,
- GAIM_CALLBACK(conv_created), NULL);
-- gaim_signal_connect(conv_handle, "deleting-conversation", plugin,
-+ gaim2_signal_connect(conv_handle, "deleting-conversation", plugin,
- GAIM_CALLBACK(deleting_conv), NULL);
-- gaim_signal_connect(conv_handle, "conversation-switched", plugin,
-+ gaim2_signal_connect(conv_handle, "conversation-switched", plugin,
- GAIM_CALLBACK(conv_switched), NULL);
- #if 0
-- gaim_signal_connect(gtk_conv_handle, "conversation-dragging", plugin,
-+ gaim2_signal_connect(gtk_conv_handle, "conversation-dragging", plugin,
- GAIM_CALLBACK(conversation_dragging), NULL);
- #endif
-
- while (convs) {
-- GaimConversation *conv = (GaimConversation *)convs->data;
-+ Gaim2Conversation *conv = (Gaim2Conversation *)convs->data;
-
- /* attach signals */
- attach_signals(conv);
-@@ -793,12 +793,12 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
-- GList *convs = gaim_get_conversations();
-+ GList *convs = gaim2_get_conversations();
-
- while (convs) {
-- GaimConversation *conv = (GaimConversation *)convs->data;
-+ Gaim2Conversation *conv = (Gaim2Conversation *)convs->data;
-
- /* kill signals */
- detach_signals(conv);
-@@ -809,13 +809,13 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -848,25 +848,25 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk");
-- gaim_prefs_add_none("/plugins/gtk/X11");
-- gaim_prefs_add_none("/plugins/gtk/X11/notify");
--
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/type_im", TRUE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/type_chat", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/type_focused", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/method_string", FALSE);
-- gaim_prefs_add_string("/plugins/gtk/X11/notify/title_string", "(*)");
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/method_urgent", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/method_count", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/method_raise", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/notify_focus", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/notify_click", FALSE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/notify_type", TRUE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/notify_send", TRUE);
-- gaim_prefs_add_bool("/plugins/gtk/X11/notify/notify_switch", TRUE);
-+ gaim2_prefs_add_none("/plugins/gtk");
-+ gaim2_prefs_add_none("/plugins/gtk/X11");
-+ gaim2_prefs_add_none("/plugins/gtk/X11/notify");
-+
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/type_im", TRUE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/type_chat", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/type_focused", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/method_string", FALSE);
-+ gaim2_prefs_add_string("/plugins/gtk/X11/notify/title_string", "(*)");
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/method_urgent", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/method_count", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/method_raise", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/notify_focus", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/notify_click", FALSE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/notify_type", TRUE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/notify_send", TRUE);
-+ gaim2_prefs_add_bool("/plugins/gtk/X11/notify/notify_switch", TRUE);
- }
-
- GAIM_INIT_PLUGIN(notify, init_plugin, info)
-diff -prNu ./plugins/perl/common/AccountOpts.xs ./plugins/perl/common/AccountOpts.xs
---- ./plugins/perl/common/AccountOpts.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/AccountOpts.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,39 +1,39 @@
- #include "module.h"
-
--MODULE = Gaim::Account::Option PACKAGE = Gaim::Account::Option PREFIX = gaim_account_option_
-+MODULE = Gaim2::Account::Option PACKAGE = Gaim2::Account::Option PREFIX = gaim2_account_option_
- PROTOTYPES: ENABLE
-
- void
--gaim_account_option_destroy(option)
-- Gaim::Account::Option option
-+gaim2_account_option_destroy(option)
-+ Gaim2::Account::Option option
-
- const char *
--gaim_account_option_get_default_string(option)
-- Gaim::Account::Option option
-+gaim2_account_option_get_default_string(option)
-+ Gaim2::Account::Option option
-
- void
--gaim_account_option_add_list_item(option, key, value)
-- Gaim::Account::Option option
-+gaim2_account_option_add_list_item(option, key, value)
-+ Gaim2::Account::Option option
- const char * key
- const char * value
-
- void
--gaim_account_option_set_default_string(option, value);
-- Gaim::Account::Option option
-+gaim2_account_option_set_default_string(option, value);
-+ Gaim2::Account::Option option
- const char * value
-
- void
--gaim_account_option_set_default_int(option, value);
-- Gaim::Account::Option option
-+gaim2_account_option_set_default_int(option, value);
-+ Gaim2::Account::Option option
- int value
-
- void
--gaim_account_option_set_default_bool(option, value);
-- Gaim::Account::Option option
-+gaim2_account_option_set_default_bool(option, value);
-+ Gaim2::Account::Option option
- gboolean value
-
--Gaim::Account::Option
--gaim_account_option_list_new(class, text, pref_name, values)
-+Gaim2::Account::Option
-+gaim2_account_option_list_new(class, text, pref_name, values)
- const char * text
- const char * pref_name
- SV * values
-@@ -48,80 +48,80 @@ CODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(values), i, 0), t_sl));
- }
-- RETVAL = gaim_account_option_list_new(text, pref_name, t_GL);
-+ RETVAL = gaim2_account_option_list_new(text, pref_name, t_GL);
- OUTPUT:
- RETVAL
-
--Gaim::Account::Option
--gaim_account_option_string_new(class, text, pref_name, default_value)
-+Gaim2::Account::Option
-+gaim2_account_option_string_new(class, text, pref_name, default_value)
- const char * text
- const char * pref_name
- const char * default_value
- C_ARGS:
- text, pref_name, default_value
-
--Gaim::Account::Option
--gaim_account_option_int_new(class, text, pref_name, default_value)
-+Gaim2::Account::Option
-+gaim2_account_option_int_new(class, text, pref_name, default_value)
- const char * text
- const char * pref_name
- gboolean default_value
- C_ARGS:
- text, pref_name, default_value
-
--Gaim::Account::Option
--gaim_account_option_bool_new(class, text, pref_name, default_value)
-+Gaim2::Account::Option
-+gaim2_account_option_bool_new(class, text, pref_name, default_value)
- const char * text
- const char * pref_name
- gboolean default_value
- C_ARGS:
- text, pref_name, default_value
-
--Gaim::Account::Option
--gaim_account_option_new(class, type, text, pref_name)
-- Gaim::PrefType type
-+Gaim2::Account::Option
-+gaim2_account_option_new(class, type, text, pref_name)
-+ Gaim2::PrefType type
- const char * text
- const char * pref_name
- C_ARGS:
- type, text, pref_name
-
- void
--gaim_account_option_get_list(option)
-- Gaim::Account::Option option
-+gaim2_account_option_get_list(option)
-+ Gaim2::Account::Option option
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_account_option_get_list(option); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_account_option_get_list(option); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
--Gaim::PrefType
--gaim_account_option_get_type(option)
-- Gaim::Account::Option option
-+Gaim2::PrefType
-+gaim2_account_option_get_type(option)
-+ Gaim2::Account::Option option
-
- gboolean
--gaim_account_option_get_masked(option)
-- Gaim::Account::Option option
-+gaim2_account_option_get_masked(option)
-+ Gaim2::Account::Option option
-
- int
--gaim_account_option_get_default_int(option)
-- Gaim::Account::Option option;
-+gaim2_account_option_get_default_int(option)
-+ Gaim2::Account::Option option;
- INIT:
-
- gboolean
--gaim_account_option_get_default_bool(option)
-- Gaim::Account::Option option;
-+gaim2_account_option_get_default_bool(option)
-+ Gaim2::Account::Option option;
-
- const char *
--gaim_account_option_get_setting(option)
-- Gaim::Account::Option option
-+gaim2_account_option_get_setting(option)
-+ Gaim2::Account::Option option
-
- const char *
--gaim_account_option_get_text(option)
-- Gaim::Account::Option option
-+gaim2_account_option_get_text(option)
-+ Gaim2::Account::Option option
-
- void
--gaim_account_option_set_list(option, values)
-- Gaim::Account::Option option
-+gaim2_account_option_set_list(option, values)
-+ Gaim2::Account::Option option
- SV * values
- PREINIT:
- GList *t_GL;
-@@ -134,18 +134,18 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(values), i, 0), t_sl));
- }
-- gaim_account_option_set_list(option, t_GL);
-+ gaim2_account_option_set_list(option, t_GL);
-
- void
--gaim_account_option_set_masked(option, masked)
-- Gaim::Account::Option option
-+gaim2_account_option_set_masked(option, masked)
-+ Gaim2::Account::Option option
- gboolean masked
-
--MODULE = Gaim::Account::Option PACKAGE = Gaim::Account::UserSplit PREFIX = gaim_account_user_split_
-+MODULE = Gaim2::Account::Option PACKAGE = Gaim2::Account::UserSplit PREFIX = gaim2_account_user_split_
- PROTOTYPES: ENABLE
-
--Gaim::Account::UserSplit
--gaim_account_user_split_new(class, text, default_value, sep)
-+Gaim2::Account::UserSplit
-+gaim2_account_user_split_new(class, text, default_value, sep)
- const char * text
- const char * default_value
- char sep
-@@ -153,13 +153,13 @@ gaim_account_user_split_new(class, text,
- text, default_value, sep
-
- char
--gaim_account_user_split_get_separator(split)
-- Gaim::Account::UserSplit split
-+gaim2_account_user_split_get_separator(split)
-+ Gaim2::Account::UserSplit split
-
- const char *
--gaim_account_user_split_get_text(split)
-- Gaim::Account::UserSplit split
-+gaim2_account_user_split_get_text(split)
-+ Gaim2::Account::UserSplit split
-
- void
--gaim_account_user_split_destroy(split)
-- Gaim::Account::UserSplit split
-+gaim2_account_user_split_destroy(split)
-+ Gaim2::Account::UserSplit split
-diff -prNu ./plugins/perl/common/Account.xs ./plugins/perl/common/Account.xs
---- ./plugins/perl/common/Account.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/Account.xs 2006-01-05 15:22:27.000000000 +0100
-@@ -1,100 +1,100 @@
- #include "module.h"
-
--MODULE = Gaim::Account PACKAGE = Gaim::Account PREFIX = gaim_account_
-+MODULE = Gaim2::Account PACKAGE = Gaim2::Account PREFIX = gaim2_account_
- PROTOTYPES: ENABLE
-
--Gaim::Presence
--gaim_account_get_presence(account)
-- Gaim::Account account
-+Gaim2::Presence
-+gaim2_account_get_presence(account)
-+ Gaim2::Account account
-
--Gaim::Account
--gaim_account_new(class, username, protocol_id)
-+Gaim2::Account
-+gaim2_account_new(class, username, protocol_id)
- const char * username
- const char * protocol_id
- C_ARGS:
- username, protocol_id
-
- void
--gaim_account_destroy(account)
-- Gaim::Account account
-+gaim2_account_destroy(account)
-+ Gaim2::Account account
-
- void
--gaim_account_connect(account)
-- Gaim::Account account
-+gaim2_account_connect(account)
-+ Gaim2::Account account
-
- void
--gaim_account_register(account)
-- Gaim::Account account
-+gaim2_account_register(account)
-+ Gaim2::Account account
-
- void
--gaim_account_disconnect(account)
-- Gaim::Account account
-+gaim2_account_disconnect(account)
-+ Gaim2::Account account
-
- void
--gaim_account_request_change_password(account)
-- Gaim::Account account
-+gaim2_account_request_change_password(account)
-+ Gaim2::Account account
-
- void
--gaim_account_request_change_user_info(account)
-- Gaim::Account account
-+gaim2_account_request_change_user_info(account)
-+ Gaim2::Account account
-
- void
--gaim_account_set_username(account, username)
-- Gaim::Account account
-+gaim2_account_set_username(account, username)
-+ Gaim2::Account account
- const char * username
-
- void
--gaim_account_set_password(account, password)
-- Gaim::Account account
-+gaim2_account_set_password(account, password)
-+ Gaim2::Account account
- const char * password
-
- void
--gaim_account_set_alias(account, alias)
-- Gaim::Account account
-+gaim2_account_set_alias(account, alias)
-+ Gaim2::Account account
- const char * alias
-
- void
--gaim_account_set_user_info(account, user_info)
-- Gaim::Account account
-+gaim2_account_set_user_info(account, user_info)
-+ Gaim2::Account account
- const char *user_info
-
- void
--gaim_account_set_buddy_icon(account, icon)
-- Gaim::Account account
-+gaim2_account_set_buddy_icon(account, icon)
-+ Gaim2::Account account
- const char *icon
-
- void
--gaim_account_set_connection(account, gc)
-- Gaim::Account account
-- Gaim::Connection gc
-+gaim2_account_set_connection(account, gc)
-+ Gaim2::Account account
-+ Gaim2::Connection gc
-
- void
--gaim_account_set_remember_password(account, value)
-- Gaim::Account account
-+gaim2_account_set_remember_password(account, value)
-+ Gaim2::Account account
- gboolean value
-
- void
--gaim_account_set_check_mail(account, value)
-- Gaim::Account account
-+gaim2_account_set_check_mail(account, value)
-+ Gaim2::Account account
- gboolean value
-
- void
--gaim_account_set_proxy_info(account, info)
-- Gaim::Account account
-- Gaim::ProxyInfo info
-+gaim2_account_set_proxy_info(account, info)
-+ Gaim2::Account account
-+ Gaim2::ProxyInfo info
-
- void
--gaim_account_set_status(account, status_id, active)
-- Gaim::Account account
-+gaim2_account_set_status(account, status_id, active)
-+ Gaim2::Account account
- const char *status_id
- gboolean active
- CODE:
-- gaim_account_set_status(account, status_id, active);
-+ gaim2_account_set_status(account, status_id, active);
-
-
- void
--gaim_account_set_status_types(account, status_types)
-- Gaim::Account account
-+gaim2_account_set_status_types(account, status_types)
-+ Gaim2::Account account
- SV * status_types
- PREINIT:
- GList *t_GL;
-@@ -107,92 +107,92 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(status_types), i, 0), t_sl));
- }
-- gaim_account_set_status_types(account, t_GL);
-+ gaim2_account_set_status_types(account, t_GL);
-
-
- void
--gaim_account_clear_settings(account)
-- Gaim::Account account
-+gaim2_account_clear_settings(account)
-+ Gaim2::Account account
-
- void
--gaim_account_set_int(account, name, value)
-- Gaim::Account account
-+gaim2_account_set_int(account, name, value)
-+ Gaim2::Account account
- const char *name
- int value
-
- gboolean
--gaim_account_is_connected(account)
-- Gaim::Account account
-+gaim2_account_is_connected(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_username(account)
-- Gaim::Account account
-+gaim2_account_get_username(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_password(account)
-- Gaim::Account account
-+gaim2_account_get_password(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_alias(account)
-- Gaim::Account account
-+gaim2_account_get_alias(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_user_info(account)
-- Gaim::Account account
-+gaim2_account_get_user_info(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_buddy_icon(account)
-- Gaim::Account account
-+gaim2_account_get_buddy_icon(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_protocol_id(account)
-- Gaim::Account account
-+gaim2_account_get_protocol_id(account)
-+ Gaim2::Account account
-
- const char *
--gaim_account_get_protocol_name(account)
-- Gaim::Account account
-+gaim2_account_get_protocol_name(account)
-+ Gaim2::Account account
-
--Gaim::Connection
--gaim_account_get_connection(account)
-- Gaim::Account account
-+Gaim2::Connection
-+gaim2_account_get_connection(account)
-+ Gaim2::Account account
-
- gboolean
--gaim_account_get_remember_password(account)
-- Gaim::Account account
-+gaim2_account_get_remember_password(account)
-+ Gaim2::Account account
-
- gboolean
--gaim_account_get_check_mail(account)
-- Gaim::Account account
-+gaim2_account_get_check_mail(account)
-+ Gaim2::Account account
-
--Gaim::ProxyInfo
--gaim_account_get_proxy_info(account)
-- Gaim::Account account
--
--Gaim::Status
--gaim_account_get_active_status(account)
-- Gaim::Account account
-+Gaim2::ProxyInfo
-+gaim2_account_get_proxy_info(account)
-+ Gaim2::Account account
-+
-+Gaim2::Status
-+gaim2_account_get_active_status(account)
-+ Gaim2::Account account
-
- void
--gaim_account_get_status_types(account)
-- Gaim::Account account
-+gaim2_account_get_status_types(account)
-+ Gaim2::Account account
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_account_get_status_types(account); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::Status::Type")));
-+ for (l = gaim2_account_get_status_types(account); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::Status::Type")));
- }
-
--Gaim::Log
--gaim_account_get_log(account)
-- Gaim::Account account
-+Gaim2::Log
-+gaim2_account_get_log(account)
-+ Gaim2::Account account
-
- void
--gaim_account_destroy_log(account)
-- Gaim::Account account
-+gaim2_account_destroy_log(account)
-+ Gaim2::Account account
-
- void
--gaim_account_add_buddies(account, list)
-- Gaim::Account account
-+gaim2_account_add_buddies(account, list)
-+ Gaim2::Account account
- SV * list
- PREINIT:
- GList *t_GL;
-@@ -205,22 +205,22 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(list), i, 0), t_sl));
- }
-- gaim_account_add_buddies(account, t_GL);
-+ gaim2_account_add_buddies(account, t_GL);
-
- void
--gaim_account_add_buddy(account, buddy)
-- Gaim::Account account
-- Gaim::BuddyList::Buddy buddy
-+gaim2_account_add_buddy(account, buddy)
-+ Gaim2::Account account
-+ Gaim2::BuddyList::Buddy buddy
-
- void
--gaim_account_change_password(account, a, b)
-- Gaim::Account account
-+gaim2_account_change_password(account, a, b)
-+ Gaim2::Account account
- const char * a
- const char * b
-
- void
--gaim_account_remove_buddies(account, A, B)
-- Gaim::Account account
-+gaim2_account_remove_buddies(account, A, B)
-+ Gaim2::Account account
- SV * A
- SV * B
- PREINIT:
-@@ -242,77 +242,77 @@ PPCODE:
- STRLEN t_sl;
- t_GL2 = g_list_append(t_GL2, SvPV(*av_fetch((AV *)SvRV(B), i, 0), t_sl));
- }
-- gaim_account_remove_buddies(account, t_GL1, t_GL2);
-+ gaim2_account_remove_buddies(account, t_GL1, t_GL2);
-
- void
--gaim_account_remove_buddy(account, buddy, group)
-- Gaim::Account account
-- Gaim::BuddyList::Buddy buddy
-- Gaim::BuddyList::Group group
-+gaim2_account_remove_buddy(account, buddy, group)
-+ Gaim2::Account account
-+ Gaim2::BuddyList::Buddy buddy
-+ Gaim2::BuddyList::Group group
-
- void
--gaim_account_remove_group(account, group)
-- Gaim::Account account
-- Gaim::BuddyList::Group group
-+gaim2_account_remove_group(account, group)
-+ Gaim2::Account account
-+ Gaim2::BuddyList::Group group
-
-
-
-
--MODULE = Gaim::Account PACKAGE = Gaim::Accounts PREFIX = gaim_accounts_
-+MODULE = Gaim2::Account PACKAGE = Gaim2::Accounts PREFIX = gaim2_accounts_
- PROTOTYPES: ENABLE
-
- void
--gaim_accounts_add(account)
-- Gaim::Account account
-+gaim2_accounts_add(account)
-+ Gaim2::Account account
-
- void
--gaim_accounts_remove(account)
-- Gaim::Account account
-+gaim2_accounts_remove(account)
-+ Gaim2::Account account
-
- void
--gaim_accounts_delete(account)
-- Gaim::Account account
-+gaim2_accounts_delete(account)
-+ Gaim2::Account account
-
- void
--gaim_accounts_reorder(account, new_index)
-- Gaim::Account account
-+gaim2_accounts_reorder(account, new_index)
-+ Gaim2::Account account
- size_t new_index
-
- void
--gaim_accounts_get_all()
-+gaim2_accounts_get_all()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_accounts_get_all(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::Account")));
-+ for (l = gaim2_accounts_get_all(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::Account")));
- }
-
- void
--gaim_accounts_get_all_active()
-+gaim2_accounts_get_all_active()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_accounts_get_all_active(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::Account")));
-+ for (l = gaim2_accounts_get_all_active(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::Account")));
- }
-
--Gaim::Account
--gaim_accounts_find(name, protocol)
-+Gaim2::Account
-+gaim2_accounts_find(name, protocol)
- const char * name
- const char * protocol
-
- void
--gaim_accounts_set_ui_ops(ops)
-- Gaim::Account::UiOps ops
-+gaim2_accounts_set_ui_ops(ops)
-+ Gaim2::Account::UiOps ops
-
--Gaim::Account::UiOps
--gaim_accounts_get_ui_ops()
-+Gaim2::Account::UiOps
-+gaim2_accounts_get_ui_ops()
-
- void
--gaim_accounts_get_handle()
-+gaim2_accounts_get_handle()
-
- void
--gaim_accounts_init()
-+gaim2_accounts_init()
-
- void
--gaim_accounts_uninit()
-+gaim2_accounts_uninit()
-diff -prNu ./plugins/perl/common/BuddyIcon.xs ./plugins/perl/common/BuddyIcon.xs
---- ./plugins/perl/common/BuddyIcon.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/BuddyIcon.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,65 +1,65 @@
- #include "module.h"
-
--MODULE = Gaim::Buddy::Icon PACKAGE = Gaim::Buddy::Icon PREFIX = gaim_buddy_icon_
-+MODULE = Gaim2::Buddy::Icon PACKAGE = Gaim2::Buddy::Icon PREFIX = gaim2_buddy_icon_
- PROTOTYPES: ENABLE
-
- void
--gaim_buddy_icon_destroy(icon)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_destroy(icon)
-+ Gaim2::Buddy::Icon icon
-
--Gaim::Buddy::Icon
--gaim_buddy_icon_ref(icon)
-- Gaim::Buddy::Icon icon
-+Gaim2::Buddy::Icon
-+gaim2_buddy_icon_ref(icon)
-+ Gaim2::Buddy::Icon icon
-
--Gaim::Buddy::Icon
--gaim_buddy_icon_unref(icon)
-- Gaim::Buddy::Icon icon
-+Gaim2::Buddy::Icon
-+gaim2_buddy_icon_unref(icon)
-+ Gaim2::Buddy::Icon icon
-
- void
--gaim_buddy_icon_update(icon)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_update(icon)
-+ Gaim2::Buddy::Icon icon
-
- void
--gaim_buddy_icon_cache(icon, buddy)
-- Gaim::Buddy::Icon icon
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_icon_cache(icon, buddy)
-+ Gaim2::Buddy::Icon icon
-+ Gaim2::BuddyList::Buddy buddy
-
- void
--gaim_buddy_icon_set_account(icon, account)
-- Gaim::Buddy::Icon icon
-- Gaim::Account account
-+gaim2_buddy_icon_set_account(icon, account)
-+ Gaim2::Buddy::Icon icon
-+ Gaim2::Account account
-
- void
--gaim_buddy_icon_set_username(icon, username)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_set_username(icon, username)
-+ Gaim2::Buddy::Icon icon
- const char * username
-
- void
--gaim_buddy_icon_set_data(icon, data, len)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_set_data(icon, data, len)
-+ Gaim2::Buddy::Icon icon
- void * data
- size_t len
-
--Gaim::Account
--gaim_buddy_icon_get_account(icon)
-- Gaim::Buddy::Icon icon
-+Gaim2::Account
-+gaim2_buddy_icon_get_account(icon)
-+ Gaim2::Buddy::Icon icon
-
- const char *
--gaim_buddy_icon_get_username(icon)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_get_username(icon)
-+ Gaim2::Buddy::Icon icon
-
- const void *
--gaim_buddy_icon_get_data(icon, len)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_get_data(icon, len)
-+ Gaim2::Buddy::Icon icon
- size_t &len
-
- const char *
--gaim_buddy_icon_get_type(icon)
-- Gaim::Buddy::Icon icon
-+gaim2_buddy_icon_get_type(icon)
-+ Gaim2::Buddy::Icon icon
-
- void
--gaim_buddy_icon_get_scale_size(spec, width, height)
-- Gaim::Buddy::Icon::Spec spec
-+gaim2_buddy_icon_get_scale_size(spec, width, height)
-+ Gaim2::Buddy::Icon::Spec spec
- int *width
- int *height
-
-@@ -71,29 +71,29 @@ gaim_buddy_icon_get_scale_size(spec, wid
-
-
-
--MODULE = Gaim::Buddy::Icon PACKAGE = Gaim::Buddy::Icons PREFIX = gaim_buddy_icons_
-+MODULE = Gaim2::Buddy::Icon PACKAGE = Gaim2::Buddy::Icons PREFIX = gaim2_buddy_icons_
- PROTOTYPES: ENABLE
-
-
- void
--gaim_buddy_icons_set_caching(caching)
-+gaim2_buddy_icons_set_caching(caching)
- gboolean caching
-
- gboolean
--gaim_buddy_icons_is_caching()
-+gaim2_buddy_icons_is_caching()
-
- void
--gaim_buddy_icons_set_cache_dir(cache_dir)
-+gaim2_buddy_icons_set_cache_dir(cache_dir)
- const char *cache_dir
-
- const char *
--gaim_buddy_icons_get_cache_dir();
-+gaim2_buddy_icons_get_cache_dir();
-
- void *
--gaim_buddy_icons_get_handle();
-+gaim2_buddy_icons_get_handle();
-
- void
--gaim_buddy_icons_init();
-+gaim2_buddy_icons_init();
-
- void
--gaim_buddy_icons_uninit()
-+gaim2_buddy_icons_uninit()
-diff -prNu ./plugins/perl/common/BuddyList.xs ./plugins/perl/common/BuddyList.xs
---- ./plugins/perl/common/BuddyList.xs 2005-11-14 23:41:51.000000000 +0100
-+++ ./plugins/perl/common/BuddyList.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,311 +1,311 @@
- #include "module.h"
- #include "../perl-handlers.h"
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::BuddyList PREFIX = gaim_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::BuddyList PREFIX = gaim2_
- PROTOTYPES: ENABLE
-
--Gaim::BuddyList
--gaim_get_blist()
-+Gaim2::BuddyList
-+gaim2_get_blist()
-
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::Find PREFIX = gaim_find_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::Find PREFIX = gaim2_find_
- PROTOTYPES: ENABLE
-
--Gaim::BuddyList::Buddy
--gaim_find_buddy(account, name)
-- Gaim::Account account
-+Gaim2::BuddyList::Buddy
-+gaim2_find_buddy(account, name)
-+ Gaim2::Account account
- const char * name
-
- void
--gaim_find_buddies(account, name)
-- Gaim::Account account
-+gaim2_find_buddies(account, name)
-+ Gaim2::Account account
- const char * name
- PREINIT:
- GSList *l;
- PPCODE:
-- for (l = gaim_find_buddies(account, name); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::BuddyList::Buddy")));
-+ for (l = gaim2_find_buddies(account, name); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::BuddyList::Buddy")));
- }
-
- gboolean
--gaim_group_on_account(group, account)
-- Gaim::BuddyList::Group group
-- Gaim::Account account
-+gaim2_group_on_account(group, account)
-+ Gaim2::BuddyList::Group group
-+ Gaim2::Account account
-
--Gaim::BuddyList::Group
--gaim_find_group(name)
-+Gaim2::BuddyList::Group
-+gaim2_find_group(name)
- const char *name
-
-
-
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::Contact PREFIX = gaim_contact_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::Contact PREFIX = gaim2_contact_
- PROTOTYPES: ENABLE
-
--Gaim::BuddyList::Contact
--gaim_contact_new();
-+Gaim2::BuddyList::Contact
-+gaim2_contact_new();
-
--Gaim::BuddyList::Buddy
--gaim_contact_get_priority_buddy(contact)
-- Gaim::BuddyList::Contact contact
-+Gaim2::BuddyList::Buddy
-+gaim2_contact_get_priority_buddy(contact)
-+ Gaim2::BuddyList::Contact contact
-
- void
--gaim_contact_set_alias(contact, alias)
-- Gaim::BuddyList::Contact contact
-+gaim2_contact_set_alias(contact, alias)
-+ Gaim2::BuddyList::Contact contact
- const char * alias
-
- const char *
--gaim_contact_get_alias(contact)
-- Gaim::BuddyList::Contact contact
-+gaim2_contact_get_alias(contact)
-+ Gaim2::BuddyList::Contact contact
-
- gboolean
--gaim_contact_on_account(contact, account)
-- Gaim::BuddyList::Contact contact
-- Gaim::Account account
-+gaim2_contact_on_account(contact, account)
-+ Gaim2::BuddyList::Contact contact
-+ Gaim2::Account account
-
- void
--gaim_contact_invalidate_priority_buddy(contact)
-- Gaim::BuddyList::Contact contact
-+gaim2_contact_invalidate_priority_buddy(contact)
-+ Gaim2::BuddyList::Contact contact
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::Group PREFIX = gaim_group_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::Group PREFIX = gaim2_group_
- PROTOTYPES: ENABLE
-
-
--Gaim::BuddyList::Group
--gaim_group_new(name)
-+Gaim2::BuddyList::Group
-+gaim2_group_new(name)
- const char *name
-
- void
--gaim_group_get_accounts(group)
-- Gaim::BuddyList::Group group
-+gaim2_group_get_accounts(group)
-+ Gaim2::BuddyList::Group group
- PREINIT:
- GSList *l;
- PPCODE:
-- for (l = gaim_group_get_accounts(group); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_group_get_accounts(group); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- gboolean
--gaim_group_on_account(group, account)
-- Gaim::BuddyList::Group group
-- Gaim::Account account
-+gaim2_group_on_account(group, account)
-+ Gaim2::BuddyList::Group group
-+ Gaim2::Account account
-
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::BuddyList PREFIX = gaim_blist_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::BuddyList PREFIX = gaim2_blist_
- PROTOTYPES: ENABLE
-
- void
--gaim_blist_add_contact(contact, group, node)
-- Gaim::BuddyList::Contact contact
-- Gaim::BuddyList::Group group
-- Gaim::BuddyList::Node node
-+gaim2_blist_add_contact(contact, group, node)
-+ Gaim2::BuddyList::Contact contact
-+ Gaim2::BuddyList::Group group
-+ Gaim2::BuddyList::Node node
-
- void
--gaim_blist_merge_contact(source, node)
-- Gaim::BuddyList::Contact source
-- Gaim::BuddyList::Node node
-+gaim2_blist_merge_contact(source, node)
-+ Gaim2::BuddyList::Contact source
-+ Gaim2::BuddyList::Node node
-
- void
--gaim_blist_add_group(group, node)
-- Gaim::BuddyList::Group group
-- Gaim::BuddyList::Node node
-+gaim2_blist_add_group(group, node)
-+ Gaim2::BuddyList::Group group
-+ Gaim2::BuddyList::Node node
-
- void
--gaim_blist_add_buddy(buddy, contact, group, node)
-- Gaim::BuddyList::Buddy buddy
-- Gaim::BuddyList::Contact contact
-- Gaim::BuddyList::Group group
-- Gaim::BuddyList::Node node
-+gaim2_blist_add_buddy(buddy, contact, group, node)
-+ Gaim2::BuddyList::Buddy buddy
-+ Gaim2::BuddyList::Contact contact
-+ Gaim2::BuddyList::Group group
-+ Gaim2::BuddyList::Node node
-
- void
--gaim_blist_remove_buddy(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_blist_remove_buddy(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- void
--gaim_blist_remove_contact(contact)
-- Gaim::BuddyList::Contact contact
-+gaim2_blist_remove_contact(contact)
-+ Gaim2::BuddyList::Contact contact
-
- void
--gaim_blist_remove_chat(chat)
-- Gaim::BuddyList::Chat chat
-+gaim2_blist_remove_chat(chat)
-+ Gaim2::BuddyList::Chat chat
-
- void
--gaim_blist_remove_group(group)
-- Gaim::BuddyList::Group group
-+gaim2_blist_remove_group(group)
-+ Gaim2::BuddyList::Group group
-
--Gaim::BuddyList::Chat
--gaim_blist_find_chat(account, name)
-- Gaim::Account account
-+Gaim2::BuddyList::Chat
-+gaim2_blist_find_chat(account, name)
-+ Gaim2::Account account
- const char *name
-
- void
--gaim_blist_add_chat(chat, group, node)
-- Gaim::BuddyList::Chat chat
-- Gaim::BuddyList::Group group
-- Gaim::BuddyList::Node node
-+gaim2_blist_add_chat(chat, group, node)
-+ Gaim2::BuddyList::Chat chat
-+ Gaim2::BuddyList::Group group
-+ Gaim2::BuddyList::Node node
-
--Gaim::BuddyList
--gaim_blist_new()
-+Gaim2::BuddyList
-+gaim2_blist_new()
-
- void
--gaim_set_blist(blist)
-- Gaim::BuddyList blist
-+gaim2_set_blist(blist)
-+ Gaim2::BuddyList blist
-
- void
--gaim_blist_show()
-+gaim2_blist_show()
-
- void
--gaim_blist_destroy();
-+gaim2_blist_destroy();
-
- void
--gaim_blist_set_visible(show)
-+gaim2_blist_set_visible(show)
- gboolean show
-
- void
--gaim_blist_update_buddy_status(buddy, old_status)
-- Gaim::BuddyList::Buddy buddy
-- Gaim::Status old_status
-+gaim2_blist_update_buddy_status(buddy, old_status)
-+ Gaim2::BuddyList::Buddy buddy
-+ Gaim2::Status old_status
-
- void
--gaim_blist_update_buddy_icon(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_blist_update_buddy_icon(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- void
--gaim_blist_rename_buddy(buddy, name)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_blist_rename_buddy(buddy, name)
-+ Gaim2::BuddyList::Buddy buddy
- const char * name
-
- void
--gaim_blist_alias_buddy(buddy, alias)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_blist_alias_buddy(buddy, alias)
-+ Gaim2::BuddyList::Buddy buddy
- const char * alias
-
- void
--gaim_blist_server_alias_buddy(buddy, alias)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_blist_server_alias_buddy(buddy, alias)
-+ Gaim2::BuddyList::Buddy buddy
- const char * alias
-
- void
--gaim_blist_alias_chat(chat, alias)
-- Gaim::BuddyList::Chat chat
-+gaim2_blist_alias_chat(chat, alias)
-+ Gaim2::BuddyList::Chat chat
- const char * alias
-
- void
--gaim_blist_rename_group(group, name)
-- Gaim::BuddyList::Group group
-+gaim2_blist_rename_group(group, name)
-+ Gaim2::BuddyList::Group group
- const char * name
-
- void
--gaim_blist_add_account(account)
-- Gaim::Account account
-+gaim2_blist_add_account(account)
-+ Gaim2::Account account
-
- void
--gaim_blist_remove_account(account)
-- Gaim::Account account
-+gaim2_blist_remove_account(account)
-+ Gaim2::Account account
-
- int
--gaim_blist_get_group_size(group, offline)
-- Gaim::BuddyList::Group group
-+gaim2_blist_get_group_size(group, offline)
-+ Gaim2::BuddyList::Group group
- gboolean offline
-
- int
--gaim_blist_get_group_online_count(group)
-- Gaim::BuddyList::Group group
-+gaim2_blist_get_group_online_count(group)
-+ Gaim2::BuddyList::Group group
-
- void
--gaim_blist_load()
-+gaim2_blist_load()
-
- void
--gaim_blist_schedule_save()
-+gaim2_blist_schedule_save()
-
- void
--gaim_blist_request_add_group()
-+gaim2_blist_request_add_group()
-
- void
--gaim_blist_node_set_bool(node, key, value)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_set_bool(node, key, value)
-+ Gaim2::BuddyList::Node node
- const char * key
- gboolean value
-
- gboolean
--gaim_blist_node_get_bool(node, key)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_get_bool(node, key)
-+ Gaim2::BuddyList::Node node
- const char * key
-
- void
--gaim_blist_node_set_int(node, key, value)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_set_int(node, key, value)
-+ Gaim2::BuddyList::Node node
- const char * key
- int value
-
- int
--gaim_blist_node_get_int(node, key)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_get_int(node, key)
-+ Gaim2::BuddyList::Node node
- const char * key
-
- const char *
--gaim_blist_node_get_string(node, key)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_get_string(node, key)
-+ Gaim2::BuddyList::Node node
- const char * key
-
- void
--gaim_blist_node_remove_setting(node, key)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_remove_setting(node, key)
-+ Gaim2::BuddyList::Node node
- const char * key
-
- void
--gaim_blist_node_set_flags(node, flags)
-- Gaim::BuddyList::Node node
-- Gaim::BlistNodeFlags flags
-+gaim2_blist_node_set_flags(node, flags)
-+ Gaim2::BuddyList::Node node
-+ Gaim2::BlistNodeFlags flags
-
--Gaim::BlistNodeFlags
--gaim_blist_node_get_flags(node)
-- Gaim::BuddyList::Node node
-+Gaim2::BlistNodeFlags
-+gaim2_blist_node_get_flags(node)
-+ Gaim2::BuddyList::Node node
-
- void
--gaim_blist_node_get_extended_menu(node)
-- Gaim::BuddyList::Node node
-+gaim2_blist_node_get_extended_menu(node)
-+ Gaim2::BuddyList::Node node
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_blist_node_get_extended_menu(node); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_blist_node_get_extended_menu(node); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
-
- void
--gaim_blist_set_ui_ops(ops)
-- Gaim::BuddyList::UiOps ops
-+gaim2_blist_set_ui_ops(ops)
-+ Gaim2::BuddyList::UiOps ops
-
-
--Gaim::BuddyList::UiOps
--gaim_blist_get_ui_ops()
-+Gaim2::BuddyList::UiOps
-+gaim2_blist_get_ui_ops()
-
- void *
--gaim_blist_get_handle()
-+gaim2_blist_get_handle()
-
- void
--gaim_blist_init()
-+gaim2_blist_init()
-
- void
--gaim_blist_uninit()
-+gaim2_blist_uninit()
-
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::Chat PREFIX = gaim_chat_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::Chat PREFIX = gaim2_chat_
- PROTOTYPES: ENABLE
-
-
--Gaim::BuddyList::Group
--gaim_chat_get_group(chat)
-- Gaim::BuddyList::Chat chat
-+Gaim2::BuddyList::Group
-+gaim2_chat_get_group(chat)
-+ Gaim2::BuddyList::Chat chat
-
- const char *
--gaim_chat_get_name(chat)
-- Gaim::BuddyList::Chat chat
-+gaim2_chat_get_name(chat)
-+ Gaim2::BuddyList::Chat chat
-
--Gaim::BuddyList::Chat
--gaim_chat_new(account, alias, components)
-- Gaim::Account account
-+Gaim2::BuddyList::Chat
-+gaim2_chat_new(account, alias, components)
-+ Gaim2::Account account
- const char * alias
- SV * components
- INIT:
-@@ -327,7 +327,7 @@ CODE:
- g_hash_table_insert(t_GHash, t_key, t_value);
- }
-
-- RETVAL = gaim_chat_new(account, alias, t_GHash);
-+ RETVAL = gaim2_chat_new(account, alias, t_GHash);
- OUTPUT:
- RETVAL
-
-@@ -341,57 +341,57 @@ OUTPUT:
-
-
-
--MODULE = Gaim::BuddyList PACKAGE = Gaim::Buddy PREFIX = gaim_buddy_
-+MODULE = Gaim2::BuddyList PACKAGE = Gaim2::Buddy PREFIX = gaim2_buddy_
- PROTOTYPES: ENABLE
-
--Gaim::BuddyList::Buddy
--gaim_buddy_new(account, screenname, alias)
-- Gaim::Account account
-+Gaim2::BuddyList::Buddy
-+gaim2_buddy_new(account, screenname, alias)
-+ Gaim2::Account account
- const char *screenname
- const char *alias
-
- void
--gaim_buddy_set_icon(buddy, icon)
-- Gaim::BuddyList::Buddy buddy
-- Gaim::Buddy::Icon icon
--
--Gaim::Account
--gaim_buddy_get_account(buddy)
-- Gaim::BuddyList::Buddy buddy
--
--Gaim::BuddyList::Group
--gaim_buddy_get_group(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_set_icon(buddy, icon)
-+ Gaim2::BuddyList::Buddy buddy
-+ Gaim2::Buddy::Icon icon
-+
-+Gaim2::Account
-+gaim2_buddy_get_account(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-+
-+Gaim2::BuddyList::Group
-+gaim2_buddy_get_group(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- const char *
--gaim_buddy_get_name(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_get_name(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
--Gaim::Buddy::Icon
--gaim_buddy_get_icon(buddy)
-- Gaim::BuddyList::Buddy buddy
--
--Gaim::BuddyList::Contact
--gaim_buddy_get_contact(buddy)
-- Gaim::BuddyList::Buddy buddy
--
--Gaim::Presence
--gaim_buddy_get_presence(buddy)
-- Gaim::BuddyList::Buddy buddy
-+Gaim2::Buddy::Icon
-+gaim2_buddy_get_icon(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-+
-+Gaim2::BuddyList::Contact
-+gaim2_buddy_get_contact(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-+
-+Gaim2::Presence
-+gaim2_buddy_get_presence(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- const char *
--gaim_buddy_get_alias_only(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_get_alias_only(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- const char *
--gaim_buddy_get_contact_alias(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_get_contact_alias(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- const char *
--gaim_buddy_get_local_alias(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_get_local_alias(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
- const char *
--gaim_buddy_get_alias(buddy)
-- Gaim::BuddyList::Buddy buddy
-+gaim2_buddy_get_alias(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
-diff -prNu ./plugins/perl/common/Cipher.xs ./plugins/perl/common/Cipher.xs
---- ./plugins/perl/common/Cipher.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Cipher.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,18 +1,18 @@
- #include "module.h"
-
--MODULE = Gaim::Cipher PACKAGE = Gaim::Cipher PREFIX = gaim_cipher_
-+MODULE = Gaim2::Cipher PACKAGE = Gaim2::Cipher PREFIX = gaim2_cipher_
- PROTOTYPES: ENABLE
-
- const gchar *
--gaim_cipher_get_name(cipher)
-- Gaim::Cipher cipher
-+gaim2_cipher_get_name(cipher)
-+ Gaim2::Cipher cipher
-
- guint
--gaim_cipher_get_capabilities(cipher)
-- Gaim::Cipher cipher
-+gaim2_cipher_get_capabilities(cipher)
-+ Gaim2::Cipher cipher
-
- gboolean
--gaim_cipher_digest_region(name, data, data_len, in_len, digest, out_len)
-+gaim2_cipher_digest_region(name, data, data_len, in_len, digest, out_len)
- const gchar * name
- const guchar * data
- size_t data_len
-@@ -20,133 +20,133 @@ gaim_cipher_digest_region(name, data, da
- guchar &digest
- size_t * out_len
-
--Gaim::Cipher
--gaim_ciphers_find_cipher(name)
-+Gaim2::Cipher
-+gaim2_ciphers_find_cipher(name)
- gchar * name
-
--Gaim::Cipher
--gaim_ciphers_register_cipher(name, ops)
-+Gaim2::Cipher
-+gaim2_ciphers_register_cipher(name, ops)
- gchar * name
-- Gaim::Cipher::Ops ops
-+ Gaim2::Cipher::Ops ops
-
- gboolean
--gaim_ciphers_unregister_cipher(cipher)
-- Gaim::Cipher cipher
-+gaim2_ciphers_unregister_cipher(cipher)
-+ Gaim2::Cipher cipher
-
- void
--gaim_ciphers_get_ciphers()
-+gaim2_ciphers_get_ciphers()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_ciphers_get_ciphers(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::Cipher")));
-+ for (l = gaim2_ciphers_get_ciphers(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::Cipher")));
- }
-
- gpointer
--gaim_ciphers_get_handle()
-+gaim2_ciphers_get_handle()
-
- void
--gaim_ciphers_init()
-+gaim2_ciphers_init()
-
- void
--gaim_ciphers_uninit()
-+gaim2_ciphers_uninit()
-
- void
--gaim_cipher_context_set_option(context, name, value)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_set_option(context, name, value)
-+ Gaim2::Cipher::Context context
- gchar *name
- gpointer value
-
- gpointer
--gaim_cipher_context_get_option(context, name)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_get_option(context, name)
-+ Gaim2::Cipher::Context context
- gchar *name
-
--Gaim::Cipher::Context
--gaim_cipher_context_new(cipher, extra)
-- Gaim::Cipher cipher
-+Gaim2::Cipher::Context
-+gaim2_cipher_context_new(cipher, extra)
-+ Gaim2::Cipher cipher
- void *extra
-
--Gaim::Cipher::Context
--gaim_cipher_context_new_by_name(name, extra)
-+Gaim2::Cipher::Context
-+gaim2_cipher_context_new_by_name(name, extra)
- gchar *name
- void *extra
-
- void
--gaim_cipher_context_reset(context, extra)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_reset(context, extra)
-+ Gaim2::Cipher::Context context
- gpointer extra
-
- void
--gaim_cipher_context_destroy(context)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_destroy(context)
-+ Gaim2::Cipher::Context context
-
- void
--gaim_cipher_context_set_iv(context, iv, len)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_set_iv(context, iv, len)
-+ Gaim2::Cipher::Context context
- guchar * iv
- size_t len
-
- void
--gaim_cipher_context_append(context, data, len)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_append(context, data, len)
-+ Gaim2::Cipher::Context context
- guchar * data
- size_t len
-
- gboolean
--gaim_cipher_context_digest(context, in_len, digest, out_len)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_digest(context, in_len, digest, out_len)
-+ Gaim2::Cipher::Context context
- size_t in_len
- guchar &digest
- size_t &out_len
-
- gboolean
--gaim_cipher_context_digest_to_str(context, in_len, digest_s, out_len)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_digest_to_str(context, in_len, digest_s, out_len)
-+ Gaim2::Cipher::Context context
- size_t in_len
- gchar &digest_s
- size_t &out_len
-
- gint
--gaim_cipher_context_encrypt(context, data, len, output, outlen)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_encrypt(context, data, len, output, outlen)
-+ Gaim2::Cipher::Context context
- guchar &data
- size_t len
- guchar &output
- size_t &outlen
-
- gint
--gaim_cipher_context_decrypt(context, data, len, output, outlen)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_decrypt(context, data, len, output, outlen)
-+ Gaim2::Cipher::Context context
- guchar &data
- size_t len
- guchar &output
- size_t &outlen
-
- void
--gaim_cipher_context_set_salt(context, salt)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_set_salt(context, salt)
-+ Gaim2::Cipher::Context context
- guchar *salt
-
- size_t
--gaim_cipher_context_get_salt_size(context)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_get_salt_size(context)
-+ Gaim2::Cipher::Context context
-
- void
--gaim_cipher_context_set_key(context, key)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_set_key(context, key)
-+ Gaim2::Cipher::Context context
- guchar *key
-
- size_t
--gaim_cipher_context_get_key_size(context)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_get_key_size(context)
-+ Gaim2::Cipher::Context context
-
- void
--gaim_cipher_context_set_data(context, data)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_set_data(context, data)
-+ Gaim2::Cipher::Context context
- gpointer data
-
- gpointer
--gaim_cipher_context_get_data(context)
-- Gaim::Cipher::Context context
-+gaim2_cipher_context_get_data(context)
-+ Gaim2::Cipher::Context context
-
-diff -prNu ./plugins/perl/common/Cmds.xs ./plugins/perl/common/Cmds.xs
---- ./plugins/perl/common/Cmds.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Cmds.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,30 +1,30 @@
- #include "module.h"
-
--MODULE = Gaim::Cmds PACKAGE = Gaim::Cmds PREFIX = gaim_cmd_
-+MODULE = Gaim2::Cmds PACKAGE = Gaim2::Cmds PREFIX = gaim2_cmd_
- PROTOTYPES: ENABLE
-
- void
--gaim_cmd_help(conv, cmd)
-- Gaim::Conversation conv
-+gaim2_cmd_help(conv, cmd)
-+ Gaim2::Conversation conv
- const gchar *cmd
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_cmd_help(conv, cmd); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_cmd_help(conv, cmd); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_cmd_list(conv)
-- Gaim::Conversation conv
-+gaim2_cmd_list(conv)
-+ Gaim2::Conversation conv
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_cmd_list(conv); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_cmd_list(conv); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_cmd_unregister(id)
-- Gaim::CmdId id
-+gaim2_cmd_unregister(id)
-+ Gaim2::CmdId id
-
-diff -prNu ./plugins/perl/common/Connection.xs ./plugins/perl/common/Connection.xs
---- ./plugins/perl/common/Connection.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Connection.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,94 +1,94 @@
- #include "module.h"
-
--MODULE = Gaim::Connection PACKAGE = Gaim::GTK::Connection PREFIX = gaim_gtk_connections_
-+MODULE = Gaim2::Connection PACKAGE = Gaim2::GTK::Connection PREFIX = gaim2_gtk_connections_
- PROTOTYPES: ENABLE
-
--Gaim::Connection::UiOps
--gaim_gtk_connections_get_ui_ops()
-+Gaim2::Connection::UiOps
-+gaim2_gtk_connections_get_ui_ops()
-
--MODULE = Gaim::Connection PACKAGE = Gaim::Connection PREFIX = gaim_connections_
-+MODULE = Gaim2::Connection PACKAGE = Gaim2::Connection PREFIX = gaim2_connections_
- PROTOTYPES: ENABLE
-
--Gaim::Account
--gaim_connection_get_account(gc)
-- Gaim::Connection gc
-+Gaim2::Account
-+gaim2_connection_get_account(gc)
-+ Gaim2::Connection gc
-
- const char *
--gaim_connection_get_password(gc)
-- Gaim::Connection gc
-+gaim2_connection_get_password(gc)
-+ Gaim2::Connection gc
-
- const char *
--gaim_connection_get_display_name(gc)
-- Gaim::Connection gc
-+gaim2_connection_get_display_name(gc)
-+ Gaim2::Connection gc
-
- void
--gaim_connection_notice(gc, text)
-- Gaim::Connection gc
-+gaim2_connection_notice(gc, text)
-+ Gaim2::Connection gc
- const char *text
-
- void
--gaim_connection_error(gc, reason)
-- Gaim::Connection gc
-+gaim2_connection_error(gc, reason)
-+ Gaim2::Connection gc
- const char *reason
-
- void
--gaim_connections_disconnect_all()
-+gaim2_connections_disconnect_all()
-
- void
--gaim_connections_get_all()
-+gaim2_connections_get_all()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
-
- void
--gaim_connections_get_connecting()
-+gaim2_connections_get_connecting()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_connections_get_connecting(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_connections_get_connecting(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_connections_set_ui_ops(ops)
-- Gaim::Connection::UiOps ops
-+gaim2_connections_set_ui_ops(ops)
-+ Gaim2::Connection::UiOps ops
-
--Gaim::Connection::UiOps
--gaim_connections_get_ui_ops()
-+Gaim2::Connection::UiOps
-+gaim2_connections_get_ui_ops()
-
- void
--gaim_connections_init()
-+gaim2_connections_init()
-
- void
--gaim_connections_uninit()
-+gaim2_connections_uninit()
-
- void *
--gaim_connections_get_handle()
-+gaim2_connections_get_handle()
-
- void
--gaim_connection_destroy(gc)
-- Gaim::Connection gc
-+gaim2_connection_destroy(gc)
-+ Gaim2::Connection gc
-
- void
--gaim_connection_set_state(gc, state)
-- Gaim::Connection gc
-- Gaim::ConnectionState state
-+gaim2_connection_set_state(gc, state)
-+ Gaim2::Connection gc
-+ Gaim2::ConnectionState state
-
- void
--gaim_connection_set_account(gc, account)
-- Gaim::Connection gc
-- Gaim::Account account
-+gaim2_connection_set_account(gc, account)
-+ Gaim2::Connection gc
-+ Gaim2::Account account
-
- void
--gaim_connection_set_display_name(gc, name)
-- Gaim::Connection gc
-+gaim2_connection_set_display_name(gc, name)
-+ Gaim2::Connection gc
- const char *name
-
--Gaim::ConnectionState
--gaim_connection_get_state(gc)
-- Gaim::Connection gc
-+Gaim2::ConnectionState
-+gaim2_connection_get_state(gc)
-+ Gaim2::Connection gc
-
-diff -prNu ./plugins/perl/common/Conversation.xs ./plugins/perl/common/Conversation.xs
---- ./plugins/perl/common/Conversation.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/Conversation.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,24 +1,24 @@
- #include "module.h"
-
--MODULE = Gaim::Conversation PACKAGE = Gaim::Conversation PREFIX = gaim_conversation_
-+MODULE = Gaim2::Conversation PACKAGE = Gaim2::Conversation PREFIX = gaim2_conversation_
- PROTOTYPES: ENABLE
-
- void *
--gaim_conversations_get_handle()
-+gaim2_conversations_get_handle()
-
- void
--gaim_conversations_init()
-+gaim2_conversations_init()
-
- void
--gaim_conversations_uninit()
-+gaim2_conversations_uninit()
-
- void
- get_ims()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_get_ims(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_get_ims(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
-@@ -26,8 +26,8 @@ get_conversations()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_get_conversations(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
-@@ -35,200 +35,200 @@ get_chats()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_get_chats(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_get_chats(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_conversation_get_send_history(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_get_send_history(conv)
-+ Gaim2::Conversation conv
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_conversation_get_send_history(conv); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_conversation_get_send_history(conv); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_conversation_destroy(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_destroy(conv)
-+ Gaim2::Conversation conv
-
--Gaim::ConversationType
--gaim_conversation_get_type(conv)
-- Gaim::Conversation conv
-+Gaim2::ConversationType
-+gaim2_conversation_get_type(conv)
-+ Gaim2::Conversation conv
-
--Gaim::Account
--gaim_conversation_get_account(conv)
-- Gaim::Conversation conv
-+Gaim2::Account
-+gaim2_conversation_get_account(conv)
-+ Gaim2::Conversation conv
-
--Gaim::Connection
--gaim_conversation_get_gc(conv)
-- Gaim::Conversation conv
-+Gaim2::Connection
-+gaim2_conversation_get_gc(conv)
-+ Gaim2::Conversation conv
-
- void
--gaim_conversation_set_title(conv, title);
-- Gaim::Conversation conv
-+gaim2_conversation_set_title(conv, title);
-+ Gaim2::Conversation conv
- const char * title
-
- const char *
--gaim_conversation_get_title(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_get_title(conv)
-+ Gaim2::Conversation conv
-
- void
--gaim_conversation_autoset_title(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_autoset_title(conv)
-+ Gaim2::Conversation conv
-
- void
--gaim_conversation_set_name(conv, name)
-- Gaim::Conversation conv
-+gaim2_conversation_set_name(conv, name)
-+ Gaim2::Conversation conv
- const char *name
-
- const char *
--gaim_conversation_get_name(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_get_name(conv)
-+ Gaim2::Conversation conv
-
- void
--gaim_conversation_set_logging(conv, log)
-- Gaim::Conversation conv
-+gaim2_conversation_set_logging(conv, log)
-+ Gaim2::Conversation conv
- gboolean log
-
- gboolean
--gaim_conversation_is_logging(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_is_logging(conv)
-+ Gaim2::Conversation conv
-
-
--Gaim::Conversation::IM
--gaim_conversation_get_im_data(conv)
-- Gaim::Conversation conv
-+Gaim2::Conversation::IM
-+gaim2_conversation_get_im_data(conv)
-+ Gaim2::Conversation conv
-
--Gaim::Conversation::Chat
--gaim_conversation_get_chat_data(conv)
-- Gaim::Conversation conv
-+Gaim2::Conversation::Chat
-+gaim2_conversation_get_chat_data(conv)
-+ Gaim2::Conversation conv
-
- gpointer
--gaim_conversation_get_data(conv, key)
-- Gaim::Conversation conv
-+gaim2_conversation_get_data(conv, key)
-+ Gaim2::Conversation conv
- const char * key
-
--Gaim::ConnectionFlags
--gaim_conversation_get_features(conv)
-- Gaim::Conversation conv
-+Gaim2::ConnectionFlags
-+gaim2_conversation_get_features(conv)
-+ Gaim2::Conversation conv
-
- gboolean
--gaim_conversation_has_focus(conv)
-- Gaim::Conversation conv
-+gaim2_conversation_has_focus(conv)
-+ Gaim2::Conversation conv
-
- void
--gaim_conversation_update(conv, type)
-- Gaim::Conversation conv
-- Gaim::ConvUpdateType type
--
--Gaim::Conversation
--gaim_conversation_new(class, type, account, name)
-- Gaim::ConversationType type
-- Gaim::Account account
-+gaim2_conversation_update(conv, type)
-+ Gaim2::Conversation conv
-+ Gaim2::ConvUpdateType type
-+
-+Gaim2::Conversation
-+gaim2_conversation_new(class, type, account, name)
-+ Gaim2::ConversationType type
-+ Gaim2::Account account
- const char *name
- C_ARGS:
- type, account, name
-
- void
--gaim_conversation_set_account(conv, account);
-- Gaim::Conversation conv
-- Gaim::Account account
-+gaim2_conversation_set_account(conv, account);
-+ Gaim2::Conversation conv
-+ Gaim2::Account account
-
-
-
--MODULE = Gaim::Conversation PACKAGE = Gaim::Conversation::IM PREFIX = gaim_conv_im_
-+MODULE = Gaim2::Conversation PACKAGE = Gaim2::Conversation::IM PREFIX = gaim2_conv_im_
- PROTOTYPES: ENABLE
-
--Gaim::Conversation
--gaim_conv_im_get_conversation(im)
-- Gaim::Conversation::IM im
-+Gaim2::Conversation
-+gaim2_conv_im_get_conversation(im)
-+ Gaim2::Conversation::IM im
-
- void
--gaim_conv_im_set_icon(im, icon)
-- Gaim::Conversation::IM im
-- Gaim::Buddy::Icon icon
-+gaim2_conv_im_set_icon(im, icon)
-+ Gaim2::Conversation::IM im
-+ Gaim2::Buddy::Icon icon
-
--Gaim::Buddy::Icon
--gaim_conv_im_get_icon(im)
-- Gaim::Conversation::IM im
-+Gaim2::Buddy::Icon
-+gaim2_conv_im_get_icon(im)
-+ Gaim2::Conversation::IM im
-
- void
--gaim_conv_im_set_typing_state(im, state)
-- Gaim::Conversation::IM im
-- Gaim::TypingState state
-+gaim2_conv_im_set_typing_state(im, state)
-+ Gaim2::Conversation::IM im
-+ Gaim2::TypingState state
-
--Gaim::TypingState
--gaim_conv_im_get_typing_state(im)
-- Gaim::Conversation::IM im
-+Gaim2::TypingState
-+gaim2_conv_im_get_typing_state(im)
-+ Gaim2::Conversation::IM im
-
- void
--gaim_conv_im_start_typing_timeout(im, timeout)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_start_typing_timeout(im, timeout)
-+ Gaim2::Conversation::IM im
- int timeout
-
- void
--gaim_conv_im_stop_typing_timeout(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_stop_typing_timeout(im)
-+ Gaim2::Conversation::IM im
-
- guint
--gaim_conv_im_get_typing_timeout(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_get_typing_timeout(im)
-+ Gaim2::Conversation::IM im
-
- void
--gaim_conv_im_set_type_again(im, val)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_set_type_again(im, val)
-+ Gaim2::Conversation::IM im
- time_t val
-
- time_t
--gaim_conv_im_get_type_again(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_get_type_again(im)
-+ Gaim2::Conversation::IM im
-
- void
--gaim_conv_im_start_type_again_timeout(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_start_type_again_timeout(im)
-+ Gaim2::Conversation::IM im
-
- void
--gaim_conv_im_stop_type_again_timeout(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_stop_type_again_timeout(im)
-+ Gaim2::Conversation::IM im
-
- guint
--gaim_conv_im_get_type_again_timeout(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_get_type_again_timeout(im)
-+ Gaim2::Conversation::IM im
-
-
- void
--gaim_conv_im_update_typing(im)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_update_typing(im)
-+ Gaim2::Conversation::IM im
-
-
- void
--gaim_conv_im_send(im, message)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_send(im, message)
-+ Gaim2::Conversation::IM im
- const char *message
-
- void
--gaim_conv_im_write(im, who, message, flags, mtime)
-- Gaim::Conversation::IM im
-+gaim2_conv_im_write(im, who, message, flags, mtime)
-+ Gaim2::Conversation::IM im
- const char *who
- const char *message
-- Gaim::MessageFlags flags
-+ Gaim2::MessageFlags flags
- time_t mtime
-
-
--MODULE = Gaim::Conversation PACKAGE = Gaim::Conversation PREFIX = gaim_conv_
-+MODULE = Gaim2::Conversation PACKAGE = Gaim2::Conversation PREFIX = gaim2_conv_
- PROTOTYPES: ENABLE
-
- gboolean
--gaim_conv_present_error(who, account, what)
-+gaim2_conv_present_error(who, account, what)
- const char *who
-- Gaim::Account account
-+ Gaim2::Account account
- const char *what
-
- void
--gaim_conv_custom_smiley_close(conv, smile)
-- Gaim::Conversation conv
-+gaim2_conv_custom_smiley_close(conv, smile)
-+ Gaim2::Conversation conv
- const char *smile
-
-
-@@ -236,16 +236,16 @@ gaim_conv_custom_smiley_close(conv, smil
-
-
-
--MODULE = Gaim::Conversation PACKAGE = Gaim::Conversation::Chat PREFIX = gaim_conv_chat_
-+MODULE = Gaim2::Conversation PACKAGE = Gaim2::Conversation::Chat PREFIX = gaim2_conv_chat_
- PROTOTYPES: ENABLE
-
--Gaim::Conversation
--gaim_conv_chat_get_conversation(chat)
-- Gaim::Conversation::Chat chat
-+Gaim2::Conversation
-+gaim2_conv_chat_get_conversation(chat)
-+ Gaim2::Conversation::Chat chat
-
- void
--gaim_conv_chat_set_users(chat, users)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_set_users(chat, users)
-+ Gaim2::Conversation::Chat chat
- SV * users
- PREINIT:
- GList *l, *t_GL;
-@@ -259,33 +259,33 @@ PPCODE:
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(users), i, 0), t_sl));
- }
-
-- for (l = gaim_conv_chat_set_users(chat, t_GL); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_conv_chat_set_users(chat, t_GL); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_conv_chat_get_users(chat)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_get_users(chat)
-+ Gaim2::Conversation::Chat chat
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_conv_chat_get_users(chat); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_conv_chat_get_users(chat); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_conv_chat_ignore(chat, name)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_ignore(chat, name)
-+ Gaim2::Conversation::Chat chat
- const char *name
-
- void
--gaim_conv_chat_unignore(chat, name)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_unignore(chat, name)
-+ Gaim2::Conversation::Chat chat
- const char *name
-
- void
--gaim_conv_chat_set_ignored(chat, ignored)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_set_ignored(chat, ignored)
-+ Gaim2::Conversation::Chat chat
- SV * ignored
- PREINIT:
- GList *l, *t_GL;
-@@ -299,43 +299,43 @@ PPCODE:
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(ignored), i, 0), t_sl));
- }
-
-- for (l = gaim_conv_chat_set_ignored(chat, t_GL); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_conv_chat_set_ignored(chat, t_GL); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- void
--gaim_conv_chat_get_ignored(chat)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_get_ignored(chat)
-+ Gaim2::Conversation::Chat chat
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_conv_chat_get_ignored(chat); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_conv_chat_get_ignored(chat); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- const char *
--gaim_conv_chat_get_topic(chat)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_get_topic(chat)
-+ Gaim2::Conversation::Chat chat
-
-
-
- void
--gaim_conv_chat_set_id(chat, id)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_set_id(chat, id)
-+ Gaim2::Conversation::Chat chat
- int id
-
- int
--gaim_conv_chat_get_id(chat)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_get_id(chat)
-+ Gaim2::Conversation::Chat chat
-
- void
--gaim_conv_chat_send(chat, message)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_send(chat, message)
-+ Gaim2::Conversation::Chat chat
- const char * message
-
- void
--gaim_conv_chat_add_users(chat, users, extra_msgs, flags, new_arrivals)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_add_users(chat, users, extra_msgs, flags, new_arrivals)
-+ Gaim2::Conversation::Chat chat
- SV * users
- SV * extra_msgs
- SV * flags
-@@ -368,45 +368,45 @@ PPCODE:
- t_GL_extra_msgs = g_list_append(t_GL_extra_msgs, SvPV(*av_fetch((AV *)SvRV(extra_msgs), i, 0), t_sl));
- }
-
-- gaim_conv_chat_add_users(chat, t_GL_users, t_GL_extra_msgs, t_GL_flags, new_arrivals);
-+ gaim2_conv_chat_add_users(chat, t_GL_users, t_GL_extra_msgs, t_GL_flags, new_arrivals);
-
-
- gboolean
--gaim_conv_chat_find_user(chat, user)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_find_user(chat, user)
-+ Gaim2::Conversation::Chat chat
- const char * user
-
--void gaim_conv_chat_clear_users(chat)
-- Gaim::Conversation::Chat chat
-+void gaim2_conv_chat_clear_users(chat)
-+ Gaim2::Conversation::Chat chat
-
--void gaim_conv_chat_set_nick(chat, nick)
-- Gaim::Conversation::Chat chat
-+void gaim2_conv_chat_set_nick(chat, nick)
-+ Gaim2::Conversation::Chat chat
- const char * nick
-
- const char *
--gaim_conv_chat_get_nick(chat)
-- Gaim::Conversation::Chat chat
-+gaim2_conv_chat_get_nick(chat)
-+ Gaim2::Conversation::Chat chat
-
--Gaim::Conversation
--gaim_find_chat(gc, id)
-- Gaim::Connection gc
-+Gaim2::Conversation
-+gaim2_find_chat(gc, id)
-+ Gaim2::Connection gc
- int id
-
--void gaim_conv_chat_left(chat)
-- Gaim::Conversation::Chat chat
-+void gaim2_conv_chat_left(chat)
-+ Gaim2::Conversation::Chat chat
-
--gboolean gaim_conv_chat_has_left(chat)
-- Gaim::Conversation::Chat chat
-+gboolean gaim2_conv_chat_has_left(chat)
-+ Gaim2::Conversation::Chat chat
-
--Gaim::Conversation::ChatBuddy
--gaim_conv_chat_cb_find(chat, name)
-- Gaim::Conversation::Chat chat
-+Gaim2::Conversation::ChatBuddy
-+gaim2_conv_chat_cb_find(chat, name)
-+ Gaim2::Conversation::Chat chat
- const char *name
-
- const char *
--gaim_conv_chat_cb_get_name(cb)
-- Gaim::Conversation::ChatBuddy cb
-+gaim2_conv_chat_cb_get_name(cb)
-+ Gaim2::Conversation::ChatBuddy cb
-
- void
--gaim_conv_chat_cb_destroy(cb);
-- Gaim::Conversation::ChatBuddy cb
-+gaim2_conv_chat_cb_destroy(cb);
-+ Gaim2::Conversation::ChatBuddy cb
-diff -prNu ./plugins/perl/common/FT.xs ./plugins/perl/common/FT.xs
---- ./plugins/perl/common/FT.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/FT.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,168 +1,168 @@
- #include "module.h"
-
--MODULE = Gaim::Xfer PACKAGE = Gaim::Xfer PREFIX = gaim_xfer_
-+MODULE = Gaim2::Xfer PACKAGE = Gaim2::Xfer PREFIX = gaim2_xfer_
- PROTOTYPES: ENABLE
-
--Gaim::Xfer
--gaim_xfer_new(class, account, type, who)
-- Gaim::Account account
-- Gaim::XferType type
-+Gaim2::Xfer
-+gaim2_xfer_new(class, account, type, who)
-+ Gaim2::Account account
-+ Gaim2::XferType type
- const char *who
- C_ARGS:
- account, type, who
-
- void
--gaim_xfer_add(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_add(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_cancel_local(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_cancel_local(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_cancel_remote(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_cancel_remote(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_end(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_end(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_error(type, account, who, msg)
-- Gaim::XferType type
-- Gaim::Account account
-+gaim2_xfer_error(type, account, who, msg)
-+ Gaim2::XferType type
-+ Gaim2::Account account
- const char *who
- const char *msg
-
--Gaim::Account
--gaim_xfer_get_account(xfer)
-- Gaim::Xfer xfer
-+Gaim2::Account
-+gaim2_xfer_get_account(xfer)
-+ Gaim2::Xfer xfer
-
- size_t
--gaim_xfer_get_bytes_remaining(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_bytes_remaining(xfer)
-+ Gaim2::Xfer xfer
-
- size_t
--gaim_xfer_get_bytes_sent(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_bytes_sent(xfer)
-+ Gaim2::Xfer xfer
-
- const char *
--gaim_xfer_get_filename(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_filename(xfer)
-+ Gaim2::Xfer xfer
-
- const char *
--gaim_xfer_get_local_filename(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_local_filename(xfer)
-+ Gaim2::Xfer xfer
-
- unsigned int
--gaim_xfer_get_local_port(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_local_port(xfer)
-+ Gaim2::Xfer xfer
-
- double
--gaim_xfer_get_progress(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_progress(xfer)
-+ Gaim2::Xfer xfer
-
- const char *
--gaim_xfer_get_remote_ip(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_remote_ip(xfer)
-+ Gaim2::Xfer xfer
-
- unsigned int
--gaim_xfer_get_remote_port(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_remote_port(xfer)
-+ Gaim2::Xfer xfer
-
- size_t
--gaim_xfer_get_size(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_get_size(xfer)
-+ Gaim2::Xfer xfer
-
--Gaim::XferStatusType
--gaim_xfer_get_status(xfer)
-- Gaim::Xfer xfer
--
--Gaim::XferType
--gaim_xfer_get_type(xfer)
-- Gaim::Xfer xfer
--
--Gaim::XferUiOps
--gaim_xfer_get_ui_ops(xfer)
-- Gaim::Xfer xfer
-+Gaim2::XferStatusType
-+gaim2_xfer_get_status(xfer)
-+ Gaim2::Xfer xfer
-+
-+Gaim2::XferType
-+gaim2_xfer_get_type(xfer)
-+ Gaim2::Xfer xfer
-+
-+Gaim2::XferUiOps
-+gaim2_xfer_get_ui_ops(xfer)
-+ Gaim2::Xfer xfer
-
- gboolean
--gaim_xfer_is_canceled(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_is_canceled(xfer)
-+ Gaim2::Xfer xfer
-
- gboolean
--gaim_xfer_is_completed(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_is_completed(xfer)
-+ Gaim2::Xfer xfer
-
- ssize_t
--gaim_xfer_read(xfer, buffer)
-- Gaim::Xfer xfer
-+gaim2_xfer_read(xfer, buffer)
-+ Gaim2::Xfer xfer
- guchar **buffer
-
- void
--gaim_xfer_ref(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_ref(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_request(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_request(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_request_accepted(xfer, filename)
-- Gaim::Xfer xfer
-+gaim2_xfer_request_accepted(xfer, filename)
-+ Gaim2::Xfer xfer
- const char *filename
-
- void
--gaim_xfer_request_denied(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_request_denied(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_set_completed(xfer, completed)
-- Gaim::Xfer xfer
-+gaim2_xfer_set_completed(xfer, completed)
-+ Gaim2::Xfer xfer
- gboolean completed
-
- void
--gaim_xfer_set_filename(xfer, filename)
-- Gaim::Xfer xfer
-+gaim2_xfer_set_filename(xfer, filename)
-+ Gaim2::Xfer xfer
- const char *filename
-
- void
--gaim_xfer_set_local_filename(xfer, filename)
-- Gaim::Xfer xfer
-+gaim2_xfer_set_local_filename(xfer, filename)
-+ Gaim2::Xfer xfer
- const char *filename
-
- void
--gaim_xfer_set_message(xfer, message)
-- Gaim::Xfer xfer
-+gaim2_xfer_set_message(xfer, message)
-+ Gaim2::Xfer xfer
- const char *message
-
- void
--gaim_xfer_set_size(xfer, size)
-- Gaim::Xfer xfer
-+gaim2_xfer_set_size(xfer, size)
-+ Gaim2::Xfer xfer
- size_t size
-
- void
--gaim_xfer_unref(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_unref(xfer)
-+ Gaim2::Xfer xfer
-
- void
--gaim_xfer_update_progress(xfer)
-- Gaim::Xfer xfer
-+gaim2_xfer_update_progress(xfer)
-+ Gaim2::Xfer xfer
-
- ssize_t
--gaim_xfer_write(xfer, buffer, size)
-- Gaim::Xfer xfer
-+gaim2_xfer_write(xfer, buffer, size)
-+ Gaim2::Xfer xfer
- const guchar *buffer
- size_t size
-
--MODULE = Gaim::Xfer PACKAGE = Gaim::Xfers PREFIX = gaim_xfers_
-+MODULE = Gaim2::Xfer PACKAGE = Gaim2::Xfers PREFIX = gaim2_xfers_
- PROTOTYPES: ENABLE
-
--Gaim::XferUiOps
--gaim_xfers_get_ui_ops()
-+Gaim2::XferUiOps
-+gaim2_xfers_get_ui_ops()
-
-
- void
--gaim_xfers_set_ui_ops(ops)
-- Gaim::XferUiOps ops
-+gaim2_xfers_set_ui_ops(ops)
-+ Gaim2::XferUiOps ops
-
-diff -prNu ./plugins/perl/common/Gaim2.pm ./plugins/perl/common/Gaim2.pm
---- ./plugins/perl/common/Gaim2.pm 1970-01-01 01:00:00.000000000 +0100
-+++ ./plugins/perl/common/Gaim2.pm 2006-01-05 14:48:17.000000000 +0100
-@@ -0,0 +1,131 @@
-+package Gaim2;
-+
-+use 5.008;
-+use strict;
-+use warnings;
-+use Carp;
-+
-+require Exporter;
-+use AutoLoader;
-+
-+our @ISA = qw(Exporter);
-+
-+# Items to export into callers namespace by default. Note: do not export
-+# names by default without a very good reason. Use EXPORT_OK instead.
-+# Do not simply export all your public functions/methods/constants.
-+
-+# This allows declaration use Gaim2 ':all';
-+# If you do not need this, moving things directly into @EXPORT or @EXPORT_OK
-+# will save memory.
-+our %EXPORT_TAGS = ( 'all' => [ qw(
-+
-+) ] );
-+
-+our @EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } );
-+
-+our @EXPORT = qw(
-+
-+);
-+
-+our $VERSION = '0.01';
-+
-+sub AUTOLOAD {
-+ # This AUTOLOAD is used to 'autoload' constants from the constant()
-+ # XS function.
-+
-+ my $constname;
-+ our $AUTOLOAD;
-+ ($constname = $AUTOLOAD) =~ s/.*:://;
-+ croak "&Gaim2::constant not defined" if $constname eq 'constant';
-+ my ($error, $val) = constant($constname);
-+ if ($error) { croak $error; }
-+ {
-+ no strict 'refs';
-+
-+ *$AUTOLOAD = sub { $val };
-+ }
-+
-+ goto &$AUTOLOAD;
-+}
-+
-+require XSLoader;
-+XSLoader::load('Gaim2', $VERSION);
-+
-+# Preloaded methods go here.
-+
-+1;
-+__END__
-+
-+=head1 NAME
-+
-+Gaim2 - Perl extension the Gaim instant messenger.
-+
-+=head1 SYNOPSIS
-+
-+ use Gaim2;
-+
-+=head1 ABSTRACT
-+
-+ This module provides the interface for using perl scripts as plugins
-+ in Gaim2.
-+
-+=head1 DESCRIPTION
-+
-+This module provides the interface for using perl scripts as plugins
-+in Gaim. With this, developers can write perl scripts that can be
-+loaded in Gaim as plugins. The scripts can interact with IMs, chats,
-+accounts, the buddy list, gaim signals, and more.
-+
-+The API for the perl interface is very similar to that of the Gaim C
-+API, which can be viewed at http://gaim.sourceforge.net/api/ or in
-+the header files in the Gaim source tree.
-+
-+=head1 FUNCTIONS
-+
-+=over
-+
-+=item @accounts = Gaim2::accounts
-+
-+Returns a list of all accounts, online or offline.
-+
-+=item @chats = Gaim2::chats
-+
-+Returns a list of all chats currently open.
-+
-+=item @connections = Gaim2::connections
-+
-+Returns a list of all active connections.
-+
-+=item @conversations = Gaim2::conversations
-+
-+Returns a list of all conversations, both IM and chat, currently open.
-+
-+=item @conv_windows = Gaim2::conv_windows
-+
-+Returns a list of all conversation windows currently open.
-+
-+=item @ims = Gaim2::ims
-+
-+Returns a list of all instant messages currently open.
-+
-+=back
-+
-+=head1 SEE ALSO
-+
-+Gaim C API documentation - http//gaim.sourceforge.net/api/
-+
-+Gaim website - http://gaim.sourceforge.net/
-+
-+=head1 AUTHOR
-+
-+Christian Hammond, E<lt>chipx86@gnupdate.orgE<gt>
-+
-+=head1 COPYRIGHT AND LICENSE
-+
-+Copyright 2003 by Christian Hammond
-+
-+This library is free software; you can redistribute it and/or modify
-+it under the terms of the General Public License (GPL). For
-+more information, see http://www.fsf.org/licenses/gpl.txt
-+
-+=cut
-diff -prNu ./plugins/perl/common/Gaim2.xs ./plugins/perl/common/Gaim2.xs
---- ./plugins/perl/common/Gaim2.xs 1970-01-01 01:00:00.000000000 +0100
-+++ ./plugins/perl/common/Gaim2.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -0,0 +1,146 @@
-+#include "module.h"
-+#include "../perl-handlers.h"
-+#include "const-c.inc"
-+
-+/* Prototypes for the BOOT section below. */
-+GAIM_PERL_BOOT_PROTO(Account);
-+GAIM_PERL_BOOT_PROTO(Account__Option);
-+GAIM_PERL_BOOT_PROTO(Buddy__Icon);
-+GAIM_PERL_BOOT_PROTO(BuddyList);
-+GAIM_PERL_BOOT_PROTO(Cipher);
-+GAIM_PERL_BOOT_PROTO(Cmds);
-+GAIM_PERL_BOOT_PROTO(Connection);
-+GAIM_PERL_BOOT_PROTO(Conversation);
-+GAIM_PERL_BOOT_PROTO(Xfer);
-+GAIM_PERL_BOOT_PROTO(ImgStore);
-+GAIM_PERL_BOOT_PROTO(Log);
-+GAIM_PERL_BOOT_PROTO(Network);
-+GAIM_PERL_BOOT_PROTO(Notify);
-+GAIM_PERL_BOOT_PROTO(Plugin);
-+GAIM_PERL_BOOT_PROTO(PluginPref);
-+GAIM_PERL_BOOT_PROTO(Pounce);
-+GAIM_PERL_BOOT_PROTO(Prefs);
-+GAIM_PERL_BOOT_PROTO(Privacy);
-+GAIM_PERL_BOOT_PROTO(Proxy);
-+GAIM_PERL_BOOT_PROTO(Prpl);
-+GAIM_PERL_BOOT_PROTO(Request);
-+GAIM_PERL_BOOT_PROTO(Roomlist);
-+GAIM_PERL_BOOT_PROTO(SSL);
-+GAIM_PERL_BOOT_PROTO(SavedStatus);
-+GAIM_PERL_BOOT_PROTO(Sound);
-+GAIM_PERL_BOOT_PROTO(Status);
-+GAIM_PERL_BOOT_PROTO(Stringref);
-+GAIM_PERL_BOOT_PROTO(Util);
-+GAIM_PERL_BOOT_PROTO(XMLNode);
-+
-+
-+MODULE = Gaim2 PACKAGE = Gaim2 PREFIX = gaim2_
-+PROTOTYPES: ENABLE
-+
-+INCLUDE: const-xs.inc
-+
-+BOOT:
-+ GAIM_PERL_BOOT(Account);
-+ GAIM_PERL_BOOT(Account__Option);
-+ GAIM_PERL_BOOT(Buddy__Icon);
-+ GAIM_PERL_BOOT(BuddyList);
-+ GAIM_PERL_BOOT(Cipher);
-+ GAIM_PERL_BOOT(Cmds);
-+ GAIM_PERL_BOOT(Connection);
-+ GAIM_PERL_BOOT(Conversation);
-+ GAIM_PERL_BOOT(Xfer);
-+ GAIM_PERL_BOOT(ImgStore);
-+ GAIM_PERL_BOOT(Log);
-+ GAIM_PERL_BOOT(Network);
-+ GAIM_PERL_BOOT(Notify);
-+ GAIM_PERL_BOOT(Plugin);
-+ GAIM_PERL_BOOT(PluginPref);
-+ GAIM_PERL_BOOT(Pounce);
-+ GAIM_PERL_BOOT(Prefs);
-+ GAIM_PERL_BOOT(Privacy);
-+ GAIM_PERL_BOOT(Proxy);
-+ GAIM_PERL_BOOT(Prpl);
-+ GAIM_PERL_BOOT(Request);
-+ GAIM_PERL_BOOT(Roomlist);
-+ GAIM_PERL_BOOT(SSL);
-+ GAIM_PERL_BOOT(SavedStatus);
-+ GAIM_PERL_BOOT(Sound);
-+ GAIM_PERL_BOOT(Status);
-+ GAIM_PERL_BOOT(Stringref);
-+ GAIM_PERL_BOOT(Util);
-+ GAIM_PERL_BOOT(XMLNode);
-+
-+
-+void
-+timeout_add(plugin, seconds, callback, data = 0)
-+ Gaim2::Plugin plugin
-+ int seconds
-+ SV *callback
-+ SV *data
-+CODE:
-+ gaim2_perl_timeout_add(plugin, seconds, callback, data);
-+
-+void
-+signal_connect(instance, signal, plugin, callback, data = 0)
-+ void *instance
-+ const char *signal
-+ Gaim2::Plugin plugin
-+ SV *callback
-+ SV *data
-+CODE:
-+ gaim2_perl_signal_connect(plugin, instance, signal, callback, data);
-+
-+void
-+signal_disconnect(instance, signal, plugin)
-+ void *instance
-+ const char *signal
-+ Gaim2::Plugin plugin
-+CODE:
-+ gaim2_perl_signal_disconnect(plugin, instance, signal);
-+
-+void
-+gaim2_debug(level, category, string)
-+ Gaim2::DebugLevel level
-+ const char *category
-+ const char *string
-+
-+void
-+debug_misc(category, string)
-+ const char *category
-+ const char *string
-+CODE:
-+ gaim2_debug(GAIM_DEBUG_MISC, category, string);
-+
-+void
-+debug_info(category, string)
-+ const char *category
-+ const char *string
-+CODE:
-+ gaim2_debug(GAIM_DEBUG_INFO, category, string);
-+
-+void
-+debug_warning(category, string)
-+ const char *category
-+ const char *string
-+CODE:
-+ gaim2_debug(GAIM_DEBUG_WARNING, category, string);
-+
-+void
-+debug_error(category, string)
-+ const char *category
-+ const char *string
-+CODE:
-+ gaim2_debug(GAIM_DEBUG_ERROR, category, string);
-+
-+void
-+debug_fatal(category, string)
-+ const char *category
-+ const char *string
-+CODE:
-+ gaim2_debug(GAIM_DEBUG_FATAL, category, string);
-+
-+void
-+deinit()
-+CODE:
-+ gaim2_perl_timeout_clear();
-+
-diff -prNu ./plugins/perl/common/Gaim.pm ./plugins/perl/common/Gaim.pm
---- ./plugins/perl/common/Gaim.pm 2003-08-25 00:00:05.000000000 +0200
-+++ ./plugins/perl/common/Gaim.pm 1970-01-01 01:00:00.000000000 +0100
-@@ -1,131 +0,0 @@
--package Gaim;
--
--use 5.008;
--use strict;
--use warnings;
--use Carp;
--
--require Exporter;
--use AutoLoader;
--
--our @ISA = qw(Exporter);
--
--# Items to export into callers namespace by default. Note: do not export
--# names by default without a very good reason. Use EXPORT_OK instead.
--# Do not simply export all your public functions/methods/constants.
--
--# This allows declaration use Gaim ':all';
--# If you do not need this, moving things directly into @EXPORT or @EXPORT_OK
--# will save memory.
--our %EXPORT_TAGS = ( 'all' => [ qw(
--
--) ] );
--
--our @EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } );
--
--our @EXPORT = qw(
--
--);
--
--our $VERSION = '0.01';
--
--sub AUTOLOAD {
-- # This AUTOLOAD is used to 'autoload' constants from the constant()
-- # XS function.
--
-- my $constname;
-- our $AUTOLOAD;
-- ($constname = $AUTOLOAD) =~ s/.*:://;
-- croak "&Gaim::constant not defined" if $constname eq 'constant';
-- my ($error, $val) = constant($constname);
-- if ($error) { croak $error; }
-- {
-- no strict 'refs';
--
-- *$AUTOLOAD = sub { $val };
-- }
--
-- goto &$AUTOLOAD;
--}
--
--require XSLoader;
--XSLoader::load('Gaim', $VERSION);
--
--# Preloaded methods go here.
--
--1;
--__END__
--
--=head1 NAME
--
--Gaim - Perl extension the Gaim instant messenger.
--
--=head1 SYNOPSIS
--
-- use Gaim;
--
--=head1 ABSTRACT
--
-- This module provides the interface for using perl scripts as plugins
-- in Gaim.
--
--=head1 DESCRIPTION
--
--This module provides the interface for using perl scripts as plugins
--in Gaim. With this, developers can write perl scripts that can be
--loaded in Gaim as plugins. The scripts can interact with IMs, chats,
--accounts, the buddy list, gaim signals, and more.
--
--The API for the perl interface is very similar to that of the Gaim C
--API, which can be viewed at http://gaim.sourceforge.net/api/ or in
--the header files in the Gaim source tree.
--
--=head1 FUNCTIONS
--
--=over
--
--=item @accounts = Gaim::accounts
--
--Returns a list of all accounts, online or offline.
--
--=item @chats = Gaim::chats
--
--Returns a list of all chats currently open.
--
--=item @connections = Gaim::connections
--
--Returns a list of all active connections.
--
--=item @conversations = Gaim::conversations
--
--Returns a list of all conversations, both IM and chat, currently open.
--
--=item @conv_windows = Gaim::conv_windows
--
--Returns a list of all conversation windows currently open.
--
--=item @ims = Gaim::ims
--
--Returns a list of all instant messages currently open.
--
--=back
--
--=head1 SEE ALSO
--
--Gaim C API documentation - http//gaim.sourceforge.net/api/
--
--Gaim website - http://gaim.sourceforge.net/
--
--=head1 AUTHOR
--
--Christian Hammond, E<lt>chipx86@gnupdate.orgE<gt>
--
--=head1 COPYRIGHT AND LICENSE
--
--Copyright 2003 by Christian Hammond
--
--This library is free software; you can redistribute it and/or modify
--it under the terms of the General Public License (GPL). For
--more information, see http://www.fsf.org/licenses/gpl.txt
--
--=cut
-diff -prNu ./plugins/perl/common/Gaim.xs ./plugins/perl/common/Gaim.xs
---- ./plugins/perl/common/Gaim.xs 2005-12-08 22:08:15.000000000 +0100
-+++ ./plugins/perl/common/Gaim.xs 1970-01-01 01:00:00.000000000 +0100
-@@ -1,146 +0,0 @@
--#include "module.h"
--#include "../perl-handlers.h"
--#include "const-c.inc"
--
--/* Prototypes for the BOOT section below. */
--GAIM_PERL_BOOT_PROTO(Account);
--GAIM_PERL_BOOT_PROTO(Account__Option);
--GAIM_PERL_BOOT_PROTO(Buddy__Icon);
--GAIM_PERL_BOOT_PROTO(BuddyList);
--GAIM_PERL_BOOT_PROTO(Cipher);
--GAIM_PERL_BOOT_PROTO(Cmds);
--GAIM_PERL_BOOT_PROTO(Connection);
--GAIM_PERL_BOOT_PROTO(Conversation);
--GAIM_PERL_BOOT_PROTO(Xfer);
--GAIM_PERL_BOOT_PROTO(ImgStore);
--GAIM_PERL_BOOT_PROTO(Log);
--GAIM_PERL_BOOT_PROTO(Network);
--GAIM_PERL_BOOT_PROTO(Notify);
--GAIM_PERL_BOOT_PROTO(Plugin);
--GAIM_PERL_BOOT_PROTO(PluginPref);
--GAIM_PERL_BOOT_PROTO(Pounce);
--GAIM_PERL_BOOT_PROTO(Prefs);
--GAIM_PERL_BOOT_PROTO(Privacy);
--GAIM_PERL_BOOT_PROTO(Proxy);
--GAIM_PERL_BOOT_PROTO(Prpl);
--GAIM_PERL_BOOT_PROTO(Request);
--GAIM_PERL_BOOT_PROTO(Roomlist);
--GAIM_PERL_BOOT_PROTO(SSL);
--GAIM_PERL_BOOT_PROTO(SavedStatus);
--GAIM_PERL_BOOT_PROTO(Sound);
--GAIM_PERL_BOOT_PROTO(Status);
--GAIM_PERL_BOOT_PROTO(Stringref);
--GAIM_PERL_BOOT_PROTO(Util);
--GAIM_PERL_BOOT_PROTO(XMLNode);
--
--
--MODULE = Gaim PACKAGE = Gaim PREFIX = gaim_
--PROTOTYPES: ENABLE
--
--INCLUDE: const-xs.inc
--
--BOOT:
-- GAIM_PERL_BOOT(Account);
-- GAIM_PERL_BOOT(Account__Option);
-- GAIM_PERL_BOOT(Buddy__Icon);
-- GAIM_PERL_BOOT(BuddyList);
-- GAIM_PERL_BOOT(Cipher);
-- GAIM_PERL_BOOT(Cmds);
-- GAIM_PERL_BOOT(Connection);
-- GAIM_PERL_BOOT(Conversation);
-- GAIM_PERL_BOOT(Xfer);
-- GAIM_PERL_BOOT(ImgStore);
-- GAIM_PERL_BOOT(Log);
-- GAIM_PERL_BOOT(Network);
-- GAIM_PERL_BOOT(Notify);
-- GAIM_PERL_BOOT(Plugin);
-- GAIM_PERL_BOOT(PluginPref);
-- GAIM_PERL_BOOT(Pounce);
-- GAIM_PERL_BOOT(Prefs);
-- GAIM_PERL_BOOT(Privacy);
-- GAIM_PERL_BOOT(Proxy);
-- GAIM_PERL_BOOT(Prpl);
-- GAIM_PERL_BOOT(Request);
-- GAIM_PERL_BOOT(Roomlist);
-- GAIM_PERL_BOOT(SSL);
-- GAIM_PERL_BOOT(SavedStatus);
-- GAIM_PERL_BOOT(Sound);
-- GAIM_PERL_BOOT(Status);
-- GAIM_PERL_BOOT(Stringref);
-- GAIM_PERL_BOOT(Util);
-- GAIM_PERL_BOOT(XMLNode);
--
--
--void
--timeout_add(plugin, seconds, callback, data = 0)
-- Gaim::Plugin plugin
-- int seconds
-- SV *callback
-- SV *data
--CODE:
-- gaim_perl_timeout_add(plugin, seconds, callback, data);
--
--void
--signal_connect(instance, signal, plugin, callback, data = 0)
-- void *instance
-- const char *signal
-- Gaim::Plugin plugin
-- SV *callback
-- SV *data
--CODE:
-- gaim_perl_signal_connect(plugin, instance, signal, callback, data);
--
--void
--signal_disconnect(instance, signal, plugin)
-- void *instance
-- const char *signal
-- Gaim::Plugin plugin
--CODE:
-- gaim_perl_signal_disconnect(plugin, instance, signal);
--
--void
--gaim_debug(level, category, string)
-- Gaim::DebugLevel level
-- const char *category
-- const char *string
--
--void
--debug_misc(category, string)
-- const char *category
-- const char *string
--CODE:
-- gaim_debug(GAIM_DEBUG_MISC, category, string);
--
--void
--debug_info(category, string)
-- const char *category
-- const char *string
--CODE:
-- gaim_debug(GAIM_DEBUG_INFO, category, string);
--
--void
--debug_warning(category, string)
-- const char *category
-- const char *string
--CODE:
-- gaim_debug(GAIM_DEBUG_WARNING, category, string);
--
--void
--debug_error(category, string)
-- const char *category
-- const char *string
--CODE:
-- gaim_debug(GAIM_DEBUG_ERROR, category, string);
--
--void
--debug_fatal(category, string)
-- const char *category
-- const char *string
--CODE:
-- gaim_debug(GAIM_DEBUG_FATAL, category, string);
--
--void
--deinit()
--CODE:
-- gaim_perl_timeout_clear();
--
-diff -prNu ./plugins/perl/common/ImgStore.xs ./plugins/perl/common/ImgStore.xs
---- ./plugins/perl/common/ImgStore.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/ImgStore.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,35 +1,35 @@
- #include "module.h"
-
--MODULE = Gaim::ImgStore PACKAGE = Gaim::ImgStore PREFIX = gaim_imgstore_
-+MODULE = Gaim2::ImgStore PACKAGE = Gaim2::ImgStore PREFIX = gaim2_imgstore_
- PROTOTYPES: ENABLE
-
- int
--gaim_imgstore_add(data, size, filename)
-+gaim2_imgstore_add(data, size, filename)
- void *data
- size_t size
- const char *filename
-
--Gaim::StoredImage
--gaim_imgstore_get(id)
-+Gaim2::StoredImage
-+gaim2_imgstore_get(id)
- int id
-
- gpointer
--gaim_imgstore_get_data(i)
-- Gaim::StoredImage i
-+gaim2_imgstore_get_data(i)
-+ Gaim2::StoredImage i
-
- const char *
--gaim_imgstore_get_filename(i)
-- Gaim::StoredImage i
-+gaim2_imgstore_get_filename(i)
-+ Gaim2::StoredImage i
-
- size_t
--gaim_imgstore_get_size(i)
-- Gaim::StoredImage i
-+gaim2_imgstore_get_size(i)
-+ Gaim2::StoredImage i
-
- void
--gaim_imgstore_ref(id)
-+gaim2_imgstore_ref(id)
- int id
-
- void
--gaim_imgstore_unref(id)
-+gaim2_imgstore_unref(id)
- int id
-
-diff -prNu ./plugins/perl/common/Log.xs ./plugins/perl/common/Log.xs
---- ./plugins/perl/common/Log.xs 2005-08-18 06:35:53.000000000 +0200
-+++ ./plugins/perl/common/Log.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,97 +1,97 @@
- #include "module.h"
-
--MODULE = Gaim::Log PACKAGE = Gaim::Log PREFIX = gaim_log_
-+MODULE = Gaim2::Log PACKAGE = Gaim2::Log PREFIX = gaim2_log_
- PROTOTYPES: ENABLE
-
- int
--gaim_log_common_sizer(log)
-- Gaim::Log log
-+gaim2_log_common_sizer(log)
-+ Gaim2::Log log
-
- void
--gaim_log_common_writer(log, ext)
-- Gaim::Log log
-+gaim2_log_common_writer(log, ext)
-+ Gaim2::Log log
- const char *ext
-
-
- gint
--gaim_log_compare(y, z)
-+gaim2_log_compare(y, z)
- gconstpointer y
- gconstpointer z
-
- void
--gaim_log_free(log)
-- Gaim::Log log
-+gaim2_log_free(log)
-+ Gaim2::Log log
-
- char *
--gaim_log_get_log_dir(type, name, account)
-- Gaim::LogType type
-+gaim2_log_get_log_dir(type, name, account)
-+ Gaim2::LogType type
- const char *name
-- Gaim::Account account
-+ Gaim2::Account account
-
- void
--gaim_log_get_log_sets()
-+gaim2_log_get_log_sets()
- PREINIT:
- GHashTable *l;
- PPCODE:
-- l = gaim_log_get_log_sets();
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l, "GHashTable")));
-+ l = gaim2_log_get_log_sets();
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l, "GHashTable")));
-
- void
--gaim_log_get_logs(type, name, account)
-- Gaim::LogType type
-+gaim2_log_get_logs(type, name, account)
-+ Gaim2::LogType type
- const char *name
-- Gaim::Account account
-+ Gaim2::Account account
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_log_get_logs(type, name, account); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_log_get_logs(type, name, account); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- int
--gaim_log_get_size(log)
-- Gaim::Log log
-+gaim2_log_get_size(log)
-+ Gaim2::Log log
-
- void
--gaim_log_get_system_logs(account)
-- Gaim::Account account
-+gaim2_log_get_system_logs(account)
-+ Gaim2::Account account
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_log_get_system_logs(account); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_log_get_system_logs(account); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- int
--gaim_log_get_total_size(type, name, account)
-- Gaim::LogType type
-+gaim2_log_get_total_size(type, name, account)
-+ Gaim2::LogType type
- const char *name
-- Gaim::Account account
-+ Gaim2::Account account
-
- void
--gaim_log_init()
-+gaim2_log_init()
-
-
- void
--gaim_log_logger_free(logger)
-- Gaim::Log::Logger logger
-+gaim2_log_logger_free(logger)
-+ Gaim2::Log::Logger logger
-
- void
--gaim_log_logger_get_options()
-+gaim2_log_logger_get_options()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_log_logger_get_options(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListEntry")));
-+ for (l = gaim2_log_logger_get_options(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListEntry")));
- }
-
- char *
--gaim_log_read(log, flags)
-- Gaim::Log log
-- Gaim::Log::ReadFlags flags
-+gaim2_log_read(log, flags)
-+ Gaim2::Log log
-+ Gaim2::Log::ReadFlags flags
-
- gint
--gaim_log_set_compare(y, z)
-+gaim2_log_set_compare(y, z)
- gconstpointer y
- gconstpointer z
-
-diff -prNu ./plugins/perl/common/Makefile.PL.in ./plugins/perl/common/Makefile.PL.in
---- ./plugins/perl/common/Makefile.PL.in 2005-12-07 08:51:30.000000000 +0100
-+++ ./plugins/perl/common/Makefile.PL.in 2006-01-05 13:53:54.000000000 +0100
-@@ -3,11 +3,11 @@ use ExtUtils::MakeMaker;
- # See lib/ExtUtils/MakeMaker.pm for details of how to influence
- # the contents of the Makefile that is written.
- WriteMakefile(
-- 'NAME' => 'Gaim',
-- 'VERSION_FROM' => '@srcdir@/Gaim.pm', # finds $VERSION
-+ 'NAME' => 'Gaim2',
-+ 'VERSION_FROM' => '@srcdir@/Gaim2.pm', # finds $VERSION
- 'PREREQ_PM' => {}, # e.g., Module::Name => 1.1
- ($] >= 5.005 ? ## Add these new keywords supported since 5.005
-- (ABSTRACT_FROM => '@srcdir@/Gaim.pm', # retrieve abstract from module
-+ (ABSTRACT_FROM => '@srcdir@/Gaim2.pm', # retrieve abstract from module
- AUTHOR => 'Christian Hammond <chipx86@gnupdate.org>') : ()),
- 'LIBS' => [''], # e.g., '-lm'
- 'DEFINE' => '@DEBUG_CFLAGS@', # e.g., '-DHAVE_SOMETHING'
-@@ -22,7 +22,7 @@ if (eval {require ExtUtils::Constant; 1}
- }
-
- ExtUtils::Constant::WriteConstants(
-- NAME => 'Gaim::DebugLevel',
-+ NAME => 'Gaim2::DebugLevel',
- NAMES => \@names,
- C_FILE => 'const-c.inc',
- XS_FILE => 'const-xs.inc'
-diff -prNu ./plugins/perl/common/MANIFEST ./plugins/perl/common/MANIFEST
---- ./plugins/perl/common/MANIFEST 2005-07-18 15:37:38.000000000 +0200
-+++ ./plugins/perl/common/MANIFEST 2006-01-05 14:27:29.000000000 +0100
-@@ -7,7 +7,7 @@ Cmds.xs
- Connection.xs
- Conversation.xs
- FT.xs
--Gaim.xs
-+Gaim2.xs
- ImgStore.xs
- Log.xs
- Network.xs
-@@ -29,7 +29,7 @@ Status.xs
- Stringref.xs
- Util.xs
- XMLNode.xs
--Gaim.pm
-+Gaim2.pm
- MANIFEST
- Makefile.PL
- typemap
-diff -prNu ./plugins/perl/common/module.h ./plugins/perl/common/module.h
---- ./plugins/perl/common/module.h 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/module.h 2006-01-05 15:27:48.000000000 +0100
-@@ -1,6 +1,6 @@
-
-
--typedef struct group *Gaim__Group;
-+typedef struct group *Gaim2__Group;
-
- #define group perl_group
-
-@@ -58,199 +58,199 @@ typedef struct group *Gaim__Group;
- #include "xmlnode.h"
-
- /* account.h */
--typedef GaimAccount * Gaim__Account;
--typedef GaimAccountOption * Gaim__Account__Option;
--typedef GaimAccountUiOps * Gaim__Account__UiOps;
--typedef GaimAccountUserSplit * Gaim__Account__UserSplit;
-+typedef Gaim2Account * Gaim2__Account;
-+typedef Gaim2AccountOption * Gaim2__Account__Option;
-+typedef Gaim2AccountUiOps * Gaim2__Account__UiOps;
-+typedef Gaim2AccountUserSplit * Gaim2__Account__UserSplit;
-
- /* blist.h */
--typedef GaimBlistNode * Gaim__BuddyList__Node;
--typedef GaimBlistNodeAction * Gaim__BuddyList__Node__Action;
--typedef GaimBlistUiOps * Gaim__BuddyList__UiOps;
--typedef GaimBlistNodeFlags Gaim__BlistNodeFlags;
--typedef GaimBuddyList * Gaim__BuddyList;
--typedef GaimBuddy * Gaim__BuddyList__Buddy;
--typedef GaimChat * Gaim__BuddyList__Chat;
--typedef GaimContact * Gaim__BuddyList__Contact;
--typedef GaimGroup * Gaim__BuddyList__Group;
-+typedef Gaim2BlistNode * Gaim2__BuddyList__Node;
-+typedef Gaim2BlistNodeAction * Gaim2__BuddyList__Node__Action;
-+typedef Gaim2BlistUiOps * Gaim2__BuddyList__UiOps;
-+typedef Gaim2BlistNodeFlags Gaim2__BlistNodeFlags;
-+typedef Gaim2BuddyList * Gaim2__BuddyList;
-+typedef Gaim2Buddy * Gaim2__BuddyList__Buddy;
-+typedef Gaim2Chat * Gaim2__BuddyList__Chat;
-+typedef Gaim2Contact * Gaim2__BuddyList__Contact;
-+typedef Gaim2Group * Gaim2__BuddyList__Group;
-
- /* buddyicon.h */
--typedef GaimBuddyIcon * Gaim__Buddy__Icon;
-+typedef Gaim2BuddyIcon * Gaim2__Buddy__Icon;
-
- /* cipher.h */
--typedef GaimCipherCaps Gaim__CipherCaps;
--typedef GaimCipher * Gaim__Cipher;
--typedef GaimCipherOps * Gaim__Cipher__Ops;
--typedef GaimCipherContext * Gaim__Cipher__Context;
-+typedef Gaim2CipherCaps Gaim2__CipherCaps;
-+typedef Gaim2Cipher * Gaim2__Cipher;
-+typedef Gaim2CipherOps * Gaim2__Cipher__Ops;
-+typedef Gaim2CipherContext * Gaim2__Cipher__Context;
-
- /* cmds.h */
--typedef GaimCmdId Gaim__CmdId;
-+typedef Gaim2CmdId Gaim2__CmdId;
-
- /* connection.h */
--typedef GaimConnectionFlags Gaim__ConnectionFlags;
--typedef GaimConnectionState Gaim__ConnectionState;
--typedef GaimConnection * Gaim__Connection;
--typedef GaimConnectionUiOps * Gaim__Connection__UiOps;
-+typedef Gaim2ConnectionFlags Gaim2__ConnectionFlags;
-+typedef Gaim2ConnectionState Gaim2__ConnectionState;
-+typedef Gaim2Connection * Gaim2__Connection;
-+typedef Gaim2ConnectionUiOps * Gaim2__Connection__UiOps;
-
- /* converstaion.h */
--typedef GaimConversationType Gaim__ConversationType;
--typedef GaimUnseenState Gaim__UnseenState;
--typedef GaimConvUpdateType Gaim__ConvUpdateType;
--typedef GaimTypingState Gaim__TypingState;
--typedef GaimMessageFlags Gaim__MessageFlags;
--typedef GaimConvChatBuddyFlags Gaim__ConvChatBuddyFlags;
--//typedef GaimConvWindowUiOps * Gaim__ConvWindow__UiOps;
--//typedef GaimConvWindow * Gaim__ConvWindow;
--typedef GaimConversationUiOps * Gaim__Conversation__UiOps;
--typedef GaimConversation * Gaim__Conversation;
--typedef GaimConvIm * Gaim__Conversation__IM;
--typedef GaimConvChat * Gaim__Conversation__Chat;
--typedef GaimConvChatBuddy * Gaim__Conversation__ChatBuddy;
-+typedef Gaim2ConversationType Gaim2__ConversationType;
-+typedef Gaim2UnseenState Gaim2__UnseenState;
-+typedef Gaim2ConvUpdateType Gaim2__ConvUpdateType;
-+typedef Gaim2TypingState Gaim2__TypingState;
-+typedef Gaim2MessageFlags Gaim2__MessageFlags;
-+typedef Gaim2ConvChatBuddyFlags Gaim2__ConvChatBuddyFlags;
-+//typedef Gaim2ConvWindowUiOps * Gaim2__ConvWindow__UiOps;
-+//typedef Gaim2ConvWindow * Gaim2__ConvWindow;
-+typedef Gaim2ConversationUiOps * Gaim2__Conversation__UiOps;
-+typedef Gaim2Conversation * Gaim2__Conversation;
-+typedef Gaim2ConvIm * Gaim2__Conversation__IM;
-+typedef Gaim2ConvChat * Gaim2__Conversation__Chat;
-+typedef Gaim2ConvChatBuddy * Gaim2__Conversation__ChatBuddy;
-
- /* debug.h */
--typedef GaimDebugLevel Gaim__DebugLevel;
-+typedef Gaim2DebugLevel Gaim2__DebugLevel;
-
- /* desktopitem.h */
--typedef GaimDesktopItem * Gaim__DesktopItem;
--typedef GaimDesktopItemType Gaim__DesktopItemType;
-+typedef Gaim2DesktopItem * Gaim2__DesktopItem;
-+typedef Gaim2DesktopItemType Gaim2__DesktopItemType;
-
- /* eventloop.h */
--typedef GaimInputCondition * Gaim__InputCondition;
--typedef GaimEventLoopUiOps * Gaim__EventLoopUiOps;
-+typedef Gaim2InputCondition * Gaim2__InputCondition;
-+typedef Gaim2EventLoopUiOps * Gaim2__EventLoopUiOps;
-
- /* ft.h */
--typedef GaimXfer * Gaim__Xfer;
--typedef GaimXferType Gaim__XferType;
--typedef GaimXferStatusType Gaim__XferStatusType;
--typedef GaimXferUiOps * Gaim__XferUiOps;
-+typedef Gaim2Xfer * Gaim2__Xfer;
-+typedef Gaim2XferType Gaim2__XferType;
-+typedef Gaim2XferStatusType Gaim2__XferStatusType;
-+typedef Gaim2XferUiOps * Gaim2__XferUiOps;
-
- /* gtkblish.h */
--typedef GaimGtkBuddyList * Gaim__GTK__BuddyList;
--typedef GaimStatusIconSize Gaim__StatusIconSize;
-+typedef Gaim2GtkBuddyList * Gaim2__GTK__BuddyList;
-+typedef Gaim2StatusIconSize Gaim2__StatusIconSize;
-
-
- /* gtkutils.h */
--typedef GaimButtonOrientation Gaim__ButtonOrientation;
--typedef GaimButtonStyle Gaim__ButtonStyle;
-+typedef Gaim2ButtonOrientation Gaim2__ButtonOrientation;
-+typedef Gaim2ButtonStyle Gaim2__ButtonStyle;
- #ifndef _WIN32
--typedef GaimBrowserPlace Gaim__BrowserPlace;
-+typedef Gaim2BrowserPlace Gaim2__BrowserPlace;
- #endif /* _WIN32 */
-
- /* gtkconv.h */
--typedef GdkPixbuf * Gaim__GDK__Pixbuf;
--typedef GtkWidget * Gaim__GTK__Widget;
--typedef GaimGtkConversation * Gaim__GTK__Conversation;
-+typedef GdkPixbuf * Gaim2__GDK__Pixbuf;
-+typedef GtkWidget * Gaim2__GTK__Widget;
-+typedef Gaim2GtkConversation * Gaim2__GTK__Conversation;
-
- /* gtkutils.h */
--typedef GtkSelectionData * Gaim__GTK__SelectionData;
--typedef GtkFileSelection * Gaim__GTK__FileSelection;
--typedef GtkTextView * Gaim__GTK__TextView;
-+typedef GtkSelectionData * Gaim2__GTK__SelectionData;
-+typedef GtkFileSelection * Gaim2__GTK__FileSelection;
-+typedef GtkTextView * Gaim2__GTK__TextView;
-
- /* gtkconn.h */
-
- /* imgstore.h */
--typedef GaimStoredImage * Gaim__StoredImage;
-+typedef Gaim2StoredImage * Gaim2__StoredImage;
-
- /* log.h */
--typedef GaimLog * Gaim__Log;
--typedef GaimLogLogger * Gaim__Log__Logger;
--typedef GaimLogCommonLoggerData * Gaim__LogCommonLoggerData;
--typedef GaimLogSet * Gaim__LogSet;
--typedef GaimLogType Gaim__LogType;
--typedef GaimLogReadFlags * Gaim__Log__ReadFlags;
-+typedef Gaim2Log * Gaim2__Log;
-+typedef Gaim2LogLogger * Gaim2__Log__Logger;
-+typedef Gaim2LogCommonLoggerData * Gaim2__LogCommonLoggerData;
-+typedef Gaim2LogSet * Gaim2__LogSet;
-+typedef Gaim2LogType Gaim2__LogType;
-+typedef Gaim2LogReadFlags * Gaim2__Log__ReadFlags;
-
- /* notify.h */
--typedef GaimNotifyCloseCallback Gaim__NotifyCloseCallback;
--typedef GaimNotifyType Gaim__NotifyType;
--typedef GaimNotifyMsgType Gaim__NotifyMsgType;
--typedef GaimNotifySearchButtonType Gaim__NotifySearchButtonType;
--typedef GaimNotifySearchResults * Gaim__NotifySearchResults;
--typedef GaimNotifySearchColumn * Gaim__NotifySearchColumn;
--typedef GaimNotifySearchButton * Gaim__NotifySearchButton;
--typedef GaimNotifyUiOps * Gaim__NotifyUiOps;
-+typedef Gaim2NotifyCloseCallback Gaim2__NotifyCloseCallback;
-+typedef Gaim2NotifyType Gaim2__NotifyType;
-+typedef Gaim2NotifyMsgType Gaim2__NotifyMsgType;
-+typedef Gaim2NotifySearchButtonType Gaim2__NotifySearchButtonType;
-+typedef Gaim2NotifySearchResults * Gaim2__NotifySearchResults;
-+typedef Gaim2NotifySearchColumn * Gaim2__NotifySearchColumn;
-+typedef Gaim2NotifySearchButton * Gaim2__NotifySearchButton;
-+typedef Gaim2NotifyUiOps * Gaim2__NotifyUiOps;
-
- /* plugin.h */
--typedef GaimPlugin * Gaim__Plugin;
--typedef GaimPluginType Gaim__PluginType;
--typedef GaimPluginInfo * Gaim__PluginInfo;
--typedef GaimPluginUiInfo * Gaim__PluginUiInfo;
--typedef GaimPluginLoaderInfo * Gaim__PluginLoaderInfo;
--typedef GaimPluginAction * Gaim__Plugin__Action;
-+typedef Gaim2Plugin * Gaim2__Plugin;
-+typedef Gaim2PluginType Gaim2__PluginType;
-+typedef Gaim2PluginInfo * Gaim2__PluginInfo;
-+typedef Gaim2PluginUiInfo * Gaim2__PluginUiInfo;
-+typedef Gaim2PluginLoaderInfo * Gaim2__PluginLoaderInfo;
-+typedef Gaim2PluginAction * Gaim2__Plugin__Action;
-
- /* pluginpref.h */
--typedef GaimPluginPrefFrame * Gaim__PluginPref__Frame;
--typedef GaimPluginPref * Gaim__PluginPref;
--typedef GaimPluginPrefType Gaim__PluginPrefType;
-+typedef Gaim2PluginPrefFrame * Gaim2__PluginPref__Frame;
-+typedef Gaim2PluginPref * Gaim2__PluginPref;
-+typedef Gaim2PluginPrefType Gaim2__PluginPrefType;
-
- /* pounce.h */
--typedef GaimPounce * Gaim__Pounce;
--typedef GaimPounceEvent Gaim__PounceEvent;
-+typedef Gaim2Pounce * Gaim2__Pounce;
-+typedef Gaim2PounceEvent Gaim2__PounceEvent;
-
-
- /* prefs.h */
--typedef GaimPrefType Gaim__PrefType;
-+typedef Gaim2PrefType Gaim2__PrefType;
-
- /* privacy.h */
--typedef GaimPrivacyType Gaim__PrivacyType;
--typedef GaimPrivacyUiOps * Gaim__Privacy__UiOps;
-+typedef Gaim2PrivacyType Gaim2__PrivacyType;
-+typedef Gaim2PrivacyUiOps * Gaim2__Privacy__UiOps;
-
- /* proxy.h */
--typedef GaimProxyType Gaim__ProxyType;
--typedef GaimProxyInfo * Gaim__ProxyInfo;
-+typedef Gaim2ProxyType Gaim2__ProxyType;
-+typedef Gaim2ProxyInfo * Gaim2__ProxyInfo;
-
-
- /* prpl.h */
--typedef GaimBuddyIconSpec * Gaim__Buddy__Icon__Spec;
--typedef GaimPluginProtocolInfo * Gaim__PluginProtocolInfo;
--typedef GaimIconScaleRules Gaim__IconScaleRules;
--typedef GaimProtocolOptions Gaim__ProtocolOptions;
-+typedef Gaim2BuddyIconSpec * Gaim2__Buddy__Icon__Spec;
-+typedef Gaim2PluginProtocolInfo * Gaim2__PluginProtocolInfo;
-+typedef Gaim2IconScaleRules Gaim2__IconScaleRules;
-+typedef Gaim2ProtocolOptions Gaim2__ProtocolOptions;
-
- /* request.h */
--typedef GaimRequestType Gaim__RequestType;
--typedef GaimRequestFieldType Gaim__RequestFieldType;
--typedef GaimRequestFields * Gaim__Request__Fields;
--typedef GaimRequestFieldGroup * Gaim__Request__Field__Group;
--typedef GaimRequestField * Gaim__Request__Field;
--typedef GaimRequestUiOps * Gaim__Request__UiOps;
-+typedef Gaim2RequestType Gaim2__RequestType;
-+typedef Gaim2RequestFieldType Gaim2__RequestFieldType;
-+typedef Gaim2RequestFields * Gaim2__Request__Fields;
-+typedef Gaim2RequestFieldGroup * Gaim2__Request__Field__Group;
-+typedef Gaim2RequestField * Gaim2__Request__Field;
-+typedef Gaim2RequestUiOps * Gaim2__Request__UiOps;
-
- /* roomlist.h */
-
--typedef GaimRoomlist * Gaim__Roomlist;
--typedef GaimRoomlistRoom * Gaim__Roomlist__Room;
--typedef GaimRoomlistField * Gaim__Roomlist__Field;
--typedef GaimRoomlistUiOps * Gaim__Roomlist__UiOps;
--typedef GaimRoomlistRoomType Gaim__RoomlistRoomType;
--typedef GaimRoomlistFieldType Gaim__RoomlistFieldType;
-+typedef Gaim2Roomlist * Gaim2__Roomlist;
-+typedef Gaim2RoomlistRoom * Gaim2__Roomlist__Room;
-+typedef Gaim2RoomlistField * Gaim2__Roomlist__Field;
-+typedef Gaim2RoomlistUiOps * Gaim2__Roomlist__UiOps;
-+typedef Gaim2RoomlistRoomType Gaim2__RoomlistRoomType;
-+typedef Gaim2RoomlistFieldType Gaim2__RoomlistFieldType;
-
- /* savedstatuses.h */
--typedef GaimSavedStatus * Gaim__SavedStatus;
--typedef GaimSavedStatusSub * Gaim__SavedStatusSub;
-+typedef Gaim2SavedStatus * Gaim2__SavedStatus;
-+typedef Gaim2SavedStatusSub * Gaim2__SavedStatusSub;
-
- /* sound.h */
--typedef GaimSoundEventID Gaim__SoundEventID;
--typedef GaimSoundUiOps * Gaim__Sound__UiOps;
-+typedef Gaim2SoundEventID Gaim2__SoundEventID;
-+typedef Gaim2SoundUiOps * Gaim2__Sound__UiOps;
-
- /* sslconn.h */
--typedef GaimSslConnection * Gaim__Ssl__Connection;
--typedef GaimInputCondition * Gaim__Input__Condition;
--typedef GaimSslErrorType Gaim__SslErrorType;
--typedef GaimSslOps * Gaim__Ssl__Ops;
-+typedef Gaim2SslConnection * Gaim2__Ssl__Connection;
-+typedef Gaim2InputCondition * Gaim2__Input__Condition;
-+typedef Gaim2SslErrorType Gaim2__SslErrorType;
-+typedef Gaim2SslOps * Gaim2__Ssl__Ops;
-
- /* status.h */
--typedef GaimStatusType * Gaim__StatusType;
--typedef GaimStatusAttr * Gaim__StatusAttr;
--typedef GaimPresence * Gaim__Presence;
--typedef GaimStatus * Gaim__Status;
--typedef GaimPresenceContext Gaim__PresenceContext;
--typedef GaimStatusPrimitive Gaim__StatusPrimitive;
-+typedef Gaim2StatusType * Gaim2__StatusType;
-+typedef Gaim2StatusAttr * Gaim2__StatusAttr;
-+typedef Gaim2Presence * Gaim2__Presence;
-+typedef Gaim2Status * Gaim2__Status;
-+typedef Gaim2PresenceContext Gaim2__PresenceContext;
-+typedef Gaim2StatusPrimitive Gaim2__StatusPrimitive;
-
--typedef GaimStringref * Gaim__Stringref;
-+typedef Gaim2Stringref * Gaim2__Stringref;
-
- /* value.h */
--typedef GaimValue * Gaim__Value;
-+typedef Gaim2Value * Gaim2__Value;
-
- /* xmlnode.h */
--typedef xmlnode * Gaim__XMLNode;
-+typedef xmlnode * Gaim2__XMLNode;
- typedef XMLNodeType XMLNode__Type;
-
-
-diff -prNu ./plugins/perl/common/Network.xs ./plugins/perl/common/Network.xs
---- ./plugins/perl/common/Network.xs 2006-01-05 06:04:05.000000000 +0100
-+++ ./plugins/perl/common/Network.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,44 +1,44 @@
- #include "module.h"
-
--MODULE = Gaim::Network PACKAGE = Gaim::Network PREFIX = gaim_network_
-+MODULE = Gaim2::Network PACKAGE = Gaim2::Network PREFIX = gaim2_network_
- PROTOTYPES: ENABLE
-
- const char *
--gaim_network_get_local_system_ip(fd)
-+gaim2_network_get_local_system_ip(fd)
- int fd
-
- const char *
--gaim_network_get_my_ip(fd)
-+gaim2_network_get_my_ip(fd)
- int fd
-
- unsigned short
--gaim_network_get_port_from_fd(fd)
-+gaim2_network_get_port_from_fd(fd)
- int fd
-
- const char *
--gaim_network_get_public_ip()
-+gaim2_network_get_public_ip()
-
-
- void
--gaim_network_init()
-+gaim2_network_init()
-
-
- const unsigned char *
--gaim_network_ip_atoi(ip)
-+gaim2_network_ip_atoi(ip)
- const char *ip
-
- int
--gaim_network_listen(port, socket_type)
-+gaim2_network_listen(port, socket_type)
- unsigned short port
- int socket_type
-
- int
--gaim_network_listen_range(start, end, socket_type)
-+gaim2_network_listen_range(start, end, socket_type)
- unsigned short start
- unsigned short end
- int socket_type
-
- void
--gaim_network_set_public_ip(ip)
-+gaim2_network_set_public_ip(ip)
- const char *ip
-
-diff -prNu ./plugins/perl/common/Notify.xs ./plugins/perl/common/Notify.xs
---- ./plugins/perl/common/Notify.xs 2005-11-28 02:50:55.000000000 +0100
-+++ ./plugins/perl/common/Notify.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,30 +1,30 @@
- #include "module.h"
-
--MODULE = Gaim::Notify PACKAGE = Gaim::Notify PREFIX = gaim_notify_
-+MODULE = Gaim2::Notify PACKAGE = Gaim2::Notify PREFIX = gaim2_notify_
- PROTOTYPES: ENABLE
-
- void
--gaim_notify_close(type, ui_handle)
-- Gaim::NotifyType type
-+gaim2_notify_close(type, ui_handle)
-+ Gaim2::NotifyType type
- void * ui_handle
-
- void
--gaim_notify_close_with_handle(handle)
-+gaim2_notify_close_with_handle(handle)
- void * handle
-
- void *
--gaim_notify_email(handle, subject, from, to, url, cb, user_data)
-+gaim2_notify_email(handle, subject, from, to, url, cb, user_data)
- void * handle
- const char *subject
- const char *from
- const char *to
- const char *url
-- Gaim::NotifyCloseCallback cb
-+ Gaim2::NotifyCloseCallback cb
- gpointer user_data
-
-
- void *
--gaim_notify_emails(handle, count, detailed, subjects, froms, tos, urls, cb, user_data)
-+gaim2_notify_emails(handle, count, detailed, subjects, froms, tos, urls, cb, user_data)
- void * handle
- size_t count
- gboolean detailed
-@@ -32,61 +32,61 @@ gaim_notify_emails(handle, count, detail
- const char **froms
- const char **tos
- const char **urls
-- Gaim::NotifyCloseCallback cb
-+ Gaim2::NotifyCloseCallback cb
- gpointer user_data
-
-
- void *
--gaim_notify_formatted(handle, title, primary, secondary, text, cb, user_data)
-+gaim2_notify_formatted(handle, title, primary, secondary, text, cb, user_data)
- void * handle
- const char *title
- const char *primary
- const char *secondary
- const char *text
-- Gaim::NotifyCloseCallback cb
-+ Gaim2::NotifyCloseCallback cb
- gpointer user_data
-
-
--Gaim::NotifyUiOps
--gaim_notify_get_ui_ops()
-+Gaim2::NotifyUiOps
-+gaim2_notify_get_ui_ops()
-
-
- void *
--gaim_notify_message(handle, type, title, primary, secondary, cb, user_data)
-+gaim2_notify_message(handle, type, title, primary, secondary, cb, user_data)
- void * handle
-- Gaim::NotifyMsgType type
-+ Gaim2::NotifyMsgType type
- const char *title
- const char *primary
- const char *secondary
-- Gaim::NotifyCloseCallback cb
-+ Gaim2::NotifyCloseCallback cb
- gpointer user_data
-
-
- void *
--gaim_notify_searchresults(gc, title, primary, secondary, results, cb, user_data)
-- Gaim::Connection gc
-+gaim2_notify_searchresults(gc, title, primary, secondary, results, cb, user_data)
-+ Gaim2::Connection gc
- const char *title
- const char *primary
- const char *secondary
-- Gaim::NotifySearchResults results
-- Gaim::NotifyCloseCallback cb
-+ Gaim2::NotifySearchResults results
-+ Gaim2::NotifyCloseCallback cb
- gpointer user_data
-
- void
--gaim_notify_set_ui_ops(ops)
-- Gaim::NotifyUiOps ops
-+gaim2_notify_set_ui_ops(ops)
-+ Gaim2::NotifyUiOps ops
-
- void *
--gaim_notify_uri(handle, uri)
-+gaim2_notify_uri(handle, uri)
- void * handle
- const char *uri
-
- void *
--gaim_notify_userinfo(gc, who, text, cb, user_data)
-- Gaim::Connection gc
-+gaim2_notify_userinfo(gc, who, text, cb, user_data)
-+ Gaim2::Connection gc
- const char *who
- const char *text
-- Gaim::NotifyCloseCallback cb
-+ Gaim2::NotifyCloseCallback cb
- gpointer user_data
-
-
-diff -prNu ./plugins/perl/common/PluginPref.xs ./plugins/perl/common/PluginPref.xs
---- ./plugins/perl/common/PluginPref.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/PluginPref.xs 2006-01-05 15:24:26.000000000 +0100
-@@ -1,143 +1,143 @@
- #include "module.h"
-
--MODULE = Gaim::PluginPref PACKAGE = Gaim::PluginPref::Frame PREFIX = gaim_plugin_pref_frame_
-+MODULE = Gaim2::PluginPref PACKAGE = Gaim2::PluginPref::Frame PREFIX = gaim2_plugin_pref_frame_
- PROTOTYPES: ENABLE
-
- void
--gaim_plugin_pref_frame_add(frame, pref)
-- Gaim::PluginPref::Frame frame
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_frame_add(frame, pref)
-+ Gaim2::PluginPref::Frame frame
-+ Gaim2::PluginPref pref
-
- void
--gaim_plugin_pref_frame_destroy(frame)
-- Gaim::PluginPref::Frame frame
-+gaim2_plugin_pref_frame_destroy(frame)
-+ Gaim2::PluginPref::Frame frame
-
- void
--gaim_plugin_pref_frame_get_prefs(frame)
-- Gaim::PluginPref::Frame frame
-+gaim2_plugin_pref_frame_get_prefs(frame)
-+ Gaim2::PluginPref::Frame frame
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_plugin_pref_frame_get_prefs(frame); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_plugin_pref_frame_get_prefs(frame); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
--Gaim::PluginPref::Frame
--gaim_plugin_pref_frame_new(class)
-+Gaim2::PluginPref::Frame
-+gaim2_plugin_pref_frame_new(class)
- C_ARGS: /* void */
-
-
--MODULE = Gaim::PluginPref PACKAGE = Gaim::PluginPref PREFIX = gaim_plugin_pref_
-+MODULE = Gaim2::PluginPref PACKAGE = Gaim2::PluginPref PREFIX = gaim2_plugin_pref_
- PROTOTYPES: ENABLE
-
- void
--gaim_plugin_pref_add_choice(pref, label, choice)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_add_choice(pref, label, choice)
-+ Gaim2::PluginPref pref
- char *label
- gpointer choice
-
- void
--gaim_plugin_pref_destroy(pref)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_destroy(pref)
-+ Gaim2::PluginPref pref
-
-
- void
--gaim_plugin_pref_get_bounds(pref, min, max)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_get_bounds(pref, min, max)
-+ Gaim2::PluginPref pref
- int *min
- int *max
-
- void
--gaim_plugin_pref_get_choices(pref)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_get_choices(pref)
-+ Gaim2::PluginPref pref
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_plugin_pref_get_choices(pref); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_plugin_pref_get_choices(pref); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
- char *
--gaim_plugin_pref_get_label(pref)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_get_label(pref)
-+ Gaim2::PluginPref pref
-
- gboolean
--gaim_plugin_pref_get_masked(pref)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_get_masked(pref)
-+ Gaim2::PluginPref pref
-
- unsigned int
--gaim_plugin_pref_get_max_length(pref)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_get_max_length(pref)
-+ Gaim2::PluginPref pref
-
- char *
--gaim_plugin_pref_get_name(pref)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_get_name(pref)
-+ Gaim2::PluginPref pref
-
--Gaim::PluginPrefType
--gaim_plugin_pref_get_type(pref)
-- Gaim::PluginPref pref
-+Gaim2::PluginPrefType
-+gaim2_plugin_pref_get_type(pref)
-+ Gaim2::PluginPref pref
-
--Gaim::PluginPref
--gaim_plugin_pref_new(class)
-+Gaim2::PluginPref
-+gaim2_plugin_pref_new(class)
- C_ARGS: /* void */
-
-
--Gaim::PluginPref
--gaim_plugin_pref_new_with_label(class, label)
-+Gaim2::PluginPref
-+gaim2_plugin_pref_new_with_label(class, label)
- char *label
- C_ARGS:
- label
-
--Gaim::PluginPref
--gaim_plugin_pref_new_with_name(class, name)
-+Gaim2::PluginPref
-+gaim2_plugin_pref_new_with_name(class, name)
- char *name
- C_ARGS:
- name
-
--Gaim::PluginPref
--gaim_plugin_pref_new_with_name_and_label(class, name, label)
-+Gaim2::PluginPref
-+gaim2_plugin_pref_new_with_name_and_label(class, name, label)
- char *name
- char *label
- C_ARGS:
- name, label
-
- void
--gaim_plugin_pref_set_bounds(pref, min, max)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_set_bounds(pref, min, max)
-+ Gaim2::PluginPref pref
- int min
- int max
-
- void
--gaim_plugin_pref_set_label(pref, label)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_set_label(pref, label)
-+ Gaim2::PluginPref pref
- char *label
-
- void
--gaim_plugin_pref_set_masked(pref, mask)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_set_masked(pref, mask)
-+ Gaim2::PluginPref pref
- gboolean mask
-
- void
--gaim_plugin_pref_set_max_length(pref, max_length)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_set_max_length(pref, max_length)
-+ Gaim2::PluginPref pref
- unsigned int max_length
-
- void
--gaim_plugin_pref_set_name(pref, name)
-- Gaim::PluginPref pref
-+gaim2_plugin_pref_set_name(pref, name)
-+ Gaim2::PluginPref pref
- char *name
-
- void
--gaim_plugin_pref_set_type(pref, type)
-- Gaim::PluginPref pref
-- Gaim::PluginPrefType type
-+gaim2_plugin_pref_set_type(pref, type)
-+ Gaim2::PluginPref pref
-+ Gaim2::PluginPrefType type
- CODE:
-- GaimPluginPrefType gpp_type = GAIM_PLUGIN_PREF_NONE;
-+ Gaim2PluginPrefType gpp_type = GAIM_PLUGIN_PREF_NONE;
-
- if (type == 1) {
- gpp_type = GAIM_PLUGIN_PREF_CHOICE;
- } else if (type == 2) {
- gpp_type = GAIM_PLUGIN_PREF_INFO;
- }
-- gaim_plugin_pref_set_type(pref, gpp_type);
-+ gaim2_plugin_pref_set_type(pref, gpp_type);
-
-diff -prNu ./plugins/perl/common/Plugin.xs ./plugins/perl/common/Plugin.xs
---- ./plugins/perl/common/Plugin.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Plugin.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,135 +1,135 @@
- #include "module.h"
-
--MODULE = Gaim::Plugin PACKAGE = Gaim::Plugin PREFIX = gaim_plugin_
-+MODULE = Gaim2::Plugin PACKAGE = Gaim2::Plugin PREFIX = gaim2_plugin_
- PROTOTYPES: ENABLE
-
- void
--gaim_plugin_destroy(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_destroy(plugin)
-+ Gaim2::Plugin plugin
-
- void
--gaim_plugin_ipc_unregister(plugin, command)
-- Gaim::Plugin plugin
-+gaim2_plugin_ipc_unregister(plugin, command)
-+ Gaim2::Plugin plugin
- const char *command
-
- void
--gaim_plugin_ipc_unregister_all(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_ipc_unregister_all(plugin)
-+ Gaim2::Plugin plugin
-
- gboolean
--gaim_plugin_is_loaded(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_is_loaded(plugin)
-+ Gaim2::Plugin plugin
-
- gboolean
--gaim_plugin_load(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_load(plugin)
-+ Gaim2::Plugin plugin
-
--Gaim::Plugin
--gaim_plugin_new(native, path)
-+Gaim2::Plugin
-+gaim2_plugin_new(native, path)
- gboolean native
- const char *path
-
--Gaim::Plugin
--gaim_plugin_probe(filename)
-+Gaim2::Plugin
-+gaim2_plugin_probe(filename)
- const char *filename
-
- gboolean
--gaim_plugin_register(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_register(plugin)
-+ Gaim2::Plugin plugin
-
- gboolean
--gaim_plugin_reload(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_reload(plugin)
-+ Gaim2::Plugin plugin
-
- gboolean
--gaim_plugin_unload(plugin)
-- Gaim::Plugin plugin
-+gaim2_plugin_unload(plugin)
-+ Gaim2::Plugin plugin
-
-
-
-
--MODULE = Gaim::Plugin PACKAGE = Gaim::Plugins PREFIX = gaim_plugins_
-+MODULE = Gaim2::Plugin PACKAGE = Gaim2::Plugins PREFIX = gaim2_plugins_
- PROTOTYPES: ENABLE
-
-
- void
--gaim_plugins_add_search_path(path)
-+gaim2_plugins_add_search_path(path)
- const char *path
-
- void
--gaim_plugins_destroy_all()
-+gaim2_plugins_destroy_all()
-
-
- gboolean
--gaim_plugins_enabled()
-+gaim2_plugins_enabled()
-
-
--Gaim::Plugin
--gaim_plugins_find_with_basename(basename)
-+Gaim2::Plugin
-+gaim2_plugins_find_with_basename(basename)
- const char *basename
-
--Gaim::Plugin
--gaim_plugins_find_with_filename(filename)
-+Gaim2::Plugin
-+gaim2_plugins_find_with_filename(filename)
- const char *filename
-
--Gaim::Plugin
--gaim_plugins_find_with_id(id)
-+Gaim2::Plugin
-+gaim2_plugins_find_with_id(id)
- const char *id
-
--Gaim::Plugin
--gaim_plugins_find_with_name(name)
-+Gaim2::Plugin
-+gaim2_plugins_find_with_name(name)
- const char *name
-
- void
--gaim_plugins_get_all()
-+gaim2_plugins_get_all()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_plugins_get_all(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::PTR")));
-+ for (l = gaim2_plugins_get_all(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::PTR")));
- }
-
-
- void *
--gaim_plugins_get_handle()
-+gaim2_plugins_get_handle()
-
-
- void
--gaim_plugins_get_loaded()
-+gaim2_plugins_get_loaded()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_plugins_get_loaded(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::PTR")));
-+ for (l = gaim2_plugins_get_loaded(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::PTR")));
- }
-
-
- void
--gaim_plugins_get_protocols()
-+gaim2_plugins_get_protocols()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_plugins_get_protocols(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::PTR")));
-+ for (l = gaim2_plugins_get_protocols(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::PTR")));
- }
-
-
- void
--gaim_plugins_init()
-+gaim2_plugins_init()
-
-
- void
--gaim_plugins_load_saved(key)
-+gaim2_plugins_load_saved(key)
- const char *key
-
- void
--gaim_plugins_probe(ext)
-+gaim2_plugins_probe(ext)
- const char *ext
-
- void
--gaim_plugins_uninit()
-+gaim2_plugins_uninit()
-
-
- void
--gaim_plugins_unload_all()
-+gaim2_plugins_unload_all()
-
-diff -prNu ./plugins/perl/common/Pounce.xs ./plugins/perl/common/Pounce.xs
---- ./plugins/perl/common/Pounce.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Pounce.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,93 +1,93 @@
- #include "module.h"
-
--MODULE = Gaim::Pounce PACKAGE = Gaim::Pounce PREFIX = gaim_pounce_
-+MODULE = Gaim2::Pounce PACKAGE = Gaim2::Pounce PREFIX = gaim2_pounce_
- PROTOTYPES: ENABLE
-
- void
--gaim_pounce_action_register(pounce, name)
-- Gaim::Pounce pounce
-+gaim2_pounce_action_register(pounce, name)
-+ Gaim2::Pounce pounce
- const char *name
-
- void
--gaim_pounce_destroy(pounce)
-- Gaim::Pounce pounce
-+gaim2_pounce_destroy(pounce)
-+ Gaim2::Pounce pounce
-
- void
--gaim_pounce_destroy_all_by_account(account)
-- Gaim::Account account
-+gaim2_pounce_destroy_all_by_account(account)
-+ Gaim2::Account account
-
- void *
--gaim_pounce_get_data(pounce)
-- Gaim::Pounce pounce
-+gaim2_pounce_get_data(pounce)
-+ Gaim2::Pounce pounce
-
--Gaim::PounceEvent
--gaim_pounce_get_events(pounce)
-- Gaim::Pounce pounce
-+Gaim2::PounceEvent
-+gaim2_pounce_get_events(pounce)
-+ Gaim2::Pounce pounce
-
- const char *
--gaim_pounce_get_pouncee(pounce)
-- Gaim::Pounce pounce
-+gaim2_pounce_get_pouncee(pounce)
-+ Gaim2::Pounce pounce
-
--Gaim::Account
--gaim_pounce_get_pouncer(pounce)
-- Gaim::Pounce pounce
-+Gaim2::Account
-+gaim2_pounce_get_pouncer(pounce)
-+ Gaim2::Pounce pounce
-
- gboolean
--gaim_pounce_get_save(pounce)
-- Gaim::Pounce pounce
-+gaim2_pounce_get_save(pounce)
-+ Gaim2::Pounce pounce
-
- void
--gaim_pounce_set_data(pounce, data)
-- Gaim::Pounce pounce
-+gaim2_pounce_set_data(pounce, data)
-+ Gaim2::Pounce pounce
- void * data
-
- void
--gaim_pounce_set_events(pounce, events)
-- Gaim::Pounce pounce
-- Gaim::PounceEvent events
-+gaim2_pounce_set_events(pounce, events)
-+ Gaim2::Pounce pounce
-+ Gaim2::PounceEvent events
-
- void
--gaim_pounce_set_pouncee(pounce, pouncee)
-- Gaim::Pounce pounce
-+gaim2_pounce_set_pouncee(pounce, pouncee)
-+ Gaim2::Pounce pounce
- const char *pouncee
-
- void
--gaim_pounce_set_pouncer(pounce, pouncer)
-- Gaim::Pounce pounce
-- Gaim::Account pouncer
-+gaim2_pounce_set_pouncer(pounce, pouncer)
-+ Gaim2::Pounce pounce
-+ Gaim2::Account pouncer
-
- void
--gaim_pounce_set_save(pounce, save)
-- Gaim::Pounce pounce
-+gaim2_pounce_set_save(pounce, save)
-+ Gaim2::Pounce pounce
- gboolean save
-
- void
--gaim_pounces_get_all()
-+gaim2_pounces_get_all()
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_pounces_get_all(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::Status::Type")));
-+ for (l = gaim2_pounces_get_all(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::Status::Type")));
- }
-
-
- void *
--gaim_pounces_get_handle()
-+gaim2_pounces_get_handle()
-
-
- void
--gaim_pounces_init()
-+gaim2_pounces_init()
-
-
- gboolean
--gaim_pounces_load()
-+gaim2_pounces_load()
-
-
- void
--gaim_pounces_uninit()
-+gaim2_pounces_uninit()
-
-
- void
--gaim_pounces_unregister_handler(ui)
-+gaim2_pounces_unregister_handler(ui)
- const char *ui
-
-diff -prNu ./plugins/perl/common/Prefs.xs ./plugins/perl/common/Prefs.xs
---- ./plugins/perl/common/Prefs.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Prefs.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,29 +1,29 @@
- #include "module.h"
-
--MODULE = Gaim::Prefs PACKAGE = Gaim::Prefs PREFIX = gaim_prefs_
-+MODULE = Gaim2::Prefs PACKAGE = Gaim2::Prefs PREFIX = gaim2_prefs_
- PROTOTYPES: ENABLE
-
- void
--gaim_prefs_add_bool(name, value)
-+gaim2_prefs_add_bool(name, value)
- const char *name
- gboolean value
-
- void
--gaim_prefs_add_int(name, value)
-+gaim2_prefs_add_int(name, value)
- const char *name
- int value
-
- void
--gaim_prefs_add_none(name)
-+gaim2_prefs_add_none(name)
- const char *name
-
- void
--gaim_prefs_add_string(name, value)
-+gaim2_prefs_add_string(name, value)
- const char *name
- const char *value
-
- void
--gaim_prefs_add_string_list(name, value)
-+gaim2_prefs_add_string_list(name, value)
- const char *name
- SV *value
- PREINIT:
-@@ -37,102 +37,102 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(value), i, 0), t_sl));
- }
-- gaim_prefs_add_string_list(name, t_GL);
-+ gaim2_prefs_add_string_list(name, t_GL);
-
-
-
- void
--gaim_prefs_destroy()
-+gaim2_prefs_destroy()
-
-
- void
--gaim_prefs_disconnect_by_handle(handle)
-+gaim2_prefs_disconnect_by_handle(handle)
- void * handle
-
- void
--gaim_prefs_disconnect_callback(callback_id)
-+gaim2_prefs_disconnect_callback(callback_id)
- guint callback_id
-
- gboolean
--gaim_prefs_exists(name)
-+gaim2_prefs_exists(name)
- const char *name
-
- gboolean
--gaim_prefs_get_bool(name)
-+gaim2_prefs_get_bool(name)
- const char *name
-
- void *
--gaim_prefs_get_handle()
-+gaim2_prefs_get_handle()
-
-
- int
--gaim_prefs_get_int(name)
-+gaim2_prefs_get_int(name)
- const char *name
-
- const char *
--gaim_prefs_get_string(name)
-+gaim2_prefs_get_string(name)
- const char *name
-
- void
--gaim_prefs_get_string_list(name)
-+gaim2_prefs_get_string_list(name)
- const char *name
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_prefs_get_string_list(name); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::PrefValue")));
-+ for (l = gaim2_prefs_get_string_list(name); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::PrefValue")));
- }
-
-
-
--Gaim::PrefType
--gaim_prefs_get_type(name)
-+Gaim2::PrefType
-+gaim2_prefs_get_type(name)
- const char *name
-
- void
--gaim_prefs_init()
-+gaim2_prefs_init()
-
-
- gboolean
--gaim_prefs_load()
-+gaim2_prefs_load()
-
-
- void
--gaim_prefs_remove(name)
-+gaim2_prefs_remove(name)
- const char *name
-
- void
--gaim_prefs_rename(oldname, newname)
-+gaim2_prefs_rename(oldname, newname)
- const char *oldname
- const char *newname
-
- void
--gaim_prefs_rename_boolean_toggle(oldname, newname)
-+gaim2_prefs_rename_boolean_toggle(oldname, newname)
- const char *oldname
- const char *newname
-
- void
--gaim_prefs_set_bool(name, value)
-+gaim2_prefs_set_bool(name, value)
- const char *name
- gboolean value
-
- void
--gaim_prefs_set_generic(name, value)
-+gaim2_prefs_set_generic(name, value)
- const char *name
- gpointer value
-
- void
--gaim_prefs_set_int(name, value)
-+gaim2_prefs_set_int(name, value)
- const char *name
- int value
-
- void
--gaim_prefs_set_string(name, value)
-+gaim2_prefs_set_string(name, value)
- const char *name
- const char *value
-
- void
--gaim_prefs_set_string_list(name, value)
-+gaim2_prefs_set_string_list(name, value)
- const char *name
- SV *value
- PREINIT:
-@@ -146,17 +146,17 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(value), i, 0), t_sl));
- }
-- gaim_prefs_set_string_list(name, t_GL);
-+ gaim2_prefs_set_string_list(name, t_GL);
-
- void
--gaim_prefs_trigger_callback(name)
-+gaim2_prefs_trigger_callback(name)
- const char *name
-
- void
--gaim_prefs_uninit()
-+gaim2_prefs_uninit()
-
-
- void
--gaim_prefs_update_old()
-+gaim2_prefs_update_old()
-
-
-diff -prNu ./plugins/perl/common/Privacy.xs ./plugins/perl/common/Privacy.xs
---- ./plugins/perl/common/Privacy.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Privacy.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,17 +1,17 @@
- #include "module.h"
-
--MODULE = Gaim::Privacy PACKAGE = Gaim::Privacy PREFIX = gaim_privacy_
-+MODULE = Gaim2::Privacy PACKAGE = Gaim2::Privacy PREFIX = gaim2_privacy_
- PROTOTYPES: ENABLE
-
--Gaim::Privacy::UiOps
--gaim_privacy_get_ui_ops()
-+Gaim2::Privacy::UiOps
-+gaim2_privacy_get_ui_ops()
-
-
- void
--gaim_privacy_init()
-+gaim2_privacy_init()
-
-
- void
--gaim_privacy_set_ui_ops(ops)
-- Gaim::Privacy::UiOps ops
-+gaim2_privacy_set_ui_ops(ops)
-+ Gaim2::Privacy::UiOps ops
-
-diff -prNu ./plugins/perl/common/Proxy.xs ./plugins/perl/common/Proxy.xs
---- ./plugins/perl/common/Proxy.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Proxy.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,70 +1,70 @@
- #include "module.h"
-
--MODULE = Gaim::Proxy PACKAGE = Gaim::Proxy PREFIX = gaim_proxy_
-+MODULE = Gaim2::Proxy PACKAGE = Gaim2::Proxy PREFIX = gaim2_proxy_
- PROTOTYPES: ENABLE
-
--Gaim::ProxyInfo
--gaim_global_proxy_get_info()
-+Gaim2::ProxyInfo
-+gaim2_global_proxy_get_info()
-
-
- void *
--gaim_proxy_get_handle()
-+gaim2_proxy_get_handle()
-
-
- void
--gaim_proxy_info_destroy(info)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_destroy(info)
-+ Gaim2::ProxyInfo info
-
- const char *
--gaim_proxy_info_get_host(info)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_get_host(info)
-+ Gaim2::ProxyInfo info
-
- const char *
--gaim_proxy_info_get_password(info)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_get_password(info)
-+ Gaim2::ProxyInfo info
-
- int
--gaim_proxy_info_get_port(info)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_get_port(info)
-+ Gaim2::ProxyInfo info
-
--Gaim::ProxyType
--gaim_proxy_info_get_type(info)
-- Gaim::ProxyInfo info
-+Gaim2::ProxyType
-+gaim2_proxy_info_get_type(info)
-+ Gaim2::ProxyInfo info
-
- const char *
--gaim_proxy_info_get_username(info)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_get_username(info)
-+ Gaim2::ProxyInfo info
-
--Gaim::ProxyInfo
--gaim_proxy_info_new()
-+Gaim2::ProxyInfo
-+gaim2_proxy_info_new()
-
-
- void
--gaim_proxy_info_set_host(info, host)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_set_host(info, host)
-+ Gaim2::ProxyInfo info
- const char *host
-
- void
--gaim_proxy_info_set_password(info, password)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_set_password(info, password)
-+ Gaim2::ProxyInfo info
- const char *password
-
- void
--gaim_proxy_info_set_port(info, port)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_set_port(info, port)
-+ Gaim2::ProxyInfo info
- int port
-
- void
--gaim_proxy_info_set_type(info, type)
-- Gaim::ProxyInfo info
-- Gaim::ProxyType type
-+gaim2_proxy_info_set_type(info, type)
-+ Gaim2::ProxyInfo info
-+ Gaim2::ProxyType type
-
- void
--gaim_proxy_info_set_username(info, username)
-- Gaim::ProxyInfo info
-+gaim2_proxy_info_set_username(info, username)
-+ Gaim2::ProxyInfo info
- const char *username
-
- void
--gaim_proxy_init()
-+gaim2_proxy_init()
-
-
-diff -prNu ./plugins/perl/common/Prpl.xs ./plugins/perl/common/Prpl.xs
---- ./plugins/perl/common/Prpl.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Prpl.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,57 +1,57 @@
- #include "module.h"
-
--MODULE = Gaim::Prpl PACKAGE = Gaim::Find PREFIX = gaim_find_
-+MODULE = Gaim2::Prpl PACKAGE = Gaim2::Find PREFIX = gaim2_find_
- PROTOTYPES: ENABLE
-
--Gaim::Plugin
--gaim_find_prpl(id)
-+Gaim2::Plugin
-+gaim2_find_prpl(id)
- const char *id
-
-
--MODULE = Gaim::Prpl PACKAGE = Gaim::Prpl PREFIX = gaim_prpl_
-+MODULE = Gaim2::Prpl PACKAGE = Gaim2::Prpl PREFIX = gaim2_prpl_
- PROTOTYPES: ENABLE
-
-
- void
--gaim_prpl_change_account_status(account, old_status, new_status)
-- Gaim::Account account
-- Gaim::Status old_status
-- Gaim::Status new_status
-+gaim2_prpl_change_account_status(account, old_status, new_status)
-+ Gaim2::Account account
-+ Gaim2::Status old_status
-+ Gaim2::Status new_status
-
- void
--gaim_prpl_get_statuses(account, presence)
-- Gaim::Account account
-- Gaim::Presence presence
-+gaim2_prpl_get_statuses(account, presence)
-+ Gaim2::Account account
-+ Gaim2::Presence presence
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_prpl_get_statuses(account,presence); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_prpl_get_statuses(account,presence); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
-
- void
--gaim_prpl_got_account_idle(account, idle, idle_time)
-- Gaim::Account account
-+gaim2_prpl_got_account_idle(account, idle, idle_time)
-+ Gaim2::Account account
- gboolean idle
- time_t idle_time
-
- void
--gaim_prpl_got_account_login_time(account, login_time)
-- Gaim::Account account
-+gaim2_prpl_got_account_login_time(account, login_time)
-+ Gaim2::Account account
- time_t login_time
-
- void
--gaim_prpl_got_user_idle(account, name, idle, idle_time)
-- Gaim::Account account
-+gaim2_prpl_got_user_idle(account, name, idle, idle_time)
-+ Gaim2::Account account
- const char *name
- gboolean idle
- time_t idle_time
-
- void
--gaim_prpl_got_user_login_time(account, name, login_time)
-- Gaim::Account account
-+gaim2_prpl_got_user_login_time(account, name, login_time)
-+ Gaim2::Account account
- const char *name
- time_t login_time
-
-diff -prNu ./plugins/perl/common/Request.xs ./plugins/perl/common/Request.xs
---- ./plugins/perl/common/Request.xs 2005-12-08 22:00:31.000000000 +0100
-+++ ./plugins/perl/common/Request.xs 2006-01-05 15:25:06.000000000 +0100
-@@ -2,7 +2,7 @@
-
- /* This breaks on faceprint's amd64 box
- void *
--gaim_request_action_varg(handle, title, primary, secondary, default_action, user_data, action_count, actions)
-+gaim2_request_action_varg(handle, title, primary, secondary, default_action, user_data, action_count, actions)
- void * handle
- const char *title
- const char *primary
-@@ -17,26 +17,26 @@ gaim_request_action_varg(handle, title,
- typedef struct {
- char *cancel_cb;
- char *ok_cb;
--} GaimPerlRequestData;
-+} Gaim2PerlRequestData;
-
- /********************************************************/
- /* */
- /* Callback function that calls a perl subroutine */
- /* */
- /* The void * field data is being used as a way to hide */
--/* the perl sub's name in a GaimPerlRequestData */
-+/* the perl sub's name in a Gaim2PerlRequestData */
- /* */
- /********************************************************/
--static void gaim_perl_request_ok_cb(void * data, GaimRequestFields *fields) {
-+static void gaim2_perl_request_ok_cb(void * data, Gaim2RequestFields *fields) {
-
-- GaimPerlRequestData *gpr = (GaimPerlRequestData *)data;
-+ Gaim2PerlRequestData *gpr = (Gaim2PerlRequestData *)data;
-
- dSP;
- ENTER;
- SAVETMPS;
- PUSHMARK(sp);
-
-- XPUSHs(gaim_perl_bless_object(fields, "Gaim::Request::Fields"));
-+ XPUSHs(gaim2_perl_bless_object(fields, "Gaim2::Request::Fields"));
- PUTBACK;
-
- call_pv(gpr->ok_cb, G_EVAL | G_SCALAR);
-@@ -47,16 +47,16 @@ static void gaim_perl_request_ok_cb(void
- LEAVE;
- }
-
--static void gaim_perl_request_cancel_cb(void * data, GaimRequestFields *fields) {
-+static void gaim2_perl_request_cancel_cb(void * data, Gaim2RequestFields *fields) {
-
-- GaimPerlRequestData *gpr = (GaimPerlRequestData *)data;
-+ Gaim2PerlRequestData *gpr = (Gaim2PerlRequestData *)data;
-
- dSP;
- ENTER;
- SAVETMPS;
- PUSHMARK(sp);
-
-- XPUSHs(gaim_perl_bless_object(fields, "Gaim::Request::Fields"));
-+ XPUSHs(gaim2_perl_bless_object(fields, "Gaim2::Request::Fields"));
- PUTBACK;
- call_pv(gpr->cancel_cb, G_EVAL | G_SCALAR);
- SPAGAIN;
-@@ -66,12 +66,12 @@ static void gaim_perl_request_cancel_cb(
- LEAVE;
- }
-
--MODULE = Gaim::Request PACKAGE = Gaim::Request PREFIX = gaim_request_
-+MODULE = Gaim2::Request PACKAGE = Gaim2::Request PREFIX = gaim2_request_
- PROTOTYPES: ENABLE
-
- void *
--gaim_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, ok_cb, cancel_text, cancel_cb)
-- Gaim::Plugin handle
-+gaim2_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, ok_cb, cancel_text, cancel_cb)
-+ Gaim2::Plugin handle
- const char * title
- const char * primary
- const char * secondary
-@@ -84,495 +84,495 @@ gaim_request_input(handle, title, primar
- const char * cancel_text
- SV * cancel_cb
- CODE:
-- GaimPerlRequestData *gpr;
-+ Gaim2PerlRequestData *gpr;
- STRLEN len;
- char *basename, *package;
-
- basename = g_path_get_basename(handle->path);
-- gaim_perl_normalize_script_name(basename);
-- package = g_strdup_printf("Gaim::Script::%s", basename);
-- gpr = g_new(GaimPerlRequestData, 1);
-+ gaim2_perl_normalize_script_name(basename);
-+ package = g_strdup_printf("Gaim2::Script::%s", basename);
-+ gpr = g_new(Gaim2PerlRequestData, 1);
- gpr->ok_cb = g_strdup_printf("%s::%s", package, SvPV(ok_cb, len));
- gpr->cancel_cb = g_strdup_printf("%s::%s", package, SvPV(cancel_cb, len));
-
-- RETVAL = gaim_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, G_CALLBACK(gaim_perl_request_ok_cb), cancel_text, G_CALLBACK(gaim_perl_request_cancel_cb), gpr);
-+ RETVAL = gaim2_request_input(handle, title, primary, secondary, default_value, multiline, masked, hint, ok_text, G_CALLBACK(gaim2_perl_request_ok_cb), cancel_text, G_CALLBACK(gaim2_perl_request_cancel_cb), gpr);
- OUTPUT:
- RETVAL
-
- void *
--gaim_request_file(handle, title, filename, savedialog, ok_cb, cancel_cb)
-- Gaim::Plugin handle
-+gaim2_request_file(handle, title, filename, savedialog, ok_cb, cancel_cb)
-+ Gaim2::Plugin handle
- const char * title
- const char * filename
- gboolean savedialog
- SV * ok_cb
- SV * cancel_cb
- CODE:
-- GaimPerlRequestData *gpr;
-+ Gaim2PerlRequestData *gpr;
- STRLEN len;
- char *basename, *package;
-
- basename = g_path_get_basename(handle->path);
-- gaim_perl_normalize_script_name(basename);
-- package = g_strdup_printf("Gaim::Script::%s", basename);
-- gpr = g_new(GaimPerlRequestData, 1);
-+ gaim2_perl_normalize_script_name(basename);
-+ package = g_strdup_printf("Gaim2::Script::%s", basename);
-+ gpr = g_new(Gaim2PerlRequestData, 1);
- gpr->ok_cb = g_strdup_printf("%s::%s", package, SvPV(ok_cb, len));
- gpr->cancel_cb = g_strdup_printf("%s::%s", package, SvPV(cancel_cb, len));
-
-- RETVAL = gaim_request_file(handle, title, filename, savedialog, G_CALLBACK(gaim_perl_request_ok_cb), G_CALLBACK(gaim_perl_request_cancel_cb), gpr);
-+ RETVAL = gaim2_request_file(handle, title, filename, savedialog, G_CALLBACK(gaim2_perl_request_ok_cb), G_CALLBACK(gaim2_perl_request_cancel_cb), gpr);
- OUTPUT:
- RETVAL
-
-
- void *
--gaim_request_fields(handle, title, primary, secondary, fields, ok_text, ok_cb, cancel_text, cancel_cb)
-- Gaim::Plugin handle
-+gaim2_request_fields(handle, title, primary, secondary, fields, ok_text, ok_cb, cancel_text, cancel_cb)
-+ Gaim2::Plugin handle
- const char * title
- const char * primary
- const char * secondary
-- Gaim::Request::Fields fields
-+ Gaim2::Request::Fields fields
- const char * ok_text
- SV * ok_cb
- const char * cancel_text
- SV * cancel_cb
- CODE:
-- GaimPerlRequestData *gpr;
-+ Gaim2PerlRequestData *gpr;
- STRLEN len;
- char *basename, *package;
-
- basename = g_path_get_basename(handle->path);
-- gaim_perl_normalize_script_name(basename);
-- package = g_strdup_printf("Gaim::Script::%s", basename);
-- gpr = g_new(GaimPerlRequestData, 1);
-+ gaim2_perl_normalize_script_name(basename);
-+ package = g_strdup_printf("Gaim2::Script::%s", basename);
-+ gpr = g_new(Gaim2PerlRequestData, 1);
- gpr->ok_cb = g_strdup_printf("%s::%s", package, SvPV(ok_cb, len));
- gpr->cancel_cb = g_strdup_printf("%s::%s", package, SvPV(cancel_cb, len));
-
-- RETVAL = gaim_request_fields(handle, title, primary, secondary, fields, ok_text, G_CALLBACK(gaim_perl_request_ok_cb), cancel_text, G_CALLBACK(gaim_perl_request_cancel_cb), gpr);
-+ RETVAL = gaim2_request_fields(handle, title, primary, secondary, fields, ok_text, G_CALLBACK(gaim2_perl_request_ok_cb), cancel_text, G_CALLBACK(gaim2_perl_request_cancel_cb), gpr);
- OUTPUT:
- RETVAL
-
- void
--gaim_request_close(type, uihandle)
-- Gaim::RequestType type
-+gaim2_request_close(type, uihandle)
-+ Gaim2::RequestType type
- void * uihandle
-
- void
--gaim_request_close_with_handle(handle)
-+gaim2_request_close_with_handle(handle)
- void * handle
-
--Gaim::Account
--gaim_request_field_account_get_default_value(field)
-- Gaim::Request::Field field
-+Gaim2::Account
-+gaim2_request_field_account_get_default_value(field)
-+ Gaim2::Request::Field field
-
- IV
--gaim_request_field_account_get_filter(field)
-- Gaim::Request::Field field
-+gaim2_request_field_account_get_filter(field)
-+ Gaim2::Request::Field field
- CODE:
-- RETVAL = PTR2IV(gaim_request_field_account_get_filter(field));
-+ RETVAL = PTR2IV(gaim2_request_field_account_get_filter(field));
- OUTPUT:
- RETVAL
-
- gboolean
--gaim_request_field_account_get_show_all(field)
-- Gaim::Request::Field field
-+gaim2_request_field_account_get_show_all(field)
-+ Gaim2::Request::Field field
-
--Gaim::Account
--gaim_request_field_account_get_value(field)
-- Gaim::Request::Field field
-+Gaim2::Account
-+gaim2_request_field_account_get_value(field)
-+ Gaim2::Request::Field field
-
--Gaim::Request::Field
--gaim_request_field_account_new(id, text, account)
-+Gaim2::Request::Field
-+gaim2_request_field_account_new(id, text, account)
- const char *id
- const char *text
-- Gaim::Account account
-+ Gaim2::Account account
-
- void
--gaim_request_field_account_set_default_value(field, default_value)
-- Gaim::Request::Field field
-- Gaim::Account default_value
-+gaim2_request_field_account_set_default_value(field, default_value)
-+ Gaim2::Request::Field field
-+ Gaim2::Account default_value
-
-
- void
--gaim_request_field_account_set_show_all(field, show_all)
-- Gaim::Request::Field field
-+gaim2_request_field_account_set_show_all(field, show_all)
-+ Gaim2::Request::Field field
- gboolean show_all
-
- void
--gaim_request_field_account_set_value(field, value)
-- Gaim::Request::Field field
-- Gaim::Account value
-+gaim2_request_field_account_set_value(field, value)
-+ Gaim2::Request::Field field
-+ Gaim2::Account value
-
- gboolean
--gaim_request_field_bool_get_default_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_bool_get_default_value(field)
-+ Gaim2::Request::Field field
-
- gboolean
--gaim_request_field_bool_get_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_bool_get_value(field)
-+ Gaim2::Request::Field field
-
--Gaim::Request::Field
--gaim_request_field_bool_new(id, text, default_value)
-+Gaim2::Request::Field
-+gaim2_request_field_bool_new(id, text, default_value)
- const char *id
- const char *text
- gboolean default_value
-
- void
--gaim_request_field_bool_set_default_value(field, default_value)
-- Gaim::Request::Field field
-+gaim2_request_field_bool_set_default_value(field, default_value)
-+ Gaim2::Request::Field field
- gboolean default_value
-
- void
--gaim_request_field_bool_set_value(field, value)
-- Gaim::Request::Field field
-+gaim2_request_field_bool_set_value(field, value)
-+ Gaim2::Request::Field field
- gboolean value
-
- void
--gaim_request_field_choice_add(field, label)
-- Gaim::Request::Field field
-+gaim2_request_field_choice_add(field, label)
-+ Gaim2::Request::Field field
- const char *label
-
- int
--gaim_request_field_choice_get_default_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_choice_get_default_value(field)
-+ Gaim2::Request::Field field
-
- void
--gaim_request_field_choice_get_labels(field)
-- Gaim::Request::Field field
-+gaim2_request_field_choice_get_labels(field)
-+ Gaim2::Request::Field field
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_request_field_choice_get_labels(field); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_request_field_choice_get_labels(field); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
-
-
- int
--gaim_request_field_choice_get_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_choice_get_value(field)
-+ Gaim2::Request::Field field
-
--Gaim::Request::Field
--gaim_request_field_choice_new(id, text, default_value)
-+Gaim2::Request::Field
-+gaim2_request_field_choice_new(id, text, default_value)
- const char *id
- const char *text
- int default_value
-
- void
--gaim_request_field_choice_set_default_value(field, default_value)
-- Gaim::Request::Field field
-+gaim2_request_field_choice_set_default_value(field, default_value)
-+ Gaim2::Request::Field field
- int default_value
-
- void
--gaim_request_field_choice_set_value(field, value)
-- Gaim::Request::Field field
-+gaim2_request_field_choice_set_value(field, value)
-+ Gaim2::Request::Field field
- int value
-
- void
--gaim_request_field_destroy(field)
-- Gaim::Request::Field field
-+gaim2_request_field_destroy(field)
-+ Gaim2::Request::Field field
-
- const char *
--gaim_request_field_get_id(field)
-- Gaim::Request::Field field
-+gaim2_request_field_get_id(field)
-+ Gaim2::Request::Field field
-
- const char *
--gaim_request_field_get_label(field)
-- Gaim::Request::Field field
-+gaim2_request_field_get_label(field)
-+ Gaim2::Request::Field field
-
--Gaim::RequestFieldType
--gaim_request_field_get_type(field)
-- Gaim::Request::Field field
-+Gaim2::RequestFieldType
-+gaim2_request_field_get_type(field)
-+ Gaim2::Request::Field field
-
- const char *
--gaim_request_field_get_type_hint(field)
-- Gaim::Request::Field field
-+gaim2_request_field_get_type_hint(field)
-+ Gaim2::Request::Field field
-
- void
--gaim_request_field_group_add_field(group, field)
-- Gaim::Request::Field::Group group
-- Gaim::Request::Field field
-+gaim2_request_field_group_add_field(group, field)
-+ Gaim2::Request::Field::Group group
-+ Gaim2::Request::Field field
-
- void
--gaim_request_field_group_destroy(group)
-- Gaim::Request::Field::Group group
-+gaim2_request_field_group_destroy(group)
-+ Gaim2::Request::Field::Group group
-
- void
--gaim_request_field_group_get_fields(group)
-- Gaim::Request::Field::Group group
-+gaim2_request_field_group_get_fields(group)
-+ Gaim2::Request::Field::Group group
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_request_field_group_get_fields(group); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_request_field_group_get_fields(group); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
-
- const char *
--gaim_request_field_group_get_title(group)
-- Gaim::Request::Field::Group group
-+gaim2_request_field_group_get_title(group)
-+ Gaim2::Request::Field::Group group
-
--Gaim::Request::Field::Group
--gaim_request_field_group_new(title)
-+Gaim2::Request::Field::Group
-+gaim2_request_field_group_new(title)
- const char *title
-
- int
--gaim_request_field_int_get_default_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_int_get_default_value(field)
-+ Gaim2::Request::Field field
-
- int
--gaim_request_field_int_get_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_int_get_value(field)
-+ Gaim2::Request::Field field
-
--Gaim::Request::Field
--gaim_request_field_int_new(id, text, default_value)
-+Gaim2::Request::Field
-+gaim2_request_field_int_new(id, text, default_value)
- const char *id
- const char *text
- int default_value
-
- void
--gaim_request_field_int_set_default_value(field, default_value)
-- Gaim::Request::Field field
-+gaim2_request_field_int_set_default_value(field, default_value)
-+ Gaim2::Request::Field field
- int default_value
-
- void
--gaim_request_field_int_set_value(field, value)
-- Gaim::Request::Field field
-+gaim2_request_field_int_set_value(field, value)
-+ Gaim2::Request::Field field
- int value
-
- gboolean
--gaim_request_field_is_required(field)
-- Gaim::Request::Field field
-+gaim2_request_field_is_required(field)
-+ Gaim2::Request::Field field
-
- gboolean
--gaim_request_field_is_visible(field)
-- Gaim::Request::Field field
-+gaim2_request_field_is_visible(field)
-+ Gaim2::Request::Field field
-
--Gaim::Request::Field
--gaim_request_field_label_new(id, text)
-+Gaim2::Request::Field
-+gaim2_request_field_label_new(id, text)
- const char *id
- const char *text
-
- void
--gaim_request_field_list_add(field, item, data)
-- Gaim::Request::Field field
-+gaim2_request_field_list_add(field, item, data)
-+ Gaim2::Request::Field field
- const char *item
- void * data
-
- void
--gaim_request_field_list_add_selected(field, item)
-- Gaim::Request::Field field
-+gaim2_request_field_list_add_selected(field, item)
-+ Gaim2::Request::Field field
- const char *item
-
- void
--gaim_request_field_list_clear_selected(field)
-- Gaim::Request::Field field
-+gaim2_request_field_list_clear_selected(field)
-+ Gaim2::Request::Field field
-
- void *
--gaim_request_field_list_get_data(field, text)
-- Gaim::Request::Field field
-+gaim2_request_field_list_get_data(field, text)
-+ Gaim2::Request::Field field
- const char *text
-
- void
--gaim_request_field_list_get_items(field)
-- Gaim::Request::Field field
-+gaim2_request_field_list_get_items(field)
-+ Gaim2::Request::Field field
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_request_field_list_get_items(field); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_request_field_list_get_items(field); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
- gboolean
--gaim_request_field_list_get_multi_select(field)
-- Gaim::Request::Field field
-+gaim2_request_field_list_get_multi_select(field)
-+ Gaim2::Request::Field field
-
- void
--gaim_request_field_list_get_selected(field)
-- Gaim::Request::Field field
-+gaim2_request_field_list_get_selected(field)
-+ Gaim2::Request::Field field
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_request_field_list_get_selected(field); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_request_field_list_get_selected(field); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
- gboolean
--gaim_request_field_list_is_selected(field, item)
-- Gaim::Request::Field field
-+gaim2_request_field_list_is_selected(field, item)
-+ Gaim2::Request::Field field
- const char *item
-
--Gaim::Request::Field
--gaim_request_field_list_new(id, text)
-+Gaim2::Request::Field
-+gaim2_request_field_list_new(id, text)
- const char *id
- const char *text
-
- void
--gaim_request_field_list_set_multi_select(field, multi_select)
-- Gaim::Request::Field field
-+gaim2_request_field_list_set_multi_select(field, multi_select)
-+ Gaim2::Request::Field field
- gboolean multi_select
-
--Gaim::Request::Field
--gaim_request_field_new(id, text, type)
-+Gaim2::Request::Field
-+gaim2_request_field_new(id, text, type)
- const char *id
- const char *text
-- Gaim::RequestFieldType type
-+ Gaim2::RequestFieldType type
-
- void
--gaim_request_field_set_label(field, label)
-- Gaim::Request::Field field
-+gaim2_request_field_set_label(field, label)
-+ Gaim2::Request::Field field
- const char *label
-
- void
--gaim_request_field_set_required(field, required)
-- Gaim::Request::Field field
-+gaim2_request_field_set_required(field, required)
-+ Gaim2::Request::Field field
- gboolean required
-
- void
--gaim_request_field_set_type_hint(field, type_hint)
-- Gaim::Request::Field field
-+gaim2_request_field_set_type_hint(field, type_hint)
-+ Gaim2::Request::Field field
- const char *type_hint
-
- void
--gaim_request_field_set_visible(field, visible)
-- Gaim::Request::Field field
-+gaim2_request_field_set_visible(field, visible)
-+ Gaim2::Request::Field field
- gboolean visible
-
- const char *
--gaim_request_field_string_get_default_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_string_get_default_value(field)
-+ Gaim2::Request::Field field
-
- const char *
--gaim_request_field_string_get_value(field)
-- Gaim::Request::Field field
-+gaim2_request_field_string_get_value(field)
-+ Gaim2::Request::Field field
-
- gboolean
--gaim_request_field_string_is_editable(field)
-- Gaim::Request::Field field
-+gaim2_request_field_string_is_editable(field)
-+ Gaim2::Request::Field field
-
- gboolean
--gaim_request_field_string_is_masked(field)
-- Gaim::Request::Field field
-+gaim2_request_field_string_is_masked(field)
-+ Gaim2::Request::Field field
-
- gboolean
--gaim_request_field_string_is_multiline(field)
-- Gaim::Request::Field field
-+gaim2_request_field_string_is_multiline(field)
-+ Gaim2::Request::Field field
-
--Gaim::Request::Field
--gaim_request_field_string_new(id, text, default_value, multiline)
-+Gaim2::Request::Field
-+gaim2_request_field_string_new(id, text, default_value, multiline)
- const char *id
- const char *text
- const char *default_value
- gboolean multiline
-
- void
--gaim_request_field_string_set_default_value(field, default_value)
-- Gaim::Request::Field field
-+gaim2_request_field_string_set_default_value(field, default_value)
-+ Gaim2::Request::Field field
- const char *default_value
-
- void
--gaim_request_field_string_set_editable(field, editable)
-- Gaim::Request::Field field
-+gaim2_request_field_string_set_editable(field, editable)
-+ Gaim2::Request::Field field
- gboolean editable
-
- void
--gaim_request_field_string_set_masked(field, masked)
-- Gaim::Request::Field field
-+gaim2_request_field_string_set_masked(field, masked)
-+ Gaim2::Request::Field field
- gboolean masked
-
- void
--gaim_request_field_string_set_value(field, value)
-- Gaim::Request::Field field
-+gaim2_request_field_string_set_value(field, value)
-+ Gaim2::Request::Field field
- const char *value
-
- void
--gaim_request_fields_add_group(fields, group)
-- Gaim::Request::Fields fields
-- Gaim::Request::Field::Group group
-+gaim2_request_fields_add_group(fields, group)
-+ Gaim2::Request::Fields fields
-+ Gaim2::Request::Field::Group group
-
- gboolean
--gaim_request_fields_all_required_filled(fields)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_all_required_filled(fields)
-+ Gaim2::Request::Fields fields
-
- void
--gaim_request_fields_destroy(fields)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_destroy(fields)
-+ Gaim2::Request::Fields fields
-
- gboolean
--gaim_request_fields_exists(fields, id)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_exists(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
--Gaim::Account
--gaim_request_fields_get_account(fields, id)
-- Gaim::Request::Fields fields
-+Gaim2::Account
-+gaim2_request_fields_get_account(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
- gboolean
--gaim_request_fields_get_bool(fields, id)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_get_bool(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
- int
--gaim_request_fields_get_choice(fields, id)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_get_choice(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
--Gaim::Request::Field
--gaim_request_fields_get_field(fields, id)
-- Gaim::Request::Fields fields
-+Gaim2::Request::Field
-+gaim2_request_fields_get_field(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
- void
--gaim_request_fields_get_groups(fields)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_get_groups(fields)
-+ Gaim2::Request::Fields fields
- PREINIT:
- GList *l;
- PPCODE:
-- for (l = gaim_request_fields_get_groups(fields); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_request_fields_get_groups(fields); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
-
- int
--gaim_request_fields_get_integer(fields, id)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_get_integer(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
- void
--gaim_request_fields_get_required(fields)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_get_required(fields)
-+ Gaim2::Request::Fields fields
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_request_fields_get_required(fields); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_request_fields_get_required(fields); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
-
- const char *
--gaim_request_fields_get_string(fields, id)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_get_string(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
- gboolean
--gaim_request_fields_is_field_required(fields, id)
-- Gaim::Request::Fields fields
-+gaim2_request_fields_is_field_required(fields, id)
-+ Gaim2::Request::Fields fields
- const char *id
-
--Gaim::Request::Fields
--gaim_request_fields_new()
-+Gaim2::Request::Fields
-+gaim2_request_fields_new()
-
-
--Gaim::Request::UiOps
--gaim_request_get_ui_ops()
-+Gaim2::Request::UiOps
-+gaim2_request_get_ui_ops()
-
-
- void
--gaim_request_set_ui_ops(ops)
-- Gaim::Request::UiOps ops
-+gaim2_request_set_ui_ops(ops)
-+ Gaim2::Request::UiOps ops
-
-diff -prNu ./plugins/perl/common/Roomlist.xs ./plugins/perl/common/Roomlist.xs
---- ./plugins/perl/common/Roomlist.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/Roomlist.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,56 +1,56 @@
- #include "module.h"
-
--MODULE = Gaim::Roomlist PACKAGE = Gaim::Roomlist PREFIX = gaim_roomlist_
-+MODULE = Gaim2::Roomlist PACKAGE = Gaim2::Roomlist PREFIX = gaim2_roomlist_
- PROTOTYPES: ENABLE
-
- void
--gaim_roomlist_cancel_get_list(list)
-- Gaim::Roomlist list
-+gaim2_roomlist_cancel_get_list(list)
-+ Gaim2::Roomlist list
-
- void
--gaim_roomlist_expand_category(list, category)
-- Gaim::Roomlist list
-- Gaim::Roomlist::Room category
-+gaim2_roomlist_expand_category(list, category)
-+ Gaim2::Roomlist list
-+ Gaim2::Roomlist::Room category
-
- gboolean
--gaim_roomlist_get_in_progress(list)
-- Gaim::Roomlist list
-+gaim2_roomlist_get_in_progress(list)
-+ Gaim2::Roomlist list
-
--Gaim::Roomlist
--gaim_roomlist_get_list(gc)
-- Gaim::Connection gc
-+Gaim2::Roomlist
-+gaim2_roomlist_get_list(gc)
-+ Gaim2::Connection gc
-
--Gaim::Roomlist::UiOps
--gaim_roomlist_get_ui_ops()
-+Gaim2::Roomlist::UiOps
-+gaim2_roomlist_get_ui_ops()
-
-
--Gaim::Roomlist
--gaim_roomlist_new(account)
-- Gaim::Account account
-+Gaim2::Roomlist
-+gaim2_roomlist_new(account)
-+ Gaim2::Account account
-
- void
--gaim_roomlist_ref(list)
-- Gaim::Roomlist list
-+gaim2_roomlist_ref(list)
-+ Gaim2::Roomlist list
-
- void
--gaim_roomlist_room_add(list, room)
-- Gaim::Roomlist list
-- Gaim::Roomlist::Room room
-+gaim2_roomlist_room_add(list, room)
-+ Gaim2::Roomlist list
-+ Gaim2::Roomlist::Room room
-
- void
--gaim_roomlist_room_add_field(list, room, field)
-- Gaim::Roomlist list
-- Gaim::Roomlist::Room room
-+gaim2_roomlist_room_add_field(list, room, field)
-+ Gaim2::Roomlist list
-+ Gaim2::Roomlist::Room room
- gconstpointer field
-
- void
--gaim_roomlist_room_join(list, room)
-- Gaim::Roomlist list
-- Gaim::Roomlist::Room room
-+gaim2_roomlist_room_join(list, room)
-+ Gaim2::Roomlist list
-+ Gaim2::Roomlist::Room room
-
- void
--gaim_roomlist_set_fields(list, fields)
-- Gaim::Roomlist list
-+gaim2_roomlist_set_fields(list, fields)
-+ Gaim2::Roomlist list
- SV *fields
- PREINIT:
- GList *t_GL;
-@@ -63,22 +63,22 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(fields), i, 0), t_sl));
- }
-- gaim_roomlist_set_fields(list, t_GL);
-+ gaim2_roomlist_set_fields(list, t_GL);
-
- void
--gaim_roomlist_set_in_progress(list, in_progress)
-- Gaim::Roomlist list
-+gaim2_roomlist_set_in_progress(list, in_progress)
-+ Gaim2::Roomlist list
- gboolean in_progress
-
- void
--gaim_roomlist_set_ui_ops(ops)
-- Gaim::Roomlist::UiOps ops
-+gaim2_roomlist_set_ui_ops(ops)
-+ Gaim2::Roomlist::UiOps ops
-
- void
--gaim_roomlist_show_with_account(account)
-- Gaim::Account account
-+gaim2_roomlist_show_with_account(account)
-+ Gaim2::Account account
-
- void
--gaim_roomlist_unref(list)
-- Gaim::Roomlist list
-+gaim2_roomlist_unref(list)
-+ Gaim2::Roomlist list
-
-diff -prNu ./plugins/perl/common/SavedStatuses.xs ./plugins/perl/common/SavedStatuses.xs
---- ./plugins/perl/common/SavedStatuses.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/SavedStatuses.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,60 +1,60 @@
- #include "module.h"
-
--MODULE = Gaim::SavedStatus PACKAGE = Gaim::SavedStatus PREFIX = gaim_savedstatus_
-+MODULE = Gaim2::SavedStatus PACKAGE = Gaim2::SavedStatus PREFIX = gaim2_savedstatus_
- PROTOTYPES: ENABLE
-
- void *
--gaim_savedstatuses_get_handle()
-+gaim2_savedstatuses_get_handle()
-
-
- gboolean
--gaim_savedstatus_delete(title)
-+gaim2_savedstatus_delete(title)
- const char *title
-
--Gaim::SavedStatus
--gaim_savedstatus_find(title)
-+Gaim2::SavedStatus
-+gaim2_savedstatus_find(title)
- const char *title
-
- const char *
--gaim_savedstatus_get_message(saved_status)
-- Gaim::SavedStatus saved_status
-+gaim2_savedstatus_get_message(saved_status)
-+ Gaim2::SavedStatus saved_status
-
- const char *
--gaim_savedstatus_get_title(saved_status)
-- Gaim::SavedStatus saved_status
-+gaim2_savedstatus_get_title(saved_status)
-+ Gaim2::SavedStatus saved_status
-
--Gaim::StatusPrimitive
--gaim_savedstatus_get_type(saved_status)
-- Gaim::SavedStatus saved_status
-+Gaim2::StatusPrimitive
-+gaim2_savedstatus_get_type(saved_status)
-+ Gaim2::SavedStatus saved_status
-
--Gaim::SavedStatus
--gaim_savedstatus_new(title, type)
-+Gaim2::SavedStatus
-+gaim2_savedstatus_new(title, type)
- const char *title
-- Gaim::StatusPrimitive type
-+ Gaim2::StatusPrimitive type
-
- void
--gaim_savedstatus_set_message(status, message)
-- Gaim::SavedStatus status
-+gaim2_savedstatus_set_message(status, message)
-+ Gaim2::SavedStatus status
- const char *message
-
--MODULE = Gaim::SavedStatus PACKAGE = Gaim::SavedStatuses PREFIX = gaim_savedstatuses_
-+MODULE = Gaim2::SavedStatus PACKAGE = Gaim2::SavedStatuses PREFIX = gaim2_savedstatuses_
- PROTOTYPES: ENABLE
-
- void
--gaim_savedstatuses_get_all()
-+gaim2_savedstatuses_get_all()
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_savedstatuses_get_all(); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_savedstatuses_get_all(); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
-
- void
--gaim_savedstatuses_init()
-+gaim2_savedstatuses_init()
-
-
- void
--gaim_savedstatuses_uninit()
-+gaim2_savedstatuses_uninit()
-
-
-diff -prNu ./plugins/perl/common/Server.xs ./plugins/perl/common/Server.xs
---- ./plugins/perl/common/Server.xs 2005-11-24 21:47:46.000000000 +0100
-+++ ./plugins/perl/common/Server.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,72 +1,72 @@
- #include "module.h"
-
--MODULE = Gaim::Serv PACKAGE = Gaim::Serv PREFIX = serv_
-+MODULE = Gaim2::Serv PACKAGE = Gaim2::Serv PREFIX = serv_
- PROTOTYPES: ENABLE
-
-
- void
- serv_add_deny(con, a)
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
-
- void
- serv_add_permit(a, b)
-- Gaim::Connection a
-+ Gaim2::Connection a
- const char * b
-
- void
- serv_alias_buddy(buddy)
-- Gaim::BuddyList::Buddy buddy
-+ Gaim2::BuddyList::Buddy buddy
-
- void
- serv_chat_invite(con, a, b, c)
-- Gaim::Connection con
-+ Gaim2::Connection con
- int a
- const char * b
- const char * c
-
- void
- serv_chat_leave(a, b)
-- Gaim::Connection a
-+ Gaim2::Connection a
- int b
-
- int
- serv_chat_send(con, a, b, flags)
-- Gaim::Connection con
-+ Gaim2::Connection con
- int a
- const char * b
-- Gaim::MessageFlags flags
-+ Gaim2::MessageFlags flags
-
- void
- serv_chat_whisper(con, a, b, c)
-- Gaim::Connection con
-+ Gaim2::Connection con
- int a
- const char * b
- const char * c
-
- void
- serv_get_info(con, a)
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
-
- void
- serv_got_alias(gc, who, alias)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *who
- const char *alias
-
- void
- serv_got_chat_in(g, id, who, chatflags, message, mtime)
-- Gaim::Connection g
-+ Gaim2::Connection g
- int id
- const char *who
-- Gaim::MessageFlags chatflags
-+ Gaim2::MessageFlags chatflags
- const char *message
- time_t mtime
-
- void
- serv_got_chat_invite(gc, name, who, message, components)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *name
- const char *who
- const char *message
-@@ -93,38 +93,38 @@ CODE:
-
- void
- serv_got_chat_left(g, id)
-- Gaim::Connection g
-+ Gaim2::Connection g
- int id
-
- void
- serv_got_im(gc, who, msg, imflags, mtime)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *who
- const char *msg
-- Gaim::MessageFlags imflags
-+ Gaim2::MessageFlags imflags
- time_t mtime
-
--Gaim::Conversation
-+Gaim2::Conversation
- serv_got_joined_chat(gc, id, name)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- int id
- const char *name
-
- void
- serv_got_typing(gc, name, timeout, state)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *name
- int timeout
-- Gaim::TypingState state
-+ Gaim2::TypingState state
-
- void
- serv_got_typing_stopped(gc, name)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *name
-
- void
- serv_join_chat(con, components)
-- Gaim::Connection con
-+ Gaim2::Connection con
- SV * components
- INIT:
- HV * t_HV;
-@@ -148,13 +148,13 @@ CODE:
-
- void
- serv_move_buddy(buddy, group1, group2)
-- Gaim::BuddyList::Buddy buddy
-- Gaim::BuddyList::Group group1
-- Gaim::BuddyList::Group group2
-+ Gaim2::BuddyList::Buddy buddy
-+ Gaim2::BuddyList::Group group1
-+ Gaim2::BuddyList::Group group2
-
- void
- serv_reject_chat(con, components)
-- Gaim::Connection con
-+ Gaim2::Connection con
- SV * components
- INIT:
- HV * t_HV;
-@@ -178,44 +178,44 @@ CODE:
-
- void
- serv_rem_deny(con, a)
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
-
- void
- serv_rem_permit(con, a)
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
-
- void
- serv_send_file(gc, who, file)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *who
- const char *file
-
- int
- serv_send_im(con, a, b, flags )
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
- const char * b
-- Gaim::MessageFlags flags
-+ Gaim2::MessageFlags flags
-
- int
- serv_send_typing(con, a, b)
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
- int b
-
- void
- serv_set_buddyicon(gc, filename)
-- Gaim::Connection gc
-+ Gaim2::Connection gc
- const char *filename
-
- void
- serv_set_info(con, a)
-- Gaim::Connection con
-+ Gaim2::Connection con
- const char * a
-
- void
- serv_set_permit_deny(con)
-- Gaim::Connection con
-+ Gaim2::Connection con
-
-diff -prNu ./plugins/perl/common/Sound.xs ./plugins/perl/common/Sound.xs
---- ./plugins/perl/common/Sound.xs 2005-10-12 04:27:32.000000000 +0200
-+++ ./plugins/perl/common/Sound.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,31 +1,31 @@
- #include "module.h"
-
--MODULE = Gaim::Sound PACKAGE = Gaim::Sound PREFIX = gaim_sound_
-+MODULE = Gaim2::Sound PACKAGE = Gaim2::Sound PREFIX = gaim2_sound_
- PROTOTYPES: ENABLE
-
--Gaim::Sound::UiOps
--gaim_sound_get_ui_ops()
-+Gaim2::Sound::UiOps
-+gaim2_sound_get_ui_ops()
-
-
- void
--gaim_sound_init()
-+gaim2_sound_init()
-
-
- void
--gaim_sound_play_event(event, account)
-- Gaim::SoundEventID event
-- Gaim::Account account
-+gaim2_sound_play_event(event, account)
-+ Gaim2::SoundEventID event
-+ Gaim2::Account account
-
- void
--gaim_sound_play_file(filename, account)
-+gaim2_sound_play_file(filename, account)
- const char *filename
-- Gaim::Account account
-+ Gaim2::Account account
-
- void
--gaim_sound_set_ui_ops(ops)
-- Gaim::Sound::UiOps ops
-+gaim2_sound_set_ui_ops(ops)
-+ Gaim2::Sound::UiOps ops
-
- void
--gaim_sound_uninit()
-+gaim2_sound_uninit()
-
-
-diff -prNu ./plugins/perl/common/SSLConn.xs ./plugins/perl/common/SSLConn.xs
---- ./plugins/perl/common/SSLConn.xs 2005-08-18 03:35:14.000000000 +0200
-+++ ./plugins/perl/common/SSLConn.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -3,24 +3,24 @@
- /* TODO
-
-
--Gaim::Ssl::Connection
--gaim_ssl_connect(account, host, port, func, error_func, data)
-- Gaim::Account account
-+Gaim2::Ssl::Connection
-+gaim2_ssl_connect(account, host, port, func, error_func, data)
-+ Gaim2::Account account
- const char *host
- int port
- GaimSslInputFunction func
- GaimSslErrorFunction error_func
-
- void
--gaim_ssl_input_add(gsc, func, data)
-- Gaim::Ssl::Connection gsc
-- Gaim::SslInputFunction func
-+gaim2_ssl_input_add(gsc, func, data)
-+ Gaim2::Ssl::Connection gsc
-+ Gaim2::SslInputFunction func
-
-
-
--Gaim::Ssl::Connection
--gaim_ssl_connect_fd(account, fd, func, error_func, data)
-- Gaim::Account account
-+Gaim2::Ssl::Connection
-+gaim2_ssl_connect_fd(account, fd, func, error_func, data)
-+ Gaim2::Account account
- int fd
- GaimSslInputFunction func
- GaimSslErrorFunction error_func
-@@ -29,47 +29,47 @@ gaim_ssl_connect_fd(account, fd, func, e
-
- */
-
--MODULE = Gaim::SSL PACKAGE = Gaim::SSL PREFIX = gaim_ssl_
-+MODULE = Gaim2::SSL PACKAGE = Gaim2::SSL PREFIX = gaim2_ssl_
- PROTOTYPES: ENABLE
-
-
-
- void
--gaim_ssl_close(gsc)
-- Gaim::Ssl::Connection gsc
-+gaim2_ssl_close(gsc)
-+ Gaim2::Ssl::Connection gsc
-
-
-
--Gaim::Ssl::Ops
--gaim_ssl_get_ops()
-+Gaim2::Ssl::Ops
-+gaim2_ssl_get_ops()
-
-
- void
--gaim_ssl_init()
-+gaim2_ssl_init()
-
-
-
- gboolean
--gaim_ssl_is_supported()
-+gaim2_ssl_is_supported()
-
-
- size_t
--gaim_ssl_read(gsc, buffer, len)
-- Gaim::Ssl::Connection gsc
-+gaim2_ssl_read(gsc, buffer, len)
-+ Gaim2::Ssl::Connection gsc
- void * buffer
- size_t len
-
- void
--gaim_ssl_set_ops(ops)
-- Gaim::Ssl::Ops ops
-+gaim2_ssl_set_ops(ops)
-+ Gaim2::Ssl::Ops ops
-
- void
--gaim_ssl_uninit()
-+gaim2_ssl_uninit()
-
-
- size_t
--gaim_ssl_write(gsc, buffer, len)
-- Gaim::Ssl::Connection gsc
-+gaim2_ssl_write(gsc, buffer, len)
-+ Gaim2::Ssl::Connection gsc
- void * buffer
- size_t len
-
-diff -prNu ./plugins/perl/common/Status.xs ./plugins/perl/common/Status.xs
---- ./plugins/perl/common/Status.xs 2005-10-02 20:28:29.000000000 +0200
-+++ ./plugins/perl/common/Status.xs 2006-01-05 15:25:40.000000000 +0100
-@@ -4,17 +4,17 @@
-
-
- void
--gaim_status_type_add_attrs(status_type, id, name, value, gaim_status_type_add_attrs)
-- Gaim::StatusType status_type
-+gaim2_status_type_add_attrs(status_type, id, name, value, gaim2_status_type_add_attrs)
-+ Gaim2::StatusType status_type
- const char *id
- const char *name
-- Gaim::Value value
-+ Gaim2::Value value
- ...
-
-
--Gaim::StatusType
--gaim_status_type_new_with_attrs(primitive, id, name, saveable, user_settable, independent, attr_id, attr_name, attr_value, gaim_status_type_new_with_attrs)
-- Gaim::StatusPrimitive primitive
-+Gaim2::StatusType
-+gaim2_status_type_new_with_attrs(primitive, id, name, saveable, user_settable, independent, attr_id, attr_name, attr_value, gaim2_status_type_new_with_attrs)
-+ Gaim2::StatusPrimitive primitive
- const char *id
- const char *name
- gboolean saveable
-@@ -22,32 +22,32 @@ gaim_status_type_new_with_attrs(primitiv
- gboolean independent
- const char *attr_id
- const char *attr_name
-- Gaim::Value attr_value
-+ Gaim2::Value attr_value
- ...
-
- */
-
- /* These break on faceprint's amd64 box
- void
--gaim_status_type_add_attrs_vargs(status_type, args)
-- Gaim::StatusType status_type
-+gaim2_status_type_add_attrs_vargs(status_type, args)
-+ Gaim2::StatusType status_type
- va_list args
-
- void
--gaim_status_set_active_with_attrs(status, active, args)
-- Gaim::Status status
-+gaim2_status_set_active_with_attrs(status, active, args)
-+ Gaim2::Status status
- gboolean active
- va_list args
-
- */
-
-
--MODULE = Gaim::Status PACKAGE = Gaim::Presence PREFIX = gaim_presence_
-+MODULE = Gaim2::Status PACKAGE = Gaim2::Presence PREFIX = gaim2_presence_
- PROTOTYPES: ENABLE
-
- void
--gaim_presence_add_list(presence, source_list)
-- Gaim::Presence presence
-+gaim2_presence_add_list(presence, source_list)
-+ Gaim2::Presence presence
- SV *source_list
- PREINIT:
- GList *t_GL;
-@@ -60,286 +60,286 @@ PPCODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(source_list), i, 0), t_sl));
- }
-- gaim_presence_add_list(presence, t_GL);
-+ gaim2_presence_add_list(presence, t_GL);
-
- void
--gaim_presence_add_status(presence, status)
-- Gaim::Presence presence
-- Gaim::Status status
-+gaim2_presence_add_status(presence, status)
-+ Gaim2::Presence presence
-+ Gaim2::Status status
-
- gint
--gaim_presence_compare(presence1, presence2)
-- Gaim::Presence presence1
-- Gaim::Presence presence2
-+gaim2_presence_compare(presence1, presence2)
-+ Gaim2::Presence presence1
-+ Gaim2::Presence presence2
-
- void
--gaim_presence_destroy(presence)
-- Gaim::Presence presence
-+gaim2_presence_destroy(presence)
-+ Gaim2::Presence presence
-
--Gaim::Account
--gaim_presence_get_account(presence)
-- Gaim::Presence presence
-+Gaim2::Account
-+gaim2_presence_get_account(presence)
-+ Gaim2::Presence presence
-
--Gaim::Status
--gaim_presence_get_active_status(presence)
-- Gaim::Presence presence
-+Gaim2::Status
-+gaim2_presence_get_active_status(presence)
-+ Gaim2::Presence presence
-
- void
--gaim_presence_get_buddies(presence)
-- Gaim::Presence presence
-+gaim2_presence_get_buddies(presence)
-+ Gaim2::Presence presence
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_presence_get_buddies(presence); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_presence_get_buddies(presence); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
- const char *
--gaim_presence_get_chat_user(presence)
-- Gaim::Presence presence
-+gaim2_presence_get_chat_user(presence)
-+ Gaim2::Presence presence
-
--Gaim::PresenceContext
--gaim_presence_get_context(presence)
-- Gaim::Presence presence
--
--Gaim::Conversation
--gaim_presence_get_conversation(presence)
-- Gaim::Presence presence
-+Gaim2::PresenceContext
-+gaim2_presence_get_context(presence)
-+ Gaim2::Presence presence
-+
-+Gaim2::Conversation
-+gaim2_presence_get_conversation(presence)
-+ Gaim2::Presence presence
-
- time_t
--gaim_presence_get_idle_time(presence)
-- Gaim::Presence presence
-+gaim2_presence_get_idle_time(presence)
-+ Gaim2::Presence presence
-
- time_t
--gaim_presence_get_login_time(presence)
-- Gaim::Presence presence
-+gaim2_presence_get_login_time(presence)
-+ Gaim2::Presence presence
-
--Gaim::Status
--gaim_presence_get_status(presence, status_id)
-- Gaim::Presence presence
-+Gaim2::Status
-+gaim2_presence_get_status(presence, status_id)
-+ Gaim2::Presence presence
- const char *status_id
-
- void
--gaim_presence_get_statuses(presence)
-- Gaim::Presence presence
-+gaim2_presence_get_statuses(presence)
-+ Gaim2::Presence presence
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_presence_get_statuses(presence); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_presence_get_statuses(presence); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
- gboolean
--gaim_presence_is_available(presence)
-- Gaim::Presence presence
-+gaim2_presence_is_available(presence)
-+ Gaim2::Presence presence
-
- gboolean
--gaim_presence_is_idle(presence)
-- Gaim::Presence presence
-+gaim2_presence_is_idle(presence)
-+ Gaim2::Presence presence
-
- gboolean
--gaim_presence_is_online(presence)
-- Gaim::Presence presence
-+gaim2_presence_is_online(presence)
-+ Gaim2::Presence presence
-
- gboolean
--gaim_presence_is_status_active(presence, status_id)
-- Gaim::Presence presence
-+gaim2_presence_is_status_active(presence, status_id)
-+ Gaim2::Presence presence
- const char *status_id
-
- gboolean
--gaim_presence_is_status_primitive_active(presence, primitive)
-- Gaim::Presence presence
-- Gaim::StatusPrimitive primitive
-+gaim2_presence_is_status_primitive_active(presence, primitive)
-+ Gaim2::Presence presence
-+ Gaim2::StatusPrimitive primitive
-
--Gaim::Presence
--gaim_presence_new(context)
-- Gaim::PresenceContext context
-+Gaim2::Presence
-+gaim2_presence_new(context)
-+ Gaim2::PresenceContext context
-
--Gaim::Presence
--gaim_presence_new_for_account(account)
-- Gaim::Account account
-+Gaim2::Presence
-+gaim2_presence_new_for_account(account)
-+ Gaim2::Account account
-
--Gaim::Presence
--gaim_presence_new_for_buddy(buddy)
-- Gaim::BuddyList::Buddy buddy
-+Gaim2::Presence
-+gaim2_presence_new_for_buddy(buddy)
-+ Gaim2::BuddyList::Buddy buddy
-
--Gaim::Presence
--gaim_presence_new_for_conv(conv)
-- Gaim::Conversation conv
-+Gaim2::Presence
-+gaim2_presence_new_for_conv(conv)
-+ Gaim2::Conversation conv
-
- void
--gaim_presence_remove_buddy(presence, buddy)
-- Gaim::Presence presence
-- Gaim::BuddyList::Buddy buddy
-+gaim2_presence_remove_buddy(presence, buddy)
-+ Gaim2::Presence presence
-+ Gaim2::BuddyList::Buddy buddy
-
- void
--gaim_presence_set_idle(presence, idle, idle_time)
-- Gaim::Presence presence
-+gaim2_presence_set_idle(presence, idle, idle_time)
-+ Gaim2::Presence presence
- gboolean idle
- time_t idle_time
-
- void
--gaim_presence_set_login_time(presence, login_time)
-- Gaim::Presence presence
-+gaim2_presence_set_login_time(presence, login_time)
-+ Gaim2::Presence presence
- time_t login_time
-
- void
--gaim_presence_set_status_active(presence, status_id, active)
-- Gaim::Presence presence
-+gaim2_presence_set_status_active(presence, status_id, active)
-+ Gaim2::Presence presence
- const char *status_id
- gboolean active
-
- void
--gaim_presence_switch_status(presence, status_id)
-- Gaim::Presence presence
-+gaim2_presence_switch_status(presence, status_id)
-+ Gaim2::Presence presence
- const char *status_id
-
- const char *
--gaim_primitive_get_id_from_type(type)
-- Gaim::StatusPrimitive type
-+gaim2_primitive_get_id_from_type(type)
-+ Gaim2::StatusPrimitive type
-
- const char *
--gaim_primitive_get_name_from_type(type)
-- Gaim::StatusPrimitive type
-+gaim2_primitive_get_name_from_type(type)
-+ Gaim2::StatusPrimitive type
-
--Gaim::StatusPrimitive
--gaim_primitive_get_type_from_id(id)
-+Gaim2::StatusPrimitive
-+gaim2_primitive_get_type_from_id(id)
- const char *id
-
--MODULE = Gaim::Status PACKAGE = Gaim::Status PREFIX = gaim_status_
-+MODULE = Gaim2::Status PACKAGE = Gaim2::Status PREFIX = gaim2_status_
- PROTOTYPES: ENABLE
-
- void
--gaim_status_attr_destroy(attr)
-- Gaim::StatusAttr attr
-+gaim2_status_attr_destroy(attr)
-+ Gaim2::StatusAttr attr
-
- const char *
--gaim_status_attr_get_id(attr)
-- Gaim::StatusAttr attr
-+gaim2_status_attr_get_id(attr)
-+ Gaim2::StatusAttr attr
-
- const char *
--gaim_status_attr_get_name(attr)
-- Gaim::StatusAttr attr
-+gaim2_status_attr_get_name(attr)
-+ Gaim2::StatusAttr attr
-
--Gaim::Value
--gaim_status_attr_get_value(attr)
-- Gaim::StatusAttr attr
-+Gaim2::Value
-+gaim2_status_attr_get_value(attr)
-+ Gaim2::StatusAttr attr
-
--Gaim::StatusAttr
--gaim_status_attr_new(id, name, value_type)
-+Gaim2::StatusAttr
-+gaim2_status_attr_new(id, name, value_type)
- const char *id
- const char *name
-- Gaim::Value value_type
-+ Gaim2::Value value_type
-
- gint
--gaim_status_compare(status1, status2)
-- Gaim::Status status1
-- Gaim::Status status2
-+gaim2_status_compare(status1, status2)
-+ Gaim2::Status status1
-+ Gaim2::Status status2
-
- void
--gaim_status_destroy(status)
-- Gaim::Status status
-+gaim2_status_destroy(status)
-+ Gaim2::Status status
-
- gboolean
--gaim_status_get_attr_boolean(status, id)
-- Gaim::Status status
-+gaim2_status_get_attr_boolean(status, id)
-+ Gaim2::Status status
- const char *id
-
- int
--gaim_status_get_attr_int(status, id)
-- Gaim::Status status
-+gaim2_status_get_attr_int(status, id)
-+ Gaim2::Status status
- const char *id
-
- const char *
--gaim_status_get_attr_string(status, id)
-- Gaim::Status status
-+gaim2_status_get_attr_string(status, id)
-+ Gaim2::Status status
- const char *id
-
--Gaim::Value
--gaim_status_get_attr_value(status, id)
-- Gaim::Status status
-+Gaim2::Value
-+gaim2_status_get_attr_value(status, id)
-+ Gaim2::Status status
- const char *id
-
- void *
--gaim_status_get_handle()
-+gaim2_status_get_handle()
-
-
- const char *
--gaim_status_get_id(status)
-- Gaim::Status status
-+gaim2_status_get_id(status)
-+ Gaim2::Status status
-
- const char *
--gaim_status_get_name(status)
-- Gaim::Status status
-+gaim2_status_get_name(status)
-+ Gaim2::Status status
-
--Gaim::Presence
--gaim_status_get_presence(status)
-- Gaim::Status status
-+Gaim2::Presence
-+gaim2_status_get_presence(status)
-+ Gaim2::Status status
-
--Gaim::StatusType
--gaim_status_get_type(status)
-- Gaim::Status status
-+Gaim2::StatusType
-+gaim2_status_get_type(status)
-+ Gaim2::Status status
-
- void
--gaim_status_init()
-+gaim2_status_init()
-
-
- gboolean
--gaim_status_is_active(status)
-- Gaim::Status status
-+gaim2_status_is_active(status)
-+ Gaim2::Status status
-
- gboolean
--gaim_status_is_available(status)
-- Gaim::Status status
-+gaim2_status_is_available(status)
-+ Gaim2::Status status
-
- gboolean
--gaim_status_is_exclusive(status)
-- Gaim::Status status
-+gaim2_status_is_exclusive(status)
-+ Gaim2::Status status
-
- gboolean
--gaim_status_is_independent(status)
-- Gaim::Status status
-+gaim2_status_is_independent(status)
-+ Gaim2::Status status
-
- gboolean
--gaim_status_is_online(status)
-- Gaim::Status status
-+gaim2_status_is_online(status)
-+ Gaim2::Status status
-
--Gaim::Status
--gaim_status_new(status_type, presence)
-- Gaim::StatusType status_type
-- Gaim::Presence presence
-+Gaim2::Status
-+gaim2_status_new(status_type, presence)
-+ Gaim2::StatusType status_type
-+ Gaim2::Presence presence
-
- void
--gaim_status_set_active(status, active)
-- Gaim::Status status
-+gaim2_status_set_active(status, active)
-+ Gaim2::Status status
- gboolean active
-
- void
--gaim_status_set_attr_boolean(status, id, value)
-- Gaim::Status status
-+gaim2_status_set_attr_boolean(status, id, value)
-+ Gaim2::Status status
- const char *id
- gboolean value
-
- void
--gaim_status_set_attr_string(status, id, value)
-- Gaim::Status status
-+gaim2_status_set_attr_string(status, id, value)
-+ Gaim2::Status status
- const char *id
- const char *value
-
- void
--gaim_status_type_add_attr(status_type, id, name, value)
-- Gaim::StatusType status_type
-+gaim2_status_type_add_attr(status_type, id, name, value)
-+ Gaim2::StatusType status_type
- const char *id
- const char *name
-- Gaim::Value value
-+ Gaim2::Value value
-
-
- void
--gaim_status_type_destroy(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_destroy(status_type)
-+ Gaim2::StatusType status_type
-
--Gaim::StatusType
--gaim_status_type_find_with_id(status_types, id)
-+Gaim2::StatusType
-+gaim2_status_type_find_with_id(status_types, id)
- SV *status_types
- const char *id
- PREINIT:
-@@ -353,71 +353,71 @@ CODE:
- STRLEN t_sl;
- t_GL = g_list_append(t_GL, SvPV(*av_fetch((AV *)SvRV(status_types), i, 0), t_sl));
- }
-- RETVAL = (GaimStatusType *)gaim_status_type_find_with_id(t_GL, id);
-+ RETVAL = (Gaim2StatusType *)gaim2_status_type_find_with_id(t_GL, id);
- OUTPUT:
- RETVAL
-
--Gaim::StatusAttr
--gaim_status_type_get_attr(status_type, id)
-- Gaim::StatusType status_type
-+Gaim2::StatusAttr
-+gaim2_status_type_get_attr(status_type, id)
-+ Gaim2::StatusType status_type
- const char *id
-
- void
--gaim_status_type_get_attrs(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_get_attrs(status_type)
-+ Gaim2::StatusType status_type
- PREINIT:
- const GList *l;
- PPCODE:
-- for (l = gaim_status_type_get_attrs(status_type); l != NULL; l = l->next) {
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::ListItem")));
-+ for (l = gaim2_status_type_get_attrs(status_type); l != NULL; l = l->next) {
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(l->data, "Gaim2::ListItem")));
- }
-
- const char *
--gaim_status_type_get_id(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_get_id(status_type)
-+ Gaim2::StatusType status_type
-
- const char *
--gaim_status_type_get_name(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_get_name(status_type)
-+ Gaim2::StatusType status_type
-
- const char *
--gaim_status_type_get_primary_attr(type)
-- Gaim::StatusType type
-+gaim2_status_type_get_primary_attr(type)
-+ Gaim2::StatusType type
-
--Gaim::StatusPrimitive
--gaim_status_type_get_primitive(status_type)
-- Gaim::StatusType status_type
-+Gaim2::StatusPrimitive
-+gaim2_status_type_get_primitive(status_type)
-+ Gaim2::StatusType status_type
-
- gboolean
--gaim_status_type_is_available(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_is_available(status_type)
-+ Gaim2::StatusType status_type
-
- gboolean
--gaim_status_type_is_exclusive(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_is_exclusive(status_type)
-+ Gaim2::StatusType status_type
-
- gboolean
--gaim_status_type_is_independent(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_is_independent(status_type)
-+ Gaim2::StatusType status_type
-
- gboolean
--gaim_status_type_is_saveable(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_is_saveable(status_type)
-+ Gaim2::StatusType status_type
-
- gboolean
--gaim_status_type_is_user_settable(status_type)
-- Gaim::StatusType status_type
-+gaim2_status_type_is_user_settable(status_type)
-+ Gaim2::StatusType status_type
-
--Gaim::StatusType
--gaim_status_type_new(primitive, id, name, user_settable)
-- Gaim::StatusPrimitive primitive
-+Gaim2::StatusType
-+gaim2_status_type_new(primitive, id, name, user_settable)
-+ Gaim2::StatusPrimitive primitive
- const char *id
- const char *name
- gboolean user_settable
-
--Gaim::StatusType
--gaim_status_type_new_full(primitive, id, name, saveable, user_settable, independent)
-- Gaim::StatusPrimitive primitive
-+Gaim2::StatusType
-+gaim2_status_type_new_full(primitive, id, name, saveable, user_settable, independent)
-+ Gaim2::StatusPrimitive primitive
- const char *id
- const char *name
- gboolean saveable
-@@ -425,11 +425,11 @@ gaim_status_type_new_full(primitive, id,
- gboolean independent
-
- void
--gaim_status_type_set_primary_attr(status_type, attr_id)
-- Gaim::StatusType status_type
-+gaim2_status_type_set_primary_attr(status_type, attr_id)
-+ Gaim2::StatusType status_type
- const char *attr_id
-
- void
--gaim_status_uninit()
-+gaim2_status_uninit()
-
-
-diff -prNu ./plugins/perl/common/Stringref.xs ./plugins/perl/common/Stringref.xs
---- ./plugins/perl/common/Stringref.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/Stringref.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,40 +1,40 @@
- #include "module.h"
-
--MODULE = Gaim::Stringref PACKAGE = Gaim::Stringref PREFIX = gaim_stringref_
-+MODULE = Gaim2::Stringref PACKAGE = Gaim2::Stringref PREFIX = gaim2_stringref_
- PROTOTYPES: ENABLE
-
- int
--gaim_stringref_cmp(s1, s2)
-- Gaim::Stringref s1
-- Gaim::Stringref s2
-+gaim2_stringref_cmp(s1, s2)
-+ Gaim2::Stringref s1
-+ Gaim2::Stringref s2
-
- size_t
--gaim_stringref_len(stringref)
-- Gaim::Stringref stringref
-+gaim2_stringref_len(stringref)
-+ Gaim2::Stringref stringref
-
--Gaim::Stringref
--gaim_stringref_new(class, value)
-+Gaim2::Stringref
-+gaim2_stringref_new(class, value)
- const char *value
- C_ARGS:
- value
-
--Gaim::Stringref
--gaim_stringref_new_noref(class, value)
-+Gaim2::Stringref
-+gaim2_stringref_new_noref(class, value)
- const char *value
- C_ARGS:
- value
-
-
-
--Gaim::Stringref
--gaim_stringref_ref(stringref)
-- Gaim::Stringref stringref
-+Gaim2::Stringref
-+gaim2_stringref_ref(stringref)
-+ Gaim2::Stringref stringref
-
- void
--gaim_stringref_unref(stringref)
-- Gaim::Stringref stringref
-+gaim2_stringref_unref(stringref)
-+ Gaim2::Stringref stringref
-
- const char *
--gaim_stringref_value(stringref)
-- Gaim::Stringref stringref
-+gaim2_stringref_value(stringref)
-+ Gaim2::Stringref stringref
-
-diff -prNu ./plugins/perl/common/typemap ./plugins/perl/common/typemap
---- ./plugins/perl/common/typemap 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/typemap 2006-01-05 15:23:17.000000000 +0100
-@@ -8,7 +8,7 @@ guint8 T_IV
- guint8 * T_PTR
- time_t T_IV
- gboolean T_BOOL
--gpointer T_GaimObj
-+gpointer TGaimObj
- gconstpointer T_PTR
- const gchar * T_PV
- const char * T_PV
-@@ -23,12 +23,12 @@ const guchar * T_PV
- char * T_PV
- int * T_PTR
- size_t * T_PTR
--Gaim::GTK::Widget * T_PTR
-+Gaim2::GTK::Widget * T_PTR
- GCallback T_PTR
- va_list T_PTR
--GString * T_PTR
-+GString * T_PTR
- GData * T_PTR
--GData ** T_PTR
-+GData ** T_PTR
- const unsigned char * T_PTR
- const struct tm * T_PTR
- xmlnode * T_PTR
-@@ -36,141 +36,141 @@ const xmlnode * T_PTR
- gssize T_IV
- const void * T_PTR
-
--Gaim::Account T_GaimObj
--Gaim::Account::Option T_GaimObj
--Gaim::Account::UiOps T_GaimObj
--Gaim::Account::UserSplit T_GaimObj
--
--
--Gaim::BlistNodeFlags T_IV
--Gaim::Buddy::Icon T_GaimObj
--Gaim::Buddy::Icon::Spec T_GaimObj
--Gaim::BuddyList T_GaimObj
--Gaim::BuddyList::Group T_GaimObj
--Gaim::BuddyList::Buddy T_GaimObj
--Gaim::BuddyList::Chat T_GaimObj
--Gaim::BuddyList::Contact T_GaimObj
--Gaim::BuddyList::Node T_GaimObj
--Gaim::BuddyList::Node::Action T_GaimObj
--Gaim::BuddyList::UiOps T_GaimObj
--
--
--Gaim::Cipher T_GaimObj
--Gaim::Cipher::Ops T_GaimObj
--Gaim::Cipher::Context T_GaimObj
--Gaim::CipherCaps T_IV
--Gaim::CmdId T_IV
--Gaim::Connection T_GaimObj
--Gaim::Connection::UiOps T_GaimObj
--Gaim::ConvWindow::UiOps T_GaimObj
--Gaim::Conversation::UiOps T_GaimObj
--Gaim::Conversation T_GaimObj
--Gaim::Conversation::Chat T_GaimObj
--Gaim::Conversation::IM T_GaimObj
--Gaim::ConvWindow T_GaimObj
--Gaim::Conversation::ChatBuddy T_GaimObj
--Gaim::ConvImFlags T_IV
--Gaim::ConvChatFlags T_IV
--
--
--Gaim::Desktop::Item T_GaimObj
--Gaim::DesktopItemType T_IV
--
--
--Gaim::GTK::BuddyList T_GaimObj
--Gaim::GDK::Pixbuf T_GaimObj
--Gaim::GTK::Conversation T_GaimObj
--Gaim::GTK::Widget T_GaimObj
--Gaim::GTK::FileSelection T_GaimObj
--Gaim::GTK::SelectionData T_GaimObj
--Gaim::GTK::TextView T_GaimObj
--
--
--Gaim::IconScaleRules T_IV
--Gaim::IM T_GaimObj
--
--
--Gaim::Log T_GaimObj
--Gaim::Log::Logger T_GaimObj
--Gaim::Log::CommonLoggerData T_GaimObj
--Gaim::Log::Set T_GaimObj
--Gaim::LogType T_IV
--Gaim::Log::ReadFlags T_GaimObj
--
--
--Gaim::NotifyCloseCallback T_PTR
--Gaim::NotifyType T_IV
--Gaim::NotifyMsgType T_IV
--Gaim::NotifySearchButtonType T_IV
--Gaim::NotifySearchResults T_GaimObj
--Gaim::NotifySearchColumn T_GaimObj
--Gaim::NotifySearchButton T_GaimObj
--Gaim::NotifyUiOps T_GaimObj
--
--Gaim::Plugin T_GaimObj
--Gaim::Plugin::Info T_GaimObj
--Gaim::PluginUiInfo T_GaimObj
--Gaim::Plugin::Loader::Info T_GaimObj
--Gaim::Plugin::Action T_GaimObj
--Gaim::Plugin::Protocol::Info T_GaimObj
--Gaim::PluginType T_IV
--Gaim::PrefType T_IV
--Gaim::PluginPref::Frame T_GaimObj
--Gaim::PluginPref T_GaimObj
--Gaim::PluginPrefType T_IV
--Gaim::Pounce T_GaimObj
--Gaim::PounceEvent T_IV
--Gaim::Presence T_GaimObj
--Gaim::PrivacyType T_IV
--Gaim::Privacy::UiOps T_GaimObj
--Gaim::ProtocolOptions T_IV
--Gaim::ProxyType T_IV
--Gaim::ProxyInfo T_GaimObj
--
--
--Gaim::RequestType T_IV
--Gaim::RequestFieldType T_IV
--Gaim::Request::Fields T_GaimObj
--Gaim::Request::Field T_GaimObj
--Gaim::Request::Field::Group T_GaimObj
--Gaim::Request::UiOps T_GaimObj
--
--Gaim::Roomlist T_GaimObj
--Gaim::Roomlist::Room T_GaimObj
--Gaim::Roomlist::Field T_GaimObj
--Gaim::Roomlist::UiOps T_GaimObj
--Gaim::RoomlistRoomType T_IV
--Gaim::RoomlistFieldType T_IV
--
--Gaim::SavedStatus T_GaimObj
--Gaim::SavedStatusSub T_GaimObj
--Gaim::SoundEventID T_IV
--Gaim::Sound::UiOps T_GaimObj
--
--Gaim::Ssl::Connection T_GaimObj
--Gaim::Input::Condition T_GaimObj
--Gaim::SslErrorType T_IV
--Gaim::Ssl::Ops T_GaimObj
--
--Gaim::Status T_GaimObj
--Gaim::StatusType T_GaimObj
--const Gaim::StatusType T_GaimObj
--Gaim::StatusAttr T_GaimObj
--Gaim::Presence T_GaimObj
--Gaim::PresenceContext T_IV
--Gaim::StatusPrimitive T_IV
--
--
--Gaim::StoredImage T_GaimObj
--Gaim::Stringref T_GaimObj
--Gaim::Value T_GaimObj
--
--Gaim::Xfer T_GaimObj
--Gaim::XferType T_IV
--Gaim::XferStatusType T_IV
--Gaim::XferUiOps T_IV
-+Gaim2::Account TGaimObj
-+Gaim2::Account::Option TGaimObj
-+Gaim2::Account::UiOps TGaimObj
-+Gaim2::Account::UserSplit TGaimObj
-+
-+
-+Gaim2::BlistNodeFlags T_IV
-+Gaim2::Buddy::Icon TGaimObj
-+Gaim2::Buddy::Icon::Spec TGaimObj
-+Gaim2::BuddyList TGaimObj
-+Gaim2::BuddyList::Group TGaimObj
-+Gaim2::BuddyList::Buddy TGaimObj
-+Gaim2::BuddyList::Chat TGaimObj
-+Gaim2::BuddyList::Contact TGaimObj
-+Gaim2::BuddyList::Node TGaimObj
-+Gaim2::BuddyList::Node::Action TGaimObj
-+Gaim2::BuddyList::UiOps TGaimObj
-+
-+
-+Gaim2::Cipher TGaimObj
-+Gaim2::Cipher::Ops TGaimObj
-+Gaim2::Cipher::Context TGaimObj
-+Gaim2::CipherCaps T_IV
-+Gaim2::CmdId T_IV
-+Gaim2::Connection TGaimObj
-+Gaim2::Connection::UiOps TGaimObj
-+Gaim2::ConvWindow::UiOps TGaimObj
-+Gaim2::Conversation::UiOps TGaimObj
-+Gaim2::Conversation TGaimObj
-+Gaim2::Conversation::Chat TGaimObj
-+Gaim2::Conversation::IM TGaimObj
-+Gaim2::ConvWindow TGaimObj
-+Gaim2::Conversation::ChatBuddy TGaimObj
-+Gaim2::ConvImFlags T_IV
-+Gaim2::ConvChatFlags T_IV
-+
-+
-+Gaim2::Desktop::Item TGaimObj
-+Gaim2::DesktopItemType T_IV
-+
-+
-+Gaim2::GTK::BuddyList TGaimObj
-+Gaim2::GDK::Pixbuf TGaimObj
-+Gaim2::GTK::Conversation TGaimObj
-+Gaim2::GTK::Widget TGaimObj
-+Gaim2::GTK::FileSelection TGaimObj
-+Gaim2::GTK::SelectionData TGaimObj
-+Gaim2::GTK::TextView TGaimObj
-+
-+
-+Gaim2::IconScaleRules T_IV
-+Gaim2::IM TGaimObj
-+
-+
-+Gaim2::Log TGaimObj
-+Gaim2::Log::Logger TGaimObj
-+Gaim2::Log::CommonLoggerData TGaimObj
-+Gaim2::Log::Set TGaimObj
-+Gaim2::LogType T_IV
-+Gaim2::Log::ReadFlags TGaimObj
-+
-+
-+Gaim2::NotifyCloseCallback T_PTR
-+Gaim2::NotifyType T_IV
-+Gaim2::NotifyMsgType T_IV
-+Gaim2::NotifySearchButtonType T_IV
-+Gaim2::NotifySearchResults TGaimObj
-+Gaim2::NotifySearchColumn TGaimObj
-+Gaim2::NotifySearchButton TGaimObj
-+Gaim2::NotifyUiOps TGaimObj
-+
-+Gaim2::Plugin TGaimObj
-+Gaim2::Plugin::Info TGaimObj
-+Gaim2::PluginUiInfo TGaimObj
-+Gaim2::Plugin::Loader::Info TGaimObj
-+Gaim2::Plugin::Action TGaimObj
-+Gaim2::Plugin::Protocol::Info TGaimObj
-+Gaim2::PluginType T_IV
-+Gaim2::PrefType T_IV
-+Gaim2::PluginPref::Frame TGaimObj
-+Gaim2::PluginPref TGaimObj
-+Gaim2::PluginPrefType T_IV
-+Gaim2::Pounce TGaimObj
-+Gaim2::PounceEvent T_IV
-+Gaim2::Presence TGaimObj
-+Gaim2::PrivacyType T_IV
-+Gaim2::Privacy::UiOps TGaimObj
-+Gaim2::ProtocolOptions T_IV
-+Gaim2::ProxyType T_IV
-+Gaim2::ProxyInfo TGaimObj
-+
-+
-+Gaim2::RequestType T_IV
-+Gaim2::RequestFieldType T_IV
-+Gaim2::Request::Fields TGaimObj
-+Gaim2::Request::Field TGaimObj
-+Gaim2::Request::Field::Group TGaimObj
-+Gaim2::Request::UiOps TGaimObj
-+
-+Gaim2::Roomlist TGaimObj
-+Gaim2::Roomlist::Room TGaimObj
-+Gaim2::Roomlist::Field TGaimObj
-+Gaim2::Roomlist::UiOps TGaimObj
-+Gaim2::RoomlistRoomType T_IV
-+Gaim2::RoomlistFieldType T_IV
-+
-+Gaim2::SavedStatus TGaimObj
-+Gaim2::SavedStatusSub TGaimObj
-+Gaim2::SoundEventID T_IV
-+Gaim2::Sound::UiOps TGaimObj
-+
-+Gaim2::Ssl::Connection TGaimObj
-+Gaim2::Input::Condition TGaimObj
-+Gaim2::SslErrorType T_IV
-+Gaim2::Ssl::Ops TGaimObj
-+
-+Gaim2::Status TGaimObj
-+Gaim2::StatusType TGaimObj
-+const Gaim2::StatusType TGaimObj
-+Gaim2::StatusAttr TGaimObj
-+Gaim2::Presence TGaimObj
-+Gaim2::PresenceContext T_IV
-+Gaim2::StatusPrimitive T_IV
-+
-+
-+Gaim2::StoredImage TGaimObj
-+Gaim2::Stringref TGaimObj
-+Gaim2::Value TGaimObj
-+
-+Gaim2::Xfer TGaimObj
-+Gaim2::XferType T_IV
-+Gaim2::XferStatusType T_IV
-+Gaim2::XferUiOps T_IV
-
--Gaim::XMLNode T_GaimObj
-+Gaim2::XMLNode TGaimObj
- XMLNode::Type T_IV
-
-
-@@ -190,34 +190,34 @@ XMLNode::Type T_IV
-
-
- /* debug.h */
--Gaim::DebugLevel T_IV
-+Gaim2::DebugLevel T_IV
-
- /* conversation.h */
--Gaim::UnseenState T_IV
--Gaim::ConversationType T_IV
--Gaim::ConvUpdateType T_IV
--Gaim::TypingState T_IV
--Gaim::MessageFlags T_IV
--Gaim::ConvChatBuddyFlags T_IV
-+Gaim2::UnseenState T_IV
-+Gaim2::ConversationType T_IV
-+Gaim2::ConvUpdateType T_IV
-+Gaim2::TypingState T_IV
-+Gaim2::MessageFlags T_IV
-+Gaim2::ConvChatBuddyFlags T_IV
-
- /* connection.h */
--Gaim::ConnectionFlags T_IV
--Gaim::ConnectionState T_IV
-+Gaim2::ConnectionFlags T_IV
-+Gaim2::ConnectionState T_IV
-
- /* gtkutils.h */
--Gaim::ButtonOrientation T_IV
--Gaim::ButtonStyle T_IV
--Gaim::BrowserPlace T_IV
-+Gaim2::ButtonOrientation T_IV
-+Gaim2::ButtonStyle T_IV
-+Gaim2::BrowserPlace T_IV
-
-
-
- INPUT
-
--T_GaimObj
-- $var = gaim_perl_ref_object($arg)
-+TGaimObj
-+ $var = gaim2_perl_ref_object($arg)
-
-
- OUTPUT
-
--T_GaimObj
-- $arg = gaim_perl_bless_object($var, \"$type\");
-+TGaimObj
-+ $arg = gaim2_perl_bless_object($var, \"$type\");
-diff -prNu ./plugins/perl/common/Util.xs ./plugins/perl/common/Util.xs
---- ./plugins/perl/common/Util.xs 2005-12-08 22:00:31.000000000 +0100
-+++ ./plugins/perl/common/Util.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -4,7 +4,7 @@ typedef struct {
- char *cb;
- } GaimPerlUrlData;
-
--static void gaim_perl_util_url_cb(void *data, const char *url_data, size_t size) {
-+static void gaim2_perl_util_url_cb(void *data, const char *url_data, size_t size) {
- GaimPerlUrlData *gpr = (GaimPerlUrlData *)data;
- dSP;
- ENTER;
-@@ -23,12 +23,12 @@ static void gaim_perl_util_url_cb(void *
- }
-
-
--MODULE = Gaim::Util PACKAGE = Gaim::Util PREFIX = gaim_
-+MODULE = Gaim2::Util PACKAGE = Gaim2::Util PREFIX = gaim2_
- PROTOTYPES: ENABLE
-
- void
--gaim_url_fetch(handle, url, full, user_agent, http11, cb)
-- Gaim::Plugin handle
-+gaim2_url_fetch(handle, url, full, user_agent, http11, cb)
-+ Gaim2::Plugin handle
- const char *url
- gboolean full
- const char *user_agent
-@@ -40,44 +40,44 @@ CODE:
- char *basename, *package;
-
- basename = g_path_get_basename(handle->path);
-- gaim_perl_normalize_script_name(basename);
-- package = g_strdup_printf("Gaim::Script::%s", basename);
-+ gaim2_perl_normalize_script_name(basename);
-+ package = g_strdup_printf("Gaim2::Script::%s", basename);
- gpr = g_new(GaimPerlUrlData, 1);
-
- gpr->cb = g_strdup_printf("%s::%s", package, SvPV(cb, len));
-- gaim_url_fetch(url, full, user_agent, http11, gaim_perl_util_url_cb, gpr);
-+ gaim2_url_fetch(url, full, user_agent, http11, gaim2_perl_util_url_cb, gpr);
-
- int
--gaim_build_dir(path, mode)
-+gaim2_build_dir(path, mode)
- const char *path
- int mode
-
- const char *
--gaim_date()
-+gaim2_date()
-
-
- const char *
--gaim_date_full()
-+gaim2_date_full()
-
-
- gboolean
--gaim_email_is_valid(address)
-+gaim2_email_is_valid(address)
- const char *address
-
- const char *
--gaim_escape_filename(str)
-+gaim2_escape_filename(str)
- const char *str
-
- char *
--gaim_fd_get_ip(fd)
-+gaim2_fd_get_ip(fd)
- int fd
-
- const gchar *
--gaim_home_dir()
-+gaim2_home_dir()
-
-
- gboolean
--gaim_markup_extract_info_field(str, len, dest, start_token, skip, end_token, check_value, no_value_token, display_name, is_link, link_prefix)
-+gaim2_markup_extract_info_field(str, len, dest, start_token, skip, end_token, check_value, no_value_token, display_name, is_link, link_prefix)
- const char *str
- int len
- GString *dest
-@@ -91,7 +91,7 @@ gaim_markup_extract_info_field(str, len,
- const char *link_prefix
-
- gboolean
--gaim_markup_find_tag(needle, haystack, start, end, attributes)
-+gaim2_markup_find_tag(needle, haystack, start, end, attributes)
- const char *needle
- const char *haystack
- const char **start
-@@ -99,124 +99,124 @@ gaim_markup_find_tag(needle, haystack, s
- GData **attributes
-
- char *
--gaim_markup_get_tag_name(tag)
-+gaim2_markup_get_tag_name(tag)
- const char *tag
-
- void
--gaim_markup_html_to_xhtml(html, dest_xhtml, dest_plain)
-+gaim2_markup_html_to_xhtml(html, dest_xhtml, dest_plain)
- const char *html
- char **dest_xhtml
- char **dest_plain
-
- char *
--gaim_markup_linkify(str)
-+gaim2_markup_linkify(str)
- const char *str
-
- char *
--gaim_markup_slice(str, x, y)
-+gaim2_markup_slice(str, x, y)
- const char *str
- guint x
- guint y
-
- char *
--gaim_markup_strip_html(str)
-+gaim2_markup_strip_html(str)
- const char *str
-
- gboolean
--gaim_message_meify(message, len)
-+gaim2_message_meify(message, len)
- char *message
- size_t len
-
- FILE *
--gaim_mkstemp(path, binary)
-+gaim2_mkstemp(path, binary)
- char **path
- gboolean binary
-
- const char *
--gaim_normalize(account, str)
-- Gaim::Account account
-+gaim2_normalize(account, str)
-+ Gaim2::Account account
- const char *str
-
- gboolean
--gaim_program_is_valid(program)
-+gaim2_program_is_valid(program)
- const char *program
-
- char *
--gaim_str_add_cr(str)
-+gaim2_str_add_cr(str)
- const char *str
-
- char *
--gaim_str_binary_to_ascii(binary, len)
-+gaim2_str_binary_to_ascii(binary, len)
- const unsigned char *binary
- guint len
-
- gboolean
--gaim_str_has_prefix(s, p)
-+gaim2_str_has_prefix(s, p)
- const char *s
- const char *p
-
- gboolean
--gaim_str_has_suffix(s, x)
-+gaim2_str_has_suffix(s, x)
- const char *s
- const char *x
-
- char *
--gaim_str_seconds_to_string(sec)
-+gaim2_str_seconds_to_string(sec)
- guint sec
-
- char *
--gaim_str_size_to_units(size)
-+gaim2_str_size_to_units(size)
- size_t size
-
- void
--gaim_str_strip_char(str, thechar)
-+gaim2_str_strip_char(str, thechar)
- char *str
- char thechar
-
- gchar *
--gaim_str_sub_away_formatters(str, name)
-+gaim2_str_sub_away_formatters(str, name)
- const char *str
- const char *name
-
- time_t
--gaim_str_to_time(timestamp, utc)
-+gaim2_str_to_time(timestamp, utc)
- const char *timestamp
- gboolean utc
-
- gchar *
--gaim_strcasereplace(string, delimiter, replacement)
-+gaim2_strcasereplace(string, delimiter, replacement)
- const char *string
- const char *delimiter
- const char *replacement
-
- const char *
--gaim_strcasestr(haystack, needle)
-+gaim2_strcasestr(haystack, needle)
- const char *haystack
- const char *needle
-
- gchar *
--gaim_strdup_withhtml(src)
-+gaim2_strdup_withhtml(src)
- const gchar *src
-
- size_t
--gaim_strftime(s, max, format, tm)
-+gaim2_strftime(s, max, format, tm)
- char *s
- size_t max
- const char *format
- const struct tm *tm
-
- gchar *
--gaim_strreplace(string, delimiter, replacement)
-+gaim2_strreplace(string, delimiter, replacement)
- const char *string
- const char *delimiter
- const char *replacement
-
- char *
--gaim_text_strip_mnemonic(in)
-+gaim2_text_strip_mnemonic(in)
- const char *in
-
- time_t
--gaim_time_build(year, month, day, hour, min, sec)
-+gaim2_time_build(year, month, day, hour, min, sec)
- int year
- int month
- int day
-@@ -225,25 +225,25 @@ gaim_time_build(year, month, day, hour,
- int sec
-
- const char *
--gaim_unescape_filename(str)
-+gaim2_unescape_filename(str)
- const char *str
-
- char *
--gaim_unescape_html(html)
-+gaim2_unescape_html(html)
- const char *html
-
- const char *
--gaim_url_decode(str)
-+gaim2_url_decode(str)
- const char *str
-
- const char *
--gaim_url_encode(str)
-+gaim2_url_encode(str)
- const char *str
-
-
-
- gboolean
--gaim_url_parse(url, ret_host, ret_port, ret_path, ret_user, ret_passwd)
-+gaim2_url_parse(url, ret_host, ret_port, ret_path, ret_user, ret_passwd)
- const char *url
- char **ret_host
- int *ret_port
-@@ -252,15 +252,15 @@ gaim_url_parse(url, ret_host, ret_port,
- char **ret_passwd
-
- const char *
--gaim_user_dir()
-+gaim2_user_dir()
-
-
- void
--gaim_util_set_user_dir(dir)
-+gaim2_util_set_user_dir(dir)
- const char *dir
-
- gboolean
--gaim_util_write_data_to_file(filename, data, size)
-+gaim2_util_write_data_to_file(filename, data, size)
- const char *filename
- const char *data
- size_t size
-diff -prNu ./plugins/perl/common/XMLNode.xs ./plugins/perl/common/XMLNode.xs
---- ./plugins/perl/common/XMLNode.xs 2005-12-06 00:54:34.000000000 +0100
-+++ ./plugins/perl/common/XMLNode.xs 2006-01-05 15:20:19.000000000 +0100
-@@ -1,10 +1,10 @@
- #include "module.h"
-
--MODULE = Gaim::XMLNode PACKAGE = Gaim::XMLNode PREFIX = xmlnode_
-+MODULE = Gaim2::XMLNode PACKAGE = Gaim2::XMLNode PREFIX = xmlnode_
- PROTOTYPES: ENABLE
-
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_copy(class, src)
- xmlnode *src
- C_ARGS:
-@@ -14,7 +14,7 @@ void
- xmlnode_free(node)
- xmlnode *node
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_from_str(class, str, size)
- const char *str
- gssize size
-@@ -26,12 +26,12 @@ xmlnode_get_attrib(node, attr)
- xmlnode *node
- const char *attr
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_get_child(parent, name)
- const xmlnode *parent
- const char *name
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_get_child_with_namespace(parent, name, xmlns)
- const xmlnode *parent
- const char *name
-@@ -41,7 +41,7 @@ char *
- xmlnode_get_data(node)
- xmlnode *node
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_get_next_twin(node)
- xmlnode *node
-
-@@ -56,13 +56,13 @@ xmlnode_insert_data(node, data, size)
- const char *data
- gssize size
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_new(class, name)
- const char *name
- C_ARGS:
- name
-
--Gaim::XMLNode
-+Gaim2::XMLNode
- xmlnode_new_child(parent, name)
- xmlnode *parent
- const char *name
-diff -prNu ./plugins/perl/Makefile.am ./plugins/perl/Makefile.am
---- ./plugins/perl/Makefile.am 2005-10-29 03:05:29.000000000 +0200
-+++ ./plugins/perl/Makefile.am 2006-01-05 13:53:10.000000000 +0100
-@@ -1,4 +1,4 @@
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- perl_dirs = common
-
-@@ -50,8 +50,8 @@ common_sources = \
- common/Connection.xs \
- common/Conversation.xs \
- common/FT.xs \
-- common/Gaim.pm \
-- common/Gaim.xs \
-+ common/Gaim2.pm \
-+ common/Gaim2.xs \
- common/ImgStore.xs \
- common/Log.xs \
- common/Makefile.PL.in \
-diff -prNu ./plugins/perl/perl.c ./plugins/perl/perl.c
---- ./plugins/perl/perl.c 2005-10-26 12:42:11.000000000 +0200
-+++ ./plugins/perl/perl.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org>
- *
-@@ -97,11 +97,11 @@ extern void boot_DynaLoader _((pTHX_ CV
-
- typedef struct
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- char *package;
- char *load_sub;
- char *unload_sub;
--} GaimPerlScript;
-+} Gaim2PerlScript;
-
-
- PerlInterpreter *my_perl = NULL;
-@@ -136,7 +136,7 @@ perl_init(void)
- the file contents. This allows to have a really local $/
- without introducing temp variables to hold the old
- value. Just a question of style:) */
-- "package Gaim::PerlLoader;"
-+ "package Gaim2::PerlLoader;"
- "use Symbol;"
-
- "sub load_file {"
-@@ -200,7 +200,7 @@ perl_end(void)
- PERL_SET_CONTEXT(my_perl);
- perl_eval_pv(
- "foreach my $lib (@DynaLoader::dl_modules) {"
-- "if ($lib =~ /^Gaim\\b/) {"
-+ "if ($lib =~ /^Gaim2\\b/) {"
- "$lib .= '::deinit();';"
- "eval $lib;"
- "}"
-@@ -215,7 +215,7 @@ perl_end(void)
- }
-
- void
--gaim_perl_callXS(void (*subaddr)(pTHX_ CV *cv), CV *cv, SV **mark)
-+gaim2_perl_callXS(void (*subaddr)(pTHX_ CV *cv), CV *cv, SV **mark)
- {
- dSP;
-
-@@ -226,7 +226,7 @@ gaim_perl_callXS(void (*subaddr)(pTHX_ C
- }
-
- static gboolean
--probe_perl_plugin(GaimPlugin *plugin)
-+probe_perl_plugin(Gaim2Plugin *plugin)
- {
- /* XXX This would be much faster if I didn't create a new
- * PerlInterpreter every time I probed a plugin */
-@@ -270,15 +270,15 @@ probe_perl_plugin(GaimPlugin *plugin)
- status = FALSE;
- else
- {
-- GaimPluginInfo *info;
-- GaimPerlScript *gps;
-+ Gaim2PluginInfo *info;
-+ Gaim2PerlScript *gps;
- char *basename;
- STRLEN len;
-
-- gaim_debug(GAIM_DEBUG_INFO, "perl", "Found plugin info\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "perl", "Found plugin info\n");
-
-- info = g_new0(GaimPluginInfo, 1);
-- gps = g_new0(GaimPerlScript, 1);
-+ info = g_new0(Gaim2PluginInfo, 1);
-+ gps = g_new0(Gaim2PerlScript, 1);
-
- info->magic = GAIM_PLUGIN_MAGIC;
- info->major_version = GAIM_MAJOR_VERSION;
-@@ -291,8 +291,8 @@ probe_perl_plugin(GaimPlugin *plugin)
- gps->plugin = plugin;
-
- basename = g_path_get_basename(plugin->path);
-- gaim_perl_normalize_script_name(basename);
-- gps->package = g_strdup_printf("Gaim::Script::%s", basename);
-+ gaim2_perl_normalize_script_name(basename);
-+ gps->package = g_strdup_printf("Gaim2::Script::%s", basename);
- g_free(basename);
-
- /* We know this one exists. */
-@@ -330,8 +330,8 @@ probe_perl_plugin(GaimPlugin *plugin)
- /********************************************************/
- /* Only one of the next two options should be present */
- /* */
-- /* prefs_info - Uses non-GUI (read GTK) gaim API calls */
-- /* and creates a GaimPluginPrefInfo type. */
-+ /* prefs_info - Uses non-GUI (read GTK) gaim2 API calls */
-+ /* and creates a Gaim2PluginPrefInfo type. */
- /* */
- /* gtk_prefs_info - Requires gtk2-perl be installed by */
- /* the user and he must create a GtkWidget */
-@@ -341,14 +341,14 @@ probe_perl_plugin(GaimPlugin *plugin)
- if ((key = hv_fetch(plugin_info, "prefs_info", strlen("prefs_info"), 0))) {
- char *tmp = g_strdup_printf("%s::%s", gps->package, SvPV(*key, len));
- /* key now is the name of the Perl sub that will create a frame for us */
-- info->prefs_info = gaim_perl_plugin_pref(tmp);
-+ info->prefs_info = gaim2_perl_plugin_pref(tmp);
- g_free(tmp);
- }
-
- if ((key = hv_fetch(plugin_info, "gtk_prefs_info", strlen("gtk_prefs_info"), 0))) {
- char *tmp = g_strdup_printf("%s::%s", gps->package, SvPV(*key, len));
- /* key now is the name of the Perl sub that will create a frame for us */
-- info->ui_info = gaim_perl_gtk_plugin_pref(tmp);
-+ info->ui_info = gaim2_perl_gtk_plugin_pref(tmp);
- g_free(tmp);
- }
-
-@@ -360,22 +360,22 @@ probe_perl_plugin(GaimPlugin *plugin)
- /* in the plugin action menu. The name is */
- /* extracted and then the callback perl sub's name */
- /* both of which then are handled by an internal */
-- /* gaim_perl function that sets up the single cb */
-+ /* gaim2_perl function that sets up the single cb */
- /* function which is then inserted into 'info'. */
- /********************************************************/
- if ((key = hv_fetch(plugin_info, "plugin_action_label", strlen("plugin_action_label"), 0))) {
-- gaim_perl_plugin_action_label = g_strdup(SvPV(*key, len));
-+ gaim2_perl_plugin_action_label = g_strdup(SvPV(*key, len));
- }
-
- if ((key = hv_fetch(plugin_info, "plugin_action", strlen("plugin_action"), 0))) {
-- gaim_perl_plugin_action_callback_sub = g_strdup_printf("%s::%s", gps->package, SvPV(*key, len));
-- info->actions = gaim_perl_plugin_action;
-+ gaim2_perl_plugin_action_callback_sub = g_strdup_printf("%s::%s", gps->package, SvPV(*key, len));
-+ info->actions = gaim2_perl_plugin_action;
- }
-
- plugin->info = info;
- info->extra_info = gps;
-
-- status = gaim_plugin_register(plugin);
-+ status = gaim2_plugin_register(plugin);
- }
- }
-
-@@ -387,15 +387,15 @@ probe_perl_plugin(GaimPlugin *plugin)
- }
-
- static gboolean
--load_perl_plugin(GaimPlugin *plugin)
-+load_perl_plugin(Gaim2Plugin *plugin)
- {
-- GaimPerlScript *gps = (GaimPerlScript *)plugin->info->extra_info;
-+ Gaim2PerlScript *gps = (Gaim2PerlScript *)plugin->info->extra_info;
- char *atmp[3] = { plugin->path, NULL, NULL };
-
- if (gps == NULL || gps->load_sub == NULL)
- return FALSE;
-
-- gaim_debug(GAIM_DEBUG_INFO, "perl", "Loading perl script\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "perl", "Loading perl script\n");
-
- if (my_perl == NULL)
- perl_init();
-@@ -405,7 +405,7 @@ load_perl_plugin(GaimPlugin *plugin)
- atmp[1] = gps->package;
-
- PERL_SET_CONTEXT(my_perl);
-- execute_perl("Gaim::PerlLoader::load_n_eval", 2, atmp);
-+ execute_perl("Gaim2::PerlLoader::load_n_eval", 2, atmp);
-
- {
- dSP;
-@@ -414,7 +414,7 @@ load_perl_plugin(GaimPlugin *plugin)
- ENTER;
- SAVETMPS;
- PUSHMARK(sp);
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(plugin, "Gaim::Plugin")));
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(plugin, "Gaim2::Plugin")));
- PUTBACK;
-
- perl_call_pv(gps->load_sub, G_EVAL | G_SCALAR);
-@@ -423,7 +423,7 @@ load_perl_plugin(GaimPlugin *plugin)
- if (SvTRUE(ERRSV)) {
- STRLEN len;
-
-- gaim_debug(GAIM_DEBUG_ERROR, "perl",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "perl",
- "Perl function %s exited abnormally: %s\n",
- gps->load_sub, SvPV(ERRSV, len));
- }
-@@ -450,7 +450,7 @@ destroy_package(const char *package)
- XPUSHs(sv_2mortal(newSVpv(package, strlen(package))));
- PUTBACK;
-
-- perl_call_pv("Gaim::PerlLoader::destroy_package",
-+ perl_call_pv("Gaim2::PerlLoader::destroy_package",
- G_VOID | G_EVAL | G_DISCARD);
-
- SPAGAIN;
-@@ -461,14 +461,14 @@ destroy_package(const char *package)
- }
-
- static gboolean
--unload_perl_plugin(GaimPlugin *plugin)
-+unload_perl_plugin(Gaim2Plugin *plugin)
- {
-- GaimPerlScript *gps = (GaimPerlScript *)plugin->info->extra_info;
-+ Gaim2PerlScript *gps = (Gaim2PerlScript *)plugin->info->extra_info;
-
- if (gps == NULL)
- return FALSE;
-
-- gaim_debug(GAIM_DEBUG_INFO, "perl", "Unloading perl script\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "perl", "Unloading perl script\n");
-
- if (gps->unload_sub != NULL)
- {
-@@ -478,7 +478,7 @@ unload_perl_plugin(GaimPlugin *plugin)
- ENTER;
- SAVETMPS;
- PUSHMARK(sp);
-- XPUSHs(sv_2mortal(gaim_perl_bless_object(plugin, "Gaim::Plugin")));
-+ XPUSHs(sv_2mortal(gaim2_perl_bless_object(plugin, "Gaim2::Plugin")));
- PUTBACK;
-
- perl_call_pv(gps->unload_sub, G_EVAL | G_SCALAR);
-@@ -487,7 +487,7 @@ unload_perl_plugin(GaimPlugin *plugin)
- if (SvTRUE(ERRSV)) {
- STRLEN len;
-
-- gaim_debug(GAIM_DEBUG_ERROR, "perl",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "perl",
- "Perl function %s exited abnormally: %s\n",
- gps->load_sub, SvPV(ERRSV, len));
- }
-@@ -497,8 +497,8 @@ unload_perl_plugin(GaimPlugin *plugin)
- LEAVE;
- }
-
-- gaim_perl_signal_clear_for_plugin(plugin);
-- gaim_perl_timeout_clear_for_plugin(plugin);
-+ gaim2_perl_signal_clear_for_plugin(plugin);
-+ gaim2_perl_timeout_clear_for_plugin(plugin);
-
- destroy_package(gps->package);
-
-@@ -506,11 +506,11 @@ unload_perl_plugin(GaimPlugin *plugin)
- }
-
- static void
--destroy_perl_plugin(GaimPlugin *plugin)
-+destroy_perl_plugin(Gaim2Plugin *plugin)
- {
- if (plugin->info != NULL)
- {
-- GaimPerlScript *gps;
-+ Gaim2PerlScript *gps;
-
- if (plugin->info->name != NULL)
- g_free(plugin->info->name);
-@@ -530,7 +530,7 @@ destroy_perl_plugin(GaimPlugin *plugin)
- if (plugin->info->homepage != NULL)
- g_free(plugin->info->homepage);
-
-- gps = (GaimPerlScript *)plugin->info->extra_info;
-+ gps = (Gaim2PerlScript *)plugin->info->extra_info;
-
- if (gps != NULL)
- {
-@@ -550,20 +550,20 @@ destroy_perl_plugin(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- perl_end();
-
- return TRUE;
- }
-
--static GaimPluginLoaderInfo loader_info =
-+static Gaim2PluginLoaderInfo loader_info =
- {
- NULL, /**< exts */
- probe_perl_plugin, /**< probe */
-@@ -572,7 +572,7 @@ static GaimPluginLoaderInfo loader_info
- destroy_perl_plugin /**< destroy */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -602,7 +602,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- loader_info.exts = g_list_append(loader_info.exts, "pl");
- }
-diff -prNu ./plugins/perl/perl-common.c ./plugins/perl/perl-common.c
---- ./plugins/perl/perl-common.c 2005-08-20 22:17:07.000000000 +0200
-+++ ./plugins/perl/perl-common.c 2006-01-05 15:27:38.000000000 +0100
-@@ -7,7 +7,7 @@ extern PerlInterpreter *my_perl;
-
- static GHashTable *object_stashes = NULL;
-
--void gaim_perl_normalize_script_name(char *name)
-+void gaim2_perl_normalize_script_name(char *name)
- {
- char *c;
-
-@@ -67,7 +67,7 @@ newSVGChar(const char *str)
- }
-
- SV *
--gaim_perl_bless_object(void *object, const char *stash_name)
-+gaim2_perl_bless_object(void *object, const char *stash_name)
- {
- HV *stash;
- HV *hv;
-@@ -83,13 +83,13 @@ gaim_perl_bless_object(void *object, con
- stash = gv_stashpv(stash_name, 1);
-
- hv = newHV();
-- hv_store(hv, "_gaim", 5, create_sv_ptr(object), 0);
-+ hv_store(hv, "_gaim2", 5, create_sv_ptr(object), 0);
-
- return sv_bless(newRV_noinc((SV *)hv), stash);
- }
-
- gboolean
--gaim_perl_is_ref_object(SV *o)
-+gaim2_perl_is_ref_object(SV *o)
- {
- SV **sv;
- HV *hv;
-@@ -98,7 +98,7 @@ gaim_perl_is_ref_object(SV *o)
-
- if (hv != NULL)
- {
-- sv = hv_fetch(hv, "_gaim", 5, 0);
-+ sv = hv_fetch(hv, "_gaim2", 5, 0);
-
- if (sv != NULL)
- return TRUE;
-@@ -108,7 +108,7 @@ gaim_perl_is_ref_object(SV *o)
- }
-
- void *
--gaim_perl_ref_object(SV *o)
-+gaim2_perl_ref_object(SV *o)
- {
- SV **sv;
- HV *hv;
-@@ -122,7 +122,7 @@ gaim_perl_ref_object(SV *o)
- if (hv == NULL)
- return NULL;
-
-- sv = hv_fetch(hv, "_gaim", 5, 0);
-+ sv = hv_fetch(hv, "_gaim2", 5, 0);
-
- if (sv == NULL)
- croak("variable is damaged");
-@@ -206,7 +206,7 @@ execute_perl(const char *function, int a
- * return value.
- */
- if (SvTRUE(ERRSV)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "perl",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "perl",
- "Perl function %s exited abnormally: %s\n",
- function, SvPV(ERRSV, na));
- POPs;
-@@ -216,7 +216,7 @@ execute_perl(const char *function, int a
- * This should NEVER happen. G_SCALAR ensures that we WILL
- * have 1 parameter.
- */
-- gaim_debug(GAIM_DEBUG_ERROR, "perl",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "perl",
- "Perl error from %s: expected 1 return value, "
- "but got %d\n", function, count);
- }
-@@ -251,65 +251,65 @@ execute_perl(const char *function, int a
-
- #if 0
- gboolean
--gaim_perl_value_from_sv(GaimValue *value, SV *sv)
-+gaim2_perl_value_from_sv(Gaim2Value *value, SV *sv)
- {
-- switch (gaim_value_get_type(value))
-+ switch (gaim2_value_get_type(value))
- {
- case GAIM_TYPE_CHAR:
- if ((tmp = SvGChar(sv)) != NULL)
-- gaim_value_set_char(value, tmp[0]);
-+ gaim2_value_set_char(value, tmp[0]);
- else
- return FALSE;
- break;
-
- case GAIM_TYPE_UCHAR:
- if ((tmp = SvPV_nolen(sv)) != NULL)
-- gaim_value_set_uchar(value, tmp[0]);
-+ gaim2_value_set_uchar(value, tmp[0]);
- else
- return FALSE;
- break;
-
- case GAIM_TYPE_BOOLEAN:
-- gaim_value_set_boolean(value, SvTRUE(sv));
-+ gaim2_value_set_boolean(value, SvTRUE(sv));
- break;
-
- case GAIM_TYPE_INT:
-- gaim_value_set_int(value, SvIV(sv));
-+ gaim2_value_set_int(value, SvIV(sv));
- break;
-
- case GAIM_TYPE_UINT:
-- gaim_value_set_uint(value, SvIV(sv));
-+ gaim2_value_set_uint(value, SvIV(sv));
- break;
-
- case GAIM_TYPE_LONG:
-- gaim_value_set_long(value, SvIV(sv));
-+ gaim2_value_set_long(value, SvIV(sv));
- break;
-
- case GAIM_TYPE_ULONG:
-- gaim_value_set_ulong(value, SvIV(sv));
-+ gaim2_value_set_ulong(value, SvIV(sv));
- break;
-
- case GAIM_TYPE_INT64:
-- gaim_value_set_int64(value, SvIV(sv));
-+ gaim2_value_set_int64(value, SvIV(sv));
- break;
-
- case GAIM_TYPE_UINT64:
-- gaim_value_set_uint64(value, SvIV(sv));
-+ gaim2_value_set_uint64(value, SvIV(sv));
- break;
-
- case GAIM_TYPE_STRING:
-- gaim_value_set_string(value, SvGChar(sv));
-+ gaim2_value_set_string(value, SvGChar(sv));
- break;
-
- case GAIM_TYPE_POINTER:
-- gaim_value_set_pointer(value, (void *)SvIV(sv));
-+ gaim2_value_set_pointer(value, (void *)SvIV(sv));
- break;
-
- case GAIM_TYPE_BOXED:
-- if (!strcmp(gaim_value_get_specific_type(value), "SV"))
-- gaim_value_set_boxed(value, (sv == &PL_sv_undef ? NULL : sv));
-+ if (!strcmp(gaim2_value_get_specific_type(value), "SV"))
-+ gaim2_value_set_boxed(value, (sv == &PL_sv_undef ? NULL : sv));
- else
-- gaim_value_set_boxed(value, sv);
-+ gaim2_value_set_boxed(value, sv);
- break;
-
- default:
-@@ -320,58 +320,58 @@ gaim_perl_value_from_sv(GaimValue *value
- }
-
- SV *
--gaim_perl_sv_from_value(const GaimValue *value, va_list list)
-+gaim2_perl_sv_from_value(const Gaim2Value *value, va_list list)
- {
-- switch (gaim_value_get_type(value))
-+ switch (gaim2_value_get_type(value))
- {
- case GAIM_TYPE_BOOLEAN:
-- return newSViv(gaim_value_get_boolean(value));
-+ return newSViv(gaim2_value_get_boolean(value));
- break;
-
- case GAIM_TYPE_INT:
-- return newSViv(gaim_value_get_int(value));
-+ return newSViv(gaim2_value_get_int(value));
- break;
-
- case GAIM_TYPE_UINT:
-- return newSVuv(gaim_value_get_uint(value));
-+ return newSVuv(gaim2_value_get_uint(value));
- break;
-
- case GAIM_TYPE_LONG:
-- return newSViv(gaim_value_get_long(value));
-+ return newSViv(gaim2_value_get_long(value));
- break;
-
- case GAIM_TYPE_ULONG:
-- return newSVuv(gaim_value_get_ulong(value));
-+ return newSVuv(gaim2_value_get_ulong(value));
- break;
-
- case GAIM_TYPE_INT64:
-- return newSViv(gaim_value_get_int64(value));
-+ return newSViv(gaim2_value_get_int64(value));
- break;
-
- case GAIM_TYPE_UINT64:
-- return newSVuv(gaim_value_get_int64(value));
-+ return newSVuv(gaim2_value_get_int64(value));
- break;
-
- case GAIM_TYPE_STRING:
-- return newSVGChar(gaim_value_get_string(value));
-+ return newSVGChar(gaim2_value_get_string(value));
- break;
-
- case GAIM_TYPE_POINTER:
-- return newSViv((IV)gaim_value_get_pointer(value));
-+ return newSViv((IV)gaim2_value_get_pointer(value));
- break;
-
- case GAIM_TYPE_BOXED:
-- if (!strcmp(gaim_value_get_specific_type(value), "SV"))
-+ if (!strcmp(gaim2_value_get_specific_type(value), "SV"))
- {
-- SV *sv = (SV *)gaim_perl_get_boxed(value);
-+ SV *sv = (SV *)gaim2_perl_get_boxed(value);
-
- return (sv == NULL ? &PL_sv_undef : sv);
- }
-
- /* Uh.. I dunno. Try this? */
-- return sv_2mortal(gaim_perl_bless_object(
-- gaim_perl_get_boxed(value),
-- gaim_value_get_specific_type(value)));
-+ return sv_2mortal(gaim2_perl_bless_object(
-+ gaim2_perl_get_boxed(value),
-+ gaim2_value_get_specific_type(value)));
-
- default:
- return FALSE;
-@@ -382,11 +382,11 @@ gaim_perl_sv_from_value(const GaimValue
- #endif
-
- void *
--gaim_perl_data_from_sv(GaimValue *value, SV *sv)
-+gaim2_perl_data_from_sv(Gaim2Value *value, SV *sv)
- {
- STRLEN na;
-
-- switch (gaim_value_get_type(value))
-+ switch (gaim2_value_get_type(value))
- {
- case GAIM_TYPE_BOOLEAN: return (void *)SvIV(sv);
- case GAIM_TYPE_INT: return (void *)SvIV(sv);
-@@ -407,42 +407,42 @@ gaim_perl_data_from_sv(GaimValue *value,
- }
-
- static SV *
--gaim_perl_sv_from_subtype(const GaimValue *value, void *arg)
-+gaim2_perl_sv_from_subtype(const Gaim2Value *value, void *arg)
- {
- const char *stash = NULL;
-
-- switch (gaim_value_get_subtype(value))
-+ switch (gaim2_value_get_subtype(value))
- {
-- case GAIM_SUBTYPE_ACCOUNT: stash = "Gaim::Account"; break;
-- case GAIM_SUBTYPE_BLIST: stash = "Gaim::BuddyList"; break;
-- case GAIM_SUBTYPE_BLIST_BUDDY: stash = "Gaim::BuddyList::Buddy"; break;
-- case GAIM_SUBTYPE_BLIST_GROUP: stash = "Gaim::BuddyList::Group"; break;
-- case GAIM_SUBTYPE_BLIST_CHAT: stash = "Gaim::BuddyList::Chat"; break;
-- case GAIM_SUBTYPE_CONNECTION: stash = "Gaim::Connection"; break;
-- case GAIM_SUBTYPE_CONVERSATION: stash = "Gaim::Conversation"; break;
-- case GAIM_SUBTYPE_CONV_WINDOW: stash = "Gaim::ConvWindow"; break;
-- case GAIM_SUBTYPE_PLUGIN: stash = "Gaim::Plugin"; break;
-+ case GAIM_SUBTYPE_ACCOUNT: stash = "Gaim2::Account"; break;
-+ case GAIM_SUBTYPE_BLIST: stash = "Gaim2::BuddyList"; break;
-+ case GAIM_SUBTYPE_BLIST_BUDDY: stash = "Gaim2::BuddyList::Buddy"; break;
-+ case GAIM_SUBTYPE_BLIST_GROUP: stash = "Gaim2::BuddyList::Group"; break;
-+ case GAIM_SUBTYPE_BLIST_CHAT: stash = "Gaim2::BuddyList::Chat"; break;
-+ case GAIM_SUBTYPE_CONNECTION: stash = "Gaim2::Connection"; break;
-+ case GAIM_SUBTYPE_CONVERSATION: stash = "Gaim2::Conversation"; break;
-+ case GAIM_SUBTYPE_CONV_WINDOW: stash = "Gaim2::ConvWindow"; break;
-+ case GAIM_SUBTYPE_PLUGIN: stash = "Gaim2::Plugin"; break;
-
- default:
-- stash = "Gaim"; /* ? */
-+ stash = "Gaim2"; /* ? */
- }
-
-- return sv_2mortal(gaim_perl_bless_object(arg, stash));
-+ return sv_2mortal(gaim2_perl_bless_object(arg, stash));
- }
-
- SV *
--gaim_perl_sv_from_vargs(const GaimValue *value, va_list *args,
-+gaim2_perl_sv_from_vargs(const Gaim2Value *value, va_list *args,
- void ***copy_arg)
- {
-- if (gaim_value_is_outgoing(value))
-+ if (gaim2_value_is_outgoing(value))
- {
-- switch (gaim_value_get_type(value))
-+ switch (gaim2_value_get_type(value))
- {
- case GAIM_TYPE_SUBTYPE:
- if ((*copy_arg = va_arg(*args, void **)) == NULL)
- return &PL_sv_undef;
-
-- return gaim_perl_sv_from_subtype(value, *(void **)*copy_arg);
-+ return gaim2_perl_sv_from_subtype(value, *(void **)*copy_arg);
-
- case GAIM_TYPE_BOOLEAN:
- if ((*copy_arg = (void *)va_arg(*args, gboolean *)) == NULL)
-@@ -504,9 +504,9 @@ gaim_perl_sv_from_vargs(const GaimValue
- if ((*copy_arg = va_arg(*args, void **)) == NULL)
- return &PL_sv_undef;
-
-- return sv_2mortal(gaim_perl_bless_object(
-+ return sv_2mortal(gaim2_perl_bless_object(
- *(void **)*copy_arg,
-- gaim_value_get_specific_type(value)));
-+ gaim2_value_get_specific_type(value)));
-
- default:
- /* If this happens, things are going to get screwed up... */
-@@ -515,13 +515,13 @@ gaim_perl_sv_from_vargs(const GaimValue
- }
- else
- {
-- switch (gaim_value_get_type(value))
-+ switch (gaim2_value_get_type(value))
- {
- case GAIM_TYPE_SUBTYPE:
- if ((*copy_arg = va_arg(*args, void *)) == NULL)
- return &PL_sv_undef;
-
-- return gaim_perl_sv_from_subtype(value, *copy_arg);
-+ return gaim2_perl_sv_from_subtype(value, *copy_arg);
-
- case GAIM_TYPE_BOOLEAN:
- *copy_arg = GINT_TO_POINTER( va_arg(*args, gboolean) );
-@@ -583,8 +583,8 @@ gaim_perl_sv_from_vargs(const GaimValue
- if ((*copy_arg = (void *)va_arg(*args, void *)) == NULL)
- return &PL_sv_undef;
-
-- return sv_2mortal(gaim_perl_bless_object(*copy_arg,
-- gaim_value_get_specific_type(value)));
-+ return sv_2mortal(gaim2_perl_bless_object(*copy_arg,
-+ gaim2_value_get_specific_type(value)));
-
- default:
- /* If this happens, things are going to get screwed up... */
-diff -prNu ./plugins/perl/perl-common.h ./plugins/perl/perl-common.h
---- ./plugins/perl/perl-common.h 2005-12-16 10:02:17.000000000 +0100
-+++ ./plugins/perl/perl-common.h 2006-01-05 15:27:48.000000000 +0100
-@@ -18,31 +18,31 @@
- (is_hvref(o) ? (HV *)SvRV(o) : NULL);
-
- #define GAIM_PERL_BOOT_PROTO(x) \
-- void boot_Gaim__##x(pTHX_ CV *cv);
-+ void boot_Gaim2__##x(pTHX_ CV *cv);
-
- #define GAIM_PERL_BOOT(x) \
-- gaim_perl_callXS(boot_Gaim__##x, cv, mark)
-+ gaim2_perl_callXS(boot_Gaim2__##x, cv, mark)
-
--void gaim_perl_normalize_script_name(char *name);
-+void gaim2_perl_normalize_script_name(char *name);
-
-
- SV *newSVGChar(const char *str);
-
--void gaim_perl_callXS(void (*subaddr)(pTHX_ CV *cv), CV *cv, SV **mark);
--void gaim_perl_bless_plain(const char *stash, void *object);
--SV *gaim_perl_bless_object(void *object, const char *stash);
--gboolean gaim_perl_is_ref_object(SV *o);
--void *gaim_perl_ref_object(SV *o);
-+void gaim2_perl_callXS(void (*subaddr)(pTHX_ CV *cv), CV *cv, SV **mark);
-+void gaim2_perl_bless_plain(const char *stash, void *object);
-+SV *gaim2_perl_bless_object(void *object, const char *stash);
-+gboolean gaim2_perl_is_ref_object(SV *o);
-+void *gaim2_perl_ref_object(SV *o);
-
- int execute_perl(const char *function, int argc, char **args);
-
- #if 0
--gboolean gaim_perl_value_from_sv(GaimValue *value, SV *sv);
--SV *gaim_perl_sv_from_value(const GaimValue *value);
-+gboolean gaim2_perl_value_from_sv(Gaim2Value *value, SV *sv);
-+SV *gaim2_perl_sv_from_value(const Gaim2Value *value);
- #endif
-
--void *gaim_perl_data_from_sv(GaimValue *value, SV *sv);
--SV *gaim_perl_sv_from_vargs(const GaimValue *value, va_list *args,
-+void *gaim2_perl_data_from_sv(Gaim2Value *value, SV *sv);
-+SV *gaim2_perl_sv_from_vargs(const Gaim2Value *value, va_list *args,
- void ***copy_arg);
-
- #endif /* _GAIM_PERL_COMMON_H_ */
-diff -prNu ./plugins/perl/perl-handlers.c ./plugins/perl/perl-handlers.c
---- ./plugins/perl/perl-handlers.c 2005-11-19 19:07:19.000000000 +0100
-+++ ./plugins/perl/perl-handlers.c 2006-01-05 15:27:38.000000000 +0100
-@@ -17,7 +17,7 @@ extern PerlInterpreter *my_perl;
- #endif
-
- /* For now a plugin can only have one action */
--void gaim_perl_plugin_action_cb(GaimPluginAction * gpa) {
-+void gaim2_perl_plugin_action_cb(Gaim2PluginAction * gpa) {
-
- dSP;
- ENTER;
-@@ -27,16 +27,16 @@ void gaim_perl_plugin_action_cb(GaimPlug
- /* We put the plugin handle on the stack so it can pass it along */
- /* to anythng called from the callback. It is supposed to pass */
- /* the Action, but there is no way to access the plugin handle from */
-- /* the GaimPluginAction in perl...yet. */
-+ /* the Gaim2PluginAction in perl...yet. */
-
-- XPUSHs(gaim_perl_bless_object(gpa->plugin, "Gaim::Plugin"));
-+ XPUSHs(gaim2_perl_bless_object(gpa->plugin, "Gaim2::Plugin"));
- PUTBACK;
-
-- /* gaim_perl_plugin_action_callback_sub defined in the header is set */
-+ /* gaim2_perl_plugin_action_callback_sub defined in the header is set */
- /* in perl.c during plugin probe by a PLUGIN_INFO hash value limiting */
- /* us to only one action for right now even though the action member of */
-- /* GaimPluginInfo can take (does take) a GList. */
-- call_pv(gaim_perl_plugin_action_callback_sub, G_EVAL | G_SCALAR);
-+ /* Gaim2PluginInfo can take (does take) a GList. */
-+ call_pv(gaim2_perl_plugin_action_callback_sub, G_EVAL | G_SCALAR);
- SPAGAIN;
-
- PUTBACK;
-@@ -44,8 +44,8 @@ void gaim_perl_plugin_action_cb(GaimPlug
- LEAVE;
- }
-
--GList *gaim_perl_plugin_action(GaimPlugin *plugin, gpointer context) {
-- GaimPluginAction *act = NULL;
-+GList *gaim2_perl_plugin_action(Gaim2Plugin *plugin, gpointer context) {
-+ Gaim2PluginAction *act = NULL;
- GList *gl = NULL;
-
- /* TODO: Fix the way we create action handlers so we can have mroe than */
-@@ -54,25 +54,25 @@ GList *gaim_perl_plugin_action(GaimPlugi
- /* name to the callback function without these global variables and */
- /* there is no way to create a callback on the fly so each would have */
- /* to be hardcoded--more than one would just be arbitrary. */
-- act = gaim_plugin_action_new(gaim_perl_plugin_action_label, gaim_perl_plugin_action_cb);
-+ act = gaim2_plugin_action_new(gaim2_perl_plugin_action_label, gaim2_perl_plugin_action_cb);
- gl = g_list_append(gl, act);
-
- return gl;
- }
-
-
--GaimGtkPluginUiInfo *gaim_perl_gtk_plugin_pref(const char * frame_cb) {
-+Gaim2GtkPluginUiInfo *gaim2_perl_gtk_plugin_pref(const char * frame_cb) {
-
-- GaimGtkPluginUiInfo *ui_info;
-+ Gaim2GtkPluginUiInfo *ui_info;
-
-- ui_info = g_new0(GaimGtkPluginUiInfo, 1);
-+ ui_info = g_new0(Gaim2GtkPluginUiInfo, 1);
- perl_gtk_plugin_pref_cb = g_strdup(frame_cb);
-- ui_info->get_config_frame = gaim_perl_gtk_get_plugin_frame;
-+ ui_info->get_config_frame = gaim2_perl_gtk_get_plugin_frame;
-
- return ui_info;
- }
-
--GtkWidget *gaim_perl_gtk_get_plugin_frame(GaimPlugin *plugin) {
-+GtkWidget *gaim2_perl_gtk_get_plugin_frame(Gaim2Plugin *plugin) {
-
- SV * sv;
- GtkWidget *ret;
-@@ -107,24 +107,24 @@ GtkWidget *gaim_perl_gtk_get_plugin_fram
-
-
-
--/* Called to create a pointer to GaimPluginUiInfo for the GaimPluginInfo */
-+/* Called to create a pointer to Gaim2PluginUiInfo for the Gaim2PluginInfo */
- /* It will then inturn create ui_info with the C function pointer */
- /* that will eventually do a call_pv to call a perl functions so users */
- /* can create their own frames in the prefs */
--GaimPluginUiInfo *gaim_perl_plugin_pref(const char * frame_cb) {
-- GaimPluginUiInfo *ui_info;
-+Gaim2PluginUiInfo *gaim2_perl_plugin_pref(const char * frame_cb) {
-+ Gaim2PluginUiInfo *ui_info;
-
-- ui_info = g_new0(GaimPluginUiInfo, 1);
-+ ui_info = g_new0(Gaim2PluginUiInfo, 1);
- perl_plugin_pref_cb = g_strdup(frame_cb);
-- ui_info->get_plugin_pref_frame = gaim_perl_get_plugin_frame;
-+ ui_info->get_plugin_pref_frame = gaim2_perl_get_plugin_frame;
-
- return ui_info;
- }
-
--GaimPluginPrefFrame *gaim_perl_get_plugin_frame(GaimPlugin *plugin) {
-+Gaim2PluginPrefFrame *gaim2_perl_get_plugin_frame(Gaim2Plugin *plugin) {
- /* Sets up the Perl Stack for our call back into the script to run the */
- /* plugin_pref... sub */
-- GaimPluginPrefFrame *ret_frame;
-+ Gaim2PluginPrefFrame *ret_frame;
- dSP;
- int count;
-
-@@ -142,7 +142,7 @@ GaimPluginPrefFrame *gaim_perl_get_plugi
- if (count != 1)
- croak("call_pv: Did not return the correct number of values.\n");
- /* the frame was created in a perl sub and is returned */
-- ret_frame = (GaimPluginPrefFrame *)gaim_perl_ref_object(POPs);
-+ ret_frame = (Gaim2PluginPrefFrame *)gaim2_perl_ref_object(POPs);
-
- /* Tidy up the Perl stack */
- PUTBACK;
-@@ -153,7 +153,7 @@ GaimPluginPrefFrame *gaim_perl_get_plugi
- }
-
- static void
--destroy_timeout_handler(GaimPerlTimeoutHandler *handler)
-+destroy_timeout_handler(Gaim2PerlTimeoutHandler *handler)
- {
- timeout_handlers = g_list_remove(timeout_handlers, handler);
-
-@@ -167,7 +167,7 @@ destroy_timeout_handler(GaimPerlTimeoutH
- }
-
- static void
--destroy_signal_handler(GaimPerlSignalHandler *handler)
-+destroy_signal_handler(Gaim2PerlSignalHandler *handler)
- {
- signal_handlers = g_list_remove(signal_handlers, handler);
-
-@@ -184,7 +184,7 @@ destroy_signal_handler(GaimPerlSignalHan
- static int
- perl_timeout_cb(gpointer data)
- {
-- GaimPerlTimeoutHandler *handler = (GaimPerlTimeoutHandler *)data;
-+ Gaim2PerlTimeoutHandler *handler = (Gaim2PerlTimeoutHandler *)data;
-
- dSP;
- ENTER;
-@@ -209,12 +209,12 @@ typedef void *DATATYPE;
- static void *
- perl_signal_cb(va_list args, void *data)
- {
-- GaimPerlSignalHandler *handler = (GaimPerlSignalHandler *)data;
-+ Gaim2PerlSignalHandler *handler = (Gaim2PerlSignalHandler *)data;
- void *ret_val = NULL;
- int i;
- int count;
- int value_count;
-- GaimValue *ret_value, **values;
-+ Gaim2Value *ret_value, **values;
- SV **sv_args;
- DATATYPE **copy_args;
- STRLEN na;
-@@ -224,7 +224,7 @@ perl_signal_cb(va_list args, void *data)
- SAVETMPS;
- PUSHMARK(sp);
-
-- gaim_signal_get_values(handler->instance, handler->signal,
-+ gaim2_signal_get_values(handler->instance, handler->signal,
- &ret_value, &value_count, &values);
-
- sv_args = g_new(SV *, value_count);
-@@ -232,7 +232,7 @@ perl_signal_cb(va_list args, void *data)
-
- for (i = 0; i < value_count; i++)
- {
-- sv_args[i] = sv_2mortal(gaim_perl_sv_from_vargs(values[i],
-+ sv_args[i] = sv_2mortal(gaim2_perl_sv_from_vargs(values[i],
- (va_list*)&args, &copy_args[i]));
-
- XPUSHs(sv_args[i]);
-@@ -251,7 +251,7 @@ perl_signal_cb(va_list args, void *data)
- if (count != 1)
- croak("Uh oh! call_sv returned %i != 1", i);
- else
-- ret_val = gaim_perl_data_from_sv(ret_value, POPs);
-+ ret_val = gaim2_perl_data_from_sv(ret_value, POPs);
- }
- else
- {
-@@ -262,16 +262,16 @@ perl_signal_cb(va_list args, void *data)
-
- if (SvTRUE(ERRSV))
- {
-- gaim_debug_error("perl", "Perl function exited abnormally: %s\n",
-+ gaim2_debug_error("perl", "Perl function exited abnormally: %s\n",
- SvPV(ERRSV, na));
- }
-
- /* See if any parameters changed. */
- for (i = 0; i < value_count; i++)
- {
-- if (gaim_value_is_outgoing(values[i]))
-+ if (gaim2_value_is_outgoing(values[i]))
- {
-- switch (gaim_value_get_type(values[i]))
-+ switch (gaim2_value_get_type(values[i]))
- {
- case GAIM_TYPE_BOOLEAN:
- *((gboolean *)copy_args[i]) = SvIV(sv_args[i]);
-@@ -323,7 +323,7 @@ perl_signal_cb(va_list args, void *data)
- }
-
- #if 0
-- *((void **)copy_args[i]) = gaim_perl_data_from_sv(values[i],
-+ *((void **)copy_args[i]) = gaim2_perl_data_from_sv(values[i],
- sv_args[i]);
- #endif
- }
-@@ -336,20 +336,20 @@ perl_signal_cb(va_list args, void *data)
- g_free(sv_args);
- g_free(copy_args);
-
-- gaim_debug_misc("perl", "ret_val = %p\n", ret_val);
-+ gaim2_debug_misc("perl", "ret_val = %p\n", ret_val);
-
- return ret_val;
- }
-
--static GaimPerlSignalHandler *
--find_signal_handler(GaimPlugin *plugin, void *instance, const char *signal)
-+static Gaim2PerlSignalHandler *
-+find_signal_handler(Gaim2Plugin *plugin, void *instance, const char *signal)
- {
-- GaimPerlSignalHandler *handler;
-+ Gaim2PerlSignalHandler *handler;
- GList *l;
-
- for (l = signal_handlers; l != NULL; l = l->next)
- {
-- handler = (GaimPerlSignalHandler *)l->data;
-+ handler = (Gaim2PerlSignalHandler *)l->data;
-
- if (handler->plugin == plugin &&
- handler->instance == instance &&
-@@ -363,9 +363,9 @@ find_signal_handler(GaimPlugin *plugin,
- }
-
- void
--gaim_perl_timeout_add(GaimPlugin *plugin, int seconds, SV *callback, SV *data)
-+gaim2_perl_timeout_add(Gaim2Plugin *plugin, int seconds, SV *callback, SV *data)
- {
-- GaimPerlTimeoutHandler *handler;
-+ Gaim2PerlTimeoutHandler *handler;
-
- if (plugin == NULL)
- {
-@@ -373,7 +373,7 @@ gaim_perl_timeout_add(GaimPlugin *plugin
- return;
- }
-
-- handler = g_new0(GaimPerlTimeoutHandler, 1);
-+ handler = g_new0(Gaim2PerlTimeoutHandler, 1);
-
- handler->plugin = plugin;
- handler->callback = (callback != NULL && callback != &PL_sv_undef
-@@ -387,16 +387,16 @@ gaim_perl_timeout_add(GaimPlugin *plugin
- }
-
- void
--gaim_perl_timeout_clear_for_plugin(GaimPlugin *plugin)
-+gaim2_perl_timeout_clear_for_plugin(Gaim2Plugin *plugin)
- {
-- GaimPerlTimeoutHandler *handler;
-+ Gaim2PerlTimeoutHandler *handler;
- GList *l, *l_next;
-
- for (l = timeout_handlers; l != NULL; l = l_next)
- {
- l_next = l->next;
-
-- handler = (GaimPerlTimeoutHandler *)l->data;
-+ handler = (Gaim2PerlTimeoutHandler *)l->data;
-
- if (handler->plugin == plugin)
- destroy_timeout_handler(handler);
-@@ -404,19 +404,19 @@ gaim_perl_timeout_clear_for_plugin(GaimP
- }
-
- void
--gaim_perl_timeout_clear(void)
-+gaim2_perl_timeout_clear(void)
- {
- while (timeout_handlers != NULL)
- destroy_timeout_handler(timeout_handlers->data);
- }
-
- void
--gaim_perl_signal_connect(GaimPlugin *plugin, void *instance,
-+gaim2_perl_signal_connect(Gaim2Plugin *plugin, void *instance,
- const char *signal, SV *callback, SV *data)
- {
-- GaimPerlSignalHandler *handler;
-+ Gaim2PerlSignalHandler *handler;
-
-- handler = g_new0(GaimPerlSignalHandler, 1);
-+ handler = g_new0(Gaim2PerlSignalHandler, 1);
- handler->plugin = plugin;
- handler->instance = instance;
- handler->signal = g_strdup(signal);
-@@ -427,15 +427,15 @@ gaim_perl_signal_connect(GaimPlugin *plu
-
- signal_handlers = g_list_append(signal_handlers, handler);
-
-- gaim_signal_connect_vargs(instance, signal,
-+ gaim2_signal_connect_vargs(instance, signal,
- plugin, GAIM_CALLBACK(perl_signal_cb), handler);
- }
-
- void
--gaim_perl_signal_disconnect(GaimPlugin *plugin, void *instance,
-+gaim2_perl_signal_disconnect(Gaim2Plugin *plugin, void *instance,
- const char *signal)
- {
-- GaimPerlSignalHandler *handler;
-+ Gaim2PerlSignalHandler *handler;
-
- handler = find_signal_handler(plugin, instance, signal);
-
-@@ -450,16 +450,16 @@ gaim_perl_signal_disconnect(GaimPlugin *
- }
-
- void
--gaim_perl_signal_clear_for_plugin(GaimPlugin *plugin)
-+gaim2_perl_signal_clear_for_plugin(Gaim2Plugin *plugin)
- {
-- GaimPerlSignalHandler *handler;
-+ Gaim2PerlSignalHandler *handler;
- GList *l, *l_next;
-
- for (l = signal_handlers; l != NULL; l = l_next)
- {
- l_next = l->next;
-
-- handler = (GaimPerlSignalHandler *)l->data;
-+ handler = (Gaim2PerlSignalHandler *)l->data;
-
- if (handler->plugin == plugin)
- destroy_signal_handler(handler);
-@@ -467,7 +467,7 @@ gaim_perl_signal_clear_for_plugin(GaimPl
- }
-
- void
--gaim_perl_signal_clear(void)
-+gaim2_perl_signal_clear(void)
- {
- while (signal_handlers != NULL)
- destroy_signal_handler(signal_handlers->data);
-diff -prNu ./plugins/perl/perl-handlers.h ./plugins/perl/perl-handlers.h
---- ./plugins/perl/perl-handlers.h 2005-07-29 15:37:59.000000000 +0200
-+++ ./plugins/perl/perl-handlers.h 2006-01-05 15:27:48.000000000 +0100
-@@ -8,18 +8,18 @@
- #include "gtkutils.h"
-
- /* TODO: Find a better way to access the perl names from the plugin prober */
--/* and store them for gaim_perl_plugin_action_* functions. */
--char * gaim_perl_plugin_action_callback_sub;
--char * gaim_perl_plugin_action_label;
-+/* and store them for gaim2_perl_plugin_action_* functions. */
-+char * gaim2_perl_plugin_action_callback_sub;
-+char * gaim2_perl_plugin_action_label;
-
- typedef struct
- {
- SV *callback;
- SV *data;
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- int iotag;
-
--} GaimPerlTimeoutHandler;
-+} Gaim2PerlTimeoutHandler;
-
- typedef struct
- {
-@@ -27,30 +27,30 @@ typedef struct
- SV *callback;
- SV *data;
- void *instance;
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
-
--} GaimPerlSignalHandler;
-+} Gaim2PerlSignalHandler;
-
--void gaim_perl_plugin_action_cb(GaimPluginAction * gpa);
--GList *gaim_perl_plugin_action(GaimPlugin *plugin, gpointer context);
-+void gaim2_perl_plugin_action_cb(Gaim2PluginAction * gpa);
-+GList *gaim2_perl_plugin_action(Gaim2Plugin *plugin, gpointer context);
-
--GaimPluginUiInfo *gaim_perl_plugin_pref(const char * frame_cb);
--GaimPluginPrefFrame *gaim_perl_get_plugin_frame(GaimPlugin *plugin);
-+Gaim2PluginUiInfo *gaim2_perl_plugin_pref(const char * frame_cb);
-+Gaim2PluginPrefFrame *gaim2_perl_get_plugin_frame(Gaim2Plugin *plugin);
-
--GaimGtkPluginUiInfo *gaim_perl_gtk_plugin_pref(const char * frame_cb);
--GtkWidget *gaim_perl_gtk_get_plugin_frame(GaimPlugin *plugin);
-+Gaim2GtkPluginUiInfo *gaim2_perl_gtk_plugin_pref(const char * frame_cb);
-+GtkWidget *gaim2_perl_gtk_get_plugin_frame(Gaim2Plugin *plugin);
-
--void gaim_perl_timeout_add(GaimPlugin *plugin, int seconds, SV *callback,
-+void gaim2_perl_timeout_add(Gaim2Plugin *plugin, int seconds, SV *callback,
- SV *data);
--void gaim_perl_timeout_clear_for_plugin(GaimPlugin *plugin);
--void gaim_perl_timeout_clear(void);
-+void gaim2_perl_timeout_clear_for_plugin(Gaim2Plugin *plugin);
-+void gaim2_perl_timeout_clear(void);
-
--void gaim_perl_signal_connect(GaimPlugin *plugin, void *instance,
-+void gaim2_perl_signal_connect(Gaim2Plugin *plugin, void *instance,
- const char *signal, SV *callback,
- SV *data);
--void gaim_perl_signal_disconnect(GaimPlugin *plugin, void *instance,
-+void gaim2_perl_signal_disconnect(Gaim2Plugin *plugin, void *instance,
- const char *signal);
--void gaim_perl_signal_clear_for_plugin(GaimPlugin *plugin);
--void gaim_perl_signal_clear(void);
-+void gaim2_perl_signal_clear_for_plugin(Gaim2Plugin *plugin);
-+void gaim2_perl_signal_clear(void);
-
- #endif /* _GAIM_PERL_HANDLERS_H_ */
-diff -prNu ./plugins/pluginpref_example.c ./plugins/pluginpref_example.c
---- ./plugins/pluginpref_example.c 2005-12-05 23:50:03.000000000 +0100
-+++ ./plugins/pluginpref_example.c 2006-01-05 15:27:38.000000000 +0100
-@@ -34,84 +34,84 @@
- #include "prefs.h"
- #include "version.h"
-
--static GaimPluginPrefFrame *
--get_plugin_pref_frame(GaimPlugin *plugin) {
-- GaimPluginPrefFrame *frame;
-- GaimPluginPref *ppref;
-+static Gaim2PluginPrefFrame *
-+get_plugin_pref_frame(Gaim2Plugin *plugin) {
-+ Gaim2PluginPrefFrame *frame;
-+ Gaim2PluginPref *ppref;
-
-- frame = gaim_plugin_pref_frame_new();
-+ frame = gaim2_plugin_pref_frame_new();
-
-- ppref = gaim_plugin_pref_new_with_label("boolean");
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label("boolean");
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/bool",
- "boolean pref");
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_label("integer");
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label("integer");
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/int",
- "integer pref");
-- gaim_plugin_pref_set_bounds(ppref, 0, 255);
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_set_bounds(ppref, 0, 255);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/int_choice",
- "integer choice");
-- gaim_plugin_pref_set_type(ppref, GAIM_PLUGIN_PREF_CHOICE);
-- gaim_plugin_pref_add_choice(ppref, "One", GINT_TO_POINTER(1));
-- gaim_plugin_pref_add_choice(ppref, "Two", GINT_TO_POINTER(2));
-- gaim_plugin_pref_add_choice(ppref, "Four", GINT_TO_POINTER(4));
-- gaim_plugin_pref_add_choice(ppref, "Eight", GINT_TO_POINTER(8));
-- gaim_plugin_pref_add_choice(ppref, "Sixteen", GINT_TO_POINTER(16));
-- gaim_plugin_pref_add_choice(ppref, "Thirty Two", GINT_TO_POINTER(32));
-- gaim_plugin_pref_add_choice(ppref, "Sixty Four", GINT_TO_POINTER(64));
-- gaim_plugin_pref_add_choice(ppref, "One Hundred Twenty Eight", GINT_TO_POINTER(128));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_set_type(ppref, GAIM_PLUGIN_PREF_CHOICE);
-+ gaim2_plugin_pref_add_choice(ppref, "One", GINT_TO_POINTER(1));
-+ gaim2_plugin_pref_add_choice(ppref, "Two", GINT_TO_POINTER(2));
-+ gaim2_plugin_pref_add_choice(ppref, "Four", GINT_TO_POINTER(4));
-+ gaim2_plugin_pref_add_choice(ppref, "Eight", GINT_TO_POINTER(8));
-+ gaim2_plugin_pref_add_choice(ppref, "Sixteen", GINT_TO_POINTER(16));
-+ gaim2_plugin_pref_add_choice(ppref, "Thirty Two", GINT_TO_POINTER(32));
-+ gaim2_plugin_pref_add_choice(ppref, "Sixty Four", GINT_TO_POINTER(64));
-+ gaim2_plugin_pref_add_choice(ppref, "One Hundred Twenty Eight", GINT_TO_POINTER(128));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_label("string");
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label("string");
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/string",
- "string pref");
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/masked_string",
- "masked string");
-- gaim_plugin_pref_set_masked(ppref, TRUE);
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_set_masked(ppref, TRUE);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/max_string",
- "string pref\n(max length of 16)");
-- gaim_plugin_pref_set_max_length(ppref, 16);
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_set_max_length(ppref, 16);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/core/pluginpref_example/string_choice",
- "string choice");
-- gaim_plugin_pref_set_type(ppref, GAIM_PLUGIN_PREF_CHOICE);
-- gaim_plugin_pref_add_choice(ppref, "red", "red");
-- gaim_plugin_pref_add_choice(ppref, "orange", "orange");
-- gaim_plugin_pref_add_choice(ppref, "yellow", "yellow");
-- gaim_plugin_pref_add_choice(ppref, "green", "green");
-- gaim_plugin_pref_add_choice(ppref, "blue", "blue");
-- gaim_plugin_pref_add_choice(ppref, "purple", "purple");
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_set_type(ppref, GAIM_PLUGIN_PREF_CHOICE);
-+ gaim2_plugin_pref_add_choice(ppref, "red", "red");
-+ gaim2_plugin_pref_add_choice(ppref, "orange", "orange");
-+ gaim2_plugin_pref_add_choice(ppref, "yellow", "yellow");
-+ gaim2_plugin_pref_add_choice(ppref, "green", "green");
-+ gaim2_plugin_pref_add_choice(ppref, "blue", "blue");
-+ gaim2_plugin_pref_add_choice(ppref, "purple", "purple");
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
- return frame;
- }
-
--static GaimPluginUiInfo prefs_info = {
-+static Gaim2PluginUiInfo prefs_info = {
- get_plugin_pref_frame
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -143,18 +143,18 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/core/pluginpref_example");
-- gaim_prefs_add_bool("/plugins/core/pluginpref_example/bool", TRUE);
-- gaim_prefs_add_int("/plugins/core/pluginpref_example/int", 0);
-- gaim_prefs_add_int("/plugins/core/pluginpref_example/int_choice", 1);
-- gaim_prefs_add_string("/plugins/core/pluginpref_example/string",
-+ gaim2_prefs_add_none("/plugins/core/pluginpref_example");
-+ gaim2_prefs_add_bool("/plugins/core/pluginpref_example/bool", TRUE);
-+ gaim2_prefs_add_int("/plugins/core/pluginpref_example/int", 0);
-+ gaim2_prefs_add_int("/plugins/core/pluginpref_example/int_choice", 1);
-+ gaim2_prefs_add_string("/plugins/core/pluginpref_example/string",
- "string");
-- gaim_prefs_add_string("/plugins/core/pluginpref_example/max_string",
-+ gaim2_prefs_add_string("/plugins/core/pluginpref_example/max_string",
- "max length string");
-- gaim_prefs_add_string("/plugins/core/pluginpref_example/masked_string", "masked");
-- gaim_prefs_add_string("/plugins/core/pluginpref_example/string_choice", "red");
-+ gaim2_prefs_add_string("/plugins/core/pluginpref_example/masked_string", "masked");
-+ gaim2_prefs_add_string("/plugins/core/pluginpref_example/string_choice", "red");
- }
-
- GAIM_INIT_PLUGIN(ppexample, init_plugin, info)
-diff -prNu ./plugins/raw.c ./plugins/raw.c
---- ./plugins/raw.c 2005-11-09 04:09:55.000000000 +0100
-+++ ./plugins/raw.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * Gaim - Send raw data across the connections of some protocols.
-+ * Gaim2 - Send raw data across the connections of some protocols.
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -22,7 +22,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "conversation.h"
- #include "debug.h"
-@@ -43,13 +43,13 @@
- #define RAW_PLUGIN_ID "gtk-raw"
-
- static GtkWidget *window = NULL;
--static GaimAccount *account = NULL;
--static GaimPlugin *my_plugin = NULL;
-+static Gaim2Account *account = NULL;
-+static Gaim2Plugin *my_plugin = NULL;
-
- static int
- window_closed_cb()
- {
-- gaim_plugin_unload(my_plugin);
-+ gaim2_plugin_unload(my_plugin);
-
- return FALSE;
- }
-@@ -58,19 +58,19 @@ static void
- text_sent_cb(GtkEntry *entry)
- {
- const char *txt;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *prpl_id;
-
- if (account == NULL)
- return;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- txt = gtk_entry_get_text(entry);
-
-- prpl_id = gaim_account_get_protocol_id(account);
-+ prpl_id = gaim2_account_get_protocol_id(account);
-
-- gaim_debug_misc("raw", "prpl_id = %s\n", prpl_id);
-+ gaim2_debug_misc("raw", "prpl_id = %s\n", prpl_id);
-
- if (strcmp(prpl_id, "prpl-toc") == 0) {
- int *a = (int *)gc->proto_data;
-@@ -80,7 +80,7 @@ text_sent_cb(GtkEntry *entry)
- write(*a, &seqno, 2);
- write(*a, &len, 2);
- write(*a, txt, ntohs(len));
-- gaim_debug(GAIM_DEBUG_MISC, "raw", "TOC C: %s\n", txt);
-+ gaim2_debug(GAIM_DEBUG_MISC, "raw", "TOC C: %s\n", txt);
-
- } else if (strcmp(prpl_id, "prpl-msn") == 0) {
- MsnSession *session = gc->proto_data;
-@@ -92,27 +92,27 @@ text_sent_cb(GtkEntry *entry)
- } else if (strcmp(prpl_id, "prpl-irc") == 0) {
- write(*(int *)gc->proto_data, txt, strlen(txt));
- write(*(int *)gc->proto_data, "\r\n", 2);
-- gaim_debug(GAIM_DEBUG_MISC, "raw", "IRC C: %s\n", txt);
-+ gaim2_debug(GAIM_DEBUG_MISC, "raw", "IRC C: %s\n", txt);
-
- } else if (strcmp(prpl_id, "prpl-jabber") == 0) {
- jabber_send_raw((JabberStream *)gc->proto_data, txt, -1);
-
- } else {
-- gaim_debug_error("raw", "Unknown protocol ID %s\n", prpl_id);
-+ gaim2_debug_error("raw", "Unknown protocol ID %s\n", prpl_id);
- }
-
- gtk_entry_set_text(entry, "");
- }
-
- static void
--account_changed_cb(GtkWidget *dropdown, GaimAccount *new_account,
-+account_changed_cb(GtkWidget *dropdown, Gaim2Account *new_account,
- void *user_data)
- {
- account = new_account;
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- GtkWidget *hbox;
- GtkWidget *entry;
-@@ -130,11 +130,11 @@ plugin_load(GaimPlugin *plugin)
- gtk_container_add(GTK_CONTAINER(window), hbox);
-
- /* Account drop-down menu. */
-- dropdown = gaim_gtk_account_option_menu_new(NULL, FALSE,
-+ dropdown = gaim2_gtk_account_option_menu_new(NULL, FALSE,
- G_CALLBACK(account_changed_cb), NULL, NULL);
-
-- if (gaim_connections_get_all())
-- account = (GaimAccount *)gaim_connections_get_all()->data;
-+ if (gaim2_connections_get_all())
-+ account = (Gaim2Account *)gaim2_connections_get_all()->data;
-
- gtk_box_pack_start(GTK_BOX(hbox), dropdown, FALSE, FALSE, 0);
-
-@@ -151,7 +151,7 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- if (window)
- gtk_widget_destroy(window);
-@@ -161,7 +161,7 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -189,7 +189,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- my_plugin = plugin;
- }
-diff -prNu ./plugins/relnot.c ./plugins/relnot.c
---- ./plugins/relnot.c 2004-09-03 23:21:20.000000000 +0200
-+++ ./plugins/relnot.c 2006-01-05 15:27:38.000000000 +0100
-@@ -60,22 +60,22 @@ version_fetch_cb(void *ud, const char *d
- while(*changelog == '\n') changelog++;
-
- message = g_string_new("");
-- g_string_append_printf(message, _("You are using Gaim version %s. The "
-+ g_string_append_printf(message, _("You are using Gaim2 version %s. The "
- "current version is %s.<hr>"),
-- gaim_core_get_version(), cur_ver);
-+ gaim2_core_get_version(), cur_ver);
-
- if(*changelog) {
-- formatted = gaim_strdup_withhtml(changelog);
-+ formatted = gaim2_strdup_withhtml(changelog);
- g_string_append_printf(message, _("<b>ChangeLog:</b>\n%s<br><br>"),
- formatted);
- g_free(formatted);
- }
-
- g_string_append_printf(message, _("You can get version %s from:<br>"
-- "<a href=\"http://gaim.sourceforge.net/\">"
-- "http://gaim.sourceforge.net</a>."), cur_ver);
-+ "<a href=\"http://gaim2.sourceforge.net/\">"
-+ "http://gaim2.sourceforge.net</a>."), cur_ver);
-
-- gaim_notify_formatted(NULL, _("New Version Available"),
-+ gaim2_notify_formatted(NULL, _("New Version Available"),
- _("New Version Available"), NULL, message->str,
- NULL, NULL);
-
-@@ -86,23 +86,23 @@ version_fetch_cb(void *ud, const char *d
- static void
- do_check(void)
- {
-- int last_check = gaim_prefs_get_int("/plugins/gtk/relnot/last_check");
-+ int last_check = gaim2_prefs_get_int("/plugins/gtk/relnot/last_check");
- if(!last_check || time(NULL) - last_check > MIN_CHECK_INTERVAL) {
-- char *url = g_strdup_printf("http://gaim.sourceforge.net/version.php?version=%s&build=%s", gaim_core_get_version(),
-+ char *url = g_strdup_printf("http://gaim2.sourceforge.net/version.php?version=%s&build=%s", gaim2_core_get_version(),
- #ifdef _WIN32
-- "gaim-win32"
-+ "gaim2-win32"
- #else
-- "gaim"
-+ "gaim2"
- #endif
- );
-- gaim_url_fetch(url, TRUE, NULL, FALSE, version_fetch_cb, NULL);
-- gaim_prefs_set_int("/plugins/gtk/relnot/last_check", time(NULL));
-+ gaim2_url_fetch(url, TRUE, NULL, FALSE, version_fetch_cb, NULL);
-+ gaim2_prefs_set_int("/plugins/gtk/relnot/last_check", time(NULL));
- g_free(url);
- }
- }
-
- static void
--signed_on_cb(GaimConnection *gc, void *data) {
-+signed_on_cb(Gaim2Connection *gc, void *data) {
- do_check();
- }
-
-@@ -110,19 +110,19 @@ signed_on_cb(GaimConnection *gc, void *d
- * Plugin stuff
- **************************************************************************/
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- plugin, GAIM_CALLBACK(signed_on_cb), NULL);
-
- /* we don't check if we're offline */
-- if(gaim_connections_get_all())
-+ if(gaim2_connections_get_all())
- do_check();
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -155,10 +155,10 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk/relnot");
-- gaim_prefs_add_int("/plugins/gtk/relnot/last_check", 0);
-+ gaim2_prefs_add_none("/plugins/gtk/relnot");
-+ gaim2_prefs_add_int("/plugins/gtk/relnot/last_check", 0);
- }
-
- GAIM_INIT_PLUGIN(relnot, init_plugin, info)
-diff -prNu ./plugins/signals-test.c ./plugins/signals-test.c
---- ./plugins/signals-test.c 2005-12-23 06:13:52.000000000 +0100
-+++ ./plugins/signals-test.c 2006-01-05 15:27:38.000000000 +0100
-@@ -38,129 +38,129 @@
- * Account subsystem signal callbacks
- **************************************************************************/
- static void
--account_connecting_cb(GaimAccount *account, void *data)
-+account_connecting_cb(Gaim2Account *account, void *data)
- {
-- gaim_debug_misc("signals test", "account-connecting (%s)\n",
-- gaim_account_get_username(account));
-+ gaim2_debug_misc("signals test", "account-connecting (%s)\n",
-+ gaim2_account_get_username(account));
- }
-
- static void
--account_setting_info_cb(GaimAccount *account, const char *info, void *data)
-+account_setting_info_cb(Gaim2Account *account, const char *info, void *data)
- {
-- gaim_debug_misc("signals test", "account-setting-info (%s, %s)\n",
-- gaim_account_get_username(account), info);
-+ gaim2_debug_misc("signals test", "account-setting-info (%s, %s)\n",
-+ gaim2_account_get_username(account), info);
- }
-
- static void
--account_set_info_cb(GaimAccount *account, const char *info, void *data)
-+account_set_info_cb(Gaim2Account *account, const char *info, void *data)
- {
-- gaim_debug_misc("signals test", "account-set-info (%s, %s)\n",
-- gaim_account_get_username(account), info);
-+ gaim2_debug_misc("signals test", "account-set-info (%s, %s)\n",
-+ gaim2_account_get_username(account), info);
- }
-
- static void
--account_status_changed(GaimAccount *account, GaimStatus *old, GaimStatus *new,
-+account_status_changed(Gaim2Account *account, Gaim2Status *old, Gaim2Status *new,
- gpointer data)
- {
-- gaim_debug_misc("signals test", "account-status-changed (%s, %s, %s)\n",
-- gaim_account_get_username(account),
-- gaim_status_get_name(old),
-- gaim_status_get_name(new));
-+ gaim2_debug_misc("signals test", "account-status-changed (%s, %s, %s)\n",
-+ gaim2_account_get_username(account),
-+ gaim2_status_get_name(old),
-+ gaim2_status_get_name(new));
- }
-
- /**************************************************************************
- * Buddy Icons signal callbacks
- **************************************************************************/
- static void
--buddy_icon_changed_cb(GaimBuddy *buddy)
-+buddy_icon_changed_cb(Gaim2Buddy *buddy)
- {
-- gaim_debug_misc("signals test", "buddy icon changed (%s)\n",
-- gaim_buddy_get_name(buddy));
-+ gaim2_debug_misc("signals test", "buddy icon changed (%s)\n",
-+ gaim2_buddy_get_name(buddy));
- }
-
- /**************************************************************************
- * Buddy List subsystem signal callbacks
- **************************************************************************/
- static void
--buddy_status_changed_cb(GaimBuddy *buddy, GaimStatus *old_status,
-- GaimStatus *status, void *data)
-+buddy_status_changed_cb(Gaim2Buddy *buddy, Gaim2Status *old_status,
-+ Gaim2Status *status, void *data)
- {
-- gaim_debug_misc("signals test", "buddy-status-changed (%s %s to %s)\n",
-- buddy->name, gaim_status_get_id(old_status),
-- gaim_status_get_id(status));
-+ gaim2_debug_misc("signals test", "buddy-status-changed (%s %s to %s)\n",
-+ buddy->name, gaim2_status_get_id(old_status),
-+ gaim2_status_get_id(status));
- }
-
- static void
--buddy_idle_changed_cb(GaimBuddy *buddy, gboolean old_idle, gboolean idle,
-+buddy_idle_changed_cb(Gaim2Buddy *buddy, gboolean old_idle, gboolean idle,
- void *data)
- {
-- gaim_debug_misc("signals test", "buddy-idle-changed (%s %s)\n",
-+ gaim2_debug_misc("signals test", "buddy-idle-changed (%s %s)\n",
- buddy->name, old_idle ? "unidled" : "idled");
- }
-
- static void
--buddy_signed_on_cb(GaimBuddy *buddy, void *data)
-+buddy_signed_on_cb(Gaim2Buddy *buddy, void *data)
- {
-- gaim_debug_misc("signals test", "buddy-signed-on (%s)\n", buddy->name);
-+ gaim2_debug_misc("signals test", "buddy-signed-on (%s)\n", buddy->name);
- }
-
- static void
--buddy_signed_off_cb(GaimBuddy *buddy, void *data)
-+buddy_signed_off_cb(Gaim2Buddy *buddy, void *data)
- {
-- gaim_debug_misc("signals test", "buddy-signed-off (%s)\n", buddy->name);
-+ gaim2_debug_misc("signals test", "buddy-signed-off (%s)\n", buddy->name);
- }
-
- static void
--buddy_added_cb(GaimBuddy *buddy, void *data)
-+buddy_added_cb(Gaim2Buddy *buddy, void *data)
- {
-- gaim_debug_misc("signals test", "buddy_added_cb (%s)\n", gaim_buddy_get_name(buddy));
-+ gaim2_debug_misc("signals test", "buddy_added_cb (%s)\n", gaim2_buddy_get_name(buddy));
- }
-
- static void
--buddy_removed_cb(GaimBuddy *buddy, void *data)
-+buddy_removed_cb(Gaim2Buddy *buddy, void *data)
- {
-- gaim_debug_misc("signals test", "buddy_removed_cb (%s)\n", gaim_buddy_get_name(buddy));
-+ gaim2_debug_misc("signals test", "buddy_removed_cb (%s)\n", gaim2_buddy_get_name(buddy));
- }
-
- static void
--blist_node_aliased(GaimBlistNode *node, const char *old_alias)
-+blist_node_aliased(Gaim2BlistNode *node, const char *old_alias)
- {
-- GaimContact *p = (GaimContact *)node;
-- GaimBuddy *b = (GaimBuddy *)node;
-- GaimChat *c = (GaimChat *)node;
-- GaimGroup *g = (GaimGroup *)node;
-+ Gaim2Contact *p = (Gaim2Contact *)node;
-+ Gaim2Buddy *b = (Gaim2Buddy *)node;
-+ Gaim2Chat *c = (Gaim2Chat *)node;
-+ Gaim2Group *g = (Gaim2Group *)node;
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
-- gaim_debug_misc("signals test", "blist-node-aliased (Contact: %s, %s)\n", p->alias, old_alias);
-+ gaim2_debug_misc("signals test", "blist-node-aliased (Contact: %s, %s)\n", p->alias, old_alias);
- else if (GAIM_BLIST_NODE_IS_BUDDY(node))
-- gaim_debug_misc("signals test", "blist-node-aliased (Buddy: %s, %s)\n", b->name, old_alias);
-+ gaim2_debug_misc("signals test", "blist-node-aliased (Buddy: %s, %s)\n", b->name, old_alias);
- else if (GAIM_BLIST_NODE_IS_CHAT(node))
-- gaim_debug_misc("signals test", "blist-node-aliased (Chat: %s, %s)\n", c->alias, old_alias);
-+ gaim2_debug_misc("signals test", "blist-node-aliased (Chat: %s, %s)\n", c->alias, old_alias);
- else if (GAIM_BLIST_NODE_IS_GROUP(node))
-- gaim_debug_misc("signals test", "blist-node-aliased (Group: %s, %s)\n", g->name, old_alias);
-+ gaim2_debug_misc("signals test", "blist-node-aliased (Group: %s, %s)\n", g->name, old_alias);
- else
-- gaim_debug_misc("signals test", "blist-node-aliased (UNKNOWN: %d, %s)\n", node->type, old_alias);
-+ gaim2_debug_misc("signals test", "blist-node-aliased (UNKNOWN: %d, %s)\n", node->type, old_alias);
-
- }
-
- static void
--blist_node_extended_menu_cb(GaimBlistNode *node, void *data)
-+blist_node_extended_menu_cb(Gaim2BlistNode *node, void *data)
- {
-- GaimContact *p = (GaimContact *)node;
-- GaimBuddy *b = (GaimBuddy *)node;
-- GaimChat *c = (GaimChat *)node;
-- GaimGroup *g = (GaimGroup *)node;
-+ Gaim2Contact *p = (Gaim2Contact *)node;
-+ Gaim2Buddy *b = (Gaim2Buddy *)node;
-+ Gaim2Chat *c = (Gaim2Chat *)node;
-+ Gaim2Group *g = (Gaim2Group *)node;
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
-- gaim_debug_misc("signals test", "blist-node-extended-menu (Contact: %s)\n", p->alias);
-+ gaim2_debug_misc("signals test", "blist-node-extended-menu (Contact: %s)\n", p->alias);
- else if (GAIM_BLIST_NODE_IS_BUDDY(node))
-- gaim_debug_misc("signals test", "blist-node-extended-menu (Buddy: %s)\n", b->name);
-+ gaim2_debug_misc("signals test", "blist-node-extended-menu (Buddy: %s)\n", b->name);
- else if (GAIM_BLIST_NODE_IS_CHAT(node))
-- gaim_debug_misc("signals test", "blist-node-extended-menu (Chat: %s)\n", c->alias);
-+ gaim2_debug_misc("signals test", "blist-node-extended-menu (Chat: %s)\n", c->alias);
- else if (GAIM_BLIST_NODE_IS_GROUP(node))
-- gaim_debug_misc("signals test", "blist-node-extended-menu (Group: %s)\n", g->name);
-+ gaim2_debug_misc("signals test", "blist-node-extended-menu (Group: %s)\n", g->name);
- else
-- gaim_debug_misc("signals test", "blist-node-extended-menu (UNKNOWN: %d)\n", node->type);
-+ gaim2_debug_misc("signals test", "blist-node-extended-menu (UNKNOWN: %d)\n", node->type);
-
- }
-
-@@ -169,279 +169,279 @@ blist_node_extended_menu_cb(GaimBlistNod
- * Connection subsystem signal callbacks
- **************************************************************************/
- static void
--signing_on_cb(GaimConnection *gc, void *data)
-+signing_on_cb(Gaim2Connection *gc, void *data)
- {
-- gaim_debug_misc("signals test", "signing-on (%s)\n",
-- gaim_account_get_username(gaim_connection_get_account(gc)));
-+ gaim2_debug_misc("signals test", "signing-on (%s)\n",
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)));
- }
-
- static void
--signed_on_cb(GaimConnection *gc, void *data)
-+signed_on_cb(Gaim2Connection *gc, void *data)
- {
-- gaim_debug_misc("signals test", "signed-on (%s)\n",
-- gaim_account_get_username(gaim_connection_get_account(gc)));
-+ gaim2_debug_misc("signals test", "signed-on (%s)\n",
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)));
- }
-
- static void
--signing_off_cb(GaimConnection *gc, void *data)
-+signing_off_cb(Gaim2Connection *gc, void *data)
- {
-- gaim_debug_misc("signals test", "signing-off (%s)\n",
-- gaim_account_get_username(gaim_connection_get_account(gc)));
-+ gaim2_debug_misc("signals test", "signing-off (%s)\n",
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)));
- }
-
- static void
--signed_off_cb(GaimConnection *gc, void *data)
-+signed_off_cb(Gaim2Connection *gc, void *data)
- {
-- gaim_debug_misc("signals test", "signed-off (%s)\n",
-- gaim_account_get_username(gaim_connection_get_account(gc)));
-+ gaim2_debug_misc("signals test", "signed-off (%s)\n",
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)));
- }
-
- /**************************************************************************
- * Conversation subsystem signal callbacks
- **************************************************************************/
- static gboolean
--writing_im_msg_cb(GaimAccount *account, GaimConversation *conv, char **buffer, void *data)
-+writing_im_msg_cb(Gaim2Account *account, Gaim2Conversation *conv, char **buffer, void *data)
- {
-- gaim_debug_misc("signals test", "writing-im-msg (%s, %s, %s)\n",
-- gaim_account_get_username(account), gaim_conversation_get_name(conv), *buffer);
-+ gaim2_debug_misc("signals test", "writing-im-msg (%s, %s, %s)\n",
-+ gaim2_account_get_username(account), gaim2_conversation_get_name(conv), *buffer);
-
- return FALSE;
-
- }
-
- static void
--wrote_im_msg_cb(GaimAccount *account, GaimConversation *conv, const char *buffer, void *data)
-+wrote_im_msg_cb(Gaim2Account *account, Gaim2Conversation *conv, const char *buffer, void *data)
- {
-- gaim_debug_misc("signals test", "wrote-im-msg (%s, %s, %s)\n",
-- gaim_account_get_username(account), gaim_conversation_get_name(conv), buffer);
-+ gaim2_debug_misc("signals test", "wrote-im-msg (%s, %s, %s)\n",
-+ gaim2_account_get_username(account), gaim2_conversation_get_name(conv), buffer);
- }
-
- static void
--sending_im_msg_cb(GaimAccount *account, char *recipient, char **buffer, void *data)
-+sending_im_msg_cb(Gaim2Account *account, char *recipient, char **buffer, void *data)
- {
-- gaim_debug_misc("signals test", "sending-im-msg (%s, %s, %s)\n",
-- gaim_account_get_username(account), recipient, *buffer);
-+ gaim2_debug_misc("signals test", "sending-im-msg (%s, %s, %s)\n",
-+ gaim2_account_get_username(account), recipient, *buffer);
-
- }
-
- static void
--sent_im_msg_cb(GaimAccount *account, const char *recipient, const char *buffer, void *data)
-+sent_im_msg_cb(Gaim2Account *account, const char *recipient, const char *buffer, void *data)
- {
-- gaim_debug_misc("signals test", "sent-im-msg (%s, %s, %s)\n",
-- gaim_account_get_username(account), recipient, buffer);
-+ gaim2_debug_misc("signals test", "sent-im-msg (%s, %s, %s)\n",
-+ gaim2_account_get_username(account), recipient, buffer);
- }
-
- static gboolean
--receiving_im_msg_cb(GaimAccount *account, char **sender, char **buffer,
-- GaimConversation *conv, int *flags, void *data)
-+receiving_im_msg_cb(Gaim2Account *account, char **sender, char **buffer,
-+ Gaim2Conversation *conv, int *flags, void *data)
- {
-- gaim_debug_misc("signals test", "receiving-im-msg (%s, %s, %s, %s, %d)\n",
-- gaim_account_get_username(account), *sender, *buffer,
-- (conv != NULL) ? gaim_conversation_get_name(conv) : "(null)", *flags);
-+ gaim2_debug_misc("signals test", "receiving-im-msg (%s, %s, %s, %s, %d)\n",
-+ gaim2_account_get_username(account), *sender, *buffer,
-+ (conv != NULL) ? gaim2_conversation_get_name(conv) : "(null)", *flags);
-
- return FALSE;
- }
-
- static void
--received_im_msg_cb(GaimAccount *account, char *sender, char *buffer,
-- GaimConversation *conv, int flags, void *data)
-+received_im_msg_cb(Gaim2Account *account, char *sender, char *buffer,
-+ Gaim2Conversation *conv, int flags, void *data)
- {
-- gaim_debug_misc("signals test", "received-im-msg (%s, %s, %s, %s, %d)\n",
-- gaim_account_get_username(account), sender, buffer,
-- (conv != NULL) ? gaim_conversation_get_name(conv) : "(null)", flags);
-+ gaim2_debug_misc("signals test", "received-im-msg (%s, %s, %s, %s, %d)\n",
-+ gaim2_account_get_username(account), sender, buffer,
-+ (conv != NULL) ? gaim2_conversation_get_name(conv) : "(null)", flags);
- }
-
- static gboolean
--writing_chat_msg_cb(GaimAccount *account, GaimConversation *conv,
-+writing_chat_msg_cb(Gaim2Account *account, Gaim2Conversation *conv,
- char **buffer, void *data)
- {
-- gaim_debug_misc("signals test", "writing-chat-msg (%s, %s)\n",
-- gaim_conversation_get_name(conv), *buffer);
-+ gaim2_debug_misc("signals test", "writing-chat-msg (%s, %s)\n",
-+ gaim2_conversation_get_name(conv), *buffer);
-
- return FALSE;
- }
-
- static void
--wrote_chat_msg_cb(GaimAccount *account, GaimConversation *conv, const char *buffer, void *data)
-+wrote_chat_msg_cb(Gaim2Account *account, Gaim2Conversation *conv, const char *buffer, void *data)
- {
-- gaim_debug_misc("signals test", "wrote-chat-msg (%s, %s)\n",
-- gaim_conversation_get_name(conv), buffer);
-+ gaim2_debug_misc("signals test", "wrote-chat-msg (%s, %s)\n",
-+ gaim2_conversation_get_name(conv), buffer);
- }
-
- static gboolean
--sending_chat_msg_cb(GaimAccount *account, char **buffer, int id, void *data)
-+sending_chat_msg_cb(Gaim2Account *account, char **buffer, int id, void *data)
- {
-- gaim_debug_misc("signals test", "sending-chat-msg (%s, %s, %d)\n",
-- gaim_account_get_username(account), *buffer, id);
-+ gaim2_debug_misc("signals test", "sending-chat-msg (%s, %s, %d)\n",
-+ gaim2_account_get_username(account), *buffer, id);
-
- return FALSE;
- }
-
- static void
--sent_chat_msg_cb(GaimAccount *account, const char *buffer, int id, void *data)
-+sent_chat_msg_cb(Gaim2Account *account, const char *buffer, int id, void *data)
- {
-- gaim_debug_misc("signals test", "sent-chat-msg (%s, %s, %d)\n",
-- gaim_account_get_username(account), buffer, id);
-+ gaim2_debug_misc("signals test", "sent-chat-msg (%s, %s, %d)\n",
-+ gaim2_account_get_username(account), buffer, id);
- }
-
- static gboolean
--receiving_chat_msg_cb(GaimAccount *account, char **sender, char **buffer,
-- GaimConversation *chat, int *flags, void *data)
-+receiving_chat_msg_cb(Gaim2Account *account, char **sender, char **buffer,
-+ Gaim2Conversation *chat, int *flags, void *data)
- {
-- gaim_debug_misc("signals test",
-+ gaim2_debug_misc("signals test",
- "receiving-chat-msg (%s, %s, %s, %s, %d)\n",
-- gaim_account_get_username(account), *sender, *buffer,
-- gaim_conversation_get_name(chat), *flags);
-+ gaim2_account_get_username(account), *sender, *buffer,
-+ gaim2_conversation_get_name(chat), *flags);
-
- return FALSE;
- }
-
- static void
--received_chat_msg_cb(GaimAccount *account, char *sender, char *buffer,
-- GaimConversation *chat, int flags, void *data)
-+received_chat_msg_cb(Gaim2Account *account, char *sender, char *buffer,
-+ Gaim2Conversation *chat, int flags, void *data)
- {
-- gaim_debug_misc("signals test",
-+ gaim2_debug_misc("signals test",
- "received-chat-msg (%s, %s, %s, %s, %d)\n",
-- gaim_account_get_username(account), sender, buffer,
-- gaim_conversation_get_name(chat), flags);
-+ gaim2_account_get_username(account), sender, buffer,
-+ gaim2_conversation_get_name(chat), flags);
- }
-
- static void
--conversation_created_cb(GaimConversation *conv, void *data)
-+conversation_created_cb(Gaim2Conversation *conv, void *data)
- {
-- gaim_debug_misc("signals test", "conversation-created (%s)\n",
-- gaim_conversation_get_name(conv));
-+ gaim2_debug_misc("signals test", "conversation-created (%s)\n",
-+ gaim2_conversation_get_name(conv));
- }
-
- static void
--deleting_conversation_cb(GaimConversation *conv, void *data)
-+deleting_conversation_cb(Gaim2Conversation *conv, void *data)
- {
-- gaim_debug_misc("signals test", "deleting-conversation (%s)\n",
-- gaim_conversation_get_name(conv));
-+ gaim2_debug_misc("signals test", "deleting-conversation (%s)\n",
-+ gaim2_conversation_get_name(conv));
- }
-
- static void
--buddy_typing_cb(GaimAccount *account, const char *name, void *data)
-+buddy_typing_cb(Gaim2Account *account, const char *name, void *data)
- {
-- gaim_debug_misc("signals test", "buddy-typing (%s, %s)\n",
-- gaim_account_get_username(account), name);
-+ gaim2_debug_misc("signals test", "buddy-typing (%s, %s)\n",
-+ gaim2_account_get_username(account), name);
- }
-
- static void
--buddy_typing_stopped_cb(GaimAccount *account, const char *name, void *data)
-+buddy_typing_stopped_cb(Gaim2Account *account, const char *name, void *data)
- {
-- gaim_debug_misc("signals test", "buddy-typing-stopped (%s, %s)\n",
-- gaim_account_get_username(account), name);
-+ gaim2_debug_misc("signals test", "buddy-typing-stopped (%s, %s)\n",
-+ gaim2_account_get_username(account), name);
- }
-
- static gboolean
--chat_buddy_joining_cb(GaimConversation *conv, const char *user,
-- GaimConvChatBuddyFlags flags, void *data)
-+chat_buddy_joining_cb(Gaim2Conversation *conv, const char *user,
-+ Gaim2ConvChatBuddyFlags flags, void *data)
- {
-- gaim_debug_misc("signals test", "chat-buddy-joining (%s, %s, %d)\n",
-- gaim_conversation_get_name(conv), user, flags);
-+ gaim2_debug_misc("signals test", "chat-buddy-joining (%s, %s, %d)\n",
-+ gaim2_conversation_get_name(conv), user, flags);
-
- return FALSE;
- }
-
- static void
--chat_buddy_joined_cb(GaimConversation *conv, const char *user,
-- GaimConvChatBuddyFlags flags, void *data)
-+chat_buddy_joined_cb(Gaim2Conversation *conv, const char *user,
-+ Gaim2ConvChatBuddyFlags flags, void *data)
- {
-- gaim_debug_misc("signals test", "chat-buddy-joined (%s, %s, %d)\n",
-- gaim_conversation_get_name(conv), user, flags);
-+ gaim2_debug_misc("signals test", "chat-buddy-joined (%s, %s, %d)\n",
-+ gaim2_conversation_get_name(conv), user, flags);
- }
-
- static void
--chat_buddy_flags_cb(GaimConversation *conv, const char *user,
-- GaimConvChatBuddyFlags oldflags, GaimConvChatBuddyFlags newflags, void *data)
-+chat_buddy_flags_cb(Gaim2Conversation *conv, const char *user,
-+ Gaim2ConvChatBuddyFlags oldflags, Gaim2ConvChatBuddyFlags newflags, void *data)
- {
-- gaim_debug_misc("signals test", "chat-buddy-flags (%s, %s, %d, %d)\n",
-- gaim_conversation_get_name(conv), user, oldflags, newflags);
-+ gaim2_debug_misc("signals test", "chat-buddy-flags (%s, %s, %d, %d)\n",
-+ gaim2_conversation_get_name(conv), user, oldflags, newflags);
- }
-
- static gboolean
--chat_buddy_leaving_cb(GaimConversation *conv, const char *user,
-+chat_buddy_leaving_cb(Gaim2Conversation *conv, const char *user,
- const char *reason, void *data)
- {
-- gaim_debug_misc("signals test", "chat-buddy-leaving (%s, %s, %s)\n",
-- gaim_conversation_get_name(conv), user, reason);
-+ gaim2_debug_misc("signals test", "chat-buddy-leaving (%s, %s, %s)\n",
-+ gaim2_conversation_get_name(conv), user, reason);
-
- return FALSE;
- }
-
- static void
--chat_buddy_left_cb(GaimConversation *conv, const char *user,
-+chat_buddy_left_cb(Gaim2Conversation *conv, const char *user,
- const char *reason, void *data)
- {
-- gaim_debug_misc("signals test", "chat-buddy-left (%s, %s, %s)\n",
-- gaim_conversation_get_name(conv), user, reason);
-+ gaim2_debug_misc("signals test", "chat-buddy-left (%s, %s, %s)\n",
-+ gaim2_conversation_get_name(conv), user, reason);
- }
-
- static void
--chat_inviting_user_cb(GaimConversation *conv, const char *name,
-+chat_inviting_user_cb(Gaim2Conversation *conv, const char *name,
- char **reason, void *data)
- {
-- gaim_debug_misc("signals test", "chat-inviting-user (%s, %s, %s)\n",
-- gaim_conversation_get_name(conv), name, *reason);
-+ gaim2_debug_misc("signals test", "chat-inviting-user (%s, %s, %s)\n",
-+ gaim2_conversation_get_name(conv), name, *reason);
- }
-
- static void
--chat_invited_user_cb(GaimConversation *conv, const char *name,
-+chat_invited_user_cb(Gaim2Conversation *conv, const char *name,
- const char *reason, void *data)
- {
-- gaim_debug_misc("signals test", "chat-invited-user (%s, %s, %s)\n",
-- gaim_conversation_get_name(conv), name, reason);
-+ gaim2_debug_misc("signals test", "chat-invited-user (%s, %s, %s)\n",
-+ gaim2_conversation_get_name(conv), name, reason);
- }
-
- static gint
--chat_invited_cb(GaimAccount *account, const char *inviter,
-+chat_invited_cb(Gaim2Account *account, const char *inviter,
- const char *room_name, const char *message,
- const GHashTable *components, void *data)
- {
-- gaim_debug_misc("signals test", "chat-invited (%s, %s, %s, %s)\n",
-- gaim_account_get_username(account), inviter,
-+ gaim2_debug_misc("signals test", "chat-invited (%s, %s, %s, %s)\n",
-+ gaim2_account_get_username(account), inviter,
- room_name, message);
-
- return 0;
- }
-
- static void
--chat_joined_cb(GaimConversation *conv, void *data)
-+chat_joined_cb(Gaim2Conversation *conv, void *data)
- {
-- gaim_debug_misc("signals test", "chat-joined (%s)\n",
-- gaim_conversation_get_name(conv));
-+ gaim2_debug_misc("signals test", "chat-joined (%s)\n",
-+ gaim2_conversation_get_name(conv));
- }
-
- static void
--chat_left_cb(GaimConversation *conv, void *data)
-+chat_left_cb(Gaim2Conversation *conv, void *data)
- {
-- gaim_debug_misc("signals test", "chat-left (%s)\n",
-- gaim_conversation_get_name(conv));
-+ gaim2_debug_misc("signals test", "chat-left (%s)\n",
-+ gaim2_conversation_get_name(conv));
- }
-
- static void
--chat_topic_changed_cb(GaimConversation *conv, const char *who,
-+chat_topic_changed_cb(Gaim2Conversation *conv, const char *who,
- const char *topic, void *data)
- {
-- gaim_debug_misc("signals test",
-+ gaim2_debug_misc("signals test",
- "chat-topic-changed (%s topic changed to: \"%s\" by %s)\n",
-- gaim_conversation_get_name(conv), topic,
-+ gaim2_conversation_get_name(conv), topic,
- (who) ? who : "unknown");
- }
- /**************************************************************************
- * Ciphers signal callbacks
- **************************************************************************/
- static void
--cipher_added_cb(GaimCipher *cipher, void *data) {
-- gaim_debug_misc("signals test", "cipher %s added\n",
-- gaim_cipher_get_name(cipher));
-+cipher_added_cb(Gaim2Cipher *cipher, void *data) {
-+ gaim2_debug_misc("signals test", "cipher %s added\n",
-+ gaim2_cipher_get_name(cipher));
- }
-
- static void
--cipher_removed_cb(GaimCipher *cipher, void *data) {
-- gaim_debug_misc("signals test", "cipher %s removed\n",
-- gaim_cipher_get_name(cipher));
-+cipher_removed_cb(Gaim2Cipher *cipher, void *data) {
-+ gaim2_debug_misc("signals test", "cipher %s removed\n",
-+ gaim2_cipher_get_name(cipher));
- }
-
- /**************************************************************************
-@@ -450,59 +450,59 @@ cipher_removed_cb(GaimCipher *cipher, vo
- static void
- quitting_cb(void *data)
- {
-- gaim_debug_misc("signals test", "quitting ()\n");
-+ gaim2_debug_misc("signals test", "quitting ()\n");
- }
-
- /**************************************************************************
- * File transfer signal callbacks
- **************************************************************************/
- static void
--ft_recv_accept_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file receive accepted\n");
-+ft_recv_accept_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file receive accepted\n");
- }
-
- static void
--ft_send_accept_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file send accepted\n");
-+ft_send_accept_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file send accepted\n");
- }
-
- static void
--ft_recv_start_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file receive started\n");
-+ft_recv_start_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file receive started\n");
- }
-
- static void
--ft_send_start_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file send started\n");
-+ft_send_start_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file send started\n");
- }
-
- static void
--ft_recv_cancel_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file receive canceled\n");
-+ft_recv_cancel_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file receive canceled\n");
- }
-
- static void
--ft_send_cancel_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file send canceled\n");
-+ft_send_cancel_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file send canceled\n");
- }
-
- static void
--ft_recv_complete_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file receive completed\n");
-+ft_recv_complete_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file receive completed\n");
- }
-
- static void
--ft_send_complete_cb(GaimXfer *xfer, gpointer data) {
-- gaim_debug_misc("signals test", "file send completed\n");
-+ft_send_complete_cb(Gaim2Xfer *xfer, gpointer data) {
-+ gaim2_debug_misc("signals test", "file send completed\n");
- }
-
- /**************************************************************************
- * Sound signal callbacks
- **************************************************************************/
- static int
--sound_playing_event_cb(GaimSoundEventID event, const GaimAccount *account) {
-- gaim_debug_misc("signals test", "sound playing event: %d for account: %s\n",
-- event, gaim_account_get_username(account));
-+sound_playing_event_cb(Gaim2SoundEventID event, const Gaim2Account *account) {
-+ gaim2_debug_misc("signals test", "sound playing event: %d for account: %s\n",
-+ event, gaim2_account_get_username(account));
-
- return 0;
- }
-@@ -511,149 +511,149 @@ sound_playing_event_cb(GaimSoundEventID
- * Plugin stuff
- **************************************************************************/
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *core_handle = gaim_get_core();
-- void *blist_handle = gaim_blist_get_handle();
-- void *conn_handle = gaim_connections_get_handle();
-- void *conv_handle = gaim_conversations_get_handle();
-- void *accounts_handle = gaim_accounts_get_handle();
-- void *ciphers_handle = gaim_ciphers_get_handle();
-- void *ft_handle = gaim_xfers_get_handle();
-- void *sound_handle = gaim_sounds_get_handle();
-+ void *core_handle = gaim2_get_core();
-+ void *blist_handle = gaim2_blist_get_handle();
-+ void *conn_handle = gaim2_connections_get_handle();
-+ void *conv_handle = gaim2_conversations_get_handle();
-+ void *accounts_handle = gaim2_accounts_get_handle();
-+ void *ciphers_handle = gaim2_ciphers_get_handle();
-+ void *ft_handle = gaim2_xfers_get_handle();
-+ void *sound_handle = gaim2_sounds_get_handle();
-
- /* Accounts subsystem signals */
-- gaim_signal_connect(accounts_handle, "account-connecting",
-+ gaim2_signal_connect(accounts_handle, "account-connecting",
- plugin, GAIM_CALLBACK(account_connecting_cb), NULL);
-- gaim_signal_connect(accounts_handle, "account-setting-info",
-+ gaim2_signal_connect(accounts_handle, "account-setting-info",
- plugin, GAIM_CALLBACK(account_setting_info_cb), NULL);
-- gaim_signal_connect(accounts_handle, "account-set-info",
-+ gaim2_signal_connect(accounts_handle, "account-set-info",
- plugin, GAIM_CALLBACK(account_set_info_cb), NULL);
-- gaim_signal_connect(accounts_handle, "account-status-changed",
-+ gaim2_signal_connect(accounts_handle, "account-status-changed",
- plugin, GAIM_CALLBACK(account_status_changed), NULL);
-
- /* Buddy List subsystem signals */
-- gaim_signal_connect(blist_handle, "buddy-status-changed",
-+ gaim2_signal_connect(blist_handle, "buddy-status-changed",
- plugin, GAIM_CALLBACK(buddy_status_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-idle-changed",
-+ gaim2_signal_connect(blist_handle, "buddy-idle-changed",
- plugin, GAIM_CALLBACK(buddy_idle_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-on",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-on",
- plugin, GAIM_CALLBACK(buddy_signed_on_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-off",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-off",
- plugin, GAIM_CALLBACK(buddy_signed_off_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-added",
-+ gaim2_signal_connect(blist_handle, "buddy-added",
- plugin, GAIM_CALLBACK(buddy_added_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-removed",
-+ gaim2_signal_connect(blist_handle, "buddy-removed",
- plugin, GAIM_CALLBACK(buddy_removed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-icon-changed",
-+ gaim2_signal_connect(blist_handle, "buddy-icon-changed",
- plugin, GAIM_CALLBACK(buddy_icon_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "blist-node-aliased",
-+ gaim2_signal_connect(blist_handle, "blist-node-aliased",
- plugin, GAIM_CALLBACK(blist_node_aliased), NULL);
-- gaim_signal_connect(blist_handle, "blist-node-extended-menu",
-+ gaim2_signal_connect(blist_handle, "blist-node-extended-menu",
- plugin, GAIM_CALLBACK(blist_node_extended_menu_cb), NULL);
-
- /* Connection subsystem signals */
-- gaim_signal_connect(conn_handle, "signing-on",
-+ gaim2_signal_connect(conn_handle, "signing-on",
- plugin, GAIM_CALLBACK(signing_on_cb), NULL);
-- gaim_signal_connect(conn_handle, "signed-on",
-+ gaim2_signal_connect(conn_handle, "signed-on",
- plugin, GAIM_CALLBACK(signed_on_cb), NULL);
-- gaim_signal_connect(conn_handle, "signing-off",
-+ gaim2_signal_connect(conn_handle, "signing-off",
- plugin, GAIM_CALLBACK(signing_off_cb), NULL);
-- gaim_signal_connect(conn_handle, "signed-off",
-+ gaim2_signal_connect(conn_handle, "signed-off",
- plugin, GAIM_CALLBACK(signed_off_cb), NULL);
-
- /* Conversations subsystem signals */
-- gaim_signal_connect(conv_handle, "writing-im-msg",
-+ gaim2_signal_connect(conv_handle, "writing-im-msg",
- plugin, GAIM_CALLBACK(writing_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "wrote-im-msg",
-+ gaim2_signal_connect(conv_handle, "wrote-im-msg",
- plugin, GAIM_CALLBACK(wrote_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "sending-im-msg",
-+ gaim2_signal_connect(conv_handle, "sending-im-msg",
- plugin, GAIM_CALLBACK(sending_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "sent-im-msg",
-+ gaim2_signal_connect(conv_handle, "sent-im-msg",
- plugin, GAIM_CALLBACK(sent_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "receiving-im-msg",
-+ gaim2_signal_connect(conv_handle, "receiving-im-msg",
- plugin, GAIM_CALLBACK(receiving_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "received-im-msg",
-+ gaim2_signal_connect(conv_handle, "received-im-msg",
- plugin, GAIM_CALLBACK(received_im_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "writing-chat-msg",
-+ gaim2_signal_connect(conv_handle, "writing-chat-msg",
- plugin, GAIM_CALLBACK(writing_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "wrote-chat-msg",
-+ gaim2_signal_connect(conv_handle, "wrote-chat-msg",
- plugin, GAIM_CALLBACK(wrote_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "sending-chat-msg",
-+ gaim2_signal_connect(conv_handle, "sending-chat-msg",
- plugin, GAIM_CALLBACK(sending_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "sent-chat-msg",
-+ gaim2_signal_connect(conv_handle, "sent-chat-msg",
- plugin, GAIM_CALLBACK(sent_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "receiving-chat-msg",
-+ gaim2_signal_connect(conv_handle, "receiving-chat-msg",
- plugin, GAIM_CALLBACK(receiving_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "received-chat-msg",
-+ gaim2_signal_connect(conv_handle, "received-chat-msg",
- plugin, GAIM_CALLBACK(received_chat_msg_cb), NULL);
-- gaim_signal_connect(conv_handle, "conversation-created",
-+ gaim2_signal_connect(conv_handle, "conversation-created",
- plugin, GAIM_CALLBACK(conversation_created_cb), NULL);
-- gaim_signal_connect(conv_handle, "deleting-conversation",
-+ gaim2_signal_connect(conv_handle, "deleting-conversation",
- plugin, GAIM_CALLBACK(deleting_conversation_cb), NULL);
-- gaim_signal_connect(conv_handle, "buddy-typing",
-+ gaim2_signal_connect(conv_handle, "buddy-typing",
- plugin, GAIM_CALLBACK(buddy_typing_cb), NULL);
-- gaim_signal_connect(conv_handle, "buddy-typing-stopped",
-+ gaim2_signal_connect(conv_handle, "buddy-typing-stopped",
- plugin, GAIM_CALLBACK(buddy_typing_stopped_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-buddy-joining",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-joining",
- plugin, GAIM_CALLBACK(chat_buddy_joining_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-buddy-joined",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-joined",
- plugin, GAIM_CALLBACK(chat_buddy_joined_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-buddy-flags",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-flags",
- plugin, GAIM_CALLBACK(chat_buddy_flags_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-buddy-leaving",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-leaving",
- plugin, GAIM_CALLBACK(chat_buddy_leaving_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-buddy-left",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-left",
- plugin, GAIM_CALLBACK(chat_buddy_left_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-inviting-user",
-+ gaim2_signal_connect(conv_handle, "chat-inviting-user",
- plugin, GAIM_CALLBACK(chat_inviting_user_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-invited-user",
-+ gaim2_signal_connect(conv_handle, "chat-invited-user",
- plugin, GAIM_CALLBACK(chat_invited_user_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-invited",
-+ gaim2_signal_connect(conv_handle, "chat-invited",
- plugin, GAIM_CALLBACK(chat_invited_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-joined",
-+ gaim2_signal_connect(conv_handle, "chat-joined",
- plugin, GAIM_CALLBACK(chat_joined_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-left",
-+ gaim2_signal_connect(conv_handle, "chat-left",
- plugin, GAIM_CALLBACK(chat_left_cb), NULL);
-- gaim_signal_connect(conv_handle, "chat-topic-changed",
-+ gaim2_signal_connect(conv_handle, "chat-topic-changed",
- plugin, GAIM_CALLBACK(chat_topic_changed_cb), NULL);
-
- /* Ciphers signals */
-- gaim_signal_connect(ciphers_handle, "cipher-added",
-+ gaim2_signal_connect(ciphers_handle, "cipher-added",
- plugin, GAIM_CALLBACK(cipher_added_cb), NULL);
-- gaim_signal_connect(ciphers_handle, "cipher-removed",
-+ gaim2_signal_connect(ciphers_handle, "cipher-removed",
- plugin, GAIM_CALLBACK(cipher_removed_cb), NULL);
-
- /* Core signals */
-- gaim_signal_connect(core_handle, "quitting",
-+ gaim2_signal_connect(core_handle, "quitting",
- plugin, GAIM_CALLBACK(quitting_cb), NULL);
-
- /* File transfer signals */
-- gaim_signal_connect(ft_handle, "file-recv-accept",
-+ gaim2_signal_connect(ft_handle, "file-recv-accept",
- plugin, GAIM_CALLBACK(ft_recv_accept_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-recv-start",
-+ gaim2_signal_connect(ft_handle, "file-recv-start",
- plugin, GAIM_CALLBACK(ft_recv_start_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-recv-cancel",
-+ gaim2_signal_connect(ft_handle, "file-recv-cancel",
- plugin, GAIM_CALLBACK(ft_recv_cancel_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-recv-complete",
-+ gaim2_signal_connect(ft_handle, "file-recv-complete",
- plugin, GAIM_CALLBACK(ft_recv_complete_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-send-accept",
-+ gaim2_signal_connect(ft_handle, "file-send-accept",
- plugin, GAIM_CALLBACK(ft_send_accept_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-send-start",
-+ gaim2_signal_connect(ft_handle, "file-send-start",
- plugin, GAIM_CALLBACK(ft_send_start_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-send-cancel",
-+ gaim2_signal_connect(ft_handle, "file-send-cancel",
- plugin, GAIM_CALLBACK(ft_send_cancel_cb), NULL);
-- gaim_signal_connect(ft_handle, "file-send-complete",
-+ gaim2_signal_connect(ft_handle, "file-send-complete",
- plugin, GAIM_CALLBACK(ft_send_complete_cb), NULL);
-
- /* Sound signals */
-- gaim_signal_connect(sound_handle, "playing-sound-event", plugin,
-+ gaim2_signal_connect(sound_handle, "playing-sound-event", plugin,
- GAIM_CALLBACK(sound_playing_event_cb), NULL);
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -685,7 +685,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/simple.c ./plugins/simple.c
---- ./plugins/simple.c 2005-08-14 00:09:30.000000000 +0200
-+++ ./plugins/simple.c 2006-01-05 15:27:38.000000000 +0100
-@@ -4,22 +4,22 @@
- #include "version.h"
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- gaim_debug(GAIM_DEBUG_INFO, "simple", "simple plugin loaded.\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "simple", "simple plugin loaded.\n");
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
-- gaim_debug(GAIM_DEBUG_INFO, "simple", "simple plugin unloaded.\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "simple", "simple plugin unloaded.\n");
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -51,7 +51,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/spellchk.c ./plugins/spellchk.c
---- ./plugins/spellchk.c 2006-01-04 04:01:32.000000000 +0100
-+++ ./plugins/spellchk.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,11 +1,11 @@
- /*
-- * Gaim - Replace certain misspelled words with their correct form.
-+ * Gaim2 - Replace certain misspelled words with their correct form.
- *
- * Signification changes were made by Benjamin Kahn ("xkahn") and
- * Richard Laager ("rlaager") in April 2005--you may want to contact
- * them if you have questions.
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,7 +31,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "debug.h"
- #include "notify.h"
-@@ -574,7 +574,7 @@ message_send_cb(GtkWidget *widget, spell
- }
-
- #if 0
-- if (!gaim_prefs_get_bool("/plugins/gtk/spellchk/last_word_replace"))
-+ if (!gaim2_prefs_get_bool("/plugins/gtk/spellchk/last_word_replace"))
- return;
- #endif
-
-@@ -599,12 +599,12 @@ message_send_cb(GtkWidget *widget, spell
- }
-
- static void
--spellchk_new_attach(GaimConversation *conv)
-+spellchk_new_attach(Gaim2Conversation *conv)
- {
- spellchk *spell;
- GtkTextBuffer *buffer;
- GtkTextIter start, end;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GtkTextView *view;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-@@ -1735,7 +1735,7 @@ static void load_conf()
- gboolean complete = TRUE;
- gboolean case_sensitive = FALSE;
-
-- buf = g_build_filename(gaim_user_dir(), "dict", NULL);
-+ buf = g_build_filename(gaim2_user_dir(), "dict", NULL);
- g_file_get_contents(buf, &ibuf, &size, NULL);
- g_free(buf);
- if (!ibuf) {
-@@ -1896,7 +1896,7 @@ static void list_add_new()
- g_free(bad);
- g_free(tmpword);
-
-- gaim_notify_error(NULL, _("Duplicate Correction"),
-+ gaim2_notify_error(NULL, _("Duplicate Correction"),
- _("The specified word already exists in the correction list."),
- gtk_entry_get_text(GTK_ENTRY(bad_entry)));
- return;
-@@ -2005,7 +2005,7 @@ static void save_list()
- } while (gtk_tree_model_iter_next(GTK_TREE_MODEL(model), &iter));
- }
-
-- gaim_util_write_data_to_file("dict", data->str, -1);
-+ gaim2_util_write_data_to_file("dict", data->str, -1);
-
- g_string_free(data, TRUE);
- }
-@@ -2044,34 +2044,34 @@ static void on_entry_changed(GtkEditable
- */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *conv_handle = gaim_conversations_get_handle();
-+ void *conv_handle = gaim2_conversations_get_handle();
- GList *convs;
-
- load_conf();
-
- /* Attach to existing conversations */
-- for (convs = gaim_get_conversations(); convs != NULL; convs = convs->next)
-+ for (convs = gaim2_get_conversations(); convs != NULL; convs = convs->next)
- {
-- spellchk_new_attach((GaimConversation *)convs->data);
-+ spellchk_new_attach((Gaim2Conversation *)convs->data);
- }
-
-- gaim_signal_connect(conv_handle, "conversation-created",
-+ gaim2_signal_connect(conv_handle, "conversation-created",
- plugin, GAIM_CALLBACK(spellchk_new_attach), NULL);
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- GList *convs;
-
- /* Detach from existing conversations */
-- for (convs = gaim_get_conversations(); convs != NULL; convs = convs->next)
-+ for (convs = gaim2_get_conversations(); convs != NULL; convs = convs->next)
- {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION((GaimConversation *)convs->data);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION((Gaim2Conversation *)convs->data);
- g_object_set_data(G_OBJECT(gtkconv->entry), SPELLCHK_OBJECT_KEY, NULL);
- }
-
-@@ -2087,7 +2087,7 @@ static void whole_words_button_toggled(G
- }
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret, *vbox, *win;
- GtkWidget *hbox, *label;
-@@ -2103,7 +2103,7 @@ get_config_frame(GaimPlugin *plugin)
- ret = gtk_vbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_container_set_border_width (GTK_CONTAINER(ret), GAIM_HIG_BORDER);
-
-- vbox = gaim_gtk_make_frame(ret, _("Text Replacements"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Text Replacements"));
- gtk_container_set_border_width(GTK_CONTAINER(vbox), 4);
- gtk_widget_show(vbox);
-
-@@ -2192,7 +2192,7 @@ get_config_frame(GaimPlugin *plugin)
-
- gtk_widget_show(button);
-
-- vbox = gaim_gtk_make_frame(ret, _("Add a new text replacement"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Add a new text replacement"));
-
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, TRUE, TRUE, 0);
-@@ -2264,8 +2264,8 @@ get_config_frame(GaimPlugin *plugin)
- gtk_widget_show(button);
-
- #if 0
-- vbox = gaim_gtk_make_frame(ret, _("General Text Replacement Options"));
-- gaim_gtk_prefs_checkbox(_("Enable replacement of last word on send"),
-+ vbox = gaim2_gtk_make_frame(ret, _("General Text Replacement Options"));
-+ gaim2_gtk_prefs_checkbox(_("Enable replacement of last word on send"),
- "/plugins/gtk/spellchk/last_word_replace", vbox);
- #endif
-
-@@ -2273,13 +2273,13 @@ get_config_frame(GaimPlugin *plugin)
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -2306,13 +2306,13 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- #if 0
-- gaim_prefs_add_none("/plugins");
-- gaim_prefs_add_none("/plugins/gtk");
-- gaim_prefs_add_none("/plugins/gtk/spellchk");
-- gaim_prefs_add_bool("/plugins/gtk/spellchk/last_word_replace", TRUE);
-+ gaim2_prefs_add_none("/plugins");
-+ gaim2_prefs_add_none("/plugins/gtk");
-+ gaim2_prefs_add_none("/plugins/gtk/spellchk");
-+ gaim2_prefs_add_bool("/plugins/gtk/spellchk/last_word_replace", TRUE);
- #endif
- }
-
-diff -prNu ./plugins/ssl/Makefile.am ./plugins/ssl/Makefile.am
---- ./plugins/ssl/Makefile.am 2005-04-29 19:04:25.000000000 +0200
-+++ ./plugins/ssl/Makefile.am 2006-01-05 13:16:58.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- ssl_la_LDFLAGS = -module -avoid-version $(GLIB_LIBS)
- ssl_gnutls_la_LDFLAGS = -module -avoid-version $(GLIB_LIBS)
-@@ -25,7 +25,7 @@ endif # PLUGINS
-
- AM_CPPFLAGS = \
- -DDATADIR=\"$(datadir)\" \
-- -DLIBDIR=\"$(libdir)/gaim/\" \
-+ -DLIBDIR=\"$(libdir)/gaim2/\" \
- -I$(top_srcdir)/src \
- $(DEBUG_CFLAGS) \
- $(GTK_CFLAGS) \
-diff -prNu ./plugins/ssl/ssl.c ./plugins/ssl/ssl.c
---- ./plugins/ssl/ssl.c 2004-09-03 23:21:22.000000000 +0200
-+++ ./plugins/ssl/ssl.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file ssl.c Main SSL plugin
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org>
- *
-@@ -27,19 +27,19 @@
-
- #define SSL_PLUGIN_ID "core-ssl"
-
--static GaimPlugin *ssl_plugin = NULL;
-+static Gaim2Plugin *ssl_plugin = NULL;
-
- static gboolean
--probe_ssl_plugins(GaimPlugin *my_plugin)
-+probe_ssl_plugins(Gaim2Plugin *my_plugin)
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GList *l;
-
- ssl_plugin = NULL;
-
-- for (l = gaim_plugins_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_plugins_get_all(); l != NULL; l = l->next)
- {
-- plugin = (GaimPlugin *)l->data;
-+ plugin = (Gaim2Plugin *)l->data;
-
- if (plugin == my_plugin)
- continue;
-@@ -47,7 +47,7 @@ probe_ssl_plugins(GaimPlugin *my_plugin)
- if (plugin->info != NULL && plugin->info->id != NULL &&
- strncmp(plugin->info->id, "ssl-", 4) == 0)
- {
-- if (gaim_plugin_is_loaded(plugin) || gaim_plugin_load(plugin))
-+ if (gaim2_plugin_is_loaded(plugin) || gaim2_plugin_load(plugin))
- {
- ssl_plugin = plugin;
-
-@@ -60,18 +60,18 @@ probe_ssl_plugins(GaimPlugin *my_plugin)
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- return probe_ssl_plugins(plugin);
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- if (ssl_plugin != NULL &&
-- g_list_find(gaim_plugins_get_loaded(), ssl_plugin) != NULL)
-+ g_list_find(gaim2_plugins_get_loaded(), ssl_plugin) != NULL)
- {
-- gaim_plugin_unload(ssl_plugin);
-+ gaim2_plugin_unload(ssl_plugin);
- }
-
- ssl_plugin = NULL;
-@@ -79,7 +79,7 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -111,7 +111,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/ssl/ssl-gnutls.c ./plugins/ssl/ssl-gnutls.c
---- ./plugins/ssl/ssl-gnutls.c 2005-09-11 18:30:49.000000000 +0200
-+++ ./plugins/ssl/ssl-gnutls.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file ssl-gnutls.c GNUTLS SSL plugin.
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org>
- *
-@@ -35,9 +35,9 @@ typedef struct
- {
- gnutls_session session;
-
--} GaimSslGnutlsData;
-+} Gaim2SslGnutlsData;
-
--#define GAIM_SSL_GNUTLS_DATA(gsc) ((GaimSslGnutlsData *)gsc->private_data)
-+#define GAIM_SSL_GNUTLS_DATA(gsc) ((Gaim2SslGnutlsData *)gsc->private_data)
-
- static gnutls_certificate_client_credentials xcred;
-
-@@ -66,10 +66,10 @@ ssl_gnutls_uninit(void)
- }
-
- static void
--ssl_gnutls_connect_cb(gpointer data, gint source, GaimInputCondition cond)
-+ssl_gnutls_connect_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimSslConnection *gsc = (GaimSslConnection *)data;
-- GaimSslGnutlsData *gnutls_data;
-+ Gaim2SslConnection *gsc = (Gaim2SslConnection *)data;
-+ Gaim2SslGnutlsData *gnutls_data;
- static const int cert_type_priority[2] = { GNUTLS_CRT_X509, 0 };
- int ret;
-
-@@ -77,13 +77,13 @@ ssl_gnutls_connect_cb(gpointer data, gin
- if(gsc->error_cb != NULL)
- gsc->error_cb(gsc, GAIM_SSL_CONNECT_FAILED, gsc->connect_cb_data);
-
-- gaim_ssl_close(gsc);
-+ gaim2_ssl_close(gsc);
- return;
- }
-
- gsc->fd = source;
-
-- gnutls_data = g_new0(GaimSslGnutlsData, 1);
-+ gnutls_data = g_new0(Gaim2SslGnutlsData, 1);
- gsc->private_data = gnutls_data;
-
- gnutls_init(&gnutls_data->session, GNUTLS_CLIENT);
-@@ -100,33 +100,33 @@ ssl_gnutls_connect_cb(gpointer data, gin
-
- do
- {
-- gaim_debug_info("gnutls", "Handshaking\n");
-+ gaim2_debug_info("gnutls", "Handshaking\n");
- ret = gnutls_handshake(gnutls_data->session);
- }
- while ((ret == GNUTLS_E_AGAIN) || (ret == GNUTLS_E_INTERRUPTED));
-
- if (ret < 0)
- {
-- gaim_debug_error("gnutls", "Handshake failed. Error %d\n", ret);
-+ gaim2_debug_error("gnutls", "Handshake failed. Error %d\n", ret);
-
- if (gsc->error_cb != NULL)
- gsc->error_cb(gsc, GAIM_SSL_HANDSHAKE_FAILED,
- gsc->connect_cb_data);
-
-- gaim_ssl_close(gsc);
-+ gaim2_ssl_close(gsc);
- }
- else
- {
-- gaim_debug_info("gnutls", "Handshake complete\n");
-+ gaim2_debug_info("gnutls", "Handshake complete\n");
-
- gsc->connect_cb(gsc->connect_cb_data, gsc, cond);
- }
- }
-
- static void
--ssl_gnutls_close(GaimSslConnection *gsc)
-+ssl_gnutls_close(Gaim2SslConnection *gsc)
- {
-- GaimSslGnutlsData *gnutls_data = GAIM_SSL_GNUTLS_DATA(gsc);
-+ Gaim2SslGnutlsData *gnutls_data = GAIM_SSL_GNUTLS_DATA(gsc);
-
- if(!gnutls_data)
- return;
-@@ -139,9 +139,9 @@ ssl_gnutls_close(GaimSslConnection *gsc)
- }
-
- static size_t
--ssl_gnutls_read(GaimSslConnection *gsc, void *data, size_t len)
-+ssl_gnutls_read(Gaim2SslConnection *gsc, void *data, size_t len)
- {
-- GaimSslGnutlsData *gnutls_data = GAIM_SSL_GNUTLS_DATA(gsc);
-+ Gaim2SslGnutlsData *gnutls_data = GAIM_SSL_GNUTLS_DATA(gsc);
- int s;
-
- do
-@@ -152,7 +152,7 @@ ssl_gnutls_read(GaimSslConnection *gsc,
-
- if (s < 0)
- {
-- gaim_debug_error("gnutls", "receive failed: %d\n", s);
-+ gaim2_debug_error("gnutls", "receive failed: %d\n", s);
- s = 0;
- }
-
-@@ -160,9 +160,9 @@ ssl_gnutls_read(GaimSslConnection *gsc,
- }
-
- static size_t
--ssl_gnutls_write(GaimSslConnection *gsc, const void *data, size_t len)
-+ssl_gnutls_write(Gaim2SslConnection *gsc, const void *data, size_t len)
- {
-- GaimSslGnutlsData *gnutls_data = GAIM_SSL_GNUTLS_DATA(gsc);
-+ Gaim2SslGnutlsData *gnutls_data = GAIM_SSL_GNUTLS_DATA(gsc);
- size_t s = 0;
-
- if(gnutls_data)
-@@ -171,7 +171,7 @@ ssl_gnutls_write(GaimSslConnection *gsc,
- return s;
- }
-
--static GaimSslOps ssl_ops =
-+static Gaim2SslOps ssl_ops =
- {
- ssl_gnutls_init,
- ssl_gnutls_uninit,
-@@ -184,11 +184,11 @@ static GaimSslOps ssl_ops =
- #endif /* HAVE_GNUTLS */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- #ifdef HAVE_GNUTLS
-- if (!gaim_ssl_get_ops()) {
-- gaim_ssl_set_ops(&ssl_ops);
-+ if (!gaim2_ssl_get_ops()) {
-+ gaim2_ssl_set_ops(&ssl_ops);
- }
-
- /* Init GNUTLS now so others can use it even if sslconn never does */
-@@ -201,18 +201,18 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- #ifdef HAVE_GNUTLS
-- if (gaim_ssl_get_ops() == &ssl_ops) {
-- gaim_ssl_set_ops(NULL);
-+ if (gaim2_ssl_get_ops() == &ssl_ops) {
-+ gaim2_ssl_set_ops(NULL);
- }
- #endif
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -244,7 +244,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/ssl/ssl-nss.c ./plugins/ssl/ssl-nss.c
---- ./plugins/ssl/ssl-nss.c 2005-11-24 13:55:22.000000000 +0100
-+++ ./plugins/ssl/ssl-nss.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file ssl-nss.c Mozilla NSS SSL plugin.
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Christian Hammond <chipx86@gnupdate.org>
- *
-@@ -47,9 +47,9 @@ typedef struct
- PRFileDesc *fd;
- PRFileDesc *in;
-
--} GaimSslNssData;
-+} Gaim2SslNssData;
-
--#define GAIM_SSL_NSS_DATA(gsc) ((GaimSslNssData *)gsc->private_data)
-+#define GAIM_SSL_NSS_DATA(gsc) ((Gaim2SslNssData *)gsc->private_data)
-
- static const PRIOMethods *_nss_methods = NULL;
- static PRDescIdentity _identity;
-@@ -71,7 +71,7 @@ ssl_nss_init_nss(void)
- g_free(lib);
- NSS_SetDomesticPolicy();
-
-- _identity = PR_GetUniqueIdentity("Gaim");
-+ _identity = PR_GetUniqueIdentity("Gaim2");
- _nss_methods = PR_GetDefaultIOMethods();
- }
-
-@@ -93,7 +93,7 @@ ssl_auth_cert(void *arg, PRFileDesc *soc
- certUsageSSLClient, pinArg);
-
- if (status != SECSuccess) {
-- gaim_debug_error("nss", "CERT_VerifyCertNow failed\n");
-+ gaim2_debug_error("nss", "CERT_VerifyCertNow failed\n");
- CERT_DestroyCertificate(cert);
- return status;
- }
-@@ -138,7 +138,7 @@ ssl_bad_cert(void *arg, PRFileDesc *sock
- break;
- }
-
-- gaim_debug_error("nss", "Bad certificate: %d\n", err);
-+ gaim2_debug_error("nss", "Bad certificate: %d\n", err);
-
- return status;
- }
-@@ -158,10 +158,10 @@ ssl_nss_uninit(void)
- }
-
- static void
--ssl_nss_connect_cb(gpointer data, gint source, GaimInputCondition cond)
-+ssl_nss_connect_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimSslConnection *gsc = (GaimSslConnection *)data;
-- GaimSslNssData *nss_data = g_new0(GaimSslNssData, 1);
-+ Gaim2SslConnection *gsc = (Gaim2SslConnection *)data;
-+ Gaim2SslNssData *nss_data = g_new0(Gaim2SslNssData, 1);
- PRSocketOptionData socket_opt;
-
- gsc->private_data = nss_data;
-@@ -172,12 +172,12 @@ ssl_nss_connect_cb(gpointer data, gint s
-
- if (nss_data->fd == NULL)
- {
-- gaim_debug_error("nss", "nss_data->fd == NULL!\n");
-+ gaim2_debug_error("nss", "nss_data->fd == NULL!\n");
-
- if (gsc->error_cb != NULL)
- gsc->error_cb(gsc, GAIM_SSL_CONNECT_FAILED, gsc->connect_cb_data);
-
-- gaim_ssl_close((GaimSslConnection *)gsc);
-+ gaim2_ssl_close((Gaim2SslConnection *)gsc);
-
- return;
- }
-@@ -191,12 +191,12 @@ ssl_nss_connect_cb(gpointer data, gint s
-
- if (nss_data->in == NULL)
- {
-- gaim_debug_error("nss", "nss_data->in == NUL!\n");
-+ gaim2_debug_error("nss", "nss_data->in == NUL!\n");
-
- if (gsc->error_cb != NULL)
- gsc->error_cb(gsc, GAIM_SSL_CONNECT_FAILED, gsc->connect_cb_data);
-
-- gaim_ssl_close((GaimSslConnection *)gsc);
-+ gaim2_ssl_close((Gaim2SslConnection *)gsc);
-
- return;
- }
-@@ -216,12 +216,12 @@ ssl_nss_connect_cb(gpointer data, gint s
-
- if (SSL_ForceHandshake(nss_data->in))
- {
-- gaim_debug_error("nss", "Handshake failed\n");
-+ gaim2_debug_error("nss", "Handshake failed\n");
-
- if (gsc->error_cb != NULL)
- gsc->error_cb(gsc, GAIM_SSL_HANDSHAKE_FAILED, gsc->connect_cb_data);
-
-- gaim_ssl_close(gsc);
-+ gaim2_ssl_close(gsc);
-
- return;
- }
-@@ -230,9 +230,9 @@ ssl_nss_connect_cb(gpointer data, gint s
- }
-
- static void
--ssl_nss_close(GaimSslConnection *gsc)
-+ssl_nss_close(Gaim2SslConnection *gsc)
- {
-- GaimSslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
-+ Gaim2SslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
-
- if(!nss_data)
- return;
-@@ -244,17 +244,17 @@ ssl_nss_close(GaimSslConnection *gsc)
- }
-
- static size_t
--ssl_nss_read(GaimSslConnection *gsc, void *data, size_t len)
-+ssl_nss_read(Gaim2SslConnection *gsc, void *data, size_t len)
- {
-- GaimSslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
-+ Gaim2SslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
-
- return PR_Read(nss_data->in, data, len);
- }
-
- static size_t
--ssl_nss_write(GaimSslConnection *gsc, const void *data, size_t len)
-+ssl_nss_write(Gaim2SslConnection *gsc, const void *data, size_t len)
- {
-- GaimSslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
-+ Gaim2SslNssData *nss_data = GAIM_SSL_NSS_DATA(gsc);
-
- if(!nss_data)
- return 0;
-@@ -262,7 +262,7 @@ ssl_nss_write(GaimSslConnection *gsc, co
- return PR_Write(nss_data->in, data, len);
- }
-
--static GaimSslOps ssl_ops =
-+static Gaim2SslOps ssl_ops =
- {
- ssl_nss_init,
- ssl_nss_uninit,
-@@ -276,11 +276,11 @@ static GaimSslOps ssl_ops =
-
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
- #ifdef HAVE_NSS
-- if (!gaim_ssl_get_ops()) {
-- gaim_ssl_set_ops(&ssl_ops);
-+ if (!gaim2_ssl_get_ops()) {
-+ gaim2_ssl_set_ops(&ssl_ops);
- }
-
- /* Init NSS now, so others can use it even if sslconn never does */
-@@ -293,18 +293,18 @@ plugin_load(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- #ifdef HAVE_NSS
-- if (gaim_ssl_get_ops() == &ssl_ops) {
-- gaim_ssl_set_ops(NULL);
-+ if (gaim2_ssl_get_ops() == &ssl_ops) {
-+ gaim2_ssl_set_ops(NULL);
- }
- #endif
-
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -336,7 +336,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/statenotify.c ./plugins/statenotify.c
---- ./plugins/statenotify.c 2005-12-21 19:36:09.000000000 +0100
-+++ ./plugins/statenotify.c 2006-01-05 15:27:38.000000000 +0100
-@@ -13,38 +13,38 @@
- #define STATENOTIFY_PLUGIN_ID "core-statenotify"
-
- static void
--write_status(GaimBuddy *buddy, const char *message)
-+write_status(Gaim2Buddy *buddy, const char *message)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- const char *who;
- char buf[256];
- char *escaped;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- buddy->name, buddy->account);
-
- if (conv == NULL)
- return;
-
-- who = gaim_buddy_get_alias(buddy);
-+ who = gaim2_buddy_get_alias(buddy);
- escaped = g_markup_escape_text(who, -1);
-
- g_snprintf(buf, sizeof(buf), message, escaped);
- g_free(escaped);
-
-- gaim_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
- }
-
- static void
--buddy_status_changed_cb(GaimBuddy *buddy, GaimStatus *old_status,
-- GaimStatus *status, void *data)
-+buddy_status_changed_cb(Gaim2Buddy *buddy, Gaim2Status *old_status,
-+ Gaim2Status *status, void *data)
- {
- gboolean available, old_available;
-
-- available = gaim_status_is_available(status);
-- old_available = gaim_status_is_available(old_status);
-+ available = gaim2_status_is_available(status);
-+ old_available = gaim2_status_is_available(old_status);
-
-- if (gaim_prefs_get_bool("/plugins/core/statenotify/notify_away")) {
-+ if (gaim2_prefs_get_bool("/plugins/core/statenotify/notify_away")) {
- if (available && !old_available)
- write_status(buddy, _("%s is no longer away."));
- else if (!available && old_available)
-@@ -53,10 +53,10 @@ buddy_status_changed_cb(GaimBuddy *buddy
- }
-
- static void
--buddy_idle_changed_cb(GaimBuddy *buddy, gboolean old_idle, gboolean idle,
-+buddy_idle_changed_cb(Gaim2Buddy *buddy, gboolean old_idle, gboolean idle,
- void *data)
- {
-- if (gaim_prefs_get_bool("/plugins/core/statenotify/notify_idle")) {
-+ if (gaim2_prefs_get_bool("/plugins/core/statenotify/notify_idle")) {
- if (idle) {
- write_status(buddy, _("%s has become idle."));
- } else {
-@@ -66,67 +66,67 @@ buddy_idle_changed_cb(GaimBuddy *buddy,
- }
-
- static void
--buddy_signon_cb(GaimBuddy *buddy, void *data)
-+buddy_signon_cb(Gaim2Buddy *buddy, void *data)
- {
-- if (gaim_prefs_get_bool("/plugins/core/statenotify/notify_signon"))
-+ if (gaim2_prefs_get_bool("/plugins/core/statenotify/notify_signon"))
- write_status(buddy, _("%s has signed on."));
- }
-
- static void
--buddy_signoff_cb(GaimBuddy *buddy, void *data)
-+buddy_signoff_cb(Gaim2Buddy *buddy, void *data)
- {
-- if (gaim_prefs_get_bool("/plugins/core/statenotify/notify_signon"))
-+ if (gaim2_prefs_get_bool("/plugins/core/statenotify/notify_signon"))
- write_status(buddy, _("%s has signed off."));
- }
-
--static GaimPluginPrefFrame *
--get_plugin_pref_frame(GaimPlugin *plugin)
-+static Gaim2PluginPrefFrame *
-+get_plugin_pref_frame(Gaim2Plugin *plugin)
- {
-- GaimPluginPrefFrame *frame;
-- GaimPluginPref *ppref;
-+ Gaim2PluginPrefFrame *frame;
-+ Gaim2PluginPref *ppref;
-
-- frame = gaim_plugin_pref_frame_new();
-+ frame = gaim2_plugin_pref_frame_new();
-
-- ppref = gaim_plugin_pref_new_with_label(_("Notify When"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label(_("Notify When"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label("/plugins/core/statenotify/notify_away", _("Buddy Goes _Away"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_name_and_label("/plugins/core/statenotify/notify_away", _("Buddy Goes _Away"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label("/plugins/core/statenotify/notify_idle", _("Buddy Goes _Idle"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_name_and_label("/plugins/core/statenotify/notify_idle", _("Buddy Goes _Idle"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label("/plugins/core/statenotify/notify_signon", _("Buddy _Signs On/Off"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_name_and_label("/plugins/core/statenotify/notify_signon", _("Buddy _Signs On/Off"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
- return frame;
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *blist_handle = gaim_blist_get_handle();
-+ void *blist_handle = gaim2_blist_get_handle();
-
-- gaim_signal_connect(blist_handle, "buddy-status-changed", plugin,
-+ gaim2_signal_connect(blist_handle, "buddy-status-changed", plugin,
- GAIM_CALLBACK(buddy_status_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-idle-changed", plugin,
-+ gaim2_signal_connect(blist_handle, "buddy-idle-changed", plugin,
- GAIM_CALLBACK(buddy_idle_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-on", plugin,
-+ gaim2_signal_connect(blist_handle, "buddy-signed-on", plugin,
- GAIM_CALLBACK(buddy_signon_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-off", plugin,
-+ gaim2_signal_connect(blist_handle, "buddy-signed-off", plugin,
- GAIM_CALLBACK(buddy_signoff_cb), NULL);
-
- return TRUE;
- }
-
--static GaimPluginUiInfo prefs_info =
-+static Gaim2PluginUiInfo prefs_info =
- {
- get_plugin_pref_frame,
- 0, /* page_num (Reserved) */
- NULL /* frame (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -160,12 +160,12 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/core/statenotify");
-- gaim_prefs_add_bool("/plugins/core/statenotify/notify_away", TRUE);
-- gaim_prefs_add_bool("/plugins/core/statenotify/notify_idle", TRUE);
-- gaim_prefs_add_bool("/plugins/core/statenotify/notify_signon", TRUE);
-+ gaim2_prefs_add_none("/plugins/core/statenotify");
-+ gaim2_prefs_add_bool("/plugins/core/statenotify/notify_away", TRUE);
-+ gaim2_prefs_add_bool("/plugins/core/statenotify/notify_idle", TRUE);
-+ gaim2_prefs_add_bool("/plugins/core/statenotify/notify_signon", TRUE);
- }
-
- GAIM_INIT_PLUGIN(statenotify, init_plugin, info)
-diff -prNu ./plugins/tcl/Makefile.am ./plugins/tcl/Makefile.am
---- ./plugins/tcl/Makefile.am 2005-04-29 19:04:25.000000000 +0200
-+++ ./plugins/tcl/Makefile.am 2006-01-05 15:30:10.000000000 +0100
-@@ -1,10 +1,10 @@
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- tcl_la_LDFLAGS = -module -avoid-version $(GLIB_LIBS) $(TCL_LIBS) $(TK_LIBS)
-
- plugin_LTLIBRARIES = tcl.la
-
--tcl_la_SOURCES = tcl.c tcl_glib.c tcl_glib.h tcl_cmds.c tcl_signals.c tcl_gaim.h
-+tcl_la_SOURCES = tcl.c tcl_glib.c tcl_glib.h tcl_cmds.c tcl_signals.c tcl_gaim2.h
-
- EXTRA_DIST = signal-test.tcl Makefile.mingw tcl_win32.c
-
-diff -prNu ./plugins/tcl/tcl.c ./plugins/tcl/tcl.c
---- ./plugins/tcl/tcl.c 2005-08-14 00:09:31.000000000 +0200
-+++ ./plugins/tcl/tcl.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
-- * @file tcl.c Gaim Tcl plugin bindings
-+ * @file tcl.c Gaim2 Tcl plugin bindings
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -35,7 +35,7 @@
- #include <string.h>
-
- #include "tcl_glib.h"
--#include "tcl_gaim.h"
-+#include "tcl_gaim2.h"
-
- #include "internal.h"
- #include "connection.h"
-@@ -46,17 +46,17 @@
- #include "version.h"
-
- struct tcl_plugin_data {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- Tcl_Interp *interp;
- };
-
- static GHashTable *tcl_plugins = NULL;
-
--GaimPlugin *_tcl_plugin;
-+Gaim2Plugin *_tcl_plugin;
-
- static gboolean tcl_loaded = FALSE;
-
--GaimPlugin *tcl_interp_get_plugin(Tcl_Interp *interp)
-+Gaim2Plugin *tcl_interp_get_plugin(Tcl_Interp *interp)
- {
- struct tcl_plugin_data *data;
-
-@@ -71,29 +71,29 @@ static int tcl_init_interp(Tcl_Interp *i
- {
- char *rcfile;
- char init[] =
-- "namespace eval ::gaim {\n"
-+ "namespace eval ::gaim2 {\n"
- " namespace export account buddy connection conversation\n"
- " namespace export core debug notify prefs send_im\n"
- " namespace export signal unload\n"
- " namespace eval _callback { }\n"
- "\n"
- " proc conv_send { account who text } {\n"
-- " set gc [gaim::account connection $account]\n"
-- " set convo [gaim::conversation new $account $who]\n"
-- " set myalias [gaim::account alias $account]\n"
-+ " set gc [gaim2::account connection $account]\n"
-+ " set convo [gaim2::conversation new $account $who]\n"
-+ " set myalias [gaim2::account alias $account]\n"
- "\n"
- " if {![string length $myalias]} {\n"
-- " set myalias [gaim::account username $account]\n"
-+ " set myalias [gaim2::account username $account]\n"
- " }\n"
- "\n"
-- " gaim::send_im $gc $who $text\n"
-- " gaim::conversation write $convo send $myalias $text\n"
-+ " gaim2::send_im $gc $who $text\n"
-+ " gaim2::conversation write $convo send $myalias $text\n"
- " }\n"
- "}\n"
- "\n"
- "proc bgerror { message } {\n"
- " global errorInfo\n"
-- " gaim::notify -error \"Tcl Error\" \"Tcl Error: $message\" \"$errorInfo\"\n"
-+ " gaim2::notify -error \"Tcl Error\" \"Tcl Error: $message\" \"$errorInfo\"\n"
- "}\n";
-
- if (Tcl_EvalEx(interp, init, -1, TCL_EVAL_GLOBAL) != TCL_OK) {
-@@ -101,31 +101,31 @@ static int tcl_init_interp(Tcl_Interp *i
- }
-
- Tcl_SetVar(interp, "argc", "0", TCL_GLOBAL_ONLY);
-- Tcl_SetVar(interp, "argv0", "gaim", TCL_GLOBAL_ONLY);
-+ Tcl_SetVar(interp, "argv0", "gaim2", TCL_GLOBAL_ONLY);
- Tcl_SetVar(interp, "tcl_interactive", "0", TCL_GLOBAL_ONLY);
-- rcfile = g_strdup_printf("%s" G_DIR_SEPARATOR_S "tclrc", gaim_user_dir());
-+ rcfile = g_strdup_printf("%s" G_DIR_SEPARATOR_S "tclrc", gaim2_user_dir());
- Tcl_SetVar(interp, "tcl_rcFileName", rcfile, TCL_GLOBAL_ONLY);
- g_free(rcfile);
-
-- Tcl_SetVar(interp, "::gaim::version", VERSION, TCL_GLOBAL_ONLY);
-- Tcl_SetVar(interp, "::gaim::user_dir", gaim_user_dir(), TCL_GLOBAL_ONLY);
-+ Tcl_SetVar(interp, "::gaim2::version", VERSION, TCL_GLOBAL_ONLY);
-+ Tcl_SetVar(interp, "::gaim2::user_dir", gaim2_user_dir(), TCL_GLOBAL_ONLY);
- #ifdef HAVE_TK
-- Tcl_SetVar(interp, "::gaim::tk_available", "1", TCL_GLOBAL_ONLY);
-+ Tcl_SetVar(interp, "::gaim2::tk_available", "1", TCL_GLOBAL_ONLY);
- #else
-- Tcl_SetVar(interp, "::gaim::tk_available", "0", TCL_GLOBAL_ONLY);
-+ Tcl_SetVar(interp, "::gaim2::tk_available", "0", TCL_GLOBAL_ONLY);
- #endif /* HAVE_TK */
-
-- Tcl_CreateObjCommand(interp, "::gaim::account", tcl_cmd_account, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::buddy", tcl_cmd_buddy, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::connection", tcl_cmd_connection, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::conversation", tcl_cmd_conversation, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::core", tcl_cmd_core, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::debug", tcl_cmd_debug, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::notify", tcl_cmd_notify, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::prefs", tcl_cmd_prefs, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::send_im", tcl_cmd_send_im, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::signal", tcl_cmd_signal, (ClientData)NULL, NULL);
-- Tcl_CreateObjCommand(interp, "::gaim::unload", tcl_cmd_unload, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::account", tcl_cmd_account, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::buddy", tcl_cmd_buddy, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::connection", tcl_cmd_connection, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::conversation", tcl_cmd_conversation, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::core", tcl_cmd_core, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::debug", tcl_cmd_debug, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::notify", tcl_cmd_notify, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::prefs", tcl_cmd_prefs, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::send_im", tcl_cmd_send_im, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::signal", tcl_cmd_signal, (ClientData)NULL, NULL);
-+ Tcl_CreateObjCommand(interp, "::gaim2::unload", tcl_cmd_unload, (ClientData)NULL, NULL);
-
- return 0;
- }
-@@ -144,14 +144,14 @@ static Tcl_Interp *tcl_create_interp()
- Tcl_DeleteInterp(interp);
- return NULL;
- }
-- Tcl_StaticPackage(interp, "gaim", tcl_init_interp, NULL);
-+ Tcl_StaticPackage(interp, "gaim2", tcl_init_interp, NULL);
-
- return interp;
- }
-
--static gboolean tcl_probe_plugin(GaimPlugin *plugin)
-+static gboolean tcl_probe_plugin(Gaim2Plugin *plugin)
- {
-- GaimPluginInfo *info;
-+ Gaim2PluginInfo *info;
- Tcl_Interp *interp;
- Tcl_Parse parse;
- Tcl_Obj *result, **listitems;
-@@ -179,7 +179,7 @@ static gboolean tcl_probe_plugin(GaimPlu
- }
-
- if (ferror(fp)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "error reading %s (%s)\n", plugin->path, strerror(errno));
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "error reading %s (%s)\n", plugin->path, strerror(errno));
- g_free(buf);
- fclose(fp);
- return FALSE;
-@@ -194,7 +194,7 @@ static gboolean tcl_probe_plugin(GaimPlu
- next = buf;
- do {
- if (Tcl_ParseCommand(interp, next, len, 0, &parse) == TCL_ERROR) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "parse error in %s: %s\n", plugin->path,
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "parse error in %s: %s\n", plugin->path,
- Tcl_GetString(Tcl_GetObjResult(interp)));
- err = 1;
- break;
-@@ -220,7 +220,7 @@ static gboolean tcl_probe_plugin(GaimPlu
- result = Tcl_GetObjResult(interp);
- if (Tcl_ListObjGetElements(interp, result, &nelems, &listitems) == TCL_OK) {
- if (nelems == 6) {
-- info = g_new0(GaimPluginInfo, 1);
-+ info = g_new0(Gaim2PluginInfo, 1);
-
- info->magic = GAIM_PLUGIN_MAGIC;
- info->major_version = GAIM_MAJOR_VERSION;
-@@ -237,7 +237,7 @@ static gboolean tcl_probe_plugin(GaimPlu
-
- plugin->info = info;
-
-- if (gaim_plugin_register(plugin))
-+ if (gaim2_plugin_register(plugin))
- status = TRUE;
- }
- }
-@@ -249,7 +249,7 @@ static gboolean tcl_probe_plugin(GaimPlu
- return status;
- }
-
--static gboolean tcl_load_plugin(GaimPlugin *plugin)
-+static gboolean tcl_load_plugin(Gaim2Plugin *plugin)
- {
- struct tcl_plugin_data *data;
- Tcl_Interp *interp;
-@@ -258,7 +258,7 @@ static gboolean tcl_load_plugin(GaimPlug
- plugin->extra = NULL;
-
- if ((interp = tcl_create_interp()) == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "Could not initialize Tcl interpreter\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "Could not initialize Tcl interpreter\n");
- return FALSE;
- }
-
-@@ -266,7 +266,7 @@ static gboolean tcl_load_plugin(GaimPlug
-
- if (Tcl_EvalFile(interp, plugin->path) != TCL_OK) {
- result = Tcl_GetObjResult(interp);
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "Error evaluating %s: %s\n", plugin->path, Tcl_GetString(result));
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "Error evaluating %s: %s\n", plugin->path, Tcl_GetString(result));
- Tcl_DeleteInterp(interp);
- return FALSE;
- }
-@@ -283,7 +283,7 @@ static gboolean tcl_load_plugin(GaimPlug
- return TRUE;
- }
-
--static gboolean tcl_unload_plugin(GaimPlugin *plugin)
-+static gboolean tcl_unload_plugin(Gaim2Plugin *plugin)
- {
- struct tcl_plugin_data *data;
-
-@@ -294,7 +294,7 @@ static gboolean tcl_unload_plugin(GaimPl
-
- g_hash_table_remove(tcl_plugins, (gpointer)(data->interp));
- if (data != NULL) {
-- gaim_signals_disconnect_by_handle(data->interp);
-+ gaim2_signals_disconnect_by_handle(data->interp);
- tcl_signal_cleanup(data->interp);
- Tcl_Release((ClientData)data->interp);
- Tcl_DeleteInterp(data->interp);
-@@ -304,7 +304,7 @@ static gboolean tcl_unload_plugin(GaimPl
- return TRUE;
- }
-
--static void tcl_destroy_plugin(GaimPlugin *plugin)
-+static void tcl_destroy_plugin(Gaim2Plugin *plugin)
- {
- if (plugin->info != NULL) {
- g_free(plugin->info->name);
-@@ -317,7 +317,7 @@ static void tcl_destroy_plugin(GaimPlugi
- return;
- }
-
--static gboolean tcl_load(GaimPlugin *plugin)
-+static gboolean tcl_load(Gaim2Plugin *plugin)
- {
- if(!tcl_loaded)
- return FALSE;
-@@ -332,7 +332,7 @@ static gboolean tcl_load(GaimPlugin *plu
- return TRUE;
- }
-
--static gboolean tcl_unload(GaimPlugin *plugin)
-+static gboolean tcl_unload(Gaim2Plugin *plugin)
- {
- g_hash_table_destroy(tcl_plugins);
- tcl_plugins = NULL;
-@@ -340,7 +340,7 @@ static gboolean tcl_unload(GaimPlugin *p
- return TRUE;
- }
-
--static GaimPluginLoaderInfo tcl_loader_info =
-+static Gaim2PluginLoaderInfo tcl_loader_info =
- {
- NULL,
- tcl_probe_plugin,
-@@ -349,7 +349,7 @@ static GaimPluginLoaderInfo tcl_loader_i
- tcl_destroy_plugin,
- };
-
--static GaimPluginInfo tcl_info =
-+static Gaim2PluginInfo tcl_info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -384,7 +384,7 @@ extern void (CALLBACK* wtk_Init)(Tcl_Int
- #define Tk_Init wtk_Init
- #endif /* _WIN32 */
-
--static void tcl_init_plugin(GaimPlugin *plugin)
-+static void tcl_init_plugin(Gaim2Plugin *plugin)
- {
- #ifdef USE_TCL_STUBS
- Tcl_Interp *interp=NULL;
-@@ -396,18 +396,18 @@ static void tcl_init_plugin(GaimPlugin *
- return;
-
- if(!Tcl_InitStubs(interp, TCL_VERSION, 0)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "Tcl_InitStubs: %s\n", interp->result);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "Tcl_InitStubs: %s\n", interp->result);
- return;
- }
- #endif
-
-- Tcl_FindExecutable("gaim");
-+ Tcl_FindExecutable("gaim2");
-
- #if defined(USE_TK_STUBS) && defined(HAVE_TK)
- Tk_Init(interp);
-
- if(!Tk_InitStubs(interp, TK_VERSION, 0)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "Error Tk_InitStubs: %s\n", interp->result);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "Error Tk_InitStubs: %s\n", interp->result);
- Tcl_DeleteInterp(interp);
- return;
- }
-diff -prNu ./plugins/tcl/tcl_cmds.c ./plugins/tcl/tcl_cmds.c
---- ./plugins/tcl/tcl_cmds.c 2005-08-25 04:33:44.000000000 +0200
-+++ ./plugins/tcl/tcl_cmds.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
-- * @file tcl_cmds.c Commands for the Gaim Tcl plugin bindings
-+ * @file tcl_cmds.c Commands for the Gaim2 Tcl plugin bindings
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -33,16 +33,16 @@
- #include "prefs.h"
- #include "core.h"
-
--#include "tcl_gaim.h"
-+#include "tcl_gaim2.h"
-
--static gboolean tcl_validate_account(GaimAccount *account, Tcl_Interp *interp);
--static gboolean tcl_validate_conversation(GaimConversation *convo, Tcl_Interp *interp);
--static gboolean tcl_validate_gc(GaimConnection *gc);
-+static gboolean tcl_validate_account(Gaim2Account *account, Tcl_Interp *interp);
-+static gboolean tcl_validate_conversation(Gaim2Conversation *convo, Tcl_Interp *interp);
-+static gboolean tcl_validate_gc(Gaim2Connection *gc);
-
--static gboolean tcl_validate_account(GaimAccount *account, Tcl_Interp *interp)
-+static gboolean tcl_validate_account(Gaim2Account *account, Tcl_Interp *interp)
- {
- GList *cur;
-- for (cur = gaim_accounts_get_all(); cur != NULL; cur = g_list_next(cur)) {
-+ for (cur = gaim2_accounts_get_all(); cur != NULL; cur = g_list_next(cur)) {
- if (account == cur->data)
- return TRUE;
- }
-@@ -51,11 +51,11 @@ static gboolean tcl_validate_account(Gai
- return FALSE;
- }
-
--static gboolean tcl_validate_conversation(GaimConversation *convo, Tcl_Interp *interp)
-+static gboolean tcl_validate_conversation(Gaim2Conversation *convo, Tcl_Interp *interp)
- {
- GList *cur;
-
-- for (cur = gaim_get_conversations(); cur != NULL; cur = g_list_next(cur)) {
-+ for (cur = gaim2_get_conversations(); cur != NULL; cur = g_list_next(cur)) {
- if (convo == cur->data)
- return TRUE;
- }
-@@ -64,10 +64,10 @@ static gboolean tcl_validate_conversatio
- return FALSE;
- }
-
--static gboolean tcl_validate_gc(GaimConnection *gc)
-+static gboolean tcl_validate_gc(Gaim2Connection *gc)
- {
- GList *cur;
-- for (cur = gaim_connections_get_all(); cur != NULL; cur = g_list_next(cur)) {
-+ for (cur = gaim2_connections_get_all(); cur != NULL; cur = g_list_next(cur)) {
- if (gc == cur->data)
- return TRUE;
- }
-@@ -88,7 +88,7 @@ int tcl_cmd_account(ClientData unused, T
- enum { CMD_ACCOUNTLIST_ALL, CMD_ACCOUNTLIST_ONLINE } listopt;
- const char *alias;
- GList *cur;
-- GaimAccount *account;
-+ Gaim2Account *account;
- int error;
-
- if (objc < 2) {
-@@ -108,7 +108,7 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- alias = gaim_account_get_alias(account);
-+ alias = gaim2_account_get_alias(account);
- Tcl_SetStringObj(result, alias ? (char *)alias : "", -1);
- break;
- case CMD_ACCOUNT_CONNECT:
-@@ -119,9 +119,9 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- if (!gaim_account_is_connected(account))
-- gaim_account_connect(account);
-- Tcl_SetIntObj(result, (int)gaim_account_get_connection(account));
-+ if (!gaim2_account_is_connected(account))
-+ gaim2_account_connect(account);
-+ Tcl_SetIntObj(result, (int)gaim2_account_get_connection(account));
- break;
- case CMD_ACCOUNT_CONNECTION:
- if (objc != 3) {
-@@ -131,7 +131,7 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- Tcl_SetIntObj(result, (int)gaim_account_get_connection(account));
-+ Tcl_SetIntObj(result, (int)gaim2_account_get_connection(account));
- break;
- case CMD_ACCOUNT_DISCONNECT:
- if (objc != 3) {
-@@ -141,14 +141,14 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- gaim_account_disconnect(account);
-+ gaim2_account_disconnect(account);
- break;
- case CMD_ACCOUNT_FIND:
- if (objc != 4) {
- Tcl_WrongNumArgs(interp, 2, objv, "username protocol");
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_accounts_find(Tcl_GetString(objv[2]),
-+ Tcl_SetIntObj(result, (int)gaim2_accounts_find(Tcl_GetString(objv[2]),
- Tcl_GetString(objv[3])));
- break;
- case CMD_ACCOUNT_HANDLE:
-@@ -156,7 +156,7 @@ int tcl_cmd_account(ClientData unused, T
- Tcl_WrongNumArgs(interp, 2, objv, "");
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_accounts_get_handle());
-+ Tcl_SetIntObj(result, (int)gaim2_accounts_get_handle());
- break;
- case CMD_ACCOUNT_ISCONNECTED:
- if (objc != 3) {
-@@ -166,7 +166,7 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- Tcl_SetBooleanObj(result, gaim_account_is_connected(account));
-+ Tcl_SetBooleanObj(result, gaim2_account_is_connected(account));
- break;
- case CMD_ACCOUNT_LIST:
- listopt = CMD_ACCOUNTLIST_ALL;
-@@ -179,9 +179,9 @@ int tcl_cmd_account(ClientData unused, T
- return error;
- }
- list = Tcl_NewListObj(0, NULL);
-- for (cur = gaim_accounts_get_all(); cur != NULL; cur = g_list_next(cur)) {
-+ for (cur = gaim2_accounts_get_all(); cur != NULL; cur = g_list_next(cur)) {
- account = cur->data;
-- if (listopt == CMD_ACCOUNTLIST_ONLINE && !gaim_account_is_connected(account))
-+ if (listopt == CMD_ACCOUNTLIST_ONLINE && !gaim2_account_is_connected(account))
- continue;
- elem = Tcl_NewIntObj((int)account);
- Tcl_ListObjAppendElement(interp, list, elem);
-@@ -196,7 +196,7 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- Tcl_SetStringObj(result, (char *)gaim_account_get_protocol_id(account), -1);
-+ Tcl_SetStringObj(result, (char *)gaim2_account_get_protocol_id(account), -1);
- break;
- case CMD_ACCOUNT_USERNAME:
- if (objc != 3) {
-@@ -206,17 +206,17 @@ int tcl_cmd_account(ClientData unused, T
- error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account);
- if (error || !tcl_validate_account(account, interp))
- return TCL_ERROR;
-- Tcl_SetStringObj(result, (char *)gaim_account_get_username(account), -1);
-+ Tcl_SetStringObj(result, (char *)gaim2_account_get_username(account), -1);
- break;
- }
-
- return TCL_OK;
- }
-
--static GaimBlistNode *tcl_list_to_buddy(Tcl_Interp *interp, int count, Tcl_Obj **elems)
-+static Gaim2BlistNode *tcl_list_to_buddy(Tcl_Interp *interp, int count, Tcl_Obj **elems)
- {
-- GaimBlistNode *node = NULL;
-- GaimAccount *account;
-+ Gaim2BlistNode *node = NULL;
-+ Gaim2Account *account;
- char *name;
- char *type;
-
-@@ -233,9 +233,9 @@ static GaimBlistNode *tcl_list_to_buddy(
- return NULL;
-
- if (!strcmp(type, "buddy")) {
-- node = (GaimBlistNode *)gaim_find_buddy(account, name);
-+ node = (Gaim2BlistNode *)gaim2_find_buddy(account, name);
- } else if (!strcmp(type, "group")) {
-- node = (GaimBlistNode *)gaim_blist_find_chat(account, name);
-+ node = (Gaim2BlistNode *)gaim2_blist_find_chat(account, name);
- }
-
- return node;
-@@ -246,11 +246,11 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- Tcl_Obj *list, *tclgroup, *tclgrouplist, *tclcontact, *tclcontactlist, *tclbud, **elems, *result;
- const char *cmds[] = { "alias", "handle", "info", "list", NULL };
- enum { CMD_BUDDY_ALIAS, CMD_BUDDY_HANDLE, CMD_BUDDY_INFO, CMD_BUDDY_LIST } cmd;
-- GaimBuddyList *blist;
-- GaimBlistNode *node, *gnode, *bnode;
-- GaimAccount *account;
-- GaimBuddy *bud;
-- GaimChat *cnode;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *node, *gnode, *bnode;
-+ Gaim2Account *account;
-+ Gaim2Buddy *bud;
-+ Gaim2Chat *cnode;
- int error, all = 0, count;
-
- if (objc < 2) {
-@@ -273,9 +273,9 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- if ((node = tcl_list_to_buddy(interp, count, elems)) == NULL)
- return TCL_ERROR;
- if (node->type == GAIM_BLIST_CHAT_NODE)
-- Tcl_SetStringObj(result, ((GaimChat *)node)->alias, -1);
-+ Tcl_SetStringObj(result, ((Gaim2Chat *)node)->alias, -1);
- else if (node->type == GAIM_BLIST_BUDDY_NODE)
-- Tcl_SetStringObj(result, (char *)gaim_buddy_get_alias((GaimBuddy *)node), -1);
-+ Tcl_SetStringObj(result, (char *)gaim2_buddy_get_alias((Gaim2Buddy *)node), -1);
- return TCL_OK;
- break;
- case CMD_BUDDY_HANDLE:
-@@ -283,7 +283,7 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- Tcl_WrongNumArgs(interp, 2, objv, "");
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_blist_get_handle());
-+ Tcl_SetIntObj(result, (int)gaim2_blist_get_handle());
- break;
- case CMD_BUDDY_INFO:
- if (objc != 3 && objc != 4) {
-@@ -305,13 +305,13 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- return TCL_ERROR;
- if (!tcl_validate_account(account, interp))
- return TCL_ERROR;
-- serv_get_info(gaim_account_get_connection(account), Tcl_GetString(elems[1]));
-+ serv_get_info(gaim2_account_get_connection(account), Tcl_GetString(elems[1]));
- } else {
- if ((error = Tcl_GetIntFromObj(interp, objv[2], (int *)&account)) != TCL_OK)
- return error;
- if (!tcl_validate_account(account, interp))
- return TCL_ERROR;
-- serv_get_info(gaim_account_get_connection(account), Tcl_GetString(objv[3]));
-+ serv_get_info(gaim2_account_get_connection(account), Tcl_GetString(objv[3]));
- }
- break;
- case CMD_BUDDY_LIST:
-@@ -325,12 +325,12 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- }
- }
- list = Tcl_NewListObj(0, NULL);
-- blist = gaim_get_blist();
-+ blist = gaim2_get_blist();
- for (gnode = blist->root; gnode != NULL; gnode = gnode->next) {
- tclgroup = Tcl_NewListObj(0, NULL);
- Tcl_ListObjAppendElement(interp, tclgroup, Tcl_NewStringObj("group", -1));
- Tcl_ListObjAppendElement(interp, tclgroup,
-- Tcl_NewStringObj(((GaimGroup *)gnode)->name, -1));
-+ Tcl_NewStringObj(((Gaim2Group *)gnode)->name, -1));
- tclgrouplist = Tcl_NewListObj(0, NULL);
- for (node = gnode->child; node != NULL; node = node->next) {
- switch (node->type) {
-@@ -344,8 +344,8 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- for (bnode = node->child; bnode != NULL; bnode = bnode ->next) {
- if (bnode->type != GAIM_BLIST_BUDDY_NODE)
- continue;
-- bud = (GaimBuddy *)bnode;
-- if (!all && !gaim_account_is_connected(bud->account))
-+ bud = (Gaim2Buddy *)bnode;
-+ if (!all && !gaim2_account_is_connected(bud->account))
- continue;
- count++;
- tclbud = Tcl_NewListObj(0, NULL);
-@@ -362,8 +362,8 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- Tcl_DecrRefCount(tclcontactlist);
- break;
- case GAIM_BLIST_CHAT_NODE:
-- cnode = (GaimChat *)node;
-- if (!all && !gaim_account_is_connected(cnode->account))
-+ cnode = (Gaim2Chat *)node;
-+ if (!all && !gaim2_account_is_connected(cnode->account))
- continue;
- tclbud = Tcl_NewListObj(0, NULL);
- Tcl_ListObjAppendElement(interp, tclbud, Tcl_NewStringObj("chat", -1));
-@@ -372,7 +372,7 @@ int tcl_cmd_buddy(ClientData unused, Tcl
- Tcl_ListObjAppendElement(interp, tclgrouplist, tclbud);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_WARNING, "tcl", "Unexpected buddy type %d", node->type);
-+ gaim2_debug(GAIM_DEBUG_WARNING, "tcl", "Unexpected buddy type %d", node->type);
- continue;
- }
- }
-@@ -393,7 +393,7 @@ int tcl_cmd_connection(ClientData unused
- enum { CMD_CONN_ACCOUNT, CMD_CONN_DISPLAYNAME, CMD_CONN_HANDLE, CMD_CONN_LIST } cmd;
- int error;
- GList *cur;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- if (objc < 2) {
- Tcl_WrongNumArgs(interp, 1, objv, "subcommand ?args?");
-@@ -414,7 +414,7 @@ int tcl_cmd_connection(ClientData unused
- Tcl_SetStringObj(result, "invalid gc", -1);
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_connection_get_account(gc));
-+ Tcl_SetIntObj(result, (int)gaim2_connection_get_account(gc));
- break;
- case CMD_CONN_DISPLAYNAME:
- if (objc != 3) {
-@@ -426,14 +426,14 @@ int tcl_cmd_connection(ClientData unused
- Tcl_SetStringObj(result, "invalid gc", -1);
- return TCL_ERROR;
- }
-- Tcl_SetStringObj(result, (char *)gaim_connection_get_display_name(gc), -1);
-+ Tcl_SetStringObj(result, (char *)gaim2_connection_get_display_name(gc), -1);
- break;
- case CMD_CONN_HANDLE:
- if (objc != 2) {
- Tcl_WrongNumArgs(interp, 2, objv, "");
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_connections_get_handle());
-+ Tcl_SetIntObj(result, (int)gaim2_connections_get_handle());
- break;
- case CMD_CONN_LIST:
- if (objc != 2) {
-@@ -441,7 +441,7 @@ int tcl_cmd_connection(ClientData unused
- return TCL_ERROR;
- }
- list = Tcl_NewListObj(0, NULL);
-- for (cur = gaim_connections_get_all(); cur != NULL; cur = g_list_next(cur)) {
-+ for (cur = gaim2_connections_get_all(); cur != NULL; cur = g_list_next(cur)) {
- elem = Tcl_NewIntObj((int)cur->data);
- Tcl_ListObjAppendElement(interp, list, elem);
- }
-@@ -461,9 +461,9 @@ int tcl_cmd_conversation(ClientData unus
- enum { CMD_CONV_WRITE_SEND, CMD_CONV_WRITE_RECV, CMD_CONV_WRITE_SYSTEM } style;
- const char *newopts[] = { "-chat", "-im" };
- enum { CMD_CONV_NEW_CHAT, CMD_CONV_NEW_IM } newopt;
-- GaimConversation *convo;
-- GaimAccount *account;
-- GaimConversationType type;
-+ Gaim2Conversation *convo;
-+ Gaim2Account *account;
-+ Gaim2ConversationType type;
- GList *cur;
- char *opt, *from, *what;
- int error, argsused, flags = 0;
-@@ -488,7 +488,7 @@ int tcl_cmd_conversation(ClientData unus
- return error;
- if (!tcl_validate_account(account, interp))
- return TCL_ERROR;
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
- Tcl_GetString(objv[3]),
- account);
- Tcl_SetIntObj(result, (int)convo);
-@@ -498,11 +498,11 @@ int tcl_cmd_conversation(ClientData unus
- Tcl_WrongNumArgs(interp, 2, objv, "");
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_conversations_get_handle());
-+ Tcl_SetIntObj(result, (int)gaim2_conversations_get_handle());
- break;
- case CMD_CONV_LIST:
- list = Tcl_NewListObj(0, NULL);
-- for (cur = gaim_get_conversations(); cur != NULL; cur = g_list_next(cur)) {
-+ for (cur = gaim2_get_conversations(); cur != NULL; cur = g_list_next(cur)) {
- elem = Tcl_NewIntObj((int)cur->data);
- Tcl_ListObjAppendElement(interp, list, elem);
- }
-@@ -542,7 +542,7 @@ int tcl_cmd_conversation(ClientData unus
- return error;
- if (!tcl_validate_account(account, interp))
- return TCL_ERROR;
-- convo = gaim_conversation_new(type, account, Tcl_GetString(objv[argsused]));
-+ convo = gaim2_conversation_new(type, account, Tcl_GetString(objv[argsused]));
- Tcl_SetIntObj(result, (int)convo);
- break;
- case CMD_CONV_WRITE:
-@@ -570,10 +570,10 @@ int tcl_cmd_conversation(ClientData unus
- flags = GAIM_MESSAGE_SYSTEM;
- break;
- }
-- if (gaim_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), from, what, flags, time(NULL));
-+ if (gaim2_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), from, what, flags, time(NULL));
- else
-- gaim_conv_im_write(GAIM_CONV_IM(convo), from, what, flags, time(NULL));
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), from, what, flags, time(NULL));
- break;
- }
-
-@@ -601,14 +601,14 @@ int tcl_cmd_core(ClientData unused, Tcl_
- Tcl_WrongNumArgs(interp, 2, objv, "");
- return TCL_ERROR;
- }
-- Tcl_SetIntObj(result, (int)gaim_get_core());
-+ Tcl_SetIntObj(result, (int)gaim2_get_core());
- break;
- case CMD_CORE_QUIT:
- if (objc != 2) {
- Tcl_WrongNumArgs(interp, 2, objv, "");
- return TCL_ERROR;
- }
-- gaim_core_quit();
-+ gaim2_core_quit();
- break;
- }
-
-@@ -620,7 +620,7 @@ int tcl_cmd_debug(ClientData unused, Tcl
- char *category, *message;
- int lev;
- const char *levels[] = { "-misc", "-info", "-warning", "-error", NULL };
-- GaimDebugLevel levelind[] = { GAIM_DEBUG_MISC, GAIM_DEBUG_INFO, GAIM_DEBUG_WARNING, GAIM_DEBUG_ERROR };
-+ Gaim2DebugLevel levelind[] = { GAIM_DEBUG_MISC, GAIM_DEBUG_INFO, GAIM_DEBUG_WARNING, GAIM_DEBUG_ERROR };
- int error;
-
- if (objc != 4) {
-@@ -635,7 +635,7 @@ int tcl_cmd_debug(ClientData unused, Tcl
- category = Tcl_GetString(objv[2]);
- message = Tcl_GetString(objv[3]);
-
-- gaim_debug(levelind[lev], category, "%s\n", message);
-+ gaim2_debug(levelind[lev], category, "%s\n", message);
-
- return TCL_OK;
- }
-@@ -644,7 +644,7 @@ int tcl_cmd_notify(ClientData unused, Tc
- {
- int error, type;
- const char *opts[] = { "-error", "-warning", "-info", NULL };
-- GaimNotifyMsgType optind[] = { GAIM_NOTIFY_MSG_ERROR, GAIM_NOTIFY_MSG_WARNING, GAIM_NOTIFY_MSG_INFO };
-+ Gaim2NotifyMsgType optind[] = { GAIM_NOTIFY_MSG_ERROR, GAIM_NOTIFY_MSG_WARNING, GAIM_NOTIFY_MSG_INFO };
- char *title, *msg1, *msg2;
-
- if (objc < 4 || objc > 5) {
-@@ -665,7 +665,7 @@ int tcl_cmd_notify(ClientData unused, Tc
- msg2 = Tcl_GetString(objv[4]);
- }
-
-- gaim_notify_message(_tcl_plugin, optind[type], title, msg1, msg2, NULL, NULL);
-+ gaim2_notify_message(_tcl_plugin, optind[type], title, msg1, msg2, NULL, NULL);
-
- return TCL_OK;
- }
-@@ -677,7 +677,7 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- enum { CMD_PREFS_GET, CMD_PREFS_SET, CMD_PREFS_TYPE } cmd;
- /* char *types[] = { "none", "boolean", "int", "string", "stringlist", NULL }; */
- /* enum { TCL_PREFS_NONE, TCL_PREFS_BOOL, TCL_PREFS_INT, TCL_PREFS_STRING, TCL_PREFS_STRINGLIST } type; */
-- GaimPrefType preftype;
-+ Gaim2PrefType preftype;
- GList *cur;
- int error, intval, nelem, i;
-
-@@ -696,23 +696,23 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- Tcl_WrongNumArgs(interp, 1, objv, "path");
- return TCL_ERROR;
- }
-- preftype = gaim_prefs_get_type(Tcl_GetString(objv[2]));
-+ preftype = gaim2_prefs_get_type(Tcl_GetString(objv[2]));
- switch (preftype) {
- case GAIM_PREF_NONE:
- Tcl_SetStringObj(result, "pref type none", -1);
- return TCL_ERROR;
- break;
- case GAIM_PREF_BOOLEAN:
-- Tcl_SetBooleanObj(result, gaim_prefs_get_bool(Tcl_GetString(objv[2])));
-+ Tcl_SetBooleanObj(result, gaim2_prefs_get_bool(Tcl_GetString(objv[2])));
- break;
- case GAIM_PREF_INT:
-- Tcl_SetIntObj(result, gaim_prefs_get_int(Tcl_GetString(objv[2])));
-+ Tcl_SetIntObj(result, gaim2_prefs_get_int(Tcl_GetString(objv[2])));
- break;
- case GAIM_PREF_STRING:
-- Tcl_SetStringObj(result, (char *)gaim_prefs_get_string(Tcl_GetString(objv[2])), -1);
-+ Tcl_SetStringObj(result, (char *)gaim2_prefs_get_string(Tcl_GetString(objv[2])), -1);
- break;
- case GAIM_PREF_STRING_LIST:
-- cur = gaim_prefs_get_string_list(Tcl_GetString(objv[2]));
-+ cur = gaim2_prefs_get_string_list(Tcl_GetString(objv[2]));
- list = Tcl_NewListObj(0, NULL);
- while (cur != NULL) {
- elem = Tcl_NewStringObj((char *)cur->data, -1);
-@@ -722,7 +722,7 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- Tcl_SetObjResult(interp, list);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "tcl does not know about pref type %d\n", preftype);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "tcl does not know about pref type %d\n", preftype);
- Tcl_SetStringObj(result, "unknown pref type", -1);
- return TCL_ERROR;
- }
-@@ -732,7 +732,7 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- Tcl_WrongNumArgs(interp, 1, objv, "path value");
- return TCL_ERROR;
- }
-- preftype = gaim_prefs_get_type(Tcl_GetString(objv[2]));
-+ preftype = gaim2_prefs_get_type(Tcl_GetString(objv[2]));
- switch (preftype) {
- case GAIM_PREF_NONE:
- Tcl_SetStringObj(result, "bad path or pref type none", -1);
-@@ -741,15 +741,15 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- case GAIM_PREF_BOOLEAN:
- if ((error = Tcl_GetBooleanFromObj(interp, objv[3], &intval)) != TCL_OK)
- return error;
-- gaim_prefs_set_bool(Tcl_GetString(objv[2]), intval);
-+ gaim2_prefs_set_bool(Tcl_GetString(objv[2]), intval);
- break;
- case GAIM_PREF_INT:
- if ((error = Tcl_GetIntFromObj(interp, objv[3], &intval)) != TCL_OK)
- return error;
-- gaim_prefs_set_int(Tcl_GetString(objv[2]), intval);
-+ gaim2_prefs_set_int(Tcl_GetString(objv[2]), intval);
- break;
- case GAIM_PREF_STRING:
-- gaim_prefs_set_string(Tcl_GetString(objv[2]), Tcl_GetString(objv[3]));
-+ gaim2_prefs_set_string(Tcl_GetString(objv[2]), Tcl_GetString(objv[3]));
- break;
- case GAIM_PREF_STRING_LIST:
- if ((error = Tcl_ListObjGetElements(interp, objv[3], &nelem, &elems)) != TCL_OK)
-@@ -758,11 +758,11 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- for (i = 0; i < nelem; i++) {
- cur = g_list_append(cur, (gpointer)Tcl_GetString(elems[i]));
- }
-- gaim_prefs_set_string_list(Tcl_GetString(objv[2]), cur);
-+ gaim2_prefs_set_string_list(Tcl_GetString(objv[2]), cur);
- g_list_free(cur);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "tcl does not know about pref type %d\n", preftype);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "tcl does not know about pref type %d\n", preftype);
- return TCL_ERROR;
- }
- break;
-@@ -771,7 +771,7 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- Tcl_WrongNumArgs(interp, 1, objv, "path");
- return TCL_ERROR;
- }
-- preftype = gaim_prefs_get_type(Tcl_GetString(objv[2]));
-+ preftype = gaim2_prefs_get_type(Tcl_GetString(objv[2]));
- switch (preftype) {
- case GAIM_PREF_NONE:
- Tcl_SetStringObj(result, "none", -1);
-@@ -789,7 +789,7 @@ int tcl_cmd_prefs(ClientData unused, Tcl
- Tcl_SetStringObj(result, "stringlist", -1);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "tcl does not know about pref type %d\n", preftype);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "tcl does not know about pref type %d\n", preftype);
- Tcl_SetStringObj(result, "unknown", -1);
- }
- break;
-@@ -800,7 +800,7 @@ int tcl_cmd_prefs(ClientData unused, Tcl
-
- int tcl_cmd_send_im(ClientData unused, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *who, *text;
- int error;
- Tcl_Obj *result;
-@@ -881,14 +881,14 @@ int tcl_cmd_signal(ClientData unused, Tc
-
- static gboolean unload_self(gpointer data)
- {
-- GaimPlugin *plugin = data;
-- gaim_plugin_unload(plugin);
-+ Gaim2Plugin *plugin = data;
-+ gaim2_plugin_unload(plugin);
- return FALSE;
- }
-
- int tcl_cmd_unload(ClientData unused, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- if (objc != 1) {
- Tcl_WrongNumArgs(interp, 1, objv, "");
- return TCL_ERROR;
-diff -prNu ./plugins/tcl/tcl_gaim2.h ./plugins/tcl/tcl_gaim2.h
---- ./plugins/tcl/tcl_gaim2.h 1970-01-01 01:00:00.000000000 +0100
-+++ ./plugins/tcl/tcl_gaim2.h 2006-01-05 15:27:48.000000000 +0100
-@@ -0,0 +1,70 @@
-+/**
-+ * @file tcl_gaim2.h Gaim2 Tcl definitions
-+ *
-+ * gaim2
-+ *
-+ * Copyright (C) 2003 Ethan Blanton <eblanton@cs.purdue.edu>
-+ *
-+ * 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
-+ */
-+
-+#ifndef _GAIM_TCL_GAIM_H_
-+#define _GAIM_TCL_GAIM_H_
-+
-+#include <tcl.h>
-+
-+#include "internal.h"
-+#include "plugin.h"
-+#include "value.h"
-+
-+struct tcl_signal_handler {
-+ Tcl_Obj *signal;
-+ Tcl_Interp *interp;
-+
-+ void *instance;
-+ Tcl_Obj *namespace;
-+ /* These following two are temporary during setup */
-+ Tcl_Obj *args;
-+ Tcl_Obj *proc;
-+
-+ Gaim2Value *returntype;
-+ int nargs;
-+ Gaim2Value **argtypes;
-+};
-+
-+extern Gaim2Plugin *_tcl_plugin;
-+
-+Gaim2Plugin *tcl_interp_get_plugin(Tcl_Interp *interp);
-+
-+void tcl_signal_init(void);
-+void tcl_signal_handler_free(struct tcl_signal_handler *handler);
-+void tcl_signal_cleanup(Tcl_Interp *interp);
-+gboolean tcl_signal_connect(struct tcl_signal_handler *handler);
-+void tcl_signal_disconnect(void *instance, const char *signal, Tcl_Interp *interp);
-+
-+Tcl_ObjCmdProc tcl_cmd_account;
-+Tcl_ObjCmdProc tcl_cmd_signal_connect;
-+Tcl_ObjCmdProc tcl_cmd_buddy;
-+Tcl_ObjCmdProc tcl_cmd_connection;
-+Tcl_ObjCmdProc tcl_cmd_conversation;
-+Tcl_ObjCmdProc tcl_cmd_core;
-+Tcl_ObjCmdProc tcl_cmd_debug;
-+Tcl_ObjCmdProc tcl_cmd_notify;
-+Tcl_ObjCmdProc tcl_cmd_prefs;
-+Tcl_ObjCmdProc tcl_cmd_send_im;
-+Tcl_ObjCmdProc tcl_cmd_signal;
-+Tcl_ObjCmdProc tcl_cmd_unload;
-+
-+#endif /* _GAIM_TCL_GAIM_H_ */
-diff -prNu ./plugins/tcl/tcl_gaim.h ./plugins/tcl/tcl_gaim.h
---- ./plugins/tcl/tcl_gaim.h 2005-12-04 19:19:51.000000000 +0100
-+++ ./plugins/tcl/tcl_gaim.h 1970-01-01 01:00:00.000000000 +0100
-@@ -1,70 +0,0 @@
--/**
-- * @file tcl_gaim.h Gaim Tcl definitions
-- *
-- * gaim
-- *
-- * Copyright (C) 2003 Ethan Blanton <eblanton@cs.purdue.edu>
-- *
-- * 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
-- */
--
--#ifndef _GAIM_TCL_GAIM_H_
--#define _GAIM_TCL_GAIM_H_
--
--#include <tcl.h>
--
--#include "internal.h"
--#include "plugin.h"
--#include "value.h"
--
--struct tcl_signal_handler {
-- Tcl_Obj *signal;
-- Tcl_Interp *interp;
--
-- void *instance;
-- Tcl_Obj *namespace;
-- /* These following two are temporary during setup */
-- Tcl_Obj *args;
-- Tcl_Obj *proc;
--
-- GaimValue *returntype;
-- int nargs;
-- GaimValue **argtypes;
--};
--
--extern GaimPlugin *_tcl_plugin;
--
--GaimPlugin *tcl_interp_get_plugin(Tcl_Interp *interp);
--
--void tcl_signal_init(void);
--void tcl_signal_handler_free(struct tcl_signal_handler *handler);
--void tcl_signal_cleanup(Tcl_Interp *interp);
--gboolean tcl_signal_connect(struct tcl_signal_handler *handler);
--void tcl_signal_disconnect(void *instance, const char *signal, Tcl_Interp *interp);
--
--Tcl_ObjCmdProc tcl_cmd_account;
--Tcl_ObjCmdProc tcl_cmd_signal_connect;
--Tcl_ObjCmdProc tcl_cmd_buddy;
--Tcl_ObjCmdProc tcl_cmd_connection;
--Tcl_ObjCmdProc tcl_cmd_conversation;
--Tcl_ObjCmdProc tcl_cmd_core;
--Tcl_ObjCmdProc tcl_cmd_debug;
--Tcl_ObjCmdProc tcl_cmd_notify;
--Tcl_ObjCmdProc tcl_cmd_prefs;
--Tcl_ObjCmdProc tcl_cmd_send_im;
--Tcl_ObjCmdProc tcl_cmd_signal;
--Tcl_ObjCmdProc tcl_cmd_unload;
--
--#endif /* _GAIM_TCL_GAIM_H_ */
-diff -prNu ./plugins/tcl/tcl_glib.c ./plugins/tcl/tcl_glib.c
---- ./plugins/tcl/tcl_glib.c 2004-07-12 20:00:26.000000000 +0200
-+++ ./plugins/tcl/tcl_glib.c 2006-01-05 15:27:37.000000000 +0100
-@@ -44,7 +44,7 @@
- /*
- * NOTES
- *
-- * This file was developed for the Gaim project. It inserts the Tcl
-+ * This file was developed for the Gaim2 project. It inserts the Tcl
- * event loop into the glib2 event loop for the purposes of providing
- * Tcl bindings in a glib2 (e.g. Gtk2) program. To use it, simply
- * link it into your executable, include tcl_glib.h, and call the
-diff -prNu ./plugins/tcl/tcl_signals.c ./plugins/tcl/tcl_signals.c
---- ./plugins/tcl/tcl_signals.c 2005-12-08 21:55:49.000000000 +0100
-+++ ./plugins/tcl/tcl_signals.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
-- * @file tcl_signals.c Gaim Tcl signal API
-+ * @file tcl_signals.c Gaim2 Tcl signal API
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -22,7 +22,7 @@
- #include <tcl.h>
- #include <stdarg.h>
-
--#include "tcl_gaim.h"
-+#include "tcl_gaim2.h"
-
- #include "internal.h"
- #include "connection.h"
-@@ -71,7 +71,7 @@ gboolean tcl_signal_connect(struct tcl_s
- {
- GString *proc;
-
-- gaim_signal_get_values(handler->instance,
-+ gaim2_signal_get_values(handler->instance,
- Tcl_GetString(handler->signal),
- &handler->returntype, &handler->nargs,
- &handler->argtypes);
-@@ -79,7 +79,7 @@ gboolean tcl_signal_connect(struct tcl_s
- tcl_signal_disconnect(handler->interp, Tcl_GetString(handler->signal),
- handler->interp);
-
-- if (!gaim_signal_connect_vargs(handler->instance,
-+ if (!gaim2_signal_connect_vargs(handler->instance,
- Tcl_GetString(handler->signal),
- (void *)handler->interp,
- GAIM_CALLBACK(tcl_signal_callback),
-@@ -117,7 +117,7 @@ void tcl_signal_disconnect(void *instanc
- handler = cur->data;
- if (handler->interp == interp && handler->instance == instance
- && !strcmp(signal, Tcl_GetString(handler->signal))) {
-- gaim_signal_disconnect(instance, signal, handler->interp,
-+ gaim2_signal_disconnect(instance, signal, handler->interp,
- GAIM_CALLBACK(tcl_signal_callback));
- cmd = g_string_sized_new(64);
- g_string_printf(cmd, "namespace delete %s",
-@@ -137,7 +137,7 @@ void tcl_signal_disconnect(void *instanc
- static void *tcl_signal_callback(va_list args, struct tcl_signal_handler *handler)
- {
- GString *name, *val;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- int error, i;
- void *retval = NULL;
- Tcl_Obj *cmd, *arg, *result;
-@@ -157,20 +157,20 @@ static void *tcl_signal_callback(va_list
- Tcl_ListObjAppendElement(handler->interp, cmd, arg);
-
- for (i = 0; i < handler->nargs; i++) {
-- if (gaim_value_is_outgoing(handler->argtypes[i]))
-+ if (gaim2_value_is_outgoing(handler->argtypes[i]))
- g_string_printf(name, "%s::arg%d",
- Tcl_GetString(handler->namespace), i);
-
-- switch(gaim_value_get_type(handler->argtypes[i])) {
-+ switch(gaim2_value_get_type(handler->argtypes[i])) {
- case GAIM_TYPE_UNKNOWN: /* What? I guess just pass the word ... */
- /* treat this as a pointer, but complain first */
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "unknown GaimValue type %d\n",
-- gaim_value_get_type(handler->argtypes[i]));
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "unknown Gaim2Value type %d\n",
-+ gaim2_value_get_type(handler->argtypes[i]));
- case GAIM_TYPE_POINTER:
- case GAIM_TYPE_OBJECT:
- case GAIM_TYPE_BOXED:
- /* These are all "pointer" types to us */
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- vals[i] = va_arg(args, void **);
- Tcl_LinkVar(handler->interp, name->str,
- vals[i], TCL_LINK_INT);
-@@ -180,7 +180,7 @@ static void *tcl_signal_callback(va_list
- }
- break;
- case GAIM_TYPE_BOOLEAN:
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- vals[i] = va_arg(args, gboolean *);
- Tcl_LinkVar(handler->interp, name->str,
- (char *)&vals[i], TCL_LINK_BOOLEAN);
-@@ -201,7 +201,7 @@ static void *tcl_signal_callback(va_list
- /* I should really cast these individually to
- * preserve as much information as possible ...
- * but heh */
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- vals[i] = va_arg(args, int *);
- Tcl_LinkVar(handler->interp, name->str,
- vals[i], TCL_LINK_INT);
-@@ -213,7 +213,7 @@ static void *tcl_signal_callback(va_list
- case GAIM_TYPE_UINT64:
- /* Tcl < 8.4 doesn't have wide ints, so we have ugly
- * ifdefs in here */
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- vals[i] = (void *)va_arg(args, gint64 *);
- #if (TCL_MAJOR_VERSION >= 8 && TCL_MINOR_VERSION >= 4)
- Tcl_LinkVar(handler->interp, name->str,
-@@ -235,7 +235,7 @@ static void *tcl_signal_callback(va_list
- }
- break;
- case GAIM_TYPE_STRING:
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- strs[i] = va_arg(args, char **);
- if (strs[i] == NULL || *strs[i] == NULL) {
- vals[i] = ckalloc(1);
-@@ -252,16 +252,16 @@ static void *tcl_signal_callback(va_list
- }
- break;
- case GAIM_TYPE_SUBTYPE:
-- switch (gaim_value_get_subtype(handler->argtypes[i])) {
-+ switch (gaim2_value_get_subtype(handler->argtypes[i])) {
- case GAIM_SUBTYPE_UNKNOWN:
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "subtype unknown\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "subtype unknown\n");
- case GAIM_SUBTYPE_ACCOUNT:
- case GAIM_SUBTYPE_CONNECTION:
- case GAIM_SUBTYPE_CONVERSATION:
- case GAIM_SUBTYPE_CONV_WINDOW:
- case GAIM_SUBTYPE_PLUGIN:
- /* pointers again */
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- vals[i] = va_arg(args, void **);
- Tcl_LinkVar(handler->interp, name->str,
- vals[i], TCL_LINK_INT);
-@@ -275,24 +275,24 @@ static void *tcl_signal_callback(va_list
- case GAIM_SUBTYPE_BLIST_GROUP:
- case GAIM_SUBTYPE_BLIST_CHAT:
- /* We're going to switch again for code-deduping */
-- if (gaim_value_is_outgoing(handler->argtypes[i]))
-- node = *va_arg(args, GaimBlistNode **);
-+ if (gaim2_value_is_outgoing(handler->argtypes[i]))
-+ node = *va_arg(args, Gaim2BlistNode **);
- else
-- node = va_arg(args, GaimBlistNode *);
-+ node = va_arg(args, Gaim2BlistNode *);
- switch (node->type) {
- case GAIM_BLIST_GROUP_NODE:
-- g_string_printf(val, "group {%s}", ((GaimGroup *)node)->name);
-+ g_string_printf(val, "group {%s}", ((Gaim2Group *)node)->name);
- break;
- case GAIM_BLIST_CONTACT_NODE:
- /* g_string_printf(val, "contact {%s}", Contact Name? ); */
- break;
- case GAIM_BLIST_BUDDY_NODE:
-- g_string_printf(val, "buddy {%s} %lu", ((GaimBuddy *)node)->name,
-- (unsigned long)((GaimBuddy *)node)->account);
-+ g_string_printf(val, "buddy {%s} %lu", ((Gaim2Buddy *)node)->name,
-+ (unsigned long)((Gaim2Buddy *)node)->account);
- break;
- case GAIM_BLIST_CHAT_NODE:
-- g_string_printf(val, "chat {%s} %lu", ((GaimChat *)node)->alias,
-- (unsigned long)((GaimChat *)node)->account);
-+ g_string_printf(val, "chat {%s} %lu", ((Gaim2Chat *)node)->alias,
-+ (unsigned long)((Gaim2Chat *)node)->account);
- break;
- case GAIM_BLIST_OTHER_NODE:
- g_string_printf(val, "other");
-@@ -307,17 +307,17 @@ static void *tcl_signal_callback(va_list
-
- /* Call the friggin' procedure already */
- if ((error = Tcl_EvalObjEx(handler->interp, cmd, TCL_EVAL_GLOBAL)) != TCL_OK) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "error evaluating callback: %s\n",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "error evaluating callback: %s\n",
- Tcl_GetString(Tcl_GetObjResult(handler->interp)));
- } else {
- result = Tcl_GetObjResult(handler->interp);
- /* handle return values -- strings and words only */
- if (handler->returntype) {
-- if (gaim_value_get_type(handler->returntype) == GAIM_TYPE_STRING) {
-+ if (gaim2_value_get_type(handler->returntype) == GAIM_TYPE_STRING) {
- retval = (void *)g_strdup(Tcl_GetString(result));
- } else {
- if ((error = Tcl_GetIntFromObj(handler->interp, result, (int *)&retval)) != TCL_OK) {
-- gaim_debug(GAIM_DEBUG_ERROR, "tcl", "Error retrieving procedure result: %s\n",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "tcl", "Error retrieving procedure result: %s\n",
- Tcl_GetString(Tcl_GetObjResult(handler->interp)));
- retval = NULL;
- }
-@@ -329,13 +329,13 @@ static void *tcl_signal_callback(va_list
- for (i = 0; i < handler->nargs; i++) {
- g_string_printf(name, "%s::arg%d",
- Tcl_GetString(handler->namespace), i);
-- if (gaim_value_is_outgoing(handler->argtypes[i]))
-+ if (gaim2_value_is_outgoing(handler->argtypes[i]))
- Tcl_UnlinkVar(handler->interp, name->str);
- /* We basically only have to deal with strings on the
- * way out */
-- switch (gaim_value_get_type(handler->argtypes[i])) {
-+ switch (gaim2_value_get_type(handler->argtypes[i])) {
- case GAIM_TYPE_STRING:
-- if (gaim_value_is_outgoing(handler->argtypes[i])) {
-+ if (gaim2_value_is_outgoing(handler->argtypes[i])) {
- if (vals[i] != NULL && *(char **)vals[i] != NULL) {
- g_free(*strs[i]);
- *strs[i] = g_strdup(vals[i]);
-@@ -363,6 +363,6 @@ static Tcl_Obj *new_cb_namespace ()
- static int cbnum;
- char name[32];
-
-- g_snprintf (name, sizeof(name), "::gaim::_callback::cb_%d", cbnum++);
-+ g_snprintf (name, sizeof(name), "::gaim2::_callback::cb_%d", cbnum++);
- return Tcl_NewStringObj (name, -1);
- }
-diff -prNu ./plugins/tcl/tcl_win32.c ./plugins/tcl/tcl_win32.c
---- ./plugins/tcl/tcl_win32.c 2005-12-08 21:58:05.000000000 +0100
-+++ ./plugins/tcl/tcl_win32.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
-- * @file tcl_win32.c Gaim Tcl Windows Init
-+ * @file tcl_win32.c Gaim2 Tcl Windows Init
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Herman Bloggs <hermanator12002@yahoo.com>
- *
-@@ -34,13 +34,13 @@ LPFNTCLCREATEINTERP wtcl_CreateInterp =
- LPFNTKINIT wtk_Init = NULL;
-
- BOOL tcl_win32_init() {
-- if(!(wtcl_CreateInterp=(LPFNTCLCREATEINTERP)wgaim_find_and_loadproc("tcl84.dll", "Tcl_CreateInterp"))) {
-- gaim_debug(GAIM_DEBUG_INFO, "tcl", "tcl_win32_init error loading Tcl_CreateInterp\n");
-+ if(!(wtcl_CreateInterp=(LPFNTCLCREATEINTERP)wgaim2_find_and_loadproc("tcl84.dll", "Tcl_CreateInterp"))) {
-+ gaim2_debug(GAIM_DEBUG_INFO, "tcl", "tcl_win32_init error loading Tcl_CreateInterp\n");
- return FALSE;
- }
-
-- if(!(wtk_Init=(LPFNTKINIT)wgaim_find_and_loadproc("tk84.dll", "Tk_Init"))) {
-- gaim_debug(GAIM_DEBUG_INFO, "tcl", "tcl_win32_init error loading Tk_Init\n");
-+ if(!(wtk_Init=(LPFNTKINIT)wgaim2_find_and_loadproc("tk84.dll", "Tk_Init"))) {
-+ gaim2_debug(GAIM_DEBUG_INFO, "tcl", "tcl_win32_init error loading Tk_Init\n");
- return FALSE;
- }
- return TRUE;
-diff -prNu ./plugins/ticker/Makefile.am ./plugins/ticker/Makefile.am
---- ./plugins/ticker/Makefile.am 2005-04-29 19:04:25.000000000 +0200
-+++ ./plugins/ticker/Makefile.am 2006-01-05 13:17:18.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--plugindir = $(libdir)/gaim
-+plugindir = $(libdir)/gaim2
-
- ticker_la_LDFLAGS = -module -avoid-version $(GTK_LIBS)
-
-diff -prNu ./plugins/ticker/ticker.c ./plugins/ticker/ticker.c
---- ./plugins/ticker/ticker.c 2005-10-31 23:02:30.000000000 +0100
-+++ ./plugins/ticker/ticker.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Gaim Ticker Plugin
-+ * Gaim2 Ticker Plugin
- * The line below doesn't apply at all, does it? It should be Syd, Sean, and
- * maybe Nathan, I believe.
- * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
-@@ -25,7 +25,7 @@
- * pluginized- Sean Egan, Summer 2002
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "blist.h"
- #include "conversation.h"
-@@ -45,7 +45,7 @@ static GtkWidget *tickerwindow = NULL;
- static GtkWidget *ticker;
-
- typedef struct {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- GtkWidget *ebox;
- GtkWidget *label;
- GtkWidget *icon;
-@@ -87,13 +87,13 @@ static void buddy_ticker_create_window()
- }
-
- static gboolean buddy_click_cb(GtkWidget *widget, GdkEventButton *event, gpointer user_data) {
-- GaimBuddy *b = user_data;
-+ Gaim2Buddy *b = user_data;
-
-- gaim_conversation_new(GAIM_CONV_TYPE_IM, b->account, b->name);
-+ gaim2_conversation_new(GAIM_CONV_TYPE_IM, b->account, b->name);
- return TRUE;
- }
-
--static TickerData *buddy_ticker_find_buddy(GaimBuddy *b) {
-+static TickerData *buddy_ticker_find_buddy(Gaim2Buddy *b) {
- GList *tb;
- for(tb = tickerbuds; tb; tb = tb->next) {
- TickerData *td = tb->data;
-@@ -103,7 +103,7 @@ static TickerData *buddy_ticker_find_bud
- return NULL;
- }
-
--static void buddy_ticker_set_pixmap(GaimBuddy *b) {
-+static void buddy_ticker_set_pixmap(Gaim2Buddy *b) {
- TickerData *td = buddy_ticker_find_buddy(b);
- GdkPixbuf *pixbuf;
-
-@@ -113,7 +113,7 @@ static void buddy_ticker_set_pixmap(Gaim
- if(!td->icon)
- td->icon = gtk_image_new();
-
-- pixbuf = gaim_gtk_blist_get_status_icon((GaimBlistNode*)b,
-+ pixbuf = gaim2_gtk_blist_get_status_icon((Gaim2BlistNode*)b,
- GAIM_STATUS_ICON_SMALL);
- gtk_image_set_from_pixbuf(GTK_IMAGE(td->icon), pixbuf);
- g_object_unref(G_OBJECT(pixbuf));
-@@ -122,14 +122,14 @@ static void buddy_ticker_set_pixmap(Gaim
- static gboolean buddy_ticker_set_pixmap_cb(gpointer data) {
- TickerData *td = data;
-
--gaim_debug(GAIM_DEBUG_ERROR, "XXX", "we're updating the pixmap, you bitch\n");
-+gaim2_debug(GAIM_DEBUG_ERROR, "XXX", "we're updating the pixmap, you bitch\n");
- buddy_ticker_set_pixmap(td->buddy);
- td->timeout = 0;
-
- return FALSE;
- }
-
--static void buddy_ticker_add_buddy(GaimBuddy *b) {
-+static void buddy_ticker_add_buddy(Gaim2Buddy *b) {
- GtkWidget *hbox;
- TickerData *td;
-
-@@ -155,7 +155,7 @@ static void buddy_ticker_add_buddy(GaimB
- g_signal_connect(G_OBJECT(td->ebox), "button-press-event",
- G_CALLBACK(buddy_click_cb), b);
-
-- td->label = gtk_label_new(gaim_buddy_get_alias(b));
-+ td->label = gtk_label_new(gaim2_buddy_get_alias(b));
- gtk_box_pack_start(GTK_BOX(hbox), td->label, FALSE, FALSE, 5);
-
- gtk_widget_show_all(td->ebox);
-@@ -168,7 +168,7 @@ static void buddy_ticker_add_buddy(GaimB
- td->timeout = g_timeout_add(11000, buddy_ticker_set_pixmap_cb, td);
- }
-
--static void buddy_ticker_remove_buddy(GaimBuddy *b) {
-+static void buddy_ticker_remove_buddy(Gaim2Buddy *b) {
- TickerData *td = buddy_ticker_find_buddy(b);
-
- if (!td)
-@@ -186,9 +186,9 @@ static void buddy_ticker_remove_buddy(Ga
-
- static void buddy_ticker_show()
- {
-- GaimBuddyList *list = gaim_get_blist();
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *b;
-+ Gaim2BuddyList *list = gaim2_get_blist();
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *b;
-
- if(!list)
- return;
-@@ -202,7 +202,7 @@ static void buddy_ticker_show()
- for(bnode = cnode->child; bnode; bnode = bnode->next) {
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if(GAIM_BUDDY_IS_ONLINE(b))
- buddy_ticker_add_buddy(b);
- }
-@@ -211,7 +211,7 @@ static void buddy_ticker_show()
- }
-
- static void
--buddy_signon_cb(GaimBuddy *b)
-+buddy_signon_cb(Gaim2Buddy *b)
- {
- if(buddy_ticker_find_buddy(b))
- buddy_ticker_set_pixmap(b);
-@@ -220,7 +220,7 @@ buddy_signon_cb(GaimBuddy *b)
- }
-
- static void
--buddy_signoff_cb(GaimBuddy *b)
-+buddy_signoff_cb(Gaim2Buddy *b)
- {
- buddy_ticker_remove_buddy(b);
- if(!tickerbuds)
-@@ -228,7 +228,7 @@ buddy_signoff_cb(GaimBuddy *b)
- }
-
- static void
--status_changed_cb(GaimBuddy *b, GaimStatus *os, GaimStatus *s)
-+status_changed_cb(Gaim2Buddy *b, Gaim2Status *os, Gaim2Status *s)
- {
- if(buddy_ticker_find_buddy(b))
- buddy_ticker_set_pixmap(b);
-@@ -237,10 +237,10 @@ status_changed_cb(GaimBuddy *b, GaimStat
- }
-
- static void
--signoff_cb(GaimConnection *gc)
-+signoff_cb(Gaim2Connection *gc)
- {
- TickerData *td;
-- if (!gaim_connections_get_all()) {
-+ if (!gaim2_connections_get_all()) {
- while (tickerbuds) {
- td = tickerbuds->data;
- tickerbuds = g_list_delete_link(tickerbuds, tickerbuds);
-@@ -269,27 +269,27 @@ signoff_cb(GaimConnection *gc)
- */
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *blist_handle = gaim_blist_get_handle();
-+ void *blist_handle = gaim2_blist_get_handle();
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off",
- plugin, GAIM_CALLBACK(signoff_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-on",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-on",
- plugin, GAIM_CALLBACK(buddy_signon_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-off",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-off",
- plugin, GAIM_CALLBACK(buddy_signoff_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-status-changed",
-+ gaim2_signal_connect(blist_handle, "buddy-status-changed",
- plugin, GAIM_CALLBACK(status_changed_cb), NULL);
-
-- if (gaim_connections_get_all())
-+ if (gaim2_connections_get_all())
- buddy_ticker_show();
-
- return TRUE;
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- TickerData *td;
-
-@@ -309,7 +309,7 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -341,7 +341,7 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
- }
-
-diff -prNu ./plugins/timestamp.c ./plugins/timestamp.c
---- ./plugins/timestamp.c 2005-12-21 22:48:37.000000000 +0100
-+++ ./plugins/timestamp.c 2006-01-05 15:27:37.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Gaim - iChat-like timestamps
-+ * Gaim2 - iChat-like timestamps
- *
- * Copyright (C) 2002-2003, Sean Egan
- * Copyright (C) 2003, Chris J. Friesen <Darth_Sebulba04@yahoo.com>
-@@ -42,18 +42,18 @@ static GSList *timestamp_timeouts = NULL
- static gboolean
- do_timestamp(gpointer data)
- {
-- GaimConversation *c = (GaimConversation *)data;
-- GaimGtkConversation *conv = GAIM_GTK_CONVERSATION(c);
-+ Gaim2Conversation *c = (Gaim2Conversation *)data;
-+ Gaim2GtkConversation *conv = GAIM_GTK_CONVERSATION(c);
- GtkTextIter iter;
- char mdate[7];
- int is_conversation_active;
- time_t tim = time(NULL);
-
-- if (!g_list_find(gaim_get_conversations(), c))
-+ if (!g_list_find(gaim2_get_conversations(), c))
- return FALSE;
-
- /* is_conversation_active is true if an im has been displayed since the last timestamp */
-- is_conversation_active = GPOINTER_TO_INT(gaim_conversation_get_data(c, "timestamp-conv-active"));
-+ is_conversation_active = GPOINTER_TO_INT(gaim2_conversation_get_data(c, "timestamp-conv-active"));
-
- if (is_conversation_active){
- int y, height;
-@@ -62,7 +62,7 @@ do_timestamp(gpointer data)
- GtkWidget *imhtml = conv->imhtml;
- GtkTextBuffer *buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(imhtml));
- gtk_text_buffer_get_end_iter(buffer, &iter);
-- gaim_conversation_set_data(c, "timestamp-conv-active", GINT_TO_POINTER(FALSE));
-+ gaim2_conversation_set_data(c, "timestamp-conv-active", GINT_TO_POINTER(FALSE));
- strftime(mdate, sizeof(mdate), "\n%H:%M", localtime(&tim));
- gtk_text_view_get_visible_rect(GTK_TEXT_VIEW(imhtml), &rect);
- gtk_text_view_get_line_yrange(GTK_TEXT_VIEW(imhtml), &iter, &y, &height);
-@@ -72,42 +72,42 @@ do_timestamp(gpointer data)
- }
- gtk_text_buffer_insert_with_tags_by_name(buffer, &iter, mdate, strlen(mdate), "TIMESTAMP", NULL);
- if (scroll)
-- gtk_imhtml_scroll_to_end(GTK_IMHTML(imhtml), gaim_prefs_get_bool("/gaim/gtk/conversations/use_smooth_scrolling"));
-+ gtk_imhtml_scroll_to_end(GTK_IMHTML(imhtml), gaim2_prefs_get_bool("/gaim2/gtk/conversations/use_smooth_scrolling"));
- }
- else
-- gaim_conversation_set_data(c, "timestamp-enabled", GINT_TO_POINTER(FALSE));
-+ gaim2_conversation_set_data(c, "timestamp-enabled", GINT_TO_POINTER(FALSE));
-
- return TRUE;
- }
-
-
- static gboolean
--timestamp_displaying_conv_msg(GaimAccount *account, GaimConversation *conv,
-- char **buffer, GaimMessageFlags flags, void *data)
-+timestamp_displaying_conv_msg(Gaim2Account *account, Gaim2Conversation *conv,
-+ char **buffer, Gaim2MessageFlags flags, void *data)
- {
- int is_timestamp_enabled;
-
-- if (!g_list_find(gaim_get_conversations(), conv))
-+ if (!g_list_find(gaim2_get_conversations(), conv))
- return FALSE;
-
- /* set to true, since there has been an im since the last timestamp */
-- gaim_conversation_set_data(conv, "timestamp-conv-active", GINT_TO_POINTER(TRUE));
-+ gaim2_conversation_set_data(conv, "timestamp-conv-active", GINT_TO_POINTER(TRUE));
-
-- is_timestamp_enabled = GPOINTER_TO_INT(gaim_conversation_get_data(conv, "timestamp-enabled"));
-+ is_timestamp_enabled = GPOINTER_TO_INT(gaim2_conversation_get_data(conv, "timestamp-enabled"));
-
- if (!is_timestamp_enabled){
-- gaim_conversation_set_data(conv, "timestamp-enabled", GINT_TO_POINTER(TRUE));
-+ gaim2_conversation_set_data(conv, "timestamp-enabled", GINT_TO_POINTER(TRUE));
- do_timestamp((gpointer)conv);
- }
-
- return FALSE;
- }
-
--static void timestamp_new_convo(GaimConversation *conv)
-+static void timestamp_new_convo(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *c = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2GtkConversation *c = GAIM_GTK_CONVERSATION(conv);
-
-- if (!g_list_find(gaim_get_conversations(), conv))
-+ if (!g_list_find(gaim2_get_conversations(), conv))
- return;
-
- gtk_imhtml_show_comments(GTK_IMHTML(c->imhtml), FALSE);
-@@ -117,11 +117,11 @@ static void timestamp_new_convo(GaimConv
- from being reinitialized. This prevents every active conversation from immediately being spammed
- with a new timestamp when the user modifies the timer interval.
- */
-- if (!gaim_conversation_get_data(conv, "timestamp-initialized")){
-+ if (!gaim2_conversation_get_data(conv, "timestamp-initialized")){
- GtkTextBuffer *buffer = gtk_text_view_get_buffer(GTK_TEXT_VIEW(c->imhtml));
-- gaim_conversation_set_data(conv, "timestamp-initialized", GINT_TO_POINTER(TRUE));
-- gaim_conversation_set_data(conv, "timestamp-enabled", GINT_TO_POINTER(TRUE));
-- gaim_conversation_set_data(conv, "timestamp-conv-active", GINT_TO_POINTER(TRUE));
-+ gaim2_conversation_set_data(conv, "timestamp-initialized", GINT_TO_POINTER(TRUE));
-+ gaim2_conversation_set_data(conv, "timestamp-enabled", GINT_TO_POINTER(TRUE));
-+ gaim2_conversation_set_data(conv, "timestamp-conv-active", GINT_TO_POINTER(TRUE));
- gtk_text_buffer_create_tag (buffer, "TIMESTAMP", "foreground", "#888888", "justification", GTK_JUSTIFY_CENTER,
- "weight", PANGO_WEIGHT_BOLD, NULL);
- do_timestamp(conv);
-@@ -147,12 +147,12 @@ static void destroy_timer_list()
- static void init_timer_list()
- {
- GList *cnvs;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- if (timestamp_timeouts != NULL)
- destroy_timer_list();
-
-- for (cnvs = gaim_get_conversations(); cnvs != NULL; cnvs = cnvs->next) {
-+ for (cnvs = gaim2_get_conversations(); cnvs != NULL; cnvs = cnvs->next) {
- c = cnvs->data;
- timestamp_new_convo(c);
- }
-@@ -164,17 +164,17 @@ static void set_timestamp(GtkWidget *spi
- int tm;
-
- tm = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(spinner));
-- gaim_debug(GAIM_DEBUG_MISC, "timestamp", "setting time to %d mins\n", tm);
-+ gaim2_debug(GAIM_DEBUG_MISC, "timestamp", "setting time to %d mins\n", tm);
-
- interval = tm * 60 * 1000;
-- gaim_prefs_set_int("/plugins/gtk/timestamp/interval", interval);
-+ gaim2_prefs_set_int("/plugins/gtk/timestamp/interval", interval);
-
- destroy_timer_list();
- init_timer_list();
- }
-
- static GtkWidget *
--get_config_frame(GaimPlugin *plugin)
-+get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *ret;
- GtkWidget *frame, *label;
-@@ -185,7 +185,7 @@ get_config_frame(GaimPlugin *plugin)
- ret = gtk_vbox_new(FALSE, 18);
- gtk_container_set_border_width (GTK_CONTAINER (ret), 12);
-
-- frame = gaim_gtk_make_frame(ret, _("iChat Timestamp"));
-+ frame = gaim2_gtk_make_frame(ret, _("iChat Timestamp"));
- vbox = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(frame), vbox);
-
-@@ -207,20 +207,20 @@ get_config_frame(GaimPlugin *plugin)
- }
-
- static gboolean
--plugin_load(GaimPlugin *plugin)
-+plugin_load(Gaim2Plugin *plugin)
- {
-- void *conv_handle = gaim_conversations_get_handle();
-+ void *conv_handle = gaim2_conversations_get_handle();
-
- init_timer_list();
-
-- gaim_signal_connect(conv_handle, "conversation-created",
-+ gaim2_signal_connect(conv_handle, "conversation-created",
- plugin, GAIM_CALLBACK(timestamp_new_convo), NULL);
-
- /* record IM display events for each conversation */
-- gaim_signal_connect(conv_handle, "displaying-im-msg",
-+ gaim2_signal_connect(conv_handle, "displaying-im-msg",
- plugin, GAIM_CALLBACK(timestamp_displaying_conv_msg), NULL);
-
-- interval = gaim_prefs_get_int("/plugins/gtk/timestamp/interval");
-+ interval = gaim2_prefs_get_int("/plugins/gtk/timestamp/interval");
-
- return TRUE;
- }
-@@ -228,28 +228,28 @@ plugin_load(GaimPlugin *plugin)
-
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- GList *cnvs;
-
- destroy_timer_list();
-
-- for (cnvs = gaim_get_conversations(); cnvs != NULL; cnvs = cnvs->next) {
-- GaimConversation *c = cnvs->data;
-- GaimGtkConversation *conv = GAIM_GTK_CONVERSATION(c);
-+ for (cnvs = gaim2_get_conversations(); cnvs != NULL; cnvs = cnvs->next) {
-+ Gaim2Conversation *c = cnvs->data;
-+ Gaim2GtkConversation *conv = GAIM_GTK_CONVERSATION(c);
- gtk_imhtml_show_comments(GTK_IMHTML(conv->imhtml), TRUE);
- }
-
- return TRUE;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame,
- 0 /* page_num (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -281,10 +281,10 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk/timestamp");
-- gaim_prefs_add_int("/plugins/gtk/timestamp/interval", interval);
-+ gaim2_prefs_add_none("/plugins/gtk/timestamp");
-+ gaim2_prefs_add_int("/plugins/gtk/timestamp/interval", interval);
- }
-
- GAIM_INIT_PLUGIN(interval, init_plugin, info)
-diff -prNu ./plugins/win32/transparency/win2ktrans.c ./plugins/win32/transparency/win2ktrans.c
---- ./plugins/win32/transparency/win2ktrans.c 2005-10-03 14:04:57.000000000 +0200
-+++ ./plugins/win32/transparency/win2ktrans.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Transparency plugin
-+ * gaim2 - Transparency plugin
- *
- * copyright (c) 1998-2002, rob flynn <rob@marko.net>
- * copyright (c) 2002-2003, Herman Bloggs <hermanator12002@yahoo.com>
-@@ -43,9 +43,9 @@
- */
- #define WINTRANS_PLUGIN_ID "gtk-win-trans"
-
--#define blist (gaim_get_blist() \
-- ? (GAIM_GTK_BLIST(gaim_get_blist()) \
-- ? ((GAIM_GTK_BLIST(gaim_get_blist()))->window) \
-+#define blist (gaim2_get_blist() \
-+ ? (GAIM_GTK_BLIST(gaim2_get_blist()) \
-+ ? ((GAIM_GTK_BLIST(gaim2_get_blist()))->window) \
- : NULL) \
- : NULL)
-
-@@ -76,11 +76,11 @@ static BOOL (*MySetLayeredWindowAttribut
- /*
- * CODE
- */
--static GtkWidget *wgaim_button(const char *text, const char *pref, GtkWidget *page) {
-+static GtkWidget *wgaim2_button(const char *text, const char *pref, GtkWidget *page) {
- GtkWidget *button;
- button = gtk_check_button_new_with_mnemonic(text);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button),
-- gaim_prefs_get_bool(pref));
-+ gaim2_prefs_get_bool(pref));
- gtk_box_pack_start(GTK_BOX(page), button, FALSE, FALSE, 0);
- gtk_widget_show(button);
- return button;
-@@ -119,17 +119,17 @@ static void set_wintrans(GtkWidget *wind
- /* When a conv window is focused, if we're only transparent when unfocused,
- * deal with transparency */
- static gboolean focus_conv_win_cb(GtkWidget *w, GdkEventFocus *e, gpointer d) {
-- if (gaim_prefs_get_bool(OPT_WINTRANS_IM_ENABLED)
-- && gaim_prefs_get_bool(OPT_WINTRANS_IM_ONFOCUS)) {
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_IM_ENABLED)
-+ && gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONFOCUS)) {
- GtkWidget *window = (GtkWidget *) d;
- if (e->in) { /* Focused */
- set_wintrans(window, 0, FALSE,
-- gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
- } else {
- set_wintrans(window,
-- gaim_prefs_get_int(OPT_WINTRANS_IM_ALPHA),
-+ gaim2_prefs_get_int(OPT_WINTRANS_IM_ALPHA),
- TRUE,
-- gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
- }
- }
- return FALSE;
-@@ -138,17 +138,17 @@ static gboolean focus_conv_win_cb(GtkWid
- /* When buddy list window is focused,
- * if we're only transparent when unfocused, deal with transparency */
- static gboolean focus_blist_win_cb(GtkWidget *w, GdkEventFocus *e, gpointer d) {
-- if (gaim_prefs_get_bool(OPT_WINTRANS_BL_ENABLED)
-- && gaim_prefs_get_bool(OPT_WINTRANS_BL_ONFOCUS)) {
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_BL_ENABLED)
-+ && gaim2_prefs_get_bool(OPT_WINTRANS_BL_ONFOCUS)) {
- GtkWidget *window = (GtkWidget *) d;
- if (e->in) { /* Focused */
- set_wintrans(window, 0, FALSE,
-- gaim_prefs_get_bool(OPT_WINTRANS_BL_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_BL_ONTOP));
- } else {
- set_wintrans(window,
-- gaim_prefs_get_int(OPT_WINTRANS_BL_ALPHA),
-+ gaim2_prefs_get_int(OPT_WINTRANS_BL_ALPHA),
- TRUE,
-- gaim_prefs_get_bool(OPT_WINTRANS_BL_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_BL_ONTOP));
- }
- }
- return FALSE;
-@@ -156,13 +156,13 @@ static gboolean focus_blist_win_cb(GtkWi
-
- static void change_alpha(GtkWidget *w, gpointer data) {
- int alpha = gtk_range_get_value(GTK_RANGE(w));
-- gaim_prefs_set_int(OPT_WINTRANS_IM_ALPHA, alpha);
-+ gaim2_prefs_set_int(OPT_WINTRANS_IM_ALPHA, alpha);
-
- /* If we're in no-transparency on focus mode,
- * don't take effect immediately */
-- if (!gaim_prefs_get_bool(OPT_WINTRANS_IM_ONFOCUS))
-+ if (!gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONFOCUS))
- set_wintrans(GTK_WIDGET(data), alpha, TRUE,
-- gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
- }
-
-
-@@ -171,7 +171,7 @@ static GtkWidget *wintrans_slider(GtkWid
- GtkWidget *label, *slider;
- GtkWidget *frame;
-
-- int imalpha = gaim_prefs_get_int(OPT_WINTRANS_IM_ALPHA);
-+ int imalpha = gaim2_prefs_get_int(OPT_WINTRANS_IM_ALPHA);
-
- frame = gtk_frame_new(NULL);
- gtk_frame_set_shadow_type(GTK_FRAME(frame), GTK_SHADOW_NONE);
-@@ -196,7 +196,7 @@ static GtkWidget *wintrans_slider(GtkWid
-
- /* Set the initial transparency level */
- set_wintrans(win, imalpha, TRUE,
-- gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-
- gtk_widget_show_all(hbox);
-
-@@ -215,12 +215,12 @@ static slider_win* find_slidwin(GtkWidge
- }
-
- /* Clean up transparency stuff for the conv window */
--static void cleanup_conv_window(GaimGtkWindow *win) {
-+static void cleanup_conv_window(Gaim2GtkWindow *win) {
- GtkWidget *window = win->window;
- slider_win *slidwin = NULL;
-
- /* Remove window from the window list */
-- gaim_debug_info(WINTRANS_PLUGIN_ID,
-+ gaim2_debug_info(WINTRANS_PLUGIN_ID,
- "Conv window destroyed... removing from list\n");
-
- if ((slidwin = find_slidwin(window))) {
-@@ -233,20 +233,20 @@ static void cleanup_conv_window(GaimGtkW
- G_CALLBACK(focus_conv_win_cb), window);
- }
-
--static void gaim_conversation_delete(GaimConversation *conv) {
-- GaimGtkWindow *win = gaim_gtkconv_get_window(GAIM_GTK_CONVERSATION(conv));
-+static void gaim2_conversation_delete(Gaim2Conversation *conv) {
-+ Gaim2GtkWindow *win = gaim2_gtkconv_get_window(GAIM_GTK_CONVERSATION(conv));
- /* If it is the last conversation in the window, cleanup */
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) == 1)
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) == 1)
- cleanup_conv_window(win);
- }
-
- static void set_blist_trans(GtkWidget *w, const char *pref) {
- gboolean enabled = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(w));
-- gaim_prefs_set_bool(pref, enabled);
-+ gaim2_prefs_set_bool(pref, enabled);
- if (blist) {
-- set_wintrans(blist, gaim_prefs_get_int(OPT_WINTRANS_BL_ALPHA),
-- gaim_prefs_get_bool(OPT_WINTRANS_BL_ENABLED),
-- gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ set_wintrans(blist, gaim2_prefs_get_int(OPT_WINTRANS_BL_ALPHA),
-+ gaim2_prefs_get_bool(OPT_WINTRANS_BL_ENABLED),
-+ gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
- }
- }
-
-@@ -269,7 +269,7 @@ static void add_slider(GtkWidget *win) {
- if (GTK_IS_VBOX(GTK_OBJECT(wl->data)))
- vbox = GTK_WIDGET(wl->data);
- else {
-- gaim_debug_error(WINTRANS_PLUGIN_ID,
-+ gaim2_debug_error(WINTRANS_PLUGIN_ID,
- "no vbox found\n");
- return;
- }
-@@ -327,11 +327,11 @@ static void remove_sliders() {
- static void remove_convs_wintrans(gboolean remove_signal) {
- GList *wins;
-
-- for (wins = gaim_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-- GaimGtkWindow *win = wins->data;
-+ for (wins = gaim2_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-+ Gaim2GtkWindow *win = wins->data;
- GtkWidget *window = win->window;
-
-- if (gaim_prefs_get_bool(OPT_WINTRANS_IM_ENABLED))
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_IM_ENABLED))
- set_wintrans(window, 0, FALSE, FALSE);
-
- /* Remove the focus cbs */
-@@ -343,15 +343,15 @@ static void remove_convs_wintrans(gboole
- remove_sliders();
- }
-
--static void set_conv_window_trans(GaimGtkWindow *oldwin, GaimGtkWindow *newwin) {
-+static void set_conv_window_trans(Gaim2GtkWindow *oldwin, Gaim2GtkWindow *newwin) {
- GtkWidget *win = newwin->window;
-
- /* check prefs to see if we want trans */
-- if (gaim_prefs_get_bool(OPT_WINTRANS_IM_ENABLED)) {
-- set_wintrans(win, gaim_prefs_get_int(OPT_WINTRANS_IM_ALPHA),
-- TRUE, gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_IM_ENABLED)) {
-+ set_wintrans(win, gaim2_prefs_get_int(OPT_WINTRANS_IM_ALPHA),
-+ TRUE, gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-
-- if (gaim_prefs_get_bool(OPT_WINTRANS_IM_SLIDER)) {
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_IM_SLIDER)) {
- add_slider(win);
- }
- }
-@@ -359,7 +359,7 @@ static void set_conv_window_trans(GaimGt
- /* If we're moving from one window to another,
- * add the focus listeners to the new window if not already there */
- if (oldwin != NULL && oldwin != newwin) {
-- if (gaim_gtk_conv_window_get_gtkconv_count(newwin) == 0) {
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(newwin) == 0) {
- g_signal_connect(G_OBJECT(win), "focus_in_event",
- G_CALLBACK(focus_conv_win_cb), win);
- g_signal_connect(G_OBJECT(win), "focus_out_event",
-@@ -367,36 +367,36 @@ static void set_conv_window_trans(GaimGt
- }
-
- /* If we've moved the last conversation, cleanup the window */
-- if (gaim_gtk_conv_window_get_gtkconv_count(oldwin) == 1)
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(oldwin) == 1)
- cleanup_conv_window(oldwin);
- }
- }
-
- static void update_convs_wintrans(GtkWidget *toggle_btn, const char *pref) {
-- gaim_prefs_set_bool(pref, gtk_toggle_button_get_active(
-+ gaim2_prefs_set_bool(pref, gtk_toggle_button_get_active(
- GTK_TOGGLE_BUTTON(toggle_btn)));
-
-- if (gaim_prefs_get_bool(OPT_WINTRANS_IM_ENABLED)) {
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_IM_ENABLED)) {
- GList *wins;
-
-- for (wins = gaim_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-- GaimGtkWindow *win = wins->data;
-+ for (wins = gaim2_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-+ Gaim2GtkWindow *win = wins->data;
- set_conv_window_trans(NULL, win);
- }
-
-- if (!gaim_prefs_get_bool(OPT_WINTRANS_IM_SLIDER))
-+ if (!gaim2_prefs_get_bool(OPT_WINTRANS_IM_SLIDER))
- remove_sliders();
- }
- else
- remove_convs_wintrans(FALSE);
- }
-
--static void gaim_new_conversation(GaimConversation *conv) {
-- GaimGtkWindow *win = gaim_gtkconv_get_window(GAIM_GTK_CONVERSATION(conv));
-+static void gaim2_new_conversation(Gaim2Conversation *conv) {
-+ Gaim2GtkWindow *win = gaim2_gtkconv_get_window(GAIM_GTK_CONVERSATION(conv));
-
- /* If it is the first conversation in the window,
- * add the sliders, and set transparency */
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) == 1) {
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) == 1) {
- GtkWidget *window = win->window;
-
- set_conv_window_trans(NULL, win);
-@@ -408,13 +408,13 @@ static void gaim_new_conversation(GaimCo
- }
- }
-
--static void blist_created_cb(GaimBuddyList *gaim_blist, gpointer data) {
-+static void blist_created_cb(Gaim2BuddyList *gaim2_blist, gpointer data) {
- if (blist) {
-- if (gaim_prefs_get_bool(OPT_WINTRANS_BL_ENABLED)) {
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_BL_ENABLED)) {
- set_wintrans(blist,
-- gaim_prefs_get_int(OPT_WINTRANS_BL_ALPHA),
-+ gaim2_prefs_get_int(OPT_WINTRANS_BL_ALPHA),
- TRUE,
-- gaim_prefs_get_bool(OPT_WINTRANS_BL_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_BL_ONTOP));
- }
-
- g_signal_connect(G_OBJECT(blist), "focus_in_event",
-@@ -428,17 +428,17 @@ static void alpha_change(GtkWidget *w, g
- GList *wins;
- int imalpha = gtk_range_get_value(GTK_RANGE(w));
-
-- for (wins = gaim_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-- GaimGtkWindow *win = wins->data;
-+ for (wins = gaim2_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-+ Gaim2GtkWindow *win = wins->data;
- set_wintrans(win->window, imalpha, TRUE,
-- gaim_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
-+ gaim2_prefs_get_bool(OPT_WINTRANS_IM_ONTOP));
- }
- }
-
- static void alpha_pref_set_int (GtkWidget *w, GdkEventFocus *e, const char *pref)
- {
- int alpha = gtk_range_get_value(GTK_RANGE(w));
-- gaim_prefs_set_int(pref, alpha);
-+ gaim2_prefs_set_int(pref, alpha);
- }
-
- static void bl_alpha_change(GtkWidget *w, gpointer data) {
-@@ -449,8 +449,8 @@ static void bl_alpha_change(GtkWidget *w
- static void update_existing_convs() {
- GList *wins;
-
-- for (wins = gaim_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-- GaimGtkWindow *win = wins->data;
-+ for (wins = gaim2_gtk_conv_windows_get_list(); wins; wins = wins->next) {
-+ Gaim2GtkWindow *win = wins->data;
- GtkWidget *window = win->window;
-
- set_conv_window_trans(NULL, win);
-@@ -465,26 +465,26 @@ static void update_existing_convs() {
- /*
- * EXPORTED FUNCTIONS
- */
--static gboolean plugin_load(GaimPlugin *plugin) {
-- MySetLayeredWindowAttributes = (void*) wgaim_find_and_loadproc(
-+static gboolean plugin_load(Gaim2Plugin *plugin) {
-+ MySetLayeredWindowAttributes = (void*) wgaim2_find_and_loadproc(
- "user32.dll", "SetLayeredWindowAttributes");
-
- if (!MySetLayeredWindowAttributes) {
-- gaim_debug_error(WINTRANS_PLUGIN_ID,
-+ gaim2_debug_error(WINTRANS_PLUGIN_ID,
- "SetLayeredWindowAttributes API not found (Required W2K+)\n");
- return FALSE;
- }
-
-- gaim_signal_connect(gaim_conversations_get_handle(),
-+ gaim2_signal_connect(gaim2_conversations_get_handle(),
- "conversation-created", plugin,
-- GAIM_CALLBACK(gaim_new_conversation), NULL);
-+ GAIM_CALLBACK(gaim2_new_conversation), NULL);
-
- /* Set callback to remove window from the list, if the window is destroyed */
-- gaim_signal_connect(gaim_conversations_get_handle(),
-+ gaim2_signal_connect(gaim2_conversations_get_handle(),
- "deleting-conversation", plugin,
-- GAIM_CALLBACK(gaim_conversation_delete), NULL);
-+ GAIM_CALLBACK(gaim2_conversation_delete), NULL);
-
-- gaim_signal_connect(gaim_gtk_conversations_get_handle(),
-+ gaim2_signal_connect(gaim2_gtk_conversations_get_handle(),
- "conversation-dragging", plugin,
- GAIM_CALLBACK(set_conv_window_trans), NULL);
-
-@@ -493,7 +493,7 @@ static gboolean plugin_load(GaimPlugin *
- if (blist)
- blist_created_cb(NULL, NULL);
- else
-- gaim_signal_connect(gaim_gtk_blist_get_handle(),
-+ gaim2_signal_connect(gaim2_gtk_blist_get_handle(),
- "gtkblist-created", plugin,
- GAIM_CALLBACK(blist_created_cb), NULL);
-
-@@ -501,13 +501,13 @@ static gboolean plugin_load(GaimPlugin *
- return TRUE;
- }
-
--static gboolean plugin_unload(GaimPlugin *plugin) {
-- gaim_debug_info(WINTRANS_PLUGIN_ID, "Unloading win2ktrans plugin\n");
-+static gboolean plugin_unload(Gaim2Plugin *plugin) {
-+ gaim2_debug_info(WINTRANS_PLUGIN_ID, "Unloading win2ktrans plugin\n");
-
- remove_convs_wintrans(TRUE);
-
- if (blist) {
-- if (gaim_prefs_get_bool(OPT_WINTRANS_BL_ENABLED))
-+ if (gaim2_prefs_get_bool(OPT_WINTRANS_BL_ENABLED))
- set_wintrans(blist, 0, FALSE, FALSE);
-
- /* Remove the focus cbs */
-@@ -518,7 +518,7 @@ static gboolean plugin_unload(GaimPlugin
- return TRUE;
- }
-
--static GtkWidget *get_config_frame(GaimPlugin *plugin) {
-+static GtkWidget *get_config_frame(Gaim2Plugin *plugin) {
- GtkWidget *ret;
- GtkWidget *imtransbox, *bltransbox;
- GtkWidget *hbox;
-@@ -530,32 +530,32 @@ static GtkWidget *get_config_frame(GaimP
- gtk_container_set_border_width(GTK_CONTAINER (ret), 12);
-
- /* IM Convo trans options */
-- imtransbox = gaim_gtk_make_frame(ret, _("IM Conversation Windows"));
-- button = wgaim_button(_("_IM window transparency"),
-+ imtransbox = gaim2_gtk_make_frame(ret, _("IM Conversation Windows"));
-+ button = wgaim2_button(_("_IM window transparency"),
- OPT_WINTRANS_IM_ENABLED, imtransbox);
- g_signal_connect(GTK_OBJECT(button), "clicked",
- GTK_SIGNAL_FUNC(update_convs_wintrans),
- (gpointer) OPT_WINTRANS_IM_ENABLED);
-
- trans_box = gtk_vbox_new(FALSE, 18);
-- if (!gaim_prefs_get_bool(OPT_WINTRANS_IM_ENABLED))
-+ if (!gaim2_prefs_get_bool(OPT_WINTRANS_IM_ENABLED))
- gtk_widget_set_sensitive(GTK_WIDGET(trans_box), FALSE);
- gtk_widget_show(trans_box);
-
- g_signal_connect(GTK_OBJECT(button), "clicked",
-- GTK_SIGNAL_FUNC(gaim_gtk_toggle_sensitive), trans_box);
-+ GTK_SIGNAL_FUNC(gaim2_gtk_toggle_sensitive), trans_box);
-
-- button = wgaim_button(_("_Show slider bar in IM window"),
-+ button = wgaim2_button(_("_Show slider bar in IM window"),
- OPT_WINTRANS_IM_SLIDER, trans_box);
- g_signal_connect(GTK_OBJECT(button), "clicked",
- GTK_SIGNAL_FUNC(update_convs_wintrans),
- (gpointer) OPT_WINTRANS_IM_SLIDER);
-
-- button = gaim_gtk_prefs_checkbox(
-+ button = gaim2_gtk_prefs_checkbox(
- _("Remove IM window transparency on focus"),
- OPT_WINTRANS_IM_ONFOCUS, trans_box);
-
-- button = wgaim_button(_("Always on top"), OPT_WINTRANS_IM_ONTOP,
-+ button = wgaim2_button(_("Always on top"), OPT_WINTRANS_IM_ONTOP,
- trans_box);
- g_signal_connect(GTK_OBJECT(button), "clicked",
- GTK_SIGNAL_FUNC(update_convs_wintrans),
-@@ -571,7 +571,7 @@ static GtkWidget *get_config_frame(GaimP
-
- slider = gtk_hscale_new_with_range(50, 255, 1);
- gtk_range_set_value(GTK_RANGE(slider),
-- gaim_prefs_get_int(OPT_WINTRANS_IM_ALPHA));
-+ gaim2_prefs_get_int(OPT_WINTRANS_IM_ALPHA));
- gtk_widget_set_usize(GTK_WIDGET(slider), 200, -1);
-
- g_signal_connect(GTK_OBJECT(slider), "value-changed",
-@@ -587,23 +587,23 @@ static GtkWidget *get_config_frame(GaimP
- gtk_box_pack_start(GTK_BOX(trans_box), hbox, FALSE, FALSE, 5);
-
- /* Buddy List trans options */
-- bltransbox = gaim_gtk_make_frame (ret, _("Buddy List Window"));
-- button = wgaim_button(_("_Buddy List window transparency"),
-+ bltransbox = gaim2_gtk_make_frame (ret, _("Buddy List Window"));
-+ button = wgaim2_button(_("_Buddy List window transparency"),
- OPT_WINTRANS_BL_ENABLED, bltransbox);
- g_signal_connect(GTK_OBJECT(button), "clicked",
- GTK_SIGNAL_FUNC(set_blist_trans),
- (gpointer) OPT_WINTRANS_BL_ENABLED);
-
- trans_box = gtk_vbox_new(FALSE, 18);
-- if (!gaim_prefs_get_bool(OPT_WINTRANS_BL_ENABLED))
-+ if (!gaim2_prefs_get_bool(OPT_WINTRANS_BL_ENABLED))
- gtk_widget_set_sensitive(GTK_WIDGET(trans_box), FALSE);
- gtk_widget_show(trans_box);
- g_signal_connect(GTK_OBJECT(button), "clicked",
-- GTK_SIGNAL_FUNC(gaim_gtk_toggle_sensitive), trans_box);
-- button = gaim_gtk_prefs_checkbox(
-+ GTK_SIGNAL_FUNC(gaim2_gtk_toggle_sensitive), trans_box);
-+ button = gaim2_gtk_prefs_checkbox(
- _("Remove Buddy List window transparency on focus"),
- OPT_WINTRANS_BL_ONFOCUS, trans_box);
-- button = wgaim_button(_("Always on top"), OPT_WINTRANS_BL_ONTOP,
-+ button = wgaim2_button(_("Always on top"), OPT_WINTRANS_BL_ONTOP,
- trans_box);
- g_signal_connect(GTK_OBJECT(button), "clicked",
- GTK_SIGNAL_FUNC(set_blist_trans),
-@@ -618,7 +618,7 @@ static GtkWidget *get_config_frame(GaimP
-
- slider = gtk_hscale_new_with_range(50, 255, 1);
- gtk_range_set_value(GTK_RANGE(slider),
-- gaim_prefs_get_int(OPT_WINTRANS_BL_ALPHA));
-+ gaim2_prefs_get_int(OPT_WINTRANS_BL_ALPHA));
-
- gtk_widget_set_usize(GTK_WIDGET(slider), 200, -1);
-
-@@ -638,12 +638,12 @@ static GtkWidget *get_config_frame(GaimP
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -673,19 +673,19 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk/win32");
-- gaim_prefs_add_none("/plugins/gtk/win32/wintrans");
-- gaim_prefs_add_bool(OPT_WINTRANS_IM_ENABLED, FALSE);
-- gaim_prefs_add_int(OPT_WINTRANS_IM_ALPHA, 255);
-- gaim_prefs_add_bool(OPT_WINTRANS_IM_SLIDER, FALSE);
-- gaim_prefs_add_bool(OPT_WINTRANS_IM_ONFOCUS, FALSE);
-- gaim_prefs_add_bool(OPT_WINTRANS_IM_ONTOP, FALSE);
-- gaim_prefs_add_bool(OPT_WINTRANS_BL_ENABLED, FALSE);
-- gaim_prefs_add_int(OPT_WINTRANS_BL_ALPHA, 255);
-- gaim_prefs_add_bool(OPT_WINTRANS_BL_ONFOCUS, FALSE);
-- gaim_prefs_add_bool(OPT_WINTRANS_BL_ONTOP, FALSE);
-+ gaim2_prefs_add_none("/plugins/gtk/win32");
-+ gaim2_prefs_add_none("/plugins/gtk/win32/wintrans");
-+ gaim2_prefs_add_bool(OPT_WINTRANS_IM_ENABLED, FALSE);
-+ gaim2_prefs_add_int(OPT_WINTRANS_IM_ALPHA, 255);
-+ gaim2_prefs_add_bool(OPT_WINTRANS_IM_SLIDER, FALSE);
-+ gaim2_prefs_add_bool(OPT_WINTRANS_IM_ONFOCUS, FALSE);
-+ gaim2_prefs_add_bool(OPT_WINTRANS_IM_ONTOP, FALSE);
-+ gaim2_prefs_add_bool(OPT_WINTRANS_BL_ENABLED, FALSE);
-+ gaim2_prefs_add_int(OPT_WINTRANS_BL_ALPHA, 255);
-+ gaim2_prefs_add_bool(OPT_WINTRANS_BL_ONFOCUS, FALSE);
-+ gaim2_prefs_add_bool(OPT_WINTRANS_BL_ONTOP, FALSE);
- }
-
- GAIM_INIT_PLUGIN(wintrans, init_plugin, info)
-diff -prNu ./plugins/win32/winprefs/gtkappbar.c ./plugins/win32/winprefs/gtkappbar.c
---- ./plugins/win32/winprefs/gtkappbar.c 2005-08-19 18:30:52.000000000 +0200
-+++ ./plugins/win32/winprefs/gtkappbar.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - WinGaim Options Plugin
-+ * gaim2 - WinGaim2 Options Plugin
- *
- * File: gtkappbar.c
- * Date: August 2, 2003
-@@ -37,19 +37,19 @@
-
- #define APPBAR_CALLBACK WM_USER + 1010
-
--typedef HMONITOR WINAPI gaim_MonitorFromPoint(POINT, DWORD);
--typedef HMONITOR WINAPI gaim_MonitorFromWindow(HWND, DWORD);
--typedef BOOL WINAPI gaim_GetMonitorInfo(HMONITOR, LPMONITORINFO);
-+typedef HMONITOR WINAPI gaim2_MonitorFromPoint(POINT, DWORD);
-+typedef HMONITOR WINAPI gaim2_MonitorFromWindow(HWND, DWORD);
-+typedef BOOL WINAPI gaim2_GetMonitorInfo(HMONITOR, LPMONITORINFO);
-
- /* Retrieve the rectangular display area from the specified monitor
- * Return TRUE if successful, otherwise FALSE
- */
- static gboolean
- get_rect_from_monitor(HMODULE hmod, HMONITOR monitor, RECT *rect) {
-- gaim_GetMonitorInfo *the_GetMonitorInfo;
-+ gaim2_GetMonitorInfo *the_GetMonitorInfo;
- MONITORINFO info;
-
-- if (!(the_GetMonitorInfo = (gaim_GetMonitorInfo*)
-+ if (!(the_GetMonitorInfo = (gaim2_GetMonitorInfo*)
- GetProcAddress(hmod, "GetMonitorInfoA"))) {
- return FALSE;
- }
-@@ -71,14 +71,14 @@ get_rect_from_monitor(HMODULE hmod, HMON
- static gboolean
- get_rect_at_point_multimonitor(POINT pt, RECT *rect) {
- HMODULE hmod;
-- gaim_MonitorFromPoint *the_MonitorFromPoint;
-+ gaim2_MonitorFromPoint *the_MonitorFromPoint;
- HMONITOR monitor;
-
- if (!(hmod = GetModuleHandle("user32"))) {
- return FALSE;
- }
-
-- if (!(the_MonitorFromPoint = (gaim_MonitorFromPoint*)
-+ if (!(the_MonitorFromPoint = (gaim2_MonitorFromPoint*)
- GetProcAddress(hmod, "MonitorFromPoint"))) {
- return FALSE;
- }
-@@ -96,14 +96,14 @@ get_rect_at_point_multimonitor(POINT pt,
- static gboolean
- get_rect_of_window_multimonitor(HWND window, RECT *rect) {
- HMODULE hmod;
-- gaim_MonitorFromWindow *the_MonitorFromWindow;
-+ gaim2_MonitorFromWindow *the_MonitorFromWindow;
- HMONITOR monitor;
-
- if (!(hmod = GetModuleHandle("user32"))) {
- return FALSE;
- }
-
-- if (!(the_MonitorFromWindow = (gaim_MonitorFromWindow*)
-+ if (!(the_MonitorFromWindow = (gaim2_MonitorFromWindow*)
- GetProcAddress(hmod, "MonitorFromWindow"))) {
- return FALSE;
- }
-@@ -152,7 +152,7 @@ static void get_window_normal_rc(HWND hw
- }
- #if 0
- static void print_rect(RECT *rc) {
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "RECT: L:%ld R:%ld T:%ld B:%ld\n",
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "RECT: L:%ld R:%ld T:%ld B:%ld\n",
- rc->left, rc->right, rc->top, rc->bottom);
- }
- #endif
-@@ -285,7 +285,7 @@ static GdkFilterReturn wnd_moving(GtkApp
- int side = -1;
- long dockAreaWidth = 0;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_moving\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_moving\n");
-
- GetCursorPos(&cp);
- monRect = get_rect_at_point(cp);
-@@ -330,7 +330,7 @@ static GdkFilterReturn wnd_moving(GtkApp
- static GdkFilterReturn wnd_sizing(GtkAppBar *ab, GdkXEvent *xevent) {
- MSG *msg = (MSG*)xevent;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_sizing\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_sizing\n");
- if(ab->docked) {
- RECT *rc = (RECT*)msg->lParam;
- if(ab->side == ABE_LEFT && msg->wParam == WMSZ_RIGHT) {
-@@ -350,7 +350,7 @@ static GdkFilterReturn wnd_activate(GtkA
- if (ab->registered) {
- APPBARDATA abd;
- MSG *msg = (MSG*)xevent;
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_activate\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_activate\n");
-
- abd.hWnd = msg->hwnd;
- abd.cbSize = sizeof(APPBARDATA);
-@@ -364,7 +364,7 @@ static GdkFilterReturn wnd_poschanged(Gt
- if (ab->registered) {
- APPBARDATA abd;
- MSG *msg = (MSG*)xevent;
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_poschanged\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_poschanged\n");
-
- abd.hWnd = msg->hwnd;
- abd.cbSize = sizeof(APPBARDATA);
-@@ -378,7 +378,7 @@ static GdkFilterReturn wnd_poschanging(G
- MSG *msg = (MSG*)xevent;
- WINDOWPOS *wpos = (WINDOWPOS*)msg->lParam;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_poschanging\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_poschanging\n");
-
- if(ab->docked || ab->docking) {
- wpos->x = ab->docked_rect.left;
-@@ -395,7 +395,7 @@ static GdkFilterReturn wnd_poschanging(G
- static GdkFilterReturn wnd_exitsizemove(GtkAppBar *ab, GdkXEvent *xevent) {
- MSG *msg = (MSG*)xevent;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_exitsizemove\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_exitsizemove\n");
- if(ab->docking) {
- gtk_appbar_setpos(ab, msg->hwnd);
- ab->docking = FALSE;
-@@ -413,15 +413,15 @@ static GdkFilterReturn wnd_exitsizemove(
- static GdkFilterReturn wnd_showwindow(GtkAppBar *ab, GdkXEvent *xevent) {
- MSG *msg = (MSG*)xevent;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_showwindow\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_showwindow\n");
- if(msg->wParam && ab->docked) {
- ab->iconized = FALSE;
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "shown\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "shown\n");
- ab->docked = FALSE;
- gtk_appbar_dock(ab, ab->side);
- }
- else if(!msg->wParam && ab->docked) {
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "hidden\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "hidden\n");
- gtk_appbar_unregister(ab, GDK_WINDOW_HWND(ab->win->window));
- set_toolbar(GDK_WINDOW_HWND(ab->win->window), FALSE);
- ab->docked = TRUE;
-@@ -433,17 +433,17 @@ static GdkFilterReturn wnd_showwindow(Gt
- static GdkFilterReturn wnd_size(GtkAppBar *ab, GdkXEvent *xevent) {
- MSG *msg = (MSG*)xevent;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_size\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_size\n");
-
- if(msg->wParam == SIZE_MINIMIZED) {
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "Minimize\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "Minimize\n");
- if(ab->docked) {
- gtk_appbar_unregister(ab, GDK_WINDOW_HWND(ab->win->window));
- ab->docked = TRUE;
- }
- }
- else if(msg->wParam == SIZE_RESTORED) {
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "Restore\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "Restore\n");
- if (!ab->iconized && ab->docked) {
- gtk_appbar_dock(ab, ab->side);
- }
-@@ -484,11 +484,11 @@ static GdkFilterReturn wnd_initmenupopup
-
- if(ab->docked && HIWORD(msg->lParam)) {
- HMENU sysmenu = GetSystemMenu(msg->hwnd, FALSE);
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_initpopupmenu: docked: %d ismenu: %d\n", ab->docked, IsMenu(sysmenu));
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "wnd_initpopupmenu: docked: %d ismenu: %d\n", ab->docked, IsMenu(sysmenu));
- if(EnableMenuItem(sysmenu, SC_MAXIMIZE, MF_BYCOMMAND|MF_GRAYED)<0)
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "SC_MAXIMIZE Menu item does not exist\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "SC_MAXIMIZE Menu item does not exist\n");
- if(EnableMenuItem(sysmenu, SC_MOVE, MF_BYCOMMAND|MF_GRAYED)<0)
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "SC_MOVE Menu item does not exist\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "SC_MOVE Menu item does not exist\n");
- return GDK_FILTER_CONTINUE;
- }
- else
-@@ -503,11 +503,11 @@ static GdkFilterReturn gtk_appbar_callba
-
- switch (msg->wParam) {
- case ABN_STATECHANGE:
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: ABN_STATECHANGE\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: ABN_STATECHANGE\n");
- break;
-
- case ABN_FULLSCREENAPP:
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: ABN_FULLSCREENAPP: %d\n", (BOOL)msg->lParam);
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: ABN_FULLSCREENAPP: %d\n", (BOOL)msg->lParam);
- if (!ab->iconized && ab->docked) {
- if ((BOOL)msg->lParam) {
- SetWindowPos(msg->hwnd, HWND_BOTTOM, 0, 0, 0, 0,
-@@ -521,7 +521,7 @@ static GdkFilterReturn gtk_appbar_callba
- break;
-
- case ABN_POSCHANGED:
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: ABN_POSCHANGED\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: ABN_POSCHANGED\n");
- CopyRect(&orig, &(ab->docked_rect));
- gtk_appbar_querypos(ab, msg->hwnd, get_rect_of_window(msg->hwnd));
- if (EqualRect(&orig, &(ab->docked_rect)) == 0) {
-@@ -533,7 +533,7 @@ static GdkFilterReturn gtk_appbar_callba
- break;
- #if 0
- default:
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: %d\n", msg->wParam);
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_callback: %d\n", msg->wParam);
- #endif
- }
- return GDK_FILTER_CONTINUE;
-@@ -570,7 +570,7 @@ static GdkFilterReturn gtk_appbar_event_
- return gtk_appbar_callback(data, xevent);
- #if 0
- default:
-- gaim_debug_info("gtkappbar", "gtk_appbar_event_filter %d\n", msg->message);
-+ gaim2_debug_info("gtkappbar", "gtk_appbar_event_filter %d\n", msg->message);
- #endif
- }
- return GDK_FILTER_CONTINUE;
-@@ -579,7 +579,7 @@ static GdkFilterReturn gtk_appbar_event_
- void gtk_appbar_dock(GtkAppBar *ab, UINT side) {
- RECT orig;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_dock\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_dock\n");
-
- if(!ab || !IsWindow(GDK_WINDOW_HWND(ab->win->window)))
- return;
-@@ -609,7 +609,7 @@ void gtk_appbar_add_dock_cb(GtkAppBar *a
- GtkAppBar *gtk_appbar_add(GtkWidget *win) {
- GtkAppBar *ab;
-
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_add\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_add\n");
-
- if(!win)
- return NULL;
-@@ -627,7 +627,7 @@ GtkAppBar *gtk_appbar_add(GtkWidget *win
- }
-
- void gtk_appbar_remove(GtkAppBar *ab) {
-- gaim_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_remove\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "gtkappbar", "gtk_appbar_remove\n");
-
- if(!ab)
- return;
-diff -prNu ./plugins/win32/winprefs/gtkappbar.h ./plugins/win32/winprefs/gtkappbar.h
---- ./plugins/win32/winprefs/gtkappbar.h 2005-01-28 06:01:24.000000000 +0100
-+++ ./plugins/win32/winprefs/gtkappbar.h 2006-01-05 15:27:48.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - WinGaim Options Plugin
-+ * gaim2 - WinGaim2 Options Plugin
- *
- * File: gtkappbar.h
- * Date: August 2, 2003
-diff -prNu ./plugins/win32/winprefs/winprefs.c ./plugins/win32/winprefs/winprefs.c
---- ./plugins/win32/winprefs/winprefs.c 2005-12-17 21:46:57.000000000 +0100
-+++ ./plugins/win32/winprefs/winprefs.c 2006-01-05 15:27:38.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim - WinGaim Options Plugin
-+ * gaim2 - WinGaim2 Options Plugin
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -55,7 +55,7 @@ static const char *PREF_IM_BLINK =
- /* Deprecated */
- static const char *PREF_DBLIST_ON_TOP = "/plugins/gtk/win32/winprefs/dblist_on_top";
-
--static GaimPlugin *handle = NULL;
-+static Gaim2Plugin *handle = NULL;
- static GtkAppBar *blist_ab = NULL;
- static GtkWidget *blist = NULL;
-
-@@ -86,12 +86,12 @@ static LPFNFLASHWINDOWEX MyFlashWindowEx
-
- static void blist_save_state() {
- if(blist_ab) {
-- if(gaim_prefs_get_bool(PREF_DBLIST_DOCKABLE) && blist_ab->docked) {
-- gaim_prefs_set_int(PREF_DBLIST_HEIGHT, blist_ab->undocked_height);
-- gaim_prefs_set_int(PREF_DBLIST_SIDE, blist_ab->side);
-- gaim_prefs_set_bool(PREF_DBLIST_DOCKED, blist_ab->docked);
-+ if(gaim2_prefs_get_bool(PREF_DBLIST_DOCKABLE) && blist_ab->docked) {
-+ gaim2_prefs_set_int(PREF_DBLIST_HEIGHT, blist_ab->undocked_height);
-+ gaim2_prefs_set_int(PREF_DBLIST_SIDE, blist_ab->side);
-+ gaim2_prefs_set_bool(PREF_DBLIST_DOCKED, blist_ab->docked);
- } else
-- gaim_prefs_set_bool(PREF_DBLIST_DOCKED, FALSE);
-+ gaim2_prefs_set_bool(PREF_DBLIST_DOCKED, FALSE);
- }
- }
-
-@@ -108,12 +108,12 @@ static void blist_set_ontop(gboolean val
-
- static void blist_dock_cb(gboolean val) {
- if (val == TRUE) {
-- gaim_debug_info(WINPREFS_PLUGIN_ID, "Blist Docking..\n");
-- if (gaim_prefs_get_int(PREF_BLIST_ON_TOP) != BLIST_TOP_NEVER)
-+ gaim2_debug_info(WINPREFS_PLUGIN_ID, "Blist Docking..\n");
-+ if (gaim2_prefs_get_int(PREF_BLIST_ON_TOP) != BLIST_TOP_NEVER)
- blist_set_ontop(TRUE);
- } else {
-- gaim_debug_info(WINPREFS_PLUGIN_ID, "Blist Undocking..\n");
-- if (gaim_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_ALWAYS)
-+ gaim2_debug_info(WINPREFS_PLUGIN_ID, "Blist Undocking..\n");
-+ if (gaim2_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_ALWAYS)
- blist_set_ontop(TRUE);
- else
- blist_set_ontop(FALSE);
-@@ -132,7 +132,7 @@ static void blist_set_dockable(gboolean
- blist_ab = NULL;
- }
-
-- if (gaim_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_ALWAYS)
-+ if (gaim2_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_ALWAYS)
- blist_set_ontop(TRUE);
- else
- blist_set_ontop(FALSE);
-@@ -143,29 +143,29 @@ static void blist_set_dockable(gboolean
-
- /* We need this because the blist destroy cb won't be called before the
- plugin is unloaded, when quitting */
--static void gaim_quit_cb() {
-- gaim_debug_info(WINPREFS_PLUGIN_ID, "gaim_quit_cb: removing appbar\n");
-+static void gaim2_quit_cb() {
-+ gaim2_debug_info(WINPREFS_PLUGIN_ID, "gaim2_quit_cb: removing appbar\n");
- blist_save_state();
- blist_set_dockable(FALSE);
- }
-
--static void blist_create_cb(GaimBuddyList *gaim_blist, void *data) {
-- gaim_debug_info(WINPREFS_PLUGIN_ID, "buddy list created\n");
-+static void blist_create_cb(Gaim2BuddyList *gaim2_blist, void *data) {
-+ gaim2_debug_info(WINPREFS_PLUGIN_ID, "buddy list created\n");
-
-- blist = GAIM_GTK_BLIST(gaim_blist)->window;
-+ blist = GAIM_GTK_BLIST(gaim2_blist)->window;
-
-- if (gaim_prefs_get_bool(PREF_DBLIST_DOCKABLE)) {
-+ if (gaim2_prefs_get_bool(PREF_DBLIST_DOCKABLE)) {
- blist_set_dockable(TRUE);
-- if (gaim_prefs_get_bool(PREF_DBLIST_DOCKED)) {
-- blist_ab->undocked_height = gaim_prefs_get_int(PREF_DBLIST_HEIGHT);
-+ if (gaim2_prefs_get_bool(PREF_DBLIST_DOCKED)) {
-+ blist_ab->undocked_height = gaim2_prefs_get_int(PREF_DBLIST_HEIGHT);
- gtk_appbar_dock(blist_ab,
-- gaim_prefs_get_int(PREF_DBLIST_SIDE));
-- if (gaim_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_DOCKED)
-+ gaim2_prefs_get_int(PREF_DBLIST_SIDE));
-+ if (gaim2_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_DOCKED)
- blist_set_ontop(TRUE);
- }
- }
-
-- if (gaim_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_ALWAYS)
-+ if (gaim2_prefs_get_int(PREF_BLIST_ON_TOP) == BLIST_TOP_ALWAYS)
- blist_set_ontop(TRUE);
-
- }
-@@ -181,7 +181,7 @@ static int open_run_key(PHKEY phKey, REG
- "SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run",
- 0, samDesired, phKey));
- else {
-- gaim_debug_error(WINPREFS_PLUGIN_ID, "open_run_key: Could not open key for writing value\n");
-+ gaim2_debug_error(WINPREFS_PLUGIN_ID, "open_run_key: Could not open key for writing value\n");
- return 0;
- }
- return 1;
-@@ -200,35 +200,35 @@ winprefs_set_autostart(GtkWidget *w)
- char buffer[1024];
- DWORD size;
-
-- if ((size = GetModuleFileName(wgaim_hinstance(),
-+ if ((size = GetModuleFileName(wgaim2_hinstance(),
- (LPBYTE)buffer, sizeof(buffer)))==0) {
-- gaim_debug_error(WINPREFS_PLUGIN_ID, "GetModuleFileName Error.. Could not set Gaim autostart.\n");
-+ gaim2_debug_error(WINPREFS_PLUGIN_ID, "GetModuleFileName Error.. Could not set Gaim2 autostart.\n");
- RegCloseKey(hKey);
- return;
- }
-
- /* Now set value of new key */
-- if (ERROR_SUCCESS != RegSetValueEx(hKey, "Gaim", 0, REG_SZ, buffer, size))
-- gaim_debug_error(WINPREFS_PLUGIN_ID, "Could not set registry key value\n");
-+ if (ERROR_SUCCESS != RegSetValueEx(hKey, "Gaim2", 0, REG_SZ, buffer, size))
-+ gaim2_debug_error(WINPREFS_PLUGIN_ID, "Could not set registry key value\n");
- } else {
-- if (ERROR_SUCCESS != RegDeleteValue(hKey, "Gaim"))
-- gaim_debug_error(WINPREFS_PLUGIN_ID, "Could not delete registry key value\n");
-+ if (ERROR_SUCCESS != RegDeleteValue(hKey, "Gaim2"))
-+ gaim2_debug_error(WINPREFS_PLUGIN_ID, "Could not delete registry key value\n");
- }
- RegCloseKey(hKey);
- }
-
- static void
--winprefs_set_blist_dockable (const char *pref, GaimPrefType type,
-+winprefs_set_blist_dockable (const char *pref, Gaim2PrefType type,
- gpointer value, gpointer user_data)
- {
- blist_set_dockable(GPOINTER_TO_INT(value));
- }
-
- static void
--winprefs_set_blist_ontop (const char *pref, GaimPrefType type,
-+winprefs_set_blist_ontop (const char *pref, Gaim2PrefType type,
- gpointer value, gpointer user_data)
- {
-- gint setting = gaim_prefs_get_int(PREF_BLIST_ON_TOP);
-+ gint setting = gaim2_prefs_get_int(PREF_BLIST_ON_TOP);
- if ((setting == BLIST_TOP_DOCKED && blist_ab && blist_ab->docked)
- || setting == BLIST_TOP_ALWAYS)
- blist_set_ontop(TRUE);
-@@ -238,7 +238,7 @@ winprefs_set_blist_ontop (const char *pr
-
- static void load_winver_specific_procs (void) {
- /* Used for Win98+ and WinNT5+ */
-- MyFlashWindowEx = (LPFNFLASHWINDOWEX)wgaim_find_and_loadproc("user32.dll", "FlashWindowEx" );
-+ MyFlashWindowEx = (LPFNFLASHWINDOWEX)wgaim2_find_and_loadproc("user32.dll", "FlashWindowEx" );
- }
-
- /* Window flasher */
-@@ -267,11 +267,11 @@ halt_flash_filter (GtkWidget *widget, Gd
- } else {
- WGAIM_FLASH_INFO *finfo = data;
- /* Stop flashing and remove filter */
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "Removing timeout\n");
-- gaim_timeout_remove(finfo->t_handle);
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "Disconnecting signal handler\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "Removing timeout\n");
-+ gaim2_timeout_remove(finfo->t_handle);
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "Disconnecting signal handler\n");
- g_signal_handler_disconnect(G_OBJECT(widget),finfo->sig_handler);
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "done\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "done\n");
- g_free(finfo);
- }
- return 0;
-@@ -280,22 +280,22 @@ halt_flash_filter (GtkWidget *widget, Gd
- /* FlashWindowEx is only supported by Win98+ and WinNT5+. If it's
- not supported we do it our own way */
- static void
--wgaim_conv_im_blink (GaimAccount *account, char *sender, char *message, int flags)
-+wgaim2_conv_im_blink (Gaim2Account *account, char *sender, char *message, int flags)
- {
-- GaimConversation *conv;
-- GaimGtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkWindow *win;
- GtkWidget *window;
-- if (gaim_prefs_get_bool(PREF_IM_BLINK) == FALSE)
-+ if (gaim2_prefs_get_bool(PREF_IM_BLINK) == FALSE)
- return;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, sender, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, sender, account);
- if (conv == NULL) {
-- gaim_debug_info("winprefs", "gar!\n");
-+ gaim2_debug_info("winprefs", "gar!\n");
- return;
- }
-- win = gaim_gtkconv_get_window(GAIM_GTK_CONVERSATION(conv));
-+ win = gaim2_gtkconv_get_window(GAIM_GTK_CONVERSATION(conv));
- if (win == NULL) {
-- gaim_debug_info("winprefs", "gar2!\n");
-+ gaim2_debug_info("winprefs", "gar2!\n");
- return;
- }
- window = win->window;
-@@ -318,7 +318,7 @@ wgaim_conv_im_blink (GaimAccount *accoun
- WGAIM_FLASH_INFO *finfo = g_new0(WGAIM_FLASH_INFO, 1);
-
- /* Start Flashing window */
-- finfo->t_handle = gaim_timeout_add(1000, flash_window_cb,
-+ finfo->t_handle = gaim2_timeout_add(1000, flash_window_cb,
- GDK_WINDOW_HWND(window->window));
- finfo->sig_handler = g_signal_connect(G_OBJECT(window),
- "focus-in-event",
-@@ -331,41 +331,41 @@ wgaim_conv_im_blink (GaimAccount *accoun
- * EXPORTED FUNCTIONS
- */
-
--gboolean plugin_load(GaimPlugin *plugin) {
-+gboolean plugin_load(Gaim2Plugin *plugin) {
- /* Find out how to go blinky */
- load_winver_specific_procs();
-
- handle = plugin;
-
- /* blist docking init */
-- if (gaim_get_blist() && GAIM_GTK_BLIST(gaim_get_blist()) && GAIM_GTK_BLIST(gaim_get_blist())->window) {
-- blist_create_cb(gaim_get_blist(), NULL);
-+ if (gaim2_get_blist() && GAIM_GTK_BLIST(gaim2_get_blist()) && GAIM_GTK_BLIST(gaim2_get_blist())->window) {
-+ blist_create_cb(gaim2_get_blist(), NULL);
- }
-
- /* This really shouldn't happen anymore generally, but if for some strange
- reason, the blist is recreated, we need to set it up again. */
-- gaim_signal_connect(gaim_gtk_blist_get_handle(), "gtkblist-created", plugin, GAIM_CALLBACK(blist_create_cb), NULL);
-+ gaim2_signal_connect(gaim2_gtk_blist_get_handle(), "gtkblist-created", plugin, GAIM_CALLBACK(blist_create_cb), NULL);
-
-- gaim_signal_connect(gaim_conversations_get_handle(), "received-im-msg", plugin, GAIM_CALLBACK(wgaim_conv_im_blink), NULL);
-+ gaim2_signal_connect(gaim2_conversations_get_handle(), "received-im-msg", plugin, GAIM_CALLBACK(wgaim2_conv_im_blink), NULL);
-
-- gaim_signal_connect((void*)gaim_get_core(), "quitting", plugin, GAIM_CALLBACK(gaim_quit_cb), NULL);
-+ gaim2_signal_connect((void*)gaim2_get_core(), "quitting", plugin, GAIM_CALLBACK(gaim2_quit_cb), NULL);
-
-- gaim_prefs_connect_callback(handle, PREF_BLIST_ON_TOP,
-+ gaim2_prefs_connect_callback(handle, PREF_BLIST_ON_TOP,
- winprefs_set_blist_ontop, NULL);
-- gaim_prefs_connect_callback(handle, PREF_DBLIST_DOCKABLE,
-+ gaim2_prefs_connect_callback(handle, PREF_DBLIST_DOCKABLE,
- winprefs_set_blist_dockable, NULL);
-
- return TRUE;
- }
-
--gboolean plugin_unload(GaimPlugin *plugin) {
-+gboolean plugin_unload(Gaim2Plugin *plugin) {
- blist_set_dockable(FALSE);
- blist_set_ontop(FALSE);
-
- return TRUE;
- }
-
--static GtkWidget* get_config_frame(GaimPlugin *plugin) {
-+static GtkWidget* get_config_frame(Gaim2Plugin *plugin) {
- GtkWidget *ret;
- GtkWidget *vbox;
- GtkWidget *button;
-@@ -382,7 +382,7 @@ static GtkWidget* get_config_frame(GaimP
- /* Display Installed GTK+ Runtime Version */
- if(gtk_version) {
- GtkWidget *label;
-- vbox = gaim_gtk_make_frame(ret, _("GTK+ Runtime Version"));
-+ vbox = gaim2_gtk_make_frame(ret, _("GTK+ Runtime Version"));
- label = gtk_label_new(gtk_version);
- gtk_box_pack_start(GTK_BOX(vbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-@@ -390,11 +390,11 @@ static GtkWidget* get_config_frame(GaimP
- }
-
- /* Autostart */
-- vbox = gaim_gtk_make_frame (ret, _("Startup"));
-- button = gtk_check_button_new_with_mnemonic(_("_Start Gaim on Windows startup"));
-+ vbox = gaim2_gtk_make_frame (ret, _("Startup"));
-+ button = gtk_check_button_new_with_mnemonic(_("_Start Gaim2 on Windows startup"));
- gtk_box_pack_start(GTK_BOX(vbox), button, FALSE, FALSE, 0);
- if(open_run_key(&hKey, KEY_QUERY_VALUE)) {
-- if(ERROR_SUCCESS == RegQueryValueEx(hKey, "Gaim", 0, NULL, NULL, NULL)) {
-+ if(ERROR_SUCCESS == RegQueryValueEx(hKey, "Gaim2", 0, NULL, NULL, NULL)) {
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button), TRUE);
- }
- }
-@@ -402,12 +402,12 @@ static GtkWidget* get_config_frame(GaimP
- gtk_widget_show(button);
-
- /* Buddy List */
-- vbox = gaim_gtk_make_frame (ret, _("Buddy List"));
-- gaim_gtk_prefs_checkbox(_("_Dockable Buddy List"),
-+ vbox = gaim2_gtk_make_frame (ret, _("Buddy List"));
-+ gaim2_gtk_prefs_checkbox(_("_Dockable Buddy List"),
- PREF_DBLIST_DOCKABLE, vbox);
-
- /* Blist On Top */
-- gaim_gtk_prefs_dropdown(vbox, _("_Keep Buddy List window on top:"),
-+ gaim2_gtk_prefs_dropdown(vbox, _("_Keep Buddy List window on top:"),
- GAIM_PREF_INT, PREF_BLIST_ON_TOP,
- _("Never"), BLIST_TOP_NEVER,
- _("Always"), BLIST_TOP_ALWAYS,
-@@ -416,20 +416,20 @@ static GtkWidget* get_config_frame(GaimP
- NULL);
-
- /* Conversations */
-- vbox = gaim_gtk_make_frame (ret, _("Conversations"));
-- gaim_gtk_prefs_checkbox(_("_Flash window when messages are received"),
-+ vbox = gaim2_gtk_make_frame (ret, _("Conversations"));
-+ gaim2_gtk_prefs_checkbox(_("_Flash window when messages are received"),
- PREF_IM_BLINK, vbox);
-
- gtk_widget_show_all(ret);
- return ret;
- }
-
--static GaimGtkPluginUiInfo ui_info =
-+static Gaim2GtkPluginUiInfo ui_info =
- {
- get_config_frame
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -440,10 +440,10 @@ static GaimPluginInfo info =
- NULL,
- GAIM_PRIORITY_DEFAULT,
- WINPREFS_PLUGIN_ID,
-- N_("WinGaim Options"),
-+ N_("WinGaim2 Options"),
- VERSION,
-- N_("Options specific to Windows Gaim."),
-- N_("Provides options specific to Windows Gaim, such as buddy list docking and conversation flashing."),
-+ N_("Options specific to Windows Gaim2."),
-+ N_("Provides options specific to Windows Gaim2, such as buddy list docking and conversation flashing."),
- "Herman Bloggs <hermanator12002@yahoo.com>",
- GAIM_WEBSITE,
- plugin_load,
-@@ -456,29 +456,29 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- gaim_prefs_add_none("/plugins/gtk");
-- gaim_prefs_add_none("/plugins/gtk/win32");
-- gaim_prefs_add_none("/plugins/gtk/win32/winprefs");
-- gaim_prefs_add_bool(PREF_DBLIST_DOCKABLE, FALSE);
-- gaim_prefs_add_bool(PREF_DBLIST_DOCKED, FALSE);
-- gaim_prefs_add_int(PREF_DBLIST_HEIGHT, 0);
-- gaim_prefs_add_int(PREF_DBLIST_SIDE, 0);
-- gaim_prefs_add_bool(PREF_IM_BLINK, TRUE);
-+ gaim2_prefs_add_none("/plugins/gtk");
-+ gaim2_prefs_add_none("/plugins/gtk/win32");
-+ gaim2_prefs_add_none("/plugins/gtk/win32/winprefs");
-+ gaim2_prefs_add_bool(PREF_DBLIST_DOCKABLE, FALSE);
-+ gaim2_prefs_add_bool(PREF_DBLIST_DOCKED, FALSE);
-+ gaim2_prefs_add_int(PREF_DBLIST_HEIGHT, 0);
-+ gaim2_prefs_add_int(PREF_DBLIST_SIDE, 0);
-+ gaim2_prefs_add_bool(PREF_IM_BLINK, TRUE);
-
- /* Convert old preferences */
-- if (gaim_prefs_exists(PREF_DBLIST_ON_TOP)) {
-+ if (gaim2_prefs_exists(PREF_DBLIST_ON_TOP)) {
- gint blist_top = BLIST_TOP_NEVER;
-- if (gaim_prefs_get_bool(PREF_BLIST_ON_TOP))
-+ if (gaim2_prefs_get_bool(PREF_BLIST_ON_TOP))
- blist_top = BLIST_TOP_ALWAYS;
-- else if (gaim_prefs_get_bool(PREF_DBLIST_ON_TOP))
-+ else if (gaim2_prefs_get_bool(PREF_DBLIST_ON_TOP))
- blist_top = BLIST_TOP_DOCKED;
-- gaim_prefs_remove(PREF_BLIST_ON_TOP);
-- gaim_prefs_remove(PREF_DBLIST_ON_TOP);
-- gaim_prefs_add_int(PREF_BLIST_ON_TOP, blist_top);
-+ gaim2_prefs_remove(PREF_BLIST_ON_TOP);
-+ gaim2_prefs_remove(PREF_DBLIST_ON_TOP);
-+ gaim2_prefs_add_int(PREF_BLIST_ON_TOP, blist_top);
- } else
-- gaim_prefs_add_int(PREF_BLIST_ON_TOP, BLIST_TOP_NEVER);
-+ gaim2_prefs_add_int(PREF_BLIST_ON_TOP, BLIST_TOP_NEVER);
- }
-
- GAIM_INIT_PLUGIN(winprefs, init_plugin, info)
-diff -prNu ./po/Makefile.in.in ./po/Makefile.in.in
---- ./po/Makefile.in.in 1970-01-01 01:00:00.000000000 +0100
-+++ ./po/Makefile.in.in 2006-01-05 14:15:18.000000000 +0100
-@@ -0,0 +1,196 @@
-+# Makefile for program source directory in GNU NLS utilities package.
-+# Copyright (C) 1995-1997, 2000, 2001 by Ulrich Drepper <drepper@gnu.ai.mit.edu>
-+#
-+# This file file be copied and used freely without restrictions. It can
-+# be used in projects which are not available under the GNU Public License
-+# but which still want to provide support for the GNU gettext functionality.
-+# Please note that the actual code is *not* freely available.
-+
-+PACKAGE = @PACKAGE@
-+VERSION = @VERSION@
-+
-+# These two variables depend on the location of this directory.
-+subdir = po
-+top_builddir = ..
-+
-+SHELL = /bin/sh
-+@SET_MAKE@
-+
-+srcdir = @srcdir@
-+top_srcdir = @top_srcdir@
-+VPATH = @srcdir@
-+
-+prefix = @prefix@
-+exec_prefix = @exec_prefix@
-+datadir = @datadir@
-+localedir = $(datadir)/locale
-+gettextsrcdir = $(datadir)/gettext/po
-+
-+INSTALL = @INSTALL@
-+INSTALL_DATA = @INSTALL_DATA@
-+MKINSTALLDIRS = @MKINSTALLDIRS@
-+mkinstalldirs = $(SHELL) `case "$(MKINSTALLDIRS)" in /*) echo "$(MKINSTALLDIRS)" ;; ./*) echo "$(top_builddir)/$(MKINSTALLDIRS)" ;; *) echo "$(MKINSTALLDIRS)" ;; esac`
-+
-+CC = @CC@
-+GMSGFMT = @GMSGFMT@
-+MSGFMT = @MSGFMT@
-+XGETTEXT = @XGETTEXT@
-+MSGMERGE = msgmerge
-+
-+DEFS = @DEFS@
-+CFLAGS = @CFLAGS@
-+CPPFLAGS = @CPPFLAGS@
-+
-+INCLUDES = -I.. -I$(top_srcdir)/intl
-+
-+COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
-+
-+POFILES = @POFILES@
-+GMOFILES = @GMOFILES@
-+DISTFILES = ChangeLog Makefile.in.in POTFILES.in $(PACKAGE).pot \
-+$(POFILES) $(GMOFILES)
-+
-+POTFILES = \
-+
-+CATALOGS = @CATALOGS@
-+
-+.SUFFIXES:
-+.SUFFIXES: .c .o .po .pox .gmo .mo
-+
-+.c.o:
-+ $(COMPILE) $<
-+
-+.po.pox:
-+ $(MAKE) $(PACKAGE).pot
-+ $(MSGMERGE) $< $(srcdir)/$(PACKAGE).pot -o $*.pox
-+
-+.po.mo:
-+ $(MSGFMT) -o $@ $<
-+
-+.po.gmo:
-+ file=$(srcdir)/`echo $* | sed 's,.*/,,'`.gmo \
-+ && rm -f $$file && $(GMSGFMT) --statistics -o $$file $<
-+
-+
-+all: all-@USE_NLS@
-+
-+all-yes: $(CATALOGS)
-+all-no:
-+
-+# Note: Target 'all' must not depend on target '$(srcdir)/$(PACKAGE).pot',
-+# otherwise packages like GCC can not be built if only parts of the source
-+# have been downloaded.
-+
-+$(srcdir)/$(PACKAGE).pot: $(POTFILES) $(srcdir)/POTFILES.in
-+ $(XGETTEXT) --default-domain=$(PACKAGE) --directory=$(top_srcdir) \
-+ --add-comments --keyword=_ --keyword=N_ \
-+ --files-from=$(srcdir)/POTFILES.in \
-+ && test ! -f $(PACKAGE).po \
-+ || ( rm -f $(srcdir)/$(PACKAGE).pot \
-+ && mv $(PACKAGE).po $(srcdir)/$(PACKAGE).pot )
-+
-+
-+install: install-exec install-data
-+install-exec:
-+install-data: install-data-@USE_NLS@
-+ if test "$(PACKAGE)" = "gettext"; then \
-+ $(mkinstalldirs) $(DESTDIR)$(gettextsrcdir); \
-+ $(INSTALL_DATA) $(srcdir)/Makefile.in.in \
-+ $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
-+ else \
-+ : ; \
-+ fi
-+install-data-no: all
-+install-data-yes: all
-+ $(mkinstalldirs) $(DESTDIR)$(datadir)
-+ @catalogs='$(CATALOGS)'; \
-+ for cat in $$catalogs; do \
-+ cat=`basename $$cat`; \
-+ lang=`echo $$cat | sed 's/\.gmo$$//'`; \
-+ dir=$(localedir)/$$lang/LC_MESSAGES; \
-+ $(mkinstalldirs) $(DESTDIR)$$dir; \
-+ if test -r $$cat; then \
-+ $(INSTALL_DATA) $$cat $(DESTDIR)$$dir/$(PACKAGE).mo; \
-+ echo "installing $$cat as $(DESTDIR)$$dir/$(PACKAGE).mo"; \
-+ else \
-+ $(INSTALL_DATA) $(srcdir)/$$cat $(DESTDIR)$$dir/$(PACKAGE).mo; \
-+ echo "installing $(srcdir)/$$cat as" \
-+ "$(DESTDIR)$$dir/$(PACKAGE).mo"; \
-+ fi; \
-+ done
-+
-+# Define this as empty until I found a useful application.
-+installcheck:
-+
-+uninstall:
-+ catalogs='$(CATALOGS)'; \
-+ for cat in $$catalogs; do \
-+ cat=`basename $$cat`; \
-+ lang=`echo $$cat | sed 's/\.gmo$$//'`; \
-+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE).mo; \
-+ done
-+ if test "$(PACKAGE)" = "gettext"; then \
-+ rm -f $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
-+ else \
-+ : ; \
-+ fi
-+
-+check: all
-+
-+dvi info tags TAGS ID:
-+
-+mostlyclean:
-+ rm -f core core.* *.pox $(PACKAGE).po *.new.po
-+ rm -fr *.o
-+
-+clean: mostlyclean
-+
-+distclean: clean
-+ rm -f Makefile Makefile.in POTFILES *.mo
-+
-+maintainer-clean: distclean
-+ @echo "This command is intended for maintainers to use;"
-+ @echo "it deletes files that may require special tools to rebuild."
-+ rm -f $(GMOFILES)
-+
-+distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-+dist distdir:
-+ $(MAKE) update-po
-+ @$(MAKE) dist2
-+# This is a separate target because 'update-po' must be executed before.
-+dist2: $(DISTFILES)
-+ dists="$(DISTFILES)"; \
-+ for file in $$dists; do \
-+ if test -f $$file; then dir=.; else dir=$(srcdir); fi; \
-+ cp -p $$dir/$$file $(distdir); \
-+ done
-+
-+update-po: Makefile
-+ $(MAKE) $(PACKAGE).pot
-+ if test "$(PACKAGE)" = "gettext"; then PATH=`pwd`/../src:$$PATH; fi; \
-+ cd $(srcdir); \
-+ catalogs='$(GMOFILES)'; \
-+ for cat in $$catalogs; do \
-+ cat=`basename $$cat`; \
-+ lang=`echo $$cat | sed 's/\.gmo$$//'`; \
-+ echo "$$lang:"; \
-+ if $(MSGMERGE) $$lang.po $(PACKAGE).pot -o $$lang.new.po; then \
-+ mv -f $$lang.new.po $$lang.po; \
-+ else \
-+ echo "msgmerge for $$cat failed!"; \
-+ rm -f $$lang.new.po; \
-+ fi; \
-+ done
-+ $(MAKE) update-gmo
-+
-+update-gmo: Makefile $(GMOFILES)
-+ @:
-+
-+Makefile: Makefile.in.in $(top_builddir)/config.status POTFILES.in
-+ cd $(top_builddir) \
-+ && CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= \
-+ $(SHELL) ./config.status
-+
-+# Tell versions [3.59,3.63) of GNU make not to export all variables.
-+# Otherwise a system limit (for SysV at least) may be exceeded.
-+.NOEXPORT:
-diff -prNu ./sounds/Makefile.am ./sounds/Makefile.am
---- ./sounds/Makefile.am 2004-11-05 06:26:42.000000000 +0100
-+++ ./sounds/Makefile.am 2006-01-05 13:06:34.000000000 +0100
-@@ -5,5 +5,5 @@ EXTRA_DIST = \
- receive.wav \
- send.wav
-
--soundsdir = $(datadir)/sounds/gaim
-+soundsdir = $(datadir)/sounds/gaim2
- sounds_DATA = $(EXTRA_DIST)
-diff -prNu ./src/account.c ./src/account.c
---- ./src/account.c 2005-12-23 20:25:42.000000000 +0100
-+++ ./src/account.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file account.c Account API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -39,10 +39,10 @@
- #include "util.h"
- #include "xmlnode.h"
-
--/* TODO: Should use GaimValue instead of this? What about "ui"? */
-+/* TODO: Should use Gaim2Value instead of this? What about "ui"? */
- typedef struct
- {
-- GaimPrefType type;
-+ Gaim2PrefType type;
-
- char *ui;
-
-@@ -54,10 +54,10 @@ typedef struct
-
- } value;
-
--} GaimAccountSetting;
-+} Gaim2AccountSetting;
-
-
--static GaimAccountUiOps *account_ui_ops = NULL;
-+static Gaim2AccountUiOps *account_ui_ops = NULL;
-
- static GList *accounts = NULL;
- static guint save_timer = 0;
-@@ -72,12 +72,12 @@ static void
- setting_to_xmlnode(gpointer key, gpointer value, gpointer user_data)
- {
- const char *name;
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- xmlnode *node, *child;
- char buf[20];
-
- name = (const char *)key;
-- setting = (GaimAccountSetting *)value;
-+ setting = (Gaim2AccountSetting *)value;
- node = (xmlnode *)user_data;
-
- child = xmlnode_new_child(node, "setting");
-@@ -119,30 +119,30 @@ ui_setting_to_xmlnode(gpointer key, gpoi
- }
-
- static xmlnode *
--status_attr_to_xmlnode(const GaimStatus *status, const GaimStatusType *type, const GaimStatusAttr *attr)
-+status_attr_to_xmlnode(const Gaim2Status *status, const Gaim2StatusType *type, const Gaim2StatusAttr *attr)
- {
- xmlnode *node;
- const char *id;
- char *value = NULL;
-- GaimStatusAttr *default_attr;
-- GaimValue *default_value;
-- GaimType attr_type;
-- GaimValue *attr_value;
-+ Gaim2StatusAttr *default_attr;
-+ Gaim2Value *default_value;
-+ Gaim2Type attr_type;
-+ Gaim2Value *attr_value;
-
-- id = gaim_status_attr_get_id(attr);
-+ id = gaim2_status_attr_get_id(attr);
- g_return_val_if_fail(id, NULL);
-
-- attr_value = gaim_status_get_attr_value(status, id);
-+ attr_value = gaim2_status_get_attr_value(status, id);
- g_return_val_if_fail(attr_value, NULL);
-- attr_type = gaim_value_get_type(attr_value);
-+ attr_type = gaim2_value_get_type(attr_value);
-
- /*
- * If attr_value is a different type than it should be
- * then don't write it to the file.
- */
-- default_attr = gaim_status_type_get_attr(type, id);
-- default_value = gaim_status_attr_get_value(default_attr);
-- if (attr_type != gaim_value_get_type(default_value))
-+ default_attr = gaim2_status_type_get_attr(type, id);
-+ default_value = gaim2_status_attr_get_value(default_attr);
-+ if (attr_type != gaim2_value_get_type(default_value))
- return NULL;
-
- /*
-@@ -151,25 +151,25 @@ status_attr_to_xmlnode(const GaimStatus
- */
- if (attr_type == GAIM_TYPE_STRING)
- {
-- const char *string_value = gaim_value_get_string(attr_value);
-- const char *default_string_value = gaim_value_get_string(default_value);
-+ const char *string_value = gaim2_value_get_string(attr_value);
-+ const char *default_string_value = gaim2_value_get_string(default_value);
- if (((string_value == NULL) && (default_string_value == NULL)) ||
- ((string_value != NULL) && (default_string_value != NULL) &&
- !strcmp(string_value, default_string_value)))
- return NULL;
-- value = g_strdup(gaim_value_get_string(attr_value));
-+ value = g_strdup(gaim2_value_get_string(attr_value));
- }
- else if (attr_type == GAIM_TYPE_INT)
- {
-- int int_value = gaim_value_get_int(attr_value);
-- if (int_value == gaim_value_get_int(default_value))
-+ int int_value = gaim2_value_get_int(attr_value);
-+ if (int_value == gaim2_value_get_int(default_value))
- return NULL;
- value = g_strdup_printf("%d", int_value);
- }
- else if (attr_type == GAIM_TYPE_BOOLEAN)
- {
-- gboolean boolean_value = gaim_value_get_boolean(attr_value);
-- if (boolean_value == gaim_value_get_boolean(default_value))
-+ gboolean boolean_value = gaim2_value_get_boolean(attr_value);
-+ if (boolean_value == gaim2_value_get_boolean(default_value))
- return NULL;
- value = g_strdup(boolean_value ?
- "true" : "false");
-@@ -192,18 +192,18 @@ status_attr_to_xmlnode(const GaimStatus
- }
-
- static xmlnode *
--status_attrs_to_xmlnode(const GaimStatus *status)
-+status_attrs_to_xmlnode(const Gaim2Status *status)
- {
-- GaimStatusType *type = gaim_status_get_type(status);
-+ Gaim2StatusType *type = gaim2_status_get_type(status);
- xmlnode *node, *child;
- const GList *attrs, *attr;
-
- node = xmlnode_new("attributes");
-
-- attrs = gaim_status_type_get_attrs(type);
-+ attrs = gaim2_status_type_get_attrs(type);
- for (attr = attrs; attr != NULL; attr = attr->next)
- {
-- child = status_attr_to_xmlnode(status, type, (const GaimStatusAttr *)attr->data);
-+ child = status_attr_to_xmlnode(status, type, (const Gaim2StatusAttr *)attr->data);
- if (child)
- xmlnode_insert_child(node, child);
- }
-@@ -212,15 +212,15 @@ status_attrs_to_xmlnode(const GaimStatus
- }
-
- static xmlnode *
--status_to_xmlnode(const GaimStatus *status)
-+status_to_xmlnode(const Gaim2Status *status)
- {
- xmlnode *node, *child;
-
- node = xmlnode_new("status");
-- xmlnode_set_attrib(node, "type", gaim_status_get_id(status));
-- if (gaim_status_get_name(status) != NULL)
-- xmlnode_set_attrib(node, "name", gaim_status_get_name(status));
-- xmlnode_set_attrib(node, "active", gaim_status_is_active(status) ? "true" : "false");
-+ xmlnode_set_attrib(node, "type", gaim2_status_get_id(status));
-+ if (gaim2_status_get_name(status) != NULL)
-+ xmlnode_set_attrib(node, "name", gaim2_status_get_name(status));
-+ xmlnode_set_attrib(node, "active", gaim2_status_is_active(status) ? "true" : "false");
-
- child = status_attrs_to_xmlnode(status);
- xmlnode_insert_child(node, child);
-@@ -229,17 +229,17 @@ status_to_xmlnode(const GaimStatus *stat
- }
-
- static xmlnode *
--statuses_to_xmlnode(const GaimPresence *presence)
-+statuses_to_xmlnode(const Gaim2Presence *presence)
- {
- xmlnode *node, *child;
- const GList *statuses, *status;
-
- node = xmlnode_new("statuses");
-
-- statuses = gaim_presence_get_statuses(presence);
-+ statuses = gaim2_presence_get_statuses(presence);
- for (status = statuses; status != NULL; status = status->next)
- {
-- child = status_to_xmlnode((GaimStatus *)status->data);
-+ child = status_to_xmlnode((Gaim2Status *)status->data);
- xmlnode_insert_child(node, child);
- }
-
-@@ -247,15 +247,15 @@ statuses_to_xmlnode(const GaimPresence *
- }
-
- static xmlnode *
--proxy_settings_to_xmlnode(GaimProxyInfo *proxy_info)
-+proxy_settings_to_xmlnode(Gaim2ProxyInfo *proxy_info)
- {
- xmlnode *node, *child;
-- GaimProxyType proxy_type;
-+ Gaim2ProxyType proxy_type;
- const char *value;
- int int_value;
- char buf[20];
-
-- proxy_type = gaim_proxy_info_get_type(proxy_info);
-+ proxy_type = gaim2_proxy_info_get_type(proxy_info);
-
- node = xmlnode_new("proxy");
-
-@@ -272,26 +272,26 @@ proxy_settings_to_xmlnode(GaimProxyInfo
- proxy_type != GAIM_PROXY_NONE &&
- proxy_type != GAIM_PROXY_USE_ENVVAR)
- {
-- if ((value = gaim_proxy_info_get_host(proxy_info)) != NULL)
-+ if ((value = gaim2_proxy_info_get_host(proxy_info)) != NULL)
- {
- child = xmlnode_new_child(node, "host");
- xmlnode_insert_data(child, value, -1);
- }
-
-- if ((int_value = gaim_proxy_info_get_port(proxy_info)) != 0)
-+ if ((int_value = gaim2_proxy_info_get_port(proxy_info)) != 0)
- {
- snprintf(buf, sizeof(buf), "%d", int_value);
- child = xmlnode_new_child(node, "port");
- xmlnode_insert_data(child, buf, -1);
- }
-
-- if ((value = gaim_proxy_info_get_username(proxy_info)) != NULL)
-+ if ((value = gaim2_proxy_info_get_username(proxy_info)) != NULL)
- {
- child = xmlnode_new_child(node, "username");
- xmlnode_insert_data(child, value, -1);
- }
-
-- if ((value = gaim_proxy_info_get_password(proxy_info)) != NULL)
-+ if ((value = gaim2_proxy_info_get_password(proxy_info)) != NULL)
- {
- child = xmlnode_new_child(node, "password");
- xmlnode_insert_data(child, value, -1);
-@@ -302,48 +302,48 @@ proxy_settings_to_xmlnode(GaimProxyInfo
- }
-
- static xmlnode *
--account_to_xmlnode(GaimAccount *account)
-+account_to_xmlnode(Gaim2Account *account)
- {
- xmlnode *node, *child;
- const char *tmp;
-- GaimPresence *presence;
-- GaimProxyInfo *proxy_info;
-+ Gaim2Presence *presence;
-+ Gaim2ProxyInfo *proxy_info;
-
- node = xmlnode_new("account");
-
- child = xmlnode_new_child(node, "protocol");
-- xmlnode_insert_data(child, gaim_account_get_protocol_id(account), -1);
-+ xmlnode_insert_data(child, gaim2_account_get_protocol_id(account), -1);
-
- child = xmlnode_new_child(node, "name");
-- xmlnode_insert_data(child, gaim_account_get_username(account), -1);
-+ xmlnode_insert_data(child, gaim2_account_get_username(account), -1);
-
-- if (gaim_account_get_remember_password(account) &&
-- ((tmp = gaim_account_get_password(account)) != NULL))
-+ if (gaim2_account_get_remember_password(account) &&
-+ ((tmp = gaim2_account_get_password(account)) != NULL))
- {
- child = xmlnode_new_child(node, "password");
- xmlnode_insert_data(child, tmp, -1);
- }
-
-- if ((tmp = gaim_account_get_alias(account)) != NULL)
-+ if ((tmp = gaim2_account_get_alias(account)) != NULL)
- {
- child = xmlnode_new_child(node, "alias");
- xmlnode_insert_data(child, tmp, -1);
- }
-
-- if ((presence = gaim_account_get_presence(account)) != NULL)
-+ if ((presence = gaim2_account_get_presence(account)) != NULL)
- {
- child = statuses_to_xmlnode(presence);
- xmlnode_insert_child(node, child);
- }
-
-- if ((tmp = gaim_account_get_user_info(account)) != NULL)
-+ if ((tmp = gaim2_account_get_user_info(account)) != NULL)
- {
-- /* TODO: Do we need to call gaim_str_strip_char(tmp, '\r') here? */
-+ /* TODO: Do we need to call gaim2_str_strip_char(tmp, '\r') here? */
- child = xmlnode_new_child(node, "userinfo");
- xmlnode_insert_data(child, tmp, -1);
- }
-
-- if ((tmp = gaim_account_get_buddy_icon(account)) != NULL)
-+ if ((tmp = gaim2_account_get_buddy_icon(account)) != NULL)
- {
- child = xmlnode_new_child(node, "buddyicon");
- xmlnode_insert_data(child, tmp, -1);
-@@ -360,7 +360,7 @@ account_to_xmlnode(GaimAccount *account)
- g_hash_table_foreach(account->ui_settings, ui_setting_to_xmlnode, node);
- }
-
-- if ((proxy_info = gaim_account_get_proxy_info(account)) != NULL)
-+ if ((proxy_info = gaim2_account_get_proxy_info(account)) != NULL)
- {
- child = proxy_settings_to_xmlnode(proxy_info);
- xmlnode_insert_child(node, child);
-@@ -378,7 +378,7 @@ accounts_to_xmlnode(void)
- node = xmlnode_new("account");
- xmlnode_set_attrib(node, "version", "1.0");
-
-- for (cur = gaim_accounts_get_all(); cur != NULL; cur = cur->next)
-+ for (cur = gaim2_accounts_get_all(); cur != NULL; cur = cur->next)
- {
- child = account_to_xmlnode(cur->data);
- xmlnode_insert_child(node, child);
-@@ -395,14 +395,14 @@ sync_accounts(void)
-
- if (!accounts_loaded)
- {
-- gaim_debug_error("account", "Attempted to save accounts before "
-+ gaim2_debug_error("account", "Attempted to save accounts before "
- "they were read!\n");
- return;
- }
-
- node = accounts_to_xmlnode();
- data = xmlnode_to_formatted_str(node, NULL);
-- gaim_util_write_data_to_file("accounts.xml", data, -1);
-+ gaim2_util_write_data_to_file("accounts.xml", data, -1);
- g_free(data);
- xmlnode_free(node);
- }
-@@ -419,7 +419,7 @@ static void
- schedule_accounts_save()
- {
- if (save_timer == 0)
-- save_timer = gaim_timeout_add(5000, save_cb, NULL);
-+ save_timer = gaim2_timeout_add(5000, save_cb, NULL);
- }
-
-
-@@ -428,7 +428,7 @@ schedule_accounts_save()
- *********************************************************************/
-
- static void
--parse_settings(xmlnode *node, GaimAccount *account)
-+parse_settings(xmlnode *node, Gaim2Account *account)
- {
- const char *ui;
- xmlnode *child;
-@@ -441,7 +441,7 @@ parse_settings(xmlnode *node, GaimAccoun
- child = xmlnode_get_next_twin(child))
- {
- const char *name, *str_type;
-- GaimPrefType type;
-+ Gaim2PrefType type;
- char *data;
-
- name = xmlnode_get_attrib(child, "name");
-@@ -472,19 +472,19 @@ parse_settings(xmlnode *node, GaimAccoun
- if (ui == NULL)
- {
- if (type == GAIM_PREF_STRING)
-- gaim_account_set_string(account, name, data);
-+ gaim2_account_set_string(account, name, data);
- else if (type == GAIM_PREF_INT)
-- gaim_account_set_int(account, name, atoi(data));
-+ gaim2_account_set_int(account, name, atoi(data));
- else if (type == GAIM_PREF_BOOLEAN)
-- gaim_account_set_bool(account, name,
-+ gaim2_account_set_bool(account, name,
- (*data == '0' ? FALSE : TRUE));
- } else {
- if (type == GAIM_PREF_STRING)
-- gaim_account_set_ui_string(account, ui, name, data);
-+ gaim2_account_set_ui_string(account, ui, name, data);
- else if (type == GAIM_PREF_INT)
-- gaim_account_set_ui_int(account, ui, name, atoi(data));
-+ gaim2_account_set_ui_int(account, ui, name, atoi(data));
- else if (type == GAIM_PREF_BOOLEAN)
-- gaim_account_set_ui_bool(account, ui, name,
-+ gaim2_account_set_ui_bool(account, ui, name,
- (*data == '0' ? FALSE : TRUE));
- }
-
-@@ -493,11 +493,11 @@ parse_settings(xmlnode *node, GaimAccoun
- }
-
- static GList *
--parse_status_attrs(xmlnode *node, GaimStatus *status)
-+parse_status_attrs(xmlnode *node, Gaim2Status *status)
- {
- GList *list = NULL;
- xmlnode *child;
-- GaimValue *attr_value;
-+ Gaim2Value *attr_value;
-
- for (child = xmlnode_get_child(node, "attribute"); child != NULL;
- child = xmlnode_get_next_twin(child))
-@@ -508,13 +508,13 @@ parse_status_attrs(xmlnode *node, GaimSt
- if (!id || !*id || !value || !*value)
- continue;
-
-- attr_value = gaim_status_get_attr_value(status, id);
-+ attr_value = gaim2_status_get_attr_value(status, id);
- if (!attr_value)
- continue;
-
- list = g_list_append(list, (char *)id);
-
-- switch (gaim_value_get_type(attr_value))
-+ switch (gaim2_value_get_type(attr_value))
- {
- case GAIM_TYPE_STRING:
- list = g_list_append(list, (char *)value);
-@@ -538,7 +538,7 @@ parse_status_attrs(xmlnode *node, GaimSt
- }
-
- static void
--parse_status(xmlnode *node, GaimAccount *account)
-+parse_status(xmlnode *node, Gaim2Account *account)
- {
- gboolean active = FALSE;
- const char *data;
-@@ -567,16 +567,16 @@ parse_status(xmlnode *node, GaimAccount
- if (child != NULL)
- {
- attrs = parse_status_attrs(child,
-- gaim_account_get_status(account, type));
-+ gaim2_account_get_status(account, type));
- }
-
-- gaim_account_set_status_list(account, type, active, attrs);
-+ gaim2_account_set_status_list(account, type, active, attrs);
-
- g_list_free(attrs);
- }
-
- static void
--parse_statuses(xmlnode *node, GaimAccount *account)
-+parse_statuses(xmlnode *node, Gaim2Account *account)
- {
- xmlnode *child;
-
-@@ -588,38 +588,38 @@ parse_statuses(xmlnode *node, GaimAccoun
- }
-
- static void
--parse_proxy_info(xmlnode *node, GaimAccount *account)
-+parse_proxy_info(xmlnode *node, Gaim2Account *account)
- {
-- GaimProxyInfo *proxy_info;
-+ Gaim2ProxyInfo *proxy_info;
- xmlnode *child;
- char *data;
-
-- proxy_info = gaim_proxy_info_new();
-+ proxy_info = gaim2_proxy_info_new();
-
- /* Use the global proxy settings, by default */
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_USE_GLOBAL);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_USE_GLOBAL);
-
- /* Read proxy type */
- child = xmlnode_get_child(node, "type");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
- if (!strcmp(data, "global"))
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_USE_GLOBAL);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_USE_GLOBAL);
- else if (!strcmp(data, "none"))
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_NONE);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_NONE);
- else if (!strcmp(data, "http"))
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_HTTP);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_HTTP);
- else if (!strcmp(data, "socks4"))
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_SOCKS4);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_SOCKS4);
- else if (!strcmp(data, "socks5"))
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_SOCKS5);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_SOCKS5);
- else if (!strcmp(data, "envvar"))
-- gaim_proxy_info_set_type(proxy_info, GAIM_PROXY_USE_ENVVAR);
-+ gaim2_proxy_info_set_type(proxy_info, GAIM_PROXY_USE_ENVVAR);
- else
- {
-- gaim_debug_error("account", "Invalid proxy type found when "
-+ gaim2_debug_error("account", "Invalid proxy type found when "
- "loading account information for %s\n",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- }
- g_free(data);
- }
-@@ -628,7 +628,7 @@ parse_proxy_info(xmlnode *node, GaimAcco
- child = xmlnode_get_child(node, "host");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_proxy_info_set_host(proxy_info, data);
-+ gaim2_proxy_info_set_host(proxy_info, data);
- g_free(data);
- }
-
-@@ -636,7 +636,7 @@ parse_proxy_info(xmlnode *node, GaimAcco
- child = xmlnode_get_child(node, "port");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_proxy_info_set_port(proxy_info, atoi(data));
-+ gaim2_proxy_info_set_port(proxy_info, atoi(data));
- g_free(data);
- }
-
-@@ -644,7 +644,7 @@ parse_proxy_info(xmlnode *node, GaimAcco
- child = xmlnode_get_child(node, "username");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_proxy_info_set_username(proxy_info, data);
-+ gaim2_proxy_info_set_username(proxy_info, data);
- g_free(data);
- }
-
-@@ -652,28 +652,28 @@ parse_proxy_info(xmlnode *node, GaimAcco
- child = xmlnode_get_child(node, "password");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_proxy_info_set_password(proxy_info, data);
-+ gaim2_proxy_info_set_password(proxy_info, data);
- g_free(data);
- }
-
- /* If there are no values set then proxy_infourn NULL */
-- if ((gaim_proxy_info_get_type(proxy_info) == GAIM_PROXY_USE_GLOBAL) &&
-- (gaim_proxy_info_get_host(proxy_info) == NULL) &&
-- (gaim_proxy_info_get_port(proxy_info) == 0) &&
-- (gaim_proxy_info_get_username(proxy_info) == NULL) &&
-- (gaim_proxy_info_get_password(proxy_info) == NULL))
-+ if ((gaim2_proxy_info_get_type(proxy_info) == GAIM_PROXY_USE_GLOBAL) &&
-+ (gaim2_proxy_info_get_host(proxy_info) == NULL) &&
-+ (gaim2_proxy_info_get_port(proxy_info) == 0) &&
-+ (gaim2_proxy_info_get_username(proxy_info) == NULL) &&
-+ (gaim2_proxy_info_get_password(proxy_info) == NULL))
- {
-- gaim_proxy_info_destroy(proxy_info);
-+ gaim2_proxy_info_destroy(proxy_info);
- return;
- }
-
-- gaim_account_set_proxy_info(account, proxy_info);
-+ gaim2_account_set_proxy_info(account, proxy_info);
- }
-
--static GaimAccount *
-+static Gaim2Account *
- parse_account(xmlnode *node)
- {
-- GaimAccount *ret;
-+ Gaim2Account *ret;
- xmlnode *child;
- char *protocol_id = NULL;
- char *name = NULL;
-@@ -701,7 +701,7 @@ parse_account(xmlnode *node)
- return NULL;
- }
-
-- ret = gaim_account_new(name, protocol_id);
-+ ret = gaim2_account_new(name, protocol_id);
- free(name);
- free(protocol_id);
-
-@@ -709,8 +709,8 @@ parse_account(xmlnode *node)
- child = xmlnode_get_child(node, "password");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_account_set_remember_password(ret, TRUE);
-- gaim_account_set_password(ret, data);
-+ gaim2_account_set_remember_password(ret, TRUE);
-+ gaim2_account_set_password(ret, data);
- g_free(data);
- }
-
-@@ -719,7 +719,7 @@ parse_account(xmlnode *node)
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
- if (*data != '\0')
-- gaim_account_set_alias(ret, data);
-+ gaim2_account_set_alias(ret, data);
- g_free(data);
- }
-
-@@ -734,7 +734,7 @@ parse_account(xmlnode *node)
- child = xmlnode_get_child(node, "userinfo");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_account_set_user_info(ret, data);
-+ gaim2_account_set_user_info(ret, data);
- g_free(data);
- }
-
-@@ -742,7 +742,7 @@ parse_account(xmlnode *node)
- child = xmlnode_get_child(node, "buddyicon");
- if ((child != NULL) && ((data = xmlnode_get_data(child)) != NULL))
- {
-- gaim_account_set_buddy_icon(ret, data);
-+ gaim2_account_set_buddy_icon(ret, data);
- g_free(data);
- }
-
-@@ -770,7 +770,7 @@ load_accounts(void)
-
- accounts_loaded = TRUE;
-
-- node = gaim_util_read_xml_from_file("accounts.xml", _("accounts"));
-+ node = gaim2_util_read_xml_from_file("accounts.xml", _("accounts"));
-
- if (node == NULL)
- return;
-@@ -778,9 +778,9 @@ load_accounts(void)
- for (child = xmlnode_get_child(node, "account"); child != NULL;
- child = xmlnode_get_next_twin(child))
- {
-- GaimAccount *new_acct;
-+ Gaim2Account *new_acct;
- new_acct = parse_account(child);
-- gaim_accounts_add(new_acct);
-+ gaim2_accounts_add(new_acct);
- }
-
- xmlnode_free(node);
-@@ -790,7 +790,7 @@ load_accounts(void)
- static void
- delete_setting(void *data)
- {
-- GaimAccountSetting *setting = (GaimAccountSetting *)data;
-+ Gaim2AccountSetting *setting = (Gaim2AccountSetting *)data;
-
- if (setting->ui != NULL)
- g_free(setting->ui);
-@@ -801,28 +801,28 @@ delete_setting(void *data)
- g_free(setting);
- }
-
--GaimAccount *
--gaim_account_new(const char *username, const char *protocol_id)
-+Gaim2Account *
-+gaim2_account_new(const char *username, const char *protocol_id)
- {
-- GaimAccount *account = NULL;
-- GaimPlugin *prpl = NULL;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimStatusType *status_type;
-+ Gaim2Account *account = NULL;
-+ Gaim2Plugin *prpl = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2StatusType *status_type;
-
- g_return_val_if_fail(username != NULL, NULL);
- g_return_val_if_fail(protocol_id != NULL, NULL);
-
-- account = gaim_accounts_find(username, protocol_id);
-+ account = gaim2_accounts_find(username, protocol_id);
-
- if (account != NULL)
- return account;
-
-- account = g_new0(GaimAccount, 1);
-- GAIM_DBUS_REGISTER_POINTER(account, GaimAccount);
-+ account = g_new0(Gaim2Account, 1);
-+ GAIM_DBUS_REGISTER_POINTER(account, Gaim2Account);
-
-- gaim_account_set_username(account, username);
-+ gaim2_account_set_username(account, username);
-
-- gaim_account_set_protocol_id(account, protocol_id);
-+ gaim2_account_set_protocol_id(account, protocol_id);
-
- account->settings = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, delete_setting);
-@@ -832,24 +832,24 @@ gaim_account_new(const char *username, c
- /* 0 is not a valid privacy setting */
- account->perm_deny = GAIM_PRIVACY_ALLOW_ALL;
-
-- account->presence = gaim_presence_new_for_account(account);
-+ account->presence = gaim2_presence_new_for_account(account);
-
-- prpl = gaim_find_prpl(protocol_id);
-+ prpl = gaim2_find_prpl(protocol_id);
-
- if (prpl == NULL)
- return account;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
- if (prpl_info != NULL && prpl_info->status_types != NULL)
-- gaim_account_set_status_types(account, prpl_info->status_types(account));
-+ gaim2_account_set_status_types(account, prpl_info->status_types(account));
-
-- status_type = gaim_account_get_status_type_with_primitive(account, GAIM_STATUS_AVAILABLE);
-+ status_type = gaim2_account_get_status_type_with_primitive(account, GAIM_STATUS_AVAILABLE);
- if (status_type != NULL)
-- gaim_presence_set_status_active(account->presence,
-- gaim_status_type_get_id(status_type),
-+ gaim2_presence_set_status_active(account->presence,
-+ gaim2_status_type_get_id(status_type),
- TRUE);
- else
-- gaim_presence_set_status_active(account->presence,
-+ gaim2_presence_set_status_active(account->presence,
- "offline",
- TRUE);
-
-@@ -857,25 +857,25 @@ gaim_account_new(const char *username, c
- }
-
- void
--gaim_account_destroy(GaimAccount *account)
-+gaim2_account_destroy(Gaim2Account *account)
- {
- GList *l;
-
- g_return_if_fail(account != NULL);
-
-- gaim_debug_info("account", "Destroying account %p\n", account);
-+ gaim2_debug_info("account", "Destroying account %p\n", account);
-
-- if (gaim_account_is_connected(account))
-- gaim_account_disconnect(account);
-+ if (gaim2_account_is_connected(account))
-+ gaim2_account_disconnect(account);
-
-- gaim_debug_info("account", "Continuing to destroy account %p\n", account);
-+ gaim2_debug_info("account", "Continuing to destroy account %p\n", account);
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next)
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next)
- {
-- GaimConversation *conv = (GaimConversation *)l->data;
-+ Gaim2Conversation *conv = (Gaim2Conversation *)l->data;
-
-- if (gaim_conversation_get_account(conv) == account)
-- gaim_conversation_set_account(conv, NULL);
-+ if (gaim2_conversation_get_account(conv) == account)
-+ gaim2_conversation_set_account(conv, NULL);
- }
-
- g_free(account->username);
-@@ -887,80 +887,80 @@ gaim_account_destroy(GaimAccount *accoun
- g_hash_table_destroy(account->settings);
- g_hash_table_destroy(account->ui_settings);
-
-- gaim_account_set_status_types(account, NULL);
-+ gaim2_account_set_status_types(account, NULL);
-
-- gaim_presence_destroy(account->presence);
-+ gaim2_presence_destroy(account->presence);
-
- if(account->system_log)
-- gaim_log_free(account->system_log);
-+ gaim2_log_free(account->system_log);
-
- GAIM_DBUS_UNREGISTER_POINTER(account);
- g_free(account);
- }
-
- void
--gaim_account_register(GaimAccount *account)
-+gaim2_account_register(Gaim2Account *account)
- {
- g_return_if_fail(account != NULL);
-
-- gaim_debug_info("account", "Registering account %s\n",
-- gaim_account_get_username(account));
-+ gaim2_debug_info("account", "Registering account %s\n",
-+ gaim2_account_get_username(account));
-
-- gaim_connection_new(account, TRUE, NULL);
-+ gaim2_connection_new(account, TRUE, NULL);
- }
-
- static void
--request_password_ok_cb(GaimAccount *account, GaimRequestFields *fields)
-+request_password_ok_cb(Gaim2Account *account, Gaim2RequestFields *fields)
- {
- const char *entry;
- gboolean remember;
-
-- entry = gaim_request_fields_get_string(fields, "password");
-- remember = gaim_request_fields_get_bool(fields, "remember");
-+ entry = gaim2_request_fields_get_string(fields, "password");
-+ remember = gaim2_request_fields_get_bool(fields, "remember");
-
- if (!entry || !*entry)
- {
-- gaim_notify_error(account, NULL, _("Password is required to sign on."), NULL);
-+ gaim2_notify_error(account, NULL, _("Password is required to sign on."), NULL);
- return;
- }
-
- if(remember)
-- gaim_account_set_remember_password(account, TRUE);
-+ gaim2_account_set_remember_password(account, TRUE);
-
-- gaim_account_set_password(account, entry);
-+ gaim2_account_set_password(account, entry);
-
-- gaim_connection_new(account, FALSE, entry);
-+ gaim2_connection_new(account, FALSE, entry);
- }
-
- static void
--request_password(GaimAccount *account)
-+request_password(Gaim2Account *account)
- {
- gchar *primary;
- const gchar *username;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-- GaimRequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-+ Gaim2RequestFields *fields;
-
- /* Close any previous password request windows */
-- gaim_request_close_with_handle(account);
-+ gaim2_request_close_with_handle(account);
-
-- username = gaim_account_get_username(account);
-+ username = gaim2_account_get_username(account);
- primary = g_strdup_printf(_("Enter password for %s (%s)"), username,
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_protocol_name(account));
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("password", _("Enter Password"), NULL, FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_string_new("password", _("Enter Password"), NULL, FALSE);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_bool_new("remember", _("Save password"), FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_bool_new("remember", _("Save password"), FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(account,
-+ gaim2_request_fields(account,
- NULL,
- primary,
- NULL,
-@@ -972,107 +972,107 @@ request_password(GaimAccount *account)
- }
-
- void
--gaim_account_connect(GaimAccount *account)
-+gaim2_account_connect(Gaim2Account *account)
- {
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
- const char *password;
-
- g_return_if_fail(account != NULL);
-
-- gaim_debug_info("account", "Connecting to account %s\n",
-- gaim_account_get_username(account));
-+ gaim2_debug_info("account", "Connecting to account %s\n",
-+ gaim2_account_get_username(account));
-
-- if (!gaim_account_get_enabled(account, gaim_core_get_ui()))
-+ if (!gaim2_account_get_enabled(account, gaim2_core_get_ui()))
- return;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
- if (prpl == NULL)
- {
- gchar *message;
-
- message = g_strdup_printf(_("Missing protocol plugin for %s"),
-- gaim_account_get_username(account));
-- gaim_notify_error(account, _("Connection Error"), message, NULL);
-+ gaim2_account_get_username(account));
-+ gaim2_notify_error(account, _("Connection Error"), message, NULL);
- g_free(message);
- return;
- }
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-- password = gaim_account_get_password(account);
-+ password = gaim2_account_get_password(account);
- if ((password == NULL) &&
- !(prpl_info->options & OPT_PROTO_NO_PASSWORD) &&
- !(prpl_info->options & OPT_PROTO_PASSWORD_OPTIONAL))
- request_password(account);
- else
-- gaim_connection_new(account, FALSE, password);
-+ gaim2_connection_new(account, FALSE, password);
- }
-
- void
--gaim_account_disconnect(GaimAccount *account)
-+gaim2_account_disconnect(Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(account != NULL);
-- g_return_if_fail(!gaim_account_is_disconnected(account));
-+ g_return_if_fail(!gaim2_account_is_disconnected(account));
-
-- gaim_debug_info("account", "Disconnecting account %p\n", account);
-+ gaim2_debug_info("account", "Disconnecting account %p\n", account);
-
- account->disconnecting = TRUE;
-
-- gc = gaim_account_get_connection(account);
-- gaim_connection_destroy(gc);
-- if (!gaim_account_get_remember_password(account))
-- gaim_account_set_password(account, NULL);
-- gaim_account_set_connection(account, NULL);
-+ gc = gaim2_account_get_connection(account);
-+ gaim2_connection_destroy(gc);
-+ if (!gaim2_account_get_remember_password(account))
-+ gaim2_account_set_password(account, NULL);
-+ gaim2_account_set_connection(account, NULL);
-
- account->disconnecting = FALSE;
- }
-
- void
--gaim_account_notify_added(GaimAccount *account, const char *remote_user,
-+gaim2_account_notify_added(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *message)
- {
-- GaimAccountUiOps *ui_ops;
-+ Gaim2AccountUiOps *ui_ops;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(remote_user != NULL);
-
-- ui_ops = gaim_accounts_get_ui_ops();
-+ ui_ops = gaim2_accounts_get_ui_ops();
-
- if (ui_ops != NULL && ui_ops->notify_added != NULL)
- ui_ops->notify_added(account, remote_user, id, alias, message);
- }
-
- void
--gaim_account_request_add(GaimAccount *account, const char *remote_user,
-+gaim2_account_request_add(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *message)
- {
-- GaimAccountUiOps *ui_ops;
-+ Gaim2AccountUiOps *ui_ops;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(remote_user != NULL);
-
-- ui_ops = gaim_accounts_get_ui_ops();
-+ ui_ops = gaim2_accounts_get_ui_ops();
-
- if (ui_ops != NULL && ui_ops->request_add != NULL)
- ui_ops->request_add(account, remote_user, id, alias, message);
- }
-
- static void
--change_password_cb(GaimAccount *account, GaimRequestFields *fields)
-+change_password_cb(Gaim2Account *account, Gaim2RequestFields *fields)
- {
- const char *orig_pass, *new_pass_1, *new_pass_2;
-
-- orig_pass = gaim_request_fields_get_string(fields, "password");
-- new_pass_1 = gaim_request_fields_get_string(fields, "new_password_1");
-- new_pass_2 = gaim_request_fields_get_string(fields, "new_password_2");
-+ orig_pass = gaim2_request_fields_get_string(fields, "password");
-+ new_pass_1 = gaim2_request_fields_get_string(fields, "new_password_1");
-+ new_pass_2 = gaim2_request_fields_get_string(fields, "new_password_2");
-
- if (g_utf8_collate(new_pass_1, new_pass_2))
- {
-- gaim_notify_error(account, NULL,
-+ gaim2_notify_error(account, NULL,
- _("New passwords do not match."), NULL);
-
- return;
-@@ -1081,56 +1081,56 @@ change_password_cb(GaimAccount *account,
- if (orig_pass == NULL || new_pass_1 == NULL || new_pass_2 == NULL ||
- *orig_pass == '\0' || *new_pass_1 == '\0' || *new_pass_2 == '\0')
- {
-- gaim_notify_error(account, NULL,
-+ gaim2_notify_error(account, NULL,
- _("Fill out all fields completely."), NULL);
- return;
- }
-
-- gaim_account_change_password(account, orig_pass, new_pass_1);
-+ gaim2_account_change_password(account, orig_pass, new_pass_1);
- }
-
- void
--gaim_account_request_change_password(GaimAccount *account)
-+gaim2_account_request_change_password(Gaim2Account *account)
- {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
- char primary[256];
-
- g_return_if_fail(account != NULL);
-- g_return_if_fail(gaim_account_is_connected(account));
-+ g_return_if_fail(gaim2_account_is_connected(account));
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("password", _("Original password"),
-+ field = gaim2_request_field_string_new("password", _("Original password"),
- NULL, FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("new_password_1",
-+ field = gaim2_request_field_string_new("new_password_1",
- _("New password"),
- NULL, FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("new_password_2",
-+ field = gaim2_request_field_string_new("new_password_2",
- _("New password (again)"),
- NULL, FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
- g_snprintf(primary, sizeof(primary), _("Change password for %s"),
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
-
- /* I'm sticking this somewhere in the code: bologna */
-
-- gaim_request_fields(gaim_account_get_connection(account),
-+ gaim2_request_fields(gaim2_account_get_connection(account),
- NULL,
- primary,
- _("Please enter your current password and your "
-@@ -1142,36 +1142,36 @@ gaim_account_request_change_password(Gai
- }
-
- static void
--set_user_info_cb(GaimAccount *account, const char *user_info)
-+set_user_info_cb(Gaim2Account *account, const char *user_info)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gaim_account_set_user_info(account, user_info);
-+ gaim2_account_set_user_info(account, user_info);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (gc != NULL)
-- serv_set_info(gaim_account_get_connection(account), user_info);
-+ serv_set_info(gaim2_account_get_connection(account), user_info);
- }
-
- void
--gaim_account_request_change_user_info(GaimAccount *account)
-+gaim2_account_request_change_user_info(Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char primary[256];
-
- g_return_if_fail(account != NULL);
-- g_return_if_fail(gaim_account_is_connected(account));
-+ g_return_if_fail(gaim2_account_is_connected(account));
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- g_snprintf(primary, sizeof(primary),
- _("Change user information for %s"),
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
-
-- gaim_request_input(gaim_account_get_connection(account),
-+ gaim2_request_input(gaim2_account_get_connection(account),
- NULL, primary, NULL,
-- gaim_account_get_user_info(account),
-+ gaim2_account_get_user_info(account),
- TRUE, FALSE, ((gc != NULL) &&
- (gc->flags & GAIM_CONNECTION_HTML) ? "html" : NULL),
- _("Save"), G_CALLBACK(set_user_info_cb),
-@@ -1179,7 +1179,7 @@ gaim_account_request_change_user_info(Ga
- }
-
- void
--gaim_account_set_username(GaimAccount *account, const char *username)
-+gaim2_account_set_username(Gaim2Account *account, const char *username)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1190,7 +1190,7 @@ gaim_account_set_username(GaimAccount *a
- }
-
- void
--gaim_account_set_password(GaimAccount *account, const char *password)
-+gaim2_account_set_password(Gaim2Account *account, const char *password)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1202,7 +1202,7 @@ gaim_account_set_password(GaimAccount *a
- }
-
- void
--gaim_account_set_alias(GaimAccount *account, const char *alias)
-+gaim2_account_set_alias(Gaim2Account *account, const char *alias)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1213,7 +1213,7 @@ gaim_account_set_alias(GaimAccount *acco
- }
-
- void
--gaim_account_set_user_info(GaimAccount *account, const char *user_info)
-+gaim2_account_set_user_info(Gaim2Account *account, const char *user_info)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1224,14 +1224,14 @@ gaim_account_set_user_info(GaimAccount *
- }
-
- void
--gaim_account_set_buddy_icon(GaimAccount *account, const char *icon)
-+gaim2_account_set_buddy_icon(Gaim2Account *account, const char *icon)
- {
- g_return_if_fail(account != NULL);
-
- /* Delete an existing icon from the cache. */
- if (account->buddy_icon != NULL && (icon == NULL || strcmp(account->buddy_icon, icon)))
- {
-- const char *dirname = gaim_buddy_icons_get_cache_dir();
-+ const char *dirname = gaim2_buddy_icons_get_cache_dir();
- struct stat st;
-
- if (g_stat(account->buddy_icon, &st) == 0)
-@@ -1255,10 +1255,10 @@ gaim_account_set_buddy_icon(GaimAccount
-
- g_free(account->buddy_icon);
- account->buddy_icon = (icon == NULL ? NULL : g_strdup(icon));
-- if (gaim_account_is_connected(account))
-+ if (gaim2_account_is_connected(account))
- {
-- char *filename = gaim_buddy_icons_get_full_path(icon);
-- serv_set_buddyicon(gaim_account_get_connection(account), filename);
-+ char *filename = gaim2_buddy_icons_get_full_path(icon);
-+ serv_set_buddyicon(gaim2_account_get_connection(account), filename);
- g_free(filename);
- }
-
-@@ -1266,7 +1266,7 @@ gaim_account_set_buddy_icon(GaimAccount
- }
-
- void
--gaim_account_set_protocol_id(GaimAccount *account, const char *protocol_id)
-+gaim2_account_set_protocol_id(Gaim2Account *account, const char *protocol_id)
- {
- g_return_if_fail(account != NULL);
- g_return_if_fail(protocol_id != NULL);
-@@ -1278,7 +1278,7 @@ gaim_account_set_protocol_id(GaimAccount
- }
-
- void
--gaim_account_set_connection(GaimAccount *account, GaimConnection *gc)
-+gaim2_account_set_connection(Gaim2Account *account, Gaim2Connection *gc)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1286,7 +1286,7 @@ gaim_account_set_connection(GaimAccount
- }
-
- void
--gaim_account_set_remember_password(GaimAccount *account, gboolean value)
-+gaim2_account_set_remember_password(Gaim2Account *account, gboolean value)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1296,49 +1296,49 @@ gaim_account_set_remember_password(GaimA
- }
-
- void
--gaim_account_set_check_mail(GaimAccount *account, gboolean value)
-+gaim2_account_set_check_mail(Gaim2Account *account, gboolean value)
- {
- g_return_if_fail(account != NULL);
-
-- gaim_account_set_bool(account, "check-mail", value);
-+ gaim2_account_set_bool(account, "check-mail", value);
- }
-
- void
--gaim_account_set_enabled(GaimAccount *account, const char *ui,
-+gaim2_account_set_enabled(Gaim2Account *account, const char *ui,
- gboolean value)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- gboolean was_enabled = FALSE;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(ui != NULL);
-
-- was_enabled = gaim_account_get_enabled(account, ui);
-+ was_enabled = gaim2_account_get_enabled(account, ui);
-
-- gaim_account_set_ui_bool(account, ui, "auto-login", value);
-- gc = gaim_account_get_connection(account);
-+ gaim2_account_set_ui_bool(account, ui, "auto-login", value);
-+ gc = gaim2_account_get_connection(account);
-
- if(was_enabled && !value)
-- gaim_signal_emit(gaim_accounts_get_handle(), "account-disabled", account);
-+ gaim2_signal_emit(gaim2_accounts_get_handle(), "account-disabled", account);
- else if(!was_enabled && value)
-- gaim_signal_emit(gaim_accounts_get_handle(), "account-enabled", account);
-+ gaim2_signal_emit(gaim2_accounts_get_handle(), "account-enabled", account);
-
- if ((gc != NULL) && (gc->wants_to_die == TRUE))
- return;
-
-- if (value && gaim_presence_is_online(account->presence))
-- gaim_account_connect(account);
-- else if (!value && !gaim_account_is_disconnected(account))
-- gaim_account_disconnect(account);
-+ if (value && gaim2_presence_is_online(account->presence))
-+ gaim2_account_connect(account);
-+ else if (!value && !gaim2_account_is_disconnected(account))
-+ gaim2_account_disconnect(account);
- }
-
- void
--gaim_account_set_proxy_info(GaimAccount *account, GaimProxyInfo *info)
-+gaim2_account_set_proxy_info(Gaim2Account *account, Gaim2ProxyInfo *info)
- {
- g_return_if_fail(account != NULL);
-
- if (account->proxy_info != NULL)
-- gaim_proxy_info_destroy(account->proxy_info);
-+ gaim2_proxy_info_destroy(account->proxy_info);
-
- account->proxy_info = info;
-
-@@ -1346,7 +1346,7 @@ gaim_account_set_proxy_info(GaimAccount
- }
-
- void
--gaim_account_set_status_types(GaimAccount *account, GList *status_types)
-+gaim2_account_set_status_types(Gaim2Account *account, GList *status_types)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1356,7 +1356,7 @@ gaim_account_set_status_types(GaimAccoun
- GList *l;
-
- for (l = account->status_types; l != NULL; l = l->next)
-- gaim_status_type_destroy((GaimStatusType *)l->data);
-+ gaim2_status_type_destroy((Gaim2StatusType *)l->data);
-
- g_list_free(account->status_types);
- }
-@@ -1366,18 +1366,18 @@ gaim_account_set_status_types(GaimAccoun
- }
-
- void
--gaim_account_set_status(GaimAccount *account, const char *status_id,
-+gaim2_account_set_status(Gaim2Account *account, const char *status_id,
- gboolean active, ...)
- {
- va_list args;
-
- va_start(args, active);
-- gaim_account_set_status_vargs(account, status_id, active, args);
-+ gaim2_account_set_status_vargs(account, status_id, active, args);
- va_end(args);
- }
-
- void
--gaim_account_set_status_vargs(GaimAccount *account, const char *status_id,
-+gaim2_account_set_status_vargs(Gaim2Account *account, const char *status_id,
- gboolean active, va_list args)
- {
- GList *attrs = NULL;
-@@ -1393,31 +1393,31 @@ gaim_account_set_status_vargs(GaimAccoun
- attrs = g_list_append(attrs, data);
- }
- }
-- gaim_account_set_status_list(account, status_id, active, attrs);
-+ gaim2_account_set_status_list(account, status_id, active, attrs);
- g_list_free(attrs);
- }
-
- void
--gaim_account_set_status_list(GaimAccount *account, const char *status_id,
-+gaim2_account_set_status_list(Gaim2Account *account, const char *status_id,
- gboolean active, GList *attrs)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(status_id != NULL);
-
-- status = gaim_account_get_status(account, status_id);
-+ status = gaim2_account_get_status(account, status_id);
- if (status == NULL)
- {
-- gaim_debug_error("account",
-+ gaim2_debug_error("account",
- "Invalid status ID %s for account %s (%s)\n",
-- status_id, gaim_account_get_username(account),
-- gaim_account_get_protocol_id(account));
-+ status_id, gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_id(account));
- return;
- }
-
-- if (active || gaim_status_is_independent(status))
-- gaim_status_set_active_with_attrs_list(status, active, attrs);
-+ if (active || gaim2_status_is_independent(status))
-+ gaim2_status_set_active_with_attrs_list(status, active, attrs);
-
- /*
- * Our current statuses are saved to accounts.xml (so that when we
-@@ -1427,7 +1427,7 @@ gaim_account_set_status_list(GaimAccount
- }
-
- void
--gaim_account_clear_settings(GaimAccount *account)
-+gaim2_account_clear_settings(Gaim2Account *account)
- {
- g_return_if_fail(account != NULL);
-
-@@ -1438,14 +1438,14 @@ gaim_account_clear_settings(GaimAccount
- }
-
- void
--gaim_account_set_int(GaimAccount *account, const char *name, int value)
-+gaim2_account_set_int(Gaim2Account *account, const char *name, int value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(name != NULL);
-
-- setting = g_new0(GaimAccountSetting, 1);
-+ setting = g_new0(Gaim2AccountSetting, 1);
-
- setting->type = GAIM_PREF_INT;
- setting->value.integer = value;
-@@ -1456,15 +1456,15 @@ gaim_account_set_int(GaimAccount *accoun
- }
-
- void
--gaim_account_set_string(GaimAccount *account, const char *name,
-+gaim2_account_set_string(Gaim2Account *account, const char *name,
- const char *value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(name != NULL);
-
-- setting = g_new0(GaimAccountSetting, 1);
-+ setting = g_new0(Gaim2AccountSetting, 1);
-
- setting->type = GAIM_PREF_STRING;
- setting->value.string = g_strdup(value);
-@@ -1475,14 +1475,14 @@ gaim_account_set_string(GaimAccount *acc
- }
-
- void
--gaim_account_set_bool(GaimAccount *account, const char *name, gboolean value)
-+gaim2_account_set_bool(Gaim2Account *account, const char *name, gboolean value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(name != NULL);
-
-- setting = g_new0(GaimAccountSetting, 1);
-+ setting = g_new0(Gaim2AccountSetting, 1);
-
- setting->type = GAIM_PREF_BOOLEAN;
- setting->value.bool = value;
-@@ -1493,7 +1493,7 @@ gaim_account_set_bool(GaimAccount *accou
- }
-
- static GHashTable *
--get_ui_settings_table(GaimAccount *account, const char *ui)
-+get_ui_settings_table(Gaim2Account *account, const char *ui)
- {
- GHashTable *table;
-
-@@ -1509,17 +1509,17 @@ get_ui_settings_table(GaimAccount *accou
- }
-
- void
--gaim_account_set_ui_int(GaimAccount *account, const char *ui,
-+gaim2_account_set_ui_int(Gaim2Account *account, const char *ui,
- const char *name, int value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- GHashTable *table;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(ui != NULL);
- g_return_if_fail(name != NULL);
-
-- setting = g_new0(GaimAccountSetting, 1);
-+ setting = g_new0(Gaim2AccountSetting, 1);
-
- setting->type = GAIM_PREF_INT;
- setting->ui = g_strdup(ui);
-@@ -1533,17 +1533,17 @@ gaim_account_set_ui_int(GaimAccount *acc
- }
-
- void
--gaim_account_set_ui_string(GaimAccount *account, const char *ui,
-+gaim2_account_set_ui_string(Gaim2Account *account, const char *ui,
- const char *name, const char *value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- GHashTable *table;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(ui != NULL);
- g_return_if_fail(name != NULL);
-
-- setting = g_new0(GaimAccountSetting, 1);
-+ setting = g_new0(Gaim2AccountSetting, 1);
-
- setting->type = GAIM_PREF_STRING;
- setting->ui = g_strdup(ui);
-@@ -1557,17 +1557,17 @@ gaim_account_set_ui_string(GaimAccount *
- }
-
- void
--gaim_account_set_ui_bool(GaimAccount *account, const char *ui,
-+gaim2_account_set_ui_bool(Gaim2Account *account, const char *ui,
- const char *name, gboolean value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- GHashTable *table;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(ui != NULL);
- g_return_if_fail(name != NULL);
-
-- setting = g_new0(GaimAccountSetting, 1);
-+ setting = g_new0(Gaim2AccountSetting, 1);
-
- setting->type = GAIM_PREF_BOOLEAN;
- setting->ui = g_strdup(ui);
-@@ -1580,40 +1580,40 @@ gaim_account_set_ui_bool(GaimAccount *ac
- schedule_accounts_save();
- }
-
--static GaimConnectionState
--gaim_account_get_state(const GaimAccount *account)
-+static Gaim2ConnectionState
-+gaim2_account_get_state(const Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- g_return_val_if_fail(account != NULL, GAIM_DISCONNECTED);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- if (!gc)
- return GAIM_DISCONNECTED;
-
-- return gaim_connection_get_state(gc);
-+ return gaim2_connection_get_state(gc);
- }
-
- gboolean
--gaim_account_is_connected(const GaimAccount *account)
-+gaim2_account_is_connected(const Gaim2Account *account)
- {
-- return (gaim_account_get_state(account) == GAIM_CONNECTED);
-+ return (gaim2_account_get_state(account) == GAIM_CONNECTED);
- }
-
- gboolean
--gaim_account_is_connecting(const GaimAccount *account)
-+gaim2_account_is_connecting(const Gaim2Account *account)
- {
-- return (gaim_account_get_state(account) == GAIM_CONNECTING);
-+ return (gaim2_account_get_state(account) == GAIM_CONNECTING);
- }
-
- gboolean
--gaim_account_is_disconnected(const GaimAccount *account)
-+gaim2_account_is_disconnected(const Gaim2Account *account)
- {
-- return (gaim_account_get_state(account) == GAIM_DISCONNECTED);
-+ return (gaim2_account_get_state(account) == GAIM_DISCONNECTED);
- }
-
- const char *
--gaim_account_get_username(const GaimAccount *account)
-+gaim2_account_get_username(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1621,7 +1621,7 @@ gaim_account_get_username(const GaimAcco
- }
-
- const char *
--gaim_account_get_password(const GaimAccount *account)
-+gaim2_account_get_password(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1629,7 +1629,7 @@ gaim_account_get_password(const GaimAcco
- }
-
- const char *
--gaim_account_get_alias(const GaimAccount *account)
-+gaim2_account_get_alias(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1637,7 +1637,7 @@ gaim_account_get_alias(const GaimAccount
- }
-
- const char *
--gaim_account_get_user_info(const GaimAccount *account)
-+gaim2_account_get_user_info(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1645,7 +1645,7 @@ gaim_account_get_user_info(const GaimAcc
- }
-
- const char *
--gaim_account_get_buddy_icon(const GaimAccount *account)
-+gaim2_account_get_buddy_icon(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1653,7 +1653,7 @@ gaim_account_get_buddy_icon(const GaimAc
- }
-
- const char *
--gaim_account_get_protocol_id(const GaimAccount *account)
-+gaim2_account_get_protocol_id(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1661,19 +1661,19 @@ gaim_account_get_protocol_id(const GaimA
- }
-
- const char *
--gaim_account_get_protocol_name(const GaimAccount *account)
-+gaim2_account_get_protocol_name(const Gaim2Account *account)
- {
-- GaimPlugin *p;
-+ Gaim2Plugin *p;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- p = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ p = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- return ((p && p->info->name) ? _(p->info->name) : _("Unknown"));
- }
-
--GaimConnection *
--gaim_account_get_connection(const GaimAccount *account)
-+Gaim2Connection *
-+gaim2_account_get_connection(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1681,7 +1681,7 @@ gaim_account_get_connection(const GaimAc
- }
-
- gboolean
--gaim_account_get_remember_password(const GaimAccount *account)
-+gaim2_account_get_remember_password(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, FALSE);
-
-@@ -1689,86 +1689,86 @@ gaim_account_get_remember_password(const
- }
-
- gboolean
--gaim_account_get_check_mail(const GaimAccount *account)
-+gaim2_account_get_check_mail(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, FALSE);
-
-- return gaim_account_get_bool(account, "check-mail", FALSE);
-+ return gaim2_account_get_bool(account, "check-mail", FALSE);
- }
-
- gboolean
--gaim_account_get_enabled(const GaimAccount *account, const char *ui)
-+gaim2_account_get_enabled(const Gaim2Account *account, const char *ui)
- {
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(ui != NULL, FALSE);
-
-- return gaim_account_get_ui_bool(account, ui, "auto-login", FALSE);
-+ return gaim2_account_get_ui_bool(account, ui, "auto-login", FALSE);
- }
-
--GaimProxyInfo *
--gaim_account_get_proxy_info(const GaimAccount *account)
-+Gaim2ProxyInfo *
-+gaim2_account_get_proxy_info(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
- return account->proxy_info;
- }
-
--GaimStatus *
--gaim_account_get_active_status(const GaimAccount *account)
-+Gaim2Status *
-+gaim2_account_get_active_status(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-- return gaim_presence_get_active_status(account->presence);
-+ return gaim2_presence_get_active_status(account->presence);
- }
-
--GaimStatus *
--gaim_account_get_status(const GaimAccount *account, const char *status_id)
-+Gaim2Status *
-+gaim2_account_get_status(const Gaim2Account *account, const char *status_id)
- {
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(status_id != NULL, NULL);
-
-- return gaim_presence_get_status(account->presence, status_id);
-+ return gaim2_presence_get_status(account->presence, status_id);
- }
-
--GaimStatusType *
--gaim_account_get_status_type(const GaimAccount *account, const char *id)
-+Gaim2StatusType *
-+gaim2_account_get_status_type(const Gaim2Account *account, const char *id)
- {
- const GList *l;
-
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(id != NULL, NULL);
-
-- for (l = gaim_account_get_status_types(account); l != NULL; l = l->next)
-+ for (l = gaim2_account_get_status_types(account); l != NULL; l = l->next)
- {
-- GaimStatusType *status_type = (GaimStatusType *)l->data;
-+ Gaim2StatusType *status_type = (Gaim2StatusType *)l->data;
-
-- if (!strcmp(gaim_status_type_get_id(status_type), id))
-+ if (!strcmp(gaim2_status_type_get_id(status_type), id))
- return status_type;
- }
-
- return NULL;
- }
-
--GaimStatusType *
--gaim_account_get_status_type_with_primitive(const GaimAccount *account, GaimStatusPrimitive primitive)
-+Gaim2StatusType *
-+gaim2_account_get_status_type_with_primitive(const Gaim2Account *account, Gaim2StatusPrimitive primitive)
- {
- const GList *l;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- for (l = gaim_account_get_status_types(account); l != NULL; l = l->next)
-+ for (l = gaim2_account_get_status_types(account); l != NULL; l = l->next)
- {
-- GaimStatusType *status_type = (GaimStatusType *)l->data;
-+ Gaim2StatusType *status_type = (Gaim2StatusType *)l->data;
-
-- if (gaim_status_type_get_primitive(status_type) == primitive)
-+ if (gaim2_status_type_get_primitive(status_type) == primitive)
- return status_type;
- }
-
- return NULL;
- }
-
--GaimPresence *
--gaim_account_get_presence(const GaimAccount *account)
-+Gaim2Presence *
-+gaim2_account_get_presence(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1776,17 +1776,17 @@ gaim_account_get_presence(const GaimAcco
- }
-
- gboolean
--gaim_account_is_status_active(const GaimAccount *account,
-+gaim2_account_is_status_active(const Gaim2Account *account,
- const char *status_id)
- {
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(status_id != NULL, FALSE);
-
-- return gaim_presence_is_status_active(account->presence, status_id);
-+ return gaim2_presence_is_status_active(account->presence, status_id);
- }
-
- const GList *
--gaim_account_get_status_types(const GaimAccount *account)
-+gaim2_account_get_status_types(const Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
-@@ -1794,10 +1794,10 @@ gaim_account_get_status_types(const Gaim
- }
-
- int
--gaim_account_get_int(const GaimAccount *account, const char *name,
-+gaim2_account_get_int(const Gaim2Account *account, const char *name,
- int default_value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
-
- g_return_val_if_fail(account != NULL, default_value);
- g_return_val_if_fail(name != NULL, default_value);
-@@ -1813,10 +1813,10 @@ gaim_account_get_int(const GaimAccount *
- }
-
- const char *
--gaim_account_get_string(const GaimAccount *account, const char *name,
-+gaim2_account_get_string(const Gaim2Account *account, const char *name,
- const char *default_value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
-
- g_return_val_if_fail(account != NULL, default_value);
- g_return_val_if_fail(name != NULL, default_value);
-@@ -1832,10 +1832,10 @@ gaim_account_get_string(const GaimAccoun
- }
-
- gboolean
--gaim_account_get_bool(const GaimAccount *account, const char *name,
-+gaim2_account_get_bool(const Gaim2Account *account, const char *name,
- gboolean default_value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
-
- g_return_val_if_fail(account != NULL, default_value);
- g_return_val_if_fail(name != NULL, default_value);
-@@ -1851,10 +1851,10 @@ gaim_account_get_bool(const GaimAccount
- }
-
- int
--gaim_account_get_ui_int(const GaimAccount *account, const char *ui,
-+gaim2_account_get_ui_int(const Gaim2Account *account, const char *ui,
- const char *name, int default_value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- GHashTable *table;
-
- g_return_val_if_fail(account != NULL, default_value);
-@@ -1873,10 +1873,10 @@ gaim_account_get_ui_int(const GaimAccoun
- }
-
- const char *
--gaim_account_get_ui_string(const GaimAccount *account, const char *ui,
-+gaim2_account_get_ui_string(const Gaim2Account *account, const char *ui,
- const char *name, const char *default_value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- GHashTable *table;
-
- g_return_val_if_fail(account != NULL, default_value);
-@@ -1895,10 +1895,10 @@ gaim_account_get_ui_string(const GaimAcc
- }
-
- gboolean
--gaim_account_get_ui_bool(const GaimAccount *account, const char *ui,
-+gaim2_account_get_ui_bool(const Gaim2Account *account, const char *ui,
- const char *name, gboolean default_value)
- {
-- GaimAccountSetting *setting;
-+ Gaim2AccountSetting *setting;
- GHashTable *table;
-
- g_return_val_if_fail(account != NULL, default_value);
-@@ -1916,20 +1916,20 @@ gaim_account_get_ui_bool(const GaimAccou
- return setting->value.bool;
- }
-
--GaimLog *
--gaim_account_get_log(GaimAccount *account)
-+Gaim2Log *
-+gaim2_account_get_log(Gaim2Account *account)
- {
- g_return_val_if_fail(account != NULL, NULL);
-
- if(!account->system_log){
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- int login_time;
-
-- presence = gaim_account_get_presence(account);
-- login_time = gaim_presence_get_login_time(presence);
-+ presence = gaim2_account_get_presence(account);
-+ login_time = gaim2_presence_get_login_time(presence);
-
-- account->system_log = gaim_log_new(GAIM_LOG_SYSTEM,
-- gaim_account_get_username(account), account, NULL,
-+ account->system_log = gaim2_log_new(GAIM_LOG_SYSTEM,
-+ gaim2_account_get_username(account), account, NULL,
- (login_time != 0) ? login_time : time(NULL));
- }
-
-@@ -1937,45 +1937,45 @@ gaim_account_get_log(GaimAccount *accoun
- }
-
- void
--gaim_account_destroy_log(GaimAccount *account)
-+gaim2_account_destroy_log(Gaim2Account *account)
- {
- g_return_if_fail(account != NULL);
-
- if(account->system_log){
-- gaim_log_free(account->system_log);
-+ gaim2_log_free(account->system_log);
- account->system_log = NULL;
- }
- }
-
- void
--gaim_account_add_buddy(GaimAccount *account, GaimBuddy *buddy)
-+gaim2_account_add_buddy(Gaim2Account *account, Gaim2Buddy *buddy)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info != NULL && g_list_find(gaim_connections_get_all(), gc) &&
-+ if (prpl_info != NULL && g_list_find(gaim2_connections_get_all(), gc) &&
- prpl_info->add_buddy != NULL)
-- prpl_info->add_buddy(gc, buddy, gaim_buddy_get_group(buddy));
-+ prpl_info->add_buddy(gc, buddy, gaim2_buddy_get_group(buddy));
- }
-
- void
--gaim_account_add_buddies(GaimAccount *account, GList *buddies)
-+gaim2_account_add_buddies(Gaim2Account *account, GList *buddies)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc)) {
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc)) {
- GList *cur, *groups = NULL;
-
- /* Make a list of what group each buddy is in */
- for (cur = buddies; cur != NULL; cur = cur->next) {
-- GaimBlistNode *node = cur->data;
-+ Gaim2BlistNode *node = cur->data;
- groups = g_list_append(groups, node->parent->parent);
- }
-
-@@ -1996,39 +1996,39 @@ gaim_account_add_buddies(GaimAccount *ac
- }
-
- void
--gaim_account_remove_buddy(GaimAccount *account, GaimBuddy *buddy,
-- GaimGroup *group)
-+gaim2_account_remove_buddy(Gaim2Account *account, Gaim2Buddy *buddy,
-+ Gaim2Group *group)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc) && prpl_info->remove_buddy)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc) && prpl_info->remove_buddy)
- prpl_info->remove_buddy(gc, buddy, group);
- }
-
- void
--gaim_account_remove_buddies(GaimAccount *account, GList *buddies, GList *groups)
-+gaim2_account_remove_buddies(Gaim2Account *account, GList *buddies, GList *groups)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
-- if (!g_list_find(gaim_connections_get_all(), gc))
-+ if (!g_list_find(gaim2_connections_get_all(), gc))
- return;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc)) {
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc)) {
- if (prpl_info->remove_buddies)
- prpl_info->remove_buddies(gc, buddies, groups);
- else {
- GList *curb = buddies;
- GList *curg = groups;
- while ((curb != NULL) && (curg != NULL)) {
-- gaim_account_remove_buddy(account, curb->data, curg->data);
-+ gaim2_account_remove_buddy(account, curb->data, curg->data);
- curb = curb->next;
- curg = curg->next;
- }
-@@ -2037,43 +2037,43 @@ gaim_account_remove_buddies(GaimAccount
- }
-
- void
--gaim_account_remove_group(GaimAccount *account, GaimGroup *group)
-+gaim2_account_remove_group(Gaim2Account *account, Gaim2Group *group)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc) && prpl_info->remove_group)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc) && prpl_info->remove_group)
- prpl_info->remove_group(gc, group);
- }
-
- void
--gaim_account_change_password(GaimAccount *account, const char *orig_pw,
-+gaim2_account_change_password(Gaim2Account *account, const char *orig_pw,
- const char *new_pw)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
-- gaim_account_set_password(account, new_pw);
-+ gaim2_account_set_password(account, new_pw);
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc) && prpl_info->change_passwd)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc) && prpl_info->change_passwd)
- prpl_info->change_passwd(gc, orig_pw, new_pw);
- }
-
--gboolean gaim_account_supports_offline_message(GaimAccount *account, GaimBuddy *buddy)
-+gboolean gaim2_account_supports_offline_message(Gaim2Account *account, Gaim2Buddy *buddy)
- {
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- g_return_val_if_fail(account, FALSE);
- g_return_val_if_fail(buddy, FALSE);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- if (gc == NULL)
- return FALSE;
-
-@@ -2085,7 +2085,7 @@ gboolean gaim_account_supports_offline_m
- }
-
- void
--gaim_accounts_add(GaimAccount *account)
-+gaim2_accounts_add(Gaim2Account *account)
- {
- g_return_if_fail(account != NULL);
-
-@@ -2096,11 +2096,11 @@ gaim_accounts_add(GaimAccount *account)
-
- schedule_accounts_save();
-
-- gaim_signal_emit(gaim_accounts_get_handle(), "account-added", account);
-+ gaim2_signal_emit(gaim2_accounts_get_handle(), "account-added", account);
- }
-
- void
--gaim_accounts_remove(GaimAccount *account)
-+gaim2_accounts_remove(Gaim2Account *account)
- {
- g_return_if_fail(account != NULL);
-
-@@ -2108,64 +2108,64 @@ gaim_accounts_remove(GaimAccount *accoun
-
- schedule_accounts_save();
-
-- gaim_signal_emit(gaim_accounts_get_handle(), "account-removed", account);
-+ gaim2_signal_emit(gaim2_accounts_get_handle(), "account-removed", account);
- }
-
- void
--gaim_accounts_delete(GaimAccount *account)
-+gaim2_accounts_delete(Gaim2Account *account)
- {
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
- g_return_if_fail(account != NULL);
-
-- gaim_notify_close_with_handle(account);
-- gaim_request_close_with_handle(account);
-+ gaim2_notify_close_with_handle(account);
-+ gaim2_request_close_with_handle(account);
-
-- gaim_accounts_remove(account);
-+ gaim2_accounts_remove(account);
-
- /* Remove this account's buddies */
-- for (gnode = gaim_get_blist()->root; gnode != NULL; gnode = gnode->next) {
-+ for (gnode = gaim2_get_blist()->root; gnode != NULL; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-
- cnode = gnode->child;
- while (cnode) {
-- GaimBlistNode *cnode_next = cnode->next;
-+ Gaim2BlistNode *cnode_next = cnode->next;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(cnode)) {
- bnode = cnode->child;
- while (bnode) {
-- GaimBlistNode *bnode_next = bnode->next;
-+ Gaim2BlistNode *bnode_next = bnode->next;
-
- if (GAIM_BLIST_NODE_IS_BUDDY(bnode)) {
-- GaimBuddy *b = (GaimBuddy *)bnode;
-+ Gaim2Buddy *b = (Gaim2Buddy *)bnode;
-
- if (b->account == account)
-- gaim_blist_remove_buddy(b);
-+ gaim2_blist_remove_buddy(b);
- }
- bnode = bnode_next;
- }
- } else if (GAIM_BLIST_NODE_IS_CHAT(cnode)) {
-- GaimChat *c = (GaimChat *)cnode;
-+ Gaim2Chat *c = (Gaim2Chat *)cnode;
-
- if (c->account == account)
-- gaim_blist_remove_chat(c);
-+ gaim2_blist_remove_chat(c);
- }
- cnode = cnode_next;
- }
- }
-
- /* Remove this account's pounces */
-- gaim_pounce_destroy_all_by_account(account);
-+ gaim2_pounce_destroy_all_by_account(account);
-
- /* This will cause the deletion of an old buddy icon. */
-- gaim_account_set_buddy_icon(account, NULL);
-+ gaim2_account_set_buddy_icon(account, NULL);
-
-- gaim_account_destroy(account);
-+ gaim2_account_destroy(account);
- }
-
- void
--gaim_accounts_reorder(GaimAccount *account, gint new_index)
-+gaim2_accounts_reorder(Gaim2Account *account, gint new_index)
- {
- gint index;
- GList *l;
-@@ -2176,9 +2176,9 @@ gaim_accounts_reorder(GaimAccount *accou
- index = g_list_index(accounts, account);
-
- if (index == -1) {
-- gaim_debug_error("account",
-+ gaim2_debug_error("account",
- "Unregistered account (%s) discovered during reorder!\n",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- return;
- }
-
-@@ -2197,21 +2197,21 @@ gaim_accounts_reorder(GaimAccount *accou
- }
-
- GList *
--gaim_accounts_get_all(void)
-+gaim2_accounts_get_all(void)
- {
- return accounts;
- }
-
- GList *
--gaim_accounts_get_all_active(void)
-+gaim2_accounts_get_all_active(void)
- {
- GList *list = NULL;
-- GList *all = gaim_accounts_get_all();
-+ GList *all = gaim2_accounts_get_all();
-
- while (all != NULL) {
-- GaimAccount *account = all->data;
-+ Gaim2Account *account = all->data;
-
-- if (gaim_account_get_enabled(account, gaim_core_get_ui()))
-+ if (gaim2_account_get_enabled(account, gaim2_core_get_ui()))
- list = g_list_append(list, account);
-
- all = all->next;
-@@ -2220,21 +2220,21 @@ gaim_accounts_get_all_active(void)
- return list;
- }
-
--GaimAccount *
--gaim_accounts_find(const char *name, const char *protocol_id)
-+Gaim2Account *
-+gaim2_accounts_find(const char *name, const char *protocol_id)
- {
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- GList *l;
- char *who;
-
- g_return_val_if_fail(name != NULL, NULL);
-
-- who = g_strdup(gaim_normalize(NULL, name));
-+ who = g_strdup(gaim2_normalize(NULL, name));
-
-- for (l = gaim_accounts_get_all(); l != NULL; l = l->next) {
-- account = (GaimAccount *)l->data;
-+ for (l = gaim2_accounts_get_all(); l != NULL; l = l->next) {
-+ account = (Gaim2Account *)l->data;
-
-- if (!strcmp(gaim_normalize(NULL, gaim_account_get_username(account)), who) &&
-+ if (!strcmp(gaim2_normalize(NULL, gaim2_account_get_username(account)), who) &&
- (!protocol_id || !strcmp(account->protocol_id, protocol_id))) {
-
- break;
-@@ -2249,36 +2249,36 @@ gaim_accounts_find(const char *name, con
- }
-
- void
--gaim_accounts_restore_previous_statuses()
-+gaim2_accounts_restore_previous_statuses()
- {
- GList *l;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- for (l = gaim_accounts_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_accounts_get_all(); l != NULL; l = l->next)
- {
-- account = (GaimAccount *)l->data;
-- if (gaim_account_get_enabled(account, gaim_core_get_ui()) &&
-- (gaim_presence_is_online(account->presence)))
-+ account = (Gaim2Account *)l->data;
-+ if (gaim2_account_get_enabled(account, gaim2_core_get_ui()) &&
-+ (gaim2_presence_is_online(account->presence)))
- {
-- gaim_account_connect(account);
-+ gaim2_account_connect(account);
- }
- }
- }
-
- void
--gaim_accounts_set_ui_ops(GaimAccountUiOps *ops)
-+gaim2_accounts_set_ui_ops(Gaim2AccountUiOps *ops)
- {
- account_ui_ops = ops;
- }
-
--GaimAccountUiOps *
--gaim_accounts_get_ui_ops(void)
-+Gaim2AccountUiOps *
-+gaim2_accounts_get_ui_ops(void)
- {
- return account_ui_ops;
- }
-
- void *
--gaim_accounts_get_handle(void)
-+gaim2_accounts_get_handle(void)
- {
- static int handle;
-
-@@ -2286,52 +2286,52 @@ gaim_accounts_get_handle(void)
- }
-
- void
--gaim_accounts_init(void)
-+gaim2_accounts_init(void)
- {
-- void *handle = gaim_accounts_get_handle();
-+ void *handle = gaim2_accounts_get_handle();
-
-- gaim_signal_register(handle, "account-connecting",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "account-connecting",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT));
-
-- gaim_signal_register(handle, "account-disabled",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "account-disabled",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT));
-
-- gaim_signal_register(handle, "account-enabled",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "account-enabled",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT));
-
-- gaim_signal_register(handle, "account-setting-info",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "account-setting-info",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "account-set-info",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "account-set-info",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "account-added",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE, GAIM_SUBTYPE_ACCOUNT));
--
-- gaim_signal_register(handle, "account-removed",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE, GAIM_SUBTYPE_ACCOUNT));
--
-- gaim_signal_register(handle, "account-status-changed",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "account-added",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE, GAIM_SUBTYPE_ACCOUNT));
-+
-+ gaim2_signal_register(handle, "account-removed",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE, GAIM_SUBTYPE_ACCOUNT));
-+
-+ gaim2_signal_register(handle, "account-status-changed",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_STATUS),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_STATUS));
-
- load_accounts();
-@@ -2339,14 +2339,14 @@ gaim_accounts_init(void)
- }
-
- void
--gaim_accounts_uninit(void)
-+gaim2_accounts_uninit(void)
- {
- if (save_timer != 0)
- {
-- gaim_timeout_remove(save_timer);
-+ gaim2_timeout_remove(save_timer);
- save_timer = 0;
- sync_accounts();
- }
-
-- gaim_signals_unregister_by_instance(gaim_accounts_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_accounts_get_handle());
- }
-diff -prNu ./src/account.h ./src/account.h
---- ./src/account.h 2005-12-23 20:25:42.000000000 +0100
-+++ ./src/account.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file account.h Account API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -29,10 +29,10 @@
-
- #include <glib.h>
-
--typedef struct _GaimAccountUiOps GaimAccountUiOps;
--typedef struct _GaimAccount GaimAccount;
-+typedef struct _Gaim2AccountUiOps Gaim2AccountUiOps;
-+typedef struct _Gaim2Account Gaim2Account;
-
--typedef gboolean (*GaimFilterAccountFunc)(GaimAccount *account);
-+typedef gboolean (*Gaim2FilterAccountFunc)(Gaim2Account *account);
-
- #include "connection.h"
- #include "log.h"
-@@ -40,20 +40,20 @@ typedef gboolean (*GaimFilterAccountFunc
- #include "prpl.h"
- #include "status.h"
-
--struct _GaimAccountUiOps
-+struct _Gaim2AccountUiOps
- {
- /* A buddy we already have added us to their buddy list. */
-- void (*notify_added)(GaimAccount *account, const char *remote_user,
-+ void (*notify_added)(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *message);
-- void (*status_changed)(GaimAccount *account, GaimStatus *status);
-+ void (*status_changed)(Gaim2Account *account, Gaim2Status *status);
- /* Someone we don't have on our list added us. Will prompt to add them. */
-- void (*request_add)(GaimAccount *account, const char *remote_user,
-+ void (*request_add)(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *message);
- };
-
--struct _GaimAccount
-+struct _Gaim2Account
- {
- char *username; /**< The username. */
- char *alias; /**< The current alias. */
-@@ -66,13 +66,13 @@ struct _GaimAccount
-
- char *protocol_id; /**< The ID of the protocol. */
-
-- GaimConnection *gc; /**< The connection handle. */
-+ Gaim2Connection *gc; /**< The connection handle. */
- gboolean disconnecting; /**< The account is currently disconnecting */
-
- GHashTable *settings; /**< Protocol-specific settings. */
- GHashTable *ui_settings; /**< UI-specific settings. */
-
-- GaimProxyInfo *proxy_info; /**< Proxy information. This will be set */
-+ Gaim2ProxyInfo *proxy_info; /**< Proxy information. This will be set */
- /* to NULL when the account inherits */
- /* proxy settings from global prefs. */
-
-@@ -82,8 +82,8 @@ struct _GaimAccount
-
- GList *status_types; /**< Status types. */
-
-- GaimPresence *presence; /**< Presence. */
-- GaimLog *system_log; /**< The system log */
-+ Gaim2Presence *presence; /**< Presence. */
-+ Gaim2Log *system_log; /**< The system log */
-
- void *ui_data; /**< The UI can put data here. */
- };
-@@ -105,35 +105,35 @@ extern "C" {
- *
- * @return The new account.
- */
--GaimAccount *gaim_account_new(const char *username, const char *protocol_id);
-+Gaim2Account *gaim2_account_new(const char *username, const char *protocol_id);
-
- /**
- * Destroys an account.
- *
- * @param account The account to destroy.
- */
--void gaim_account_destroy(GaimAccount *account);
-+void gaim2_account_destroy(Gaim2Account *account);
-
- /**
- * Connects to an account.
- *
- * @param account The account to connect to.
- */
--void gaim_account_connect(GaimAccount *account);
-+void gaim2_account_connect(Gaim2Account *account);
-
- /**
- * Registers an account.
- *
- * @param account The account to register.
- */
--void gaim_account_register(GaimAccount *account);
-+void gaim2_account_register(Gaim2Account *account);
-
- /**
- * Disconnects from an account.
- *
- * @param account The account to disconnect from.
- */
--void gaim_account_disconnect(GaimAccount *account);
-+void gaim2_account_disconnect(Gaim2Account *account);
-
- /**
- * Notifies the user that the account was added to a remote user's
-@@ -148,7 +148,7 @@ void gaim_account_disconnect(GaimAccount
- * @param alias The optional alias of the user.
- * @param message The optional message sent from the user adding you.
- */
--void gaim_account_notify_added(GaimAccount *account, const char *remote_user,
-+void gaim2_account_notify_added(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *message);
-
-@@ -167,7 +167,7 @@ void gaim_account_notify_added(GaimAccou
- * @param alias The optional alias of the user.
- * @param message The optional message sent from the user adding you.
- */
--void gaim_account_request_add(GaimAccount *account, const char *remote_user,
-+void gaim2_account_request_add(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *message);
- /**
-@@ -175,7 +175,7 @@ void gaim_account_request_add(GaimAccoun
- *
- * @param account The account to change the password on.
- */
--void gaim_account_request_change_password(GaimAccount *account);
-+void gaim2_account_request_change_password(Gaim2Account *account);
-
- /**
- * Requests information from the user to change the account's
-@@ -183,7 +183,7 @@ void gaim_account_request_change_passwor
- *
- * @param account The account to change the user information on.
- */
--void gaim_account_request_change_user_info(GaimAccount *account);
-+void gaim2_account_request_change_user_info(Gaim2Account *account);
-
- /**
- * Sets the account's username.
-@@ -191,7 +191,7 @@ void gaim_account_request_change_user_in
- * @param account The account.
- * @param username The username.
- */
--void gaim_account_set_username(GaimAccount *account, const char *username);
-+void gaim2_account_set_username(Gaim2Account *account, const char *username);
-
- /**
- * Sets the account's password.
-@@ -199,7 +199,7 @@ void gaim_account_set_username(GaimAccou
- * @param account The account.
- * @param password The password.
- */
--void gaim_account_set_password(GaimAccount *account, const char *password);
-+void gaim2_account_set_password(Gaim2Account *account, const char *password);
-
- /**
- * Sets the account's alias.
-@@ -207,7 +207,7 @@ void gaim_account_set_password(GaimAccou
- * @param account The account.
- * @param alias The alias.
- */
--void gaim_account_set_alias(GaimAccount *account, const char *alias);
-+void gaim2_account_set_alias(Gaim2Account *account, const char *alias);
-
- /**
- * Sets the account's user information
-@@ -215,7 +215,7 @@ void gaim_account_set_alias(GaimAccount
- * @param account The account.
- * @param user_info The user information.
- */
--void gaim_account_set_user_info(GaimAccount *account, const char *user_info);
-+void gaim2_account_set_user_info(Gaim2Account *account, const char *user_info);
-
- /**
- * Sets the account's buddy icon.
-@@ -223,7 +223,7 @@ void gaim_account_set_user_info(GaimAcco
- * @param account The account.
- * @param icon The buddy icon file.
- */
--void gaim_account_set_buddy_icon(GaimAccount *account, const char *icon);
-+void gaim2_account_set_buddy_icon(Gaim2Account *account, const char *icon);
-
- /**
- * Sets the account's protocol ID.
-@@ -231,7 +231,7 @@ void gaim_account_set_buddy_icon(GaimAcc
- * @param account The account.
- * @param protocol_id The protocol ID.
- */
--void gaim_account_set_protocol_id(GaimAccount *account,
-+void gaim2_account_set_protocol_id(Gaim2Account *account,
- const char *protocol_id);
-
- /**
-@@ -240,7 +240,7 @@ void gaim_account_set_protocol_id(GaimAc
- * @param account The account.
- * @param gc The connection.
- */
--void gaim_account_set_connection(GaimAccount *account, GaimConnection *gc);
-+void gaim2_account_set_connection(Gaim2Account *account, Gaim2Connection *gc);
-
- /**
- * Sets whether or not this account should save its password.
-@@ -248,7 +248,7 @@ void gaim_account_set_connection(GaimAcc
- * @param account The account.
- * @param value @c TRUE if it should remember the password.
- */
--void gaim_account_set_remember_password(GaimAccount *account, gboolean value);
-+void gaim2_account_set_remember_password(Gaim2Account *account, gboolean value);
-
- /**
- * Sets whether or not this account should check for mail.
-@@ -256,7 +256,7 @@ void gaim_account_set_remember_password(
- * @param account The account.
- * @param value @c TRUE if it should check for mail.
- */
--void gaim_account_set_check_mail(GaimAccount *account, gboolean value);
-+void gaim2_account_set_check_mail(Gaim2Account *account, gboolean value);
-
- /**
- * Sets whether or not this account is enabled for the specified
-@@ -266,7 +266,7 @@ void gaim_account_set_check_mail(GaimAcc
- * @param ui The UI.
- * @param value @c TRUE if it is enabled.
- */
--void gaim_account_set_enabled(GaimAccount *account, const char *ui,
-+void gaim2_account_set_enabled(Gaim2Account *account, const char *ui,
- gboolean value);
-
- /**
-@@ -275,7 +275,7 @@ void gaim_account_set_enabled(GaimAccoun
- * @param account The account.
- * @param info The proxy information.
- */
--void gaim_account_set_proxy_info(GaimAccount *account, GaimProxyInfo *info);
-+void gaim2_account_set_proxy_info(Gaim2Account *account, Gaim2ProxyInfo *info);
-
- /**
- * Sets the account's status types.
-@@ -283,12 +283,12 @@ void gaim_account_set_proxy_info(GaimAcc
- * @param account The account.
- * @param status_types The list of status types.
- */
--void gaim_account_set_status_types(GaimAccount *account, GList *status_types);
-+void gaim2_account_set_status_types(Gaim2Account *account, GList *status_types);
-
- /**
- * Activates or deactivates a status. All changes to the statuses of
-- * an account go through this function or gaim_account_set_status_vargs
-- * or gaim_account_set_status_list.
-+ * an account go through this function or gaim2_account_set_status_vargs
-+ * or gaim2_account_set_status_list.
- *
- * Only independent statuses can be deactivated with this. To deactivate
- * an exclusive status, activate a different (and exclusive?) status.
-@@ -299,14 +299,14 @@ void gaim_account_set_status_types(GaimA
- * @param ... Optional NULL-terminated attributes passed for the
- * new status, in an id, value pair.
- */
--void gaim_account_set_status(GaimAccount *account, const char *status_id,
-+void gaim2_account_set_status(Gaim2Account *account, const char *status_id,
- gboolean active, ...);
-
-
- /**
- * Activates or deactivates a status. All changes to the statuses of
-- * an account go through this function or gaim_account_set_status or
-- * gaim_account_set_status_list.
-+ * an account go through this function or gaim2_account_set_status or
-+ * gaim2_account_set_status_list.
- *
- * Only independent statuses can be deactivated with this. To deactivate
- * an exclusive status, activate a different (and exclusive?) status.
-@@ -316,14 +316,14 @@ void gaim_account_set_status(GaimAccount
- * @param active The active state.
- * @param args The va_list of attributes.
- */
--void gaim_account_set_status_vargs(GaimAccount *account,
-+void gaim2_account_set_status_vargs(Gaim2Account *account,
- const char *status_id,
- gboolean active, va_list args);
-
- /**
- * Activates or deactivates a status. All changes to the statuses of
-- * an account go through this function or gaim_account_set_status or
-- * gaim_account_set_status_vargs.
-+ * an account go through this function or gaim2_account_set_status or
-+ * gaim2_account_set_status_vargs.
- *
- * Only independent statuses can be deactivated with this. To deactivate
- * an exclusive status, activate a different (and exclusive?) status.
-@@ -333,7 +333,7 @@ void gaim_account_set_status_vargs(GaimA
- * @param active The active state.
- * @param attrs A list of attributes in key/value pairs
- */
--void gaim_account_set_status_list(GaimAccount *account,
-+void gaim2_account_set_status_list(Gaim2Account *account,
- const char *status_id,
- gboolean active, GList *attrs);
-
-@@ -342,7 +342,7 @@ void gaim_account_set_status_list(GaimAc
- *
- * @param account The account.
- */
--void gaim_account_clear_settings(GaimAccount *account);
-+void gaim2_account_clear_settings(Gaim2Account *account);
-
- /**
- * Sets a protocol-specific integer setting for an account.
-@@ -351,7 +351,7 @@ void gaim_account_clear_settings(GaimAcc
- * @param name The name of the setting.
- * @param value The setting's value.
- */
--void gaim_account_set_int(GaimAccount *account, const char *name, int value);
-+void gaim2_account_set_int(Gaim2Account *account, const char *name, int value);
-
- /**
- * Sets a protocol-specific string setting for an account.
-@@ -360,7 +360,7 @@ void gaim_account_set_int(GaimAccount *a
- * @param name The name of the setting.
- * @param value The setting's value.
- */
--void gaim_account_set_string(GaimAccount *account, const char *name,
-+void gaim2_account_set_string(Gaim2Account *account, const char *name,
- const char *value);
-
- /**
-@@ -370,7 +370,7 @@ void gaim_account_set_string(GaimAccount
- * @param name The name of the setting.
- * @param value The setting's value.
- */
--void gaim_account_set_bool(GaimAccount *account, const char *name,
-+void gaim2_account_set_bool(Gaim2Account *account, const char *name,
- gboolean value);
-
- /**
-@@ -381,7 +381,7 @@ void gaim_account_set_bool(GaimAccount *
- * @param name The name of the setting.
- * @param value The setting's value.
- */
--void gaim_account_set_ui_int(GaimAccount *account, const char *ui,
-+void gaim2_account_set_ui_int(Gaim2Account *account, const char *ui,
- const char *name, int value);
-
- /**
-@@ -392,7 +392,7 @@ void gaim_account_set_ui_int(GaimAccount
- * @param name The name of the setting.
- * @param value The setting's value.
- */
--void gaim_account_set_ui_string(GaimAccount *account, const char *ui,
-+void gaim2_account_set_ui_string(Gaim2Account *account, const char *ui,
- const char *name, const char *value);
-
- /**
-@@ -403,7 +403,7 @@ void gaim_account_set_ui_string(GaimAcco
- * @param name The name of the setting.
- * @param value The setting's value.
- */
--void gaim_account_set_ui_bool(GaimAccount *account, const char *ui,
-+void gaim2_account_set_ui_bool(Gaim2Account *account, const char *ui,
- const char *name, gboolean value);
-
- /**
-@@ -413,7 +413,7 @@ void gaim_account_set_ui_bool(GaimAccoun
- *
- * @return @c TRUE if connected, or @c FALSE otherwise.
- */
--gboolean gaim_account_is_connected(const GaimAccount *account);
-+gboolean gaim2_account_is_connected(const Gaim2Account *account);
-
- /**
- * Returns whether or not the account is connecting.
-@@ -422,7 +422,7 @@ gboolean gaim_account_is_connected(const
- *
- * @return @c TRUE if connecting, or @c FALSE otherwise.
- */
--gboolean gaim_account_is_connecting(const GaimAccount *account);
-+gboolean gaim2_account_is_connecting(const Gaim2Account *account);
-
- /**
- * Returns whether or not the account is disconnected.
-@@ -431,7 +431,7 @@ gboolean gaim_account_is_connecting(cons
- *
- * @return @c TRUE if disconnected, or @c FALSE otherwise.
- */
--gboolean gaim_account_is_disconnected(const GaimAccount *account);
-+gboolean gaim2_account_is_disconnected(const Gaim2Account *account);
-
- /**
- * Returns the account's username.
-@@ -440,7 +440,7 @@ gboolean gaim_account_is_disconnected(co
- *
- * @return The username.
- */
--const char *gaim_account_get_username(const GaimAccount *account);
-+const char *gaim2_account_get_username(const Gaim2Account *account);
-
- /**
- * Returns the account's password.
-@@ -449,7 +449,7 @@ const char *gaim_account_get_username(co
- *
- * @return The password.
- */
--const char *gaim_account_get_password(const GaimAccount *account);
-+const char *gaim2_account_get_password(const Gaim2Account *account);
-
- /**
- * Returns the account's alias.
-@@ -458,7 +458,7 @@ const char *gaim_account_get_password(co
- *
- * @return The alias.
- */
--const char *gaim_account_get_alias(const GaimAccount *account);
-+const char *gaim2_account_get_alias(const Gaim2Account *account);
-
- /**
- * Returns the account's user information.
-@@ -467,7 +467,7 @@ const char *gaim_account_get_alias(const
- *
- * @return The user information.
- */
--const char *gaim_account_get_user_info(const GaimAccount *account);
-+const char *gaim2_account_get_user_info(const Gaim2Account *account);
-
- /**
- * Returns the account's buddy icon filename.
-@@ -476,7 +476,7 @@ const char *gaim_account_get_user_info(c
- *
- * @return The buddy icon filename.
- */
--const char *gaim_account_get_buddy_icon(const GaimAccount *account);
-+const char *gaim2_account_get_buddy_icon(const Gaim2Account *account);
-
- /**
- * Returns the account's protocol ID.
-@@ -485,7 +485,7 @@ const char *gaim_account_get_buddy_icon(
- *
- * @return The protocol ID.
- */
--const char *gaim_account_get_protocol_id(const GaimAccount *account);
-+const char *gaim2_account_get_protocol_id(const Gaim2Account *account);
-
- /**
- * Returns the account's protocol name.
-@@ -494,7 +494,7 @@ const char *gaim_account_get_protocol_id
- *
- * @return The protocol name.
- */
--const char *gaim_account_get_protocol_name(const GaimAccount *account);
-+const char *gaim2_account_get_protocol_name(const Gaim2Account *account);
-
- /**
- * Returns the account's connection.
-@@ -503,7 +503,7 @@ const char *gaim_account_get_protocol_na
- *
- * @return The connection.
- */
--GaimConnection *gaim_account_get_connection(const GaimAccount *account);
-+Gaim2Connection *gaim2_account_get_connection(const Gaim2Account *account);
-
- /**
- * Returns whether or not this account should save its password.
-@@ -512,7 +512,7 @@ GaimConnection *gaim_account_get_connect
- *
- * @return @c TRUE if it should remember the password.
- */
--gboolean gaim_account_get_remember_password(const GaimAccount *account);
-+gboolean gaim2_account_get_remember_password(const Gaim2Account *account);
-
- /**
- * Returns whether or not this account should check for mail.
-@@ -521,7 +521,7 @@ gboolean gaim_account_get_remember_passw
- *
- * @return @c TRUE if it should check for mail.
- */
--gboolean gaim_account_get_check_mail(const GaimAccount *account);
-+gboolean gaim2_account_get_check_mail(const Gaim2Account *account);
-
- /**
- * Returns whether or not this account is enabled for the
-@@ -532,7 +532,7 @@ gboolean gaim_account_get_check_mail(con
- *
- * @return @c TRUE if it enabled on this UI.
- */
--gboolean gaim_account_get_enabled(const GaimAccount *account,
-+gboolean gaim2_account_get_enabled(const Gaim2Account *account,
- const char *ui);
-
- /**
-@@ -542,24 +542,24 @@ gboolean gaim_account_get_enabled(const
- *
- * @return The proxy information.
- */
--GaimProxyInfo *gaim_account_get_proxy_info(const GaimAccount *account);
-+Gaim2ProxyInfo *gaim2_account_get_proxy_info(const Gaim2Account *account);
-
- /**
- * Returns the active status for this account. This looks through
-- * the GaimPresence associated with this account and returns the
-- * GaimStatus that has its active flag set to "TRUE." There can be
-- * only one active GaimStatus in a GaimPresence.
-+ * the Gaim2Presence associated with this account and returns the
-+ * Gaim2Status that has its active flag set to "TRUE." There can be
-+ * only one active Gaim2Status in a Gaim2Presence.
- *
- * @param account The account.
- *
- * @return The active status.
- */
--GaimStatus *gaim_account_get_active_status(const GaimAccount *account);
-+Gaim2Status *gaim2_account_get_active_status(const Gaim2Account *account);
-
- /**
- * Returns the account status with the specified ID.
- *
-- * Note that this works differently than gaim_buddy_get_status() in that
-+ * Note that this works differently than gaim2_buddy_get_status() in that
- * it will only return NULL if the status was not registered.
- *
- * @param account The account.
-@@ -567,7 +567,7 @@ GaimStatus *gaim_account_get_active_stat
- *
- * @return The status, or NULL if it was never registered.
- */
--GaimStatus *gaim_account_get_status(const GaimAccount *account,
-+Gaim2Status *gaim2_account_get_status(const Gaim2Account *account,
- const char *status_id);
-
- /**
-@@ -578,23 +578,23 @@ GaimStatus *gaim_account_get_status(cons
- *
- * @return The status type if found, or NULL.
- */
--GaimStatusType *gaim_account_get_status_type(const GaimAccount *account,
-+Gaim2StatusType *gaim2_account_get_status_type(const Gaim2Account *account,
- const char *id);
-
- /**
- * Returns the account status type with the specified primitive.
- * Note: It is possible for an account to have more than one
-- * GaimStatusType with the same primitive. In this case, the
-- * first GaimStatusType is returned.
-+ * Gaim2StatusType with the same primitive. In this case, the
-+ * first Gaim2StatusType is returned.
- *
- * @param account The account.
- * @param primitive The type of the status type to find.
- *
- * @return The status if found, or NULL.
- */
--GaimStatusType *gaim_account_get_status_type_with_primitive(
-- const GaimAccount *account,
-- GaimStatusPrimitive primitive);
-+Gaim2StatusType *gaim2_account_get_status_type_with_primitive(
-+ const Gaim2Account *account,
-+ Gaim2StatusPrimitive primitive);
-
- /**
- * Returns the account's presence.
-@@ -603,7 +603,7 @@ GaimStatusType *gaim_account_get_status_
- *
- * @return The account's presence.
- */
--GaimPresence *gaim_account_get_presence(const GaimAccount *account);
-+Gaim2Presence *gaim2_account_get_presence(const Gaim2Account *account);
-
- /**
- * Returns whether or not an account status is active.
-@@ -613,7 +613,7 @@ GaimPresence *gaim_account_get_presence(
- *
- * @return TRUE if active, or FALSE if not.
- */
--gboolean gaim_account_is_status_active(const GaimAccount *account,
-+gboolean gaim2_account_is_status_active(const Gaim2Account *account,
- const char *status_id);
-
- /**
-@@ -623,7 +623,7 @@ gboolean gaim_account_is_status_active(c
- *
- * @return The account's status types.
- */
--const GList *gaim_account_get_status_types(const GaimAccount *account);
-+const GList *gaim2_account_get_status_types(const Gaim2Account *account);
-
- /**
- * Returns a protocol-specific integer setting for an account.
-@@ -634,7 +634,7 @@ const GList *gaim_account_get_status_typ
- *
- * @return The value.
- */
--int gaim_account_get_int(const GaimAccount *account, const char *name,
-+int gaim2_account_get_int(const Gaim2Account *account, const char *name,
- int default_value);
-
- /**
-@@ -646,7 +646,7 @@ int gaim_account_get_int(const GaimAccou
- *
- * @return The value.
- */
--const char *gaim_account_get_string(const GaimAccount *account,
-+const char *gaim2_account_get_string(const Gaim2Account *account,
- const char *name,
- const char *default_value);
-
-@@ -659,7 +659,7 @@ const char *gaim_account_get_string(cons
- *
- * @return The value.
- */
--gboolean gaim_account_get_bool(const GaimAccount *account, const char *name,
-+gboolean gaim2_account_get_bool(const Gaim2Account *account, const char *name,
- gboolean default_value);
-
- /**
-@@ -672,7 +672,7 @@ gboolean gaim_account_get_bool(const Gai
- *
- * @return The value.
- */
--int gaim_account_get_ui_int(const GaimAccount *account, const char *ui,
-+int gaim2_account_get_ui_int(const Gaim2Account *account, const char *ui,
- const char *name, int default_value);
-
- /**
-@@ -685,7 +685,7 @@ int gaim_account_get_ui_int(const GaimAc
- *
- * @return The value.
- */
--const char *gaim_account_get_ui_string(const GaimAccount *account,
-+const char *gaim2_account_get_ui_string(const Gaim2Account *account,
- const char *ui, const char *name,
- const char *default_value);
-
-@@ -699,7 +699,7 @@ const char *gaim_account_get_ui_string(c
- *
- * @return The value.
- */
--gboolean gaim_account_get_ui_bool(const GaimAccount *account, const char *ui,
-+gboolean gaim2_account_get_ui_bool(const Gaim2Account *account, const char *ui,
- const char *name, gboolean default_value);
-
-
-@@ -711,14 +711,14 @@ gboolean gaim_account_get_ui_bool(const
- *
- * @return The log.
- */
--GaimLog *gaim_account_get_log(GaimAccount *account);
-+Gaim2Log *gaim2_account_get_log(Gaim2Account *account);
-
- /**
- * Frees the system log of an account
- *
- * @param account The account.
- */
--void gaim_account_destroy_log(GaimAccount *account);
-+void gaim2_account_destroy_log(Gaim2Account *account);
-
- /**
- * Adds a buddy to the server-side buddy list for the specified account.
-@@ -726,14 +726,14 @@ void gaim_account_destroy_log(GaimAccoun
- * @param account The account.
- * @param buddy The buddy to add.
- */
--void gaim_account_add_buddy(GaimAccount *account, GaimBuddy *buddy);
-+void gaim2_account_add_buddy(Gaim2Account *account, Gaim2Buddy *buddy);
- /**
- * Adds a list of buddies to the server-side buddy list.
- *
- * @param account The account.
-- * @param buddies The list of GaimBlistNodes representing the buddies to add.
-+ * @param buddies The list of Gaim2BlistNodes representing the buddies to add.
- */
--void gaim_account_add_buddies(GaimAccount *account, GList *buddies);
-+void gaim2_account_add_buddies(Gaim2Account *account, GList *buddies);
-
- /**
- * Removes a buddy from the server-side buddy list.
-@@ -742,8 +742,8 @@ void gaim_account_add_buddies(GaimAccoun
- * @param buddy The buddy to remove.
- * @param group The group to remove the buddy from.
- */
--void gaim_account_remove_buddy(GaimAccount *account, GaimBuddy *buddy,
-- GaimGroup *group);
-+void gaim2_account_remove_buddy(Gaim2Account *account, Gaim2Buddy *buddy,
-+ Gaim2Group *group);
-
- /**
- * Removes a list of buddies from the server-side buddy list.
-@@ -756,7 +756,7 @@ void gaim_account_remove_buddy(GaimAccou
- * @param groups The list of groups to remove buddies from. Each node of this
- * list should match the corresponding node of buddies.
- */
--void gaim_account_remove_buddies(GaimAccount *account, GList *buddies,
-+void gaim2_account_remove_buddies(Gaim2Account *account, GList *buddies,
- GList *groups);
-
- /**
-@@ -765,7 +765,7 @@ void gaim_account_remove_buddies(GaimAcc
- * @param account The account.
- * @param group The group to remove.
- */
--void gaim_account_remove_group(GaimAccount *account, GaimGroup *group);
-+void gaim2_account_remove_group(Gaim2Account *account, Gaim2Group *group);
-
- /**
- * Changes the password on the specified account.
-@@ -774,7 +774,7 @@ void gaim_account_remove_group(GaimAccou
- * @param orig_pw The old password.
- * @param new_pw The new password.
- */
--void gaim_account_change_password(GaimAccount *account, const char *orig_pw,
-+void gaim2_account_change_password(Gaim2Account *account, const char *orig_pw,
- const char *new_pw);
-
- /**
-@@ -783,7 +783,7 @@ void gaim_account_change_password(GaimAc
- * @param account The account
- * @param buddy The buddy
- */
--gboolean gaim_account_supports_offline_message(GaimAccount *account, GaimBuddy *buddy);
-+gboolean gaim2_account_supports_offline_message(Gaim2Account *account, Gaim2Buddy *buddy);
-
- /*@}*/
-
-@@ -797,14 +797,14 @@ gboolean gaim_account_supports_offline_m
- *
- * @param account The account.
- */
--void gaim_accounts_add(GaimAccount *account);
-+void gaim2_accounts_add(Gaim2Account *account);
-
- /**
- * Removes an account from the list of accounts.
- *
- * @param account The account.
- */
--void gaim_accounts_remove(GaimAccount *account);
-+void gaim2_accounts_remove(Gaim2Account *account);
-
- /**
- * Deletes an account.
-@@ -815,7 +815,7 @@ void gaim_accounts_remove(GaimAccount *a
- *
- * @param account The account.
- */
--void gaim_accounts_delete(GaimAccount *account);
-+void gaim2_accounts_delete(Gaim2Account *account);
-
- /**
- * Reorders an account.
-@@ -823,14 +823,14 @@ void gaim_accounts_delete(GaimAccount *a
- * @param account The account to reorder.
- * @param new_index The new index for the account.
- */
--void gaim_accounts_reorder(GaimAccount *account, gint new_index);
-+void gaim2_accounts_reorder(Gaim2Account *account, gint new_index);
-
- /**
- * Returns a list of all accounts.
- *
- * @return A list of all accounts.
- */
--GList *gaim_accounts_get_all(void);
-+GList *gaim2_accounts_get_all(void);
-
- /**
- * Returns a list of all enabled accounts
-@@ -839,7 +839,7 @@ GList *gaim_accounts_get_all(void);
- * by the caller, and must be g_list_free()d to avoid
- * leaking the nodes.
- */
--GList *gaim_accounts_get_all_active(void);
-+GList *gaim2_accounts_get_all_active(void);
-
- /**
- * Finds an account with the specified name and protocol id.
-@@ -849,7 +849,7 @@ GList *gaim_accounts_get_all_active(void
- *
- * @return The account, if found, or @c FALSE otherwise.
- */
--GaimAccount *gaim_accounts_find(const char *name, const char *protocol);
-+Gaim2Account *gaim2_accounts_find(const char *name, const char *protocol);
-
- /**
- * This is called by the core after all subsystems and what
-@@ -860,7 +860,7 @@ GaimAccount *gaim_accounts_find(const ch
- * You probably shouldn't call this unless you really know
- * what you're doing.
- */
--void gaim_accounts_restore_previous_statuses(void);
-+void gaim2_accounts_restore_previous_statuses(void);
-
- /*@}*/
-
-@@ -874,14 +874,14 @@ void gaim_accounts_restore_previous_stat
- *
- * @param ops The UI operations structure.
- */
--void gaim_accounts_set_ui_ops(GaimAccountUiOps *ops);
-+void gaim2_accounts_set_ui_ops(Gaim2AccountUiOps *ops);
-
- /**
- * Returns the UI operations structure used for accounts.
- *
- * @return The UI operations structure in use.
- */
--GaimAccountUiOps *gaim_accounts_get_ui_ops(void);
-+Gaim2AccountUiOps *gaim2_accounts_get_ui_ops(void);
-
- /*@}*/
-
-@@ -896,17 +896,17 @@ GaimAccountUiOps *gaim_accounts_get_ui_o
- *
- * @return The accounts subsystem handle.
- */
--void *gaim_accounts_get_handle(void);
-+void *gaim2_accounts_get_handle(void);
-
- /**
- * Initializes the accounts subsystem.
- */
--void gaim_accounts_init(void);
-+void gaim2_accounts_init(void);
-
- /**
- * Uninitializes the accounts subsystem.
- */
--void gaim_accounts_uninit(void);
-+void gaim2_accounts_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/accountopt.c ./src/accountopt.c
---- ./src/accountopt.c 2005-11-20 18:29:09.000000000 +0100
-+++ ./src/accountopt.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file accountopt.c Account Options API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,17 +25,17 @@
- #include "accountopt.h"
- #include "util.h"
-
--GaimAccountOption *
--gaim_account_option_new(GaimPrefType type, const char *text,
-+Gaim2AccountOption *
-+gaim2_account_option_new(Gaim2PrefType type, const char *text,
- const char *pref_name)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
- g_return_val_if_fail(type != GAIM_PREF_NONE, NULL);
- g_return_val_if_fail(text != NULL, NULL);
- g_return_val_if_fail(pref_name != NULL, NULL);
-
-- option = g_new0(GaimAccountOption, 1);
-+ option = g_new0(Gaim2AccountOption, 1);
-
- option->type = type;
- option->text = g_strdup(text);
-@@ -44,13 +44,13 @@ gaim_account_option_new(GaimPrefType typ
- return option;
- }
-
--GaimAccountOption *
--gaim_account_option_bool_new(const char *text, const char *pref_name,
-+Gaim2AccountOption *
-+gaim2_account_option_bool_new(const char *text, const char *pref_name,
- gboolean default_value)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_new(GAIM_PREF_BOOLEAN, text, pref_name);
-+ option = gaim2_account_option_new(GAIM_PREF_BOOLEAN, text, pref_name);
-
- if (option == NULL)
- return NULL;
-@@ -60,13 +60,13 @@ gaim_account_option_bool_new(const char
- return option;
- }
-
--GaimAccountOption *
--gaim_account_option_int_new(const char *text, const char *pref_name,
-+Gaim2AccountOption *
-+gaim2_account_option_int_new(const char *text, const char *pref_name,
- int default_value)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_new(GAIM_PREF_INT, text, pref_name);
-+ option = gaim2_account_option_new(GAIM_PREF_INT, text, pref_name);
-
- if (option == NULL)
- return NULL;
-@@ -76,13 +76,13 @@ gaim_account_option_int_new(const char *
- return option;
- }
-
--GaimAccountOption *
--gaim_account_option_string_new(const char *text, const char *pref_name,
-+Gaim2AccountOption *
-+gaim2_account_option_string_new(const char *text, const char *pref_name,
- const char *default_value)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_new(GAIM_PREF_STRING, text, pref_name);
-+ option = gaim2_account_option_new(GAIM_PREF_STRING, text, pref_name);
-
- if (option == NULL)
- return NULL;
-@@ -93,13 +93,13 @@ gaim_account_option_string_new(const cha
- return option;
- }
-
--GaimAccountOption *
--gaim_account_option_list_new(const char *text, const char *pref_name,
-+Gaim2AccountOption *
-+gaim2_account_option_list_new(const char *text, const char *pref_name,
- GList *list)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_new(GAIM_PREF_STRING_LIST, text, pref_name);
-+ option = gaim2_account_option_new(GAIM_PREF_STRING_LIST, text, pref_name);
-
- if (option == NULL)
- return NULL;
-@@ -110,7 +110,7 @@ gaim_account_option_list_new(const char
- }
-
- void
--gaim_account_option_destroy(GaimAccountOption *option)
-+gaim2_account_option_destroy(Gaim2AccountOption *option)
- {
- g_return_if_fail(option != NULL);
-
-@@ -138,7 +138,7 @@ gaim_account_option_destroy(GaimAccountO
- }
-
- void
--gaim_account_option_set_default_bool(GaimAccountOption *option,
-+gaim2_account_option_set_default_bool(Gaim2AccountOption *option,
- gboolean value)
- {
- g_return_if_fail(option != NULL);
-@@ -148,7 +148,7 @@ gaim_account_option_set_default_bool(Gai
- }
-
- void
--gaim_account_option_set_default_int(GaimAccountOption *option, int value)
-+gaim2_account_option_set_default_int(Gaim2AccountOption *option, int value)
- {
- g_return_if_fail(option != NULL);
- g_return_if_fail(option->type == GAIM_PREF_INT);
-@@ -157,7 +157,7 @@ gaim_account_option_set_default_int(Gaim
- }
-
- void
--gaim_account_option_set_default_string(GaimAccountOption *option,
-+gaim2_account_option_set_default_string(Gaim2AccountOption *option,
- const char *value)
- {
- g_return_if_fail(option != NULL);
-@@ -170,7 +170,7 @@ gaim_account_option_set_default_string(G
- }
-
- void
--gaim_account_option_set_masked(GaimAccountOption *option, gboolean masked)
-+gaim2_account_option_set_masked(Gaim2AccountOption *option, gboolean masked)
- {
- g_return_if_fail(option != NULL);
- g_return_if_fail(option->type == GAIM_PREF_STRING);
-@@ -180,7 +180,7 @@ gaim_account_option_set_masked(GaimAccou
-
-
- void
--gaim_account_option_set_list(GaimAccountOption *option, GList *values)
-+gaim2_account_option_set_list(Gaim2AccountOption *option, GList *values)
- {
- g_return_if_fail(option != NULL);
- g_return_if_fail(option->type == GAIM_PREF_STRING_LIST);
-@@ -195,17 +195,17 @@ gaim_account_option_set_list(GaimAccount
- }
-
- void
--gaim_account_option_add_list_item(GaimAccountOption *option,
-+gaim2_account_option_add_list_item(Gaim2AccountOption *option,
- const char *key, const char *value)
- {
-- GaimKeyValuePair *kvp;
-+ Gaim2KeyValuePair *kvp;
-
- g_return_if_fail(option != NULL);
- g_return_if_fail(key != NULL);
- g_return_if_fail(value != NULL);
- g_return_if_fail(option->type == GAIM_PREF_STRING_LIST);
-
-- kvp = g_new0(GaimKeyValuePair, 1);
-+ kvp = g_new0(Gaim2KeyValuePair, 1);
- kvp->key = g_strdup(key);
- kvp->value = g_strdup(value);
-
-@@ -213,8 +213,8 @@ gaim_account_option_add_list_item(GaimAc
- kvp);
- }
-
--GaimPrefType
--gaim_account_option_get_type(const GaimAccountOption *option)
-+Gaim2PrefType
-+gaim2_account_option_get_type(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, GAIM_PREF_NONE);
-
-@@ -222,7 +222,7 @@ gaim_account_option_get_type(const GaimA
- }
-
- const char *
--gaim_account_option_get_text(const GaimAccountOption *option)
-+gaim2_account_option_get_text(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, NULL);
-
-@@ -230,7 +230,7 @@ gaim_account_option_get_text(const GaimA
- }
-
- const char *
--gaim_account_option_get_setting(const GaimAccountOption *option)
-+gaim2_account_option_get_setting(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, NULL);
-
-@@ -238,7 +238,7 @@ gaim_account_option_get_setting(const Ga
- }
-
- gboolean
--gaim_account_option_get_default_bool(const GaimAccountOption *option)
-+gaim2_account_option_get_default_bool(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, FALSE);
- g_return_val_if_fail(option->type == GAIM_PREF_BOOLEAN, FALSE);
-@@ -247,7 +247,7 @@ gaim_account_option_get_default_bool(con
- }
-
- int
--gaim_account_option_get_default_int(const GaimAccountOption *option)
-+gaim2_account_option_get_default_int(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, -1);
- g_return_val_if_fail(option->type == GAIM_PREF_INT, -1);
-@@ -256,7 +256,7 @@ gaim_account_option_get_default_int(cons
- }
-
- const char *
--gaim_account_option_get_default_string(const GaimAccountOption *option)
-+gaim2_account_option_get_default_string(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, NULL);
- g_return_val_if_fail(option->type == GAIM_PREF_STRING, NULL);
-@@ -265,9 +265,9 @@ gaim_account_option_get_default_string(c
- }
-
- const char *
--gaim_account_option_get_default_list_value(const GaimAccountOption *option)
-+gaim2_account_option_get_default_list_value(const Gaim2AccountOption *option)
- {
-- GaimKeyValuePair *kvp;
-+ Gaim2KeyValuePair *kvp;
-
- g_return_val_if_fail(option != NULL, NULL);
- g_return_val_if_fail(option->type == GAIM_PREF_STRING_LIST, NULL);
-@@ -281,7 +281,7 @@ gaim_account_option_get_default_list_val
- }
-
- gboolean
--gaim_account_option_get_masked(const GaimAccountOption *option)
-+gaim2_account_option_get_masked(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, FALSE);
- g_return_val_if_fail(option->type == GAIM_PREF_STRING, FALSE);
-@@ -290,7 +290,7 @@ gaim_account_option_get_masked(const Gai
- }
-
- const GList *
--gaim_account_option_get_list(const GaimAccountOption *option)
-+gaim2_account_option_get_list(const Gaim2AccountOption *option)
- {
- g_return_val_if_fail(option != NULL, NULL);
- g_return_val_if_fail(option->type == GAIM_PREF_STRING_LIST, NULL);
-@@ -301,16 +301,16 @@ gaim_account_option_get_list(const GaimA
- /**************************************************************************
- * Account User Split API
- **************************************************************************/
--GaimAccountUserSplit *
--gaim_account_user_split_new(const char *text, const char *default_value,
-+Gaim2AccountUserSplit *
-+gaim2_account_user_split_new(const char *text, const char *default_value,
- char sep)
- {
-- GaimAccountUserSplit *split;
-+ Gaim2AccountUserSplit *split;
-
- g_return_val_if_fail(text != NULL, NULL);
- g_return_val_if_fail(sep != 0, NULL);
-
-- split = g_new0(GaimAccountUserSplit, 1);
-+ split = g_new0(Gaim2AccountUserSplit, 1);
-
- split->text = g_strdup(text);
- split->field_sep = sep;
-@@ -321,7 +321,7 @@ gaim_account_user_split_new(const char *
- }
-
- void
--gaim_account_user_split_destroy(GaimAccountUserSplit *split)
-+gaim2_account_user_split_destroy(Gaim2AccountUserSplit *split)
- {
- g_return_if_fail(split != NULL);
-
-@@ -335,7 +335,7 @@ gaim_account_user_split_destroy(GaimAcco
- }
-
- const char *
--gaim_account_user_split_get_text(const GaimAccountUserSplit *split)
-+gaim2_account_user_split_get_text(const Gaim2AccountUserSplit *split)
- {
- g_return_val_if_fail(split != NULL, NULL);
-
-@@ -343,7 +343,7 @@ gaim_account_user_split_get_text(const G
- }
-
- const char *
--gaim_account_user_split_get_default_value(const GaimAccountUserSplit *split)
-+gaim2_account_user_split_get_default_value(const Gaim2AccountUserSplit *split)
- {
- g_return_val_if_fail(split != NULL, NULL);
-
-@@ -351,7 +351,7 @@ gaim_account_user_split_get_default_valu
- }
-
- char
--gaim_account_user_split_get_separator(const GaimAccountUserSplit *split)
-+gaim2_account_user_split_get_separator(const Gaim2AccountUserSplit *split)
- {
- g_return_val_if_fail(split != NULL, 0);
-
-diff -prNu ./src/accountopt.h ./src/accountopt.h
---- ./src/accountopt.h 2005-11-20 18:29:09.000000000 +0100
-+++ ./src/accountopt.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file accountopt.h Account Options API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,7 +35,7 @@
- */
- typedef struct
- {
-- GaimPrefType type; /**< The type of value. */
-+ Gaim2PrefType type; /**< The type of value. */
-
- char *text; /**< The text that will appear to the user. */
- char *pref_name; /**< The name of the associated preference. */
-@@ -51,7 +51,7 @@ typedef struct
-
- gboolean masked;
-
--} GaimAccountOption;
-+} Gaim2AccountOption;
-
- /**
- * A username split.
-@@ -65,7 +65,7 @@ typedef struct
- char *default_value; /**< The default value. */
- char field_sep; /**< The field separator. */
-
--} GaimAccountUserSplit;
-+} Gaim2AccountUserSplit;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -85,7 +85,7 @@ extern "C" {
- *
- * @return The account option.
- */
--GaimAccountOption *gaim_account_option_new(GaimPrefType type, const char *text,
-+Gaim2AccountOption *gaim2_account_option_new(Gaim2PrefType type, const char *text,
- const char *pref_name);
-
- /**
-@@ -97,7 +97,7 @@ GaimAccountOption *gaim_account_option_n
- *
- * @return The account option.
- */
--GaimAccountOption *gaim_account_option_bool_new(const char *text,
-+Gaim2AccountOption *gaim2_account_option_bool_new(const char *text,
- const char *pref_name,
- gboolean default_value);
-
-@@ -110,7 +110,7 @@ GaimAccountOption *gaim_account_option_b
- *
- * @return The account option.
- */
--GaimAccountOption *gaim_account_option_int_new(const char *text,
-+Gaim2AccountOption *gaim2_account_option_int_new(const char *text,
- const char *pref_name,
- int default_value);
-
-@@ -123,7 +123,7 @@ GaimAccountOption *gaim_account_option_i
- *
- * @return The account option.
- */
--GaimAccountOption *gaim_account_option_string_new(const char *text,
-+Gaim2AccountOption *gaim2_account_option_string_new(const char *text,
- const char *pref_name,
- const char *default_value);
-
-@@ -133,7 +133,7 @@ GaimAccountOption *gaim_account_option_s
- * The list passed will be owned by the account option, and the
- * strings inside will be freed automatically.
- *
-- * The list is a list of GaimKeyValuePair items. The key is the ID stored and
-+ * The list is a list of Gaim2KeyValuePair items. The key is the ID stored and
- * used internally, and the value is the label displayed.
- *
- * @param text The text of the option.
-@@ -142,7 +142,7 @@ GaimAccountOption *gaim_account_option_s
- *
- * @return The account option.
- */
--GaimAccountOption *gaim_account_option_list_new(const char *text,
-+Gaim2AccountOption *gaim2_account_option_list_new(const char *text,
- const char *pref_name,
- GList *list);
-
-@@ -151,7 +151,7 @@ GaimAccountOption *gaim_account_option_l
- *
- * @param option The option to destroy.
- */
--void gaim_account_option_destroy(GaimAccountOption *option);
-+void gaim2_account_option_destroy(Gaim2AccountOption *option);
-
- /**
- * Sets the default boolean value for an account option.
-@@ -159,7 +159,7 @@ void gaim_account_option_destroy(GaimAcc
- * @param option The account option.
- * @param value The default boolean value.
- */
--void gaim_account_option_set_default_bool(GaimAccountOption *option,
-+void gaim2_account_option_set_default_bool(Gaim2AccountOption *option,
- gboolean value);
-
- /**
-@@ -168,7 +168,7 @@ void gaim_account_option_set_default_boo
- * @param option The account option.
- * @param value The default integer value.
- */
--void gaim_account_option_set_default_int(GaimAccountOption *option,
-+void gaim2_account_option_set_default_int(Gaim2AccountOption *option,
- int value);
-
- /**
-@@ -177,7 +177,7 @@ void gaim_account_option_set_default_int
- * @param option The account option.
- * @param value The default string value.
- */
--void gaim_account_option_set_default_string(GaimAccountOption *option,
-+void gaim2_account_option_set_default_string(Gaim2AccountOption *option,
- const char *value);
-
- /**
-@@ -187,7 +187,7 @@ void gaim_account_option_set_default_str
- * @param masked The masking.
- */
- void
--gaim_account_option_set_masked(GaimAccountOption *option, gboolean masked);
-+gaim2_account_option_set_masked(Gaim2AccountOption *option, gboolean masked);
-
- /**
- * Sets the list values for an account option.
-@@ -201,7 +201,7 @@ gaim_account_option_set_masked(GaimAccou
- * @param option The account option.
- * @param values The default list value.
- */
--void gaim_account_option_set_list(GaimAccountOption *option, GList *values);
-+void gaim2_account_option_set_list(Gaim2AccountOption *option, GList *values);
-
- /**
- * Adds an item to a list account option.
-@@ -210,7 +210,7 @@ void gaim_account_option_set_list(GaimAc
- * @param key The key.
- * @param value The value.
- */
--void gaim_account_option_add_list_item(GaimAccountOption *option,
-+void gaim2_account_option_add_list_item(Gaim2AccountOption *option,
- const char *key, const char *value);
-
- /**
-@@ -220,7 +220,7 @@ void gaim_account_option_add_list_item(G
- *
- * @return The account option's type.
- */
--GaimPrefType gaim_account_option_get_type(const GaimAccountOption *option);
-+Gaim2PrefType gaim2_account_option_get_type(const Gaim2AccountOption *option);
-
- /**
- * Returns the text for an account option.
-@@ -229,7 +229,7 @@ GaimPrefType gaim_account_option_get_typ
- *
- * @return The account option's text.
- */
--const char *gaim_account_option_get_text(const GaimAccountOption *option);
-+const char *gaim2_account_option_get_text(const Gaim2AccountOption *option);
-
- /**
- * Returns the account setting for an account option.
-@@ -238,7 +238,7 @@ const char *gaim_account_option_get_text
- *
- * @return The account setting.
- */
--const char *gaim_account_option_get_setting(const GaimAccountOption *option);
-+const char *gaim2_account_option_get_setting(const Gaim2AccountOption *option);
-
- /**
- * Returns the default boolean value for an account option.
-@@ -247,7 +247,7 @@ const char *gaim_account_option_get_sett
- *
- * @return The default boolean value.
- */
--gboolean gaim_account_option_get_default_bool(const GaimAccountOption *option);
-+gboolean gaim2_account_option_get_default_bool(const Gaim2AccountOption *option);
-
- /**
- * Returns the default integer value for an account option.
-@@ -256,7 +256,7 @@ gboolean gaim_account_option_get_default
- *
- * @return The default integer value.
- */
--int gaim_account_option_get_default_int(const GaimAccountOption *option);
-+int gaim2_account_option_get_default_int(const Gaim2AccountOption *option);
-
- /**
- * Returns the default string value for an account option.
-@@ -265,8 +265,8 @@ int gaim_account_option_get_default_int(
- *
- * @return The default string value.
- */
--const char *gaim_account_option_get_default_string(
-- const GaimAccountOption *option);
-+const char *gaim2_account_option_get_default_string(
-+ const Gaim2AccountOption *option);
-
- /**
- * Returns the default string value for a list account option.
-@@ -275,8 +275,8 @@ const char *gaim_account_option_get_defa
- *
- * @return The default list string value.
- */
--const char *gaim_account_option_get_default_list_value(
-- const GaimAccountOption *option);
-+const char *gaim2_account_option_get_default_list_value(
-+ const Gaim2AccountOption *option);
-
- /**
- * Returns the masking for an account option.
-@@ -286,7 +286,7 @@ const char *gaim_account_option_get_defa
- * @return The masking.
- */
- gboolean
--gaim_account_option_get_masked(const GaimAccountOption *option);
-+gaim2_account_option_get_masked(const Gaim2AccountOption *option);
-
- /**
- * Returns the list values for an account option.
-@@ -295,7 +295,7 @@ gaim_account_option_get_masked(const Gai
- *
- * @return The list values.
- */
--const GList *gaim_account_option_get_list(const GaimAccountOption *option);
-+const GList *gaim2_account_option_get_list(const Gaim2AccountOption *option);
-
- /*@}*/
-
-@@ -314,7 +314,7 @@ const GList *gaim_account_option_get_lis
- *
- * @return The new user split.
- */
--GaimAccountUserSplit *gaim_account_user_split_new(const char *text,
-+Gaim2AccountUserSplit *gaim2_account_user_split_new(const char *text,
- const char *default_value,
- char sep);
-
-@@ -323,7 +323,7 @@ GaimAccountUserSplit *gaim_account_user_
- *
- * @param split The split to destroy.
- */
--void gaim_account_user_split_destroy(GaimAccountUserSplit *split);
-+void gaim2_account_user_split_destroy(Gaim2AccountUserSplit *split);
-
- /**
- * Returns the text for an account username split.
-@@ -332,7 +332,7 @@ void gaim_account_user_split_destroy(Gai
- *
- * @return The account username split's text.
- */
--const char *gaim_account_user_split_get_text(const GaimAccountUserSplit *split);
-+const char *gaim2_account_user_split_get_text(const Gaim2AccountUserSplit *split);
-
- /**
- * Returns the default string value for an account split.
-@@ -341,8 +341,8 @@ const char *gaim_account_user_split_get_
- *
- * @return The default string.
- */
--const char *gaim_account_user_split_get_default_value(
-- const GaimAccountUserSplit *split);
-+const char *gaim2_account_user_split_get_default_value(
-+ const Gaim2AccountUserSplit *split);
-
- /**
- * Returns the field separator for an account split.
-@@ -351,7 +351,7 @@ const char *gaim_account_user_split_get_
- *
- * @return The field separator.
- */
--char gaim_account_user_split_get_separator(const GaimAccountUserSplit *split);
-+char gaim2_account_user_split_get_separator(const Gaim2AccountUserSplit *split);
-
- /*@}*/
-
-diff -prNu ./src/blist.c ./src/blist.c
---- ./src/blist.c 2006-01-03 02:19:32.000000000 +0100
-+++ ./src/blist.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -37,9 +37,9 @@
-
- #define PATHSIZE 1024
-
--static GaimBlistUiOps *blist_ui_ops = NULL;
-+static Gaim2BlistUiOps *blist_ui_ops = NULL;
-
--static GaimBuddyList *gaimbuddylist = NULL;
-+static Gaim2BuddyList *gaim2buddylist = NULL;
- static guint save_timer = 0;
- static gboolean blist_loaded = FALSE;
-
-@@ -48,9 +48,9 @@ static gboolean blist_loaded = FAL
- * Private utility functions *
- *********************************************************************/
-
--static GaimBlistNode *gaim_blist_get_last_sibling(GaimBlistNode *node)
-+static Gaim2BlistNode *gaim2_blist_get_last_sibling(Gaim2BlistNode *node)
- {
-- GaimBlistNode *n = node;
-+ Gaim2BlistNode *n = node;
- if (!n)
- return NULL;
- while (n->next)
-@@ -58,30 +58,30 @@ static GaimBlistNode *gaim_blist_get_las
- return n;
- }
-
--static GaimBlistNode *gaim_blist_get_last_child(GaimBlistNode *node)
-+static Gaim2BlistNode *gaim2_blist_get_last_child(Gaim2BlistNode *node)
- {
- if (!node)
- return NULL;
-- return gaim_blist_get_last_sibling(node->child);
-+ return gaim2_blist_get_last_sibling(node->child);
- }
-
--struct _gaim_hbuddy {
-+struct _gaim2_hbuddy {
- char *name;
-- GaimAccount *account;
-- GaimBlistNode *group;
-+ Gaim2Account *account;
-+ Gaim2BlistNode *group;
- };
-
--static guint _gaim_blist_hbuddy_hash(struct _gaim_hbuddy *hb)
-+static guint _gaim2_blist_hbuddy_hash(struct _gaim2_hbuddy *hb)
- {
- return g_str_hash(hb->name);
- }
-
--static guint _gaim_blist_hbuddy_equal(struct _gaim_hbuddy *hb1, struct _gaim_hbuddy *hb2)
-+static guint _gaim2_blist_hbuddy_equal(struct _gaim2_hbuddy *hb1, struct _gaim2_hbuddy *hb2)
- {
- return ((!strcmp(hb1->name, hb2->name)) && hb1->account == hb2->account && hb1->group == hb2->group);
- }
-
--static void _gaim_blist_hbuddy_free_key(struct _gaim_hbuddy *hb)
-+static void _gaim2_blist_hbuddy_free_key(struct _gaim2_hbuddy *hb)
- {
- g_free(hb->name);
- g_free(hb);
-@@ -96,12 +96,12 @@ static void
- value_to_xmlnode(gpointer key, gpointer hvalue, gpointer user_data)
- {
- const char *name;
-- GaimValue *value;
-+ Gaim2Value *value;
- xmlnode *node, *child;
- char buf[20];
-
- name = (const char *)key;
-- value = (GaimValue *)hvalue;
-+ value = (Gaim2Value *)hvalue;
- node = (xmlnode *)user_data;
-
- g_return_if_fail(value != NULL);
-@@ -109,18 +109,18 @@ value_to_xmlnode(gpointer key, gpointer
- child = xmlnode_new_child(node, "setting");
- xmlnode_set_attrib(child, "name", name);
-
-- if (gaim_value_get_type(value) == GAIM_TYPE_INT) {
-+ if (gaim2_value_get_type(value) == GAIM_TYPE_INT) {
- xmlnode_set_attrib(child, "type", "int");
-- snprintf(buf, sizeof(buf), "%d", gaim_value_get_int(value));
-+ snprintf(buf, sizeof(buf), "%d", gaim2_value_get_int(value));
- xmlnode_insert_data(child, buf, -1);
- }
-- else if (gaim_value_get_type(value) == GAIM_TYPE_STRING) {
-+ else if (gaim2_value_get_type(value) == GAIM_TYPE_STRING) {
- xmlnode_set_attrib(child, "type", "string");
-- xmlnode_insert_data(child, gaim_value_get_string(value), -1);
-+ xmlnode_insert_data(child, gaim2_value_get_string(value), -1);
- }
-- else if (gaim_value_get_type(value) == GAIM_TYPE_BOOLEAN) {
-+ else if (gaim2_value_get_type(value) == GAIM_TYPE_BOOLEAN) {
- xmlnode_set_attrib(child, "type", "bool");
-- snprintf(buf, sizeof(buf), "%d", gaim_value_get_boolean(value));
-+ snprintf(buf, sizeof(buf), "%d", gaim2_value_get_boolean(value));
- xmlnode_insert_data(child, buf, -1);
- }
- }
-@@ -144,16 +144,16 @@ chat_component_to_xmlnode(gpointer key,
- }
-
- static xmlnode *
--buddy_to_xmlnode(GaimBlistNode *bnode)
-+buddy_to_xmlnode(Gaim2BlistNode *bnode)
- {
- xmlnode *node, *child;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
-
- node = xmlnode_new("buddy");
-- xmlnode_set_attrib(node, "account", gaim_account_get_username(buddy->account));
-- xmlnode_set_attrib(node, "proto", gaim_account_get_protocol_id(buddy->account));
-+ xmlnode_set_attrib(node, "account", gaim2_account_get_username(buddy->account));
-+ xmlnode_set_attrib(node, "proto", gaim2_account_get_protocol_id(buddy->account));
-
- child = xmlnode_new_child(node, "name");
- xmlnode_insert_data(child, buddy->name, -1);
-@@ -171,13 +171,13 @@ buddy_to_xmlnode(GaimBlistNode *bnode)
- }
-
- static xmlnode *
--contact_to_xmlnode(GaimBlistNode *cnode)
-+contact_to_xmlnode(Gaim2BlistNode *cnode)
- {
- xmlnode *node, *child;
-- GaimContact *contact;
-- GaimBlistNode *bnode;
-+ Gaim2Contact *contact;
-+ Gaim2BlistNode *bnode;
-
-- contact = (GaimContact *)cnode;
-+ contact = (Gaim2Contact *)cnode;
-
- node = xmlnode_new("contact");
-
-@@ -205,16 +205,16 @@ contact_to_xmlnode(GaimBlistNode *cnode)
- }
-
- static xmlnode *
--chat_to_xmlnode(GaimBlistNode *cnode)
-+chat_to_xmlnode(Gaim2BlistNode *cnode)
- {
- xmlnode *node, *child;
-- GaimChat *chat;
-+ Gaim2Chat *chat;
-
-- chat = (GaimChat *)cnode;
-+ chat = (Gaim2Chat *)cnode;
-
- node = xmlnode_new("chat");
-- xmlnode_set_attrib(node, "proto", gaim_account_get_protocol_id(chat->account));
-- xmlnode_set_attrib(node, "account", gaim_account_get_username(chat->account));
-+ xmlnode_set_attrib(node, "proto", gaim2_account_get_protocol_id(chat->account));
-+ xmlnode_set_attrib(node, "account", gaim2_account_get_username(chat->account));
-
- if (chat->alias != NULL)
- {
-@@ -232,13 +232,13 @@ chat_to_xmlnode(GaimBlistNode *cnode)
- }
-
- static xmlnode *
--group_to_xmlnode(GaimBlistNode *gnode)
-+group_to_xmlnode(Gaim2BlistNode *gnode)
- {
- xmlnode *node, *child;
-- GaimGroup *group;
-- GaimBlistNode *cnode;
-+ Gaim2Group *group;
-+ Gaim2BlistNode *cnode;
-
-- group = (GaimGroup *)gnode;
-+ group = (Gaim2Group *)gnode;
-
- node = xmlnode_new("group");
- xmlnode_set_attrib(node, "name", group->name);
-@@ -267,15 +267,15 @@ group_to_xmlnode(GaimBlistNode *gnode)
- }
-
- static xmlnode *
--accountprivacy_to_xmlnode(GaimAccount *account)
-+accountprivacy_to_xmlnode(Gaim2Account *account)
- {
- xmlnode *node, *child;
- GSList *cur;
- char buf[10];
-
- node = xmlnode_new("account");
-- xmlnode_set_attrib(node, "proto", gaim_account_get_protocol_id(account));
-- xmlnode_set_attrib(node, "name", gaim_account_get_username(account));
-+ xmlnode_set_attrib(node, "proto", gaim2_account_get_protocol_id(account));
-+ xmlnode_set_attrib(node, "name", gaim2_account_get_username(account));
- snprintf(buf, sizeof(buf), "%d", account->perm_deny);
- xmlnode_set_attrib(node, "mode", buf);
-
-@@ -298,15 +298,15 @@ static xmlnode *
- blist_to_xmlnode()
- {
- xmlnode *node, *child, *grandchild;
-- GaimBlistNode *gnode;
-+ Gaim2BlistNode *gnode;
- GList *cur;
-
-- node = xmlnode_new("gaim");
-+ node = xmlnode_new("gaim2");
- xmlnode_set_attrib(node, "version", "1.0");
-
- /* Write groups */
- child = xmlnode_new_child(node, "blist");
-- for (gnode = gaimbuddylist->root; gnode != NULL; gnode = gnode->next)
-+ for (gnode = gaim2buddylist->root; gnode != NULL; gnode = gnode->next)
- {
- if (!GAIM_BLIST_NODE_SHOULD_SAVE(gnode))
- continue;
-@@ -319,7 +319,7 @@ blist_to_xmlnode()
-
- /* Write privacy settings */
- child = xmlnode_new_child(node, "privacy");
-- for (cur = gaim_accounts_get_all(); cur != NULL; cur = cur->next)
-+ for (cur = gaim2_accounts_get_all(); cur != NULL; cur = cur->next)
- {
- grandchild = accountprivacy_to_xmlnode(cur->data);
- xmlnode_insert_child(child, grandchild);
-@@ -329,21 +329,21 @@ blist_to_xmlnode()
- }
-
- static void
--gaim_blist_sync()
-+gaim2_blist_sync()
- {
- xmlnode *node;
- char *data;
-
- if (!blist_loaded)
- {
-- gaim_debug_error("blist", "Attempted to save buddy list before it "
-+ gaim2_debug_error("blist", "Attempted to save buddy list before it "
- "was read!\n");
- return;
- }
-
- node = blist_to_xmlnode();
- data = xmlnode_to_formatted_str(node, NULL);
-- gaim_util_write_data_to_file("blist.xml", data, -1);
-+ gaim2_util_write_data_to_file("blist.xml", data, -1);
- g_free(data);
- xmlnode_free(node);
- }
-@@ -351,16 +351,16 @@ gaim_blist_sync()
- static gboolean
- save_cb(gpointer data)
- {
-- gaim_blist_sync();
-+ gaim2_blist_sync();
- save_timer = 0;
- return FALSE;
- }
-
- void
--gaim_blist_schedule_save()
-+gaim2_blist_schedule_save()
- {
- if (save_timer == 0)
-- save_timer = gaim_timeout_add(5000, save_cb, NULL);
-+ save_timer = gaim2_timeout_add(5000, save_cb, NULL);
- }
-
-
-@@ -369,7 +369,7 @@ gaim_blist_schedule_save()
- *********************************************************************/
-
- static void
--parse_setting(GaimBlistNode *node, xmlnode *setting)
-+parse_setting(Gaim2BlistNode *node, xmlnode *setting)
- {
- const char *name = xmlnode_get_attrib(setting, "name");
- const char *type = xmlnode_get_attrib(setting, "type");
-@@ -379,20 +379,20 @@ parse_setting(GaimBlistNode *node, xmlno
- return;
-
- if (!type || !strcmp(type, "string"))
-- gaim_blist_node_set_string(node, name, value);
-+ gaim2_blist_node_set_string(node, name, value);
- else if (!strcmp(type, "bool"))
-- gaim_blist_node_set_bool(node, name, atoi(value));
-+ gaim2_blist_node_set_bool(node, name, atoi(value));
- else if (!strcmp(type, "int"))
-- gaim_blist_node_set_int(node, name, atoi(value));
-+ gaim2_blist_node_set_int(node, name, atoi(value));
-
- g_free(value);
- }
-
- static void
--parse_buddy(GaimGroup *group, GaimContact *contact, xmlnode *bnode)
-+parse_buddy(Gaim2Group *group, Gaim2Contact *contact, xmlnode *bnode)
- {
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
- char *name = NULL, *alias = NULL;
- const char *acct_name, *proto, *protocol;
- xmlnode *x;
-@@ -404,7 +404,7 @@ parse_buddy(GaimGroup *group, GaimContac
- if (!acct_name || (!proto && !protocol))
- return;
-
-- account = gaim_accounts_find(acct_name, proto ? proto : protocol);
-+ account = gaim2_accounts_find(acct_name, proto ? proto : protocol);
-
- if (!account)
- return;
-@@ -418,12 +418,12 @@ parse_buddy(GaimGroup *group, GaimContac
- if ((x = xmlnode_get_child(bnode, "alias")))
- alias = xmlnode_get_data(x);
-
-- buddy = gaim_buddy_new(account, name, alias);
-- gaim_blist_add_buddy(buddy, contact, group,
-- gaim_blist_get_last_child((GaimBlistNode*)contact));
-+ buddy = gaim2_buddy_new(account, name, alias);
-+ gaim2_blist_add_buddy(buddy, contact, group,
-+ gaim2_blist_get_last_child((Gaim2BlistNode*)contact));
-
- for (x = xmlnode_get_child(bnode, "setting"); x; x = xmlnode_get_next_twin(x)) {
-- parse_setting((GaimBlistNode*)buddy, x);
-+ parse_setting((Gaim2BlistNode*)buddy, x);
- }
-
- g_free(name);
-@@ -431,17 +431,17 @@ parse_buddy(GaimGroup *group, GaimContac
- }
-
- static void
--parse_contact(GaimGroup *group, xmlnode *cnode)
-+parse_contact(Gaim2Group *group, xmlnode *cnode)
- {
-- GaimContact *contact = gaim_contact_new();
-+ Gaim2Contact *contact = gaim2_contact_new();
- xmlnode *x;
- const char *alias;
-
-- gaim_blist_add_contact(contact, group,
-- gaim_blist_get_last_child((GaimBlistNode*)group));
-+ gaim2_blist_add_contact(contact, group,
-+ gaim2_blist_get_last_child((Gaim2BlistNode*)group));
-
- if ((alias = xmlnode_get_attrib(cnode, "alias"))) {
-- gaim_contact_set_alias(contact, alias);
-+ gaim2_contact_set_alias(contact, alias);
- }
-
- for (x = cnode->child; x; x = x->next) {
-@@ -450,19 +450,19 @@ parse_contact(GaimGroup *group, xmlnode
- if (!strcmp(x->name, "buddy"))
- parse_buddy(group, contact, x);
- else if (!strcmp(x->name, "setting"))
-- parse_setting((GaimBlistNode*)contact, x);
-+ parse_setting((Gaim2BlistNode*)contact, x);
- }
-
- /* if the contact is empty, don't keep it around. it causes problems */
-- if (!((GaimBlistNode*)contact)->child)
-- gaim_blist_remove_contact(contact);
-+ if (!((Gaim2BlistNode*)contact)->child)
-+ gaim2_blist_remove_contact(contact);
- }
-
- static void
--parse_chat(GaimGroup *group, xmlnode *cnode)
-+parse_chat(Gaim2Group *group, xmlnode *cnode)
- {
-- GaimChat *chat;
-- GaimAccount *account;
-+ Gaim2Chat *chat;
-+ Gaim2Account *account;
- const char *acct_name, *proto, *protocol;
- xmlnode *x;
- char *alias = NULL;
-@@ -475,7 +475,7 @@ parse_chat(GaimGroup *group, xmlnode *cn
- if (!acct_name || (!proto && !protocol))
- return;
-
-- account = gaim_accounts_find(acct_name, proto ? proto : protocol);
-+ account = gaim2_accounts_find(acct_name, proto ? proto : protocol);
-
- if (!account)
- return;
-@@ -494,12 +494,12 @@ parse_chat(GaimGroup *group, xmlnode *cn
- g_hash_table_replace(components, g_strdup(name), value);
- }
-
-- chat = gaim_chat_new(account, alias, components);
-- gaim_blist_add_chat(chat, group,
-- gaim_blist_get_last_child((GaimBlistNode*)group));
-+ chat = gaim2_chat_new(account, alias, components);
-+ gaim2_blist_add_chat(chat, group,
-+ gaim2_blist_get_last_child((Gaim2BlistNode*)group));
-
- for (x = xmlnode_get_child(cnode, "setting"); x; x = xmlnode_get_next_twin(x)) {
-- parse_setting((GaimBlistNode*)chat, x);
-+ parse_setting((Gaim2BlistNode*)chat, x);
- }
-
- g_free(alias);
-@@ -509,21 +509,21 @@ static void
- parse_group(xmlnode *groupnode)
- {
- const char *name = xmlnode_get_attrib(groupnode, "name");
-- GaimGroup *group;
-+ Gaim2Group *group;
- xmlnode *cnode;
-
- if (!name)
- name = _("Buddies");
-
-- group = gaim_group_new(name);
-- gaim_blist_add_group(group,
-- gaim_blist_get_last_sibling(gaimbuddylist->root));
-+ group = gaim2_group_new(name);
-+ gaim2_blist_add_group(group,
-+ gaim2_blist_get_last_sibling(gaim2buddylist->root));
-
- for (cnode = groupnode->child; cnode; cnode = cnode->next) {
- if (cnode->type != XMLNODE_TYPE_TAG)
- continue;
- if (!strcmp(cnode->name, "setting"))
-- parse_setting((GaimBlistNode*)group, cnode);
-+ parse_setting((Gaim2BlistNode*)group, cnode);
- else if (!strcmp(cnode->name, "contact") ||
- !strcmp(cnode->name, "person"))
- parse_contact(group, cnode);
-@@ -534,18 +534,18 @@ parse_group(xmlnode *groupnode)
-
- /* TODO: Make static and rename to load_blist */
- void
--gaim_blist_load()
-+gaim2_blist_load()
- {
-- xmlnode *gaim, *blist, *privacy;
-+ xmlnode *gaim2, *blist, *privacy;
-
- blist_loaded = TRUE;
-
-- gaim = gaim_util_read_xml_from_file("blist.xml", _("buddy list"));
-+ gaim2 = gaim2_util_read_xml_from_file("blist.xml", _("buddy list"));
-
-- if (gaim == NULL)
-+ if (gaim2 == NULL)
- return;
-
-- blist = xmlnode_get_child(gaim, "blist");
-+ blist = xmlnode_get_child(gaim2, "blist");
- if (blist) {
- xmlnode *groupnode;
- for (groupnode = xmlnode_get_child(blist, "group"); groupnode != NULL;
-@@ -554,12 +554,12 @@ gaim_blist_load()
- }
- }
-
-- privacy = xmlnode_get_child(gaim, "privacy");
-+ privacy = xmlnode_get_child(gaim2, "privacy");
- if (privacy) {
- xmlnode *anode;
- for (anode = privacy->child; anode; anode = anode->next) {
- xmlnode *x;
-- GaimAccount *account;
-+ Gaim2Account *account;
- int imode;
- const char *acct_name, *proto, *mode, *protocol;
-
-@@ -571,7 +571,7 @@ gaim_blist_load()
- if (!acct_name || (!proto && !protocol) || !mode)
- continue;
-
-- account = gaim_accounts_find(acct_name, proto ? proto : protocol);
-+ account = gaim2_accounts_find(acct_name, proto ? proto : protocol);
-
- if (!account)
- continue;
-@@ -586,18 +586,18 @@ gaim_blist_load()
-
- if (!strcmp(x->name, "permit")) {
- name = xmlnode_get_data(x);
-- gaim_privacy_permit_add(account, name, TRUE);
-+ gaim2_privacy_permit_add(account, name, TRUE);
- g_free(name);
- } else if (!strcmp(x->name, "block")) {
- name = xmlnode_get_data(x);
-- gaim_privacy_deny_add(account, name, TRUE);
-+ gaim2_privacy_deny_add(account, name, TRUE);
- g_free(name);
- }
- }
- }
- }
-
-- xmlnode_free(gaim);
-+ xmlnode_free(gaim2);
- }
-
-
-@@ -606,26 +606,26 @@ gaim_blist_load()
- *********************************************************************/
-
- static void
--gaim_contact_compute_priority_buddy(GaimContact *contact)
-+gaim2_contact_compute_priority_buddy(Gaim2Contact *contact)
- {
-- GaimBlistNode *bnode;
-- GaimBuddy *new_priority = NULL;
-+ Gaim2BlistNode *bnode;
-+ Gaim2Buddy *new_priority = NULL;
-
- g_return_if_fail(contact != NULL);
-
- contact->priority = NULL;
-- for (bnode = ((GaimBlistNode*)contact)->child;
-+ for (bnode = ((Gaim2BlistNode*)contact)->child;
- bnode != NULL;
- bnode = bnode->next)
- {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy*)bnode;
-+ buddy = (Gaim2Buddy*)bnode;
-
-- if (!gaim_account_is_connected(buddy->account))
-+ if (!gaim2_account_is_connected(buddy->account))
- continue;
- if (new_priority == NULL)
- new_priority = buddy;
-@@ -633,11 +633,11 @@ gaim_contact_compute_priority_buddy(Gaim
- {
- int cmp;
-
-- cmp = gaim_presence_compare(gaim_buddy_get_presence(new_priority),
-- gaim_buddy_get_presence(buddy));
-+ cmp = gaim2_presence_compare(gaim2_buddy_get_presence(new_priority),
-+ gaim2_buddy_get_presence(buddy));
-
- if (cmp > 0 || (cmp == 0 &&
-- gaim_prefs_get_bool("/core/contact/last_match")))
-+ gaim2_prefs_get_bool("/core/contact/last_match")))
- {
- new_priority = buddy;
- }
-@@ -653,16 +653,16 @@ gaim_contact_compute_priority_buddy(Gaim
- * Public API functions *
- *****************************************************************************/
-
--GaimBuddyList *gaim_blist_new()
-+Gaim2BuddyList *gaim2_blist_new()
- {
-- GaimBuddyList *gbl = g_new0(GaimBuddyList, 1);
-- GAIM_DBUS_REGISTER_POINTER(gbl, GaimBuddyList);
-+ Gaim2BuddyList *gbl = g_new0(Gaim2BuddyList, 1);
-+ GAIM_DBUS_REGISTER_POINTER(gbl, Gaim2BuddyList);
-
-- gbl->ui_ops = gaim_blist_get_ui_ops();
-+ gbl->ui_ops = gaim2_blist_get_ui_ops();
-
-- gbl->buddies = g_hash_table_new_full((GHashFunc)_gaim_blist_hbuddy_hash,
-- (GEqualFunc)_gaim_blist_hbuddy_equal,
-- (GDestroyNotify)_gaim_blist_hbuddy_free_key, NULL);
-+ gbl->buddies = g_hash_table_new_full((GHashFunc)_gaim2_blist_hbuddy_hash,
-+ (GEqualFunc)_gaim2_blist_hbuddy_equal,
-+ (GDestroyNotify)_gaim2_blist_hbuddy_free_key, NULL);
-
- if (gbl->ui_ops != NULL && gbl->ui_ops->new_list != NULL)
- gbl->ui_ops->new_list(gbl);
-@@ -671,44 +671,44 @@ GaimBuddyList *gaim_blist_new()
- }
-
- void
--gaim_set_blist(GaimBuddyList *list)
-+gaim2_set_blist(Gaim2BuddyList *list)
- {
-- gaimbuddylist = list;
-+ gaim2buddylist = list;
- }
-
--GaimBuddyList *
--gaim_get_blist()
-+Gaim2BuddyList *
-+gaim2_get_blist()
- {
-- return gaimbuddylist;
-+ return gaim2buddylist;
- }
-
--void gaim_blist_show()
-+void gaim2_blist_show()
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-
- if (ops && ops->show)
-- ops->show(gaimbuddylist);
-+ ops->show(gaim2buddylist);
- }
-
--void gaim_blist_destroy()
-+void gaim2_blist_destroy()
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-
-- gaim_debug(GAIM_DEBUG_INFO, "blist", "Destroying\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "blist", "Destroying\n");
-
- if (ops && ops->destroy)
-- ops->destroy(gaimbuddylist);
-+ ops->destroy(gaim2buddylist);
- }
-
--void gaim_blist_set_visible(gboolean show)
-+void gaim2_blist_set_visible(gboolean show)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-
- if (ops && ops->set_visible)
-- ops->set_visible(gaimbuddylist, show);
-+ ops->set_visible(gaim2buddylist, show);
- }
-
--static GaimBlistNode *get_next_node(GaimBlistNode *node, gboolean godeep)
-+static Gaim2BlistNode *get_next_node(Gaim2BlistNode *node, gboolean godeep)
- {
- if (node == NULL)
- return NULL;
-@@ -722,52 +722,52 @@ static GaimBlistNode *get_next_node(Gaim
- return get_next_node(node->parent, FALSE);
- }
-
--GaimBlistNode *gaim_blist_node_next(GaimBlistNode *node, gboolean offline)
-+Gaim2BlistNode *gaim2_blist_node_next(Gaim2BlistNode *node, gboolean offline)
- {
-- GaimBlistNode *ret = node;
-+ Gaim2BlistNode *ret = node;
-
- do
- {
- ret = get_next_node(ret, TRUE);
- } while (ret && !offline && GAIM_BLIST_NODE_IS_BUDDY(ret) &&
-- !gaim_account_is_connected(gaim_buddy_get_account((GaimBuddy *)ret)));
-+ !gaim2_account_is_connected(gaim2_buddy_get_account((Gaim2Buddy *)ret)));
-
- return ret;
- }
-
- void
--gaim_blist_update_buddy_status(GaimBuddy *buddy, GaimStatus *old_status)
-+gaim2_blist_update_buddy_status(Gaim2Buddy *buddy, Gaim2Status *old_status)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimPresence *presence;
-- GaimStatus *status;
-- GaimConversation *conv;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-+ Gaim2Conversation *conv;
-
- g_return_if_fail(buddy != NULL);
-
-- presence = gaim_buddy_get_presence(buddy);
-- status = gaim_presence_get_active_status(presence);
-+ presence = gaim2_buddy_get_presence(buddy);
-+ status = gaim2_presence_get_active_status(presence);
-
-- gaim_debug_info("blist", "Updating buddy status for %s (%s)\n",
-- buddy->name, gaim_account_get_protocol_name(buddy->account));
-+ gaim2_debug_info("blist", "Updating buddy status for %s (%s)\n",
-+ buddy->name, gaim2_account_get_protocol_name(buddy->account));
-
-- if (gaim_status_is_online(status) &&
-- !gaim_status_is_online(old_status)) {
-+ if (gaim2_status_is_online(status) &&
-+ !gaim2_status_is_online(old_status)) {
-
-- gaim_signal_emit(gaim_blist_get_handle(), "buddy-signed-on", buddy);
--
-- ((GaimContact*)((GaimBlistNode*)buddy)->parent)->online++;
-- if (((GaimContact*)((GaimBlistNode*)buddy)->parent)->online == 1)
-- ((GaimGroup *)((GaimBlistNode *)buddy)->parent->parent)->online++;
-- } else if (!gaim_status_is_online(status) &&
-- gaim_status_is_online(old_status)) {
-- gaim_blist_node_set_int(&buddy->node, "last_seen", time(NULL));
-- gaim_signal_emit(gaim_blist_get_handle(), "buddy-signed-off", buddy);
-- ((GaimContact*)((GaimBlistNode*)buddy)->parent)->online--;
-- if (((GaimContact*)((GaimBlistNode*)buddy)->parent)->online == 0)
-- ((GaimGroup *)((GaimBlistNode *)buddy)->parent->parent)->online--;
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "buddy-signed-on", buddy);
-+
-+ ((Gaim2Contact*)((Gaim2BlistNode*)buddy)->parent)->online++;
-+ if (((Gaim2Contact*)((Gaim2BlistNode*)buddy)->parent)->online == 1)
-+ ((Gaim2Group *)((Gaim2BlistNode *)buddy)->parent->parent)->online++;
-+ } else if (!gaim2_status_is_online(status) &&
-+ gaim2_status_is_online(old_status)) {
-+ gaim2_blist_node_set_int(&buddy->node, "last_seen", time(NULL));
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "buddy-signed-off", buddy);
-+ ((Gaim2Contact*)((Gaim2BlistNode*)buddy)->parent)->online--;
-+ if (((Gaim2Contact*)((Gaim2BlistNode*)buddy)->parent)->online == 0)
-+ ((Gaim2Group *)((Gaim2BlistNode *)buddy)->parent->parent)->online--;
- } else {
-- gaim_signal_emit(gaim_blist_get_handle(),
-+ gaim2_signal_emit(gaim2_blist_get_handle(),
- "buddy-status-changed", buddy, old_status,
- status);
- }
-@@ -782,60 +782,60 @@ gaim_blist_update_buddy_status(GaimBuddy
- * because something, somewhere changed. Calling the stuff below
- * certainly won't hurt anything. Unless you're on a K6-2 300.
- */
-- gaim_contact_invalidate_priority_buddy(gaim_buddy_get_contact(buddy));
-+ gaim2_contact_invalidate_priority_buddy(gaim2_buddy_get_contact(buddy));
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)buddy);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)buddy);
-
-- if ((conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name, buddy->account)))
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_AWAY);
-+ if ((conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name, buddy->account)))
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_AWAY);
- }
-
--void gaim_blist_update_buddy_icon(GaimBuddy *buddy)
-+void gaim2_blist_update_buddy_icon(Gaim2Buddy *buddy)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-
- g_return_if_fail(buddy != NULL);
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)buddy);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)buddy);
- }
-
- /*
- * TODO: Maybe remove the call to this from server.c and call it
- * from oscar.c and toc.c instead?
- */
--void gaim_blist_rename_buddy(GaimBuddy *buddy, const char *name)
-+void gaim2_blist_rename_buddy(Gaim2Buddy *buddy, const char *name)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- struct _gaim_hbuddy *hb;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ struct _gaim2_hbuddy *hb;
-
- g_return_if_fail(buddy != NULL);
-
-- hb = g_new(struct _gaim_hbuddy, 1);
-- hb->name = g_strdup(gaim_normalize(buddy->account, buddy->name));
-+ hb = g_new(struct _gaim2_hbuddy, 1);
-+ hb->name = g_strdup(gaim2_normalize(buddy->account, buddy->name));
- hb->account = buddy->account;
-- hb->group = ((GaimBlistNode *)buddy)->parent->parent;
-- g_hash_table_remove(gaimbuddylist->buddies, hb);
-+ hb->group = ((Gaim2BlistNode *)buddy)->parent->parent;
-+ g_hash_table_remove(gaim2buddylist->buddies, hb);
-
- g_free(hb->name);
-- hb->name = g_strdup(gaim_normalize(buddy->account, name));
-- g_hash_table_replace(gaimbuddylist->buddies, hb, buddy);
-+ hb->name = g_strdup(gaim2_normalize(buddy->account, name));
-+ g_hash_table_replace(gaim2buddylist->buddies, hb, buddy);
-
- g_free(buddy->name);
- buddy->name = g_strdup(name);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)buddy);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)buddy);
- }
-
--void gaim_blist_alias_contact(GaimContact *contact, const char *alias)
-+void gaim2_blist_alias_contact(Gaim2Contact *contact, const char *alias)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimConversation *conv;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Conversation *conv;
- char *old_alias = contact->alias;
-- GaimBlistNode *bnode;
-+ Gaim2BlistNode *bnode;
-
- g_return_if_fail(contact != NULL);
-
-@@ -844,29 +844,29 @@ void gaim_blist_alias_contact(GaimContac
- else
- contact->alias = NULL;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)contact);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)contact);
-
-- for(bnode = ((GaimBlistNode *)contact)->child; bnode != NULL; bnode = bnode->next)
-+ for(bnode = ((Gaim2BlistNode *)contact)->child; bnode != NULL; bnode = bnode->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)bnode;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)bnode;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name,
- buddy->account);
- if (conv)
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
- }
-
-- gaim_signal_emit(gaim_blist_get_handle(), "blist-node-aliased",
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "blist-node-aliased",
- contact, old_alias);
- g_free(old_alias);
- }
-
--void gaim_blist_alias_chat(GaimChat *chat, const char *alias)
-+void gaim2_blist_alias_chat(Gaim2Chat *chat, const char *alias)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
- char *old_alias = chat->alias;
-
- g_return_if_fail(chat != NULL);
-@@ -876,20 +876,20 @@ void gaim_blist_alias_chat(GaimChat *cha
- else
- chat->alias = NULL;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)chat);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)chat);
-
-- gaim_signal_emit(gaim_blist_get_handle(), "blist-node-aliased",
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "blist-node-aliased",
- chat, old_alias);
- g_free(old_alias);
- }
-
--void gaim_blist_alias_buddy(GaimBuddy *buddy, const char *alias)
-+void gaim2_blist_alias_buddy(Gaim2Buddy *buddy, const char *alias)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimConversation *conv;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Conversation *conv;
- char *old_alias = buddy->alias;
-
- g_return_if_fail(buddy != NULL);
-@@ -899,25 +899,25 @@ void gaim_blist_alias_buddy(GaimBuddy *b
- else
- buddy->alias = NULL;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)buddy);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)buddy);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name,
- buddy->account);
- if (conv)
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
-
-- gaim_signal_emit(gaim_blist_get_handle(), "blist-node-aliased",
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "blist-node-aliased",
- buddy, old_alias);
- g_free(old_alias);
- }
-
--void gaim_blist_server_alias_buddy(GaimBuddy *buddy, const char *alias)
-+void gaim2_blist_server_alias_buddy(Gaim2Buddy *buddy, const char *alias)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimConversation *conv;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Conversation *conv;
- char *old_alias = buddy->server_alias;
-
- g_return_if_fail(buddy != NULL);
-@@ -927,17 +927,17 @@ void gaim_blist_server_alias_buddy(GaimB
- else
- buddy->server_alias = NULL;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)buddy);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)buddy);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name,
- buddy->account);
- if (conv)
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
-
-- gaim_signal_emit(gaim_blist_get_handle(), "blist-node-aliased",
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "blist-node-aliased",
- buddy, old_alias);
- g_free(old_alias);
- }
-@@ -945,10 +945,10 @@ void gaim_blist_server_alias_buddy(GaimB
- /*
- * TODO: If merging, prompt the user if they want to merge.
- */
--void gaim_blist_rename_group(GaimGroup *source, const char *new_name)
-+void gaim2_blist_rename_group(Gaim2Group *source, const char *new_name)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimGroup *dest;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Group *dest;
- gchar *old_name;
- GList *moved_buddies = NULL;
- GSList *accts;
-@@ -959,13 +959,13 @@ void gaim_blist_rename_group(GaimGroup *
- if (*new_name == '\0' || !strcmp(new_name, source->name))
- return;
-
-- dest = gaim_find_group(new_name);
-+ dest = gaim2_find_group(new_name);
- if (dest != NULL) {
- /* We're merging two groups */
-- GaimBlistNode *prev, *child, *next;
-+ Gaim2BlistNode *prev, *child, *next;
-
-- prev = gaim_blist_get_last_child((GaimBlistNode*)dest);
-- child = ((GaimBlistNode*)source)->child;
-+ prev = gaim2_blist_get_last_child((Gaim2BlistNode*)dest);
-+ child = ((Gaim2BlistNode*)source)->child;
-
- /*
- * TODO: This seems like a dumb way to do this... why not just
-@@ -977,19 +977,19 @@ void gaim_blist_rename_group(GaimGroup *
- {
- next = child->next;
- if (GAIM_BLIST_NODE_IS_CONTACT(child)) {
-- GaimBlistNode *bnode;
-- gaim_blist_add_contact((GaimContact *)child, dest, prev);
-+ Gaim2BlistNode *bnode;
-+ gaim2_blist_add_contact((Gaim2Contact *)child, dest, prev);
- for (bnode = child->child; bnode != NULL; bnode = bnode->next) {
-- gaim_blist_add_buddy((GaimBuddy *)bnode, (GaimContact *)child,
-+ gaim2_blist_add_buddy((Gaim2Buddy *)bnode, (Gaim2Contact *)child,
- NULL, bnode->prev);
- moved_buddies = g_list_append(moved_buddies, bnode);
- }
- prev = child;
- } else if (GAIM_BLIST_NODE_IS_CHAT(child)) {
-- gaim_blist_add_chat((GaimChat *)child, dest, prev);
-+ gaim2_blist_add_chat((Gaim2Chat *)child, dest, prev);
- prev = child;
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "blist",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "blist",
- "Unknown child type in group %s\n", source->name);
- }
- child = next;
-@@ -997,13 +997,13 @@ void gaim_blist_rename_group(GaimGroup *
-
- /* Make a copy of the old group name and then delete the old group */
- old_name = g_strdup(source->name);
-- gaim_blist_remove_group(source);
-+ gaim2_blist_remove_group(source);
- } else {
- /* A simple rename */
-- GaimBlistNode *cnode, *bnode;
-+ Gaim2BlistNode *cnode, *bnode;
-
- /* Build a GList of all buddies in this group */
-- for (cnode = ((GaimBlistNode *)source)->child; cnode != NULL; cnode = cnode->next) {
-+ for (cnode = ((Gaim2BlistNode *)source)->child; cnode != NULL; cnode = cnode->next) {
- if (GAIM_BLIST_NODE_IS_CONTACT(cnode))
- for (bnode = cnode->child; bnode != NULL; bnode = bnode->next)
- moved_buddies = g_list_append(moved_buddies, bnode);
-@@ -1015,17 +1015,17 @@ void gaim_blist_rename_group(GaimGroup *
- }
-
- /* Save our changes */
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- /* Update the UI */
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode*)source);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode*)source);
-
- /* Notify all PRPLs */
- if(old_name && source && strcmp(source->name, old_name)) {
-- for (accts = gaim_group_get_accounts(source); accts; accts = g_slist_remove(accts, accts->data)) {
-- GaimAccount *account = accts->data;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ for (accts = gaim2_group_get_accounts(source); accts; accts = g_slist_remove(accts, accts->data)) {
-+ Gaim2Account *account = accts->data;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- GList *l = NULL, *buddies = NULL;
-
- if(account->gc && account->gc->prpl)
-@@ -1035,10 +1035,10 @@ void gaim_blist_rename_group(GaimGroup *
- continue;
-
- for(l = moved_buddies; l; l = l->next) {
-- GaimBuddy *buddy = (GaimBuddy *)l->data;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)l->data;
-
- if(buddy && buddy->account == account)
-- buddies = g_list_append(buddies, (GaimBlistNode *)buddy);
-+ buddies = g_list_append(buddies, (Gaim2BlistNode *)buddy);
- }
-
- if(prpl_info->rename_group) {
-@@ -1048,13 +1048,13 @@ void gaim_blist_rename_group(GaimGroup *
-
- /* Make a list of what the groups each buddy is in */
- for(cur = buddies; cur; cur = cur->next) {
-- GaimBlistNode *node = (GaimBlistNode *)cur->data;
-+ Gaim2BlistNode *node = (Gaim2BlistNode *)cur->data;
- groups = g_list_append(groups, node->parent->parent);
- }
-
-- gaim_account_remove_buddies(account, buddies, groups);
-+ gaim2_account_remove_buddies(account, buddies, groups);
- g_list_free(groups);
-- gaim_account_add_buddies(account, buddies);
-+ gaim2_account_add_buddies(account, buddies);
- }
-
- g_list_free(buddies);
-@@ -1064,83 +1064,83 @@ void gaim_blist_rename_group(GaimGroup *
- g_free(old_name);
- }
-
--static void gaim_blist_node_initialize_settings(GaimBlistNode *node);
-+static void gaim2_blist_node_initialize_settings(Gaim2BlistNode *node);
-
--GaimChat *gaim_chat_new(GaimAccount *account, const char *alias, GHashTable *components)
-+Gaim2Chat *gaim2_chat_new(Gaim2Account *account, const char *alias, GHashTable *components)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimChat *chat;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Chat *chat;
-
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(components != NULL, FALSE);
-
-- chat = g_new0(GaimChat, 1);
-+ chat = g_new0(Gaim2Chat, 1);
- chat->account = account;
- if ((alias != NULL) && (*alias != '\0'))
- chat->alias = g_strdup(alias);
- chat->components = components;
-- gaim_blist_node_initialize_settings((GaimBlistNode *)chat);
-- ((GaimBlistNode *)chat)->type = GAIM_BLIST_CHAT_NODE;
-+ gaim2_blist_node_initialize_settings((Gaim2BlistNode *)chat);
-+ ((Gaim2BlistNode *)chat)->type = GAIM_BLIST_CHAT_NODE;
-
- if (ops != NULL && ops->new_node != NULL)
-- ops->new_node((GaimBlistNode *)chat);
-+ ops->new_node((Gaim2BlistNode *)chat);
-
-- GAIM_DBUS_REGISTER_POINTER(chat, GaimChat);
-+ GAIM_DBUS_REGISTER_POINTER(chat, Gaim2Chat);
- return chat;
- }
-
--GaimBuddy *gaim_buddy_new(GaimAccount *account, const char *screenname, const char *alias)
-+Gaim2Buddy *gaim2_buddy_new(Gaim2Account *account, const char *screenname, const char *alias)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBuddy *buddy;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Buddy *buddy;
-
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(screenname != NULL, FALSE);
-
-- buddy = g_new0(GaimBuddy, 1);
-+ buddy = g_new0(Gaim2Buddy, 1);
- buddy->account = account;
- buddy->name = g_strdup(screenname);
- buddy->alias = g_strdup(alias);
-- buddy->presence = gaim_presence_new_for_buddy(buddy);
-- ((GaimBlistNode *)buddy)->type = GAIM_BLIST_BUDDY_NODE;
-+ buddy->presence = gaim2_presence_new_for_buddy(buddy);
-+ ((Gaim2BlistNode *)buddy)->type = GAIM_BLIST_BUDDY_NODE;
-
-- gaim_presence_set_status_active(buddy->presence, "offline", TRUE);
-+ gaim2_presence_set_status_active(buddy->presence, "offline", TRUE);
-
-- gaim_blist_node_initialize_settings((GaimBlistNode *)buddy);
-+ gaim2_blist_node_initialize_settings((Gaim2BlistNode *)buddy);
-
- if (ops && ops->new_node)
-- ops->new_node((GaimBlistNode *)buddy);
-+ ops->new_node((Gaim2BlistNode *)buddy);
-
-- GAIM_DBUS_REGISTER_POINTER(buddy, GaimBuddy);
-+ GAIM_DBUS_REGISTER_POINTER(buddy, Gaim2Buddy);
- return buddy;
- }
-
- void
--gaim_buddy_set_icon(GaimBuddy *buddy, GaimBuddyIcon *icon)
-+gaim2_buddy_set_icon(Gaim2Buddy *buddy, Gaim2BuddyIcon *icon)
- {
- g_return_if_fail(buddy != NULL);
-
- if (buddy->icon != icon) {
- if (buddy->icon != NULL)
-- gaim_buddy_icon_unref(buddy->icon);
-+ gaim2_buddy_icon_unref(buddy->icon);
-
-- buddy->icon = (icon != NULL ? gaim_buddy_icon_ref(icon) : NULL);
-+ buddy->icon = (icon != NULL ? gaim2_buddy_icon_ref(icon) : NULL);
- }
-
- if (buddy->icon)
-- gaim_buddy_icon_cache(icon, buddy);
-+ gaim2_buddy_icon_cache(icon, buddy);
- else
-- gaim_buddy_icon_uncache(buddy);
-+ gaim2_buddy_icon_uncache(buddy);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
-- gaim_signal_emit(gaim_blist_get_handle(), "buddy-icon-changed", buddy);
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "buddy-icon-changed", buddy);
-
-- gaim_blist_update_buddy_icon(buddy);
-+ gaim2_blist_update_buddy_icon(buddy);
- }
-
--GaimAccount *
--gaim_buddy_get_account(const GaimBuddy *buddy)
-+Gaim2Account *
-+gaim2_buddy_get_account(const Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
-@@ -1148,37 +1148,37 @@ gaim_buddy_get_account(const GaimBuddy *
- }
-
- const char *
--gaim_buddy_get_name(const GaimBuddy *buddy)
-+gaim2_buddy_get_name(const Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
- return buddy->name;
- }
-
--GaimBuddyIcon *
--gaim_buddy_get_icon(const GaimBuddy *buddy)
-+Gaim2BuddyIcon *
-+gaim2_buddy_get_icon(const Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
- return buddy->icon;
- }
-
--void gaim_blist_add_chat(GaimChat *chat, GaimGroup *group, GaimBlistNode *node)
-+void gaim2_blist_add_chat(Gaim2Chat *chat, Gaim2Group *group, Gaim2BlistNode *node)
- {
-- GaimBlistNode *cnode = (GaimBlistNode*)chat;
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistNode *cnode = (Gaim2BlistNode*)chat;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-
- g_return_if_fail(chat != NULL);
-- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT((GaimBlistNode *)chat));
-+ g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT((Gaim2BlistNode *)chat));
-
- if (node == NULL) {
- if (group == NULL) {
-- group = gaim_group_new(_("Chats"));
-- gaim_blist_add_group(group,
-- gaim_blist_get_last_sibling(gaimbuddylist->root));
-+ group = gaim2_group_new(_("Chats"));
-+ gaim2_blist_add_group(group,
-+ gaim2_blist_get_last_sibling(gaim2buddylist->root));
- }
- } else {
-- group = (GaimGroup*)node->parent;
-+ group = (Gaim2Group*)node->parent;
- }
-
- /* if we're moving to overtop of ourselves, do nothing */
-@@ -1189,10 +1189,10 @@ void gaim_blist_add_chat(GaimChat *chat,
- /* This chat was already in the list and is
- * being moved.
- */
-- ((GaimGroup *)cnode->parent)->totalsize--;
-- if (gaim_account_is_connected(chat->account)) {
-- ((GaimGroup *)cnode->parent)->online--;
-- ((GaimGroup *)cnode->parent)->currentsize--;
-+ ((Gaim2Group *)cnode->parent)->totalsize--;
-+ if (gaim2_account_is_connected(chat->account)) {
-+ ((Gaim2Group *)cnode->parent)->online--;
-+ ((Gaim2Group *)cnode->parent)->currentsize--;
- }
- if (cnode->next)
- cnode->next->prev = cnode->prev;
-@@ -1201,12 +1201,12 @@ void gaim_blist_add_chat(GaimChat *chat,
- if (cnode->parent->child == cnode)
- cnode->parent->child = cnode->next;
-
-- ops->remove(gaimbuddylist, cnode);
-+ ops->remove(gaim2buddylist, cnode);
- /* ops->remove() cleaned up the cnode's ui_data, so we need to
- * reinitialize it */
- ops->new_node(cnode);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- if (node != NULL) {
-@@ -1216,87 +1216,87 @@ void gaim_blist_add_chat(GaimChat *chat,
- cnode->prev = node;
- cnode->parent = node->parent;
- node->next = cnode;
-- ((GaimGroup *)node->parent)->totalsize++;
-- if (gaim_account_is_connected(chat->account)) {
-- ((GaimGroup *)node->parent)->online++;
-- ((GaimGroup *)node->parent)->currentsize++;
-+ ((Gaim2Group *)node->parent)->totalsize++;
-+ if (gaim2_account_is_connected(chat->account)) {
-+ ((Gaim2Group *)node->parent)->online++;
-+ ((Gaim2Group *)node->parent)->currentsize++;
- }
- } else {
-- if (((GaimBlistNode *)group)->child)
-- ((GaimBlistNode *)group)->child->prev = cnode;
-- cnode->next = ((GaimBlistNode *)group)->child;
-+ if (((Gaim2BlistNode *)group)->child)
-+ ((Gaim2BlistNode *)group)->child->prev = cnode;
-+ cnode->next = ((Gaim2BlistNode *)group)->child;
- cnode->prev = NULL;
-- ((GaimBlistNode *)group)->child = cnode;
-- cnode->parent = (GaimBlistNode *)group;
-+ ((Gaim2BlistNode *)group)->child = cnode;
-+ cnode->parent = (Gaim2BlistNode *)group;
- group->totalsize++;
-- if (gaim_account_is_connected(chat->account)) {
-+ if (gaim2_account_is_connected(chat->account)) {
- group->online++;
- group->currentsize++;
- }
- }
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode *)cnode);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode *)cnode);
- }
-
--void gaim_blist_add_buddy(GaimBuddy *buddy, GaimContact *contact, GaimGroup *group, GaimBlistNode *node)
-+void gaim2_blist_add_buddy(Gaim2Buddy *buddy, Gaim2Contact *contact, Gaim2Group *group, Gaim2BlistNode *node)
- {
-- GaimBlistNode *cnode, *bnode;
-- GaimGroup *g;
-- GaimContact *c;
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- struct _gaim_hbuddy *hb;
-+ Gaim2BlistNode *cnode, *bnode;
-+ Gaim2Group *g;
-+ Gaim2Contact *c;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ struct _gaim2_hbuddy *hb;
-
- g_return_if_fail(buddy != NULL);
-- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY((GaimBlistNode*)buddy));
-+ g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY((Gaim2BlistNode*)buddy));
-
-- bnode = (GaimBlistNode *)buddy;
-+ bnode = (Gaim2BlistNode *)buddy;
-
- /* if we're moving to overtop of ourselves, do nothing */
- if (bnode == node || (!node && bnode->parent &&
-- contact && bnode->parent == (GaimBlistNode*)contact
-+ contact && bnode->parent == (Gaim2BlistNode*)contact
- && bnode == bnode->parent->child))
- return;
-
- if (node && GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- c = (GaimContact*)node->parent;
-- g = (GaimGroup*)node->parent->parent;
-+ c = (Gaim2Contact*)node->parent;
-+ g = (Gaim2Group*)node->parent->parent;
- } else if (contact) {
- c = contact;
-- g = (GaimGroup *)((GaimBlistNode *)c)->parent;
-+ g = (Gaim2Group *)((Gaim2BlistNode *)c)->parent;
- } else {
- if (group) {
- g = group;
- } else {
-- g = gaim_group_new(_("Buddies"));
-- gaim_blist_add_group(g,
-- gaim_blist_get_last_sibling(gaimbuddylist->root));
-+ g = gaim2_group_new(_("Buddies"));
-+ gaim2_blist_add_group(g,
-+ gaim2_blist_get_last_sibling(gaim2buddylist->root));
- }
-- c = gaim_contact_new();
-- gaim_blist_add_contact(c, g,
-- gaim_blist_get_last_child((GaimBlistNode*)g));
-+ c = gaim2_contact_new();
-+ gaim2_blist_add_contact(c, g,
-+ gaim2_blist_get_last_child((Gaim2BlistNode*)g));
- }
-
-- cnode = (GaimBlistNode *)c;
-+ cnode = (Gaim2BlistNode *)c;
-
- if (bnode->parent) {
- if (GAIM_BUDDY_IS_ONLINE(buddy)) {
-- ((GaimContact*)bnode->parent)->online--;
-- if (((GaimContact*)bnode->parent)->online == 0)
-- ((GaimGroup*)bnode->parent->parent)->online--;
-- }
-- if (gaim_account_is_connected(buddy->account)) {
-- ((GaimContact*)bnode->parent)->currentsize--;
-- if (((GaimContact*)bnode->parent)->currentsize == 0)
-- ((GaimGroup*)bnode->parent->parent)->currentsize--;
-+ ((Gaim2Contact*)bnode->parent)->online--;
-+ if (((Gaim2Contact*)bnode->parent)->online == 0)
-+ ((Gaim2Group*)bnode->parent->parent)->online--;
-+ }
-+ if (gaim2_account_is_connected(buddy->account)) {
-+ ((Gaim2Contact*)bnode->parent)->currentsize--;
-+ if (((Gaim2Contact*)bnode->parent)->currentsize == 0)
-+ ((Gaim2Group*)bnode->parent->parent)->currentsize--;
- }
-- ((GaimContact*)bnode->parent)->totalsize--;
-+ ((Gaim2Contact*)bnode->parent)->totalsize--;
- /* the group totalsize will be taken care of by remove_contact below */
-
-- if (bnode->parent->parent != (GaimBlistNode*)g)
-- serv_move_buddy(buddy, (GaimGroup *)bnode->parent->parent, g);
-+ if (bnode->parent->parent != (Gaim2BlistNode*)g)
-+ serv_move_buddy(buddy, (Gaim2Group *)bnode->parent->parent, g);
-
- if (bnode->next)
- bnode->next->prev = bnode->prev;
-@@ -1305,25 +1305,25 @@ void gaim_blist_add_buddy(GaimBuddy *bud
- if (bnode->parent->child == bnode)
- bnode->parent->child = bnode->next;
-
-- ops->remove(gaimbuddylist, bnode);
-+ ops->remove(gaim2buddylist, bnode);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
-- if (bnode->parent->parent != (GaimBlistNode*)g) {
-- hb = g_new(struct _gaim_hbuddy, 1);
-- hb->name = g_strdup(gaim_normalize(buddy->account, buddy->name));
-+ if (bnode->parent->parent != (Gaim2BlistNode*)g) {
-+ hb = g_new(struct _gaim2_hbuddy, 1);
-+ hb->name = g_strdup(gaim2_normalize(buddy->account, buddy->name));
- hb->account = buddy->account;
- hb->group = bnode->parent->parent;
-- g_hash_table_remove(gaimbuddylist->buddies, hb);
-+ g_hash_table_remove(gaim2buddylist->buddies, hb);
- g_free(hb->name);
- g_free(hb);
- }
-
- if (!bnode->parent->child) {
-- gaim_blist_remove_contact((GaimContact*)bnode->parent);
-+ gaim2_blist_remove_contact((Gaim2Contact*)bnode->parent);
- } else {
-- gaim_contact_invalidate_priority_buddy((GaimContact*)bnode->parent);
-- ops->update(gaimbuddylist, bnode->parent);
-+ gaim2_contact_invalidate_priority_buddy((Gaim2Contact*)bnode->parent);
-+ ops->update(gaim2buddylist, bnode->parent);
- }
- }
-
-@@ -1344,56 +1344,56 @@ void gaim_blist_add_buddy(GaimBuddy *bud
- }
-
- if (GAIM_BUDDY_IS_ONLINE(buddy)) {
-- ((GaimContact*)bnode->parent)->online++;
-- if (((GaimContact*)bnode->parent)->online == 1)
-- ((GaimGroup*)bnode->parent->parent)->online++;
-- }
-- if (gaim_account_is_connected(buddy->account)) {
-- ((GaimContact*)bnode->parent)->currentsize++;
-- if (((GaimContact*)bnode->parent)->currentsize == 1)
-- ((GaimGroup*)bnode->parent->parent)->currentsize++;
-+ ((Gaim2Contact*)bnode->parent)->online++;
-+ if (((Gaim2Contact*)bnode->parent)->online == 1)
-+ ((Gaim2Group*)bnode->parent->parent)->online++;
-+ }
-+ if (gaim2_account_is_connected(buddy->account)) {
-+ ((Gaim2Contact*)bnode->parent)->currentsize++;
-+ if (((Gaim2Contact*)bnode->parent)->currentsize == 1)
-+ ((Gaim2Group*)bnode->parent->parent)->currentsize++;
- }
-- ((GaimContact*)bnode->parent)->totalsize++;
-+ ((Gaim2Contact*)bnode->parent)->totalsize++;
-
-- hb = g_new(struct _gaim_hbuddy, 1);
-- hb->name = g_strdup(gaim_normalize(buddy->account, buddy->name));
-+ hb = g_new(struct _gaim2_hbuddy, 1);
-+ hb->name = g_strdup(gaim2_normalize(buddy->account, buddy->name));
- hb->account = buddy->account;
-- hb->group = ((GaimBlistNode*)buddy)->parent->parent;
-+ hb->group = ((Gaim2BlistNode*)buddy)->parent->parent;
-
-- g_hash_table_replace(gaimbuddylist->buddies, hb, buddy);
-+ g_hash_table_replace(gaim2buddylist->buddies, hb, buddy);
-
-- gaim_contact_invalidate_priority_buddy(gaim_buddy_get_contact(buddy));
-+ gaim2_contact_invalidate_priority_buddy(gaim2_buddy_get_contact(buddy));
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode*)buddy);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode*)buddy);
-
- /* Signal that the buddy has been added */
-- gaim_signal_emit(gaim_blist_get_handle(), "buddy-added", buddy);
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "buddy-added", buddy);
- }
-
--GaimContact *gaim_contact_new()
-+Gaim2Contact *gaim2_contact_new()
- {
-- GaimBlistUiOps *ops = gaim_blist_get_ui_ops();
-+ Gaim2BlistUiOps *ops = gaim2_blist_get_ui_ops();
-
-- GaimContact *contact = g_new0(GaimContact, 1);
-+ Gaim2Contact *contact = g_new0(Gaim2Contact, 1);
- contact->totalsize = 0;
- contact->currentsize = 0;
- contact->online = 0;
-- gaim_blist_node_initialize_settings((GaimBlistNode *)contact);
-- ((GaimBlistNode *)contact)->type = GAIM_BLIST_CONTACT_NODE;
-+ gaim2_blist_node_initialize_settings((Gaim2BlistNode *)contact);
-+ ((Gaim2BlistNode *)contact)->type = GAIM_BLIST_CONTACT_NODE;
-
- if (ops && ops->new_node)
-- ops->new_node((GaimBlistNode *)contact);
-+ ops->new_node((Gaim2BlistNode *)contact);
-
-- GAIM_DBUS_REGISTER_POINTER(contact, GaimContact);
-+ GAIM_DBUS_REGISTER_POINTER(contact, Gaim2Contact);
- return contact;
- }
-
--void gaim_contact_set_alias(GaimContact *contact, const char *alias)
-+void gaim2_contact_set_alias(Gaim2Contact *contact, const char *alias)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
- char *old_alias = contact->alias;
-
- g_return_if_fail(contact != NULL);
-@@ -1403,105 +1403,105 @@ void gaim_contact_set_alias(GaimContact
- else
- contact->alias = NULL;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update)
-- ops->update(gaimbuddylist, (GaimBlistNode*)contact);
-+ ops->update(gaim2buddylist, (Gaim2BlistNode*)contact);
-
-- gaim_signal_emit(gaim_blist_get_handle(), "blist-node-aliased",
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "blist-node-aliased",
- contact, old_alias);
- g_free(old_alias);
- }
-
--const char *gaim_contact_get_alias(GaimContact* contact)
-+const char *gaim2_contact_get_alias(Gaim2Contact* contact)
- {
- g_return_val_if_fail(contact != NULL, NULL);
-
- if (contact->alias)
- return contact->alias;
-
-- return gaim_buddy_get_alias(gaim_contact_get_priority_buddy(contact));
-+ return gaim2_buddy_get_alias(gaim2_contact_get_priority_buddy(contact));
- }
-
--gboolean gaim_contact_on_account(GaimContact *c, GaimAccount *account)
-+gboolean gaim2_contact_on_account(Gaim2Contact *c, Gaim2Account *account)
- {
-- GaimBlistNode *bnode, *cnode = (GaimBlistNode *) c;
-+ Gaim2BlistNode *bnode, *cnode = (Gaim2BlistNode *) c;
-
- g_return_val_if_fail(c != NULL, FALSE);
- g_return_val_if_fail(account != NULL, FALSE);
-
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- if (! GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
- if (buddy->account == account)
- return TRUE;
- }
- return FALSE;
- }
-
--void gaim_contact_invalidate_priority_buddy(GaimContact *contact)
-+void gaim2_contact_invalidate_priority_buddy(Gaim2Contact *contact)
- {
- g_return_if_fail(contact != NULL);
-
- contact->priority_valid = FALSE;
- }
-
--GaimGroup *gaim_group_new(const char *name)
-+Gaim2Group *gaim2_group_new(const char *name)
- {
-- GaimBlistUiOps *ops = gaim_blist_get_ui_ops();
-- GaimGroup *group;
-+ Gaim2BlistUiOps *ops = gaim2_blist_get_ui_ops();
-+ Gaim2Group *group;
-
- g_return_val_if_fail(name != NULL, NULL);
- g_return_val_if_fail(*name != '\0', NULL);
-
-- group = gaim_find_group(name);
-+ group = gaim2_find_group(name);
- if (group != NULL)
- return group;
-
-- group = g_new0(GaimGroup, 1);
-+ group = g_new0(Gaim2Group, 1);
- group->name = g_strdup(name);
- group->totalsize = 0;
- group->currentsize = 0;
- group->online = 0;
-- gaim_blist_node_initialize_settings((GaimBlistNode *)group);
-- ((GaimBlistNode *)group)->type = GAIM_BLIST_GROUP_NODE;
-+ gaim2_blist_node_initialize_settings((Gaim2BlistNode *)group);
-+ ((Gaim2BlistNode *)group)->type = GAIM_BLIST_GROUP_NODE;
-
- if (ops && ops->new_node)
-- ops->new_node((GaimBlistNode *)group);
-+ ops->new_node((Gaim2BlistNode *)group);
-
-- GAIM_DBUS_REGISTER_POINTER(group, GaimGroup);
-+ GAIM_DBUS_REGISTER_POINTER(group, Gaim2Group);
- return group;
- }
-
--void gaim_blist_add_contact(GaimContact *contact, GaimGroup *group, GaimBlistNode *node)
-+void gaim2_blist_add_contact(Gaim2Contact *contact, Gaim2Group *group, Gaim2BlistNode *node)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimGroup *g;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2Group *g;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
- g_return_if_fail(contact != NULL);
-- g_return_if_fail(GAIM_BLIST_NODE_IS_CONTACT((GaimBlistNode*)contact));
-+ g_return_if_fail(GAIM_BLIST_NODE_IS_CONTACT((Gaim2BlistNode*)contact));
-
-- if ((GaimBlistNode*)contact == node)
-+ if ((Gaim2BlistNode*)contact == node)
- return;
-
- if (node && (GAIM_BLIST_NODE_IS_CONTACT(node) ||
- GAIM_BLIST_NODE_IS_CHAT(node)))
-- g = (GaimGroup*)node->parent;
-+ g = (Gaim2Group*)node->parent;
- else if (group)
- g = group;
- else {
-- g = gaim_group_new(_("Buddies"));
-- gaim_blist_add_group(g,
-- gaim_blist_get_last_sibling(gaimbuddylist->root));
-+ g = gaim2_group_new(_("Buddies"));
-+ gaim2_blist_add_group(g,
-+ gaim2_blist_get_last_sibling(gaim2buddylist->root));
- }
-
-- gnode = (GaimBlistNode*)g;
-- cnode = (GaimBlistNode*)contact;
-+ gnode = (Gaim2BlistNode*)g;
-+ cnode = (Gaim2BlistNode*)contact;
-
- if (cnode->parent) {
- if (cnode->parent->child == cnode)
-@@ -1514,22 +1514,22 @@ void gaim_blist_add_contact(GaimContact
- if (cnode->parent != gnode) {
- bnode = cnode->child;
- while (bnode) {
-- GaimBlistNode *next_bnode = bnode->next;
-- GaimBuddy *b = (GaimBuddy*)bnode;
-+ Gaim2BlistNode *next_bnode = bnode->next;
-+ Gaim2Buddy *b = (Gaim2Buddy*)bnode;
-
-- struct _gaim_hbuddy *hb = g_new(struct _gaim_hbuddy, 1);
-- hb->name = g_strdup(gaim_normalize(b->account, b->name));
-+ struct _gaim2_hbuddy *hb = g_new(struct _gaim2_hbuddy, 1);
-+ hb->name = g_strdup(gaim2_normalize(b->account, b->name));
- hb->account = b->account;
- hb->group = cnode->parent;
-
-- g_hash_table_remove(gaimbuddylist->buddies, hb);
-+ g_hash_table_remove(gaim2buddylist->buddies, hb);
-
-- if (!gaim_find_buddy_in_group(b->account, b->name, g)) {
-+ if (!gaim2_find_buddy_in_group(b->account, b->name, g)) {
- hb->group = gnode;
-- g_hash_table_replace(gaimbuddylist->buddies, hb, b);
-+ g_hash_table_replace(gaim2buddylist->buddies, hb, b);
-
- if (b->account->gc)
-- serv_move_buddy(b, (GaimGroup *)cnode->parent, g);
-+ serv_move_buddy(b, (Gaim2Group *)cnode->parent, g);
- } else {
- gboolean empty_contact = FALSE;
-
-@@ -1538,13 +1538,13 @@ void gaim_blist_add_contact(GaimContact
- g_free(hb->name);
- g_free(hb);
- if (b->account->gc)
-- gaim_account_remove_buddy(b->account, b, (GaimGroup *)cnode->parent);
-+ gaim2_account_remove_buddy(b->account, b, (Gaim2Group *)cnode->parent);
-
- if (!cnode->child->next)
- empty_contact = TRUE;
-- gaim_blist_remove_buddy(b);
-+ gaim2_blist_remove_buddy(b);
-
-- /** in gaim_blist_remove_buddy(), if the last buddy in a
-+ /** in gaim2_blist_remove_buddy(), if the last buddy in a
- * contact is removed, the contact is cleaned up and
- * g_free'd, so we mustn't try to reference bnode->next */
- if (empty_contact)
-@@ -1555,14 +1555,14 @@ void gaim_blist_add_contact(GaimContact
- }
-
- if (contact->online > 0)
-- ((GaimGroup*)cnode->parent)->online--;
-+ ((Gaim2Group*)cnode->parent)->online--;
- if (contact->currentsize > 0)
-- ((GaimGroup*)cnode->parent)->currentsize--;
-- ((GaimGroup*)cnode->parent)->totalsize--;
-+ ((Gaim2Group*)cnode->parent)->currentsize--;
-+ ((Gaim2Group*)cnode->parent)->totalsize--;
-
-- ops->remove(gaimbuddylist, cnode);
-+ ops->remove(gaim2buddylist, cnode);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- if (node && (GAIM_BLIST_NODE_IS_CONTACT(node) ||
-@@ -1588,30 +1588,30 @@ void gaim_blist_add_contact(GaimContact
- g->currentsize++;
- g->totalsize++;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && cnode->child)
-- ops->update(gaimbuddylist, cnode);
-+ ops->update(gaim2buddylist, cnode);
-
- for (bnode = cnode->child; bnode; bnode = bnode->next)
-- ops->update(gaimbuddylist, bnode);
-+ ops->update(gaim2buddylist, bnode);
- }
-
--void gaim_blist_merge_contact(GaimContact *source, GaimBlistNode *node)
-+void gaim2_blist_merge_contact(Gaim2Contact *source, Gaim2BlistNode *node)
- {
-- GaimBlistNode *sourcenode = (GaimBlistNode*)source;
-- GaimBlistNode *targetnode;
-- GaimBlistNode *prev, *cur, *next;
-- GaimContact *target;
-+ Gaim2BlistNode *sourcenode = (Gaim2BlistNode*)source;
-+ Gaim2BlistNode *targetnode;
-+ Gaim2BlistNode *prev, *cur, *next;
-+ Gaim2Contact *target;
-
- g_return_if_fail(source != NULL);
- g_return_if_fail(node != NULL);
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- target = (GaimContact *)node;
-- prev = gaim_blist_get_last_child(node);
-+ target = (Gaim2Contact *)node;
-+ prev = gaim2_blist_get_last_child(node);
- } else if (GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- target = (GaimContact *)node->parent;
-+ target = (Gaim2Contact *)node->parent;
- prev = node;
- } else {
- return;
-@@ -1620,31 +1620,31 @@ void gaim_blist_merge_contact(GaimContac
- if (source == target || !target)
- return;
-
-- targetnode = (GaimBlistNode *)target;
-+ targetnode = (Gaim2BlistNode *)target;
- next = sourcenode->child;
-
- while (next) {
- cur = next;
- next = cur->next;
- if (GAIM_BLIST_NODE_IS_BUDDY(cur)) {
-- gaim_blist_add_buddy((GaimBuddy *)cur, target, NULL, prev);
-+ gaim2_blist_add_buddy((Gaim2Buddy *)cur, target, NULL, prev);
- prev = cur;
- }
- }
- }
-
--void gaim_blist_add_group(GaimGroup *group, GaimBlistNode *node)
-+void gaim2_blist_add_group(Gaim2Group *group, Gaim2BlistNode *node)
- {
-- GaimBlistUiOps *ops;
-- GaimBlistNode *gnode = (GaimBlistNode*)group;
-+ Gaim2BlistUiOps *ops;
-+ Gaim2BlistNode *gnode = (Gaim2BlistNode*)group;
-
- g_return_if_fail(group != NULL);
-- g_return_if_fail(GAIM_BLIST_NODE_IS_GROUP((GaimBlistNode *)group));
-+ g_return_if_fail(GAIM_BLIST_NODE_IS_GROUP((Gaim2BlistNode *)group));
-
-- ops = gaimbuddylist->ui_ops;
-+ ops = gaim2buddylist->ui_ops;
-
-- if (!gaimbuddylist->root) {
-- gaimbuddylist->root = gnode;
-+ if (!gaim2buddylist->root) {
-+ gaim2buddylist->root = gnode;
- return;
- }
-
-@@ -1652,13 +1652,13 @@ void gaim_blist_add_group(GaimGroup *gro
- if (gnode == node)
- return;
-
-- if (gaim_find_group(group->name)) {
-+ if (gaim2_find_group(group->name)) {
- /* This is just being moved */
-
-- ops->remove(gaimbuddylist, (GaimBlistNode *)group);
-+ ops->remove(gaim2buddylist, (Gaim2BlistNode *)group);
-
-- if (gnode == gaimbuddylist->root)
-- gaimbuddylist->root = gnode->next;
-+ if (gnode == gaim2buddylist->root)
-+ gaim2buddylist->root = gnode->next;
- if (gnode->prev)
- gnode->prev->next = gnode->next;
- if (gnode->next)
-@@ -1672,30 +1672,30 @@ void gaim_blist_add_group(GaimGroup *gro
- node->next->prev = gnode;
- node->next = gnode;
- } else {
-- if (gaimbuddylist->root)
-- gaimbuddylist->root->prev = gnode;
-- gnode->next = gaimbuddylist->root;
-+ if (gaim2buddylist->root)
-+ gaim2buddylist->root->prev = gnode;
-+ gnode->next = gaim2buddylist->root;
- gnode->prev = NULL;
-- gaimbuddylist->root = gnode;
-+ gaim2buddylist->root = gnode;
- }
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- if (ops && ops->update) {
-- ops->update(gaimbuddylist, gnode);
-+ ops->update(gaim2buddylist, gnode);
- for (node = gnode->child; node; node = node->next)
-- ops->update(gaimbuddylist, node);
-+ ops->update(gaim2buddylist, node);
- }
- }
-
--void gaim_blist_remove_contact(GaimContact *contact)
-+void gaim2_blist_remove_contact(Gaim2Contact *contact)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBlistNode *node, *gnode;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2BlistNode *node, *gnode;
-
- g_return_if_fail(contact != NULL);
-
-- node = (GaimBlistNode *)contact;
-+ node = (Gaim2BlistNode *)contact;
- gnode = node->parent;
-
- if (node->child) {
-@@ -1705,14 +1705,14 @@ void gaim_blist_remove_contact(GaimConta
- * deleted.
- */
- while (node->child->next) {
-- gaim_blist_remove_buddy((GaimBuddy*)node->child);
-+ gaim2_blist_remove_buddy((Gaim2Buddy*)node->child);
- }
- /*
- * Remove the last buddy and trigger the deletion of the contact.
- * It would probably be cleaner if contact-deletion was done after
- * a timeout? Or if it had to be done manually, like below?
- */
-- gaim_blist_remove_buddy((GaimBuddy*)node->child);
-+ gaim2_blist_remove_buddy((Gaim2Buddy*)node->child);
- } else {
- /* Remove the node from its parent */
- if (gnode->child == node)
-@@ -1722,11 +1722,11 @@ void gaim_blist_remove_contact(GaimConta
- if (node->next)
- node->next->prev = node->prev;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- /* Update the UI */
- if (ops && ops->remove)
-- ops->remove(gaimbuddylist, node);
-+ ops->remove(gaim2buddylist, node);
-
- /* Delete the node */
- g_hash_table_destroy(contact->node.settings);
-@@ -1735,24 +1735,24 @@ void gaim_blist_remove_contact(GaimConta
- }
- }
-
--void gaim_blist_remove_buddy(GaimBuddy *buddy)
-+void gaim2_blist_remove_buddy(Gaim2Buddy *buddy)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBlistNode *node, *cnode, *gnode;
-- GaimContact *contact;
-- GaimGroup *group;
-- struct _gaim_hbuddy hb;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2BlistNode *node, *cnode, *gnode;
-+ Gaim2Contact *contact;
-+ Gaim2Group *group;
-+ struct _gaim2_hbuddy hb;
-
- g_return_if_fail(buddy != NULL);
-
-- node = (GaimBlistNode *)buddy;
-+ node = (Gaim2BlistNode *)buddy;
- cnode = node->parent;
- gnode = cnode->parent;
-- contact = (GaimContact *)cnode;
-- group = (GaimGroup *)gnode;
-+ contact = (Gaim2Contact *)cnode;
-+ group = (Gaim2Group *)gnode;
-
- /* Delete any buddy icon. */
-- gaim_buddy_icon_uncache(buddy);
-+ gaim2_buddy_icon_uncache(buddy);
-
- /* Remove the node from its parent */
- if (node->prev)
-@@ -1768,42 +1768,42 @@ void gaim_blist_remove_buddy(GaimBuddy *
- if (contact->online == 0)
- group->online--;
- }
-- if (gaim_account_is_connected(buddy->account)) {
-+ if (gaim2_account_is_connected(buddy->account)) {
- contact->currentsize--;
- if (contact->currentsize == 0)
- group->currentsize--;
- }
- contact->totalsize--;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- /* Re-sort the contact */
- if (contact->priority == buddy) {
-- gaim_contact_invalidate_priority_buddy(contact);
-+ gaim2_contact_invalidate_priority_buddy(contact);
- if (ops && ops->update)
-- ops->update(gaimbuddylist, cnode);
-+ ops->update(gaim2buddylist, cnode);
- }
-
- /* Remove this buddy from the buddies hash table */
-- hb.name = g_strdup(gaim_normalize(buddy->account, buddy->name));
-+ hb.name = g_strdup(gaim2_normalize(buddy->account, buddy->name));
- hb.account = buddy->account;
-- hb.group = ((GaimBlistNode*)buddy)->parent->parent;
-- g_hash_table_remove(gaimbuddylist->buddies, &hb);
-+ hb.group = ((Gaim2BlistNode*)buddy)->parent->parent;
-+ g_hash_table_remove(gaim2buddylist->buddies, &hb);
- g_free(hb.name);
-
- /* Update the UI */
- if (ops && ops->remove)
-- ops->remove(gaimbuddylist, node);
-+ ops->remove(gaim2buddylist, node);
-
- /* Signal that the buddy has been removed before freeing the memory for it */
-- gaim_signal_emit(gaim_blist_get_handle(), "buddy-removed", buddy);
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "buddy-removed", buddy);
-
- /* Delete the node */
- if (buddy->icon != NULL)
-- gaim_buddy_icon_unref(buddy->icon);
-+ gaim2_buddy_icon_unref(buddy->icon);
- g_hash_table_destroy(buddy->node.settings);
-- gaim_presence_remove_buddy(buddy->presence, buddy);
-- gaim_presence_destroy(buddy->presence);
-+ gaim2_presence_remove_buddy(buddy->presence, buddy);
-+ gaim2_presence_destroy(buddy->presence);
- g_free(buddy->name);
- g_free(buddy->alias);
- g_free(buddy->server_alias);
-@@ -1813,20 +1813,20 @@ void gaim_blist_remove_buddy(GaimBuddy *
-
- /* If the contact is empty then remove it */
- if (!cnode->child)
-- gaim_blist_remove_contact(contact);
-+ gaim2_blist_remove_contact(contact);
- }
-
--void gaim_blist_remove_chat(GaimChat *chat)
-+void gaim2_blist_remove_chat(Gaim2Chat *chat)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBlistNode *node, *gnode;
-- GaimGroup *group;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2BlistNode *node, *gnode;
-+ Gaim2Group *group;
-
- g_return_if_fail(chat != NULL);
-
-- node = (GaimBlistNode *)chat;
-+ node = (Gaim2BlistNode *)chat;
- gnode = node->parent;
-- group = (GaimGroup *)gnode;
-+ group = (Gaim2Group *)gnode;
-
- if (gnode != NULL)
- {
-@@ -1839,18 +1839,18 @@ void gaim_blist_remove_chat(GaimChat *ch
- node->next->prev = node->prev;
-
- /* Adjust size counts */
-- if (gaim_account_is_connected(chat->account)) {
-+ if (gaim2_account_is_connected(chat->account)) {
- group->online--;
- group->currentsize--;
- }
- group->totalsize--;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- /* Update the UI */
- if (ops && ops->remove)
-- ops->remove(gaimbuddylist, node);
-+ ops->remove(gaim2buddylist, node);
-
- /* Delete the node */
- g_hash_table_destroy(chat->components);
-@@ -1860,21 +1860,21 @@ void gaim_blist_remove_chat(GaimChat *ch
- g_free(chat);
- }
-
--void gaim_blist_remove_group(GaimGroup *group)
-+void gaim2_blist_remove_group(Gaim2Group *group)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBlistNode *node;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2BlistNode *node;
- GList *l;
-
- g_return_if_fail(group != NULL);
-
-- node = (GaimBlistNode *)group;
-+ node = (Gaim2BlistNode *)group;
-
- /* Make sure the group is empty */
- if (node->child) {
- char *buf;
- int count = 0;
-- GaimBlistNode *child;
-+ Gaim2BlistNode *child;
-
- for (child = node->child; child != NULL; child = child->next)
- count++;
-@@ -1888,32 +1888,32 @@ void gaim_blist_remove_group(GaimGroup *
- "not logged in. These buddies and "
- "the group were not removed.\n", count),
- count, group->name);
-- gaim_notify_error(NULL, NULL, _("Group not removed"), buf);
-+ gaim2_notify_error(NULL, NULL, _("Group not removed"), buf);
- g_free(buf);
- return;
- }
-
- /* Remove the node from its parent */
-- if (gaimbuddylist->root == node)
-- gaimbuddylist->root = node->next;
-+ if (gaim2buddylist->root == node)
-+ gaim2buddylist->root = node->next;
- if (node->prev)
- node->prev->next = node->next;
- if (node->next)
- node->next->prev = node->prev;
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- /* Update the UI */
- if (ops && ops->remove)
-- ops->remove(gaimbuddylist, node);
-+ ops->remove(gaim2buddylist, node);
-
- /* Remove the group from all accounts that are online */
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- {
-- GaimConnection *gc = (GaimConnection *)l->data;
-+ Gaim2Connection *gc = (Gaim2Connection *)l->data;
-
-- if (gaim_connection_get_state(gc) == GAIM_CONNECTED)
-- gaim_account_remove_group(gaim_connection_get_account(gc), group);
-+ if (gaim2_connection_get_state(gc) == GAIM_CONNECTED)
-+ gaim2_account_remove_group(gaim2_connection_get_account(gc), group);
- }
-
- /* Delete the node */
-@@ -1923,17 +1923,17 @@ void gaim_blist_remove_group(GaimGroup *
- g_free(group);
- }
-
--GaimBuddy *gaim_contact_get_priority_buddy(GaimContact *contact)
-+Gaim2Buddy *gaim2_contact_get_priority_buddy(Gaim2Contact *contact)
- {
- g_return_val_if_fail(contact != NULL, NULL);
-
- if (!contact->priority_valid)
-- gaim_contact_compute_priority_buddy(contact);
-+ gaim2_contact_compute_priority_buddy(contact);
-
- return contact->priority;
- }
-
--const char *gaim_buddy_get_alias_only(GaimBuddy *buddy)
-+const char *gaim2_buddy_get_alias_only(Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
-@@ -1949,9 +1949,9 @@ const char *gaim_buddy_get_alias_only(Ga
- }
-
-
--const char *gaim_buddy_get_contact_alias(GaimBuddy *buddy)
-+const char *gaim2_buddy_get_contact_alias(Gaim2Buddy *buddy)
- {
-- GaimContact *c;
-+ Gaim2Contact *c;
-
- g_return_val_if_fail(buddy != NULL, NULL);
-
-@@ -1961,7 +1961,7 @@ const char *gaim_buddy_get_contact_alias
- return buddy->alias;
-
- /* The contact alias */
-- c = gaim_buddy_get_contact(buddy);
-+ c = gaim2_buddy_get_contact(buddy);
- if ((c != NULL) && (c->alias != NULL))
- return c->alias;
-
-@@ -1974,7 +1974,7 @@ const char *gaim_buddy_get_contact_alias
- }
-
-
--const char *gaim_buddy_get_alias(GaimBuddy *buddy)
-+const char *gaim2_buddy_get_alias(Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
-@@ -1991,9 +1991,9 @@ const char *gaim_buddy_get_alias(GaimBud
- return buddy->name;
- }
-
--const char *gaim_buddy_get_local_alias(GaimBuddy *buddy)
-+const char *gaim2_buddy_get_local_alias(Gaim2Buddy *buddy)
- {
-- GaimContact *c;
-+ Gaim2Contact *c;
-
- g_return_val_if_fail(buddy != NULL, NULL);
-
-@@ -2003,7 +2003,7 @@ const char *gaim_buddy_get_local_alias(G
- return buddy->alias;
-
- /* The contact alias */
-- c = gaim_buddy_get_contact(buddy);
-+ c = gaim2_buddy_get_contact(buddy);
- if ((c != NULL) && (c->alias != NULL))
- return c->alias;
-
-@@ -2011,7 +2011,7 @@ const char *gaim_buddy_get_local_alias(G
- return buddy->name;
- }
-
--const char *gaim_chat_get_name(GaimChat *chat)
-+const char *gaim2_chat_get_name(Gaim2Chat *chat)
- {
- struct proto_chat_entry *pce;
- GList *parts, *tmp;
-@@ -2032,22 +2032,22 @@ const char *gaim_chat_get_name(GaimChat
- return ret;
- }
-
--GaimBuddy *gaim_find_buddy(GaimAccount *account, const char *name)
-+Gaim2Buddy *gaim2_find_buddy(Gaim2Account *account, const char *name)
- {
-- GaimBuddy *buddy;
-- struct _gaim_hbuddy hb;
-- GaimBlistNode *group;
-+ Gaim2Buddy *buddy;
-+ struct _gaim2_hbuddy hb;
-+ Gaim2BlistNode *group;
-
-- g_return_val_if_fail(gaimbuddylist != NULL, NULL);
-+ g_return_val_if_fail(gaim2buddylist != NULL, NULL);
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail((name != NULL) && (*name != '\0'), NULL);
-
- hb.account = account;
-- hb.name = g_strdup(gaim_normalize(account, name));
-+ hb.name = g_strdup(gaim2_normalize(account, name));
-
-- for (group = gaimbuddylist->root; group; group = group->next) {
-+ for (group = gaim2buddylist->root; group; group = group->next) {
- hb.group = group;
-- if ((buddy = g_hash_table_lookup(gaimbuddylist->buddies, &hb))) {
-+ if ((buddy = g_hash_table_lookup(gaim2buddylist->buddies, &hb))) {
- g_free(hb.name);
- return buddy;
- }
-@@ -2057,43 +2057,43 @@ GaimBuddy *gaim_find_buddy(GaimAccount *
- return NULL;
- }
-
--GaimBuddy *gaim_find_buddy_in_group(GaimAccount *account, const char *name,
-- GaimGroup *group)
-+Gaim2Buddy *gaim2_find_buddy_in_group(Gaim2Account *account, const char *name,
-+ Gaim2Group *group)
- {
-- struct _gaim_hbuddy hb;
-- GaimBuddy *ret;
-+ struct _gaim2_hbuddy hb;
-+ Gaim2Buddy *ret;
-
-- g_return_val_if_fail(gaimbuddylist != NULL, NULL);
-+ g_return_val_if_fail(gaim2buddylist != NULL, NULL);
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail((name != NULL) && (*name != '\0'), NULL);
-
-- hb.name = g_strdup(gaim_normalize(account, name));
-+ hb.name = g_strdup(gaim2_normalize(account, name));
- hb.account = account;
-- hb.group = (GaimBlistNode*)group;
-+ hb.group = (Gaim2BlistNode*)group;
-
-- ret = g_hash_table_lookup(gaimbuddylist->buddies, &hb);
-+ ret = g_hash_table_lookup(gaim2buddylist->buddies, &hb);
- g_free(hb.name);
-
- return ret;
- }
-
--GSList *gaim_find_buddies(GaimAccount *account, const char *name)
-+GSList *gaim2_find_buddies(Gaim2Account *account, const char *name)
- {
- struct buddy *buddy;
-- struct _gaim_hbuddy hb;
-- GaimBlistNode *node;
-+ struct _gaim2_hbuddy hb;
-+ Gaim2BlistNode *node;
- GSList *ret = NULL;
-
-- g_return_val_if_fail(gaimbuddylist != NULL, NULL);
-+ g_return_val_if_fail(gaim2buddylist != NULL, NULL);
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail((name != NULL) && (*name != '\0'), NULL);
-
-- hb.name = g_strdup(gaim_normalize(account, name));
-+ hb.name = g_strdup(gaim2_normalize(account, name));
- hb.account = account;
-
-- for (node = gaimbuddylist->root; node != NULL; node = node->next) {
-+ for (node = gaim2buddylist->root; node != NULL; node = node->next) {
- hb.group = node;
-- if ((buddy = g_hash_table_lookup(gaimbuddylist->buddies, &hb)) != NULL)
-+ if ((buddy = g_hash_table_lookup(gaim2buddylist->buddies, &hb)) != NULL)
- ret = g_slist_append(ret, buddy);
- }
- g_free(hb.name);
-@@ -2101,55 +2101,55 @@ GSList *gaim_find_buddies(GaimAccount *a
- return ret;
- }
-
--GaimGroup *gaim_find_group(const char *name)
-+Gaim2Group *gaim2_find_group(const char *name)
- {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
-
-- g_return_val_if_fail(gaimbuddylist != NULL, NULL);
-+ g_return_val_if_fail(gaim2buddylist != NULL, NULL);
- g_return_val_if_fail((name != NULL) && (*name != '\0'), NULL);
-
-- for (node = gaimbuddylist->root; node != NULL; node = node->next) {
-- if (!strcmp(((GaimGroup *)node)->name, name))
-- return (GaimGroup *)node;
-+ for (node = gaim2buddylist->root; node != NULL; node = node->next) {
-+ if (!strcmp(((Gaim2Group *)node)->name, name))
-+ return (Gaim2Group *)node;
- }
-
- return NULL;
- }
-
--GaimChat *
--gaim_blist_find_chat(GaimAccount *account, const char *name)
-+Gaim2Chat *
-+gaim2_blist_find_chat(Gaim2Account *account, const char *name)
- {
- char *chat_name;
-- GaimChat *chat;
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Chat *chat;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- struct proto_chat_entry *pce;
-- GaimBlistNode *node, *group;
-+ Gaim2BlistNode *node, *group;
- GList *parts;
-
-- g_return_val_if_fail(gaimbuddylist != NULL, NULL);
-+ g_return_val_if_fail(gaim2buddylist != NULL, NULL);
- g_return_val_if_fail((name != NULL) && (*name != '\0'), NULL);
-
-- if (!gaim_account_is_connected(account))
-+ if (!gaim2_account_is_connected(account))
- return NULL;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-
- if (prpl_info->find_blist_chat != NULL)
- return prpl_info->find_blist_chat(account, name);
-
-- for (group = gaimbuddylist->root; group != NULL; group = group->next) {
-+ for (group = gaim2buddylist->root; group != NULL; group = group->next) {
- for (node = group->child; node != NULL; node = node->next) {
- if (GAIM_BLIST_NODE_IS_CHAT(node)) {
-
-- chat = (GaimChat*)node;
-+ chat = (Gaim2Chat*)node;
-
- if (account != chat->account)
- continue;
-
- parts = prpl_info->chat_info(
-- gaim_account_get_connection(chat->account));
-+ gaim2_account_get_connection(chat->account));
-
- pce = parts->data;
- chat_name = g_hash_table_lookup(chat->components,
-@@ -2167,53 +2167,53 @@ gaim_blist_find_chat(GaimAccount *accoun
- return NULL;
- }
-
--GaimGroup *
--gaim_chat_get_group(GaimChat *chat)
-+Gaim2Group *
-+gaim2_chat_get_group(Gaim2Chat *chat)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-- return (GaimGroup *)(((GaimBlistNode *)chat)->parent);
-+ return (Gaim2Group *)(((Gaim2BlistNode *)chat)->parent);
- }
-
--GaimContact *gaim_buddy_get_contact(GaimBuddy *buddy)
-+Gaim2Contact *gaim2_buddy_get_contact(Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
-- return (GaimContact*)((GaimBlistNode*)buddy)->parent;
-+ return (Gaim2Contact*)((Gaim2BlistNode*)buddy)->parent;
- }
-
--GaimPresence *gaim_buddy_get_presence(const GaimBuddy *buddy)
-+Gaim2Presence *gaim2_buddy_get_presence(const Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
- return buddy->presence;
- }
-
--GaimGroup *gaim_buddy_get_group(GaimBuddy *buddy)
-+Gaim2Group *gaim2_buddy_get_group(Gaim2Buddy *buddy)
- {
- g_return_val_if_fail(buddy != NULL, NULL);
-
-- if (((GaimBlistNode *)buddy)->parent == NULL)
-+ if (((Gaim2BlistNode *)buddy)->parent == NULL)
- return NULL;
-
-- return (GaimGroup *)(((GaimBlistNode*)buddy)->parent->parent);
-+ return (Gaim2Group *)(((Gaim2BlistNode*)buddy)->parent->parent);
- }
-
--GSList *gaim_group_get_accounts(GaimGroup *group)
-+GSList *gaim2_group_get_accounts(Gaim2Group *group)
- {
- GSList *l = NULL;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
-- gnode = (GaimBlistNode *)group;
-+ gnode = (Gaim2BlistNode *)group;
-
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if (GAIM_BLIST_NODE_IS_CHAT(cnode)) {
-- if (!g_slist_find(l, ((GaimChat *)cnode)->account))
-- l = g_slist_append(l, ((GaimChat *)cnode)->account);
-+ if (!g_slist_find(l, ((Gaim2Chat *)cnode)->account))
-+ l = g_slist_append(l, ((Gaim2Chat *)cnode)->account);
- } else if (GAIM_BLIST_NODE_IS_CONTACT(cnode)) {
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
- if (GAIM_BLIST_NODE_IS_BUDDY(bnode)) {
-- if (!g_slist_find(l, ((GaimBuddy *)bnode)->account))
-- l = g_slist_append(l, ((GaimBuddy *)bnode)->account);
-+ if (!g_slist_find(l, ((Gaim2Buddy *)bnode)->account))
-+ l = g_slist_append(l, ((Gaim2Buddy *)bnode)->account);
- }
- }
- }
-@@ -2222,17 +2222,17 @@ GSList *gaim_group_get_accounts(GaimGrou
- return l;
- }
-
--void gaim_blist_add_account(GaimAccount *account)
-+void gaim2_blist_add_account(Gaim2Account *account)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
-- g_return_if_fail(gaimbuddylist != NULL);
-+ g_return_if_fail(gaim2buddylist != NULL);
-
- if (!ops || !ops->update)
- return;
-
-- for (gnode = gaimbuddylist->root; gnode; gnode = gnode->next) {
-+ for (gnode = gaim2buddylist->root; gnode; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
-@@ -2240,70 +2240,70 @@ void gaim_blist_add_account(GaimAccount
- gboolean recompute = FALSE;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
- if (GAIM_BLIST_NODE_IS_BUDDY(bnode) &&
-- ((GaimBuddy*)bnode)->account == account) {
-+ ((Gaim2Buddy*)bnode)->account == account) {
- recompute = TRUE;
-- ((GaimContact*)cnode)->currentsize++;
-- if (((GaimContact*)cnode)->currentsize == 1)
-- ((GaimGroup*)gnode)->currentsize++;
-- ops->update(gaimbuddylist, bnode);
-+ ((Gaim2Contact*)cnode)->currentsize++;
-+ if (((Gaim2Contact*)cnode)->currentsize == 1)
-+ ((Gaim2Group*)gnode)->currentsize++;
-+ ops->update(gaim2buddylist, bnode);
- }
- }
- if (recompute ||
-- gaim_blist_node_get_bool(cnode, "show_offline")) {
-- gaim_contact_invalidate_priority_buddy((GaimContact*)cnode);
-- ops->update(gaimbuddylist, cnode);
-+ gaim2_blist_node_get_bool(cnode, "show_offline")) {
-+ gaim2_contact_invalidate_priority_buddy((Gaim2Contact*)cnode);
-+ ops->update(gaim2buddylist, cnode);
- }
- } else if (GAIM_BLIST_NODE_IS_CHAT(cnode) &&
-- ((GaimChat*)cnode)->account == account) {
-- ((GaimGroup *)gnode)->online++;
-- ((GaimGroup *)gnode)->currentsize++;
-- ops->update(gaimbuddylist, cnode);
-+ ((Gaim2Chat*)cnode)->account == account) {
-+ ((Gaim2Group *)gnode)->online++;
-+ ((Gaim2Group *)gnode)->currentsize++;
-+ ops->update(gaim2buddylist, cnode);
- }
- }
-- ops->update(gaimbuddylist, gnode);
-+ ops->update(gaim2buddylist, gnode);
- }
- }
-
--void gaim_blist_remove_account(GaimAccount *account)
-+void gaim2_blist_remove_account(Gaim2Account *account)
- {
-- GaimBlistUiOps *ops = gaimbuddylist->ui_ops;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *buddy;
-- GaimChat *chat;
-- GaimContact *contact;
-- GaimGroup *group;
-+ Gaim2BlistUiOps *ops = gaim2buddylist->ui_ops;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *buddy;
-+ Gaim2Chat *chat;
-+ Gaim2Contact *contact;
-+ Gaim2Group *group;
- GList *list = NULL, *iter = NULL;
-
-- g_return_if_fail(gaimbuddylist != NULL);
-+ g_return_if_fail(gaim2buddylist != NULL);
-
-- for (gnode = gaimbuddylist->root; gnode; gnode = gnode->next) {
-+ for (gnode = gaim2buddylist->root; gnode; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-
-- group = (GaimGroup *)gnode;
-+ group = (Gaim2Group *)gnode;
-
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if (GAIM_BLIST_NODE_IS_CONTACT(cnode)) {
- gboolean recompute = FALSE;
-- contact = (GaimContact *)cnode;
-+ contact = (Gaim2Contact *)cnode;
-
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
- if (account == buddy->account) {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- recompute = TRUE;
-
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
-- if(gaim_presence_is_online(presence)) {
-+ if(gaim2_presence_is_online(presence)) {
- contact->online--;
- if (contact->online == 0)
- group->online--;
-
-- gaim_blist_node_set_int(&buddy->node,
-+ gaim2_blist_node_set_int(&buddy->node,
- "last_seen", time(NULL));
- }
-
-@@ -2315,23 +2315,23 @@ void gaim_blist_remove_account(GaimAccou
- list = g_list_prepend(list, presence);
-
- if (ops && ops->remove)
-- ops->remove(gaimbuddylist, bnode);
-+ ops->remove(gaim2buddylist, bnode);
- }
- }
- if (recompute) {
-- gaim_contact_invalidate_priority_buddy(contact);
-+ gaim2_contact_invalidate_priority_buddy(contact);
- if (ops && ops->update)
-- ops->update(gaimbuddylist, cnode);
-+ ops->update(gaim2buddylist, cnode);
- }
- } else if (GAIM_BLIST_NODE_IS_CHAT(cnode)) {
-- chat = (GaimChat *)cnode;
-+ chat = (Gaim2Chat *)cnode;
-
- if(chat->account == account) {
- group->currentsize--;
- group->online--;
-
- if (ops && ops->remove)
-- ops->remove(gaimbuddylist, cnode);
-+ ops->remove(gaim2buddylist, cnode);
- }
- }
- }
-@@ -2339,21 +2339,21 @@ void gaim_blist_remove_account(GaimAccou
-
- for (iter = list; iter; iter = iter->next)
- {
-- gaim_presence_set_status_active(iter->data, "offline", TRUE);
-+ gaim2_presence_set_status_active(iter->data, "offline", TRUE);
- }
- g_list_free(list);
- }
-
--gboolean gaim_group_on_account(GaimGroup *g, GaimAccount *account)
-+gboolean gaim2_group_on_account(Gaim2Group *g, Gaim2Account *account)
- {
-- GaimBlistNode *cnode;
-- for (cnode = ((GaimBlistNode *)g)->child; cnode; cnode = cnode->next) {
-+ Gaim2BlistNode *cnode;
-+ for (cnode = ((Gaim2BlistNode *)g)->child; cnode; cnode = cnode->next) {
- if (GAIM_BLIST_NODE_IS_CONTACT(cnode)) {
-- if(gaim_contact_on_account((GaimContact *) cnode, account))
-+ if(gaim2_contact_on_account((Gaim2Contact *) cnode, account))
- return TRUE;
- } else if (GAIM_BLIST_NODE_IS_CHAT(cnode)) {
-- GaimChat *chat = (GaimChat *)cnode;
-- if ((!account && gaim_account_is_connected(chat->account))
-+ Gaim2Chat *chat = (Gaim2Chat *)cnode;
-+ if ((!account && gaim2_account_is_connected(chat->account))
- || chat->account == account)
- return TRUE;
- }
-@@ -2362,60 +2362,60 @@ gboolean gaim_group_on_account(GaimGroup
- }
-
- void
--gaim_blist_request_add_buddy(GaimAccount *account, const char *username,
-+gaim2_blist_request_add_buddy(Gaim2Account *account, const char *username,
- const char *group, const char *alias)
- {
-- GaimBlistUiOps *ui_ops;
-+ Gaim2BlistUiOps *ui_ops;
-
-- ui_ops = gaim_blist_get_ui_ops();
-+ ui_ops = gaim2_blist_get_ui_ops();
-
- if (ui_ops != NULL && ui_ops->request_add_buddy != NULL)
- ui_ops->request_add_buddy(account, username, group, alias);
- }
-
- void
--gaim_blist_request_add_chat(GaimAccount *account, GaimGroup *group,
-+gaim2_blist_request_add_chat(Gaim2Account *account, Gaim2Group *group,
- const char *alias, const char *name)
- {
-- GaimBlistUiOps *ui_ops;
-+ Gaim2BlistUiOps *ui_ops;
-
-- ui_ops = gaim_blist_get_ui_ops();
-+ ui_ops = gaim2_blist_get_ui_ops();
-
- if (ui_ops != NULL && ui_ops->request_add_chat != NULL)
- ui_ops->request_add_chat(account, group, alias, name);
- }
-
- void
--gaim_blist_request_add_group(void)
-+gaim2_blist_request_add_group(void)
- {
-- GaimBlistUiOps *ui_ops;
-+ Gaim2BlistUiOps *ui_ops;
-
-- ui_ops = gaim_blist_get_ui_ops();
-+ ui_ops = gaim2_blist_get_ui_ops();
-
- if (ui_ops != NULL && ui_ops->request_add_group != NULL)
- ui_ops->request_add_group();
- }
-
- static void
--gaim_blist_node_setting_free(gpointer data)
-+gaim2_blist_node_setting_free(gpointer data)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
-- value = (GaimValue *)data;
-+ value = (Gaim2Value *)data;
-
-- gaim_value_destroy(value);
-+ gaim2_value_destroy(value);
- }
-
--static void gaim_blist_node_initialize_settings(GaimBlistNode *node)
-+static void gaim2_blist_node_initialize_settings(Gaim2BlistNode *node)
- {
- if (node->settings)
- return;
-
- node->settings = g_hash_table_new_full(g_str_hash, g_str_equal, g_free,
-- (GDestroyNotify)gaim_blist_node_setting_free);
-+ (GDestroyNotify)gaim2_blist_node_setting_free);
- }
-
--void gaim_blist_node_remove_setting(GaimBlistNode *node, const char *key)
-+void gaim2_blist_node_remove_setting(Gaim2BlistNode *node, const char *key)
- {
- g_return_if_fail(node != NULL);
- g_return_if_fail(node->settings != NULL);
-@@ -2423,19 +2423,19 @@ void gaim_blist_node_remove_setting(Gaim
-
- g_hash_table_remove(node->settings, key);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- void
--gaim_blist_node_set_flags(GaimBlistNode *node, GaimBlistNodeFlags flags)
-+gaim2_blist_node_set_flags(Gaim2BlistNode *node, Gaim2BlistNodeFlags flags)
- {
- g_return_if_fail(node != NULL);
-
- node->flags = flags;
- }
-
--GaimBlistNodeFlags
--gaim_blist_node_get_flags(GaimBlistNode *node)
-+Gaim2BlistNodeFlags
-+gaim2_blist_node_get_flags(Gaim2BlistNode *node)
- {
- g_return_val_if_fail(node != NULL, 0);
-
-@@ -2443,26 +2443,26 @@ gaim_blist_node_get_flags(GaimBlistNode
- }
-
- void
--gaim_blist_node_set_bool(GaimBlistNode* node, const char *key, gboolean data)
-+gaim2_blist_node_set_bool(Gaim2BlistNode* node, const char *key, gboolean data)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_if_fail(node != NULL);
- g_return_if_fail(node->settings != NULL);
- g_return_if_fail(key != NULL);
-
-- value = gaim_value_new(GAIM_TYPE_BOOLEAN);
-- gaim_value_set_boolean(value, data);
-+ value = gaim2_value_new(GAIM_TYPE_BOOLEAN);
-+ gaim2_value_set_boolean(value, data);
-
- g_hash_table_replace(node->settings, g_strdup(key), value);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- gboolean
--gaim_blist_node_get_bool(GaimBlistNode* node, const char *key)
-+gaim2_blist_node_get_bool(Gaim2BlistNode* node, const char *key)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_val_if_fail(node != NULL, FALSE);
- g_return_val_if_fail(node->settings != NULL, FALSE);
-@@ -2473,32 +2473,32 @@ gaim_blist_node_get_bool(GaimBlistNode*
- if (value == NULL)
- return FALSE;
-
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_BOOLEAN, FALSE);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_BOOLEAN, FALSE);
-
-- return gaim_value_get_boolean(value);
-+ return gaim2_value_get_boolean(value);
- }
-
- void
--gaim_blist_node_set_int(GaimBlistNode* node, const char *key, int data)
-+gaim2_blist_node_set_int(Gaim2BlistNode* node, const char *key, int data)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_if_fail(node != NULL);
- g_return_if_fail(node->settings != NULL);
- g_return_if_fail(key != NULL);
-
-- value = gaim_value_new(GAIM_TYPE_INT);
-- gaim_value_set_int(value, data);
-+ value = gaim2_value_new(GAIM_TYPE_INT);
-+ gaim2_value_set_int(value, data);
-
- g_hash_table_replace(node->settings, g_strdup(key), value);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- int
--gaim_blist_node_get_int(GaimBlistNode* node, const char *key)
-+gaim2_blist_node_get_int(Gaim2BlistNode* node, const char *key)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_val_if_fail(node != NULL, 0);
- g_return_val_if_fail(node->settings != NULL, 0);
-@@ -2509,32 +2509,32 @@ gaim_blist_node_get_int(GaimBlistNode* n
- if (value == NULL)
- return 0;
-
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_INT, 0);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_INT, 0);
-
-- return gaim_value_get_int(value);
-+ return gaim2_value_get_int(value);
- }
-
- void
--gaim_blist_node_set_string(GaimBlistNode* node, const char *key, const char *data)
-+gaim2_blist_node_set_string(Gaim2BlistNode* node, const char *key, const char *data)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_if_fail(node != NULL);
- g_return_if_fail(node->settings != NULL);
- g_return_if_fail(key != NULL);
-
-- value = gaim_value_new(GAIM_TYPE_STRING);
-- gaim_value_set_string(value, data);
-+ value = gaim2_value_new(GAIM_TYPE_STRING);
-+ gaim2_value_set_string(value, data);
-
- g_hash_table_replace(node->settings, g_strdup(key), value);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
- }
-
- const char *
--gaim_blist_node_get_string(GaimBlistNode* node, const char *key)
-+gaim2_blist_node_get_string(Gaim2BlistNode* node, const char *key)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_val_if_fail(node != NULL, NULL);
- g_return_val_if_fail(node->settings != NULL, NULL);
-@@ -2545,30 +2545,30 @@ gaim_blist_node_get_string(GaimBlistNode
- if (value == NULL)
- return NULL;
-
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_STRING, NULL);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_STRING, NULL);
-
-- return gaim_value_get_string(value);
-+ return gaim2_value_get_string(value);
- }
-
- GList *
--gaim_blist_node_get_extended_menu(GaimBlistNode *n)
-+gaim2_blist_node_get_extended_menu(Gaim2BlistNode *n)
- {
- GList *menu = NULL;
-
- g_return_val_if_fail(n != NULL, NULL);
-
-- gaim_signal_emit(gaim_blist_get_handle(),
-+ gaim2_signal_emit(gaim2_blist_get_handle(),
- "blist-node-extended-menu",
- n, &menu);
- return menu;
- }
-
--GaimBlistNodeAction *
--gaim_blist_node_action_new(char *label,
-- void (*callback)(GaimBlistNode *, gpointer),
-+Gaim2BlistNodeAction *
-+gaim2_blist_node_action_new(char *label,
-+ void (*callback)(Gaim2BlistNode *, gpointer),
- gpointer data, GList *children)
- {
-- GaimBlistNodeAction *act = g_new0(GaimBlistNodeAction, 1);
-+ Gaim2BlistNodeAction *act = g_new0(Gaim2BlistNodeAction, 1);
- act->label = label;
- act->callback = callback;
- act->data = data;
-@@ -2576,7 +2576,7 @@ gaim_blist_node_action_new(char *label,
- return act;
- }
-
--int gaim_blist_get_group_size(GaimGroup *group, gboolean offline)
-+int gaim2_blist_get_group_size(Gaim2Group *group, gboolean offline)
- {
- if (!group)
- return 0;
-@@ -2584,7 +2584,7 @@ int gaim_blist_get_group_size(GaimGroup
- return offline ? group->totalsize : group->currentsize;
- }
-
--int gaim_blist_get_group_online_count(GaimGroup *group)
-+int gaim2_blist_get_group_online_count(Gaim2Group *group)
- {
- if (!group)
- return 0;
-@@ -2593,20 +2593,20 @@ int gaim_blist_get_group_online_count(Ga
- }
-
- void
--gaim_blist_set_ui_ops(GaimBlistUiOps *ops)
-+gaim2_blist_set_ui_ops(Gaim2BlistUiOps *ops)
- {
- blist_ui_ops = ops;
- }
-
--GaimBlistUiOps *
--gaim_blist_get_ui_ops(void)
-+Gaim2BlistUiOps *
-+gaim2_blist_get_ui_ops(void)
- {
- return blist_ui_ops;
- }
-
-
- void *
--gaim_blist_get_handle(void)
-+gaim2_blist_get_handle(void)
- {
- static int handle;
-
-@@ -2614,78 +2614,78 @@ gaim_blist_get_handle(void)
- }
-
- void
--gaim_blist_init(void)
-+gaim2_blist_init(void)
- {
-- void *handle = gaim_blist_get_handle();
-+ void *handle = gaim2_blist_get_handle();
-
-- gaim_signal_register(handle, "buddy-status-changed",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL,
-+ gaim2_signal_register(handle, "buddy-status-changed",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL,
- 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_STATUS),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_STATUS));
-
-- gaim_signal_register(handle, "buddy-idle-changed",
-- gaim_marshal_VOID__POINTER_INT_INT, NULL,
-+ gaim2_signal_register(handle, "buddy-idle-changed",
-+ gaim2_marshal_VOID__POINTER_INT_INT, NULL,
- 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY),
-- gaim_value_new(GAIM_TYPE_INT),
-- gaim_value_new(GAIM_TYPE_INT));
-+ gaim2_value_new(GAIM_TYPE_INT),
-+ gaim2_value_new(GAIM_TYPE_INT));
-
-
-- gaim_signal_register(handle, "buddy-signed-on",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-signed-on",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY));
-
-- gaim_signal_register(handle, "buddy-signed-off",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-signed-off",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY));
-
-- gaim_signal_register(handle, "buddy-added",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-added",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY));
-
-- gaim_signal_register(handle, "buddy-removed",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-removed",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY));
-
-- gaim_signal_register(handle, "buddy-icon-changed",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-icon-changed",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_BUDDY));
-
-- gaim_signal_register(handle, "update-idle", gaim_marshal_VOID, NULL, 0);
-+ gaim2_signal_register(handle, "update-idle", gaim2_marshal_VOID, NULL, 0);
-
-- gaim_signal_register(handle, "blist-node-extended-menu",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "blist-node-extended-menu",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_NODE),
-- gaim_value_new(GAIM_TYPE_BOXED, "GList **"));
-+ gaim2_value_new(GAIM_TYPE_BOXED, "GList **"));
-
-- gaim_signal_register(handle, "blist-node-aliased",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "blist-node-aliased",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST_NODE),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
- }
-
- void
--gaim_blist_uninit(void)
-+gaim2_blist_uninit(void)
- {
- if (save_timer != 0)
- {
-- gaim_timeout_remove(save_timer);
-+ gaim2_timeout_remove(save_timer);
- save_timer = 0;
-- gaim_blist_sync();
-+ gaim2_blist_sync();
- }
-
-- gaim_signals_unregister_by_instance(gaim_blist_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_blist_get_handle());
- }
-diff -prNu ./src/blist.h ./src/blist.h
---- ./src/blist.h 2005-12-17 06:13:45.000000000 +0100
-+++ ./src/blist.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file blist.h Buddy List API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -29,16 +29,16 @@
-
- #include <glib.h>
-
--typedef struct _GaimBuddyList GaimBuddyList;
--typedef struct _GaimBlistUiOps GaimBlistUiOps;
--typedef struct _GaimBlistNode GaimBlistNode;
--
--typedef struct _GaimBlistNodeAction GaimBlistNodeAction;
--
--typedef struct _GaimChat GaimChat;
--typedef struct _GaimGroup GaimGroup;
--typedef struct _GaimContact GaimContact;
--typedef struct _GaimBuddy GaimBuddy;
-+typedef struct _Gaim2BuddyList Gaim2BuddyList;
-+typedef struct _Gaim2BlistUiOps Gaim2BlistUiOps;
-+typedef struct _Gaim2BlistNode Gaim2BlistNode;
-+
-+typedef struct _Gaim2BlistNodeAction Gaim2BlistNodeAction;
-+
-+typedef struct _Gaim2Chat Gaim2Chat;
-+typedef struct _Gaim2Group Gaim2Group;
-+typedef struct _Gaim2Contact Gaim2Contact;
-+typedef struct _Gaim2Buddy Gaim2Buddy;
-
- /**************************************************************************/
- /* Enumerations */
-@@ -51,7 +51,7 @@ typedef enum
- GAIM_BLIST_CHAT_NODE,
- GAIM_BLIST_OTHER_NODE
-
--} GaimBlistNodeType;
-+} Gaim2BlistNodeType;
-
- #define GAIM_BLIST_NODE_IS_CHAT(n) ((n)->type == GAIM_BLIST_CHAT_NODE)
- #define GAIM_BLIST_NODE_IS_BUDDY(n) ((n)->type == GAIM_BLIST_BUDDY_NODE)
-@@ -59,20 +59,20 @@ typedef enum
- #define GAIM_BLIST_NODE_IS_GROUP(n) ((n)->type == GAIM_BLIST_GROUP_NODE)
-
- #define GAIM_BUDDY_IS_ONLINE(b) \
-- ((b) != NULL && gaim_account_is_connected((b)->account) && \
-- gaim_presence_is_online(gaim_buddy_get_presence(b)))
-+ ((b) != NULL && gaim2_account_is_connected((b)->account) && \
-+ gaim2_presence_is_online(gaim2_buddy_get_presence(b)))
-
- typedef enum
- {
- GAIM_BLIST_NODE_FLAG_NO_SAVE = 1 /**< node should not be saved with the buddy list */
-
--} GaimBlistNodeFlags;
-+} Gaim2BlistNodeFlags;
-
- #define GAIM_BLIST_NODE_HAS_FLAG(b, f) ((b)->flags & (f))
- #define GAIM_BLIST_NODE_SHOULD_SAVE(b) (! GAIM_BLIST_NODE_HAS_FLAG(b, GAIM_BLIST_NODE_FLAG_NO_SAVE))
-
--#define GAIM_BLIST_NODE_NAME(n) ((n)->type == GAIM_BLIST_CHAT_NODE ? gaim_chat_get_name((GaimChat*)n) : \
-- (n)->type == GAIM_BLIST_BUDDY_NODE ? gaim_buddy_get_name((GaimBuddy*)n) : NULL)
-+#define GAIM_BLIST_NODE_NAME(n) ((n)->type == GAIM_BLIST_CHAT_NODE ? gaim2_chat_get_name((Gaim2Chat*)n) : \
-+ (n)->type == GAIM_BLIST_BUDDY_NODE ? gaim2_buddy_get_name((Gaim2Buddy*)n) : NULL)
-
- #include "account.h"
- #include "buddyicon.h"
-@@ -86,50 +86,50 @@ typedef enum
- * A Buddy list node. This can represent a group, a buddy, or anything else.
- * This is a base class for struct buddy and struct group and for anything
- * else that wants to put itself in the buddy list. */
--struct _GaimBlistNode {
-- GaimBlistNodeType type; /**< The type of node this is */
-- GaimBlistNode *prev; /**< The sibling before this buddy. */
-- GaimBlistNode *next; /**< The sibling after this buddy. */
-- GaimBlistNode *parent; /**< The parent of this node */
-- GaimBlistNode *child; /**< The child of this node */
-+struct _Gaim2BlistNode {
-+ Gaim2BlistNodeType type; /**< The type of node this is */
-+ Gaim2BlistNode *prev; /**< The sibling before this buddy. */
-+ Gaim2BlistNode *next; /**< The sibling after this buddy. */
-+ Gaim2BlistNode *parent; /**< The parent of this node */
-+ Gaim2BlistNode *child; /**< The child of this node */
- GHashTable *settings; /**< per-node settings */
- void *ui_data; /**< The UI can put data here. */
-- GaimBlistNodeFlags flags; /**< The buddy flags */
-+ Gaim2BlistNodeFlags flags; /**< The buddy flags */
- };
-
- /**
-- * A buddy. This contains everything Gaim will ever need to know about someone on the buddy list. Everything.
-+ * A buddy. This contains everything Gaim2 will ever need to know about someone on the buddy list. Everything.
- */
--struct _GaimBuddy {
-- GaimBlistNode node; /**< The node that this buddy inherits from */
-+struct _Gaim2Buddy {
-+ Gaim2BlistNode node; /**< The node that this buddy inherits from */
- char *name; /**< The screenname of the buddy. */
- char *alias; /**< The user-set alias of the buddy */
- char *server_alias; /**< The server-specified alias of the buddy. (i.e. MSN "Friendly Names") */
- void *proto_data; /**< This allows the prpl to associate whatever data it wants with a buddy */
-- GaimBuddyIcon *icon; /**< The buddy icon. */
-- GaimAccount *account; /**< the account this buddy belongs to */
-- GaimPresence *presence;
-+ Gaim2BuddyIcon *icon; /**< The buddy icon. */
-+ Gaim2Account *account; /**< the account this buddy belongs to */
-+ Gaim2Presence *presence;
- };
-
- /**
-- * A contact. This contains everything Gaim will ever need to know about a contact.
-+ * A contact. This contains everything Gaim2 will ever need to know about a contact.
- */
--struct _GaimContact {
-- GaimBlistNode node; /**< The node that this contact inherits from. */
-+struct _Gaim2Contact {
-+ Gaim2BlistNode node; /**< The node that this contact inherits from. */
- char *alias; /**< The user-set alias of the contact */
- int totalsize; /**< The number of buddies in this contact */
- int currentsize; /**< The number of buddies in this contact corresponding to online accounts */
- int online; /**< The number of buddies in this contact who are currently online */
-- GaimBuddy *priority; /**< The "top" buddy for this contact */
-+ Gaim2Buddy *priority; /**< The "top" buddy for this contact */
- gboolean priority_valid; /**< Is priority valid? */
- };
-
-
- /**
-- * A group. This contains everything Gaim will ever need to know about a group.
-+ * A group. This contains everything Gaim2 will ever need to know about a group.
- */
--struct _GaimGroup {
-- GaimBlistNode node; /**< The node that this group inherits from */
-+struct _Gaim2Group {
-+ Gaim2BlistNode node; /**< The node that this group inherits from */
- char *name; /**< The name of this group. */
- int totalsize; /**< The number of chats and contacts in this group */
- int currentsize; /**< The number of chats and contacts in this group corresponding to online accounts */
-@@ -137,24 +137,24 @@ struct _GaimGroup {
- };
-
- /**
-- * A chat. This contains everything Gaim needs to put a chat room in the
-+ * A chat. This contains everything Gaim2 needs to put a chat room in the
- * buddy list.
- */
--struct _GaimChat {
-- GaimBlistNode node; /**< The node that this chat inherits from */
-+struct _Gaim2Chat {
-+ Gaim2BlistNode node; /**< The node that this chat inherits from */
- char *alias; /**< The display name of this chat. */
- GHashTable *components; /**< the stuff the protocol needs to know to join the chat */
-- GaimAccount *account; /**< The account this chat is attached to */
-+ Gaim2Account *account; /**< The account this chat is attached to */
- };
-
-
- /**
- * The Buddy List
- */
--struct _GaimBuddyList {
-- GaimBlistNode *root; /**< The first node in the buddy list */
-+struct _Gaim2BuddyList {
-+ Gaim2BlistNode *root; /**< The first node in the buddy list */
- GHashTable *buddies; /**< Every buddy in this list */
-- GaimBlistUiOps *ui_ops; /**< The UI operations for the buddy list */
-+ Gaim2BlistUiOps *ui_ops; /**< The UI operations for the buddy list */
-
- void *ui_data; /**< UI-specific data. */
- };
-@@ -162,32 +162,32 @@ struct _GaimBuddyList {
- /**
- * Buddy list UI operations.
- *
-- * Any UI representing a buddy list must assign a filled-out GaimBlistUiOps
-+ * Any UI representing a buddy list must assign a filled-out Gaim2BlistUiOps
- * structure to the buddy list core.
- */
--struct _GaimBlistUiOps
-+struct _Gaim2BlistUiOps
- {
-- void (*new_list)(GaimBuddyList *list); /**< Sets UI-specific data on a buddy list. */
-- void (*new_node)(GaimBlistNode *node); /**< Sets UI-specific data on a node. */
-- void (*show)(GaimBuddyList *list); /**< The core will call this when it's finished doing its core stuff */
-- void (*update)(GaimBuddyList *list,
-- GaimBlistNode *node); /**< This will update a node in the buddy list. */
-- void (*remove)(GaimBuddyList *list,
-- GaimBlistNode *node); /**< This removes a node from the list */
-- void (*destroy)(GaimBuddyList *list); /**< When the list gets destroyed, this gets called to destroy the UI. */
-- void (*set_visible)(GaimBuddyList *list,
-+ void (*new_list)(Gaim2BuddyList *list); /**< Sets UI-specific data on a buddy list. */
-+ void (*new_node)(Gaim2BlistNode *node); /**< Sets UI-specific data on a node. */
-+ void (*show)(Gaim2BuddyList *list); /**< The core will call this when it's finished doing its core stuff */
-+ void (*update)(Gaim2BuddyList *list,
-+ Gaim2BlistNode *node); /**< This will update a node in the buddy list. */
-+ void (*remove)(Gaim2BuddyList *list,
-+ Gaim2BlistNode *node); /**< This removes a node from the list */
-+ void (*destroy)(Gaim2BuddyList *list); /**< When the list gets destroyed, this gets called to destroy the UI. */
-+ void (*set_visible)(Gaim2BuddyList *list,
- gboolean show); /**< Hides or unhides the buddy list */
-- void (*request_add_buddy)(GaimAccount *account, const char *username,
-+ void (*request_add_buddy)(Gaim2Account *account, const char *username,
- const char *group, const char *alias);
-- void (*request_add_chat)(GaimAccount *account, GaimGroup *group,
-+ void (*request_add_chat)(Gaim2Account *account, Gaim2Group *group,
- const char *alias, const char *name);
- void (*request_add_group)(void);
- };
-
-
--struct _GaimBlistNodeAction {
-+struct _Gaim2BlistNodeAction {
- char *label;
-- void (*callback)(GaimBlistNode *, gpointer);
-+ void (*callback)(Gaim2BlistNode *, gpointer);
- gpointer data;
- GList *children;
- };
-@@ -207,49 +207,49 @@ extern "C" {
- *
- * @return The new buddy list.
- */
--GaimBuddyList *gaim_blist_new(void);
-+Gaim2BuddyList *gaim2_blist_new(void);
-
- /**
- * Sets the main buddy list.
- *
- * @param blist The buddy list you want to use.
- */
--void gaim_set_blist(GaimBuddyList *blist);
-+void gaim2_set_blist(Gaim2BuddyList *blist);
-
- /**
- * Returns the main buddy list.
- *
- * @return The main buddy list.
- */
--GaimBuddyList *gaim_get_blist(void);
-+Gaim2BuddyList *gaim2_get_blist(void);
-
- /**
- * Returns the next node of a given node. This function is to be used to iterate
-- * over the tree returned by gaim_get_blist.
-+ * over the tree returned by gaim2_get_blist.
- *
- * @param node A node.
- * @param offline Whether to include nodes for offline accounts
- * @return The next node
- */
--GaimBlistNode *gaim_blist_node_next(GaimBlistNode *node, gboolean offline);
-+Gaim2BlistNode *gaim2_blist_node_next(Gaim2BlistNode *node, gboolean offline);
-
- /**
- * Shows the buddy list, creating a new one if necessary.
- */
--void gaim_blist_show(void);
-+void gaim2_blist_show(void);
-
-
- /**
- * Destroys the buddy list window.
- */
--void gaim_blist_destroy(void);
-+void gaim2_blist_destroy(void);
-
- /**
- * Hides or unhides the buddy list.
- *
- * @param show Whether or not to show the buddy list
- */
--void gaim_blist_set_visible(gboolean show);
-+void gaim2_blist_set_visible(gboolean show);
-
- /**
- * Updates a buddy's status.
-@@ -257,14 +257,14 @@ void gaim_blist_set_visible(gboolean sho
- * @param buddy The buddy whose status has changed.
- * @param old_status The status from which we are changing.
- */
--void gaim_blist_update_buddy_status(GaimBuddy *buddy, GaimStatus *old_status);
-+void gaim2_blist_update_buddy_status(Gaim2Buddy *buddy, Gaim2Status *old_status);
-
- /**
- * Updates a buddy's icon.
- *
- * @param buddy The buddy whose buddy icon has changed
- */
--void gaim_blist_update_buddy_icon(GaimBuddy *buddy);
-+void gaim2_blist_update_buddy_icon(Gaim2Buddy *buddy);
-
- /**
- * Renames a buddy in the buddy list.
-@@ -272,7 +272,7 @@ void gaim_blist_update_buddy_icon(GaimBu
- * @param buddy The buddy whose name will be changed.
- * @param name The new name of the buddy.
- */
--void gaim_blist_rename_buddy(GaimBuddy *buddy, const char *name);
-+void gaim2_blist_rename_buddy(Gaim2Buddy *buddy, const char *name);
-
- /**
- * Aliases a contact in the buddy list.
-@@ -280,7 +280,7 @@ void gaim_blist_rename_buddy(GaimBuddy *
- * @param contact The contact whose alias will be changed.
- * @param alias The contact's alias.
- */
--void gaim_blist_alias_contact(GaimContact *contact, const char *alias);
-+void gaim2_blist_alias_contact(Gaim2Contact *contact, const char *alias);
-
- /**
- * Aliases a buddy in the buddy list.
-@@ -288,7 +288,7 @@ void gaim_blist_alias_contact(GaimContac
- * @param buddy The buddy whose alias will be changed.
- * @param alias The buddy's alias.
- */
--void gaim_blist_alias_buddy(GaimBuddy *buddy, const char *alias);
-+void gaim2_blist_alias_buddy(Gaim2Buddy *buddy, const char *alias);
-
- /**
- * Sets the server-sent alias of a buddy in the buddy list.
-@@ -296,7 +296,7 @@ void gaim_blist_alias_buddy(GaimBuddy *b
- * @param buddy The buddy whose alias will be changed.
- * @param alias The buddy's "official" alias.
- */
--void gaim_blist_server_alias_buddy(GaimBuddy *buddy, const char *alias);
-+void gaim2_blist_server_alias_buddy(Gaim2Buddy *buddy, const char *alias);
-
- /**
- * Aliases a chat in the buddy list.
-@@ -304,7 +304,7 @@ void gaim_blist_server_alias_buddy(GaimB
- * @param chat The chat whose alias will be changed.
- * @param alias The chat's new alias.
- */
--void gaim_blist_alias_chat(GaimChat *chat, const char *alias);
-+void gaim2_blist_alias_chat(Gaim2Chat *chat, const char *alias);
-
- /**
- * Renames a group
-@@ -312,7 +312,7 @@ void gaim_blist_alias_chat(GaimChat *cha
- * @param group The group to rename
- * @param name The new name
- */
--void gaim_blist_rename_group(GaimGroup *group, const char *name);
-+void gaim2_blist_rename_group(Gaim2Group *group, const char *name);
-
- /**
- * Creates a new chat for the buddy list
-@@ -322,7 +322,7 @@ void gaim_blist_rename_group(GaimGroup *
- * @param components The info the prpl needs to join the chat
- * @return A newly allocated chat
- */
--GaimChat *gaim_chat_new(GaimAccount *account, const char *alias, GHashTable *components);
-+Gaim2Chat *gaim2_chat_new(Gaim2Account *account, const char *alias, GHashTable *components);
-
- /**
- * Adds a new chat to the buddy list.
-@@ -335,7 +335,7 @@ GaimChat *gaim_chat_new(GaimAccount *acc
- * @param group The group to add the new chat to.
- * @param node The insertion point
- */
--void gaim_blist_add_chat(GaimChat *chat, GaimGroup *group, GaimBlistNode *node);
-+void gaim2_blist_add_chat(Gaim2Chat *chat, Gaim2Group *group, Gaim2BlistNode *node);
-
- /**
- * Creates a new buddy
-@@ -345,20 +345,20 @@ void gaim_blist_add_chat(GaimChat *chat,
- * @param alias The alias of the new buddy (or NULL if unaliased)
- * @return A newly allocated buddy
- */
--GaimBuddy *gaim_buddy_new(GaimAccount *account, const char *screenname, const char *alias);
-+Gaim2Buddy *gaim2_buddy_new(Gaim2Account *account, const char *screenname, const char *alias);
-
- /**
- * Sets a buddy's icon.
- *
-- * This should only be called from within Gaim. You probably want to
-- * call gaim_buddy_icon_set_data().
-+ * This should only be called from within Gaim2. You probably want to
-+ * call gaim2_buddy_icon_set_data().
- *
- * @param buddy The buddy.
- * @param icon The buddy icon.
- *
-- * @see gaim_buddy_icon_set_data()
-+ * @see gaim2_buddy_icon_set_data()
- */
--void gaim_buddy_set_icon(GaimBuddy *buddy, GaimBuddyIcon *icon);
-+void gaim2_buddy_set_icon(Gaim2Buddy *buddy, Gaim2BuddyIcon *icon);
-
- /**
- * Returns a buddy's account.
-@@ -367,7 +367,7 @@ void gaim_buddy_set_icon(GaimBuddy *budd
- *
- * @return The account
- */
--GaimAccount *gaim_buddy_get_account(const GaimBuddy *buddy);
-+Gaim2Account *gaim2_buddy_get_account(const Gaim2Buddy *buddy);
-
- /**
- * Returns a buddy's name
-@@ -376,7 +376,7 @@ GaimAccount *gaim_buddy_get_account(cons
- *
- * @return The name.
- */
--const char *gaim_buddy_get_name(const GaimBuddy *buddy);
-+const char *gaim2_buddy_get_name(const Gaim2Buddy *buddy);
-
- /**
- * Returns a buddy's icon.
-@@ -385,7 +385,7 @@ const char *gaim_buddy_get_name(const Ga
- *
- * @return The buddy icon.
- */
--GaimBuddyIcon *gaim_buddy_get_icon(const GaimBuddy *buddy);
-+Gaim2BuddyIcon *gaim2_buddy_get_icon(const Gaim2Buddy *buddy);
-
- /**
- * Returns a buddy's contact.
-@@ -394,7 +394,7 @@ GaimBuddyIcon *gaim_buddy_get_icon(const
- *
- * @return The buddy's contact.
- */
--GaimContact *gaim_buddy_get_contact(GaimBuddy *buddy);
-+Gaim2Contact *gaim2_buddy_get_contact(Gaim2Buddy *buddy);
-
- /**
- * Returns a buddy's presence.
-@@ -403,7 +403,7 @@ GaimContact *gaim_buddy_get_contact(Gaim
- *
- * @return The buddy's presence.
- */
--GaimPresence *gaim_buddy_get_presence(const GaimBuddy *buddy);
-+Gaim2Presence *gaim2_buddy_get_presence(const Gaim2Buddy *buddy);
-
- /**
- * Adds a new buddy to the buddy list.
-@@ -417,7 +417,7 @@ GaimPresence *gaim_buddy_get_presence(co
- * @param group The group to add the new buddy to.
- * @param node The insertion point
- */
--void gaim_blist_add_buddy(GaimBuddy *buddy, GaimContact *contact, GaimGroup *group, GaimBlistNode *node);
-+void gaim2_blist_add_buddy(Gaim2Buddy *buddy, Gaim2Contact *contact, Gaim2Group *group, Gaim2BlistNode *node);
-
- /**
- * Creates a new group
-@@ -428,7 +428,7 @@ void gaim_blist_add_buddy(GaimBuddy *bud
- * @param name The name of the new group
- * @return A new group struct
- */
--GaimGroup *gaim_group_new(const char *name);
-+Gaim2Group *gaim2_group_new(const char *name);
-
- /**
- * Adds a new group to the buddy list.
-@@ -439,14 +439,14 @@ GaimGroup *gaim_group_new(const char *na
- * @param group The group
- * @param node The insertion point
- */
--void gaim_blist_add_group(GaimGroup *group, GaimBlistNode *node);
-+void gaim2_blist_add_group(Gaim2Group *group, Gaim2BlistNode *node);
-
- /**
- * Creates a new contact
- *
- * @return A new contact struct
- */
--GaimContact *gaim_contact_new(void);
-+Gaim2Contact *gaim2_contact_new(void);
-
- /**
- * Adds a new contact to the buddy list.
-@@ -458,7 +458,7 @@ GaimContact *gaim_contact_new(void);
- * @param group The group to add the contact to
- * @param node The insertion point
- */
--void gaim_blist_add_contact(GaimContact *contact, GaimGroup *group, GaimBlistNode *node);
-+void gaim2_blist_add_contact(Gaim2Contact *contact, Gaim2Group *group, Gaim2BlistNode *node);
-
- /**
- * Merges two contacts
-@@ -468,7 +468,7 @@ void gaim_blist_add_contact(GaimContact
- * @param source The contact to merge
- * @param node The place to merge to (a buddy or contact)
- */
--void gaim_blist_merge_contact(GaimContact *source, GaimBlistNode *node);
-+void gaim2_blist_merge_contact(Gaim2Contact *source, Gaim2BlistNode *node);
-
- /**
- * Returns the highest priority buddy for a given contact.
-@@ -476,7 +476,7 @@ void gaim_blist_merge_contact(GaimContac
- * @param contact The contact
- * @return The highest priority buddy
- */
--GaimBuddy *gaim_contact_get_priority_buddy(GaimContact *contact);
-+Gaim2Buddy *gaim2_contact_get_priority_buddy(Gaim2Contact *contact);
-
- /**
- * Sets the alias for a contact.
-@@ -484,7 +484,7 @@ GaimBuddy *gaim_contact_get_priority_bud
- * @param contact The contact
- * @param alias The alias to set, or NULL to unset
- */
--void gaim_contact_set_alias(GaimContact *contact, const char *alias);
-+void gaim2_contact_set_alias(Gaim2Contact *contact, const char *alias);
-
- /**
- * Gets the alias for a contact.
-@@ -492,7 +492,7 @@ void gaim_contact_set_alias(GaimContact
- * @param contact The contact
- * @return The alias, or NULL if it is not set.
- */
--const char *gaim_contact_get_alias(GaimContact *contact);
-+const char *gaim2_contact_get_alias(Gaim2Contact *contact);
-
- /**
- * Determines whether an account owns any buddies in a given contact
-@@ -502,21 +502,21 @@ const char *gaim_contact_get_alias(GaimC
- *
- * @return TRUE if there are any buddies from account in the contact, or FALSE otherwise.
- */
--gboolean gaim_contact_on_account(GaimContact *contact, GaimAccount *account);
-+gboolean gaim2_contact_on_account(Gaim2Contact *contact, Gaim2Account *account);
-
- /**
- * Invalidates the priority buddy so that the next call to
-- * gaim_contact_get_priority_buddy recomputes it.
-+ * gaim2_contact_get_priority_buddy recomputes it.
- *
- * @param contact The contact
- */
--void gaim_contact_invalidate_priority_buddy(GaimContact *contact);
-+void gaim2_contact_invalidate_priority_buddy(Gaim2Contact *contact);
- /**
- * Removes a buddy from the buddy list and frees the memory allocated to it.
- *
- * @param buddy The buddy to be removed
- */
--void gaim_blist_remove_buddy(GaimBuddy *buddy);
-+void gaim2_blist_remove_buddy(Gaim2Buddy *buddy);
-
- /**
- * Removes a contact, and any buddies it contains, and frees the memory
-@@ -524,14 +524,14 @@ void gaim_blist_remove_buddy(GaimBuddy *
- *
- * @param contact The contact to be removed
- */
--void gaim_blist_remove_contact(GaimContact *contact);
-+void gaim2_blist_remove_contact(Gaim2Contact *contact);
-
- /**
- * Removes a chat from the buddy list and frees the memory allocated to it.
- *
- * @param chat The chat to be removed
- */
--void gaim_blist_remove_chat(GaimChat *chat);
-+void gaim2_blist_remove_chat(Gaim2Chat *chat);
-
- /**
- * Removes a group from the buddy list and frees the memory allocated to it and to
-@@ -539,7 +539,7 @@ void gaim_blist_remove_chat(GaimChat *ch
- *
- * @param group The group to be removed
- */
--void gaim_blist_remove_group(GaimGroup *group);
-+void gaim2_blist_remove_group(Gaim2Group *group);
-
- /**
- * Returns the alias of a buddy.
-@@ -548,7 +548,7 @@ void gaim_blist_remove_group(GaimGroup *
- * @return The alias (if set), server alias (if set),
- * or NULL.
- */
--const char *gaim_buddy_get_alias_only(GaimBuddy *buddy);
-+const char *gaim2_buddy_get_alias_only(Gaim2Buddy *buddy);
-
-
- /**
-@@ -560,7 +560,7 @@ const char *gaim_buddy_get_alias_only(Ga
- * @return The appropriate name or alias, or NULL.
- *
- */
--const char *gaim_buddy_get_contact_alias(GaimBuddy *buddy);
-+const char *gaim2_buddy_get_contact_alias(Gaim2Buddy *buddy);
-
- /**
- * Returns the correct alias for this user, ignoring server aliases. Used
-@@ -570,7 +570,7 @@ const char *gaim_buddy_get_contact_alias
- * @param buddy The buddy whose alias will be returned.
- * @return The appropriate name or alias.
- */
--const char *gaim_buddy_get_local_alias(GaimBuddy *buddy);
-+const char *gaim2_buddy_get_local_alias(Gaim2Buddy *buddy);
-
- /**
- * Returns the correct name to display for a buddy. In order of precedence:
-@@ -580,7 +580,7 @@ const char *gaim_buddy_get_local_alias(G
- * @param buddy The buddy whose name will be returned.
- * @return The appropriate name or alias, or NULL
- */
--const char *gaim_buddy_get_alias(GaimBuddy *buddy);
-+const char *gaim2_buddy_get_alias(Gaim2Buddy *buddy);
-
- /**
- * Returns the correct name to display for a blist chat.
-@@ -588,7 +588,7 @@ const char *gaim_buddy_get_alias(GaimBud
- * @param chat The chat whose name will be returned.
- * @return The alias (if set), or first component value.
- */
--const char *gaim_chat_get_name(GaimChat *chat);
-+const char *gaim2_chat_get_name(Gaim2Chat *chat);
-
- /**
- * Finds the buddy struct given a screenname and an account
-@@ -597,7 +597,7 @@ const char *gaim_chat_get_name(GaimChat
- * @param name The buddy's screenname
- * @return The buddy or NULL if the buddy does not exist
- */
--GaimBuddy *gaim_find_buddy(GaimAccount *account, const char *name);
-+Gaim2Buddy *gaim2_find_buddy(Gaim2Account *account, const char *name);
-
- /**
- * Finds the buddy struct given a screenname, an account, and a group
-@@ -607,18 +607,18 @@ GaimBuddy *gaim_find_buddy(GaimAccount *
- * @param group The group to look in
- * @return The buddy or NULL if the buddy does not exist in the group
- */
--GaimBuddy *gaim_find_buddy_in_group(GaimAccount *account, const char *name,
-- GaimGroup *group);
-+Gaim2Buddy *gaim2_find_buddy_in_group(Gaim2Account *account, const char *name,
-+ Gaim2Group *group);
-
- /**
-- * Finds all GaimBuddy structs given a screenname and an account
-+ * Finds all Gaim2Buddy structs given a screenname and an account
- *
- * @param account The account this buddy belongs to
- * @param name The buddy's screenname
- *
- * @return A GSList of buddies (which must be freed), or NULL if the buddy doesn't exist
- */
--GSList *gaim_find_buddies(GaimAccount *account, const char *name);
-+GSList *gaim2_find_buddies(Gaim2Account *account, const char *name);
-
-
- /**
-@@ -627,7 +627,7 @@ GSList *gaim_find_buddies(GaimAccount *a
- * @param name The groups name
- * @return The group or NULL if the group does not exist
- */
--GaimGroup *gaim_find_group(const char *name);
-+Gaim2Group *gaim2_find_group(const char *name);
-
- /**
- * Finds a chat by name.
-@@ -637,7 +637,7 @@ GaimGroup *gaim_find_group(const char *n
- *
- * @return The chat, or @c NULL if the chat does not exist.
- */
--GaimChat *gaim_blist_find_chat(GaimAccount *account, const char *name);
-+Gaim2Chat *gaim2_blist_find_chat(Gaim2Account *account, const char *name);
-
- /**
- * Returns the group of which the chat is a member.
-@@ -646,7 +646,7 @@ GaimChat *gaim_blist_find_chat(GaimAccou
- *
- * @return The parent group, or @c NULL if the chat is not in a group.
- */
--GaimGroup *gaim_chat_get_group(GaimChat *chat);
-+Gaim2Group *gaim2_chat_get_group(Gaim2Chat *chat);
-
- /**
- * Returns the group of which the buddy is a member.
-@@ -654,7 +654,7 @@ GaimGroup *gaim_chat_get_group(GaimChat
- * @param buddy The buddy
- * @return The group or NULL if the buddy is not in a group
- */
--GaimGroup *gaim_buddy_get_group(GaimBuddy *buddy);
-+Gaim2Group *gaim2_buddy_get_group(Gaim2Buddy *buddy);
-
-
- /**
-@@ -662,9 +662,9 @@ GaimGroup *gaim_buddy_get_group(GaimBudd
- *
- * @param g The group
- *
-- * @return A list of gaim_accounts
-+ * @return A list of gaim2_accounts
- */
--GSList *gaim_group_get_accounts(GaimGroup *g);
-+GSList *gaim2_group_get_accounts(Gaim2Group *g);
-
- /**
- * Determines whether an account owns any buddies in a given group
-@@ -674,7 +674,7 @@ GSList *gaim_group_get_accounts(GaimGrou
- *
- * @return TRUE if there are any buddies in the group, or FALSE otherwise.
- */
--gboolean gaim_group_on_account(GaimGroup *g, GaimAccount *account);
-+gboolean gaim2_group_on_account(Gaim2Group *g, Gaim2Account *account);
-
- /**
- * Called when an account gets signed on. Tells the UI to update all the
-@@ -682,7 +682,7 @@ gboolean gaim_group_on_account(GaimGroup
- *
- * @param account The account
- */
--void gaim_blist_add_account(GaimAccount *account);
-+void gaim2_blist_add_account(Gaim2Account *account);
-
-
- /**
-@@ -691,7 +691,7 @@ void gaim_blist_add_account(GaimAccount
- *
- * @param account The account
- */
--void gaim_blist_remove_account(GaimAccount *account);
-+void gaim2_blist_remove_account(Gaim2Account *account);
-
-
- /**
-@@ -701,7 +701,7 @@ void gaim_blist_remove_account(GaimAccou
- * @param offline Count buddies in offline accounts
- * @return The number of buddies in the group
- */
--int gaim_blist_get_group_size(GaimGroup *group, gboolean offline);
-+int gaim2_blist_get_group_size(Gaim2Group *group, gboolean offline);
-
- /**
- * Determines the number of online buddies in a group
-@@ -709,7 +709,7 @@ int gaim_blist_get_group_size(GaimGroup
- * @param group The group
- * @return The number of online buddies in the group, or 0 if the group is NULL
- */
--int gaim_blist_get_group_online_count(GaimGroup *group);
-+int gaim2_blist_get_group_online_count(Gaim2Group *group);
-
- /*@}*/
-
-@@ -718,9 +718,9 @@ int gaim_blist_get_group_online_count(Ga
- /****************************************************************************************/
-
- /**
-- * Loads the buddy list from ~/.gaim/blist.xml.
-+ * Loads the buddy list from ~/.gaim2/blist.xml.
- */
--void gaim_blist_load(void);
-+void gaim2_blist_load(void);
-
- /**
- * Schedule a save of the blist.xml file. This is used by the privacy
-@@ -729,7 +729,7 @@ void gaim_blist_load(void);
- * the buddy list is saved automatically, so you should not need to
- * call this.
- */
--void gaim_blist_schedule_save(void);
-+void gaim2_blist_schedule_save(void);
-
- /**
- * Requests from the user information needed to add a buddy to the
-@@ -740,7 +740,7 @@ void gaim_blist_schedule_save(void);
- * @param group The name of the group to place the buddy in.
- * @param alias The optional alias for the buddy.
- */
--void gaim_blist_request_add_buddy(GaimAccount *account, const char *username,
-+void gaim2_blist_request_add_buddy(Gaim2Account *account, const char *username,
- const char *group, const char *alias);
-
- /**
-@@ -752,14 +752,14 @@ void gaim_blist_request_add_buddy(GaimAc
- * @param alias The optional alias for the chat.
- * @param name The required chat name.
- */
--void gaim_blist_request_add_chat(GaimAccount *account, GaimGroup *group,
-+void gaim2_blist_request_add_chat(Gaim2Account *account, Gaim2Group *group,
- const char *alias, const char *name);
-
- /**
- * Requests from the user information needed to add a group to the
- * buddy list.
- */
--void gaim_blist_request_add_group(void);
-+void gaim2_blist_request_add_group(void);
-
- /**
- * Associates a boolean with a node in the buddy list
-@@ -768,7 +768,7 @@ void gaim_blist_request_add_group(void);
- * @param key The identifier for the data
- * @param value The value to set
- */
--void gaim_blist_node_set_bool(GaimBlistNode *node, const char *key, gboolean value);
-+void gaim2_blist_node_set_bool(Gaim2BlistNode *node, const char *key, gboolean value);
-
- /**
- * Retrieves a named boolean setting from a node in the buddy list
-@@ -778,7 +778,7 @@ void gaim_blist_node_set_bool(GaimBlistN
- *
- * @return The value, or FALSE if there is no setting
- */
--gboolean gaim_blist_node_get_bool(GaimBlistNode *node, const char *key);
-+gboolean gaim2_blist_node_get_bool(Gaim2BlistNode *node, const char *key);
-
- /**
- * Associates an integer with a node in the buddy list
-@@ -787,7 +787,7 @@ gboolean gaim_blist_node_get_bool(GaimBl
- * @param key The identifier for the data
- * @param value The value to set
- */
--void gaim_blist_node_set_int(GaimBlistNode *node, const char *key, int value);
-+void gaim2_blist_node_set_int(Gaim2BlistNode *node, const char *key, int value);
-
- /**
- * Retrieves a named integer setting from a node in the buddy list
-@@ -797,7 +797,7 @@ void gaim_blist_node_set_int(GaimBlistNo
- *
- * @return The value, or 0 if there is no setting
- */
--int gaim_blist_node_get_int(GaimBlistNode *node, const char *key);
-+int gaim2_blist_node_get_int(Gaim2BlistNode *node, const char *key);
-
- /**
- * Associates a string with a node in the buddy list
-@@ -806,7 +806,7 @@ int gaim_blist_node_get_int(GaimBlistNod
- * @param key The identifier for the data
- * @param value The value to set
- */
--void gaim_blist_node_set_string(GaimBlistNode *node, const char *key,
-+void gaim2_blist_node_set_string(Gaim2BlistNode *node, const char *key,
- const char *value);
-
- /**
-@@ -817,7 +817,7 @@ void gaim_blist_node_set_string(GaimBlis
- *
- * @return The value, or NULL if there is no setting
- */
--const char *gaim_blist_node_get_string(GaimBlistNode *node, const char *key);
-+const char *gaim2_blist_node_get_string(Gaim2BlistNode *node, const char *key);
-
- /**
- * Removes a named setting from a blist node
-@@ -825,17 +825,17 @@ const char *gaim_blist_node_get_string(G
- * @param node The node from which to remove the setting
- * @param key The name of the setting
- */
--void gaim_blist_node_remove_setting(GaimBlistNode *node, const char *key);
-+void gaim2_blist_node_remove_setting(Gaim2BlistNode *node, const char *key);
-
- /**
- * Set the flags for the given node. Setting a node's flags will overwrite
- * the old flags, so if you want to save them, you must first call
-- * gaim_blist_node_get_flags and modify that appropriately.
-+ * gaim2_blist_node_get_flags and modify that appropriately.
- *
- * @param node The node on which to set the flags.
- * @param flags The flags to set. This is a bitmask.
- */
--void gaim_blist_node_set_flags(GaimBlistNode *node, GaimBlistNodeFlags flags);
-+void gaim2_blist_node_set_flags(Gaim2BlistNode *node, Gaim2BlistNodeFlags flags);
-
- /**
- * Get the current flags on a given node.
-@@ -844,7 +844,7 @@ void gaim_blist_node_set_flags(GaimBlist
- *
- * @return The flags on the node. This is a bitmask.
- */
--GaimBlistNodeFlags gaim_blist_node_get_flags(GaimBlistNode *node);
-+Gaim2BlistNodeFlags gaim2_blist_node_get_flags(Gaim2BlistNode *node);
-
- /*@}*/
-
-@@ -852,24 +852,24 @@ GaimBlistNodeFlags gaim_blist_node_get_f
- /**
- * Retrieves the extended menu items for a buddy list node.
- * @param n The blist node for which to obtain the extended menu items.
-- * @return A list of GaimBlistNodeAction items, as harvested by the
-+ * @return A list of Gaim2BlistNodeAction items, as harvested by the
- * blist-node-extended-menu signal.
- */
--GList *gaim_blist_node_get_extended_menu(GaimBlistNode *n);
-+GList *gaim2_blist_node_get_extended_menu(Gaim2BlistNode *n);
-
-
- /**
-- * Creates a new GaimBlistNodeAction.
-+ * Creates a new Gaim2BlistNodeAction.
- * @param label The text label to display for this action.
- * @param callback The function to be called when the action is used on
-- * a selected GaimBlistNode.
-+ * a selected Gaim2BlistNode.
- * @param data Additional data, to be passed to the callback
-- * @param children A GList of GaimBlistNodeActions to be added as a
-+ * @param children A GList of Gaim2BlistNodeActions to be added as a
- * submenu of the action.
-- * @return The GaimBlistNodeAction.
-+ * @return The Gaim2BlistNodeAction.
- */
--GaimBlistNodeAction *gaim_blist_node_action_new(char *label,
-- void (*callback)(GaimBlistNode *, gpointer), gpointer data,
-+Gaim2BlistNodeAction *gaim2_blist_node_action_new(char *label,
-+ void (*callback)(Gaim2BlistNode *, gpointer), gpointer data,
- GList *children);
-
-
-@@ -883,14 +883,14 @@ GaimBlistNodeAction *gaim_blist_node_act
- *
- * @param ops The ops struct.
- */
--void gaim_blist_set_ui_ops(GaimBlistUiOps *ops);
-+void gaim2_blist_set_ui_ops(Gaim2BlistUiOps *ops);
-
- /**
- * Returns the UI operations structure to be used for the buddy list.
- *
- * @return The UI operations structure.
- */
--GaimBlistUiOps *gaim_blist_get_ui_ops(void);
-+Gaim2BlistUiOps *gaim2_blist_get_ui_ops(void);
-
- /*@}*/
-
-@@ -904,17 +904,17 @@ GaimBlistUiOps *gaim_blist_get_ui_ops(vo
- *
- * @return The buddy list subsystem handle.
- */
--void *gaim_blist_get_handle(void);
-+void *gaim2_blist_get_handle(void);
-
- /**
- * Initializes the buddy list subsystem.
- */
--void gaim_blist_init(void);
-+void gaim2_blist_init(void);
-
- /**
- * Uninitializes the buddy list subsystem.
- */
--void gaim_blist_uninit(void);
-+void gaim2_blist_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/buddyicon.c ./src/buddyicon.c
---- ./src/buddyicon.c 2005-11-28 12:47:50.000000000 +0100
-+++ ./src/buddyicon.c 2006-01-05 15:11:07.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file icon.c Buddy Icon API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,16 +32,16 @@ static GHashTable *account_cache = NULL;
- static char *cache_dir = NULL;
- static gboolean icon_caching = TRUE;
-
--static GaimBuddyIcon *
--gaim_buddy_icon_create(GaimAccount *account, const char *username)
-+static Gaim2BuddyIcon *
-+gaim2_buddy_icon_create(Gaim2Account *account, const char *username)
- {
-- GaimBuddyIcon *icon;
-+ Gaim2BuddyIcon *icon;
- GHashTable *icon_cache;
-
-- icon = g_new0(GaimBuddyIcon, 1);
-+ icon = g_new0(Gaim2BuddyIcon, 1);
-
-- gaim_buddy_icon_set_account(icon, account);
-- gaim_buddy_icon_set_username(icon, username);
-+ gaim2_buddy_icon_set_account(icon, account);
-+ gaim2_buddy_icon_set_username(icon, username);
-
- icon_cache = g_hash_table_lookup(account_cache, account);
-
-@@ -53,30 +53,30 @@ gaim_buddy_icon_create(GaimAccount *acco
- }
-
- g_hash_table_insert(icon_cache,
-- (char *)gaim_buddy_icon_get_username(icon), icon);
-+ (char *)gaim2_buddy_icon_get_username(icon), icon);
- return icon;
- }
-
--GaimBuddyIcon *
--gaim_buddy_icon_new(GaimAccount *account, const char *username,
-+Gaim2BuddyIcon *
-+gaim2_buddy_icon_new(Gaim2Account *account, const char *username,
- void *icon_data, size_t icon_len)
- {
-- GaimBuddyIcon *icon;
-+ Gaim2BuddyIcon *icon;
-
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(username != NULL, NULL);
- g_return_val_if_fail(icon_data != NULL, NULL);
- g_return_val_if_fail(icon_len > 0, NULL);
-
-- icon = gaim_buddy_icons_find(account, username);
-+ icon = gaim2_buddy_icons_find(account, username);
-
- if (icon == NULL)
-- icon = gaim_buddy_icon_create(account, username);
-+ icon = gaim2_buddy_icon_create(account, username);
-
-- gaim_buddy_icon_ref(icon);
-- gaim_buddy_icon_set_data(icon, icon_data, icon_len);
-+ gaim2_buddy_icon_ref(icon);
-+ gaim2_buddy_icon_set_data(icon, icon_data, icon_len);
-
-- /* gaim_buddy_icon_set_data() makes blist.c or
-+ /* gaim2_buddy_icon_set_data() makes blist.c or
- * conversation.c, or both, take a reference.
- *
- * Plus, we leave one for the caller of this function.
-@@ -86,10 +86,10 @@ gaim_buddy_icon_new(GaimAccount *account
- }
-
- void
--gaim_buddy_icon_destroy(GaimBuddyIcon *icon)
-+gaim2_buddy_icon_destroy(Gaim2BuddyIcon *icon)
- {
-- GaimConversation *conv;
-- GaimAccount *account;
-+ Gaim2Conversation *conv;
-+ Gaim2Account *account;
- GHashTable *icon_cache;
- const char *username;
- GSList *sl, *list;
-@@ -99,24 +99,24 @@ gaim_buddy_icon_destroy(GaimBuddyIcon *i
- if (icon->ref_count > 0)
- {
- /* If the ref count is greater than 0, then we weren't called from
-- * gaim_buddy_icon_unref(). So we go through and ask everyone to
-+ * gaim2_buddy_icon_unref(). So we go through and ask everyone to
- * unref us. Then we return, since we know somewhere along the
- * line we got called recursively by one of the unrefs, and the
- * icon is already destroyed.
- */
-- account = gaim_buddy_icon_get_account(icon);
-- username = gaim_buddy_icon_get_username(icon);
-+ account = gaim2_buddy_icon_get_account(icon);
-+ username = gaim2_buddy_icon_get_username(icon);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, username, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, username, account);
- if (conv != NULL)
-- gaim_conv_im_set_icon(GAIM_CONV_IM(conv), NULL);
-+ gaim2_conv_im_set_icon(GAIM_CONV_IM(conv), NULL);
-
-- for (list = sl = gaim_find_buddies(account, username); sl != NULL;
-+ for (list = sl = gaim2_find_buddies(account, username); sl != NULL;
- sl = sl->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)sl->data;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)sl->data;
-
-- gaim_buddy_set_icon(buddy, NULL);
-+ gaim2_buddy_set_icon(buddy, NULL);
- }
-
- g_slist_free(list);
-@@ -125,10 +125,10 @@ gaim_buddy_icon_destroy(GaimBuddyIcon *i
- }
-
- icon_cache = g_hash_table_lookup(account_cache,
-- gaim_buddy_icon_get_account(icon));
-+ gaim2_buddy_icon_get_account(icon));
-
- if (icon_cache != NULL)
-- g_hash_table_remove(icon_cache, gaim_buddy_icon_get_username(icon));
-+ g_hash_table_remove(icon_cache, gaim2_buddy_icon_get_username(icon));
-
- if (icon->username != NULL)
- g_free(icon->username);
-@@ -139,8 +139,8 @@ gaim_buddy_icon_destroy(GaimBuddyIcon *i
- g_free(icon);
- }
-
--GaimBuddyIcon *
--gaim_buddy_icon_ref(GaimBuddyIcon *icon)
-+Gaim2BuddyIcon *
-+gaim2_buddy_icon_ref(Gaim2BuddyIcon *icon)
- {
- g_return_val_if_fail(icon != NULL, NULL);
-
-@@ -149,8 +149,8 @@ gaim_buddy_icon_ref(GaimBuddyIcon *icon)
- return icon;
- }
-
--GaimBuddyIcon *
--gaim_buddy_icon_unref(GaimBuddyIcon *icon)
-+Gaim2BuddyIcon *
-+gaim2_buddy_icon_unref(Gaim2BuddyIcon *icon)
- {
- g_return_val_if_fail(icon != NULL, NULL);
- g_return_val_if_fail(icon->ref_count > 0, NULL);
-@@ -159,7 +159,7 @@ gaim_buddy_icon_unref(GaimBuddyIcon *ico
-
- if (icon->ref_count == 0)
- {
-- gaim_buddy_icon_destroy(icon);
-+ gaim2_buddy_icon_destroy(icon);
-
- return NULL;
- }
-@@ -168,32 +168,32 @@ gaim_buddy_icon_unref(GaimBuddyIcon *ico
- }
-
- void
--gaim_buddy_icon_update(GaimBuddyIcon *icon)
-+gaim2_buddy_icon_update(Gaim2BuddyIcon *icon)
- {
-- GaimConversation *conv;
-- GaimAccount *account;
-+ Gaim2Conversation *conv;
-+ Gaim2Account *account;
- const char *username;
- GSList *sl, *list;
-
- g_return_if_fail(icon != NULL);
-
-- account = gaim_buddy_icon_get_account(icon);
-- username = gaim_buddy_icon_get_username(icon);
-+ account = gaim2_buddy_icon_get_account(icon);
-+ username = gaim2_buddy_icon_get_username(icon);
-
-- for (list = sl = gaim_find_buddies(account, username); sl != NULL;
-+ for (list = sl = gaim2_find_buddies(account, username); sl != NULL;
- sl = sl->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)sl->data;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)sl->data;
-
-- gaim_buddy_set_icon(buddy, icon);
-+ gaim2_buddy_set_icon(buddy, icon);
- }
-
- g_slist_free(list);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, username, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, username, account);
-
- if (conv != NULL)
-- gaim_conv_im_set_icon(GAIM_CONV_IM(conv), icon);
-+ gaim2_conv_im_set_icon(GAIM_CONV_IM(conv), icon);
- }
-
- static void
-@@ -216,7 +216,7 @@ delete_icon_cache_file(const char *dirna
- }
-
- void
--gaim_buddy_icon_cache(GaimBuddyIcon *icon, GaimBuddy *buddy)
-+gaim2_buddy_icon_cache(Gaim2BuddyIcon *icon, Gaim2Buddy *buddy)
- {
- const guchar *data;
- const char *dirname;
-@@ -229,23 +229,23 @@ gaim_buddy_icon_cache(GaimBuddyIcon *ico
- g_return_if_fail(icon != NULL);
- g_return_if_fail(buddy != NULL);
-
-- if (!gaim_buddy_icons_is_caching())
-+ if (!gaim2_buddy_icons_is_caching())
- return;
-
-- data = gaim_buddy_icon_get_data(icon, &len);
-+ data = gaim2_buddy_icon_get_data(icon, &len);
-
- random = g_strdup_printf("%x", g_random_int());
-- dirname = gaim_buddy_icons_get_cache_dir();
-+ dirname = gaim2_buddy_icons_get_cache_dir();
- filename = g_build_filename(dirname, random, NULL);
-- old_icon = gaim_blist_node_get_string((GaimBlistNode*)buddy, "buddy_icon");
-+ old_icon = gaim2_blist_node_get_string((Gaim2BlistNode*)buddy, "buddy_icon");
-
- if (!g_file_test(dirname, G_FILE_TEST_IS_DIR))
- {
-- gaim_debug_info("buddy icons", "Creating icon cache directory.\n");
-+ gaim2_debug_info("buddy icons", "Creating icon cache directory.\n");
-
- if (g_mkdir(dirname, S_IRUSR | S_IWUSR | S_IXUSR) < 0)
- {
-- gaim_debug_error("buddy icons",
-+ gaim2_debug_error("buddy icons",
- "Unable to create directory %s: %s\n",
- dirname, strerror(errno));
- }
-@@ -258,7 +258,7 @@ gaim_buddy_icon_cache(GaimBuddyIcon *ico
- }
- else
- {
-- gaim_debug_error("buddy icons", "Unable to create file %s: %s\n",
-+ gaim2_debug_error("buddy icons", "Unable to create file %s: %s\n",
- filename, strerror(errno));
- }
-
-@@ -267,36 +267,36 @@ gaim_buddy_icon_cache(GaimBuddyIcon *ico
- if (old_icon != NULL)
- delete_icon_cache_file(dirname, old_icon);
-
-- gaim_blist_node_set_string((GaimBlistNode *)buddy, "buddy_icon", random);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *)buddy, "buddy_icon", random);
-
- g_free(random);
- }
-
- void
--gaim_buddy_icon_uncache(GaimBuddy *buddy)
-+gaim2_buddy_icon_uncache(Gaim2Buddy *buddy)
- {
- const char *old_icon;
-
- g_return_if_fail(buddy != NULL);
-
-- old_icon = gaim_blist_node_get_string((GaimBlistNode *)buddy, "buddy_icon");
-+ old_icon = gaim2_blist_node_get_string((Gaim2BlistNode *)buddy, "buddy_icon");
-
- if (old_icon != NULL)
-- delete_icon_cache_file(gaim_buddy_icons_get_cache_dir(), old_icon);
-+ delete_icon_cache_file(gaim2_buddy_icons_get_cache_dir(), old_icon);
-
-- gaim_blist_node_remove_setting((GaimBlistNode *)buddy, "buddy_icon");
-+ gaim2_blist_node_remove_setting((Gaim2BlistNode *)buddy, "buddy_icon");
-
- /* Unset the icon in case this function is called from
-- * something other than gaim_buddy_set_icon(). */
-+ * something other than gaim2_buddy_set_icon(). */
- if (buddy->icon != NULL)
- {
-- gaim_buddy_icon_unref(buddy->icon);
-+ gaim2_buddy_icon_unref(buddy->icon);
- buddy->icon = NULL;
- }
- }
-
- void
--gaim_buddy_icon_set_account(GaimBuddyIcon *icon, GaimAccount *account)
-+gaim2_buddy_icon_set_account(Gaim2BuddyIcon *icon, Gaim2Account *account)
- {
- g_return_if_fail(icon != NULL);
- g_return_if_fail(account != NULL);
-@@ -305,7 +305,7 @@ gaim_buddy_icon_set_account(GaimBuddyIco
- }
-
- void
--gaim_buddy_icon_set_username(GaimBuddyIcon *icon, const char *username)
-+gaim2_buddy_icon_set_username(Gaim2BuddyIcon *icon, const char *username)
- {
- g_return_if_fail(icon != NULL);
- g_return_if_fail(username != NULL);
-@@ -317,7 +317,7 @@ gaim_buddy_icon_set_username(GaimBuddyIc
- }
-
- void
--gaim_buddy_icon_set_data(GaimBuddyIcon *icon, void *data, size_t len)
-+gaim2_buddy_icon_set_data(Gaim2BuddyIcon *icon, void *data, size_t len)
- {
- g_return_if_fail(icon != NULL);
-
-@@ -335,11 +335,11 @@ gaim_buddy_icon_set_data(GaimBuddyIcon *
- icon->len = 0;
- }
-
-- gaim_buddy_icon_update(icon);
-+ gaim2_buddy_icon_update(icon);
- }
-
--GaimAccount *
--gaim_buddy_icon_get_account(const GaimBuddyIcon *icon)
-+Gaim2Account *
-+gaim2_buddy_icon_get_account(const Gaim2BuddyIcon *icon)
- {
- g_return_val_if_fail(icon != NULL, NULL);
-
-@@ -347,7 +347,7 @@ gaim_buddy_icon_get_account(const GaimBu
- }
-
- const char *
--gaim_buddy_icon_get_username(const GaimBuddyIcon *icon)
-+gaim2_buddy_icon_get_username(const Gaim2BuddyIcon *icon)
- {
- g_return_val_if_fail(icon != NULL, NULL);
-
-@@ -355,7 +355,7 @@ gaim_buddy_icon_get_username(const GaimB
- }
-
- const guchar *
--gaim_buddy_icon_get_data(const GaimBuddyIcon *icon, size_t *len)
-+gaim2_buddy_icon_get_data(const Gaim2BuddyIcon *icon, size_t *len)
- {
- g_return_val_if_fail(icon != NULL, NULL);
-
-@@ -366,14 +366,14 @@ gaim_buddy_icon_get_data(const GaimBuddy
- }
-
- const char *
--gaim_buddy_icon_get_type(const GaimBuddyIcon *icon)
-+gaim2_buddy_icon_get_type(const Gaim2BuddyIcon *icon)
- {
- const void *data;
- size_t len;
-
- g_return_val_if_fail(icon != NULL, NULL);
-
-- data = gaim_buddy_icon_get_data(icon, &len);
-+ data = gaim2_buddy_icon_get_data(icon, &len);
-
- /* TODO: Find a way to do this with GDK */
- if (len >= 4)
-@@ -392,7 +392,7 @@ gaim_buddy_icon_get_type(const GaimBuddy
- }
-
- void
--gaim_buddy_icons_set_for_user(GaimAccount *account, const char *username,
-+gaim2_buddy_icons_set_for_user(Gaim2Account *account, const char *username,
- void *icon_data, size_t icon_len)
- {
- g_return_if_fail(account != NULL);
-@@ -400,25 +400,25 @@ gaim_buddy_icons_set_for_user(GaimAccoun
-
- if (icon_data == NULL || icon_len == 0)
- {
-- GaimBuddyIcon *buddy_icon;
-+ Gaim2BuddyIcon *buddy_icon;
-
-- buddy_icon = gaim_buddy_icons_find(account, username);
-+ buddy_icon = gaim2_buddy_icons_find(account, username);
-
- if (buddy_icon != NULL)
-- gaim_buddy_icon_destroy(buddy_icon);
-+ gaim2_buddy_icon_destroy(buddy_icon);
- }
- else
- {
-- GaimBuddyIcon *icon = gaim_buddy_icon_new(account, username, icon_data, icon_len);
-- gaim_buddy_icon_unref(icon);
-+ Gaim2BuddyIcon *icon = gaim2_buddy_icon_new(account, username, icon_data, icon_len);
-+ gaim2_buddy_icon_unref(icon);
- }
- }
-
--GaimBuddyIcon *
--gaim_buddy_icons_find(GaimAccount *account, const char *username)
-+Gaim2BuddyIcon *
-+gaim2_buddy_icons_find(Gaim2Account *account, const char *username)
- {
- GHashTable *icon_cache;
-- GaimBuddyIcon *ret = NULL;
-+ Gaim2BuddyIcon *ret = NULL;
- char *filename = NULL;
-
- g_return_val_if_fail(account != NULL, NULL);
-@@ -429,18 +429,18 @@ gaim_buddy_icons_find(GaimAccount *accou
- if ((icon_cache == NULL) || ((ret = g_hash_table_lookup(icon_cache, username)) == NULL)) {
- const char *file;
- struct stat st;
-- GaimBuddy *b = gaim_find_buddy(account, username);
-+ Gaim2Buddy *b = gaim2_find_buddy(account, username);
-
- if (!b)
- return NULL;
-
-- if ((file = gaim_blist_node_get_string((GaimBlistNode*)b, "buddy_icon")) == NULL)
-+ if ((file = gaim2_blist_node_get_string((Gaim2BlistNode*)b, "buddy_icon")) == NULL)
- return NULL;
-
- if (!g_stat(file, &st))
- filename = g_strdup(file);
- else
-- filename = g_build_filename(gaim_buddy_icons_get_cache_dir(), file, NULL);
-+ filename = g_build_filename(gaim2_buddy_icons_get_cache_dir(), file, NULL);
-
- if (!g_stat(filename, &st)) {
- FILE *f = g_fopen(filename, "rb");
-@@ -448,10 +448,10 @@ gaim_buddy_icons_find(GaimAccount *accou
- char *data = g_malloc(st.st_size);
- fread(data, 1, st.st_size, f);
- fclose(f);
-- ret = gaim_buddy_icon_create(account, username);
-- gaim_buddy_icon_ref(ret);
-- gaim_buddy_icon_set_data(ret, data, st.st_size);
-- gaim_buddy_icon_unref(ret);
-+ ret = gaim2_buddy_icon_create(account, username);
-+ gaim2_buddy_icon_ref(ret);
-+ gaim2_buddy_icon_set_data(ret, data, st.st_size);
-+ gaim2_buddy_icon_unref(ret);
- g_free(data);
- g_free(filename);
- return ret;
-@@ -464,19 +464,19 @@ gaim_buddy_icons_find(GaimAccount *accou
- }
-
- void
--gaim_buddy_icons_set_caching(gboolean caching)
-+gaim2_buddy_icons_set_caching(gboolean caching)
- {
- icon_caching = caching;
- }
-
- gboolean
--gaim_buddy_icons_is_caching(void)
-+gaim2_buddy_icons_is_caching(void)
- {
- return icon_caching;
- }
-
- void
--gaim_buddy_icons_set_cache_dir(const char *dir)
-+gaim2_buddy_icons_set_cache_dir(const char *dir)
- {
- g_return_if_fail(dir != NULL);
-
-@@ -487,12 +487,12 @@ gaim_buddy_icons_set_cache_dir(const cha
- }
-
- const char *
--gaim_buddy_icons_get_cache_dir(void)
-+gaim2_buddy_icons_get_cache_dir(void)
- {
- return cache_dir;
- }
-
--char *gaim_buddy_icons_get_full_path(const char *icon) {
-+char *gaim2_buddy_icons_get_full_path(const char *icon) {
- struct stat st;
-
- if (icon == NULL)
-@@ -501,11 +501,11 @@ char *gaim_buddy_icons_get_full_path(con
- if (g_stat(icon, &st) == 0)
- return g_strdup(icon);
- else
-- return g_build_filename(gaim_buddy_icons_get_cache_dir(), icon, NULL);
-+ return g_build_filename(gaim2_buddy_icons_get_cache_dir(), icon, NULL);
- }
-
- void *
--gaim_buddy_icons_get_handle()
-+gaim2_buddy_icons_get_handle()
- {
- static int handle;
-
-@@ -513,22 +513,22 @@ gaim_buddy_icons_get_handle()
- }
-
- void
--gaim_buddy_icons_init()
-+gaim2_buddy_icons_init()
- {
- account_cache = g_hash_table_new_full(
- g_direct_hash, g_direct_equal,
- NULL, (GFreeFunc)g_hash_table_destroy);
-
-- cache_dir = g_build_filename(gaim_user_dir(), "icons", NULL);
-+ cache_dir = g_build_filename(gaim2_user_dir(), "icons", NULL);
- }
-
- void
--gaim_buddy_icons_uninit()
-+gaim2_buddy_icons_uninit()
- {
- g_hash_table_destroy(account_cache);
- }
-
--void gaim_buddy_icon_get_scale_size(GaimBuddyIconSpec *spec, int *width, int *height)
-+void gaim2_buddy_icon_get_scale_size(Gaim2BuddyIconSpec *spec, int *width, int *height)
- {
- if(spec && spec->scale_rules & GAIM_ICON_SCALE_DISPLAY) {
- int new_width, new_height;
-diff -prNu ./src/buddyicon.h ./src/buddyicon.h
---- ./src/buddyicon.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/buddyicon.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file buddyicon.h Buddy Icon API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,15 +25,15 @@
- #ifndef _GAIM_BUDDYICON_H_
- #define _GAIM_BUDDYICON_H_
-
--typedef struct _GaimBuddyIcon GaimBuddyIcon;
-+typedef struct _Gaim2BuddyIcon Gaim2BuddyIcon;
-
- #include "account.h"
- #include "blist.h"
- #include "prpl.h"
-
--struct _GaimBuddyIcon
-+struct _Gaim2BuddyIcon
- {
-- GaimAccount *account; /**< The account the user is on. */
-+ Gaim2Account *account; /**< The account the user is on. */
- char *username; /**< The username the icon belongs to. */
-
- void *data; /**< The buddy icon data. */
-@@ -57,7 +57,7 @@ struct _GaimBuddyIcon
- *
- * @return The buddy icon structure.
- */
--GaimBuddyIcon *gaim_buddy_icon_new(GaimAccount *account, const char *username,
-+Gaim2BuddyIcon *gaim2_buddy_icon_new(Gaim2Account *account, const char *username,
- void *icon_data, size_t icon_len);
-
- /**
-@@ -68,7 +68,7 @@ GaimBuddyIcon *gaim_buddy_icon_new(GaimA
- *
- * @param icon The buddy icon structure to destroy.
- */
--void gaim_buddy_icon_destroy(GaimBuddyIcon *icon);
-+void gaim2_buddy_icon_destroy(Gaim2BuddyIcon *icon);
-
- /**
- * Increments the reference count on a buddy icon.
-@@ -77,7 +77,7 @@ void gaim_buddy_icon_destroy(GaimBuddyIc
- *
- * @return @a icon.
- */
--GaimBuddyIcon *gaim_buddy_icon_ref(GaimBuddyIcon *icon);
-+Gaim2BuddyIcon *gaim2_buddy_icon_ref(Gaim2BuddyIcon *icon);
-
- /**
- * Decrements the reference count on a buddy icon.
-@@ -88,14 +88,14 @@ GaimBuddyIcon *gaim_buddy_icon_ref(GaimB
- *
- * @return @a icon, or @c NULL if the reference count reached 0.
- */
--GaimBuddyIcon *gaim_buddy_icon_unref(GaimBuddyIcon *icon);
-+Gaim2BuddyIcon *gaim2_buddy_icon_unref(Gaim2BuddyIcon *icon);
-
- /**
- * Updates every instance of this icon.
- *
- * @param icon The buddy icon.
- */
--void gaim_buddy_icon_update(GaimBuddyIcon *icon);
-+void gaim2_buddy_icon_update(Gaim2BuddyIcon *icon);
-
- /**
- * Caches a buddy icon associated with a specific buddy to disk.
-@@ -103,14 +103,14 @@ void gaim_buddy_icon_update(GaimBuddyIco
- * @param icon The buddy icon.
- * @param buddy The buddy that this icon belongs to.
- */
--void gaim_buddy_icon_cache(GaimBuddyIcon *icon, GaimBuddy *buddy);
-+void gaim2_buddy_icon_cache(Gaim2BuddyIcon *icon, Gaim2Buddy *buddy);
-
- /**
- * Removes cached buddy icon for a specific buddy.
- *
- * @param buddy The buddy for which to remove the cached icon.
- */
--void gaim_buddy_icon_uncache(GaimBuddy *buddy);
-+void gaim2_buddy_icon_uncache(Gaim2Buddy *buddy);
-
- /**
- * Sets the buddy icon's account.
-@@ -118,7 +118,7 @@ void gaim_buddy_icon_uncache(GaimBuddy *
- * @param icon The buddy icon.
- * @param account The account.
- */
--void gaim_buddy_icon_set_account(GaimBuddyIcon *icon, GaimAccount *account);
-+void gaim2_buddy_icon_set_account(Gaim2BuddyIcon *icon, Gaim2Account *account);
-
- /**
- * Sets the buddy icon's username.
-@@ -126,7 +126,7 @@ void gaim_buddy_icon_set_account(GaimBud
- * @param icon The buddy icon.
- * @param username The username.
- */
--void gaim_buddy_icon_set_username(GaimBuddyIcon *icon, const char *username);
-+void gaim2_buddy_icon_set_username(Gaim2BuddyIcon *icon, const char *username);
-
- /**
- * Sets the buddy icon's icon data.
-@@ -135,7 +135,7 @@ void gaim_buddy_icon_set_username(GaimBu
- * @param data The buddy icon data.
- * @param len The length of the icon data.
- */
--void gaim_buddy_icon_set_data(GaimBuddyIcon *icon, void *data, size_t len);
-+void gaim2_buddy_icon_set_data(Gaim2BuddyIcon *icon, void *data, size_t len);
-
- /**
- * Returns the buddy icon's account.
-@@ -144,7 +144,7 @@ void gaim_buddy_icon_set_data(GaimBuddyI
- *
- * @return The account.
- */
--GaimAccount *gaim_buddy_icon_get_account(const GaimBuddyIcon *icon);
-+Gaim2Account *gaim2_buddy_icon_get_account(const Gaim2BuddyIcon *icon);
-
- /**
- * Returns the buddy icon's username.
-@@ -153,7 +153,7 @@ GaimAccount *gaim_buddy_icon_get_account
- *
- * @return The username.
- */
--const char *gaim_buddy_icon_get_username(const GaimBuddyIcon *icon);
-+const char *gaim2_buddy_icon_get_username(const Gaim2BuddyIcon *icon);
-
- /**
- * Returns the buddy icon's data.
-@@ -163,7 +163,7 @@ const char *gaim_buddy_icon_get_username
- *
- * @return The icon data.
- */
--const guchar *gaim_buddy_icon_get_data(const GaimBuddyIcon *icon, size_t *len);
-+const guchar *gaim2_buddy_icon_get_data(const Gaim2BuddyIcon *icon, size_t *len);
-
- /**
- * Returns an extension corresponding to the buddy icon's file type.
-@@ -172,7 +172,7 @@ const guchar *gaim_buddy_icon_get_data(c
- *
- * @return The icon's extension.
- */
--const char *gaim_buddy_icon_get_type(const GaimBuddyIcon *icon);
-+const char *gaim2_buddy_icon_get_type(const Gaim2BuddyIcon *icon);
-
- /*@}*/
-
-@@ -189,7 +189,7 @@ const char *gaim_buddy_icon_get_type(con
- * @param icon_data The icon data.
- * @param icon_len The length of the icon data.
- */
--void gaim_buddy_icons_set_for_user(GaimAccount *account, const char *username,
-+void gaim2_buddy_icons_set_for_user(Gaim2Account *account, const char *username,
- void *icon_data, size_t icon_len);
-
- /**
-@@ -200,7 +200,7 @@ void gaim_buddy_icons_set_for_user(GaimA
- *
- * @return The icon data if found, or @c NULL if not found.
- */
--GaimBuddyIcon *gaim_buddy_icons_find(GaimAccount *account,
-+Gaim2BuddyIcon *gaim2_buddy_icons_find(Gaim2Account *account,
- const char *username);
-
- /**
-@@ -209,63 +209,63 @@ GaimBuddyIcon *gaim_buddy_icons_find(Gai
- * @param caching TRUE of buddy icon caching should be enabled, or
- * FALSE otherwise.
- */
--void gaim_buddy_icons_set_caching(gboolean caching);
-+void gaim2_buddy_icons_set_caching(gboolean caching);
-
- /**
- * Returns whether or not buddy icon caching should be enabled.
- *
- * The default is TRUE, unless otherwise specified by
-- * gaim_buddy_icons_set_caching().
-+ * gaim2_buddy_icons_set_caching().
- *
- * @return TRUE if buddy icon caching is enabled, or FALSE otherwise.
- */
--gboolean gaim_buddy_icons_is_caching(void);
-+gboolean gaim2_buddy_icons_is_caching(void);
-
- /**
- * Sets the directory used to store buddy icon cache files.
- *
- * @param cache_dir The directory to store buddy icon cache files to.
- */
--void gaim_buddy_icons_set_cache_dir(const char *cache_dir);
-+void gaim2_buddy_icons_set_cache_dir(const char *cache_dir);
-
- /**
- * Returns the directory used to store buddy icon cache files.
- *
- * The default directory is GAIMDIR/icons, unless otherwise specified
-- * by gaim_buddy_icons_set_cache_dir().
-+ * by gaim2_buddy_icons_set_cache_dir().
- *
- * @return The directory to store buddy icon cache files to.
- */
--const char *gaim_buddy_icons_get_cache_dir(void);
-+const char *gaim2_buddy_icons_get_cache_dir(void);
-
- /**
- * Takes a buddy icon and returns a full path.
- *
- * If @a icon is a full path to an existing file, a copy of
- * @a icon is returned. Otherwise, a newly allocated string
-- * consiting of gaim_buddy_icons_get_cache_dir() + @a icon is
-+ * consiting of gaim2_buddy_icons_get_cache_dir() + @a icon is
- * returned.
- *
- * @return The full path for an icon.
- */
--char *gaim_buddy_icons_get_full_path(const char *icon);
-+char *gaim2_buddy_icons_get_full_path(const char *icon);
-
- /**
- * Returns the buddy icon subsystem handle.
- *
- * @return The subsystem handle.
- */
--void *gaim_buddy_icons_get_handle(void);
-+void *gaim2_buddy_icons_get_handle(void);
-
- /**
- * Initializes the buddy icon subsystem.
- */
--void gaim_buddy_icons_init(void);
-+void gaim2_buddy_icons_init(void);
-
- /**
- * Uninitializes the buddy icon subsystem.
- */
--void gaim_buddy_icons_uninit(void);
-+void gaim2_buddy_icons_uninit(void);
-
- /*@}*/
-
-@@ -277,7 +277,7 @@ void gaim_buddy_icons_uninit(void);
- /**
- * Gets display size for a buddy icon
- */
--void gaim_buddy_icon_get_scale_size(GaimBuddyIconSpec *spec, int *width, int *height);
-+void gaim2_buddy_icon_get_scale_size(Gaim2BuddyIconSpec *spec, int *width, int *height);
-
- /*@}*/
-
-diff -prNu ./src/cipher.c ./src/cipher.c
---- ./src/cipher.c 2005-12-07 12:01:47.000000000 +0100
-+++ ./src/cipher.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -83,21 +83,21 @@ struct MD5Context {
- }
-
- static void
--md5_init(GaimCipherContext *context, gpointer extra) {
-+md5_init(Gaim2CipherContext *context, gpointer extra) {
- struct MD5Context *md5_context;
-
- md5_context = g_new0(struct MD5Context, 1);
-
-- gaim_cipher_context_set_data(context, md5_context);
-+ gaim2_cipher_context_set_data(context, md5_context);
-
-- gaim_cipher_context_reset(context, extra);
-+ gaim2_cipher_context_reset(context, extra);
- }
-
- static void
--md5_reset(GaimCipherContext *context, gpointer extra) {
-+md5_reset(Gaim2CipherContext *context, gpointer extra) {
- struct MD5Context *md5_context;
-
-- md5_context = gaim_cipher_context_get_data(context);
-+ md5_context = gaim2_cipher_context_get_data(context);
-
- md5_context->total[0] = 0;
- md5_context->total[1] = 0;
-@@ -111,12 +111,12 @@ md5_reset(GaimCipherContext *context, gp
- }
-
- static void
--md5_uninit(GaimCipherContext *context) {
-+md5_uninit(Gaim2CipherContext *context) {
- struct MD5Context *md5_context;
-
-- gaim_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-
-- md5_context = gaim_cipher_context_get_data(context);
-+ md5_context = gaim2_cipher_context_get_data(context);
- memset(md5_context, 0, sizeof(md5_context));
-
- g_free(md5_context);
-@@ -244,13 +244,13 @@ md5_process(struct MD5Context *md5_conte
- }
-
- static void
--md5_append(GaimCipherContext *context, const guchar *data, size_t len) {
-+md5_append(Gaim2CipherContext *context, const guchar *data, size_t len) {
- struct MD5Context *md5_context = NULL;
- guint32 left = 0, fill = 0;
-
- g_return_if_fail(context != NULL);
-
-- md5_context = gaim_cipher_context_get_data(context);
-+ md5_context = gaim2_cipher_context_get_data(context);
- g_return_if_fail(md5_context != NULL);
-
- left = md5_context->total[0] & 0x3F;
-@@ -282,7 +282,7 @@ md5_append(GaimCipherContext *context, c
- }
-
- static gboolean
--md5_digest(GaimCipherContext *context, size_t in_len, guchar digest[16],
-+md5_digest(Gaim2CipherContext *context, size_t in_len, guchar digest[16],
- size_t *out_len)
- {
- struct MD5Context *md5_context = NULL;
-@@ -298,7 +298,7 @@ md5_digest(GaimCipherContext *context, s
-
- g_return_val_if_fail(in_len >= 16, FALSE);
-
-- md5_context = gaim_cipher_context_get_data(context);
-+ md5_context = gaim2_cipher_context_get_data(context);
-
- high = (md5_context->total[0] >> 29)
- | (md5_context->total[1] << 3);
-@@ -324,7 +324,7 @@ md5_digest(GaimCipherContext *context, s
- return TRUE;
- }
-
--static GaimCipherOps MD5Ops = {
-+static Gaim2CipherOps MD5Ops = {
- NULL, /* Set option */
- NULL, /* Get option */
- md5_init, /* init */
-@@ -471,11 +471,11 @@ static inline void md4_transform_helper(
- }
-
- static void
--md4_init(GaimCipherContext *context, gpointer extra) {
-+md4_init(Gaim2CipherContext *context, gpointer extra) {
- struct MD4_Context *mctx;
- mctx = g_new0(struct MD4_Context, 1);
-- gaim_cipher_context_set_data(context, mctx);
-- gaim_cipher_context_reset(context, extra);
-+ gaim2_cipher_context_set_data(context, mctx);
-+ gaim2_cipher_context_reset(context, extra);
-
- mctx->hash[0] = 0x67452301;
- mctx->hash[1] = 0xefcdab89;
-@@ -485,10 +485,10 @@ md4_init(GaimCipherContext *context, gpo
- }
-
- static void
--md4_reset(GaimCipherContext *context, gpointer extra) {
-+md4_reset(Gaim2CipherContext *context, gpointer extra) {
- struct MD4_Context *mctx;
-
-- mctx = gaim_cipher_context_get_data(context);
-+ mctx = gaim2_cipher_context_get_data(context);
-
- mctx->hash[0] = 0x67452301;
- mctx->hash[1] = 0xefcdab89;
-@@ -498,9 +498,9 @@ md4_reset(GaimCipherContext *context, gp
- }
-
- static void
--md4_append(GaimCipherContext *context, const guchar *data, size_t len)
-+md4_append(Gaim2CipherContext *context, const guchar *data, size_t len)
- {
-- struct MD4_Context *mctx = gaim_cipher_context_get_data(context);
-+ struct MD4_Context *mctx = gaim2_cipher_context_get_data(context);
- const guint32 avail = sizeof(mctx->block) - (mctx->byte_count & 0x3f);
-
- mctx->byte_count += len;
-@@ -529,10 +529,10 @@ md4_append(GaimCipherContext *context, c
- }
-
- static gboolean
--md4_digest(GaimCipherContext *context, size_t in_len, guchar *out,
-+md4_digest(Gaim2CipherContext *context, size_t in_len, guchar *out,
- size_t *out_len)
- {
-- struct MD4_Context *mctx = gaim_cipher_context_get_data(context);
-+ struct MD4_Context *mctx = gaim2_cipher_context_get_data(context);
- const unsigned int offset = mctx->byte_count & 0x3f;
- char *p = (char *)mctx->block + offset;
- int padding = 56 - (offset + 1);
-@@ -561,19 +561,19 @@ md4_digest(GaimCipherContext *context, s
- }
-
- static void
--md4_uninit(GaimCipherContext *context) {
-+md4_uninit(Gaim2CipherContext *context) {
- struct MD4_Context *md4_context;
-
-- gaim_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-
-- md4_context = gaim_cipher_context_get_data(context);
-+ md4_context = gaim2_cipher_context_get_data(context);
- memset(md4_context, 0, sizeof(md4_context));
-
- g_free(md4_context);
- md4_context = NULL;
- }
-
--static GaimCipherOps MD4Ops = {
-+static Gaim2CipherOps MD4Ops = {
- NULL, /* Set option */
- NULL, /* Get option */
- md4_init, /* init */
-@@ -897,9 +897,9 @@ des_key_schedule (const guint8 * rawkey,
- * Does not check for weak keys.
- **/
- static void
--des_set_key (GaimCipherContext *context, guchar * key)
-+des_set_key (Gaim2CipherContext *context, guchar * key)
- {
-- struct _des_ctx *ctx = gaim_cipher_context_get_data(context);
-+ struct _des_ctx *ctx = gaim2_cipher_context_get_data(context);
- int i;
-
- des_key_schedule (key, ctx->encrypt_subkeys);
-@@ -944,14 +944,14 @@ des_ecb_crypt (struct _des_ctx *ctx, con
- }
-
- static gint
--des_encrypt(GaimCipherContext *context, const guchar data[],
-+des_encrypt(Gaim2CipherContext *context, const guchar data[],
- size_t len, guchar output[], size_t *outlen) {
- int offset = 0;
- int i = 0;
- int tmp;
- guint8 buf[8] = {0,0,0,0,0,0,0,0};
- while(offset+8<=len) {
-- des_ecb_crypt(gaim_cipher_context_get_data(context),
-+ des_ecb_crypt(gaim2_cipher_context_get_data(context),
- data+offset,
- output+offset,
- 0);
-@@ -965,7 +965,7 @@ des_encrypt(GaimCipherContext *context,
- buf[i++] = data[tmp];
- tmp++;
- }
-- des_ecb_crypt(gaim_cipher_context_get_data(context),
-+ des_ecb_crypt(gaim2_cipher_context_get_data(context),
- buf,
- output+offset,
- 0);
-@@ -974,24 +974,24 @@ des_encrypt(GaimCipherContext *context,
- }
-
- static void
--des_init(GaimCipherContext *context, gpointer extra) {
-+des_init(Gaim2CipherContext *context, gpointer extra) {
- struct _des_ctx *mctx;
- mctx = g_new0(struct _des_ctx, 1);
-- gaim_cipher_context_set_data(context, mctx);
-+ gaim2_cipher_context_set_data(context, mctx);
- }
-
- static void
--des_uninit(GaimCipherContext *context) {
-+des_uninit(Gaim2CipherContext *context) {
- struct _des_ctx *des_context;
-
-- des_context = gaim_cipher_context_get_data(context);
-+ des_context = gaim2_cipher_context_get_data(context);
- memset(des_context, 0, sizeof(des_context));
-
- g_free(des_context);
- des_context = NULL;
- }
-
--static GaimCipherOps DESOps = {
-+static Gaim2CipherOps DESOps = {
- NULL, /* Set option */
- NULL, /* Get option */
- des_init, /* init */
-@@ -1086,10 +1086,10 @@ sha1_hash_block(struct SHA1Context *sha1
- }
-
- static void
--sha1_set_opt(GaimCipherContext *context, const gchar *name, void *value) {
-+sha1_set_opt(Gaim2CipherContext *context, const gchar *name, void *value) {
- struct SHA1Context *ctx;
-
-- ctx = gaim_cipher_context_get_data(context);
-+ ctx = gaim2_cipher_context_get_data(context);
-
- if(!strcmp(name, "sizeHi")) {
- ctx->sizeHi = GPOINTER_TO_INT(value);
-@@ -1101,10 +1101,10 @@ sha1_set_opt(GaimCipherContext *context,
- }
-
- static void *
--sha1_get_opt(GaimCipherContext *context, const gchar *name) {
-+sha1_get_opt(Gaim2CipherContext *context, const gchar *name) {
- struct SHA1Context *ctx;
-
-- ctx = gaim_cipher_context_get_data(context);
-+ ctx = gaim2_cipher_context_get_data(context);
-
- if(!strcmp(name, "sizeHi")) {
- return GINT_TO_POINTER(ctx->sizeHi);
-@@ -1118,22 +1118,22 @@ sha1_get_opt(GaimCipherContext *context,
- }
-
- static void
--sha1_init(GaimCipherContext *context, void *extra) {
-+sha1_init(Gaim2CipherContext *context, void *extra) {
- struct SHA1Context *sha1_ctx;
-
- sha1_ctx = g_new0(struct SHA1Context, 1);
-
-- gaim_cipher_context_set_data(context, sha1_ctx);
-+ gaim2_cipher_context_set_data(context, sha1_ctx);
-
-- gaim_cipher_context_reset(context, extra);
-+ gaim2_cipher_context_reset(context, extra);
- }
-
- static void
--sha1_reset(GaimCipherContext *context, void *extra) {
-+sha1_reset(Gaim2CipherContext *context, void *extra) {
- struct SHA1Context *sha1_ctx;
- gint i;
-
-- sha1_ctx = gaim_cipher_context_get_data(context);
-+ sha1_ctx = gaim2_cipher_context_get_data(context);
-
- g_return_if_fail(sha1_ctx);
-
-@@ -1152,12 +1152,12 @@ sha1_reset(GaimCipherContext *context, v
- }
-
- static void
--sha1_uninit(GaimCipherContext *context) {
-+sha1_uninit(Gaim2CipherContext *context) {
- struct SHA1Context *sha1_ctx;
-
-- gaim_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-
-- sha1_ctx = gaim_cipher_context_get_data(context);
-+ sha1_ctx = gaim2_cipher_context_get_data(context);
-
- memset(sha1_ctx, 0, sizeof(struct SHA1Context));
-
-@@ -1167,11 +1167,11 @@ sha1_uninit(GaimCipherContext *context)
-
-
- static void
--sha1_append(GaimCipherContext *context, const guchar *data, size_t len) {
-+sha1_append(Gaim2CipherContext *context, const guchar *data, size_t len) {
- struct SHA1Context *sha1_ctx;
- gint i;
-
-- sha1_ctx = gaim_cipher_context_get_data(context);
-+ sha1_ctx = gaim2_cipher_context_get_data(context);
-
- g_return_if_fail(sha1_ctx);
-
-@@ -1190,7 +1190,7 @@ sha1_append(GaimCipherContext *context,
- }
-
- static gboolean
--sha1_digest(GaimCipherContext *context, size_t in_len, guchar digest[20],
-+sha1_digest(Gaim2CipherContext *context, size_t in_len, guchar digest[20],
- size_t *out_len)
- {
- struct SHA1Context *sha1_ctx;
-@@ -1200,7 +1200,7 @@ sha1_digest(GaimCipherContext *context,
-
- g_return_val_if_fail(in_len >= 20, FALSE);
-
-- sha1_ctx = gaim_cipher_context_get_data(context);
-+ sha1_ctx = gaim2_cipher_context_get_data(context);
-
- g_return_val_if_fail(sha1_ctx, FALSE);
-
-@@ -1214,17 +1214,17 @@ sha1_digest(GaimCipherContext *context,
- padlen[7] = (guchar)((sha1_ctx->sizeLo >> 0) & 255);
-
- /* pad with a 1, then zeroes, then length */
-- gaim_cipher_context_append(context, &pad0x80, 1);
-+ gaim2_cipher_context_append(context, &pad0x80, 1);
- while(sha1_ctx->lenW != 56)
-- gaim_cipher_context_append(context, &pad0x00, 1);
-- gaim_cipher_context_append(context, padlen, 8);
-+ gaim2_cipher_context_append(context, &pad0x00, 1);
-+ gaim2_cipher_context_append(context, padlen, 8);
-
- for(i = 0; i < 20; i++) {
- digest[i] = (guchar)(sha1_ctx->H[i / 4] >> 24);
- sha1_ctx->H[i / 4] <<= 8;
- }
-
-- gaim_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-
- if(out_len)
- *out_len = 20;
-@@ -1232,7 +1232,7 @@ sha1_digest(GaimCipherContext *context,
- return TRUE;
- }
-
--static GaimCipherOps SHA1Ops = {
-+static Gaim2CipherOps SHA1Ops = {
- sha1_set_opt, /* Set Option */
- sha1_get_opt, /* Get Option */
- sha1_init, /* init */
-@@ -1252,14 +1252,14 @@ static GaimCipherOps SHA1Ops = {
- /*******************************************************************************
- * Structs
- ******************************************************************************/
--struct _GaimCipher {
-+struct _Gaim2Cipher {
- gchar *name;
-- GaimCipherOps *ops;
-+ Gaim2CipherOps *ops;
- guint ref;
- };
-
--struct _GaimCipherContext {
-- GaimCipher *cipher;
-+struct _Gaim2CipherContext {
-+ Gaim2Cipher *cipher;
- gpointer data;
- };
-
-@@ -1269,18 +1269,18 @@ struct _GaimCipherContext {
- static GList *ciphers = NULL;
-
- /******************************************************************************
-- * GaimCipher API
-+ * Gaim2Cipher API
- *****************************************************************************/
- const gchar *
--gaim_cipher_get_name(GaimCipher *cipher) {
-+gaim2_cipher_get_name(Gaim2Cipher *cipher) {
- g_return_val_if_fail(cipher, NULL);
-
- return cipher->name;
- }
-
- guint
--gaim_cipher_get_capabilities(GaimCipher *cipher) {
-- GaimCipherOps *ops = NULL;
-+gaim2_cipher_get_capabilities(Gaim2Cipher *cipher) {
-+ Gaim2CipherOps *ops = NULL;
- guint caps = 0;
-
- g_return_val_if_fail(cipher, 0);
-@@ -1321,42 +1321,42 @@ gaim_cipher_get_capabilities(GaimCipher
- }
-
- gboolean
--gaim_cipher_digest_region(const gchar *name, const guchar *data,
-+gaim2_cipher_digest_region(const gchar *name, const guchar *data,
- size_t data_len, size_t in_len,
- guchar digest[], size_t *out_len)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- gboolean ret = FALSE;
-
- g_return_val_if_fail(name, FALSE);
- g_return_val_if_fail(data, FALSE);
-
-- cipher = gaim_ciphers_find_cipher(name);
-+ cipher = gaim2_ciphers_find_cipher(name);
-
- g_return_val_if_fail(cipher, FALSE);
-
- if(!cipher->ops->append || !cipher->ops->digest) {
-- gaim_debug_info("cipher", "gaim_cipher_region failed: "
-+ gaim2_debug_info("cipher", "gaim2_cipher_region failed: "
- "the %s cipher does not support appending and or "
- "digesting.", cipher->name);
- return FALSE;
- }
-
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, data, data_len);
-- ret = gaim_cipher_context_digest(context, in_len, digest, out_len);
-- gaim_cipher_context_destroy(context);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, data, data_len);
-+ ret = gaim2_cipher_context_digest(context, in_len, digest, out_len);
-+ gaim2_cipher_context_destroy(context);
-
- return ret;
- }
-
- /******************************************************************************
-- * GaimCiphers API
-+ * Gaim2Ciphers API
- *****************************************************************************/
--GaimCipher *
--gaim_ciphers_find_cipher(const gchar *name) {
-- GaimCipher *cipher;
-+Gaim2Cipher *
-+gaim2_ciphers_find_cipher(const gchar *name) {
-+ Gaim2Cipher *cipher;
- GList *l;
-
- g_return_val_if_fail(name, NULL);
-@@ -1371,32 +1371,32 @@ gaim_ciphers_find_cipher(const gchar *na
- return NULL;
- }
-
--GaimCipher *
--gaim_ciphers_register_cipher(const gchar *name, GaimCipherOps *ops) {
-- GaimCipher *cipher = NULL;
-+Gaim2Cipher *
-+gaim2_ciphers_register_cipher(const gchar *name, Gaim2CipherOps *ops) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(name, NULL);
- g_return_val_if_fail(ops, NULL);
-- g_return_val_if_fail(!gaim_ciphers_find_cipher(name), NULL);
-+ g_return_val_if_fail(!gaim2_ciphers_find_cipher(name), NULL);
-
-- cipher = g_new0(GaimCipher, 1);
-+ cipher = g_new0(Gaim2Cipher, 1);
-
- cipher->name = g_strdup(name);
- cipher->ops = ops;
-
- ciphers = g_list_append(ciphers, cipher);
-
-- gaim_signal_emit(gaim_ciphers_get_handle(), "cipher-added", cipher);
-+ gaim2_signal_emit(gaim2_ciphers_get_handle(), "cipher-added", cipher);
-
- return cipher;
- }
-
- gboolean
--gaim_ciphers_unregister_cipher(GaimCipher *cipher) {
-+gaim2_ciphers_unregister_cipher(Gaim2Cipher *cipher) {
- g_return_val_if_fail(cipher, FALSE);
- g_return_val_if_fail(cipher->ref == 0, FALSE);
-
-- gaim_signal_emit(gaim_ciphers_get_handle(), "cipher-removed", cipher);
-+ gaim2_signal_emit(gaim2_ciphers_get_handle(), "cipher-removed", cipher);
-
- ciphers = g_list_remove(ciphers, cipher);
-
-@@ -1407,67 +1407,67 @@ gaim_ciphers_unregister_cipher(GaimCiphe
- }
-
- GList *
--gaim_ciphers_get_ciphers() {
-+gaim2_ciphers_get_ciphers() {
- return ciphers;
- }
-
- /******************************************************************************
-- * GaimCipher Subsystem API
-+ * Gaim2Cipher Subsystem API
- *****************************************************************************/
- gpointer
--gaim_ciphers_get_handle() {
-+gaim2_ciphers_get_handle() {
- static gint handle;
-
- return &handle;
- }
-
- void
--gaim_ciphers_init() {
-+gaim2_ciphers_init() {
- gpointer handle;
-
-- handle = gaim_ciphers_get_handle();
-+ handle = gaim2_ciphers_get_handle();
-
-- gaim_signal_register(handle, "cipher-added",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "cipher-added",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CIPHER));
-- gaim_signal_register(handle, "cipher-removed",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "cipher-removed",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CIPHER));
-
-- gaim_ciphers_register_cipher("md5", &MD5Ops);
-- gaim_ciphers_register_cipher("sha1", &SHA1Ops);
-- gaim_ciphers_register_cipher("md4", &MD4Ops);
-- gaim_ciphers_register_cipher("des", &DESOps);
-+ gaim2_ciphers_register_cipher("md5", &MD5Ops);
-+ gaim2_ciphers_register_cipher("sha1", &SHA1Ops);
-+ gaim2_ciphers_register_cipher("md4", &MD4Ops);
-+ gaim2_ciphers_register_cipher("des", &DESOps);
- }
-
- void
--gaim_ciphers_uninit() {
-- GaimCipher *cipher;
-+gaim2_ciphers_uninit() {
-+ Gaim2Cipher *cipher;
- GList *l, *ll;
-
- for(l = ciphers; l; l = ll) {
- ll = l->next;
-
- cipher = GAIM_CIPHER(l->data);
-- gaim_ciphers_unregister_cipher(cipher);
-+ gaim2_ciphers_unregister_cipher(cipher);
-
- ciphers = g_list_remove(ciphers, cipher);
- }
-
- g_list_free(ciphers);
-
-- gaim_signals_unregister_by_instance(gaim_ciphers_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_ciphers_get_handle());
- }
- /******************************************************************************
-- * GaimCipherContext API
-+ * Gaim2CipherContext API
- *****************************************************************************/
- void
--gaim_cipher_context_set_option(GaimCipherContext *context, const gchar *name,
-+gaim2_cipher_context_set_option(Gaim2CipherContext *context, const gchar *name,
- gpointer value)
- {
-- GaimCipher *cipher = NULL;
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
- g_return_if_fail(name);
-@@ -1478,13 +1478,13 @@ gaim_cipher_context_set_option(GaimCiphe
- if(cipher->ops && cipher->ops->set_option)
- cipher->ops->set_option(context, name, value);
- else
-- gaim_debug_info("cipher", "the %s cipher does not support the "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the "
- "set_option operation\n", cipher->name);
- }
-
- gpointer
--gaim_cipher_context_get_option(GaimCipherContext *context, const gchar *name) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_get_option(Gaim2CipherContext *context, const gchar *name) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(context, NULL);
- g_return_val_if_fail(name, NULL);
-@@ -1495,22 +1495,22 @@ gaim_cipher_context_get_option(GaimCiphe
- if(cipher->ops && cipher->ops->get_option)
- return cipher->ops->get_option(context, name);
- else {
-- gaim_debug_info("cipher", "the %s cipher does not support the "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the "
- "get_option operation\n", cipher->name);
-
- return NULL;
- }
- }
-
--GaimCipherContext *
--gaim_cipher_context_new(GaimCipher *cipher, void *extra) {
-- GaimCipherContext *context = NULL;
-+Gaim2CipherContext *
-+gaim2_cipher_context_new(Gaim2Cipher *cipher, void *extra) {
-+ Gaim2CipherContext *context = NULL;
-
- g_return_val_if_fail(cipher, NULL);
-
- cipher->ref++;
-
-- context = g_new0(GaimCipherContext, 1);
-+ context = g_new0(Gaim2CipherContext, 1);
- context->cipher = cipher;
-
- if(cipher->ops->init)
-@@ -1519,22 +1519,22 @@ gaim_cipher_context_new(GaimCipher *ciph
- return context;
- }
-
--GaimCipherContext *
--gaim_cipher_context_new_by_name(const gchar *name, void *extra) {
-- GaimCipher *cipher;
-+Gaim2CipherContext *
-+gaim2_cipher_context_new_by_name(const gchar *name, void *extra) {
-+ Gaim2Cipher *cipher;
-
- g_return_val_if_fail(name, NULL);
-
-- cipher = gaim_ciphers_find_cipher(name);
-+ cipher = gaim2_ciphers_find_cipher(name);
-
- g_return_val_if_fail(cipher, NULL);
-
-- return gaim_cipher_context_new(cipher, extra);
-+ return gaim2_cipher_context_new(cipher, extra);
- }
-
- void
--gaim_cipher_context_reset(GaimCipherContext *context, void *extra) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_reset(Gaim2CipherContext *context, void *extra) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
-
-@@ -1546,8 +1546,8 @@ gaim_cipher_context_reset(GaimCipherCont
- }
-
- void
--gaim_cipher_context_destroy(GaimCipherContext *context) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_destroy(Gaim2CipherContext *context) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
-
-@@ -1565,9 +1565,9 @@ gaim_cipher_context_destroy(GaimCipherCo
- }
-
- void
--gaim_cipher_context_set_iv(GaimCipherContext *context, guchar *iv, size_t len)
-+gaim2_cipher_context_set_iv(Gaim2CipherContext *context, guchar *iv, size_t len)
- {
-- GaimCipher *cipher = NULL;
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
- g_return_if_fail(iv);
-@@ -1578,15 +1578,15 @@ gaim_cipher_context_set_iv(GaimCipherCon
- if(cipher->ops && cipher->ops->set_iv)
- cipher->ops->set_iv(context, iv, len);
- else
-- gaim_debug_info("cipher", "the %s cipher does not support the set"
-+ gaim2_debug_info("cipher", "the %s cipher does not support the set"
- "initialization vector operation\n", cipher->name);
- }
-
- void
--gaim_cipher_context_append(GaimCipherContext *context, const guchar *data,
-+gaim2_cipher_context_append(Gaim2CipherContext *context, const guchar *data,
- size_t len)
- {
-- GaimCipher *cipher = NULL;
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
-
-@@ -1596,15 +1596,15 @@ gaim_cipher_context_append(GaimCipherCon
- if(cipher->ops && cipher->ops->append)
- cipher->ops->append(context, data, len);
- else
-- gaim_debug_info("cipher", "the %s cipher does not support the append "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the append "
- "operation\n", cipher->name);
- }
-
- gboolean
--gaim_cipher_context_digest(GaimCipherContext *context, size_t in_len,
-+gaim2_cipher_context_digest(Gaim2CipherContext *context, size_t in_len,
- guchar digest[], size_t *out_len)
- {
-- GaimCipher *cipher = NULL;
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(context, FALSE);
-
-@@ -1614,14 +1614,14 @@ gaim_cipher_context_digest(GaimCipherCon
- if(cipher->ops && cipher->ops->digest)
- return cipher->ops->digest(context, in_len, digest, out_len);
- else {
-- gaim_debug_info("cipher", "the %s cipher does not support the digest "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the digest "
- "operation\n", cipher->name);
- return FALSE;
- }
- }
-
- gboolean
--gaim_cipher_context_digest_to_str(GaimCipherContext *context, size_t in_len,
-+gaim2_cipher_context_digest_to_str(Gaim2CipherContext *context, size_t in_len,
- gchar digest_s[], size_t *out_len)
- {
- /* 8k is a bit excessive, will tweak later. */
-@@ -1632,7 +1632,7 @@ gaim_cipher_context_digest_to_str(GaimCi
- g_return_val_if_fail(context, FALSE);
- g_return_val_if_fail(digest_s, FALSE);
-
-- if(!gaim_cipher_context_digest(context, sizeof(digest), digest, &dlen))
-+ if(!gaim2_cipher_context_digest(context, sizeof(digest), digest, &dlen))
- return FALSE;
-
- /* in_len must be greater than dlen * 2 so we have room for the NUL. */
-@@ -1651,10 +1651,10 @@ gaim_cipher_context_digest_to_str(GaimCi
- }
-
- gint
--gaim_cipher_context_encrypt(GaimCipherContext *context, const guchar data[],
-+gaim2_cipher_context_encrypt(Gaim2CipherContext *context, const guchar data[],
- size_t len, guchar output[], size_t *outlen)
- {
-- GaimCipher *cipher = NULL;
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(context, -1);
-
-@@ -1664,7 +1664,7 @@ gaim_cipher_context_encrypt(GaimCipherCo
- if(cipher->ops && cipher->ops->encrypt)
- return cipher->ops->encrypt(context, data, len, output, outlen);
- else {
-- gaim_debug_info("cipher", "the %s cipher does not support the encrypt"
-+ gaim2_debug_info("cipher", "the %s cipher does not support the encrypt"
- "operation\n", cipher->name);
-
- if(outlen)
-@@ -1675,10 +1675,10 @@ gaim_cipher_context_encrypt(GaimCipherCo
- }
-
- gint
--gaim_cipher_context_decrypt(GaimCipherContext *context, const guchar data[],
-+gaim2_cipher_context_decrypt(Gaim2CipherContext *context, const guchar data[],
- size_t len, guchar output[], size_t *outlen)
- {
-- GaimCipher *cipher = NULL;
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(context, -1);
-
-@@ -1688,7 +1688,7 @@ gaim_cipher_context_decrypt(GaimCipherCo
- if(cipher->ops && cipher->ops->decrypt)
- return cipher->ops->decrypt(context, data, len, output, outlen);
- else {
-- gaim_debug_info("cipher", "the %s cipher does not support the decrypt"
-+ gaim2_debug_info("cipher", "the %s cipher does not support the decrypt"
- "operation\n", cipher->name);
-
- if(outlen)
-@@ -1699,8 +1699,8 @@ gaim_cipher_context_decrypt(GaimCipherCo
- }
-
- void
--gaim_cipher_context_set_salt(GaimCipherContext *context, guchar *salt) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_set_salt(Gaim2CipherContext *context, guchar *salt) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
-
-@@ -1710,13 +1710,13 @@ gaim_cipher_context_set_salt(GaimCipherC
- if(cipher->ops && cipher->ops->set_salt)
- cipher->ops->set_salt(context, salt);
- else
-- gaim_debug_info("cipher", "the %s cipher does not support the "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the "
- "set_salt operation\n", cipher->name);
- }
-
- size_t
--gaim_cipher_context_get_salt_size(GaimCipherContext *context) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_get_salt_size(Gaim2CipherContext *context) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(context, -1);
-
-@@ -1726,7 +1726,7 @@ gaim_cipher_context_get_salt_size(GaimCi
- if(cipher->ops && cipher->ops->get_salt_size)
- return cipher->ops->get_salt_size(context);
- else {
-- gaim_debug_info("cipher", "the %s cipher does not support the "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the "
- "get_salt_size operation\n", cipher->name);
-
- return -1;
-@@ -1734,8 +1734,8 @@ gaim_cipher_context_get_salt_size(GaimCi
- }
-
- void
--gaim_cipher_context_set_key(GaimCipherContext *context, guchar *key) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_set_key(Gaim2CipherContext *context, guchar *key) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_if_fail(context);
-
-@@ -1745,13 +1745,13 @@ gaim_cipher_context_set_key(GaimCipherCo
- if(cipher->ops && cipher->ops->set_key)
- cipher->ops->set_key(context, key);
- else
-- gaim_debug_info("cipher", "the %s cipher does not support the "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the "
- "set_key operation\n", cipher->name);
- }
-
- size_t
--gaim_cipher_context_get_key_size(GaimCipherContext *context) {
-- GaimCipher *cipher = NULL;
-+gaim2_cipher_context_get_key_size(Gaim2CipherContext *context) {
-+ Gaim2Cipher *cipher = NULL;
-
- g_return_val_if_fail(context, -1);
-
-@@ -1761,7 +1761,7 @@ gaim_cipher_context_get_key_size(GaimCip
- if(cipher->ops && cipher->ops->get_key_size)
- return cipher->ops->get_key_size(context);
- else {
-- gaim_debug_info("cipher", "the %s cipher does not support the "
-+ gaim2_debug_info("cipher", "the %s cipher does not support the "
- "get_key_size operation\n", cipher->name);
-
- return -1;
-@@ -1769,20 +1769,20 @@ gaim_cipher_context_get_key_size(GaimCip
- }
-
- void
--gaim_cipher_context_set_data(GaimCipherContext *context, gpointer data) {
-+gaim2_cipher_context_set_data(Gaim2CipherContext *context, gpointer data) {
- g_return_if_fail(context);
-
- context->data = data;
- }
-
- gpointer
--gaim_cipher_context_get_data(GaimCipherContext *context) {
-+gaim2_cipher_context_get_data(Gaim2CipherContext *context) {
- g_return_val_if_fail(context, NULL);
-
- return context->data;
- }
-
--gchar *gaim_cipher_http_digest_calculate_session_key(
-+gchar *gaim2_cipher_http_digest_calculate_session_key(
- const gchar *algorithm,
- const gchar *username,
- const gchar *realm,
-@@ -1790,8 +1790,8 @@ gchar *gaim_cipher_http_digest_calculate
- const gchar *nonce,
- const gchar *client_nonce)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- gchar hash[33]; /* We only support MD5. */
-
- g_return_val_if_fail(username != NULL, NULL);
-@@ -1805,16 +1805,16 @@ gchar *gaim_cipher_http_digest_calculate
- strcasecmp(algorithm, "MD5") ||
- strcasecmp(algorithm, "MD5-sess"), NULL);
-
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
- g_return_val_if_fail(cipher != NULL, NULL);
-
-- context = gaim_cipher_context_new(cipher, NULL);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
-- gaim_cipher_context_append(context, (guchar *)username, strlen(username));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)realm, strlen(realm));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)password, strlen(password));
-+ gaim2_cipher_context_append(context, (guchar *)username, strlen(username));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)realm, strlen(realm));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)password, strlen(password));
-
- if (algorithm != NULL && !strcasecmp(algorithm, "MD5-sess"))
- {
-@@ -1822,29 +1822,29 @@ gchar *gaim_cipher_http_digest_calculate
-
- if (client_nonce == NULL)
- {
-- gaim_cipher_context_destroy(context);
-- gaim_debug_error("cipher", "Required client_nonce missing for MD5-sess digest calculation.");
-+ gaim2_cipher_context_destroy(context);
-+ gaim2_debug_error("cipher", "Required client_nonce missing for MD5-sess digest calculation.");
- return NULL;
- }
-
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, digest, sizeof(digest));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)nonce, strlen(nonce));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)client_nonce, strlen(client_nonce));
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, digest, sizeof(digest));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)nonce, strlen(nonce));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)client_nonce, strlen(client_nonce));
- }
-
-- gaim_cipher_context_digest_to_str(context, sizeof(hash), hash, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_digest_to_str(context, sizeof(hash), hash, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- return g_strdup(hash);
- }
-
--gchar *gaim_cipher_http_digest_calculate_response(
-+gchar *gaim2_cipher_http_digest_calculate_response(
- const gchar *algorithm,
- const gchar *method,
- const gchar *digest_uri,
-@@ -1855,8 +1855,8 @@ gchar *gaim_cipher_http_digest_calculate
- const gchar *client_nonce,
- const gchar *session_key)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- static gchar hash2[33]; /* We only support MD5. */
-
- g_return_val_if_fail(method != NULL, NULL);
-@@ -1876,77 +1876,77 @@ gchar *gaim_cipher_http_digest_calculate
- strcasecmp(qop, "auth") ||
- strcasecmp(qop, "auth-int"), NULL);
-
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
- g_return_val_if_fail(cipher != NULL, NULL);
-
-- context = gaim_cipher_context_new(cipher, NULL);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
-- gaim_cipher_context_append(context, (guchar *)method, strlen(method));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)digest_uri, strlen(digest_uri));
-+ gaim2_cipher_context_append(context, (guchar *)method, strlen(method));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)digest_uri, strlen(digest_uri));
-
- if (qop != NULL && !strcasecmp(qop, "auth-int"))
- {
-- GaimCipherContext *context2;
-+ Gaim2CipherContext *context2;
- gchar entity_hash[33];
-
- if (entity == NULL)
- {
-- gaim_cipher_context_destroy(context);
-- gaim_debug_error("cipher", "Required entity missing for auth-int digest calculation.");
-+ gaim2_cipher_context_destroy(context);
-+ gaim2_debug_error("cipher", "Required entity missing for auth-int digest calculation.");
- return NULL;
- }
-
-- context2 = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context2, (guchar *)entity, strlen(entity));
-- gaim_cipher_context_digest_to_str(context2, sizeof(entity_hash), entity_hash, NULL);
-- gaim_cipher_context_destroy(context2);
--
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)entity_hash, strlen(entity_hash));
-- }
--
-- gaim_cipher_context_digest_to_str(context, sizeof(hash2), hash2, NULL);
-- gaim_cipher_context_destroy(context);
--
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, (guchar *)session_key, strlen(session_key));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)nonce, strlen(nonce));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-+ context2 = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context2, (guchar *)entity, strlen(entity));
-+ gaim2_cipher_context_digest_to_str(context2, sizeof(entity_hash), entity_hash, NULL);
-+ gaim2_cipher_context_destroy(context2);
-+
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)entity_hash, strlen(entity_hash));
-+ }
-+
-+ gaim2_cipher_context_digest_to_str(context, sizeof(hash2), hash2, NULL);
-+ gaim2_cipher_context_destroy(context);
-+
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, (guchar *)session_key, strlen(session_key));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)nonce, strlen(nonce));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-
- if (qop != NULL && *qop != '\0')
- {
- if (nonce_count == NULL)
- {
-- gaim_cipher_context_destroy(context);
-- gaim_debug_error("cipher", "Required nonce_count missing for digest calculation.");
-+ gaim2_cipher_context_destroy(context);
-+ gaim2_debug_error("cipher", "Required nonce_count missing for digest calculation.");
- return NULL;
- }
-
- if (client_nonce == NULL)
- {
-- gaim_cipher_context_destroy(context);
-- gaim_debug_error("cipher", "Required client_nonce missing for digest calculation.");
-+ gaim2_cipher_context_destroy(context);
-+ gaim2_debug_error("cipher", "Required client_nonce missing for digest calculation.");
- return NULL;
- }
-
-- gaim_cipher_context_append(context, (guchar *)nonce_count, strlen(nonce_count));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-- gaim_cipher_context_append(context, (guchar *)client_nonce, strlen(client_nonce));
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)nonce_count, strlen(nonce_count));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)client_nonce, strlen(client_nonce));
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
-
- if (qop != NULL)
-- gaim_cipher_context_append(context, (guchar *)qop, strlen(qop));
-+ gaim2_cipher_context_append(context, (guchar *)qop, strlen(qop));
- else
-- gaim_cipher_context_append(context, (guchar *)"", 0);
-+ gaim2_cipher_context_append(context, (guchar *)"", 0);
-
-- gaim_cipher_context_append(context, (guchar *)":", 1);
-+ gaim2_cipher_context_append(context, (guchar *)":", 1);
- }
-
-- gaim_cipher_context_append(context, (guchar *)hash2, strlen(hash2));
-- gaim_cipher_context_digest_to_str(context, sizeof(hash2), hash2, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_append(context, (guchar *)hash2, strlen(hash2));
-+ gaim2_cipher_context_digest_to_str(context, sizeof(hash2), hash2, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- return g_strdup(hash2);
- }
-diff -prNu ./src/cipher.h ./src/cipher.h
---- ./src/cipher.h 2005-12-07 12:01:47.000000000 +0100
-+++ ./src/cipher.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file cipher.h Gaim Cipher API
-+ * @file cipher.h Gaim2 Cipher API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -27,19 +27,19 @@
-
- #include <glib.h>
-
--#define GAIM_CIPHER(obj) ((GaimCipher *)(obj)) /**< GaimCipher typecast helper */
--#define GAIM_CIPHER_OPS(obj) ((GaimCipherOps *)(obj)) /**< GaimCipherInfo typecase helper */
--#define GAIM_CIPHER_CONTEXT(obj) ((GaimCipherContext *)(obj)) /**< GaimCipherContext typecast helper */
--
--typedef struct _GaimCipher GaimCipher; /**< A handle to a GaimCipher */
--typedef struct _GaimCipherOps GaimCipherOps; /**< Ops for a GaimCipher */
--typedef struct _GaimCipherContext GaimCipherContext; /**< A context for a GaimCipher */
-+#define GAIM_CIPHER(obj) ((Gaim2Cipher *)(obj)) /**< Gaim2Cipher typecast helper */
-+#define GAIM_CIPHER_OPS(obj) ((Gaim2CipherOps *)(obj)) /**< Gaim2CipherInfo typecase helper */
-+#define GAIM_CIPHER_CONTEXT(obj) ((Gaim2CipherContext *)(obj)) /**< Gaim2CipherContext typecast helper */
-+
-+typedef struct _Gaim2Cipher Gaim2Cipher; /**< A handle to a Gaim2Cipher */
-+typedef struct _Gaim2CipherOps Gaim2CipherOps; /**< Ops for a Gaim2Cipher */
-+typedef struct _Gaim2CipherContext Gaim2CipherContext; /**< A context for a Gaim2Cipher */
-
-
- /**
- * The operation flags for a cipher
- */
--typedef enum _GaimCipherCaps {
-+typedef enum _Gaim2CipherCaps {
- GAIM_CIPHER_CAPS_SET_OPT = 1 << 1, /**< Set option flag */
- GAIM_CIPHER_CAPS_GET_OPT = 1 << 2, /**< Get option flag */
- GAIM_CIPHER_CAPS_INIT = 1 << 3, /**< Init flag */
-@@ -55,53 +55,53 @@ typedef enum _GaimCipherCaps {
- GAIM_CIPHER_CAPS_SET_KEY = 1 << 13, /**< Set key flag */
- GAIM_CIPHER_CAPS_GET_KEY_SIZE = 1 << 14, /**< Get key size flag */
- GAIM_CIPHER_CAPS_UNKNOWN = 1 << 16 /**< Unknown */
--} GaimCipherCaps;
-+} Gaim2CipherCaps;
-
- /**
- * The operations of a cipher. Every cipher must implement one of these.
- */
--struct _GaimCipherOps {
-+struct _Gaim2CipherOps {
- /** The set option function */
-- void (*set_option)(GaimCipherContext *context, const gchar *name, void *value);
-+ void (*set_option)(Gaim2CipherContext *context, const gchar *name, void *value);
-
- /** The get option function */
-- void *(*get_option)(GaimCipherContext *context, const gchar *name);
-+ void *(*get_option)(Gaim2CipherContext *context, const gchar *name);
-
- /** The init function */
-- void (*init)(GaimCipherContext *context, void *extra);
-+ void (*init)(Gaim2CipherContext *context, void *extra);
-
- /** The reset function */
-- void (*reset)(GaimCipherContext *context, void *extra);
-+ void (*reset)(Gaim2CipherContext *context, void *extra);
-
- /** The uninit function */
-- void (*uninit)(GaimCipherContext *context);
-+ void (*uninit)(Gaim2CipherContext *context);
-
- /** The set initialization vector function */
-- void (*set_iv)(GaimCipherContext *context, guchar *iv, size_t len);
-+ void (*set_iv)(Gaim2CipherContext *context, guchar *iv, size_t len);
-
- /** The append data function */
-- void (*append)(GaimCipherContext *context, const guchar *data, size_t len);
-+ void (*append)(Gaim2CipherContext *context, const guchar *data, size_t len);
-
- /** The digest function */
-- gboolean (*digest)(GaimCipherContext *context, size_t in_len, guchar digest[], size_t *out_len);
-+ gboolean (*digest)(Gaim2CipherContext *context, size_t in_len, guchar digest[], size_t *out_len);
-
- /** The encrypt function */
-- int (*encrypt)(GaimCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-+ int (*encrypt)(Gaim2CipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-
- /** The decrypt function */
-- int (*decrypt)(GaimCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-+ int (*decrypt)(Gaim2CipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-
- /** The set salt function */
-- void (*set_salt)(GaimCipherContext *context, guchar *salt);
-+ void (*set_salt)(Gaim2CipherContext *context, guchar *salt);
-
- /** The get salt size function */
-- size_t (*get_salt_size)(GaimCipherContext *context);
-+ size_t (*get_salt_size)(Gaim2CipherContext *context);
-
- /** The set key function */
-- void (*set_key)(GaimCipherContext *context, guchar *key);
-+ void (*set_key)(Gaim2CipherContext *context, guchar *key);
-
- /** The get key size function */
-- size_t (*get_key_size)(GaimCipherContext *context);
-+ size_t (*get_key_size)(Gaim2CipherContext *context);
- };
-
- #ifdef __cplusplus
-@@ -109,7 +109,7 @@ extern "C" {
- #endif /* __cplusplus */
-
- /*****************************************************************************/
--/** @name GaimCipher API */
-+/** @name Gaim2Cipher API */
- /*****************************************************************************/
- /*@{*/
-
-@@ -120,7 +120,7 @@ extern "C" {
- *
- * @return The cipher's name
- */
--const gchar *gaim_cipher_get_name(GaimCipher *cipher);
-+const gchar *gaim2_cipher_get_name(Gaim2Cipher *cipher);
-
- /**
- * Gets a cipher's capabilities
-@@ -129,7 +129,7 @@ const gchar *gaim_cipher_get_name(GaimCi
- *
- * @return The cipher's info
- */
--guint gaim_cipher_get_capabilities(GaimCipher *cipher);
-+guint gaim2_cipher_get_capabilities(Gaim2Cipher *cipher);
-
- /**
- * Gets a digest from a cipher
-@@ -143,11 +143,11 @@ guint gaim_cipher_get_capabilities(GaimC
- *
- * @return @c TRUE if successful, @c FALSE otherwise
- */
--gboolean gaim_cipher_digest_region(const gchar *name, const guchar *data, size_t data_len, size_t in_len, guchar digest[], size_t *out_len);
-+gboolean gaim2_cipher_digest_region(const gchar *name, const guchar *data, size_t data_len, size_t in_len, guchar digest[], size_t *out_len);
-
- /*@}*/
- /******************************************************************************/
--/** @name GaimCiphers API */
-+/** @name Gaim2Ciphers API */
- /******************************************************************************/
- /*@{*/
-
-@@ -158,7 +158,7 @@ gboolean gaim_cipher_digest_region(const
- *
- * @return The cipher handle or @c NULL
- */
--GaimCipher *gaim_ciphers_find_cipher(const gchar *name);
-+Gaim2Cipher *gaim2_ciphers_find_cipher(const gchar *name);
-
- /**
- * Registers a cipher as a usable cipher
-@@ -168,7 +168,7 @@ GaimCipher *gaim_ciphers_find_cipher(con
- *
- * @return The handle to the new cipher or @c NULL if it failed
- */
--GaimCipher *gaim_ciphers_register_cipher(const gchar *name, GaimCipherOps *ops);
-+Gaim2Cipher *gaim2_ciphers_register_cipher(const gchar *name, Gaim2CipherOps *ops);
-
- /**
- * Unregisters a cipher
-@@ -177,7 +177,7 @@ GaimCipher *gaim_ciphers_register_cipher
- *
- * @return Whether or not the cipher was successfully unloaded
- */
--gboolean gaim_ciphers_unregister_cipher(GaimCipher *cipher);
-+gboolean gaim2_ciphers_unregister_cipher(Gaim2Cipher *cipher);
-
- /**
- * Gets the list of ciphers
-@@ -185,11 +185,11 @@ gboolean gaim_ciphers_unregister_cipher(
- * @return The list of available ciphers
- * @note This list should not be modified, it is owned by the cipher core
- */
--GList *gaim_ciphers_get_ciphers(void);
-+GList *gaim2_ciphers_get_ciphers(void);
-
- /*@}*/
- /******************************************************************************/
--/** @name GaimCipher Subsystem API */
-+/** @name Gaim2Cipher Subsystem API */
- /******************************************************************************/
- /*@{*/
-
-@@ -198,21 +198,21 @@ GList *gaim_ciphers_get_ciphers(void);
- *
- * @return The handle to the cipher subsystem
- */
--gpointer gaim_ciphers_get_handle(void);
-+gpointer gaim2_ciphers_get_handle(void);
-
- /**
- * Initializes the cipher core
- */
--void gaim_ciphers_init(void);
-+void gaim2_ciphers_init(void);
-
- /**
- * Uninitializes the cipher core
- */
--void gaim_ciphers_uninit(void);
-+void gaim2_ciphers_uninit(void);
-
- /*@}*/
- /******************************************************************************/
--/** @name GaimCipherContext API */
-+/** @name Gaim2CipherContext API */
- /******************************************************************************/
- /*@{*/
-
-@@ -223,7 +223,7 @@ void gaim_ciphers_uninit(void);
- * @param name The name of the option
- * @param value The value to set
- */
--void gaim_cipher_context_set_option(GaimCipherContext *context, const gchar *name, gpointer value);
-+void gaim2_cipher_context_set_option(Gaim2CipherContext *context, const gchar *name, gpointer value);
-
- /**
- * Gets the vale of an option on a cipher context
-@@ -232,7 +232,7 @@ void gaim_cipher_context_set_option(Gaim
- * @param name The name of the option
- * @return The value of the option
- */
--gpointer gaim_cipher_context_get_option(GaimCipherContext *context, const gchar *name);
-+gpointer gaim2_cipher_context_get_option(Gaim2CipherContext *context, const gchar *name);
-
- /**
- * Creates a new cipher context and initializes it
-@@ -242,7 +242,7 @@ gpointer gaim_cipher_context_get_option(
- *
- * @return The new cipher context
- */
--GaimCipherContext *gaim_cipher_context_new(GaimCipher *cipher, void *extra);
-+Gaim2CipherContext *gaim2_cipher_context_new(Gaim2Cipher *cipher, void *extra);
-
- /**
- * Creates a new cipher context by the cipher name and initializes it
-@@ -252,7 +252,7 @@ GaimCipherContext *gaim_cipher_context_n
- *
- * @return The new cipher context
- */
--GaimCipherContext *gaim_cipher_context_new_by_name(const gchar *name, void *extra);
-+Gaim2CipherContext *gaim2_cipher_context_new_by_name(const gchar *name, void *extra);
-
- /**
- * Resets a cipher context to it's default value
-@@ -261,14 +261,14 @@ GaimCipherContext *gaim_cipher_context_n
- * @param context The context to reset
- * @param extra Extra data for the specific cipher
- */
--void gaim_cipher_context_reset(GaimCipherContext *context, gpointer extra);
-+void gaim2_cipher_context_reset(Gaim2CipherContext *context, gpointer extra);
-
- /**
- * Destorys a cipher context and deinitializes it
- *
- * @param context The cipher context to destory
- */
--void gaim_cipher_context_destroy(GaimCipherContext *context);
-+void gaim2_cipher_context_destroy(Gaim2CipherContext *context);
-
- /**
- * Sets the initialization vector for a context
-@@ -278,7 +278,7 @@ void gaim_cipher_context_destroy(GaimCip
- * @param iv The initialization vector to set
- * @param len The len of the IV
- */
--void gaim_cipher_context_set_iv(GaimCipherContext *context, guchar *iv, size_t len);
-+void gaim2_cipher_context_set_iv(Gaim2CipherContext *context, guchar *iv, size_t len);
-
- /**
- * Appends data to the context
-@@ -287,7 +287,7 @@ void gaim_cipher_context_set_iv(GaimCiph
- * @param data The data to append
- * @param len The length of the data
- */
--void gaim_cipher_context_append(GaimCipherContext *context, const guchar *data, size_t len);
-+void gaim2_cipher_context_append(Gaim2CipherContext *context, const guchar *data, size_t len);
-
- /**
- * Digests a context
-@@ -297,7 +297,7 @@ void gaim_cipher_context_append(GaimCiph
- * @param digest The return buffer for the digest
- * @param out_len The length of the returned value
- */
--gboolean gaim_cipher_context_digest(GaimCipherContext *context, size_t in_len, guchar digest[], size_t *out_len);
-+gboolean gaim2_cipher_context_digest(Gaim2CipherContext *context, size_t in_len, guchar digest[], size_t *out_len);
-
- /**
- * Converts a guchar digest into a hex string
-@@ -307,7 +307,7 @@ gboolean gaim_cipher_context_digest(Gaim
- * @param digest_s The return buffer for the string digest
- * @param out_len The length of the returned value
- */
--gboolean gaim_cipher_context_digest_to_str(GaimCipherContext *context, size_t in_len, gchar digest_s[], size_t *out_len);
-+gboolean gaim2_cipher_context_digest_to_str(Gaim2CipherContext *context, size_t in_len, gchar digest_s[], size_t *out_len);
-
- /**
- * Encrypts data using the context
-@@ -320,7 +320,7 @@ gboolean gaim_cipher_context_digest_to_s
- *
- * @return A cipher specific status code
- */
--gint gaim_cipher_context_encrypt(GaimCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-+gint gaim2_cipher_context_encrypt(Gaim2CipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-
- /**
- * Decrypts data using the context
-@@ -333,7 +333,7 @@ gint gaim_cipher_context_encrypt(GaimCip
- *
- * @return A cipher specific status code
- */
--gint gaim_cipher_context_decrypt(GaimCipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-+gint gaim2_cipher_context_decrypt(Gaim2CipherContext *context, const guchar data[], size_t len, guchar output[], size_t *outlen);
-
- /**
- * Sets the salt on a context
-@@ -341,7 +341,7 @@ gint gaim_cipher_context_decrypt(GaimCip
- * @param context The context who's salt to set
- * @param salt The salt
- */
--void gaim_cipher_context_set_salt(GaimCipherContext *context, guchar *salt);
-+void gaim2_cipher_context_set_salt(Gaim2CipherContext *context, guchar *salt);
-
- /**
- * Gets the size of the salt if the cipher supports it
-@@ -350,7 +350,7 @@ void gaim_cipher_context_set_salt(GaimCi
- *
- * @return The size of the salt
- */
--size_t gaim_cipher_context_get_salt_size(GaimCipherContext *context);
-+size_t gaim2_cipher_context_get_salt_size(Gaim2CipherContext *context);
-
- /**
- * Sets the key on a context
-@@ -358,7 +358,7 @@ size_t gaim_cipher_context_get_salt_size
- * @param context The context who's key to set
- * @param key The key
- */
--void gaim_cipher_context_set_key(GaimCipherContext *context, guchar *key);
-+void gaim2_cipher_context_set_key(Gaim2CipherContext *context, guchar *key);
-
- /**
- * Gets the key size for a context
-@@ -367,7 +367,7 @@ void gaim_cipher_context_set_key(GaimCip
- *
- * @return The size of the key
- */
--size_t gaim_cipher_context_get_key_size(GaimCipherContext *context);
-+size_t gaim2_cipher_context_get_key_size(Gaim2CipherContext *context);
-
- /**
- * Sets the cipher data for a context
-@@ -375,7 +375,7 @@ size_t gaim_cipher_context_get_key_size(
- * @param context The context who's cipher data to set
- * @param data The cipher data to set
- */
--void gaim_cipher_context_set_data(GaimCipherContext *context, gpointer data);
-+void gaim2_cipher_context_set_data(Gaim2CipherContext *context, gpointer data);
-
- /**
- * Gets the cipher data for a context
-@@ -384,11 +384,11 @@ void gaim_cipher_context_set_data(GaimCi
- *
- * @return The cipher data
- */
--gpointer gaim_cipher_context_get_data(GaimCipherContext *context);
-+gpointer gaim2_cipher_context_get_data(Gaim2CipherContext *context);
-
- /*@}*/
- /*****************************************************************************/
--/** @name Gaim Cipher HTTP Digest Helper Functions */
-+/** @name Gaim2 Cipher HTTP Digest Helper Functions */
- /*****************************************************************************/
- /*@{*/
-
-@@ -406,7 +406,7 @@ gpointer gaim_cipher_context_get_data(Ga
- *
- * @return The session key, or @c NULL if an error occurred.
- */
--gchar *gaim_cipher_http_digest_calculate_session_key(
-+gchar *gaim2_cipher_http_digest_calculate_session_key(
- const gchar *algorithm, const gchar *username,
- const gchar *realm, const gchar *password,
- const gchar *nonce, const gchar *client_nonce);
-@@ -423,11 +423,11 @@ gchar *gaim_cipher_http_digest_calculate
- * @param nonce The nonce provided by the server
- * @param nonce_count The nonce count
- * @param client_nonce The nonce provided by the client
-- * @param session_key The session key from gaim_cipher_http_digest_calculate_session_key()
-+ * @param session_key The session key from gaim2_cipher_http_digest_calculate_session_key()
- *
- * @return The hashed response, or @c NULL if an error occurred.
- */
--gchar *gaim_cipher_http_digest_calculate_response(
-+gchar *gaim2_cipher_http_digest_calculate_response(
- const gchar *algorithm, const gchar *method,
- const gchar *digest_uri, const gchar *qop,
- const gchar *entity, const gchar *nonce,
-diff -prNu ./src/cmds.c ./src/cmds.c
---- ./src/cmds.c 2005-11-09 02:15:47.000000000 +0100
-+++ ./src/cmds.c 2006-01-05 15:11:04.000000000 +0100
-@@ -29,20 +29,20 @@
- static GList *cmds = NULL;
- static guint next_id = 1;
-
--typedef struct _GaimCmd {
-- GaimCmdId id;
-+typedef struct _Gaim2Cmd {
-+ Gaim2CmdId id;
- gchar *cmd;
- gchar *args;
-- GaimCmdPriority priority;
-- GaimCmdFlag flags;
-+ Gaim2CmdPriority priority;
-+ Gaim2CmdFlag flags;
- gchar *prpl_id;
-- GaimCmdFunc func;
-+ Gaim2CmdFunc func;
- gchar *help;
- void *data;
--} GaimCmd;
-+} Gaim2Cmd;
-
-
--static gint cmds_compare_func(const GaimCmd *a, const GaimCmd *b)
-+static gint cmds_compare_func(const Gaim2Cmd *a, const Gaim2Cmd *b)
- {
- if (a->priority > b->priority)
- return -1;
-@@ -51,13 +51,13 @@ static gint cmds_compare_func(const Gaim
- else return 0;
- }
-
--GaimCmdId gaim_cmd_register(const gchar *cmd, const gchar *args,
-- GaimCmdPriority p, GaimCmdFlag f,
-- const gchar *prpl_id, GaimCmdFunc func,
-+Gaim2CmdId gaim2_cmd_register(const gchar *cmd, const gchar *args,
-+ Gaim2CmdPriority p, Gaim2CmdFlag f,
-+ const gchar *prpl_id, Gaim2CmdFunc func,
- const gchar *helpstr, void *data)
- {
-- GaimCmdId id;
-- GaimCmd *c;
-+ Gaim2CmdId id;
-+ Gaim2Cmd *c;
-
- g_return_val_if_fail(cmd != NULL && *cmd != '\0', 0);
- g_return_val_if_fail(args != NULL, 0);
-@@ -65,7 +65,7 @@ GaimCmdId gaim_cmd_register(const gchar
-
- id = next_id++;
-
-- c = g_new0(GaimCmd, 1);
-+ c = g_new0(Gaim2Cmd, 1);
- c->id = id;
- c->cmd = g_strdup(cmd);
- c->args = g_strdup(args);
-@@ -81,7 +81,7 @@ GaimCmdId gaim_cmd_register(const gchar
- return id;
- }
-
--static void gaim_cmd_free(GaimCmd *c)
-+static void gaim2_cmd_free(Gaim2Cmd *c)
- {
- g_free(c->cmd);
- g_free(c->args);
-@@ -93,9 +93,9 @@ static void gaim_cmd_free(GaimCmd *c)
- g_free(c);
- }
-
--void gaim_cmd_unregister(GaimCmdId id)
-+void gaim2_cmd_unregister(Gaim2CmdId id)
- {
-- GaimCmd *c;
-+ Gaim2Cmd *c;
- GList *l;
-
- for (l = cmds; l; l = l->next) {
-@@ -103,13 +103,13 @@ void gaim_cmd_unregister(GaimCmdId id)
-
- if (c->id == id) {
- cmds = g_list_remove(cmds, c);
-- gaim_cmd_free(c);
-+ gaim2_cmd_free(c);
- return;
- }
- }
- }
-
--static gboolean gaim_cmd_parse_args(GaimCmd *cmd, const gchar *s, const gchar *m, gchar ***args)
-+static gboolean gaim2_cmd_parse_args(Gaim2Cmd *cmd, const gchar *s, const gchar *m, gchar ***args)
- {
- int i;
- const char *end, *cur;
-@@ -136,10 +136,10 @@ static gboolean gaim_cmd_parse_args(Gaim
- case 'W':
- if (!(end = strchr(cur, ' '))) {
- end = cur + strlen(cur);
-- (*args)[i] = gaim_markup_slice(m, g_utf8_pointer_to_offset(s, cur), g_utf8_pointer_to_offset(s, end));
-+ (*args)[i] = gaim2_markup_slice(m, g_utf8_pointer_to_offset(s, cur), g_utf8_pointer_to_offset(s, end));
- cur = end;
- } else {
-- (*args)[i] = gaim_markup_slice(m, g_utf8_pointer_to_offset(s, cur), g_utf8_pointer_to_offset(s, end));
-+ (*args)[i] = gaim2_markup_slice(m, g_utf8_pointer_to_offset(s, cur), g_utf8_pointer_to_offset(s, end));
- cur = end +1;
- }
- break;
-@@ -148,7 +148,7 @@ static gboolean gaim_cmd_parse_args(Gaim
- cur = cur + strlen(cur);
- break;
- case 'S':
-- (*args)[i] = gaim_markup_slice(m, g_utf8_pointer_to_offset(s, cur), g_utf8_strlen(cur, -1) + 1);
-+ (*args)[i] = gaim2_markup_slice(m, g_utf8_pointer_to_offset(s, cur), g_utf8_strlen(cur, -1) + 1);
- cur = cur + strlen(cur);
- break;
- }
-@@ -160,7 +160,7 @@ static gboolean gaim_cmd_parse_args(Gaim
- return TRUE;
- }
-
--static void gaim_cmd_free_args(gchar **args)
-+static void gaim2_cmd_free_args(gchar **args)
- {
- int i;
-
-@@ -169,7 +169,7 @@ static void gaim_cmd_free_args(gchar **a
- g_free(args);
- }
-
--static void gaim_cmd_strip_current_char(gunichar c, char *s, guint len)
-+static void gaim2_cmd_strip_current_char(gunichar c, char *s, guint len)
- {
- int bytes;
-
-@@ -177,7 +177,7 @@ static void gaim_cmd_strip_current_char(
- memmove(s, s + bytes, len + 1 - bytes);
- }
-
--static void gaim_cmd_strip_cmd_from_markup(char *markup)
-+static void gaim2_cmd_strip_cmd_from_markup(char *markup)
- {
- guint len = strlen(markup);
- char *s = markup;
-@@ -190,20 +190,20 @@ static void gaim_cmd_strip_cmd_from_mark
- if (!s)
- return;
- } else if (g_unichar_isspace(c)) {
-- gaim_cmd_strip_current_char(c, s, len - (s - markup));
-+ gaim2_cmd_strip_current_char(c, s, len - (s - markup));
- return;
- } else {
-- gaim_cmd_strip_current_char(c, s, len - (s - markup));
-+ gaim2_cmd_strip_current_char(c, s, len - (s - markup));
- continue;
- }
- s = g_utf8_next_char(s);
- }
- }
-
--GaimCmdStatus gaim_cmd_do_command(GaimConversation *conv, const gchar *cmdline,
-+Gaim2CmdStatus gaim2_cmd_do_command(Gaim2Conversation *conv, const gchar *cmdline,
- const gchar *markup, gchar **error)
- {
-- GaimCmd *c;
-+ Gaim2Cmd *c;
- GList *l;
- gchar *err = NULL;
- gboolean is_im;
-@@ -211,14 +211,14 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- const gchar *prpl_id;
- gchar **args = NULL;
- gchar *cmd, *rest, *mrest;
-- GaimCmdRet ret = GAIM_CMD_RET_CONTINUE;
-+ Gaim2CmdRet ret = GAIM_CMD_RET_CONTINUE;
-
- *error = NULL;
-- prpl_id = gaim_account_get_protocol_id(gaim_conversation_get_account(conv));
-+ prpl_id = gaim2_account_get_protocol_id(gaim2_conversation_get_account(conv));
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- is_im = TRUE;
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- is_im = FALSE;
- else
- return GAIM_CMD_STATUS_FAILED;
-@@ -233,7 +233,7 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- }
-
- mrest = g_strdup(markup);
-- gaim_cmd_strip_cmd_from_markup(mrest);
-+ gaim2_cmd_strip_cmd_from_markup(mrest);
-
- for (l = cmds; l; l = l->next) {
- c = l->data;
-@@ -259,8 +259,8 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- right_prpl = TRUE;
-
- /* this checks the allow bad args flag for us */
-- if (!gaim_cmd_parse_args(c, rest, mrest, &args)) {
-- gaim_cmd_free_args(args);
-+ if (!gaim2_cmd_parse_args(c, rest, mrest, &args)) {
-+ gaim2_cmd_free_args(args);
- args = NULL;
- continue;
- }
-@@ -271,7 +271,7 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- if (err)
- g_free(err);
- err = NULL;
-- gaim_cmd_free_args(args);
-+ gaim2_cmd_free_args(args);
- args = NULL;
- continue;
- } else {
-@@ -281,7 +281,7 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- }
-
- if (args)
-- gaim_cmd_free_args(args);
-+ gaim2_cmd_free_args(args);
- g_free(cmd);
- g_free(mrest);
-
-@@ -308,24 +308,24 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- }
-
-
--GList *gaim_cmd_list(GaimConversation *conv)
-+GList *gaim2_cmd_list(Gaim2Conversation *conv)
- {
- GList *ret = NULL;
-- GaimCmd *c;
-+ Gaim2Cmd *c;
- GList *l;
-
- for (l = cmds; l; l = l->next) {
- c = l->data;
-
-- if (conv && (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM))
-+ if (conv && (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM))
- if (!(c->flags & GAIM_CMD_FLAG_IM))
- continue;
-- if (conv && (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT))
-+ if (conv && (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT))
- if (!(c->flags & GAIM_CMD_FLAG_CHAT))
- continue;
-
- if (conv && (c->flags & GAIM_CMD_FLAG_PRPL_ONLY) && c->prpl_id &&
-- (strcmp(c->prpl_id, gaim_account_get_protocol_id(gaim_conversation_get_account(conv))) != 0))
-+ (strcmp(c->prpl_id, gaim2_account_get_protocol_id(gaim2_conversation_get_account(conv))) != 0))
- continue;
-
- ret = g_list_append(ret, c->cmd);
-@@ -337,10 +337,10 @@ GList *gaim_cmd_list(GaimConversation *c
- }
-
-
--GList *gaim_cmd_help(GaimConversation *conv, const gchar *cmd)
-+GList *gaim2_cmd_help(Gaim2Conversation *conv, const gchar *cmd)
- {
- GList *ret = NULL;
-- GaimCmd *c;
-+ Gaim2Cmd *c;
- GList *l;
-
- for (l = cmds; l; l = l->next) {
-@@ -349,15 +349,15 @@ GList *gaim_cmd_help(GaimConversation *c
- if (cmd && (strcmp(cmd, c->cmd) != 0))
- continue;
-
-- if (conv && (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM))
-+ if (conv && (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM))
- if (!(c->flags & GAIM_CMD_FLAG_IM))
- continue;
-- if (conv && (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT))
-+ if (conv && (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT))
- if (!(c->flags & GAIM_CMD_FLAG_CHAT))
- continue;
-
- if (conv && (c->flags & GAIM_CMD_FLAG_PRPL_ONLY) && c->prpl_id &&
-- (strcmp(c->prpl_id, gaim_account_get_protocol_id(gaim_conversation_get_account(conv))) != 0))
-+ (strcmp(c->prpl_id, gaim2_account_get_protocol_id(gaim2_conversation_get_account(conv))) != 0))
- continue;
-
- ret = g_list_append(ret, c->help);
-diff -prNu ./src/cmds.h ./src/cmds.h
---- ./src/cmds.h 2005-04-07 16:41:18.000000000 +0200
-+++ ./src/cmds.h 2006-01-05 15:11:20.000000000 +0100
-@@ -29,12 +29,12 @@
- /**************************************************************************/
- /*@{*/
-
--typedef enum _GaimCmdPriority GaimCmdPriority;
--typedef enum _GaimCmdFlag GaimCmdFlag;
--typedef enum _GaimCmdStatus GaimCmdStatus;
--typedef enum _GaimCmdRet GaimCmdRet;
-+typedef enum _Gaim2CmdPriority Gaim2CmdPriority;
-+typedef enum _Gaim2CmdFlag Gaim2CmdFlag;
-+typedef enum _Gaim2CmdStatus Gaim2CmdStatus;
-+typedef enum _Gaim2CmdRet Gaim2CmdRet;
-
--enum _GaimCmdStatus {
-+enum _Gaim2CmdStatus {
- GAIM_CMD_STATUS_OK,
- GAIM_CMD_STATUS_FAILED,
- GAIM_CMD_STATUS_NOT_FOUND,
-@@ -43,19 +43,19 @@ enum _GaimCmdStatus {
- GAIM_CMD_STATUS_WRONG_TYPE,
- };
-
--enum _GaimCmdRet {
-+enum _Gaim2CmdRet {
- GAIM_CMD_RET_OK, /**< Everything's okay. Don't look for another command to call. */
- GAIM_CMD_RET_FAILED, /**< The command failed, but stop looking.*/
- GAIM_CMD_RET_CONTINUE, /**< Continue, looking for other commands with the same name to call. */
- };
-
--#define GAIM_CMD_FUNC(func) ((GaimCmdFunc)func)
-+#define GAIM_CMD_FUNC(func) ((Gaim2CmdFunc)func)
-
--typedef GaimCmdRet (*GaimCmdFunc)(GaimConversation *, const gchar *cmd,
-+typedef Gaim2CmdRet (*Gaim2CmdFunc)(Gaim2Conversation *, const gchar *cmd,
- gchar **args, gchar **error, void *data);
--typedef guint GaimCmdId;
-+typedef guint Gaim2CmdId;
-
--enum _GaimCmdPriority {
-+enum _Gaim2CmdPriority {
- GAIM_CMD_P_VERY_LOW = -1000,
- GAIM_CMD_P_LOW = 0,
- GAIM_CMD_P_DEFAULT = 1000,
-@@ -66,7 +66,7 @@ enum _GaimCmdPriority {
- GAIM_CMD_P_VERYHIGH = 6000,
- };
-
--enum _GaimCmdFlag {
-+enum _Gaim2CmdFlag {
- GAIM_CMD_FLAG_IM = 0x01,
- GAIM_CMD_FLAG_CHAT = 0x02,
- GAIM_CMD_FLAG_PRPL_ONLY = 0x04,
-@@ -93,8 +93,8 @@ extern "C" {
- *
- * @param cmd The command. This should be a UTF8 (or ASCII) string, with no spaces
- * or other white space.
-- * @param args This tells Gaim how to parse the arguments to the command for you.
-- * If what the user types doesn't match, Gaim will keep looking for another
-+ * @param args This tells Gaim2 how to parse the arguments to the command for you.
-+ * If what the user types doesn't match, Gaim2 will keep looking for another
- * command, unless the flag @c GAIM_CMD_FLAG_ALLOW_WRONG_ARGS is passed in f.
- * This string contains no whitespace, and uses a single character for each argument.
- * The recognized characters are:
-@@ -118,12 +118,12 @@ extern "C" {
- * and any arguments it accpets (if it takes any arguments, otherwise no space), follow
- * by a colon, two spaces, and a description of the command in sentence form. No slash
- * before the command name.
-- * @param data User defined data to pass to the GaimCmdFunc
-- * @return A GaimCmdId. This is only used for calling gaim_cmd_unregister.
-+ * @param data User defined data to pass to the Gaim2CmdFunc
-+ * @return A Gaim2CmdId. This is only used for calling gaim2_cmd_unregister.
- * Returns 0 on failure.
- */
--GaimCmdId gaim_cmd_register(const gchar *cmd, const gchar *args, GaimCmdPriority p, GaimCmdFlag f,
-- const gchar *prpl_id, GaimCmdFunc func, const gchar *helpstr, void *data);
-+Gaim2CmdId gaim2_cmd_register(const gchar *cmd, const gchar *args, Gaim2CmdPriority p, Gaim2CmdFlag f,
-+ const gchar *prpl_id, Gaim2CmdFunc func, const gchar *helpstr, void *data);
-
- /**
- * Unregister a command with the core.
-@@ -132,9 +132,9 @@ GaimCmdId gaim_cmd_register(const gchar
- * or something else that might go away. Normally this is called when the plugin
- * unloads itself.
- *
-- * @param id The GaimCmdId to unregister.
-+ * @param id The Gaim2CmdId to unregister.
- */
--void gaim_cmd_unregister(GaimCmdId id);
-+void gaim2_cmd_unregister(Gaim2CmdId id);
-
- /**
- * Do a command.
-@@ -152,9 +152,9 @@ void gaim_cmd_unregister(GaimCmdId id);
- * include both the default formatting and any extra manual formatting.
- * @param errormsg If the command failed errormsg is filled in with the appropriate error
- * message. It must be freed by the caller with g_free().
-- * @return A GaimCmdStatus indicated if the command succeeded or failed.
-+ * @return A Gaim2CmdStatus indicated if the command succeeded or failed.
- */
--GaimCmdStatus gaim_cmd_do_command(GaimConversation *conv, const gchar *cmdline,
-+Gaim2CmdStatus gaim2_cmd_do_command(Gaim2Conversation *conv, const gchar *cmdline,
- const gchar *markup, gchar **errormsg);
-
- /**
-@@ -168,7 +168,7 @@ GaimCmdStatus gaim_cmd_do_command(GaimCo
- * @param conv The conversation, or @c NULL.
- * @return A GList of const char*, which must be freed with g_list_free().
- */
--GList *gaim_cmd_list(GaimConversation *conv);
-+GList *gaim2_cmd_list(Gaim2Conversation *conv);
-
- /**
- * Get the help string for a command.
-@@ -182,7 +182,7 @@ GList *gaim_cmd_list(GaimConversation *c
- * @return A GList of const char*s, which is the help string
- * for that command.
- */
--GList *gaim_cmd_help(GaimConversation *conv, const gchar *cmd);
-+GList *gaim2_cmd_help(Gaim2Conversation *conv, const gchar *cmd);
-
- /*@}*/
-
-diff -prNu ./src/connection.c ./src/connection.c
---- ./src/connection.c 2005-12-08 22:00:31.000000000 +0100
-+++ ./src/connection.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file connection.c Connection API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,7 +28,7 @@
- #include "connection.h"
- #include "dbus-maybe.h"
- #include "debug.h"
--#include "gaim.h"
-+#include "gaim2.h"
- #include "log.h"
- #include "notify.h"
- #include "prefs.h"
-@@ -39,15 +39,15 @@
-
- static GList *connections = NULL;
- static GList *connections_connecting = NULL;
--static GaimConnectionUiOps *connection_ui_ops = NULL;
-+static Gaim2ConnectionUiOps *connection_ui_ops = NULL;
-
- static int connections_handle;
-
- static gboolean
- send_keepalive(gpointer data)
- {
-- GaimConnection *gc = data;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = data;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -59,34 +59,34 @@ send_keepalive(gpointer data)
- }
-
- static void
--update_keepalive(GaimConnection *gc, gboolean on)
-+update_keepalive(Gaim2Connection *gc, gboolean on)
- {
- if (on && !gc->keepalive)
- {
-- gaim_debug_info("connection", "Activating keepalive.\n");
-- gc->keepalive = gaim_timeout_add(30000, send_keepalive, gc);
-+ gaim2_debug_info("connection", "Activating keepalive.\n");
-+ gc->keepalive = gaim2_timeout_add(30000, send_keepalive, gc);
- }
- else if (!on && gc->keepalive > 0)
- {
-- gaim_debug_info("connection", "Deactivating keepalive.\n");
-- gaim_timeout_remove(gc->keepalive);
-+ gaim2_debug_info("connection", "Deactivating keepalive.\n");
-+ gaim2_timeout_remove(gc->keepalive);
- gc->keepalive = 0;
- }
- }
-
- void
--gaim_connection_new(GaimAccount *account, gboolean regist, const char *password)
-+gaim2_connection_new(Gaim2Account *account, gboolean regist, const char *password)
- {
-- GaimConnection *gc;
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Connection *gc;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- g_return_if_fail(account != NULL);
-
-- if (!gaim_account_is_disconnected(account))
-+ if (!gaim2_account_is_disconnected(account))
- return;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- if (prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-@@ -94,8 +94,8 @@ gaim_connection_new(GaimAccount *account
- gchar *message;
-
- message = g_strdup_printf(_("Missing protocol plugin for %s"),
-- gaim_account_get_username(account));
-- gaim_notify_error(NULL, regist ? _("Registration Error") :
-+ gaim2_account_get_username(account));
-+ gaim2_notify_error(NULL, regist ? _("Registration Error") :
- _("Connection Error"), message, NULL);
- g_free(message);
- return;
-@@ -112,28 +112,28 @@ gaim_connection_new(GaimAccount *account
- !(prpl_info->options & OPT_PROTO_NO_PASSWORD) &&
- !(prpl_info->options & OPT_PROTO_PASSWORD_OPTIONAL))
- {
-- gaim_debug_error("connection", "Can not connect to account %s without "
-- "a password.\n", gaim_account_get_username(account));
-+ gaim2_debug_error("connection", "Can not connect to account %s without "
-+ "a password.\n", gaim2_account_get_username(account));
- return;
- }
- }
-
-- gc = g_new0(GaimConnection, 1);
-- GAIM_DBUS_REGISTER_POINTER(gc, GaimConnection);
-+ gc = g_new0(Gaim2Connection, 1);
-+ GAIM_DBUS_REGISTER_POINTER(gc, Gaim2Connection);
-
- gc->prpl = prpl;
- if ((password != NULL) && (*password != '\0'))
- gc->password = g_strdup(password);
-- gaim_connection_set_account(gc, account);
-- gaim_connection_set_state(gc, GAIM_CONNECTING);
-+ gaim2_connection_set_account(gc, account);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTING);
- connections = g_list_append(connections, gc);
-- gaim_account_set_connection(account, gc);
-+ gaim2_account_set_connection(account, gc);
-
-- gaim_signal_emit(gaim_connections_get_handle(), "signing-on", gc);
-+ gaim2_signal_emit(gaim2_connections_get_handle(), "signing-on", gc);
-
- if (regist)
- {
-- gaim_debug_info("connection", "Registering. gc = %p\n", gc);
-+ gaim2_debug_info("connection", "Registering. gc = %p\n", gc);
-
- /* set this so we don't auto-reconnect after registering */
- gc->wants_to_die = TRUE;
-@@ -142,40 +142,40 @@ gaim_connection_new(GaimAccount *account
- }
- else
- {
-- gaim_debug_info("connection", "Connecting. gc = %p\n", gc);
-+ gaim2_debug_info("connection", "Connecting. gc = %p\n", gc);
-
-- gaim_signal_emit(gaim_accounts_get_handle(), "account-connecting", account);
-+ gaim2_signal_emit(gaim2_accounts_get_handle(), "account-connecting", account);
- prpl_info->login(account);
- }
- }
-
- void
--gaim_connection_destroy(GaimConnection *gc)
-+gaim2_connection_destroy(Gaim2Connection *gc)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- #if 0
- GList *wins;
- #endif
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- gboolean remove = FALSE;
-
- g_return_if_fail(gc != NULL);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- gaim_debug_info("connection", "Disconnecting connection %p\n", gc);
-+ gaim2_debug_info("connection", "Disconnecting connection %p\n", gc);
-
-- if (gaim_connection_get_state(gc) != GAIM_CONNECTING)
-+ if (gaim2_connection_get_state(gc) != GAIM_CONNECTING)
- remove = TRUE;
-
-- gaim_signal_emit(gaim_connections_get_handle(), "signing-off", gc);
-+ gaim2_signal_emit(gaim2_connections_get_handle(), "signing-off", gc);
-
- while (gc->buddy_chats)
- {
-- GaimConversation *b = gc->buddy_chats->data;
-+ Gaim2Conversation *b = gc->buddy_chats->data;
-
- gc->buddy_chats = g_slist_remove(gc->buddy_chats, b);
-- gaim_conv_chat_left(GAIM_CONV_CHAT(b));
-+ gaim2_conv_chat_left(GAIM_CONV_CHAT(b));
- }
-
- update_keepalive(gc, FALSE);
-@@ -190,12 +190,12 @@ gaim_connection_destroy(GaimConnection *
-
- connections = g_list_remove(connections, gc);
-
-- gaim_connection_set_state(gc, GAIM_DISCONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_DISCONNECTED);
-
- if (remove)
-- gaim_blist_remove_account(account);
-+ gaim2_blist_remove_account(account);
-
-- gaim_signal_emit(gaim_connections_get_handle(), "signed-off", gc);
-+ gaim2_signal_emit(gaim2_connections_get_handle(), "signed-off", gc);
-
- #if 0
- /* see comment later in file on if 0'd same code */
-@@ -203,19 +203,19 @@ gaim_connection_destroy(GaimConnection *
- * XXX This is a hack! Remove this and replace it with a better event
- * notification system.
- */
-- for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) {
-- GaimConvWindow *win = (GaimConvWindow *)wins->data;
-- gaim_conversation_update(gaim_conv_window_get_conversation_at(win, 0),
-+ for (wins = gaim2_get_windows(); wins != NULL; wins = wins->next) {
-+ Gaim2ConvWindow *win = (Gaim2ConvWindow *)wins->data;
-+ gaim2_conversation_update(gaim2_conv_window_get_conversation_at(win, 0),
- GAIM_CONV_ACCOUNT_OFFLINE);
- }
- #endif
-
-- gaim_request_close_with_handle(gc);
-- gaim_notify_close_with_handle(gc);
-+ gaim2_request_close_with_handle(gc);
-+ gaim2_notify_close_with_handle(gc);
-
-- gaim_debug_info("connection", "Destroying connection %p\n", gc);
-+ gaim2_debug_info("connection", "Destroying connection %p\n", gc);
-
-- gaim_account_set_connection(account, NULL);
-+ gaim2_account_set_connection(account, NULL);
-
- if (gc->password != NULL)
- g_free(gc->password);
-@@ -224,7 +224,7 @@ gaim_connection_destroy(GaimConnection *
- g_free(gc->display_name);
-
- if (gc->disconnect_timeout)
-- gaim_timeout_remove(gc->disconnect_timeout);
-+ gaim2_timeout_remove(gc->disconnect_timeout);
-
- GAIM_DBUS_UNREGISTER_POINTER(gc);
- g_free(gc);
-@@ -241,9 +241,9 @@ gaim_connection_destroy(GaimConnection *
- */
-
- void
--gaim_connection_set_state(GaimConnection *gc, GaimConnectionState state)
-+gaim2_connection_set_state(Gaim2Connection *gc, Gaim2ConnectionState state)
- {
-- GaimConnectionUiOps *ops;
-+ Gaim2ConnectionUiOps *ops;
-
- g_return_if_fail(gc != NULL);
-
-@@ -252,7 +252,7 @@ gaim_connection_set_state(GaimConnection
-
- gc->state = state;
-
-- ops = gaim_connections_get_ui_ops();
-+ ops = gaim2_connections_get_ui_ops();
-
- if (gc->state == GAIM_CONNECTING) {
- connections_connecting = g_list_append(connections_connecting, gc);
-@@ -265,23 +265,23 @@ gaim_connection_set_state(GaimConnection
- #if 0
- GList *wins;
- #endif
-- GaimAccount *account;
-- GaimPresence *presence;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
-
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-
- /* Set the time the account came online */
-- gaim_presence_set_login_time(presence, time(NULL));
-+ gaim2_presence_set_login_time(presence, time(NULL));
-
-- if (gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_system"))
- {
-- GaimLog *log = gaim_account_get_log(account);
-+ Gaim2Log *log = gaim2_account_get_log(account);
- char *msg = g_strdup_printf(_("+++ %s signed on"),
-- gaim_account_get_username(account));
-- gaim_log_write(log, GAIM_MESSAGE_SYSTEM,
-- gaim_account_get_username(account),
-- gaim_presence_get_login_time(presence),
-+ gaim2_account_get_username(account));
-+ gaim2_log_write(log, GAIM_MESSAGE_SYSTEM,
-+ gaim2_account_get_username(account),
-+ gaim2_presence_get_login_time(presence),
- msg);
- g_free(msg);
- }
-@@ -289,7 +289,7 @@ gaim_connection_set_state(GaimConnection
- if (ops != NULL && ops->connected != NULL)
- ops->connected(gc);
-
-- gaim_blist_add_account(account);
-+ gaim2_blist_add_account(account);
-
- /*
- * XXX This is a hack! Remove this and replace it with a better event
-@@ -298,36 +298,36 @@ gaim_connection_set_state(GaimConnection
- #if 0
- /* This looks like it was horribly broken before I got here... */
- /* Why is it updating the first tab of each window? */
-- for (wins = gaim_get_windows(); wins != NULL; wins = wins->next) {
-- GaimConvWindow *win = (GaimConvWindow *)wins->data;
-- gaim_conversation_update(gaim_conv_window_get_conversation_at(win, 0),
-+ for (wins = gaim2_get_windows(); wins != NULL; wins = wins->next) {
-+ Gaim2ConvWindow *win = (Gaim2ConvWindow *)wins->data;
-+ gaim2_conversation_update(gaim2_conv_window_get_conversation_at(win, 0),
- GAIM_CONV_ACCOUNT_ONLINE);
- }
- #endif
-- gaim_signal_emit(gaim_connections_get_handle(), "signed-on", gc);
-+ gaim2_signal_emit(gaim2_connections_get_handle(), "signed-on", gc);
-
- serv_set_permit_deny(gc);
-
- update_keepalive(gc, TRUE);
-
-- if (gaim_account_get_user_info(account) != NULL)
-- serv_set_info(gc, gaim_account_get_user_info(account));
-+ if (gaim2_account_get_user_info(account) != NULL)
-+ serv_set_info(gc, gaim2_account_get_user_info(account));
- }
- else if (gc->state == GAIM_DISCONNECTED) {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-
-- if (gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_system"))
- {
-- GaimLog *log = gaim_account_get_log(account);
-+ Gaim2Log *log = gaim2_account_get_log(account);
- char *msg = g_strdup_printf(_("+++ %s signed off"),
-- gaim_account_get_username(account));
-- gaim_log_write(log, GAIM_MESSAGE_SYSTEM,
-- gaim_account_get_username(account), time(NULL),
-+ gaim2_account_get_username(account));
-+ gaim2_log_write(log, GAIM_MESSAGE_SYSTEM,
-+ gaim2_account_get_username(account), time(NULL),
- msg);
- g_free(msg);
- }
-
-- gaim_account_destroy_log(account);
-+ gaim2_account_destroy_log(account);
-
- if (ops != NULL && ops->disconnected != NULL)
- ops->disconnected(gc);
-@@ -335,7 +335,7 @@ gaim_connection_set_state(GaimConnection
- }
-
- void
--gaim_connection_set_account(GaimConnection *gc, GaimAccount *account)
-+gaim2_connection_set_account(Gaim2Connection *gc, Gaim2Account *account)
- {
- g_return_if_fail(gc != NULL);
- g_return_if_fail(account != NULL);
-@@ -344,7 +344,7 @@ gaim_connection_set_account(GaimConnecti
- }
-
- void
--gaim_connection_set_display_name(GaimConnection *gc, const char *name)
-+gaim2_connection_set_display_name(Gaim2Connection *gc, const char *name)
- {
- g_return_if_fail(gc != NULL);
-
-@@ -354,16 +354,16 @@ gaim_connection_set_display_name(GaimCon
- gc->display_name = (name == NULL ? NULL : g_strdup(name));
- }
-
--GaimConnectionState
--gaim_connection_get_state(const GaimConnection *gc)
-+Gaim2ConnectionState
-+gaim2_connection_get_state(const Gaim2Connection *gc)
- {
- g_return_val_if_fail(gc != NULL, GAIM_DISCONNECTED);
-
- return gc->state;
- }
-
--GaimAccount *
--gaim_connection_get_account(const GaimConnection *gc)
-+Gaim2Account *
-+gaim2_connection_get_account(const Gaim2Connection *gc)
- {
- g_return_val_if_fail(gc != NULL, NULL);
-
-@@ -371,7 +371,7 @@ gaim_connection_get_account(const GaimCo
- }
-
- const char *
--gaim_connection_get_password(const GaimConnection *gc)
-+gaim2_connection_get_password(const Gaim2Connection *gc)
- {
- g_return_val_if_fail(gc != NULL, NULL);
-
-@@ -379,7 +379,7 @@ gaim_connection_get_password(const GaimC
- }
-
- const char *
--gaim_connection_get_display_name(const GaimConnection *gc)
-+gaim2_connection_get_display_name(const Gaim2Connection *gc)
- {
- g_return_val_if_fail(gc != NULL, NULL);
-
-@@ -387,51 +387,51 @@ gaim_connection_get_display_name(const G
- }
-
- void
--gaim_connection_update_progress(GaimConnection *gc, const char *text,
-+gaim2_connection_update_progress(Gaim2Connection *gc, const char *text,
- size_t step, size_t count)
- {
-- GaimConnectionUiOps *ops;
-+ Gaim2ConnectionUiOps *ops;
-
- g_return_if_fail(gc != NULL);
- g_return_if_fail(text != NULL);
- g_return_if_fail(step < count);
- g_return_if_fail(count > 1);
-
-- ops = gaim_connections_get_ui_ops();
-+ ops = gaim2_connections_get_ui_ops();
-
- if (ops != NULL && ops->connect_progress != NULL)
- ops->connect_progress(gc, text, step, count);
- }
-
- void
--gaim_connection_notice(GaimConnection *gc, const char *text)
-+gaim2_connection_notice(Gaim2Connection *gc, const char *text)
- {
-- GaimConnectionUiOps *ops;
-+ Gaim2ConnectionUiOps *ops;
-
- g_return_if_fail(gc != NULL);
- g_return_if_fail(text != NULL);
-
-- ops = gaim_connections_get_ui_ops();
-+ ops = gaim2_connections_get_ui_ops();
-
- if (ops != NULL && ops->notice != NULL)
- ops->notice(gc, text);
- }
-
- static gboolean
--gaim_connection_disconnect_cb(gpointer data)
-+gaim2_connection_disconnect_cb(gpointer data)
- {
-- GaimAccount *account = data;
-- char *password = g_strdup(gaim_account_get_password(account));
-- gaim_account_disconnect(account);
-- gaim_account_set_password(account, password);
-+ Gaim2Account *account = data;
-+ char *password = g_strdup(gaim2_account_get_password(account));
-+ gaim2_account_disconnect(account);
-+ gaim2_account_set_password(account, password);
- g_free(password);
- return FALSE;
- }
-
- void
--gaim_connection_error(GaimConnection *gc, const char *text)
-+gaim2_connection_error(Gaim2Connection *gc, const char *text)
- {
-- GaimConnectionUiOps *ops;
-+ Gaim2ConnectionUiOps *ops;
-
- g_return_if_fail(gc != NULL);
- g_return_if_fail(text != NULL);
-@@ -440,88 +440,88 @@ gaim_connection_error(GaimConnection *gc
- if (gc->disconnect_timeout)
- return;
-
-- ops = gaim_connections_get_ui_ops();
-+ ops = gaim2_connections_get_ui_ops();
-
- if (ops != NULL) {
- if (ops->report_disconnect != NULL)
- ops->report_disconnect(gc, text);
- }
-
-- gc->disconnect_timeout = gaim_timeout_add(0, gaim_connection_disconnect_cb,
-- gaim_connection_get_account(gc));
-+ gc->disconnect_timeout = gaim2_timeout_add(0, gaim2_connection_disconnect_cb,
-+ gaim2_connection_get_account(gc));
- }
-
- void
--gaim_connections_disconnect_all(void)
-+gaim2_connections_disconnect_all(void)
- {
- GList *l;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- while ((l = gaim_connections_get_all()) != NULL) {
-+ while ((l = gaim2_connections_get_all()) != NULL) {
- gc = l->data;
- gc->wants_to_die = TRUE;
-- gaim_account_disconnect(gc->account);
-+ gaim2_account_disconnect(gc->account);
- }
- }
-
- GList *
--gaim_connections_get_all(void)
-+gaim2_connections_get_all(void)
- {
- return connections;
- }
-
- GList *
--gaim_connections_get_connecting(void)
-+gaim2_connections_get_connecting(void)
- {
- return connections_connecting;
- }
-
- void
--gaim_connections_set_ui_ops(GaimConnectionUiOps *ops)
-+gaim2_connections_set_ui_ops(Gaim2ConnectionUiOps *ops)
- {
- connection_ui_ops = ops;
- }
-
--GaimConnectionUiOps *
--gaim_connections_get_ui_ops(void)
-+Gaim2ConnectionUiOps *
-+gaim2_connections_get_ui_ops(void)
- {
- return connection_ui_ops;
- }
-
- void
--gaim_connections_init(void)
-+gaim2_connections_init(void)
- {
-- void *handle = gaim_connections_get_handle();
-+ void *handle = gaim2_connections_get_handle();
-
-- gaim_signal_register(handle, "signing-on",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "signing-on",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONNECTION));
-
-- gaim_signal_register(handle, "signed-on",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "signed-on",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONNECTION));
-
-- gaim_signal_register(handle, "signing-off",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "signing-off",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONNECTION));
-
-- gaim_signal_register(handle, "signed-off",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "signed-off",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONNECTION));
- }
-
- void
--gaim_connections_uninit(void)
-+gaim2_connections_uninit(void)
- {
-- gaim_signals_unregister_by_instance(gaim_connections_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_connections_get_handle());
- }
-
- void *
--gaim_connections_get_handle(void)
-+gaim2_connections_get_handle(void)
- {
- return &connections_handle;
- }
-diff -prNu ./src/connection.h ./src/connection.h
---- ./src/connection.h 2005-11-30 07:03:49.000000000 +0100
-+++ ./src/connection.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file connection.h Connection API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -27,7 +27,7 @@
- #ifndef _GAIM_CONNECTION_H_
- #define _GAIM_CONNECTION_H_
-
--typedef struct _GaimConnection GaimConnection;
-+typedef struct _Gaim2Connection Gaim2Connection;
-
- /**
- * Flags to change behavior of the client for a given connection.
-@@ -44,7 +44,7 @@ typedef enum
- GAIM_CONNECTION_NO_URLDESC = 0x0040, /**< Connection does not support descriptions with links */
- GAIM_CONNECTION_NO_IMAGES = 0x0080, /**< Connection does not support sending of images */
-
--} GaimConnectionFlags;
-+} Gaim2ConnectionFlags;
-
- typedef enum
- {
-@@ -52,7 +52,7 @@ typedef enum
- GAIM_CONNECTED, /**< Connected. */
- GAIM_CONNECTING /**< Connecting. */
-
--} GaimConnectionState;
-+} Gaim2ConnectionState;
-
- #include <time.h>
-
-@@ -62,23 +62,23 @@ typedef enum
-
- typedef struct
- {
-- void (*connect_progress)(GaimConnection *gc, const char *text,
-+ void (*connect_progress)(Gaim2Connection *gc, const char *text,
- size_t step, size_t step_count);
-- void (*connected)(GaimConnection *gc);
-- void (*disconnected)(GaimConnection *gc);
-- void (*notice)(GaimConnection *gc, const char *text);
-- void (*report_disconnect)(GaimConnection *gc, const char *text);
-+ void (*connected)(Gaim2Connection *gc);
-+ void (*disconnected)(Gaim2Connection *gc);
-+ void (*notice)(Gaim2Connection *gc, const char *text);
-+ void (*report_disconnect)(Gaim2Connection *gc, const char *text);
-
--} GaimConnectionUiOps;
-+} Gaim2ConnectionUiOps;
-
--struct _GaimConnection
-+struct _Gaim2Connection
- {
-- GaimPlugin *prpl; /**< The protocol plugin. */
-- GaimConnectionFlags flags; /**< Connection flags. */
-+ Gaim2Plugin *prpl; /**< The protocol plugin. */
-+ Gaim2ConnectionFlags flags; /**< Connection flags. */
-
-- GaimConnectionState state; /**< The connection state. */
-+ Gaim2ConnectionState state; /**< The connection state. */
-
-- GaimAccount *account; /**< The account being connected to. */
-+ Gaim2Account *account; /**< The account being connected to. */
- char *password; /**< The password used. */
- int inpa; /**< The input watcher. */
-
-@@ -110,7 +110,7 @@ extern "C" {
- /*@{*/
-
- /**
-- * This function should only be called by gaim_account_connect()
-+ * This function should only be called by gaim2_account_connect()
- * in account.c. If you're trying to sign on an account, use that
- * function instead.
- *
-@@ -118,27 +118,27 @@ extern "C" {
- * or attempts to register a new account. If you are logging in,
- * the connection uses the current active status for this account.
- * So if you want to sign on as "away," for example, you need to
-- * have called gaim_account_set_status(account, "away").
-- * (And this will call gaim_account_connect() automatically).
-+ * have called gaim2_account_set_status(account, "away").
-+ * (And this will call gaim2_account_connect() automatically).
- *
- * @param account The account the connection should be connecting to.
- * @param regist Whether we are registering a new account or just
- * trying to do a normal signon.
- * @param password The password to use.
- */
--void gaim_connection_new(GaimAccount *account, gboolean regist,
-+void gaim2_connection_new(Gaim2Account *account, gboolean regist,
- const char *password);
-
- /**
-- * This function should only be called by gaim_account_disconnect()
-+ * This function should only be called by gaim2_account_disconnect()
- * in account.c. If you're trying to sign on an account, use that
- * function instead.
- *
-- * Disconnects and destroys a GaimConnection.
-+ * Disconnects and destroys a Gaim2Connection.
- *
-- * @param gc The gaim connection to destroy.
-+ * @param gc The gaim2 connection to destroy.
- */
--void gaim_connection_destroy(GaimConnection *gc);
-+void gaim2_connection_destroy(Gaim2Connection *gc);
-
- /**
- * Sets the connection state. PRPLs should call this and pass in
-@@ -150,7 +150,7 @@ void gaim_connection_destroy(GaimConnect
- * @param gc The connection.
- * @param state The connection state.
- */
--void gaim_connection_set_state(GaimConnection *gc, GaimConnectionState state);
-+void gaim2_connection_set_state(Gaim2Connection *gc, Gaim2ConnectionState state);
-
- /**
- * Sets the connection's account.
-@@ -158,7 +158,7 @@ void gaim_connection_set_state(GaimConne
- * @param gc The connection.
- * @param account The account.
- */
--void gaim_connection_set_account(GaimConnection *gc, GaimAccount *account);
-+void gaim2_connection_set_account(Gaim2Connection *gc, Gaim2Account *account);
-
- /**
- * Sets the connection's displayed name.
-@@ -166,7 +166,7 @@ void gaim_connection_set_account(GaimCon
- * @param gc The connection.
- * @param name The displayed name.
- */
--void gaim_connection_set_display_name(GaimConnection *gc, const char *name);
-+void gaim2_connection_set_display_name(Gaim2Connection *gc, const char *name);
-
- /**
- * Returns the connection state.
-@@ -175,7 +175,7 @@ void gaim_connection_set_display_name(Ga
- *
- * @return The connection state.
- */
--GaimConnectionState gaim_connection_get_state(const GaimConnection *gc);
-+Gaim2ConnectionState gaim2_connection_get_state(const Gaim2Connection *gc);
-
- /**
- * Returns TRUE if the account is connected, otherwise returns FALSE.
-@@ -192,7 +192,7 @@ GaimConnectionState gaim_connection_get_
- *
- * @return The connection's account.
- */
--GaimAccount *gaim_connection_get_account(const GaimConnection *gc);
-+Gaim2Account *gaim2_connection_get_account(const Gaim2Connection *gc);
-
- /**
- * Returns the connection's password.
-@@ -201,7 +201,7 @@ GaimAccount *gaim_connection_get_account
- *
- * @return The connection's password.
- */
--const char *gaim_connection_get_password(const GaimConnection *gc);
-+const char *gaim2_connection_get_password(const Gaim2Connection *gc);
-
- /**
- * Returns the connection's displayed name.
-@@ -210,7 +210,7 @@ const char *gaim_connection_get_password
- *
- * @return The connection's displayed name.
- */
--const char *gaim_connection_get_display_name(const GaimConnection *gc);
-+const char *gaim2_connection_get_display_name(const Gaim2Connection *gc);
-
- /**
- * Updates the connection progress.
-@@ -220,7 +220,7 @@ const char *gaim_connection_get_display_
- * @param step The current step.
- * @param count The total number of steps.
- */
--void gaim_connection_update_progress(GaimConnection *gc, const char *text,
-+void gaim2_connection_update_progress(Gaim2Connection *gc, const char *text,
- size_t step, size_t count);
-
- /**
-@@ -229,7 +229,7 @@ void gaim_connection_update_progress(Gai
- * @param gc The connection.
- * @param text The notice text.
- */
--void gaim_connection_notice(GaimConnection *gc, const char *text);
-+void gaim2_connection_notice(Gaim2Connection *gc, const char *text);
-
- /**
- * Closes a connection with an error.
-@@ -237,7 +237,7 @@ void gaim_connection_notice(GaimConnecti
- * @param gc The connection.
- * @param reason The error text.
- */
--void gaim_connection_error(GaimConnection *gc, const char *reason);
-+void gaim2_connection_error(Gaim2Connection *gc, const char *reason);
-
- /*@}*/
-
-@@ -249,7 +249,7 @@ void gaim_connection_error(GaimConnectio
- /**
- * Disconnects from all connections.
- */
--void gaim_connections_disconnect_all(void);
-+void gaim2_connections_disconnect_all(void);
-
- /**
- * Returns a list of all active connections. This does not
-@@ -257,21 +257,21 @@ void gaim_connections_disconnect_all(voi
- *
- * @return A list of all active connections.
- */
--GList *gaim_connections_get_all(void);
-+GList *gaim2_connections_get_all(void);
-
- /**
- * Returns a list of all connections in the process of connecting.
- *
- * @return A list of connecting connections.
- */
--GList *gaim_connections_get_connecting(void);
-+GList *gaim2_connections_get_connecting(void);
-
- /**
- * Checks if gc is still a valid pointer to a gc.
- *
- * @return @c TRUE if gc is valid.
- */
--#define GAIM_CONNECTION_IS_VALID(gc) (g_list_find(gaim_connections_get_all(), (gc)) || g_list_find(gaim_connections_get_connecting(), (gc)))
-+#define GAIM_CONNECTION_IS_VALID(gc) (g_list_find(gaim2_connections_get_all(), (gc)) || g_list_find(gaim2_connections_get_connecting(), (gc)))
-
- /*@}*/
-
-@@ -285,14 +285,14 @@ GList *gaim_connections_get_connecting(v
- *
- * @param ops The UI operations structure.
- */
--void gaim_connections_set_ui_ops(GaimConnectionUiOps *ops);
-+void gaim2_connections_set_ui_ops(Gaim2ConnectionUiOps *ops);
-
- /**
- * Returns the UI operations structure used for connections.
- *
- * @return The UI operations structure in use.
- */
--GaimConnectionUiOps *gaim_connections_get_ui_ops(void);
-+Gaim2ConnectionUiOps *gaim2_connections_get_ui_ops(void);
-
- /*@}*/
-
-@@ -304,19 +304,19 @@ GaimConnectionUiOps *gaim_connections_ge
- /**
- * Initializes the connections subsystem.
- */
--void gaim_connections_init(void);
-+void gaim2_connections_init(void);
-
- /**
- * Uninitializes the connections subsystem.
- */
--void gaim_connections_uninit(void);
-+void gaim2_connections_uninit(void);
-
- /**
- * Returns the handle to the connections subsystem.
- *
- * @return The connections subsystem handle.
- */
--void *gaim_connections_get_handle(void);
-+void *gaim2_connections_get_handle(void);
-
- /*@}*/
-
-diff -prNu ./src/conversation.c ./src/conversation.c
---- ./src/conversation.c 2005-12-23 06:13:52.000000000 +0100
-+++ ./src/conversation.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -36,11 +36,11 @@
- static GList *conversations = NULL;
- static GList *ims = NULL;
- static GList *chats = NULL;
--static GaimConversationUiOps *default_ops = NULL;
-+static Gaim2ConversationUiOps *default_ops = NULL;
-
-
- void
--gaim_conversations_set_ui_ops(GaimConversationUiOps *ops)
-+gaim2_conversations_set_ui_ops(Gaim2ConversationUiOps *ops)
- {
- default_ops = ops;
- }
-@@ -48,17 +48,17 @@ gaim_conversations_set_ui_ops(GaimConver
- static gboolean
- reset_typing(gpointer data)
- {
-- GaimConversation *c = (GaimConversation *)data;
-- GaimConvIm *im;
-+ Gaim2Conversation *c = (Gaim2Conversation *)data;
-+ Gaim2ConvIm *im;
-
- if (!g_list_find(conversations, c))
- return FALSE;
-
- im = GAIM_CONV_IM(c);
-
-- gaim_conv_im_set_typing_state(im, GAIM_NOT_TYPING);
-- gaim_conv_im_update_typing(im);
-- gaim_conv_im_stop_typing_timeout(im);
-+ gaim2_conv_im_set_typing_state(im, GAIM_NOT_TYPING);
-+ gaim2_conv_im_update_typing(im);
-+ gaim2_conv_im_stop_typing_timeout(im);
-
- return FALSE;
- }
-@@ -66,31 +66,31 @@ reset_typing(gpointer data)
- static gboolean
- send_typed(gpointer data)
- {
-- GaimConversation *conv = (GaimConversation *)data;
-- GaimConnection *gc;
-+ Gaim2Conversation *conv = (Gaim2Conversation *)data;
-+ Gaim2Connection *gc;
- const char *name;
-
-- gc = gaim_conversation_get_gc(conv);
-- name = gaim_conversation_get_name(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-+ name = gaim2_conversation_get_name(conv);
-
- if (conv != NULL && gc != NULL && name != NULL) {
-- gaim_conv_im_set_type_again(GAIM_CONV_IM(conv), TRUE);
-+ gaim2_conv_im_set_type_again(GAIM_CONV_IM(conv), TRUE);
-
- serv_send_typing(gc, name, GAIM_TYPED);
-
-- gaim_debug(GAIM_DEBUG_MISC, "conversation", "typed...\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "conversation", "typed...\n");
- }
-
- return FALSE;
- }
-
- static void
--common_send(GaimConversation *conv, const char *message, GaimMessageFlags msgflags)
-+common_send(Gaim2Conversation *conv, const char *message, Gaim2MessageFlags msgflags)
- {
-- GaimConversationType type;
-- GaimAccount *account;
-- GaimConnection *gc;
-- GaimConversationUiOps *ops;
-+ Gaim2ConversationType type;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-+ Gaim2ConversationUiOps *ops;
- char *displayed = NULL, *sent = NULL;
- int plugin_return;
- int err = 0;
-@@ -98,26 +98,26 @@ common_send(GaimConversation *conv, cons
- if (strlen(message) == 0)
- return;
-
-- account = gaim_conversation_get_account(conv);
-- gc = gaim_conversation_get_gc(conv);
-+ account = gaim2_conversation_get_account(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(gc != NULL);
-
-- type = gaim_conversation_get_type(conv);
-- ops = gaim_conversation_get_ui_ops(conv);
-+ type = gaim2_conversation_get_type(conv);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
- if ((conv->features & GAIM_CONNECTION_HTML) &&
- !(msgflags & GAIM_MESSAGE_RAW))
- {
-- displayed = gaim_markup_linkify(message);
-+ displayed = gaim2_markup_linkify(message);
- }
- else
- displayed = g_strdup(message);
-
- plugin_return =
-- GPOINTER_TO_INT(gaim_signal_emit_return_1(
-- gaim_conversations_get_handle(),
-+ GPOINTER_TO_INT(gaim2_signal_emit_return_1(
-+ gaim2_conversations_get_handle(),
- (type == GAIM_CONV_TYPE_IM ? "writing-im-msg" : "writing-chat-msg"),
- account, conv, &displayed));
-
-@@ -129,7 +129,7 @@ common_send(GaimConversation *conv, cons
- return;
- }
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- (type == GAIM_CONV_TYPE_IM ? "wrote-im-msg" : "wrote-chat-msg"),
- account, conv, displayed);
-
-@@ -138,36 +138,36 @@ common_send(GaimConversation *conv, cons
- msgflags |= GAIM_MESSAGE_SEND;
-
- if (type == GAIM_CONV_TYPE_IM) {
-- GaimConvIm *im = GAIM_CONV_IM(conv);
-+ Gaim2ConvIm *im = GAIM_CONV_IM(conv);
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "sending-im-msg",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "sending-im-msg",
- account,
-- gaim_conversation_get_name(conv), &sent);
-+ gaim2_conversation_get_name(conv), &sent);
-
- if (sent != NULL && sent[0] != '\0') {
-
-- err = serv_send_im(gc, gaim_conversation_get_name(conv),
-+ err = serv_send_im(gc, gaim2_conversation_get_name(conv),
- sent, msgflags);
-
- if ((err > 0) && (displayed != NULL))
-- gaim_conv_im_write(im, NULL, displayed, msgflags, time(NULL));
-+ gaim2_conv_im_write(im, NULL, displayed, msgflags, time(NULL));
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "sent-im-msg",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "sent-im-msg",
- account,
-- gaim_conversation_get_name(conv), sent);
-+ gaim2_conversation_get_name(conv), sent);
- }
- }
- else {
-- gaim_signal_emit(gaim_conversations_get_handle(), "sending-chat-msg",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "sending-chat-msg",
- account, &sent,
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)));
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)));
-
- if (sent != NULL && sent[0] != '\0') {
-- err = serv_chat_send(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)), sent, msgflags);
-+ err = serv_chat_send(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)), sent, msgflags);
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "sent-chat-msg",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "sent-chat-msg",
- account, sent,
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)));
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)));
- }
- }
-
-@@ -175,27 +175,27 @@ common_send(GaimConversation *conv, cons
- const char *who;
- char *msg;
-
-- who = gaim_conversation_get_name(conv);
-+ who = gaim2_conversation_get_name(conv);
-
- if (err == -E2BIG) {
- msg = _("Unable to send message: The message is too large.");
-
-- if (!gaim_conv_present_error(who, account, msg)) {
-+ if (!gaim2_conv_present_error(who, account, msg)) {
- msg = g_strdup_printf(_("Unable to send message to %s."), who);
-- gaim_notify_error(gc, NULL, msg, _("The message is too large."));
-+ gaim2_notify_error(gc, NULL, msg, _("The message is too large."));
- g_free(msg);
- }
- }
- else if (err == -ENOTCONN) {
-- gaim_debug(GAIM_DEBUG_ERROR, "conversation",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "conversation",
- "Not yet connected.\n");
- }
- else {
- msg = _("Unable to send message.");
-
-- if (!gaim_conv_present_error(who, account, msg)) {
-+ if (!gaim2_conv_present_error(who, account, msg)) {
- msg = g_strdup_printf(_("Unable to send message to %s."), who);
-- gaim_notify_error(gc, NULL, msg, NULL);
-+ gaim2_notify_error(gc, NULL, msg, NULL);
- g_free(msg);
- }
- }
-@@ -206,9 +206,9 @@ common_send(GaimConversation *conv, cons
- }
-
- static void
--open_log(GaimConversation *conv)
-+open_log(Gaim2Conversation *conv)
- {
-- conv->logs = g_list_append(NULL, gaim_log_new(conv->type == GAIM_CONV_TYPE_CHAT ? GAIM_LOG_CHAT :
-+ conv->logs = g_list_append(NULL, gaim2_log_new(conv->type == GAIM_CONV_TYPE_CHAT ? GAIM_LOG_CHAT :
- GAIM_LOG_IM, conv->name, conv->account,
- conv, time(NULL)));
- }
-@@ -218,64 +218,64 @@ open_log(GaimConversation *conv)
- * Conversation API
- **************************************************************************/
- static void
--gaim_conversation_chat_cleanup_for_rejoin(GaimConversation *conv)
-+gaim2_conversation_chat_cleanup_for_rejoin(Gaim2Conversation *conv)
- {
- const char *disp;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
-
-- gaim_conversation_close_logs(conv);
-+ gaim2_conversation_close_logs(conv);
- open_log(conv);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
-- if ((disp = gaim_connection_get_display_name(gc)) != NULL)
-- gaim_conv_chat_set_nick(GAIM_CONV_CHAT(conv), disp);
-+ if ((disp = gaim2_connection_get_display_name(gc)) != NULL)
-+ gaim2_conv_chat_set_nick(GAIM_CONV_CHAT(conv), disp);
- else
- {
-- gaim_conv_chat_set_nick(GAIM_CONV_CHAT(conv),
-- gaim_account_get_username(account));
-+ gaim2_conv_chat_set_nick(GAIM_CONV_CHAT(conv),
-+ gaim2_account_get_username(account));
- }
-
-- gaim_conv_chat_clear_users(GAIM_CONV_CHAT(conv));
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(conv), NULL, NULL);
-+ gaim2_conv_chat_clear_users(GAIM_CONV_CHAT(conv));
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(conv), NULL, NULL);
- GAIM_CONV_CHAT(conv)->left = FALSE;
-
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_CHATLEFT);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_CHATLEFT);
- }
-
--GaimConversation *
--gaim_conversation_new(GaimConversationType type, GaimAccount *account,
-+Gaim2Conversation *
-+gaim2_conversation_new(Gaim2ConversationType type, Gaim2Account *account,
- const char *name)
- {
-- GaimConversation *conv;
-- GaimConnection *gc;
-- GaimConversationUiOps *ops;
-+ Gaim2Conversation *conv;
-+ Gaim2Connection *gc;
-+ Gaim2ConversationUiOps *ops;
-
- g_return_val_if_fail(type != GAIM_CONV_TYPE_UNKNOWN, NULL);
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
-
- /* Check if this conversation already exists. */
-- if ((conv = gaim_find_conversation_with_account(type, name, account)) != NULL)
-+ if ((conv = gaim2_find_conversation_with_account(type, name, account)) != NULL)
- {
-- if (gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_CHAT ||
-- gaim_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
-+ if (gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_CHAT ||
-+ gaim2_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
- {
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-- gaim_conversation_chat_cleanup_for_rejoin(conv);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conversation_chat_cleanup_for_rejoin(conv);
-
- return conv;
- }
- }
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- g_return_val_if_fail(gc != NULL, NULL);
-
-- conv = g_new0(GaimConversation, 1);
-- GAIM_DBUS_REGISTER_POINTER(conv, GaimConversation);
-+ conv = g_new0(Gaim2Conversation, 1);
-+ GAIM_DBUS_REGISTER_POINTER(conv, Gaim2Conversation);
-
- conv->type = type;
- conv->account = account;
-@@ -289,18 +289,18 @@ gaim_conversation_new(GaimConversationTy
-
- if (type == GAIM_CONV_TYPE_IM)
- {
-- GaimBuddyIcon *icon;
-- conv->u.im = g_new0(GaimConvIm, 1);
-+ Gaim2BuddyIcon *icon;
-+ conv->u.im = g_new0(Gaim2ConvIm, 1);
- conv->u.im->conv = conv;
-- GAIM_DBUS_REGISTER_POINTER(conv->u.im, GaimConvIm);
-+ GAIM_DBUS_REGISTER_POINTER(conv->u.im, Gaim2ConvIm);
-
- ims = g_list_append(ims, conv);
-- if ((icon = gaim_buddy_icons_find(account, name)))
-- gaim_conv_im_set_icon(conv->u.im, icon);
-+ if ((icon = gaim2_buddy_icons_find(account, name)))
-+ gaim2_conv_im_set_icon(conv->u.im, icon);
-
-- if (gaim_prefs_get_bool("/core/logging/log_ims"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_ims"))
- {
-- gaim_conversation_set_logging(conv, TRUE);
-+ gaim2_conversation_set_logging(conv, TRUE);
- open_log(conv);
- }
- }
-@@ -308,21 +308,21 @@ gaim_conversation_new(GaimConversationTy
- {
- const char *disp;
-
-- conv->u.chat = g_new0(GaimConvChat, 1);
-+ conv->u.chat = g_new0(Gaim2ConvChat, 1);
- conv->u.chat->conv = conv;
-- GAIM_DBUS_REGISTER_POINTER(conv->u.chat, GaimConvChat);
-+ GAIM_DBUS_REGISTER_POINTER(conv->u.chat, Gaim2ConvChat);
-
- chats = g_list_append(chats, conv);
-
-- if ((disp = gaim_connection_get_display_name(account->gc)))
-- gaim_conv_chat_set_nick(conv->u.chat, disp);
-+ if ((disp = gaim2_connection_get_display_name(account->gc)))
-+ gaim2_conv_chat_set_nick(conv->u.chat, disp);
- else
-- gaim_conv_chat_set_nick(conv->u.chat,
-- gaim_account_get_username(account));
-+ gaim2_conv_chat_set_nick(conv->u.chat,
-+ gaim2_account_get_username(account));
-
-- if (gaim_prefs_get_bool("/core/logging/log_chats"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_chats"))
- {
-- gaim_conversation_set_logging(conv, TRUE);
-+ gaim2_conversation_set_logging(conv, TRUE);
- open_log(conv);
- }
- }
-@@ -330,7 +330,7 @@ gaim_conversation_new(GaimConversationTy
- conversations = g_list_append(conversations, conv);
-
- /* Auto-set the title. */
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
-
- /* Don't move this.. it needs to be one of the last things done otherwise
- * it causes mysterious crashes on my system.
-@@ -340,47 +340,47 @@ gaim_conversation_new(GaimConversationTy
- if (ops != NULL && ops->create_conversation != NULL)
- ops->create_conversation(conv);
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "conversation-created", conv);
-
- return conv;
- }
-
- void
--gaim_conversation_destroy(GaimConversation *conv)
-+gaim2_conversation_destroy(Gaim2Conversation *conv)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConversationUiOps *ops;
-- GaimConnection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2ConversationUiOps *ops;
-+ Gaim2Connection *gc;
- const char *name;
- GList *node;
-
- g_return_if_fail(conv != NULL);
-
-- ops = gaim_conversation_get_ui_ops(conv);
-- gc = gaim_conversation_get_gc(conv);
-- name = gaim_conversation_get_name(conv);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-+ name = gaim2_conversation_get_name(conv);
-
- if (gc != NULL)
- {
- /* Still connected */
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- {
-- if (gaim_prefs_get_bool("/core/conversations/im/send_typing"))
-+ if (gaim2_prefs_get_bool("/core/conversations/im/send_typing"))
- serv_send_typing(gc, name, GAIM_NOT_TYPING);
-
- if (gc && prpl_info->convo_closed != NULL)
- prpl_info->convo_closed(gc, name);
- }
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- {
-- int chat_id = gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-+ int chat_id = gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv));
- #if 0
- /*
- * This is unfortunately necessary, because calling
-- * serv_chat_leave() calls this gaim_conversation_destroy(),
-+ * serv_chat_leave() calls this gaim2_conversation_destroy(),
- * which leads to two calls here.. We can't just return after
- * this, because then it'll return on the next pass. So, since
- * serv_got_chat_left(), which is eventually called from the
-@@ -408,14 +408,14 @@ gaim_conversation_destroy(GaimConversati
- * internals on it's own time. Don't do this if the prpl already
- * knows it left the chat.
- */
-- if (!gaim_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
-+ if (!gaim2_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
- serv_chat_leave(gc, chat_id);
-
- /*
- * If they didn't call serv_got_chat_left by now, it's too late.
- * So we better do it for them before we destroy the thing.
- */
-- if (!gaim_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
-+ if (!gaim2_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
- serv_got_chat_left(gc, chat_id);
- }
- }
-@@ -428,7 +428,7 @@ gaim_conversation_destroy(GaimConversati
- else if(conv->type==GAIM_CONV_TYPE_CHAT)
- chats = g_list_remove(chats, conv);
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "deleting-conversation", conv);
-
- g_free(conv->name);
-@@ -449,11 +449,11 @@ gaim_conversation_destroy(GaimConversati
- g_list_free(g_list_first(conv->send_history));
-
- if (conv->type == GAIM_CONV_TYPE_IM) {
-- gaim_conv_im_stop_typing_timeout(conv->u.im);
-- gaim_conv_im_stop_type_again_timeout(conv->u.im);
-+ gaim2_conv_im_stop_typing_timeout(conv->u.im);
-+ gaim2_conv_im_stop_type_again_timeout(conv->u.im);
-
- if (conv->u.im->icon != NULL)
-- gaim_buddy_icon_unref(conv->u.im->icon);
-+ gaim2_buddy_icon_unref(conv->u.im->icon);
- conv->u.im->icon = NULL;
-
- GAIM_DBUS_UNREGISTER_POINTER(conv->u.im);
-@@ -464,7 +464,7 @@ gaim_conversation_destroy(GaimConversati
-
- for (node = conv->u.chat->in_room; node != NULL; node = node->next) {
- if (node->data != NULL)
-- gaim_conv_chat_cb_destroy((GaimConvChatBuddy *)node->data);
-+ gaim2_conv_chat_cb_destroy((Gaim2ConvChatBuddy *)node->data);
- node->data = NULL;
- }
-
-@@ -502,7 +502,7 @@ gaim_conversation_destroy(GaimConversati
- if (ops != NULL && ops->destroy_conversation != NULL)
- ops->destroy_conversation(conv);
-
-- gaim_conversation_close_logs(conv);
-+ gaim2_conversation_close_logs(conv);
-
- GAIM_DBUS_UNREGISTER_POINTER(conv);
- g_free(conv);
-@@ -511,38 +511,38 @@ gaim_conversation_destroy(GaimConversati
-
-
- void
--gaim_conversation_present(GaimConversation *conv) {
-- GaimConversationUiOps *ops;
-+gaim2_conversation_present(Gaim2Conversation *conv) {
-+ Gaim2ConversationUiOps *ops;
-
- g_return_if_fail(conv != NULL);
-
-- ops = gaim_conversation_get_ui_ops(conv);
-+ ops = gaim2_conversation_get_ui_ops(conv);
- if(ops && ops->present)
- ops->present(conv);
- }
-
-
- void
--gaim_conversation_set_features(GaimConversation *conv, GaimConnectionFlags features)
-+gaim2_conversation_set_features(Gaim2Conversation *conv, Gaim2ConnectionFlags features)
- {
- g_return_if_fail(conv != NULL);
-
- conv->features = features;
-
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_FEATURES);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_FEATURES);
- }
-
-
--GaimConnectionFlags
--gaim_conversation_get_features(GaimConversation *conv)
-+Gaim2ConnectionFlags
-+gaim2_conversation_get_features(Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, 0);
- return conv->features;
- }
-
-
--GaimConversationType
--gaim_conversation_get_type(const GaimConversation *conv)
-+Gaim2ConversationType
-+gaim2_conversation_get_type(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, GAIM_CONV_TYPE_UNKNOWN);
-
-@@ -550,8 +550,8 @@ gaim_conversation_get_type(const GaimCon
- }
-
- void
--gaim_conversation_set_ui_ops(GaimConversation *conv,
-- GaimConversationUiOps *ops)
-+gaim2_conversation_set_ui_ops(Gaim2Conversation *conv,
-+ Gaim2ConversationUiOps *ops)
- {
- g_return_if_fail(conv != NULL);
-
-@@ -566,8 +566,8 @@ gaim_conversation_set_ui_ops(GaimConvers
- conv->ui_ops = ops;
- }
-
--GaimConversationUiOps *
--gaim_conversation_get_ui_ops(const GaimConversation *conv)
-+Gaim2ConversationUiOps *
-+gaim2_conversation_get_ui_ops(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
-@@ -575,34 +575,34 @@ gaim_conversation_get_ui_ops(const GaimC
- }
-
- void
--gaim_conversation_set_account(GaimConversation *conv, GaimAccount *account)
-+gaim2_conversation_set_account(Gaim2Conversation *conv, Gaim2Account *account)
- {
- g_return_if_fail(conv != NULL);
-
-- if (account == gaim_conversation_get_account(conv))
-+ if (account == gaim2_conversation_get_account(conv))
- return;
-
- conv->account = account;
-
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_ACCOUNT);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_ACCOUNT);
- }
-
--GaimAccount *
--gaim_conversation_get_account(const GaimConversation *conv)
-+Gaim2Account *
-+gaim2_conversation_get_account(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
- return conv->account;
- }
-
--GaimConnection *
--gaim_conversation_get_gc(const GaimConversation *conv)
-+Gaim2Connection *
-+gaim2_conversation_get_gc(const Gaim2Conversation *conv)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- g_return_val_if_fail(conv != NULL, NULL);
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
-
- if (account == NULL)
- return NULL;
-@@ -611,7 +611,7 @@ gaim_conversation_get_gc(const GaimConve
- }
-
- void
--gaim_conversation_set_title(GaimConversation *conv, const char *title)
-+gaim2_conversation_set_title(Gaim2Conversation *conv, const char *title)
- {
- g_return_if_fail(conv != NULL);
- g_return_if_fail(title != NULL);
-@@ -621,11 +621,11 @@ gaim_conversation_set_title(GaimConversa
-
- conv->title = g_strdup(title);
-
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_TITLE);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_TITLE);
- }
-
- const char *
--gaim_conversation_get_title(const GaimConversation *conv)
-+gaim2_conversation_get_title(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
-@@ -633,23 +633,23 @@ gaim_conversation_get_title(const GaimCo
- }
-
- void
--gaim_conversation_autoset_title(GaimConversation *conv)
-+gaim2_conversation_autoset_title(Gaim2Conversation *conv)
- {
-- GaimAccount *account;
-- GaimBuddy *b;
-- GaimChat *chat;
-+ Gaim2Account *account;
-+ Gaim2Buddy *b;
-+ Gaim2Chat *chat;
- const char *text = NULL, *name;
-
- g_return_if_fail(conv != NULL);
-
-- account = gaim_conversation_get_account(conv);
-- name = gaim_conversation_get_name(conv);
-+ account = gaim2_conversation_get_account(conv);
-+ name = gaim2_conversation_get_name(conv);
-
-- if(gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-- if(account && ((b = gaim_find_buddy(account, name)) != NULL))
-- text = gaim_buddy_get_contact_alias(b);
-- } else if(gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-- if(account && ((chat = gaim_blist_find_chat(account, name)) != NULL))
-+ if(gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ if(account && ((b = gaim2_find_buddy(account, name)) != NULL))
-+ text = gaim2_buddy_get_contact_alias(b);
-+ } else if(gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ if(account && ((chat = gaim2_blist_find_chat(account, name)) != NULL))
- text = chat->alias;
- }
-
-@@ -657,26 +657,26 @@ gaim_conversation_autoset_title(GaimConv
- if(text == NULL)
- text = name;
-
-- gaim_conversation_set_title(conv, text);
-+ gaim2_conversation_set_title(conv, text);
- }
-
- void
--gaim_conversation_foreach(void (*func)(GaimConversation *conv))
-+gaim2_conversation_foreach(void (*func)(Gaim2Conversation *conv))
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- GList *l;
-
- g_return_if_fail(func != NULL);
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next) {
-- conv = (GaimConversation *)l->data;
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next) {
-+ conv = (Gaim2Conversation *)l->data;
-
- func(conv);
- }
- }
-
- void
--gaim_conversation_set_name(GaimConversation *conv, const char *name)
-+gaim2_conversation_set_name(Gaim2Conversation *conv, const char *name)
- {
- g_return_if_fail(conv != NULL);
-
-@@ -685,11 +685,11 @@ gaim_conversation_set_name(GaimConversat
-
- conv->name = (name == NULL ? NULL : g_strdup(name));
-
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
- }
-
- const char *
--gaim_conversation_get_name(const GaimConversation *conv)
-+gaim2_conversation_get_name(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
-@@ -697,19 +697,19 @@ gaim_conversation_get_name(const GaimCon
- }
-
- void
--gaim_conversation_set_logging(GaimConversation *conv, gboolean log)
-+gaim2_conversation_set_logging(Gaim2Conversation *conv, gboolean log)
- {
- g_return_if_fail(conv != NULL);
-
- if (conv->logging != log)
- {
- conv->logging = log;
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_LOGGING);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_LOGGING);
- }
- }
-
- gboolean
--gaim_conversation_is_logging(const GaimConversation *conv)
-+gaim2_conversation_is_logging(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, FALSE);
-
-@@ -717,47 +717,47 @@ gaim_conversation_is_logging(const GaimC
- }
-
- void
--gaim_conversation_close_logs(GaimConversation *conv)
-+gaim2_conversation_close_logs(Gaim2Conversation *conv)
- {
- g_return_if_fail(conv != NULL);
-
-- g_list_foreach(conv->logs, (GFunc)gaim_log_free, NULL);
-+ g_list_foreach(conv->logs, (GFunc)gaim2_log_free, NULL);
- g_list_free(conv->logs);
- conv->logs = NULL;
- }
-
- GList *
--gaim_conversation_get_send_history(const GaimConversation *conv)
-+gaim2_conversation_get_send_history(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
- return conv->send_history;
- }
-
--GaimConvIm *
--gaim_conversation_get_im_data(const GaimConversation *conv)
-+Gaim2ConvIm *
-+gaim2_conversation_get_im_data(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
-- if (gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_IM)
- return NULL;
-
- return conv->u.im;
- }
-
--GaimConvChat *
--gaim_conversation_get_chat_data(const GaimConversation *conv)
-+Gaim2ConvChat *
-+gaim2_conversation_get_chat_data(const Gaim2Conversation *conv)
- {
- g_return_val_if_fail(conv != NULL, NULL);
-
-- if (gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_CHAT)
-+ if (gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_CHAT)
- return NULL;
-
- return conv->u.chat;
- }
-
- void
--gaim_conversation_set_data(GaimConversation *conv, const char *key,
-+gaim2_conversation_set_data(Gaim2Conversation *conv, const char *key,
- gpointer data)
- {
- g_return_if_fail(conv != NULL);
-@@ -767,7 +767,7 @@ gaim_conversation_set_data(GaimConversat
- }
-
- gpointer
--gaim_conversation_get_data(GaimConversation *conv, const char *key)
-+gaim2_conversation_get_data(Gaim2Conversation *conv, const char *key)
- {
- g_return_val_if_fail(conv != NULL, NULL);
- g_return_val_if_fail(key != NULL, NULL);
-@@ -776,45 +776,45 @@ gaim_conversation_get_data(GaimConversat
- }
-
- GList *
--gaim_get_conversations(void)
-+gaim2_get_conversations(void)
- {
- return conversations;
- }
-
- GList *
--gaim_get_ims(void)
-+gaim2_get_ims(void)
- {
- return ims;
- }
-
- GList *
--gaim_get_chats(void)
-+gaim2_get_chats(void)
- {
- return chats;
- }
-
-
--GaimConversation *
--gaim_find_conversation_with_account(GaimConversationType type,
-+Gaim2Conversation *
-+gaim2_find_conversation_with_account(Gaim2ConversationType type,
- const char *name,
-- const GaimAccount *account)
-+ const Gaim2Account *account)
- {
-- GaimConversation *c = NULL;
-+ Gaim2Conversation *c = NULL;
- gchar *name1;
- const gchar *name2;
- GList *cnv;
-
- g_return_val_if_fail(name != NULL, NULL);
-
-- name1 = g_strdup(gaim_normalize(account, name));
-+ name1 = g_strdup(gaim2_normalize(account, name));
-
-- for (cnv = gaim_get_conversations(); cnv != NULL; cnv = cnv->next) {
-- c = (GaimConversation *)cnv->data;
-- name2 = gaim_normalize(account, gaim_conversation_get_name(c));
--
-- if (((type == GAIM_CONV_TYPE_ANY) || (type == gaim_conversation_get_type(c))) &&
-- (account == gaim_conversation_get_account(c)) &&
-- !gaim_utf8_strcasecmp(name1, name2)) {
-+ for (cnv = gaim2_get_conversations(); cnv != NULL; cnv = cnv->next) {
-+ c = (Gaim2Conversation *)cnv->data;
-+ name2 = gaim2_normalize(account, gaim2_conversation_get_name(c));
-+
-+ if (((type == GAIM_CONV_TYPE_ANY) || (type == gaim2_conversation_get_type(c))) &&
-+ (account == gaim2_conversation_get_account(c)) &&
-+ !gaim2_utf8_strcasecmp(name1, name2)) {
-
- break;
- }
-@@ -828,74 +828,74 @@ gaim_find_conversation_with_account(Gaim
- }
-
- void
--gaim_conversation_write(GaimConversation *conv, const char *who,
-- const char *message, GaimMessageFlags flags,
-+gaim2_conversation_write(Gaim2Conversation *conv, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc = NULL;
-- GaimAccount *account;
-- GaimConversationUiOps *ops;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = NULL;
-+ Gaim2Account *account;
-+ Gaim2ConversationUiOps *ops;
- const char *alias;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- /* int logging_font_options = 0; */
-
- g_return_if_fail(conv != NULL);
- g_return_if_fail(message != NULL);
-
-- ops = gaim_conversation_get_ui_ops(conv);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
- if (ops == NULL || ops->write_conv == NULL)
- return;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
-
- if (account != NULL)
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT &&
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT &&
- (gc == NULL || !g_slist_find(gc->buddy_chats, conv)))
- return;
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM &&
-- !g_list_find(gaim_get_conversations(), conv))
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM &&
-+ !g_list_find(gaim2_get_conversations(), conv))
- return;
-
- if (who == NULL || *who == '\0')
-- who = gaim_conversation_get_name(conv);
-+ who = gaim2_conversation_get_name(conv);
-
- alias = who;
-
- if (account != NULL) {
-- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gaim_find_prpl(gaim_account_get_protocol_id(account)));
-+ prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gaim2_find_prpl(gaim2_account_get_protocol_id(account)));
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM ||
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM ||
- !(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) {
-
- if (flags & GAIM_MESSAGE_SEND) {
-- b = gaim_find_buddy(account,
-- gaim_account_get_username(account));
-+ b = gaim2_find_buddy(account,
-+ gaim2_account_get_username(account));
-
-- if (gaim_account_get_alias(account) != NULL)
-+ if (gaim2_account_get_alias(account) != NULL)
- alias = account->alias;
-- else if (b != NULL && strcmp(b->name, gaim_buddy_get_contact_alias(b)))
-- alias = gaim_buddy_get_contact_alias(b);
-- else if (gaim_connection_get_display_name(gc) != NULL)
-- alias = gaim_connection_get_display_name(gc);
-+ else if (b != NULL && strcmp(b->name, gaim2_buddy_get_contact_alias(b)))
-+ alias = gaim2_buddy_get_contact_alias(b);
-+ else if (gaim2_connection_get_display_name(gc) != NULL)
-+ alias = gaim2_connection_get_display_name(gc);
- else
-- alias = gaim_account_get_username(account);
-+ alias = gaim2_account_get_username(account);
- }
- else
- {
-- b = gaim_find_buddy(account, who);
-+ b = gaim2_find_buddy(account, who);
-
- if (b != NULL)
-- alias = gaim_buddy_get_contact_alias(b);
-+ alias = gaim2_buddy_get_contact_alias(b);
- }
- }
- }
-
-- if (!(flags & GAIM_MESSAGE_NO_LOG) && gaim_conversation_is_logging(conv)) {
-+ if (!(flags & GAIM_MESSAGE_NO_LOG) && gaim2_conversation_is_logging(conv)) {
- GList *log;
-
- if (conv->logs == NULL)
-@@ -903,30 +903,30 @@ gaim_conversation_write(GaimConversation
-
- log = conv->logs;
- while (log != NULL) {
-- gaim_log_write((GaimLog *)log->data, flags, alias, mtime, message);
-+ gaim2_log_write((Gaim2Log *)log->data, flags, alias, mtime, message);
- log = log->next;
- }
- }
- ops->write_conv(conv, who, alias, message, flags, mtime);
-
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
- if ((flags & GAIM_MESSAGE_RECV) == GAIM_MESSAGE_RECV) {
-- gaim_conv_im_set_typing_state(GAIM_CONV_IM(conv), GAIM_NOT_TYPING);
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_TITLE);
-+ gaim2_conv_im_set_typing_state(GAIM_CONV_IM(conv), GAIM_NOT_TYPING);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_TITLE);
- }
- }
- }
-
- gboolean
--gaim_conversation_has_focus(GaimConversation *conv)
-+gaim2_conversation_has_focus(Gaim2Conversation *conv)
- {
- gboolean ret = FALSE;
-- GaimConversationUiOps *ops;
-+ Gaim2ConversationUiOps *ops;
-
- g_return_val_if_fail(conv != NULL, FALSE);
-
-- ops = gaim_conversation_get_ui_ops(conv);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
- if (ops != NULL && ops->has_focus != NULL)
- ret = ops->has_focus(conv);
-@@ -941,26 +941,26 @@ gaim_conversation_has_focus(GaimConversa
- * when chats are added/removed from the blist.
- */
- void
--gaim_conversation_update(GaimConversation *conv, GaimConvUpdateType type)
-+gaim2_conversation_update(Gaim2Conversation *conv, Gaim2ConvUpdateType type)
- {
-- GaimConversationUiOps *ops;
-+ Gaim2ConversationUiOps *ops;
-
- g_return_if_fail(conv != NULL);
-
-- ops = gaim_conversation_get_ui_ops(conv);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
- if (ops != NULL && ops->updated != NULL)
- ops->updated(conv, type);
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "conversation-updated", conv, type);
- }
-
- /**************************************************************************
- * IM Conversation API
- **************************************************************************/
--GaimConversation *
--gaim_conv_im_get_conversation(const GaimConvIm *im)
-+Gaim2Conversation *
-+gaim2_conv_im_get_conversation(const Gaim2ConvIm *im)
- {
- g_return_val_if_fail(im != NULL, NULL);
-
-@@ -968,24 +968,24 @@ gaim_conv_im_get_conversation(const Gaim
- }
-
- void
--gaim_conv_im_set_icon(GaimConvIm *im, GaimBuddyIcon *icon)
-+gaim2_conv_im_set_icon(Gaim2ConvIm *im, Gaim2BuddyIcon *icon)
- {
- g_return_if_fail(im != NULL);
-
- if (im->icon != icon)
- {
- if (im->icon != NULL)
-- gaim_buddy_icon_unref(im->icon);
-+ gaim2_buddy_icon_unref(im->icon);
-
-- im->icon = (icon == NULL ? NULL : gaim_buddy_icon_ref(icon));
-+ im->icon = (icon == NULL ? NULL : gaim2_buddy_icon_ref(icon));
- }
-
-- gaim_conversation_update(gaim_conv_im_get_conversation(im),
-+ gaim2_conversation_update(gaim2_conv_im_get_conversation(im),
- GAIM_CONV_UPDATE_ICON);
- }
-
--GaimBuddyIcon *
--gaim_conv_im_get_icon(const GaimConvIm *im)
-+Gaim2BuddyIcon *
-+gaim2_conv_im_get_icon(const Gaim2ConvIm *im)
- {
- g_return_val_if_fail(im != NULL, NULL);
-
-@@ -993,15 +993,15 @@ gaim_conv_im_get_icon(const GaimConvIm *
- }
-
- void
--gaim_conv_im_set_typing_state(GaimConvIm *im, GaimTypingState state)
-+gaim2_conv_im_set_typing_state(Gaim2ConvIm *im, Gaim2TypingState state)
- {
- g_return_if_fail(im != NULL);
-
- im->typing_state = state;
- }
-
--GaimTypingState
--gaim_conv_im_get_typing_state(const GaimConvIm *im)
-+Gaim2TypingState
-+gaim2_conv_im_get_typing_state(const Gaim2ConvIm *im)
- {
- g_return_val_if_fail(im != NULL, 0);
-
-@@ -1009,36 +1009,36 @@ gaim_conv_im_get_typing_state(const Gaim
- }
-
- void
--gaim_conv_im_start_typing_timeout(GaimConvIm *im, int timeout)
-+gaim2_conv_im_start_typing_timeout(Gaim2ConvIm *im, int timeout)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- const char *name;
-
- g_return_if_fail(im != NULL);
-
- if (im->typing_timeout > 0)
-- gaim_conv_im_stop_typing_timeout(im);
-+ gaim2_conv_im_stop_typing_timeout(im);
-
-- conv = gaim_conv_im_get_conversation(im);
-- name = gaim_conversation_get_name(conv);
-+ conv = gaim2_conv_im_get_conversation(im);
-+ name = gaim2_conversation_get_name(conv);
-
-- im->typing_timeout = gaim_timeout_add(timeout * 1000, reset_typing, conv);
-+ im->typing_timeout = gaim2_timeout_add(timeout * 1000, reset_typing, conv);
- }
-
- void
--gaim_conv_im_stop_typing_timeout(GaimConvIm *im)
-+gaim2_conv_im_stop_typing_timeout(Gaim2ConvIm *im)
- {
- g_return_if_fail(im != NULL);
-
- if (im->typing_timeout == 0)
- return;
-
-- gaim_timeout_remove(im->typing_timeout);
-+ gaim2_timeout_remove(im->typing_timeout);
- im->typing_timeout = 0;
- }
-
- guint
--gaim_conv_im_get_typing_timeout(const GaimConvIm *im)
-+gaim2_conv_im_get_typing_timeout(const Gaim2ConvIm *im)
- {
- g_return_val_if_fail(im != NULL, 0);
-
-@@ -1046,7 +1046,7 @@ gaim_conv_im_get_typing_timeout(const Ga
- }
-
- void
--gaim_conv_im_set_type_again(GaimConvIm *im, time_t val)
-+gaim2_conv_im_set_type_again(Gaim2ConvIm *im, time_t val)
- {
- g_return_if_fail(im != NULL);
-
-@@ -1054,7 +1054,7 @@ gaim_conv_im_set_type_again(GaimConvIm *
- }
-
- time_t
--gaim_conv_im_get_type_again(const GaimConvIm *im)
-+gaim2_conv_im_get_type_again(const Gaim2ConvIm *im)
- {
- g_return_val_if_fail(im != NULL, 0);
-
-@@ -1062,28 +1062,28 @@ gaim_conv_im_get_type_again(const GaimCo
- }
-
- void
--gaim_conv_im_start_type_again_timeout(GaimConvIm *im)
-+gaim2_conv_im_start_type_again_timeout(Gaim2ConvIm *im)
- {
- g_return_if_fail(im != NULL);
-
-- im->type_again_timeout = gaim_timeout_add(SEND_TYPED_TIMEOUT, send_typed,
-- gaim_conv_im_get_conversation(im));
-+ im->type_again_timeout = gaim2_timeout_add(SEND_TYPED_TIMEOUT, send_typed,
-+ gaim2_conv_im_get_conversation(im));
- }
-
- void
--gaim_conv_im_stop_type_again_timeout(GaimConvIm *im)
-+gaim2_conv_im_stop_type_again_timeout(Gaim2ConvIm *im)
- {
- g_return_if_fail(im != NULL);
-
- if (im->type_again_timeout == 0)
- return;
-
-- gaim_timeout_remove(im->type_again_timeout);
-+ gaim2_timeout_remove(im->type_again_timeout);
- im->type_again_timeout = 0;
- }
-
- guint
--gaim_conv_im_get_type_again_timeout(const GaimConvIm *im)
-+gaim2_conv_im_get_type_again_timeout(const Gaim2ConvIm *im)
- {
- g_return_val_if_fail(im != NULL, 0);
-
-@@ -1091,43 +1091,43 @@ gaim_conv_im_get_type_again_timeout(cons
- }
-
- void
--gaim_conv_im_update_typing(GaimConvIm *im)
-+gaim2_conv_im_update_typing(Gaim2ConvIm *im)
- {
- g_return_if_fail(im != NULL);
-
-- gaim_conversation_update(gaim_conv_im_get_conversation(im),
-+ gaim2_conversation_update(gaim2_conv_im_get_conversation(im),
- GAIM_CONV_UPDATE_TYPING);
- }
-
- void
--gaim_conv_im_write(GaimConvIm *im, const char *who, const char *message,
-- GaimMessageFlags flags, time_t mtime)
-+gaim2_conv_im_write(Gaim2ConvIm *im, const char *who, const char *message,
-+ Gaim2MessageFlags flags, time_t mtime)
- {
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- g_return_if_fail(im != NULL);
- g_return_if_fail(message != NULL);
-
-- c = gaim_conv_im_get_conversation(im);
-+ c = gaim2_conv_im_get_conversation(im);
-
- /* Raise the window, if specified in prefs. */
- if (c->ui_ops != NULL && c->ui_ops->write_im != NULL)
- c->ui_ops->write_im(c, who, message, flags, mtime);
- else
-- gaim_conversation_write(c, who, message, flags, mtime);
-+ gaim2_conversation_write(c, who, message, flags, mtime);
- }
-
--gboolean gaim_conv_present_error(const char *who, GaimAccount *account, const char *what)
-+gboolean gaim2_conv_present_error(const char *who, Gaim2Account *account, const char *what)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- g_return_val_if_fail(who != NULL, FALSE);
- g_return_val_if_fail(account !=NULL, FALSE);
- g_return_val_if_fail(what != NULL, FALSE);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, who, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, who, account);
- if (conv != NULL)
-- gaim_conversation_write(conv, NULL, what, GAIM_MESSAGE_ERROR, time(NULL));
-+ gaim2_conversation_write(conv, NULL, what, GAIM_MESSAGE_ERROR, time(NULL));
- else
- return FALSE;
-
-@@ -1135,22 +1135,22 @@ gboolean gaim_conv_present_error(const c
- }
-
- void
--gaim_conv_im_send(GaimConvIm *im, const char *message)
-+gaim2_conv_im_send(Gaim2ConvIm *im, const char *message)
- {
-- gaim_conv_im_send_with_flags(im, message, 0);
-+ gaim2_conv_im_send_with_flags(im, message, 0);
- }
-
- void
--gaim_conv_im_send_with_flags(GaimConvIm *im, const char *message, GaimMessageFlags flags)
-+gaim2_conv_im_send_with_flags(Gaim2ConvIm *im, const char *message, Gaim2MessageFlags flags)
- {
- g_return_if_fail(im != NULL);
- g_return_if_fail(message != NULL);
-
-- common_send(gaim_conv_im_get_conversation(im), message, flags);
-+ common_send(gaim2_conv_im_get_conversation(im), message, flags);
- }
-
- gboolean
--gaim_conv_custom_smiley_add(GaimConversation *conv, const char *smile,
-+gaim2_conv_custom_smiley_add(Gaim2Conversation *conv, const char *smile,
- const char *cksum_type, const char *chksum,
- gboolean remote)
- {
-@@ -1163,14 +1163,14 @@ gaim_conv_custom_smiley_add(GaimConversa
- if (conv->ui_ops != NULL && conv->ui_ops->custom_smiley_add !=NULL) {
- return conv->ui_ops->custom_smiley_add(conv, smile, remote);
- } else {
-- gaim_debug_info("conversation", "Could not find add custom smiley function");
-+ gaim2_debug_info("conversation", "Could not find add custom smiley function");
- return FALSE;
- }
-
- }
-
- void
--gaim_conv_custom_smiley_write(GaimConversation *conv, const char *smile,
-+gaim2_conv_custom_smiley_write(Gaim2Conversation *conv, const char *smile,
- const guchar *data, gsize size)
- {
- g_return_if_fail(conv != NULL);
-@@ -1179,11 +1179,11 @@ gaim_conv_custom_smiley_write(GaimConver
- if (conv->ui_ops != NULL && conv->ui_ops->custom_smiley_write != NULL)
- conv->ui_ops->custom_smiley_write(conv, smile, data, size);
- else
-- gaim_debug_info("conversation", "Could not find the smiley write function");
-+ gaim2_debug_info("conversation", "Could not find the smiley write function");
- }
-
- void
--gaim_conv_custom_smiley_close(GaimConversation *conv, const char *smile)
-+gaim2_conv_custom_smiley_close(Gaim2Conversation *conv, const char *smile)
- {
- g_return_if_fail(conv != NULL);
- g_return_if_fail(smile != NULL && *smile);
-@@ -1191,7 +1191,7 @@ gaim_conv_custom_smiley_close(GaimConver
- if (conv->ui_ops != NULL && conv->ui_ops->custom_smiley_close != NULL)
- conv->ui_ops->custom_smiley_close(conv, smile);
- else
-- gaim_debug_info("conversation", "Could not find custom smiley close function");
-+ gaim2_debug_info("conversation", "Could not find custom smiley close function");
- }
-
-
-@@ -1199,8 +1199,8 @@ gaim_conv_custom_smiley_close(GaimConver
- * Chat Conversation API
- **************************************************************************/
-
--GaimConversation *
--gaim_conv_chat_get_conversation(const GaimConvChat *chat)
-+Gaim2Conversation *
-+gaim2_conv_chat_get_conversation(const Gaim2ConvChat *chat)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-@@ -1208,7 +1208,7 @@ gaim_conv_chat_get_conversation(const Ga
- }
-
- GList *
--gaim_conv_chat_set_users(GaimConvChat *chat, GList *users)
-+gaim2_conv_chat_set_users(Gaim2ConvChat *chat, GList *users)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-@@ -1218,7 +1218,7 @@ gaim_conv_chat_set_users(GaimConvChat *c
- }
-
- GList *
--gaim_conv_chat_get_users(const GaimConvChat *chat)
-+gaim2_conv_chat_get_users(const Gaim2ConvChat *chat)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-@@ -1226,21 +1226,21 @@ gaim_conv_chat_get_users(const GaimConvC
- }
-
- void
--gaim_conv_chat_ignore(GaimConvChat *chat, const char *name)
-+gaim2_conv_chat_ignore(Gaim2ConvChat *chat, const char *name)
- {
- g_return_if_fail(chat != NULL);
- g_return_if_fail(name != NULL);
-
- /* Make sure the user isn't already ignored. */
-- if (gaim_conv_chat_is_user_ignored(chat, name))
-+ if (gaim2_conv_chat_is_user_ignored(chat, name))
- return;
-
-- gaim_conv_chat_set_ignored(chat,
-- g_list_append(gaim_conv_chat_get_ignored(chat), g_strdup(name)));
-+ gaim2_conv_chat_set_ignored(chat,
-+ g_list_append(gaim2_conv_chat_get_ignored(chat), g_strdup(name)));
- }
-
- void
--gaim_conv_chat_unignore(GaimConvChat *chat, const char *name)
-+gaim2_conv_chat_unignore(Gaim2ConvChat *chat, const char *name)
- {
- GList *item;
-
-@@ -1248,21 +1248,21 @@ gaim_conv_chat_unignore(GaimConvChat *ch
- g_return_if_fail(name != NULL);
-
- /* Make sure the user is actually ignored. */
-- if (!gaim_conv_chat_is_user_ignored(chat, name))
-+ if (!gaim2_conv_chat_is_user_ignored(chat, name))
- return;
-
-- item = g_list_find(gaim_conv_chat_get_ignored(chat),
-- gaim_conv_chat_get_ignored_user(chat, name));
-+ item = g_list_find(gaim2_conv_chat_get_ignored(chat),
-+ gaim2_conv_chat_get_ignored_user(chat, name));
-
-- gaim_conv_chat_set_ignored(chat,
-- g_list_remove_link(gaim_conv_chat_get_ignored(chat), item));
-+ gaim2_conv_chat_set_ignored(chat,
-+ g_list_remove_link(gaim2_conv_chat_get_ignored(chat), item));
-
- g_free(item->data);
- g_list_free_1(item);
- }
-
- GList *
--gaim_conv_chat_set_ignored(GaimConvChat *chat, GList *ignored)
-+gaim2_conv_chat_set_ignored(Gaim2ConvChat *chat, GList *ignored)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-@@ -1272,7 +1272,7 @@ gaim_conv_chat_set_ignored(GaimConvChat
- }
-
- GList *
--gaim_conv_chat_get_ignored(const GaimConvChat *chat)
-+gaim2_conv_chat_get_ignored(const Gaim2ConvChat *chat)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-@@ -1280,28 +1280,28 @@ gaim_conv_chat_get_ignored(const GaimCon
- }
-
- const char *
--gaim_conv_chat_get_ignored_user(const GaimConvChat *chat, const char *user)
-+gaim2_conv_chat_get_ignored_user(const Gaim2ConvChat *chat, const char *user)
- {
- GList *ignored;
-
- g_return_val_if_fail(chat != NULL, NULL);
- g_return_val_if_fail(user != NULL, NULL);
-
-- for (ignored = gaim_conv_chat_get_ignored(chat);
-+ for (ignored = gaim2_conv_chat_get_ignored(chat);
- ignored != NULL;
- ignored = ignored->next) {
-
- const char *ign = (const char *)ignored->data;
-
-- if (!gaim_utf8_strcasecmp(user, ign) ||
-- ((*ign == '+' || *ign == '%') && !gaim_utf8_strcasecmp(user, ign + 1)))
-+ if (!gaim2_utf8_strcasecmp(user, ign) ||
-+ ((*ign == '+' || *ign == '%') && !gaim2_utf8_strcasecmp(user, ign + 1)))
- return ign;
-
- if (*ign == '@') {
- ign++;
-
-- if ((*ign == '+' && !gaim_utf8_strcasecmp(user, ign + 1)) ||
-- (*ign != '+' && !gaim_utf8_strcasecmp(user, ign)))
-+ if ((*ign == '+' && !gaim2_utf8_strcasecmp(user, ign + 1)) ||
-+ (*ign != '+' && !gaim2_utf8_strcasecmp(user, ign)))
- return ign;
- }
- }
-@@ -1310,16 +1310,16 @@ gaim_conv_chat_get_ignored_user(const Ga
- }
-
- gboolean
--gaim_conv_chat_is_user_ignored(const GaimConvChat *chat, const char *user)
-+gaim2_conv_chat_is_user_ignored(const Gaim2ConvChat *chat, const char *user)
- {
- g_return_val_if_fail(chat != NULL, FALSE);
- g_return_val_if_fail(user != NULL, FALSE);
-
-- return (gaim_conv_chat_get_ignored_user(chat, user) != NULL);
-+ return (gaim2_conv_chat_get_ignored_user(chat, user) != NULL);
- }
-
- void
--gaim_conv_chat_set_topic(GaimConvChat *chat, const char *who, const char *topic)
-+gaim2_conv_chat_set_topic(Gaim2ConvChat *chat, const char *who, const char *topic)
- {
- g_return_if_fail(chat != NULL);
-
-@@ -1329,15 +1329,15 @@ gaim_conv_chat_set_topic(GaimConvChat *c
- chat->who = (who == NULL ? NULL : g_strdup(who));
- chat->topic = (topic == NULL ? NULL : g_strdup(topic));
-
-- gaim_conversation_update(gaim_conv_chat_get_conversation(chat),
-+ gaim2_conversation_update(gaim2_conv_chat_get_conversation(chat),
- GAIM_CONV_UPDATE_TOPIC);
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-topic-changed",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-topic-changed",
- chat->conv, chat->who, chat->topic);
- }
-
- const char *
--gaim_conv_chat_get_topic(const GaimConvChat *chat)
-+gaim2_conv_chat_get_topic(const Gaim2ConvChat *chat)
- {
- g_return_val_if_fail(chat != NULL, NULL);
-
-@@ -1345,7 +1345,7 @@ gaim_conv_chat_get_topic(const GaimConvC
- }
-
- void
--gaim_conv_chat_set_id(GaimConvChat *chat, int id)
-+gaim2_conv_chat_set_id(Gaim2ConvChat *chat, int id)
- {
- g_return_if_fail(chat != NULL);
-
-@@ -1353,7 +1353,7 @@ gaim_conv_chat_set_id(GaimConvChat *chat
- }
-
- int
--gaim_conv_chat_get_id(const GaimConvChat *chat)
-+gaim2_conv_chat_get_id(const Gaim2ConvChat *chat)
- {
- g_return_val_if_fail(chat != NULL, -1);
-
-@@ -1361,38 +1361,38 @@ gaim_conv_chat_get_id(const GaimConvChat
- }
-
- void
--gaim_conv_chat_write(GaimConvChat *chat, const char *who, const char *message,
-- GaimMessageFlags flags, time_t mtime)
-+gaim2_conv_chat_write(Gaim2ConvChat *chat, const char *who, const char *message,
-+ Gaim2MessageFlags flags, time_t mtime)
- {
-- GaimAccount *account;
-- GaimConversation *conv;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Account *account;
-+ Gaim2Conversation *conv;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- g_return_if_fail(chat != NULL);
- g_return_if_fail(who != NULL);
- g_return_if_fail(message != NULL);
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- gc = gaim_conversation_get_gc(conv);
-- account = gaim_connection_get_account(gc);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ gc = gaim2_conversation_get_gc(conv);
-+ account = gaim2_connection_get_account(gc);
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
- /* Don't display this if the person who wrote it is ignored. */
-- if (gaim_conv_chat_is_user_ignored(chat, who))
-+ if (gaim2_conv_chat_is_user_ignored(chat, who))
- return;
-
- if (!(flags & GAIM_MESSAGE_WHISPER)) {
- char *str;
-
-- str = g_strdup(gaim_normalize(account, who));
-+ str = g_strdup(gaim2_normalize(account, who));
-
-- if (!strcmp(str, gaim_normalize(account, chat->nick))) {
-+ if (!strcmp(str, gaim2_normalize(account, chat->nick))) {
- flags |= GAIM_MESSAGE_SEND;
- } else {
- flags |= GAIM_MESSAGE_RECV;
-
-- if (gaim_utf8_has_word(message, chat->nick))
-+ if (gaim2_utf8_has_word(message, chat->nick))
- flags |= GAIM_MESSAGE_NICK;
- }
-
-@@ -1403,34 +1403,34 @@ gaim_conv_chat_write(GaimConvChat *chat,
- if (conv->ui_ops != NULL && conv->ui_ops->write_chat != NULL)
- conv->ui_ops->write_chat(conv, who, message, flags, mtime);
- else
-- gaim_conversation_write(conv, who, message, flags, mtime);
-+ gaim2_conversation_write(conv, who, message, flags, mtime);
- }
-
- void
--gaim_conv_chat_send(GaimConvChat *chat, const char *message)
-+gaim2_conv_chat_send(Gaim2ConvChat *chat, const char *message)
- {
-- gaim_conv_chat_send_with_flags(chat, message, 0);
-+ gaim2_conv_chat_send_with_flags(chat, message, 0);
- }
-
- void
--gaim_conv_chat_send_with_flags(GaimConvChat *chat, const char *message, GaimMessageFlags flags)
-+gaim2_conv_chat_send_with_flags(Gaim2ConvChat *chat, const char *message, Gaim2MessageFlags flags)
- {
- g_return_if_fail(chat != NULL);
- g_return_if_fail(message != NULL);
-
-- common_send(gaim_conv_chat_get_conversation(chat), message, flags);
-+ common_send(gaim2_conv_chat_get_conversation(chat), message, flags);
- }
-
- void
--gaim_conv_chat_add_user(GaimConvChat *chat, const char *user,
-- const char *extra_msg, GaimConvChatBuddyFlags flags,
-+gaim2_conv_chat_add_user(Gaim2ConvChat *chat, const char *user,
-+ const char *extra_msg, Gaim2ConvChatBuddyFlags flags,
- gboolean new_arrival)
- {
- GList *users = g_list_append(NULL, (char *)user);
- GList *extra_msgs = g_list_append(NULL, (char *)extra_msg);
- GList *flags2 = g_list_append(NULL, GINT_TO_POINTER(flags));
-
-- gaim_conv_chat_add_users(chat, users, extra_msgs, flags2, new_arrival);
-+ gaim2_conv_chat_add_users(chat, users, extra_msgs, flags2, new_arrival);
-
- g_list_free(users);
- g_list_free(extra_msgs);
-@@ -1438,24 +1438,24 @@ gaim_conv_chat_add_user(GaimConvChat *ch
- }
-
- void
--gaim_conv_chat_add_users(GaimConvChat *chat, GList *users, GList *extra_msgs,
-+gaim2_conv_chat_add_users(Gaim2ConvChat *chat, GList *users, GList *extra_msgs,
- GList *flags, gboolean new_arrivals)
- {
-- GaimConversation *conv;
-- GaimConversationUiOps *ops;
-- GaimConvChatBuddy *cb;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Conversation *conv;
-+ Gaim2ConversationUiOps *ops;
-+ Gaim2ConvChatBuddy *cb;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
- GList *ul, *fl;
- GList *aliases = NULL;
-
- g_return_if_fail(chat != NULL);
- g_return_if_fail(users != NULL);
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- ops = gaim_conversation_get_ui_ops(conv);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
- if (!gc || !(prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)))
- return;
-
-@@ -1465,32 +1465,32 @@ gaim_conv_chat_add_users(GaimConvChat *c
- const char *user = (const char *)ul->data;
- const char *alias = user;
- gboolean quiet;
-- GaimConvChatBuddyFlags flags = GPOINTER_TO_INT(fl->data);
-+ Gaim2ConvChatBuddyFlags flags = GPOINTER_TO_INT(fl->data);
- const char *extra_msg = (extra_msgs ? extra_msgs->data : NULL);
-
-- if (!strcmp(chat->nick, gaim_normalize(conv->account, user))) {
-- const char *alias2 = gaim_account_get_alias(conv->account);
-+ if (!strcmp(chat->nick, gaim2_normalize(conv->account, user))) {
-+ const char *alias2 = gaim2_account_get_alias(conv->account);
- if (alias2 != NULL)
- alias = alias2;
- else
- {
-- const char *display_name = gaim_connection_get_display_name(gc);
-+ const char *display_name = gaim2_connection_get_display_name(gc);
- if (display_name != NULL)
- alias = display_name;
- }
- } else if (!(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) {
-- GaimBuddy *buddy;
-- if ((buddy = gaim_find_buddy(gc->account, user)) != NULL)
-- alias = gaim_buddy_get_contact_alias(buddy);
-+ Gaim2Buddy *buddy;
-+ if ((buddy = gaim2_find_buddy(gc->account, user)) != NULL)
-+ alias = gaim2_buddy_get_contact_alias(buddy);
- }
-
-- quiet = GPOINTER_TO_INT(gaim_signal_emit_return_1(gaim_conversations_get_handle(),
-+ quiet = GPOINTER_TO_INT(gaim2_signal_emit_return_1(gaim2_conversations_get_handle(),
- "chat-buddy-joining", conv, user, flags)) |
-- gaim_conv_chat_is_user_ignored(chat, user);
-+ gaim2_conv_chat_is_user_ignored(chat, user);
-
-- cb = gaim_conv_chat_cb_new(user, flags);
-- gaim_conv_chat_set_users(chat,
-- g_list_prepend(gaim_conv_chat_get_users(chat), cb));
-+ cb = gaim2_conv_chat_cb_new(user, flags);
-+ gaim2_conv_chat_set_users(chat,
-+ g_list_prepend(gaim2_conv_chat_get_users(chat), cb));
- /* We reverse this later to keep it in the same order as users. */
- aliases = g_list_prepend(aliases, (char *)alias);
-
-@@ -1503,11 +1503,11 @@ gaim_conv_chat_add_users(GaimConvChat *c
- tmp = g_strdup_printf(_("%s [<I>%s</I>] entered the room."),
- alias, extra_msg);
-
-- gaim_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(tmp);
- }
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "chat-buddy-joined", conv, user, flags);
- ul = ul->next;
- fl = fl->next;
-@@ -1526,15 +1526,15 @@ gaim_conv_chat_add_users(GaimConvChat *c
- }
-
- void
--gaim_conv_chat_rename_user(GaimConvChat *chat, const char *old_user,
-+gaim2_conv_chat_rename_user(Gaim2ConvChat *chat, const char *old_user,
- const char *new_user)
- {
-- GaimConversation *conv;
-- GaimConversationUiOps *ops;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-- GaimConvChatBuddy *cb;
-- GaimConvChatBuddyFlags flags;
-+ Gaim2Conversation *conv;
-+ Gaim2ConversationUiOps *ops;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
-+ Gaim2ConvChatBuddy *cb;
-+ Gaim2ConvChatBuddyFlags flags;
- const char *new_alias = new_user;
- char tmp[BUF_LONG];
- gboolean is_me = FALSE;
-@@ -1543,63 +1543,63 @@ gaim_conv_chat_rename_user(GaimConvChat
- g_return_if_fail(old_user != NULL);
- g_return_if_fail(new_user != NULL);
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- ops = gaim_conversation_get_ui_ops(conv);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
- g_return_if_fail(gc != NULL);
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
- g_return_if_fail(prpl_info != NULL);
-
-- flags = gaim_conv_chat_user_get_flags(chat, old_user);
-- cb = gaim_conv_chat_cb_new(new_user, flags);
-- gaim_conv_chat_set_users(chat,
-- g_list_prepend(gaim_conv_chat_get_users(chat), cb));
-+ flags = gaim2_conv_chat_user_get_flags(chat, old_user);
-+ cb = gaim2_conv_chat_cb_new(new_user, flags);
-+ gaim2_conv_chat_set_users(chat,
-+ g_list_prepend(gaim2_conv_chat_get_users(chat), cb));
-
-- if (!strcmp(chat->nick, gaim_normalize(conv->account, old_user))) {
-+ if (!strcmp(chat->nick, gaim2_normalize(conv->account, old_user))) {
- const char *alias;
-
- /* Note this for later. */
- is_me = TRUE;
-
-- alias = gaim_account_get_alias(conv->account);
-+ alias = gaim2_account_get_alias(conv->account);
- if (alias != NULL)
- new_alias = alias;
- else
- {
-- const char *display_name = gaim_connection_get_display_name(gc);
-+ const char *display_name = gaim2_connection_get_display_name(gc);
- if (display_name != NULL)
- alias = display_name;
- }
- } else if (!(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) {
-- GaimBuddy *buddy;
-- if ((buddy = gaim_find_buddy(gc->account, new_user)) != NULL)
-- new_alias = gaim_buddy_get_contact_alias(buddy);
-+ Gaim2Buddy *buddy;
-+ if ((buddy = gaim2_find_buddy(gc->account, new_user)) != NULL)
-+ new_alias = gaim2_buddy_get_contact_alias(buddy);
- }
-
- if (ops != NULL && ops->chat_rename_user != NULL)
- ops->chat_rename_user(conv, old_user, new_user, new_alias);
-
-- cb = gaim_conv_chat_cb_find(chat, old_user);
-+ cb = gaim2_conv_chat_cb_find(chat, old_user);
-
- if (cb) {
-- gaim_conv_chat_set_users(chat,
-- g_list_remove(gaim_conv_chat_get_users(chat), cb));
-- gaim_conv_chat_cb_destroy(cb);
-+ gaim2_conv_chat_set_users(chat,
-+ g_list_remove(gaim2_conv_chat_get_users(chat), cb));
-+ gaim2_conv_chat_cb_destroy(cb);
- }
-
-- if (gaim_conv_chat_is_user_ignored(chat, old_user)) {
-- gaim_conv_chat_unignore(chat, old_user);
-- gaim_conv_chat_ignore(chat, new_user);
-+ if (gaim2_conv_chat_is_user_ignored(chat, old_user)) {
-+ gaim2_conv_chat_unignore(chat, old_user);
-+ gaim2_conv_chat_ignore(chat, new_user);
- }
-- else if (gaim_conv_chat_is_user_ignored(chat, new_user))
-- gaim_conv_chat_unignore(chat, new_user);
-+ else if (gaim2_conv_chat_is_user_ignored(chat, new_user))
-+ gaim2_conv_chat_unignore(chat, new_user);
-
- if (is_me)
-- gaim_conv_chat_set_nick(chat, new_user);
-+ gaim2_conv_chat_set_nick(chat, new_user);
-
-- if (gaim_prefs_get_bool("/core/conversations/chat/show_nick_change") &&
-- !gaim_conv_chat_is_user_ignored(chat, new_user)) {
-+ if (gaim2_prefs_get_bool("/core/conversations/chat/show_nick_change") &&
-+ !gaim2_conv_chat_is_user_ignored(chat, new_user)) {
-
- if (is_me) {
- g_snprintf(tmp, sizeof(tmp),
-@@ -1609,28 +1609,28 @@ gaim_conv_chat_rename_user(GaimConvChat
- const char *new_alias = new_user;
-
- if (!(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- if ((buddy = gaim_find_buddy(gc->account, old_user)) != NULL)
-- old_alias = gaim_buddy_get_contact_alias(buddy);
-- if ((buddy = gaim_find_buddy(gc->account, new_user)) != NULL)
-- new_alias = gaim_buddy_get_contact_alias(buddy);
-+ if ((buddy = gaim2_find_buddy(gc->account, old_user)) != NULL)
-+ old_alias = gaim2_buddy_get_contact_alias(buddy);
-+ if ((buddy = gaim2_find_buddy(gc->account, new_user)) != NULL)
-+ new_alias = gaim2_buddy_get_contact_alias(buddy);
- }
-
- g_snprintf(tmp, sizeof(tmp),
- _("%s is now known as %s"), old_alias, new_alias);
- }
-
-- gaim_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
- }
- }
-
- void
--gaim_conv_chat_remove_user(GaimConvChat *chat, const char *user, const char *reason)
-+gaim2_conv_chat_remove_user(Gaim2ConvChat *chat, const char *user, const char *reason)
- {
-- GaimConversation *conv;
-- GaimConversationUiOps *ops;
-- GaimConvChatBuddy *cb;
-+ Gaim2Conversation *conv;
-+ Gaim2ConversationUiOps *ops;
-+ Gaim2ConvChatBuddy *cb;
- char tmp[BUF_LONG];
- gboolean quiet;
- const char *alias = user;
-@@ -1638,38 +1638,38 @@ gaim_conv_chat_remove_user(GaimConvChat
- g_return_if_fail(chat != NULL);
- g_return_if_fail(user != NULL);
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- ops = gaim_conversation_get_ui_ops(conv);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
-- quiet = GPOINTER_TO_INT(gaim_signal_emit_return_1(gaim_conversations_get_handle(),
-+ quiet = GPOINTER_TO_INT(gaim2_signal_emit_return_1(gaim2_conversations_get_handle(),
- "chat-buddy-leaving", conv, user, reason)) |
-- gaim_conv_chat_is_user_ignored(chat, user);
-+ gaim2_conv_chat_is_user_ignored(chat, user);
-
- if (ops != NULL && ops->chat_remove_user != NULL)
- ops->chat_remove_user(conv, user);
-
-- cb = gaim_conv_chat_cb_find(chat, user);
-+ cb = gaim2_conv_chat_cb_find(chat, user);
-
- if (cb) {
-- gaim_conv_chat_set_users(chat,
-- g_list_remove(gaim_conv_chat_get_users(chat), cb));
-- gaim_conv_chat_cb_destroy(cb);
-+ gaim2_conv_chat_set_users(chat,
-+ g_list_remove(gaim2_conv_chat_get_users(chat), cb));
-+ gaim2_conv_chat_cb_destroy(cb);
- }
-
- /* NOTE: Don't remove them from ignored in case they re-enter. */
-
- if (!quiet) {
-- GaimConnection *gc = gaim_conversation_get_gc(conv);
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Connection *gc = gaim2_conversation_get_gc(conv);
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- if (!gc || !(prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)))
- return;
-
- if (!(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- if ((buddy = gaim_find_buddy(gc->account, user)) != NULL)
-- alias = gaim_buddy_get_contact_alias(buddy);
-+ if ((buddy = gaim2_find_buddy(gc->account, user)) != NULL)
-+ alias = gaim2_buddy_get_contact_alias(buddy);
- }
-
- if (reason != NULL && *reason != '\0')
-@@ -1678,19 +1678,19 @@ gaim_conv_chat_remove_user(GaimConvChat
- else
- g_snprintf(tmp, sizeof(tmp), _("%s left the room."), alias);
-
-- gaim_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
- }
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-buddy-left",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-buddy-left",
- conv, user, reason);
- }
-
- void
--gaim_conv_chat_remove_users(GaimConvChat *chat, GList *users, const char *reason)
-+gaim2_conv_chat_remove_users(Gaim2ConvChat *chat, GList *users, const char *reason)
- {
-- GaimConversation *conv;
-- GaimConversationUiOps *ops;
-- GaimConvChatBuddy *cb;
-+ Gaim2Conversation *conv;
-+ Gaim2ConversationUiOps *ops;
-+ Gaim2ConvChatBuddy *cb;
- char tmp[BUF_LONG];
- GList *l;
- gboolean quiet = FALSE;
-@@ -1698,13 +1698,13 @@ gaim_conv_chat_remove_users(GaimConvChat
- g_return_if_fail(chat != NULL);
- g_return_if_fail(users != NULL);
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- ops = gaim_conversation_get_ui_ops(conv);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
- for (l = users; l != NULL; l = l->next) {
- const char *user = (const char *)l->data;
-
-- quiet = GPOINTER_TO_INT(gaim_signal_emit_return_1(gaim_conversations_get_handle(),
-+ quiet = GPOINTER_TO_INT(gaim2_signal_emit_return_1(gaim2_conversations_get_handle(),
- "chat-buddy-leaving", conv, user, reason));
- }
-
-@@ -1714,15 +1714,15 @@ gaim_conv_chat_remove_users(GaimConvChat
- for (l = users; l != NULL; l = l->next) {
- const char *user = (const char *)l->data;
-
-- cb = gaim_conv_chat_cb_find(chat, user);
-+ cb = gaim2_conv_chat_cb_find(chat, user);
-
- if (cb) {
-- gaim_conv_chat_set_users(chat,
-- g_list_remove(gaim_conv_chat_get_users(chat), cb));
-- gaim_conv_chat_cb_destroy(cb);
-+ gaim2_conv_chat_set_users(chat,
-+ g_list_remove(gaim2_conv_chat_get_users(chat), cb));
-+ gaim2_conv_chat_cb_destroy(cb);
- }
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-buddy-left",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-buddy-left",
- conv, user, reason);
- }
-
-@@ -1738,7 +1738,7 @@ gaim_conv_chat_remove_users(GaimConvChat
-
- for (l = users, i = 0; i < max; i++, l = l->next)
- {
-- if (!gaim_conv_chat_is_user_ignored(chat, (char *)l->data))
-+ if (!gaim2_conv_chat_is_user_ignored(chat, (char *)l->data))
- {
- g_strlcat(tmp, (char *)l->data, sizeof(tmp));
-
-@@ -1757,28 +1757,28 @@ gaim_conv_chat_remove_users(GaimConvChat
-
- g_snprintf(tmp, sizeof(tmp), _(" left the room (%s)."), reason);
-
-- gaim_conversation_write(conv, NULL, tmp,
-+ gaim2_conversation_write(conv, NULL, tmp,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- }
- }
-
- void
--gaim_conv_chat_clear_users(GaimConvChat *chat)
-+gaim2_conv_chat_clear_users(Gaim2ConvChat *chat)
- {
-- GaimConversation *conv;
-- GaimConversationUiOps *ops;
-+ Gaim2Conversation *conv;
-+ Gaim2ConversationUiOps *ops;
- GList *users, *names = NULL;
- GList *l;
-
- g_return_if_fail(chat != NULL);
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- ops = gaim_conversation_get_ui_ops(conv);
-- users = gaim_conv_chat_get_users(chat);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-+ users = gaim2_conv_chat_get_users(chat);
-
- if (ops != NULL && ops->chat_remove_users != NULL) {
- for (l = users; l; l = l->next) {
-- GaimConvChatBuddy *cb = l->data;
-+ Gaim2ConvChatBuddy *cb = l->data;
- names = g_list_append(names, cb->name);
- }
- ops->chat_remove_users(conv, names);
-@@ -1787,43 +1787,43 @@ gaim_conv_chat_clear_users(GaimConvChat
-
- for (l = users; l; l = l->next)
- {
-- GaimConvChatBuddy *cb = l->data;
-+ Gaim2ConvChatBuddy *cb = l->data;
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "chat-buddy-leaving", conv, cb->name, NULL);
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "chat-buddy-left", conv, cb->name, NULL);
-
-- gaim_conv_chat_cb_destroy(cb);
-+ gaim2_conv_chat_cb_destroy(cb);
- }
-
- g_list_free(users);
-- gaim_conv_chat_set_users(chat, NULL);
-+ gaim2_conv_chat_set_users(chat, NULL);
- }
-
-
- gboolean
--gaim_conv_chat_find_user(GaimConvChat *chat, const char *user)
-+gaim2_conv_chat_find_user(Gaim2ConvChat *chat, const char *user)
- {
- g_return_val_if_fail(chat != NULL, FALSE);
- g_return_val_if_fail(user != NULL, FALSE);
-
-- return (gaim_conv_chat_cb_find(chat, user) != NULL);
-+ return (gaim2_conv_chat_cb_find(chat, user) != NULL);
- }
-
- void
--gaim_conv_chat_user_set_flags(GaimConvChat *chat, const char *user,
-- GaimConvChatBuddyFlags flags)
-+gaim2_conv_chat_user_set_flags(Gaim2ConvChat *chat, const char *user,
-+ Gaim2ConvChatBuddyFlags flags)
- {
-- GaimConversation *conv;
-- GaimConversationUiOps *ops;
-- GaimConvChatBuddy *cb;
-- GaimConvChatBuddyFlags oldflags;
-+ Gaim2Conversation *conv;
-+ Gaim2ConversationUiOps *ops;
-+ Gaim2ConvChatBuddy *cb;
-+ Gaim2ConvChatBuddyFlags oldflags;
-
- g_return_if_fail(chat != NULL);
- g_return_if_fail(user != NULL);
-
-- cb = gaim_conv_chat_cb_find(chat, user);
-+ cb = gaim2_conv_chat_cb_find(chat, user);
-
- if (!cb)
- return;
-@@ -1834,25 +1834,25 @@ gaim_conv_chat_user_set_flags(GaimConvCh
- oldflags = cb->flags;
- cb->flags = flags;
-
-- conv = gaim_conv_chat_get_conversation(chat);
-- ops = gaim_conversation_get_ui_ops(conv);
-+ conv = gaim2_conv_chat_get_conversation(chat);
-+ ops = gaim2_conversation_get_ui_ops(conv);
-
- if (ops != NULL && ops->chat_update_user != NULL)
- ops->chat_update_user(conv, user);
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "chat-buddy-flags", conv, user, oldflags, flags);
- }
-
--GaimConvChatBuddyFlags
--gaim_conv_chat_user_get_flags(GaimConvChat *chat, const char *user)
-+Gaim2ConvChatBuddyFlags
-+gaim2_conv_chat_user_get_flags(Gaim2ConvChat *chat, const char *user)
- {
-- GaimConvChatBuddy *cb;
-+ Gaim2ConvChatBuddy *cb;
-
- g_return_val_if_fail(chat != NULL, 0);
- g_return_val_if_fail(user != NULL, 0);
-
-- cb = gaim_conv_chat_cb_find(chat, user);
-+ cb = gaim2_conv_chat_cb_find(chat, user);
-
- if (!cb)
- return GAIM_CBFLAGS_NONE;
-@@ -1860,31 +1860,31 @@ gaim_conv_chat_user_get_flags(GaimConvCh
- return cb->flags;
- }
-
--void gaim_conv_chat_set_nick(GaimConvChat *chat, const char *nick) {
-+void gaim2_conv_chat_set_nick(Gaim2ConvChat *chat, const char *nick) {
- g_return_if_fail(chat != NULL);
-
- if(chat->nick)
- g_free(chat->nick);
-- chat->nick = g_strdup(gaim_normalize(chat->conv->account, nick));
-+ chat->nick = g_strdup(gaim2_normalize(chat->conv->account, nick));
- }
-
--const char *gaim_conv_chat_get_nick(GaimConvChat *chat) {
-+const char *gaim2_conv_chat_get_nick(Gaim2ConvChat *chat) {
- g_return_val_if_fail(chat != NULL, NULL);
-
- return chat->nick;
- }
-
--GaimConversation *
--gaim_find_chat(const GaimConnection *gc, int id)
-+Gaim2Conversation *
-+gaim2_find_chat(const Gaim2Connection *gc, int id)
- {
- GList *l;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
-- for (l = gaim_get_chats(); l != NULL; l = l->next) {
-- conv = (GaimConversation *)l->data;
-+ for (l = gaim2_get_chats(); l != NULL; l = l->next) {
-+ conv = (Gaim2Conversation *)l->data;
-
-- if (gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)) == id &&
-- gaim_conversation_get_gc(conv) == gc)
-+ if (gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)) == id &&
-+ gaim2_conversation_get_gc(conv) == gc)
- return conv;
- }
-
-@@ -1892,49 +1892,49 @@ gaim_find_chat(const GaimConnection *gc,
- }
-
- void
--gaim_conv_chat_left(GaimConvChat *chat)
-+gaim2_conv_chat_left(Gaim2ConvChat *chat)
- {
- g_return_if_fail(chat != NULL);
-
- chat->left = TRUE;
-- gaim_conversation_update(chat->conv, GAIM_CONV_UPDATE_CHATLEFT);
-+ gaim2_conversation_update(chat->conv, GAIM_CONV_UPDATE_CHATLEFT);
- }
-
- gboolean
--gaim_conv_chat_has_left(GaimConvChat *chat)
-+gaim2_conv_chat_has_left(Gaim2ConvChat *chat)
- {
- g_return_val_if_fail(chat != NULL, TRUE);
-
- return chat->left;
- }
-
--GaimConvChatBuddy *
--gaim_conv_chat_cb_new(const char *name, GaimConvChatBuddyFlags flags)
-+Gaim2ConvChatBuddy *
-+gaim2_conv_chat_cb_new(const char *name, Gaim2ConvChatBuddyFlags flags)
- {
-- GaimConvChatBuddy *cb;
-+ Gaim2ConvChatBuddy *cb;
-
- g_return_val_if_fail(name != NULL, NULL);
-
-- cb = g_new0(GaimConvChatBuddy, 1);
-+ cb = g_new0(Gaim2ConvChatBuddy, 1);
- cb->name = g_strdup(name);
- cb->flags = flags;
-
-- GAIM_DBUS_REGISTER_POINTER(cb, GaimConvChatBuddy);
-+ GAIM_DBUS_REGISTER_POINTER(cb, Gaim2ConvChatBuddy);
- return cb;
- }
-
--GaimConvChatBuddy *
--gaim_conv_chat_cb_find(GaimConvChat *chat, const char *name)
-+Gaim2ConvChatBuddy *
-+gaim2_conv_chat_cb_find(Gaim2ConvChat *chat, const char *name)
- {
- GList *l;
-- GaimConvChatBuddy *cb = NULL;
-+ Gaim2ConvChatBuddy *cb = NULL;
-
- g_return_val_if_fail(chat != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
-
-- for (l = gaim_conv_chat_get_users(chat); l; l = l->next) {
-+ for (l = gaim2_conv_chat_get_users(chat); l; l = l->next) {
- cb = l->data;
-- if (!gaim_utf8_strcasecmp(cb->name, name))
-+ if (!gaim2_utf8_strcasecmp(cb->name, name))
- return cb;
- }
-
-@@ -1942,7 +1942,7 @@ gaim_conv_chat_cb_find(GaimConvChat *cha
- }
-
- void
--gaim_conv_chat_cb_destroy(GaimConvChatBuddy *cb)
-+gaim2_conv_chat_cb_destroy(Gaim2ConvChatBuddy *cb)
- {
- g_return_if_fail(cb != NULL);
-
-@@ -1956,7 +1956,7 @@ gaim_conv_chat_cb_destroy(GaimConvChatBu
- }
-
- const char *
--gaim_conv_chat_cb_get_name(GaimConvChatBuddy *cb)
-+gaim2_conv_chat_cb_get_name(Gaim2ConvChatBuddy *cb)
- {
- g_return_val_if_fail(cb != NULL, NULL);
-
-@@ -1964,7 +1964,7 @@ gaim_conv_chat_cb_get_name(GaimConvChatB
- }
-
- void *
--gaim_conversations_get_handle(void)
-+gaim2_conversations_get_handle(void)
- {
- static int handle;
-
-@@ -1972,251 +1972,251 @@ gaim_conversations_get_handle(void)
- }
-
- void
--gaim_conversations_init(void)
-+gaim2_conversations_init(void)
- {
-- void *handle = gaim_conversations_get_handle();
-+ void *handle = gaim2_conversations_get_handle();
-
- /**********************************************************************
- * Register preferences
- **********************************************************************/
-
- /* Conversations */
-- gaim_prefs_add_none("/core/conversations");
-+ gaim2_prefs_add_none("/core/conversations");
-
- /* Conversations -> Chat */
-- gaim_prefs_add_none("/core/conversations/chat");
-- gaim_prefs_add_bool("/core/conversations/chat/show_nick_change", TRUE);
-+ gaim2_prefs_add_none("/core/conversations/chat");
-+ gaim2_prefs_add_bool("/core/conversations/chat/show_nick_change", TRUE);
-
- /* Conversations -> IM */
-- gaim_prefs_add_none("/core/conversations/im");
-- gaim_prefs_add_bool("/core/conversations/im/send_typing", TRUE);
-+ gaim2_prefs_add_none("/core/conversations/im");
-+ gaim2_prefs_add_bool("/core/conversations/im/send_typing", TRUE);
-
-
- /**********************************************************************
- * Register signals
- **********************************************************************/
-- gaim_signal_register(handle, "writing-im-msg",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "writing-im-msg",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING));
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "wrote-im-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER,
-+ gaim2_signal_register(handle, "wrote-im-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER,
- NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "sending-im-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER,
-+ gaim2_signal_register(handle, "sending-im-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER,
- NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "sent-im-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER,
-+ gaim2_signal_register(handle, "sent-im-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER,
- NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "receiving-im-msg",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 5,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "receiving-im-msg",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 5,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new_outgoing(GAIM_TYPE_UINT));
-+ gaim2_value_new_outgoing(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "received-im-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT,
-+ gaim2_signal_register(handle, "received-im-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT,
- NULL, 5,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "writing-chat-msg",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "writing-chat-msg",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING));
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "wrote-chat-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER,
-+ gaim2_signal_register(handle, "wrote-chat-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER,
- NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "sending-chat-msg",
-- gaim_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "sending-chat-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "sent-chat-msg",
-- gaim_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "sent-chat-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "receiving-chat-msg",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 5,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "receiving-chat-msg",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 5,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new_outgoing(GAIM_TYPE_UINT));
-+ gaim2_value_new_outgoing(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "received-chat-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT,
-+ gaim2_signal_register(handle, "received-chat-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT,
- NULL, 5,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "conversation-created",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "conversation-created",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION));
-
-- gaim_signal_register(handle, "conversation-updated",
-- gaim_marshal_VOID__POINTER_UINT, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "conversation-updated",
-+ gaim2_marshal_VOID__POINTER_UINT, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "deleting-conversation",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "deleting-conversation",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION));
-
-- gaim_signal_register(handle, "buddy-typing",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-typing",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "buddy-typing-stopped",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "buddy-typing-stopped",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "chat-buddy-joining",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_UINT,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-buddy-joining",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_UINT,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "chat-buddy-joined",
-- gaim_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-buddy-joined",
-+ gaim2_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_UINT));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_UINT));
-
-- gaim_signal_register(handle, "chat-buddy-flags",
-- gaim_marshal_VOID__POINTER_POINTER_UINT_UINT, NULL, 4,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-buddy-flags",
-+ gaim2_marshal_VOID__POINTER_POINTER_UINT_UINT, NULL, 4,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_UINT),
-- gaim_value_new(GAIM_TYPE_UINT));
--
-- gaim_signal_register(handle, "chat-buddy-leaving",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_UINT),
-+ gaim2_value_new(GAIM_TYPE_UINT));
-+
-+ gaim2_signal_register(handle, "chat-buddy-leaving",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "chat-buddy-left",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-buddy-left",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "chat-inviting-user",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-inviting-user",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "chat-invited-user",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-invited-user",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING));
-
-- gaim_signal_register(handle, "chat-invited",
-- gaim_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER,
-+ gaim2_signal_register(handle, "chat-invited",
-+ gaim2_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER,
- NULL, 5,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_POINTER));
--
-- gaim_signal_register(handle, "chat-joined",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+
-+ gaim2_signal_register(handle, "chat-joined",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION));
-
-- gaim_signal_register(handle, "chat-left",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-left",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION));
-
-- gaim_signal_register(handle, "chat-topic-changed",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "chat-topic-changed",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(GAIM_TYPE_STRING));
- }
-
- void
--gaim_conversations_uninit(void)
-+gaim2_conversations_uninit(void)
- {
- while (conversations)
-- gaim_conversation_destroy((GaimConversation*)conversations->data);
-- gaim_signals_unregister_by_instance(gaim_conversations_get_handle());
-+ gaim2_conversation_destroy((Gaim2Conversation*)conversations->data);
-+ gaim2_signals_unregister_by_instance(gaim2_conversations_get_handle());
- }
-diff -prNu ./src/conversation.h ./src/conversation.h
---- ./src/conversation.h 2005-12-22 18:16:57.000000000 +0100
-+++ ./src/conversation.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file conversation.h Conversation API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,11 +32,11 @@
- /**************************************************************************/
-
-
--typedef struct _GaimConversationUiOps GaimConversationUiOps;
--typedef struct _GaimConversation GaimConversation;
--typedef struct _GaimConvIm GaimConvIm;
--typedef struct _GaimConvChat GaimConvChat;
--typedef struct _GaimConvChatBuddy GaimConvChatBuddy;
-+typedef struct _Gaim2ConversationUiOps Gaim2ConversationUiOps;
-+typedef struct _Gaim2Conversation Gaim2Conversation;
-+typedef struct _Gaim2ConvIm Gaim2ConvIm;
-+typedef struct _Gaim2ConvChat Gaim2ConvChat;
-+typedef struct _Gaim2ConvChatBuddy Gaim2ConvChatBuddy;
-
- /**
- * A type of conversation.
-@@ -49,7 +49,7 @@ typedef enum
- GAIM_CONV_TYPE_MISC, /**< A misc. conversation. */
- GAIM_CONV_TYPE_ANY /**< Any type of conversation. */
-
--} GaimConversationType;
-+} Gaim2ConversationType;
-
- /**
- * Conversation update type.
-@@ -60,7 +60,7 @@ typedef enum
- was added. */
- GAIM_CONV_UPDATE_REMOVE, /**< The buddy associated with the conversation
- was removed. */
-- GAIM_CONV_UPDATE_ACCOUNT, /**< The gaim_account was changed. */
-+ GAIM_CONV_UPDATE_ACCOUNT, /**< The gaim2_account was changed. */
- GAIM_CONV_UPDATE_TYPING, /**< The typing state was updated. */
- GAIM_CONV_UPDATE_UNSEEN, /**< The unseen state was updated. */
- GAIM_CONV_UPDATE_LOGGING, /**< Logging for this conversation was
-@@ -79,7 +79,7 @@ typedef enum
-
- GAIM_CONV_UPDATE_FEATURES, /**< The features for a chat have changed */
-
--} GaimConvUpdateType;
-+} Gaim2ConvUpdateType;
-
- /**
- * The typing state of a user.
-@@ -90,7 +90,7 @@ typedef enum
- GAIM_TYPING, /**< Currently typing. */
- GAIM_TYPED /**< Stopped typing momentarily. */
-
--} GaimTypingState;
-+} Gaim2TypingState;
-
- /**
- * Flags applicable to a message. Most will have send, recv or system.
-@@ -110,7 +110,7 @@ typedef enum
- GAIM_MESSAGE_RAW = 0x0800, /**< "Raw" message - don't apply formatting */
- GAIM_MESSAGE_IMAGES = 0x1000 /**< Message contains images */
-
--} GaimMessageFlags;
-+} Gaim2MessageFlags;
-
- /**
- * Flags applicable to users in Chats.
-@@ -125,7 +125,7 @@ typedef enum
- GAIM_CBFLAGS_TYPING = 0x0010, /**< Currently typing */
-
-
--} GaimConvChatBuddyFlags;
-+} Gaim2ConvChatBuddyFlags;
-
- #include "account.h"
- #include "buddyicon.h"
-@@ -136,66 +136,66 @@ typedef enum
- * Conversation operations and events.
- *
- * Any UI representing a conversation must assign a filled-out
-- * GaimConversationUiOps structure to the GaimConversation.
-+ * Gaim2ConversationUiOps structure to the Gaim2Conversation.
- */
--struct _GaimConversationUiOps
-+struct _Gaim2ConversationUiOps
- {
-- void (*create_conversation)(GaimConversation *conv);
-- void (*destroy_conversation)(GaimConversation *conv);
-- void (*write_chat)(GaimConversation *conv, const char *who,
-- const char *message, GaimMessageFlags flags,
-+ void (*create_conversation)(Gaim2Conversation *conv);
-+ void (*destroy_conversation)(Gaim2Conversation *conv);
-+ void (*write_chat)(Gaim2Conversation *conv, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime);
-- void (*write_im)(GaimConversation *conv, const char *who,
-- const char *message, GaimMessageFlags flags,
-+ void (*write_im)(Gaim2Conversation *conv, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime);
-- void (*write_conv)(GaimConversation *conv, const char *name, const char *alias,
-- const char *message, GaimMessageFlags flags,
-+ void (*write_conv)(Gaim2Conversation *conv, const char *name, const char *alias,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime);
-
-- void (*chat_add_users)(GaimConversation *conv, GList *users,
-+ void (*chat_add_users)(Gaim2Conversation *conv, GList *users,
- GList *flags, GList *aliases, gboolean new_arrivals);
-- void (*chat_rename_user)(GaimConversation *conv, const char *old_name,
-+ void (*chat_rename_user)(Gaim2Conversation *conv, const char *old_name,
- const char *new_name, const char *new_alias);
-- void (*chat_remove_user)(GaimConversation *conv, const char *user);
-- void (*chat_remove_users)(GaimConversation *conv, GList *users);
-- void (*chat_update_user)(GaimConversation *conv, const char *user);
-+ void (*chat_remove_user)(Gaim2Conversation *conv, const char *user);
-+ void (*chat_remove_users)(Gaim2Conversation *conv, GList *users);
-+ void (*chat_update_user)(Gaim2Conversation *conv, const char *user);
-
-- void (*present)(GaimConversation *conv);
-+ void (*present)(Gaim2Conversation *conv);
-
-- gboolean (*has_focus)(GaimConversation *conv);
-+ gboolean (*has_focus)(Gaim2Conversation *conv);
-
- /* Custom Smileys */
-- gboolean (*custom_smiley_add)(GaimConversation *conv, const char *smile, gboolean remote);
-- void (*custom_smiley_write)(GaimConversation *conv, const char *smile,
-+ gboolean (*custom_smiley_add)(Gaim2Conversation *conv, const char *smile, gboolean remote);
-+ void (*custom_smiley_write)(Gaim2Conversation *conv, const char *smile,
- const guchar *data, gsize size);
-- void (*custom_smiley_close)(GaimConversation *conv, const char *smile);
-+ void (*custom_smiley_close)(Gaim2Conversation *conv, const char *smile);
-
- /* Events */
-- void (*updated)(GaimConversation *conv, GaimConvUpdateType type);
-+ void (*updated)(Gaim2Conversation *conv, Gaim2ConvUpdateType type);
-
- };
-
- /**
- * Data specific to Instant Messages.
- */
--struct _GaimConvIm
-+struct _Gaim2ConvIm
- {
-- GaimConversation *conv; /**< The parent conversation. */
-+ Gaim2Conversation *conv; /**< The parent conversation. */
-
-- GaimTypingState typing_state; /**< The current typing state. */
-+ Gaim2TypingState typing_state; /**< The current typing state. */
- guint typing_timeout; /**< The typing timer handle. */
- time_t type_again; /**< The type again time. */
- guint type_again_timeout; /**< The type again timer handle. */
-
-- GaimBuddyIcon *icon; /**< The buddy icon. */
-+ Gaim2BuddyIcon *icon; /**< The buddy icon. */
- };
-
- /**
- * Data specific to Chats.
- */
--struct _GaimConvChat
-+struct _Gaim2ConvChat
- {
-- GaimConversation *conv; /**< The parent conversation. */
-+ Gaim2Conversation *conv; /**< The parent conversation. */
-
- GList *in_room; /**< The users in the room. */
- GList *ignored; /**< Ignored users. */
-@@ -210,10 +210,10 @@ struct _GaimConvChat
- /**
- * Data for "Chat Buddies"
- */
--struct _GaimConvChatBuddy
-+struct _Gaim2ConvChatBuddy
- {
- char *name; /**< The name */
-- GaimConvChatBuddyFlags flags; /**< Flags (ops, voice etc.) */
-+ Gaim2ConvChatBuddyFlags flags; /**< Flags (ops, voice etc.) */
- };
-
- /**
-@@ -221,11 +221,11 @@ struct _GaimConvChatBuddy
- *
- * The conversation can be an IM or a chat.
- */
--struct _GaimConversation
-+struct _Gaim2Conversation
- {
-- GaimConversationType type; /**< The type of conversation. */
-+ Gaim2ConversationType type; /**< The type of conversation. */
-
-- GaimAccount *account; /**< The user using this conversation. */
-+ Gaim2Account *account; /**< The user using this conversation. */
-
-
- char *name; /**< The name of the conversation. */
-@@ -239,18 +239,18 @@ struct _GaimConversation
-
- union
- {
-- GaimConvIm *im; /**< IM-specific data. */
-- GaimConvChat *chat; /**< Chat-specific data. */
-+ Gaim2ConvIm *im; /**< IM-specific data. */
-+ Gaim2ConvChat *chat; /**< Chat-specific data. */
- void *misc; /**< Misc. data. */
-
- } u;
-
-- GaimConversationUiOps *ui_ops; /**< UI-specific operations. */
-+ Gaim2ConversationUiOps *ui_ops; /**< UI-specific operations. */
- void *ui_data; /**< UI-specific data. */
-
- GHashTable *data; /**< Plugin-specific data. */
-
-- GaimConnectionFlags features; /**< The supported features */
-+ Gaim2ConnectionFlags features; /**< The supported features */
-
- };
-
-@@ -267,14 +267,14 @@ extern "C" {
- * Creates a new conversation of the specified type.
- *
- * @param type The type of conversation.
-- * @param account The account opening the conversation window on the gaim
-+ * @param account The account opening the conversation window on the gaim2
- * user's end.
- * @param name The name of the conversation.
- *
- * @return The new conversation.
- */
--GaimConversation *gaim_conversation_new(GaimConversationType type,
-- GaimAccount *account,
-+Gaim2Conversation *gaim2_conversation_new(Gaim2ConversationType type,
-+ Gaim2Account *account,
- const char *name);
-
- /**
-@@ -286,7 +286,7 @@ GaimConversation *gaim_conversation_new(
- *
- * @param conv The conversation to destroy.
- */
--void gaim_conversation_destroy(GaimConversation *conv);
-+void gaim2_conversation_destroy(Gaim2Conversation *conv);
-
-
- /**
-@@ -294,7 +294,7 @@ void gaim_conversation_destroy(GaimConve
- * conversation by displaying the IM dialog.
- * @param conv The conversation to present
- */
--void gaim_conversation_present(GaimConversation *conv);
-+void gaim2_conversation_present(Gaim2Conversation *conv);
-
-
- /**
-@@ -304,7 +304,7 @@ void gaim_conversation_present(GaimConve
- *
- * @return The conversation's type.
- */
--GaimConversationType gaim_conversation_get_type(const GaimConversation *conv);
-+Gaim2ConversationType gaim2_conversation_get_type(const Gaim2Conversation *conv);
-
- /**
- * Sets the specified conversation's UI operations structure.
-@@ -312,15 +312,15 @@ GaimConversationType gaim_conversation_g
- * @param conv The conversation.
- * @param ops The UI conversation operations structure.
- */
--void gaim_conversation_set_ui_ops(GaimConversation *conv,
-- GaimConversationUiOps *ops);
-+void gaim2_conversation_set_ui_ops(Gaim2Conversation *conv,
-+ Gaim2ConversationUiOps *ops);
-
- /**
- * Sets the default conversation UI operations structure.
- *
- * @param ops The UI conversation operations structure.
- */
--void gaim_conversations_set_ui_ops(GaimConversationUiOps *ops);
-+void gaim2_conversations_set_ui_ops(Gaim2ConversationUiOps *ops);
-
- /**
- * Returns the specified conversation's UI operations structure.
-@@ -329,43 +329,43 @@ void gaim_conversations_set_ui_ops(GaimC
- *
- * @return The operations structure.
- */
--GaimConversationUiOps *gaim_conversation_get_ui_ops(
-- const GaimConversation *conv);
-+Gaim2ConversationUiOps *gaim2_conversation_get_ui_ops(
-+ const Gaim2Conversation *conv);
-
- /**
-- * Sets the specified conversation's gaim_account.
-+ * Sets the specified conversation's gaim2_account.
- *
-- * This gaim_account represents the user using gaim, not the person the user
-+ * This gaim2_account represents the user using gaim2, not the person the user
- * is having a conversation/chat/flame with.
- *
- * @param conv The conversation.
-- * @param account The gaim_account.
-+ * @param account The gaim2_account.
- */
--void gaim_conversation_set_account(GaimConversation *conv,
-- GaimAccount *account);
-+void gaim2_conversation_set_account(Gaim2Conversation *conv,
-+ Gaim2Account *account);
-
- /**
-- * Returns the specified conversation's gaim_account.
-+ * Returns the specified conversation's gaim2_account.
- *
-- * This gaim_account represents the user using gaim, not the person the user
-+ * This gaim2_account represents the user using gaim2, not the person the user
- * is having a conversation/chat/flame with.
- *
- * @param conv The conversation.
- *
-- * @return The conversation's gaim_account.
-+ * @return The conversation's gaim2_account.
- */
--GaimAccount *gaim_conversation_get_account(const GaimConversation *conv);
-+Gaim2Account *gaim2_conversation_get_account(const Gaim2Conversation *conv);
-
- /**
-- * Returns the specified conversation's gaim_connection.
-+ * Returns the specified conversation's gaim2_connection.
- *
-- * This is the same as gaim_conversation_get_user(conv)->gc.
-+ * This is the same as gaim2_conversation_get_user(conv)->gc.
- *
- * @param conv The conversation.
- *
-- * @return The conversation's gaim_connection.
-+ * @return The conversation's gaim2_connection.
- */
--GaimConnection *gaim_conversation_get_gc(const GaimConversation *conv);
-+Gaim2Connection *gaim2_conversation_get_gc(const Gaim2Conversation *conv);
-
- /**
- * Sets the specified conversation's title.
-@@ -373,7 +373,7 @@ GaimConnection *gaim_conversation_get_gc
- * @param conv The conversation.
- * @param title The title.
- */
--void gaim_conversation_set_title(GaimConversation *conv, const char *title);
-+void gaim2_conversation_set_title(Gaim2Conversation *conv, const char *title);
-
- /**
- * Returns the specified conversation's title.
-@@ -382,7 +382,7 @@ void gaim_conversation_set_title(GaimCon
- *
- * @return The title.
- */
--const char *gaim_conversation_get_title(const GaimConversation *conv);
-+const char *gaim2_conversation_get_title(const Gaim2Conversation *conv);
-
- /**
- * Automatically sets the specified conversation's title.
-@@ -392,7 +392,7 @@ const char *gaim_conversation_get_title(
- *
- * @param conv The conversation.
- */
--void gaim_conversation_autoset_title(GaimConversation *conv);
-+void gaim2_conversation_autoset_title(Gaim2Conversation *conv);
-
- /**
- * Sets the specified conversation's name.
-@@ -400,7 +400,7 @@ void gaim_conversation_autoset_title(Gai
- * @param conv The conversation.
- * @param name The conversation's name.
- */
--void gaim_conversation_set_name(GaimConversation *conv, const char *name);
-+void gaim2_conversation_set_name(Gaim2Conversation *conv, const char *name);
-
- /**
- * Returns the specified conversation's name.
-@@ -409,7 +409,7 @@ void gaim_conversation_set_name(GaimConv
- *
- * @return The conversation's name.
- */
--const char *gaim_conversation_get_name(const GaimConversation *conv);
-+const char *gaim2_conversation_get_name(const Gaim2Conversation *conv);
-
- /**
- * Enables or disables logging for this conversation.
-@@ -417,7 +417,7 @@ const char *gaim_conversation_get_name(c
- * @param conv The conversation.
- * @param log @c TRUE if logging should be enabled, or @c FALSE otherwise.
- */
--void gaim_conversation_set_logging(GaimConversation *conv, gboolean log);
-+void gaim2_conversation_set_logging(Gaim2Conversation *conv, gboolean log);
-
- /**
- * Returns whether or not logging is enabled for this conversation.
-@@ -426,18 +426,18 @@ void gaim_conversation_set_logging(GaimC
- *
- * @return @c TRUE if logging is enabled, or @c FALSE otherwise.
- */
--gboolean gaim_conversation_is_logging(const GaimConversation *conv);
-+gboolean gaim2_conversation_is_logging(const Gaim2Conversation *conv);
-
- /**
- * Closes any open logs for this conversation.
- *
- * Note that new logs will be opened as necessary (e.g. upon receipt of a
- * message, if the conversation has logging enabled. To disable logging for
-- * the remainder of the conversation, use gaim_conversation_set_logging().
-+ * the remainder of the conversation, use gaim2_conversation_set_logging().
- *
- * @param conv The conversation.
- */
--void gaim_conversation_close_logs(GaimConversation *conv);
-+void gaim2_conversation_close_logs(Gaim2Conversation *conv);
-
- /**
- * Returns the specified conversation's send history.
-@@ -446,7 +446,7 @@ void gaim_conversation_close_logs(GaimCo
- *
- * @return The conversation's send history.
- */
--GList *gaim_conversation_get_send_history(const GaimConversation *conv);
-+GList *gaim2_conversation_get_send_history(const Gaim2Conversation *conv);
-
- /**
- * Returns the specified conversation's IM-specific data.
-@@ -457,9 +457,9 @@ GList *gaim_conversation_get_send_histor
- *
- * @return The IM-specific data.
- */
--GaimConvIm *gaim_conversation_get_im_data(const GaimConversation *conv);
-+Gaim2ConvIm *gaim2_conversation_get_im_data(const Gaim2Conversation *conv);
-
--#define GAIM_CONV_IM(c) (gaim_conversation_get_im_data(c))
-+#define GAIM_CONV_IM(c) (gaim2_conversation_get_im_data(c))
-
- /**
- * Returns the specified conversation's chat-specific data.
-@@ -470,9 +470,9 @@ GaimConvIm *gaim_conversation_get_im_dat
- *
- * @return The chat-specific data.
- */
--GaimConvChat *gaim_conversation_get_chat_data(const GaimConversation *conv);
-+Gaim2ConvChat *gaim2_conversation_get_chat_data(const Gaim2Conversation *conv);
-
--#define GAIM_CONV_CHAT(c) (gaim_conversation_get_chat_data(c))
-+#define GAIM_CONV_CHAT(c) (gaim2_conversation_get_chat_data(c))
-
- /**
- * Sets extra data for a conversation.
-@@ -481,7 +481,7 @@ GaimConvChat *gaim_conversation_get_chat
- * @param key The unique key.
- * @param data The data to assign.
- */
--void gaim_conversation_set_data(GaimConversation *conv, const char *key,
-+void gaim2_conversation_set_data(Gaim2Conversation *conv, const char *key,
- gpointer data);
-
- /**
-@@ -492,7 +492,7 @@ void gaim_conversation_set_data(GaimConv
- *
- * @return The data associated with the key.
- */
--gpointer gaim_conversation_get_data(GaimConversation *conv, const char *key);
-+gpointer gaim2_conversation_get_data(Gaim2Conversation *conv, const char *key);
-
- /**
- * Returns a list of all conversations.
-@@ -501,40 +501,40 @@ gpointer gaim_conversation_get_data(Gaim
- *
- * @return A GList of all conversations.
- */
--GList *gaim_get_conversations(void);
-+GList *gaim2_get_conversations(void);
-
- /**
- * Returns a list of all IMs.
- *
- * @return A GList of all IMs.
- */
--GList *gaim_get_ims(void);
-+GList *gaim2_get_ims(void);
-
- /**
- * Returns a list of all chats.
- *
- * @return A GList of all chats.
- */
--GList *gaim_get_chats(void);
-+GList *gaim2_get_chats(void);
-
- /**
-- * Finds a conversation with the specified type, name, and Gaim account.
-+ * Finds a conversation with the specified type, name, and Gaim2 account.
- *
- * @param type The type of the conversation.
- * @param name The name of the conversation.
-- * @param account The gaim_account associated with the conversation.
-+ * @param account The gaim2_account associated with the conversation.
- *
- * @return The conversation if found, or @c NULL otherwise.
- */
--GaimConversation *gaim_find_conversation_with_account(
-- GaimConversationType type, const char *name,
-- const GaimAccount *account);
-+Gaim2Conversation *gaim2_find_conversation_with_account(
-+ Gaim2ConversationType type, const char *name,
-+ const Gaim2Account *account);
-
- /**
- * Writes to a conversation window.
- *
- * This function should not be used to write IM or chat messages. Use
-- * gaim_conv_im_write() and gaim_conv_chat_write() instead. Those functions will
-+ * gaim2_conv_im_write() and gaim2_conv_chat_write() instead. Those functions will
- * most likely call this anyway, but they may do their own formatting,
- * sound playback, etc.
- *
-@@ -547,11 +547,11 @@ GaimConversation *gaim_find_conversation
- * @param flags The message flags.
- * @param mtime The time the message was sent.
- *
-- * @see gaim_conv_im_write()
-- * @see gaim_conv_chat_write()
-+ * @see gaim2_conv_im_write()
-+ * @see gaim2_conv_chat_write()
- */
--void gaim_conversation_write(GaimConversation *conv, const char *who,
-- const char *message, GaimMessageFlags flags,
-+void gaim2_conversation_write(Gaim2Conversation *conv, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime);
-
-
-@@ -560,15 +560,15 @@ void gaim_conversation_write(GaimConvers
- @param conv The conversation
- @param features Bitset defining supported features
- */
--void gaim_conversation_set_features(GaimConversation *conv,
-- GaimConnectionFlags features);
-+void gaim2_conversation_set_features(Gaim2Conversation *conv,
-+ Gaim2ConnectionFlags features);
-
-
- /**
- Get the features supported by the given conversation.
- @param conv The conversation
- */
--GaimConnectionFlags gaim_conversation_get_features(GaimConversation *conv);
-+Gaim2ConnectionFlags gaim2_conversation_get_features(Gaim2Conversation *conv);
-
- /**
- * Determines if a conversation has focus
-@@ -578,7 +578,7 @@ GaimConnectionFlags gaim_conversation_ge
- * @return @c TRUE if the conversation has focus, @c FALSE if
- * it does not or the UI does not have a concept of conversation focus
- */
--gboolean gaim_conversation_has_focus(GaimConversation *conv);
-+gboolean gaim2_conversation_has_focus(Gaim2Conversation *conv);
-
- /**
- * Updates the visual status and UI of a conversation.
-@@ -586,14 +586,14 @@ gboolean gaim_conversation_has_focus(Gai
- * @param conv The conversation.
- * @param type The update type.
- */
--void gaim_conversation_update(GaimConversation *conv, GaimConvUpdateType type);
-+void gaim2_conversation_update(Gaim2Conversation *conv, Gaim2ConvUpdateType type);
-
- /**
- * Calls a function on each conversation.
- *
- * @param func The function.
- */
--void gaim_conversation_foreach(void (*func)(GaimConversation *conv));
-+void gaim2_conversation_foreach(void (*func)(Gaim2Conversation *conv));
-
- /*@}*/
-
-@@ -610,20 +610,20 @@ void gaim_conversation_foreach(void (*fu
- *
- * @return The parent conversation.
- */
--GaimConversation *gaim_conv_im_get_conversation(const GaimConvIm *im);
-+Gaim2Conversation *gaim2_conv_im_get_conversation(const Gaim2ConvIm *im);
-
- /**
- * Sets the IM's buddy icon.
- *
-- * This should only be called from within Gaim. You probably want to
-- * call gaim_buddy_icon_set_data().
-+ * This should only be called from within Gaim2. You probably want to
-+ * call gaim2_buddy_icon_set_data().
- *
- * @param im The IM.
- * @param icon The buddy icon.
- *
-- * @see gaim_buddy_icon_set_data()
-+ * @see gaim2_buddy_icon_set_data()
- */
--void gaim_conv_im_set_icon(GaimConvIm *im, GaimBuddyIcon *icon);
-+void gaim2_conv_im_set_icon(Gaim2ConvIm *im, Gaim2BuddyIcon *icon);
-
- /**
- * Returns the IM's buddy icon.
-@@ -632,7 +632,7 @@ void gaim_conv_im_set_icon(GaimConvIm *i
- *
- * @return The buddy icon.
- */
--GaimBuddyIcon *gaim_conv_im_get_icon(const GaimConvIm *im);
-+Gaim2BuddyIcon *gaim2_conv_im_get_icon(const Gaim2ConvIm *im);
-
- /**
- * Sets the IM's typing state.
-@@ -640,7 +640,7 @@ GaimBuddyIcon *gaim_conv_im_get_icon(con
- * @param im The IM.
- * @param state The typing state.
- */
--void gaim_conv_im_set_typing_state(GaimConvIm *im, GaimTypingState state);
-+void gaim2_conv_im_set_typing_state(Gaim2ConvIm *im, Gaim2TypingState state);
-
- /**
- * Returns the IM's typing state.
-@@ -649,7 +649,7 @@ void gaim_conv_im_set_typing_state(GaimC
- *
- * @return The IM's typing state.
- */
--GaimTypingState gaim_conv_im_get_typing_state(const GaimConvIm *im);
-+Gaim2TypingState gaim2_conv_im_get_typing_state(const Gaim2ConvIm *im);
-
- /**
- * Starts the IM's typing timeout.
-@@ -657,14 +657,14 @@ GaimTypingState gaim_conv_im_get_typing_
- * @param im The IM.
- * @param timeout The timeout.
- */
--void gaim_conv_im_start_typing_timeout(GaimConvIm *im, int timeout);
-+void gaim2_conv_im_start_typing_timeout(Gaim2ConvIm *im, int timeout);
-
- /**
- * Stops the IM's typing timeout.
- *
- * @param im The IM.
- */
--void gaim_conv_im_stop_typing_timeout(GaimConvIm *im);
-+void gaim2_conv_im_stop_typing_timeout(Gaim2ConvIm *im);
-
- /**
- * Returns the IM's typing timeout.
-@@ -673,7 +673,7 @@ void gaim_conv_im_stop_typing_timeout(Ga
- *
- * @return The timeout.
- */
--guint gaim_conv_im_get_typing_timeout(const GaimConvIm *im);
-+guint gaim2_conv_im_get_typing_timeout(const Gaim2ConvIm *im);
-
- /**
- * Sets the IM's time until it should send another typing notification.
-@@ -681,7 +681,7 @@ guint gaim_conv_im_get_typing_timeout(co
- * @param im The IM.
- * @param val The time.
- */
--void gaim_conv_im_set_type_again(GaimConvIm *im, time_t val);
-+void gaim2_conv_im_set_type_again(Gaim2ConvIm *im, time_t val);
-
- /**
- * Returns the IM's time until it should send another typing notification.
-@@ -690,21 +690,21 @@ void gaim_conv_im_set_type_again(GaimCon
- *
- * @return The time.
- */
--time_t gaim_conv_im_get_type_again(const GaimConvIm *im);
-+time_t gaim2_conv_im_get_type_again(const Gaim2ConvIm *im);
-
- /**
- * Starts the IM's type again timeout.
- *
- * @param im The IM.
- */
--void gaim_conv_im_start_type_again_timeout(GaimConvIm *im);
-+void gaim2_conv_im_start_type_again_timeout(Gaim2ConvIm *im);
-
- /**
- * Stops the IM's type again timeout.
- *
- * @param im The IM.
- */
--void gaim_conv_im_stop_type_again_timeout(GaimConvIm *im);
-+void gaim2_conv_im_stop_type_again_timeout(Gaim2ConvIm *im);
-
- /**
- * Returns the IM's type again timeout interval.
-@@ -713,14 +713,14 @@ void gaim_conv_im_stop_type_again_timeou
- *
- * @return The type again timeout interval.
- */
--guint gaim_conv_im_get_type_again_timeout(const GaimConvIm *im);
-+guint gaim2_conv_im_get_type_again_timeout(const Gaim2ConvIm *im);
-
- /**
- * Updates the visual typing notification for an IM conversation.
- *
- * @param im The IM.
- */
--void gaim_conv_im_update_typing(GaimConvIm *im);
-+void gaim2_conv_im_update_typing(Gaim2ConvIm *im);
-
- /**
- * Writes to an IM.
-@@ -731,8 +731,8 @@ void gaim_conv_im_update_typing(GaimConv
- * @param flags The message flags.
- * @param mtime The time the message was sent.
- */
--void gaim_conv_im_write(GaimConvIm *im, const char *who,
-- const char *message, GaimMessageFlags flags,
-+void gaim2_conv_im_write(Gaim2ConvIm *im, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime);
-
- /**
-@@ -741,14 +741,14 @@ void gaim_conv_im_write(GaimConvIm *im,
- * This is a helper function to find a conversation, write an error to it, and
- * raise the window. If a conversation with this user doesn't already exist,
- * the function will return FALSE and the calling function can attempt to present
-- * the error another way (gaim_notify_error, most likely)
-+ * the error another way (gaim2_notify_error, most likely)
- *
- * @param who The user this error is about
- * @param account The account this error is on
- * @param what The error
- * @return TRUE if the error was presented, else FALSE
- */
--gboolean gaim_conv_present_error(const char *who, GaimAccount *account, const char *what);
-+gboolean gaim2_conv_present_error(const char *who, Gaim2Account *account, const char *what);
-
- /**
- * Sends a message to this IM conversation.
-@@ -756,21 +756,21 @@ gboolean gaim_conv_present_error(const c
- * @param im The IM.
- * @param message The message to send.
- */
--void gaim_conv_im_send(GaimConvIm *im, const char *message);
-+void gaim2_conv_im_send(Gaim2ConvIm *im, const char *message);
-
- /**
- * Sends a message to this IM conversation with specified flags.
- *
- * @param im The IM.
- * @param message The message to send.
-- * @param flags The GaimMessageFlags flags to use in addition to GAIM_MESSAGE_SEND.
-+ * @param flags The Gaim2MessageFlags flags to use in addition to GAIM_MESSAGE_SEND.
- */
--void gaim_conv_im_send_with_flags(GaimConvIm *im, const char *message, GaimMessageFlags flags);
-+void gaim2_conv_im_send_with_flags(Gaim2ConvIm *im, const char *message, Gaim2MessageFlags flags);
-
- /**
- * Adds a smiley to the conversation's smiley tree. If this returns
-- * @c TRUE you should call gaim_conv_custom_smiley_write() one or more
-- * times, and then gaim_conv_custom_smiley_close(). If this returns
-+ * @c TRUE you should call gaim2_conv_custom_smiley_write() one or more
-+ * times, and then gaim2_conv_custom_smiley_close(). If this returns
- * @c FALSE, either the conv or smile were invalid, or the icon was
- * found in the cache. In either case, calling write or close would
- * be an error.
-@@ -781,12 +781,12 @@ void gaim_conv_im_send_with_flags(GaimCo
- * @param chksum The checksum, as a NUL terminated base64 string.
- * @param remote @c TRUE if the custom smiley is set by the remote user (buddy).
- * @return @c TRUE if an icon is expected, else FALSE. Note that
-- * it is an error to never call gaim_conv_custom_smiley_close if
-+ * it is an error to never call gaim2_conv_custom_smiley_close if
- * this function returns @c TRUE, but an error to call it if
- * @c FALSE is returned.
- */
-
--gboolean gaim_conv_custom_smiley_add(GaimConversation *conv, const char *smile,
-+gboolean gaim2_conv_custom_smiley_add(Gaim2Conversation *conv, const char *smile,
- const char *cksum_type, const char *chksum,
- gboolean remote);
-
-@@ -800,21 +800,21 @@ gboolean gaim_conv_custom_smiley_add(Gai
- * @param size The length of the data.
- */
-
--void gaim_conv_custom_smiley_write(GaimConversation *conv,
-+void gaim2_conv_custom_smiley_write(Gaim2Conversation *conv,
- const char *smile,
- const guchar *data,
- gsize size);
-
- /**
- * Close the custom smiley, all data has been written with
-- * gaim_conv_custom_smiley_write, and it is no longer valid
-+ * gaim2_conv_custom_smiley_write, and it is no longer valid
- * to call that function on that smiley.
- *
-- * @param conv The gaim conversation associated with the smiley.
-+ * @param conv The gaim2 conversation associated with the smiley.
- * @param smile The text associated with the smiley
- */
-
--void gaim_conv_custom_smiley_close(GaimConversation *conv, const char *smile);
-+void gaim2_conv_custom_smiley_close(Gaim2Conversation *conv, const char *smile);
-
- /*@}*/
-
-@@ -831,21 +831,21 @@ void gaim_conv_custom_smiley_close(GaimC
- *
- * @return The parent conversation.
- */
--GaimConversation *gaim_conv_chat_get_conversation(const GaimConvChat *chat);
-+Gaim2Conversation *gaim2_conv_chat_get_conversation(const Gaim2ConvChat *chat);
-
- /**
- * Sets the list of users in the chat room.
- *
- * @note Calling this function will not update the display of the users.
-- * Please use gaim_conv_chat_add_user(), gaim_conv_chat_add_users(),
-- * gaim_conv_chat_remove_user(), and gaim_conv_chat_remove_users() instead.
-+ * Please use gaim2_conv_chat_add_user(), gaim2_conv_chat_add_users(),
-+ * gaim2_conv_chat_remove_user(), and gaim2_conv_chat_remove_users() instead.
- *
- * @param chat The chat.
- * @param users The list of users.
- *
- * @return The list passed.
- */
--GList *gaim_conv_chat_set_users(GaimConvChat *chat, GList *users);
-+GList *gaim2_conv_chat_set_users(Gaim2ConvChat *chat, GList *users);
-
- /**
- * Returns a list of users in the chat room.
-@@ -854,7 +854,7 @@ GList *gaim_conv_chat_set_users(GaimConv
- *
- * @return The list of users.
- */
--GList *gaim_conv_chat_get_users(const GaimConvChat *chat);
-+GList *gaim2_conv_chat_get_users(const Gaim2ConvChat *chat);
-
- /**
- * Ignores a user in a chat room.
-@@ -862,7 +862,7 @@ GList *gaim_conv_chat_get_users(const Ga
- * @param chat The chat.
- * @param name The name of the user.
- */
--void gaim_conv_chat_ignore(GaimConvChat *chat, const char *name);
-+void gaim2_conv_chat_ignore(Gaim2ConvChat *chat, const char *name);
-
- /**
- * Unignores a user in a chat room.
-@@ -870,7 +870,7 @@ void gaim_conv_chat_ignore(GaimConvChat
- * @param chat The chat.
- * @param name The name of the user.
- */
--void gaim_conv_chat_unignore(GaimConvChat *chat, const char *name);
-+void gaim2_conv_chat_unignore(Gaim2ConvChat *chat, const char *name);
-
- /**
- * Sets the list of ignored users in the chat room.
-@@ -880,7 +880,7 @@ void gaim_conv_chat_unignore(GaimConvCha
- *
- * @return The list passed.
- */
--GList *gaim_conv_chat_set_ignored(GaimConvChat *chat, GList *ignored);
-+GList *gaim2_conv_chat_set_ignored(Gaim2ConvChat *chat, GList *ignored);
-
- /**
- * Returns the list of ignored users in the chat room.
-@@ -889,7 +889,7 @@ GList *gaim_conv_chat_set_ignored(GaimCo
- *
- * @return The list of ignored users.
- */
--GList *gaim_conv_chat_get_ignored(const GaimConvChat *chat);
-+GList *gaim2_conv_chat_get_ignored(const Gaim2ConvChat *chat);
-
- /**
- * Returns the actual name of the specified ignored user, if it exists in
-@@ -905,7 +905,7 @@ GList *gaim_conv_chat_get_ignored(const
- * @return The ignored user if found, complete with prefixes, or @c NULL
- * if not found.
- */
--const char *gaim_conv_chat_get_ignored_user(const GaimConvChat *chat,
-+const char *gaim2_conv_chat_get_ignored_user(const Gaim2ConvChat *chat,
- const char *user);
-
- /**
-@@ -916,7 +916,7 @@ const char *gaim_conv_chat_get_ignored_u
- *
- * @return @c TRUE if the user is in the ignore list; @c FALSE otherwise.
- */
--gboolean gaim_conv_chat_is_user_ignored(const GaimConvChat *chat,
-+gboolean gaim2_conv_chat_is_user_ignored(const Gaim2ConvChat *chat,
- const char *user);
-
- /**
-@@ -926,7 +926,7 @@ gboolean gaim_conv_chat_is_user_ignored(
- * @param who The user that set the topic.
- * @param topic The topic.
- */
--void gaim_conv_chat_set_topic(GaimConvChat *chat, const char *who,
-+void gaim2_conv_chat_set_topic(Gaim2ConvChat *chat, const char *who,
- const char *topic);
-
- /**
-@@ -936,7 +936,7 @@ void gaim_conv_chat_set_topic(GaimConvCh
- *
- * @return The chat's topic.
- */
--const char *gaim_conv_chat_get_topic(const GaimConvChat *chat);
-+const char *gaim2_conv_chat_get_topic(const Gaim2ConvChat *chat);
-
- /**
- * Sets the chat room's ID.
-@@ -944,7 +944,7 @@ const char *gaim_conv_chat_get_topic(con
- * @param chat The chat.
- * @param id The ID.
- */
--void gaim_conv_chat_set_id(GaimConvChat *chat, int id);
-+void gaim2_conv_chat_set_id(Gaim2ConvChat *chat, int id);
-
- /**
- * Returns the chat room's ID.
-@@ -953,7 +953,7 @@ void gaim_conv_chat_set_id(GaimConvChat
- *
- * @return The ID.
- */
--int gaim_conv_chat_get_id(const GaimConvChat *chat);
-+int gaim2_conv_chat_get_id(const Gaim2ConvChat *chat);
-
- /**
- * Writes to a chat.
-@@ -964,8 +964,8 @@ int gaim_conv_chat_get_id(const GaimConv
- * @param flags The flags.
- * @param mtime The time the message was sent.
- */
--void gaim_conv_chat_write(GaimConvChat *chat, const char *who,
-- const char *message, GaimMessageFlags flags,
-+void gaim2_conv_chat_write(Gaim2ConvChat *chat, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime);
-
- /**
-@@ -974,16 +974,16 @@ void gaim_conv_chat_write(GaimConvChat *
- * @param chat The chat.
- * @param message The message to send.
- */
--void gaim_conv_chat_send(GaimConvChat *chat, const char *message);
-+void gaim2_conv_chat_send(Gaim2ConvChat *chat, const char *message);
-
- /**
- * Sends a message to this chat conversation with specified flags.
- *
- * @param chat The chat.
- * @param message The message to send.
-- * @param flags The GaimMessageFlags flags to use.
-+ * @param flags The Gaim2MessageFlags flags to use.
- */
--void gaim_conv_chat_send_with_flags(GaimConvChat *chat, const char *message, GaimMessageFlags flags);
-+void gaim2_conv_chat_send_with_flags(Gaim2ConvChat *chat, const char *message, Gaim2MessageFlags flags);
-
- /**
- * Adds a user to a chat.
-@@ -994,8 +994,8 @@ void gaim_conv_chat_send_with_flags(Gaim
- * @param flags The users flags
- * @param new_arrival Decides whether or not to show a join notice.
- */
--void gaim_conv_chat_add_user(GaimConvChat *chat, const char *user,
-- const char *extra_msg, GaimConvChatBuddyFlags flags,
-+void gaim2_conv_chat_add_user(Gaim2ConvChat *chat, const char *user,
-+ const char *extra_msg, Gaim2ConvChatBuddyFlags flags,
- gboolean new_arrival);
-
- /**
-@@ -1015,7 +1015,7 @@ void gaim_conv_chat_add_user(GaimConvCha
- * @param flags The list of flags for each user.
- * @param new_arrivals Decides whether or not to show join notices.
- */
--void gaim_conv_chat_add_users(GaimConvChat *chat, GList *users, GList *extra_msgs,
-+void gaim2_conv_chat_add_users(Gaim2ConvChat *chat, GList *users, GList *extra_msgs,
- GList *flags, gboolean new_arrivals);
-
- /**
-@@ -1025,7 +1025,7 @@ void gaim_conv_chat_add_users(GaimConvCh
- * @param old_user The old username.
- * @param new_user The new username.
- */
--void gaim_conv_chat_rename_user(GaimConvChat *chat, const char *old_user,
-+void gaim2_conv_chat_rename_user(Gaim2ConvChat *chat, const char *old_user,
- const char *new_user);
-
- /**
-@@ -1037,7 +1037,7 @@ void gaim_conv_chat_rename_user(GaimConv
- * @param user The user that is being removed.
- * @param reason The optional reason given for the removal. Can be @c NULL.
- */
--void gaim_conv_chat_remove_user(GaimConvChat *chat, const char *user,
-+void gaim2_conv_chat_remove_user(Gaim2ConvChat *chat, const char *user,
- const char *reason);
-
- /**
-@@ -1047,7 +1047,7 @@ void gaim_conv_chat_remove_user(GaimConv
- * @param users The users that are being removed.
- * @param reason The optional reason given for the removal. Can be @c NULL.
- */
--void gaim_conv_chat_remove_users(GaimConvChat *chat, GList *users,
-+void gaim2_conv_chat_remove_users(Gaim2ConvChat *chat, GList *users,
- const char *reason);
-
- /**
-@@ -1058,7 +1058,7 @@ void gaim_conv_chat_remove_users(GaimCon
- *
- * @return TRUE if the user is in the chat, FALSE if not
- */
--gboolean gaim_conv_chat_find_user(GaimConvChat *chat, const char *user);
-+gboolean gaim2_conv_chat_find_user(Gaim2ConvChat *chat, const char *user);
-
- /**
- * Set a users flags in a chat
-@@ -1067,8 +1067,8 @@ gboolean gaim_conv_chat_find_user(GaimCo
- * @param user The user to update.
- * @param flags The new flags.
- */
--void gaim_conv_chat_user_set_flags(GaimConvChat *chat, const char *user,
-- GaimConvChatBuddyFlags flags);
-+void gaim2_conv_chat_user_set_flags(Gaim2ConvChat *chat, const char *user,
-+ Gaim2ConvChatBuddyFlags flags);
-
- /**
- * Get the flags for a user in a chat
-@@ -1078,7 +1078,7 @@ void gaim_conv_chat_user_set_flags(GaimC
- *
- * @return The flags for the user
- */
--GaimConvChatBuddyFlags gaim_conv_chat_user_get_flags(GaimConvChat *chat,
-+Gaim2ConvChatBuddyFlags gaim2_conv_chat_user_get_flags(Gaim2ConvChat *chat,
- const char *user);
-
- /**
-@@ -1086,7 +1086,7 @@ GaimConvChatBuddyFlags gaim_conv_chat_us
- *
- * @param chat The chat.
- */
--void gaim_conv_chat_clear_users(GaimConvChat *chat);
-+void gaim2_conv_chat_clear_users(Gaim2ConvChat *chat);
-
- /**
- * Sets your nickname (used for hilighting) for a chat.
-@@ -1094,7 +1094,7 @@ void gaim_conv_chat_clear_users(GaimConv
- * @param chat The chat.
- * @param nick The nick.
- */
--void gaim_conv_chat_set_nick(GaimConvChat *chat, const char *nick);
-+void gaim2_conv_chat_set_nick(Gaim2ConvChat *chat, const char *nick);
-
- /**
- * Gets your nickname (used for hilighting) for a chat.
-@@ -1102,17 +1102,17 @@ void gaim_conv_chat_set_nick(GaimConvCha
- * @param chat The chat.
- * @return The nick.
- */
--const char *gaim_conv_chat_get_nick(GaimConvChat *chat);
-+const char *gaim2_conv_chat_get_nick(Gaim2ConvChat *chat);
-
- /**
- * Finds a chat with the specified chat ID.
- *
-- * @param gc The gaim_connection.
-+ * @param gc The gaim2_connection.
- * @param id The chat ID.
- *
- * @return The chat conversation.
- */
--GaimConversation *gaim_find_chat(const GaimConnection *gc, int id);
-+Gaim2Conversation *gaim2_find_chat(const Gaim2Connection *gc, int id);
-
- /**
- * Lets the core know we left a chat, without destroying it.
-@@ -1120,7 +1120,7 @@ GaimConversation *gaim_find_chat(const G
- *
- * @param chat The chat.
- */
--void gaim_conv_chat_left(GaimConvChat *chat);
-+void gaim2_conv_chat_left(Gaim2ConvChat *chat);
-
- /**
- * Returns true if we're no longer in this chat,
-@@ -1131,7 +1131,7 @@ void gaim_conv_chat_left(GaimConvChat *c
- * @return @c TRUE if we left the chat already, @c FALSE if
- * we're still there.
- */
--gboolean gaim_conv_chat_has_left(GaimConvChat *chat);
-+gboolean gaim2_conv_chat_has_left(Gaim2ConvChat *chat);
-
- /**
- * Creates a new chat buddy
-@@ -1141,8 +1141,8 @@ gboolean gaim_conv_chat_has_left(GaimCon
- *
- * @return The new chat buddy
- */
--GaimConvChatBuddy *gaim_conv_chat_cb_new(const char *name,
-- GaimConvChatBuddyFlags flags);
-+Gaim2ConvChatBuddy *gaim2_conv_chat_cb_new(const char *name,
-+ Gaim2ConvChatBuddyFlags flags);
-
- /**
- * Find a chat buddy in a chat
-@@ -1150,7 +1150,7 @@ GaimConvChatBuddy *gaim_conv_chat_cb_new
- * @param chat The chat.
- * @param name The name of the chat buddy to find.
- */
--GaimConvChatBuddy *gaim_conv_chat_cb_find(GaimConvChat *chat, const char *name);
-+Gaim2ConvChatBuddy *gaim2_conv_chat_cb_find(Gaim2ConvChat *chat, const char *name);
-
- /**
- * Get the name of a chat buddy
-@@ -1159,14 +1159,14 @@ GaimConvChatBuddy *gaim_conv_chat_cb_fin
- *
- * @return The name of the chat buddy.
- */
--const char *gaim_conv_chat_cb_get_name(GaimConvChatBuddy *cb);
-+const char *gaim2_conv_chat_cb_get_name(Gaim2ConvChatBuddy *cb);
-
- /**
- * Destroys a chat buddy
- *
- * @param cb The chat buddy to destroy
- */
--void gaim_conv_chat_cb_destroy(GaimConvChatBuddy *cb);
-+void gaim2_conv_chat_cb_destroy(Gaim2ConvChatBuddy *cb);
-
- /*@}*/
-
-@@ -1180,17 +1180,17 @@ void gaim_conv_chat_cb_destroy(GaimConvC
- *
- * @return The conversation subsystem handle.
- */
--void *gaim_conversations_get_handle(void);
-+void *gaim2_conversations_get_handle(void);
-
- /**
- * Initializes the conversation subsystem.
- */
--void gaim_conversations_init(void);
-+void gaim2_conversations_init(void);
-
- /**
- * Uninitializes the conversation subsystem.
- */
--void gaim_conversations_uninit(void);
-+void gaim2_conversations_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/core.c ./src/core.c
---- ./src/core.c 2005-11-30 07:03:49.000000000 +0100
-+++ ./src/core.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file core.c Gaim Core API
-+ * @file core.c Gaim2 Core API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -48,43 +48,43 @@
- # include "dbus-server.h"
- #endif
-
--struct GaimCore
-+struct Gaim2Core
- {
- char *ui;
-
- void *reserved;
- };
-
--static GaimCoreUiOps *_ops = NULL;
--static GaimCore *_core = NULL;
-+static Gaim2CoreUiOps *_ops = NULL;
-+static Gaim2Core *_core = NULL;
-
- STATIC_PROTO_INIT
-
- gboolean
--gaim_core_init(const char *ui)
-+gaim2_core_init(const char *ui)
- {
-- GaimCoreUiOps *ops;
-- GaimCore *core;
-+ Gaim2CoreUiOps *ops;
-+ Gaim2Core *core;
-
- g_return_val_if_fail(ui != NULL, FALSE);
-- g_return_val_if_fail(gaim_get_core() == NULL, FALSE);
-+ g_return_val_if_fail(gaim2_get_core() == NULL, FALSE);
-
-- _core = core = g_new0(GaimCore, 1);
-+ _core = core = g_new0(Gaim2Core, 1);
- core->ui = g_strdup(ui);
- core->reserved = NULL;
-
-- ops = gaim_core_get_ui_ops();
-+ ops = gaim2_core_get_ui_ops();
-
- /* The signals subsystem is important and should be first. */
-- gaim_signals_init();
-+ gaim2_signals_init();
-
-- gaim_signal_register(core, "quitting", gaim_marshal_VOID, NULL, 0);
-+ gaim2_signal_register(core, "quitting", gaim2_marshal_VOID, NULL, 0);
-
- /* The prefs subsystem needs to be initialized before static protocols
- * for protocol prefs to work. */
-- gaim_prefs_init();
-+ gaim2_prefs_init();
-
-- gaim_debug_init();
-+ gaim2_debug_init();
-
- if (ops != NULL)
- {
-@@ -96,7 +96,7 @@ gaim_core_init(const char *ui)
- }
-
- #ifdef HAVE_DBUS
-- gaim_dbus_init();
-+ gaim2_dbus_init();
- #endif
-
- /* Initialize all static protocols. */
-@@ -105,31 +105,31 @@ gaim_core_init(const char *ui)
- /* Since plugins get probed so early we should probably initialize their
- * subsystem right away too.
- */
-- gaim_plugins_init();
-- gaim_plugins_probe(G_MODULE_SUFFIX);
-+ gaim2_plugins_init();
-+ gaim2_plugins_probe(G_MODULE_SUFFIX);
-
-- gaim_status_init();
-- gaim_accounts_init();
-- gaim_savedstatuses_init();
-- gaim_ciphers_init();
-- gaim_notify_init();
-- gaim_connections_init();
-- gaim_conversations_init();
-- gaim_blist_init();
-- gaim_log_init();
-- gaim_buddy_icons_init();
-+ gaim2_status_init();
-+ gaim2_accounts_init();
-+ gaim2_savedstatuses_init();
-+ gaim2_ciphers_init();
-+ gaim2_notify_init();
-+ gaim2_connections_init();
-+ gaim2_conversations_init();
-+ gaim2_blist_init();
-+ gaim2_log_init();
-+ gaim2_buddy_icons_init();
- #ifdef HAVE_VV
-- gaim_media_init();
-+ gaim2_media_init();
- #endif
-- gaim_network_init();
-- gaim_privacy_init();
-- gaim_pounces_init();
-- gaim_proxy_init();
-- gaim_sound_init();
-- gaim_ssl_init();
-- gaim_stun_init();
-- gaim_xfers_init();
-- gaim_idle_init();
-+ gaim2_network_init();
-+ gaim2_privacy_init();
-+ gaim2_pounces_init();
-+ gaim2_proxy_init();
-+ gaim2_sound_init();
-+ gaim2_ssl_init();
-+ gaim2_stun_init();
-+ gaim2_xfers_init();
-+ gaim2_idle_init();
-
- if (ops != NULL && ops->ui_init != NULL)
- ops->ui_init();
-@@ -138,44 +138,44 @@ gaim_core_init(const char *ui)
- }
-
- void
--gaim_core_quit(void)
-+gaim2_core_quit(void)
- {
-- GaimCoreUiOps *ops;
-- GaimCore *core = gaim_get_core();
-+ Gaim2CoreUiOps *ops;
-+ Gaim2Core *core = gaim2_get_core();
-
- g_return_if_fail(core != NULL);
-
- /* The self destruct sequence has been initiated */
-- gaim_signal_emit(gaim_get_core(), "quitting");
-+ gaim2_signal_emit(gaim2_get_core(), "quitting");
-
- /* Transmission ends */
-- gaim_connections_disconnect_all();
-+ gaim2_connections_disconnect_all();
-
- /* Save .xml files, remove signals, etc. */
-- gaim_idle_uninit();
-- gaim_ssl_uninit();
-- gaim_pounces_uninit();
-- gaim_blist_uninit();
-- gaim_ciphers_uninit();
-- gaim_notify_uninit();
-- gaim_conversations_uninit();
-- gaim_connections_uninit();
-- gaim_buddy_icons_uninit();
-- gaim_accounts_uninit();
-- gaim_savedstatuses_uninit();
-- gaim_status_uninit();
-- gaim_prefs_uninit();
-- gaim_xfers_uninit();
-+ gaim2_idle_uninit();
-+ gaim2_ssl_uninit();
-+ gaim2_pounces_uninit();
-+ gaim2_blist_uninit();
-+ gaim2_ciphers_uninit();
-+ gaim2_notify_uninit();
-+ gaim2_conversations_uninit();
-+ gaim2_connections_uninit();
-+ gaim2_buddy_icons_uninit();
-+ gaim2_accounts_uninit();
-+ gaim2_savedstatuses_uninit();
-+ gaim2_status_uninit();
-+ gaim2_prefs_uninit();
-+ gaim2_xfers_uninit();
-
-- gaim_debug_info("main", "Unloading all plugins\n");
-- gaim_plugins_destroy_all();
-+ gaim2_debug_info("main", "Unloading all plugins\n");
-+ gaim2_plugins_destroy_all();
-
-- ops = gaim_core_get_ui_ops();
-+ ops = gaim2_core_get_ui_ops();
- if (ops != NULL && ops->quit != NULL)
- ops->quit();
-
- /*
-- * gaim_sound_uninit() should be called as close to
-+ * gaim2_sound_uninit() should be called as close to
- * shutdown as possible. This is because the call
- * to ao_shutdown() can sometimes leave our
- * environment variables in an unusable state, which
-@@ -185,10 +185,10 @@ gaim_core_quit(void)
- *
- * TODO: Eventually move this call higher up with the others.
- */
-- gaim_sound_uninit();
-+ gaim2_sound_uninit();
-
-- gaim_plugins_uninit();
-- gaim_signals_uninit();
-+ gaim2_plugins_uninit();
-+ gaim2_signals_uninit();
-
- if (core->ui != NULL) {
- g_free(core->ui);
-@@ -201,43 +201,43 @@ gaim_core_quit(void)
- }
-
- gboolean
--gaim_core_quit_cb(gpointer unused)
-+gaim2_core_quit_cb(gpointer unused)
- {
-- gaim_core_quit();
-+ gaim2_core_quit();
-
- return FALSE;
- }
-
- const char *
--gaim_core_get_version(void)
-+gaim2_core_get_version(void)
- {
- return VERSION;
- }
-
- const char *
--gaim_core_get_ui(void)
-+gaim2_core_get_ui(void)
- {
-- GaimCore *core = gaim_get_core();
-+ Gaim2Core *core = gaim2_get_core();
-
- g_return_val_if_fail(core != NULL, NULL);
-
- return core->ui;
- }
-
--GaimCore *
--gaim_get_core(void)
-+Gaim2Core *
-+gaim2_get_core(void)
- {
- return _core;
- }
-
- void
--gaim_core_set_ui_ops(GaimCoreUiOps *ops)
-+gaim2_core_set_ui_ops(Gaim2CoreUiOps *ops)
- {
- _ops = ops;
- }
-
--GaimCoreUiOps *
--gaim_core_get_ui_ops(void)
-+Gaim2CoreUiOps *
-+gaim2_core_get_ui_ops(void)
- {
- return _ops;
- }
-diff -prNu ./src/core.h ./src/core.h
---- ./src/core.h 2005-12-06 04:46:25.000000000 +0100
-+++ ./src/core.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
-- * @defgroup core Gaim Core
-+ * @defgroup core Gaim2 Core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- #ifndef _GAIM_CORE_H_
- #define _GAIM_CORE_H_
-
--typedef struct GaimCore GaimCore;
-+typedef struct Gaim2Core Gaim2Core;
-
- typedef struct
- {
-@@ -33,78 +33,78 @@ typedef struct
- void (*ui_init)(void);
- void (*quit)(void);
-
--} GaimCoreUiOps;
-+} Gaim2CoreUiOps;
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- /**
-- * Initializes the core of gaim.
-+ * Initializes the core of gaim2.
- *
- * This will setup preferences for all the core subsystems.
- *
- * @param ui The ID of the UI using the core. This should be a
-- * unique ID, registered with the gaim team.
-+ * unique ID, registered with the gaim2 team.
- *
- * @return @c TRUE if successful, or @c FALSE otherwise.
- */
--gboolean gaim_core_init(const char *ui);
-+gboolean gaim2_core_init(const char *ui);
-
- /**
-- * Quits the core of gaim, which, depending on the UI, may quit the
-- * application using the gaim core.
-+ * Quits the core of gaim2, which, depending on the UI, may quit the
-+ * application using the gaim2 core.
- */
--void gaim_core_quit(void);
-+void gaim2_core_quit(void);
-
- /**
-- * Calls gaim_core_quit(). This can be used as the function
-- * passed to gaim_timeout_add() when you want to shutdown Gaim
-- * in a specified amount of time. When shutting down Gaim
-+ * Calls gaim2_core_quit(). This can be used as the function
-+ * passed to gaim2_timeout_add() when you want to shutdown Gaim2
-+ * in a specified amount of time. When shutting down Gaim2
- * from a plugin, you must use this with a timeout value of 0:
-- * gaim_timeout_add(0, gaim_core_quitcb, NULL);
-+ * gaim2_timeout_add(0, gaim2_core_quitcb, NULL);
- * This is ensures that code from your plugin is not being
-- * executed when gaim_core_quit() is called. Otherwise you
-- * would get a core dump after gaim_core_quit() executes and
-- * control returns to your plugin because gaim_core_quit() frees
-+ * executed when gaim2_core_quit() is called. Otherwise you
-+ * would get a core dump after gaim2_core_quit() executes and
-+ * control returns to your plugin because gaim2_core_quit() frees
- * all plugins.
- */
--gboolean gaim_core_quit_cb(gpointer unused);
-+gboolean gaim2_core_quit_cb(gpointer unused);
-
- /**
- * Returns the version of the core library.
- *
- * @return The version of the core library.
- */
--const char *gaim_core_get_version(void);
-+const char *gaim2_core_get_version(void);
-
- /**
- * Returns the ID of the UI that is using the core.
- *
- * @return The ID of the UI that is currently using the core.
- */
--const char *gaim_core_get_ui(void);
-+const char *gaim2_core_get_ui(void);
-
- /**
-- * Returns a handle to the gaim core.
-+ * Returns a handle to the gaim2 core.
- *
- * This is used for such things as signals.
- */
--GaimCore *gaim_get_core(void);
-+Gaim2Core *gaim2_get_core(void);
-
- /**
- * Sets the UI ops for the core.
- *
- * @param ops A UI ops structure for the core.
- */
--void gaim_core_set_ui_ops(GaimCoreUiOps *ops);
-+void gaim2_core_set_ui_ops(Gaim2CoreUiOps *ops);
-
- /**
- * Returns the UI ops for the core.
- *
- * @return The core's UI ops structure.
- */
--GaimCoreUiOps *gaim_core_get_ui_ops(void);
-+Gaim2CoreUiOps *gaim2_core_get_ui_ops(void);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/.cvsignore ./src/.cvsignore
---- ./src/.cvsignore 2005-12-21 01:08:21.000000000 +0100
-+++ ./src/.cvsignore 2006-01-05 13:38:38.000000000 +0100
-@@ -5,7 +5,7 @@ Makefile
- dbus-bindings.c
- dbus-server-bindings.c
- dbus-types.*
--gaim
-+gaim2
- gaim.def
- gaim.lib
- gaim.dll
-diff -prNu ./src/dbus-bindings.h ./src/dbus-bindings.h
---- ./src/dbus-bindings.h 2005-10-29 04:06:36.000000000 +0200
-+++ ./src/dbus-bindings.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file dbus-bindings.h Gaim DBUS Bindings
-+ * @file dbus-bindings.h Gaim2 DBUS Bindings
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,10 +35,10 @@
- extern "C" {
- #endif
-
--gint gaim_dbus_pointer_to_id(gpointer node);
--gpointer gaim_dbus_id_to_pointer(gint id, GaimDBusType *type);
--gint gaim_dbus_pointer_to_id_error(gpointer ptr, DBusError *error);
--gpointer gaim_dbus_id_to_pointer_error(gint id, GaimDBusType *type,
-+gint gaim2_dbus_pointer_to_id(gpointer node);
-+gpointer gaim2_dbus_id_to_pointer(gint id, Gaim2DBusType *type);
-+gint gaim2_dbus_pointer_to_id_error(gpointer ptr, DBusError *error);
-+gpointer gaim2_dbus_id_to_pointer_error(gint id, Gaim2DBusType *type,
- const char *typename, DBusError *error);
-
- #define NULLIFY(id) id = empty_to_null(id)
-@@ -47,7 +47,7 @@ gpointer gaim_dbus_id_to_pointer_error(g
-
- #define GAIM_DBUS_ID_TO_POINTER(ptr, id, type, error) \
- G_STMT_START { \
-- ptr = (type*) gaim_dbus_id_to_pointer_error \
-+ ptr = (type*) gaim2_dbus_id_to_pointer_error \
- (id, GAIM_DBUS_TYPE(type), #type, error); \
- CHECK_ERROR(error); \
- } G_STMT_END
-@@ -55,43 +55,43 @@ gpointer gaim_dbus_id_to_pointer_error(g
-
- #define GAIM_DBUS_POINTER_TO_ID(id, ptr, error) \
- G_STMT_START { \
-- id = gaim_dbus_pointer_to_id_error(ptr,error); \
-+ id = gaim2_dbus_pointer_to_id_error(ptr,error); \
- CHECK_ERROR(error); \
- } G_STMT_END
-
-
- dbus_bool_t
--gaim_dbus_message_get_args (DBusMessage *message,
-+gaim2_dbus_message_get_args (DBusMessage *message,
- DBusError *error,
- int first_arg_type,
- ...);
- dbus_bool_t
--gaim_dbus_message_get_args_valist (DBusMessage *message,
-+gaim2_dbus_message_get_args_valist (DBusMessage *message,
- DBusError *error,
- int first_arg_type,
- va_list var_args);
-
- dbus_bool_t
--gaim_dbus_message_iter_get_args (DBusMessageIter *iter,
-+gaim2_dbus_message_iter_get_args (DBusMessageIter *iter,
- DBusError *error,
- int first_arg_type,
- ...);
-
- dbus_bool_t
--gaim_dbus_message_iter_get_args_valist (DBusMessageIter *iter,
-+gaim2_dbus_message_iter_get_args_valist (DBusMessageIter *iter,
- DBusError *error,
- int first_arg_type,
- va_list var_args);
-
--dbus_int32_t* gaim_dbusify_GList(GList *list, gboolean free_memory,
-+dbus_int32_t* gaim2_dbusify_GList(GList *list, gboolean free_memory,
- dbus_int32_t *len);
--dbus_int32_t* gaim_dbusify_GSList(GSList *list, gboolean free_memory,
-+dbus_int32_t* gaim2_dbusify_GSList(GSList *list, gboolean free_memory,
- dbus_int32_t *len);
--gpointer* gaim_GList_to_array(GList *list, gboolean free_memory,
-+gpointer* gaim2_GList_to_array(GList *list, gboolean free_memory,
- dbus_int32_t *len);
--gpointer* gaim_GSList_to_array(GSList *list, gboolean free_memory,
-+gpointer* gaim2_GSList_to_array(GSList *list, gboolean free_memory,
- dbus_int32_t *len);
--GHashTable *gaim_dbus_iter_hash_table(DBusMessageIter *iter, DBusError *error);
-+GHashTable *gaim2_dbus_iter_hash_table(DBusMessageIter *iter, DBusError *error);
-
- const char* empty_to_null(const char *str);
- const char* null_to_empty(const char *s);
-@@ -100,11 +100,11 @@ typedef struct {
- const char *name;
- const char *parameters;
- DBusMessage* (*handler)(DBusMessage *request, DBusError *error);
--} GaimDBusBinding;
-+} Gaim2DBusBinding;
-
--void gaim_dbus_register_bindings(void *handle, GaimDBusBinding *bindings);
-+void gaim2_dbus_register_bindings(void *handle, Gaim2DBusBinding *bindings);
-
--DBusConnection *gaim_dbus_get_connection(void);
-+DBusConnection *gaim2_dbus_get_connection(void);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/dbus-define-api.h ./src/dbus-define-api.h
---- ./src/dbus-define-api.h 2005-07-22 21:47:29.000000000 +0200
-+++ ./src/dbus-define-api.h 2006-01-05 15:11:20.000000000 +0100
-@@ -6,20 +6,20 @@
- program, which makes these macros callable by DBUS. */
-
- /* blist.h */
--gboolean GAIM_BLIST_NODE_IS_CHAT(GaimBlistNode *node);
--gboolean GAIM_BLIST_NODE_IS_BUDDY(GaimBlistNode *node);
--gboolean GAIM_BLIST_NODE_IS_CONTACT(GaimBlistNode *node);
--gboolean GAIM_BLIST_NODE_IS_GROUP(GaimBlistNode *node);
--gboolean GAIM_BUDDY_IS_ONLINE(GaimBuddy *buddy);
--gboolean GAIM_BLIST_NODE_HAS_FLAG(GaimBlistNode *node, int flags);
--gboolean GAIM_BLIST_NODE_SHOULD_SAVE(GaimBlistNode *node);
-+gboolean GAIM_BLIST_NODE_IS_CHAT(Gaim2BlistNode *node);
-+gboolean GAIM_BLIST_NODE_IS_BUDDY(Gaim2BlistNode *node);
-+gboolean GAIM_BLIST_NODE_IS_CONTACT(Gaim2BlistNode *node);
-+gboolean GAIM_BLIST_NODE_IS_GROUP(Gaim2BlistNode *node);
-+gboolean GAIM_BUDDY_IS_ONLINE(Gaim2Buddy *buddy);
-+gboolean GAIM_BLIST_NODE_HAS_FLAG(Gaim2BlistNode *node, int flags);
-+gboolean GAIM_BLIST_NODE_SHOULD_SAVE(Gaim2BlistNode *node);
-
- /* connection.h */
--gboolean GAIM_CONNECTION_IS_CONNECTED(GaimConnection *connection);
--gboolean GAIM_CONNECTION_IS_VALID(GaimConnection *connection);
-+gboolean GAIM_CONNECTION_IS_CONNECTED(Gaim2Connection *connection);
-+gboolean GAIM_CONNECTION_IS_VALID(Gaim2Connection *connection);
-
- /* conversation.h */
--GaimConvIm *GAIM_CONV_IM(const GaimConversation *conversation);
--GaimConvIm *GAIM_CONV_CHAT(const GaimConversation *conversation);
-+Gaim2ConvIm *GAIM_CONV_IM(const Gaim2Conversation *conversation);
-+Gaim2ConvIm *GAIM_CONV_CHAT(const Gaim2Conversation *conversation);
-
-
-diff -prNu ./src/dbus-gaim.h ./src/dbus-gaim.h
---- ./src/dbus-gaim.h 2005-07-03 23:48:55.000000000 +0200
-+++ ./src/dbus-gaim.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,8 +24,8 @@
- #ifndef _DBUS_GAIM_H_
- #define _DBUS_GAIM_H_
-
--#define DBUS_SERVICE_GAIM "org.gaim.GaimService"
--#define DBUS_PATH_GAIM "/org/gaim/GaimObject"
--#define DBUS_INTERFACE_GAIM "org.gaim.GaimInterface"
-+#define DBUS_SERVICE_GAIM "org.gaim2.Gaim2Service"
-+#define DBUS_PATH_GAIM "/org/gaim2/Gaim2Object"
-+#define DBUS_INTERFACE_GAIM "org.gaim2.Gaim2Interface"
-
- #endif /* _DBUS_GAIM_H_ */
-diff -prNu ./src/dbus-maybe.h ./src/dbus-maybe.h
---- ./src/dbus-maybe.h 2005-07-30 02:23:20.000000000 +0200
-+++ ./src/dbus-maybe.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,4 +1,4 @@
--/* This file contains macros that wrap calls to the gaim dbus module.
-+/* This file contains macros that wrap calls to the gaim2 dbus module.
- These macros call the appropriate functions if the build includes
- dbus support and do nothing otherwise. See "dbus-server.h" for
- documentation. */
-@@ -13,9 +13,9 @@
- /* this provides a type check */
- #define GAIM_DBUS_REGISTER_POINTER(ptr, type) { \
- type *typed_ptr = ptr; \
-- gaim_dbus_register_pointer(typed_ptr, GAIM_DBUS_TYPE(type)); \
-+ gaim2_dbus_register_pointer(typed_ptr, GAIM_DBUS_TYPE(type)); \
- }
--#define GAIM_DBUS_UNREGISTER_POINTER(ptr) gaim_dbus_unregister_pointer(ptr)
-+#define GAIM_DBUS_UNREGISTER_POINTER(ptr) gaim2_dbus_unregister_pointer(ptr)
-
- #else /* !HAVE_DBUS */
-
-diff -prNu ./src/dbus-server.c ./src/dbus-server.c
---- ./src/dbus-server.c 2005-12-22 19:28:08.000000000 +0100
-+++ ./src/dbus-server.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,7 +30,7 @@
- #include "account.h"
- #include "blist.h"
- #include "conversation.h"
--#include "dbus-gaim.h"
-+#include "dbus-gaim2.h"
- #include "dbus-server.h"
- #include "dbus-useful.h"
- #include "dbus-bindings.h"
-@@ -40,12 +40,12 @@
-
-
- /**************************************************************************/
--/** @name Gaim DBUS pointer registration mechanism */
-+/** @name Gaim2 DBUS pointer registration mechanism */
- /**************************************************************************/
-
- /*
- Here we include the list of #GAIM_DBUS_DEFINE_TYPE statements for
-- all structs defined in gaim. This file has been generated by the
-+ all structs defined in gaim2. This file has been generated by the
- #dbus-analize-types.py script.
- */
-
-@@ -62,18 +62,18 @@ static GHashTable *map_id_type;
- /* This function initializes the pointer-id traslation system. It
- creates the three above hashtables and defines parents of some types.
- */
--void gaim_dbus_init_ids(void) {
-+void gaim2_dbus_init_ids(void) {
- map_id_node = g_hash_table_new (g_direct_hash, g_direct_equal);
- map_id_type = g_hash_table_new (g_direct_hash, g_direct_equal);
- map_node_id = g_hash_table_new (g_direct_hash, g_direct_equal);
-
-- GAIM_DBUS_TYPE(GaimBuddy)->parent = GAIM_DBUS_TYPE(GaimBlistNode);
-- GAIM_DBUS_TYPE(GaimContact)->parent = GAIM_DBUS_TYPE(GaimBlistNode);
-- GAIM_DBUS_TYPE(GaimChat)->parent = GAIM_DBUS_TYPE(GaimBlistNode);
-- GAIM_DBUS_TYPE(GaimGroup)->parent = GAIM_DBUS_TYPE(GaimBlistNode);
-+ GAIM_DBUS_TYPE(Gaim2Buddy)->parent = GAIM_DBUS_TYPE(Gaim2BlistNode);
-+ GAIM_DBUS_TYPE(Gaim2Contact)->parent = GAIM_DBUS_TYPE(Gaim2BlistNode);
-+ GAIM_DBUS_TYPE(Gaim2Chat)->parent = GAIM_DBUS_TYPE(Gaim2BlistNode);
-+ GAIM_DBUS_TYPE(Gaim2Group)->parent = GAIM_DBUS_TYPE(Gaim2BlistNode);
- }
-
--void gaim_dbus_register_pointer(gpointer node, GaimDBusType *type)
-+void gaim2_dbus_register_pointer(gpointer node, Gaim2DBusType *type)
- {
- static gint last_id = 0;
-
-@@ -86,7 +86,7 @@ void gaim_dbus_register_pointer(gpointer
- g_hash_table_insert(map_id_type, GINT_TO_POINTER(last_id), type);
- }
-
--void gaim_dbus_unregister_pointer(gpointer node) {
-+void gaim2_dbus_unregister_pointer(gpointer node) {
- gpointer id = g_hash_table_lookup(map_node_id, node);
-
- g_hash_table_remove(map_node_id, node);
-@@ -94,15 +94,15 @@ void gaim_dbus_unregister_pointer(gpoint
- g_hash_table_remove(map_id_type, GINT_TO_POINTER(id));
- }
-
--gint gaim_dbus_pointer_to_id(gpointer node) {
-+gint gaim2_dbus_pointer_to_id(gpointer node) {
- gint id = GPOINTER_TO_INT(g_hash_table_lookup(map_node_id, node));
- g_return_val_if_fail(id || node == NULL, 0);
- return id;
- }
-
--gpointer gaim_dbus_id_to_pointer(gint id, GaimDBusType *type) {
-- GaimDBusType *objtype =
-- (GaimDBusType*) g_hash_table_lookup(map_id_type,
-+gpointer gaim2_dbus_id_to_pointer(gint id, Gaim2DBusType *type) {
-+ Gaim2DBusType *objtype =
-+ (Gaim2DBusType*) g_hash_table_lookup(map_id_type,
- GINT_TO_POINTER(id));
-
- while (objtype != type && objtype != NULL)
-@@ -114,24 +114,24 @@ gpointer gaim_dbus_id_to_pointer(gint id
- return NULL;
- }
-
--gint gaim_dbus_pointer_to_id_error(gpointer ptr, DBusError *error)
-+gint gaim2_dbus_pointer_to_id_error(gpointer ptr, DBusError *error)
- {
-- gint id = gaim_dbus_pointer_to_id(ptr);
-+ gint id = gaim2_dbus_pointer_to_id(ptr);
-
- if (ptr != NULL && id == 0)
-- dbus_set_error(error, "org.gaim.ObjectNotFound",
-- "The return object is not mapped (this is a Gaim error)");
-+ dbus_set_error(error, "org.gaim2.ObjectNotFound",
-+ "The return object is not mapped (this is a Gaim2 error)");
-
- return id;
- }
-
--gpointer gaim_dbus_id_to_pointer_error(gint id, GaimDBusType *type,
-+gpointer gaim2_dbus_id_to_pointer_error(gint id, Gaim2DBusType *type,
- const char *typename, DBusError *error)
- {
-- gpointer ptr = gaim_dbus_id_to_pointer(id, type);
-+ gpointer ptr = gaim2_dbus_id_to_pointer(id, type);
-
- if (ptr == NULL && id != 0)
-- dbus_set_error(error, "org.gaim.InvalidHandle",
-+ dbus_set_error(error, "org.gaim2.InvalidHandle",
- "%s object with ID = %i not found", typename, id);
-
- return ptr;
-@@ -143,7 +143,7 @@ gpointer gaim_dbus_id_to_pointer_error(g
- /**************************************************************************/
-
- dbus_bool_t
--gaim_dbus_message_get_args (DBusMessage *message,
-+gaim2_dbus_message_get_args (DBusMessage *message,
- DBusError *error,
- int first_arg_type,
- ...)
-@@ -152,14 +152,14 @@ gaim_dbus_message_get_args (DBusMessage
- va_list var_args;
-
- va_start (var_args, first_arg_type);
-- retval = gaim_dbus_message_get_args_valist (message, error, first_arg_type, var_args);
-+ retval = gaim2_dbus_message_get_args_valist (message, error, first_arg_type, var_args);
- va_end (var_args);
-
- return retval;
- }
-
- dbus_bool_t
--gaim_dbus_message_get_args_valist (DBusMessage *message,
-+gaim2_dbus_message_get_args_valist (DBusMessage *message,
- DBusError *error,
- int first_arg_type,
- va_list var_args)
-@@ -167,11 +167,11 @@ gaim_dbus_message_get_args_valist (DBusM
- DBusMessageIter iter;
-
- dbus_message_iter_init (message, &iter);
-- return gaim_dbus_message_iter_get_args_valist (&iter, error, first_arg_type, var_args);
-+ return gaim2_dbus_message_iter_get_args_valist (&iter, error, first_arg_type, var_args);
- }
-
- dbus_bool_t
--gaim_dbus_message_iter_get_args(DBusMessageIter *iter,
-+gaim2_dbus_message_iter_get_args(DBusMessageIter *iter,
- DBusError *error,
- int first_arg_type,
- ...)
-@@ -180,7 +180,7 @@ gaim_dbus_message_iter_get_args(DBusMess
- va_list var_args;
-
- va_start (var_args, first_arg_type);
-- retval = gaim_dbus_message_iter_get_args_valist(iter, error, first_arg_type, var_args);
-+ retval = gaim2_dbus_message_iter_get_args_valist(iter, error, first_arg_type, var_args);
- va_end (var_args);
-
- return retval;
-@@ -194,7 +194,7 @@ gaim_dbus_message_iter_get_args(DBusMess
-
-
- dbus_bool_t
--gaim_dbus_message_iter_get_args_valist (DBusMessageIter *iter,
-+gaim2_dbus_message_iter_get_args_valist (DBusMessageIter *iter,
- DBusError *error,
- int first_arg_type,
- va_list var_args)
-@@ -257,7 +257,7 @@ const char* null_to_empty(const char *s)
- return "";
- }
-
--dbus_int32_t* gaim_dbusify_GList(GList *list, gboolean free_memory,
-+dbus_int32_t* gaim2_dbusify_GList(GList *list, gboolean free_memory,
- dbus_int32_t *len)
- {
- dbus_int32_t *array;
-@@ -267,7 +267,7 @@ dbus_int32_t* gaim_dbusify_GList(GList *
- *len = g_list_length(list);
- array = g_new0(dbus_int32_t, g_list_length(list));
- for(i = 0, elem = list; elem != NULL; elem = elem->next, i++)
-- array[i] = gaim_dbus_pointer_to_id(elem->data);
-+ array[i] = gaim2_dbus_pointer_to_id(elem->data);
-
- if (free_memory)
- g_list_free(list);
-@@ -275,7 +275,7 @@ dbus_int32_t* gaim_dbusify_GList(GList *
- return array;
- }
-
--dbus_int32_t* gaim_dbusify_GSList(GSList *list, gboolean free_memory,
-+dbus_int32_t* gaim2_dbusify_GSList(GSList *list, gboolean free_memory,
- dbus_int32_t *len)
- {
- dbus_int32_t *array;
-@@ -285,7 +285,7 @@ dbus_int32_t* gaim_dbusify_GSList(GSList
- *len = g_slist_length(list);
- array = g_new0(dbus_int32_t, g_slist_length(list));
- for(i = 0, elem = list; elem != NULL; elem = elem->next, i++)
-- array[i] = gaim_dbus_pointer_to_id(elem->data);
-+ array[i] = gaim2_dbus_pointer_to_id(elem->data);
-
- if (free_memory)
- g_slist_free(list);
-@@ -293,7 +293,7 @@ dbus_int32_t* gaim_dbusify_GSList(GSList
- return array;
- }
-
--gpointer* gaim_GList_to_array(GList *list, gboolean free_memory,
-+gpointer* gaim2_GList_to_array(GList *list, gboolean free_memory,
- dbus_int32_t *len)
- {
- gpointer *array;
-@@ -311,7 +311,7 @@ gpointer* gaim_GList_to_array(GList *lis
- return array;
- }
-
--gpointer* gaim_GSList_to_array(GSList *list, gboolean free_memory,
-+gpointer* gaim2_GSList_to_array(GSList *list, gboolean free_memory,
- dbus_int32_t *len)
- {
- gpointer *array;
-@@ -329,7 +329,7 @@ gpointer* gaim_GSList_to_array(GSList *l
- return array;
- }
-
--GHashTable *gaim_dbus_iter_hash_table(DBusMessageIter *iter, DBusError *error) {
-+GHashTable *gaim2_dbus_iter_hash_table(DBusMessageIter *iter, DBusError *error) {
- GHashTable *hash;
-
- /* we do not need to destroy strings because they are part of the message */
-@@ -349,7 +349,7 @@ GHashTable *gaim_dbus_iter_hash_table(DB
- for exceptional situations. */
-
- dbus_message_iter_recurse(iter, &subiter);
-- if (!gaim_dbus_message_iter_get_args(&subiter, error,
-+ if (!gaim2_dbus_message_iter_get_args(&subiter, error,
- DBUS_TYPE_STRING, &key,
- DBUS_TYPE_STRING, &value,
- DBUS_TYPE_INVALID))
-@@ -369,30 +369,30 @@ GHashTable *gaim_dbus_iter_hash_table(DB
- /* DBus bindings ... */
- /**************************************************************/
-
--static DBusConnection *gaim_dbus_connection;
-+static DBusConnection *gaim2_dbus_connection;
-
--DBusConnection *gaim_dbus_get_connection(void) {
-- return gaim_dbus_connection;
-+DBusConnection *gaim2_dbus_get_connection(void) {
-+ return gaim2_dbus_connection;
- }
-
- #include "dbus-bindings.c"
-
--void *gaim_dbus_get_handle(void) {
-+void *gaim2_dbus_get_handle(void) {
- static int handle;
-
- return &handle;
- }
-
- static gboolean
--gaim_dbus_dispatch_cb(DBusConnection *connection,
-+gaim2_dbus_dispatch_cb(DBusConnection *connection,
- DBusMessage *message,
- void *user_data)
- {
- const char *name;
-- GaimDBusBinding *bindings;
-+ Gaim2DBusBinding *bindings;
- int i;
-
-- bindings = (GaimDBusBinding*) user_data;
-+ bindings = (Gaim2DBusBinding*) user_data;
-
- if (!dbus_message_has_path(message, DBUS_PATH_GAIM))
- return FALSE;
-@@ -438,11 +438,11 @@ static const char *gettext(const char **
- }
-
- static void
--gaim_dbus_introspect_cb(GList **bindings_list, void *bindings) {
-+gaim2_dbus_introspect_cb(GList **bindings_list, void *bindings) {
- *bindings_list = g_list_prepend(*bindings_list, bindings);
- }
-
--static DBusMessage *gaim_dbus_introspect(DBusMessage *message)
-+static DBusMessage *gaim2_dbus_introspect(DBusMessage *message)
- {
- DBusMessage *reply;
- GString *str;
-@@ -455,13 +455,13 @@ static DBusMessage *gaim_dbus_introspect
- g_string_append_printf(str, "<interface name='%s'>\n", DBUS_INTERFACE_GAIM);
-
- bindings_list = NULL;
-- gaim_signal_emit(gaim_dbus_get_handle(), "dbus-introspect", &bindings_list);
-+ gaim2_signal_emit(gaim2_dbus_get_handle(), "dbus-introspect", &bindings_list);
-
- for(node = bindings_list; node; node = node->next) {
-- GaimDBusBinding *bindings;
-+ Gaim2DBusBinding *bindings;
- int i;
-
-- bindings = (GaimDBusBinding*) node->data;
-+ bindings = (Gaim2DBusBinding*) node->data;
-
- for(i=0; bindings[i].name; i++) {
- const char *text;
-@@ -496,11 +496,11 @@ static DBusMessage *gaim_dbus_introspect
-
- }
-
--static DBusHandlerResult gaim_dbus_dispatch(DBusConnection *connection,
-+static DBusHandlerResult gaim2_dbus_dispatch(DBusConnection *connection,
- DBusMessage *message,
- void *user_data)
- {
-- if (gaim_signal_emit_return_1(gaim_dbus_get_handle(),
-+ if (gaim2_signal_emit_return_1(gaim2_dbus_get_handle(),
- "dbus-method-called",
- connection, message))
- return DBUS_HANDLER_RESULT_HANDLED;
-@@ -511,7 +511,7 @@ static DBusHandlerResult gaim_dbus_dispa
- dbus_message_has_member(message, "Introspect"))
- {
- DBusMessage *reply;
-- reply = gaim_dbus_introspect(message);
-+ reply = gaim2_dbus_introspect(message);
- dbus_connection_send (connection, reply, NULL);
- dbus_message_unref(reply);
- return DBUS_HANDLER_RESULT_HANDLED;
-@@ -520,70 +520,70 @@ static DBusHandlerResult gaim_dbus_dispa
- return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
- }
-
--void gaim_dbus_register_bindings(void *handle, GaimDBusBinding *bindings) {
-- gaim_signal_connect(gaim_dbus_get_handle(), "dbus-method-called",
-+void gaim2_dbus_register_bindings(void *handle, Gaim2DBusBinding *bindings) {
-+ gaim2_signal_connect(gaim2_dbus_get_handle(), "dbus-method-called",
- handle,
-- GAIM_CALLBACK(gaim_dbus_dispatch_cb),
-+ GAIM_CALLBACK(gaim2_dbus_dispatch_cb),
- bindings);
-- gaim_signal_connect(gaim_dbus_get_handle(), "dbus-introspect",
-+ gaim2_signal_connect(gaim2_dbus_get_handle(), "dbus-introspect",
- handle,
-- GAIM_CALLBACK(gaim_dbus_introspect_cb),
-+ GAIM_CALLBACK(gaim2_dbus_introspect_cb),
- bindings);
- }
-
-
-
--static gboolean gaim_dbus_dispatch_init(void)
-+static gboolean gaim2_dbus_dispatch_init(void)
- {
-- static DBusObjectPathVTable vtable = {NULL, &gaim_dbus_dispatch, NULL, NULL, NULL, NULL};
-+ static DBusObjectPathVTable vtable = {NULL, &gaim2_dbus_dispatch, NULL, NULL, NULL, NULL};
-
- DBusError error;
- int result;
-
- dbus_error_init (&error);
-- gaim_dbus_connection = dbus_bus_get (DBUS_BUS_STARTER, &error);
-+ gaim2_dbus_connection = dbus_bus_get (DBUS_BUS_STARTER, &error);
-
-- if (gaim_dbus_connection == NULL) {
-- gaim_debug_error("dbus", "Failed to get connection\n");
-+ if (gaim2_dbus_connection == NULL) {
-+ gaim2_debug_error("dbus", "Failed to get connection\n");
- dbus_error_free(&error);
- return FALSE;
- }
-
-- if (!dbus_connection_register_object_path (gaim_dbus_connection,
-+ if (!dbus_connection_register_object_path (gaim2_dbus_connection,
- DBUS_PATH_GAIM, &vtable, NULL))
- {
-- gaim_debug_error("dbus", "Failed to get name: %s\n", error.name);
-+ gaim2_debug_error("dbus", "Failed to get name: %s\n", error.name);
- dbus_error_free(&error);
- return FALSE;
- }
-
-
-- result = dbus_bus_request_name (gaim_dbus_connection, DBUS_SERVICE_GAIM,
-+ result = dbus_bus_request_name (gaim2_dbus_connection, DBUS_SERVICE_GAIM,
- 0, &error);
-
- if (dbus_error_is_set (&error)) {
-- dbus_connection_unref(gaim_dbus_connection);
-+ dbus_connection_unref(gaim2_dbus_connection);
- dbus_error_free(&error);
-- gaim_dbus_connection = NULL;
-- gaim_debug_error("dbus", "Failed to get serv name: %s\n", error.name);
-+ gaim2_dbus_connection = NULL;
-+ gaim2_debug_error("dbus", "Failed to get serv name: %s\n", error.name);
- return FALSE;
- }
-
-- dbus_connection_setup_with_g_main(gaim_dbus_connection, NULL);
-+ dbus_connection_setup_with_g_main(gaim2_dbus_connection, NULL);
-
-- gaim_debug_misc ("dbus", "okkk\n");
-+ gaim2_debug_misc ("dbus", "okkk\n");
-
-- gaim_signal_register(gaim_dbus_get_handle(), "dbus-method-called",
-- gaim_marshal_BOOLEAN__POINTER_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 2,
-- gaim_value_new(GAIM_TYPE_POINTER),
-- gaim_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(gaim2_dbus_get_handle(), "dbus-method-called",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 2,
-+ gaim2_value_new(GAIM_TYPE_POINTER),
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-
-- gaim_signal_register(gaim_dbus_get_handle(), "dbus-introspect",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new_outgoing(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(gaim2_dbus_get_handle(), "dbus-introspect",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new_outgoing(GAIM_TYPE_POINTER));
-
-- GAIM_DBUS_REGISTER_BINDINGS(gaim_dbus_get_handle());
-+ GAIM_DBUS_REGISTER_BINDINGS(gaim2_dbus_get_handle());
-
- return TRUE;
- }
-@@ -596,18 +596,18 @@ static gboolean gaim_dbus_dispatch_init(
-
-
-
--static char *gaim_dbus_convert_signal_name(const char *gaim_name)
-+static char *gaim2_dbus_convert_signal_name(const char *gaim2_name)
- {
-- int gaim_index, g_index;
-- char *g_name = g_new(char, strlen(gaim_name)+1);
-+ int gaim2_index, g_index;
-+ char *g_name = g_new(char, strlen(gaim2_name)+1);
- gboolean capitalize_next = TRUE;
-
-- for(gaim_index = g_index = 0; gaim_name[gaim_index]; gaim_index++)
-- if (gaim_name[gaim_index] != '-' && gaim_name[gaim_index] != '_') {
-+ for(gaim2_index = g_index = 0; gaim2_name[gaim2_index]; gaim2_index++)
-+ if (gaim2_name[gaim2_index] != '-' && gaim2_name[gaim2_index] != '_') {
- if (capitalize_next)
-- g_name[g_index++] = g_ascii_toupper(gaim_name[gaim_index]);
-+ g_name[g_index++] = g_ascii_toupper(gaim2_name[gaim2_index]);
- else
-- g_name[g_index++] = gaim_name[gaim_index];
-+ g_name[g_index++] = gaim2_name[gaim2_index];
- capitalize_next = FALSE;
- } else
- capitalize_next = TRUE;
-@@ -618,9 +618,9 @@ static char *gaim_dbus_convert_signal_n
-
- #define my_arg(type) (ptr != NULL ? * ((type *)ptr) : va_arg(data, type))
-
--static void gaim_dbus_message_append_gaim_values(DBusMessageIter *iter,
-+static void gaim2_dbus_message_append_gaim2_values(DBusMessageIter *iter,
- int number,
-- GaimValue **gaim_values,
-+ Gaim2Value **gaim2_values,
- va_list data)
- {
- int i;
-@@ -632,12 +632,12 @@ static void gaim_dbus_message_append_gai
- guint xuint;
- gboolean xboolean;
- gpointer ptr = NULL;
-- if (gaim_value_is_outgoing(gaim_values[i])) {
-+ if (gaim2_value_is_outgoing(gaim2_values[i])) {
- ptr = my_arg(gpointer);
- g_return_if_fail(ptr);
- }
-
-- switch(gaim_values[i]->type) {
-+ switch(gaim2_values[i]->type) {
- case GAIM_TYPE_INT:
- xint = my_arg(gint);
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &xint);
-@@ -658,7 +658,7 @@ static void gaim_dbus_message_append_gai
- case GAIM_TYPE_POINTER:
- case GAIM_TYPE_OBJECT:
- case GAIM_TYPE_BOXED:
-- id = gaim_dbus_pointer_to_id(my_arg(gpointer));
-+ id = gaim2_dbus_pointer_to_id(my_arg(gpointer));
- dbus_message_iter_append_basic(iter, DBUS_TYPE_INT32, &id);
- break;
- default: /* no conversion implemented */
-@@ -669,17 +669,17 @@ static void gaim_dbus_message_append_gai
-
- #undef my_arg
-
--void gaim_dbus_signal_emit_gaim(const char *name, int num_values,
-- GaimValue **values, va_list vargs)
-+void gaim2_dbus_signal_emit_gaim2(const char *name, int num_values,
-+ Gaim2Value **values, va_list vargs)
- {
- DBusMessage *signal;
- DBusMessageIter iter;
- char *newname;
-
- #if 0 /* this is noisy with no dbus connection */
-- g_return_if_fail(gaim_dbus_connection);
-+ g_return_if_fail(gaim2_dbus_connection);
- #else
-- if (gaim_dbus_connection == NULL)
-+ if (gaim2_dbus_connection == NULL)
- return;
- #endif
-
-@@ -691,13 +691,13 @@ void gaim_dbus_signal_emit_gaim(const ch
- if (!strcmp(name, "dbus-method-called"))
- return;
-
-- newname = gaim_dbus_convert_signal_name(name);
-+ newname = gaim2_dbus_convert_signal_name(name);
- signal = dbus_message_new_signal(DBUS_PATH_GAIM, DBUS_INTERFACE_GAIM, newname);
- dbus_message_iter_init_append(signal, &iter);
-
-- gaim_dbus_message_append_gaim_values(&iter, num_values, values, vargs);
-+ gaim2_dbus_message_append_gaim2_values(&iter, num_values, values, vargs);
-
-- dbus_connection_send(gaim_dbus_connection, signal, NULL);
-+ dbus_connection_send(gaim2_dbus_connection, signal, NULL);
-
- g_free(newname);
- dbus_message_unref(signal);
-@@ -708,10 +708,10 @@ void gaim_dbus_signal_emit_gaim(const ch
-
-
-
--gboolean gaim_dbus_init(void)
-+gboolean gaim2_dbus_init(void)
- {
-- gaim_dbus_init_ids();
-- return gaim_dbus_dispatch_init() ;
-+ gaim2_dbus_init_ids();
-+ return gaim2_dbus_dispatch_init() ;
- }
-
-
-diff -prNu ./src/dbus-server.h ./src/dbus-server.h
---- ./src/dbus-server.h 2005-12-22 19:28:08.000000000 +0100
-+++ ./src/dbus-server.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file dbus-server.h Gaim DBUS Server
-+ * @file dbus-server.h Gaim2 DBUS Server
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,25 +33,25 @@
- G_BEGIN_DECLS
-
- /**
-- Types of pointers are identified by the ADDRESS of a GaimDbusType
-- object. This way, plugins can easily access types defined in gaim
-+ Types of pointers are identified by the ADDRESS of a Gaim2DbusType
-+ object. This way, plugins can easily access types defined in gaim2
- proper as well as introduce their own types that will not conflict
- with those introduced by other plugins.
-
-- The structure GaimDbusType has only one element (GaimDBusType::parent), a
-+ The structure Gaim2DbusType has only one element (Gaim2DBusType::parent), a
- contains a pointer to the parent type, or @c NULL if the type has no
- parent. Parent means the same as the base class in object oriented
- programming.
- */
-
--typedef struct _GaimDBusType GaimDBusType;
-+typedef struct _Gaim2DBusType Gaim2DBusType;
-
--struct _GaimDBusType {
-- GaimDBusType *parent;
-+struct _Gaim2DBusType {
-+ Gaim2DBusType *parent;
- };
-
--/* By convesion, the GaimDBusType variable representing each structure
-- GaimSomeStructure has the name GAIM_DBUS_TYPE_GaimSomeStructure.
-+/* By convesion, the Gaim2DBusType variable representing each structure
-+ Gaim2SomeStructure has the name GAIM_DBUS_TYPE_Gaim2SomeStructure.
- The following macros facilitate defining such variables
-
- #GAIM_DBUS_DECLARE_TYPE declares an extern variable representing a
-@@ -66,21 +66,21 @@ struct _GaimDBusType {
-
-
- #define GAIM_DBUS_DECLARE_TYPE(type) \
-- extern GaimDBusType GAIM_DBUS_TYPE_##type;
-+ extern Gaim2DBusType GAIM_DBUS_TYPE_##type;
-
- #define GAIM_DBUS_DEFINE_TYPE(type) \
-- GaimDBusType GAIM_DBUS_TYPE_##type = { NULL };
-+ Gaim2DBusType GAIM_DBUS_TYPE_##type = { NULL };
-
- #define GAIM_DBUS_DEFINE_INHERITING_TYPE(type, parent) \
-- GaimDBusType GAIM_DBUS_TYPE_##type = { GAIM_DBUS_TYPE(parent) };
-+ Gaim2DBusType GAIM_DBUS_TYPE_##type = { GAIM_DBUS_TYPE(parent) };
-
-
- /**
-- Initializes gaim dbus pointer registration engine.
-+ Initializes gaim2 dbus pointer registration engine.
-
- Remote dbus applications need a way of addressing objects exposed
-- by gaim to the outside world. In gaim itself, these objects (such
-- as GaimBuddy and company) are identified by pointers. The gaim
-+ by gaim2 to the outside world. In gaim2 itself, these objects (such
-+ as Gaim2Buddy and company) are identified by pointers. The gaim2
- dbus pointer registration engine converts pointers to handles and
- back.
-
-@@ -89,12 +89,12 @@ struct _GaimDBusType {
- allocates an integer id which can be resolved to the pointer and
- back.
-
-- Handles are not persistent. They are reissued every time gaim is
-- started. This is not good; external applications that use gaim
-- should work even whether gaim was restarted in the middle of the
-+ Handles are not persistent. They are reissued every time gaim2 is
-+ started. This is not good; external applications that use gaim2
-+ should work even whether gaim2 was restarted in the middle of the
- interaction.
-
-- Pointer registration is only a temporary solution. When GaimBuddy
-+ Pointer registration is only a temporary solution. When Gaim2Buddy
- and similar structures have been converted into gobjects, this
- registration will be done automatically by objects themselves.
-
-@@ -102,7 +102,7 @@ struct _GaimDBusType {
- common that there must be a library (maybe even glib) that
- implements it. I feel a bit like reinventing the wheel here.
- */
--void gaim_dbus_init_ids(void);
-+void gaim2_dbus_init_ids(void);
-
- /**
- Registers a typed pointer.
-@@ -110,15 +110,15 @@ void gaim_dbus_init_ids(void);
- @param node The pointer to register.
- @param type Type of that pointer.
- */
--void gaim_dbus_register_pointer(gpointer node, GaimDBusType *type);
-+void gaim2_dbus_register_pointer(gpointer node, Gaim2DBusType *type);
-
- /**
- Unregisters a pointer previously registered with
-- gaim_dbus_register_pointer.
-+ gaim2_dbus_register_pointer.
-
- @param node The pointer to register.
- */
--void gaim_dbus_unregister_pointer(gpointer node);
-+void gaim2_dbus_unregister_pointer(gpointer node);
-
-
-
-@@ -127,20 +127,20 @@ void gaim_dbus_unregister_pointer(gpoint
-
- @param name The name of the signal ("bla-bla-blaa")
- @param num_values The number of parameters.
-- @param values Array of pointers to #GaimValue objects representing
-+ @param values Array of pointers to #Gaim2Value objects representing
- the types of the parameters.
- @param vargs A va_list containing the actual parameters.
- */
--void gaim_dbus_signal_emit_gaim(const char *name, int num_values,
-- GaimValue **values, va_list vargs);
-+void gaim2_dbus_signal_emit_gaim2(const char *name, int num_values,
-+ Gaim2Value **values, va_list vargs);
-
- /**
-- * Starts the gaim DBUS server. It is responsible for handling DBUS
-+ * Starts the gaim2 DBUS server. It is responsible for handling DBUS
- * requests from other applications.
- *
- * @return TRUE if successful, FALSE otherwise.
- */
--gboolean gaim_dbus_init(void);
-+gboolean gaim2_dbus_init(void);
-
-
- /**
-@@ -148,7 +148,7 @@ gboolean gaim_dbus_init(void);
- *
- * @return The dbus subsystem handle.
- */
--void *gaim_dbus_get_handle(void);
-+void *gaim2_dbus_get_handle(void);
-
- /**
-
-@@ -164,7 +164,7 @@ void *gaim_dbus_get_handle(void);
-
- /*
- Here we include the list of #GAIM_DBUS_DECLARE_TYPE statements for
-- all structs defined in gaim. This file has been generated by the
-+ all structs defined in gaim2. This file has been generated by the
- #dbus-analize-types.py script.
- */
-
-diff -prNu ./src/dbus-useful.c ./src/dbus-useful.c
---- ./src/dbus-useful.c 2005-10-30 18:24:38.000000000 +0100
-+++ ./src/dbus-useful.c 2006-01-05 15:11:04.000000000 +0100
-@@ -6,23 +6,23 @@
- #include "util.h"
-
-
--GaimAccount *
--gaim_accounts_find_ext(const char *name, const char *protocol_id,
-- gboolean (*account_test)(const GaimAccount *account))
-+Gaim2Account *
-+gaim2_accounts_find_ext(const char *name, const char *protocol_id,
-+ gboolean (*account_test)(const Gaim2Account *account))
- {
-- GaimAccount *result = NULL;
-+ Gaim2Account *result = NULL;
- GList *l;
- char *who;
-
- if (name)
-- who = g_strdup(gaim_normalize(NULL, name));
-+ who = g_strdup(gaim2_normalize(NULL, name));
- else
- who = NULL;
-
-- for (l = gaim_accounts_get_all(); l != NULL; l = l->next) {
-- GaimAccount *account = (GaimAccount *)l->data;
-+ for (l = gaim2_accounts_get_all(); l != NULL; l = l->next) {
-+ Gaim2Account *account = (Gaim2Account *)l->data;
-
-- if (who && strcmp(gaim_normalize(NULL, gaim_account_get_username(account)), who))
-+ if (who && strcmp(gaim2_normalize(NULL, gaim2_account_get_username(account)), who))
- continue;
-
- if (protocol_id && strcmp(account->protocol_id, protocol_id))
-@@ -40,14 +40,14 @@ gaim_accounts_find_ext(const char *name,
- return result;
- }
-
--GaimAccount *gaim_accounts_find_any(const char *name, const char *protocol)
-+Gaim2Account *gaim2_accounts_find_any(const char *name, const char *protocol)
- {
-- return gaim_accounts_find_ext(name, protocol, NULL);
-+ return gaim2_accounts_find_ext(name, protocol, NULL);
- }
-
--GaimAccount *gaim_accounts_find_connected(const char *name, const char *protocol)
-+Gaim2Account *gaim2_accounts_find_connected(const char *name, const char *protocol)
- {
-- return gaim_accounts_find_ext(name, protocol, gaim_account_is_connected);
-+ return gaim2_accounts_find_ext(name, protocol, gaim2_account_is_connected);
- }
-
-
-diff -prNu ./src/dbus-useful.h ./src/dbus-useful.h
---- ./src/dbus-useful.h 2005-07-22 21:47:29.000000000 +0200
-+++ ./src/dbus-useful.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,11 +1,11 @@
- #include "conversation.h"
-
--GaimAccount *gaim_accounts_find_ext(const char *name, const char *protocol_id,
-- gboolean (*account_test)(const GaimAccount *account));
-+Gaim2Account *gaim2_accounts_find_ext(const char *name, const char *protocol_id,
-+ gboolean (*account_test)(const Gaim2Account *account));
-
--GaimAccount *gaim_accounts_find_any(const char *name, const char *protocol);
-+Gaim2Account *gaim2_accounts_find_any(const char *name, const char *protocol);
-
--GaimAccount *gaim_accounts_find_connected(const char *name, const char *protocol);
-+Gaim2Account *gaim2_accounts_find_connected(const char *name, const char *protocol);
-
-
-
-diff -prNu ./src/debug.c ./src/debug.c
---- ./src/debug.c 2005-09-11 07:16:59.000000000 +0200
-+++ ./src/debug.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file debug.c Debug API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,25 +26,25 @@
- #include "internal.h"
- #include "prefs.h"
-
--static GaimDebugUiOps *debug_ui_ops = NULL;
-+static Gaim2DebugUiOps *debug_ui_ops = NULL;
-
- /*
- * This determines whether debug info should be written to the
- * console or not.
- *
-- * It doesn't make sense to make this a normal Gaim preference
-+ * It doesn't make sense to make this a normal Gaim2 preference
- * because it's a command line option. This will always be FALSE,
-- * unless the user explicitly started Gaim with the -d flag.
-- * It doesn't matter what this value was the last time Gaim was
-+ * unless the user explicitly started Gaim2 with the -d flag.
-+ * It doesn't matter what this value was the last time Gaim2 was
- * started, so it doesn't make sense to save it in prefs.
- */
- static gboolean debug_enabled = FALSE;
-
- static void
--gaim_debug_vargs(GaimDebugLevel level, const char *category,
-+gaim2_debug_vargs(Gaim2DebugLevel level, const char *category,
- const char *format, va_list args)
- {
-- GaimDebugUiOps *ops;
-+ Gaim2DebugUiOps *ops;
-
- g_return_if_fail(level != GAIM_DEBUG_ALL);
- g_return_if_fail(format != NULL);
-@@ -55,8 +55,8 @@ gaim_debug_vargs(GaimDebugLevel level, c
- arg_s = g_strdup_vprintf(format, args);
-
- if ((category != NULL) &&
-- (gaim_prefs_exists("/core/debug/timestamps")) &&
-- (gaim_prefs_get_bool("/core/debug/timestamps"))) {
-+ (gaim2_prefs_exists("/core/debug/timestamps")) &&
-+ (gaim2_prefs_get_bool("/core/debug/timestamps"))) {
- gchar mdate[64];
-
- time_t mtime = time(NULL);
-@@ -75,14 +75,14 @@ gaim_debug_vargs(GaimDebugLevel level, c
- g_free(ts_s);
- }
-
-- ops = gaim_debug_get_ui_ops();
-+ ops = gaim2_debug_get_ui_ops();
-
- if (ops != NULL && ops->print != NULL)
- ops->print(level, category, format, args);
- }
-
- void
--gaim_debug(GaimDebugLevel level, const char *category,
-+gaim2_debug(Gaim2DebugLevel level, const char *category,
- const char *format, ...)
- {
- va_list args;
-@@ -91,102 +91,102 @@ gaim_debug(GaimDebugLevel level, const c
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
-- gaim_debug_vargs(level, category, format, args);
-+ gaim2_debug_vargs(level, category, format, args);
- va_end(args);
- }
-
- void
--gaim_debug_misc(const char *category, const char *format, ...)
-+gaim2_debug_misc(const char *category, const char *format, ...)
- {
- va_list args;
-
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
-- gaim_debug_vargs(GAIM_DEBUG_MISC, category, format, args);
-+ gaim2_debug_vargs(GAIM_DEBUG_MISC, category, format, args);
- va_end(args);
- }
-
- void
--gaim_debug_info(const char *category, const char *format, ...)
-+gaim2_debug_info(const char *category, const char *format, ...)
- {
- va_list args;
-
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
-- gaim_debug_vargs(GAIM_DEBUG_INFO, category, format, args);
-+ gaim2_debug_vargs(GAIM_DEBUG_INFO, category, format, args);
- va_end(args);
- }
-
- void
--gaim_debug_warning(const char *category, const char *format, ...)
-+gaim2_debug_warning(const char *category, const char *format, ...)
- {
- va_list args;
-
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
-- gaim_debug_vargs(GAIM_DEBUG_WARNING, category, format, args);
-+ gaim2_debug_vargs(GAIM_DEBUG_WARNING, category, format, args);
- va_end(args);
- }
-
- void
--gaim_debug_error(const char *category, const char *format, ...)
-+gaim2_debug_error(const char *category, const char *format, ...)
- {
- va_list args;
-
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
-- gaim_debug_vargs(GAIM_DEBUG_ERROR, category, format, args);
-+ gaim2_debug_vargs(GAIM_DEBUG_ERROR, category, format, args);
- va_end(args);
- }
-
- void
--gaim_debug_fatal(const char *category, const char *format, ...)
-+gaim2_debug_fatal(const char *category, const char *format, ...)
- {
- va_list args;
-
- g_return_if_fail(format != NULL);
-
- va_start(args, format);
-- gaim_debug_vargs(GAIM_DEBUG_FATAL, category, format, args);
-+ gaim2_debug_vargs(GAIM_DEBUG_FATAL, category, format, args);
- va_end(args);
- }
-
- void
--gaim_debug_set_enabled(gboolean enabled)
-+gaim2_debug_set_enabled(gboolean enabled)
- {
- debug_enabled = enabled;
- }
-
- gboolean
--gaim_debug_is_enabled()
-+gaim2_debug_is_enabled()
- {
- return debug_enabled;
- }
-
- void
--gaim_debug_set_ui_ops(GaimDebugUiOps *ops)
-+gaim2_debug_set_ui_ops(Gaim2DebugUiOps *ops)
- {
- debug_ui_ops = ops;
- }
-
--GaimDebugUiOps *
--gaim_debug_get_ui_ops(void)
-+Gaim2DebugUiOps *
-+gaim2_debug_get_ui_ops(void)
- {
- return debug_ui_ops;
- }
-
- void
--gaim_debug_init(void)
-+gaim2_debug_init(void)
- {
-- gaim_prefs_add_none("/core/debug");
-+ gaim2_prefs_add_none("/core/debug");
-
- /*
- * This pref is currently used by both the console
- * output and the debug window output.
- */
-- gaim_prefs_add_bool("/core/debug/timestamps", FALSE);
-+ gaim2_prefs_add_bool("/core/debug/timestamps", FALSE);
- }
-diff -prNu ./src/debug.h ./src/debug.h
---- ./src/debug.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/debug.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file debug.h Debug API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -40,16 +40,16 @@ typedef enum
- GAIM_DEBUG_ERROR, /**< Errors. */
- GAIM_DEBUG_FATAL /**< Fatal errors. */
-
--} GaimDebugLevel;
-+} Gaim2DebugLevel;
-
- /**
- * Debug UI operations.
- */
- typedef struct
- {
-- void (*print)(GaimDebugLevel level, const char *category,
-+ void (*print)(Gaim2DebugLevel level, const char *category,
- const char *format, va_list args);
--} GaimDebugUiOps;
-+} Gaim2DebugUiOps;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -65,87 +65,87 @@ extern "C" {
- * @param category The category (or @c NULL).
- * @param format The format string.
- */
--void gaim_debug(GaimDebugLevel level, const char *category,
-+void gaim2_debug(Gaim2DebugLevel level, const char *category,
- const char *format, ...);
-
- /**
- * Outputs misc. level debug information.
- *
-- * This is a wrapper for gaim_debug(), and uses GAIM_DEBUG_MISC as
-+ * This is a wrapper for gaim2_debug(), and uses GAIM_DEBUG_MISC as
- * the level.
- *
- * @param category The category (or @c NULL).
- * @param format The format string.
- *
-- * @see gaim_debug()
-+ * @see gaim2_debug()
- */
--void gaim_debug_misc(const char *category, const char *format, ...);
-+void gaim2_debug_misc(const char *category, const char *format, ...);
-
- /**
- * Outputs info level debug information.
- *
-- * This is a wrapper for gaim_debug(), and uses GAIM_DEBUG_INFO as
-+ * This is a wrapper for gaim2_debug(), and uses GAIM_DEBUG_INFO as
- * the level.
- *
- * @param category The category (or @c NULL).
- * @param format The format string.
- *
-- * @see gaim_debug()
-+ * @see gaim2_debug()
- */
--void gaim_debug_info(const char *category, const char *format, ...);
-+void gaim2_debug_info(const char *category, const char *format, ...);
-
- /**
- * Outputs warning level debug information.
- *
-- * This is a wrapper for gaim_debug(), and uses GAIM_DEBUG_WARNING as
-+ * This is a wrapper for gaim2_debug(), and uses GAIM_DEBUG_WARNING as
- * the level.
- *
- * @param category The category (or @c NULL).
- * @param format The format string.
- *
-- * @see gaim_debug()
-+ * @see gaim2_debug()
- */
--void gaim_debug_warning(const char *category, const char *format, ...);
-+void gaim2_debug_warning(const char *category, const char *format, ...);
-
- /**
- * Outputs error level debug information.
- *
-- * This is a wrapper for gaim_debug(), and uses GAIM_DEBUG_ERROR as
-+ * This is a wrapper for gaim2_debug(), and uses GAIM_DEBUG_ERROR as
- * the level.
- *
- * @param category The category (or @c NULL).
- * @param format The format string.
- *
-- * @see gaim_debug()
-+ * @see gaim2_debug()
- */
--void gaim_debug_error(const char *category, const char *format, ...);
-+void gaim2_debug_error(const char *category, const char *format, ...);
-
- /**
- * Outputs fatal error level debug information.
- *
-- * This is a wrapper for gaim_debug(), and uses GAIM_DEBUG_ERROR as
-+ * This is a wrapper for gaim2_debug(), and uses GAIM_DEBUG_ERROR as
- * the level.
- *
- * @param category The category (or @c NULL).
- * @param format The format string.
- *
-- * @see gaim_debug()
-+ * @see gaim2_debug()
- */
--void gaim_debug_fatal(const char *category, const char *format, ...);
-+void gaim2_debug_fatal(const char *category, const char *format, ...);
-
- /**
- * Enable or disable printing debug output to the console.
- *
- * @param enabled TRUE to enable debug output or FALSE to disable it.
- */
--void gaim_debug_set_enabled(gboolean enabled);
-+void gaim2_debug_set_enabled(gboolean enabled);
-
- /**
- * Check if console debug output is enabled.
- *
- * @return TRUE if debuggin is enabled, FALSE if it is not.
- */
--gboolean gaim_debug_is_enabled(void);
-+gboolean gaim2_debug_is_enabled(void);
-
- /*@}*/
-
-@@ -160,7 +160,7 @@ gboolean gaim_debug_is_enabled(void);
- *
- * @param ops The UI operations structure.
- */
--void gaim_debug_set_ui_ops(GaimDebugUiOps *ops);
-+void gaim2_debug_set_ui_ops(Gaim2DebugUiOps *ops);
-
- /**
- * Returns the UI operations structure used when outputting debug
-@@ -168,7 +168,7 @@ void gaim_debug_set_ui_ops(GaimDebugUiOp
- *
- * @return The UI operations structure in use.
- */
--GaimDebugUiOps *gaim_debug_get_ui_ops(void);
-+Gaim2DebugUiOps *gaim2_debug_get_ui_ops(void);
-
- /*@}*/
-
-@@ -180,7 +180,7 @@ GaimDebugUiOps *gaim_debug_get_ui_ops(vo
- /**
- * Initializes the debug subsystem.
- */
--void gaim_debug_init(void);
-+void gaim2_debug_init(void);
-
- /*@}*/
-
-diff -prNu ./src/desktopitem.c ./src/desktopitem.c
---- ./src/desktopitem.c 2005-02-11 06:10:21.000000000 +0100
-+++ ./src/desktopitem.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,8 +1,8 @@
- /**
-- * @file gaim-desktop-item.c Functions for managing .desktop files
-+ * @file gaim2-desktop-item.c Functions for managing .desktop files
- * @ingroup core
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -59,13 +59,13 @@
- #include "desktopitem.h"
- #include "internal.h"
-
--struct _GaimDesktopItem {
-+struct _Gaim2DesktopItem {
- int refcount;
-
- /* all languages used */
- GList *languages;
-
-- GaimDesktopItemType type;
-+ Gaim2DesktopItemType type;
-
- /* `modified' means that the ditem has been
- * modified since the last save. */
-@@ -99,7 +99,7 @@ typedef enum {
- /**************************************************************************
- * Private utility functions
- **************************************************************************/
--static GaimDesktopItemType
-+static Gaim2DesktopItemType
- type_from_string (const char *type)
- {
- if (!type)
-@@ -141,7 +141,7 @@ type_from_string (const char *type)
- }
-
- static Section *
--find_section (GaimDesktopItem *item, const char *section)
-+find_section (Gaim2DesktopItem *item, const char *section)
- {
- GList *li;
- Section *sec;
-@@ -170,7 +170,7 @@ find_section (GaimDesktopItem *item, con
- }
-
- static Section *
--section_from_key (GaimDesktopItem *item, const char *key)
-+section_from_key (Gaim2DesktopItem *item, const char *key)
- {
- char *p;
- char *name;
-@@ -203,7 +203,7 @@ key_basename (const char *key)
- }
-
- static void
--set (GaimDesktopItem *item, const char *key, const char *value)
-+set (Gaim2DesktopItem *item, const char *key, const char *value)
- {
- Section *sec = section_from_key (item, key);
-
-@@ -253,7 +253,7 @@ set (GaimDesktopItem *item, const char *
-
-
- static void
--_gaim_desktop_item_set_string (GaimDesktopItem *item,
-+_gaim2_desktop_item_set_string (Gaim2DesktopItem *item,
- const char *attr,
- const char *value)
- {
-@@ -267,12 +267,12 @@ _gaim_desktop_item_set_string (GaimDeskt
- item->type = type_from_string (value);
- }
-
--static GaimDesktopItem *
--_gaim_desktop_item_new (void)
-+static Gaim2DesktopItem *
-+_gaim2_desktop_item_new (void)
- {
-- GaimDesktopItem *retval;
-+ Gaim2DesktopItem *retval;
-
-- retval = g_new0 (GaimDesktopItem, 1);
-+ retval = g_new0 (Gaim2DesktopItem, 1);
-
- retval->refcount++;
-
-@@ -281,13 +281,13 @@ _gaim_desktop_item_new (void)
- (GDestroyNotify) g_free);
-
- /* These are guaranteed to be set */
-- _gaim_desktop_item_set_string (retval,
-+ _gaim2_desktop_item_set_string (retval,
- GAIM_DESKTOP_ITEM_NAME,
- _("No name"));
-- _gaim_desktop_item_set_string (retval,
-+ _gaim2_desktop_item_set_string (retval,
- GAIM_DESKTOP_ITEM_ENCODING,
- "UTF-8");
-- _gaim_desktop_item_set_string (retval,
-+ _gaim2_desktop_item_set_string (retval,
- GAIM_DESKTOP_ITEM_VERSION,
- "1.0");
-
-@@ -295,15 +295,15 @@ _gaim_desktop_item_new (void)
- }
-
- static gpointer
--_gaim_desktop_item_copy (gpointer boxed)
-+_gaim2_desktop_item_copy (gpointer boxed)
- {
-- return gaim_desktop_item_copy (boxed);
-+ return gaim2_desktop_item_copy (boxed);
- }
-
- static void
--_gaim_desktop_item_free (gpointer boxed)
-+_gaim2_desktop_item_free (gpointer boxed)
- {
-- gaim_desktop_item_unref (boxed);
-+ gaim2_desktop_item_unref (boxed);
- }
-
- /* Note, does not include the trailing \n */
-@@ -660,7 +660,7 @@ cannonize (const char *key, const char *
- }
-
- static void
--insert_key (GaimDesktopItem *item,
-+insert_key (Gaim2DesktopItem *item,
- Section *cur_section,
- Encoding encoding,
- const char *key,
-@@ -776,13 +776,13 @@ insert_key (GaimDesktopItem *item,
- }
-
- static const char *
--lookup (const GaimDesktopItem *item, const char *key)
-+lookup (const Gaim2DesktopItem *item, const char *key)
- {
- return g_hash_table_lookup (item->main_hash, key);
- }
-
- static void
--setup_type (GaimDesktopItem *item, const char *uri)
-+setup_type (Gaim2DesktopItem *item, const char *uri)
- {
- const char *type = g_hash_table_lookup (item->main_hash,
- GAIM_DESKTOP_ITEM_TYPE);
-@@ -807,7 +807,7 @@ setup_type (GaimDesktopItem *item, const
- }
-
- static const char *
--lookup_locale (const GaimDesktopItem *item, const char *key, const char *locale)
-+lookup_locale (const Gaim2DesktopItem *item, const char *key, const char *locale)
- {
- if (locale == NULL ||
- strcmp (locale, "C") == 0) {
-@@ -823,7 +823,7 @@ lookup_locale (const GaimDesktopItem *it
-
- /* fallback to find something suitable for C locale */
- static char *
--try_english_key (GaimDesktopItem *item, const char *key)
-+try_english_key (Gaim2DesktopItem *item, const char *key)
- {
- char *str;
- char *locales[] = { "en_US", "en_GB", "en_AU", "en", NULL };
-@@ -847,7 +847,7 @@ try_english_key (GaimDesktopItem *item,
-
-
- static void
--sanitize (GaimDesktopItem *item, const char *uri)
-+sanitize (Gaim2DesktopItem *item, const char *uri)
- {
- const char *type;
-
-@@ -907,7 +907,7 @@ enum {
- KeyValue
- };
-
--static GaimDesktopItem *
-+static Gaim2DesktopItem *
- ditem_load (FILE *df,
- gboolean no_translations,
- const char *uri)
-@@ -917,7 +917,7 @@ ditem_load (FILE *df,
- char *next = CharBuffer;
- int c;
- Encoding encoding;
-- GaimDesktopItem *item;
-+ Gaim2DesktopItem *item;
- Section *cur_section = NULL;
- char *key = NULL;
- gboolean old_kde = FALSE;
-@@ -939,7 +939,7 @@ ditem_load (FILE *df,
- return NULL;
- }
-
-- item = _gaim_desktop_item_new ();
-+ item = _gaim2_desktop_item_new ();
- item->modified = FALSE;
-
- /* Note: location and mtime are filled in by the new_from_file
-@@ -1142,10 +1142,10 @@ dup_section (Section *sec)
- /**************************************************************************
- * Public functions
- **************************************************************************/
--GaimDesktopItem *
--gaim_desktop_item_new_from_file (const char *filename)
-+Gaim2DesktopItem *
-+gaim2_desktop_item_new_from_file (const char *filename)
- {
-- GaimDesktopItem *retval;
-+ Gaim2DesktopItem *retval;
- FILE *dfile;
-
- g_return_val_if_fail (filename != NULL, NULL);
-@@ -1161,8 +1161,8 @@ gaim_desktop_item_new_from_file (const c
- return retval;
- }
-
--GaimDesktopItemType
--gaim_desktop_item_get_entry_type (const GaimDesktopItem *item)
-+Gaim2DesktopItemType
-+gaim2_desktop_item_get_entry_type (const Gaim2DesktopItem *item)
- {
- g_return_val_if_fail (item != NULL, 0);
- g_return_val_if_fail (item->refcount > 0, 0);
-@@ -1171,7 +1171,7 @@ gaim_desktop_item_get_entry_type (const
- }
-
- const char *
--gaim_desktop_item_get_string (const GaimDesktopItem *item,
-+gaim2_desktop_item_get_string (const Gaim2DesktopItem *item,
- const char *attr)
- {
- g_return_val_if_fail (item != NULL, NULL);
-@@ -1181,16 +1181,16 @@ gaim_desktop_item_get_string (const Gaim
- return lookup (item, attr);
- }
-
--GaimDesktopItem *
--gaim_desktop_item_copy (const GaimDesktopItem *item)
-+Gaim2DesktopItem *
-+gaim2_desktop_item_copy (const Gaim2DesktopItem *item)
- {
- GList *li;
-- GaimDesktopItem *retval;
-+ Gaim2DesktopItem *retval;
-
- g_return_val_if_fail (item != NULL, NULL);
- g_return_val_if_fail (item->refcount > 0, NULL);
-
-- retval = _gaim_desktop_item_new ();
-+ retval = _gaim2_desktop_item_new ();
-
- retval->type = item->type;
- retval->modified = item->modified;
-@@ -1224,7 +1224,7 @@ gaim_desktop_item_copy (const GaimDeskto
- }
-
- void
--gaim_desktop_item_unref (GaimDesktopItem *item)
-+gaim2_desktop_item_unref (Gaim2DesktopItem *item)
- {
- g_return_if_fail (item != NULL);
- g_return_if_fail (item->refcount > 0);
-@@ -1256,14 +1256,14 @@ gaim_desktop_item_unref (GaimDesktopItem
- }
-
- GType
--gaim_desktop_item_get_type (void)
-+gaim2_desktop_item_get_type (void)
- {
- static GType type = 0;
-
- if (type == 0) {
-- type = g_boxed_type_register_static ("GaimDesktopItem",
-- _gaim_desktop_item_copy,
-- _gaim_desktop_item_free);
-+ type = g_boxed_type_register_static ("Gaim2DesktopItem",
-+ _gaim2_desktop_item_copy,
-+ _gaim2_desktop_item_free);
- }
-
- return type;
-diff -prNu ./src/desktopitem.h ./src/desktopitem.h
---- ./src/desktopitem.h 2004-11-27 20:39:18.000000000 +0100
-+++ ./src/desktopitem.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,7 +2,7 @@
- * @file desktopitem.h Functions for managing .desktop files
- * @ingroup core
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -75,12 +75,12 @@ typedef enum {
- GAIM_DESKTOP_ITEM_TYPE_DIRECTORY,
- GAIM_DESKTOP_ITEM_TYPE_SERVICE,
- GAIM_DESKTOP_ITEM_TYPE_SERVICE_TYPE
--} GaimDesktopItemType;
-+} Gaim2DesktopItemType;
-
--typedef struct _GaimDesktopItem GaimDesktopItem;
-+typedef struct _Gaim2DesktopItem Gaim2DesktopItem;
-
--#define GAIM_TYPE_DESKTOP_ITEM (gaim_desktop_item_get_type ())
--GType gaim_desktop_item_get_type (void);
-+#define GAIM_TYPE_DESKTOP_ITEM (gaim2_desktop_item_get_type ())
-+GType gaim2_desktop_item_get_type (void);
-
- /* standard */
- #define GAIM_DESKTOP_ITEM_ENCODING "Encoding" /* string */
-@@ -115,13 +115,13 @@ GType gaim_desktop_item_get_type (
- #define GAIM_DESKTOP_ITEM_DOC_PATH "X-GNOME-DocPath" /* string */
-
- /**
-- * This function loads 'filename' and turns it into a GaimDesktopItem.
-+ * This function loads 'filename' and turns it into a Gaim2DesktopItem.
- *
-- * @param filename The filename or directory path to load the GaimDesktopItem from
-+ * @param filename The filename or directory path to load the Gaim2DesktopItem from
- *
- * @return The newly loaded item, or NULL on error.
- */
--GaimDesktopItem *gaim_desktop_item_new_from_file (const char *filename);
-+Gaim2DesktopItem *gaim2_desktop_item_new_from_file (const char *filename);
-
- /**
- * Gets the type attribute (the 'Type' field) of the item. This should
-@@ -133,9 +133,9 @@ GaimDesktopItem *gaim_desktop_item_new_f
- * @param item A desktop item
- *
- * @return The type of the specified 'item'. The returned memory
-- * remains owned by the GaimDesktopItem and should not be freed.
-+ * remains owned by the Gaim2DesktopItem and should not be freed.
- */
--GaimDesktopItemType gaim_desktop_item_get_entry_type (const GaimDesktopItem *item);
-+Gaim2DesktopItemType gaim2_desktop_item_get_entry_type (const Gaim2DesktopItem *item);
-
- /**
- * Gets the value of an attribute of the item, as a string.
-@@ -145,18 +145,18 @@ GaimDesktopItemType gaim_desktop_item_ge
- *
- * @return The value of the specified item attribute.
- */
--const char *gaim_desktop_item_get_string (const GaimDesktopItem *item,
-+const char *gaim2_desktop_item_get_string (const Gaim2DesktopItem *item,
- const char *attr);
-
- /**
-- * Creates a copy of a GaimDesktopItem. The new copy has a refcount of 1.
-+ * Creates a copy of a Gaim2DesktopItem. The new copy has a refcount of 1.
- * Note: Section stack is NOT copied.
- *
- * @param item The item to be copied
- *
- * @return The new copy
- */
--GaimDesktopItem *gaim_desktop_item_copy (const GaimDesktopItem *item);
-+Gaim2DesktopItem *gaim2_desktop_item_copy (const Gaim2DesktopItem *item);
-
- /**
- * Decreases the reference count of the specified item, and destroys
-@@ -164,7 +164,7 @@ GaimDesktopItem *gaim_desktop_item_copy
- *
- * @param item A desktop item
- */
--void gaim_desktop_item_unref (GaimDesktopItem *item);
-+void gaim2_desktop_item_unref (Gaim2DesktopItem *item);
-
- G_END_DECLS
-
-diff -prNu ./src/dnssrv.c ./src/dnssrv.c
---- ./src/dnssrv.c 2006-01-03 06:56:22.000000000 +0100
-+++ ./src/dnssrv.c 2006-01-05 15:11:03.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file dnssrv.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -58,7 +58,7 @@ static void (*MyDnsRecordListFree) (PDNS
- #endif
-
- struct resdata {
-- GaimSRVCallback cb;
-+ Gaim2SRVCallback cb;
- gpointer extradata;
- #ifndef _WIN32
- guint handle;
-@@ -70,8 +70,8 @@ struct resdata {
- };
-
- static gint responsecompare(gconstpointer ar, gconstpointer br) {
-- GaimSrvResponse *a = (GaimSrvResponse*)ar;
-- GaimSrvResponse *b = (GaimSrvResponse*)br;
-+ Gaim2SrvResponse *a = (Gaim2SrvResponse*)ar;
-+ Gaim2SrvResponse *b = (Gaim2SrvResponse*)br;
-
- if(a->pref == b->pref) {
- if(a->weight == b->weight)
-@@ -87,7 +87,7 @@ static gint responsecompare(gconstpointe
- #ifndef _WIN32
- static void resolve(int in, int out) {
- GList *ret = NULL;
-- GaimSrvResponse *srvres;
-+ Gaim2SrvResponse *srvres;
- queryans answer;
- int size;
- int qdcount;
-@@ -142,7 +142,7 @@ static void resolve(int in, int out) {
-
- cp += size;
-
-- srvres = g_new0(GaimSrvResponse, 1);
-+ srvres = g_new0(Gaim2SrvResponse, 1);
- strcpy(srvres->hostname, name);
- srvres->pref = pref;
- srvres->port = port;
-@@ -156,7 +156,7 @@ static void resolve(int in, int out) {
- end: size = g_list_length(ret);
- write(out, &size, sizeof(int));
- while(g_list_first(ret)) {
-- write(out, g_list_first(ret)->data, sizeof(GaimSrvResponse));
-+ write(out, g_list_first(ret)->data, sizeof(Gaim2SrvResponse));
- g_free(g_list_first(ret)->data);
- ret = g_list_remove(ret, g_list_first(ret)->data);
- }
-@@ -167,24 +167,24 @@ end: size = g_list_length(ret);
- _exit(0);
- }
-
--static void resolved(gpointer data, gint source, GaimInputCondition cond) {
-+static void resolved(gpointer data, gint source, Gaim2InputCondition cond) {
- int size;
- struct resdata *rdata = (struct resdata*)data;
-- GaimSrvResponse *res;
-- GaimSrvResponse *tmp;
-+ Gaim2SrvResponse *res;
-+ Gaim2SrvResponse *tmp;
- int i;
-- GaimSRVCallback cb = rdata->cb;
-+ Gaim2SRVCallback cb = rdata->cb;
-
- read(source, &size, sizeof(int));
-- gaim_debug_info("srv","found %d SRV entries\n", size);
-- tmp = res = g_new0(GaimSrvResponse, size);
-+ gaim2_debug_info("srv","found %d SRV entries\n", size);
-+ tmp = res = g_new0(Gaim2SrvResponse, size);
- i = size;
- while(i) {
-- read(source, tmp++, sizeof(GaimSrvResponse));
-+ read(source, tmp++, sizeof(Gaim2SrvResponse));
- i--;
- }
- cb(res, size, rdata->extradata);
-- gaim_input_remove(rdata->handle);
-+ gaim2_input_remove(rdata->handle);
- g_free(rdata);
- }
-
-@@ -193,22 +193,22 @@ static void resolved(gpointer data, gint
- /** The Jabber Server code was inspiration for parts of this. */
-
- static gboolean res_main_thread_cb(gpointer data) {
-- GaimSrvResponse *srvres = NULL;
-+ Gaim2SrvResponse *srvres = NULL;
- int size = 0;
- struct resdata *rdata = data;
-
- if (rdata->errmsg != NULL) {
-- gaim_debug_error("srv", rdata->errmsg);
-+ gaim2_debug_error("srv", rdata->errmsg);
- g_free(rdata->errmsg);
- } else {
-- GaimSrvResponse *srvres_tmp;
-+ Gaim2SrvResponse *srvres_tmp;
- GSList *lst = rdata->results;
-
- size = g_slist_length(rdata->results);
-
-- srvres_tmp = srvres = g_new0(GaimSrvResponse, size);
-+ srvres_tmp = srvres = g_new0(Gaim2SrvResponse, size);
- while (lst) {
-- memcpy(srvres_tmp++, lst->data, sizeof(GaimSrvResponse));
-+ memcpy(srvres_tmp++, lst->data, sizeof(Gaim2SrvResponse));
- g_free(lst->data);
- lst = g_slist_remove(lst, lst->data);
- }
-@@ -216,7 +216,7 @@ static gboolean res_main_thread_cb(gpoin
- rdata->results = lst;
- }
-
-- gaim_debug_info("srv", "found %d SRV entries\n", size);
-+ gaim2_debug_info("srv", "found %d SRV entries\n", size);
-
- rdata->cb(srvres, size, rdata->extradata);
-
-@@ -241,7 +241,7 @@ static gpointer res_thread(gpointer data
- PDNS_RECORD dr_tmp;
- GSList *lst = NULL;
- DNS_SRV_DATA *srv_data;
-- GaimSrvResponse *srvres;
-+ Gaim2SrvResponse *srvres;
-
- for (dr_tmp = dr; dr_tmp != NULL; dr_tmp = dr_tmp->pNext) {
- /* Discard any incorrect entries. I'm not sure if this is necessary */
-@@ -250,7 +250,7 @@ static gpointer res_thread(gpointer data
- }
-
- srv_data = &dr_tmp->Data.SRV;
-- srvres = g_new0(GaimSrvResponse, 1);
-+ srvres = g_new0(Gaim2SrvResponse, 1);
- strncpy(srvres->hostname, srv_data->pNameTarget, 255);
- srvres->hostname[255] = '\0';
- srvres->pref = srv_data->wPriority;
-@@ -273,15 +273,15 @@ static gpointer res_thread(gpointer data
-
- #endif
-
--void gaim_srv_resolve(const char *protocol, const char *transport, const char *domain, GaimSRVCallback cb, gpointer extradata) {
-+void gaim2_srv_resolve(const char *protocol, const char *transport, const char *domain, Gaim2SRVCallback cb, gpointer extradata) {
- char *query = g_strdup_printf("_%s._%s.%s",protocol, transport, domain);
- struct resdata *rdata;
- #ifndef _WIN32
- int in[2], out[2];
- int pid;
-- gaim_debug_info("srv","querying SRV record for %s\n", query);
-+ gaim2_debug_info("srv","querying SRV record for %s\n", query);
- if(pipe(in) || pipe(out)) {
-- gaim_debug_error("srv", "Could not create pipe\n");
-+ gaim2_debug_error("srv", "Could not create pipe\n");
- g_free(query);
- cb(NULL, 0, extradata);
- return;
-@@ -290,7 +290,7 @@ void gaim_srv_resolve(const char *protoc
- pid = fork();
-
- if(pid == -1) {
-- gaim_debug_error("srv","Could not create process!\n");
-+ gaim2_debug_error("srv","Could not create process!\n");
- cb(NULL, 0, extradata);
- g_free(query);
- return;
-@@ -306,12 +306,12 @@ void gaim_srv_resolve(const char *protoc
- close(in[0]);
-
- if(write(in[1], query, strlen(query)+1)<0) {
-- gaim_debug_error("srv", "Could not write to SRV resolver\n");
-+ gaim2_debug_error("srv", "Could not write to SRV resolver\n");
- }
- rdata = g_new0(struct resdata,1);
- rdata->cb = cb;
- rdata->extradata = extradata;
-- rdata->handle = gaim_input_add(out[0], GAIM_INPUT_READ, resolved, rdata);
-+ rdata->handle = gaim2_input_add(out[0], GAIM_INPUT_READ, resolved, rdata);
-
- g_free(query);
- #else
-@@ -319,17 +319,17 @@ void gaim_srv_resolve(const char *protoc
-
- static gboolean initialized = FALSE;
-
-- gaim_debug_info("srv","querying SRV record for %s\n", query);
-+ gaim2_debug_info("srv","querying SRV record for %s\n", query);
-
- if (!initialized) {
-- MyDnsQuery_UTF8 = (void*) wgaim_find_and_loadproc("dnsapi.dll", "DnsQuery_UTF8");
-- MyDnsRecordListFree = (void*) wgaim_find_and_loadproc(
-+ MyDnsQuery_UTF8 = (void*) wgaim2_find_and_loadproc("dnsapi.dll", "DnsQuery_UTF8");
-+ MyDnsRecordListFree = (void*) wgaim2_find_and_loadproc(
- "dnsapi.dll", "DnsRecordListFree");
- initialized = TRUE;
- }
-
- if (!MyDnsQuery_UTF8 || !MyDnsRecordListFree) {
-- gaim_debug_error("srv", "System missing DNS API (Requires W2K+)\n");
-+ gaim2_debug_error("srv", "System missing DNS API (Requires W2K+)\n");
- g_free(query);
- cb(NULL, 0, extradata);
- return;
-diff -prNu ./src/dnssrv.h ./src/dnssrv.h
---- ./src/dnssrv.h 2006-01-03 01:23:24.000000000 +0100
-+++ ./src/dnssrv.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file dnssrv.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005, Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -23,16 +23,16 @@
- #ifndef _GAIM_DNSSRV_H
- #define _GAIM_DNSSRV_H
-
--typedef struct _GaimSrvResponse GaimSrvResponse;
-+typedef struct _Gaim2SrvResponse Gaim2SrvResponse;
-
--struct _GaimSrvResponse {
-+struct _Gaim2SrvResponse {
- char hostname[256];
- int port;
- int weight;
- int pref;
- };
-
--typedef void (*GaimSRVCallback)(GaimSrvResponse *resp, int results, gpointer data);
-+typedef void (*Gaim2SRVCallback)(Gaim2SrvResponse *resp, int results, gpointer data);
-
- /**
- * Queries an SRV record.
-@@ -43,6 +43,6 @@ typedef void (*GaimSRVCallback)(GaimSrvR
- * @param cb A callback which will be called with the results
- * @param extradata Extra data to be passed to the callback
- */
--void gaim_srv_resolve(const char *protocol, const char *transport, const char *domain, GaimSRVCallback cb, gpointer extradata);
-+void gaim2_srv_resolve(const char *protocol, const char *transport, const char *domain, Gaim2SRVCallback cb, gpointer extradata);
-
- #endif /* _GAIM_DNSSRV_H */
-diff -prNu ./src/eventloop.c ./src/eventloop.c
---- ./src/eventloop.c 2005-08-18 05:14:29.000000000 +0200
-+++ ./src/eventloop.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file eventloop.c Gaim Event Loop API
-+ * @file eventloop.c Gaim2 Event Loop API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,48 +24,48 @@
- */
- #include "eventloop.h"
-
--static GaimEventLoopUiOps *eventloop_ui_ops = NULL;
-+static Gaim2EventLoopUiOps *eventloop_ui_ops = NULL;
-
- guint
--gaim_timeout_add(guint interval, GSourceFunc function, gpointer data)
-+gaim2_timeout_add(guint interval, GSourceFunc function, gpointer data)
- {
-- GaimEventLoopUiOps *ops = gaim_eventloop_get_ui_ops();
-+ Gaim2EventLoopUiOps *ops = gaim2_eventloop_get_ui_ops();
-
- return ops->timeout_add(interval, function, data);
- }
-
- guint
--gaim_timeout_remove(guint tag)
-+gaim2_timeout_remove(guint tag)
- {
-- GaimEventLoopUiOps *ops = gaim_eventloop_get_ui_ops();
-+ Gaim2EventLoopUiOps *ops = gaim2_eventloop_get_ui_ops();
-
- return ops->timeout_remove(tag);
- }
-
- guint
--gaim_input_add(int source, GaimInputCondition condition, GaimInputFunction func, gpointer user_data)
-+gaim2_input_add(int source, Gaim2InputCondition condition, Gaim2InputFunction func, gpointer user_data)
- {
-- GaimEventLoopUiOps *ops = gaim_eventloop_get_ui_ops();
-+ Gaim2EventLoopUiOps *ops = gaim2_eventloop_get_ui_ops();
-
- return ops->input_add(source, condition, func, user_data);
- }
-
- guint
--gaim_input_remove(guint tag)
-+gaim2_input_remove(guint tag)
- {
-- GaimEventLoopUiOps *ops = gaim_eventloop_get_ui_ops();
-+ Gaim2EventLoopUiOps *ops = gaim2_eventloop_get_ui_ops();
-
- return ops->input_remove(tag);
- }
-
- void
--gaim_eventloop_set_ui_ops(GaimEventLoopUiOps *ops)
-+gaim2_eventloop_set_ui_ops(Gaim2EventLoopUiOps *ops)
- {
- eventloop_ui_ops = ops;
- }
-
--GaimEventLoopUiOps *
--gaim_eventloop_get_ui_ops(void)
-+Gaim2EventLoopUiOps *
-+gaim2_eventloop_get_ui_ops(void)
- {
- g_return_val_if_fail(eventloop_ui_ops != NULL, NULL);
-
-diff -prNu ./src/eventloop.h ./src/eventloop.h
---- ./src/eventloop.h 2004-10-02 00:08:38.000000000 +0200
-+++ ./src/eventloop.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file eventloop.h Gaim Event Loop API
-+ * @file eventloop.h Gaim2 Event Loop API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -39,36 +39,36 @@ typedef enum
- GAIM_INPUT_READ = 1 << 0, /**< A read condition. */
- GAIM_INPUT_WRITE = 1 << 1 /**< A write condition. */
-
--} GaimInputCondition;
-+} Gaim2InputCondition;
-
--typedef void (*GaimInputFunction)(gpointer, gint, GaimInputCondition);
-+typedef void (*Gaim2InputFunction)(gpointer, gint, Gaim2InputCondition);
-
--typedef struct _GaimEventLoopUiOps GaimEventLoopUiOps;
-+typedef struct _Gaim2EventLoopUiOps Gaim2EventLoopUiOps;
-
--struct _GaimEventLoopUiOps
-+struct _Gaim2EventLoopUiOps
- {
- /**
- * Creates a callback timer.
-- * @see g_timeout_add, gaim_timeout_add
-+ * @see g_timeout_add, gaim2_timeout_add
- **/
- guint (*timeout_add)(guint interval, GSourceFunc function, gpointer data);
-
- /**
- * Removes a callback timer.
-- * @see gaim_timeout_remove, g_source_remove
-+ * @see gaim2_timeout_remove, g_source_remove
- */
- guint (*timeout_remove)(guint handle);
-
- /**
- * Adds an input handler.
-- * @see gaim_input_add, g_io_add_watch_full
-+ * @see gaim2_input_add, g_io_add_watch_full
- */
-- guint (*input_add)(int fd, GaimInputCondition cond,
-- GaimInputFunction func, gpointer user_data);
-+ guint (*input_add)(int fd, Gaim2InputCondition cond,
-+ Gaim2InputFunction func, gpointer user_data);
-
- /**
- * Removes an input handler.
-- * @see gaim_input_remove, g_source_remove
-+ * @see gaim2_input_remove, g_source_remove
- */
- guint (*input_remove)(guint handle);
- };
-@@ -86,18 +86,18 @@ struct _GaimEventLoopUiOps
- * @param function The function to call.
- * @param data data to pass to @a function.
- * @return A handle to the timer which can be passed to
-- * gaim_timeout_remove to remove the timer.
-+ * gaim2_timeout_remove to remove the timer.
- */
--guint gaim_timeout_add(guint interval, GSourceFunc function, gpointer data);
-+guint gaim2_timeout_add(guint interval, GSourceFunc function, gpointer data);
-
- /**
- * Removes a timeout handler.
- *
-- * @param handle The handle, as returned by gaim_timeout_add.
-+ * @param handle The handle, as returned by gaim2_timeout_add.
- *
- * @return Something.
- */
--guint gaim_timeout_remove(guint handle);
-+guint gaim2_timeout_remove(guint handle);
-
- /**
- * Adds an input handler.
-@@ -110,16 +110,16 @@ guint gaim_timeout_remove(guint handle);
- * @return The resulting handle.
- * @see g_io_add_watch_full
- */
--guint gaim_input_add(int fd, GaimInputCondition cond,
-- GaimInputFunction func, gpointer user_data);
-+guint gaim2_input_add(int fd, Gaim2InputCondition cond,
-+ Gaim2InputFunction func, gpointer user_data);
-
- /**
- * Removes an input handler.
- *
- * @param handle The handle of the input handler. Note that this is the return
-- * value from gaim_input_add, <i>not</i> the file descriptor.
-+ * value from gaim2_input_add, <i>not</i> the file descriptor.
- */
--guint gaim_input_remove(guint handle);
-+guint gaim2_input_remove(guint handle);
-
- /*@}*/
-
-@@ -133,14 +133,14 @@ guint gaim_input_remove(guint handle);
- *
- * @param ops The UI operations structure.
- */
--void gaim_eventloop_set_ui_ops(GaimEventLoopUiOps *ops);
-+void gaim2_eventloop_set_ui_ops(Gaim2EventLoopUiOps *ops);
-
- /**
- * Returns the UI operations structure used for accounts.
- *
- * @return The UI operations structure in use.
- */
--GaimEventLoopUiOps *gaim_eventloop_get_ui_ops(void);
-+Gaim2EventLoopUiOps *gaim2_eventloop_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/ft.c ./src/ft.c
---- ./src/ft.c 2005-11-28 12:47:50.000000000 +0100
-+++ ./src/ft.c 2006-01-05 15:11:03.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file ft.c File Transfer API
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,28 +31,28 @@
- #include "request.h"
- #include "util.h"
-
--static GaimXferUiOps *xfer_ui_ops = NULL;
-+static Gaim2XferUiOps *xfer_ui_ops = NULL;
-
--GaimXfer *
--gaim_xfer_new(GaimAccount *account, GaimXferType type, const char *who)
-+Gaim2Xfer *
-+gaim2_xfer_new(Gaim2Account *account, Gaim2XferType type, const char *who)
- {
-- GaimXfer *xfer;
-- GaimXferUiOps *ui_ops;
-+ Gaim2Xfer *xfer;
-+ Gaim2XferUiOps *ui_ops;
-
- g_return_val_if_fail(type != GAIM_XFER_UNKNOWN, NULL);
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(who != NULL, NULL);
-
-- xfer = g_new0(GaimXfer, 1);
-+ xfer = g_new0(Gaim2Xfer, 1);
-
- xfer->ref = 1;
- xfer->type = type;
- xfer->account = account;
- xfer->who = g_strdup(who);
-- xfer->ui_ops = gaim_xfers_get_ui_ops();
-+ xfer->ui_ops = gaim2_xfers_get_ui_ops();
- xfer->message = NULL;
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->new_xfer != NULL)
- ui_ops->new_xfer(xfer);
-@@ -61,19 +61,19 @@ gaim_xfer_new(GaimAccount *account, Gaim
- }
-
- static void
--gaim_xfer_destroy(GaimXfer *xfer)
-+gaim2_xfer_destroy(Gaim2Xfer *xfer)
- {
-- GaimXferUiOps *ui_ops;
-+ Gaim2XferUiOps *ui_ops;
-
- g_return_if_fail(xfer != NULL);
-
- /* Close the file browser, if it's open */
-- gaim_request_close_with_handle(xfer);
-+ gaim2_request_close_with_handle(xfer);
-
-- if (gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_STARTED)
-- gaim_xfer_cancel_local(xfer);
-+ if (gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_STARTED)
-+ gaim2_xfer_cancel_local(xfer);
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->destroy != NULL)
- ui_ops->destroy(xfer);
-@@ -87,7 +87,7 @@ gaim_xfer_destroy(GaimXfer *xfer)
- }
-
- void
--gaim_xfer_ref(GaimXfer *xfer)
-+gaim2_xfer_ref(Gaim2Xfer *xfer)
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -95,7 +95,7 @@ gaim_xfer_ref(GaimXfer *xfer)
- }
-
- void
--gaim_xfer_unref(GaimXfer *xfer)
-+gaim2_xfer_unref(Gaim2Xfer *xfer)
- {
- g_return_if_fail(xfer != NULL);
- g_return_if_fail(xfer->ref > 0);
-@@ -103,28 +103,28 @@ gaim_xfer_unref(GaimXfer *xfer)
- xfer->ref--;
-
- if (xfer->ref == 0)
-- gaim_xfer_destroy(xfer);
-+ gaim2_xfer_destroy(xfer);
- }
-
- static void
--gaim_xfer_set_status(GaimXfer *xfer, GaimXferStatusType status)
-+gaim2_xfer_set_status(Gaim2Xfer *xfer, Gaim2XferStatusType status)
- {
- g_return_if_fail(xfer != NULL);
-
- if(xfer->type == GAIM_XFER_SEND) {
- switch(status) {
- case GAIM_XFER_STATUS_ACCEPTED:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-send-accept", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-send-accept", xfer);
- break;
- case GAIM_XFER_STATUS_STARTED:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-send-start", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-send-start", xfer);
- break;
- case GAIM_XFER_STATUS_DONE:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-send-complete", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-send-complete", xfer);
- break;
- case GAIM_XFER_STATUS_CANCEL_LOCAL:
- case GAIM_XFER_STATUS_CANCEL_REMOTE:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-send-cancel", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-send-cancel", xfer);
- break;
- default:
- break;
-@@ -132,17 +132,17 @@ gaim_xfer_set_status(GaimXfer *xfer, Gai
- } else if(xfer->type == GAIM_XFER_RECEIVE) {
- switch(status) {
- case GAIM_XFER_STATUS_ACCEPTED:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-recv-accept", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-recv-accept", xfer);
- break;
- case GAIM_XFER_STATUS_STARTED:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-recv-start", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-recv-start", xfer);
- break;
- case GAIM_XFER_STATUS_DONE:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-recv-complete", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-recv-complete", xfer);
- break;
- case GAIM_XFER_STATUS_CANCEL_LOCAL:
- case GAIM_XFER_STATUS_CANCEL_REMOTE:
-- gaim_signal_emit(gaim_xfers_get_handle(), "file-recv-cancel", xfer);
-+ gaim2_signal_emit(gaim2_xfers_get_handle(), "file-recv-cancel", xfer);
- break;
- default:
- break;
-@@ -152,17 +152,17 @@ gaim_xfer_set_status(GaimXfer *xfer, Gai
- xfer->status = status;
- }
-
--void gaim_xfer_conversation_write(GaimXfer *xfer, char *message, gboolean is_error)
-+void gaim2_xfer_conversation_write(Gaim2Xfer *xfer, char *message, gboolean is_error)
- {
-- GaimConversation *conv = NULL;
-- GaimMessageFlags flags = GAIM_MESSAGE_SYSTEM;
-+ Gaim2Conversation *conv = NULL;
-+ Gaim2MessageFlags flags = GAIM_MESSAGE_SYSTEM;
- char *escaped;
-
- g_return_if_fail(xfer != NULL);
- g_return_if_fail(message != NULL);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, xfer->who,
-- gaim_xfer_get_account(xfer));
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, xfer->who,
-+ gaim2_xfer_get_account(xfer));
-
- if (conv == NULL)
- return;
-@@ -172,16 +172,16 @@ void gaim_xfer_conversation_write(GaimXf
- if (is_error)
- flags = GAIM_MESSAGE_ERROR;
-
-- gaim_conversation_write(conv, NULL, escaped, flags, time(NULL));
-+ gaim2_conversation_write(conv, NULL, escaped, flags, time(NULL));
- g_free(escaped);
- }
-
--static void gaim_xfer_show_file_error(GaimXfer *xfer, const char *filename)
-+static void gaim2_xfer_show_file_error(Gaim2Xfer *xfer, const char *filename)
- {
- int err = errno;
- gchar *msg = NULL, *utf8;
-- GaimXferType xfer_type = gaim_xfer_get_type(xfer);
-- GaimAccount *account = gaim_xfer_get_account(xfer);
-+ Gaim2XferType xfer_type = gaim2_xfer_get_type(xfer);
-+ Gaim2Account *account = gaim2_xfer_get_account(xfer);
-
- utf8 = g_filename_to_utf8(filename, -1, NULL, NULL, NULL);
- switch(xfer_type) {
-@@ -200,167 +200,167 @@ static void gaim_xfer_show_file_error(Ga
- }
- g_free(utf8);
-
-- gaim_xfer_conversation_write(xfer, msg, TRUE);
-- gaim_xfer_error(xfer_type, account, xfer->who, msg);
-+ gaim2_xfer_conversation_write(xfer, msg, TRUE);
-+ gaim2_xfer_error(xfer_type, account, xfer->who, msg);
- g_free(msg);
- }
-
- static void
--gaim_xfer_choose_file_ok_cb(void *user_data, const char *filename)
-+gaim2_xfer_choose_file_ok_cb(void *user_data, const char *filename)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct stat st;
-
-- xfer = (GaimXfer *)user_data;
-+ xfer = (Gaim2Xfer *)user_data;
-
- if (g_stat(filename, &st) != 0) {
- /* File not found. */
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-- gaim_xfer_request_accepted(xfer, filename);
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ gaim2_xfer_request_accepted(xfer, filename);
- }
- else {
-- gaim_xfer_show_file_error(xfer, filename);
-- gaim_xfer_request_denied(xfer);
-+ gaim2_xfer_show_file_error(xfer, filename);
-+ gaim2_xfer_request_denied(xfer);
- }
- }
-- else if ((gaim_xfer_get_type(xfer) == GAIM_XFER_SEND) &&
-+ else if ((gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND) &&
- (st.st_size == 0)) {
-
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("Cannot send a file of 0 bytes."), NULL);
-
-- gaim_xfer_request_denied(xfer);
-+ gaim2_xfer_request_denied(xfer);
- }
-- else if ((gaim_xfer_get_type(xfer) == GAIM_XFER_SEND) &&
-+ else if ((gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND) &&
- S_ISDIR(st.st_mode)) {
- /*
- * XXX - Sending a directory should be valid for some protocols.
- */
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("Cannot send a directory."), NULL);
-
-- gaim_xfer_request_denied(xfer);
-+ gaim2_xfer_request_denied(xfer);
- }
-- else if ((gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) &&
-+ else if ((gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) &&
- S_ISDIR(st.st_mode)) {
- char *msg, *utf8;
- utf8 = g_filename_to_utf8(filename, -1, NULL, NULL, NULL);
- msg = g_strdup_printf(
- _("%s is not a regular file. Cowardly refusing to overwrite it.\n"), utf8);
- g_free(utf8);
-- gaim_notify_error(NULL, NULL, msg, NULL);
-+ gaim2_notify_error(NULL, NULL, msg, NULL);
- g_free(msg);
-- gaim_xfer_request_denied(xfer);
-+ gaim2_xfer_request_denied(xfer);
- }
- else {
-- gaim_xfer_request_accepted(xfer, filename);
-+ gaim2_xfer_request_accepted(xfer, filename);
- }
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-
- static void
--gaim_xfer_choose_file_cancel_cb(void *user_data, const char *filename)
-+gaim2_xfer_choose_file_cancel_cb(void *user_data, const char *filename)
- {
-- GaimXfer *xfer = (GaimXfer *)user_data;
-+ Gaim2Xfer *xfer = (Gaim2Xfer *)user_data;
-
-- gaim_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_LOCAL);
-- gaim_xfer_request_denied(xfer);
-+ gaim2_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_LOCAL);
-+ gaim2_xfer_request_denied(xfer);
- }
-
- static int
--gaim_xfer_choose_file(GaimXfer *xfer)
-+gaim2_xfer_choose_file(Gaim2Xfer *xfer)
- {
-- gaim_request_file(xfer, NULL, gaim_xfer_get_filename(xfer),
-- (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE),
-- G_CALLBACK(gaim_xfer_choose_file_ok_cb),
-- G_CALLBACK(gaim_xfer_choose_file_cancel_cb), xfer);
-+ gaim2_request_file(xfer, NULL, gaim2_xfer_get_filename(xfer),
-+ (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE),
-+ G_CALLBACK(gaim2_xfer_choose_file_ok_cb),
-+ G_CALLBACK(gaim2_xfer_choose_file_cancel_cb), xfer);
-
- return 0;
- }
-
- static int
--cancel_recv_cb(GaimXfer *xfer)
-+cancel_recv_cb(Gaim2Xfer *xfer)
- {
-- gaim_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_LOCAL);
-- gaim_xfer_request_denied(xfer);
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_LOCAL);
-+ gaim2_xfer_request_denied(xfer);
-+ gaim2_xfer_unref(xfer);
-
- return 0;
- }
-
- static void
--gaim_xfer_ask_recv(GaimXfer *xfer)
-+gaim2_xfer_ask_recv(Gaim2Xfer *xfer)
- {
- char *buf, *size_buf;
- size_t size;
-
- /* If we have already accepted the request, ask the destination file
- name directly */
-- if (gaim_xfer_get_status(xfer) != GAIM_XFER_STATUS_ACCEPTED) {
-- GaimBuddy *buddy = gaim_find_buddy(xfer->account, xfer->who);
-+ if (gaim2_xfer_get_status(xfer) != GAIM_XFER_STATUS_ACCEPTED) {
-+ Gaim2Buddy *buddy = gaim2_find_buddy(xfer->account, xfer->who);
-
-- if (gaim_xfer_get_filename(xfer) != NULL)
-+ if (gaim2_xfer_get_filename(xfer) != NULL)
- {
-- size = gaim_xfer_get_size(xfer);
-- size_buf = gaim_str_size_to_units(size);
-+ size = gaim2_xfer_get_size(xfer);
-+ size_buf = gaim2_str_size_to_units(size);
- buf = g_strdup_printf(_("%s wants to send you %s (%s)"),
-- buddy ? gaim_buddy_get_alias(buddy) : xfer->who,
-- gaim_xfer_get_filename(xfer), size_buf);
-+ buddy ? gaim2_buddy_get_alias(buddy) : xfer->who,
-+ gaim2_xfer_get_filename(xfer), size_buf);
- g_free(size_buf);
- }
- else
- {
- buf = g_strdup_printf(_("%s wants to send you a file"),
-- buddy ? gaim_buddy_get_alias(buddy) : xfer->who);
-+ buddy ? gaim2_buddy_get_alias(buddy) : xfer->who);
- }
-
- if (xfer->message != NULL)
-- serv_got_im(gaim_account_get_connection(xfer->account),
-+ serv_got_im(gaim2_account_get_connection(xfer->account),
- xfer->who, xfer->message, 0, time(NULL));
-
-- gaim_request_accept_cancel(xfer, NULL, buf, NULL,
-+ gaim2_request_accept_cancel(xfer, NULL, buf, NULL,
- GAIM_DEFAULT_ACTION_NONE, xfer,
-- G_CALLBACK(gaim_xfer_choose_file),
-+ G_CALLBACK(gaim2_xfer_choose_file),
- G_CALLBACK(cancel_recv_cb));
-
- g_free(buf);
- } else
-- gaim_xfer_choose_file(xfer);
-+ gaim2_xfer_choose_file(xfer);
- }
-
- static int
--ask_accept_ok(GaimXfer *xfer)
-+ask_accept_ok(Gaim2Xfer *xfer)
- {
-- gaim_xfer_request_accepted(xfer, NULL);
-+ gaim2_xfer_request_accepted(xfer, NULL);
-
- return 0;
- }
-
- static int
--ask_accept_cancel(GaimXfer *xfer)
-+ask_accept_cancel(Gaim2Xfer *xfer)
- {
-- gaim_xfer_request_denied(xfer);
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_request_denied(xfer);
-+ gaim2_xfer_unref(xfer);
-
- return 0;
- }
-
- static void
--gaim_xfer_ask_accept(GaimXfer *xfer)
-+gaim2_xfer_ask_accept(Gaim2Xfer *xfer)
- {
- char *buf, *buf2 = NULL;
-- GaimBuddy *buddy = gaim_find_buddy(xfer->account, xfer->who);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(xfer->account, xfer->who);
-
- buf = g_strdup_printf(_("Accept file transfer request from %s?"),
-- buddy ? gaim_buddy_get_alias(buddy) : xfer->who);
-- if (gaim_xfer_get_remote_ip(xfer) &&
-- gaim_xfer_get_remote_port(xfer))
-+ buddy ? gaim2_buddy_get_alias(buddy) : xfer->who);
-+ if (gaim2_xfer_get_remote_ip(xfer) &&
-+ gaim2_xfer_get_remote_port(xfer))
- buf2 = g_strdup_printf(_("A file is available for download from:\n"
- "Remote host: %s\nRemote port: %d"),
-- gaim_xfer_get_remote_ip(xfer),
-- gaim_xfer_get_remote_port(xfer));
-- gaim_request_accept_cancel(xfer, NULL, buf, buf2,
-+ gaim2_xfer_get_remote_ip(xfer),
-+ gaim2_xfer_get_remote_port(xfer));
-+ gaim2_request_accept_cancel(xfer, NULL, buf, buf2,
- GAIM_DEFAULT_ACTION_NONE, xfer,
- G_CALLBACK(ask_accept_ok),
- G_CALLBACK(ask_accept_cancel));
-@@ -369,43 +369,43 @@ gaim_xfer_ask_accept(GaimXfer *xfer)
- }
-
- void
--gaim_xfer_request(GaimXfer *xfer)
-+gaim2_xfer_request(Gaim2Xfer *xfer)
- {
- g_return_if_fail(xfer != NULL);
- g_return_if_fail(xfer->ops.init != NULL);
-
-- gaim_xfer_ref(xfer);
-+ gaim2_xfer_ref(xfer);
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-- if (gaim_xfer_get_filename(xfer) ||
-- gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_ACCEPTED) {
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ if (gaim2_xfer_get_filename(xfer) ||
-+ gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_ACCEPTED) {
- gchar* message = NULL;
- message = g_strdup_printf(_("%s is offering to send file %s"),
-- xfer->who, gaim_xfer_get_filename(xfer));
-- gaim_xfer_conversation_write(xfer, message, FALSE);
-+ xfer->who, gaim2_xfer_get_filename(xfer));
-+ gaim2_xfer_conversation_write(xfer, message, FALSE);
- g_free(message);
-- gaim_xfer_ask_recv(xfer);
-+ gaim2_xfer_ask_recv(xfer);
- } else {
-- gaim_xfer_ask_accept(xfer);
-+ gaim2_xfer_ask_accept(xfer);
- }
- } else
-- gaim_xfer_choose_file(xfer);
-+ gaim2_xfer_choose_file(xfer);
- }
-
- void
--gaim_xfer_request_accepted(GaimXfer *xfer, const char *filename)
-+gaim2_xfer_request_accepted(Gaim2Xfer *xfer, const char *filename)
- {
-- GaimXferType type;
-+ Gaim2XferType type;
- struct stat st;
- char *msg, *utf8;
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
-
- if (xfer == NULL)
- return;
-
-- type = gaim_xfer_get_type(xfer);
-- account = gaim_xfer_get_account(xfer);
-+ type = gaim2_xfer_get_type(xfer);
-+ account = gaim2_xfer_get_account(xfer);
-
- if (!filename && type == GAIM_XFER_RECEIVE) {
- xfer->status = GAIM_XFER_STATUS_ACCEPTED;
-@@ -413,7 +413,7 @@ gaim_xfer_request_accepted(GaimXfer *xfe
- return;
- }
-
-- buddy = gaim_find_buddy(account, xfer->who);
-+ buddy = gaim2_find_buddy(account, xfer->who);
-
- if (type == GAIM_XFER_SEND) {
- /* Check the filename. */
-@@ -425,77 +425,77 @@ gaim_xfer_request_accepted(GaimXfer *xfe
- char *utf8 = g_filename_to_utf8(filename, -1, NULL, NULL, NULL);
-
- msg = g_strdup_printf(_("%s is not a valid filename.\n"), utf8);
-- gaim_xfer_error(type, account, xfer->who, msg);
-+ gaim2_xfer_error(type, account, xfer->who, msg);
- g_free(utf8);
- g_free(msg);
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- return;
- }
-
- if (g_stat(filename, &st) == -1) {
-- gaim_xfer_show_file_error(xfer, filename);
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_show_file_error(xfer, filename);
-+ gaim2_xfer_unref(xfer);
- return;
- }
-
-- gaim_xfer_set_local_filename(xfer, filename);
-- gaim_xfer_set_size(xfer, st.st_size);
-+ gaim2_xfer_set_local_filename(xfer, filename);
-+ gaim2_xfer_set_size(xfer, st.st_size);
-
- utf8 = g_filename_to_utf8(g_basename(filename), -1, NULL, NULL, NULL);
-- gaim_xfer_set_filename(xfer, utf8);
-+ gaim2_xfer_set_filename(xfer, utf8);
-
- msg = g_strdup_printf(_("Offering to send %s to %s"),
-- utf8, buddy ? gaim_buddy_get_alias(buddy) : xfer->who);
-+ utf8, buddy ? gaim2_buddy_get_alias(buddy) : xfer->who);
- g_free(utf8);
-
-- gaim_xfer_conversation_write(xfer, msg, FALSE);
-+ gaim2_xfer_conversation_write(xfer, msg, FALSE);
- g_free(msg);
- }
- else {
- xfer->status = GAIM_XFER_STATUS_ACCEPTED;
-- gaim_xfer_set_local_filename(xfer, filename);
-+ gaim2_xfer_set_local_filename(xfer, filename);
-
- msg = g_strdup_printf(_("Starting transfer of %s from %s"),
-- xfer->filename, buddy ? gaim_buddy_get_alias(buddy) : xfer->who);
-- gaim_xfer_conversation_write(xfer, msg, FALSE);
-+ xfer->filename, buddy ? gaim2_buddy_get_alias(buddy) : xfer->who);
-+ gaim2_xfer_conversation_write(xfer, msg, FALSE);
- g_free(msg);
- }
-
-- gaim_xfer_add(xfer);
-+ gaim2_xfer_add(xfer);
- xfer->ops.init(xfer);
-
- }
-
- void
--gaim_xfer_request_denied(GaimXfer *xfer)
-+gaim2_xfer_request_denied(Gaim2Xfer *xfer)
- {
- g_return_if_fail(xfer != NULL);
-
- if (xfer->ops.request_denied != NULL)
- xfer->ops.request_denied(xfer);
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-
--GaimXferType
--gaim_xfer_get_type(const GaimXfer *xfer)
-+Gaim2XferType
-+gaim2_xfer_get_type(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, GAIM_XFER_UNKNOWN);
-
- return xfer->type;
- }
-
--GaimAccount *
--gaim_xfer_get_account(const GaimXfer *xfer)
-+Gaim2Account *
-+gaim2_xfer_get_account(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, NULL);
-
- return xfer->account;
- }
-
--GaimXferStatusType
--gaim_xfer_get_status(const GaimXfer *xfer)
-+Gaim2XferStatusType
-+gaim2_xfer_get_status(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, GAIM_XFER_STATUS_UNKNOWN);
-
-@@ -503,27 +503,27 @@ gaim_xfer_get_status(const GaimXfer *xfe
- }
-
- gboolean
--gaim_xfer_is_canceled(const GaimXfer *xfer)
-+gaim2_xfer_is_canceled(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, TRUE);
-
-- if ((gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_LOCAL) ||
-- (gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_REMOTE))
-+ if ((gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_LOCAL) ||
-+ (gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_REMOTE))
- return TRUE;
- else
- return FALSE;
- }
-
- gboolean
--gaim_xfer_is_completed(const GaimXfer *xfer)
-+gaim2_xfer_is_completed(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, TRUE);
-
-- return (gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_DONE);
-+ return (gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_DONE);
- }
-
- const char *
--gaim_xfer_get_filename(const GaimXfer *xfer)
-+gaim2_xfer_get_filename(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, NULL);
-
-@@ -531,7 +531,7 @@ gaim_xfer_get_filename(const GaimXfer *x
- }
-
- const char *
--gaim_xfer_get_local_filename(const GaimXfer *xfer)
-+gaim2_xfer_get_local_filename(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, NULL);
-
-@@ -539,7 +539,7 @@ gaim_xfer_get_local_filename(const GaimX
- }
-
- size_t
--gaim_xfer_get_bytes_sent(const GaimXfer *xfer)
-+gaim2_xfer_get_bytes_sent(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, 0);
-
-@@ -547,7 +547,7 @@ gaim_xfer_get_bytes_sent(const GaimXfer
- }
-
- size_t
--gaim_xfer_get_bytes_remaining(const GaimXfer *xfer)
-+gaim2_xfer_get_bytes_remaining(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, 0);
-
-@@ -555,7 +555,7 @@ gaim_xfer_get_bytes_remaining(const Gaim
- }
-
- size_t
--gaim_xfer_get_size(const GaimXfer *xfer)
-+gaim2_xfer_get_size(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, 0);
-
-@@ -563,19 +563,19 @@ gaim_xfer_get_size(const GaimXfer *xfer)
- }
-
- double
--gaim_xfer_get_progress(const GaimXfer *xfer)
-+gaim2_xfer_get_progress(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, 0.0);
-
-- if (gaim_xfer_get_size(xfer) == 0)
-+ if (gaim2_xfer_get_size(xfer) == 0)
- return 0.0;
-
-- return ((double)gaim_xfer_get_bytes_sent(xfer) /
-- (double)gaim_xfer_get_size(xfer));
-+ return ((double)gaim2_xfer_get_bytes_sent(xfer) /
-+ (double)gaim2_xfer_get_size(xfer));
- }
-
- unsigned int
--gaim_xfer_get_local_port(const GaimXfer *xfer)
-+gaim2_xfer_get_local_port(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, -1);
-
-@@ -583,7 +583,7 @@ gaim_xfer_get_local_port(const GaimXfer
- }
-
- const char *
--gaim_xfer_get_remote_ip(const GaimXfer *xfer)
-+gaim2_xfer_get_remote_ip(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, NULL);
-
-@@ -591,7 +591,7 @@ gaim_xfer_get_remote_ip(const GaimXfer *
- }
-
- unsigned int
--gaim_xfer_get_remote_port(const GaimXfer *xfer)
-+gaim2_xfer_get_remote_port(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, -1);
-
-@@ -599,33 +599,33 @@ gaim_xfer_get_remote_port(const GaimXfer
- }
-
- void
--gaim_xfer_set_completed(GaimXfer *xfer, gboolean completed)
-+gaim2_xfer_set_completed(Gaim2Xfer *xfer, gboolean completed)
- {
-- GaimXferUiOps *ui_ops;
-+ Gaim2XferUiOps *ui_ops;
-
- g_return_if_fail(xfer != NULL);
-
- if (completed == TRUE) {
- char *msg = NULL;
-- gaim_xfer_set_status(xfer, GAIM_XFER_STATUS_DONE);
-+ gaim2_xfer_set_status(xfer, GAIM_XFER_STATUS_DONE);
-
-- if (gaim_xfer_get_filename(xfer) != NULL)
-+ if (gaim2_xfer_get_filename(xfer) != NULL)
- msg = g_strdup_printf(_("Transfer of file %s complete"),
-- gaim_xfer_get_filename(xfer));
-+ gaim2_xfer_get_filename(xfer));
- else
- msg = g_strdup_printf(_("File transfer complete"));
-- gaim_xfer_conversation_write(xfer, msg, FALSE);
-+ gaim2_xfer_conversation_write(xfer, msg, FALSE);
- g_free(msg);
- }
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->update_progress != NULL)
-- ui_ops->update_progress(xfer, gaim_xfer_get_progress(xfer));
-+ ui_ops->update_progress(xfer, gaim2_xfer_get_progress(xfer));
- }
-
- void
--gaim_xfer_set_message(GaimXfer *xfer, const char *message)
-+gaim2_xfer_set_message(Gaim2Xfer *xfer, const char *message)
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -638,7 +638,7 @@ gaim_xfer_set_message(GaimXfer *xfer, co
- }
-
- void
--gaim_xfer_set_filename(GaimXfer *xfer, const char *filename)
-+gaim2_xfer_set_filename(Gaim2Xfer *xfer, const char *filename)
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -649,7 +649,7 @@ gaim_xfer_set_filename(GaimXfer *xfer, c
- }
-
- void
--gaim_xfer_set_local_filename(GaimXfer *xfer, const char *filename)
-+gaim2_xfer_set_local_filename(Gaim2Xfer *xfer, const char *filename)
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -660,7 +660,7 @@ gaim_xfer_set_local_filename(GaimXfer *x
- }
-
- void
--gaim_xfer_set_size(GaimXfer *xfer, size_t size)
-+gaim2_xfer_set_size(Gaim2Xfer *xfer, size_t size)
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -670,8 +670,8 @@ gaim_xfer_set_size(GaimXfer *xfer, size_
- xfer->size = size;
- }
-
--GaimXferUiOps *
--gaim_xfer_get_ui_ops(const GaimXfer *xfer)
-+Gaim2XferUiOps *
-+gaim2_xfer_get_ui_ops(const Gaim2Xfer *xfer)
- {
- g_return_val_if_fail(xfer != NULL, NULL);
-
-@@ -679,14 +679,14 @@ gaim_xfer_get_ui_ops(const GaimXfer *xfe
- }
-
- void
--gaim_xfer_set_init_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *))
-+gaim2_xfer_set_init_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
- xfer->ops.init = fnc;
- }
-
--void gaim_xfer_set_request_denied_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *))
-+void gaim2_xfer_set_request_denied_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -694,7 +694,7 @@ void gaim_xfer_set_request_denied_fnc(Ga
- }
-
- void
--gaim_xfer_set_read_fnc(GaimXfer *xfer, gssize (*fnc)(guchar **, GaimXfer *))
-+gaim2_xfer_set_read_fnc(Gaim2Xfer *xfer, gssize (*fnc)(guchar **, Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -702,8 +702,8 @@ gaim_xfer_set_read_fnc(GaimXfer *xfer, g
- }
-
- void
--gaim_xfer_set_write_fnc(GaimXfer *xfer,
-- gssize (*fnc)(const guchar *, size_t, GaimXfer *))
-+gaim2_xfer_set_write_fnc(Gaim2Xfer *xfer,
-+ gssize (*fnc)(const guchar *, size_t, Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -711,8 +711,8 @@ gaim_xfer_set_write_fnc(GaimXfer *xfer,
- }
-
- void
--gaim_xfer_set_ack_fnc(GaimXfer *xfer,
-- void (*fnc)(GaimXfer *, const guchar *, size_t))
-+gaim2_xfer_set_ack_fnc(Gaim2Xfer *xfer,
-+ void (*fnc)(Gaim2Xfer *, const guchar *, size_t))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -720,7 +720,7 @@ gaim_xfer_set_ack_fnc(GaimXfer *xfer,
- }
-
- void
--gaim_xfer_set_start_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *))
-+gaim2_xfer_set_start_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -728,7 +728,7 @@ gaim_xfer_set_start_fnc(GaimXfer *xfer,
- }
-
- void
--gaim_xfer_set_end_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *))
-+gaim2_xfer_set_end_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -736,7 +736,7 @@ gaim_xfer_set_end_fnc(GaimXfer *xfer, vo
- }
-
- void
--gaim_xfer_set_cancel_send_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *))
-+gaim2_xfer_set_cancel_send_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -744,7 +744,7 @@ gaim_xfer_set_cancel_send_fnc(GaimXfer *
- }
-
- void
--gaim_xfer_set_cancel_recv_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *))
-+gaim2_xfer_set_cancel_recv_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *))
- {
- g_return_if_fail(xfer != NULL);
-
-@@ -752,17 +752,17 @@ gaim_xfer_set_cancel_recv_fnc(GaimXfer *
- }
-
- gssize
--gaim_xfer_read(GaimXfer *xfer, guchar **buffer)
-+gaim2_xfer_read(Gaim2Xfer *xfer, guchar **buffer)
- {
- gssize s, r;
-
- g_return_val_if_fail(xfer != NULL, 0);
- g_return_val_if_fail(buffer != NULL, 0);
-
-- if (gaim_xfer_get_size(xfer) == 0)
-+ if (gaim2_xfer_get_size(xfer) == 0)
- s = 4096;
- else
-- s = MIN(gaim_xfer_get_bytes_remaining(xfer), 4096);
-+ s = MIN(gaim2_xfer_get_bytes_remaining(xfer), 4096);
-
- if (xfer->ops.read != NULL)
- r = (xfer->ops.read)(buffer, xfer);
-@@ -770,9 +770,9 @@ gaim_xfer_read(GaimXfer *xfer, guchar **
- *buffer = g_malloc0(s);
-
- r = read(xfer->fd, *buffer, s);
-- if ((gaim_xfer_get_size(xfer) > 0) &&
-- ((gaim_xfer_get_bytes_sent(xfer)+r) >= gaim_xfer_get_size(xfer)))
-- gaim_xfer_set_completed(xfer, TRUE);
-+ if ((gaim2_xfer_get_size(xfer) > 0) &&
-+ ((gaim2_xfer_get_bytes_sent(xfer)+r) >= gaim2_xfer_get_size(xfer)))
-+ gaim2_xfer_set_completed(xfer, TRUE);
- else if(r <= 0)
- r = -1;
- }
-@@ -781,7 +781,7 @@ gaim_xfer_read(GaimXfer *xfer, guchar **
- }
-
- gssize
--gaim_xfer_write(GaimXfer *xfer, const guchar *buffer, size_t size)
-+gaim2_xfer_write(Gaim2Xfer *xfer, const guchar *buffer, size_t size)
- {
- gssize r, s;
-
-@@ -789,45 +789,45 @@ gaim_xfer_write(GaimXfer *xfer, const gu
- g_return_val_if_fail(buffer != NULL, 0);
- g_return_val_if_fail(size != 0, 0);
-
-- s = MIN(gaim_xfer_get_bytes_remaining(xfer), size);
-+ s = MIN(gaim2_xfer_get_bytes_remaining(xfer), size);
-
- if (xfer->ops.write != NULL) {
- r = (xfer->ops.write)(buffer, s, xfer);
- } else {
- r = write(xfer->fd, buffer, s);
-- if ((gaim_xfer_get_bytes_sent(xfer)+r) >= gaim_xfer_get_size(xfer))
-- gaim_xfer_set_completed(xfer, TRUE);
-+ if ((gaim2_xfer_get_bytes_sent(xfer)+r) >= gaim2_xfer_get_size(xfer))
-+ gaim2_xfer_set_completed(xfer, TRUE);
- }
-
- return r;
- }
-
- static void
--transfer_cb(gpointer data, gint source, GaimInputCondition condition)
-+transfer_cb(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimXferUiOps *ui_ops;
-- GaimXfer *xfer = (GaimXfer *)data;
-+ Gaim2XferUiOps *ui_ops;
-+ Gaim2Xfer *xfer = (Gaim2Xfer *)data;
- guchar *buffer = NULL;
- gssize r = 0;
-
- if (condition & GAIM_INPUT_READ) {
-- r = gaim_xfer_read(xfer, &buffer);
-+ r = gaim2_xfer_read(xfer, &buffer);
- if (r > 0) {
- fwrite(buffer, 1, r, xfer->dest_fp);
- } else if(r < 0) {
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
- }
-
- if (condition & GAIM_INPUT_WRITE) {
-- size_t s = MIN(gaim_xfer_get_bytes_remaining(xfer), 4096);
-+ size_t s = MIN(gaim2_xfer_get_bytes_remaining(xfer), 4096);
-
- /* this is so the prpl can keep the connection open
- if it needs to for some odd reason. */
- if (s == 0) {
- if (xfer->watcher) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- }
- return;
-@@ -838,10 +838,10 @@ transfer_cb(gpointer data, gint source,
- fread(buffer, 1, s, xfer->dest_fp);
-
- /* Write as much as we're allowed to. */
-- r = gaim_xfer_write(xfer, buffer, s);
-+ r = gaim2_xfer_write(xfer, buffer, s);
-
- if (r == -1) {
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- g_free(buffer);
- return;
- } else if (r < s) {
-@@ -850,7 +850,7 @@ transfer_cb(gpointer data, gint source,
- }
- }
-
-- if (gaim_xfer_get_size(xfer) > 0)
-+ if (gaim2_xfer_get_size(xfer) > 0)
- xfer->bytes_remaining -= r;
-
- xfer->bytes_sent += r;
-@@ -860,39 +860,39 @@ transfer_cb(gpointer data, gint source,
-
- g_free(buffer);
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->update_progress != NULL)
-- ui_ops->update_progress(xfer, gaim_xfer_get_progress(xfer));
-+ ui_ops->update_progress(xfer, gaim2_xfer_get_progress(xfer));
-
-- if (gaim_xfer_is_completed(xfer))
-- gaim_xfer_end(xfer);
-+ if (gaim2_xfer_is_completed(xfer))
-+ gaim2_xfer_end(xfer);
- }
-
- static void
--begin_transfer(GaimXfer *xfer, GaimInputCondition cond)
-+begin_transfer(Gaim2Xfer *xfer, Gaim2InputCondition cond)
- {
-- GaimXferType type = gaim_xfer_get_type(xfer);
-+ Gaim2XferType type = gaim2_xfer_get_type(xfer);
-
-- xfer->dest_fp = g_fopen(gaim_xfer_get_local_filename(xfer),
-+ xfer->dest_fp = g_fopen(gaim2_xfer_get_local_filename(xfer),
- type == GAIM_XFER_RECEIVE ? "wb" : "rb");
-
- if (xfer->dest_fp == NULL) {
-- gaim_xfer_show_file_error(xfer, gaim_xfer_get_local_filename(xfer));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_show_file_error(xfer, gaim2_xfer_get_local_filename(xfer));
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-
-- xfer->watcher = gaim_input_add(xfer->fd, cond, transfer_cb, xfer);
-+ xfer->watcher = gaim2_input_add(xfer->fd, cond, transfer_cb, xfer);
-
- if (xfer->ops.start != NULL)
- xfer->ops.start(xfer);
- }
-
- static void
--connect_cb(gpointer data, gint source, GaimInputCondition condition)
-+connect_cb(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimXfer *xfer = (GaimXfer *)data;
-+ Gaim2Xfer *xfer = (Gaim2Xfer *)data;
-
- xfer->fd = source;
-
-@@ -900,21 +900,21 @@ connect_cb(gpointer data, gint source, G
- }
-
- void
--gaim_xfer_start(GaimXfer *xfer, int fd, const char *ip,
-+gaim2_xfer_start(Gaim2Xfer *xfer, int fd, const char *ip,
- unsigned int port)
- {
-- GaimInputCondition cond;
-- GaimXferType type;
-+ Gaim2InputCondition cond;
-+ Gaim2XferType type;
-
- g_return_if_fail(xfer != NULL);
-- g_return_if_fail(gaim_xfer_get_type(xfer) != GAIM_XFER_UNKNOWN);
-+ g_return_if_fail(gaim2_xfer_get_type(xfer) != GAIM_XFER_UNKNOWN);
-
-- type = gaim_xfer_get_type(xfer);
-+ type = gaim2_xfer_get_type(xfer);
-
-- xfer->bytes_remaining = gaim_xfer_get_size(xfer);
-+ xfer->bytes_remaining = gaim2_xfer_get_size(xfer);
- xfer->bytes_sent = 0;
-
-- gaim_xfer_set_status(xfer, GAIM_XFER_STATUS_STARTED);
-+ gaim2_xfer_set_status(xfer, GAIM_XFER_STATUS_STARTED);
-
- if (type == GAIM_XFER_RECEIVE) {
- cond = GAIM_INPUT_READ;
-@@ -924,7 +924,7 @@ gaim_xfer_start(GaimXfer *xfer, int fd,
- xfer->remote_port = port;
-
- /* Establish a file descriptor. */
-- gaim_proxy_connect(xfer->account, xfer->remote_ip,
-+ gaim2_proxy_connect(xfer->account, xfer->remote_ip,
- xfer->remote_port, connect_cb, xfer);
-
- return;
-@@ -943,13 +943,13 @@ gaim_xfer_start(GaimXfer *xfer, int fd,
- }
-
- void
--gaim_xfer_end(GaimXfer *xfer)
-+gaim2_xfer_end(Gaim2Xfer *xfer)
- {
- g_return_if_fail(xfer != NULL);
-
- /* See if we are actually trying to cancel this. */
-- if (gaim_xfer_get_status(xfer) != GAIM_XFER_STATUS_DONE) {
-- gaim_xfer_cancel_local(xfer);
-+ if (gaim2_xfer_get_status(xfer) != GAIM_XFER_STATUS_DONE) {
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-
-@@ -957,7 +957,7 @@ gaim_xfer_end(GaimXfer *xfer)
- xfer->ops.end(xfer);
-
- if (xfer->watcher != 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- }
-
-@@ -969,45 +969,45 @@ gaim_xfer_end(GaimXfer *xfer)
- xfer->dest_fp = NULL;
- }
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-
- void
--gaim_xfer_add(GaimXfer *xfer)
-+gaim2_xfer_add(Gaim2Xfer *xfer)
- {
-- GaimXferUiOps *ui_ops;
-+ Gaim2XferUiOps *ui_ops;
-
- g_return_if_fail(xfer != NULL);
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->add_xfer != NULL)
- ui_ops->add_xfer(xfer);
- }
-
- void
--gaim_xfer_cancel_local(GaimXfer *xfer)
-+gaim2_xfer_cancel_local(Gaim2Xfer *xfer)
- {
-- GaimXferUiOps *ui_ops;
-+ Gaim2XferUiOps *ui_ops;
- char *msg = NULL;
-
- g_return_if_fail(xfer != NULL);
-
-- gaim_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_LOCAL);
-+ gaim2_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_LOCAL);
-
-- if (gaim_xfer_get_filename(xfer) != NULL)
-+ if (gaim2_xfer_get_filename(xfer) != NULL)
- {
- msg = g_strdup_printf(_("You canceled the transfer of %s"),
-- gaim_xfer_get_filename(xfer));
-+ gaim2_xfer_get_filename(xfer));
- }
- else
- {
- msg = g_strdup_printf(_("File transfer cancelled"));
- }
-- gaim_xfer_conversation_write(xfer, msg, FALSE);
-+ gaim2_xfer_conversation_write(xfer, msg, FALSE);
- g_free(msg);
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_SEND)
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND)
- {
- if (xfer->ops.cancel_send != NULL)
- xfer->ops.cancel_send(xfer);
-@@ -1019,7 +1019,7 @@ gaim_xfer_cancel_local(GaimXfer *xfer)
- }
-
- if (xfer->watcher != 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- }
-
-@@ -1031,47 +1031,47 @@ gaim_xfer_cancel_local(GaimXfer *xfer)
- xfer->dest_fp = NULL;
- }
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->cancel_local != NULL)
- ui_ops->cancel_local(xfer);
-
- xfer->bytes_remaining = 0;
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-
- void
--gaim_xfer_cancel_remote(GaimXfer *xfer)
-+gaim2_xfer_cancel_remote(Gaim2Xfer *xfer)
- {
-- GaimXferUiOps *ui_ops;
-+ Gaim2XferUiOps *ui_ops;
- gchar *msg;
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
-
- g_return_if_fail(xfer != NULL);
-
-- gaim_request_close_with_handle(xfer);
-- gaim_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_REMOTE);
-+ gaim2_request_close_with_handle(xfer);
-+ gaim2_xfer_set_status(xfer, GAIM_XFER_STATUS_CANCEL_REMOTE);
-
-- account = gaim_xfer_get_account(xfer);
-- buddy = gaim_find_buddy(account, xfer->who);
-+ account = gaim2_xfer_get_account(xfer);
-+ buddy = gaim2_find_buddy(account, xfer->who);
-
-- if (gaim_xfer_get_filename(xfer) != NULL)
-+ if (gaim2_xfer_get_filename(xfer) != NULL)
- {
- msg = g_strdup_printf(_("%s canceled the transfer of %s"),
-- buddy ? gaim_buddy_get_alias(buddy) : xfer->who, gaim_xfer_get_filename(xfer));
-+ buddy ? gaim2_buddy_get_alias(buddy) : xfer->who, gaim2_xfer_get_filename(xfer));
- }
- else
- {
- msg = g_strdup_printf(_("%s canceled the file transfer"),
-- buddy ? gaim_buddy_get_alias(buddy) : xfer->who);
-+ buddy ? gaim2_buddy_get_alias(buddy) : xfer->who);
- }
-- gaim_xfer_conversation_write(xfer, msg, TRUE);
-- gaim_xfer_error(gaim_xfer_get_type(xfer), account, xfer->who, msg);
-+ gaim2_xfer_conversation_write(xfer, msg, TRUE);
-+ gaim2_xfer_error(gaim2_xfer_get_type(xfer), account, xfer->who, msg);
- g_free(msg);
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_SEND)
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND)
- {
- if (xfer->ops.cancel_send != NULL)
- xfer->ops.cancel_send(xfer);
-@@ -1083,7 +1083,7 @@ gaim_xfer_cancel_remote(GaimXfer *xfer)
- }
-
- if (xfer->watcher != 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- }
-
-@@ -1095,18 +1095,18 @@ gaim_xfer_cancel_remote(GaimXfer *xfer)
- xfer->dest_fp = NULL;
- }
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
-
- if (ui_ops != NULL && ui_ops->cancel_remote != NULL)
- ui_ops->cancel_remote(xfer);
-
- xfer->bytes_remaining = 0;
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-
- void
--gaim_xfer_error(GaimXferType type, GaimAccount *account, const char *who, const char *msg)
-+gaim2_xfer_error(Gaim2XferType type, Gaim2Account *account, const char *who, const char *msg)
- {
- char *title;
-
-@@ -1114,10 +1114,10 @@ gaim_xfer_error(GaimXferType type, GaimA
- g_return_if_fail(type != GAIM_XFER_UNKNOWN);
-
- if (account) {
-- GaimBuddy *buddy;
-- buddy = gaim_find_buddy(account, who);
-+ Gaim2Buddy *buddy;
-+ buddy = gaim2_find_buddy(account, who);
- if (buddy)
-- who = gaim_buddy_get_alias(buddy);
-+ who = gaim2_buddy_get_alias(buddy);
- }
-
- if (type == GAIM_XFER_SEND)
-@@ -1125,21 +1125,21 @@ gaim_xfer_error(GaimXferType type, GaimA
- else
- title = g_strdup_printf(_("File transfer from %s failed."), who);
-
-- gaim_notify_error(NULL, NULL, title, msg);
-+ gaim2_notify_error(NULL, NULL, title, msg);
-
- g_free(title);
- }
-
- void
--gaim_xfer_update_progress(GaimXfer *xfer)
-+gaim2_xfer_update_progress(Gaim2Xfer *xfer)
- {
-- GaimXferUiOps *ui_ops;
-+ Gaim2XferUiOps *ui_ops;
-
- g_return_if_fail(xfer != NULL);
-
-- ui_ops = gaim_xfer_get_ui_ops(xfer);
-+ ui_ops = gaim2_xfer_get_ui_ops(xfer);
- if (ui_ops != NULL && ui_ops->update_progress != NULL)
-- ui_ops->update_progress(xfer, gaim_xfer_get_progress(xfer));
-+ ui_ops->update_progress(xfer, gaim2_xfer_get_progress(xfer));
- }
-
-
-@@ -1147,62 +1147,62 @@ gaim_xfer_update_progress(GaimXfer *xfer
- * File Transfer Subsystem API
- **************************************************************************/
- void *
--gaim_xfers_get_handle(void) {
-+gaim2_xfers_get_handle(void) {
- static int handle = 0;
-
- return &handle;
- }
-
- void
--gaim_xfers_init(void) {
-- void *handle = gaim_xfers_get_handle();
-+gaim2_xfers_init(void) {
-+ void *handle = gaim2_xfers_get_handle();
-
- /* register signals */
-- gaim_signal_register(handle, "file-recv-accept",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_signal_register(handle, "file-recv-accept",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-send-accept",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-send-accept",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-recv-start",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-recv-start",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-send-start",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-send-start",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-send-cancel",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-send-cancel",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-recv-cancel",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-recv-cancel",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-send-complete",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-send-complete",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-- gaim_signal_register(handle, "file-recv-complete",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "file-recv-complete",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
-+ gaim2_value_new(GAIM_TYPE_POINTER));
- }
-
- void
--gaim_xfers_uninit(void) {
-- gaim_signals_disconnect_by_handle(gaim_xfers_get_handle());
-+gaim2_xfers_uninit(void) {
-+ gaim2_signals_disconnect_by_handle(gaim2_xfers_get_handle());
- }
-
- void
--gaim_xfers_set_ui_ops(GaimXferUiOps *ops) {
-+gaim2_xfers_set_ui_ops(Gaim2XferUiOps *ops) {
- xfer_ui_ops = ops;
- }
-
--GaimXferUiOps *
--gaim_xfers_get_ui_ops(void) {
-+Gaim2XferUiOps *
-+gaim2_xfers_get_ui_ops(void) {
- return xfer_ui_ops;
- }
-diff -prNu ./src/ft.h ./src/ft.h
---- ./src/ft.h 2005-11-19 04:16:49.000000000 +0100
-+++ ./src/ft.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file ft.h File Transfer API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,7 +28,7 @@
- /**************************************************************************/
- /** Data Structures */
- /**************************************************************************/
--typedef struct _GaimXfer GaimXfer;
-+typedef struct _Gaim2Xfer Gaim2Xfer;
-
- #include <glib.h>
- #include <stdio.h>
-@@ -44,7 +44,7 @@ typedef enum
- GAIM_XFER_SEND, /**< File sending. */
- GAIM_XFER_RECEIVE /**< File receiving. */
-
--} GaimXferType;
-+} Gaim2XferType;
-
- /**
- * The different states of the xfer.
-@@ -54,38 +54,38 @@ typedef enum
- GAIM_XFER_STATUS_UNKNOWN = 0, /**< Unknown, the xfer may be null. */
- GAIM_XFER_STATUS_NOT_STARTED, /**< It hasn't started yet. */
- GAIM_XFER_STATUS_ACCEPTED, /**< Receive accepted, but destination file not selected yet */
-- GAIM_XFER_STATUS_STARTED, /**< gaim_xfer_start has been called. */
-+ GAIM_XFER_STATUS_STARTED, /**< gaim2_xfer_start has been called. */
- GAIM_XFER_STATUS_DONE, /**< The xfer completed successfully. */
- GAIM_XFER_STATUS_CANCEL_LOCAL, /**< The xfer was canceled by us. */
- GAIM_XFER_STATUS_CANCEL_REMOTE /**< The xfer was canceled by the other end, or we couldn't connect. */
--} GaimXferStatusType;
-+} Gaim2XferStatusType;
-
- /**
- * File transfer UI operations.
- *
- * Any UI representing a file transfer must assign a filled-out
-- * GaimXferUiOps structure to the gaim_xfer.
-+ * Gaim2XferUiOps structure to the gaim2_xfer.
- */
- typedef struct
- {
-- void (*new_xfer)(GaimXfer *xfer);
-- void (*destroy)(GaimXfer *xfer);
-- void (*add_xfer)(GaimXfer *xfer);
-- void (*update_progress)(GaimXfer *xfer, double percent);
-- void (*cancel_local)(GaimXfer *xfer);
-- void (*cancel_remote)(GaimXfer *xfer);
-+ void (*new_xfer)(Gaim2Xfer *xfer);
-+ void (*destroy)(Gaim2Xfer *xfer);
-+ void (*add_xfer)(Gaim2Xfer *xfer);
-+ void (*update_progress)(Gaim2Xfer *xfer, double percent);
-+ void (*cancel_local)(Gaim2Xfer *xfer);
-+ void (*cancel_remote)(Gaim2Xfer *xfer);
-
--} GaimXferUiOps;
-+} Gaim2XferUiOps;
-
- /**
- * A core representation of a file transfer.
- */
--struct _GaimXfer
-+struct _Gaim2Xfer
- {
- guint ref; /**< The reference count. */
-- GaimXferType type; /**< The type of transfer. */
-+ Gaim2XferType type; /**< The type of transfer. */
-
-- GaimAccount *account; /**< The account. */
-+ Gaim2Account *account; /**< The account. */
-
- char *who; /**< The person on the other end of the
- transfer. */
-@@ -107,24 +107,24 @@ struct _GaimXfer
- size_t bytes_sent; /**< The number of bytes sent. */
- size_t bytes_remaining; /**< The number of bytes remaining. */
-
-- GaimXferStatusType status; /**< File Transfer's status. */
-+ Gaim2XferStatusType status; /**< File Transfer's status. */
-
- /* I/O operations. */
- struct
- {
-- void (*init)(GaimXfer *xfer);
-- void (*request_denied)(GaimXfer *xfer);
-- void (*start)(GaimXfer *xfer);
-- void (*end)(GaimXfer *xfer);
-- void (*cancel_send)(GaimXfer *xfer);
-- void (*cancel_recv)(GaimXfer *xfer);
-- gssize (*read)(guchar **buffer, GaimXfer *xfer);
-- gssize (*write)(const guchar *buffer, size_t size, GaimXfer *xfer);
-- void (*ack)(GaimXfer *xfer, const guchar *buffer, size_t size);
-+ void (*init)(Gaim2Xfer *xfer);
-+ void (*request_denied)(Gaim2Xfer *xfer);
-+ void (*start)(Gaim2Xfer *xfer);
-+ void (*end)(Gaim2Xfer *xfer);
-+ void (*cancel_send)(Gaim2Xfer *xfer);
-+ void (*cancel_recv)(Gaim2Xfer *xfer);
-+ gssize (*read)(guchar **buffer, Gaim2Xfer *xfer);
-+ gssize (*write)(const guchar *buffer, size_t size, Gaim2Xfer *xfer);
-+ void (*ack)(Gaim2Xfer *xfer, const guchar *buffer, size_t size);
-
- } ops;
-
-- GaimXferUiOps *ui_ops; /**< UI-specific operations. */
-+ Gaim2XferUiOps *ui_ops; /**< UI-specific operations. */
- void *ui_data; /**< UI-specific data. */
-
- void *data; /**< prpl-specific data. */
-@@ -144,7 +144,7 @@ extern "C" {
- * This is called by prpls.
- * The handle starts with a ref count of 1, and this reference
- * is owned by the core. The prpl normally does not need to
-- * gaim_xfer_ref or unref.
-+ * gaim2_xfer_ref or unref.
- *
- * @param account The account sending or receiving the file.
- * @param type The type of file transfer.
-@@ -152,27 +152,27 @@ extern "C" {
- *
- * @return A file transfer handle.
- */
--GaimXfer *gaim_xfer_new(GaimAccount *account,
-- GaimXferType type, const char *who);
-+Gaim2Xfer *gaim2_xfer_new(Gaim2Account *account,
-+ Gaim2XferType type, const char *who);
-
- /**
-- * Increases the reference count on a GaimXfer.
-- * Please call gaim_xfer_unref later.
-+ * Increases the reference count on a Gaim2Xfer.
-+ * Please call gaim2_xfer_unref later.
- *
- * @param xfer A file transfer handle.
- */
--void gaim_xfer_ref(GaimXfer *xfer);
-+void gaim2_xfer_ref(Gaim2Xfer *xfer);
-
- /**
-- * Decreases the reference count on a GaimXfer.
-- * If the reference reaches 0, gaim_xfer_destroy (an internal function)
-+ * Decreases the reference count on a Gaim2Xfer.
-+ * If the reference reaches 0, gaim2_xfer_destroy (an internal function)
- * will destroy the xfer. It calls the ui destroy cb first.
- * Since the core keeps a ref on the xfer, only an erroneous call to
- * this function will destroy the xfer while still in use.
- *
- * @param xfer A file transfer handle.
- */
--void gaim_xfer_unref(GaimXfer *xfer);
-+void gaim2_xfer_unref(Gaim2Xfer *xfer);
-
- /**
- * Requests confirmation for a file transfer from the user. If receiving
-@@ -183,7 +183,7 @@ void gaim_xfer_unref(GaimXfer *xfer);
- *
- * @param xfer The file transfer to request confirmation on.
- */
--void gaim_xfer_request(GaimXfer *xfer);
-+void gaim2_xfer_request(Gaim2Xfer *xfer);
-
- /**
- * Called if the user accepts the file transfer request.
-@@ -191,14 +191,14 @@ void gaim_xfer_request(GaimXfer *xfer);
- * @param xfer The file transfer.
- * @param filename The filename.
- */
--void gaim_xfer_request_accepted(GaimXfer *xfer, const char *filename);
-+void gaim2_xfer_request_accepted(Gaim2Xfer *xfer, const char *filename);
-
- /**
- * Called if the user rejects the file transfer request.
- *
- * @param xfer The file transfer.
- */
--void gaim_xfer_request_denied(GaimXfer *xfer);
-+void gaim2_xfer_request_denied(Gaim2Xfer *xfer);
-
- /**
- * Returns the type of file transfer.
-@@ -207,7 +207,7 @@ void gaim_xfer_request_denied(GaimXfer *
- *
- * @return The type of the file transfer.
- */
--GaimXferType gaim_xfer_get_type(const GaimXfer *xfer);
-+Gaim2XferType gaim2_xfer_get_type(const Gaim2Xfer *xfer);
-
- /**
- * Returns the account the file transfer is using.
-@@ -216,7 +216,7 @@ GaimXferType gaim_xfer_get_type(const Ga
- *
- * @return The account.
- */
--GaimAccount *gaim_xfer_get_account(const GaimXfer *xfer);
-+Gaim2Account *gaim2_xfer_get_account(const Gaim2Xfer *xfer);
-
- /**
- * Returns the status of the xfer.
-@@ -225,7 +225,7 @@ GaimAccount *gaim_xfer_get_account(const
- *
- * @return The status.
- */
--GaimXferStatusType gaim_xfer_get_status(const GaimXfer *xfer);
-+Gaim2XferStatusType gaim2_xfer_get_status(const Gaim2Xfer *xfer);
-
- /**
- * Returns true if the file transfer was canceled.
-@@ -234,7 +234,7 @@ GaimXferStatusType gaim_xfer_get_status(
- *
- * @return Whether or not the transfer was canceled.
- */
--gboolean gaim_xfer_is_canceled(const GaimXfer *xfer);
-+gboolean gaim2_xfer_is_canceled(const Gaim2Xfer *xfer);
-
- /**
- * Returns the completed state for a file transfer.
-@@ -243,7 +243,7 @@ gboolean gaim_xfer_is_canceled(const Gai
- *
- * @return The completed state.
- */
--gboolean gaim_xfer_is_completed(const GaimXfer *xfer);
-+gboolean gaim2_xfer_is_completed(const Gaim2Xfer *xfer);
-
- /**
- * Returns the name of the file being sent or received.
-@@ -252,7 +252,7 @@ gboolean gaim_xfer_is_completed(const Ga
- *
- * @return The filename.
- */
--const char *gaim_xfer_get_filename(const GaimXfer *xfer);
-+const char *gaim2_xfer_get_filename(const Gaim2Xfer *xfer);
-
- /**
- * Returns the file's destination filename,
-@@ -261,7 +261,7 @@ const char *gaim_xfer_get_filename(const
- *
- * @return The destination filename.
- */
--const char *gaim_xfer_get_local_filename(const GaimXfer *xfer);
-+const char *gaim2_xfer_get_local_filename(const Gaim2Xfer *xfer);
-
- /**
- * Returns the number of bytes sent so far.
-@@ -270,7 +270,7 @@ const char *gaim_xfer_get_local_filename
- *
- * @return The number of bytes sent.
- */
--size_t gaim_xfer_get_bytes_sent(const GaimXfer *xfer);
-+size_t gaim2_xfer_get_bytes_sent(const Gaim2Xfer *xfer);
-
- /**
- * Returns the number of bytes received so far.
-@@ -279,7 +279,7 @@ size_t gaim_xfer_get_bytes_sent(const Ga
- *
- * @return The number of bytes received.
- */
--size_t gaim_xfer_get_bytes_remaining(const GaimXfer *xfer);
-+size_t gaim2_xfer_get_bytes_remaining(const Gaim2Xfer *xfer);
-
- /**
- * Returns the size of the file being sent or received.
-@@ -288,7 +288,7 @@ size_t gaim_xfer_get_bytes_remaining(con
- *
- * @return The total size of the file.
- */
--size_t gaim_xfer_get_size(const GaimXfer *xfer);
-+size_t gaim2_xfer_get_size(const Gaim2Xfer *xfer);
-
- /**
- * Returns the current percentage of progress of the transfer.
-@@ -299,7 +299,7 @@ size_t gaim_xfer_get_size(const GaimXfer
- *
- * @return The percentage complete.
- */
--double gaim_xfer_get_progress(const GaimXfer *xfer);
-+double gaim2_xfer_get_progress(const Gaim2Xfer *xfer);
-
- /**
- * Returns the local port number in the file transfer.
-@@ -308,7 +308,7 @@ double gaim_xfer_get_progress(const Gaim
- *
- * @return The port number on this end.
- */
--unsigned int gaim_xfer_get_local_port(const GaimXfer *xfer);
-+unsigned int gaim2_xfer_get_local_port(const Gaim2Xfer *xfer);
-
- /**
- * Returns the remote IP address in the file transfer.
-@@ -317,7 +317,7 @@ unsigned int gaim_xfer_get_local_port(co
- *
- * @return The IP address on the other end.
- */
--const char *gaim_xfer_get_remote_ip(const GaimXfer *xfer);
-+const char *gaim2_xfer_get_remote_ip(const Gaim2Xfer *xfer);
-
- /**
- * Returns the remote port number in the file transfer.
-@@ -326,7 +326,7 @@ const char *gaim_xfer_get_remote_ip(cons
- *
- * @return The port number on the other end.
- */
--unsigned int gaim_xfer_get_remote_port(const GaimXfer *xfer);
-+unsigned int gaim2_xfer_get_remote_port(const Gaim2Xfer *xfer);
-
- /**
- * Sets the completed state for the file transfer.
-@@ -334,7 +334,7 @@ unsigned int gaim_xfer_get_remote_port(c
- * @param xfer The file transfer.
- * @param completed The completed state.
- */
--void gaim_xfer_set_completed(GaimXfer *xfer, gboolean completed);
-+void gaim2_xfer_set_completed(Gaim2Xfer *xfer, gboolean completed);
-
- /**
- * Sets the filename for the file transfer.
-@@ -342,7 +342,7 @@ void gaim_xfer_set_completed(GaimXfer *x
- * @param xfer The file transfer.
- * @param message The message.
- */
--void gaim_xfer_set_message(GaimXfer *xfer, const char *message);
-+void gaim2_xfer_set_message(Gaim2Xfer *xfer, const char *message);
-
- /**
- * Sets the filename for the file transfer.
-@@ -350,7 +350,7 @@ void gaim_xfer_set_message(GaimXfer *xfe
- * @param xfer The file transfer.
- * @param filename The filename.
- */
--void gaim_xfer_set_filename(GaimXfer *xfer, const char *filename);
-+void gaim2_xfer_set_filename(Gaim2Xfer *xfer, const char *filename);
-
- /**
- * Sets the local filename for the file transfer.
-@@ -358,7 +358,7 @@ void gaim_xfer_set_filename(GaimXfer *xf
- * @param xfer The file transfer.
- * @param filename The filename
- */
--void gaim_xfer_set_local_filename(GaimXfer *xfer, const char *filename);
-+void gaim2_xfer_set_local_filename(Gaim2Xfer *xfer, const char *filename);
-
- /**
- * Sets the size of the file in a file transfer.
-@@ -366,7 +366,7 @@ void gaim_xfer_set_local_filename(GaimXf
- * @param xfer The file transfer.
- * @param size The size of the file.
- */
--void gaim_xfer_set_size(GaimXfer *xfer, size_t size);
-+void gaim2_xfer_set_size(Gaim2Xfer *xfer, size_t size);
-
- /**
- * Returns the UI operations structure for a file transfer.
-@@ -375,7 +375,7 @@ void gaim_xfer_set_size(GaimXfer *xfer,
- *
- * @return The UI operations structure.
- */
--GaimXferUiOps *gaim_xfer_get_ui_ops(const GaimXfer *xfer);
-+Gaim2XferUiOps *gaim2_xfer_get_ui_ops(const Gaim2Xfer *xfer);
-
- /**
- * Sets the read function for the file transfer.
-@@ -383,8 +383,8 @@ GaimXferUiOps *gaim_xfer_get_ui_ops(cons
- * @param xfer The file transfer.
- * @param fnc The read function.
- */
--void gaim_xfer_set_read_fnc(GaimXfer *xfer,
-- gssize (*fnc)(guchar **, GaimXfer *));
-+void gaim2_xfer_set_read_fnc(Gaim2Xfer *xfer,
-+ gssize (*fnc)(guchar **, Gaim2Xfer *));
-
- /**
- * Sets the write function for the file transfer.
-@@ -392,8 +392,8 @@ void gaim_xfer_set_read_fnc(GaimXfer *xf
- * @param xfer The file transfer.
- * @param fnc The write function.
- */
--void gaim_xfer_set_write_fnc(GaimXfer *xfer,
-- gssize (*fnc)(const guchar *, size_t, GaimXfer *));
-+void gaim2_xfer_set_write_fnc(Gaim2Xfer *xfer,
-+ gssize (*fnc)(const guchar *, size_t, Gaim2Xfer *));
-
- /**
- * Sets the acknowledge function for the file transfer.
-@@ -401,8 +401,8 @@ void gaim_xfer_set_write_fnc(GaimXfer *x
- * @param xfer The file transfer.
- * @param fnc The acknowledge function.
- */
--void gaim_xfer_set_ack_fnc(GaimXfer *xfer,
-- void (*fnc)(GaimXfer *, const guchar *, size_t));
-+void gaim2_xfer_set_ack_fnc(Gaim2Xfer *xfer,
-+ void (*fnc)(Gaim2Xfer *, const guchar *, size_t));
-
- /**
- * Sets the function to be called if the request is denied.
-@@ -410,19 +410,19 @@ void gaim_xfer_set_ack_fnc(GaimXfer *xfe
- * @param xfer The file transfer.
- * @param fnc The request denied prpl callback.
- */
--void gaim_xfer_set_request_denied_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *));
-+void gaim2_xfer_set_request_denied_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *));
-
- /**
- * Sets the transfer initialization function for the file transfer.
- *
-- * This function is required, and must call gaim_xfer_start() with
-+ * This function is required, and must call gaim2_xfer_start() with
- * the necessary parameters. This will be called if the file transfer
- * is accepted by the user.
- *
- * @param xfer The file transfer.
- * @param fnc The transfer initialization function.
- */
--void gaim_xfer_set_init_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *));
-+void gaim2_xfer_set_init_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *));
-
- /**
- * Sets the start transfer function for the file transfer.
-@@ -430,7 +430,7 @@ void gaim_xfer_set_init_fnc(GaimXfer *xf
- * @param xfer The file transfer.
- * @param fnc The start transfer function.
- */
--void gaim_xfer_set_start_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *));
-+void gaim2_xfer_set_start_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *));
-
- /**
- * Sets the end transfer function for the file transfer.
-@@ -438,7 +438,7 @@ void gaim_xfer_set_start_fnc(GaimXfer *x
- * @param xfer The file transfer.
- * @param fnc The end transfer function.
- */
--void gaim_xfer_set_end_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *));
-+void gaim2_xfer_set_end_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *));
-
- /**
- * Sets the cancel send function for the file transfer.
-@@ -446,7 +446,7 @@ void gaim_xfer_set_end_fnc(GaimXfer *xfe
- * @param xfer The file transfer.
- * @param fnc The cancel send function.
- */
--void gaim_xfer_set_cancel_send_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *));
-+void gaim2_xfer_set_cancel_send_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *));
-
- /**
- * Sets the cancel receive function for the file transfer.
-@@ -454,7 +454,7 @@ void gaim_xfer_set_cancel_send_fnc(GaimX
- * @param xfer The file transfer.
- * @param fnc The cancel receive function.
- */
--void gaim_xfer_set_cancel_recv_fnc(GaimXfer *xfer, void (*fnc)(GaimXfer *));
-+void gaim2_xfer_set_cancel_recv_fnc(Gaim2Xfer *xfer, void (*fnc)(Gaim2Xfer *));
-
- /**
- * Reads in data from a file transfer stream.
-@@ -464,7 +464,7 @@ void gaim_xfer_set_cancel_recv_fnc(GaimX
- *
- * @return The number of bytes read, or -1.
- */
--gssize gaim_xfer_read(GaimXfer *xfer, guchar **buffer);
-+gssize gaim2_xfer_read(Gaim2Xfer *xfer, guchar **buffer);
-
- /**
- * Writes data to a file transfer stream.
-@@ -475,7 +475,7 @@ gssize gaim_xfer_read(GaimXfer *xfer, gu
- *
- * @return The number of bytes written, or -1.
- */
--gssize gaim_xfer_write(GaimXfer *xfer, const guchar *buffer, gsize size);
-+gssize gaim2_xfer_write(Gaim2Xfer *xfer, const guchar *buffer, gsize size);
-
- /**
- * Starts a file transfer.
-@@ -489,7 +489,7 @@ gssize gaim_xfer_write(GaimXfer *xfer, c
- * @param ip The IP address to connect to.
- * @param port The port to connect to.
- */
--void gaim_xfer_start(GaimXfer *xfer, int fd, const char *ip,
-+void gaim2_xfer_start(Gaim2Xfer *xfer, int fd, const char *ip,
- unsigned int port);
-
- /**
-@@ -497,34 +497,34 @@ void gaim_xfer_start(GaimXfer *xfer, int
- *
- * @param xfer The file transfer.
- */
--void gaim_xfer_end(GaimXfer *xfer);
-+void gaim2_xfer_end(Gaim2Xfer *xfer);
-
- /**
- * Adds a new file transfer to the list of file transfers. Call this only
-- * if you are not using gaim_xfer_start.
-+ * if you are not using gaim2_xfer_start.
- *
- * @param xfer The file transfer.
- */
--void gaim_xfer_add(GaimXfer *xfer);
-+void gaim2_xfer_add(Gaim2Xfer *xfer);
-
- /**
- * Cancels a file transfer on the local end.
- *
- * @param xfer The file transfer.
- */
--void gaim_xfer_cancel_local(GaimXfer *xfer);
-+void gaim2_xfer_cancel_local(Gaim2Xfer *xfer);
-
- /**
- * Cancels a file transfer from the remote end.
- *
- * @param xfer The file transfer.
- */
--void gaim_xfer_cancel_remote(GaimXfer *xfer);
-+void gaim2_xfer_cancel_remote(Gaim2Xfer *xfer);
-
- /**
- * Displays a file transfer-related error message.
- *
-- * This is a wrapper around gaim_notify_error(), which automatically
-+ * This is a wrapper around gaim2_notify_error(), which automatically
- * specifies a title ("File transfer to <i>user</i> failed" or
- * "File Transfer from <i>user</i> failed").
- *
-@@ -533,25 +533,25 @@ void gaim_xfer_cancel_remote(GaimXfer *x
- * @param who The user on the other end of the transfer.
- * @param msg The message to display.
- */
--void gaim_xfer_error(GaimXferType type, GaimAccount *account, const char *who, const char *msg);
-+void gaim2_xfer_error(Gaim2XferType type, Gaim2Account *account, const char *who, const char *msg);
-
- /**
- * Updates file transfer progress.
- *
- * @param xfer The file transfer.
- */
--void gaim_xfer_update_progress(GaimXfer *xfer);
-+void gaim2_xfer_update_progress(Gaim2Xfer *xfer);
-
- /**
- * Displays a file transfer-related message in the conversation window
- *
-- * This is a wrapper around gaim_conversation_write
-+ * This is a wrapper around gaim2_conversation_write
- *
- * @param xfer The file transfer to which this message relates.
- * @param message The message to display.
- * @param is_error Is this an error message?.
- */
--void gaim_xfer_conversation_write(GaimXfer *xfer, char *message, gboolean is_error);
-+void gaim2_xfer_conversation_write(Gaim2Xfer *xfer, char *message, gboolean is_error);
-
- /*@}*/
-
-@@ -565,31 +565,31 @@ void gaim_xfer_conversation_write(GaimXf
- *
- * @return The handle
- */
--void *gaim_xfers_get_handle(void);
-+void *gaim2_xfers_get_handle(void);
-
- /**
- * Initializes the file transfer subsystem
- */
--void gaim_xfers_init(void);
-+void gaim2_xfers_init(void);
-
- /**
- * Uninitializes the file transfer subsystem
- */
--void gaim_xfers_uninit(void);
-+void gaim2_xfers_uninit(void);
-
- /**
-- * Sets the UI operations structure to be used in all gaim file transfers.
-+ * Sets the UI operations structure to be used in all gaim2 file transfers.
- *
- * @param ops The UI operations structure.
- */
--void gaim_xfers_set_ui_ops(GaimXferUiOps *ops);
-+void gaim2_xfers_set_ui_ops(Gaim2XferUiOps *ops);
-
- /**
-- * Returns the UI operations structure to be used in all gaim file transfers.
-+ * Returns the UI operations structure to be used in all gaim2 file transfers.
- *
- * @return The UI operations structure.
- */
--GaimXferUiOps *gaim_xfers_get_ui_ops(void);
-+Gaim2XferUiOps *gaim2_xfers_get_ui_ops(void);
-
- /*@}*/
-
-Les fichiers ./src/gaim et ./src/gaim sont différents.
-diff -prNu ./src/gaim2.h ./src/gaim2.h
---- ./src/gaim2.h 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/gaim2.h 2006-01-05 15:11:20.000000000 +0100
-@@ -0,0 +1,28 @@
-+/*
-+ * gaim2
-+ *
-+ * Gaim2 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
-+ *
-+ */
-+#ifndef _GAIM_H_
-+#define _GAIM_H_
-+
-+#define XPATCH BAD /* Because Kalla Said So */
-+
-+#endif /* _GAIM_H_ */
-diff -prNu ./src/gaim-client.c ./src/gaim-client.c
---- ./src/gaim-client.c 2005-08-16 17:22:35.000000000 +0200
-+++ ./src/gaim-client.c 2006-01-05 15:11:04.000000000 +0100
-@@ -4,11 +4,11 @@
- #include <stdio.h>
- #include <stdlib.h>
-
--#include "dbus-gaim.h"
--#include "gaim-client-bindings.h"
-+#include "dbus-gaim2.h"
-+#include "gaim2-client-bindings.h"
-
- static DBusGConnection *bus;
--static DBusGProxy *gaim_proxy;
-+static DBusGProxy *gaim2_proxy;
-
- static GList *garray_int_to_glist(GArray *array) {
- GList *list = NULL;
-@@ -32,7 +32,7 @@ static GSList *garray_int_to_gslist(GArr
- return list;
- }
-
--#include "gaim-client-bindings.c"
-+#include "gaim2-client-bindings.c"
-
- static void lose (const char *fmt, ...) G_GNUC_NORETURN G_GNUC_PRINTF (1, 2);
- static void lose_gerror (const char *prefix, GError *error) G_GNUC_NORETURN;
-@@ -58,7 +58,7 @@ lose_gerror (const char *prefix, GError
- lose ("%s: %s", prefix, error->message);
- }
-
--void gaim_init(void) {
-+void gaim2_init(void) {
- GError *error = NULL;
-
- g_type_init ();
-@@ -67,12 +67,12 @@ void gaim_init(void) {
- if (!bus)
- lose_gerror ("Couldn't connect to session bus", error);
-
-- gaim_proxy = dbus_g_proxy_new_for_name (bus,
-+ gaim2_proxy = dbus_g_proxy_new_for_name (bus,
- DBUS_SERVICE_GAIM,
- DBUS_PATH_GAIM,
- DBUS_INTERFACE_GAIM);
-
-- if (!gaim_proxy)
-- lose_gerror ("Couldn't connect to the Gaim Service", error);
-+ if (!gaim2_proxy)
-+ lose_gerror ("Couldn't connect to the Gaim2 Service", error);
- }
-
-diff -prNu ./src/gaim-client-example.c ./src/gaim-client-example.c
---- ./src/gaim-client-example.c 2005-10-30 18:24:38.000000000 +0100
-+++ ./src/gaim-client-example.c 2006-01-05 15:11:04.000000000 +0100
-@@ -3,19 +3,19 @@
- #include <stdio.h>
- #include <stdlib.h>
-
--#include "gaim-client.h"
-+#include "gaim2-client.h"
-
- /*
-- This example demonstrates how to use libgaim-client to communicate
-- with gaim. The names and signatures of functions provided by
-- libgaim-client are the same as those in gaim. However, all
-- structures (such as GaimAccount) are opaque, that is, you can only
-+ This example demonstrates how to use libgaim2-client to communicate
-+ with gaim2. The names and signatures of functions provided by
-+ libgaim2-client are the same as those in gaim2. However, all
-+ structures (such as Gaim2Account) are opaque, that is, you can only
- use pointer to them. In fact, these pointers DO NOT actually point
- to anything, they are just integer identifiers of assigned to these
-- structures by gaim. So NEVER try to dereference these pointers.
-+ structures by gaim2. So NEVER try to dereference these pointers.
- Integer ids as disguised as pointers to provide type checking and
-- prevent mistakes such as passing an id of GaimAccount when an id of
-- GaimBuddy is expected. According to glib manual, this technique is
-+ prevent mistakes such as passing an id of Gaim2Account when an id of
-+ Gaim2Buddy is expected. According to glib manual, this technique is
- portable.
- */
-
-@@ -23,12 +23,12 @@ int main (int argc, char **argv)
- {
- GList *alist, *node;
-
-- gaim_init();
-+ gaim2_init();
-
-- alist = gaim_accounts_get_all();
-+ alist = gaim2_accounts_get_all();
- for (node = alist; node; node = node->next) {
-- GaimAccount *account = (GaimAccount*) node->data;
-- char *name = gaim_account_get_username(account);
-+ Gaim2Account *account = (Gaim2Account*) node->data;
-+ char *name = gaim2_account_get_username(account);
- g_print("Name: %s\n", name);
- g_free(name);
- }
-diff -prNu ./src/gaim-client.h ./src/gaim-client.h
---- ./src/gaim-client.h 2005-12-22 19:28:08.000000000 +0100
-+++ ./src/gaim-client.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,11 +2,11 @@
- #define _GAIM_CLIENT_H_INCLUDED_
-
- #include <glib.h>
--#include "gaim-client-bindings.h"
-+#include "gaim2-client-bindings.h"
-
- G_BEGIN_DECLS
-
--void gaim_init(void);
-+void gaim2_init(void);
-
- G_END_DECLS
-
-diff -prNu ./src/gaim.h ./src/gaim.h
---- ./src/gaim.h 2005-10-31 00:00:47.000000000 +0100
-+++ ./src/gaim.h 1970-01-01 01:00:00.000000000 +0100
-@@ -1,28 +0,0 @@
--/*
-- * 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
-- *
-- */
--#ifndef _GAIM_H_
--#define _GAIM_H_
--
--#define XPATCH BAD /* Because Kalla Said So */
--
--#endif /* _GAIM_H_ */
-diff -prNu ./src/gaim-socket.h ./src/gaim-socket.h
---- ./src/gaim-socket.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gaim-socket.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim-remote
-+ * gaim2-remote
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- #ifndef _GAIM_GAIM_SOCKET_H_
- #define _GAIM_GAIM_SOCKET_H_
-
--struct gaim_cui_packet {
-+struct gaim2_cui_packet {
- guchar type;
- guchar subtype;
- guint32 length;
-@@ -31,15 +31,15 @@ struct gaim_cui_packet {
- };
-
-
--void cui_send_packet (int fd, struct gaim_cui_packet *p);
--gint gaim_connect_to_session(gint session);
--gboolean gaim_session_exists(int sess);
--
--struct gaim_cui_packet *cui_packet_new(guchar type, guchar subtype);
--void cui_packet_free(struct gaim_cui_packet *p);
--void cui_packet_append_string(struct gaim_cui_packet *p, char *str);
--void cui_packet_append_char(struct gaim_cui_packet *p, char c);
--void cui_packet_append_raw(struct gaim_cui_packet *p, char *str, int len);
-+void cui_send_packet (int fd, struct gaim2_cui_packet *p);
-+gint gaim2_connect_to_session(gint session);
-+gboolean gaim2_session_exists(int sess);
-+
-+struct gaim2_cui_packet *cui_packet_new(guchar type, guchar subtype);
-+void cui_packet_free(struct gaim2_cui_packet *p);
-+void cui_packet_append_string(struct gaim2_cui_packet *p, char *str);
-+void cui_packet_append_char(struct gaim2_cui_packet *p, char c);
-+void cui_packet_append_raw(struct gaim2_cui_packet *p, char *str, int len);
-
-
- #endif /* _GAIM_GAIM_SOCKET_H_ */
-diff -prNu ./src/getopt1.c ./src/getopt1.c
---- ./src/getopt1.c 2005-12-06 10:52:30.000000000 +0100
-+++ ./src/getopt1.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,5 +1,5 @@
- /* getopt_long and getopt_long_only entry points for GNU getopt.
-- Gaim is the legal property of its developers, whose names are too numerous
-+ Gaim2 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.
-
-diff -prNu ./src/getopt.c ./src/getopt.c
---- ./src/getopt.c 2005-12-19 13:48:13.000000000 +0100
-+++ ./src/getopt.c 2006-01-05 15:11:04.000000000 +0100
-@@ -3,7 +3,7 @@
- "Keep this file name-space clean" means, talk to roland@gnu.ai.mit.edu
- before changing it!
-
-- Gaim is the legal property of its developers, whose names are too numerous
-+ Gaim2 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.
-
-diff -prNu ./src/getopt.h ./src/getopt.h
---- ./src/getopt.h 2005-12-06 08:59:07.000000000 +0100
-+++ ./src/getopt.h 2006-01-05 15:11:20.000000000 +0100
-@@ -4,7 +4,7 @@
- "Keep this file name-space clean" means, talk to roland@gnu.ai.mit.edu
- before changing it!
-
-- Gaim is the legal property of its developers, whose names are too numerous
-+ Gaim2 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.
-
-diff -prNu ./src/gtkaccount.c ./src/gtkaccount.c
---- ./src/gtkaccount.c 2005-12-29 02:56:44.000000000 +0100
-+++ ./src/gtkaccount.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkaccount.c GTK+ Account Editor UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "accountopt.h"
-@@ -59,11 +59,11 @@ enum
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *username;
- char *alias;
-
--} GaimGtkAccountAddUserData;
-+} Gaim2GtkAccountAddUserData;
-
- typedef struct
- {
-@@ -82,14 +82,14 @@ typedef struct
-
- typedef struct
- {
-- GaimGtkAccountDialogType type;
-+ Gaim2GtkAccountDialogType type;
-
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *protocol_id;
-- GaimPlugin *plugin;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *plugin;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
-- GaimProxyType new_proxy_type;
-+ Gaim2ProxyType new_proxy_type;
-
- GList *user_split_entries;
- GList *protocol_opt_entries;
-@@ -141,20 +141,20 @@ typedef struct
- gboolean pulse_to_grey;
- float pulse_value;
- int timeout;
-- GaimAccount *account;
-+ Gaim2Account *account;
- GtkTreeModel *model;
-
--} GaimGtkPulseData;
-+} Gaim2GtkPulseData;
-
-
- static AccountsWindow *accounts_window = NULL;
- static GHashTable *account_pref_wins;
-
--static void add_account_to_liststore(GaimAccount *account, gpointer user_data);
-+static void add_account_to_liststore(Gaim2Account *account, gpointer user_data);
- static void set_account(GtkListStore *store, GtkTreeIter *iter,
-- GaimAccount *account);
-+ Gaim2Account *account);
- static char*
--convert_buddy_icon(GaimPlugin *plugin, const char *path);
-+convert_buddy_icon(Gaim2Plugin *plugin, const char *path);
-
- /**************************************************************************
- * Add/Modify Account dialog
-@@ -184,7 +184,7 @@ add_pref_box(AccountPrefsDialog *dialog,
-
- gtk_box_pack_start(GTK_BOX(hbox), widget, TRUE, TRUE, GAIM_HIG_BORDER);
- gtk_widget_show(widget);
-- gaim_set_accessible_label (widget, label);
-+ gaim2_set_accessible_label (widget, label);
-
- return hbox;
- }
-@@ -192,7 +192,7 @@ add_pref_box(AccountPrefsDialog *dialog,
- static void
- set_dialog_icon(AccountPrefsDialog *dialog)
- {
-- char *filename = gaim_buddy_icons_get_full_path(dialog->icon_path);
-+ char *filename = gaim2_buddy_icons_get_full_path(dialog->icon_path);
- gtk_image_set_from_file(GTK_IMAGE(dialog->icon_entry), filename);
- g_free(filename);
- }
-@@ -201,9 +201,9 @@ static void
- set_account_protocol_cb(GtkWidget *item, const char *id,
- AccountPrefsDialog *dialog)
- {
-- GaimPlugin *new_plugin;
-+ Gaim2Plugin *new_plugin;
-
-- new_plugin = gaim_find_prpl(id);
-+ new_plugin = gaim2_find_prpl(id);
-
- if (new_plugin == dialog->plugin)
- return;
-@@ -221,7 +221,7 @@ set_account_protocol_cb(GtkWidget *item,
- }
-
- if (dialog->account != NULL)
-- gaim_account_clear_settings(dialog->account);
-+ gaim2_account_clear_settings(dialog->account);
-
- add_login_options(dialog, dialog->top_vbox);
- add_user_options(dialog, dialog->top_vbox);
-@@ -271,7 +271,7 @@ icon_filesel_choose_cb(GtkWidget *widget
- filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(dialog->icon_filesel));
- current_folder = gtk_file_chooser_get_current_folder(GTK_FILE_CHOOSER(dialog->icon_filesel));
- if (current_folder != NULL) {
-- gaim_prefs_set_string("/gaim/gtk/filelocations/last_icon_folder", current_folder);
-+ gaim2_prefs_set_string("/gaim2/gtk/filelocations/last_icon_folder", current_folder);
- g_free(current_folder);
- }
-
-@@ -285,7 +285,7 @@ icon_filesel_choose_cb(GtkWidget *w, Acc
- GTK_FILE_SELECTION(dialog->icon_filesel)));
-
- /* If they typed in a directory, change there */
-- if (gaim_gtk_check_if_dir(filename,
-+ if (gaim2_gtk_check_if_dir(filename,
- GTK_FILE_SELECTION(dialog->icon_filesel)))
- {
- g_free(filename);
-@@ -294,7 +294,7 @@ icon_filesel_choose_cb(GtkWidget *w, Acc
-
- current_folder = g_path_get_dirname(filename);
- if (current_folder != NULL) {
-- gaim_prefs_set_string("/gaim/gtk/filelocations/last_icon_folder", current_folder);
-+ gaim2_prefs_set_string("/gaim2/gtk/filelocations/last_icon_folder", current_folder);
- g_free(current_folder);
- }
-
-@@ -353,7 +353,7 @@ icon_preview_change_cb(GtkTreeSelection
- width = gdk_pixbuf_get_width(pixbuf);
- height = gdk_pixbuf_get_height(pixbuf);
- basename = g_path_get_basename(filename);
-- size = gaim_str_size_to_units(st.st_size);
-+ size = gaim2_str_size_to_units(st.st_size);
- markup = g_strdup_printf(_("<b>File:</b> %s\n"
- "<b>File size:</b> %s\n"
- "<b>Image size:</b> %dx%d"),
-@@ -402,7 +402,7 @@ icon_select_cb(GtkWidget *button, Accoun
- return;
- }
-
-- current_folder = gaim_prefs_get_string("/gaim/gtk/filelocations/last_icon_folder");
-+ current_folder = gaim2_prefs_get_string("/gaim2/gtk/filelocations/last_icon_folder");
- #if GTK_CHECK_VERSION(2,4,0) /* FILECHOOSER */
- dialog->icon_filesel = gtk_file_chooser_dialog_new(_("Buddy Icon"),
- GTK_WINDOW(dialog->window),
-@@ -488,7 +488,7 @@ account_dnd_recv(GtkWidget *widget, GdkD
- /* 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",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "buddyicon", "%s\n",
- (converr ? converr->message :
- "g_filename_from_uri error"));
- return;
-@@ -525,14 +525,14 @@ str_array_match(char **a, char **b)
- #endif
-
- static char*
--convert_buddy_icon(GaimPlugin *plugin, const char *path)
-+convert_buddy_icon(Gaim2Plugin *plugin, const char *path)
- {
- #if GTK_CHECK_VERSION(2,2,0)
- int width, height;
- char **pixbuf_formats = NULL;
- GdkPixbufFormat *format;
- GdkPixbuf *pixbuf;
-- GaimPluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(plugin);
-+ Gaim2PluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(plugin);
- char **prpl_formats = g_strsplit (prpl_info->icon_spec.format,",",0);
- #if !GTK_CHECK_VERSION(2,4,0)
- GdkPixbufLoader *loader;
-@@ -541,15 +541,15 @@ convert_buddy_icon(GaimPlugin *plugin, c
- void *data = NULL;
- #endif
- #endif
-- const char *dirname = gaim_buddy_icons_get_cache_dir();
-+ const char *dirname = gaim2_buddy_icons_get_cache_dir();
- char *random = g_strdup_printf("%x", g_random_int());
- char *filename = g_build_filename(dirname, random, NULL);
-
- if (!g_file_test(dirname, G_FILE_TEST_IS_DIR)) {
-- gaim_debug_info("buddyicon", "Creating icon cache directory.\n");
-+ gaim2_debug_info("buddyicon", "Creating icon cache directory.\n");
-
- if (g_mkdir(dirname, S_IRUSR | S_IWUSR | S_IXUSR) < 0) {
-- gaim_debug_error("buddyicon",
-+ gaim2_debug_error("buddyicon",
- "Unable to create directory %s: %s\n",
- dirname, strerror(errno));
- #if GTK_CHECK_VERSION(2,2,0)
-@@ -675,19 +675,19 @@ convert_buddy_icon(GaimPlugin *plugin, c
- if (error) {
- g_free(random);
- g_free(filename);
-- gaim_debug_error("buddyicon", "Could not open icon for conversion: %s\n", error->message);
-+ gaim2_debug_error("buddyicon", "Could not open icon for conversion: %s\n", error->message);
- g_error_free(error);
- g_strfreev(prpl_formats);
- return NULL;
- }
-
- for (i = 0; prpl_formats[i]; i++) {
-- gaim_debug_info("buddyicon", "Converting buddy icon to %s as %s\n", prpl_formats[i], filename);
-+ gaim2_debug_info("buddyicon", "Converting buddy icon to %s as %s\n", prpl_formats[i], filename);
- /* The gdk-pixbuf documentation is wrong. gdk_pixbuf_save returns TRUE if it was successful,
- * FALSE if an error was set. */
- if (gdk_pixbuf_save (pixbuf, filename, prpl_formats[i], &error, NULL) == TRUE)
- break;
-- gaim_debug_warning("buddyicon", "Could not convert to %s: %s\n", prpl_formats[i], error->message);
-+ gaim2_debug_warning("buddyicon", "Could not convert to %s: %s\n", prpl_formats[i], error->message);
- g_error_free(error);
- error = NULL;
- }
-@@ -697,7 +697,7 @@ convert_buddy_icon(GaimPlugin *plugin, c
- g_free(filename);
- return random;
- } else {
-- gaim_debug_error("buddyicon", "Could not convert icon to usable format: %s\n", error->message);
-+ gaim2_debug_error("buddyicon", "Could not convert icon to usable format: %s\n", error->message);
- g_error_free(error);
- }
- g_free(random);
-@@ -709,15 +709,15 @@ convert_buddy_icon(GaimPlugin *plugin, c
- }
-
- static void
--update_editable(GaimConnection *gc, AccountPrefsDialog *dialog)
-+update_editable(Gaim2Connection *gc, AccountPrefsDialog *dialog)
- {
- gboolean set;
- GList *l;
-
-- if (gc != NULL && dialog->account != gaim_connection_get_account(gc))
-+ if (gc != NULL && dialog->account != gaim2_connection_get_account(gc))
- return;
-
-- set = !(gaim_account_is_connected(dialog->account) || gaim_account_is_connecting(dialog->account));
-+ set = !(gaim2_account_is_connected(dialog->account) || gaim2_account_is_connecting(dialog->account));
- gtk_widget_set_sensitive(dialog->protocol_menu, set);
- gtk_widget_set_sensitive(dialog->screenname_entry, set);
-
-@@ -739,7 +739,7 @@ add_login_options(AccountPrefsDialog *di
- gtk_widget_destroy(dialog->login_frame);
-
- /* Build the login options frame. */
-- frame = gaim_gtk_make_frame(parent, _("Login Options"));
-+ frame = gaim2_gtk_make_frame(parent, _("Login Options"));
-
- /* cringe */
- dialog->login_frame = gtk_widget_get_parent(gtk_widget_get_parent(frame));
-@@ -753,7 +753,7 @@ add_login_options(AccountPrefsDialog *di
- gtk_widget_show(vbox);
-
- /* Protocol */
-- dialog->protocol_menu = gaim_gtk_protocol_option_menu_new(
-+ dialog->protocol_menu = gaim2_gtk_protocol_option_menu_new(
- dialog->protocol_id, G_CALLBACK(set_account_protocol_cb), dialog);
-
- add_pref_box(dialog, vbox, _("Protocol:"), dialog->protocol_menu);
-@@ -773,7 +773,7 @@ add_login_options(AccountPrefsDialog *di
- user_splits = dialog->prpl_info->user_splits;
-
- if (dialog->account != NULL)
-- username = g_strdup(gaim_account_get_username(dialog->account));
-+ username = g_strdup(gaim2_account_get_username(dialog->account));
-
- if (dialog->user_split_entries != NULL) {
- g_list_free(dialog->user_split_entries);
-@@ -781,10 +781,10 @@ add_login_options(AccountPrefsDialog *di
- }
-
- for (l = user_splits; l != NULL; l = l->next) {
-- GaimAccountUserSplit *split = l->data;
-+ Gaim2AccountUserSplit *split = l->data;
- char *buf;
-
-- buf = g_strdup_printf("%s:", gaim_account_user_split_get_text(split));
-+ buf = g_strdup_printf("%s:", gaim2_account_user_split_get_text(split));
-
- entry = gtk_entry_new();
-
-@@ -802,13 +802,13 @@ add_login_options(AccountPrefsDialog *di
- l = l->prev, l2 = l2->prev) {
-
- GtkWidget *entry = l->data;
-- GaimAccountUserSplit *split = l2->data;
-+ Gaim2AccountUserSplit *split = l2->data;
- const char *value = NULL;
- char *c;
-
- if (dialog->account != NULL) {
- c = strrchr(username,
-- gaim_account_user_split_get_separator(split));
-+ gaim2_account_user_split_get_separator(split));
-
- if (c != NULL) {
- *c = '\0';
-@@ -819,7 +819,7 @@ add_login_options(AccountPrefsDialog *di
- }
-
- if (value == NULL)
-- value = gaim_account_user_split_get_default_value(split);
-+ value = gaim2_account_user_split_get_default_value(split);
-
- if (value != NULL)
- gtk_entry_set_text(GTK_ENTRY(entry), value);
-@@ -853,17 +853,17 @@ add_login_options(AccountPrefsDialog *di
-
- /* Set the fields. */
- if (dialog->account != NULL) {
-- if (gaim_account_get_password(dialog->account))
-+ if (gaim2_account_get_password(dialog->account))
- gtk_entry_set_text(GTK_ENTRY(dialog->password_entry),
-- gaim_account_get_password(dialog->account));
-+ gaim2_account_get_password(dialog->account));
-
-- if (gaim_account_get_alias(dialog->account))
-+ if (gaim2_account_get_alias(dialog->account))
- gtk_entry_set_text(GTK_ENTRY(dialog->alias_entry),
-- gaim_account_get_alias(dialog->account));
-+ gaim2_account_get_alias(dialog->account));
-
- gtk_toggle_button_set_active(
- GTK_TOGGLE_BUTTON(dialog->remember_pass_check),
-- gaim_account_get_remember_password(dialog->account));
-+ gaim2_account_get_remember_password(dialog->account));
- }
-
- if (dialog->prpl_info != NULL &&
-@@ -875,9 +875,9 @@ add_login_options(AccountPrefsDialog *di
-
- /* 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,
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signing-on", dialog,
- G_CALLBACK(update_editable), dialog);
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off", dialog,
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off", dialog,
- G_CALLBACK(update_editable), dialog);
- }
-
-@@ -896,7 +896,7 @@ add_user_options(AccountPrefsDialog *dia
- gtk_widget_destroy(dialog->user_frame);
-
- /* Build the user options frame. */
-- frame = gaim_gtk_make_frame(parent, _("User Options"));
-+ frame = gaim2_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);
-@@ -927,7 +927,7 @@ add_user_options(AccountPrefsDialog *dia
- 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);
-+ gaim2_set_accessible_label (dialog->icon_entry, label);
- dialog->icon_path = NULL;
-
- vbox2 = gtk_vbox_new(FALSE, 0);
-@@ -960,10 +960,10 @@ add_user_options(AccountPrefsDialog *dia
-
- if (dialog->account != NULL) {
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->new_mail_check),
-- gaim_account_get_check_mail(dialog->account));
-+ gaim2_account_get_check_mail(dialog->account));
-
-- if (gaim_account_get_buddy_icon(dialog->account) != NULL) {
-- dialog->icon_path = g_strdup(gaim_account_get_buddy_icon(dialog->account));
-+ if (gaim2_account_get_buddy_icon(dialog->account) != NULL) {
-+ dialog->icon_path = g_strdup(gaim2_account_get_buddy_icon(dialog->account));
- set_dialog_icon(dialog);
- }
- }
-@@ -980,15 +980,15 @@ add_user_options(AccountPrefsDialog *dia
- static void
- add_protocol_options(AccountPrefsDialog *dialog, GtkWidget *parent)
- {
-- GaimAccountOption *option;
-- GaimAccount *account;
-+ Gaim2AccountOption *option;
-+ Gaim2Account *account;
- GtkWidget *frame, *vbox, *check, *entry, *combo;
- const GList *list, *node;
- gint i, idx, int_value;
- GtkListStore *model;
- GtkTreeIter iter;
- GtkCellRenderer *renderer;
-- GaimKeyValuePair *kvp;
-+ Gaim2KeyValuePair *kvp;
- GList *l;
- char buf[1024];
- char *title;
-@@ -1011,7 +1011,7 @@ add_protocol_options(AccountPrefsDialog
- /* Build the protocol options frame. */
- g_snprintf(buf, sizeof(buf), _("%s Options"), dialog->plugin->info->name);
-
-- frame = gaim_gtk_make_frame(parent, buf);
-+ frame = gaim2_gtk_make_frame(parent, buf);
- dialog->protocol_frame =
- gtk_widget_get_parent(gtk_widget_get_parent(frame));
-
-@@ -1030,26 +1030,26 @@ add_protocol_options(AccountPrefsDialog
-
- for (l = dialog->prpl_info->protocol_options; l != NULL; l = l->next)
- {
-- option = (GaimAccountOption *)l->data;
-+ option = (Gaim2AccountOption *)l->data;
-
-- switch (gaim_account_option_get_type(option))
-+ switch (gaim2_account_option_get_type(option))
- {
- case GAIM_PREF_BOOLEAN:
- if (account == NULL ||
-- strcmp(gaim_account_get_protocol_id(account),
-+ strcmp(gaim2_account_get_protocol_id(account),
- dialog->protocol_id))
- {
-- bool_value = gaim_account_option_get_default_bool(option);
-+ bool_value = gaim2_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));
-+ bool_value = gaim2_account_get_bool(account,
-+ gaim2_account_option_get_setting(option),
-+ gaim2_account_option_get_default_bool(option));
- }
-
- check = gtk_check_button_new_with_label(
-- gaim_account_option_get_text(option));
-+ gaim2_account_option_get_text(option));
-
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(check),
- bool_value);
-@@ -1064,16 +1064,16 @@ add_protocol_options(AccountPrefsDialog
-
- case GAIM_PREF_INT:
- if (account == NULL ||
-- strcmp(gaim_account_get_protocol_id(account),
-+ strcmp(gaim2_account_get_protocol_id(account),
- dialog->protocol_id))
- {
-- int_value = gaim_account_option_get_default_int(option);
-+ int_value = gaim2_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));
-+ int_value = gaim2_account_get_int(account,
-+ gaim2_account_option_get_setting(option),
-+ gaim2_account_option_get_default_int(option));
- }
-
- g_snprintf(buf, sizeof(buf), "%d", int_value);
-@@ -1082,7 +1082,7 @@ add_protocol_options(AccountPrefsDialog
- gtk_entry_set_text(GTK_ENTRY(entry), buf);
-
- title = g_strdup_printf("%s:",
-- gaim_account_option_get_text(option));
-+ gaim2_account_option_get_text(option));
-
- add_pref_box(dialog, vbox, title, entry);
-
-@@ -1095,20 +1095,20 @@ add_protocol_options(AccountPrefsDialog
-
- case GAIM_PREF_STRING:
- if (account == NULL ||
-- strcmp(gaim_account_get_protocol_id(account),
-+ strcmp(gaim2_account_get_protocol_id(account),
- dialog->protocol_id))
- {
-- str_value = gaim_account_option_get_default_string(option);
-+ str_value = gaim2_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));
-+ str_value = gaim2_account_get_string(account,
-+ gaim2_account_option_get_setting(option),
-+ gaim2_account_option_get_default_string(option));
- }
-
- entry = gtk_entry_new();
-- if (gaim_account_option_get_masked(option))
-+ if (gaim2_account_option_get_masked(option))
- {
- gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE);
- gtk_entry_set_invisible_char(GTK_ENTRY(entry), GAIM_INVISIBLE_CHAR);
-@@ -1118,7 +1118,7 @@ add_protocol_options(AccountPrefsDialog
- gtk_entry_set_text(GTK_ENTRY(entry), str_value);
-
- title = g_strdup_printf("%s:",
-- gaim_account_option_get_text(option));
-+ gaim2_account_option_get_text(option));
-
- add_pref_box(dialog, vbox, title, entry);
-
-@@ -1134,26 +1134,26 @@ add_protocol_options(AccountPrefsDialog
- idx = 0;
-
- if (account == NULL ||
-- strcmp(gaim_account_get_protocol_id(account),
-+ strcmp(gaim2_account_get_protocol_id(account),
- dialog->protocol_id))
- {
-- str_value = gaim_account_option_get_default_list_value(option);
-+ str_value = gaim2_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));
-+ str_value = gaim2_account_get_string(account,
-+ gaim2_account_option_get_setting(option),
-+ gaim2_account_option_get_default_list_value(option));
- }
-
-- list = gaim_account_option_get_list(option);
-+ list = gaim2_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 */
-+ /* Loop through list of Gaim2KeyValuePair items */
- for (node = list; node != NULL; node = node->next) {
- if (node->data != NULL) {
-- kvp = (GaimKeyValuePair *) node->data;
-+ kvp = (Gaim2KeyValuePair *) node->data;
- if ((kvp->value != NULL) && (str_value != NULL) &&
- !g_utf8_collate(kvp->value, str_value))
- idx = i;
-@@ -1179,7 +1179,7 @@ add_protocol_options(AccountPrefsDialog
- renderer, "text", 0, NULL);
-
- title = g_strdup_printf("%s:",
-- gaim_account_option_get_text(option));
-+ gaim2_account_option_get_text(option));
-
- add_pref_box(dialog, vbox, title, combo);
-
-@@ -1286,7 +1286,7 @@ port_popup_cb(GtkWidget *w, GtkMenu *men
- static void
- add_proxy_options(AccountPrefsDialog *dialog, GtkWidget *parent)
- {
-- GaimProxyInfo *proxy_info;
-+ Gaim2ProxyInfo *proxy_info;
- GtkWidget *frame;
- GtkWidget *vbox;
- GtkWidget *vbox2;
-@@ -1294,7 +1294,7 @@ add_proxy_options(AccountPrefsDialog *di
- if (dialog->proxy_frame != NULL)
- gtk_widget_destroy(dialog->proxy_frame);
-
-- frame = gaim_gtk_make_frame(parent, _("Proxy Options"));
-+ frame = gaim2_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);
-@@ -1338,9 +1338,9 @@ add_proxy_options(AccountPrefsDialog *di
- 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) {
-+ (proxy_info = gaim2_account_get_proxy_info(dialog->account)) != NULL) {
-
-- GaimProxyType type = gaim_proxy_info_get_type(proxy_info);
-+ Gaim2ProxyType type = gaim2_proxy_info_get_type(proxy_info);
-
- /* Hah! */
- /* I dunno what you're laughing about, fuzz ball. */
-@@ -1356,10 +1356,10 @@ add_proxy_options(AccountPrefsDialog *di
- const char *value;
- int int_val;
-
-- if ((value = gaim_proxy_info_get_host(proxy_info)) != NULL)
-+ if ((value = gaim2_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) {
-+ if ((int_val = gaim2_proxy_info_get_port(proxy_info)) != 0) {
- char buf[32];
-
- g_snprintf(buf, sizeof(buf), "%d", int_val);
-@@ -1367,10 +1367,10 @@ add_proxy_options(AccountPrefsDialog *di
- gtk_entry_set_text(GTK_ENTRY(dialog->proxy_port_entry), buf);
- }
-
-- if ((value = gaim_proxy_info_get_username(proxy_info)) != NULL)
-+ if ((value = gaim2_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)
-+ if ((value = gaim2_proxy_info_get_password(proxy_info)) != NULL)
- gtk_entry_set_text(GTK_ENTRY(dialog->proxy_pass_entry), value);
- }
- }
-@@ -1405,12 +1405,12 @@ account_win_destroy_cb(GtkWidget *w, Gdk
-
- if (dialog->icon_path != NULL)
- {
-- const char *icon = gaim_account_get_buddy_icon(dialog->account);
-+ const char *icon = gaim2_account_get_buddy_icon(dialog->account);
- 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);
-+ char *filename = g_build_filename(gaim2_buddy_icons_get_cache_dir(), dialog->icon_path, NULL);
- g_unlink(filename);
- g_free(filename);
- }
-@@ -1421,7 +1421,7 @@ account_win_destroy_cb(GtkWidget *w, Gdk
- if (dialog->icon_filesel)
- gtk_widget_destroy(dialog->icon_filesel);
-
-- gaim_signals_disconnect_by_handle(dialog);
-+ gaim2_signals_disconnect_by_handle(dialog);
-
- g_free(dialog);
- }
-@@ -1432,23 +1432,23 @@ cancel_account_prefs_cb(GtkWidget *w, Ac
- account_win_destroy_cb(NULL, NULL, dialog);
- }
-
--static GaimAccount*
-+static Gaim2Account*
- ok_account_prefs_cb(GtkWidget *w, AccountPrefsDialog *dialog)
- {
-- GaimProxyInfo *proxy_info = NULL;
-+ Gaim2ProxyInfo *proxy_info = NULL;
- GList *l, *l2;
- const char *value;
- char *username;
- char *tmp;
- gboolean new = FALSE;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- 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);
-+ account = gaim2_account_new(screenname, dialog->protocol_id);
- new = TRUE;
- }
- else
-@@ -1456,28 +1456,28 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
- account = dialog->account;
-
- /* Protocol */
-- gaim_account_set_protocol_id(account, dialog->protocol_id);
-+ gaim2_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);
-+ gaim2_account_set_alias(account, value);
- else
-- gaim_account_set_alias(account, NULL);
-+ gaim2_account_set_alias(account, NULL);
-
- /* Buddy Icon */
-- gaim_account_set_buddy_icon(account, dialog->icon_path);
-+ gaim2_account_set_buddy_icon(account, dialog->icon_path);
-
- /* Remember Password */
-- gaim_account_set_remember_password(account,
-+ gaim2_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,
-+ gaim2_account_set_check_mail(account,
- gtk_toggle_button_get_active(
- GTK_TOGGLE_BUTTON(dialog->new_mail_check)));
-
-@@ -1490,10 +1490,10 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
- * 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);
-+ if ((gaim2_account_get_remember_password(account) || new) && (*value != '\0'))
-+ gaim2_account_set_password(account, value);
- else
-- gaim_account_set_password(account, NULL);
-+ gaim2_account_set_password(account, NULL);
-
- /* Build the username string. */
- username =
-@@ -1506,17 +1506,17 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
- l != NULL && l2 != NULL;
- l = l->next, l2 = l2->next)
- {
-- GaimAccountUserSplit *split = l->data;
-+ Gaim2AccountUserSplit *split = l->data;
- GtkEntry *entry = l2->data;
- char sep[2] = " ";
-
- value = gtk_entry_get_text(entry);
-
-- *sep = gaim_account_user_split_get_separator(split);
-+ *sep = gaim2_account_user_split_get_separator(split);
-
- tmp = g_strconcat(username, sep,
- (*value ? value :
-- gaim_account_user_split_get_default_value(split)),
-+ gaim2_account_user_split_get_default_value(split)),
- NULL);
-
- g_free(username);
-@@ -1524,7 +1524,7 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
- }
- }
-
-- gaim_account_set_username(account, username);
-+ gaim2_account_set_username(account, username);
- g_free(username);
-
- /* Add the protocol settings */
-@@ -1534,39 +1534,39 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
- l != NULL && l2 != NULL;
- l = l->next, l2 = l2->next) {
-
-- GaimPrefType type;
-- GaimAccountOption *option = l->data;
-+ Gaim2PrefType type;
-+ Gaim2AccountOption *option = l->data;
- GtkWidget *widget = l2->data;
- GtkTreeIter iter;
- const char *setting;
- int int_value;
- gboolean bool_value;
-
-- type = gaim_account_option_get_type(option);
-+ type = gaim2_account_option_get_type(option);
-
-- setting = gaim_account_option_get_setting(option);
-+ setting = gaim2_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);
-+ gaim2_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);
-+ gaim2_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);
-+ gaim2_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, &value, -1);
-- gaim_account_set_string(dialog->account, setting, value);
-+ gaim2_account_set_string(dialog->account, setting, value);
- break;
-
- default:
-@@ -1577,51 +1577,51 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
-
- /* Set the proxy stuff. */
- if (dialog->new_proxy_type == GAIM_PROXY_USE_GLOBAL) {
-- gaim_account_set_proxy_info(account, NULL);
-+ gaim2_account_set_proxy_info(account, NULL);
- }
- else {
-- proxy_info = gaim_account_get_proxy_info(account);
-+ proxy_info = gaim2_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);
-+ proxy_info = gaim2_proxy_info_new();
-+ gaim2_account_set_proxy_info(account, proxy_info);
- }
-
- /* Set the proxy info type. */
-- gaim_proxy_info_set_type(proxy_info, dialog->new_proxy_type);
-+ gaim2_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);
-+ gaim2_proxy_info_set_host(proxy_info, value);
- else
-- gaim_proxy_info_set_host(proxy_info, NULL);
-+ gaim2_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));
-+ gaim2_proxy_info_set_port(proxy_info, atoi(value));
- else
-- gaim_proxy_info_set_port(proxy_info, 0);
-+ gaim2_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);
-+ gaim2_proxy_info_set_username(proxy_info, value);
- else
-- gaim_proxy_info_set_username(proxy_info, NULL);
-+ gaim2_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);
-+ gaim2_proxy_info_set_password(proxy_info, value);
- else
-- gaim_proxy_info_set_password(proxy_info, NULL);
-+ gaim2_proxy_info_set_password(proxy_info, NULL);
- }
-
- /* We no longer need the data from the dialog window */
-@@ -1629,18 +1629,18 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
-
- /* If this is a new account, add it to our list */
- if (new)
-- gaim_accounts_add(account);
-+ gaim2_accounts_add(account);
- else
-- gaim_signal_emit(gaim_gtk_account_get_handle(), "account-modified", account);
-+ gaim2_signal_emit(gaim2_gtk_account_get_handle(), "account-modified", account);
-
- /* If this is a new account, then sign on! */
- if (new) {
-- const GaimSavedStatus *saved_status;
-+ const Gaim2SavedStatus *saved_status;
-
-- saved_status = gaim_savedstatus_get_current();
-+ saved_status = gaim2_savedstatus_get_current();
- if (saved_status != NULL) {
-- gaim_savedstatus_activate_for_account(saved_status, account);
-- gaim_account_set_enabled(account, GAIM_GTK_UI, TRUE);
-+ gaim2_savedstatus_activate_for_account(saved_status, account);
-+ gaim2_account_set_enabled(account, GAIM_GTK_UI, TRUE);
- }
- }
-
-@@ -1650,9 +1650,9 @@ ok_account_prefs_cb(GtkWidget *w, Accoun
- static void
- register_account_prefs_cb(GtkWidget *w, AccountPrefsDialog *dialog)
- {
-- GaimAccount *account = ok_account_prefs_cb(NULL, dialog);
-+ Gaim2Account *account = ok_account_prefs_cb(NULL, dialog);
-
-- gaim_account_register(account);
-+ gaim2_account_register(account);
- }
-
-
-@@ -1663,8 +1663,8 @@ static const GtkTargetEntry dnd_targets[
- };
-
- void
--gaim_gtk_account_dialog_show(GaimGtkAccountDialogType type,
-- GaimAccount *account)
-+gaim2_gtk_account_dialog_show(Gaim2GtkAccountDialogType type,
-+ Gaim2Account *account)
- {
- AccountPrefsDialog *dialog;
- GtkWidget *win;
-@@ -1695,17 +1695,17 @@ gaim_gtk_account_dialog_show(GaimGtkAcco
-
- if (dialog->account == NULL) {
- /* Select the first prpl in the list*/
-- GList *prpl_list = gaim_plugins_get_protocols();
-+ GList *prpl_list = gaim2_plugins_get_protocols();
- if (prpl_list != NULL)
-- dialog->protocol_id = g_strdup(((GaimPlugin *) prpl_list->data)->info->id);
-+ dialog->protocol_id = g_strdup(((Gaim2Plugin *) prpl_list->data)->info->id);
- }
- else
- {
- dialog->protocol_id =
-- g_strdup(gaim_account_get_protocol_id(dialog->account));
-+ g_strdup(gaim2_account_get_protocol_id(dialog->account));
- }
-
-- if ((dialog->plugin = gaim_find_prpl(dialog->protocol_id)) != NULL)
-+ if ((dialog->plugin = gaim2_find_prpl(dialog->protocol_id)) != NULL)
- dialog->prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(dialog->plugin);
-
-
-@@ -1819,10 +1819,10 @@ gaim_gtk_account_dialog_show(GaimGtkAcco
- * Accounts Dialog
- **************************************************************************/
- static void
--signed_on_off_cb(GaimConnection *gc, gpointer user_data)
-+signed_on_off_cb(Gaim2Connection *gc, gpointer user_data)
- {
-- GaimAccount *account;
-- GaimGtkPulseData *pulse_data;
-+ Gaim2Account *account;
-+ Gaim2GtkPulseData *pulse_data;
- GtkTreeModel *model;
- GtkTreeIter iter;
- GdkPixbuf *pixbuf, *scale = NULL;
-@@ -1832,9 +1832,9 @@ signed_on_off_cb(GaimConnection *gc, gpo
- if (accounts_window == NULL)
- return;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- model = GTK_TREE_MODEL(accounts_window->model);
-- index = g_list_index(gaim_accounts_get_all(), account);
-+ index = g_list_index(gaim2_accounts_get_all(), account);
-
- if (gtk_tree_model_iter_nth_child(model, &iter, NULL, index))
- {
-@@ -1851,14 +1851,14 @@ signed_on_off_cb(GaimConnection *gc, gpo
- g_free(pulse_data);
- }
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
- GDK_INTERP_BILINEAR);
-
-- if (gaim_account_is_disconnected(account))
-+ if (gaim2_account_is_disconnected(account))
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.0, FALSE);
- }
- gtk_list_store_set(accounts_window->model, &iter,
-@@ -1877,10 +1877,10 @@ signed_on_off_cb(GaimConnection *gc, gpo
- * GtkListStore
- */
- static gboolean
--accounts_window_find_account_in_treemodel(GtkTreeIter *iter, GaimAccount *account)
-+accounts_window_find_account_in_treemodel(GtkTreeIter *iter, Gaim2Account *account)
- {
- GtkTreeModel *model;
-- GaimAccount *cur;
-+ Gaim2Account *cur;
-
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(accounts_window != NULL, FALSE);
-@@ -1905,7 +1905,7 @@ accounts_window_find_account_in_treemode
- }
-
- static void
--account_removed_cb(GaimAccount *account, gpointer user_data)
-+account_removed_cb(Gaim2Account *account, gpointer user_data)
- {
- AccountPrefsDialog *dialog;
- GtkTreeIter iter;
-@@ -1923,7 +1923,7 @@ account_removed_cb(GaimAccount *account,
- }
-
- static void
--account_abled_cb(GaimAccount *account, gpointer user_data)
-+account_abled_cb(Gaim2Account *account, gpointer user_data)
- {
- GtkTreeIter iter;
-
-@@ -1946,7 +1946,7 @@ drag_data_get_cb(GtkWidget *widget, GdkD
- GtkTreeRowReference *ref;
- GtkTreePath *source_row;
- GtkTreeIter iter;
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- GValue val;
-
- ref = g_object_get_data(G_OBJECT(ctx), "gtk-tree-view-source-row");
-@@ -1977,7 +1977,7 @@ move_account_after(GtkListStore *store,
- GtkTreeIter *position)
- {
- GtkTreeIter new_iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- gtk_tree_model_get(GTK_TREE_MODEL(store), iter,
- COLUMN_DATA, &account,
-@@ -1995,7 +1995,7 @@ move_account_before(GtkListStore *store,
- GtkTreeIter *position)
- {
- GtkTreeIter new_iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- gtk_tree_model_get(GTK_TREE_MODEL(store), iter,
- COLUMN_DATA, &account,
-@@ -2015,7 +2015,7 @@ drag_data_received_cb(GtkWidget *widget,
- {
- if (sd->target == gdk_atom_intern("GAIM_ACCOUNT", FALSE) && sd->data) {
- gint dest_index;
-- GaimAccount *a = NULL;
-+ Gaim2Account *a = NULL;
- GtkTreePath *path = NULL;
- GtkTreeViewDropPosition position;
-
-@@ -2025,7 +2025,7 @@ drag_data_received_cb(GtkWidget *widget,
- &path, &position)) {
-
- GtkTreeIter iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
- GValue val;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(dialog->model), &iter, path);
-@@ -2040,13 +2040,13 @@ drag_data_received_cb(GtkWidget *widget,
- 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(),
-+ dest_index = g_list_index(gaim2_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(),
-+ dest_index = g_list_index(gaim2_accounts_get_all(),
- account);
-
- move_account_before(dialog->model, &dialog->drag_iter,
-@@ -2057,7 +2057,7 @@ drag_data_received_cb(GtkWidget *widget,
- return;
- }
-
-- gaim_accounts_reorder(a, dest_index);
-+ gaim2_accounts_reorder(a, dest_index);
- }
- }
- }
-@@ -2065,7 +2065,7 @@ drag_data_received_cb(GtkWidget *widget,
- static gint
- accedit_win_destroy_cb(GtkWidget *w, GdkEvent *event, AccountsWindow *dialog)
- {
-- gaim_gtk_accounts_window_hide();
-+ gaim2_gtk_accounts_window_hide();
-
- return 0;
- }
-@@ -2074,12 +2074,12 @@ 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 old_width = gaim2_prefs_get_int("/gaim2/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);
-+ gaim2_prefs_set_int("/gaim2/gtk/accounts/dialog/width", event->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/accounts/dialog/height", event->height);
-
- col_width = gtk_tree_view_column_get_width(dialog->screenname_col);
-
-@@ -2106,19 +2106,19 @@ configure_cb(GtkWidget *w, GdkEventConfi
- static void
- add_account_cb(GtkWidget *w, AccountsWindow *dialog)
- {
-- gaim_gtk_account_dialog_show(GAIM_GTK_ADD_ACCOUNT_DIALOG, NULL);
-+ gaim2_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;
-+ Gaim2Account *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);
-+ gaim2_gtk_account_dialog_show(GAIM_GTK_MODIFY_ACCOUNT_DIALOG, account);
- }
-
- static void
-@@ -2132,16 +2132,16 @@ modify_account_cb(GtkWidget *w, Accounts
- }
-
- static void
--delete_account_cb(GaimAccount *account)
-+delete_account_cb(Gaim2Account *account)
- {
-- gaim_accounts_delete(account);
-+ gaim2_accounts_delete(account);
- }
-
- static void
- ask_delete_account_sel(GtkTreeModel *model, GtkTreePath *path,
- GtkTreeIter *iter, gpointer data)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- gtk_tree_model_get(model, iter, COLUMN_DATA, &account, -1);
-
-@@ -2149,10 +2149,10 @@ ask_delete_account_sel(GtkTreeModel *mod
- char *buf;
-
- buf = g_strdup_printf(_("Are you sure you want to delete %s?"),
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
-
-- gaim_request_close_with_handle(account);
-- gaim_request_action(account, NULL, buf, NULL, 0, account, 2,
-+ gaim2_request_close_with_handle(account);
-+ gaim2_request_action(account, NULL, buf, NULL, 0, account, 2,
- _("Delete"), delete_account_cb,
- _("Cancel"), NULL);
- g_free(buf);
-@@ -2175,7 +2175,7 @@ close_accounts_cb(GtkWidget *w, Accounts
- {
- gtk_widget_destroy(dialog->window);
-
-- gaim_gtk_accounts_window_hide();
-+ gaim2_gtk_accounts_window_hide();
- }
-
-
-@@ -2184,11 +2184,11 @@ enabled_cb(GtkCellRendererToggle *render
- gpointer data)
- {
- AccountsWindow *dialog = (AccountsWindow *)data;
-- GaimAccount *account;
-+ Gaim2Account *account;
- GtkTreeModel *model = GTK_TREE_MODEL(dialog->model);
- GtkTreeIter iter;
- gboolean enabled;
-- const GaimSavedStatus *saved_status;
-+ const Gaim2SavedStatus *saved_status;
-
- gtk_tree_model_get_iter_from_string(model, &iter, path_str);
- gtk_tree_model_get(model, &iter,
-@@ -2197,10 +2197,10 @@ enabled_cb(GtkCellRendererToggle *render
- -1);
-
- /* Set the statuses for this account to the current status */
-- saved_status = gaim_savedstatus_get_current();
-- gaim_savedstatus_activate_for_account(saved_status, account);
-+ saved_status = gaim2_savedstatus_get_current();
-+ gaim2_savedstatus_activate_for_account(saved_status, account);
-
-- gaim_account_set_enabled(account, GAIM_GTK_UI, !enabled);
-+ gaim2_account_set_enabled(account, GAIM_GTK_UI, !enabled);
- }
-
- static void
-@@ -2253,28 +2253,28 @@ add_columns(GtkWidget *treeview, Account
- }
-
- static void
--set_account(GtkListStore *store, GtkTreeIter *iter, GaimAccount *account)
-+set_account(GtkListStore *store, GtkTreeIter *iter, Gaim2Account *account)
- {
- GdkPixbuf *pixbuf;
- GdkPixbuf *scale;
-
- scale = NULL;
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16, GDK_INTERP_BILINEAR);
-
-- if (gaim_account_is_disconnected(account))
-+ if (gaim2_account_is_disconnected(account))
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.0, FALSE);
- }
-
- gtk_list_store_set(store, iter,
- COLUMN_ICON, scale,
-- 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_SCREENNAME, gaim2_account_get_username(account),
-+ COLUMN_ENABLED, gaim2_account_get_enabled(account, GAIM_GTK_UI),
-+ COLUMN_PROTOCOL, gaim2_account_get_protocol_name(account),
- COLUMN_DATA, account,
- -1);
-
-@@ -2283,7 +2283,7 @@ set_account(GtkListStore *store, GtkTree
- }
-
- static void
--add_account_to_liststore(GaimAccount *account, gpointer user_data)
-+add_account_to_liststore(Gaim2Account *account, gpointer user_data)
- {
- GtkTreeIter iter;
-
-@@ -2302,8 +2302,8 @@ populate_accounts_list(AccountsWindow *d
-
- 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);
-+ for (l = gaim2_accounts_get_all(); l != NULL; l = l->next)
-+ add_account_to_liststore((Gaim2Account *)l->data, NULL);
- }
-
- #if !GTK_CHECK_VERSION(2,2,0)
-@@ -2337,7 +2337,7 @@ account_treeview_double_click_cb(GtkTree
- GtkTreePath *path;
- GtkTreeViewColumn *column;
- GtkTreeIter iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
- const gchar *title;
-
- dialog = (AccountsWindow *)user_data;
-@@ -2357,7 +2357,7 @@ account_treeview_double_click_cb(GtkTree
- (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);
-+ gaim2_gtk_account_dialog_show(GAIM_GTK_MODIFY_ACCOUNT_DIALOG, account);
- return TRUE;
- }
-
-@@ -2425,7 +2425,7 @@ create_accounts_list(AccountsWindow *dia
- }
-
- static void
--account_modified_cb(GaimAccount *account, AccountsWindow *window)
-+account_modified_cb(Gaim2Account *account, AccountsWindow *window)
- {
- GtkTreeIter iter;
-
-@@ -2436,7 +2436,7 @@ account_modified_cb(GaimAccount *account
- }
-
- void
--gaim_gtk_accounts_window_show(void)
-+gaim2_gtk_accounts_window_show(void)
- {
- AccountsWindow *dialog;
- GtkWidget *win;
-@@ -2453,8 +2453,8 @@ gaim_gtk_accounts_window_show(void)
-
- 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");
-+ width = gaim2_prefs_get_int("/gaim2/gtk/accounts/dialog/width");
-+ height = gaim2_prefs_get_int("/gaim2/gtk/accounts/dialog/height");
-
- dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
- gtk_window_set_default_size(GTK_WINDOW(win), width, height);
-@@ -2520,7 +2520,7 @@ gaim_gtk_accounts_window_show(void)
- g_signal_connect(G_OBJECT(button), "clicked",
- G_CALLBACK(close_accounts_cb), dialog);
-
-- gaim_signal_connect(gaim_gtk_account_get_handle(), "account-modified",
-+ gaim2_signal_connect(gaim2_gtk_account_get_handle(), "account-modified",
- accounts_window,
- GAIM_CALLBACK(account_modified_cb), accounts_window);
-
-@@ -2528,26 +2528,26 @@ gaim_gtk_accounts_window_show(void)
- }
-
- void
--gaim_gtk_accounts_window_hide(void)
-+gaim2_gtk_accounts_window_hide(void)
- {
- if (accounts_window == NULL)
- return;
-
-- gaim_signals_disconnect_by_handle(accounts_window);
-+ gaim2_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) {
-+ if (GAIM_GTK_BLIST(gaim2_get_blist())->window == NULL &&
-+ gaim2_connections_get_all() == NULL) {
-
-- gaim_core_quit();
-+ gaim2_core_quit();
- }
- }
-
- static void
--free_add_user_data(GaimGtkAccountAddUserData *data)
-+free_add_user_data(Gaim2GtkAccountAddUserData *data)
- {
- g_free(data->username);
-
-@@ -2558,13 +2558,13 @@ free_add_user_data(GaimGtkAccountAddUser
- }
-
- static void
--add_user_cb(GaimGtkAccountAddUserData *data)
-+add_user_cb(Gaim2GtkAccountAddUserData *data)
- {
-- GaimConnection *gc = gaim_account_get_connection(data->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(data->account);
-
-- if (g_list_find(gaim_connections_get_all(), gc))
-+ if (g_list_find(gaim2_connections_get_all(), gc))
- {
-- gaim_blist_request_add_buddy(data->account, data->username,
-+ gaim2_blist_request_add_buddy(data->account, data->username,
- NULL, data->alias);
- }
-
-@@ -2572,7 +2572,7 @@ add_user_cb(GaimGtkAccountAddUserData *d
- }
-
- static char *
--make_info(GaimAccount *account, GaimConnection *gc, const char *remote_user,
-+make_info(Gaim2Account *account, Gaim2Connection *gc, const char *remote_user,
- const char *id, const char *alias, const char *msg)
- {
- return g_strdup_printf(_("%s%s%s%s has made %s his or her buddy%s%s"),
-@@ -2582,49 +2582,49 @@ make_info(GaimAccount *account, GaimConn
- (alias != NULL ? ")" : ""),
- (id != NULL
- ? id
-- : (gaim_connection_get_display_name(gc) != NULL
-- ? gaim_connection_get_display_name(gc)
-- : gaim_account_get_username(account))),
-+ : (gaim2_connection_get_display_name(gc) != NULL
-+ ? gaim2_connection_get_display_name(gc)
-+ : gaim2_account_get_username(account))),
- (msg != NULL ? ": " : "."),
- (msg != NULL ? msg : ""));
- }
-
- static void
--gaim_gtk_accounts_notify_added(GaimAccount *account, const char *remote_user,
-+gaim2_gtk_accounts_notify_added(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *msg)
- {
- char *buffer;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- buffer = make_info(account, gc, remote_user, id, alias, msg);
-
-- gaim_notify_info(NULL, NULL, buffer, NULL);
-+ gaim2_notify_info(NULL, NULL, buffer, NULL);
-
- g_free(buffer);
- }
-
- static void
--gaim_gtk_accounts_request_add(GaimAccount *account, const char *remote_user,
-+gaim2_gtk_accounts_request_add(Gaim2Account *account, const char *remote_user,
- const char *id, const char *alias,
- const char *msg)
- {
- char *buffer;
-- GaimConnection *gc;
-- GaimGtkAccountAddUserData *data;
-+ Gaim2Connection *gc;
-+ Gaim2GtkAccountAddUserData *data;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
-- data = g_new0(GaimGtkAccountAddUserData, 1);
-+ data = g_new0(Gaim2GtkAccountAddUserData, 1);
- data->account = account;
- data->username = g_strdup(remote_user);
- data->alias = (alias != NULL ? g_strdup(alias) : NULL);
-
- buffer = make_info(account, gc, remote_user, id, alias, msg);
-
-- gaim_request_action(NULL, NULL, _("Add buddy to your list?"),
-+ gaim2_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));
-@@ -2632,57 +2632,57 @@ gaim_gtk_accounts_request_add(GaimAccoun
- g_free(buffer);
- }
-
--static GaimAccountUiOps ui_ops =
-+static Gaim2AccountUiOps ui_ops =
- {
-- gaim_gtk_accounts_notify_added,
-+ gaim2_gtk_accounts_notify_added,
- NULL,
-- gaim_gtk_accounts_request_add
-+ gaim2_gtk_accounts_request_add
- };
-
--GaimAccountUiOps *
--gaim_gtk_accounts_get_ui_ops(void)
-+Gaim2AccountUiOps *
-+gaim2_gtk_accounts_get_ui_ops(void)
- {
- return &ui_ops;
- }
-
- void *
--gaim_gtk_account_get_handle() {
-+gaim2_gtk_account_get_handle() {
- static int handle;
-
- return &handle;
- }
-
- void
--gaim_gtk_account_init(void)
-+gaim2_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_signal_register(gaim_gtk_account_get_handle(), "account-modified",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_prefs_add_none("/gaim2/gtk/accounts");
-+ gaim2_prefs_add_none("/gaim2/gtk/accounts/dialog");
-+ gaim2_prefs_add_int("/gaim2/gtk/accounts/dialog/width", 520);
-+ gaim2_prefs_add_int("/gaim2/gtk/accounts/dialog/height", 321);
-+
-+ gaim2_signal_register(gaim2_gtk_account_get_handle(), "account-modified",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_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(),
-+ /* Setup some gaim2 signal handlers. */
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
-+ gaim2_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(),
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off",
-+ gaim2_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(),
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-added",
-+ gaim2_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(),
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-removed",
-+ gaim2_gtk_account_get_handle(),
- GAIM_CALLBACK(account_removed_cb), NULL);
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-disabled",
-- gaim_gtk_account_get_handle(),
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-disabled",
-+ gaim2_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(),
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-enabled",
-+ gaim2_gtk_account_get_handle(),
- GAIM_CALLBACK(account_abled_cb), GINT_TO_POINTER(TRUE));
-
- account_pref_wins =
-@@ -2690,7 +2690,7 @@ gaim_gtk_account_init(void)
- }
-
- void
--gaim_gtk_account_uninit(void)
-+gaim2_gtk_account_uninit(void)
- {
- /*
- * TODO: Need to free all the dialogs in here. Could probably create
-@@ -2699,7 +2699,7 @@ gaim_gtk_account_uninit(void)
- */
- 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());
-+ gaim2_signals_disconnect_by_handle(gaim2_gtk_account_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_gtk_account_get_handle());
- }
-
-diff -prNu ./src/gtkaccount.h ./src/gtkaccount.h
---- ./src/gtkaccount.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gtkaccount.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkaccount.h GTK+ Account Editor UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,18 +32,18 @@ typedef enum
- GAIM_GTK_ADD_ACCOUNT_DIALOG,
- GAIM_GTK_MODIFY_ACCOUNT_DIALOG
-
--} GaimGtkAccountDialogType;
-+} Gaim2GtkAccountDialogType;
-
-
- /**
- * Shows the accounts window.
- */
--void gaim_gtk_accounts_window_show(void);
-+void gaim2_gtk_accounts_window_show(void);
-
- /**
- * Hides the accounts window.
- */
--void gaim_gtk_accounts_window_hide(void);
-+void gaim2_gtk_accounts_window_hide(void);
-
- /**
- * Shows an add/modify account dialog.
-@@ -51,31 +51,31 @@ void gaim_gtk_accounts_window_hide(void)
- * @param type The type of dialog.
- * @param account The associated account, or @c NULL for an Add dialog.
- */
--void gaim_gtk_account_dialog_show(GaimGtkAccountDialogType type,
-- GaimAccount *account);
-+void gaim2_gtk_account_dialog_show(Gaim2GtkAccountDialogType type,
-+ Gaim2Account *account);
-
- /**
- * Returns the GTK+ account UI ops
- *
- * @return The UI operations structure.
- */
--GaimAccountUiOps *gaim_gtk_accounts_get_ui_ops(void);
-+Gaim2AccountUiOps *gaim2_gtk_accounts_get_ui_ops(void);
-
- /**
- * Returns the gtkaccounts handle
- *
- * @return The handle to the GTK+ account system
- */
--void *gaim_gtk_account_get_handle(void);
-+void *gaim2_gtk_account_get_handle(void);
-
- /**
- * Initializes the GTK+ account system
- */
--void gaim_gtk_account_init(void);
-+void gaim2_gtk_account_init(void);
-
- /**
- * Uninitializes the GTK+ account system
- */
--void gaim_gtk_account_uninit(void);
-+void gaim2_gtk_account_uninit(void);
-
- #endif /* _GAIM_GTKACCOUNT_H_ */
-diff -prNu ./src/gtkblist.c ./src/gtkblist.c
---- ./src/gtkblist.c 2006-01-04 05:19:23.000000000 +0100
-+++ ./src/gtkblist.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkblist.c GTK+ BuddyList API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "connection.h"
-@@ -61,7 +61,7 @@
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- GtkWidget *window;
- GtkWidget *combo;
-@@ -69,11 +69,11 @@ typedef struct
- GtkWidget *entry_for_alias;
- GtkWidget *account_box;
-
--} GaimGtkAddBuddyData;
-+} Gaim2GtkAddBuddyData;
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- gchar *default_chat_name;
-
- GtkWidget *window;
-@@ -85,11 +85,11 @@ typedef struct
-
- GList *entries;
-
--} GaimGtkAddChatData;
-+} Gaim2GtkAddChatData;
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- GtkWidget *window;
- GtkWidget *account_menu;
-@@ -97,7 +97,7 @@ typedef struct
- GtkSizeGroup *sg;
-
- GList *entries;
--} GaimGtkJoinChatData;
-+} Gaim2GtkJoinChatData;
-
-
- static GtkWidget *accountmenu = NULL;
-@@ -105,31 +105,31 @@ static GtkWidget *accountmenu = NULL;
- static guint visibility_manager_count = 0;
- static gboolean gtk_blist_obscured = FALSE;
-
--static GList *gaim_gtk_blist_sort_methods = NULL;
--static struct gaim_gtk_blist_sort_method *current_sort_method = NULL;
--static void sort_method_none(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
-+static GList *gaim2_gtk_blist_sort_methods = NULL;
-+static struct gaim2_gtk_blist_sort_method *current_sort_method = NULL;
-+static void sort_method_none(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
-
- /* The functions we use for sorting aren't available in gtk 2.0.x, and
- * segfault in 2.2.0. 2.2.1 is known to work, so I'll require that */
- #if GTK_CHECK_VERSION(2,2,1)
--static void sort_method_alphabetical(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
--static void sort_method_status(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
--static void sort_method_log(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
-+static void sort_method_alphabetical(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
-+static void sort_method_status(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
-+static void sort_method_log(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter);
- #endif
--static GaimGtkBuddyList *gtkblist = NULL;
-+static Gaim2GtkBuddyList *gtkblist = NULL;
-
--static void gaim_gtk_blist_update_buddy(GaimBuddyList *list, GaimBlistNode *node);
--static void gaim_gtk_blist_selection_changed(GtkTreeSelection *selection, gpointer data);
--static void gaim_gtk_blist_update(GaimBuddyList *list, GaimBlistNode *node);
--static char *gaim_get_tooltip_text(GaimBlistNode *node, gboolean full);
-+static void gaim2_gtk_blist_update_buddy(Gaim2BuddyList *list, Gaim2BlistNode *node);
-+static void gaim2_gtk_blist_selection_changed(GtkTreeSelection *selection, gpointer data);
-+static void gaim2_gtk_blist_update(Gaim2BuddyList *list, Gaim2BlistNode *node);
-+static char *gaim2_get_tooltip_text(Gaim2BlistNode *node, gboolean full);
- static char *item_factory_translate_func (const char *path, gpointer func_data);
--static gboolean get_iter_from_node(GaimBlistNode *node, GtkTreeIter *iter);
--static void redo_buddy_list(GaimBuddyList *list, gboolean remove);
--static void gaim_gtk_blist_collapse_contact_cb(GtkWidget *w, GaimBlistNode *node);
-+static gboolean get_iter_from_node(Gaim2BlistNode *node, GtkTreeIter *iter);
-+static void redo_buddy_list(Gaim2BuddyList *list, gboolean remove);
-+static void gaim2_gtk_blist_collapse_contact_cb(GtkWidget *w, Gaim2BlistNode *node);
-
--static void gaim_gtk_blist_tooltip_destroy(void);
-+static void gaim2_gtk_blist_tooltip_destroy(void);
-
--struct _gaim_gtk_blist_node {
-+struct _gaim2_gtk_blist_node {
- GtkTreeRowReference *row;
- gboolean contact_expanded;
- gboolean recent_signonoff;
-@@ -170,16 +170,16 @@ static gboolean gtk_blist_window_state_c
- {
- if(event->changed_mask & GDK_WINDOW_STATE_WITHDRAWN) {
- if(event->new_window_state & GDK_WINDOW_STATE_WITHDRAWN)
-- gaim_prefs_set_bool("/gaim/gtk/blist/list_visible", FALSE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/list_visible", FALSE);
- else
-- gaim_prefs_set_bool("/gaim/gtk/blist/list_visible", TRUE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/list_visible", TRUE);
- }
-
- if(event->changed_mask & GDK_WINDOW_STATE_MAXIMIZED) {
- if(event->new_window_state & GDK_WINDOW_STATE_MAXIMIZED)
-- gaim_prefs_set_bool("/gaim/gtk/blist/list_maximized", TRUE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/list_maximized", TRUE);
- else
-- gaim_prefs_set_bool("/gaim/gtk/blist/list_maximized", FALSE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/list_maximized", FALSE);
- }
-
- return FALSE;
-@@ -188,9 +188,9 @@ static gboolean gtk_blist_window_state_c
- static gboolean gtk_blist_delete_cb(GtkWidget *w, GdkEventAny *event, gpointer data)
- {
- if(visibility_manager_count)
-- gaim_blist_set_visible(FALSE);
-+ gaim2_blist_set_visible(FALSE);
- else
-- gaim_core_quit();
-+ gaim2_core_quit();
-
- /* we handle everything, event should not propogate further */
- return TRUE;
-@@ -213,10 +213,10 @@ static gboolean gtk_blist_configure_cb(G
- return FALSE; /* carry on normally */
-
- /* don't save if nothing changed */
-- if (x == gaim_prefs_get_int("/gaim/gtk/blist/x") &&
-- y == gaim_prefs_get_int("/gaim/gtk/blist/y") &&
-- event->width == gaim_prefs_get_int("/gaim/gtk/blist/width") &&
-- event->height == gaim_prefs_get_int("/gaim/gtk/blist/height")) {
-+ if (x == gaim2_prefs_get_int("/gaim2/gtk/blist/x") &&
-+ y == gaim2_prefs_get_int("/gaim2/gtk/blist/y") &&
-+ event->width == gaim2_prefs_get_int("/gaim2/gtk/blist/width") &&
-+ event->height == gaim2_prefs_get_int("/gaim2/gtk/blist/height")) {
-
- return FALSE; /* carry on normally */
- }
-@@ -231,60 +231,60 @@ static gboolean gtk_blist_configure_cb(G
- }
-
- /* ignore changes when maximized */
-- if(gaim_prefs_get_bool("/gaim/gtk/blist/list_maximized"))
-+ if(gaim2_prefs_get_bool("/gaim2/gtk/blist/list_maximized"))
- return FALSE;
-
- /* store the position */
-- gaim_prefs_set_int("/gaim/gtk/blist/x", x);
-- gaim_prefs_set_int("/gaim/gtk/blist/y", y);
-- gaim_prefs_set_int("/gaim/gtk/blist/width", event->width);
-- gaim_prefs_set_int("/gaim/gtk/blist/height", event->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/blist/x", x);
-+ gaim2_prefs_set_int("/gaim2/gtk/blist/y", y);
-+ gaim2_prefs_set_int("/gaim2/gtk/blist/width", event->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/blist/height", event->height);
-
- /* continue to handle event normally */
- return FALSE;
- }
-
--static void gtk_blist_menu_info_cb(GtkWidget *w, GaimBuddy *b)
-+static void gtk_blist_menu_info_cb(GtkWidget *w, Gaim2Buddy *b)
- {
- serv_get_info(b->account->gc, b->name);
- }
-
--static void gtk_blist_menu_im_cb(GtkWidget *w, GaimBuddy *b)
-+static void gtk_blist_menu_im_cb(GtkWidget *w, Gaim2Buddy *b)
- {
-- gaim_gtkdialogs_im_with_user(b->account, b->name);
-+ gaim2_gtkdialogs_im_with_user(b->account, b->name);
- }
-
--static void gtk_blist_menu_send_file_cb(GtkWidget *w, GaimBuddy *b)
-+static void gtk_blist_menu_send_file_cb(GtkWidget *w, Gaim2Buddy *b)
- {
- serv_send_file(b->account->gc, b->name, NULL);
- }
-
--static void gtk_blist_menu_voice_chat_cb(GtkWidget *w, GaimBuddy *b)
-+static void gtk_blist_menu_voice_chat_cb(GtkWidget *w, Gaim2Buddy *b)
- {
- serv_voice_chat(b->account->gc, b->name);
- }
-
--static void gtk_blist_menu_autojoin_cb(GtkWidget *w, GaimChat *chat)
-+static void gtk_blist_menu_autojoin_cb(GtkWidget *w, Gaim2Chat *chat)
- {
-- gaim_blist_node_set_bool((GaimBlistNode*)chat, "gtk-autojoin",
-+ gaim2_blist_node_set_bool((Gaim2BlistNode*)chat, "gtk-autojoin",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(w)));
- }
-
--static void gtk_blist_join_chat(GaimChat *chat)
-+static void gtk_blist_join_chat(Gaim2Chat *chat)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-- gaim_chat_get_name(chat),
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ gaim2_chat_get_name(chat),
- chat->account);
-
- if (conv != NULL)
-- gaim_gtkconv_present_conversation(conv);
-+ gaim2_gtkconv_present_conversation(conv);
-
- serv_join_chat(chat->account->gc, chat->components);
- }
-
--static void gtk_blist_menu_join_cb(GtkWidget *w, GaimChat *chat)
-+static void gtk_blist_menu_join_cb(GtkWidget *w, Gaim2Chat *chat)
- {
- gtk_blist_join_chat(chat);
- }
-@@ -295,7 +295,7 @@ static void gtk_blist_renderer_edited_cb
- GtkTreeIter iter;
- GtkTreePath *path;
- GValue val;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
-
- path = gtk_tree_path_new_from_string (arg1);
- gtk_tree_model_get_iter (GTK_TREE_MODEL(gtkblist->treemodel), &iter, path);
-@@ -310,36 +310,36 @@ static void gtk_blist_renderer_edited_cb
- {
- case GAIM_BLIST_CONTACT_NODE:
- {
-- GaimContact *contact = (GaimContact *)node;
-- struct _gaim_gtk_blist_node *gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ Gaim2Contact *contact = (Gaim2Contact *)node;
-+ struct _gaim2_gtk_blist_node *gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
-
- if (contact->alias || gtknode->contact_expanded)
-- gaim_blist_alias_contact(contact, arg2);
-+ gaim2_blist_alias_contact(contact, arg2);
- else
- {
-- GaimBuddy *buddy = gaim_contact_get_priority_buddy(contact);
-- gaim_blist_alias_buddy(buddy, arg2);
-+ Gaim2Buddy *buddy = gaim2_contact_get_priority_buddy(contact);
-+ gaim2_blist_alias_buddy(buddy, arg2);
- serv_alias_buddy(buddy);
- }
- }
- break;
-
- case GAIM_BLIST_BUDDY_NODE:
-- gaim_blist_alias_buddy((GaimBuddy*)node, arg2);
-- serv_alias_buddy((GaimBuddy *)node);
-+ gaim2_blist_alias_buddy((Gaim2Buddy*)node, arg2);
-+ serv_alias_buddy((Gaim2Buddy *)node);
- break;
- case GAIM_BLIST_GROUP_NODE:
-- gaim_blist_rename_group((GaimGroup*)node, arg2);
-+ gaim2_blist_rename_group((Gaim2Group*)node, arg2);
- break;
- case GAIM_BLIST_CHAT_NODE:
-- gaim_blist_alias_chat((GaimChat*)node, arg2);
-+ gaim2_blist_alias_chat((Gaim2Chat*)node, arg2);
- break;
- default:
- break;
- }
- }
-
--static void gtk_blist_menu_alias_cb(GtkWidget *w, GaimBlistNode *node)
-+static void gtk_blist_menu_alias_cb(GtkWidget *w, Gaim2BlistNode *node)
- {
- GtkTreeIter iter;
- GtkTreePath *path;
-@@ -355,16 +355,16 @@ static void gtk_blist_menu_alias_cb(GtkW
-
- switch (node->type) {
- case GAIM_BLIST_BUDDY_NODE:
-- text = gaim_buddy_get_alias((GaimBuddy *)node);
-+ text = gaim2_buddy_get_alias((Gaim2Buddy *)node);
- break;
- case GAIM_BLIST_CONTACT_NODE:
-- text = gaim_contact_get_alias((GaimContact *)node);
-+ text = gaim2_contact_get_alias((Gaim2Contact *)node);
- break;
- case GAIM_BLIST_GROUP_NODE:
-- text = ((GaimGroup *)node)->name;
-+ text = ((Gaim2Group *)node)->name;
- break;
- case GAIM_BLIST_CHAT_NODE:
-- text = gaim_chat_get_name((GaimChat *)node);
-+ text = gaim2_chat_get_name((Gaim2Chat *)node);
- break;
- default:
- g_return_if_reached();
-@@ -380,16 +380,16 @@ static void gtk_blist_menu_alias_cb(GtkW
- gtk_tree_path_free(path);
- }
-
--static void gtk_blist_menu_bp_cb(GtkWidget *w, GaimBuddy *b)
-+static void gtk_blist_menu_bp_cb(GtkWidget *w, Gaim2Buddy *b)
- {
-- gaim_gtk_pounce_editor_show(b->account, b->name, NULL);
-+ gaim2_gtk_pounce_editor_show(b->account, b->name, NULL);
- }
-
--static void gtk_blist_menu_showlog_cb(GtkWidget *w, GaimBlistNode *node)
-+static void gtk_blist_menu_showlog_cb(GtkWidget *w, Gaim2BlistNode *node)
- {
- GdkCursor *cursor = gdk_cursor_new(GDK_WATCH);
-- GaimLogType type;
-- GaimAccount *account;
-+ Gaim2LogType type;
-+ Gaim2Account *account;
- char *name = NULL;
-
- gdk_window_set_cursor(gtkblist->window->window, cursor);
-@@ -398,21 +398,21 @@ static void gtk_blist_menu_showlog_cb(Gt
- gtk_main_iteration();
-
- if (GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- GaimBuddy *b = (GaimBuddy*) node;
-+ Gaim2Buddy *b = (Gaim2Buddy*) node;
- type = GAIM_LOG_IM;
- name = g_strdup(b->name);
- account = b->account;
- } else if (GAIM_BLIST_NODE_IS_CHAT(node)) {
-- GaimChat *c = (GaimChat*) node;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Chat *c = (Gaim2Chat*) node;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- type = GAIM_LOG_CHAT;
- account = c->account;
-- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gaim_find_prpl(gaim_account_get_protocol_id(account)));
-+ prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gaim2_find_prpl(gaim2_account_get_protocol_id(account)));
- if (prpl_info && prpl_info->get_chat_name) {
- name = prpl_info->get_chat_name(c->components);
- }
- } else if (GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- gaim_gtk_log_show_contact((GaimContact *)node);
-+ gaim2_gtk_log_show_contact((Gaim2Contact *)node);
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- return;
- } else {
-@@ -424,7 +424,7 @@ static void gtk_blist_menu_showlog_cb(Gt
- }
-
- if (name && account) {
-- gaim_gtk_log_show(type, name, account);
-+ gaim2_gtk_log_show(type, name, account);
- g_free(name);
-
- gdk_window_set_cursor(gtkblist->window->window, NULL);
-@@ -433,23 +433,23 @@ static void gtk_blist_menu_showlog_cb(Gt
-
- static void gtk_blist_show_systemlog_cb()
- {
-- gaim_gtk_syslog_show();
-+ gaim2_gtk_syslog_show();
- }
-
- static void gtk_blist_show_onlinehelp_cb()
- {
-- gaim_notify_uri(NULL, GAIM_WEBSITE "documentation.php");
-+ gaim2_notify_uri(NULL, GAIM_WEBSITE "documentation.php");
- }
-
- static void
--do_join_chat(GaimGtkJoinChatData *data)
-+do_join_chat(Gaim2GtkJoinChatData *data)
- {
- if (data)
- {
- GHashTable *components =
- g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free);
- GList *tmp;
-- GaimChat *chat;
-+ Gaim2Chat *chat;
-
- for (tmp = data->entries; tmp != NULL; tmp = tmp->next)
- {
-@@ -468,14 +468,14 @@ do_join_chat(GaimGtkJoinChatData *data)
- }
- }
-
-- chat = gaim_chat_new(data->account, NULL, components);
-+ chat = gaim2_chat_new(data->account, NULL, components);
- gtk_blist_join_chat(chat);
-- gaim_blist_remove_chat(chat);
-+ gaim2_blist_remove_chat(chat);
- }
- }
-
- static void
--do_joinchat(GtkWidget *dialog, int id, GaimGtkJoinChatData *info)
-+do_joinchat(GtkWidget *dialog, int id, Gaim2GtkJoinChatData *info)
- {
- switch(id)
- {
-@@ -497,7 +497,7 @@ do_joinchat(GtkWidget *dialog, int id, G
- static void
- joinchat_set_sensitive_if_input_cb(GtkWidget *entry, gpointer user_data)
- {
-- GaimGtkJoinChatData *data;
-+ Gaim2GtkJoinChatData *data;
- GList *tmp;
- const char *text;
- gboolean required;
-@@ -520,9 +520,9 @@ joinchat_set_sensitive_if_input_cb(GtkWi
- }
-
- static void
--rebuild_joinchat_entries(GaimGtkJoinChatData *data)
-+rebuild_joinchat_entries(Gaim2GtkJoinChatData *data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GList *list = NULL, *tmp = NULL;
- GHashTable *defaults = NULL;
- struct proto_chat_entry *pce;
-@@ -530,7 +530,7 @@ rebuild_joinchat_entries(GaimGtkJoinChat
-
- g_return_if_fail(data->account != NULL);
-
-- gc = gaim_account_get_connection(data->account);
-+ gc = gaim2_account_get_connection(data->account);
-
- while (GTK_BOX(data->entries_box)->children)
- {
-@@ -599,7 +599,7 @@ rebuild_joinchat_entries(GaimGtkJoinChat
- focus = FALSE;
- }
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), input);
-- gaim_set_accessible_label(input, label);
-+ gaim2_set_accessible_label(input, label);
- g_object_set_data(G_OBJECT(input), "identifier", pce->identifier);
- g_object_set_data(G_OBJECT(input), "is_spin", GINT_TO_POINTER(pce->is_int));
- g_object_set_data(G_OBJECT(input), "required", GINT_TO_POINTER(pce->required));
-@@ -618,11 +618,11 @@ rebuild_joinchat_entries(GaimGtkJoinChat
- }
-
- static void
--joinchat_select_account_cb(GObject *w, GaimAccount *account,
-- GaimGtkJoinChatData *data)
-+joinchat_select_account_cb(GObject *w, Gaim2Account *account,
-+ Gaim2GtkJoinChatData *data)
- {
-- if (strcmp(gaim_account_get_protocol_id(data->account),
-- gaim_account_get_protocol_id(account)) == 0)
-+ if (strcmp(gaim2_account_get_protocol_id(data->account),
-+ gaim2_account_get_protocol_id(account)) == 0)
- {
- data->account = account;
- }
-@@ -634,10 +634,10 @@ joinchat_select_account_cb(GObject *w, G
- }
-
- static gboolean
--chat_account_filter_func(GaimAccount *account)
-+chat_account_filter_func(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -645,15 +645,15 @@ chat_account_filter_func(GaimAccount *ac
- }
-
- gboolean
--gaim_gtk_blist_joinchat_is_showable()
-+gaim2_gtk_blist_joinchat_is_showable()
- {
- GList *c;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- for (c = gaim_connections_get_all(); c != NULL; c = c->next) {
-+ for (c = gaim2_connections_get_all(); c != NULL; c = c->next) {
- gc = c->data;
-
-- if (chat_account_filter_func(gaim_connection_get_account(gc)))
-+ if (chat_account_filter_func(gaim2_connection_get_account(gc)))
- return TRUE;
- }
-
-@@ -661,19 +661,19 @@ gaim_gtk_blist_joinchat_is_showable()
- }
-
- void
--gaim_gtk_blist_joinchat_show(void)
-+gaim2_gtk_blist_joinchat_show(void)
- {
- GtkWidget *hbox, *vbox;
- GtkWidget *rowbox;
- GtkWidget *label;
-- GaimGtkBuddyList *gtkblist;
-+ Gaim2GtkBuddyList *gtkblist;
- GtkWidget *img = NULL;
-- GaimGtkJoinChatData *data = NULL;
-+ Gaim2GtkJoinChatData *data = NULL;
-
-- gtkblist = GAIM_GTK_BLIST(gaim_get_blist());
-+ gtkblist = GAIM_GTK_BLIST(gaim2_get_blist());
- img = gtk_image_new_from_stock(GAIM_STOCK_DIALOG_QUESTION,
- GTK_ICON_SIZE_DIALOG);
-- data = g_new0(GaimGtkJoinChatData, 1);
-+ data = g_new0(Gaim2GtkJoinChatData, 1);
-
- data->window = gtk_dialog_new_with_buttons(_("Join a Chat"),
- NULL, GTK_DIALOG_NO_SEPARATOR,
-@@ -712,19 +712,19 @@ gaim_gtk_blist_joinchat_show(void)
- gtk_box_pack_start(GTK_BOX(rowbox), label, FALSE, FALSE, 0);
- gtk_size_group_add_widget(data->sg, label);
-
-- data->account_menu = gaim_gtk_account_option_menu_new(NULL, FALSE,
-+ data->account_menu = gaim2_gtk_account_option_menu_new(NULL, FALSE,
- G_CALLBACK(joinchat_select_account_cb),
- chat_account_filter_func, data);
- gtk_box_pack_start(GTK_BOX(rowbox), data->account_menu, TRUE, TRUE, 0);
- gtk_label_set_mnemonic_widget(GTK_LABEL(label),
- GTK_WIDGET(data->account_menu));
-- gaim_set_accessible_label (data->account_menu, label);
-+ gaim2_set_accessible_label (data->account_menu, label);
-
- data->entries_box = gtk_vbox_new(FALSE, 5);
- gtk_container_add(GTK_CONTAINER(vbox), data->entries_box);
- gtk_container_set_border_width(GTK_CONTAINER(data->entries_box), 0);
-
-- data->account = gaim_gtk_account_option_menu_get_selected(data->account_menu);
-+ data->account = gaim2_gtk_account_option_menu_get_selected(data->account_menu);
-
- rebuild_joinchat_entries(data);
-
-@@ -737,7 +737,7 @@ gaim_gtk_blist_joinchat_show(void)
- }
-
- static void gtk_blist_row_expanded_cb(GtkTreeView *tv, GtkTreeIter *iter, GtkTreePath *path, gpointer user_data) {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-
- val.g_type = 0;
-@@ -746,12 +746,12 @@ static void gtk_blist_row_expanded_cb(Gt
- node = g_value_get_pointer(&val);
-
- if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_blist_node_set_bool(node, "collapsed", FALSE);
-+ gaim2_blist_node_set_bool(node, "collapsed", FALSE);
- }
- }
-
- static void gtk_blist_row_collapsed_cb(GtkTreeView *tv, GtkTreeIter *iter, GtkTreePath *path, gpointer user_data) {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-
- val.g_type = 0;
-@@ -760,14 +760,14 @@ static void gtk_blist_row_collapsed_cb(G
- node = g_value_get_pointer(&val);
-
- if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_blist_node_set_bool(node, "collapsed", TRUE);
-+ gaim2_blist_node_set_bool(node, "collapsed", TRUE);
- } else if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- gaim_gtk_blist_collapse_contact_cb(NULL, node);
-+ gaim2_gtk_blist_collapse_contact_cb(NULL, node);
- }
- }
-
- static void gtk_blist_row_activated_cb(GtkTreeView *tv, GtkTreePath *path, GtkTreeViewColumn *col, gpointer data) {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GtkTreeIter iter;
- GValue val;
-
-@@ -778,16 +778,16 @@ static void gtk_blist_row_activated_cb(G
- node = g_value_get_pointer(&val);
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node) || GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node))
-- buddy = gaim_contact_get_priority_buddy((GaimContact*)node);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
- else
-- buddy = (GaimBuddy*)node;
-+ buddy = (Gaim2Buddy*)node;
-
-- gaim_gtkdialogs_im_with_user(buddy->account, buddy->name);
-+ gaim2_gtkdialogs_im_with_user(buddy->account, buddy->name);
- } else if (GAIM_BLIST_NODE_IS_CHAT(node)) {
-- gtk_blist_join_chat((GaimChat *)node);
-+ gtk_blist_join_chat((Gaim2Chat *)node);
- } else if (GAIM_BLIST_NODE_IS_GROUP(node)) {
- if (gtk_tree_view_row_expanded(tv, path))
- gtk_tree_view_collapse_row(tv, path);
-@@ -796,80 +796,80 @@ static void gtk_blist_row_activated_cb(G
- }
- }
-
--static void gaim_gtk_blist_add_chat_cb()
-+static void gaim2_gtk_blist_add_chat_cb()
- {
- GtkTreeSelection *sel = gtk_tree_view_get_selection(GTK_TREE_VIEW(gtkblist->treeview));
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
-
- if(gtk_tree_selection_get_selected(sel, NULL, &iter)){
- gtk_tree_model_get(GTK_TREE_MODEL(gtkblist->treemodel), &iter, NODE_COLUMN, &node, -1);
- if (GAIM_BLIST_NODE_IS_BUDDY(node))
-- gaim_blist_request_add_chat(NULL, (GaimGroup*)node->parent->parent, NULL, NULL);
-+ gaim2_blist_request_add_chat(NULL, (Gaim2Group*)node->parent->parent, NULL, NULL);
- if (GAIM_BLIST_NODE_IS_CONTACT(node) || GAIM_BLIST_NODE_IS_CHAT(node))
-- gaim_blist_request_add_chat(NULL, (GaimGroup*)node->parent, NULL, NULL);
-+ gaim2_blist_request_add_chat(NULL, (Gaim2Group*)node->parent, NULL, NULL);
- else if (GAIM_BLIST_NODE_IS_GROUP(node))
-- gaim_blist_request_add_chat(NULL, (GaimGroup*)node, NULL, NULL);
-+ gaim2_blist_request_add_chat(NULL, (Gaim2Group*)node, NULL, NULL);
- }
- else {
-- gaim_blist_request_add_chat(NULL, NULL, NULL, NULL);
-+ gaim2_blist_request_add_chat(NULL, NULL, NULL, NULL);
- }
- }
-
--static void gaim_gtk_blist_add_buddy_cb()
-+static void gaim2_gtk_blist_add_buddy_cb()
- {
- GtkTreeSelection *sel = gtk_tree_view_get_selection(GTK_TREE_VIEW(gtkblist->treeview));
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
-
- if(gtk_tree_selection_get_selected(sel, NULL, &iter)){
- gtk_tree_model_get(GTK_TREE_MODEL(gtkblist->treemodel), &iter, NODE_COLUMN, &node, -1);
- if (GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- gaim_blist_request_add_buddy(NULL, NULL, ((GaimGroup*)node->parent->parent)->name,
-+ gaim2_blist_request_add_buddy(NULL, NULL, ((Gaim2Group*)node->parent->parent)->name,
- NULL);
- } else if (GAIM_BLIST_NODE_IS_CONTACT(node)
- || GAIM_BLIST_NODE_IS_CHAT(node)) {
-- gaim_blist_request_add_buddy(NULL, NULL, ((GaimGroup*)node->parent)->name, NULL);
-+ gaim2_blist_request_add_buddy(NULL, NULL, ((Gaim2Group*)node->parent)->name, NULL);
- } else if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_blist_request_add_buddy(NULL, NULL, ((GaimGroup*)node)->name, NULL);
-+ gaim2_blist_request_add_buddy(NULL, NULL, ((Gaim2Group*)node)->name, NULL);
- }
- }
- else {
-- gaim_blist_request_add_buddy(NULL, NULL, NULL, NULL);
-+ gaim2_blist_request_add_buddy(NULL, NULL, NULL, NULL);
- }
- }
-
- static void
--gaim_gtk_blist_remove_cb (GtkWidget *w, GaimBlistNode *node)
-+gaim2_gtk_blist_remove_cb (GtkWidget *w, Gaim2BlistNode *node)
- {
- if (GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- gaim_gtkdialogs_remove_buddy((GaimBuddy*)node);
-+ gaim2_gtkdialogs_remove_buddy((Gaim2Buddy*)node);
- } else if (GAIM_BLIST_NODE_IS_CHAT(node)) {
-- gaim_gtkdialogs_remove_chat((GaimChat*)node);
-+ gaim2_gtkdialogs_remove_chat((Gaim2Chat*)node);
- } else if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_gtkdialogs_remove_group((GaimGroup*)node);
-+ gaim2_gtkdialogs_remove_group((Gaim2Group*)node);
- } else if (GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- gaim_gtkdialogs_remove_contact((GaimContact*)node);
-+ gaim2_gtkdialogs_remove_contact((Gaim2Contact*)node);
- }
- }
-
- static void
--gaim_gtk_blist_expand_contact_cb(GtkWidget *w, GaimBlistNode *node)
-+gaim2_gtk_blist_expand_contact_cb(GtkWidget *w, Gaim2BlistNode *node)
- {
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
- GtkTreeIter iter, parent;
-- GaimBlistNode *bnode;
-+ Gaim2BlistNode *bnode;
- GtkTreePath *path;
-
- if(!GAIM_BLIST_NODE_IS_CONTACT(node))
- return;
-
-- gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
-
- gtknode->contact_expanded = TRUE;
-
- for(bnode = node->child; bnode; bnode = bnode->next) {
-- gaim_gtk_blist_update(NULL, bnode);
-+ gaim2_gtk_blist_update(NULL, bnode);
- }
-
- /* This ensures that the bottom buddy is visible, i.e. not scrolled off the alignment */
-@@ -883,48 +883,48 @@ gaim_gtk_blist_expand_contact_cb(GtkWidg
- gtk_tree_view_scroll_to_cell (GTK_TREE_VIEW(gtkblist->treeview), path, NULL, FALSE, 0, 0);
-
-
-- gaim_gtk_blist_update(NULL, node);
-+ gaim2_gtk_blist_update(NULL, node);
- gtk_tree_path_free(path);
- }
-
- static void
--gaim_gtk_blist_collapse_contact_cb(GtkWidget *w, GaimBlistNode *node)
-+gaim2_gtk_blist_collapse_contact_cb(GtkWidget *w, Gaim2BlistNode *node)
- {
-- GaimBlistNode *bnode;
-- struct _gaim_gtk_blist_node *gtknode;
-+ Gaim2BlistNode *bnode;
-+ struct _gaim2_gtk_blist_node *gtknode;
-
- if(!GAIM_BLIST_NODE_IS_CONTACT(node))
- return;
-
-- gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
-
- gtknode->contact_expanded = FALSE;
-
- for(bnode = node->child; bnode; bnode = bnode->next) {
-- gaim_gtk_blist_update(NULL, bnode);
-+ gaim2_gtk_blist_update(NULL, bnode);
- }
- }
-
-
- static void
--blist_node_menu_cb(GtkMenuItem *item, GaimBlistNode *node)
-+blist_node_menu_cb(GtkMenuItem *item, Gaim2BlistNode *node)
- {
-- void (*callback)(GaimBlistNode *, gpointer);
-+ void (*callback)(Gaim2BlistNode *, gpointer);
- gpointer data;
-- callback = g_object_get_data(G_OBJECT(item), "gaimcallback");
-- data = g_object_get_data(G_OBJECT(item), "gaimcallbackdata");
-+ callback = g_object_get_data(G_OBJECT(item), "gaim2callback");
-+ data = g_object_get_data(G_OBJECT(item), "gaim2callbackdata");
- if (callback)
- callback(node, data);
- }
-
-
- static void
--append_blist_node_action(GtkWidget *menu, GaimBlistNodeAction *act,
-- GaimBlistNode *node, gboolean *dup_separator)
-+append_blist_node_action(GtkWidget *menu, Gaim2BlistNodeAction *act,
-+ Gaim2BlistNode *node, gboolean *dup_separator)
- {
- if(act == NULL) {
- if(! *dup_separator) {
-- gaim_separator(menu);
-+ gaim2_separator(menu);
- *dup_separator = TRUE;
- }
- } else {
-@@ -935,9 +935,9 @@ append_blist_node_action(GtkWidget *menu
-
- menuitem = gtk_menu_item_new_with_mnemonic(act->label);
- if (act->callback != NULL) {
-- g_object_set_data(G_OBJECT(menuitem), "gaimcallback",
-+ g_object_set_data(G_OBJECT(menuitem), "gaim2callback",
- act->callback);
-- g_object_set_data(G_OBJECT(menuitem), "gaimcallbackdata",
-+ g_object_set_data(G_OBJECT(menuitem), "gaim2callbackdata",
- act->data);
- g_signal_connect(G_OBJECT(menuitem), "activate",
- G_CALLBACK(blist_node_menu_cb), node);
-@@ -956,7 +956,7 @@ append_blist_node_action(GtkWidget *menu
- gtk_menu_item_set_submenu(GTK_MENU_ITEM(menuitem), submenu);
-
- for (l = act->children; l; l = l->next) {
-- GaimBlistNodeAction *act = (GaimBlistNodeAction *) l->data;
-+ Gaim2BlistNodeAction *act = (Gaim2BlistNodeAction *) l->data;
-
- append_blist_node_action(submenu, act, node, dup_separator);
- }
-@@ -969,18 +969,18 @@ append_blist_node_action(GtkWidget *menu
-
-
- void
--gaim_gtk_append_blist_node_proto_menu(GtkWidget *menu, GaimConnection *gc,
-- GaimBlistNode *node)
-+gaim2_gtk_append_blist_node_proto_menu(GtkWidget *menu, Gaim2Connection *gc,
-+ Gaim2BlistNode *node)
- {
- GList *l, *ll;
- gboolean dup_separator = FALSE;
-- GaimPluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-+ Gaim2PluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
- if(!prpl_info || !prpl_info->blist_node_menu)
- return;
-
- for(l = ll = prpl_info->blist_node_menu(node); l; l = l->next) {
-- GaimBlistNodeAction *act = (GaimBlistNodeAction *) l->data;
-+ Gaim2BlistNodeAction *act = (Gaim2BlistNodeAction *) l->data;
- append_blist_node_action(menu, act, node, &dup_separator);
- }
- g_list_free(ll);
-@@ -988,13 +988,13 @@ gaim_gtk_append_blist_node_proto_menu(Gt
-
-
- void
--gaim_gtk_append_blist_node_extended_menu (GtkWidget *menu, GaimBlistNode *node)
-+gaim2_gtk_append_blist_node_extended_menu (GtkWidget *menu, Gaim2BlistNode *node)
- {
- GList *l, *ll;
- gboolean dup_separator = FALSE;
-
-- for(l = ll = gaim_blist_node_get_extended_menu(node); l; l = l->next) {
-- GaimBlistNodeAction *act = (GaimBlistNodeAction *) l->data;
-+ for(l = ll = gaim2_blist_node_get_extended_menu(node); l; l = l->next) {
-+ Gaim2BlistNodeAction *act = (Gaim2BlistNodeAction *) l->data;
- append_blist_node_action(menu, act, node, &dup_separator);
- }
- g_list_free(ll);
-@@ -1002,9 +1002,9 @@ gaim_gtk_append_blist_node_extended_menu
-
-
- void
--gaim_gtk_blist_make_buddy_menu(GtkWidget *menu, GaimBuddy *buddy, gboolean sub) {
-- GaimPluginProtocolInfo *prpl_info;
-- GaimContact *contact;
-+gaim2_gtk_blist_make_buddy_menu(GtkWidget *menu, Gaim2Buddy *buddy, gboolean sub) {
-+ Gaim2PluginProtocolInfo *prpl_info;
-+ Gaim2Contact *contact;
- gboolean contact_expanded = FALSE;
-
- g_return_if_fail(menu);
-@@ -1012,22 +1012,22 @@ gaim_gtk_blist_make_buddy_menu(GtkWidget
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(buddy->account->gc->prpl);
-
-- contact = gaim_buddy_get_contact(buddy);
-+ contact = gaim2_buddy_get_contact(buddy);
- if (contact) {
-- contact_expanded = ((struct _gaim_gtk_blist_node *)(((GaimBlistNode*)contact)->ui_data))->contact_expanded;
-+ contact_expanded = ((struct _gaim2_gtk_blist_node *)(((Gaim2BlistNode*)contact)->ui_data))->contact_expanded;
- }
-
- if (prpl_info && prpl_info->get_info) {
-- gaim_new_item_from_stock(menu, _("Get _Info"), GAIM_STOCK_INFO,
-+ gaim2_new_item_from_stock(menu, _("Get _Info"), GAIM_STOCK_INFO,
- G_CALLBACK(gtk_blist_menu_info_cb), buddy, 0, 0, NULL);
- }
-- gaim_new_item_from_stock(menu, _("I_M"), GAIM_STOCK_IM,
-+ gaim2_new_item_from_stock(menu, _("I_M"), GAIM_STOCK_IM,
- G_CALLBACK(gtk_blist_menu_im_cb), buddy, 0, 0, NULL);
- if (prpl_info && prpl_info->send_file) {
- if (!prpl_info->can_receive_file ||
- prpl_info->can_receive_file(buddy->account->gc, buddy->name))
- {
-- gaim_new_item_from_stock(menu, _("_Send File"),
-+ gaim2_new_item_from_stock(menu, _("_Send File"),
- GAIM_STOCK_FILE_TRANSFER,
- G_CALLBACK(gtk_blist_menu_send_file_cb),
- buddy, 0, 0, NULL);
-@@ -1035,51 +1035,51 @@ gaim_gtk_blist_make_buddy_menu(GtkWidget
- }
-
- if (prpl_info && prpl_info->media_prpl_ops && prpl_info->media_prpl_ops->call) {
-- gaim_new_item_from_stock(menu, _("Start _Voice Chat"),
-+ gaim2_new_item_from_stock(menu, _("Start _Voice Chat"),
- GAIM_STOCK_VOICE_CHAT,
- G_CALLBACK(gtk_blist_menu_voice_chat_cb),
- buddy, 0, 0, NULL);
- }
-
-- gaim_new_item_from_stock(menu, _("Add Buddy _Pounce"), GAIM_STOCK_POUNCE,
-+ gaim2_new_item_from_stock(menu, _("Add Buddy _Pounce"), GAIM_STOCK_POUNCE,
- G_CALLBACK(gtk_blist_menu_bp_cb), buddy, 0, 0, NULL);
-
-- if(((GaimBlistNode*)buddy)->parent->child->next && !sub && !contact_expanded) {
-- gaim_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
-+ if(((Gaim2BlistNode*)buddy)->parent->child->next && !sub && !contact_expanded) {
-+ gaim2_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
- G_CALLBACK(gtk_blist_menu_showlog_cb),
- contact, 0, 0, NULL);
- } else if (!sub) {
-- gaim_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
-+ gaim2_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
- G_CALLBACK(gtk_blist_menu_showlog_cb), buddy, 0, 0, NULL);
- }
-
-- gaim_gtk_append_blist_node_proto_menu(menu, buddy->account->gc,
-- (GaimBlistNode *)buddy);
-- gaim_gtk_append_blist_node_extended_menu(menu, (GaimBlistNode *)buddy);
-+ gaim2_gtk_append_blist_node_proto_menu(menu, buddy->account->gc,
-+ (Gaim2BlistNode *)buddy);
-+ gaim2_gtk_append_blist_node_extended_menu(menu, (Gaim2BlistNode *)buddy);
-
-- if (((GaimBlistNode*)buddy)->parent->child->next && !sub && !contact_expanded) {
-- gaim_separator(menu);
-+ if (((Gaim2BlistNode*)buddy)->parent->child->next && !sub && !contact_expanded) {
-+ gaim2_separator(menu);
-
-- gaim_new_item_from_stock(menu, _("Alias..."), GAIM_STOCK_ALIAS,
-+ gaim2_new_item_from_stock(menu, _("Alias..."), GAIM_STOCK_ALIAS,
- G_CALLBACK(gtk_blist_menu_alias_cb),
- contact, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("Remove"), GTK_STOCK_REMOVE,
-- G_CALLBACK(gaim_gtk_blist_remove_cb),
-+ gaim2_new_item_from_stock(menu, _("Remove"), GTK_STOCK_REMOVE,
-+ G_CALLBACK(gaim2_gtk_blist_remove_cb),
- contact, 0, 0, NULL);
- } else if (!sub || contact_expanded) {
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
-- gaim_new_item_from_stock(menu, _("_Alias..."), GAIM_STOCK_ALIAS,
-+ gaim2_new_item_from_stock(menu, _("_Alias..."), GAIM_STOCK_ALIAS,
- G_CALLBACK(gtk_blist_menu_alias_cb), buddy, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("_Remove"), GTK_STOCK_REMOVE,
-- G_CALLBACK(gaim_gtk_blist_remove_cb), buddy,
-+ gaim2_new_item_from_stock(menu, _("_Remove"), GTK_STOCK_REMOVE,
-+ G_CALLBACK(gaim2_gtk_blist_remove_cb), buddy,
- 0, 0, NULL);
- }
- }
-
- static gboolean
- gtk_blist_key_press_cb(GtkWidget *tv, GdkEventKey *event, gpointer data) {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
- GtkTreeIter iter;
- GtkTreeSelection *sel;
-@@ -1095,12 +1095,12 @@ gtk_blist_key_press_cb(GtkWidget *tv, Gd
-
- if(event->state & GDK_CONTROL_MASK &&
- (event->keyval == 'o' || event->keyval == 'O')) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- buddy = gaim_contact_get_priority_buddy((GaimContact*)node);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
- } else if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- buddy = (GaimBuddy*)node;
-+ buddy = (Gaim2Buddy*)node;
- } else {
- return FALSE;
- }
-@@ -1113,115 +1113,115 @@ gtk_blist_key_press_cb(GtkWidget *tv, Gd
-
-
- static GtkWidget *
--create_group_menu (GaimBlistNode *node, GaimGroup *g)
-+create_group_menu (Gaim2BlistNode *node, Gaim2Group *g)
- {
- GtkWidget *menu;
- GtkWidget *item;
-
- menu = gtk_menu_new();
-- gaim_new_item_from_stock(menu, _("Add a _Buddy"), GTK_STOCK_ADD,
-- G_CALLBACK(gaim_gtk_blist_add_buddy_cb), node, 0, 0, NULL);
-- item = gaim_new_item_from_stock(menu, _("Add a C_hat"), GTK_STOCK_ADD,
-- G_CALLBACK(gaim_gtk_blist_add_chat_cb), node, 0, 0, NULL);
-- gtk_widget_set_sensitive(item, gaim_gtk_blist_joinchat_is_showable());
-- gaim_new_item_from_stock(menu, _("_Delete Group"), GTK_STOCK_REMOVE,
-- G_CALLBACK(gaim_gtk_blist_remove_cb), node, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("_Rename"), NULL,
-+ gaim2_new_item_from_stock(menu, _("Add a _Buddy"), GTK_STOCK_ADD,
-+ G_CALLBACK(gaim2_gtk_blist_add_buddy_cb), node, 0, 0, NULL);
-+ item = gaim2_new_item_from_stock(menu, _("Add a C_hat"), GTK_STOCK_ADD,
-+ G_CALLBACK(gaim2_gtk_blist_add_chat_cb), node, 0, 0, NULL);
-+ gtk_widget_set_sensitive(item, gaim2_gtk_blist_joinchat_is_showable());
-+ gaim2_new_item_from_stock(menu, _("_Delete Group"), GTK_STOCK_REMOVE,
-+ G_CALLBACK(gaim2_gtk_blist_remove_cb), node, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("_Rename"), NULL,
- G_CALLBACK(gtk_blist_menu_alias_cb), node, 0, 0, NULL);
-
-- gaim_gtk_append_blist_node_extended_menu(menu, node);
-+ gaim2_gtk_append_blist_node_extended_menu(menu, node);
-
- return menu;
- }
-
-
- static GtkWidget *
--create_chat_menu(GaimBlistNode *node, GaimChat *c) {
-+create_chat_menu(Gaim2BlistNode *node, Gaim2Chat *c) {
- GtkWidget *menu;
- gboolean autojoin;
-
- menu = gtk_menu_new();
-- autojoin = (gaim_blist_node_get_bool(node, "gtk-autojoin") ||
-- (gaim_blist_node_get_string(node, "gtk-autojoin") != NULL));
-+ autojoin = (gaim2_blist_node_get_bool(node, "gtk-autojoin") ||
-+ (gaim2_blist_node_get_string(node, "gtk-autojoin") != NULL));
-
-- gaim_new_item_from_stock(menu, _("_Join"), GAIM_STOCK_CHAT,
-+ gaim2_new_item_from_stock(menu, _("_Join"), GAIM_STOCK_CHAT,
- G_CALLBACK(gtk_blist_menu_join_cb), node, 0, 0, NULL);
-- gaim_new_check_item(menu, _("Auto-Join"),
-+ gaim2_new_check_item(menu, _("Auto-Join"),
- G_CALLBACK(gtk_blist_menu_autojoin_cb), node, autojoin);
-- gaim_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
-+ gaim2_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
- G_CALLBACK(gtk_blist_menu_showlog_cb), node, 0, 0, NULL);
-
-- gaim_gtk_append_blist_node_proto_menu(menu, c->account->gc, node);
-- gaim_gtk_append_blist_node_extended_menu(menu, node);
-+ gaim2_gtk_append_blist_node_proto_menu(menu, c->account->gc, node);
-+ gaim2_gtk_append_blist_node_extended_menu(menu, node);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
-- gaim_new_item_from_stock(menu, _("_Alias..."), GAIM_STOCK_ALIAS,
-+ gaim2_new_item_from_stock(menu, _("_Alias..."), GAIM_STOCK_ALIAS,
- G_CALLBACK(gtk_blist_menu_alias_cb), node, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("_Remove"), GTK_STOCK_REMOVE,
-- G_CALLBACK(gaim_gtk_blist_remove_cb), node, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("_Remove"), GTK_STOCK_REMOVE,
-+ G_CALLBACK(gaim2_gtk_blist_remove_cb), node, 0, 0, NULL);
-
- return menu;
- }
-
- static GtkWidget *
--create_contact_menu (GaimBlistNode *node)
-+create_contact_menu (Gaim2BlistNode *node)
- {
- GtkWidget *menu;
-
- menu = gtk_menu_new();
-
-- gaim_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
-+ gaim2_new_item_from_stock(menu, _("View _Log"), GAIM_STOCK_LOG,
- G_CALLBACK(gtk_blist_menu_showlog_cb),
- node, 0, 0, NULL);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
-- gaim_new_item_from_stock(menu, _("_Alias..."), GAIM_STOCK_ALIAS,
-+ gaim2_new_item_from_stock(menu, _("_Alias..."), GAIM_STOCK_ALIAS,
- G_CALLBACK(gtk_blist_menu_alias_cb), node, 0, 0, NULL);
-- gaim_new_item_from_stock(menu, _("_Remove"), GTK_STOCK_REMOVE,
-- G_CALLBACK(gaim_gtk_blist_remove_cb), node, 0, 0, NULL);
-+ gaim2_new_item_from_stock(menu, _("_Remove"), GTK_STOCK_REMOVE,
-+ G_CALLBACK(gaim2_gtk_blist_remove_cb), node, 0, 0, NULL);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
-- gaim_new_item_from_stock(menu, _("_Collapse"), GTK_STOCK_ZOOM_OUT,
-- G_CALLBACK(gaim_gtk_blist_collapse_contact_cb),
-+ gaim2_new_item_from_stock(menu, _("_Collapse"), GTK_STOCK_ZOOM_OUT,
-+ G_CALLBACK(gaim2_gtk_blist_collapse_contact_cb),
- node, 0, 0, NULL);
-
-- gaim_gtk_append_blist_node_extended_menu(menu, node);
-+ gaim2_gtk_append_blist_node_extended_menu(menu, node);
-
- return menu;
- }
-
- static GtkWidget *
--create_buddy_menu(GaimBlistNode *node, GaimBuddy *b) {
-- struct _gaim_gtk_blist_node *gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+create_buddy_menu(Gaim2BlistNode *node, Gaim2Buddy *b) {
-+ struct _gaim2_gtk_blist_node *gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
- GtkWidget *menu;
- GtkWidget *menuitem;
-- gboolean show_offline = gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies");
-+ gboolean show_offline = gaim2_prefs_get_bool("/gaim2/gtk/blist/show_offline_buddies");
-
- menu = gtk_menu_new();
-- gaim_gtk_blist_make_buddy_menu(menu, b, FALSE);
-+ gaim2_gtk_blist_make_buddy_menu(menu, b, FALSE);
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
- if(gtknode->contact_expanded) {
-- gaim_new_item_from_stock(menu, _("_Collapse"),
-+ gaim2_new_item_from_stock(menu, _("_Collapse"),
- GTK_STOCK_ZOOM_OUT,
-- G_CALLBACK(gaim_gtk_blist_collapse_contact_cb),
-+ G_CALLBACK(gaim2_gtk_blist_collapse_contact_cb),
- node, 0, 0, NULL);
- } else {
-- gaim_new_item_from_stock(menu, _("_Expand"),
-+ gaim2_new_item_from_stock(menu, _("_Expand"),
- GTK_STOCK_ZOOM_IN,
-- G_CALLBACK(gaim_gtk_blist_expand_contact_cb), node,
-+ G_CALLBACK(gaim2_gtk_blist_expand_contact_cb), node,
- 0, 0, NULL);
- }
- if(node->child->next) {
-- GaimBlistNode *bnode;
-+ Gaim2BlistNode *bnode;
-
- for(bnode = node->child; bnode; bnode = bnode->next) {
-- GaimBuddy *buddy = (GaimBuddy*)bnode;
-+ Gaim2Buddy *buddy = (Gaim2Buddy*)bnode;
- GdkPixbuf *buf;
- GtkWidget *submenu;
- GtkWidget *image;
-@@ -1234,7 +1234,7 @@ create_buddy_menu(GaimBlistNode *node, G
- continue;
-
- menuitem = gtk_image_menu_item_new_with_label(buddy->name);
-- buf = gaim_gtk_blist_get_status_icon(bnode,
-+ buf = gaim2_gtk_blist_get_status_icon(bnode,
- GAIM_STATUS_ICON_SMALL);
- image = gtk_image_new_from_pixbuf(buf);
- g_object_unref(G_OBJECT(buf));
-@@ -1248,7 +1248,7 @@ create_buddy_menu(GaimBlistNode *node, G
- gtk_menu_item_set_submenu(GTK_MENU_ITEM(menuitem), submenu);
- gtk_widget_show(submenu);
-
-- gaim_gtk_blist_make_buddy_menu(submenu, buddy, TRUE);
-+ gaim2_gtk_blist_make_buddy_menu(submenu, buddy, TRUE);
- }
- }
- }
-@@ -1256,36 +1256,36 @@ create_buddy_menu(GaimBlistNode *node, G
- }
-
- static gboolean
--gaim_gtk_blist_show_context_menu(GaimBlistNode *node,
-+gaim2_gtk_blist_show_context_menu(Gaim2BlistNode *node,
- GtkMenuPositionFunc func,
- GtkWidget *tv,
- guint button,
- guint32 time)
- {
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
- GtkWidget *menu = NULL;
- gboolean handled = FALSE;
-
-- gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
-
- /* Create a menu based on the thing we right-clicked on */
- if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- GaimGroup *g = (GaimGroup *)node;
-+ Gaim2Group *g = (Gaim2Group *)node;
-
- menu = create_group_menu(node, g);
- } else if (GAIM_BLIST_NODE_IS_CHAT(node)) {
-- GaimChat *c = (GaimChat *)node;
-+ Gaim2Chat *c = (Gaim2Chat *)node;
-
- menu = create_chat_menu(node, c);
- } else if ((GAIM_BLIST_NODE_IS_CONTACT(node)) && (gtknode->contact_expanded)) {
- menu = create_contact_menu(node);
- } else if (GAIM_BLIST_NODE_IS_CONTACT(node) || GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
-- b = gaim_contact_get_priority_buddy((GaimContact*)node);
-+ b = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
- else
-- b = (GaimBuddy *)node;
-+ b = (Gaim2Buddy *)node;
-
- menu = create_buddy_menu(node, b);
- }
-@@ -1313,13 +1313,13 @@ gaim_gtk_blist_show_context_menu(GaimBli
- static gboolean gtk_blist_button_press_cb(GtkWidget *tv, GdkEventButton *event, gpointer user_data)
- {
- GtkTreePath *path;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
- GtkTreeIter iter;
- GtkTreeSelection *sel;
-- GaimPlugin *prpl = NULL;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- struct _gaim_gtk_blist_node *gtknode;
-+ Gaim2Plugin *prpl = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ struct _gaim2_gtk_blist_node *gtknode;
- gboolean handled = FALSE;
-
- /* Here we figure out which node was clicked */
-@@ -1329,31 +1329,31 @@ static gboolean gtk_blist_button_press_c
- val.g_type = 0;
- gtk_tree_model_get_value(GTK_TREE_MODEL(gtkblist->treemodel), &iter, NODE_COLUMN, &val);
- node = g_value_get_pointer(&val);
-- gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
-
- /* Right click draws a context menu */
- if ((event->button == 3) && (event->type == GDK_BUTTON_PRESS)) {
-- handled = gaim_gtk_blist_show_context_menu(node, NULL, tv, 3, event->time);
-+ handled = gaim2_gtk_blist_show_context_menu(node, NULL, tv, 3, event->time);
-
- /* CTRL+middle click expands or collapse a contact */
- } else if ((event->button == 2) && (event->type == GDK_BUTTON_PRESS) &&
- (event->state & GDK_CONTROL_MASK) && (GAIM_BLIST_NODE_IS_CONTACT(node))) {
- if (gtknode->contact_expanded)
-- gaim_gtk_blist_collapse_contact_cb(NULL, node);
-+ gaim2_gtk_blist_collapse_contact_cb(NULL, node);
- else
-- gaim_gtk_blist_expand_contact_cb(NULL, node);
-+ gaim2_gtk_blist_expand_contact_cb(NULL, node);
- handled = TRUE;
-
- /* Double middle click gets info */
- } else if ((event->button == 2) && (event->type == GDK_2BUTTON_PRESS) &&
- ((GAIM_BLIST_NODE_IS_CONTACT(node)) || (GAIM_BLIST_NODE_IS_BUDDY(node)))) {
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- if(GAIM_BLIST_NODE_IS_CONTACT(node))
-- b = gaim_contact_get_priority_buddy((GaimContact*)node);
-+ b = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
- else
-- b = (GaimBuddy *)node;
-+ b = (Gaim2Buddy *)node;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(b->account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(b->account));
- if (prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-
-@@ -1384,9 +1384,9 @@ static gboolean gtk_blist_button_press_c
- }
-
- static gboolean
--gaim_gtk_blist_popup_menu_cb(GtkWidget *tv, void *user_data)
-+gaim2_gtk_blist_popup_menu_cb(GtkWidget *tv, void *user_data)
- {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
- GtkTreeIter iter;
- GtkTreeSelection *sel;
-@@ -1402,12 +1402,12 @@ gaim_gtk_blist_popup_menu_cb(GtkWidget *
- node = g_value_get_pointer(&val);
-
- /* Shift+F10 draws a context menu */
-- handled = gaim_gtk_blist_show_context_menu(node, gaim_gtk_treeview_popup_menu_position_func, tv, 0, GDK_CURRENT_TIME);
-+ handled = gaim2_gtk_blist_show_context_menu(node, gaim2_gtk_treeview_popup_menu_position_func, tv, 0, GDK_CURRENT_TIME);
-
- return handled;
- }
-
--static void gaim_gtk_blist_buddy_details_cb(gpointer data, guint action, GtkWidget *item)
-+static void gaim2_gtk_blist_buddy_details_cb(gpointer data, guint action, GtkWidget *item)
- {
- if (gtkblist->window->window)
- {
-@@ -1418,14 +1418,14 @@ static void gaim_gtk_blist_buddy_details
- gdk_cursor_unref(cursor);
- }
-
-- gaim_prefs_set_bool("/gaim/gtk/blist/show_buddy_icons",
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/show_buddy_icons",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(item)));
-
- if (gtkblist->window->window)
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- }
-
--static void gaim_gtk_blist_show_idle_time_cb(gpointer data, guint action, GtkWidget *item)
-+static void gaim2_gtk_blist_show_idle_time_cb(gpointer data, guint action, GtkWidget *item)
- {
- if (gtkblist->window->window)
- {
-@@ -1436,14 +1436,14 @@ static void gaim_gtk_blist_show_idle_tim
- gdk_cursor_unref(cursor);
- }
-
-- gaim_prefs_set_bool("/gaim/gtk/blist/show_idle_time",
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/show_idle_time",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(item)));
-
- if (gtkblist->window->window)
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- }
-
--static void gaim_gtk_blist_show_empty_groups_cb(gpointer data, guint action, GtkWidget *item)
-+static void gaim2_gtk_blist_show_empty_groups_cb(gpointer data, guint action, GtkWidget *item)
- {
- if (gtkblist->window->window)
- {
-@@ -1454,14 +1454,14 @@ static void gaim_gtk_blist_show_empty_gr
- gdk_cursor_unref(cursor);
- }
-
-- gaim_prefs_set_bool("/gaim/gtk/blist/show_empty_groups",
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/show_empty_groups",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(item)));
-
- if (gtkblist->window->window)
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- }
-
--static void gaim_gtk_blist_edit_mode_cb(gpointer callback_data, guint callback_action,
-+static void gaim2_gtk_blist_edit_mode_cb(gpointer callback_data, guint callback_action,
- GtkWidget *checkitem)
- {
- if (gtkblist->window->window)
-@@ -1473,25 +1473,25 @@ static void gaim_gtk_blist_edit_mode_cb(
- gdk_cursor_unref(cursor);
- }
-
-- gaim_prefs_set_bool("/gaim/gtk/blist/show_offline_buddies",
-+ gaim2_prefs_set_bool("/gaim2/gtk/blist/show_offline_buddies",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(checkitem)));
-
- if (gtkblist->window->window)
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- }
-
--static void gaim_gtk_blist_mute_sounds_cb(gpointer data, guint action, GtkWidget *item)
-+static void gaim2_gtk_blist_mute_sounds_cb(gpointer data, guint action, GtkWidget *item)
- {
-- gaim_prefs_set_bool("/gaim/gtk/sound/mute", GTK_CHECK_MENU_ITEM(item)->active);
-+ gaim2_prefs_set_bool("/gaim2/gtk/sound/mute", GTK_CHECK_MENU_ITEM(item)->active);
- }
-
--static void gaim_gtk_blist_mute_pref_cb(const char *name, GaimPrefType type, gpointer value, gpointer data)
-+static void gaim2_gtk_blist_mute_pref_cb(const char *name, Gaim2PrefType type, gpointer value, gpointer data)
- {
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_item_factory_get_item(gtkblist->ift,
- N_("/Tools/Mute Sounds"))), (gboolean)GPOINTER_TO_INT(value));
- }
-
--static void gaim_gtk_blist_sound_method_pref_cb(const char *name, GaimPrefType type, gpointer value, gpointer data)
-+static void gaim2_gtk_blist_sound_method_pref_cb(const char *name, Gaim2PrefType type, gpointer value, gpointer data)
- {
- gboolean sensitive = TRUE;
-
-@@ -1502,22 +1502,22 @@ static void gaim_gtk_blist_sound_method_
- }
-
- static void
--add_buddies_from_vcard(const char *prpl_id, GaimGroup *group, GList *list,
-+add_buddies_from_vcard(const char *prpl_id, Gaim2Group *group, GList *list,
- const char *alias)
- {
- GList *l;
-- GaimAccount *account = NULL;
-- GaimConnection *gc;
-+ Gaim2Account *account = NULL;
-+ Gaim2Connection *gc;
-
- if (list == NULL)
- return;
-
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- {
-- gc = (GaimConnection *)l->data;
-- account = gaim_connection_get_account(gc);
-+ gc = (Gaim2Connection *)l->data;
-+ account = gaim2_connection_get_account(gc);
-
-- if (!strcmp(gaim_account_get_protocol_id(account), prpl_id))
-+ if (!strcmp(gaim2_account_get_protocol_id(account), prpl_id))
- break;
-
- account = NULL;
-@@ -1527,7 +1527,7 @@ add_buddies_from_vcard(const char *prpl_
- {
- for (l = list; l != NULL; l = l->next)
- {
-- gaim_blist_request_add_buddy(account, l->data,
-+ gaim2_blist_request_add_buddy(account, l->data,
- (group ? group->name : NULL),
- alias);
- }
-@@ -1538,7 +1538,7 @@ add_buddies_from_vcard(const char *prpl_
- }
-
- static gboolean
--parse_vcard(const char *vcard, GaimGroup *group)
-+parse_vcard(const char *vcard, Gaim2Group *group)
- {
- char *temp_vcard;
- char *s, *c;
-@@ -1634,10 +1634,10 @@ parse_vcard(const char *vcard, GaimGroup
- }
-
- #ifdef _WIN32
--static void gaim_gtk_blist_drag_begin(GtkWidget *widget,
-+static void gaim2_gtk_blist_drag_begin(GtkWidget *widget,
- GdkDragContext *drag_context, gpointer user_data)
- {
-- gaim_gtk_blist_tooltip_destroy();
-+ gaim2_gtk_blist_tooltip_destroy();
-
-
- /* Unhook the tooltip-timeout since we don't want a tooltip
-@@ -1650,7 +1650,7 @@ static void gaim_gtk_blist_drag_begin(Gt
- }
- #endif
-
--static void gaim_gtk_blist_drag_data_get_cb(GtkWidget *widget,
-+static void gaim2_gtk_blist_drag_data_get_cb(GtkWidget *widget,
- GdkDragContext *dc,
- GtkSelectionData *data,
- guint info,
-@@ -1663,7 +1663,7 @@ static void gaim_gtk_blist_drag_data_get
- GtkTreeRowReference *ref = g_object_get_data(G_OBJECT(dc), "gtk-tree-view-source-row");
- GtkTreePath *sourcerow = gtk_tree_row_reference_get_path(ref);
- GtkTreeIter iter;
-- GaimBlistNode *node = NULL;
-+ Gaim2BlistNode *node = NULL;
- GValue val;
- if(!sourcerow)
- return;
-@@ -1684,9 +1684,9 @@ static void gaim_gtk_blist_drag_data_get
- GtkTreeRowReference *ref;
- GtkTreePath *sourcerow;
- GtkTreeIter iter;
-- GaimBlistNode *node = NULL;
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2BlistNode *node = NULL;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- GValue val;
- GString *str;
- const char *protocol;
-@@ -1708,7 +1708,7 @@ static void gaim_gtk_blist_drag_data_get
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
- {
-- buddy = gaim_contact_get_priority_buddy((GaimContact *)node);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact *)node);
- }
- else if (!GAIM_BLIST_NODE_IS_BUDDY(node))
- {
-@@ -1717,10 +1717,10 @@ static void gaim_gtk_blist_drag_data_get
- }
- else
- {
-- buddy = (GaimBuddy *)node;
-+ buddy = (Gaim2Buddy *)node;
- }
-
-- gc = gaim_account_get_connection(buddy->account);
-+ gc = gaim2_account_get_connection(buddy->account);
-
- if (gc == NULL)
- {
-@@ -1763,20 +1763,20 @@ static void gaim_gtk_blist_drag_data_get
- }
- }
-
--static void gaim_gtk_blist_drag_data_rcv_cb(GtkWidget *widget, GdkDragContext *dc, guint x, guint y,
-+static void gaim2_gtk_blist_drag_data_rcv_cb(GtkWidget *widget, GdkDragContext *dc, guint x, guint y,
- GtkSelectionData *sd, guint info, guint t)
- {
- if (sd->target == gdk_atom_intern("GAIM_BLIST_NODE", FALSE) && sd->data) {
-- GaimBlistNode *n = NULL;
-+ Gaim2BlistNode *n = NULL;
- GtkTreePath *path = NULL;
- GtkTreeViewDropPosition position;
- memcpy(&n, sd->data, sizeof(n));
- if(gtk_tree_view_get_dest_row_at_pos(GTK_TREE_VIEW(widget), x, y, &path, &position)) {
- /* if we're here, I think it means the drop is ok */
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(gtkblist->treemodel),
- &iter, path);
-@@ -1787,91 +1787,91 @@ static void gaim_gtk_blist_drag_data_rcv
- gtknode = node->ui_data;
-
- if (GAIM_BLIST_NODE_IS_CONTACT(n)) {
-- GaimContact *c = (GaimContact*)n;
-+ Gaim2Contact *c = (Gaim2Contact*)n;
- if (GAIM_BLIST_NODE_IS_CONTACT(node) && gtknode->contact_expanded) {
-- gaim_blist_merge_contact(c, node);
-+ gaim2_blist_merge_contact(c, node);
- } else if (GAIM_BLIST_NODE_IS_CONTACT(node) ||
- GAIM_BLIST_NODE_IS_CHAT(node)) {
- switch(position) {
- case GTK_TREE_VIEW_DROP_AFTER:
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
-- gaim_blist_add_contact(c, (GaimGroup*)node->parent,
-+ gaim2_blist_add_contact(c, (Gaim2Group*)node->parent,
- node);
- break;
- case GTK_TREE_VIEW_DROP_BEFORE:
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
-- gaim_blist_add_contact(c, (GaimGroup*)node->parent,
-+ gaim2_blist_add_contact(c, (Gaim2Group*)node->parent,
- node->prev);
- break;
- }
- } else if(GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_blist_add_contact(c, (GaimGroup*)node, NULL);
-+ gaim2_blist_add_contact(c, (Gaim2Group*)node, NULL);
- } else if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- gaim_blist_merge_contact(c, node);
-+ gaim2_blist_merge_contact(c, node);
- }
- } else if (GAIM_BLIST_NODE_IS_BUDDY(n)) {
-- GaimBuddy *b = (GaimBuddy*)n;
-+ Gaim2Buddy *b = (Gaim2Buddy*)n;
- if (GAIM_BLIST_NODE_IS_BUDDY(node)) {
- switch(position) {
- case GTK_TREE_VIEW_DROP_AFTER:
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
-- gaim_blist_add_buddy(b, (GaimContact*)node->parent,
-- (GaimGroup*)node->parent->parent, node);
-+ gaim2_blist_add_buddy(b, (Gaim2Contact*)node->parent,
-+ (Gaim2Group*)node->parent->parent, node);
- break;
- case GTK_TREE_VIEW_DROP_BEFORE:
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
-- gaim_blist_add_buddy(b, (GaimContact*)node->parent,
-- (GaimGroup*)node->parent->parent,
-+ gaim2_blist_add_buddy(b, (Gaim2Contact*)node->parent,
-+ (Gaim2Group*)node->parent->parent,
- node->prev);
- break;
- }
- } else if(GAIM_BLIST_NODE_IS_CHAT(node)) {
-- gaim_blist_add_buddy(b, NULL, (GaimGroup*)node->parent,
-+ gaim2_blist_add_buddy(b, NULL, (Gaim2Group*)node->parent,
- NULL);
- } else if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_blist_add_buddy(b, NULL, (GaimGroup*)node, NULL);
-+ gaim2_blist_add_buddy(b, NULL, (Gaim2Group*)node, NULL);
- } else if (GAIM_BLIST_NODE_IS_CONTACT(node)) {
- if(gtknode->contact_expanded) {
- switch(position) {
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
- case GTK_TREE_VIEW_DROP_AFTER:
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
-- gaim_blist_add_buddy(b, (GaimContact*)node,
-- (GaimGroup*)node->parent, NULL);
-+ gaim2_blist_add_buddy(b, (Gaim2Contact*)node,
-+ (Gaim2Group*)node->parent, NULL);
- break;
- case GTK_TREE_VIEW_DROP_BEFORE:
-- gaim_blist_add_buddy(b, NULL,
-- (GaimGroup*)node->parent, node->prev);
-+ gaim2_blist_add_buddy(b, NULL,
-+ (Gaim2Group*)node->parent, node->prev);
- break;
- }
- } else {
- switch(position) {
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
- case GTK_TREE_VIEW_DROP_AFTER:
-- gaim_blist_add_buddy(b, NULL,
-- (GaimGroup*)node->parent, NULL);
-+ gaim2_blist_add_buddy(b, NULL,
-+ (Gaim2Group*)node->parent, NULL);
- break;
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
- case GTK_TREE_VIEW_DROP_BEFORE:
-- gaim_blist_add_buddy(b, NULL,
-- (GaimGroup*)node->parent, node->prev);
-+ gaim2_blist_add_buddy(b, NULL,
-+ (Gaim2Group*)node->parent, node->prev);
- break;
- }
- }
- }
- } else if (GAIM_BLIST_NODE_IS_CHAT(n)) {
-- GaimChat *chat = (GaimChat *)n;
-+ Gaim2Chat *chat = (Gaim2Chat *)n;
- if (GAIM_BLIST_NODE_IS_BUDDY(node)) {
- switch(position) {
- case GTK_TREE_VIEW_DROP_AFTER:
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
-- gaim_blist_add_chat(chat,
-- (GaimGroup*)node->parent->parent, node);
-+ gaim2_blist_add_chat(chat,
-+ (Gaim2Group*)node->parent->parent, node);
- break;
- case GTK_TREE_VIEW_DROP_BEFORE:
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
-- gaim_blist_add_chat(chat,
-- (GaimGroup*)node->parent->parent,
-+ gaim2_blist_add_chat(chat,
-+ (Gaim2Group*)node->parent->parent,
- node->prev);
- break;
- }
-@@ -1880,34 +1880,34 @@ static void gaim_gtk_blist_drag_data_rcv
- switch(position) {
- case GTK_TREE_VIEW_DROP_AFTER:
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
-- gaim_blist_add_chat(chat, (GaimGroup*)node->parent, node);
-+ gaim2_blist_add_chat(chat, (Gaim2Group*)node->parent, node);
- break;
- case GTK_TREE_VIEW_DROP_BEFORE:
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
-- gaim_blist_add_chat(chat, (GaimGroup*)node->parent, node->prev);
-+ gaim2_blist_add_chat(chat, (Gaim2Group*)node->parent, node->prev);
- break;
- }
- } else if (GAIM_BLIST_NODE_IS_GROUP(node)) {
-- gaim_blist_add_chat(chat, (GaimGroup*)node, NULL);
-+ gaim2_blist_add_chat(chat, (Gaim2Group*)node, NULL);
- }
- } else if (GAIM_BLIST_NODE_IS_GROUP(n)) {
-- GaimGroup *g = (GaimGroup*)n;
-+ Gaim2Group *g = (Gaim2Group*)n;
- if (GAIM_BLIST_NODE_IS_GROUP(node)) {
- switch (position) {
- case GTK_TREE_VIEW_DROP_INTO_OR_AFTER:
- case GTK_TREE_VIEW_DROP_AFTER:
-- gaim_blist_add_group(g, node);
-+ gaim2_blist_add_group(g, node);
- break;
- case GTK_TREE_VIEW_DROP_INTO_OR_BEFORE:
- case GTK_TREE_VIEW_DROP_BEFORE:
-- gaim_blist_add_group(g, node->prev);
-+ gaim2_blist_add_group(g, node->prev);
- break;
- }
- } else if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- gaim_blist_add_group(g, node->parent->parent);
-+ gaim2_blist_add_group(g, node->parent->parent);
- } else if(GAIM_BLIST_NODE_IS_CONTACT(node) ||
- GAIM_BLIST_NODE_IS_CHAT(node)) {
-- gaim_blist_add_group(g, node->parent);
-+ gaim2_blist_add_group(g, node->parent);
- }
- }
-
-@@ -1918,10 +1918,10 @@ static void gaim_gtk_blist_drag_data_rcv
- else if (sd->target == gdk_atom_intern("application/x-im-contact",
- FALSE) && sd->data)
- {
-- GaimGroup *group = NULL;
-+ Gaim2Group *group = NULL;
- GtkTreePath *path = NULL;
- GtkTreeViewDropPosition position;
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *protocol = NULL;
- char *username = NULL;
- char *alias = NULL;
-@@ -1930,7 +1930,7 @@ static void gaim_gtk_blist_drag_data_rcv
- x, y, &path, &position))
- {
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(gtkblist->treemodel),
-@@ -1942,31 +1942,31 @@ static void gaim_gtk_blist_drag_data_rcv
-
- if (GAIM_BLIST_NODE_IS_BUDDY(node))
- {
-- group = (GaimGroup *)node->parent->parent;
-+ group = (Gaim2Group *)node->parent->parent;
- }
- else if (GAIM_BLIST_NODE_IS_CHAT(node) ||
- GAIM_BLIST_NODE_IS_CONTACT(node))
- {
-- group = (GaimGroup *)node->parent;
-+ group = (Gaim2Group *)node->parent;
- }
- else if (GAIM_BLIST_NODE_IS_GROUP(node))
- {
-- group = (GaimGroup *)node;
-+ group = (Gaim2Group *)node;
- }
- }
-
-- if (gaim_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
-+ if (gaim2_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
- &protocol, &username, &alias))
- {
- if (account == NULL)
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("You are not currently signed on with an account that "
- "can add that buddy."), NULL);
- }
- else
- {
-- gaim_blist_request_add_buddy(account, username,
-+ gaim2_blist_request_add_buddy(account, username,
- (group ? group->name : NULL),
- alias);
- }
-@@ -1984,7 +1984,7 @@ static void gaim_gtk_blist_drag_data_rcv
- else if (sd->target == gdk_atom_intern("text/x-vcard", FALSE) && sd->data)
- {
- gboolean result;
-- GaimGroup *group = NULL;
-+ Gaim2Group *group = NULL;
- GtkTreePath *path = NULL;
- GtkTreeViewDropPosition position;
-
-@@ -1992,7 +1992,7 @@ static void gaim_gtk_blist_drag_data_rcv
- x, y, &path, &position))
- {
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(gtkblist->treemodel),
-@@ -2004,16 +2004,16 @@ static void gaim_gtk_blist_drag_data_rcv
-
- if (GAIM_BLIST_NODE_IS_BUDDY(node))
- {
-- group = (GaimGroup *)node->parent->parent;
-+ group = (Gaim2Group *)node->parent->parent;
- }
- else if (GAIM_BLIST_NODE_IS_CHAT(node) ||
- GAIM_BLIST_NODE_IS_CONTACT(node))
- {
-- group = (GaimGroup *)node->parent;
-+ group = (Gaim2Group *)node->parent;
- }
- else if (GAIM_BLIST_NODE_IS_GROUP(node))
- {
-- group = (GaimGroup *)node;
-+ group = (Gaim2Group *)node;
- }
- }
-
-@@ -2028,7 +2028,7 @@ static void gaim_gtk_blist_drag_data_rcv
- x, y, &path, &position))
- {
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(gtkblist->treemodel),
-@@ -2039,8 +2039,8 @@ static void gaim_gtk_blist_drag_data_rcv
- node = g_value_get_pointer(&val);
-
- if (GAIM_BLIST_NODE_IS_BUDDY(node) || GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- GaimBuddy *b = GAIM_BLIST_NODE_IS_BUDDY(node) ? (GaimBuddy*)node : gaim_contact_get_priority_buddy((GaimContact*)node);
-- gaim_dnd_file_manage(sd, b->account, b->name);
-+ Gaim2Buddy *b = GAIM_BLIST_NODE_IS_BUDDY(node) ? (Gaim2Buddy*)node : gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
-+ gaim2_dnd_file_manage(sd, b->account, b->name);
- gtk_drag_finish(dc, TRUE, (dc->action == GDK_ACTION_MOVE), t);
- } else {
- gtk_drag_finish(dc, FALSE, FALSE, t);
-@@ -2049,35 +2049,35 @@ static void gaim_gtk_blist_drag_data_rcv
- }
- }
-
--static GdkPixbuf *gaim_gtk_blist_get_buddy_icon(GaimBlistNode *node,
-+static GdkPixbuf *gaim2_gtk_blist_get_buddy_icon(Gaim2BlistNode *node,
- gboolean scaled, gboolean greyed)
- {
- GdkPixbuf *buf, *ret = NULL;
- GdkPixbufLoader *loader;
-- GaimBuddyIcon *icon;
-+ Gaim2BuddyIcon *icon;
- const guchar *data;
- gsize len;
-- GaimBuddy *buddy = (GaimBuddy *)node;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)node;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- buddy = gaim_contact_get_priority_buddy((GaimContact*)node);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
- } else if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- buddy = (GaimBuddy*)node;
-+ buddy = (Gaim2Buddy*)node;
- } else {
- return NULL;
- }
-
- #if 0
-- if (!gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons"))
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons"))
- return NULL;
- #endif
-
-- if (!(icon = gaim_buddy_get_icon(buddy)))
-- if (!(icon = gaim_buddy_icons_find(buddy->account, buddy->name))) /* Not sure I like this...*/
-+ if (!(icon = gaim2_buddy_get_icon(buddy)))
-+ if (!(icon = gaim2_buddy_icons_find(buddy->account, buddy->name))) /* Not sure I like this...*/
- return NULL;
-
- loader = gdk_pixbuf_loader_new();
-- data = gaim_buddy_icon_get_data(icon, &len);
-+ data = gaim2_buddy_icon_get_data(icon, &len);
- gdk_pixbuf_loader_write(loader, data, len, NULL);
- gdk_pixbuf_loader_close(loader, NULL);
- buf = gdk_pixbuf_loader_get_pixbuf(loader);
-@@ -2086,8 +2086,8 @@ static GdkPixbuf *gaim_gtk_blist_get_bud
- g_object_unref(G_OBJECT(loader));
-
- if (buf) {
-- GaimAccount *account = gaim_buddy_get_account(buddy);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Account *account = gaim2_buddy_get_account(buddy);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- int orig_width, orig_height;
- int scale_width, scale_height;
-
-@@ -2095,20 +2095,20 @@ static GdkPixbuf *gaim_gtk_blist_get_bud
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(account->gc->prpl);
-
- if (greyed) {
-- GaimPresence *presence = gaim_buddy_get_presence(buddy);
-+ Gaim2Presence *presence = gaim2_buddy_get_presence(buddy);
- if (!GAIM_BUDDY_IS_ONLINE(buddy))
- gdk_pixbuf_saturate_and_pixelate(buf, buf, 0.0, FALSE);
-- if (gaim_presence_is_idle(presence))
-+ if (gaim2_presence_is_idle(presence))
- gdk_pixbuf_saturate_and_pixelate(buf, buf, 0.25, FALSE);
- }
-
-- /* i'd use the gaim_gtk_buddy_icon_get_scale_size() thing,
-+ /* i'd use the gaim2_gtk_buddy_icon_get_scale_size() thing,
- * but it won't tell me the original size, which I need for scaling
- * purposes */
- scale_width = orig_width = gdk_pixbuf_get_width(buf);
- scale_height = orig_height = gdk_pixbuf_get_height(buf);
-
-- gaim_buddy_icon_get_scale_size(prpl_info ? &prpl_info->icon_spec : NULL, &scale_width, &scale_height);
-+ gaim2_buddy_icon_get_scale_size(prpl_info ? &prpl_info->icon_spec : NULL, &scale_width, &scale_height);
-
- if (scaled) {
- if(scale_height > scale_width) {
-@@ -2140,14 +2140,14 @@ struct tooltip_data {
- int height;
- };
-
--static struct tooltip_data * create_tip_for_node(GaimBlistNode *node, gboolean full)
-+static struct tooltip_data * create_tip_for_node(Gaim2BlistNode *node, gboolean full)
- {
- char *tooltip_text = NULL;
- struct tooltip_data *td = g_new0(struct tooltip_data, 1);
-
-- td->status_icon = gaim_gtk_blist_get_status_icon(node, GAIM_STATUS_ICON_LARGE);
-- td->avatar = gaim_gtk_blist_get_buddy_icon(node, FALSE, FALSE);
-- tooltip_text = gaim_get_tooltip_text(node, full);
-+ td->status_icon = gaim2_gtk_blist_get_status_icon(node, GAIM_STATUS_ICON_LARGE);
-+ td->avatar = gaim2_gtk_blist_get_buddy_icon(node, FALSE, FALSE);
-+ tooltip_text = gaim2_get_tooltip_text(node, full);
- td->layout = gtk_widget_create_pango_layout(gtkblist->tipwindow, NULL);
- pango_layout_set_markup(td->layout, tooltip_text, strlen(tooltip_text));
- pango_layout_set_wrap(td->layout, PANGO_WRAP_WORD);
-@@ -2167,7 +2167,7 @@ static struct tooltip_data * create_tip_
- return td;
- }
-
--static void gaim_gtk_blist_paint_tip(GtkWidget *widget, GdkEventExpose *event, GaimBlistNode *node)
-+static void gaim2_gtk_blist_paint_tip(GtkWidget *widget, GdkEventExpose *event, Gaim2BlistNode *node)
- {
- GtkStyle *style;
- int current_height, max_width;
-@@ -2218,7 +2218,7 @@ static void gaim_gtk_blist_paint_tip(Gtk
- }
- }
-
--static void gaim_gtk_blist_tooltip_destroy()
-+static void gaim2_gtk_blist_tooltip_destroy()
- {
- while(gtkblist->tooltipdata) {
- struct tooltip_data *td = gtkblist->tooltipdata->data;
-@@ -2239,13 +2239,13 @@ static void gaim_gtk_blist_tooltip_destr
- gtkblist->tipwindow = NULL;
- }
-
--static gboolean gaim_gtk_blist_expand_timeout(GtkWidget *tv)
-+static gboolean gaim2_gtk_blist_expand_timeout(GtkWidget *tv)
- {
- GtkTreePath *path;
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
-
- if (!gtk_tree_view_get_path_at_pos(GTK_TREE_VIEW(tv), gtkblist->tip_rect.x, gtkblist->tip_rect.y, &path, NULL, NULL, NULL))
- return FALSE;
-@@ -2264,7 +2264,7 @@ static gboolean gaim_gtk_blist_expand_ti
- if (!gtknode->contact_expanded) {
- GtkTreeIter i;
-
-- gaim_gtk_blist_expand_contact_cb(NULL, node);
-+ gaim2_gtk_blist_expand_contact_cb(NULL, node);
-
- gtk_tree_view_get_cell_area(GTK_TREE_VIEW(tv), path, NULL, &gtkblist->contact_rect);
- gdk_drawable_get_size(GDK_DRAWABLE(tv->window), &(gtkblist->contact_rect.width), NULL);
-@@ -2281,27 +2281,27 @@ static gboolean gaim_gtk_blist_expand_ti
- return FALSE;
- }
-
--static gboolean buddy_is_displayable(GaimBuddy *buddy)
-+static gboolean buddy_is_displayable(Gaim2Buddy *buddy)
- {
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
-
- if(!buddy)
- return FALSE;
-
-- gtknode = ((GaimBlistNode*)buddy)->ui_data;
-+ gtknode = ((Gaim2BlistNode*)buddy)->ui_data;
-
-- return (gaim_account_is_connected(buddy->account) &&
-- (gaim_presence_is_online(buddy->presence) ||
-+ return (gaim2_account_is_connected(buddy->account) &&
-+ (gaim2_presence_is_online(buddy->presence) ||
- (gtknode && gtknode->recent_signonoff) ||
-- gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies") ||
-- gaim_blist_node_get_bool((GaimBlistNode*)buddy, "show_offline")));
-+ gaim2_prefs_get_bool("/gaim2/gtk/blist/show_offline_buddies") ||
-+ gaim2_blist_node_get_bool((Gaim2BlistNode*)buddy, "show_offline")));
- }
-
--static gboolean gaim_gtk_blist_tooltip_timeout(GtkWidget *tv)
-+static gboolean gaim2_gtk_blist_tooltip_timeout(GtkWidget *tv)
- {
- GtkTreePath *path;
- GtkTreeIter iter;
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
- GValue val;
- int scr_w, scr_h, w, h, x, y;
- #if GTK_CHECK_VERSION(2,2,0)
-@@ -2309,14 +2309,14 @@ static gboolean gaim_gtk_blist_tooltip_t
- GdkScreen *screen = NULL;
- #endif
- gboolean tooltip_top = FALSE;
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
- GdkRectangle mon_size;
-
- /*
- * Attempt to free the previous tooltip. I have a feeling
- * this is never needed... but just in case.
- */
-- gaim_gtk_blist_tooltip_destroy();
-+ gaim2_gtk_blist_tooltip_destroy();
-
- if (!gtk_tree_view_get_path_at_pos(GTK_TREE_VIEW(tv), gtkblist->tip_rect.x, gtkblist->tip_rect.y, &path, NULL, NULL, NULL))
- return FALSE;
-@@ -2335,14 +2335,14 @@ static gboolean gaim_gtk_blist_tooltip_t
- w = td->width;
- h = td->height + 8;
- } else if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- GaimBlistNode *child;
-- GaimBuddy *b = gaim_contact_get_priority_buddy((GaimContact *)node);
-+ Gaim2BlistNode *child;
-+ Gaim2Buddy *b = gaim2_contact_get_priority_buddy((Gaim2Contact *)node);
- w = h = 0;
- for(child = node->child; child; child = child->next)
- {
-- if(GAIM_BLIST_NODE_IS_BUDDY(child) && buddy_is_displayable((GaimBuddy*)child)) {
-- struct tooltip_data *td = create_tip_for_node(child, (b == (GaimBuddy*)child));
-- if (b == (GaimBuddy *)child) {
-+ if(GAIM_BLIST_NODE_IS_BUDDY(child) && buddy_is_displayable((Gaim2Buddy*)child)) {
-+ struct tooltip_data *td = create_tip_for_node(child, (b == (Gaim2Buddy*)child));
-+ if (b == (Gaim2Buddy *)child) {
- gtkblist->tooltipdata = g_list_prepend(gtkblist->tooltipdata, td);
- } else {
- gtkblist->tooltipdata = g_list_append(gtkblist->tooltipdata, td);
-@@ -2369,7 +2369,7 @@ static gboolean gaim_gtk_blist_tooltip_t
- gtk_window_set_resizable(GTK_WINDOW(gtkblist->tipwindow), FALSE);
- gtk_widget_set_name(gtkblist->tipwindow, "gtk-tooltips");
- g_signal_connect(G_OBJECT(gtkblist->tipwindow), "expose_event",
-- G_CALLBACK(gaim_gtk_blist_paint_tip), NULL);
-+ G_CALLBACK(gaim2_gtk_blist_paint_tip), NULL);
- gtk_widget_ensure_style (gtkblist->tipwindow);
-
-
-@@ -2427,7 +2427,7 @@ static gboolean gaim_gtk_blist_tooltip_t
- return FALSE;
- }
-
--static gboolean gaim_gtk_blist_drag_motion_cb(GtkWidget *tv, GdkDragContext *drag_context,
-+static gboolean gaim2_gtk_blist_drag_motion_cb(GtkWidget *tv, GdkDragContext *drag_context,
- gint x, gint y, guint time, gpointer user_data)
- {
- GtkTreePath *path;
-@@ -2451,11 +2451,11 @@ static gboolean gaim_gtk_blist_drag_moti
-
- if (path)
- gtk_tree_path_free(path);
-- gtkblist->drag_timeout = g_timeout_add(delay, (GSourceFunc)gaim_gtk_blist_expand_timeout, tv);
-+ gtkblist->drag_timeout = g_timeout_add(delay, (GSourceFunc)gaim2_gtk_blist_expand_timeout, tv);
-
- if (gtkblist->mouseover_contact) {
- if ((y < gtkblist->contact_rect.y) || ((y - gtkblist->contact_rect.height) > gtkblist->contact_rect.y)) {
-- gaim_gtk_blist_collapse_contact_cb(NULL, gtkblist->mouseover_contact);
-+ gaim2_gtk_blist_collapse_contact_cb(NULL, gtkblist->mouseover_contact);
- gtkblist->mouseover_contact = NULL;
- }
- }
-@@ -2463,12 +2463,12 @@ static gboolean gaim_gtk_blist_drag_moti
- return FALSE;
- }
-
--static gboolean gaim_gtk_blist_motion_cb (GtkWidget *tv, GdkEventMotion *event, gpointer null)
-+static gboolean gaim2_gtk_blist_motion_cb (GtkWidget *tv, GdkEventMotion *event, gpointer null)
- {
- GtkTreePath *path;
- int delay;
-
-- delay = gaim_prefs_get_int("/gaim/gtk/blist/tooltip_delay");
-+ delay = gaim2_prefs_get_int("/gaim2/gtk/blist/tooltip_delay");
-
- if (delay == 0)
- return FALSE;
-@@ -2477,7 +2477,7 @@ static gboolean gaim_gtk_blist_motion_cb
- if ((event->y > gtkblist->tip_rect.y) && ((event->y - gtkblist->tip_rect.height) < gtkblist->tip_rect.y))
- return FALSE;
- /* We've left the cell. Remove the timeout and create a new one below */
-- gaim_gtk_blist_tooltip_destroy();
-+ gaim2_gtk_blist_tooltip_destroy();
- g_source_remove(gtkblist->timeout);
- }
-
-@@ -2486,11 +2486,11 @@ static gboolean gaim_gtk_blist_motion_cb
-
- if (path)
- gtk_tree_path_free(path);
-- gtkblist->timeout = g_timeout_add(delay, (GSourceFunc)gaim_gtk_blist_tooltip_timeout, tv);
-+ gtkblist->timeout = g_timeout_add(delay, (GSourceFunc)gaim2_gtk_blist_tooltip_timeout, tv);
-
- if (gtkblist->mouseover_contact) {
- if ((event->y < gtkblist->contact_rect.y) || ((event->y - gtkblist->contact_rect.height) > gtkblist->contact_rect.y)) {
-- gaim_gtk_blist_collapse_contact_cb(NULL, gtkblist->mouseover_contact);
-+ gaim2_gtk_blist_collapse_contact_cb(NULL, gtkblist->mouseover_contact);
- gtkblist->mouseover_contact = NULL;
- }
- }
-@@ -2498,7 +2498,7 @@ static gboolean gaim_gtk_blist_motion_cb
- return FALSE;
- }
-
--static void gaim_gtk_blist_leave_cb (GtkWidget *w, GdkEventCrossing *e, gpointer n)
-+static void gaim2_gtk_blist_leave_cb (GtkWidget *w, GdkEventCrossing *e, gpointer n)
- {
-
- if (gtkblist->timeout) {
-@@ -2511,12 +2511,12 @@ static void gaim_gtk_blist_leave_cb (Gtk
- gtkblist->drag_timeout = 0;
- }
-
-- gaim_gtk_blist_tooltip_destroy();
-+ gaim2_gtk_blist_tooltip_destroy();
-
- if (gtkblist->mouseover_contact &&
- !((e->x > gtkblist->contact_rect.x) && (e->x < (gtkblist->contact_rect.x + gtkblist->contact_rect.width)) &&
- (e->y > gtkblist->contact_rect.y) && (e->y < (gtkblist->contact_rect.y + gtkblist->contact_rect.height)))) {
-- gaim_gtk_blist_collapse_contact_cb(NULL, gtkblist->mouseover_contact);
-+ gaim2_gtk_blist_collapse_contact_cb(NULL, gtkblist->mouseover_contact);
- gtkblist->mouseover_contact = NULL;
- }
- }
-@@ -2524,8 +2524,8 @@ static void gaim_gtk_blist_leave_cb (Gtk
- static void
- toggle_debug(void)
- {
-- gaim_prefs_set_bool("/gaim/gtk/debug/enabled",
-- !gaim_prefs_get_bool("/gaim/gtk/debug/enabled"));
-+ gaim2_prefs_set_bool("/gaim2/gtk/debug/enabled",
-+ !gaim2_prefs_get_bool("/gaim2/gtk/debug/enabled"));
- }
-
-
-@@ -2536,74 +2536,74 @@ static GtkItemFactoryEntry blist_menu[]
- {
- /* Buddies menu */
- { N_("/_Buddies"), NULL, NULL, 0, "<Branch>", NULL },
-- { N_("/Buddies/New Instant _Message..."), "<CTL>M", gaim_gtkdialogs_im, 0, "<StockItem>", GAIM_STOCK_IM },
-- { N_("/Buddies/Join a _Chat..."), "<CTL>C", gaim_gtk_blist_joinchat_show, 0, "<StockItem>", GAIM_STOCK_CHAT },
-- { N_("/Buddies/Get User _Info..."), "<CTL>I", gaim_gtkdialogs_info, 0, "<StockItem>", GAIM_STOCK_INFO },
-- { N_("/Buddies/View User _Log..."), "<CTL>L", gaim_gtkdialogs_log, 0, "<StockItem>", GAIM_STOCK_LOG },
-+ { N_("/Buddies/New Instant _Message..."), "<CTL>M", gaim2_gtkdialogs_im, 0, "<StockItem>", GAIM_STOCK_IM },
-+ { N_("/Buddies/Join a _Chat..."), "<CTL>C", gaim2_gtk_blist_joinchat_show, 0, "<StockItem>", GAIM_STOCK_CHAT },
-+ { N_("/Buddies/Get User _Info..."), "<CTL>I", gaim2_gtkdialogs_info, 0, "<StockItem>", GAIM_STOCK_INFO },
-+ { N_("/Buddies/View User _Log..."), "<CTL>L", gaim2_gtkdialogs_log, 0, "<StockItem>", GAIM_STOCK_LOG },
- { "/Buddies/sep1", NULL, NULL, 0, "<Separator>", NULL },
-- { N_("/Buddies/Show _Offline Buddies"), NULL, gaim_gtk_blist_edit_mode_cb, 1, "<CheckItem>", NULL },
-- { N_("/Buddies/Show _Empty Groups"), NULL, gaim_gtk_blist_show_empty_groups_cb, 1, "<CheckItem>", NULL },
-- { N_("/Buddies/Show Buddy _Details"), NULL, gaim_gtk_blist_buddy_details_cb, 1, "<CheckItem>", NULL },
-- { N_("/Buddies/Show Idle _Times"), NULL, gaim_gtk_blist_show_idle_time_cb, 1, "<CheckItem>", NULL },
-+ { N_("/Buddies/Show _Offline Buddies"), NULL, gaim2_gtk_blist_edit_mode_cb, 1, "<CheckItem>", NULL },
-+ { N_("/Buddies/Show _Empty Groups"), NULL, gaim2_gtk_blist_show_empty_groups_cb, 1, "<CheckItem>", NULL },
-+ { N_("/Buddies/Show Buddy _Details"), NULL, gaim2_gtk_blist_buddy_details_cb, 1, "<CheckItem>", NULL },
-+ { N_("/Buddies/Show Idle _Times"), NULL, gaim2_gtk_blist_show_idle_time_cb, 1, "<CheckItem>", NULL },
- { N_("/Buddies/_Sort Buddies"), NULL, NULL, 0, "<Branch>", NULL },
- { "/Buddies/sep2", NULL, NULL, 0, "<Separator>", NULL },
-- { N_("/Buddies/_Add Buddy..."), "<CTL>B", gaim_gtk_blist_add_buddy_cb, 0, "<StockItem>", GTK_STOCK_ADD },
-- { N_("/Buddies/Add C_hat..."), NULL, gaim_gtk_blist_add_chat_cb, 0, "<StockItem>", GTK_STOCK_ADD },
-- { N_("/Buddies/Add _Group..."), NULL, gaim_blist_request_add_group, 0, "<StockItem>", GTK_STOCK_ADD },
-+ { N_("/Buddies/_Add Buddy..."), "<CTL>B", gaim2_gtk_blist_add_buddy_cb, 0, "<StockItem>", GTK_STOCK_ADD },
-+ { N_("/Buddies/Add C_hat..."), NULL, gaim2_gtk_blist_add_chat_cb, 0, "<StockItem>", GTK_STOCK_ADD },
-+ { N_("/Buddies/Add _Group..."), NULL, gaim2_blist_request_add_group, 0, "<StockItem>", GTK_STOCK_ADD },
- { "/Buddies/sep2", NULL, NULL, 0, "<Separator>", NULL },
-- { N_("/Buddies/_Quit"), "<CTL>Q", gaim_core_quit, 0, "<StockItem>", GTK_STOCK_QUIT },
-+ { N_("/Buddies/_Quit"), "<CTL>Q", gaim2_core_quit, 0, "<StockItem>", GTK_STOCK_QUIT },
-
- /* Accounts menu */
- { N_("/_Accounts"), NULL, NULL, 0, "<Branch>", NULL },
-- { N_("/Accounts/Add\\/Edit"), "<CTL>A", gaim_gtk_accounts_window_show, 0, "<StockItem>", GAIM_STOCK_ACCOUNTS },
-+ { N_("/Accounts/Add\\/Edit"), "<CTL>A", gaim2_gtk_accounts_window_show, 0, "<StockItem>", GAIM_STOCK_ACCOUNTS },
-
- /* Tools */
- { N_("/_Tools"), NULL, NULL, 0, "<Branch>", NULL },
-- { N_("/Tools/Buddy _Pounces"), NULL, gaim_gtk_pounces_manager_show, 0, "<StockItem>", GAIM_STOCK_POUNCE },
-- { N_("/Tools/Plu_gins"), "<CTL>U", gaim_gtk_plugin_dialog_show, 0, "<StockItem>", GAIM_STOCK_PLUGIN },
-- { N_("/Tools/Pr_eferences"), "<CTL>P", gaim_gtk_prefs_show, 0, "<StockItem>", GTK_STOCK_PREFERENCES },
-- { N_("/Tools/Pr_ivacy"), NULL, gaim_gtk_privacy_dialog_show, 0, "<StockItem>", GTK_STOCK_DIALOG_ERROR },
-+ { N_("/Tools/Buddy _Pounces"), NULL, gaim2_gtk_pounces_manager_show, 0, "<StockItem>", GAIM_STOCK_POUNCE },
-+ { N_("/Tools/Plu_gins"), "<CTL>U", gaim2_gtk_plugin_dialog_show, 0, "<StockItem>", GAIM_STOCK_PLUGIN },
-+ { N_("/Tools/Pr_eferences"), "<CTL>P", gaim2_gtk_prefs_show, 0, "<StockItem>", GTK_STOCK_PREFERENCES },
-+ { N_("/Tools/Pr_ivacy"), NULL, gaim2_gtk_privacy_dialog_show, 0, "<StockItem>", GTK_STOCK_DIALOG_ERROR },
- { "/Tools/sep2", NULL, NULL, 0, "<Separator>", NULL },
-- { N_("/Tools/_File Transfers"), "<CTL>T", gaim_show_xfer_dialog, 0, "<StockItem>", GAIM_STOCK_FILE_TRANSFER },
-- { N_("/Tools/R_oom List"), NULL, gaim_gtk_roomlist_dialog_show, 0, "<StockItem>", GTK_STOCK_INDEX },
-+ { N_("/Tools/_File Transfers"), "<CTL>T", gaim2_show_xfer_dialog, 0, "<StockItem>", GAIM_STOCK_FILE_TRANSFER },
-+ { N_("/Tools/R_oom List"), NULL, gaim2_gtk_roomlist_dialog_show, 0, "<StockItem>", GTK_STOCK_INDEX },
- { N_("/Tools/System _Log"), NULL, gtk_blist_show_systemlog_cb, 0, "<StockItem>", GAIM_STOCK_LOG },
- { "/Tools/sep3", NULL, NULL, 0, "<Separator>", NULL },
-- { N_("/Tools/Mute _Sounds"), "<CTL>S", gaim_gtk_blist_mute_sounds_cb, 0, "<CheckItem>", NULL },
-+ { N_("/Tools/Mute _Sounds"), "<CTL>S", gaim2_gtk_blist_mute_sounds_cb, 0, "<CheckItem>", NULL },
-
- /* Help */
- { N_("/_Help"), NULL, NULL, 0, "<Branch>", NULL },
- { N_("/Help/Online _Help"), "F1", gtk_blist_show_onlinehelp_cb, 0, "<StockItem>", GTK_STOCK_HELP },
- { N_("/Help/_Debug Window"), NULL, toggle_debug, 0, "<StockItem>", GAIM_STOCK_DEBUG },
-- { N_("/Help/_About"), NULL, gaim_gtkdialogs_about, 0, "<StockItem>", GAIM_STOCK_ABOUT },
-+ { N_("/Help/_About"), NULL, gaim2_gtkdialogs_about, 0, "<StockItem>", GAIM_STOCK_ABOUT },
- };
-
- /*********************************************************
- * Private Utility functions *
- *********************************************************/
-
--static char *gaim_get_tooltip_text(GaimBlistNode *node, gboolean full)
-+static char *gaim2_get_tooltip_text(Gaim2BlistNode *node, gboolean full)
- {
- GString *str = g_string_new("");
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- char *tmp;
-
- if (GAIM_BLIST_NODE_IS_CHAT(node))
- {
-- GaimChat *chat;
-+ Gaim2Chat *chat;
- GList *cur;
- struct proto_chat_entry *pce;
- char *name, *value;
-
-- chat = (GaimChat *)node;
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(chat->account));
-+ chat = (Gaim2Chat *)node;
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(chat->account));
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-
-- tmp = g_markup_escape_text(gaim_chat_get_name(chat), -1);
-+ tmp = g_markup_escape_text(gaim2_chat_get_name(chat), -1);
- g_string_append_printf(str, "<span size='larger' weight='bold'>%s</span>", tmp);
- g_free(tmp);
-
-- if (g_list_length(gaim_connections_get_all()) > 1)
-+ if (g_list_length(gaim2_connections_get_all()) > 1)
- {
- tmp = g_markup_escape_text(chat->account->username, -1);
- g_string_append_printf(str, _("\n<b>Account:</b> %s"), tmp);
-@@ -2622,7 +2622,7 @@ static char *gaim_get_tooltip_text(GaimB
- if (!pce->secret && (!pce->required &&
- g_hash_table_lookup(chat->components, pce->identifier) == NULL))
- {
-- tmp = gaim_text_strip_mnemonic(pce->label);
-+ tmp = gaim2_text_strip_mnemonic(pce->label);
- name = g_markup_escape_text(tmp, -1);
- g_free(tmp);
- value = g_markup_escape_text(g_hash_table_lookup(
-@@ -2640,38 +2640,38 @@ static char *gaim_get_tooltip_text(GaimB
- }
- else if (GAIM_BLIST_NODE_IS_CONTACT(node) || GAIM_BLIST_NODE_IS_BUDDY(node))
- {
-- GaimContact *c;
-- GaimBuddy *b;
-- GaimPresence *presence;
-+ Gaim2Contact *c;
-+ Gaim2Buddy *b;
-+ Gaim2Presence *presence;
- char *tmp;
- time_t idle_secs, signon;
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
- {
-- c = (GaimContact *)node;
-- b = gaim_contact_get_priority_buddy(c);
-+ c = (Gaim2Contact *)node;
-+ b = gaim2_contact_get_priority_buddy(c);
- }
- else
- {
-- b = (GaimBuddy *)node;
-- c = gaim_buddy_get_contact(b);
-+ b = (Gaim2Buddy *)node;
-+ c = gaim2_buddy_get_contact(b);
- }
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(b->account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(b->account));
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-
-- presence = gaim_buddy_get_presence(b);
-+ presence = gaim2_buddy_get_presence(b);
-
- /* Buddy Name */
-- tmp = g_markup_escape_text(gaim_buddy_get_name(b), -1);
-+ tmp = g_markup_escape_text(gaim2_buddy_get_name(b), -1);
- g_string_append_printf(str, "<span size='larger' weight='bold'>%s</span>", tmp);
- g_free(tmp);
-
- /* Account */
-- if (full && g_list_length(gaim_connections_get_all()) > 1)
-+ if (full && g_list_length(gaim2_connections_get_all()) > 1)
- {
-- tmp = g_markup_escape_text(gaim_account_get_username(
-- gaim_buddy_get_account(b)), -1);
-+ tmp = g_markup_escape_text(gaim2_account_get_username(
-+ gaim2_buddy_get_account(b)), -1);
- g_string_append_printf(str, _("\n<b>Account:</b> %s"), tmp);
- g_free(tmp);
- }
-@@ -2702,22 +2702,22 @@ static char *gaim_get_tooltip_text(GaimB
- }
-
- /* Logged In */
-- signon = gaim_presence_get_login_time(presence);
-+ signon = gaim2_presence_get_login_time(presence);
- if (full && GAIM_BUDDY_IS_ONLINE(b) && signon > 0)
- {
-- tmp = gaim_str_seconds_to_string(time(NULL) - signon);
-+ tmp = gaim2_str_seconds_to_string(time(NULL) - signon);
- g_string_append_printf(str, _("\n<b>Logged In:</b> %s"), tmp);
- g_free(tmp);
- }
-
- /* Idle */
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/show_idle_time") &&
-- gaim_presence_is_idle(presence))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_idle_time") &&
-+ gaim2_presence_is_idle(presence))
- {
-- idle_secs = gaim_presence_get_idle_time(presence);
-+ idle_secs = gaim2_presence_get_idle_time(presence);
- if (idle_secs > 0)
- {
-- tmp = gaim_str_seconds_to_string(time(NULL) - idle_secs);
-+ tmp = gaim2_str_seconds_to_string(time(NULL) - idle_secs);
- g_string_append_printf(str, _("\n<b>Idle:</b> %s"), tmp);
- g_free(tmp);
- }
-@@ -2726,8 +2726,8 @@ static char *gaim_get_tooltip_text(GaimB
- /* Last Seen */
- if (!GAIM_BUDDY_IS_ONLINE(b))
- {
-- struct _gaim_gtk_blist_node *gtknode = ((GaimBlistNode *)c)->ui_data;
-- GaimBlistNode *bnode;
-+ struct _gaim2_gtk_blist_node *gtknode = ((Gaim2BlistNode *)c)->ui_data;
-+ Gaim2BlistNode *bnode;
- int lastseen = 0;
-
- if (!gtknode->contact_expanded || GAIM_BLIST_NODE_IS_CONTACT(node))
-@@ -2736,9 +2736,9 @@ static char *gaim_get_tooltip_text(GaimB
- * an expanded contact itself so we show the most recent
- * (largest) last_seen time for any of the buddies under
- * the contact. */
-- for (bnode = ((GaimBlistNode *)c)->child ; bnode != NULL ; bnode = bnode->next)
-+ for (bnode = ((Gaim2BlistNode *)c)->child ; bnode != NULL ; bnode = bnode->next)
- {
-- int value = gaim_blist_node_get_int(bnode, "last_seen");
-+ int value = gaim2_blist_node_get_int(bnode, "last_seen");
- if (value > lastseen)
- lastseen = value;
- }
-@@ -2747,12 +2747,12 @@ static char *gaim_get_tooltip_text(GaimB
- {
- /* We're dealing with a buddy under an expanded contact,
- * so we show the last_seen time for the buddy. */
-- lastseen = gaim_blist_node_get_int(&b->node, "last_seen");
-+ lastseen = gaim2_blist_node_get_int(&b->node, "last_seen");
- }
-
- if (lastseen > 0)
- {
-- tmp = gaim_str_seconds_to_string(time(NULL) - lastseen);
-+ tmp = gaim2_str_seconds_to_string(time(NULL) - lastseen);
- g_string_append_printf(str, _("\n<b>Last Seen:</b> %s ago"), tmp);
- g_free(tmp);
- }
-@@ -2791,7 +2791,7 @@ static char *gaim_get_tooltip_text(GaimB
- g_string_append(str, _("\n<b>Status:</b> Rockin'"));
- }
-
-- gaim_signal_emit(gaim_gtk_blist_get_handle(),
-+ gaim2_signal_emit(gaim2_gtk_blist_get_handle(),
- "drawing-tooltip", node, str, full);
-
- return g_string_free(str, FALSE);
-@@ -2804,45 +2804,45 @@ struct _emblem_data {
- };
-
- GdkPixbuf *
--gaim_gtk_blist_get_status_icon(GaimBlistNode *node, GaimStatusIconSize size)
-+gaim2_gtk_blist_get_status_icon(Gaim2BlistNode *node, Gaim2StatusIconSize size)
- {
- GdkPixbuf *scale, *status = NULL;
- int i, scalesize = 30;
- char *filename;
- const char *protoname = NULL;
-- struct _gaim_gtk_blist_node *gtknode = node->ui_data;
-- struct _gaim_gtk_blist_node *gtkbuddynode = NULL;
-+ struct _gaim2_gtk_blist_node *gtknode = node->ui_data;
-+ struct _gaim2_gtk_blist_node *gtkbuddynode = NULL;
- struct _emblem_data emblems[4] = {{NULL, 15, 15}, {NULL, 0, 15},
- {NULL, 0, 0}, {NULL, 15, 0}};
-- GaimPresence *presence = NULL;
-- GaimBuddy *buddy = NULL;
-- GaimChat *chat = NULL;
-+ Gaim2Presence *presence = NULL;
-+ Gaim2Buddy *buddy = NULL;
-+ Gaim2Chat *chat = NULL;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
- if(!gtknode->contact_expanded) {
-- buddy = gaim_contact_get_priority_buddy((GaimContact*)node);
-- gtkbuddynode = ((GaimBlistNode*)buddy)->ui_data;
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
-+ gtkbuddynode = ((Gaim2BlistNode*)buddy)->ui_data;
- }
- } else if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- buddy = (GaimBuddy*)node;
-+ buddy = (Gaim2Buddy*)node;
- gtkbuddynode = node->ui_data;
- } else if(GAIM_BLIST_NODE_IS_CHAT(node)) {
-- chat = (GaimChat*)node;
-+ chat = (Gaim2Chat*)node;
- } else {
- return NULL;
- }
-
- if(buddy || chat) {
-- GaimAccount *account;
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Account *account;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- if(buddy)
- account = buddy->account;
- else
- account = chat->account;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
- if(!prpl)
- return NULL;
-
-@@ -2866,16 +2866,16 @@ gaim_gtk_blist_get_status_icon(GaimBlist
- }
-
- if(buddy && GAIM_BUDDY_IS_ONLINE(buddy) && gtkbuddynode && gtkbuddynode->recent_signonoff) {
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", "login.png", NULL);
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", "login.png", NULL);
- } else if(buddy && !GAIM_BUDDY_IS_ONLINE(buddy) && gtkbuddynode && gtkbuddynode->recent_signonoff) {
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", "logout.png", NULL);
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", "logout.png", NULL);
- } else if(buddy || chat) {
- char *image = g_strdup_printf("%s.png", protoname);
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", image, NULL);
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", image, NULL);
- g_free(image);
- } else {
-- /* gaim dude */
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim.png", NULL);
-+ /* gaim2 dude */
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2.png", NULL);
- }
-
- status = gdk_pixbuf_new_from_file(filename, NULL);
-@@ -2892,7 +2892,7 @@ gaim_gtk_blist_get_status_icon(GaimBlist
- if(emblems[i].filename) {
- GdkPixbuf *emblem;
- char *image = g_strdup_printf("%s.png", emblems[i].filename);
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", image, NULL);
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", image, NULL);
- g_free(image);
- emblem = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-@@ -2920,19 +2920,19 @@ gaim_gtk_blist_get_status_icon(GaimBlist
- }
-
- if(buddy) {
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
- if (!GAIM_BUDDY_IS_ONLINE(buddy))
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.0, FALSE);
-- else if (gaim_presence_is_idle(presence))
-+ else if (gaim2_presence_is_idle(presence))
- {
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.25, FALSE);
- }
-
-- if (!gaim_privacy_check(buddy->account, gaim_buddy_get_name(buddy)))
-+ if (!gaim2_privacy_check(buddy->account, gaim2_buddy_get_name(buddy)))
- {
- GdkPixbuf *emblem;
-- char *filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", "blocked.png", NULL);
-+ char *filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", "blocked.png", NULL);
-
- emblem = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-@@ -2954,39 +2954,39 @@ gaim_gtk_blist_get_status_icon(GaimBlist
- return scale;
- }
-
--static gchar *gaim_gtk_blist_get_name_markup(GaimBuddy *b, gboolean selected)
-+static gchar *gaim2_gtk_blist_get_name_markup(Gaim2Buddy *b, gboolean selected)
- {
- const char *name;
- char *esc, *text = NULL;
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimContact *contact;
-- GaimPresence *presence;
-- struct _gaim_gtk_blist_node *gtkcontactnode = NULL;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Contact *contact;
-+ Gaim2Presence *presence;
-+ struct _gaim2_gtk_blist_node *gtkcontactnode = NULL;
- char *idletime = NULL, *statustext = NULL;
- time_t t;
- /* XXX Clean up this crap */
-
-- contact = (GaimContact*)((GaimBlistNode*)b)->parent;
-+ contact = (Gaim2Contact*)((Gaim2BlistNode*)b)->parent;
- if(contact)
-- gtkcontactnode = ((GaimBlistNode*)contact)->ui_data;
-+ gtkcontactnode = ((Gaim2BlistNode*)contact)->ui_data;
-
- if(gtkcontactnode && !gtkcontactnode->contact_expanded && contact->alias)
- name = contact->alias;
- else
-- name = gaim_buddy_get_alias(b);
-+ name = gaim2_buddy_get_alias(b);
- esc = g_markup_escape_text(name, strlen(name));
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(b->account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(b->account));
-
- if (prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-
-- presence = gaim_buddy_get_presence(b);
-+ presence = gaim2_buddy_get_presence(b);
-
-- if (!gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons")) {
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons")) {
-
-- if ((gaim_presence_is_idle(presence) || !GAIM_BUDDY_IS_ONLINE(b)) && !selected)
-+ if ((gaim2_presence_is_idle(presence) || !GAIM_BUDDY_IS_ONLINE(b)) && !selected)
- {
- text = g_strdup_printf("<span color='%s'>%s</span>",
- dim_grey(), esc);
-@@ -3015,7 +3015,7 @@ static gchar *gaim_gtk_blist_get_name_ma
- int length = 0, vis=0;
- gboolean inside = FALSE;
- g_strdelimit(tmp, "\n", ' ');
-- gaim_str_strip_char(tmp, '\r');
-+ gaim2_str_strip_char(tmp, '\r');
-
- while(*c && vis < 20) {
- if(*c == '&')
-@@ -3045,10 +3045,10 @@ static gchar *gaim_gtk_blist_get_name_ma
- #endif
- }
-
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/show_idle_time") &&
-- gaim_presence_is_idle(presence))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_idle_time") &&
-+ gaim2_presence_is_idle(presence))
- {
-- time_t idle_secs = gaim_presence_get_idle_time(presence);
-+ time_t idle_secs = gaim2_presence_get_idle_time(presence);
-
- if (idle_secs > 0) {
- int ihrs, imin;
-@@ -3069,7 +3069,7 @@ static gchar *gaim_gtk_blist_get_name_ma
- if(!GAIM_BUDDY_IS_ONLINE(b) && !statustext)
- statustext = g_strdup(_("Offline "));
-
-- if (gaim_presence_is_idle(presence) && !selected) {
-+ if (gaim2_presence_is_idle(presence) && !selected) {
- text = g_strdup_printf("<span color='%s'>%s</span>\n"
- "<span color='%s' size='smaller'>%s%s%s</span>",
- dim_grey(), esc, dim_grey(),
-@@ -3101,20 +3101,20 @@ static gchar *gaim_gtk_blist_get_name_ma
- return text;
- }
-
--static void gaim_gtk_blist_restore_position()
-+static void gaim2_gtk_blist_restore_position()
- {
- int blist_x, blist_y, blist_width, blist_height;
-
-- blist_width = gaim_prefs_get_int("/gaim/gtk/blist/width");
-+ blist_width = gaim2_prefs_get_int("/gaim2/gtk/blist/width");
-
- /* if the window exists, is hidden, we're saving positions, and the
- * position is sane... */
- if (gtkblist && gtkblist->window &&
- !GTK_WIDGET_VISIBLE(gtkblist->window) && blist_width != 0) {
-
-- blist_x = gaim_prefs_get_int("/gaim/gtk/blist/x");
-- blist_y = gaim_prefs_get_int("/gaim/gtk/blist/y");
-- blist_height = gaim_prefs_get_int("/gaim/gtk/blist/height");
-+ blist_x = gaim2_prefs_get_int("/gaim2/gtk/blist/x");
-+ blist_y = gaim2_prefs_get_int("/gaim2/gtk/blist/y");
-+ blist_height = gaim2_prefs_get_int("/gaim2/gtk/blist/height");
-
- /* ...check position is on screen... */
- if (blist_x >= gdk_screen_width())
-@@ -3130,27 +3130,27 @@ static void gaim_gtk_blist_restore_posit
- /* ...and move it back. */
- gtk_window_move(GTK_WINDOW(gtkblist->window), blist_x, blist_y);
- gtk_window_resize(GTK_WINDOW(gtkblist->window), blist_width, blist_height);
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/list_maximized"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/list_maximized"))
- gtk_window_maximize(GTK_WINDOW(gtkblist->window));
- }
- }
-
--static gboolean gaim_gtk_blist_refresh_timer(GaimBuddyList *list)
-+static gboolean gaim2_gtk_blist_refresh_timer(Gaim2BuddyList *list)
- {
-- GaimBlistNode *gnode, *cnode;
-+ Gaim2BlistNode *gnode, *cnode;
-
- for(gnode = list->root; gnode; gnode = gnode->next) {
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
- if(GAIM_BLIST_NODE_IS_CONTACT(cnode)) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- buddy = gaim_contact_get_priority_buddy((GaimContact*)cnode);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)cnode);
-
- if (buddy &&
-- gaim_presence_is_idle(gaim_buddy_get_presence(buddy)))
-- gaim_gtk_blist_update(list, cnode);
-+ gaim2_presence_is_idle(gaim2_buddy_get_presence(buddy)))
-+ gaim2_gtk_blist_update(list, cnode);
- }
- }
- }
-@@ -3159,9 +3159,9 @@ static gboolean gaim_gtk_blist_refresh_t
- return TRUE;
- }
-
--static void gaim_gtk_blist_hide_node(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_hide_node(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
-- struct _gaim_gtk_blist_node *gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ struct _gaim2_gtk_blist_node *gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
- GtkTreeIter iter;
-
- if (!gtknode || !gtknode->row || !gtkblist)
-@@ -3174,7 +3174,7 @@ static void gaim_gtk_blist_hide_node(Gai
- gtk_tree_store_remove(gtkblist->treemodel, &iter);
- if(GAIM_BLIST_NODE_IS_CONTACT(node) || GAIM_BLIST_NODE_IS_BUDDY(node)
- || GAIM_BLIST_NODE_IS_CHAT(node)) {
-- gaim_gtk_blist_update(list, node->parent);
-+ gaim2_gtk_blist_update(list, node->parent);
- }
- }
- gtk_tree_row_reference_free(gtknode->row);
-@@ -3199,7 +3199,7 @@ static const int require_connection_size
- * where appropriate.
- */
- static void
--update_menu_bar(GaimGtkBuddyList *gtkblist)
-+update_menu_bar(Gaim2GtkBuddyList *gtkblist)
- {
- GtkWidget *widget;
- gboolean sensitive;
-@@ -3207,9 +3207,9 @@ update_menu_bar(GaimGtkBuddyList *gtkbli
-
- g_return_if_fail(gtkblist != NULL);
-
-- gaim_gtk_blist_update_accounts_menu();
-+ gaim2_gtk_blist_update_accounts_menu();
-
-- sensitive = (gaim_connections_get_all() != NULL);
-+ sensitive = (gaim2_connections_get_all() != NULL);
-
- for (i = 0; i < require_connection_size; i++)
- {
-@@ -3218,33 +3218,33 @@ update_menu_bar(GaimGtkBuddyList *gtkbli
- }
-
- widget = gtk_item_factory_get_widget(gtkblist->ift, N_("/Buddies/Join a Chat..."));
-- gtk_widget_set_sensitive(widget, gaim_gtk_blist_joinchat_is_showable());
-+ gtk_widget_set_sensitive(widget, gaim2_gtk_blist_joinchat_is_showable());
-
- widget = gtk_item_factory_get_widget(gtkblist->ift, N_("/Buddies/Add Chat..."));
-- gtk_widget_set_sensitive(widget, gaim_gtk_blist_joinchat_is_showable());
-+ gtk_widget_set_sensitive(widget, gaim2_gtk_blist_joinchat_is_showable());
-
- widget = gtk_item_factory_get_widget(gtkblist->ift, N_("/Tools/Buddy Pounces"));
-- gtk_widget_set_sensitive(widget, (gaim_connections_get_all() != NULL));
-+ gtk_widget_set_sensitive(widget, (gaim2_connections_get_all() != NULL));
-
- widget = gtk_item_factory_get_widget(gtkblist->ift, N_("/Tools/Privacy"));
-- gtk_widget_set_sensitive(widget, gaim_gtk_privacy_is_showable());
-+ gtk_widget_set_sensitive(widget, gaim2_gtk_privacy_is_showable());
-
- widget = gtk_item_factory_get_widget(gtkblist->ift, N_("/Tools/Room List"));
-- gtk_widget_set_sensitive(widget, gaim_gtk_roomlist_is_showable());
-+ gtk_widget_set_sensitive(widget, gaim2_gtk_roomlist_is_showable());
- }
-
- static void
--sign_on_off_cb(GaimConnection *gc, GaimBuddyList *blist)
-+sign_on_off_cb(Gaim2Connection *gc, Gaim2BuddyList *blist)
- {
-- GaimGtkBuddyList *gtkblist = GAIM_GTK_BLIST(blist);
-+ Gaim2GtkBuddyList *gtkblist = GAIM_GTK_BLIST(blist);
-
- update_menu_bar(gtkblist);
- }
-
- static void
--plugin_changed_cb(GaimPlugin *p, gpointer *data)
-+plugin_changed_cb(Gaim2Plugin *p, gpointer *data)
- {
-- gaim_gtk_blist_update_plugin_actions();
-+ gaim2_gtk_blist_update_plugin_actions();
- }
-
- static void
-@@ -3258,13 +3258,13 @@ unseen_conv_menu()
-
- menu = gtk_menu_new();
-
-- convs = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM, GAIM_UNSEEN_TEXT, TRUE, 0);
-+ convs = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM, GAIM_UNSEEN_TEXT, TRUE, 0);
- if (!convs) {
- /* no conversations added, don't show the menu */
- gtk_widget_destroy(menu);
- return;
- }
-- gaim_gtk_conversations_fill_menu(menu, convs);
-+ gaim2_gtk_conversations_fill_menu(menu, convs);
- g_list_free(convs);
- gtk_widget_show_all(menu);
- gtk_menu_popup(GTK_MENU(menu), NULL, NULL, NULL, NULL, 3,
-@@ -3278,10 +3278,10 @@ menutray_press_cb(GtkWidget *widget, Gdk
-
- switch (event->button) {
- case 1:
-- convs = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM,
-+ convs = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM,
- GAIM_UNSEEN_TEXT, TRUE, 1);
- if (convs) {
-- gaim_gtkconv_present_conversation((GaimConversation*)convs->data);
-+ gaim2_gtkconv_present_conversation((Gaim2Conversation*)convs->data);
- g_list_free(convs);
- }
- break;
-@@ -3293,8 +3293,8 @@ menutray_press_cb(GtkWidget *widget, Gdk
- }
-
- static void
--conversation_updated_cb(GaimConversation *conv, GaimConvUpdateType type,
-- GaimGtkBuddyList *gtkblist)
-+conversation_updated_cb(Gaim2Conversation *conv, Gaim2ConvUpdateType type,
-+ Gaim2GtkBuddyList *gtkblist)
- {
- GList *convs = NULL;
- GList *l = NULL;
-@@ -3307,7 +3307,7 @@ conversation_updated_cb(GaimConversation
- gtkblist->menutrayicon = NULL;
- }
-
-- convs = gaim_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM, GAIM_UNSEEN_TEXT, TRUE, 0);
-+ convs = gaim2_gtk_conversations_find_unseen_list(GAIM_CONV_TYPE_IM, GAIM_UNSEEN_TEXT, TRUE, 0);
- if (convs) {
- GtkWidget *img = NULL;
- GString *tooltip_text = NULL;
-@@ -3316,7 +3316,7 @@ conversation_updated_cb(GaimConversation
- l = convs;
- while (l != NULL) {
- if (GAIM_IS_GTK_CONVERSATION(l->data)) {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION((GaimConversation *)l->data);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION((Gaim2Conversation *)l->data);
-
- g_string_append_printf(tooltip_text,
- ngettext("%d unread message from %s\n", "%d unread messages from %s\n", gtkconv->unseen_count),
-@@ -3336,7 +3336,7 @@ conversation_updated_cb(GaimConversation
- gtk_widget_show(gtkblist->menutrayicon);
- g_signal_connect(G_OBJECT(gtkblist->menutrayicon), "button-press-event", G_CALLBACK(menutray_press_cb), NULL);
-
-- gaim_gtk_menu_tray_append(GAIM_GTK_MENU_TRAY(gtkblist->menutray), gtkblist->menutrayicon, tooltip_text->str);
-+ gaim2_gtk_menu_tray_append(GAIM_GTK_MENU_TRAY(gtkblist->menutray), gtkblist->menutrayicon, tooltip_text->str);
- }
- g_string_free(tooltip_text, TRUE);
- g_list_free(convs);
-@@ -3344,7 +3344,7 @@ conversation_updated_cb(GaimConversation
- }
-
- static void
--conversation_deleting_cb(GaimConversation *conv, GaimGtkBuddyList *gtkblist)
-+conversation_deleting_cb(Gaim2Conversation *conv, Gaim2GtkBuddyList *gtkblist)
- {
- conversation_updated_cb(conv, GAIM_CONV_UPDATE_UNSEEN, gtkblist);
- }
-@@ -3353,49 +3353,49 @@ conversation_deleting_cb(GaimConversatio
- * Public API Functions *
- **********************************************************************************/
-
--static void gaim_gtk_blist_new_list(GaimBuddyList *blist)
-+static void gaim2_gtk_blist_new_list(Gaim2BuddyList *blist)
- {
-- GaimGtkBuddyList *gtkblist;
-+ Gaim2GtkBuddyList *gtkblist;
-
-- gtkblist = g_new0(GaimGtkBuddyList, 1);
-+ gtkblist = g_new0(Gaim2GtkBuddyList, 1);
- blist->ui_data = gtkblist;
- }
-
--static void gaim_gtk_blist_new_node(GaimBlistNode *node)
-+static void gaim2_gtk_blist_new_node(Gaim2BlistNode *node)
- {
-- node->ui_data = g_new0(struct _gaim_gtk_blist_node, 1);
-+ node->ui_data = g_new0(struct _gaim2_gtk_blist_node, 1);
- }
-
--gboolean gaim_gtk_blist_node_is_contact_expanded(GaimBlistNode *node)
-+gboolean gaim2_gtk_blist_node_is_contact_expanded(Gaim2BlistNode *node)
- {
- if GAIM_BLIST_NODE_IS_BUDDY(node)
- node = node->parent;
-
- g_return_val_if_fail(GAIM_BLIST_NODE_IS_CONTACT(node), FALSE);
-
-- return ((struct _gaim_gtk_blist_node *)node->ui_data)->contact_expanded;
-+ return ((struct _gaim2_gtk_blist_node *)node->ui_data)->contact_expanded;
- }
-
--void gaim_gtk_blist_update_columns()
-+void gaim2_gtk_blist_update_columns()
- {
- if(!gtkblist)
- return;
-
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons")) {
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons")) {
- gtk_tree_view_column_set_visible(gtkblist->buddy_icon_column, TRUE);
- gtk_tree_view_column_set_visible(gtkblist->idle_column, FALSE);
- } else {
- gtk_tree_view_column_set_visible(gtkblist->idle_column,
-- gaim_prefs_get_bool("/gaim/gtk/blist/show_idle_time"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/blist/show_idle_time"));
- gtk_tree_view_column_set_visible(gtkblist->buddy_icon_column, FALSE);
- }
- }
-
- static void
--show_buddy_icons_pref_cb(const char *name, GaimPrefType type,
-+show_buddy_icons_pref_cb(const char *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
-- gaim_gtk_blist_update_columns();
-+ gaim2_gtk_blist_update_columns();
- }
-
- enum {
-@@ -3413,27 +3413,27 @@ item_factory_translate_func (const char
- return _((char *)path);
- }
-
--void gaim_gtk_blist_setup_sort_methods()
-+void gaim2_gtk_blist_setup_sort_methods()
- {
-- gaim_gtk_blist_sort_method_reg("none", _("Manually"), sort_method_none);
-+ gaim2_gtk_blist_sort_method_reg("none", _("Manually"), sort_method_none);
- #if GTK_CHECK_VERSION(2,2,1)
-- gaim_gtk_blist_sort_method_reg("alphabetical", _("Alphabetically"), sort_method_alphabetical);
-- gaim_gtk_blist_sort_method_reg("status", _("By status"), sort_method_status);
-- gaim_gtk_blist_sort_method_reg("log_size", _("By log size"), sort_method_log);
-+ gaim2_gtk_blist_sort_method_reg("alphabetical", _("Alphabetically"), sort_method_alphabetical);
-+ gaim2_gtk_blist_sort_method_reg("status", _("By status"), sort_method_status);
-+ gaim2_gtk_blist_sort_method_reg("log_size", _("By log size"), sort_method_log);
- #endif
-- gaim_gtk_blist_sort_method_set(gaim_prefs_get_string("/gaim/gtk/blist/sort_type"));
-+ gaim2_gtk_blist_sort_method_set(gaim2_prefs_get_string("/gaim2/gtk/blist/sort_type"));
- }
-
- static void _prefs_change_redo_list()
- {
-- redo_buddy_list(gaim_get_blist(), TRUE);
-+ redo_buddy_list(gaim2_get_blist(), TRUE);
- }
-
--static void _prefs_change_sort_method(const char *pref_name, GaimPrefType type,
-+static void _prefs_change_sort_method(const char *pref_name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
-- if(!strcmp(pref_name, "/gaim/gtk/blist/sort_type"))
-- gaim_gtk_blist_sort_method_set(val);
-+ if(!strcmp(pref_name, "/gaim2/gtk/blist/sort_type"))
-+ gaim2_gtk_blist_sort_method_set(val);
- }
-
- /*
-@@ -3462,9 +3462,9 @@ _search_func(GtkTreeModel *model, gint c
-
- gtk_tree_model_get(model, iter, column, &withmarkup, -1);
-
-- enteredstring = g_utf8_casefold(gaim_normalize(NULL, key), -1);
-- nomarkup = gaim_markup_strip_html(withmarkup);
-- normalized = g_utf8_casefold(gaim_normalize(NULL, nomarkup), -1);
-+ enteredstring = g_utf8_casefold(gaim2_normalize(NULL, key), -1);
-+ nomarkup = gaim2_markup_strip_html(withmarkup);
-+ normalized = g_utf8_casefold(gaim2_normalize(NULL, nomarkup), -1);
-
- result = (g_strstr_len(normalized, strlen(normalized), enteredstring) == NULL);
-
-@@ -3476,7 +3476,7 @@ _search_func(GtkTreeModel *model, gint c
- return result;
- }
-
--static void account_modified(GaimAccount *account, GaimGtkBuddyList *gtkblist)
-+static void account_modified(Gaim2Account *account, Gaim2GtkBuddyList *gtkblist)
- {
- if (!gtkblist)
- return;
-@@ -3485,7 +3485,7 @@ static void account_modified(GaimAccount
- }
-
- static gboolean
--gtk_blist_window_key_press_cb(GtkWidget *w, GdkEventKey *event, GaimGtkBuddyList *gtkblist)
-+gtk_blist_window_key_press_cb(GtkWidget *w, GdkEventKey *event, Gaim2GtkBuddyList *gtkblist)
- {
- GtkWidget *imhtml;
-
-@@ -3499,7 +3499,7 @@ gtk_blist_window_key_press_cb(GtkWidget
- return FALSE;
- }
-
--static void gaim_gtk_blist_show(GaimBuddyList *list)
-+static void gaim2_gtk_blist_show(Gaim2BuddyList *list)
- {
- void *handle;
- GtkCellRenderer *rend;
-@@ -3517,7 +3517,7 @@ static void gaim_gtk_blist_show(GaimBudd
- {"application/x-im-contact", 0, DRAG_BUDDY},
- {"text/x-vcard", 0, DRAG_VCARD }};
- if (gtkblist && gtkblist->window) {
-- gaim_blist_set_visible(gaim_prefs_get_bool("/gaim/gtk/blist/list_visible"));
-+ gaim2_blist_set_visible(gaim2_prefs_get_bool("/gaim2/gtk/blist/list_visible"));
- return;
- }
-
-@@ -3543,17 +3543,17 @@ static void gaim_gtk_blist_show(GaimBudd
- accel_group = gtk_accel_group_new();
- gtk_window_add_accel_group(GTK_WINDOW (gtkblist->window), accel_group);
- g_object_unref(accel_group);
-- gtkblist->ift = gtk_item_factory_new(GTK_TYPE_MENU_BAR, "<GaimMain>", accel_group);
-+ gtkblist->ift = gtk_item_factory_new(GTK_TYPE_MENU_BAR, "<Gaim2Main>", accel_group);
- gtk_item_factory_set_translate_func(gtkblist->ift,
- item_factory_translate_func,
- NULL, NULL);
- gtk_item_factory_create_items(gtkblist->ift, sizeof(blist_menu) / sizeof(*blist_menu),
- blist_menu, NULL);
-- gaim_gtk_load_accels();
-+ gaim2_gtk_load_accels();
- g_signal_connect(G_OBJECT(accel_group), "accel-changed",
-- G_CALLBACK(gaim_gtk_save_accels_cb), NULL);
-- menu = gtk_item_factory_get_widget(gtkblist->ift, "<GaimMain>");
-- gtkblist->menutray = gaim_gtk_menu_tray_new();
-+ G_CALLBACK(gaim2_gtk_save_accels_cb), NULL);
-+ menu = gtk_item_factory_get_widget(gtkblist->ift, "<Gaim2Main>");
-+ gtkblist->menutray = gaim2_gtk_menu_tray_new();
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), gtkblist->menutray);
- gtk_widget_show(gtkblist->menutray);
- gtk_widget_show(menu);
-@@ -3573,11 +3573,11 @@ static void gaim_gtk_blist_show(GaimBudd
-
- gtkblist->treeview = gtk_tree_view_new_with_model(GTK_TREE_MODEL(gtkblist->treemodel));
- gtk_widget_show(gtkblist->treeview);
-- gtk_widget_set_name(gtkblist->treeview, "gaim_gtkblist_treeview");
-+ gtk_widget_set_name(gtkblist->treeview, "gaim2_gtkblist_treeview");
-
- /* Set up selection stuff */
- selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(gtkblist->treeview));
-- g_signal_connect(G_OBJECT(selection), "changed", G_CALLBACK(gaim_gtk_blist_selection_changed), NULL);
-+ g_signal_connect(G_OBJECT(selection), "changed", G_CALLBACK(gaim2_gtk_blist_selection_changed), NULL);
-
- /* Set up dnd */
- gtk_tree_view_enable_model_drag_source(GTK_TREE_VIEW(gtkblist->treeview),
-@@ -3587,17 +3587,17 @@ static void gaim_gtk_blist_show(GaimBudd
- dte, 5,
- GDK_ACTION_COPY | GDK_ACTION_MOVE);
-
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-data-received", G_CALLBACK(gaim_gtk_blist_drag_data_rcv_cb), NULL);
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-data-get", G_CALLBACK(gaim_gtk_blist_drag_data_get_cb), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-data-received", G_CALLBACK(gaim2_gtk_blist_drag_data_rcv_cb), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-data-get", G_CALLBACK(gaim2_gtk_blist_drag_data_get_cb), NULL);
- #ifdef _WIN32
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-begin", G_CALLBACK(gaim_gtk_blist_drag_begin), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-begin", G_CALLBACK(gaim2_gtk_blist_drag_begin), NULL);
- #endif
-
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-motion", G_CALLBACK(gaim_gtk_blist_drag_motion_cb), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "drag-motion", G_CALLBACK(gaim2_gtk_blist_drag_motion_cb), NULL);
-
- /* Tooltips */
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "motion-notify-event", G_CALLBACK(gaim_gtk_blist_motion_cb), NULL);
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "leave-notify-event", G_CALLBACK(gaim_gtk_blist_leave_cb), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "motion-notify-event", G_CALLBACK(gaim2_gtk_blist_motion_cb), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "leave-notify-event", G_CALLBACK(gaim2_gtk_blist_leave_cb), NULL);
-
- gtk_tree_view_set_headers_visible(GTK_TREE_VIEW(gtkblist->treeview), FALSE);
-
-@@ -3639,7 +3639,7 @@ static void gaim_gtk_blist_show(GaimBudd
- g_signal_connect(G_OBJECT(gtkblist->treeview), "row-collapsed", G_CALLBACK(gtk_blist_row_collapsed_cb), NULL);
- g_signal_connect(G_OBJECT(gtkblist->treeview), "button-press-event", G_CALLBACK(gtk_blist_button_press_cb), NULL);
- g_signal_connect(G_OBJECT(gtkblist->treeview), "key-press-event", G_CALLBACK(gtk_blist_key_press_cb), NULL);
-- g_signal_connect(G_OBJECT(gtkblist->treeview), "popup-menu", G_CALLBACK(gaim_gtk_blist_popup_menu_cb), NULL);
-+ g_signal_connect(G_OBJECT(gtkblist->treeview), "popup-menu", G_CALLBACK(gaim2_gtk_blist_popup_menu_cb), NULL);
-
- /* Enable CTRL+F searching */
- gtk_tree_view_set_search_column(GTK_TREE_VIEW(gtkblist->treeview), NAME_COLUMN);
-@@ -3647,10 +3647,10 @@ static void gaim_gtk_blist_show(GaimBudd
-
- gtk_box_pack_start(GTK_BOX(gtkblist->vbox), sw, TRUE, TRUE, 0);
- gtk_container_add(GTK_CONTAINER(sw), gtkblist->treeview);
-- gaim_gtk_blist_update_columns();
-+ gaim2_gtk_blist_update_columns();
-
-- gtkblist->statusbox = gtk_gaim_status_box_new();
-- gtk_widget_set_name(gtkblist->statusbox, "gaim_gtkblist_statusbox");
-+ gtkblist->statusbox = gtk_gaim2_status_box_new();
-+ gtk_widget_set_name(gtkblist->statusbox, "gaim2_gtkblist_statusbox");
-
- gtk_widget_show(gtkblist->statusbox);
- gtk_box_pack_start(GTK_BOX(gtkblist->vbox), gtkblist->statusbox, FALSE, TRUE, 0);
-@@ -3660,130 +3660,130 @@ static void gaim_gtk_blist_show(GaimBudd
- * after the treeview or faceprint gets mad. -Robot101
- */
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_item_factory_get_item (gtkblist->ift, N_("/Buddies/Show Offline Buddies"))),
-- gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/blist/show_offline_buddies"));
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_item_factory_get_item (gtkblist->ift, N_("/Buddies/Show Empty Groups"))),
-- gaim_prefs_get_bool("/gaim/gtk/blist/show_empty_groups"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/blist/show_empty_groups"));
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_item_factory_get_item (gtkblist->ift, N_("/Tools/Mute Sounds"))),
-- gaim_prefs_get_bool("/gaim/gtk/sound/mute"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/sound/mute"));
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_item_factory_get_item (gtkblist->ift, N_("/Buddies/Show Buddy Details"))),
-- gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons"));
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtk_item_factory_get_item (gtkblist->ift, N_("/Buddies/Show Idle Times"))),
-- gaim_prefs_get_bool("/gaim/gtk/blist/show_idle_time"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/blist/show_idle_time"));
-
-- if(!strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"), "none"))
-+ if(!strcmp(gaim2_prefs_get_string("/gaim2/gtk/sound/method"), "none"))
- gtk_widget_set_sensitive(gtk_item_factory_get_widget(gtkblist->ift, N_("/Tools/Mute Sounds")), FALSE);
-
- /* Update some dynamic things */
- update_menu_bar(gtkblist);
-- gaim_gtk_blist_update_plugin_actions();
-- gaim_gtk_blist_update_sort_methods();
-+ gaim2_gtk_blist_update_plugin_actions();
-+ gaim2_gtk_blist_update_sort_methods();
-
- /* OK... let's show this bad boy. */
-- gaim_gtk_blist_refresh(list);
-- gaim_gtk_blist_restore_position();
-+ gaim2_gtk_blist_refresh(list);
-+ gaim2_gtk_blist_restore_position();
- gtk_widget_show_all(GTK_WIDGET(gtkblist->window));
-- gaim_blist_set_visible(gaim_prefs_get_bool("/gaim/gtk/blist/list_visible"));
-+ gaim2_blist_set_visible(gaim2_prefs_get_bool("/gaim2/gtk/blist/list_visible"));
-
- /* start the refresh timer */
-- gtkblist->refresh_timer = g_timeout_add(30000, (GSourceFunc)gaim_gtk_blist_refresh_timer, list);
-+ gtkblist->refresh_timer = g_timeout_add(30000, (GSourceFunc)gaim2_gtk_blist_refresh_timer, list);
-
-- handle = gaim_gtk_blist_get_handle();
-+ handle = gaim2_gtk_blist_get_handle();
-
- /* things that affect how buddies are displayed */
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/show_buddy_icons",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/show_buddy_icons",
- _prefs_change_redo_list, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/show_idle_time",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/show_idle_time",
- _prefs_change_redo_list, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/show_empty_groups",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/show_empty_groups",
- _prefs_change_redo_list, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/show_offline_buddies",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/show_offline_buddies",
- _prefs_change_redo_list, NULL);
-
- /* sorting */
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/sort_type",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/sort_type",
- _prefs_change_sort_method, NULL);
-
- /* things that affect what columns are displayed */
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/show_buddy_icons",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/show_buddy_icons",
- show_buddy_icons_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/blist/show_idle_time",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/blist/show_idle_time",
- show_buddy_icons_pref_cb, NULL);
-
- /* menus */
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/sound/mute",
-- gaim_gtk_blist_mute_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/sound/method",
-- gaim_gtk_blist_sound_method_pref_cb, NULL);
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/sound/mute",
-+ gaim2_gtk_blist_mute_pref_cb, NULL);
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/sound/method",
-+ gaim2_gtk_blist_sound_method_pref_cb, NULL);
-
-- /* Setup some gaim signal handlers. */
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-enabled",
-+ /* Setup some gaim2 signal handlers. */
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-enabled",
- gtkblist, GAIM_CALLBACK(account_modified), gtkblist);
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-disabled",
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-disabled",
- gtkblist, GAIM_CALLBACK(account_modified), gtkblist);
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-removed",
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-removed",
- gtkblist, GAIM_CALLBACK(account_modified), gtkblist);
-
-- gaim_signal_connect(gaim_gtk_account_get_handle(), "account-modified",
-+ gaim2_signal_connect(gaim2_gtk_account_get_handle(), "account-modified",
- gtkblist, GAIM_CALLBACK(account_modified), gtkblist);
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- gtkblist, GAIM_CALLBACK(sign_on_off_cb), list);
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off",
- gtkblist, GAIM_CALLBACK(sign_on_off_cb), list);
-
-- gaim_signal_connect(gaim_plugins_get_handle(), "plugin-load",
-+ gaim2_signal_connect(gaim2_plugins_get_handle(), "plugin-load",
- gtkblist, GAIM_CALLBACK(plugin_changed_cb), NULL);
-- gaim_signal_connect(gaim_plugins_get_handle(), "plugin-unload",
-+ gaim2_signal_connect(gaim2_plugins_get_handle(), "plugin-unload",
- gtkblist, GAIM_CALLBACK(plugin_changed_cb), NULL);
-
-- gaim_signal_connect(gaim_conversations_get_handle(), "conversation-updated",
-+ gaim2_signal_connect(gaim2_conversations_get_handle(), "conversation-updated",
- gtkblist, GAIM_CALLBACK(conversation_updated_cb),
- gtkblist);
-- gaim_signal_connect(gaim_conversations_get_handle(), "deleting-conversation",
-+ gaim2_signal_connect(gaim2_conversations_get_handle(), "deleting-conversation",
- gtkblist, GAIM_CALLBACK(conversation_deleting_cb),
- gtkblist);
-
- /* emit our created signal */
-- gaim_signal_emit(handle, "gtkblist-created", list);
-+ gaim2_signal_emit(handle, "gtkblist-created", list);
- }
-
--static void redo_buddy_list(GaimBuddyList *list, gboolean remove)
-+static void redo_buddy_list(Gaim2BuddyList *list, gboolean remove)
- {
-- GaimBlistNode *node = list->root;
-+ Gaim2BlistNode *node = list->root;
-
- while (node)
- {
- if (!GAIM_BLIST_NODE_IS_GROUP(node) && remove)
-- gaim_gtk_blist_hide_node(list, node);
-+ gaim2_gtk_blist_hide_node(list, node);
-
-- gaim_gtk_blist_update(list, node);
-- node = gaim_blist_node_next(node, FALSE);
-+ gaim2_gtk_blist_update(list, node);
-+ node = gaim2_blist_node_next(node, FALSE);
- }
- }
-
--void gaim_gtk_blist_refresh(GaimBuddyList *list)
-+void gaim2_gtk_blist_refresh(Gaim2BuddyList *list)
- {
- redo_buddy_list(list, FALSE);
- }
-
- void
--gaim_gtk_blist_update_refresh_timeout()
-+gaim2_gtk_blist_update_refresh_timeout()
- {
-- GaimBuddyList *blist;
-- GaimGtkBuddyList *gtkblist;
-+ Gaim2BuddyList *blist;
-+ Gaim2GtkBuddyList *gtkblist;
-
-- blist = gaim_get_blist();
-- gtkblist = GAIM_GTK_BLIST(gaim_get_blist());
-+ blist = gaim2_get_blist();
-+ gtkblist = GAIM_GTK_BLIST(gaim2_get_blist());
-
-- gtkblist->refresh_timer = g_timeout_add(30000,(GSourceFunc)gaim_gtk_blist_refresh_timer, blist);
-+ gtkblist->refresh_timer = g_timeout_add(30000,(GSourceFunc)gaim2_gtk_blist_refresh_timer, blist);
- }
-
--static gboolean get_iter_from_node(GaimBlistNode *node, GtkTreeIter *iter) {
-- struct _gaim_gtk_blist_node *gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+static gboolean get_iter_from_node(Gaim2BlistNode *node, GtkTreeIter *iter) {
-+ struct _gaim2_gtk_blist_node *gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
- GtkTreePath *path;
-
- if (!gtknode) {
-@@ -3791,7 +3791,7 @@ static gboolean get_iter_from_node(GaimB
- }
-
- if (!gtkblist) {
-- gaim_debug_error("gtkblist", "get_iter_from_node was called, but we don't seem to have a blist\n");
-+ gaim2_debug_error("gtkblist", "get_iter_from_node was called, but we don't seem to have a blist\n");
- return FALSE;
- }
-
-@@ -3810,16 +3810,16 @@ static gboolean get_iter_from_node(GaimB
- return TRUE;
- }
-
--static void gaim_gtk_blist_remove(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_remove(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
-- struct _gaim_gtk_blist_node *gtknode = node->ui_data;
-+ struct _gaim2_gtk_blist_node *gtknode = node->ui_data;
-
-- gaim_request_close_with_handle(node);
-+ gaim2_request_close_with_handle(node);
-
-- gaim_gtk_blist_hide_node(list, node);
-+ gaim2_gtk_blist_hide_node(list, node);
-
- if(node->parent)
-- gaim_gtk_blist_update(list, node->parent);
-+ gaim2_gtk_blist_update(list, node->parent);
-
- /* There's something I don't understand here - Ethan */
- /* Ethan said that back in 2003, but this g_free has been left commented
-@@ -3832,33 +3832,33 @@ static void gaim_gtk_blist_remove(GaimBu
-
- if(gtknode) {
- if(gtknode->recent_signonoff_timer > 0)
-- gaim_timeout_remove(gtknode->recent_signonoff_timer);
-+ gaim2_timeout_remove(gtknode->recent_signonoff_timer);
-
- g_free(node->ui_data);
- node->ui_data = NULL;
- }
- }
-
--static gboolean do_selection_changed(GaimBlistNode *new_selection)
-+static gboolean do_selection_changed(Gaim2BlistNode *new_selection)
- {
-- GaimBlistNode *old_selection = NULL;
-+ Gaim2BlistNode *old_selection = NULL;
-
- /* test for gtkblist because crazy timeout means we can be called after the blist is gone */
- if (gtkblist && new_selection != gtkblist->selected_node) {
- old_selection = gtkblist->selected_node;
- gtkblist->selected_node = new_selection;
- if(new_selection)
-- gaim_gtk_blist_update(NULL, new_selection);
-+ gaim2_gtk_blist_update(NULL, new_selection);
- if(old_selection)
-- gaim_gtk_blist_update(NULL, old_selection);
-+ gaim2_gtk_blist_update(NULL, old_selection);
- }
-
- return FALSE;
- }
-
--static void gaim_gtk_blist_selection_changed(GtkTreeSelection *selection, gpointer data)
-+static void gaim2_gtk_blist_selection_changed(GtkTreeSelection *selection, gpointer data)
- {
-- GaimBlistNode *new_selection = NULL;
-+ Gaim2BlistNode *new_selection = NULL;
- GtkTreeIter iter;
-
- if(gtk_tree_selection_get_selected(selection, NULL, &iter)){
-@@ -3870,10 +3870,10 @@ static void gaim_gtk_blist_selection_cha
- g_timeout_add(0, (GSourceFunc)do_selection_changed, new_selection);
- }
-
--static gboolean insert_node(GaimBuddyList *list, GaimBlistNode *node, GtkTreeIter *iter)
-+static gboolean insert_node(Gaim2BuddyList *list, Gaim2BlistNode *node, GtkTreeIter *iter)
- {
- GtkTreeIter parent_iter, cur, *curptr = NULL;
-- struct _gaim_gtk_blist_node *gtknode = node->ui_data;
-+ struct _gaim2_gtk_blist_node *gtknode = node->ui_data;
- GtkTreePath *newpath;
-
- if(!iter)
-@@ -3894,8 +3894,8 @@ static gboolean insert_node(GaimBuddyLis
- if(gtknode != NULL) {
- gtk_tree_row_reference_free(gtknode->row);
- } else {
-- gaim_gtk_blist_new_node(node);
-- gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ gaim2_gtk_blist_new_node(node);
-+ gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
- }
-
- newpath = gtk_tree_model_get_path(GTK_TREE_MODEL(gtkblist->treemodel),
-@@ -3912,10 +3912,10 @@ static gboolean insert_node(GaimBuddyLis
-
- if(node->parent) {
- GtkTreePath *expand = NULL;
-- struct _gaim_gtk_blist_node *gtkparentnode = node->parent->ui_data;
-+ struct _gaim2_gtk_blist_node *gtkparentnode = node->parent->ui_data;
-
- if(GAIM_BLIST_NODE_IS_GROUP(node->parent)) {
-- if(!gaim_blist_node_get_bool(node->parent, "collapsed"))
-+ if(!gaim2_blist_node_get_bool(node->parent, "collapsed"))
- expand = gtk_tree_model_get_path(GTK_TREE_MODEL(gtkblist->treemodel), &parent_iter);
- } else if(GAIM_BLIST_NODE_IS_CONTACT(node->parent) &&
- gtkparentnode->contact_expanded) {
-@@ -3930,34 +3930,34 @@ static gboolean insert_node(GaimBuddyLis
- return TRUE;
- }
-
--static void gaim_gtk_blist_update_group(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_update_group(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
-- GaimGroup *group;
-+ Gaim2Group *group;
- int count;
- gboolean show = FALSE;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_GROUP(node));
-
-- group = (GaimGroup*)node;
-+ group = (Gaim2Group*)node;
-
-- if(gaim_prefs_get_bool("/gaim/gtk/blist/show_offline_buddies"))
-- count = gaim_blist_get_group_size(group, FALSE);
-+ if(gaim2_prefs_get_bool("/gaim2/gtk/blist/show_offline_buddies"))
-+ count = gaim2_blist_get_group_size(group, FALSE);
- else
-- count = gaim_blist_get_group_online_count(group);
-+ count = gaim2_blist_get_group_online_count(group);
-
-- if (count > 0 || gaim_prefs_get_bool("/gaim/gtk/blist/show_empty_groups"))
-+ if (count > 0 || gaim2_prefs_get_bool("/gaim2/gtk/blist/show_empty_groups"))
- show = TRUE;
- else {
-- GaimBlistNode *n;
-+ Gaim2BlistNode *n;
- n = node->child;
- while (n && !GAIM_BLIST_NODE_IS_GROUP(n)) {
- if (GAIM_BLIST_NODE_IS_BUDDY(n)) {
-- if (buddy_is_displayable((GaimBuddy*)n)) {
-+ if (buddy_is_displayable((Gaim2Buddy*)n)) {
- show = TRUE;
- break;
- }
- }
-- n = gaim_blist_node_next(n, FALSE);
-+ n = gaim2_blist_node_next(n, FALSE);
- }
- }
-
-@@ -3970,8 +3970,8 @@ static void gaim_gtk_blist_update_group(
-
- esc = g_markup_escape_text(group->name, -1);
- mark = g_strdup_printf("<span weight='bold'>%s</span> (%d/%d)",
-- esc, gaim_blist_get_group_online_count(group),
-- gaim_blist_get_group_size(group, FALSE));
-+ esc, gaim2_blist_get_group_online_count(group),
-+ gaim2_blist_get_group_size(group, FALSE));
- g_free(esc);
-
- gtk_tree_store_set(gtkblist->treemodel, &iter,
-@@ -3982,31 +3982,31 @@ static void gaim_gtk_blist_update_group(
- -1);
- g_free(mark);
- } else {
-- gaim_gtk_blist_hide_node(list, node);
-+ gaim2_gtk_blist_hide_node(list, node);
- }
- }
-
--static void buddy_node(GaimBuddy *buddy, GtkTreeIter *iter, GaimBlistNode *node)
-+static void buddy_node(Gaim2Buddy *buddy, GtkTreeIter *iter, Gaim2BlistNode *node)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- GdkPixbuf *status, *avatar;
- char *mark;
- char *idle = NULL;
- gboolean selected = (gtkblist->selected_node == node);
-
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
-- status = gaim_gtk_blist_get_status_icon((GaimBlistNode*)buddy,
-- (gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons")
-+ status = gaim2_gtk_blist_get_status_icon((Gaim2BlistNode*)buddy,
-+ (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons")
- ? GAIM_STATUS_ICON_LARGE : GAIM_STATUS_ICON_SMALL));
-
-- avatar = gaim_gtk_blist_get_buddy_icon((GaimBlistNode *)buddy, TRUE, TRUE);
-- mark = gaim_gtk_blist_get_name_markup(buddy, selected);
-+ avatar = gaim2_gtk_blist_get_buddy_icon((Gaim2BlistNode *)buddy, TRUE, TRUE);
-+ mark = gaim2_gtk_blist_get_name_markup(buddy, selected);
-
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/show_idle_time") &&
-- gaim_presence_is_idle(presence))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_idle_time") &&
-+ gaim2_presence_is_idle(presence))
- {
-- time_t idle_secs = gaim_presence_get_idle_time(presence);
-+ time_t idle_secs = gaim2_presence_get_idle_time(presence);
-
- if (idle_secs > 0)
- {
-@@ -4023,7 +4023,7 @@ static void buddy_node(GaimBuddy *buddy,
- }
- }
-
-- if (gaim_presence_is_idle(presence))
-+ if (gaim2_presence_is_idle(presence))
- {
- if (idle && !selected) {
- char *i2 = g_strdup_printf("<span color='%s'>%s</span>",
-@@ -4050,19 +4050,19 @@ static void buddy_node(GaimBuddy *buddy,
- }
-
-
--static void gaim_gtk_blist_update_contact(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_update_contact(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
-- GaimContact *contact;
-- GaimBuddy *buddy;
-- struct _gaim_gtk_blist_node *gtknode;
-+ Gaim2Contact *contact;
-+ Gaim2Buddy *buddy;
-+ struct _gaim2_gtk_blist_node *gtknode;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CONTACT(node));
-
- /* First things first, update the group */
-- gaim_gtk_blist_update_group(list, node->parent);
-+ gaim2_gtk_blist_update_group(list, node->parent);
-
-- contact = (GaimContact*)node;
-- buddy = gaim_contact_get_priority_buddy(contact);
-+ contact = (Gaim2Contact*)node;
-+ buddy = gaim2_contact_get_priority_buddy(contact);
-
- if (buddy_is_displayable(buddy))
- {
-@@ -4071,17 +4071,17 @@ static void gaim_gtk_blist_update_contac
- if(!insert_node(list, node, &iter))
- return;
-
-- gtknode = (struct _gaim_gtk_blist_node *)node->ui_data;
-+ gtknode = (struct _gaim2_gtk_blist_node *)node->ui_data;
-
- if(gtknode->contact_expanded) {
- GdkPixbuf *status;
- char *mark;
-
-- status = gaim_gtk_blist_get_status_icon(node,
-- (gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons") ?
-+ status = gaim2_gtk_blist_get_status_icon(node,
-+ (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons") ?
- GAIM_STATUS_ICON_LARGE : GAIM_STATUS_ICON_SMALL));
-
-- mark = g_markup_escape_text(gaim_contact_get_alias(contact), -1);
-+ mark = g_markup_escape_text(gaim2_contact_get_alias(contact), -1);
-
- gtk_tree_store_set(gtkblist->treemodel, &iter,
- STATUS_ICON_COLUMN, status,
-@@ -4097,28 +4097,28 @@ static void gaim_gtk_blist_update_contac
- buddy_node(buddy, &iter, node);
- }
- } else {
-- gaim_gtk_blist_hide_node(list, node);
-+ gaim2_gtk_blist_hide_node(list, node);
- }
- }
-
--static void gaim_gtk_blist_update_buddy(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_update_buddy(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
-- GaimContact *contact;
-- GaimBuddy *buddy;
-- struct _gaim_gtk_blist_node *gtkparentnode;
-+ Gaim2Contact *contact;
-+ Gaim2Buddy *buddy;
-+ struct _gaim2_gtk_blist_node *gtkparentnode;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy*)node;
-- contact = (GaimContact*)node->parent;
-+ buddy = (Gaim2Buddy*)node;
-+ contact = (Gaim2Contact*)node->parent;
-
- if (contact == NULL)
- return;
-
- /* First things first, update the contact */
-- gaim_gtk_blist_update_contact(list, node->parent);
-+ gaim2_gtk_blist_update_contact(list, node->parent);
-
-- gtkparentnode = (struct _gaim_gtk_blist_node *)node->parent->ui_data;
-+ gtkparentnode = (struct _gaim2_gtk_blist_node *)node->parent->ui_data;
-
- if (gtkparentnode->contact_expanded && buddy_is_displayable(buddy))
- {
-@@ -4130,23 +4130,23 @@ static void gaim_gtk_blist_update_buddy(
- buddy_node(buddy, &iter, node);
-
- } else {
-- gaim_gtk_blist_hide_node(list, node);
-+ gaim2_gtk_blist_hide_node(list, node);
- }
-
- }
-
--static void gaim_gtk_blist_update_chat(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_update_chat(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
-- GaimChat *chat;
-+ Gaim2Chat *chat;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
- /* First things first, update the group */
-- gaim_gtk_blist_update_group(list, node->parent);
-+ gaim2_gtk_blist_update_group(list, node->parent);
-
-- chat = (GaimChat*)node;
-+ chat = (Gaim2Chat*)node;
-
-- if(gaim_account_is_connected(chat->account)) {
-+ if(gaim2_account_is_connected(chat->account)) {
- GtkTreeIter iter;
- GdkPixbuf *status;
- char *mark;
-@@ -4154,11 +4154,11 @@ static void gaim_gtk_blist_update_chat(G
- if(!insert_node(list, node, &iter))
- return;
-
-- status = gaim_gtk_blist_get_status_icon(node,
-- (gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons") ?
-+ status = gaim2_gtk_blist_get_status_icon(node,
-+ (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons") ?
- GAIM_STATUS_ICON_LARGE : GAIM_STATUS_ICON_SMALL));
-
-- mark = g_markup_escape_text(gaim_chat_get_name(chat), -1);
-+ mark = g_markup_escape_text(gaim2_chat_get_name(chat), -1);
-
- gtk_tree_store_set(gtkblist->treemodel, &iter,
- STATUS_ICON_COLUMN, status,
-@@ -4170,27 +4170,27 @@ static void gaim_gtk_blist_update_chat(G
- if(status)
- g_object_unref(status);
- } else {
-- gaim_gtk_blist_hide_node(list, node);
-+ gaim2_gtk_blist_hide_node(list, node);
- }
- }
-
--static void gaim_gtk_blist_update(GaimBuddyList *list, GaimBlistNode *node)
-+static void gaim2_gtk_blist_update(Gaim2BuddyList *list, Gaim2BlistNode *node)
- {
- if(!gtkblist)
- return;
-
- switch(node->type) {
- case GAIM_BLIST_GROUP_NODE:
-- gaim_gtk_blist_update_group(list, node);
-+ gaim2_gtk_blist_update_group(list, node);
- break;
- case GAIM_BLIST_CONTACT_NODE:
-- gaim_gtk_blist_update_contact(list, node);
-+ gaim2_gtk_blist_update_contact(list, node);
- break;
- case GAIM_BLIST_BUDDY_NODE:
-- gaim_gtk_blist_update_buddy(list, node);
-+ gaim2_gtk_blist_update_buddy(list, node);
- break;
- case GAIM_BLIST_CHAT_NODE:
-- gaim_gtk_blist_update_chat(list, node);
-+ gaim2_gtk_blist_update_chat(list, node);
- break;
- case GAIM_BLIST_OTHER_NODE:
- return;
-@@ -4200,19 +4200,19 @@ static void gaim_gtk_blist_update(GaimBu
- }
-
-
--static void gaim_gtk_blist_destroy(GaimBuddyList *list)
-+static void gaim2_gtk_blist_destroy(Gaim2BuddyList *list)
- {
- if (!gtkblist)
- return;
-
-- gaim_signal_disconnect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_disconnect(gaim2_connections_get_handle(), "signed-on",
- gtkblist, GAIM_CALLBACK(sign_on_off_cb));
-- gaim_signal_disconnect(gaim_connections_get_handle(), "signed-off",
-+ gaim2_signal_disconnect(gaim2_connections_get_handle(), "signed-off",
- gtkblist, GAIM_CALLBACK(sign_on_off_cb));
-
- gtk_widget_destroy(gtkblist->window);
-
-- gaim_gtk_blist_tooltip_destroy();
-+ gaim2_gtk_blist_tooltip_destroy();
-
- if (gtkblist->refresh_timer)
- g_source_remove(gtkblist->refresh_timer);
-@@ -4232,22 +4232,22 @@ static void gaim_gtk_blist_destroy(GaimB
- accountmenu = NULL;
- gtkblist = NULL;
-
-- gaim_prefs_disconnect_by_handle(gaim_gtk_blist_get_handle());
-+ gaim2_prefs_disconnect_by_handle(gaim2_gtk_blist_get_handle());
- }
-
--static void gaim_gtk_blist_set_visible(GaimBuddyList *list, gboolean show)
-+static void gaim2_gtk_blist_set_visible(Gaim2BuddyList *list, gboolean show)
- {
- if (!(gtkblist && gtkblist->window))
- return;
-
- if (show) {
- if(!GAIM_WINDOW_ICONIFIED(gtkblist->window) && !GTK_WIDGET_VISIBLE(gtkblist->window))
-- gaim_signal_emit(gaim_gtk_blist_get_handle(), "gtkblist-unhiding", gtkblist);
-- gaim_gtk_blist_restore_position();
-+ gaim2_signal_emit(gaim2_gtk_blist_get_handle(), "gtkblist-unhiding", gtkblist);
-+ gaim2_gtk_blist_restore_position();
- gtk_window_present(GTK_WINDOW(gtkblist->window));
- } else {
- if(visibility_manager_count) {
-- gaim_signal_emit(gaim_gtk_blist_get_handle(), "gtkblist-hiding", gtkblist);
-+ gaim2_signal_emit(gaim2_gtk_blist_get_handle(), "gtkblist-hiding", gtkblist);
- gtk_widget_hide(gtkblist->window);
- } else {
- if (!GTK_WIDGET_VISIBLE(gtkblist->window))
-@@ -4262,23 +4262,23 @@ groups_tree(void)
- {
- GList *tmp = NULL;
- char *tmp2;
-- GaimGroup *g;
-- GaimBlistNode *gnode;
-+ Gaim2Group *g;
-+ Gaim2BlistNode *gnode;
-
-- if (gaim_get_blist()->root == NULL)
-+ if (gaim2_get_blist()->root == NULL)
- {
- tmp2 = g_strdup(_("Buddies"));
- tmp = g_list_append(tmp, tmp2);
- }
- else
- {
-- for (gnode = gaim_get_blist()->root;
-+ for (gnode = gaim2_get_blist()->root;
- gnode != NULL;
- gnode = gnode->next)
- {
- if (GAIM_BLIST_NODE_IS_GROUP(gnode))
- {
-- g = (GaimGroup *)gnode;
-+ g = (Gaim2Group *)gnode;
- tmp2 = g->name;
- tmp = g_list_append(tmp, tmp2);
- }
-@@ -4289,26 +4289,26 @@ groups_tree(void)
- }
-
- static void
--add_buddy_select_account_cb(GObject *w, GaimAccount *account,
-- GaimGtkAddBuddyData *data)
-+add_buddy_select_account_cb(GObject *w, Gaim2Account *account,
-+ Gaim2GtkAddBuddyData *data)
- {
- /* Save our account */
- data->account = account;
- }
-
- static void
--destroy_add_buddy_dialog_cb(GtkWidget *win, GaimGtkAddBuddyData *data)
-+destroy_add_buddy_dialog_cb(GtkWidget *win, Gaim2GtkAddBuddyData *data)
- {
- g_free(data);
- }
-
- static void
--add_buddy_cb(GtkWidget *w, int resp, GaimGtkAddBuddyData *data)
-+add_buddy_cb(GtkWidget *w, int resp, Gaim2GtkAddBuddyData *data)
- {
- const char *grp, *who, *whoalias;
-- GaimConversation *c;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Conversation *c;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
-
- if (resp == GTK_RESPONSE_OK)
- {
-@@ -4318,35 +4318,35 @@ add_buddy_cb(GtkWidget *w, int resp, Gai
- if (*whoalias == '\0')
- whoalias = NULL;
-
-- if ((g = gaim_find_group(grp)) == NULL)
-+ if ((g = gaim2_find_group(grp)) == NULL)
- {
-- g = gaim_group_new(grp);
-- gaim_blist_add_group(g, NULL);
-+ g = gaim2_group_new(grp);
-+ gaim2_blist_add_group(g, NULL);
- }
-
-- b = gaim_buddy_new(data->account, who, whoalias);
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-- gaim_account_add_buddy(data->account, b);
-+ b = gaim2_buddy_new(data->account, who, whoalias);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
-+ gaim2_account_add_buddy(data->account, b);
-
- /*
- * XXX
- * It really seems like it would be better if the call to
-- * gaim_account_add_buddy() and gaim_conversation_update() were done in
-- * blist.c, possibly in the gaim_blist_add_buddy() function. Maybe
-- * gaim_account_add_buddy() should be renamed to
-- * gaim_blist_add_new_buddy() or something, and have it call
-- * gaim_blist_add_buddy() after it creates it. --Mark
-+ * gaim2_account_add_buddy() and gaim2_conversation_update() were done in
-+ * blist.c, possibly in the gaim2_blist_add_buddy() function. Maybe
-+ * gaim2_account_add_buddy() should be renamed to
-+ * gaim2_blist_add_new_buddy() or something, and have it call
-+ * gaim2_blist_add_buddy() after it creates it. --Mark
- *
- * No that's not good. blist.c should only deal with adding nodes to the
- * local list. We need a new, non-gtk file that calls both
-- * gaim_account_add_buddy and gaim_blist_add_buddy().
-+ * gaim2_account_add_buddy and gaim2_blist_add_buddy().
- * Or something. --Mark
- */
-
-- c = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, data->account);
-+ c = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, data->account);
- if (c != NULL) {
-- gaim_buddy_icon_update(gaim_conv_im_get_icon(GAIM_CONV_IM(c)));
-- gaim_conversation_update(c, GAIM_CONV_UPDATE_ADD);
-+ gaim2_buddy_icon_update(gaim2_conv_im_get_icon(GAIM_CONV_IM(c)));
-+ gaim2_conversation_update(c, GAIM_CONV_UPDATE_ADD);
- }
- }
-
-@@ -4354,7 +4354,7 @@ add_buddy_cb(GtkWidget *w, int resp, Gai
- }
-
- static void
--gaim_gtk_blist_request_add_buddy(GaimAccount *account, const char *username,
-+gaim2_gtk_blist_request_add_buddy(Gaim2Account *account, const char *username,
- const char *group, const char *alias)
- {
- GtkWidget *table;
-@@ -4362,18 +4362,18 @@ gaim_gtk_blist_request_add_buddy(GaimAcc
- GtkWidget *hbox;
- GtkWidget *vbox;
- GtkWidget *img;
-- GaimGtkBuddyList *gtkblist;
-- GaimGtkAddBuddyData *data = g_new0(GaimGtkAddBuddyData, 1);
-+ Gaim2GtkBuddyList *gtkblist;
-+ Gaim2GtkAddBuddyData *data = g_new0(Gaim2GtkAddBuddyData, 1);
-
- data->account =
- (account != NULL
- ? account
-- : gaim_connection_get_account(gaim_connections_get_all()->data));
-+ : gaim2_connection_get_account(gaim2_connections_get_all()->data));
-
- img = gtk_image_new_from_stock(GAIM_STOCK_DIALOG_QUESTION,
- GTK_ICON_SIZE_DIALOG);
-
-- gtkblist = GAIM_GTK_BLIST(gaim_get_blist());
-+ gtkblist = GAIM_GTK_BLIST(gaim2_get_blist());
-
- data->window = gtk_dialog_new_with_buttons(_("Add Buddy"),
- NULL, GTK_DIALOG_NO_SEPARATOR,
-@@ -4436,10 +4436,10 @@ gaim_gtk_blist_request_add_buddy(GaimAcc
- GTK_RESPONSE_OK, FALSE);
-
- gtk_entry_set_activates_default (GTK_ENTRY(data->entry), TRUE);
-- gaim_set_accessible_label (data->entry, label);
-+ gaim2_set_accessible_label (data->entry, label);
-
- g_signal_connect(G_OBJECT(data->entry), "changed",
-- G_CALLBACK(gaim_gtk_set_sensitive_if_input),
-+ G_CALLBACK(gaim2_gtk_set_sensitive_if_input),
- data->window);
-
- label = gtk_label_new(_("Alias:"));
-@@ -4457,7 +4457,7 @@ gaim_gtk_blist_request_add_buddy(GaimAcc
- gtk_widget_grab_focus(GTK_WIDGET(data->entry_for_alias));
-
- gtk_entry_set_activates_default (GTK_ENTRY(data->entry_for_alias), TRUE);
-- gaim_set_accessible_label (data->entry_for_alias, label);
-+ gaim2_set_accessible_label (data->entry_for_alias, label);
-
- label = gtk_label_new(_("Group:"));
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
-@@ -4466,18 +4466,18 @@ gaim_gtk_blist_request_add_buddy(GaimAcc
- data->combo = gtk_combo_new();
- gtk_combo_set_popdown_strings(GTK_COMBO(data->combo), groups_tree());
- gtk_table_attach_defaults(GTK_TABLE(table), data->combo, 1, 2, 2, 3);
-- gaim_set_accessible_label (data->combo, label);
-+ gaim2_set_accessible_label (data->combo, label);
-
- /* Set up stuff for the account box */
- label = gtk_label_new(_("Account:"));
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
- gtk_table_attach_defaults(GTK_TABLE(table), label, 0, 1, 3, 4);
-
-- data->account_box = gaim_gtk_account_option_menu_new(account, FALSE,
-+ data->account_box = gaim2_gtk_account_option_menu_new(account, FALSE,
- G_CALLBACK(add_buddy_select_account_cb), NULL, data);
-
- gtk_table_attach_defaults(GTK_TABLE(table), data->account_box, 1, 2, 3, 4);
-- gaim_set_accessible_label (data->account_box, label);
-+ gaim2_set_accessible_label (data->account_box, label);
- /* End of account box */
-
- g_signal_connect(G_OBJECT(data->window), "response",
-@@ -4490,15 +4490,15 @@ gaim_gtk_blist_request_add_buddy(GaimAcc
- }
-
- static void
--add_chat_cb(GtkWidget *w, GaimGtkAddChatData *data)
-+add_chat_cb(GtkWidget *w, Gaim2GtkAddChatData *data)
- {
- GHashTable *components;
- GList *tmp;
-- GaimChat *chat;
-- GaimGroup *group;
-+ Gaim2Chat *chat;
-+ Gaim2Group *group;
- const char *group_name;
- char *chat_name = NULL;
-- GaimConversation *conv = NULL;
-+ Gaim2Conversation *conv = NULL;
- const char *value;
-
- components = g_hash_table_new_full(g_str_hash, g_str_equal,
-@@ -4523,35 +4523,35 @@ add_chat_cb(GtkWidget *w, GaimGtkAddChat
- }
- }
-
-- chat = gaim_chat_new(data->account,
-+ chat = gaim2_chat_new(data->account,
- gtk_entry_get_text(GTK_ENTRY(data->alias_entry)),
- components);
-
- group_name = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(data->group_combo)->entry));
-
-- if ((group = gaim_find_group(group_name)) == NULL)
-+ if ((group = gaim2_find_group(group_name)) == NULL)
- {
-- group = gaim_group_new(group_name);
-- gaim_blist_add_group(group, NULL);
-+ group = gaim2_group_new(group_name);
-+ gaim2_blist_add_group(group, NULL);
- }
-
- if (chat != NULL)
- {
-- gaim_blist_add_chat(chat, group, NULL);
-+ gaim2_blist_add_chat(chat, group, NULL);
-
- if (GAIM_PLUGIN_PROTOCOL_INFO(data->account->gc->prpl)->get_chat_name != NULL)
- chat_name = GAIM_PLUGIN_PROTOCOL_INFO(
- data->account->gc->prpl)->get_chat_name(chat->components);
-
- if (chat_name != NULL) {
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chat_name,
- data->account);
- g_free(chat_name);
- }
-
- if (conv != NULL)
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_ADD);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_ADD);
- }
-
- gtk_widget_destroy(data->window);
-@@ -4561,7 +4561,7 @@ add_chat_cb(GtkWidget *w, GaimGtkAddChat
- }
-
- static void
--add_chat_resp_cb(GtkWidget *w, int resp, GaimGtkAddChatData *data)
-+add_chat_resp_cb(GtkWidget *w, int resp, Gaim2GtkAddChatData *data)
- {
- if (resp == GTK_RESPONSE_OK)
- {
-@@ -4583,7 +4583,7 @@ add_chat_resp_cb(GtkWidget *w, int resp,
- static void
- addchat_set_sensitive_if_input_cb(GtkWidget *entry, gpointer user_data)
- {
-- GaimGtkAddChatData *data;
-+ Gaim2GtkAddChatData *data;
- GList *tmp;
- const char *text;
- gboolean required;
-@@ -4606,9 +4606,9 @@ addchat_set_sensitive_if_input_cb(GtkWid
- }
-
- static void
--rebuild_addchat_entries(GaimGtkAddChatData *data)
-+rebuild_addchat_entries(Gaim2GtkAddChatData *data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GList *list = NULL, *tmp = NULL;
- GHashTable *defaults = NULL;
- struct proto_chat_entry *pce;
-@@ -4616,7 +4616,7 @@ rebuild_addchat_entries(GaimGtkAddChatDa
-
- g_return_if_fail(data->account != NULL);
-
-- gc = gaim_account_get_connection(data->account);
-+ gc = gaim2_account_get_connection(data->account);
-
- while (GTK_BOX(data->entries_box)->children)
- {
-@@ -4685,7 +4685,7 @@ rebuild_addchat_entries(GaimGtkAddChatDa
- focus = FALSE;
- }
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), input);
-- gaim_set_accessible_label(input, label);
-+ gaim2_set_accessible_label(input, label);
- g_object_set_data(G_OBJECT(input), "identifier", pce->identifier);
- g_object_set_data(G_OBJECT(input), "is_spin", GINT_TO_POINTER(pce->is_int));
- g_object_set_data(G_OBJECT(input), "required", GINT_TO_POINTER(pce->required));
-@@ -4704,11 +4704,11 @@ rebuild_addchat_entries(GaimGtkAddChatDa
- }
-
- static void
--addchat_select_account_cb(GObject *w, GaimAccount *account,
-- GaimGtkAddChatData *data)
-+addchat_select_account_cb(GObject *w, Gaim2Account *account,
-+ Gaim2GtkAddChatData *data)
- {
-- if (strcmp(gaim_account_get_protocol_id(data->account),
-- gaim_account_get_protocol_id(account)) == 0)
-+ if (strcmp(gaim2_account_get_protocol_id(data->account),
-+ gaim2_account_get_protocol_id(account)) == 0)
- {
- data->account = account;
- }
-@@ -4720,13 +4720,13 @@ addchat_select_account_cb(GObject *w, Ga
- }
-
- static void
--gaim_gtk_blist_request_add_chat(GaimAccount *account, GaimGroup *group,
-+gaim2_gtk_blist_request_add_chat(Gaim2Account *account, Gaim2Group *group,
- const char *alias, const char *name)
- {
-- GaimGtkAddChatData *data;
-- GaimGtkBuddyList *gtkblist;
-+ Gaim2GtkAddChatData *data;
-+ Gaim2GtkBuddyList *gtkblist;
- GList *l;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GtkWidget *label;
- GtkWidget *rowbox;
- GtkWidget *hbox;
-@@ -4734,39 +4734,39 @@ gaim_gtk_blist_request_add_chat(GaimAcco
- GtkWidget *img;
-
- if (account != NULL) {
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)->join_chat == NULL) {
-- gaim_notify_error(gc, NULL, _("This protocol does not support chat rooms."), NULL);
-+ gaim2_notify_error(gc, NULL, _("This protocol does not support chat rooms."), NULL);
- return;
- }
- } else {
- /* Find an account with chat capabilities */
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next) {
-- gc = (GaimConnection *)l->data;
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next) {
-+ gc = (Gaim2Connection *)l->data;
-
- if (GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)->join_chat != NULL) {
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- break;
- }
- }
-
- if (account == NULL) {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("You are not currently signed on with any "
- "protocols that have the ability to chat."), NULL);
- return;
- }
- }
-
-- data = g_new0(GaimGtkAddChatData, 1);
-+ data = g_new0(Gaim2GtkAddChatData, 1);
- data->account = account;
- data->default_chat_name = g_strdup(name);
-
- img = gtk_image_new_from_stock(GAIM_STOCK_DIALOG_QUESTION,
- GTK_ICON_SIZE_DIALOG);
-
-- gtkblist = GAIM_GTK_BLIST(gaim_get_blist());
-+ gtkblist = GAIM_GTK_BLIST(gaim2_get_blist());
-
- data->sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
-@@ -4809,11 +4809,11 @@ gaim_gtk_blist_request_add_chat(GaimAcco
- gtk_size_group_add_widget(data->sg, label);
- gtk_box_pack_start(GTK_BOX(rowbox), label, FALSE, FALSE, 0);
-
-- data->account_menu = gaim_gtk_account_option_menu_new(account, FALSE,
-+ data->account_menu = gaim2_gtk_account_option_menu_new(account, FALSE,
- G_CALLBACK(addchat_select_account_cb),
- chat_account_filter_func, data);
- gtk_box_pack_start(GTK_BOX(rowbox), data->account_menu, TRUE, TRUE, 0);
-- gaim_set_accessible_label (data->account_menu, label);
-+ gaim2_set_accessible_label (data->account_menu, label);
-
- data->entries_box = gtk_vbox_new(FALSE, 5);
- gtk_container_set_border_width(GTK_CONTAINER(data->entries_box), 0);
-@@ -4834,7 +4834,7 @@ gaim_gtk_blist_request_add_chat(GaimAcco
- gtk_entry_set_text(GTK_ENTRY(data->alias_entry), alias);
- gtk_box_pack_end(GTK_BOX(rowbox), data->alias_entry, TRUE, TRUE, 0);
- gtk_entry_set_activates_default(GTK_ENTRY(data->alias_entry), TRUE);
-- gaim_set_accessible_label (data->alias_entry, label);
-+ gaim2_set_accessible_label (data->alias_entry, label);
-
- rowbox = gtk_hbox_new(FALSE, 5);
- gtk_box_pack_start(GTK_BOX(vbox), rowbox, FALSE, FALSE, 0);
-@@ -4853,7 +4853,7 @@ gaim_gtk_blist_request_add_chat(GaimAcco
- gtk_entry_set_text(GTK_ENTRY(GTK_COMBO(data->group_combo)->entry),
- group->name);
- }
-- gaim_set_accessible_label (data->group_combo, label);
-+ gaim2_set_accessible_label (data->group_combo, label);
-
- g_signal_connect(G_OBJECT(data->window), "response",
- G_CALLBACK(add_chat_resp_cb), data);
-@@ -4862,21 +4862,21 @@ gaim_gtk_blist_request_add_chat(GaimAcco
- }
-
- static void
--add_group_cb(GaimConnection *gc, const char *group_name)
-+add_group_cb(Gaim2Connection *gc, const char *group_name)
- {
-- GaimGroup *group;
-+ Gaim2Group *group;
-
- if ((group_name == NULL) || (*group_name == '\0'))
- return;
-
-- group = gaim_group_new(group_name);
-- gaim_blist_add_group(group, NULL);
-+ group = gaim2_group_new(group_name);
-+ gaim2_blist_add_group(group, NULL);
- }
-
- static void
--gaim_gtk_blist_request_add_group(void)
-+gaim2_gtk_blist_request_add_group(void)
- {
-- gaim_request_input(NULL, _("Add Group"), NULL,
-+ gaim2_request_input(NULL, _("Add Group"), NULL,
- _("Please enter the name of the group to be added."),
- NULL, FALSE, FALSE, NULL,
- _("Add"), G_CALLBACK(add_group_cb),
-@@ -4884,83 +4884,83 @@ gaim_gtk_blist_request_add_group(void)
- }
-
- void
--gaim_gtk_blist_toggle_visibility()
-+gaim2_gtk_blist_toggle_visibility()
- {
- if (gtkblist && gtkblist->window) {
- if (GTK_WIDGET_VISIBLE(gtkblist->window)) {
-- gaim_blist_set_visible(GAIM_WINDOW_ICONIFIED(gtkblist->window) || gtk_blist_obscured);
-+ gaim2_blist_set_visible(GAIM_WINDOW_ICONIFIED(gtkblist->window) || gtk_blist_obscured);
- } else {
-- gaim_blist_set_visible(TRUE);
-+ gaim2_blist_set_visible(TRUE);
- }
- }
- }
-
- void
--gaim_gtk_blist_visibility_manager_add()
-+gaim2_gtk_blist_visibility_manager_add()
- {
- visibility_manager_count++;
-- gaim_debug_info("gtkblist", "added visibility manager: %d\n", visibility_manager_count);
-+ gaim2_debug_info("gtkblist", "added visibility manager: %d\n", visibility_manager_count);
- }
-
- void
--gaim_gtk_blist_visibility_manager_remove()
-+gaim2_gtk_blist_visibility_manager_remove()
- {
- if (visibility_manager_count)
- visibility_manager_count--;
- if (!visibility_manager_count)
-- gaim_blist_set_visible(gaim_prefs_get_bool("/gaim/gtk/blist/list_visible"));
-- gaim_debug_info("gtkblist", "removed visibility manager: %d\n", visibility_manager_count);
-+ gaim2_blist_set_visible(gaim2_prefs_get_bool("/gaim2/gtk/blist/list_visible"));
-+ gaim2_debug_info("gtkblist", "removed visibility manager: %d\n", visibility_manager_count);
- }
-
-
--static GaimBlistUiOps blist_ui_ops =
-+static Gaim2BlistUiOps blist_ui_ops =
- {
-- gaim_gtk_blist_new_list,
-- gaim_gtk_blist_new_node,
-- gaim_gtk_blist_show,
-- gaim_gtk_blist_update,
-- gaim_gtk_blist_remove,
-- gaim_gtk_blist_destroy,
-- gaim_gtk_blist_set_visible,
-- gaim_gtk_blist_request_add_buddy,
-- gaim_gtk_blist_request_add_chat,
-- gaim_gtk_blist_request_add_group
-+ gaim2_gtk_blist_new_list,
-+ gaim2_gtk_blist_new_node,
-+ gaim2_gtk_blist_show,
-+ gaim2_gtk_blist_update,
-+ gaim2_gtk_blist_remove,
-+ gaim2_gtk_blist_destroy,
-+ gaim2_gtk_blist_set_visible,
-+ gaim2_gtk_blist_request_add_buddy,
-+ gaim2_gtk_blist_request_add_chat,
-+ gaim2_gtk_blist_request_add_group
- };
-
-
--GaimBlistUiOps *
--gaim_gtk_blist_get_ui_ops(void)
-+Gaim2BlistUiOps *
-+gaim2_gtk_blist_get_ui_ops(void)
- {
- return &blist_ui_ops;
- }
-
--GaimGtkBuddyList *gaim_gtk_blist_get_default_gtk_blist()
-+Gaim2GtkBuddyList *gaim2_gtk_blist_get_default_gtk_blist()
- {
- return gtkblist;
- }
-
--static void account_signon_cb(GaimConnection *gc, gpointer z)
-+static void account_signon_cb(Gaim2Connection *gc, gpointer z)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimBlistNode *gnode, *cnode;
-- for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next)
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2BlistNode *gnode, *cnode;
-+ for(gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next)
- {
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for(cnode = gnode->child; cnode; cnode = cnode->next)
- {
-- GaimChat *chat;
-+ Gaim2Chat *chat;
-
- if(!GAIM_BLIST_NODE_IS_CHAT(cnode))
- continue;
-
-- chat = (GaimChat *)cnode;
-+ chat = (Gaim2Chat *)cnode;
-
- if(chat->account != account)
- continue;
-
-- if(gaim_blist_node_get_bool((GaimBlistNode*)chat, "gtk-autojoin") ||
-- (gaim_blist_node_get_string((GaimBlistNode*)chat,
-+ if(gaim2_blist_node_get_bool((Gaim2BlistNode*)chat, "gtk-autojoin") ||
-+ (gaim2_blist_node_get_string((Gaim2BlistNode*)chat,
- "gtk-autojoin") != NULL))
- serv_join_chat(gc, chat->components);
- }
-@@ -4968,155 +4968,155 @@ static void account_signon_cb(GaimConnec
- }
-
- void *
--gaim_gtk_blist_get_handle() {
-+gaim2_gtk_blist_get_handle() {
- static int handle;
-
- return &handle;
- }
-
--static gboolean buddy_signonoff_timeout_cb(GaimBuddy *buddy)
-+static gboolean buddy_signonoff_timeout_cb(Gaim2Buddy *buddy)
- {
-- struct _gaim_gtk_blist_node *gtknode = ((GaimBlistNode*)buddy)->ui_data;
-- GaimConversation *conv;
-+ struct _gaim2_gtk_blist_node *gtknode = ((Gaim2BlistNode*)buddy)->ui_data;
-+ Gaim2Conversation *conv;
-
- gtknode->recent_signonoff = FALSE;
- gtknode->recent_signonoff_timer = 0;
-
-- gaim_gtk_blist_update(NULL, (GaimBlistNode*)buddy);
-+ gaim2_gtk_blist_update(NULL, (Gaim2BlistNode*)buddy);
-
-- if((conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name, buddy->account))) {
-+ if((conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, buddy->name, buddy->account))) {
- if(GAIM_BUDDY_IS_ONLINE(buddy)) {
-- gaim_conversation_update(conv, GAIM_CONV_ACCOUNT_ONLINE);
-+ gaim2_conversation_update(conv, GAIM_CONV_ACCOUNT_ONLINE);
- } else {
-- gaim_conversation_update(conv, GAIM_CONV_ACCOUNT_OFFLINE);
-+ gaim2_conversation_update(conv, GAIM_CONV_ACCOUNT_OFFLINE);
- }
- }
-
- return FALSE;
- }
-
--static void buddy_signonoff_cb(GaimBuddy *buddy)
-+static void buddy_signonoff_cb(Gaim2Buddy *buddy)
- {
-- struct _gaim_gtk_blist_node *gtknode;
-+ struct _gaim2_gtk_blist_node *gtknode;
-
-- if(!((GaimBlistNode*)buddy)->ui_data) {
-- gaim_gtk_blist_new_node((GaimBlistNode*)buddy);
-+ if(!((Gaim2BlistNode*)buddy)->ui_data) {
-+ gaim2_gtk_blist_new_node((Gaim2BlistNode*)buddy);
- }
-
-- gtknode = ((GaimBlistNode*)buddy)->ui_data;
-+ gtknode = ((Gaim2BlistNode*)buddy)->ui_data;
-
- gtknode->recent_signonoff = TRUE;
-
- if(gtknode->recent_signonoff_timer > 0)
-- gaim_timeout_remove(gtknode->recent_signonoff_timer);
-- gtknode->recent_signonoff_timer = gaim_timeout_add(10000,
-+ gaim2_timeout_remove(gtknode->recent_signonoff_timer);
-+ gtknode->recent_signonoff_timer = gaim2_timeout_add(10000,
- (GSourceFunc)buddy_signonoff_timeout_cb, buddy);
- }
-
--void gaim_gtk_blist_init(void)
-+void gaim2_gtk_blist_init(void)
- {
-- void *gtk_blist_handle = gaim_gtk_blist_get_handle();
-+ void *gtk_blist_handle = gaim2_gtk_blist_get_handle();
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- gtk_blist_handle, GAIM_CALLBACK(account_signon_cb),
- NULL);
-
- /* Initialize prefs */
-- gaim_prefs_add_none("/gaim/gtk/blist");
-- gaim_prefs_add_bool("/gaim/gtk/blist/show_buddy_icons", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/blist/show_empty_groups", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/blist/show_idle_time", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/blist/show_offline_buddies", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/blist/list_visible", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/blist/list_maximized", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/blist/sort_type", "alphabetical");
-- gaim_prefs_add_int("/gaim/gtk/blist/x", 0);
-- gaim_prefs_add_int("/gaim/gtk/blist/y", 0);
-- gaim_prefs_add_int("/gaim/gtk/blist/width", 309); /* Golden ratio, baby */
-- gaim_prefs_add_int("/gaim/gtk/blist/height", 500); /* Golden ratio, baby */
-- gaim_prefs_add_int("/gaim/gtk/blist/tooltip_delay", 500);
-+ gaim2_prefs_add_none("/gaim2/gtk/blist");
-+ gaim2_prefs_add_bool("/gaim2/gtk/blist/show_buddy_icons", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/blist/show_empty_groups", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/blist/show_idle_time", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/blist/show_offline_buddies", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/blist/list_visible", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/blist/list_maximized", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/blist/sort_type", "alphabetical");
-+ gaim2_prefs_add_int("/gaim2/gtk/blist/x", 0);
-+ gaim2_prefs_add_int("/gaim2/gtk/blist/y", 0);
-+ gaim2_prefs_add_int("/gaim2/gtk/blist/width", 309); /* Golden ratio, baby */
-+ gaim2_prefs_add_int("/gaim2/gtk/blist/height", 500); /* Golden ratio, baby */
-+ gaim2_prefs_add_int("/gaim2/gtk/blist/tooltip_delay", 500);
-
- /* Register our signals */
-- gaim_signal_register(gtk_blist_handle, "gtkblist-hiding",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_POINTER));
--
-- gaim_signal_register(gtk_blist_handle, "gtkblist-unhiding",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE));
--
-- gaim_signal_register(gtk_blist_handle, "gtkblist-created",
-- gaim_marshal_VOID__POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(gtk_blist_handle, "gtkblist-hiding",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-+
-+ gaim2_signal_register(gtk_blist_handle, "gtkblist-unhiding",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE));
-+
-+ gaim2_signal_register(gtk_blist_handle, "gtkblist-created",
-+ gaim2_marshal_VOID__POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_BLIST));
-
-- gaim_signal_register(gtk_blist_handle, "drawing-tooltip",
-- gaim_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE, GAIM_SUBTYPE_BLIST_NODE),
-- gaim_value_new_outgoing(GAIM_TYPE_BOXED, "GString *"),
-- gaim_value_new(GAIM_TYPE_BOOLEAN));
-+ gaim2_signal_register(gtk_blist_handle, "drawing-tooltip",
-+ gaim2_marshal_VOID__POINTER_POINTER_UINT, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE, GAIM_SUBTYPE_BLIST_NODE),
-+ gaim2_value_new_outgoing(GAIM_TYPE_BOXED, "GString *"),
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN));
-
-
-- gaim_signal_connect(gaim_blist_get_handle(), "buddy-signed-on", gtk_blist_handle, GAIM_CALLBACK(buddy_signonoff_cb), NULL);
-- gaim_signal_connect(gaim_blist_get_handle(), "buddy-signed-off", gtk_blist_handle, GAIM_CALLBACK(buddy_signonoff_cb), NULL);
-+ gaim2_signal_connect(gaim2_blist_get_handle(), "buddy-signed-on", gtk_blist_handle, GAIM_CALLBACK(buddy_signonoff_cb), NULL);
-+ gaim2_signal_connect(gaim2_blist_get_handle(), "buddy-signed-off", gtk_blist_handle, GAIM_CALLBACK(buddy_signonoff_cb), NULL);
- }
-
- void
--gaim_gtk_blist_uninit(void) {
-- gaim_signals_unregister_by_instance(gaim_gtk_blist_get_handle());
-+gaim2_gtk_blist_uninit(void) {
-+ gaim2_signals_unregister_by_instance(gaim2_gtk_blist_get_handle());
- }
-
- /*********************************************************************
- * Buddy List sorting functions *
- *********************************************************************/
-
--GList *gaim_gtk_blist_get_sort_methods()
-+GList *gaim2_gtk_blist_get_sort_methods()
- {
-- return gaim_gtk_blist_sort_methods;
-+ return gaim2_gtk_blist_sort_methods;
- }
-
--void gaim_gtk_blist_sort_method_reg(const char *id, const char *name, gaim_gtk_blist_sort_function func)
-+void gaim2_gtk_blist_sort_method_reg(const char *id, const char *name, gaim2_gtk_blist_sort_function func)
- {
-- struct gaim_gtk_blist_sort_method *method = g_new0(struct gaim_gtk_blist_sort_method, 1);
-+ struct gaim2_gtk_blist_sort_method *method = g_new0(struct gaim2_gtk_blist_sort_method, 1);
- method->id = g_strdup(id);
- method->name = g_strdup(name);
- method->func = func;
-- gaim_gtk_blist_sort_methods = g_list_append(gaim_gtk_blist_sort_methods, method);
-- gaim_gtk_blist_update_sort_methods();
-+ gaim2_gtk_blist_sort_methods = g_list_append(gaim2_gtk_blist_sort_methods, method);
-+ gaim2_gtk_blist_update_sort_methods();
- }
-
--void gaim_gtk_blist_sort_method_unreg(const char *id){
-- GList *l = gaim_gtk_blist_sort_methods;
-+void gaim2_gtk_blist_sort_method_unreg(const char *id){
-+ GList *l = gaim2_gtk_blist_sort_methods;
-
- while(l) {
-- struct gaim_gtk_blist_sort_method *method = l->data;
-+ struct gaim2_gtk_blist_sort_method *method = l->data;
- if(!strcmp(method->id, id)) {
-- gaim_gtk_blist_sort_methods = g_list_delete_link(gaim_gtk_blist_sort_methods, l);
-+ gaim2_gtk_blist_sort_methods = g_list_delete_link(gaim2_gtk_blist_sort_methods, l);
- g_free(method->id);
- g_free(method->name);
- g_free(method);
- break;
- }
- }
-- gaim_gtk_blist_update_sort_methods();
-+ gaim2_gtk_blist_update_sort_methods();
- }
-
--void gaim_gtk_blist_sort_method_set(const char *id){
-- GList *l = gaim_gtk_blist_sort_methods;
-+void gaim2_gtk_blist_sort_method_set(const char *id){
-+ GList *l = gaim2_gtk_blist_sort_methods;
-
- if(!id)
- id = "none";
-
-- while (l && strcmp(((struct gaim_gtk_blist_sort_method*)l->data)->id, id))
-+ while (l && strcmp(((struct gaim2_gtk_blist_sort_method*)l->data)->id, id))
- l = l->next;
-
- if (l) {
- current_sort_method = l->data;
- } else if (!current_sort_method) {
-- gaim_gtk_blist_sort_method_set("none");
-+ gaim2_gtk_blist_sort_method_set("none");
- return;
- }
-- redo_buddy_list(gaim_get_blist(), TRUE);
-+ redo_buddy_list(gaim2_get_blist(), TRUE);
-
- }
-
-@@ -5124,9 +5124,9 @@ void gaim_gtk_blist_sort_method_set(cons
- ** Sort Methods
- ******************************************/
-
--static void sort_method_none(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter parent_iter, GtkTreeIter *cur, GtkTreeIter *iter)
-+static void sort_method_none(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter parent_iter, GtkTreeIter *cur, GtkTreeIter *iter)
- {
-- GaimBlistNode *sibling = node->prev;
-+ Gaim2BlistNode *sibling = node->prev;
- GtkTreeIter sibling_iter;
-
- if (cur != NULL) {
-@@ -5145,16 +5145,16 @@ static void sort_method_none(GaimBlistNo
-
- #if GTK_CHECK_VERSION(2,2,1)
-
--static void sort_method_alphabetical(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter)
-+static void sort_method_alphabetical(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter)
- {
- GtkTreeIter more_z;
-
- const char *my_name;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- my_name = gaim_contact_get_alias((GaimContact*)node);
-+ my_name = gaim2_contact_get_alias((Gaim2Contact*)node);
- } else if(GAIM_BLIST_NODE_IS_CHAT(node)) {
-- my_name = gaim_chat_get_name((GaimChat*)node);
-+ my_name = gaim2_chat_get_name((Gaim2Chat*)node);
- } else {
- sort_method_none(node, blist, groupiter, cur, iter);
- return;
-@@ -5168,7 +5168,7 @@ static void sort_method_alphabetical(Gai
-
- do {
- GValue val;
-- GaimBlistNode *n;
-+ Gaim2BlistNode *n;
- const char *this_name;
- int cmp;
-
-@@ -5177,14 +5177,14 @@ static void sort_method_alphabetical(Gai
- n = g_value_get_pointer(&val);
-
- if(GAIM_BLIST_NODE_IS_CONTACT(n)) {
-- this_name = gaim_contact_get_alias((GaimContact*)n);
-+ this_name = gaim2_contact_get_alias((Gaim2Contact*)n);
- } else if(GAIM_BLIST_NODE_IS_CHAT(n)) {
-- this_name = gaim_chat_get_name((GaimChat*)n);
-+ this_name = gaim2_chat_get_name((Gaim2Chat*)n);
- } else {
- this_name = NULL;
- }
-
-- cmp = gaim_utf8_strcasecmp(my_name, this_name);
-+ cmp = gaim2_utf8_strcasecmp(my_name, this_name);
-
- if(this_name && (cmp < 0 || (cmp == 0 && node < n))) {
- if(cur) {
-@@ -5210,14 +5210,14 @@ static void sort_method_alphabetical(Gai
- }
- }
-
--static void sort_method_status(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter)
-+static void sort_method_status(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter)
- {
- GtkTreeIter more_z;
-
-- GaimBuddy *my_buddy, *this_buddy;
-+ Gaim2Buddy *my_buddy, *this_buddy;
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- my_buddy = gaim_contact_get_priority_buddy((GaimContact*)node);
-+ my_buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)node);
- } else if(GAIM_BLIST_NODE_IS_CHAT(node)) {
- if (cur != NULL) {
- *iter = *cur;
-@@ -5239,7 +5239,7 @@ static void sort_method_status(GaimBlist
-
- do {
- GValue val;
-- GaimBlistNode *n;
-+ Gaim2BlistNode *n;
- gint name_cmp;
- gint presence_cmp;
-
-@@ -5248,22 +5248,22 @@ static void sort_method_status(GaimBlist
- n = g_value_get_pointer(&val);
-
- if(GAIM_BLIST_NODE_IS_CONTACT(n)) {
-- this_buddy = gaim_contact_get_priority_buddy((GaimContact*)n);
-+ this_buddy = gaim2_contact_get_priority_buddy((Gaim2Contact*)n);
- } else {
- this_buddy = NULL;
- }
-
-- name_cmp = gaim_utf8_strcasecmp(
-+ name_cmp = gaim2_utf8_strcasecmp(
- (my_buddy
-- ? gaim_contact_get_alias(gaim_buddy_get_contact(my_buddy))
-+ ? gaim2_contact_get_alias(gaim2_buddy_get_contact(my_buddy))
- : NULL),
- (this_buddy
-- ? gaim_contact_get_alias(gaim_buddy_get_contact(this_buddy))
-+ ? gaim2_contact_get_alias(gaim2_buddy_get_contact(this_buddy))
- : NULL));
-
-- presence_cmp = gaim_presence_compare(
-- gaim_buddy_get_presence(my_buddy),
-- gaim_buddy_get_presence(this_buddy));
-+ presence_cmp = gaim2_presence_compare(
-+ gaim2_buddy_get_presence(my_buddy),
-+ gaim2_buddy_get_presence(this_buddy));
-
- if (this_buddy == NULL ||
- (presence_cmp < 0 ||
-@@ -5299,7 +5299,7 @@ static void sort_method_status(GaimBlist
- }
- }
-
--static void sort_method_log(GaimBlistNode *node, GaimBuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter)
-+static void sort_method_log(Gaim2BlistNode *node, Gaim2BuddyList *blist, GtkTreeIter groupiter, GtkTreeIter *cur, GtkTreeIter *iter)
- {
- GtkTreeIter more_z;
-
-@@ -5312,10 +5312,10 @@ static void sort_method_log(GaimBlistNod
- }
-
- if(GAIM_BLIST_NODE_IS_CONTACT(node)) {
-- GaimBlistNode *n;
-+ Gaim2BlistNode *n;
- for (n = node->child; n; n = n->next)
-- log_size += gaim_log_get_total_size(GAIM_LOG_IM, ((GaimBuddy*)(n))->name, ((GaimBuddy*)(n))->account);
-- buddy_name = gaim_contact_get_alias((GaimContact*)node);
-+ log_size += gaim2_log_get_total_size(GAIM_LOG_IM, ((Gaim2Buddy*)(n))->name, ((Gaim2Buddy*)(n))->account);
-+ buddy_name = gaim2_contact_get_alias((Gaim2Contact*)node);
- } else if(GAIM_BLIST_NODE_IS_CHAT(node)) {
- /* we don't have a reliable way of getting the log filename
- * from the chat info in the blist, yet */
-@@ -5339,8 +5339,8 @@ static void sort_method_log(GaimBlistNod
-
- do {
- GValue val;
-- GaimBlistNode *n;
-- GaimBlistNode *n2;
-+ Gaim2BlistNode *n;
-+ Gaim2BlistNode *n2;
- int cmp;
-
- val.g_type = 0;
-@@ -5350,13 +5350,13 @@ static void sort_method_log(GaimBlistNod
-
- if(GAIM_BLIST_NODE_IS_CONTACT(n)) {
- for (n2 = n->child; n2; n2 = n2->next)
-- this_log_size += gaim_log_get_total_size(GAIM_LOG_IM, ((GaimBuddy*)(n2))->name, ((GaimBuddy*)(n2))->account);
-- this_buddy_name = gaim_contact_get_alias((GaimContact*)n);
-+ this_log_size += gaim2_log_get_total_size(GAIM_LOG_IM, ((Gaim2Buddy*)(n2))->name, ((Gaim2Buddy*)(n2))->account);
-+ this_buddy_name = gaim2_contact_get_alias((Gaim2Contact*)n);
- } else {
- this_buddy_name = NULL;
- }
-
-- cmp = gaim_utf8_strcasecmp(buddy_name, this_buddy_name);
-+ cmp = gaim2_utf8_strcasecmp(buddy_name, this_buddy_name);
-
- if (!GAIM_BLIST_NODE_IS_CONTACT(n) || log_size > this_log_size ||
- ((log_size == this_log_size) &&
-@@ -5387,17 +5387,17 @@ static void sort_method_log(GaimBlistNod
- #endif
-
- static void
--plugin_act(GtkObject *obk, GaimPluginAction *pam)
-+plugin_act(GtkObject *obk, Gaim2PluginAction *pam)
- {
- if (pam->callback)
- pam->callback(pam);
- }
-
- static void
--build_plugin_actions(GtkWidget *menu, GaimPlugin *plugin)
-+build_plugin_actions(GtkWidget *menu, Gaim2Plugin *plugin)
- {
- GtkWidget *menuitem;
-- GaimPluginAction *action = NULL;
-+ Gaim2PluginAction *action = NULL;
- GList *actions, *l;
-
- actions = GAIM_PLUGIN_ACTIONS(plugin, NULL);
-@@ -5406,7 +5406,7 @@ build_plugin_actions(GtkWidget *menu, Ga
- {
- if (l->data)
- {
-- action = (GaimPluginAction *) l->data;
-+ action = (Gaim2PluginAction *) l->data;
- action->plugin = plugin;
- action->context = NULL;
-
-@@ -5419,7 +5419,7 @@ build_plugin_actions(GtkWidget *menu, Ga
- gtk_widget_show(menuitem);
- }
- else
-- gaim_separator(menu);
-+ gaim2_separator(menu);
- }
-
- g_list_free(actions);
-@@ -5428,31 +5428,31 @@ build_plugin_actions(GtkWidget *menu, Ga
- static void
- modify_account_cb(GtkWidget *widget, gpointer data)
- {
-- gaim_gtk_account_dialog_show(GAIM_GTK_MODIFY_ACCOUNT_DIALOG, data);
-+ gaim2_gtk_account_dialog_show(GAIM_GTK_MODIFY_ACCOUNT_DIALOG, data);
- }
-
- static void
- enable_account_cb(GtkCheckMenuItem *widget, gpointer data)
- {
-- GaimAccount *account = data;
-- const GaimSavedStatus *saved_status;
-+ Gaim2Account *account = data;
-+ const Gaim2SavedStatus *saved_status;
-
-- saved_status = gaim_savedstatus_get_current();
-- gaim_savedstatus_activate_for_account(saved_status, account);
-+ saved_status = gaim2_savedstatus_get_current();
-+ gaim2_savedstatus_activate_for_account(saved_status, account);
-
-- gaim_account_set_enabled(account, GAIM_GTK_UI, TRUE);
-+ gaim2_account_set_enabled(account, GAIM_GTK_UI, TRUE);
- }
-
- static void
- disable_account_cb(GtkCheckMenuItem *widget, gpointer data)
- {
-- GaimAccount *account = data;
-+ Gaim2Account *account = data;
-
-- gaim_account_set_enabled(account, GAIM_GTK_UI, FALSE);
-+ gaim2_account_set_enabled(account, GAIM_GTK_UI, FALSE);
- }
-
- void
--gaim_gtk_blist_update_accounts_menu(void)
-+gaim2_gtk_blist_update_accounts_menu(void)
- {
- GtkWidget *menuitem = NULL, *submenu = NULL;
- GList *l = NULL, *accounts = NULL;
-@@ -5470,27 +5470,27 @@ gaim_gtk_blist_update_accounts_menu(void
- GTK_WIDGET(l->data));
- }
-
-- for (accounts = gaim_accounts_get_all(); accounts; accounts = accounts->next) {
-+ for (accounts = gaim2_accounts_get_all(); accounts; accounts = accounts->next) {
- char *buf = NULL;
- GtkWidget *image = NULL;
-- GaimConnection *gc = NULL;
-- GaimAccount *account = NULL;
-- GaimStatus *status = NULL;
-+ Gaim2Connection *gc = NULL;
-+ Gaim2Account *account = NULL;
-+ Gaim2Status *status = NULL;
- GdkPixbuf *pixbuf = NULL, *scale = NULL;
-
- account = accounts->data;
-
-- if(gaim_account_get_enabled(account, GAIM_GTK_UI)) {
-- buf = g_strconcat(gaim_account_get_username(account), " (",
-- gaim_account_get_protocol_name(account), ")", NULL);
-+ if(gaim2_account_get_enabled(account, GAIM_GTK_UI)) {
-+ buf = g_strconcat(gaim2_account_get_username(account), " (",
-+ gaim2_account_get_protocol_name(account), ")", NULL);
- menuitem = gtk_image_menu_item_new_with_label(buf);
- g_free(buf);
-- status = gaim_account_get_active_status(account);
-- pixbuf = gaim_gtk_create_prpl_icon_with_status(account, gaim_status_get_type(status));
-+ status = gaim2_account_get_active_status(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon_with_status(account, gaim2_status_get_type(status));
- if (pixbuf) {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
- GDK_INTERP_BILINEAR);
-- if (!gaim_account_is_connected(account))
-+ if (!gaim2_account_is_connected(account))
- gdk_pixbuf_saturate_and_pixelate(scale, scale,
- 0.0, FALSE);
- image = gtk_image_new_from_pixbuf(scale);
-@@ -5513,20 +5513,20 @@ gaim_gtk_blist_update_accounts_menu(void
- gtk_menu_shell_append(GTK_MENU_SHELL(submenu), menuitem);
- gtk_widget_show(menuitem);
-
-- gaim_separator(submenu);
-+ gaim2_separator(submenu);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- if (gc && GAIM_CONNECTION_IS_CONNECTED(gc)) {
-- GaimPlugin *plugin = NULL;
-+ Gaim2Plugin *plugin = NULL;
-
- plugin = gc->prpl;
- if (GAIM_PLUGIN_HAS_ACTIONS(plugin)) {
- GList *l, *ll = NULL;
-- GaimPluginAction *action = NULL;
-+ Gaim2PluginAction *action = NULL;
-
- for (l = ll = GAIM_PLUGIN_ACTIONS(plugin, gc); l; l = l->next) {
- if (l->data) {
-- action = (GaimPluginAction *)l->data;
-+ action = (Gaim2PluginAction *)l->data;
- action->plugin = plugin;
- action->context = gc;
-
-@@ -5537,7 +5537,7 @@ gaim_gtk_blist_update_accounts_menu(void
- g_object_set_data(G_OBJECT(menuitem), "plugin_action", action);
- gtk_widget_show(menuitem);
- } else
-- gaim_separator(submenu);
-+ gaim2_separator(submenu);
- }
- } else {
- menuitem = gtk_menu_item_new_with_label(_("No actions available"));
-@@ -5552,7 +5552,7 @@ gaim_gtk_blist_update_accounts_menu(void
- gtk_widget_show(menuitem);
- }
-
-- gaim_separator(submenu);
-+ gaim2_separator(submenu);
-
- menuitem = gtk_menu_item_new_with_mnemonic(_("_Disable"));
- g_signal_connect(G_OBJECT(menuitem), "activate",
-@@ -5565,7 +5565,7 @@ gaim_gtk_blist_update_accounts_menu(void
- }
-
- if(disabled_accounts) {
-- gaim_separator(accountmenu);
-+ gaim2_separator(accountmenu);
- menuitem = gtk_menu_item_new_with_label(_("Enable Account"));
- gtk_menu_shell_append(GTK_MENU_SHELL(accountmenu), menuitem);
- gtk_widget_show(menuitem);
-@@ -5574,27 +5574,27 @@ gaim_gtk_blist_update_accounts_menu(void
- gtk_menu_item_set_submenu(GTK_MENU_ITEM(menuitem), submenu);
- gtk_widget_show(submenu);
-
-- for (accounts = gaim_accounts_get_all(); accounts; accounts = accounts->next) {
-+ for (accounts = gaim2_accounts_get_all(); accounts; accounts = accounts->next) {
- char *buf = NULL;
- GtkWidget *image = NULL;
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- GdkPixbuf *pixbuf = NULL, *scale = NULL;
-
- account = accounts->data;
-
-- if(!gaim_account_get_enabled(account, GAIM_GTK_UI)) {
-+ if(!gaim2_account_get_enabled(account, GAIM_GTK_UI)) {
-
- disabled_accounts = TRUE;
-
-- buf = g_strconcat(gaim_account_get_username(account), " (",
-- gaim_account_get_protocol_name(account), ")", NULL);
-+ buf = g_strconcat(gaim2_account_get_username(account), " (",
-+ gaim2_account_get_protocol_name(account), ")", NULL);
- menuitem = gtk_image_menu_item_new_with_label(buf);
- g_free(buf);
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
- if (pixbuf) {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
- GDK_INTERP_BILINEAR);
-- if (gaim_account_is_disconnected(account))
-+ if (gaim2_account_is_disconnected(account))
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.00, FALSE);
- image = gtk_image_new_from_pixbuf(scale);
- g_object_unref(G_OBJECT(pixbuf));
-@@ -5614,10 +5614,10 @@ gaim_gtk_blist_update_accounts_menu(void
- static GList *plugin_submenus = NULL;
-
- void
--gaim_gtk_blist_update_plugin_actions(void)
-+gaim2_gtk_blist_update_plugin_actions(void)
- {
- GtkWidget *menuitem, *submenu;
-- GaimPlugin *plugin = NULL;
-+ Gaim2Plugin *plugin = NULL;
- GList *l;
- GtkAccelGroup *accel_group;
-
-@@ -5635,7 +5635,7 @@ gaim_gtk_blist_update_plugin_actions(voi
- menuitems = gtk_container_get_children(GTK_CONTAINER(submenu));
- while (menuitems != NULL)
- {
-- GaimPluginAction *action;
-+ Gaim2PluginAction *action;
- menuitem = menuitems->data;
- action = g_object_get_data(G_OBJECT(menuitem), "plugin_action");
- g_free(action);
-@@ -5650,10 +5650,10 @@ gaim_gtk_blist_update_plugin_actions(voi
- accel_group = gtk_menu_get_accel_group(GTK_MENU(pluginmenu));
-
- /* Add a submenu for each plugin with custom actions */
-- for (l = gaim_plugins_get_loaded(); l; l = l->next) {
-+ for (l = gaim2_plugins_get_loaded(); l; l = l->next) {
- char *path;
-
-- plugin = (GaimPlugin *) l->data;
-+ plugin = (Gaim2Plugin *) l->data;
-
- if (GAIM_IS_PROTOCOL_PLUGIN(plugin))
- continue;
-@@ -5695,8 +5695,8 @@ sortmethod_act(GtkCheckMenuItem *checkme
- while (gtk_events_pending())
- gtk_main_iteration();
-
-- gaim_gtk_blist_sort_method_set(id);
-- gaim_prefs_set_string("/gaim/gtk/blist/sort_type", id);
-+ gaim2_gtk_blist_sort_method_set(id);
-+ gaim2_prefs_set_string("/gaim2/gtk/blist/sort_type", id);
-
- if (gtkblist->window->window != NULL)
- gdk_window_set_cursor(gtkblist->window->window, NULL);
-@@ -5704,14 +5704,14 @@ sortmethod_act(GtkCheckMenuItem *checkme
- }
-
- void
--gaim_gtk_blist_update_sort_methods(void)
-+gaim2_gtk_blist_update_sort_methods(void)
- {
- GtkWidget *menuitem = NULL, *activeitem = NULL;
-- GaimGtkBlistSortMethod *method = NULL;
-+ Gaim2GtkBlistSortMethod *method = NULL;
- GList *l;
- GSList *sl = NULL;
- GtkWidget *sortmenu;
-- const char *m = gaim_prefs_get_string("/gaim/gtk/blist/sort_type");
-+ const char *m = gaim2_prefs_get_string("/gaim2/gtk/blist/sort_type");
-
- if (gtkblist == NULL)
- return;
-@@ -5727,8 +5727,8 @@ gaim_gtk_blist_update_sort_methods(void)
- gtk_widget_destroy(GTK_WIDGET(menuitem));
- }
-
-- for (l = gaim_gtk_blist_sort_methods; l; l = l->next) {
-- method = (GaimGtkBlistSortMethod *) l->data;
-+ for (l = gaim2_gtk_blist_sort_methods; l; l = l->next) {
-+ method = (Gaim2GtkBlistSortMethod *) l->data;
- menuitem = gtk_radio_menu_item_new_with_label(sl, _(method->name));
- if (!strcmp(m, method->id))
- activeitem = menuitem;
-diff -prNu ./src/gtkblist.h ./src/gtkblist.h
---- ./src/gtkblist.h 2005-12-20 23:57:54.000000000 +0100
-+++ ./src/gtkblist.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkblist.h GTK+ Buddy List API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,7 +25,7 @@
- #ifndef _GAIM_GTKBLIST_H_
- #define _GAIM_GTKBLIST_H_
-
--typedef struct _GaimGtkBuddyList GaimGtkBuddyList;
-+typedef struct _Gaim2GtkBuddyList Gaim2GtkBuddyList;
-
- enum {
- STATUS_ICON_COLUMN,
-@@ -42,9 +42,9 @@ typedef enum {
- GAIM_STATUS_ICON_LARGE,
- GAIM_STATUS_ICON_SMALL
-
--} GaimStatusIconSize;
-+} Gaim2StatusIconSize;
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "blist.h"
-
- /**************************************************************************
-@@ -53,7 +53,7 @@ typedef enum {
- /**
- * Like, everything you need to know about the gtk buddy list
- */
--struct _GaimGtkBuddyList {
-+struct _Gaim2GtkBuddyList {
- GtkWidget *window;
- GtkWidget *vbox; /**< This is the vbox that everything gets packed into. Your plugin might
- want to pack something in it itself. Go, plugins! */
-@@ -81,21 +81,21 @@ struct _GaimGtkBuddyList {
- GdkRectangle contact_rect; /**< This is the bounding rectangle of the contact node
- and its children. This is used for auto-expand on
- mouseover. */
-- GaimBlistNode *mouseover_contact; /**< This is the contact currently mouse-over expanded */
-+ Gaim2BlistNode *mouseover_contact; /**< This is the contact currently mouse-over expanded */
-
- GtkWidget *tipwindow; /**< The window used by the tooltip */
- GList *tooltipdata; /**< The data for each "chunk" of the tooltip */
-
-- GaimBlistNode *selected_node; /**< The currently selected node */
-+ Gaim2BlistNode *selected_node; /**< The currently selected node */
- GtkWidget *statusbox; /**< The status selector dropdown */
- GdkPixbuf *east, *south; /**< Drop shadow stuff */
- GdkWindow *east_shadow, *south_shadow; /**< Drop shadow stuff */
-
- };
-
--#define GAIM_GTK_BLIST(list) ((GaimGtkBuddyList *)(list)->ui_data)
-+#define GAIM_GTK_BLIST(list) ((Gaim2GtkBuddyList *)(list)->ui_data)
- #define GAIM_IS_GTK_BLIST(list) \
-- ((list)->ui_ops == gaim_gtk_blist_get_ui_ops())
-+ ((list)->ui_ops == gaim2_gtk_blist_get_ui_ops())
-
- /**************************************************************************
- * @name GTK+ Buddy List API
-@@ -106,35 +106,35 @@ struct _GaimGtkBuddyList {
- *
- * @return the handle to the blist system
- */
--void *gaim_gtk_blist_get_handle(void);
-+void *gaim2_gtk_blist_get_handle(void);
-
- /**
- * Initializes the GTK+ blist system.
- */
--void gaim_gtk_blist_init(void);
-+void gaim2_gtk_blist_init(void);
-
- /**
- * Uninitializes the GTK+ blist system.
- */
--void gaim_gtk_blist_uninit(void);
-+void gaim2_gtk_blist_uninit(void);
-
- /**
- * Returns the UI operations structure for the buddy list.
- *
- * @return The GTK+ list operations structure.
- */
--GaimBlistUiOps *gaim_gtk_blist_get_ui_ops(void);
-+Gaim2BlistUiOps *gaim2_gtk_blist_get_ui_ops(void);
-
- /**
- * Returns the default gtk buddy list
- *
- * There's normally only one buddy list window, but that isn't a necessity. This function
-- * returns the GaimGtkBuddyList we're most likely wanting to work with. This is slightly
-+ * returns the Gaim2GtkBuddyList we're most likely wanting to work with. This is slightly
- * cleaner than an externed global.
- *
- * @return The default GTK+ buddy list
- */
--GaimGtkBuddyList *gaim_gtk_blist_get_default_gtk_blist(void);
-+Gaim2GtkBuddyList *gaim2_gtk_blist_get_default_gtk_blist(void);
-
- /**
- * Populates a menu with the items shown on the buddy list for a buddy.
-@@ -143,7 +143,7 @@ GaimGtkBuddyList *gaim_gtk_blist_get_def
- * @param buddy The buddy who's menu to get
- * @param sub TRUE if this is a sub-menu, FALSE otherwise
- */
--void gaim_gtk_blist_make_buddy_menu(GtkWidget *menu, GaimBuddy *buddy, gboolean sub);
-+void gaim2_gtk_blist_make_buddy_menu(GtkWidget *menu, Gaim2Buddy *buddy, gboolean sub);
-
- /**
- * Refreshes all the nodes of the buddy list.
-@@ -151,22 +151,22 @@ void gaim_gtk_blist_make_buddy_menu(GtkW
- *
- * @param list This is the core list that gets updated from
- */
--void gaim_gtk_blist_refresh(GaimBuddyList *list);
-+void gaim2_gtk_blist_refresh(Gaim2BuddyList *list);
-
- /**
- * Tells the buddy list to update its toolbar based on the preferences
- *
- */
--void gaim_gtk_blist_update_toolbar(void);
-+void gaim2_gtk_blist_update_toolbar(void);
-
--void gaim_gtk_blist_update_columns(void);
--void gaim_gtk_blist_update_refresh_timeout(void);
-+void gaim2_gtk_blist_update_columns(void);
-+void gaim2_gtk_blist_update_refresh_timeout(void);
-
- /**
- * Useful for the buddy ticker
- */
--GdkPixbuf *gaim_gtk_blist_get_status_icon(GaimBlistNode *node,
-- GaimStatusIconSize size);
-+GdkPixbuf *gaim2_gtk_blist_get_status_icon(Gaim2BlistNode *node,
-+ Gaim2StatusIconSize size);
-
- /**
- * Returns a boolean indicating if @a node is part of an expanded contact.
-@@ -177,14 +177,14 @@ GdkPixbuf *gaim_gtk_blist_get_status_ico
- * @param node The node in question.
- * @return A boolean indicating if @a node is part of an expanded contact.
- */
--gboolean gaim_gtk_blist_node_is_contact_expanded(GaimBlistNode *node);
-+gboolean gaim2_gtk_blist_node_is_contact_expanded(Gaim2BlistNode *node);
-
- /**
- * Intelligently toggles the visibility of the buddy list. If the buddy
- * list is obscured, it is brought to the front. If it is not obscured,
- * it is hidden. If it is hidden it is shown.
- */
--void gaim_gtk_blist_toggle_visibility(void);
-+void gaim2_gtk_blist_toggle_visibility(void);
-
- /**
- * Increases the reference count of visibility managers. Callers should
-@@ -194,35 +194,35 @@ void gaim_gtk_blist_toggle_visibility(vo
- * A visibility manager is something that provides some method for
- * showing the buddy list after it is hidden (e.g. docklet plugin).
- */
--void gaim_gtk_blist_visibility_manager_add(void);
-+void gaim2_gtk_blist_visibility_manager_add(void);
-
- /**
- * Decreases the reference count of visibility managers. If the count
- * drops below zero, the buddy list is shown.
- */
--void gaim_gtk_blist_visibility_manager_remove(void);
-+void gaim2_gtk_blist_visibility_manager_remove(void);
-
-
- /**************************************************************************
- * @name GTK+ Buddy List sorting functions
- **************************************************************************/
-
--typedef void (*gaim_gtk_blist_sort_function)(GaimBlistNode *new, GaimBuddyList *blist, GtkTreeIter group, GtkTreeIter *cur, GtkTreeIter *iter);
-+typedef void (*gaim2_gtk_blist_sort_function)(Gaim2BlistNode *new, Gaim2BuddyList *blist, GtkTreeIter group, GtkTreeIter *cur, GtkTreeIter *iter);
-
- /**
- * Gets the current list of sort methods.
- *
- * @return A GSlist of sort methods
- */
--GList *gaim_gtk_blist_get_sort_methods(void);
-+GList *gaim2_gtk_blist_get_sort_methods(void);
-
--struct gaim_gtk_blist_sort_method {
-+struct gaim2_gtk_blist_sort_method {
- char *id;
- char *name;
-- gaim_gtk_blist_sort_function func;
-+ gaim2_gtk_blist_sort_function func;
- };
-
--typedef struct gaim_gtk_blist_sort_method GaimGtkBlistSortMethod;
-+typedef struct gaim2_gtk_blist_sort_method Gaim2GtkBlistSortMethod;
-
- /**
- * Registers a buddy list sorting method.
-@@ -232,41 +232,41 @@ typedef struct gaim_gtk_blist_sort_metho
- * @param func A pointer to the function.
- *
- */
--void gaim_gtk_blist_sort_method_reg(const char *id, const char *name, gaim_gtk_blist_sort_function func);
-+void gaim2_gtk_blist_sort_method_reg(const char *id, const char *name, gaim2_gtk_blist_sort_function func);
-
- /**
- * Unregisters a buddy list sorting method.
- *
- * @param id The method's id
- */
--void gaim_gtk_blist_sort_method_unreg(const char *id);
-+void gaim2_gtk_blist_sort_method_unreg(const char *id);
-
- /**
- * Sets a buddy list sorting method.
- *
- * @param id The method's id.
- */
--void gaim_gtk_blist_sort_method_set(const char *id);
-+void gaim2_gtk_blist_sort_method_set(const char *id);
-
- /**
- * Sets up the programs default sort methods
- */
--void gaim_gtk_blist_setup_sort_methods(void);
-+void gaim2_gtk_blist_setup_sort_methods(void);
-
- /**
- * Updates the accounts menu on the GTK+ buddy list window.
- */
--void gaim_gtk_blist_update_accounts_menu(void);
-+void gaim2_gtk_blist_update_accounts_menu(void);
-
- /**
- * Updates the plugin actions menu on the GTK+ buddy list window.
- */
--void gaim_gtk_blist_update_plugin_actions(void);
-+void gaim2_gtk_blist_update_plugin_actions(void);
-
- /**
- * Updates the Sorting menu on the GTK+ buddy list window.
- */
--void gaim_gtk_blist_update_sort_methods(void);
-+void gaim2_gtk_blist_update_sort_methods(void);
-
- /**
- * Determines if showing the join chat dialog is a valid action.
-@@ -274,21 +274,21 @@ void gaim_gtk_blist_update_sort_methods(
- * @return Returns TRUE if there are accounts online capable of
- * joining chat rooms. Otherwise returns FALSE.
- */
--gboolean gaim_gtk_blist_joinchat_is_showable(void);
-+gboolean gaim2_gtk_blist_joinchat_is_showable(void);
-
- /**
- * Shows the join chat dialog.
- */
--void gaim_gtk_blist_joinchat_show(void);
-+void gaim2_gtk_blist_joinchat_show(void);
-
- /**
-- * Appends the protocol specific menu items for a GaimBlistNode
-+ * Appends the protocol specific menu items for a Gaim2BlistNode
- */
--void gaim_gtk_append_blist_node_proto_menu (GtkWidget *menu, GaimConnection *gc, GaimBlistNode *node);
-+void gaim2_gtk_append_blist_node_proto_menu (GtkWidget *menu, Gaim2Connection *gc, Gaim2BlistNode *node);
-
- /**
-- * Appends the extended menu items for a GaimBlistNode
-+ * Appends the extended menu items for a Gaim2BlistNode
- */
--void gaim_gtk_append_blist_node_extended_menu(GtkWidget *menu, GaimBlistNode *node);
-+void gaim2_gtk_append_blist_node_extended_menu(GtkWidget *menu, Gaim2BlistNode *node);
-
- #endif /* _GAIM_GTKBLIST_H_ */
-diff -prNu ./src/gtkcelllayout.c ./src/gtkcelllayout.c
---- ./src/gtkcelllayout.c 2005-03-20 18:37:31.000000000 +0100
-+++ ./src/gtkcelllayout.c 2006-01-05 15:11:04.000000000 +0100
-@@ -45,7 +45,7 @@ gtk_cell_layout_get_type (void)
- };
-
- cell_layout_type =
-- g_type_register_static (G_TYPE_INTERFACE, "GaimGtkCellLayout",
-+ g_type_register_static (G_TYPE_INTERFACE, "Gaim2GtkCellLayout",
- &cell_layout_info, 0);
-
- g_type_interface_add_prerequisite (cell_layout_type, G_TYPE_OBJECT);
-diff -prNu ./src/gtkcellrendererprogress.c ./src/gtkcellrendererprogress.c
---- ./src/gtkcellrendererprogress.c 2005-12-21 19:36:11.000000000 +0100
-+++ ./src/gtkcellrendererprogress.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkcellrendererprogress.c GTK+ Cell Renderer Progress
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,24 +30,24 @@
-
- #include "gtkcellrendererprogress.h"
-
--static void gaim_gtk_cell_renderer_progress_get_property (GObject *object,
-+static void gaim2_gtk_cell_renderer_progress_get_property (GObject *object,
- guint param_id,
- GValue *value,
- GParamSpec *pspec);
--static void gaim_gtk_cell_renderer_progress_set_property (GObject *object,
-+static void gaim2_gtk_cell_renderer_progress_set_property (GObject *object,
- guint param_id,
- const GValue *value,
- GParamSpec *pspec);
--static void gaim_gtk_cell_renderer_progress_init (GaimGtkCellRendererProgress *cellprogress);
--static void gaim_gtk_cell_renderer_progress_class_init (GaimGtkCellRendererProgressClass *class);
--static void gaim_gtk_cell_renderer_progress_get_size (GtkCellRenderer *cell,
-+static void gaim2_gtk_cell_renderer_progress_init (Gaim2GtkCellRendererProgress *cellprogress);
-+static void gaim2_gtk_cell_renderer_progress_class_init (Gaim2GtkCellRendererProgressClass *class);
-+static void gaim2_gtk_cell_renderer_progress_get_size (GtkCellRenderer *cell,
- GtkWidget *widget,
- GdkRectangle *cell_area,
- gint *x_offset,
- gint *y_offset,
- gint *width,
- gint *height);
--static void gaim_gtk_cell_renderer_progress_render (GtkCellRenderer *cell,
-+static void gaim2_gtk_cell_renderer_progress_render (GtkCellRenderer *cell,
- GdkWindow *window,
- GtkWidget *widget,
- GdkRectangle *background_area,
-@@ -55,7 +55,7 @@ static void gaim_gtk_cell_renderer_progr
- GdkRectangle *expose_area,
- guint flags);
- #if 0
--static gboolean gaim_gtk_cell_renderer_progress_activate (GtkCellRenderer *cell,
-+static gboolean gaim2_gtk_cell_renderer_progress_activate (GtkCellRenderer *cell,
- GdkEvent *event,
- GtkWidget *widget,
- const gchar *path,
-@@ -63,7 +63,7 @@ static gboolean gaim_gtk_cell_renderer_p
- GdkRectangle *cell_area,
- guint flags);
- #endif
--static void gaim_gtk_cell_renderer_progress_finalize (GObject *gobject);
-+static void gaim2_gtk_cell_renderer_progress_finalize (GObject *gobject);
-
- enum {
- LAST_SIGNAL
-@@ -79,7 +79,7 @@ enum {
- static gpointer parent_class;
- /* static guint progress_cell_renderer_signals [LAST_SIGNAL]; */
-
--GType gaim_gtk_cell_renderer_progress_get_type (void)
-+GType gaim2_gtk_cell_renderer_progress_get_type (void)
- {
- static GType cell_progress_type = 0;
-
-@@ -87,47 +87,47 @@ GType gaim_gtk_cell_renderer_progress_g
- {
- static const GTypeInfo cell_progress_info =
- {
-- sizeof (GaimGtkCellRendererProgressClass),
-+ sizeof (Gaim2GtkCellRendererProgressClass),
- NULL, /* base_init */
- NULL, /* base_finalize */
-- (GClassInitFunc) gaim_gtk_cell_renderer_progress_class_init,
-+ (GClassInitFunc) gaim2_gtk_cell_renderer_progress_class_init,
- NULL, /* class_finalize */
- NULL, /* class_data */
-- sizeof (GaimGtkCellRendererProgress),
-+ sizeof (Gaim2GtkCellRendererProgress),
- 0, /* n_preallocs */
-- (GInstanceInitFunc) gaim_gtk_cell_renderer_progress_init,
-+ (GInstanceInitFunc) gaim2_gtk_cell_renderer_progress_init,
- NULL /* value_table */
- };
-
- cell_progress_type =
- g_type_register_static (GTK_TYPE_CELL_RENDERER,
-- "GaimGtkCellRendererProgress",
-+ "Gaim2GtkCellRendererProgress",
- &cell_progress_info, 0);
- }
-
- return cell_progress_type;
- }
-
--static void gaim_gtk_cell_renderer_progress_init (GaimGtkCellRendererProgress *cellprogress)
-+static void gaim2_gtk_cell_renderer_progress_init (Gaim2GtkCellRendererProgress *cellprogress)
- {
- GTK_CELL_RENDERER(cellprogress)->mode = GTK_CELL_RENDERER_MODE_INERT;
- GTK_CELL_RENDERER(cellprogress)->xpad = 2;
- GTK_CELL_RENDERER(cellprogress)->ypad = 2;
- }
-
--static void gaim_gtk_cell_renderer_progress_class_init (GaimGtkCellRendererProgressClass *class)
-+static void gaim2_gtk_cell_renderer_progress_class_init (Gaim2GtkCellRendererProgressClass *class)
- {
- GObjectClass *object_class = G_OBJECT_CLASS(class);
- GtkCellRendererClass *cell_class = GTK_CELL_RENDERER_CLASS(class);
-
- parent_class = g_type_class_peek_parent (class);
-- object_class->finalize = gaim_gtk_cell_renderer_progress_finalize;
-+ object_class->finalize = gaim2_gtk_cell_renderer_progress_finalize;
-
-- object_class->get_property = gaim_gtk_cell_renderer_progress_get_property;
-- object_class->set_property = gaim_gtk_cell_renderer_progress_set_property;
-+ object_class->get_property = gaim2_gtk_cell_renderer_progress_get_property;
-+ object_class->set_property = gaim2_gtk_cell_renderer_progress_set_property;
-
-- cell_class->get_size = gaim_gtk_cell_renderer_progress_get_size;
-- cell_class->render = gaim_gtk_cell_renderer_progress_render;
-+ cell_class->get_size = gaim2_gtk_cell_renderer_progress_get_size;
-+ cell_class->render = gaim2_gtk_cell_renderer_progress_render;
-
- g_object_class_install_property (object_class,
- PROP_PERCENTAGE,
-@@ -152,21 +152,21 @@ static void gaim_gtk_cell_renderer_progr
- G_PARAM_READABLE | G_PARAM_WRITABLE));
- }
-
--static void gaim_gtk_cell_renderer_progress_finalize (GObject *object)
-+static void gaim2_gtk_cell_renderer_progress_finalize (GObject *object)
- {
- /*
-- GaimGtkCellRendererProgress *cellprogress = GAIM_GTK_CELL_RENDERER_PROGRESS(object);
-+ Gaim2GtkCellRendererProgress *cellprogress = GAIM_GTK_CELL_RENDERER_PROGRESS(object);
- */
-
- (* G_OBJECT_CLASS (parent_class)->finalize) (object);
- }
-
--static void gaim_gtk_cell_renderer_progress_get_property (GObject *object,
-+static void gaim2_gtk_cell_renderer_progress_get_property (GObject *object,
- guint param_id,
- GValue *value,
- GParamSpec *psec)
- {
-- GaimGtkCellRendererProgress *cellprogress = GAIM_GTK_CELL_RENDERER_PROGRESS(object);
-+ Gaim2GtkCellRendererProgress *cellprogress = GAIM_GTK_CELL_RENDERER_PROGRESS(object);
-
- switch (param_id)
- {
-@@ -185,12 +185,12 @@ static void gaim_gtk_cell_renderer_progr
- }
- }
-
--static void gaim_gtk_cell_renderer_progress_set_property (GObject *object,
-+static void gaim2_gtk_cell_renderer_progress_set_property (GObject *object,
- guint param_id,
- const GValue *value,
- GParamSpec *pspec)
- {
-- GaimGtkCellRendererProgress *cellprogress = GAIM_GTK_CELL_RENDERER_PROGRESS (object);
-+ Gaim2GtkCellRendererProgress *cellprogress = GAIM_GTK_CELL_RENDERER_PROGRESS (object);
-
- switch (param_id)
- {
-@@ -212,12 +212,12 @@ static void gaim_gtk_cell_renderer_progr
- }
- }
-
--GtkCellRenderer *gaim_gtk_cell_renderer_progress_new(void)
-+GtkCellRenderer *gaim2_gtk_cell_renderer_progress_new(void)
- {
- return g_object_new(GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, NULL);
- }
-
--static void gaim_gtk_cell_renderer_progress_get_size (GtkCellRenderer *cell,
-+static void gaim2_gtk_cell_renderer_progress_get_size (GtkCellRenderer *cell,
- GtkWidget *widget,
- GdkRectangle *cell_area,
- gint *x_offset,
-@@ -253,7 +253,7 @@ static void gaim_gtk_cell_renderer_progr
- }
-
-
--static void gaim_gtk_cell_renderer_progress_render (GtkCellRenderer *cell,
-+static void gaim2_gtk_cell_renderer_progress_render (GtkCellRenderer *cell,
- GdkWindow *window,
- GtkWidget *widget,
- GdkRectangle *background_area,
-@@ -261,7 +261,7 @@ static void gaim_gtk_cell_renderer_progr
- GdkRectangle *expose_area,
- guint flags)
- {
-- GaimGtkCellRendererProgress *cellprogress = (GaimGtkCellRendererProgress *) cell;
-+ Gaim2GtkCellRendererProgress *cellprogress = (Gaim2GtkCellRendererProgress *) cell;
-
- gint width, height;
- GtkStateType state;
-diff -prNu ./src/gtkcellrendererprogress.h ./src/gtkcellrendererprogress.h
---- ./src/gtkcellrendererprogress.h 2004-08-28 14:58:57.000000000 +0200
-+++ ./src/gtkcellrendererprogress.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,5 +1,5 @@
- /* gtkxcellrendererprogress.h
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,17 +28,17 @@ extern "C" {
- #endif /* __cplusplus */
-
-
--#define GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS (gaim_gtk_cell_renderer_progress_get_type())
--#define GAIM_GTK_CELL_RENDERER_PROGRESS(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, GaimGtkCellRendererProgress))
--#define GAIM_GTK_CELL_RENDERER_PROGRESS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, GaimGtkCellRendererProgressClass))
-+#define GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS (gaim2_gtk_cell_renderer_progress_get_type())
-+#define GAIM_GTK_CELL_RENDERER_PROGRESS(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, Gaim2GtkCellRendererProgress))
-+#define GAIM_GTK_CELL_RENDERER_PROGRESS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, Gaim2GtkCellRendererProgressClass))
- #define GAIM_IS_GTK_CELL_PROGRESS_PROGRESS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS))
- #define GAIM_IS_GTK_CELL_PROGRESS_PROGRESS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS))
--#define GAIM_GTK_CELL_RENDERER_PROGRESS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, GaimGtkCellRendererProgressClass))
-+#define GAIM_GTK_CELL_RENDERER_PROGRESS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GAIM_TYPE_GTK_CELL_RENDERER_PROGRESS, Gaim2GtkCellRendererProgressClass))
-
--typedef struct _GaimGtkCellRendererProgress GaimGtkCellRendererProgress;
--typedef struct _GaimGtkCellRendererProgressClass GaimGtkCellRendererProgressClass;
-+typedef struct _Gaim2GtkCellRendererProgress Gaim2GtkCellRendererProgress;
-+typedef struct _Gaim2GtkCellRendererProgressClass Gaim2GtkCellRendererProgressClass;
-
--struct _GaimGtkCellRendererProgress {
-+struct _Gaim2GtkCellRendererProgress {
- GtkCellRenderer parent;
-
- gdouble progress;
-@@ -46,12 +46,12 @@ struct _GaimGtkCellRendererProgress {
- gboolean text_set;
- };
-
--struct _GaimGtkCellRendererProgressClass {
-+struct _Gaim2GtkCellRendererProgressClass {
- GtkCellRendererClass parent_class;
- };
-
--GType gaim_gtk_cell_renderer_progress_get_type (void);
--GtkCellRenderer *gaim_gtk_cell_renderer_progress_new (void);
-+GType gaim2_gtk_cell_renderer_progress_get_type (void);
-+GtkCellRenderer *gaim2_gtk_cell_renderer_progress_new (void);
-
-
- #ifdef __cplusplus
-diff -prNu ./src/gtkcellview.c ./src/gtkcellview.c
---- ./src/gtkcellview.c 2005-03-20 18:37:31.000000000 +0100
-+++ ./src/gtkcellview.c 2006-01-05 15:11:07.000000000 +0100
-@@ -164,7 +164,7 @@ gtk_cell_view_get_type (void)
- NULL
- };
-
-- cell_view_type = g_type_register_static (GTK_TYPE_WIDGET, "GaimGtkCellView",
-+ cell_view_type = g_type_register_static (GTK_TYPE_WIDGET, "Gaim2GtkCellView",
- &cell_view_info, 0);
-
- g_type_add_interface_static (cell_view_type, GTK_TYPE_CELL_LAYOUT,
-diff -prNu ./src/gtkcellviewmenuitem.c ./src/gtkcellviewmenuitem.c
---- ./src/gtkcellviewmenuitem.c 2005-03-20 18:37:31.000000000 +0100
-+++ ./src/gtkcellviewmenuitem.c 2006-01-05 15:11:04.000000000 +0100
-@@ -56,7 +56,7 @@ gtk_cell_view_menu_item_get_type (void)
- };
-
- cell_view_menu_item_type =
-- g_type_register_static (GTK_TYPE_MENU_ITEM, "GaimGtkCellViewMenuItem",
-+ g_type_register_static (GTK_TYPE_MENU_ITEM, "Gaim2GtkCellViewMenuItem",
- &cell_view_menu_item_info, 0);
- }
-
-diff -prNu ./src/gtkcombobox.c ./src/gtkcombobox.c
---- ./src/gtkcombobox.c 2005-12-16 20:40:53.000000000 +0100
-+++ ./src/gtkcombobox.c 2006-01-05 15:11:05.000000000 +0100
-@@ -425,7 +425,7 @@ gtk_combo_box_get_type (void)
- };
-
- combo_box_type = g_type_register_static (GTK_TYPE_BIN,
-- "GaimGtkComboBox",
-+ "Gaim2GtkComboBox",
- &combo_box_info,
- 0);
-
-diff -prNu ./src/gtkconn.c ./src/gtkconn.c
---- ./src/gtkconn.c 2005-12-22 01:36:44.000000000 +0100
-+++ ./src/gtkconn.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkconn.c GTK+ Connection API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "debug.h"
-@@ -43,31 +43,31 @@
- typedef struct {
- int delay;
- guint timeout;
--} GaimAutoRecon;
-+} Gaim2AutoRecon;
-
- static GHashTable *hash = NULL;
- static GSList *accountReconnecting = NULL;
-
--static void gaim_gtk_connection_connect_progress(GaimConnection *gc,
-+static void gaim2_gtk_connection_connect_progress(Gaim2Connection *gc,
- const char *text, size_t step, size_t step_count)
- {
-- GaimGtkBuddyList *gtkblist = gaim_gtk_blist_get_default_gtk_blist();
-+ Gaim2GtkBuddyList *gtkblist = gaim2_gtk_blist_get_default_gtk_blist();
- if (!gtkblist)
- return;
-- gtk_gaim_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox),
-- (gaim_connections_get_connecting() != NULL));
-- gtk_gaim_status_box_pulse_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox));
-+ gtk_gaim2_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox),
-+ (gaim2_connections_get_connecting() != NULL));
-+ gtk_gaim2_status_box_pulse_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox));
- }
-
--static void gaim_gtk_connection_connected(GaimConnection *gc)
-+static void gaim2_gtk_connection_connected(Gaim2Connection *gc)
- {
-- GaimGtkBuddyList *gtkblist = gaim_gtk_blist_get_default_gtk_blist();
-- GaimAccount *account = NULL;
-+ Gaim2GtkBuddyList *gtkblist = gaim2_gtk_blist_get_default_gtk_blist();
-+ Gaim2Account *account = NULL;
- if (!gtkblist)
- return;
-- gtk_gaim_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox),
-- (gaim_connections_get_connecting() != NULL));
-- account = gaim_connection_get_account(gc);
-+ gtk_gaim2_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox),
-+ (gaim2_connections_get_connecting() != NULL));
-+ account = gaim2_connection_get_account(gc);
-
- if (hash != NULL)
- g_hash_table_remove(hash, account);
-@@ -75,24 +75,24 @@ static void gaim_gtk_connection_connecte
- return;
- accountReconnecting = g_slist_remove(accountReconnecting, account);
- if (accountReconnecting == NULL)
-- gtk_gaim_status_box_set_error(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), NULL);
-+ gtk_gaim2_status_box_set_error(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), NULL);
- }
-
--static void gaim_gtk_connection_disconnected(GaimConnection *gc)
-+static void gaim2_gtk_connection_disconnected(Gaim2Connection *gc)
- {
-- GaimGtkBuddyList *gtkblist = gaim_gtk_blist_get_default_gtk_blist();
-+ Gaim2GtkBuddyList *gtkblist = gaim2_gtk_blist_get_default_gtk_blist();
- if (!gtkblist)
- return;
-- gtk_gaim_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox),
-- (gaim_connections_get_connecting() != NULL));
-+ gtk_gaim2_status_box_set_connecting(GTK_GAIM_STATUS_BOX(gtkblist->statusbox),
-+ (gaim2_connections_get_connecting() != NULL));
-
-- if (gaim_connections_get_all() != NULL)
-+ if (gaim2_connections_get_all() != NULL)
- return;
-
-- gaim_gtkdialogs_destroy_all();
-+ gaim2_gtkdialogs_destroy_all();
- }
-
--static void gaim_gtk_connection_notice(GaimConnection *gc,
-+static void gaim2_gtk_connection_notice(Gaim2Connection *gc,
- const char *text)
- {
- }
-@@ -101,7 +101,7 @@ static void gaim_gtk_connection_notice(G
- static void
- free_auto_recon(gpointer data)
- {
-- GaimAutoRecon *info = data;
-+ Gaim2AutoRecon *info = data;
-
- if (info->timeout != 0)
- g_source_remove(info->timeout);
-@@ -112,38 +112,38 @@ free_auto_recon(gpointer data)
- static gboolean
- do_signon(gpointer data)
- {
-- GaimAccount *account = data;
-- GaimAutoRecon *info;
-+ Gaim2Account *account = data;
-+ Gaim2AutoRecon *info;
-
-- gaim_debug(GAIM_DEBUG_INFO, "autorecon", "do_signon called\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "autorecon", "do_signon called\n");
- g_return_val_if_fail(account != NULL, FALSE);
- info = g_hash_table_lookup(hash, account);
-
-- if (g_list_index(gaim_accounts_get_all(), account) < 0)
-+ if (g_list_index(gaim2_accounts_get_all(), account) < 0)
- return FALSE;
-
- if (info)
- info->timeout = 0;
-
-- gaim_debug(GAIM_DEBUG_INFO, "autorecon", "calling gaim_account_connect\n");
-- gaim_account_connect(account);
-- gaim_debug(GAIM_DEBUG_INFO, "autorecon", "done calling gaim_account_connect\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "autorecon", "calling gaim2_account_connect\n");
-+ gaim2_account_connect(account);
-+ gaim2_debug(GAIM_DEBUG_INFO, "autorecon", "done calling gaim2_account_connect\n");
-
- return FALSE;
- }
-
--static void gaim_gtk_connection_report_disconnect(GaimConnection *gc, const char *text)
-+static void gaim2_gtk_connection_report_disconnect(Gaim2Connection *gc, const char *text)
- {
-- GaimGtkBuddyList *gtkblist = gaim_gtk_blist_get_default_gtk_blist();
-- GaimAccount *account = NULL;
-- GaimAutoRecon *info;
-+ Gaim2GtkBuddyList *gtkblist = gaim2_gtk_blist_get_default_gtk_blist();
-+ Gaim2Account *account = NULL;
-+ Gaim2AutoRecon *info;
- GSList* listAccount;
-
- if (hash == NULL) {
- hash = g_hash_table_new_full(g_int_hash, g_int_equal, NULL,
- free_auto_recon);
- }
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- info = g_hash_table_lookup(hash, account);
- if (accountReconnecting)
- listAccount = g_slist_find(accountReconnecting, account);
-@@ -152,10 +152,10 @@ static void gaim_gtk_connection_report_d
-
- if (!gc->wants_to_die) {
- if (gtkblist != NULL)
-- gtk_gaim_status_box_set_error(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), text);
-+ gtk_gaim2_status_box_set_error(GTK_GAIM_STATUS_BOX(gtkblist->statusbox), text);
-
- if (info == NULL) {
-- info = g_new0(GaimAutoRecon, 1);
-+ info = g_new0(Gaim2AutoRecon, 1);
- g_hash_table_insert(hash, account, info);
- info->delay = INITIAL_RECON_DELAY;
- } else {
-@@ -175,41 +175,41 @@ static void gaim_gtk_connection_report_d
- if (listAccount)
- accountReconnecting = g_slist_delete_link(accountReconnecting, listAccount);
-
-- if (gaim_account_get_alias(account)) {
-+ if (gaim2_account_get_alias(account)) {
- n = g_strdup_printf("%s (%s) (%s)",
-- gaim_account_get_username(account),
-- gaim_account_get_alias(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_alias(account),
-+ gaim2_account_get_protocol_name(account));
- } else {
- n = g_strdup_printf("%s (%s)",
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
- }
-
- p = g_strdup_printf(_("%s disconnected"), n);
- s = g_strdup_printf(_("%s was disconnected due to an error. %s The account has been disabled. "
- "Correct the error and reenable the account to connect."), n, text);
-- gaim_notify_error(NULL, NULL, p, s);
-+ gaim2_notify_error(NULL, NULL, p, s);
- g_free(p);
- g_free(s);
- g_free(n);
- /* XXX: do we really want to disable the account when it's disconnected by wants_to_die?
- * This normally happens when you sign on from somewhere else. */
-- gaim_account_set_enabled(account, GAIM_GTK_UI, FALSE);
-+ gaim2_account_set_enabled(account, GAIM_GTK_UI, FALSE);
- }
- }
-
--static GaimConnectionUiOps conn_ui_ops =
-+static Gaim2ConnectionUiOps conn_ui_ops =
- {
-- gaim_gtk_connection_connect_progress,
-- gaim_gtk_connection_connected,
-- gaim_gtk_connection_disconnected,
-- gaim_gtk_connection_notice,
-- gaim_gtk_connection_report_disconnect,
-+ gaim2_gtk_connection_connect_progress,
-+ gaim2_gtk_connection_connected,
-+ gaim2_gtk_connection_disconnected,
-+ gaim2_gtk_connection_notice,
-+ gaim2_gtk_connection_report_disconnect,
- };
-
--GaimConnectionUiOps *
--gaim_gtk_connections_get_ui_ops(void)
-+Gaim2ConnectionUiOps *
-+gaim2_gtk_connections_get_ui_ops(void)
- {
- return &conn_ui_ops;
- }
-diff -prNu ./src/gtkconn.h ./src/gtkconn.h
---- ./src/gtkconn.h 2005-04-11 14:24:43.000000000 +0200
-+++ ./src/gtkconn.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file gtkconn.h GTK+ Connection API
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -34,7 +34,7 @@
- *
- * @return UI operations struct
- */
--GaimConnectionUiOps *gaim_gtk_connections_get_ui_ops(void);
-+Gaim2ConnectionUiOps *gaim2_gtk_connections_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/gtkconv.c ./src/gtkconv.c
---- ./src/gtkconv.c 2006-01-05 00:04:34.000000000 +0100
-+++ ./src/gtkconv.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkconv.c GTK+ Conversation API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #ifndef _WIN32
- # include <X11/Xlib.h>
-@@ -122,38 +122,38 @@ typedef struct {
- GtkWidget *entry;
- GtkWidget *message;
-
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- } InviteBuddyInfo;
-
- static GtkWidget *invite_dialog = NULL;
- static GtkWidget *warn_close_dialog = NULL;
-
--static GaimGtkWindow *hidden_convwin = NULL;
-+static Gaim2GtkWindow *hidden_convwin = NULL;
- static GList *window_list = NULL;
-
-
--static gboolean update_send_to_selection(GaimGtkWindow *win);
--static void generate_send_to_items(GaimGtkWindow *win);
-+static gboolean update_send_to_selection(Gaim2GtkWindow *win);
-+static void generate_send_to_items(Gaim2GtkWindow *win);
-
- /* Prototypes. <-- because Paco-Paco hates this comment. */
--static void got_typing_keypress(GaimGtkConversation *gtkconv, gboolean first);
--static void gray_stuff_out(GaimGtkConversation *gtkconv);
--static GList *generate_invite_user_names(GaimConnection *gc);
--static void add_chat_buddy_common(GaimConversation *conv, const char *name,
-- GaimConvChatBuddyFlags flags, const char *alias, const char *old_name);
--static gboolean tab_complete(GaimConversation *conv);
--static void gaim_gtkconv_updated(GaimConversation *conv, GaimConvUpdateType type);
--static void gtkconv_set_unseen(GaimGtkConversation *gtkconv, GaimUnseenState state);
--static void update_typing_icon(GaimGtkConversation *gtkconv);
-+static void got_typing_keypress(Gaim2GtkConversation *gtkconv, gboolean first);
-+static void gray_stuff_out(Gaim2GtkConversation *gtkconv);
-+static GList *generate_invite_user_names(Gaim2Connection *gc);
-+static void add_chat_buddy_common(Gaim2Conversation *conv, const char *name,
-+ Gaim2ConvChatBuddyFlags flags, const char *alias, const char *old_name);
-+static gboolean tab_complete(Gaim2Conversation *conv);
-+static void gaim2_gtkconv_updated(Gaim2Conversation *conv, Gaim2ConvUpdateType type);
-+static void gtkconv_set_unseen(Gaim2GtkConversation *gtkconv, Gaim2UnseenState state);
-+static void update_typing_icon(Gaim2GtkConversation *gtkconv);
- static char *item_factory_translate_func (const char *path, gpointer func_data);
--gboolean gaim_gtkconv_has_focus(GaimConversation *conv);
--static void gaim_gtkconv_custom_smiley_allocated(GdkPixbufLoader *loader, gpointer user_data);
--static void gaim_gtkconv_custom_smiley_closed(GdkPixbufLoader *loader, gpointer user_data);
-+gboolean gaim2_gtkconv_has_focus(Gaim2Conversation *conv);
-+static void gaim2_gtkconv_custom_smiley_allocated(GdkPixbufLoader *loader, gpointer user_data);
-+static void gaim2_gtkconv_custom_smiley_closed(GdkPixbufLoader *loader, gpointer user_data);
- static GdkColor* generate_nick_colors(guint numcolors, GdkColor background);
- static gboolean color_is_visible(GdkColor foreground, GdkColor background, int color_contrast, int brightness_contrast);
-
--static GdkColor *get_nick_color(GaimGtkConversation *gtkconv, const char *name) {
-+static GdkColor *get_nick_color(Gaim2GtkConversation *gtkconv, const char *name) {
- static GdkColor col;
- GtkStyle *style = gtk_widget_get_style(gtkconv->imhtml);
- float scale;
-@@ -177,14 +177,14 @@ static GdkColor *get_nick_color(GaimGtkC
- **************************************************************************/
-
- static gint
--close_conv_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+close_conv_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
- GList *list = g_list_copy(gtkconv->convs), *l;
-
- l = list;
- while (l) {
-- GaimConversation *conv = l->data;
-- gaim_conversation_destroy(conv);
-+ Gaim2Conversation *conv = l->data;
-+ gaim2_conversation_destroy(conv);
- l = l->next;
- }
-
-@@ -194,9 +194,9 @@ close_conv_cb(GtkWidget *w, GaimGtkConve
- }
-
- static gboolean
--size_allocate_cb(GtkWidget *w, GtkAllocation *allocation, GaimGtkConversation *gtkconv)
-+size_allocate_cb(GtkWidget *w, GtkAllocation *allocation, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-
- if (!GTK_WIDGET_VISIBLE(w))
- return FALSE;
-@@ -210,57 +210,57 @@ size_allocate_cb(GtkWidget *w, GtkAlloca
- * size of the last resized new window. */
- /* I think that the above justification is not the majority, and that the new tab resizing should
- * negate it anyway. --luke */
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- {
- if (w == gtkconv->imhtml) {
-- gaim_prefs_set_int("/gaim/gtk/conversations/im/default_width", allocation->width);
-- gaim_prefs_set_int("/gaim/gtk/conversations/im/default_height", allocation->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/im/default_width", allocation->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/im/default_height", allocation->height);
- }
- if (w == gtkconv->entry)
-- gaim_prefs_set_int("/gaim/gtk/conversations/im/entry_height", allocation->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/im/entry_height", allocation->height);
- }
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- {
- if (w == gtkconv->imhtml) {
-- gaim_prefs_set_int("/gaim/gtk/conversations/chat/default_width", allocation->width);
-- gaim_prefs_set_int("/gaim/gtk/conversations/chat/default_height", allocation->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/chat/default_width", allocation->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/chat/default_height", allocation->height);
- }
- if (w == gtkconv->entry)
-- gaim_prefs_set_int("/gaim/gtk/conversations/chat/entry_height", allocation->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/chat/entry_height", allocation->height);
- }
-
- return FALSE;
- }
-
- static void
--default_formatize(GaimGtkConversation *c)
-+default_formatize(Gaim2GtkConversation *c)
- {
-- GaimConversation *conv = c->active_conv;
-+ Gaim2Conversation *conv = c->active_conv;
-
- if (conv->features & GAIM_CONNECTION_HTML)
- {
- char *color;
- GdkColor fg_color, bg_color;
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/send_bold") != GTK_IMHTML(c->entry)->edit.bold)
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/send_bold") != GTK_IMHTML(c->entry)->edit.bold)
- gtk_imhtml_toggle_bold(GTK_IMHTML(c->entry));
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/send_italic") != GTK_IMHTML(c->entry)->edit.italic)
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/send_italic") != GTK_IMHTML(c->entry)->edit.italic)
- gtk_imhtml_toggle_italic(GTK_IMHTML(c->entry));
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/send_underline") != GTK_IMHTML(c->entry)->edit.underline)
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/send_underline") != GTK_IMHTML(c->entry)->edit.underline)
- gtk_imhtml_toggle_underline(GTK_IMHTML(c->entry));
-
- gtk_imhtml_toggle_fontface(GTK_IMHTML(c->entry),
-- gaim_prefs_get_string("/gaim/gtk/conversations/font_face"));
-+ gaim2_prefs_get_string("/gaim2/gtk/conversations/font_face"));
-
- if (!(conv->features & GAIM_CONNECTION_NO_FONTSIZE))
- gtk_imhtml_font_set_size(GTK_IMHTML(c->entry),
-- gaim_prefs_get_int("/gaim/gtk/conversations/font_size"));
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/font_size"));
-
-- if(strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/fgcolor"), "") != 0)
-+ if(strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/fgcolor"), "") != 0)
- {
-- gdk_color_parse(gaim_prefs_get_string("/gaim/gtk/conversations/fgcolor"),
-+ gdk_color_parse(gaim2_prefs_get_string("/gaim2/gtk/conversations/fgcolor"),
- &fg_color);
- color = g_strdup_printf("#%02x%02x%02x",
- fg_color.red / 256,
-@@ -274,9 +274,9 @@ default_formatize(GaimGtkConversation *c
- g_free(color);
-
- if(!(conv->features & GAIM_CONNECTION_NO_BGCOLOR) &&
-- strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/bgcolor"), "") != 0)
-+ strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/bgcolor"), "") != 0)
- {
-- gdk_color_parse(gaim_prefs_get_string("/gaim/gtk/conversations/bgcolor"),
-+ gdk_color_parse(gaim2_prefs_get_string("/gaim2/gtk/conversations/bgcolor"),
- &bg_color);
- color = g_strdup_printf("#%02x%02x%02x",
- bg_color.red / 256,
-@@ -298,74 +298,74 @@ default_formatize(GaimGtkConversation *c
- }
-
- static void
--clear_formatting_cb(GtkIMHtml *imhtml, GaimGtkConversation *gtkconv)
-+clear_formatting_cb(GtkIMHtml *imhtml, Gaim2GtkConversation *gtkconv)
- {
- default_formatize(gtkconv);
- }
-
- static const char *
--gaim_gtk_get_cmd_prefix(void)
-+gaim2_gtk_get_cmd_prefix(void)
- {
- return "/";
- }
-
--static GaimCmdRet
--say_command_cb(GaimConversation *conv,
-+static Gaim2CmdRet
-+say_command_cb(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_conv_im_send(GAIM_CONV_IM(conv), args[0]);
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_send(GAIM_CONV_CHAT(conv), args[0]);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_conv_im_send(GAIM_CONV_IM(conv), args[0]);
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_send(GAIM_CONV_CHAT(conv), args[0]);
-
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet
--me_command_cb(GaimConversation *conv,
-+static Gaim2CmdRet
-+me_command_cb(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- char *tmp;
-
- tmp = g_strdup_printf("/me %s", args[0]);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_conv_im_send(GAIM_CONV_IM(conv), tmp);
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_send(GAIM_CONV_CHAT(conv), tmp);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_conv_im_send(GAIM_CONV_IM(conv), tmp);
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_send(GAIM_CONV_CHAT(conv), tmp);
-
- g_free(tmp);
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet
--debug_command_cb(GaimConversation *conv,
-+static Gaim2CmdRet
-+debug_command_cb(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- char *tmp, *markup;
-- GaimCmdStatus status;
-+ Gaim2CmdStatus status;
-
- if (!g_ascii_strcasecmp(args[0], "version")) {
-- tmp = g_strdup_printf(_("me is using Gaim v%s."), VERSION);
-+ tmp = g_strdup_printf(_("me is using Gaim2 v%s."), VERSION);
- markup = g_markup_escape_text(tmp, -1);
-
-- status = gaim_cmd_do_command(conv, tmp, markup, error);
-+ status = gaim2_cmd_do_command(conv, tmp, markup, error);
-
- g_free(tmp);
- g_free(markup);
- return status;
- } else {
-- gaim_conversation_write(conv, NULL, _("Supported debug options are: version"),
-+ gaim2_conversation_write(conv, NULL, _("Supported debug options are: version"),
- GAIM_MESSAGE_NO_LOG|GAIM_MESSAGE_ERROR, time(NULL));
- return GAIM_CMD_STATUS_OK;
- }
- }
-
--static GaimCmdRet
--clear_command_cb(GaimConversation *conv,
-+static Gaim2CmdRet
-+clear_command_cb(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimGtkConversation *gtkconv = NULL;
-+ Gaim2GtkConversation *gtkconv = NULL;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
-@@ -373,8 +373,8 @@ clear_command_cb(GaimConversation *conv,
- return GAIM_CMD_STATUS_OK;
- }
-
--static GaimCmdRet
--help_command_cb(GaimConversation *conv,
-+static Gaim2CmdRet
-+help_command_cb(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- GList *l, *text;
-@@ -382,7 +382,7 @@ help_command_cb(GaimConversation *conv,
-
- if (args[0] != NULL) {
- s = g_string_new("");
-- text = gaim_cmd_help(conv, args[0]);
-+ text = gaim2_cmd_help(conv, args[0]);
-
- if (text) {
- for (l = text; l; l = l->next)
-@@ -397,7 +397,7 @@ help_command_cb(GaimConversation *conv,
- s = g_string_new(_("Use \"/help &lt;command&gt;\" for help on a specific command.\n"
- "The following commands are available in this context:\n"));
-
-- text = gaim_cmd_list(conv);
-+ text = gaim2_cmd_list(conv);
- for (l = text; l; l = l->next)
- if (l->next)
- g_string_append_printf(s, "%s, ", (char *)l->data);
-@@ -405,14 +405,14 @@ help_command_cb(GaimConversation *conv,
- g_string_append_printf(s, "%s.", (char *)l->data);
- }
-
-- gaim_conversation_write(conv, NULL, s->str, GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conversation_write(conv, NULL, s->str, GAIM_MESSAGE_NO_LOG, time(NULL));
- g_string_free(s, TRUE);
-
- return GAIM_CMD_STATUS_OK;
- }
-
- static void
--send_history_add(GaimConversation *conv, const char *message)
-+send_history_add(Gaim2Conversation *conv, const char *message)
- {
- GList *first;
-
-@@ -427,24 +427,24 @@ send_history_add(GaimConversation *conv,
- }
-
- static gboolean
--check_for_and_do_command(GaimConversation *conv)
-+check_for_and_do_command(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- char *cmd;
- const char *prefix;
-- GaimAccount *account;
-+ Gaim2Account *account;
- GtkTextIter start;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-- account = gaim_conversation_get_account(conv);
-- prefix = gaim_gtk_get_cmd_prefix();
-+ account = gaim2_conversation_get_account(conv);
-+ prefix = gaim2_gtk_get_cmd_prefix();
-
- cmd = gtk_imhtml_get_text(GTK_IMHTML(gtkconv->entry), NULL, NULL);
- gtk_text_buffer_get_start_iter(GTK_IMHTML(gtkconv->entry)->text_buffer, &start);
-
- if (cmd && (strncmp(cmd, prefix, strlen(prefix)) == 0)
- && !gtk_text_iter_get_child_anchor(&start)) {
-- GaimCmdStatus status;
-+ Gaim2CmdStatus status;
- char *error, *cmdline, *markup, *send_history;
- GtkTextIter end;
-
-@@ -457,7 +457,7 @@ check_for_and_do_command(GaimConversatio
- gtk_text_iter_forward_chars(&start, g_utf8_strlen(prefix, -1));
- gtk_text_buffer_get_end_iter(GTK_IMHTML(gtkconv->entry)->text_buffer, &end);
- markup = gtk_imhtml_get_markup_range(GTK_IMHTML(gtkconv->entry), &start, &end);
-- status = gaim_cmd_do_command(conv, cmdline, markup, &error);
-+ status = gaim2_cmd_do_command(conv, cmdline, markup, &error);
- g_free(cmd);
- g_free(markup);
-
-@@ -465,34 +465,34 @@ check_for_and_do_command(GaimConversatio
- case GAIM_CMD_STATUS_OK:
- return TRUE;
- case GAIM_CMD_STATUS_NOT_FOUND:
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/passthrough_unknown_commands")) {
-- gaim_conversation_write(conv, "", _("No such command."),
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/passthrough_unknown_commands")) {
-+ gaim2_conversation_write(conv, "", _("No such command."),
- GAIM_MESSAGE_NO_LOG, time(NULL));
-
- return TRUE;
- }
- return FALSE;
- case GAIM_CMD_STATUS_WRONG_ARGS:
-- gaim_conversation_write(conv, "", _("Syntax Error: You typed the wrong number of arguments "
-+ gaim2_conversation_write(conv, "", _("Syntax Error: You typed the wrong number of arguments "
- "to that command."),
- GAIM_MESSAGE_NO_LOG, time(NULL));
- return TRUE;
- case GAIM_CMD_STATUS_FAILED:
-- gaim_conversation_write(conv, "", error ? error : _("Your command failed for an unknown reason."),
-+ gaim2_conversation_write(conv, "", error ? error : _("Your command failed for an unknown reason."),
- GAIM_MESSAGE_NO_LOG, time(NULL));
- if(error)
- g_free(error);
- return TRUE;
- case GAIM_CMD_STATUS_WRONG_TYPE:
-- if(gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_conversation_write(conv, "", _("That command only works in chats, not IMs."),
-+ if(gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_conversation_write(conv, "", _("That command only works in chats, not IMs."),
- GAIM_MESSAGE_NO_LOG, time(NULL));
- else
-- gaim_conversation_write(conv, "", _("That command only works in IMs, not chats."),
-+ gaim2_conversation_write(conv, "", _("That command only works in IMs, not chats."),
- GAIM_MESSAGE_NO_LOG, time(NULL));
- return TRUE;
- case GAIM_CMD_STATUS_WRONG_PRPL:
-- gaim_conversation_write(conv, "", _("That command doesn't work on this protocol."),
-+ gaim2_conversation_write(conv, "", _("That command doesn't work on this protocol."),
- GAIM_MESSAGE_NO_LOG, time(NULL));
- return TRUE;
- }
-@@ -503,21 +503,21 @@ check_for_and_do_command(GaimConversatio
- }
-
- static void
--send_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+send_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimAccount *account;
-- GaimConnection *gc;
-- GaimMessageFlags flags = 0;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-+ Gaim2MessageFlags flags = 0;
- char *buf, *clean;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
-
-- if (!gaim_account_is_connected(account))
-+ if (!gaim2_account_is_connected(account))
- return;
-
-- if ((gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) &&
-- gaim_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
-+ if ((gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) &&
-+ gaim2_conv_chat_has_left(GAIM_CONV_CHAT(conv)))
- return;
-
- if (check_for_and_do_command(conv)) {
-@@ -535,13 +535,13 @@ send_cb(GtkWidget *widget, GaimGtkConver
- return;
- }
-
-- gaim_idle_touch();
-+ gaim2_idle_touch();
-
- /* XXX: is there a better way to tell if the message has images? */
- if (GTK_IMHTML(gtkconv->entry)->im_images != NULL)
- flags |= GAIM_MESSAGE_IMAGES;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- if (gc && (conv->features & GAIM_CONNECTION_NO_NEWLINES)) {
- char **bufs;
- int i;
-@@ -549,20 +549,20 @@ send_cb(GtkWidget *widget, GaimGtkConver
- bufs = gtk_imhtml_get_markup_lines(GTK_IMHTML(gtkconv->entry));
- for (i = 0; bufs[i]; i++) {
- send_history_add(conv, bufs[i]);
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_conv_im_send_with_flags(GAIM_CONV_IM(conv), bufs[i], flags);
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_send_with_flags(GAIM_CONV_CHAT(conv), bufs[i], flags);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_conv_im_send_with_flags(GAIM_CONV_IM(conv), bufs[i], flags);
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_send_with_flags(GAIM_CONV_CHAT(conv), bufs[i], flags);
- }
-
- g_strfreev(bufs);
-
- } else {
- send_history_add(conv, buf);
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_conv_im_send_with_flags(GAIM_CONV_IM(conv), buf, flags);
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_send_with_flags(GAIM_CONV_CHAT(conv), buf, flags);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_conv_im_send_with_flags(GAIM_CONV_IM(conv), buf, flags);
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_send_with_flags(GAIM_CONV_CHAT(conv), buf, flags);
- }
-
- g_free(clean);
-@@ -573,43 +573,43 @@ send_cb(GtkWidget *widget, GaimGtkConver
- }
-
- static void
--add_remove_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+add_remove_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *name;
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-
-- account = gaim_conversation_get_account(conv);
-- name = gaim_conversation_get_name(conv);
-+ account = gaim2_conversation_get_account(conv);
-+ name = gaim2_conversation_get_name(conv);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-- GaimBuddy *b;
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ Gaim2Buddy *b;
-
-- b = gaim_find_buddy(account, name);
-+ b = gaim2_find_buddy(account, name);
- if (b != NULL)
-- gaim_gtkdialogs_remove_buddy(b);
-- else if (account != NULL && gaim_account_is_connected(account))
-- gaim_blist_request_add_buddy(account, (char *)name, NULL, NULL);
-- } else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-- GaimChat *c;
-+ gaim2_gtkdialogs_remove_buddy(b);
-+ else if (account != NULL && gaim2_account_is_connected(account))
-+ gaim2_blist_request_add_buddy(account, (char *)name, NULL, NULL);
-+ } else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ Gaim2Chat *c;
-
-- c = gaim_blist_find_chat(account, name);
-+ c = gaim2_blist_find_chat(account, name);
- if (c != NULL)
-- gaim_gtkdialogs_remove_chat(c);
-- else if (account != NULL && gaim_account_is_connected(account))
-- gaim_blist_request_add_chat(account, NULL, NULL, name);
-+ gaim2_gtkdialogs_remove_chat(c);
-+ else if (account != NULL && gaim2_account_is_connected(account))
-+ gaim2_blist_request_add_chat(account, NULL, NULL, name);
- }
-
- gtk_widget_grab_focus(GAIM_GTK_CONVERSATION(conv)->entry);
- }
-
--static void chat_do_info(GaimGtkConversation *gtkconv, const char *who)
-+static void chat_do_info(Gaim2GtkConversation *gtkconv, const char *who)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc;
-
-- if ((gc = gaim_conversation_get_gc(conv))) {
-+ if ((gc = gaim2_conversation_get_gc(conv))) {
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
- /*
-@@ -619,7 +619,7 @@ static void chat_do_info(GaimGtkConversa
- if (prpl_info->get_cb_info != NULL)
- {
- prpl_info->get_cb_info(gc,
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)), who);
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)), who);
- }
- else
- prpl_info->get_info(gc, who);
-@@ -628,18 +628,18 @@ static void chat_do_info(GaimGtkConversa
-
-
- static void
--info_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+info_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-- serv_get_info(gaim_conversation_get_gc(conv),
-- gaim_conversation_get_name(conv));
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ serv_get_info(gaim2_conversation_get_gc(conv),
-+ gaim2_conversation_get_name(conv));
-
- gtk_widget_grab_focus(gtkconv->entry);
-- } else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ } else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
- /* Get info of the person currently selected in the GtkTreeView */
-- GaimGtkChatPane *gtkchat;
-+ Gaim2GtkChatPane *gtkchat;
- GtkTreeIter iter;
- GtkTreeModel *model;
- GtkTreeSelection *sel;
-@@ -661,15 +661,15 @@ info_cb(GtkWidget *widget, GaimGtkConver
- }
-
- static void
--block_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+block_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimAccount *account;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2Account *account;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
-
-- if (account != NULL && gaim_account_is_connected(account))
-- gaim_gtk_request_add_block(account, gaim_conversation_get_name(conv));
-+ if (account != NULL && gaim2_account_is_connected(account))
-+ gaim2_gtk_request_add_block(account, gaim2_conversation_get_name(conv));
-
- gtk_widget_grab_focus(GAIM_GTK_CONVERSATION(conv)->entry);
- }
-@@ -678,7 +678,7 @@ static void
- do_invite(GtkWidget *w, int resp, InviteBuddyInfo *info)
- {
- const char *buddy, *message;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- gtkconv = GAIM_GTK_CONVERSATION(info->conv);
-
-@@ -689,8 +689,8 @@ do_invite(GtkWidget *w, int resp, Invite
- if (!g_ascii_strcasecmp(buddy, ""))
- return;
-
-- serv_chat_invite(gaim_conversation_get_gc(info->conv),
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(info->conv)),
-+ serv_chat_invite(gaim2_conversation_get_gc(info->conv),
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(info->conv)),
- message, buddy);
- }
-
-@@ -707,25 +707,25 @@ invite_dnd_recv(GtkWidget *widget, GdkDr
- InviteBuddyInfo *info = (InviteBuddyInfo *)data;
- const char *convprotocol;
-
-- convprotocol = gaim_account_get_protocol_id(gaim_conversation_get_account(info->conv));
-+ convprotocol = gaim2_account_get_protocol_id(gaim2_conversation_get_account(info->conv));
-
- if (sd->target == gdk_atom_intern("GAIM_BLIST_NODE", FALSE))
- {
-- GaimBlistNode *node = NULL;
-- GaimBuddy *buddy;
-+ Gaim2BlistNode *node = NULL;
-+ Gaim2Buddy *buddy;
-
- memcpy(&node, sd->data, sizeof(node));
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
-- buddy = gaim_contact_get_priority_buddy((GaimContact *)node);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact *)node);
- else if (GAIM_BLIST_NODE_IS_BUDDY(node))
-- buddy = (GaimBuddy *)node;
-+ buddy = (Gaim2Buddy *)node;
- else
- return;
-
-- if (strcmp(convprotocol, gaim_account_get_protocol_id(buddy->account)))
-+ if (strcmp(convprotocol, gaim2_account_get_protocol_id(buddy->account)))
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("That buddy is not on the same protocol as this "
- "chat."), NULL);
- }
-@@ -738,20 +738,20 @@ invite_dnd_recv(GtkWidget *widget, GdkDr
- {
- char *protocol = NULL;
- char *username = NULL;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- if (gaim_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
-+ if (gaim2_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
- &protocol, &username, NULL))
- {
- if (account == NULL)
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("You are not currently signed on with an account that "
- "can invite that buddy."), NULL);
- }
-- else if (strcmp(convprotocol, gaim_account_get_protocol_id(account)))
-+ else if (strcmp(convprotocol, gaim2_account_get_protocol_id(account)))
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("That buddy is not on the same protocol as this "
- "chat."), NULL);
- }
-@@ -775,14 +775,14 @@ static const GtkTargetEntry dnd_targets[
- };
-
- static void
--invite_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+invite_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
- InviteBuddyInfo *info = NULL;
-
- if (invite_dialog == NULL) {
-- GaimConnection *gc;
-- GaimGtkWindow *gtkwin;
-+ Gaim2Connection *gc;
-+ Gaim2GtkWindow *gtkwin;
- GtkWidget *label;
- GtkWidget *vbox, *hbox;
- GtkWidget *table;
-@@ -794,8 +794,8 @@ invite_cb(GtkWidget *widget, GaimGtkConv
- info = g_new0(InviteBuddyInfo, 1);
- info->conv = conv;
-
-- gc = gaim_conversation_get_gc(conv);
-- gtkwin = gaim_gtkconv_get_window(gtkconv);
-+ gc = gaim2_conversation_get_gc(conv);
-+ gtkwin = gaim2_gtkconv_get_window(gtkconv);
-
- /* Create the new dialog. */
- invite_dialog = gtk_dialog_new_with_buttons(
-@@ -915,23 +915,23 @@ invite_cb(GtkWidget *widget, GaimGtkConv
- static void
- menu_new_conv_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- gaim_gtkdialogs_im();
-+ gaim2_gtkdialogs_im();
- }
-
- static void
- savelog_writefile_cb(void *user_data, const char *filename)
- {
-- GaimConversation *conv = (GaimConversation *)user_data;
-+ Gaim2Conversation *conv = (Gaim2Conversation *)user_data;
- FILE *fp;
- const char *name;
- gchar *text;
-
- if ((fp = g_fopen(filename, "w+")) == NULL) {
-- gaim_notify_error(conv, NULL, _("Unable to open file."), NULL);
-+ gaim2_notify_error(conv, NULL, _("Unable to open file."), NULL);
- return;
- }
-
-- name = gaim_conversation_get_name(conv);
-+ name = gaim2_conversation_get_name(conv);
- fprintf(fp, "<html>\n<head><title>%s</title></head>\n<body>", name);
- fprintf(fp, _("<h1>Conversation with %s</h1>\n"), name);
-
-@@ -951,13 +951,13 @@ savelog_writefile_cb(void *user_data, co
- static void
- menu_save_as_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv = gaim2_gtk_conv_window_get_active_conversation(win);
- gchar *buf;
-
-- buf = g_strdup_printf("%s.html", gaim_normalize(conv->account, conv->name));
-+ buf = g_strdup_printf("%s.html", gaim2_normalize(conv->account, conv->name));
-
-- gaim_request_file(conv, _("Save Conversation"), gaim_escape_filename(buf),
-+ gaim2_request_file(conv, _("Save Conversation"), gaim2_escape_filename(buf),
- TRUE, G_CALLBACK(savelog_writefile_cb), NULL, conv);
-
- g_free(buf);
-@@ -966,26 +966,26 @@ menu_save_as_cb(gpointer data, guint act
- static void
- menu_view_log_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimLogType type;
-- GaimGtkBuddyList *gtkblist;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2LogType type;
-+ Gaim2GtkBuddyList *gtkblist;
- GdkCursor *cursor;
- const char *name;
-- GaimAccount *account;
-+ Gaim2Account *account;
- GSList *buddies;
- GSList *cur;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- type = GAIM_LOG_IM;
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- type = GAIM_LOG_CHAT;
- else
- return;
-
-- gtkblist = gaim_gtk_blist_get_default_gtk_blist();
-+ gtkblist = gaim2_gtk_blist_get_default_gtk_blist();
- cursor = gdk_cursor_new(GDK_WATCH);
-
- gdk_window_set_cursor(gtkblist->window->window, cursor);
-@@ -994,16 +994,16 @@ menu_view_log_cb(gpointer data, guint ac
- while (gtk_events_pending())
- gtk_main_iteration();
-
-- name = gaim_conversation_get_name(conv);
-- account = gaim_conversation_get_account(conv);
-+ name = gaim2_conversation_get_name(conv);
-+ account = gaim2_conversation_get_account(conv);
-
-- buddies = gaim_find_buddies(account, name);
-+ buddies = gaim2_find_buddies(account, name);
- for (cur = buddies; cur != NULL; cur = cur->next)
- {
-- GaimBlistNode *node = cur->data;
-+ Gaim2BlistNode *node = cur->data;
- if ((node != NULL) && ((node->prev != NULL) || (node->next != NULL)))
- {
-- gaim_gtk_log_show_contact((GaimContact *)node->parent);
-+ gaim2_gtk_log_show_contact((Gaim2Contact *)node->parent);
- g_slist_free(buddies);
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- gdk_window_set_cursor(win->window->window, NULL);
-@@ -1012,7 +1012,7 @@ menu_view_log_cb(gpointer data, guint ac
- }
- g_slist_free(buddies);
-
-- gaim_gtk_log_show(type, name, account);
-+ gaim2_gtk_log_show(type, name, account);
-
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- gdk_window_set_cursor(win->window->window, NULL);
-@@ -1021,18 +1021,18 @@ menu_view_log_cb(gpointer data, guint ac
- static void
- menu_clear_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- gtk_imhtml_clear(GTK_IMHTML(gtkconv->imhtml));
- }
-
- struct _search {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GtkWidget *entry;
- };
-
-@@ -1057,9 +1057,9 @@ static void do_search_cb(GtkWidget *widg
- static void
- menu_find_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *gtkwin = data;
-- GaimConversation *conv = gaim_gtk_conv_window_get_active_conversation(gtkwin);
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2GtkWindow *gtkwin = data;
-+ Gaim2Conversation *conv = gaim2_gtk_conv_window_get_active_conversation(gtkwin);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
- GtkWidget *hbox;
- GtkWidget *img = gtk_image_new_from_stock(GAIM_STOCK_DIALOG_QUESTION,
- GTK_ICON_SIZE_DIALOG);
-@@ -1107,7 +1107,7 @@ menu_find_cb(gpointer data, guint action
- gtk_entry_set_activates_default(GTK_ENTRY(s->entry), TRUE);
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), GTK_WIDGET(s->entry));
- g_signal_connect(G_OBJECT(s->entry), "changed",
-- G_CALLBACK(gaim_gtk_set_sensitive_if_input),
-+ G_CALLBACK(gaim2_gtk_set_sensitive_if_input),
- gtkconv->dialogs.search);
- gtk_box_pack_start(GTK_BOX(hbox), s->entry, FALSE, FALSE, 0);
-
-@@ -1118,11 +1118,11 @@ menu_find_cb(gpointer data, guint action
- static void
- menu_send_file_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-- serv_send_file(gaim_conversation_get_gc(conv), gaim_conversation_get_name(conv), NULL);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ serv_send_file(gaim2_conversation_get_gc(conv), gaim2_conversation_get_name(conv), NULL);
- }
-
- }
-@@ -1130,23 +1130,23 @@ menu_send_file_cb(gpointer data, guint a
- static void
- menu_add_pounce_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_gtk_conv_window_get_active_gtkconv(win)->active_conv;
-+ conv = gaim2_gtk_conv_window_get_active_gtkconv(win)->active_conv;
-
-- gaim_gtk_pounce_editor_show(gaim_conversation_get_account(conv),
-- gaim_conversation_get_name(conv), NULL);
-+ gaim2_gtk_pounce_editor_show(gaim2_conversation_get_account(conv),
-+ gaim2_conversation_get_name(conv), NULL);
- }
-
- static void
- menu_insert_link_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2GtkConversation *gtkconv;
- GtkIMHtmlToolbar *toolbar;
-
-- gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
- toolbar = GTK_IMHTMLTOOLBAR(gtkconv->toolbar);
-
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toolbar->link),
-@@ -1156,12 +1156,12 @@ menu_insert_link_cb(gpointer data, guint
- static void
- menu_insert_image_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- GtkIMHtmlToolbar *toolbar;
-
-- gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
- conv = gtkconv->active_conv;
- toolbar = GTK_IMHTMLTOOLBAR(gtkconv->toolbar);
-
-@@ -1172,37 +1172,37 @@ menu_insert_image_cb(gpointer data, guin
- static void
- menu_alias_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimAccount *account;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2Account *account;
- const char *name;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-- account = gaim_conversation_get_account(conv);
-- name = gaim_conversation_get_name(conv);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-+ account = gaim2_conversation_get_account(conv);
-+ name = gaim2_conversation_get_name(conv);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-- GaimBuddy *b;
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ Gaim2Buddy *b;
-
-- b = gaim_find_buddy(account, name);
-+ b = gaim2_find_buddy(account, name);
- if (b != NULL)
-- gaim_gtkdialogs_alias_buddy(b);
-- } else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-- GaimChat *c;
-+ gaim2_gtkdialogs_alias_buddy(b);
-+ } else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ Gaim2Chat *c;
-
-- c = gaim_blist_find_chat(account, name);
-+ c = gaim2_blist_find_chat(account, name);
- if (c != NULL)
-- gaim_gtkdialogs_alias_chat(c);
-+ gaim2_gtkdialogs_alias_chat(c);
- }
- }
-
- static void
- menu_get_info_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- info_cb(NULL, GAIM_GTK_CONVERSATION(conv));
- }
-@@ -1210,10 +1210,10 @@ menu_get_info_cb(gpointer data, guint ac
- static void
- menu_invite_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- invite_cb(NULL, GAIM_GTK_CONVERSATION(conv));
- }
-@@ -1221,10 +1221,10 @@ menu_invite_cb(gpointer data, guint acti
- static void
- menu_block_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- block_cb(NULL, GAIM_GTK_CONVERSATION(conv));
- }
-@@ -1232,10 +1232,10 @@ menu_block_cb(gpointer data, guint actio
- static void
- menu_add_remove_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- add_remove_cb(NULL, GAIM_GTK_CONVERSATION(conv));
- }
-@@ -1243,34 +1243,34 @@ menu_add_remove_cb(gpointer data, guint
- static void
- menu_close_conv_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-+ Gaim2GtkWindow *win = data;
-
-- close_conv_cb(NULL, GAIM_GTK_CONVERSATION(gaim_gtk_conv_window_get_active_conversation(win)));
-+ close_conv_cb(NULL, GAIM_GTK_CONVERSATION(gaim2_gtk_conv_window_get_active_conversation(win)));
- }
-
- static void
- menu_logging_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
- gboolean logging;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (conv == NULL)
- return;
-
- logging = gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(widget));
-
-- if (logging == gaim_conversation_is_logging(conv))
-+ if (logging == gaim2_conversation_is_logging(conv))
- return;
-
- if (logging)
- {
- /* Enable logging first so the message below can be logged. */
-- gaim_conversation_set_logging(conv, TRUE);
-+ gaim2_conversation_set_logging(conv, TRUE);
-
-- gaim_conversation_write(conv, NULL,
-+ gaim2_conversation_write(conv, NULL,
- _("Logging started. Future messages in this conversation will be logged."),
- conv->logs ? (GAIM_MESSAGE_SYSTEM) :
- (GAIM_MESSAGE_SYSTEM | GAIM_MESSAGE_NO_LOG),
-@@ -1278,43 +1278,43 @@ menu_logging_cb(gpointer data, guint act
- }
- else
- {
-- gaim_conversation_write(conv, NULL,
-+ gaim2_conversation_write(conv, NULL,
- _("Logging stopped. Future messages in this conversation will not be logged."),
- conv->logs ? (GAIM_MESSAGE_SYSTEM) :
- (GAIM_MESSAGE_SYSTEM | GAIM_MESSAGE_NO_LOG),
- time(NULL));
-
- /* Disable the logging second, so that the above message can be logged. */
-- gaim_conversation_set_logging(conv, FALSE);
-+ gaim2_conversation_set_logging(conv, FALSE);
- }
- }
-
- static void
- menu_toolbar_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (conv == NULL)
- return;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
-- gaim_prefs_set_bool("/gaim/gtk/conversations/show_formatting_toolbar",
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/show_formatting_toolbar",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(widget)));
- }
-
- static void
- menu_sounds_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (!conv)
- return;
-@@ -1328,56 +1328,56 @@ menu_sounds_cb(gpointer data, guint acti
- static void
- menu_timestamps_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (!conv)
- return;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
-- gaim_prefs_set_bool("/gaim/gtk/conversations/show_timestamps",
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/show_timestamps",
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(widget)));
- }
-
- static void
--chat_do_im(GaimGtkConversation *gtkconv, const char *who)
-+chat_do_im(Gaim2GtkConversation *gtkconv, const char *who)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimAccount *account;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- char *real_who;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
- g_return_if_fail(account != NULL);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- g_return_if_fail(gc != NULL);
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
- if (prpl_info && prpl_info->get_cb_real_name)
- real_who = prpl_info->get_cb_real_name(gc,
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)), who);
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)), who);
- else
- real_who = g_strdup(who);
-
- if(!real_who)
- return;
-
-- gaim_gtkdialogs_im_with_user(account, real_who);
-+ gaim2_gtkdialogs_im_with_user(account, real_who);
-
- g_free(real_who);
- }
-
- static void
--chat_im_button_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+chat_im_button_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimGtkChatPane *gtkchat;
-+ Gaim2GtkChatPane *gtkchat;
- GtkTreeIter iter;
- GtkTreeModel *model;
- GtkTreeSelection *sel;
-@@ -1398,12 +1398,12 @@ chat_im_button_cb(GtkWidget *widget, Gai
- }
-
- static void
--ignore_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+ignore_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimGtkChatPane *gtkchat;
-- GaimConvChat *chat;
-- GaimConvChatBuddyFlags flags;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-+ Gaim2ConvChatBuddyFlags flags;
- GtkTreeIter iter;
- GtkTreeModel *model;
- GtkTreeSelection *sel;
-@@ -1427,10 +1427,10 @@ ignore_cb(GtkWidget *w, GaimGtkConversat
- else
- return;
-
-- if (gaim_conv_chat_is_user_ignored(chat, name))
-- gaim_conv_chat_unignore(chat, name);
-+ if (gaim2_conv_chat_is_user_ignored(chat, name))
-+ gaim2_conv_chat_unignore(chat, name);
- else
-- gaim_conv_chat_ignore(chat, name);
-+ gaim2_conv_chat_ignore(chat, name);
-
- add_chat_buddy_common(conv, name, flags, alias, NULL);
- g_free(name);
-@@ -1438,7 +1438,7 @@ ignore_cb(GtkWidget *w, GaimGtkConversat
- }
-
- static void
--menu_chat_im_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+menu_chat_im_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
- const char *who = g_object_get_data(G_OBJECT(w), "user_data");
-
-@@ -1446,17 +1446,17 @@ menu_chat_im_cb(GtkWidget *w, GaimGtkCon
- }
-
- static void
--menu_chat_send_file_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+menu_chat_send_file_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
- const char *who = g_object_get_data(G_OBJECT(w), "user_data");
-- GaimConnection *gc = gaim_conversation_get_gc(conv);
-+ Gaim2Connection *gc = gaim2_conversation_get_gc(conv);
-
- serv_send_file(gc, who, NULL);
- }
-
- static void
--menu_chat_info_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+menu_chat_info_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
- char *who;
-
-@@ -1466,14 +1466,14 @@ menu_chat_info_cb(GtkWidget *w, GaimGtkC
- }
-
- static void
--menu_chat_get_away_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+menu_chat_get_away_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc;
- char *who;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
- who = g_object_get_data(G_OBJECT(w), "user_data");
-
- if (gc != NULL) {
-@@ -1486,37 +1486,37 @@ menu_chat_get_away_cb(GtkWidget *w, Gaim
- if (prpl_info->get_cb_away != NULL)
- {
- prpl_info->get_cb_away(gc,
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)), who);
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)), who);
- }
- }
- }
-
- static void
--menu_chat_add_remove_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+menu_chat_add_remove_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimAccount *account;
-- GaimBuddy *b;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2Account *account;
-+ Gaim2Buddy *b;
- char *name;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
- name = g_object_get_data(G_OBJECT(w), "user_data");
-- b = gaim_find_buddy(account, name);
-+ b = gaim2_find_buddy(account, name);
-
- if (b != NULL)
-- gaim_gtkdialogs_remove_buddy(b);
-- else if (account != NULL && gaim_account_is_connected(account))
-- gaim_blist_request_add_buddy(account, name, NULL, NULL);
-+ gaim2_gtkdialogs_remove_buddy(b);
-+ else if (account != NULL && gaim2_account_is_connected(account))
-+ gaim2_blist_request_add_buddy(account, name, NULL, NULL);
-
- gtk_widget_grab_focus(GAIM_GTK_CONVERSATION(conv)->entry);
- }
-
- static GtkWidget *
--create_chat_menu(GaimConversation *conv, const char *who,
-- GaimPluginProtocolInfo *prpl_info, GaimConnection *gc)
-+create_chat_menu(Gaim2Conversation *conv, const char *who,
-+ Gaim2PluginProtocolInfo *prpl_info, Gaim2Connection *gc)
- {
- static GtkWidget *menu = NULL;
-- GaimConvChat *chat = GAIM_CONV_CHAT(conv);
-+ Gaim2ConvChat *chat = GAIM_CONV_CHAT(conv);
- gboolean is_me = FALSE;
- GtkWidget *button;
-
-@@ -1527,51 +1527,51 @@ create_chat_menu(GaimConversation *conv,
- if (menu)
- gtk_widget_destroy(menu);
-
-- if (!strcmp(chat->nick, gaim_normalize(conv->account, who)))
-+ if (!strcmp(chat->nick, gaim2_normalize(conv->account, who)))
- is_me = TRUE;
-
- menu = gtk_menu_new();
-
- if (!is_me) {
-- button = gaim_new_item_from_stock(menu, _("IM"), GAIM_STOCK_IM,
-+ button = gaim2_new_item_from_stock(menu, _("IM"), GAIM_STOCK_IM,
- G_CALLBACK(menu_chat_im_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- g_object_set_data_full(G_OBJECT(button), "user_data", g_strdup(who), g_free);
-
- if (prpl_info && prpl_info->send_file
- && (!prpl_info->can_receive_file || prpl_info->can_receive_file(gc, who))) {
-- button = gaim_new_item_from_stock(menu, _("Send File"),
-+ button = gaim2_new_item_from_stock(menu, _("Send File"),
- GAIM_STOCK_FILE_TRANSFER, G_CALLBACK(menu_chat_send_file_cb),
- GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- g_object_set_data_full(G_OBJECT(button), "user_data", g_strdup(who), g_free);
- }
-
-- if (gaim_conv_chat_is_user_ignored(GAIM_CONV_CHAT(conv), who))
-- button = gaim_new_item_from_stock(menu, _("Un-Ignore"), GAIM_STOCK_IGNORE,
-+ if (gaim2_conv_chat_is_user_ignored(GAIM_CONV_CHAT(conv), who))
-+ button = gaim2_new_item_from_stock(menu, _("Un-Ignore"), GAIM_STOCK_IGNORE,
- G_CALLBACK(ignore_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- else
-- button = gaim_new_item_from_stock(menu, _("Ignore"), GAIM_STOCK_IGNORE,
-+ button = gaim2_new_item_from_stock(menu, _("Ignore"), GAIM_STOCK_IGNORE,
- G_CALLBACK(ignore_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- g_object_set_data_full(G_OBJECT(button), "user_data", g_strdup(who), g_free);
- }
-
- if (prpl_info->get_info || prpl_info->get_cb_info) {
-- button = gaim_new_item_from_stock(menu, _("Info"), GAIM_STOCK_INFO,
-+ button = gaim2_new_item_from_stock(menu, _("Info"), GAIM_STOCK_INFO,
- G_CALLBACK(menu_chat_info_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- g_object_set_data_full(G_OBJECT(button), "user_data", g_strdup(who), g_free);
- }
-
- if (prpl_info->get_cb_away) {
-- button = gaim_new_item_from_stock(menu, _("Get Away Message"), GAIM_STOCK_AWAY,
-+ button = gaim2_new_item_from_stock(menu, _("Get Away Message"), GAIM_STOCK_AWAY,
- G_CALLBACK(menu_chat_get_away_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- g_object_set_data_full(G_OBJECT(button), "user_data", g_strdup(who), g_free);
- }
-
- if (!is_me && !(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME)) {
-- if (gaim_find_buddy(gc->account, who))
-- button = gaim_new_item_from_stock(menu, _("Remove"), GTK_STOCK_REMOVE,
-+ if (gaim2_find_buddy(gc->account, who))
-+ button = gaim2_new_item_from_stock(menu, _("Remove"), GTK_STOCK_REMOVE,
- G_CALLBACK(menu_chat_add_remove_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- else
-- button = gaim_new_item_from_stock(menu, _("Add"), GTK_STOCK_ADD,
-+ button = gaim2_new_item_from_stock(menu, _("Add"), GTK_STOCK_ADD,
- G_CALLBACK(menu_chat_add_remove_cb), GAIM_GTK_CONVERSATION(conv), 0, 0, NULL);
- g_object_set_data_full(G_OBJECT(button), "user_data", g_strdup(who), g_free);
- }
-@@ -1581,13 +1581,13 @@ create_chat_menu(GaimConversation *conv,
-
-
- static gint
--gtkconv_chat_popup_menu_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+gtkconv_chat_popup_menu_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimGtkChatPane *gtkchat;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- GtkTreeSelection *sel;
- GtkTreeIter iter;
- GtkTreeModel *model;
-@@ -1596,7 +1596,7 @@ gtkconv_chat_popup_menu_cb(GtkWidget *wi
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkchat = gtkconv->u.chat;
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
- gc = account->gc;
-
- model = gtk_tree_view_get_model(GTK_TREE_VIEW(gtkchat->list));
-@@ -1611,7 +1611,7 @@ gtkconv_chat_popup_menu_cb(GtkWidget *wi
- gtk_tree_model_get(GTK_TREE_MODEL(model), &iter, CHAT_USERS_NAME_COLUMN, &who, -1);
- menu = create_chat_menu (conv, who, prpl_info, gc);
- gtk_menu_popup(GTK_MENU(menu), NULL, NULL,
-- gaim_gtk_treeview_popup_menu_position_func, widget,
-+ gaim2_gtk_treeview_popup_menu_position_func, widget,
- 0, GDK_CURRENT_TIME);
- g_free(who);
-
-@@ -1621,13 +1621,13 @@ gtkconv_chat_popup_menu_cb(GtkWidget *wi
-
- static gint
- right_click_chat_cb(GtkWidget *widget, GdkEventButton *event,
-- GaimGtkConversation *gtkconv)
-+ Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimGtkChatPane *gtkchat;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- GtkTreePath *path;
- GtkTreeIter iter;
- GtkTreeModel *model;
-@@ -1636,7 +1636,7 @@ right_click_chat_cb(GtkWidget *widget, G
- int x, y;
-
- gtkchat = gtkconv->u.chat;
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
- gc = account->gc;
-
- model = gtk_tree_view_get_model(GTK_TREE_VIEW(gtkchat->list));
-@@ -1671,19 +1671,19 @@ right_click_chat_cb(GtkWidget *widget, G
- }
-
- static void
--move_to_next_unread_tab(GaimGtkConversation *gtkconv, gboolean forward)
-+move_to_next_unread_tab(Gaim2GtkConversation *gtkconv, gboolean forward)
- {
-- GaimGtkConversation *next_gtkconv = NULL;
-- GaimGtkWindow *win;
-+ Gaim2GtkConversation *next_gtkconv = NULL;
-+ Gaim2GtkWindow *win;
- int index, i, total, found = 0;
-
- win = gtkconv->win;
- index = gtk_notebook_page_num(GTK_NOTEBOOK(win->notebook), gtkconv->tab_cont);
-- total = gaim_gtk_conv_window_get_gtkconv_count(win);
-+ total = gaim2_gtk_conv_window_get_gtkconv_count(win);
-
- /* First check the tabs after (forward) or before (!forward) this position. */
- for (i = forward ? index + 1 : index - 1;
-- !found && (next_gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(win, i));
-+ !found && (next_gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(win, i));
- forward ? i++ : i--) {
- if (i == -1) {
- break;
-@@ -1697,7 +1697,7 @@ move_to_next_unread_tab(GaimGtkConversat
- /* Now check from the beginning up to (forward) or end back to (!forward) this position. */
- for (i = forward ? 0 : total - 1;
- !found && (forward ? i < index : i >= 0) &&
-- (next_gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(win, i));
-+ (next_gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(win, i));
- forward ? i++ : i--) {
-
- if (next_gtkconv->unseen_state > 0)
-@@ -1712,24 +1712,24 @@ move_to_next_unread_tab(GaimGtkConversat
- else {
- index = (index == 0) ? total - 1 : index - 1;
- }
-- if (!(next_gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(win, index)))
-- next_gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(win, 0);
-+ if (!(next_gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(win, index)))
-+ next_gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(win, 0);
- }
- }
-
- if (next_gtkconv != NULL && next_gtkconv != gtkconv)
-- gaim_gtk_conv_window_switch_gtkconv(win, next_gtkconv);
-+ gaim2_gtk_conv_window_switch_gtkconv(win, next_gtkconv);
- }
-
- static gboolean
- entry_key_press_cb(GtkWidget *entry, GdkEventKey *event, gpointer data)
- {
-- GaimGtkWindow *win;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- int curconv;
-
-- gtkconv = (GaimGtkConversation *)data;
-+ gtkconv = (Gaim2GtkConversation *)data;
- conv = gtkconv->active_conv;
- win = gtkconv->win;
- curconv = gtk_notebook_get_current_page(GTK_NOTEBOOK(win->notebook));
-@@ -1828,7 +1828,7 @@ entry_key_press_cb(GtkWidget *entry, Gdk
-
- case GDK_Page_Down:
- case ']':
-- if (!gaim_gtk_conv_window_get_gtkconv_at_index(win, curconv + 1))
-+ if (!gaim2_gtk_conv_window_get_gtkconv_at_index(win, curconv + 1))
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook), 0);
- else
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook), curconv + 1);
-@@ -1837,7 +1837,7 @@ entry_key_press_cb(GtkWidget *entry, Gdk
-
- case GDK_Page_Up:
- case '[':
-- if (!gaim_gtk_conv_window_get_gtkconv_at_index(win, curconv - 1))
-+ if (!gaim2_gtk_conv_window_get_gtkconv_at_index(win, curconv - 1))
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook), -1);
- else
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook), curconv - 1);
-@@ -1880,7 +1880,7 @@ entry_key_press_cb(GtkWidget *entry, Gdk
- if (event->keyval > '0' && event->keyval <= '9')
- {
- guint switchto = event->keyval - '1';
-- if (switchto < gaim_gtk_conv_window_get_gtkconv_count(win))
-+ if (switchto < gaim2_gtk_conv_window_get_gtkconv_count(win))
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook), switchto);
-
- return TRUE;
-@@ -1941,7 +1941,7 @@ entry_stop_rclick_cb(GtkWidget *widget,
- static gboolean
- refocus_entry_cb(GtkWidget *widget, GdkEventKey *event, gpointer data)
- {
-- GaimGtkConversation *gtkconv = data;
-+ Gaim2GtkConversation *gtkconv = data;
-
- /* If we have a valid key for the conversation display, then exit */
- if ((event->state & GDK_CONTROL_MASK) ||
-@@ -1968,9 +1968,9 @@ refocus_entry_cb(GtkWidget *widget, GdkE
- }
-
- static void
--gaim_gtkconv_set_active_conversation(GaimConversation *conv)
-+gaim2_gtkconv_set_active_conversation(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- g_return_if_fail(conv != NULL);
-
-@@ -1979,26 +1979,26 @@ gaim_gtkconv_set_active_conversation(Gai
- if (gtkconv->active_conv == conv)
- return;
-
-- gaim_conversation_close_logs(gtkconv->active_conv);
-+ gaim2_conversation_close_logs(gtkconv->active_conv);
-
- gtkconv->active_conv = conv;
-
-- gaim_conversation_set_logging(conv,
-+ gaim2_conversation_set_logging(conv,
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(gtkconv->win->menu.logging)));
-
-- gaim_signal_emit(gaim_gtk_conversations_get_handle(), "conversation-switched", conv);
-+ gaim2_signal_emit(gaim2_gtk_conversations_get_handle(), "conversation-switched", conv);
- }
-
- void
--gaim_gtkconv_switch_active_conversation(GaimConversation *conv)
-+gaim2_gtkconv_switch_active_conversation(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- g_return_if_fail(conv != NULL);
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
-- gaim_gtkconv_set_active_conversation(conv);
-+ gaim2_gtkconv_set_active_conversation(conv);
-
- gray_stuff_out(gtkconv);
- update_typing_icon(gtkconv);
-@@ -2006,37 +2006,37 @@ gaim_gtkconv_switch_active_conversation(
- gtk_window_set_title(GTK_WINDOW(gtkconv->win->window),
- gtk_label_get_text(GTK_LABEL(gtkconv->tab_label)));
-
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_ACCOUNT);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_ACCOUNT);
- gtk_imhtml_set_protocol_name(GTK_IMHTML(gtkconv->entry),
-- gaim_account_get_protocol_name(conv->account));
-+ gaim2_account_get_protocol_name(conv->account));
- }
-
- static void
- menu_conv_sel_send_cb(GObject *m, gpointer data)
- {
-- GaimAccount *account = g_object_get_data(m, "gaim_account");
-- gchar *name = g_object_get_data(m, "gaim_buddy_name");
-- GaimConversation *conv;
-+ Gaim2Account *account = g_object_get_data(m, "gaim2_account");
-+ gchar *name = g_object_get_data(m, "gaim2_buddy_name");
-+ Gaim2Conversation *conv;
-
- if (gtk_check_menu_item_get_active((GtkCheckMenuItem*) m) == FALSE)
- return;
-
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, name);
-- gaim_gtkconv_switch_active_conversation(conv);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, name);
-+ gaim2_gtkconv_switch_active_conversation(conv);
- }
-
- static void
- insert_text_cb(GtkTextBuffer *textbuffer, GtkTextIter *position,
- gchar *new_text, gint new_text_length, gpointer user_data)
- {
-- GaimGtkConversation *gtkconv = (GaimGtkConversation *)user_data;
-- GaimConversation *conv;
-+ Gaim2GtkConversation *gtkconv = (Gaim2GtkConversation *)user_data;
-+ Gaim2Conversation *conv;
-
- g_return_if_fail(gtkconv != NULL);
-
- conv = gtkconv->active_conv;
-
-- if (!gaim_prefs_get_bool("/core/conversations/im/send_typing"))
-+ if (!gaim2_prefs_get_bool("/core/conversations/im/send_typing"))
- return;
-
- got_typing_keypress(gtkconv, (gtk_text_iter_is_start(position) &&
-@@ -2047,15 +2047,15 @@ static void
- delete_text_cb(GtkTextBuffer *textbuffer, GtkTextIter *start_pos,
- GtkTextIter *end_pos, gpointer user_data)
- {
-- GaimGtkConversation *gtkconv = (GaimGtkConversation *)user_data;
-- GaimConversation *conv;
-- GaimConvIm *im;
-+ Gaim2GtkConversation *gtkconv = (Gaim2GtkConversation *)user_data;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvIm *im;
-
- g_return_if_fail(gtkconv != NULL);
-
- conv = gtkconv->active_conv;
-
-- if (!gaim_prefs_get_bool("/core/conversations/im/send_typing"))
-+ if (!gaim2_prefs_get_bool("/core/conversations/im/send_typing"))
- return;
-
- im = GAIM_CONV_IM(conv);
-@@ -2063,11 +2063,11 @@ delete_text_cb(GtkTextBuffer *textbuffer
- if (gtk_text_iter_is_start(start_pos) && gtk_text_iter_is_end(end_pos)) {
-
- /* We deleted all the text, so turn off typing. */
-- if (gaim_conv_im_get_type_again_timeout(im))
-- gaim_conv_im_stop_type_again_timeout(im);
-+ if (gaim2_conv_im_get_type_again_timeout(im))
-+ gaim2_conv_im_stop_type_again_timeout(im);
-
-- serv_send_typing(gaim_conversation_get_gc(conv),
-- gaim_conversation_get_name(conv),
-+ serv_send_typing(gaim2_conversation_get_gc(conv),
-+ gaim2_conversation_get_name(conv),
- GAIM_NOT_TYPING);
- }
- else {
-@@ -2080,31 +2080,31 @@ delete_text_cb(GtkTextBuffer *textbuffer
- * A bunch of buddy icon functions
- **************************************************************************/
- GdkPixbuf *
--gaim_gtkconv_get_tab_icon(GaimConversation *conv, gboolean small_icon)
-+gaim2_gtkconv_get_tab_icon(Gaim2Conversation *conv, gboolean small_icon)
- {
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- const char *name = NULL;
- GdkPixbuf *status = NULL;
-
- g_return_val_if_fail(conv != NULL, NULL);
-
-- account = gaim_conversation_get_account(conv);
-- name = gaim_conversation_get_name(conv);
-+ account = gaim2_conversation_get_account(conv);
-+ name = gaim2_conversation_get_name(conv);
-
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-- GaimBuddy *b = gaim_find_buddy(account, name);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ Gaim2Buddy *b = gaim2_find_buddy(account, name);
- if (b != NULL) {
-- status = gaim_gtk_blist_get_status_icon((GaimBlistNode*)b,
-+ status = gaim2_gtk_blist_get_status_icon((Gaim2BlistNode*)b,
- (small_icon ? GAIM_STATUS_ICON_SMALL : GAIM_STATUS_ICON_LARGE));
- }
- }
-
- if (!status) {
- GdkPixbuf *pixbuf;
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (small_icon && pixbuf != NULL)
- {
-@@ -2119,11 +2119,11 @@ gaim_gtkconv_get_tab_icon(GaimConversati
- }
-
- static void
--update_tab_icon(GaimConversation *conv)
-+update_tab_icon(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-- GaimAccount *account;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-+ Gaim2Account *account;
- const char *name;
- GdkPixbuf *status = NULL;
-
-@@ -2131,10 +2131,10 @@ update_tab_icon(GaimConversation *conv)
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- win = gtkconv->win;
-- name = gaim_conversation_get_name(conv);
-- account = gaim_conversation_get_account(conv);
-+ name = gaim2_conversation_get_name(conv);
-+ account = gaim2_conversation_get_account(conv);
-
-- status = gaim_gtkconv_get_tab_icon(conv, TRUE);
-+ status = gaim2_gtkconv_get_tab_icon(conv, TRUE);
-
- g_return_if_fail(status != NULL);
-
-@@ -2144,11 +2144,11 @@ update_tab_icon(GaimConversation *conv)
- if (status != NULL)
- g_object_unref(status);
-
-- if (gaim_gtk_conv_window_is_active_conversation(conv) &&
-- (gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_IM ||
-+ if (gaim2_gtk_conv_window_is_active_conversation(conv) &&
-+ (gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_IM ||
- gtkconv->u.im->anim == NULL))
- {
-- status = gaim_gtkconv_get_tab_icon(conv, FALSE);
-+ status = gaim2_gtkconv_get_tab_icon(conv, FALSE);
-
- gtk_window_set_icon(GTK_WINDOW(win->window), status);
-
-@@ -2160,10 +2160,10 @@ update_tab_icon(GaimConversation *conv)
- static gboolean
- redraw_icon(gpointer data)
- {
-- GaimGtkConversation *gtkconv = (GaimGtkConversation *)data;
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimAccount *account;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2GtkConversation *gtkconv = (Gaim2GtkConversation *)data;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2Account *account;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- GdkPixbuf *buf;
- GdkPixbuf *scale;
-@@ -2173,14 +2173,14 @@ redraw_icon(gpointer data)
- int scale_width, scale_height;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
- if(account && account->gc)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(account->gc->prpl);
-
- gdk_pixbuf_animation_iter_advance(gtkconv->u.im->iter, NULL);
- buf = gdk_pixbuf_animation_iter_get_pixbuf(gtkconv->u.im->iter);
-
-- gaim_gtk_buddy_icon_get_scale_size(buf, prpl_info ? &prpl_info->icon_spec :
-+ gaim2_gtk_buddy_icon_get_scale_size(buf, prpl_info ? &prpl_info->icon_spec :
- NULL, &scale_width, &scale_height);
-
- /* this code is ugly, and scares me */
-@@ -2211,7 +2211,7 @@ redraw_icon(gpointer data)
- }
-
- static void
--start_anim(GtkObject *obj, GaimGtkConversation *gtkconv)
-+start_anim(GtkObject *obj, Gaim2GtkConversation *gtkconv)
- {
- int delay;
-
-@@ -2233,10 +2233,10 @@ start_anim(GtkObject *obj, GaimGtkConver
- }
-
- static void
--remove_icon(GaimGtkConversation *gtkconv)
-+remove_icon(Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimGtkWindow *gtkwin;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2GtkWindow *gtkwin;
-
- g_return_if_fail(conv != NULL);
-
-@@ -2266,23 +2266,23 @@ remove_icon(GaimGtkConversation *gtkconv
- static void
- saveicon_writefile_cb(void *user_data, const char *filename)
- {
-- GaimGtkConversation *gtkconv = (GaimGtkConversation *)user_data;
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2GtkConversation *gtkconv = (Gaim2GtkConversation *)user_data;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
- FILE *fp;
-- GaimBuddyIcon *icon;
-+ Gaim2BuddyIcon *icon;
- const void *data;
- size_t len;
-
- if ((fp = g_fopen(filename, "wb")) == NULL) {
-- gaim_notify_error(conv, NULL, _("Unable to open file."), NULL);
-+ gaim2_notify_error(conv, NULL, _("Unable to open file."), NULL);
- return;
- }
-
-- icon = gaim_conv_im_get_icon(GAIM_CONV_IM(conv));
-- data = gaim_buddy_icon_get_data(icon, &len);
-+ icon = gaim2_conv_im_get_icon(GAIM_CONV_IM(conv));
-+ data = gaim2_buddy_icon_get_data(icon, &len);
-
- if ((len <= 0) || (data == NULL)) {
-- gaim_notify_error(conv, NULL, _("Unable to save icon file to disk."), NULL);
-+ gaim2_notify_error(conv, NULL, _("Unable to save icon file to disk."), NULL);
- return;
- }
-
-@@ -2291,28 +2291,28 @@ saveicon_writefile_cb(void *user_data, c
- }
-
- static void
--icon_menu_save_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+icon_menu_save_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
- const gchar *ext;
- gchar *buf;
-
- g_return_if_fail(conv != NULL);
-
-- ext = gaim_buddy_icon_get_type(gaim_conv_im_get_icon(GAIM_CONV_IM(conv)));
-+ ext = gaim2_buddy_icon_get_type(gaim2_conv_im_get_icon(GAIM_CONV_IM(conv)));
- if (ext == NULL)
- ext = "icon";
-
-- buf = g_strdup_printf("%s.%s", gaim_normalize(conv->account, conv->name), ext);
-+ buf = g_strdup_printf("%s.%s", gaim2_normalize(conv->account, conv->name), ext);
-
-- gaim_request_file(conv, _("Save Icon"), buf, TRUE,
-+ gaim2_request_file(conv, _("Save Icon"), buf, TRUE,
- G_CALLBACK(saveicon_writefile_cb), NULL, gtkconv);
-
- g_free(buf);
- }
-
- static void
--stop_anim(GtkObject *obj, GaimGtkConversation *gtkconv)
-+stop_anim(GtkObject *obj, Gaim2GtkConversation *gtkconv)
- {
- if (gtkconv->u.im->icon_timer != 0)
- g_source_remove(gtkconv->u.im->icon_timer);
-@@ -2322,7 +2322,7 @@ stop_anim(GtkObject *obj, GaimGtkConvers
-
-
- static void
--toggle_icon_animate_cb(GtkWidget *w, GaimGtkConversation *gtkconv)
-+toggle_icon_animate_cb(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
- gtkconv->u.im->animate =
- gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(w));
-@@ -2334,7 +2334,7 @@ toggle_icon_animate_cb(GtkWidget *w, Gai
- }
-
- static gboolean
--icon_menu(GtkObject *obj, GdkEventButton *e, GaimGtkConversation *gtkconv)
-+icon_menu(GtkObject *obj, GdkEventButton *e, Gaim2GtkConversation *gtkconv)
- {
- static GtkWidget *menu = NULL;
- GtkWidget *button;
-@@ -2354,7 +2354,7 @@ icon_menu(GtkObject *obj, GdkEventButton
- if (gtkconv->u.im->anim &&
- !(gdk_pixbuf_animation_is_static_image(gtkconv->u.im->anim)))
- {
-- gaim_new_check_item(menu, _("Animate"),
-+ gaim2_new_check_item(menu, _("Animate"),
- G_CALLBACK(toggle_icon_animate_cb), gtkconv,
- gtkconv->u.im->icon_timer);
- }
-@@ -2365,7 +2365,7 @@ icon_menu(GtkObject *obj, GdkEventButton
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), button);
- gtk_widget_show(button);
-
-- gaim_new_item_from_stock(menu, _("Save Icon As..."), GTK_STOCK_SAVE_AS,
-+ gaim2_new_item_from_stock(menu, _("Save Icon As..."), GTK_STOCK_SAVE_AS,
- G_CALLBACK(icon_menu_save_cb), gtkconv,
- 0, 0, NULL);
-
-@@ -2377,24 +2377,24 @@ icon_menu(GtkObject *obj, GdkEventButton
- static void
- menu_buddyicon_cb(gpointer data, guint action, GtkWidget *widget)
- {
-- GaimGtkWindow *win = data;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win = data;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- gboolean active;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (!conv)
- return;
-
-- g_return_if_fail(gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM);
-+ g_return_if_fail(gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM);
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- active = gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(widget));
- gtkconv->u.im->show_icon = active;
- if (active)
-- gaim_gtkconv_update_buddy_icon(conv);
-+ gaim2_gtkconv_update_buddy_icon(conv);
- else
- remove_icon(gtkconv);
- }
-@@ -2403,24 +2403,24 @@ menu_buddyicon_cb(gpointer data, guint a
- * End of the bunch of buddy icon functions
- **************************************************************************/
- void
--gaim_gtkconv_present_conversation(GaimConversation *conv)
-+gaim2_gtkconv_present_conversation(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- if(gtkconv->win==hidden_convwin) {
-- gaim_gtk_conv_window_remove_gtkconv(hidden_convwin, gtkconv);
-- gaim_gtkconv_placement_place(gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(hidden_convwin, gtkconv);
-+ gaim2_gtkconv_placement_place(gtkconv);
- }
-
-- gaim_gtkconv_set_active_conversation(conv);
-- gaim_gtk_conv_window_switch_gtkconv(gtkconv->win, gtkconv);
-- gaim_gtk_conv_window_raise(gtkconv->win);
-+ gaim2_gtkconv_set_active_conversation(conv);
-+ gaim2_gtk_conv_window_switch_gtkconv(gtkconv->win, gtkconv);
-+ gaim2_gtk_conv_window_raise(gtkconv->win);
- gtk_window_present(GTK_WINDOW(gtkconv->win->window));
- }
-
- GList *
--gaim_gtk_conversations_find_unseen_list(GaimConversationType type,
-- GaimUnseenState min_state,
-+gaim2_gtk_conversations_find_unseen_list(Gaim2ConversationType type,
-+ Gaim2UnseenState min_state,
- gboolean hidden_only,
- guint max_count)
- {
-@@ -2429,16 +2429,16 @@ gaim_gtk_conversations_find_unseen_list(
- guint c = 0;
-
- if (type == GAIM_CONV_TYPE_IM) {
-- l = gaim_get_ims();
-+ l = gaim2_get_ims();
- } else if (type == GAIM_CONV_TYPE_CHAT) {
-- l = gaim_get_chats();
-+ l = gaim2_get_chats();
- } else {
-- l = gaim_get_conversations();
-+ l = gaim2_get_conversations();
- }
-
- for (; l != NULL && (max_count == 0 || c < max_count); l = l->next) {
-- GaimConversation *conv = (GaimConversation*)l->data;
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2Conversation *conv = (Gaim2Conversation*)l->data;
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- if(gtkconv->active_conv != conv)
- continue;
-@@ -2456,14 +2456,14 @@ gaim_gtk_conversations_find_unseen_list(
- }
-
- static void
--unseen_conv_menu_cb(GtkMenuItem *item, GaimConversation *conv)
-+unseen_conv_menu_cb(GtkMenuItem *item, Gaim2Conversation *conv)
- {
- g_return_if_fail(conv != NULL);
-- gaim_gtkconv_present_conversation(conv);
-+ gaim2_gtkconv_present_conversation(conv);
- }
-
- guint
--gaim_gtk_conversations_fill_menu(GtkWidget *menu, GList *convs)
-+gaim2_gtk_conversations_fill_menu(GtkWidget *menu, GList *convs)
- {
- GList *l;
- guint ret=0;
-@@ -2472,11 +2472,11 @@ gaim_gtk_conversations_fill_menu(GtkWidg
- g_return_val_if_fail(convs != NULL, 0);
-
- for (l = convs; l != NULL ; l = l->next) {
-- GaimConversation *conv = (GaimConversation*)l->data;
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2Conversation *conv = (Gaim2Conversation*)l->data;
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- GtkWidget *icon = gtk_image_new();
-- GdkPixbuf *pbuf = gaim_gtkconv_get_tab_icon(conv, TRUE);
-+ GdkPixbuf *pbuf = gaim2_gtkconv_get_tab_icon(conv, TRUE);
- GtkWidget *item;
- gchar *text = g_strdup_printf("%s (%d)",
- gtk_label_get_text(GTK_LABEL(gtkconv->tab_label)),
-@@ -2496,8 +2496,8 @@ gaim_gtk_conversations_fill_menu(GtkWidg
- return ret;
- }
-
--GaimGtkWindow *
--gaim_gtkconv_get_window(GaimGtkConversation *gtkconv)
-+Gaim2GtkWindow *
-+gaim2_gtkconv_get_window(Gaim2GtkConversation *gtkconv)
- {
- g_return_val_if_fail(gtkconv != NULL, NULL);
- return gtkconv->win;
-@@ -2573,9 +2573,9 @@ item_factory_translate_func (const char
- }
-
- static void
--sound_method_pref_changed_cb(const char *name, GaimPrefType type, gpointer value, gpointer data)
-+sound_method_pref_changed_cb(const char *name, Gaim2PrefType type, gpointer value, gpointer data)
- {
-- GaimGtkWindow *win = data;
-+ Gaim2GtkWindow *win = data;
- const char *method = value;
-
- if (!strcmp(method, "none"))
-@@ -2586,7 +2586,7 @@ sound_method_pref_changed_cb(const char
- }
- else
- {
-- GaimGtkConversation *gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ Gaim2GtkConversation *gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
-
- if (gtkconv != NULL)
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.sounds),
-@@ -2597,9 +2597,9 @@ sound_method_pref_changed_cb(const char
- }
-
- static void
--show_buddy_icons_pref_changed_cb(const char *name, GaimPrefType type, gpointer value, gpointer data)
-+show_buddy_icons_pref_changed_cb(const char *name, Gaim2PrefType type, gpointer value, gpointer data)
- {
-- GaimGtkWindow *win = data;
-+ Gaim2GtkWindow *win = data;
- gboolean show_icons = GPOINTER_TO_INT(value);
-
- if (!show_icons)
-@@ -2610,7 +2610,7 @@ show_buddy_icons_pref_changed_cb(const c
- }
- else
- {
-- GaimGtkConversation *gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ Gaim2GtkConversation *gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
-
- if (gtkconv != NULL)
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.show_icon),
-@@ -2622,7 +2622,7 @@ show_buddy_icons_pref_changed_cb(const c
-
-
- static GtkWidget *
--setup_menubar(GaimGtkWindow *win)
-+setup_menubar(Gaim2GtkWindow *win)
- {
- GtkAccelGroup *accel_group;
- const char *method;
-@@ -2641,7 +2641,7 @@ setup_menubar(GaimGtkWindow *win)
- gtk_item_factory_create_items(win->menu.item_factory, menu_item_count,
- menu_items, win);
- g_signal_connect(G_OBJECT(accel_group), "accel-changed",
-- G_CALLBACK(gaim_gtk_save_accels_cb), NULL);
-+ G_CALLBACK(gaim2_gtk_save_accels_cb), NULL);
-
-
- win->menu.menubar =
-@@ -2708,14 +2708,14 @@ setup_menubar(GaimGtkWindow *win)
- win->menu.sounds =
- gtk_item_factory_get_widget(win->menu.item_factory,
- N_("/Options/Enable Sounds"));
-- method = gaim_prefs_get_string("/gaim/gtk/sound/method");
-+ method = gaim2_prefs_get_string("/gaim2/gtk/sound/method");
- if (!strcmp(method, "none"))
- {
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.sounds),
- FALSE);
- gtk_widget_set_sensitive(win->menu.sounds, FALSE);
- }
-- gaim_prefs_connect_callback(win, "/gaim/gtk/sound/method",
-+ gaim2_prefs_connect_callback(win, "/gaim2/gtk/sound/method",
- sound_method_pref_changed_cb, win);
-
- win->menu.show_formatting_toolbar =
-@@ -2727,16 +2727,16 @@ setup_menubar(GaimGtkWindow *win)
- win->menu.show_icon =
- gtk_item_factory_get_widget(win->menu.item_factory,
- N_("/Options/Show Buddy Icon"));
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/im/show_buddy_icons"))
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/im/show_buddy_icons"))
- {
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.show_icon),
- FALSE);
- gtk_widget_set_sensitive(win->menu.show_icon, FALSE);
- }
-- gaim_prefs_connect_callback(win, "/gaim/gtk/conversations/im/show_buddy_icons",
-+ gaim2_prefs_connect_callback(win, "/gaim2/gtk/conversations/im/show_buddy_icons",
- show_buddy_icons_pref_changed_cb, win);
-
-- win->menu.tray = gaim_gtk_menu_tray_new();
-+ win->menu.tray = gaim2_gtk_menu_tray_new();
- gtk_menu_shell_append(GTK_MENU_SHELL(win->menu.menubar),
- win->menu.tray);
- gtk_widget_show(win->menu.tray);
-@@ -2752,10 +2752,10 @@ setup_menubar(GaimGtkWindow *win)
- **************************************************************************/
-
- static void
--got_typing_keypress(GaimGtkConversation *gtkconv, gboolean first)
-+got_typing_keypress(Gaim2GtkConversation *gtkconv, gboolean first)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimConvIm *im;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2ConvIm *im;
-
- /*
- * We know we got something, so we at least have to make sure we don't
-@@ -2764,46 +2764,46 @@ got_typing_keypress(GaimGtkConversation
-
- im = GAIM_CONV_IM(conv);
-
-- if (gaim_conv_im_get_type_again_timeout(im))
-- gaim_conv_im_stop_type_again_timeout(im);
-+ if (gaim2_conv_im_get_type_again_timeout(im))
-+ gaim2_conv_im_stop_type_again_timeout(im);
-
-- gaim_conv_im_start_type_again_timeout(im);
-+ gaim2_conv_im_start_type_again_timeout(im);
-
-- if (first || (gaim_conv_im_get_type_again(im) != 0 &&
-- time(NULL) > gaim_conv_im_get_type_again(im))) {
-+ if (first || (gaim2_conv_im_get_type_again(im) != 0 &&
-+ time(NULL) > gaim2_conv_im_get_type_again(im))) {
-
-- int timeout = serv_send_typing(gaim_conversation_get_gc(conv),
-- (char *)gaim_conversation_get_name(conv),
-+ int timeout = serv_send_typing(gaim2_conversation_get_gc(conv),
-+ (char *)gaim2_conversation_get_name(conv),
- GAIM_TYPING);
-
- if (timeout)
-- gaim_conv_im_set_type_again(im, time(NULL) + timeout);
-+ gaim2_conv_im_set_type_again(im, time(NULL) + timeout);
- else
-- gaim_conv_im_set_type_again(im, 0);
-+ gaim2_conv_im_set_type_again(im, 0);
- }
- }
-
- static void
--update_typing_icon(GaimGtkConversation *gtkconv)
-+update_typing_icon(Gaim2GtkConversation *gtkconv)
- {
-- GaimGtkWindow *gtkwin;
-- GaimConvIm *im = NULL;
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2GtkWindow *gtkwin;
-+ Gaim2ConvIm *im = NULL;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
- char *stock_id, *tooltip;
-
- gtkwin = gtkconv->win;
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- im = GAIM_CONV_IM(conv);
-
- if (gtkwin->menu.typing_icon) {
- gtk_widget_hide(gtkwin->menu.typing_icon);
- }
-
-- if (!im || (gaim_conv_im_get_typing_state(im) == GAIM_NOT_TYPING))
-+ if (!im || (gaim2_conv_im_get_typing_state(im) == GAIM_NOT_TYPING))
- return;
-
-- if (gaim_conv_im_get_typing_state(im) == GAIM_TYPING) {
-+ if (gaim2_conv_im_get_typing_state(im) == GAIM_TYPING) {
- stock_id = GAIM_STOCK_TYPING;
- tooltip = _("User is typing...");
- } else {
-@@ -2814,14 +2814,14 @@ update_typing_icon(GaimGtkConversation *
- if (gtkwin->menu.typing_icon == NULL)
- {
- gtkwin->menu.typing_icon = gtk_image_new_from_stock(stock_id, GTK_ICON_SIZE_MENU);
-- gaim_gtk_menu_tray_append(GAIM_GTK_MENU_TRAY(gtkwin->menu.tray),
-+ gaim2_gtk_menu_tray_append(GAIM_GTK_MENU_TRAY(gtkwin->menu.tray),
- gtkwin->menu.typing_icon,
- tooltip);
- }
- else
- {
- gtk_image_set_from_stock(GTK_IMAGE(gtkwin->menu.typing_icon), stock_id, GTK_ICON_SIZE_MENU);
-- gaim_gtk_menu_tray_set_tooltip(GAIM_GTK_MENU_TRAY(gtkwin->menu.tray),
-+ gaim2_gtk_menu_tray_set_tooltip(GAIM_GTK_MENU_TRAY(gtkwin->menu.tray),
- gtkwin->menu.typing_icon,
- tooltip);
- }
-@@ -2830,25 +2830,25 @@ update_typing_icon(GaimGtkConversation *
- }
-
- static gboolean
--update_send_to_selection(GaimGtkWindow *win)
-+update_send_to_selection(Gaim2GtkWindow *win)
- {
-- GaimAccount *account;
-- GaimConversation *conv;
-+ Gaim2Account *account;
-+ Gaim2Conversation *conv;
- GtkWidget *menu;
- GList *child;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (conv == NULL)
- return FALSE;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
-
- if (win->menu.send_to == NULL)
- return FALSE;
-
-- if (!(b = gaim_find_buddy(account, conv->name)))
-+ if (!(b = gaim2_find_buddy(account, conv->name)))
- return FALSE;
-
-
-@@ -2862,11 +2862,11 @@ update_send_to_selection(GaimGtkWindow *
- child = child->next) {
-
- GtkWidget *item = child->data;
-- GaimBuddy *item_buddy;
-- GaimAccount *item_account = g_object_get_data(G_OBJECT(item), "gaim_account");
-+ Gaim2Buddy *item_buddy;
-+ Gaim2Account *item_account = g_object_get_data(G_OBJECT(item), "gaim2_account");
- gchar *buddy_name = g_object_get_data(G_OBJECT(item),
-- "gaim_buddy_name");
-- item_buddy = gaim_find_buddy(item_account, buddy_name);
-+ "gaim2_buddy_name");
-+ item_buddy = gaim2_find_buddy(item_account, buddy_name);
-
- if (b == item_buddy) {
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(item), TRUE);
-@@ -2892,7 +2892,7 @@ send_to_item_leave_notify_cb(GtkWidget *
- }
-
- static void
--create_sendto_item(GtkWidget *menu, GtkSizeGroup *sg, GSList **group, GaimBuddy *buddy, GaimAccount *account, const char *name)
-+create_sendto_item(GtkWidget *menu, GtkSizeGroup *sg, GSList **group, Gaim2Buddy *buddy, Gaim2Account *account, const char *name)
- {
- GtkWidget *box;
- GtkWidget *label;
-@@ -2903,10 +2903,10 @@ create_sendto_item(GtkWidget *menu, GtkS
-
- /* Create a pixmap for the protocol icon. */
- if (buddy != NULL)
-- pixbuf = gaim_gtk_blist_get_status_icon((GaimBlistNode*)buddy, GAIM_STATUS_ICON_SMALL);
-+ pixbuf = gaim2_gtk_blist_get_status_icon((Gaim2BlistNode*)buddy, GAIM_STATUS_ICON_SMALL);
- else
- {
-- GdkPixbuf *unscaled = gaim_gtk_create_prpl_icon(account);
-+ GdkPixbuf *unscaled = gaim2_gtk_create_prpl_icon(account);
-
- /* XXX: 15 is the size for GAIM_STATUS_ICON_SMALL in gtkblist.c */
- pixbuf = gdk_pixbuf_scale_simple(unscaled, 15, 15,
-@@ -2925,7 +2925,7 @@ create_sendto_item(GtkWidget *menu, GtkS
- g_object_unref(G_OBJECT(pixbuf));
-
- /* Make our menu item */
-- text = g_strdup_printf("%s (%s)", name, gaim_account_get_username(account));
-+ text = g_strdup_printf("%s (%s)", name, gaim2_account_get_username(account));
- menuitem = gtk_radio_menu_item_new_with_label(*group, text);
- g_free(text);
- *group = gtk_radio_menu_item_get_group(GTK_RADIO_MENU_ITEM(menuitem));
-@@ -2941,8 +2941,8 @@ create_sendto_item(GtkWidget *menu, GtkS
- gtk_box_pack_start(GTK_BOX(box), label, TRUE, TRUE, 4);
-
- if (buddy != NULL &&
-- !gaim_presence_is_online(gaim_buddy_get_presence(buddy)) &&
-- !gaim_account_supports_offline_message(account, buddy))
-+ !gaim2_presence_is_online(gaim2_buddy_get_presence(buddy)) &&
-+ !gaim2_account_supports_offline_message(account, buddy))
- {
- gtk_widget_set_sensitive(label, FALSE);
-
-@@ -2965,8 +2965,8 @@ create_sendto_item(GtkWidget *menu, GtkS
- gtk_widget_show(box);
-
- /* Set our data and callbacks. */
-- g_object_set_data(G_OBJECT(menuitem), "gaim_account", account);
-- g_object_set_data_full(G_OBJECT(menuitem), "gaim_buddy_name", g_strdup(name), g_free);
-+ g_object_set_data(G_OBJECT(menuitem), "gaim2_account", account);
-+ g_object_set_data_full(G_OBJECT(menuitem), "gaim2_buddy_name", g_strdup(name), g_free);
-
- g_signal_connect(G_OBJECT(menuitem), "activate",
- G_CALLBACK(menu_conv_sel_send_cb), NULL);
-@@ -2976,17 +2976,17 @@ create_sendto_item(GtkWidget *menu, GtkS
- }
-
- static void
--generate_send_to_items(GaimGtkWindow *win)
-+generate_send_to_items(Gaim2GtkWindow *win)
- {
- GtkWidget *menu;
- GSList *group = NULL;
- GtkSizeGroup *sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GSList *l, *buds;
-
- g_return_if_fail(win != NULL);
-
-- gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
-
- g_return_if_fail(gtkconv != NULL);
-
-@@ -3005,7 +3005,7 @@ generate_send_to_items(GaimGtkWindow *wi
- gtk_widget_show(menu);
-
- if (gtkconv->active_conv->type == GAIM_CONV_TYPE_IM) {
-- buds = gaim_find_buddies(gtkconv->active_conv->account, gtkconv->active_conv->name);
-+ buds = gaim2_find_buddies(gtkconv->active_conv->account, gtkconv->active_conv->name);
-
- if (buds == NULL)
- {
-@@ -3016,21 +3016,21 @@ generate_send_to_items(GaimGtkWindow *wi
- {
- for (l = buds; l != NULL; l = l->next)
- {
-- GaimBlistNode *node;
-+ Gaim2BlistNode *node;
-
-- node = (GaimBlistNode *) gaim_buddy_get_contact((GaimBuddy *)l->data);
-+ node = (Gaim2BlistNode *) gaim2_buddy_get_contact((Gaim2Buddy *)l->data);
-
- for (node = node->child; node != NULL; node = node->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)node;
-- GaimAccount *account;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)node;
-+ Gaim2Account *account;
-
- if (!GAIM_BLIST_NODE_IS_BUDDY(node))
- continue;
-
-- account = gaim_buddy_get_account(buddy);
-- if (gaim_account_is_connected(account))
-- create_sendto_item(menu, sg, &group, buddy, account, gaim_buddy_get_name(buddy));
-+ account = gaim2_buddy_get_account(buddy);
-+ if (gaim2_account_is_connected(account))
-+ create_sendto_item(menu, sg, &group, buddy, account, gaim2_buddy_get_name(buddy));
- }
- }
-
-@@ -3048,9 +3048,9 @@ generate_send_to_items(GaimGtkWindow *wi
- }
-
- static GList *
--generate_invite_user_names(GaimConnection *gc)
-+generate_invite_user_names(Gaim2Connection *gc)
- {
-- GaimBlistNode *gnode,*cnode,*bnode;
-+ Gaim2BlistNode *gnode,*cnode,*bnode;
- static GList *tmp = NULL;
-
- if (tmp)
-@@ -3059,19 +3059,19 @@ generate_invite_user_names(GaimConnectio
- tmp = g_list_append(NULL, "");
-
- if (gc != NULL) {
-- for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for(gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for(bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
-
- if (buddy->account == gc->account &&
- GAIM_BUDDY_IS_ONLINE(buddy))
-@@ -3086,7 +3086,7 @@ generate_invite_user_names(GaimConnectio
- }
-
- static GdkPixbuf *
--get_chat_buddy_status_icon(GaimConvChat *chat, const char *name, GaimConvChatBuddyFlags flags)
-+get_chat_buddy_status_icon(Gaim2ConvChat *chat, const char *name, Gaim2ConvChatBuddyFlags flags)
- {
- GdkPixbuf *pixbuf, *scale, *scale2;
- char *filename;
-@@ -3100,13 +3100,13 @@ get_chat_buddy_status_icon(GaimConvChat
- image = "halfop.png";
- } else if (flags & GAIM_CBFLAGS_VOICE) {
- image = "voice.png";
-- } else if ((!flags) && gaim_conv_chat_is_user_ignored(chat, name)) {
-+ } else if ((!flags) && gaim2_conv_chat_is_user_ignored(chat, name)) {
- image = "ignored.png";
- } else {
- return NULL;
- }
-
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", image, NULL);
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", image, NULL);
- pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-
-@@ -3116,8 +3116,8 @@ get_chat_buddy_status_icon(GaimConvChat
- scale = gdk_pixbuf_scale_simple(pixbuf, 15, 15, GDK_INTERP_BILINEAR);
- g_object_unref(pixbuf);
-
-- if (flags && gaim_conv_chat_is_user_ignored(chat, name)) {
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default", "ignored.png", NULL);
-+ if (flags && gaim2_conv_chat_is_user_ignored(chat, name)) {
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default", "ignored.png", NULL);
- pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
- scale2 = gdk_pixbuf_scale_simple(pixbuf, 15, 15, GDK_INTERP_BILINEAR);
-@@ -3130,13 +3130,13 @@ get_chat_buddy_status_icon(GaimConvChat
- }
-
- static void
--add_chat_buddy_common(GaimConversation *conv, const char *name, GaimConvChatBuddyFlags flags, const char *alias, const char *old_name)
-+add_chat_buddy_common(Gaim2Conversation *conv, const char *name, Gaim2ConvChatBuddyFlags flags, const char *alias, const char *old_name)
- {
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-- GaimConvChat *chat;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
- GtkListStore *ls;
- GdkPixbuf *pixbuf;
- GtkTreeIter iter;
-@@ -3146,7 +3146,7 @@ add_chat_buddy_common(GaimConversation *
- chat = GAIM_CONV_CHAT(conv);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkchat = gtkconv->u.chat;
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (!gc || !(prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)))
- return;
-@@ -3155,10 +3155,10 @@ add_chat_buddy_common(GaimConversation *
-
- pixbuf = get_chat_buddy_status_icon(chat, name, flags);
-
-- if (!strcmp(chat->nick, gaim_normalize(conv->account, old_name != NULL ? old_name : name)))
-+ if (!strcmp(chat->nick, gaim2_normalize(conv->account, old_name != NULL ? old_name : name)))
- is_me = TRUE;
-
-- is_buddy = (gaim_find_buddy(conv->account, name) != NULL);
-+ is_buddy = (gaim2_find_buddy(conv->account, name) != NULL);
-
- gtk_list_store_append(ls, &iter);
-
-@@ -3198,7 +3198,7 @@ tab_complete_process_item(int *most_matc
- {
- strncpy(nick_partial, name, strlen(entered));
- nick_partial[strlen(entered)] = '\0';
-- if (gaim_utf8_strcasecmp(nick_partial, entered))
-+ if (gaim2_utf8_strcasecmp(nick_partial, entered))
- return;
-
- /* if we're here, it's a possible completion */
-@@ -3214,7 +3214,7 @@ tab_complete_process_item(int *most_matc
- else if (*most_matched) {
- char *tmp = g_strdup(name);
-
-- while (gaim_utf8_strcasecmp(tmp, *partial)) {
-+ while (gaim2_utf8_strcasecmp(tmp, *partial)) {
- (*partial)[*most_matched] = '\0';
- if (*most_matched < strlen(tmp))
- tmp[*most_matched] = '\0';
-@@ -3226,13 +3226,13 @@ tab_complete_process_item(int *most_matc
- }
-
- *matches = g_list_insert_sorted(*matches, g_strdup(name),
-- (GCompareFunc)gaim_utf8_strcasecmp);
-+ (GCompareFunc)gaim2_utf8_strcasecmp);
- }
-
- static gboolean
--tab_complete(GaimConversation *conv)
-+tab_complete(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GtkTextIter cursor, word_start, start_buffer;
- int start;
- int most_matched = -1;
-@@ -3253,7 +3253,7 @@ tab_complete(GaimConversation *conv)
-
- /* if there's nothing there just return */
- if (!gtk_text_iter_compare(&cursor, &start_buffer))
-- return (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) ? TRUE : FALSE;
-+ return (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) ? TRUE : FALSE;
-
- text = gtk_text_buffer_get_text(gtkconv->entry_buffer, &start_buffer,
- &cursor, FALSE);
-@@ -3272,7 +3272,7 @@ tab_complete(GaimConversation *conv)
- start--;
- }
-
-- prefix = gaim_gtk_get_cmd_prefix();
-+ prefix = gaim2_gtk_get_cmd_prefix();
- if (start == -1 && (strlen(text) >= strlen(prefix)) && !strncmp(text, prefix, strlen(prefix))) {
- command = TRUE;
- gtk_text_iter_forward_chars(&word_start, strlen(prefix));
-@@ -3285,13 +3285,13 @@ tab_complete(GaimConversation *conv)
-
- if (!g_utf8_strlen(entered, -1)) {
- g_free(entered);
-- return (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) ? TRUE : FALSE;
-+ return (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) ? TRUE : FALSE;
- }
-
- nick_partial = g_malloc(strlen(entered)+1);
-
- if (command) {
-- GList *list = gaim_cmd_list(conv);
-+ GList *list = gaim2_cmd_list(conv);
- GList *l;
-
- /* Commands */
-@@ -3300,9 +3300,9 @@ tab_complete(GaimConversation *conv)
- &matches, TRUE, l->data);
- }
- g_list_free(list);
-- } else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-- GaimConvChat *chat = GAIM_CONV_CHAT(conv);
-- GList *l = gaim_conv_chat_get_users(chat);
-+ } else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ Gaim2ConvChat *chat = GAIM_CONV_CHAT(conv);
-+ GList *l = gaim2_conv_chat_get_users(chat);
- GtkTreeModel *model = gtk_tree_view_get_model(GTK_TREE_VIEW(GAIM_GTK_CONVERSATION(conv)->u.chat->list));
- GtkTreeIter iter;
- int f;
-@@ -3310,7 +3310,7 @@ tab_complete(GaimConversation *conv)
- /* Users */
- for (; l != NULL; l = l->next) {
- tab_complete_process_item(&most_matched, entered, &partial, nick_partial,
-- &matches, TRUE, ((GaimConvChatBuddy *)l->data)->name);
-+ &matches, TRUE, ((Gaim2ConvChatBuddy *)l->data)->name);
- }
-
-
-@@ -3349,7 +3349,7 @@ tab_complete(GaimConversation *conv)
- if (!matches) {
- /* if matches isn't set partials won't be either */
- g_free(entered);
-- return (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) ? TRUE : FALSE;
-+ return (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) ? TRUE : FALSE;
- }
-
- gtk_text_buffer_delete(gtkconv->entry_buffer, &word_start, &cursor);
-@@ -3387,7 +3387,7 @@ tab_complete(GaimConversation *conv)
- matches = g_list_remove(matches, matches->data);
- }
-
-- gaim_conversation_write(conv, NULL, addthis, GAIM_MESSAGE_NO_LOG,
-+ gaim2_conversation_write(conv, NULL, addthis, GAIM_MESSAGE_NO_LOG,
- time(NULL));
- gtk_text_buffer_insert_at_cursor(gtkconv->entry_buffer, partial, -1);
- g_free(addthis);
-@@ -3399,16 +3399,16 @@ tab_complete(GaimConversation *conv)
- return TRUE;
- }
-
--static void topic_callback(GtkWidget *w, GaimGtkConversation *gtkconv)
-+static void topic_callback(GtkWidget *w, Gaim2GtkConversation *gtkconv)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc;
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimGtkChatPane *gtkchat;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2GtkChatPane *gtkchat;
- char *new_topic;
- const char *current_topic;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if(!gc || !(prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl)))
- return;
-@@ -3419,7 +3419,7 @@ static void topic_callback(GtkWidget *w,
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkchat = gtkconv->u.chat;
- new_topic = g_strdup(gtk_entry_get_text(GTK_ENTRY(gtkchat->topic_text)));
-- current_topic = gaim_conv_chat_get_topic(GAIM_CONV_CHAT(conv));
-+ current_topic = gaim2_conv_chat_get_topic(GAIM_CONV_CHAT(conv));
-
- if(current_topic && !g_utf8_collate(new_topic, current_topic)){
- g_free(new_topic);
-@@ -3428,7 +3428,7 @@ static void topic_callback(GtkWidget *w,
-
- gtk_entry_set_text(GTK_ENTRY(gtkchat->topic_text), current_topic);
-
-- prpl_info->set_chat_topic(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)),
-+ prpl_info->set_chat_topic(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)),
- new_topic);
-
- g_free(new_topic);
-@@ -3437,7 +3437,7 @@ static void topic_callback(GtkWidget *w,
- static gint
- sort_chat_users(GtkTreeModel *model, GtkTreeIter *a, GtkTreeIter *b, gpointer userdata)
- {
-- GaimConvChatBuddyFlags f1 = 0, f2 = 0;
-+ Gaim2ConvChatBuddyFlags f1 = 0, f2 = 0;
- char *user1 = NULL, *user2 = NULL;
- gboolean buddy1 = FALSE, buddy2 = FALSE;
- gint ret = 0;
-@@ -3462,7 +3462,7 @@ sort_chat_users(GtkTreeModel *model, Gtk
- } else if (buddy1 != buddy2) {
- ret = buddy1 ? -1 : 1;
- } else {
-- ret = gaim_utf8_strcasecmp(user1, user2);
-+ ret = gaim2_utf8_strcasecmp(user1, user2);
- }
-
- g_free(user1);
-@@ -3472,10 +3472,10 @@ sort_chat_users(GtkTreeModel *model, Gtk
- }
-
- static void
--update_chat_alias(GaimBuddy *buddy, GaimConversation *conv, GaimConnection *gc, GaimPluginProtocolInfo *prpl_info)
-+update_chat_alias(Gaim2Buddy *buddy, Gaim2Conversation *conv, Gaim2Connection *gc, Gaim2PluginProtocolInfo *prpl_info)
- {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-- GaimConvChat *chat = GAIM_CONV_CHAT(conv);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2ConvChat *chat = GAIM_CONV_CHAT(conv);
- GtkTreeModel *model;
- char *normalized_name;
- GtkTreeIter iter;
-@@ -3490,22 +3490,22 @@ update_chat_alias(GaimBuddy *buddy, Gaim
- if (!gtk_tree_model_get_iter_first(GTK_TREE_MODEL(model), &iter))
- return;
-
-- normalized_name = g_strdup(gaim_normalize(conv->account, buddy->name));
-+ normalized_name = g_strdup(gaim2_normalize(conv->account, buddy->name));
-
- do {
- char *name;
-
- gtk_tree_model_get(model, &iter, CHAT_USERS_NAME_COLUMN, &name, -1);
-
-- if (!strcmp(normalized_name, gaim_normalize(conv->account, name))) {
-+ if (!strcmp(normalized_name, gaim2_normalize(conv->account, name))) {
- const char *alias = name;
-- GaimBuddy *buddy2;
-+ Gaim2Buddy *buddy2;
-
-- if (strcmp(chat->nick, gaim_normalize(conv->account, name))) {
-+ if (strcmp(chat->nick, gaim2_normalize(conv->account, name))) {
- /* This user is not me, so look into updating the alias. */
-
-- if ((buddy2 = gaim_find_buddy(conv->account, name)) != NULL)
-- alias = gaim_buddy_get_contact_alias(buddy2);
-+ if ((buddy2 = gaim2_find_buddy(conv->account, name)) != NULL)
-+ alias = gaim2_buddy_get_contact_alias(buddy2);
-
- gtk_list_store_set(GTK_LIST_STORE(model), &iter,
- CHAT_USERS_ALIAS_COLUMN, alias,
-@@ -3524,15 +3524,15 @@ update_chat_alias(GaimBuddy *buddy, Gaim
- }
-
- static void
--blist_node_aliased_cb(GaimBlistNode *node, const char *old_alias, GaimConversation *conv)
-+blist_node_aliased_cb(Gaim2BlistNode *node, const char *old_alias, Gaim2Conversation *conv)
- {
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- g_return_if_fail(node != NULL);
- g_return_if_fail(conv != NULL);
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
- g_return_if_fail(gc != NULL);
- g_return_if_fail(gc->prpl != NULL);
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -3542,22 +3542,22 @@ blist_node_aliased_cb(GaimBlistNode *nod
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
- {
-- GaimBlistNode *bnode;
-+ Gaim2BlistNode *bnode;
-
- for(bnode = node->child; bnode; bnode = bnode->next) {
-
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- update_chat_alias((GaimBuddy *)bnode, conv, gc, prpl_info);
-+ update_chat_alias((Gaim2Buddy *)bnode, conv, gc, prpl_info);
- }
- }
- else if (GAIM_BLIST_NODE_IS_BUDDY(node))
-- update_chat_alias((GaimBuddy *)node, conv, gc, prpl_info);
-+ update_chat_alias((Gaim2Buddy *)node, conv, gc, prpl_info);
- }
-
- static void
--buddy_cb_common(GaimBuddy *buddy, GaimConversation *conv, gboolean is_buddy)
-+buddy_cb_common(Gaim2Buddy *buddy, Gaim2Conversation *conv, gboolean is_buddy)
- {
- GtkTreeModel *model;
- char *normalized_name;
-@@ -3568,7 +3568,7 @@ buddy_cb_common(GaimBuddy *buddy, GaimCo
- g_return_if_fail(conv != NULL);
-
- /* Do nothing if the buddy does not belong to the conv's account */
-- if (gaim_buddy_get_account(buddy) != gaim_conversation_get_account(conv))
-+ if (gaim2_buddy_get_account(buddy) != gaim2_conversation_get_account(conv))
- return;
-
- /* This is safe because this callback is only used in chats, not IMs. */
-@@ -3577,14 +3577,14 @@ buddy_cb_common(GaimBuddy *buddy, GaimCo
- if (!gtk_tree_model_get_iter_first(GTK_TREE_MODEL(model), &iter))
- return;
-
-- normalized_name = g_strdup(gaim_normalize(conv->account, buddy->name));
-+ normalized_name = g_strdup(gaim2_normalize(conv->account, buddy->name));
-
- do {
- char *name;
-
- gtk_tree_model_get(model, &iter, CHAT_USERS_NAME_COLUMN, &name, -1);
-
-- if (!strcmp(normalized_name, gaim_normalize(conv->account, name))) {
-+ if (!strcmp(normalized_name, gaim2_normalize(conv->account, name))) {
- gtk_list_store_set(GTK_LIST_STORE(model), &iter, CHAT_USERS_BUDDY_COLUMN, is_buddy, -1);
- g_free(name);
- break;
-@@ -3597,26 +3597,26 @@ buddy_cb_common(GaimBuddy *buddy, GaimCo
-
- g_free(normalized_name);
-
-- blist_node_aliased_cb((GaimBlistNode *)buddy, NULL, conv);
-+ blist_node_aliased_cb((Gaim2BlistNode *)buddy, NULL, conv);
- }
-
- static void
--buddy_added_cb(GaimBuddy *buddy, GaimConversation *conv)
-+buddy_added_cb(Gaim2Buddy *buddy, Gaim2Conversation *conv)
- {
- buddy_cb_common(buddy, conv, TRUE);
- }
-
- static void
--buddy_removed_cb(GaimBuddy *buddy, GaimConversation *conv)
-+buddy_removed_cb(Gaim2Buddy *buddy, Gaim2Conversation *conv)
- {
- /* If there's another buddy for the same "dude" on the list, do nothing. */
-- if (gaim_find_buddy(buddy->account, buddy->name) != NULL)
-+ if (gaim2_find_buddy(buddy->account, buddy->name) != NULL)
- return;
-
- buddy_cb_common(buddy, conv, FALSE);
- }
-
--static void send_menu_cb(GtkWidget *widget, GaimGtkConversation *gtkconv)
-+static void send_menu_cb(GtkWidget *widget, Gaim2GtkConversation *gtkconv)
- {
- g_signal_emit_by_name(gtkconv->entry, "message_send");
- }
-@@ -3625,12 +3625,12 @@ static void
- entry_popup_menu_cb(GtkIMHtml *imhtml, GtkMenu *menu, gpointer data)
- {
- GtkWidget *menuitem;
-- GaimGtkConversation *gtkconv = data;
-+ Gaim2GtkConversation *gtkconv = data;
-
- g_return_if_fail(menu != NULL);
- g_return_if_fail(gtkconv != NULL);
-
-- menuitem = gaim_new_item_from_stock(NULL, _("_Send"), GAIM_STOCK_SEND,
-+ menuitem = gaim2_new_item_from_stock(NULL, _("_Send"), GAIM_STOCK_SEND,
- G_CALLBACK(send_menu_cb), gtkconv,
- 0, 0, NULL);
- if (gtk_text_buffer_get_char_count(imhtml->text_buffer) == 0)
-@@ -3643,12 +3643,12 @@ entry_popup_menu_cb(GtkIMHtml *imhtml, G
- }
-
- static GtkWidget *
--setup_chat_pane(GaimGtkConversation *gtkconv)
-+setup_chat_pane(Gaim2GtkConversation *gtkconv)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimGtkChatPane *gtkchat;
-- GaimConnection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2Connection *gc;
- GtkWidget *vpaned, *hpaned;
- GtkWidget *vbox, *hbox, *frame;
- GtkWidget *lbox, *bbox;
-@@ -3659,11 +3659,11 @@ setup_chat_pane(GaimGtkConversation *gtk
- GtkListStore *ls;
- GtkCellRenderer *rend;
- GtkTreeViewColumn *col;
-- void *blist_handle = gaim_blist_get_handle();
-+ void *blist_handle = gaim2_blist_get_handle();
- GList *focus_chain = NULL;
-
- gtkchat = gtkconv->u.chat;
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- /* Setup the outer pane. */
- vpaned = gtk_vpaned_new();
-@@ -3706,15 +3706,15 @@ setup_chat_pane(GaimGtkConversation *gtk
- gtk_widget_show(hpaned);
-
- /* Setup gtkihmtml. */
-- frame = gaim_gtk_create_imhtml(FALSE, &gtkconv->imhtml, NULL);
-- gtk_widget_set_name(gtkconv->imhtml, "gaim_gtkconv_imhtml");
-+ frame = gaim2_gtk_create_imhtml(FALSE, &gtkconv->imhtml, NULL);
-+ gtk_widget_set_name(gtkconv->imhtml, "gaim2_gtkconv_imhtml");
- gtk_imhtml_show_comments(GTK_IMHTML(gtkconv->imhtml), TRUE);
- gtk_paned_pack1(GTK_PANED(hpaned), frame, TRUE, TRUE);
- gtk_widget_show(frame);
-
- gtk_widget_set_size_request(gtkconv->imhtml,
-- gaim_prefs_get_int("/gaim/gtk/conversations/chat/default_width"),
-- gaim_prefs_get_int("/gaim/gtk/conversations/chat/default_height"));
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/chat/default_width"),
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/chat/default_height"));
- g_signal_connect(G_OBJECT(gtkconv->imhtml), "size-allocate",
- G_CALLBACK(size_allocate_cb), gtkconv);
-
-@@ -3776,11 +3776,11 @@ setup_chat_pane(GaimGtkConversation *gtk
- "weight-set", CHAT_USERS_BUDDY_COLUMN,
- NULL);
-
-- gaim_signal_connect(blist_handle, "buddy-added",
-+ gaim2_signal_connect(blist_handle, "buddy-added",
- gtkchat, GAIM_CALLBACK(buddy_added_cb), conv);
-- gaim_signal_connect(blist_handle, "buddy-removed",
-+ gaim2_signal_connect(blist_handle, "buddy-removed",
- gtkchat, GAIM_CALLBACK(buddy_removed_cb), conv);
-- gaim_signal_connect(blist_handle, "blist-node-aliased",
-+ gaim2_signal_connect(blist_handle, "blist-node-aliased",
- gtkchat, GAIM_CALLBACK(blist_node_aliased_cb), conv);
-
- #if GTK_CHECK_VERSION(2,6,0)
-@@ -3805,7 +3805,7 @@ setup_chat_pane(GaimGtkConversation *gtk
- gtk_widget_show(bbox);
-
- /* IM */
-- button = gaim_pixbuf_button_from_stock(NULL, GAIM_STOCK_IM,
-+ button = gaim2_pixbuf_button_from_stock(NULL, GAIM_STOCK_IM,
- GAIM_BUTTON_VERTICAL);
- gtkchat->userlist_im = button;
- gtk_button_set_relief(GTK_BUTTON(button), GTK_RELIEF_NONE);
-@@ -3817,7 +3817,7 @@ setup_chat_pane(GaimGtkConversation *gtk
- gtk_widget_show(button);
-
- /* Ignore */
-- button = gaim_pixbuf_button_from_stock(NULL, GAIM_STOCK_IGNORE,
-+ button = gaim2_pixbuf_button_from_stock(NULL, GAIM_STOCK_IGNORE,
- GAIM_BUTTON_VERTICAL);
- gtkchat->userlist_ignore = button;
- gtk_button_set_relief(GTK_BUTTON(button), GTK_RELIEF_NONE);
-@@ -3829,7 +3829,7 @@ setup_chat_pane(GaimGtkConversation *gtk
- gtk_widget_show(button);
-
- /* Info */
-- button = gaim_pixbuf_button_from_stock(NULL, GAIM_STOCK_INFO,
-+ button = gaim2_pixbuf_button_from_stock(NULL, GAIM_STOCK_INFO,
- GAIM_BUTTON_VERTICAL);
- gtkchat->userlist_info = button;
- gtk_button_set_relief(GTK_BUTTON(button), GTK_RELIEF_NONE);
-@@ -3855,18 +3855,18 @@ setup_chat_pane(GaimGtkConversation *gtk
- gtk_widget_show(vbox);
-
- /* Setup the toolbar, entry widget and all signals */
-- frame = gaim_gtk_create_imhtml(TRUE, &gtkconv->entry, &gtkconv->toolbar);
-+ frame = gaim2_gtk_create_imhtml(TRUE, &gtkconv->entry, &gtkconv->toolbar);
- gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
- gtk_widget_show(frame);
-
- g_signal_connect(G_OBJECT(gtkconv->entry), "populate-popup",
- G_CALLBACK(entry_popup_menu_cb), gtkconv);
-
-- gtk_widget_set_name(gtkconv->entry, "gaim_gtkconv_entry");
-+ gtk_widget_set_name(gtkconv->entry, "gaim2_gtkconv_entry");
- gtk_imhtml_set_protocol_name(GTK_IMHTML(gtkconv->entry),
-- gaim_account_get_protocol_name(conv->account));
-+ gaim2_account_get_protocol_name(conv->account));
- gtk_widget_set_size_request(gtkconv->entry, -1,
-- gaim_prefs_get_int("/gaim/gtk/conversations/chat/entry_height"));
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/chat/entry_height"));
- gtkconv->entry_buffer =
- gtk_text_view_get_buffer(GTK_TEXT_VIEW(gtkconv->entry));
- g_object_set_data(G_OBJECT(gtkconv->entry_buffer), "user_data", gtkconv);
-@@ -3894,9 +3894,9 @@ setup_chat_pane(GaimGtkConversation *gtk
- }
-
- static GtkWidget *
--setup_im_pane(GaimGtkConversation *gtkconv)
-+setup_im_pane(Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
- GtkWidget *frame;
- GtkWidget *paned;
- GtkWidget *vbox;
-@@ -3913,15 +3913,15 @@ setup_im_pane(GaimGtkConversation *gtkco
- gtk_widget_show(vbox);
-
- /* Setup the gtkimhtml widget */
-- frame = gaim_gtk_create_imhtml(FALSE, &gtkconv->imhtml, NULL);
-- gtk_widget_set_name(gtkconv->imhtml, "gaim_gtkconv_imhtml");
-+ frame = gaim2_gtk_create_imhtml(FALSE, &gtkconv->imhtml, NULL);
-+ gtk_widget_set_name(gtkconv->imhtml, "gaim2_gtkconv_imhtml");
- gtk_imhtml_show_comments(GTK_IMHTML(gtkconv->imhtml),TRUE);
- gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
- gtk_widget_show(frame);
-
- gtk_widget_set_size_request(gtkconv->imhtml,
-- gaim_prefs_get_int("/gaim/gtk/conversations/im/default_width"),
-- gaim_prefs_get_int("/gaim/gtk/conversations/im/default_height"));
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/im/default_width"),
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/im/default_height"));
- g_signal_connect(G_OBJECT(gtkconv->imhtml), "size-allocate",
- G_CALLBACK(size_allocate_cb), gtkconv);
-
-@@ -3946,18 +3946,18 @@ setup_im_pane(GaimGtkConversation *gtkco
- gtk_widget_show(vbox2);
-
- /* Setup the toolbar, entry widget and all signals */
-- frame = gaim_gtk_create_imhtml(TRUE, &gtkconv->entry, &gtkconv->toolbar);
-+ frame = gaim2_gtk_create_imhtml(TRUE, &gtkconv->entry, &gtkconv->toolbar);
- gtk_box_pack_start(GTK_BOX(vbox2), frame, TRUE, TRUE, 0);
- gtk_widget_show(frame);
-
- g_signal_connect(G_OBJECT(gtkconv->entry), "populate-popup",
- G_CALLBACK(entry_popup_menu_cb), gtkconv);
-
-- gtk_widget_set_name(gtkconv->entry, "gaim_gtkconv_entry");
-+ gtk_widget_set_name(gtkconv->entry, "gaim2_gtkconv_entry");
- gtk_imhtml_set_protocol_name(GTK_IMHTML(gtkconv->entry),
-- gaim_account_get_protocol_name(conv->account));
-+ gaim2_account_get_protocol_name(conv->account));
- gtk_widget_set_size_request(gtkconv->entry, -1,
-- gaim_prefs_get_int("/gaim/gtk/conversations/im/entry_height"));
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/im/entry_height"));
- gtkconv->entry_buffer =
- gtk_text_view_get_buffer(GTK_TEXT_VIEW(gtkconv->entry));
- g_object_set_data(G_OBJECT(gtkconv->entry_buffer), "user_data", gtkconv);
-@@ -3984,7 +3984,7 @@ setup_im_pane(GaimGtkConversation *gtkco
- g_signal_connect_after(G_OBJECT(gtkconv->entry), "format_function_clear",
- G_CALLBACK(clear_formatting_cb), gtkconv);
-
-- gtkconv->u.im->animate = gaim_prefs_get_bool("/gaim/gtk/conversations/im/animate_buddy_icons");
-+ gtkconv->u.im->animate = gaim2_prefs_get_bool("/gaim2/gtk/conversations/im/animate_buddy_icons");
- gtkconv->u.im->show_icon = TRUE;
-
- /*
-@@ -4000,23 +4000,23 @@ setup_im_pane(GaimGtkConversation *gtkco
- static void
- conv_dnd_recv(GtkWidget *widget, GdkDragContext *dc, guint x, guint y,
- GtkSelectionData *sd, guint info, guint t,
-- GaimGtkConversation *gtkconv)
-+ Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimGtkWindow *win = gtkconv->win;
-- GaimConversation *c;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2GtkWindow *win = gtkconv->win;
-+ Gaim2Conversation *c;
- if (sd->target == gdk_atom_intern("GAIM_BLIST_NODE", FALSE))
- {
-- GaimBlistNode *n = NULL;
-- GaimBuddy *b;
-- GaimGtkConversation *gtkconv = NULL;
-+ Gaim2BlistNode *n = NULL;
-+ Gaim2Buddy *b;
-+ Gaim2GtkConversation *gtkconv = NULL;
-
-- n = *(GaimBlistNode **)sd->data;
-+ n = *(Gaim2BlistNode **)sd->data;
-
- if (GAIM_BLIST_NODE_IS_CONTACT(n))
-- b = gaim_contact_get_priority_buddy((GaimContact*)n);
-+ b = gaim2_contact_get_priority_buddy((Gaim2Contact*)n);
- else if (GAIM_BLIST_NODE_IS_BUDDY(n))
-- b = (GaimBuddy*)n;
-+ b = (Gaim2Buddy*)n;
- else
- return;
-
-@@ -4025,27 +4025,27 @@ conv_dnd_recv(GtkWidget *widget, GdkDrag
- * just move the conv to this window. Otherwise, create a new
- * conv and add it to this window.
- */
-- c = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, b->name, b->account);
-+ c = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, b->name, b->account);
- if (c != NULL) {
-- GaimGtkWindow *oldwin;
-+ Gaim2GtkWindow *oldwin;
- gtkconv = GAIM_GTK_CONVERSATION(c);
- oldwin = gtkconv->win;
- if (oldwin != win) {
-- gaim_gtk_conv_window_remove_gtkconv(oldwin, gtkconv);
-- gaim_gtk_conv_window_add_gtkconv(win, gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(oldwin, gtkconv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, gtkconv);
- }
- } else {
-- c = gaim_conversation_new(GAIM_CONV_TYPE_IM, b->account, b->name);
-+ c = gaim2_conversation_new(GAIM_CONV_TYPE_IM, b->account, b->name);
- gtkconv = GAIM_GTK_CONVERSATION(c);
- if (gtkconv->win != win)
- {
-- gaim_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv);
-- gaim_gtk_conv_window_add_gtkconv(win, gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, gtkconv);
- }
- }
-
- /* Make this conversation the active conversation */
-- gaim_gtk_conv_window_switch_gtkconv(win, gtkconv);
-+ gaim2_gtk_conv_window_switch_gtkconv(win, gtkconv);
-
- gtk_drag_finish(dc, TRUE, (dc->action == GDK_ACTION_MOVE), t);
- }
-@@ -4053,26 +4053,26 @@ conv_dnd_recv(GtkWidget *widget, GdkDrag
- {
- char *protocol = NULL;
- char *username = NULL;
-- GaimAccount *account;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Account *account;
-+ Gaim2GtkConversation *gtkconv;
-
-- if (gaim_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
-+ if (gaim2_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
- &protocol, &username, NULL))
- {
- if (account == NULL)
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("You are not currently signed on with an account that "
- "can add that buddy."), NULL);
- }
- else
- {
-- c = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, username);
-+ c = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, username);
- gtkconv = GAIM_GTK_CONVERSATION(c);
- if (gtkconv->win != win)
- {
-- gaim_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv);
-- gaim_gtk_conv_window_add_gtkconv(win, gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, gtkconv);
- }
- }
- }
-@@ -4083,8 +4083,8 @@ conv_dnd_recv(GtkWidget *widget, GdkDrag
- gtk_drag_finish(dc, TRUE, (dc->action == GDK_ACTION_MOVE), t);
- }
- else if (sd->target == gdk_atom_intern("text/uri-list", FALSE)) {
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_dnd_file_manage(sd, gaim_conversation_get_account(conv), gaim_conversation_get_name(conv));
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_dnd_file_manage(sd, gaim2_conversation_get_account(conv), gaim2_conversation_get_name(conv));
- gtk_drag_finish(dc, TRUE, (dc->action == GDK_ACTION_MOVE), t);
- }
- else
-@@ -4099,23 +4099,23 @@ static const GtkTargetEntry te[] =
- {"application/x-im-contact", 0, GTK_IMHTML_DRAG_NUM + 1}
- };
-
--static GaimGtkConversation *
--gaim_gtk_conv_find_gtkconv(GaimConversation * conv)
-+static Gaim2GtkConversation *
-+gaim2_gtk_conv_find_gtkconv(Gaim2Conversation * conv)
- {
-- GaimBuddy *bud = gaim_find_buddy(conv->account, conv->name), *b;
-- GaimContact *c;
-- GaimBlistNode *cn;
-+ Gaim2Buddy *bud = gaim2_find_buddy(conv->account, conv->name), *b;
-+ Gaim2Contact *c;
-+ Gaim2BlistNode *cn;
-
- if (!bud)
- return NULL;
-
-- if (!(c = gaim_buddy_get_contact(bud)))
-+ if (!(c = gaim2_buddy_get_contact(bud)))
- return NULL;
-
-- cn = (GaimBlistNode *)c;
-- for (b = (GaimBuddy *)cn->child; b; b = (GaimBuddy *) ((GaimBlistNode *)b)->next) {
-- GaimConversation *conv;
-- if ((conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, b->name, b->account))) {
-+ cn = (Gaim2BlistNode *)c;
-+ for (b = (Gaim2Buddy *)cn->child; b; b = (Gaim2Buddy *) ((Gaim2BlistNode *)b)->next) {
-+ Gaim2Conversation *conv;
-+ if ((conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, b->name, b->account))) {
- if (conv->ui_data)
- return conv->ui_data;
- }
-@@ -4125,22 +4125,22 @@ gaim_gtk_conv_find_gtkconv(GaimConversat
- }
-
- static void
--buddy_update_cb(GaimBlistNode *bnode, gpointer null)
-+buddy_update_cb(Gaim2BlistNode *bnode, gpointer null)
- {
- GList *list;
-
- g_return_if_fail(bnode);
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(bnode));
-
-- for (list = gaim_gtk_conv_windows_get_list(); list; list = list->next)
-+ for (list = gaim2_gtk_conv_windows_get_list(); list; list = list->next)
- {
-- GaimGtkWindow *win = list->data;
-- GaimConversation *conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ Gaim2GtkWindow *win = list->data;
-+ Gaim2Conversation *conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
-- if (gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_IM)
- continue;
-
-- gaim_conversation_update(conv, GAIM_CONV_ACCOUNT_ONLINE);
-+ gaim2_conversation_update(conv, GAIM_CONV_ACCOUNT_ONLINE);
- }
- }
-
-@@ -4148,22 +4148,22 @@ buddy_update_cb(GaimBlistNode *bnode, gp
- * Conversation UI operations
- **************************************************************************/
- static void
--private_gtkconv_new(GaimConversation *conv, gboolean hidden)
-+private_gtkconv_new(Gaim2Conversation *conv, gboolean hidden)
- {
-- GaimGtkConversation *gtkconv;
-- GaimConversationType conv_type = gaim_conversation_get_type(conv);
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2ConversationType conv_type = gaim2_conversation_get_type(conv);
- GtkWidget *pane = NULL;
- GtkWidget *tab_cont;
-
-- if (conv_type == GAIM_CONV_TYPE_IM && (gtkconv = gaim_gtk_conv_find_gtkconv(conv))) {
-+ if (conv_type == GAIM_CONV_TYPE_IM && (gtkconv = gaim2_gtk_conv_find_gtkconv(conv))) {
- conv->ui_data = gtkconv;
- if (!g_list_find(gtkconv->convs, conv))
- gtkconv->convs = g_list_prepend(gtkconv->convs, conv);
-- gaim_gtkconv_switch_active_conversation(conv);
-+ gaim2_gtkconv_switch_active_conversation(conv);
- return;
- }
-
-- gtkconv = g_new0(GaimGtkConversation, 1);
-+ gtkconv = g_new0(Gaim2GtkConversation, 1);
- conv->ui_data = gtkconv;
- gtkconv->active_conv = conv;
- gtkconv->convs = g_list_prepend(gtkconv->convs, conv);
-@@ -4175,11 +4175,11 @@ private_gtkconv_new(GaimConversation *co
- gtkconv->unseen_count = 0;
-
- if (conv_type == GAIM_CONV_TYPE_IM) {
-- gtkconv->u.im = g_malloc0(sizeof(GaimGtkImPane));
-+ gtkconv->u.im = g_malloc0(sizeof(Gaim2GtkImPane));
-
- pane = setup_im_pane(gtkconv);
- } else if (conv_type == GAIM_CONV_TYPE_CHAT) {
-- gtkconv->u.chat = g_malloc0(sizeof(GaimGtkChatPane));
-+ gtkconv->u.chat = g_malloc0(sizeof(Gaim2GtkChatPane));
- pane = setup_chat_pane(gtkconv);
- }
-
-@@ -4225,95 +4225,95 @@ private_gtkconv_new(GaimConversation *co
-
- /* Setup the container for the tab. */
- gtkconv->tab_cont = tab_cont = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
-- g_object_set_data(G_OBJECT(tab_cont), "GaimGtkConversation", gtkconv);
-+ g_object_set_data(G_OBJECT(tab_cont), "Gaim2GtkConversation", gtkconv);
- gtk_container_set_border_width(GTK_CONTAINER(tab_cont), GAIM_HIG_BOX_SPACE);
- gtk_container_add(GTK_CONTAINER(tab_cont), pane);
- gtk_widget_show(pane);
-
- gtkconv->make_sound = TRUE;
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/show_formatting_toolbar"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/show_formatting_toolbar"))
- gtk_widget_show(gtkconv->toolbar);
- else
- gtk_widget_hide(gtkconv->toolbar);
-
- gtk_imhtml_show_comments(GTK_IMHTML(gtkconv->imhtml),
-- gaim_prefs_get_bool("/gaim/gtk/conversations/show_timestamps"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/conversations/show_timestamps"));
- gtk_imhtml_set_protocol_name(GTK_IMHTML(gtkconv->imhtml),
-- gaim_account_get_protocol_name(conv->account));
-+ gaim2_account_get_protocol_name(conv->account));
-
- g_signal_connect_swapped(G_OBJECT(pane), "focus",
- G_CALLBACK(gtk_widget_grab_focus),
- gtkconv->entry);
-
- if (hidden)
-- gaim_gtk_conv_window_add_gtkconv(hidden_convwin, gtkconv);
-+ gaim2_gtk_conv_window_add_gtkconv(hidden_convwin, gtkconv);
- else
-- gaim_gtkconv_placement_place(gtkconv);
-+ gaim2_gtkconv_placement_place(gtkconv);
-
- if (nick_colors == NULL)
- nick_colors = generate_nick_colors(NUM_NICK_COLORS, gtk_widget_get_style(gtkconv->imhtml)->base[GTK_STATE_NORMAL]);
- }
-
- static void
--gaim_gtkconv_new_hidden(GaimConversation *conv)
-+gaim2_gtkconv_new_hidden(Gaim2Conversation *conv)
- {
- private_gtkconv_new(conv, TRUE);
- }
-
- void
--gaim_gtkconv_new(GaimConversation *conv)
-+gaim2_gtkconv_new(Gaim2Conversation *conv)
- {
- private_gtkconv_new(conv, FALSE);
- }
-
- static void
--received_im_msg_cb(GaimAccount *account, char *sender, char *message,
-- GaimConversation *conv, int flags)
-+received_im_msg_cb(Gaim2Account *account, char *sender, char *message,
-+ Gaim2Conversation *conv, int flags)
- {
-- GaimConversationUiOps *ui_ops = gaim_gtk_conversations_get_conv_ui_ops();
-+ Gaim2ConversationUiOps *ui_ops = gaim2_gtk_conversations_get_conv_ui_ops();
- if (conv != NULL)
- return;
-
- /* create hidden conv if hide_new pref is always */
-- if (strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/im/hide_new"), "always") == 0)
-+ if (strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/im/hide_new"), "always") == 0)
- {
-- ui_ops->create_conversation = gaim_gtkconv_new_hidden;
-- gaim_conversation_new(GAIM_CONV_TYPE_IM, account, sender);
-- ui_ops->create_conversation = gaim_gtkconv_new;
-+ ui_ops->create_conversation = gaim2_gtkconv_new_hidden;
-+ gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, sender);
-+ ui_ops->create_conversation = gaim2_gtkconv_new;
- return;
- }
-
- /* create hidden conv if hide_new pref is away and account is away */
-- if (strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/im/hide_new"), "away") == 0 &&
-- !gaim_status_is_available(gaim_account_get_active_status(account)))
-+ if (strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/im/hide_new"), "away") == 0 &&
-+ !gaim2_status_is_available(gaim2_account_get_active_status(account)))
- {
-- ui_ops->create_conversation = gaim_gtkconv_new_hidden;
-- gaim_conversation_new(GAIM_CONV_TYPE_IM, account, sender);
-- ui_ops->create_conversation = gaim_gtkconv_new;
-+ ui_ops->create_conversation = gaim2_gtkconv_new_hidden;
-+ gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, sender);
-+ ui_ops->create_conversation = gaim2_gtkconv_new;
- return;
- }
- }
-
- static void
--gaim_gtkconv_destroy(GaimConversation *conv)
-+gaim2_gtkconv_destroy(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- gtkconv->convs = g_list_remove(gtkconv->convs, conv);
- /* Don't destroy ourselves until all our convos are gone */
- if (gtkconv->convs)
- return;
-
-- gaim_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(gtkconv->win, gtkconv);
-
- /* If the "Save Conversation" or "Save Icon" dialogs are open then close them */
-- gaim_request_close_with_handle(conv);
-+ gaim2_request_close_with_handle(conv);
-
- gtk_widget_destroy(gtkconv->tab_cont);
- g_object_unref(gtkconv->tab_cont);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
- if (gtkconv->u.im->icon_timer != 0)
- g_source_remove(gtkconv->u.im->icon_timer);
-
-@@ -4321,8 +4321,8 @@ gaim_gtkconv_destroy(GaimConversation *c
- g_object_unref(G_OBJECT(gtkconv->u.im->anim));
-
- g_free(gtkconv->u.im);
-- } else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-- gaim_signals_disconnect_by_handle(gtkconv->u.chat);
-+ } else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ gaim2_signals_disconnect_by_handle(gtkconv->u.chat);
- g_free(gtkconv->u.chat);
- }
-
-@@ -4332,30 +4332,30 @@ gaim_gtkconv_destroy(GaimConversation *c
- }
-
- static void
--gaim_gtkconv_write_im(GaimConversation *conv, const char *who,
-- const char *message, GaimMessageFlags flags,
-+gaim2_gtkconv_write_im(Gaim2Conversation *conv, const char *who,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-- gaim_gtkconv_set_active_conversation(conv);
-+ gaim2_gtkconv_set_active_conversation(conv);
-
-- gaim_conversation_write(conv, who, message, flags, mtime);
-+ gaim2_conversation_write(conv, who, message, flags, mtime);
- }
-
- static void
--gaim_gtkconv_write_chat(GaimConversation *conv, const char *who,
-- const char *message, GaimMessageFlags flags, time_t mtime)
-+gaim2_gtkconv_write_chat(Gaim2Conversation *conv, const char *who,
-+ const char *message, Gaim2MessageFlags flags, time_t mtime)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-- gaim_gtkconv_set_active_conversation(conv);
-+ gaim2_gtkconv_set_active_conversation(conv);
-
- flags |= GAIM_MESSAGE_COLORIZE;
-
-- gaim_conversation_write(conv, who, message, flags, mtime);
-+ gaim2_conversation_write(conv, who, message, flags, mtime);
- }
-
- /* The callback for an event on a link tag. */
-@@ -4364,7 +4364,7 @@ static gboolean buddytag_event(GtkTextTa
- if (event->type == GDK_BUTTON_PRESS
- || event->type == GDK_2BUTTON_PRESS) {
- GdkEventButton *btn_event = (GdkEventButton*) event;
-- GaimConversation *conv = data;
-+ Gaim2Conversation *conv = data;
- char *buddyname;
-
- /* strlen("BUDDY ") == 6 */
-@@ -4387,10 +4387,10 @@ static gboolean buddytag_event(GtkTextTa
- if (!gtk_text_buffer_get_selection_bounds(
- gtk_text_iter_get_buffer(arg2),
- &start, &end)) {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- GtkWidget *menu = NULL;
-- GaimConnection *gc =
-- gaim_conversation_get_gc(conv);
-+ Gaim2Connection *gc =
-+ gaim2_conversation_get_gc(conv);
-
-
- if (gc != NULL)
-@@ -4413,8 +4413,8 @@ static gboolean buddytag_event(GtkTextTa
- return FALSE;
- }
-
--static GtkTextTag *get_buddy_tag(GaimConversation *conv, const char *who) {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+static GtkTextTag *get_buddy_tag(Gaim2Conversation *conv, const char *who) {
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
- GtkTextTag *buddytag;
- /* strlen("BUDDY ") == 6 */
- gchar str[strlen(who) + 7];
-@@ -4438,19 +4438,19 @@ static GtkTextTag *get_buddy_tag(GaimCon
- }
-
- static void
--gaim_gtkconv_write_conv(GaimConversation *conv, const char *name, const char *alias,
-- const char *message, GaimMessageFlags flags,
-+gaim2_gtkconv_write_conv(Gaim2Conversation *conv, const char *name, const char *alias,
-+ const char *message, Gaim2MessageFlags flags,
- time_t mtime)
- {
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-- GaimConnection *gc;
-- GaimAccount *account;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
-+ Gaim2PluginProtocolInfo *prpl_info;
- int gtk_font_options = 0;
- int gtk_font_options_all = 0;
-- int max_scrollback_lines = gaim_prefs_get_int(
-- "/gaim/gtk/conversations/scrollback_lines");
-+ int max_scrollback_lines = gaim2_prefs_get_int(
-+ "/gaim2/gtk/conversations/scrollback_lines");
- int line_count;
- char buf2[BUF_LONG];
- char mdate[64];
-@@ -4459,26 +4459,26 @@ gaim_gtkconv_write_conv(GaimConversation
- char *with_font_tag;
- char *sml_attrib = NULL;
- size_t length;
-- GaimConversationType type;
-+ Gaim2ConversationType type;
- char *displaying;
- gboolean plugin_return;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
-- if(gaim_prefs_get_bool("/gaim/gtk/conversations/use_smooth_scrolling"))
-+ if(gaim2_prefs_get_bool("/gaim2/gtk/conversations/use_smooth_scrolling"))
- gtk_font_options_all |= GTK_IMHTML_USE_SMOOTHSCROLLING;
-
- /* Set the active conversation to the one that just messaged us. */
- /* TODO: consider not doing this if the account is offline or something */
-- gaim_gtkconv_set_active_conversation(conv);
-- type = gaim_conversation_get_type(conv);
-+ gaim2_gtkconv_set_active_conversation(conv);
-+ type = gaim2_conversation_get_type(conv);
-
-- gc = gaim_conversation_get_gc(conv);
-- account = gaim_conversation_get_account(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-+ account = gaim2_conversation_get_account(conv);
-
- displaying = g_strdup(message);
-- plugin_return = GPOINTER_TO_INT(gaim_signal_emit_return_1(
-- gaim_gtk_conversations_get_handle(), (type == GAIM_CONV_TYPE_IM ?
-+ plugin_return = GPOINTER_TO_INT(gaim2_signal_emit_return_1(
-+ gaim2_gtk_conversations_get_handle(), (type == GAIM_CONV_TYPE_IM ?
- "displaying-im-msg" : "displaying-chat-msg"),
- account, conv, &displaying, flags));
- if (plugin_return)
-@@ -4520,16 +4520,16 @@ gaim_gtkconv_write_conv(GaimConversation
-
- if(gc)
- sml_attrib = g_strdup_printf("sml=\"%s\"",
-- gaim_account_get_protocol_name(conv->account));
-+ gaim2_account_get_protocol_name(conv->account));
-
- gtk_font_options |= GTK_IMHTML_NO_COMMENTS;
-
- if ((flags & GAIM_MESSAGE_RECV) &&
-- !gaim_prefs_get_bool("/gaim/gtk/conversations/show_incoming_formatting"))
-+ !gaim2_prefs_get_bool("/gaim2/gtk/conversations/show_incoming_formatting"))
- gtk_font_options |= GTK_IMHTML_NO_COLOURS | GTK_IMHTML_NO_FONTS | GTK_IMHTML_NO_SIZES | GTK_IMHTML_NO_FORMATTING;
-
- /* this is gonna crash one day, I can feel it. */
-- if (GAIM_PLUGIN_PROTOCOL_INFO(gaim_find_prpl(gaim_account_get_protocol_id(conv->account)))->options &
-+ if (GAIM_PLUGIN_PROTOCOL_INFO(gaim2_find_prpl(gaim2_account_get_protocol_id(conv->account)))->options &
- OPT_PROTO_USE_POINTSIZE) {
- gtk_font_options |= GTK_IMHTML_USE_POINTSIZE;
- }
-@@ -4584,7 +4584,7 @@ gaim_gtkconv_write_conv(GaimConversation
- str = g_malloc(1024);
-
- /* If we're whispering, it's not an autoresponse. */
-- if (gaim_message_meify(new_message, -1 )) {
-+ if (gaim2_message_meify(new_message, -1 )) {
- g_snprintf(str, 1024, "***%s", alias_escaped);
- strcpy(color, "#6C2585");
- tag_start_offset += 3;
-@@ -4597,7 +4597,7 @@ gaim_gtkconv_write_conv(GaimConversation
- }
- }
- else {
-- if (gaim_message_meify(new_message, -1)) {
-+ if (gaim2_message_meify(new_message, -1)) {
- str = g_malloc(1024);
-
- if (flags & GAIM_MESSAGE_AUTO_RESP) {
-@@ -4638,7 +4638,7 @@ gaim_gtkconv_write_conv(GaimConversation
- else if (flags & GAIM_MESSAGE_SEND)
- strcpy(color, SEND_COLOR);
- else {
-- gaim_debug_error("gtkconv", "message missing flags\n");
-+ gaim2_debug_error("gtkconv", "message missing flags\n");
- strcpy(color, "#000000");
- }
- }
-@@ -4649,12 +4649,12 @@ gaim_gtkconv_write_conv(GaimConversation
-
- /* Are we in a chat where we can tell which users are buddies? */
- if (!(prpl_info->options & OPT_PROTO_UNIQUE_CHATNAME) &&
-- gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-
- /* Bold buddies to make them stand out from non-buddies. */
- if (flags & GAIM_MESSAGE_SEND ||
- flags & GAIM_MESSAGE_NICK ||
-- gaim_find_buddy(account, name) != NULL) {
-+ gaim2_find_buddy(account, name) != NULL) {
- g_snprintf(buf2, BUF_LONG,
- "<FONT COLOR=\"%s\" %s><FONT SIZE=\"2\"><!--(%s) --></FONT>"
- "<B>%s</B></FONT> ",
-@@ -4676,7 +4676,7 @@ gaim_gtkconv_write_conv(GaimConversation
-
- gtk_imhtml_append_text(GTK_IMHTML(gtkconv->imhtml), buf2, gtk_font_options_all);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT &&
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT &&
- !(flags & GAIM_MESSAGE_SEND)) {
-
- GtkTextIter start, end;
-@@ -4736,15 +4736,15 @@ gaim_gtkconv_write_conv(GaimConversation
- if(sml_attrib)
- g_free(sml_attrib);
-
-- gaim_signal_emit(gaim_gtk_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_gtk_conversations_get_handle(),
- (type == GAIM_CONV_TYPE_IM ? "displayed-im-msg" : "displayed-chat-msg"),
- account, conv, message, flags);
- g_free(displaying);
-
- /* Tab highlighting stuff */
-- if (!gaim_gtkconv_has_focus(conv))
-+ if (!gaim2_gtkconv_has_focus(conv))
- {
-- GaimUnseenState unseen = GAIM_UNSEEN_NONE;
-+ Gaim2UnseenState unseen = GAIM_UNSEEN_NONE;
-
- if ((flags & GAIM_MESSAGE_NICK) == GAIM_MESSAGE_NICK)
- unseen = GAIM_UNSEEN_NICK;
-@@ -4761,11 +4761,11 @@ gaim_gtkconv_write_conv(GaimConversation
- }
-
- static void
--gaim_gtkconv_chat_add_users(GaimConversation *conv, GList *users, GList *flags, GList *aliases, gboolean new_arrivals)
-+gaim2_gtkconv_chat_add_users(Gaim2Conversation *conv, GList *users, GList *flags, GList *aliases, gboolean new_arrivals)
- {
-- GaimConvChat *chat;
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
- GList *l;
- GList *ll;
- GList *lll;
-@@ -4776,7 +4776,7 @@ gaim_gtkconv_chat_add_users(GaimConversa
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkchat = gtkconv->u.chat;
-
-- num_users = g_list_length(gaim_conv_chat_get_users(chat));
-+ num_users = g_list_length(gaim2_conv_chat_get_users(chat));
-
- g_snprintf(tmp, sizeof(tmp),
- ngettext("%d person in room", "%d people in room",
-@@ -4797,13 +4797,13 @@ gaim_gtkconv_chat_add_users(GaimConversa
- }
-
- static void
--gaim_gtkconv_chat_rename_user(GaimConversation *conv, const char *old_name,
-+gaim2_gtkconv_chat_rename_user(Gaim2Conversation *conv, const char *old_name,
- const char *new_name, const char *new_alias)
- {
-- GaimConvChat *chat;
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-- GaimConvChatBuddyFlags flags;
-+ Gaim2ConvChat *chat;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2ConvChatBuddyFlags flags;
- GtkTreeIter iter;
- GtkTreeModel *model;
- int f = 1;
-@@ -4822,7 +4822,7 @@ gaim_gtkconv_chat_rename_user(GaimConver
-
- gtk_tree_model_get(GTK_TREE_MODEL(model), &iter, CHAT_USERS_NAME_COLUMN, &val, CHAT_USERS_FLAGS_COLUMN, &flags, -1);
-
-- if (!gaim_utf8_strcasecmp(old_name, val)) {
-+ if (!gaim2_utf8_strcasecmp(old_name, val)) {
- gtk_list_store_remove(GTK_LIST_STORE(model), &iter);
- g_free(val);
- break;
-@@ -4833,7 +4833,7 @@ gaim_gtkconv_chat_rename_user(GaimConver
- g_free(val);
- }
-
-- if (!gaim_conv_chat_find_user(chat, old_name))
-+ if (!gaim2_conv_chat_find_user(chat, old_name))
- return;
-
- g_return_if_fail(new_alias != NULL);
-@@ -4842,11 +4842,11 @@ gaim_gtkconv_chat_rename_user(GaimConver
- }
-
- static void
--gaim_gtkconv_chat_remove_user(GaimConversation *conv, const char *user)
-+gaim2_gtkconv_chat_remove_user(Gaim2Conversation *conv, const char *user)
- {
-- GaimConvChat *chat;
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
- GtkTreeIter iter;
- GtkTreeModel *model;
- char tmp[BUF_LONG];
-@@ -4857,7 +4857,7 @@ gaim_gtkconv_chat_remove_user(GaimConver
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkchat = gtkconv->u.chat;
-
-- num_users = g_list_length(gaim_conv_chat_get_users(chat)) - 1;
-+ num_users = g_list_length(gaim2_conv_chat_get_users(chat)) - 1;
-
- model = gtk_tree_view_get_model(GTK_TREE_VIEW(gtkchat->list));
-
-@@ -4869,7 +4869,7 @@ gaim_gtkconv_chat_remove_user(GaimConver
-
- gtk_tree_model_get(GTK_TREE_MODEL(model), &iter, CHAT_USERS_NAME_COLUMN, &val, -1);
-
-- if (!gaim_utf8_strcasecmp(user, val)) {
-+ if (!gaim2_utf8_strcasecmp(user, val)) {
- gtk_list_store_remove(GTK_LIST_STORE(model), &iter);
- g_free(val);
- break;
-@@ -4880,7 +4880,7 @@ gaim_gtkconv_chat_remove_user(GaimConver
- g_free(val);
- }
-
-- if (!gaim_conv_chat_find_user(chat, user))
-+ if (!gaim2_conv_chat_find_user(chat, user))
- return;
-
- g_snprintf(tmp, sizeof(tmp),
-@@ -4892,11 +4892,11 @@ gaim_gtkconv_chat_remove_user(GaimConver
- }
-
- static void
--gaim_gtkconv_chat_remove_users(GaimConversation *conv, GList *users)
-+gaim2_gtkconv_chat_remove_users(Gaim2Conversation *conv, GList *users)
- {
-- GaimConvChat *chat;
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
- GtkTreeIter iter;
- GtkTreeModel *model;
- GList *l;
-@@ -4908,7 +4908,7 @@ gaim_gtkconv_chat_remove_users(GaimConve
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkchat = gtkconv->u.chat;
-
-- num_users = g_list_length(gaim_conv_chat_get_users(chat)) -
-+ num_users = g_list_length(gaim2_conv_chat_get_users(chat)) -
- g_list_length(users);
-
- for (l = users; l != NULL; l = l->next) {
-@@ -4923,7 +4923,7 @@ gaim_gtkconv_chat_remove_users(GaimConve
- gtk_tree_model_get(GTK_TREE_MODEL(model), &iter,
- CHAT_USERS_NAME_COLUMN, &val, -1);
-
-- if (!gaim_utf8_strcasecmp((char *)l->data, val)) {
-+ if (!gaim2_utf8_strcasecmp((char *)l->data, val)) {
- #if GTK_CHECK_VERSION(2,2,0)
- f = gtk_list_store_remove(GTK_LIST_STORE(model), &iter);
- #else
-@@ -4946,12 +4946,12 @@ gaim_gtkconv_chat_remove_users(GaimConve
- }
-
- static void
--gaim_gtkconv_chat_update_user(GaimConversation *conv, const char *user)
-+gaim2_gtkconv_chat_update_user(Gaim2Conversation *conv, const char *user)
- {
-- GaimConvChat *chat;
-- GaimConvChatBuddyFlags flags;
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-+ Gaim2ConvChatBuddyFlags flags;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
- GtkTreeIter iter;
- GtkTreeModel *model;
- int f = 1;
-@@ -4971,7 +4971,7 @@ gaim_gtkconv_chat_update_user(GaimConver
-
- gtk_tree_model_get(GTK_TREE_MODEL(model), &iter, CHAT_USERS_NAME_COLUMN, &val, -1);
-
-- if (!gaim_utf8_strcasecmp(user, val)) {
-+ if (!gaim2_utf8_strcasecmp(user, val)) {
- gtk_tree_model_get(GTK_TREE_MODEL(model), &iter, CHAT_USERS_ALIAS_COLUMN, &alias, -1);
- gtk_list_store_remove(GTK_LIST_STORE(model), &iter);
- g_free(val);
-@@ -4983,35 +4983,35 @@ gaim_gtkconv_chat_update_user(GaimConver
- g_free(val);
- }
-
-- if (!gaim_conv_chat_find_user(chat, user))
-+ if (!gaim2_conv_chat_find_user(chat, user))
- return;
-
- g_return_if_fail(alias != NULL);
-
-- flags = gaim_conv_chat_user_get_flags(chat, user);
-+ flags = gaim2_conv_chat_user_get_flags(chat, user);
-
- add_chat_buddy_common(conv, user, flags, alias, NULL);
- g_free(alias);
- }
-
- gboolean
--gaim_gtkconv_has_focus(GaimConversation *conv)
-+gaim2_gtkconv_has_focus(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-- GaimGtkWindow *win;
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2GtkWindow *win;
- gboolean has_focus;
-
- win = gtkconv->win;
-
- g_object_get(G_OBJECT(win->window), "has-toplevel-focus", &has_focus, NULL);
-
-- if (has_focus && gaim_gtk_conv_window_is_active_conversation(conv))
-+ if (has_focus && gaim2_gtk_conv_window_is_active_conversation(conv))
- return TRUE;
-
- return FALSE;
- }
-
--static void gaim_gtkconv_custom_smiley_allocated(GdkPixbufLoader *loader, gpointer user_data)
-+static void gaim2_gtkconv_custom_smiley_allocated(GdkPixbufLoader *loader, gpointer user_data)
- {
- GtkIMHtmlSmiley *smiley;
-
-@@ -5021,11 +5021,11 @@ static void gaim_gtkconv_custom_smiley_a
- if (smiley->icon)
- g_object_ref(G_OBJECT(smiley->icon));
- #ifdef DEBUG_CUSTOM_SMILEY
-- gaim_debug_info("custom-smiley", "gaim_gtkconv_custom_smiley_allocated(): got GdkPixbufAnimation %p for smiley '%s'\n", smiley->icon, smiley->smile);
-+ gaim2_debug_info("custom-smiley", "gaim2_gtkconv_custom_smiley_allocated(): got GdkPixbufAnimation %p for smiley '%s'\n", smiley->icon, smiley->smile);
- #endif
- }
-
--static void gaim_gtkconv_custom_smiley_closed(GdkPixbufLoader *loader, gpointer user_data)
-+static void gaim2_gtkconv_custom_smiley_closed(GdkPixbufLoader *loader, gpointer user_data)
- {
- GtkIMHtmlSmiley *smiley;
- GtkWidget *icon = NULL;
-@@ -5035,7 +5035,7 @@ static void gaim_gtkconv_custom_smiley_c
- smiley = (GtkIMHtmlSmiley *)user_data;
- if (!smiley->imhtml) {
- #ifdef DEBUG_CUSTOM_SMILEY
-- gaim_debug_error("custom-smiley", "gaim_gtkconv_custom_smiley_closed(): orphan smiley found: %p\n", smiley);
-+ gaim2_debug_error("custom-smiley", "gaim2_gtkconv_custom_smiley_closed(): orphan smiley found: %p\n", smiley);
- #endif
- g_object_unref(G_OBJECT(loader));
- smiley->loader = NULL;
-@@ -5047,7 +5047,7 @@ static void gaim_gtkconv_custom_smiley_c
- icon = gtk_image_new_from_animation(smiley->icon);
-
- #ifdef DEBUG_CUSTOM_SMILEY
-- gaim_debug_info("custom-smiley", "gaim_gtkconv_custom_smiley_closed(): got GtkImage %p from GtkPixbufAnimation %p for smiley '%s'\n",
-+ gaim2_debug_info("custom-smiley", "gaim2_gtkconv_custom_smiley_closed(): got GtkImage %p from GtkPixbufAnimation %p for smiley '%s'\n",
- icon, smiley->icon, smiley->smile);
- #endif
- if (icon) {
-@@ -5055,7 +5055,7 @@ static void gaim_gtkconv_custom_smiley_c
-
- anchor = GTK_TEXT_CHILD_ANCHOR(current->data);
-
-- g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_plaintext", g_strdup(gaim_unescape_html(smiley->smile)), g_free);
-+ g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_plaintext", g_strdup(gaim2_unescape_html(smiley->smile)), g_free);
- g_object_set_data_full(G_OBJECT(anchor), "gtkimhtml_htmltext", g_strdup(smiley->smile), g_free);
-
- if (smiley->imhtml)
-@@ -5093,8 +5093,8 @@ add_custom_smiley_for_imhtml(GtkIMHtml *
- smiley->loader = gdk_pixbuf_loader_new();
- smiley->icon = NULL;
-
-- g_signal_connect(smiley->loader, "area_prepared", G_CALLBACK(gaim_gtkconv_custom_smiley_allocated), smiley);
-- g_signal_connect(smiley->loader, "closed", G_CALLBACK(gaim_gtkconv_custom_smiley_closed), smiley);
-+ g_signal_connect(smiley->loader, "area_prepared", G_CALLBACK(gaim2_gtkconv_custom_smiley_allocated), smiley);
-+ g_signal_connect(smiley->loader, "closed", G_CALLBACK(gaim2_gtkconv_custom_smiley_closed), smiley);
-
- return TRUE;
- }
-@@ -5110,8 +5110,8 @@ add_custom_smiley_for_imhtml(GtkIMHtml *
- smiley->loader = loader;
- smiley->flags = smiley->flags | GTK_IMHTML_SMILEY_CUSTOM;
-
-- g_signal_connect(smiley->loader, "area_prepared", G_CALLBACK(gaim_gtkconv_custom_smiley_allocated), smiley);
-- g_signal_connect(smiley->loader, "closed", G_CALLBACK(gaim_gtkconv_custom_smiley_closed), smiley);
-+ g_signal_connect(smiley->loader, "area_prepared", G_CALLBACK(gaim2_gtkconv_custom_smiley_allocated), smiley);
-+ g_signal_connect(smiley->loader, "closed", G_CALLBACK(gaim2_gtkconv_custom_smiley_closed), smiley);
-
- gtk_imhtml_associate_smiley(imhtml, sml, smiley);
-
-@@ -5119,9 +5119,9 @@ add_custom_smiley_for_imhtml(GtkIMHtml *
- }
-
- static gboolean
--gaim_gtkconv_custom_smiley_add(GaimConversation *conv, const char *smile, gboolean remote)
-+gaim2_gtkconv_custom_smiley_add(Gaim2Conversation *conv, const char *smile, gboolean remote)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- struct smiley_list *list;
- const char *sml = NULL, *conv_sml;
-
-@@ -5130,12 +5130,12 @@ gaim_gtkconv_custom_smiley_add(GaimConve
- }
-
- /* If smileys are off, return false */
-- if (gaim_gtkthemes_smileys_disabled())
-+ if (gaim2_gtkthemes_smileys_disabled())
- return FALSE;
-
- /* If possible add this smiley to the current theme.
- * The addition is only temporary: custom smilies aren't saved to disk. */
-- conv_sml = gaim_account_get_protocol_name(conv->account);
-+ conv_sml = gaim2_account_get_protocol_name(conv->account);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- for (list = (struct smiley_list *)current_smiley_theme->list; list; list = list->next) {
-@@ -5156,15 +5156,15 @@ gaim_gtkconv_custom_smiley_add(GaimConve
- }
-
- static void
--gaim_gtkconv_custom_smiley_write(GaimConversation *conv, const char *smile,
-+gaim2_gtkconv_custom_smiley_write(Gaim2Conversation *conv, const char *smile,
- const guchar *data, gsize size)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GtkIMHtmlSmiley *smiley;
- GdkPixbufLoader *loader;
- const char *sml;
-
-- sml = gaim_account_get_protocol_name(conv->account);
-+ sml = gaim2_account_get_protocol_name(conv->account);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- smiley = gtk_imhtml_smiley_get(GTK_IMHTML(gtkconv->imhtml), sml, smile);
-
-@@ -5179,9 +5179,9 @@ gaim_gtkconv_custom_smiley_write(GaimCon
- }
-
- static void
--gaim_gtkconv_custom_smiley_close(GaimConversation *conv, const char *smile)
-+gaim2_gtkconv_custom_smiley_close(Gaim2Conversation *conv, const char *smile)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- GtkIMHtmlSmiley *smiley;
- GdkPixbufLoader *loader;
- const char *sml;
-@@ -5189,7 +5189,7 @@ gaim_gtkconv_custom_smiley_close(GaimCon
- g_return_if_fail(conv != NULL);
- g_return_if_fail(smile != NULL);
-
-- sml = gaim_account_get_protocol_name(conv->account);
-+ sml = gaim2_account_get_protocol_name(conv->account);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- smiley = gtk_imhtml_smiley_get(GTK_IMHTML(gtkconv->imhtml), sml, smile);
-
-@@ -5203,7 +5203,7 @@ gaim_gtkconv_custom_smiley_close(GaimCon
-
-
-
-- gaim_debug_info("gtkconv", "About to close the smiley pixbuf\n");
-+ gaim2_debug_info("gtkconv", "About to close the smiley pixbuf\n");
-
- gdk_pixbuf_loader_close(loader, NULL);
-
-@@ -5215,19 +5215,19 @@ gaim_gtkconv_custom_smiley_close(GaimCon
- * account signs on or off.
- */
- static void
--gray_stuff_out(GaimGtkConversation *gtkconv)
-+gray_stuff_out(Gaim2GtkConversation *gtkconv)
- {
-- GaimGtkWindow *win;
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2GtkWindow *win;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- GdkPixbuf *window_icon = NULL;
- GtkIMHtmlButtons buttons;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- win = gaim_gtkconv_get_window(gtkconv);
-- gc = gaim_conversation_get_gc(conv);
-- account = gaim_conversation_get_account(conv);
-+ win = gaim2_gtkconv_get_window(gtkconv);
-+ gc = gaim2_conversation_get_gc(conv);
-+ account = gaim2_conversation_get_account(conv);
-
- if (gc != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -5237,13 +5237,13 @@ gray_stuff_out(GaimGtkConversation *gtkc
-
- /*
- * Handle hiding and showing stuff based on what type of conv this is.
-- * Stuff that Gaim IMs support in general should be shown for IM
-- * conversations. Stuff that Gaim chats support in general should be
-+ * Stuff that Gaim2 IMs support in general should be shown for IM
-+ * conversations. Stuff that Gaim2 chats support in general should be
- * shown for chat conversations. It doesn't matter whether the PRPL
- * supports it or not--that only affects if the button or menu item
- * is sensitive or not.
- */
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) {
- /* Show stuff that applies to IMs, hide stuff that applies to chats */
-
- /* Deal with menu items */
-@@ -5255,7 +5255,7 @@ gray_stuff_out(GaimGtkConversation *gtkc
- gtk_widget_show(win->menu.alias);
- gtk_widget_show(win->menu.block);
-
-- if (gaim_find_buddy(account, gaim_conversation_get_name(conv)) == NULL) {
-+ if (gaim2_find_buddy(account, gaim2_conversation_get_name(conv)) == NULL) {
- gtk_widget_show(win->menu.add);
- gtk_widget_hide(win->menu.remove);
- } else {
-@@ -5266,7 +5266,7 @@ gray_stuff_out(GaimGtkConversation *gtkc
- gtk_widget_show(win->menu.insert_link);
- gtk_widget_show(win->menu.insert_image);
- gtk_widget_show(win->menu.show_icon);
-- } else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
-+ } else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT) {
- /* Show stuff that applies to Chats, hide stuff that applies to IMs */
-
- /* Deal with menu items */
-@@ -5279,7 +5279,7 @@ gray_stuff_out(GaimGtkConversation *gtkc
- gtk_widget_hide(win->menu.block);
- gtk_widget_hide(win->menu.show_icon);
-
-- if (gaim_blist_find_chat(account, gaim_conversation_get_name(conv)) == NULL) {
-+ if (gaim2_blist_find_chat(account, gaim2_conversation_get_name(conv)) == NULL) {
- /* If the chat is NOT in the buddy list */
- gtk_widget_show(win->menu.add);
- gtk_widget_hide(win->menu.remove);
-@@ -5298,8 +5298,8 @@ gray_stuff_out(GaimGtkConversation *gtkc
- * and what features that account supports.
- */
- if ((gc != NULL) &&
-- ((gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_CHAT) ||
-- !gaim_conv_chat_has_left(GAIM_CONV_CHAT(conv)) ))
-+ ((gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_CHAT) ||
-+ !gaim2_conv_chat_has_left(GAIM_CONV_CHAT(conv)) ))
- {
- /* Account is online */
- /* Deal with the toolbar */
-@@ -5324,7 +5324,7 @@ gray_stuff_out(GaimGtkConversation *gtkc
- buttons &= ~GTK_IMHTML_IMAGE;
-
- gtk_imhtml_set_format_functions(GTK_IMHTML(gtkconv->entry), buttons);
-- gtk_imhtmltoolbar_associate_smileys(GTK_IMHTMLTOOLBAR(gtkconv->toolbar), gaim_account_get_protocol_id(account));
-+ gtk_imhtmltoolbar_associate_smileys(GTK_IMHTMLTOOLBAR(gtkconv->toolbar), gaim2_account_get_protocol_id(account));
-
- /* Deal with menu items */
- gtk_widget_set_sensitive(win->menu.view_log, TRUE);
-@@ -5335,26 +5335,26 @@ gray_stuff_out(GaimGtkConversation *gtkc
- gtk_widget_set_sensitive(win->menu.insert_link, (conv->features & GAIM_CONNECTION_HTML));
- gtk_widget_set_sensitive(win->menu.insert_image, (prpl_info->options & OPT_PROTO_IM_IMAGE) && !(conv->features & GAIM_CONNECTION_NO_IMAGES));
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- {
- gtk_widget_set_sensitive(win->menu.add, (prpl_info->add_buddy != NULL));
- gtk_widget_set_sensitive(win->menu.remove, (prpl_info->remove_buddy != NULL));
- gtk_widget_set_sensitive(win->menu.send_file,
- (prpl_info->send_file != NULL && (!prpl_info->can_receive_file ||
-- prpl_info->can_receive_file(gc, gaim_conversation_get_name(conv)))));
-+ prpl_info->can_receive_file(gc, gaim2_conversation_get_name(conv)))));
- gtk_widget_set_sensitive(win->menu.alias,
-- (gaim_find_buddy(account, gaim_conversation_get_name(conv)) != NULL));
-+ (gaim2_find_buddy(account, gaim2_conversation_get_name(conv)) != NULL));
- }
-- else if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ else if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- {
- gtk_widget_set_sensitive(win->menu.add, (prpl_info->join_chat != NULL));
- gtk_widget_set_sensitive(win->menu.remove, (prpl_info->join_chat != NULL));
- gtk_widget_set_sensitive(win->menu.alias,
-- (gaim_blist_find_chat(account, gaim_conversation_get_name(conv)) != NULL));
-+ (gaim2_blist_find_chat(account, gaim2_conversation_get_name(conv)) != NULL));
- }
-
- /* Deal with chat userlist buttons */
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- {
- gtk_widget_set_sensitive(gtkconv->u.chat->userlist_im, TRUE);
- gtk_widget_set_sensitive(gtkconv->u.chat->userlist_ignore, TRUE);
-@@ -5378,7 +5378,7 @@ gray_stuff_out(GaimGtkConversation *gtkc
- gtk_widget_set_sensitive(win->menu.insert_image, FALSE);
-
- /* Deal with chat userlist buttons */
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
- {
- gtk_widget_set_sensitive(gtkconv->u.chat->userlist_im, FALSE);
- gtk_widget_set_sensitive(gtkconv->u.chat->userlist_ignore, FALSE);
-@@ -5389,16 +5389,16 @@ gray_stuff_out(GaimGtkConversation *gtkc
- /*
- * Update the window's icon
- */
-- if (gaim_gtk_conv_window_is_active_conversation(conv))
-+ if (gaim2_gtk_conv_window_is_active_conversation(conv))
- {
-- if ((gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) &&
-+ if ((gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) &&
- (gtkconv->u.im->anim))
- {
- window_icon =
- gdk_pixbuf_animation_get_static_image(gtkconv->u.im->anim);
- g_object_ref(window_icon);
- } else {
-- window_icon = gaim_gtkconv_get_tab_icon(conv, FALSE);
-+ window_icon = gaim2_gtkconv_get_tab_icon(conv, FALSE);
- }
- gtk_window_set_icon(GTK_WINDOW(win->window), window_icon);
- if (window_icon != NULL)
-@@ -5408,12 +5408,12 @@ gray_stuff_out(GaimGtkConversation *gtkc
-
-
- static void
--gaim_gtkconv_updated(GaimConversation *conv, GaimConvUpdateType type)
-+gaim2_gtkconv_updated(Gaim2Conversation *conv, Gaim2ConvUpdateType type)
- {
-- GaimGtkWindow *win;
-- GaimGtkConversation *gtkconv;
-- GaimGtkChatPane *gtkchat;
-- GaimConvChat *chat;
-+ Gaim2GtkWindow *win;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkChatPane *gtkchat;
-+ Gaim2ConvChat *chat;
-
- g_return_if_fail(conv != NULL);
-
-@@ -5426,16 +5426,16 @@ gaim_gtkconv_updated(GaimConversation *c
-
- if (type == GAIM_CONV_UPDATE_ACCOUNT)
- {
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_gtkconv_update_buddy_icon(conv);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_gtkconv_update_buddy_icon(conv);
-
-- gaim_gtkconv_update_buttons_by_protocol(conv);
-+ gaim2_gtkconv_update_buttons_by_protocol(conv);
-
- update_send_to_selection(win);
-
-- gaim_gtkthemes_smiley_themeize(gtkconv->imhtml);
-+ gaim2_gtkthemes_smiley_themeize(gtkconv->imhtml);
-
- update_tab_icon(conv);
- }
-@@ -5444,20 +5444,20 @@ gaim_gtkconv_updated(GaimConversation *c
- type == GAIM_CONV_UPDATE_TITLE)
- {
- char *title;
-- GaimConvIm *im = NULL;
-- GaimAccount *account = gaim_conversation_get_account(conv);
-+ Gaim2ConvIm *im = NULL;
-+ Gaim2Account *account = gaim2_conversation_get_account(conv);
- /* I think this is a little longer than it needs to be but I'm lazy. */
- char style[51];
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
- im = GAIM_CONV_IM(conv);
-
-- if (!gaim_account_is_connected(account)
-- || ((gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-- && gaim_conv_chat_has_left(GAIM_CONV_CHAT(conv))))
-- title = g_strdup_printf("(%s)", gaim_conversation_get_title(conv));
-+ if (!gaim2_account_is_connected(account)
-+ || ((gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_CHAT)
-+ && gaim2_conv_chat_has_left(GAIM_CONV_CHAT(conv))))
-+ title = g_strdup_printf("(%s)", gaim2_conversation_get_title(conv));
- else
-- title = g_strdup(gaim_conversation_get_title(conv));
-+ title = g_strdup(gaim2_conversation_get_title(conv));
-
- *style = '\0';
-
-@@ -5465,12 +5465,12 @@ gaim_gtkconv_updated(GaimConversation *c
- gtk_widget_realize(gtkconv->tab_label);
-
- if (im != NULL &&
-- gaim_conv_im_get_typing_state(im) == GAIM_TYPING)
-+ gaim2_conv_im_get_typing_state(im) == GAIM_TYPING)
- {
- strncpy(style, "color=\"#47A046\"", sizeof(style));
- }
- else if (im != NULL &&
-- gaim_conv_im_get_typing_state(im) == GAIM_TYPED)
-+ gaim2_conv_im_get_typing_state(im) == GAIM_TYPED)
- {
- strncpy(style, "color=\"#D1940C\"", sizeof(style));
- }
-@@ -5502,12 +5502,12 @@ gaim_gtkconv_updated(GaimConversation *c
- else
- gtk_label_set_text(GTK_LABEL(gtkconv->tab_label), title);
-
-- if (gaim_gtk_conv_window_is_active_conversation(conv))
-+ if (gaim2_gtk_conv_window_is_active_conversation(conv))
- update_typing_icon(gtkconv);
-
- if (type == GAIM_CONV_UPDATE_TITLE) {
- gtk_label_set_text(GTK_LABEL(gtkconv->menu_label), title);
-- if (gaim_gtk_conv_window_is_active_conversation(conv))
-+ if (gaim2_gtk_conv_window_is_active_conversation(conv))
- gtk_window_set_title(GTK_WINDOW(win->window), title);
- }
-
-@@ -5519,7 +5519,7 @@ gaim_gtkconv_updated(GaimConversation *c
- chat = GAIM_CONV_CHAT(conv);
- gtkchat = gtkconv->u.chat;
-
-- topic = gaim_conv_chat_get_topic(chat);
-+ topic = gaim2_conv_chat_get_topic(chat);
-
- gtk_entry_set_text(GTK_ENTRY(gtkchat->topic_text), topic ? topic : "");
- gtk_tooltips_set_tip(gtkconv->tooltips, gtkchat->topic_text,
-@@ -5528,10 +5528,10 @@ gaim_gtkconv_updated(GaimConversation *c
- else if (type == GAIM_CONV_ACCOUNT_ONLINE ||
- type == GAIM_CONV_ACCOUNT_OFFLINE)
- {
-- gray_stuff_out(GAIM_GTK_CONVERSATION(gaim_gtk_conv_window_get_active_conversation(win)));
-+ gray_stuff_out(GAIM_GTK_CONVERSATION(gaim2_gtk_conv_window_get_active_conversation(win)));
- generate_send_to_items(win);
- update_tab_icon(conv);
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
- }
- else if (type == GAIM_CONV_UPDATE_AWAY)
- {
-@@ -5540,12 +5540,12 @@ gaim_gtkconv_updated(GaimConversation *c
- else if (type == GAIM_CONV_UPDATE_ADD || type == GAIM_CONV_UPDATE_REMOVE ||
- type == GAIM_CONV_UPDATE_CHATLEFT)
- {
-- gaim_conversation_autoset_title(conv);
-+ gaim2_conversation_autoset_title(conv);
- gray_stuff_out(GAIM_GTK_CONVERSATION(conv));
- }
- else if (type == GAIM_CONV_UPDATE_ICON)
- {
-- gaim_gtkconv_update_buddy_icon(conv);
-+ gaim2_gtkconv_update_buddy_icon(conv);
- }
- else if (type == GAIM_CONV_UPDATE_FEATURES)
- {
-@@ -5553,28 +5553,28 @@ gaim_gtkconv_updated(GaimConversation *c
- }
- }
-
--static GaimConversationUiOps conversation_ui_ops =
-+static Gaim2ConversationUiOps conversation_ui_ops =
- {
-- gaim_gtkconv_new,
-- gaim_gtkconv_destroy, /* destroy_conversation */
-- gaim_gtkconv_write_chat, /* write_chat */
-- gaim_gtkconv_write_im, /* write_im */
-- gaim_gtkconv_write_conv, /* write_conv */
-- gaim_gtkconv_chat_add_users, /* chat_add_users */
-- gaim_gtkconv_chat_rename_user, /* chat_rename_user */
-- gaim_gtkconv_chat_remove_user, /* chat_remove_user */
-- gaim_gtkconv_chat_remove_users, /* chat_remove_users */
-- gaim_gtkconv_chat_update_user, /* chat_update_user */
-- gaim_gtkconv_present_conversation, /* present */
-- gaim_gtkconv_has_focus, /* has_focus */
-- gaim_gtkconv_custom_smiley_add, /* custom_smiley_add */
-- gaim_gtkconv_custom_smiley_write, /* custom_smiley_write */
-- gaim_gtkconv_custom_smiley_close, /* custom_smiley_close */
-- gaim_gtkconv_updated /* updated */
-+ gaim2_gtkconv_new,
-+ gaim2_gtkconv_destroy, /* destroy_conversation */
-+ gaim2_gtkconv_write_chat, /* write_chat */
-+ gaim2_gtkconv_write_im, /* write_im */
-+ gaim2_gtkconv_write_conv, /* write_conv */
-+ gaim2_gtkconv_chat_add_users, /* chat_add_users */
-+ gaim2_gtkconv_chat_rename_user, /* chat_rename_user */
-+ gaim2_gtkconv_chat_remove_user, /* chat_remove_user */
-+ gaim2_gtkconv_chat_remove_users, /* chat_remove_users */
-+ gaim2_gtkconv_chat_update_user, /* chat_update_user */
-+ gaim2_gtkconv_present_conversation, /* present */
-+ gaim2_gtkconv_has_focus, /* has_focus */
-+ gaim2_gtkconv_custom_smiley_add, /* custom_smiley_add */
-+ gaim2_gtkconv_custom_smiley_write, /* custom_smiley_write */
-+ gaim2_gtkconv_custom_smiley_close, /* custom_smiley_close */
-+ gaim2_gtkconv_updated /* updated */
- };
-
--GaimConversationUiOps *
--gaim_gtk_conversations_get_conv_ui_ops(void)
-+Gaim2ConversationUiOps *
-+gaim2_gtk_conversations_get_conv_ui_ops(void)
- {
- return &conversation_ui_ops;
- }
-@@ -5583,10 +5583,10 @@ gaim_gtk_conversations_get_conv_ui_ops(v
- * Public conversation utility functions
- **************************************************************************/
- void
--gaim_gtkconv_update_buddy_icon(GaimConversation *conv)
-+gaim2_gtkconv_update_buddy_icon(Gaim2Conversation *conv)
- {
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-
- GdkPixbufLoader *loader;
- GdkPixbufAnimation *anim;
-@@ -5604,14 +5604,14 @@ gaim_gtkconv_update_buddy_icon(GaimConve
- GdkBitmap *bm;
- int scale_width, scale_height;
-
-- GaimAccount *account;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Account *account;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
-- GaimBuddyIcon *icon;
-+ Gaim2BuddyIcon *icon;
-
- g_return_if_fail(conv != NULL);
- g_return_if_fail(GAIM_IS_GTK_CONVERSATION(conv));
-- g_return_if_fail(gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM);
-+ g_return_if_fail(gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM);
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- win = gtkconv->win;
-@@ -5619,7 +5619,7 @@ gaim_gtkconv_update_buddy_icon(GaimConve
- if (!gtkconv->u.im->show_icon)
- return;
-
-- account = gaim_conversation_get_account(conv);
-+ account = gaim2_conversation_get_account(conv);
- if(account && account->gc)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(account->gc->prpl);
-
-@@ -5643,18 +5643,18 @@ gaim_gtkconv_update_buddy_icon(GaimConve
-
- gtkconv->u.im->iter = NULL;
-
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/im/show_buddy_icons"))
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/im/show_buddy_icons"))
- return;
-
-- if (gaim_conversation_get_gc(conv) == NULL)
-+ if (gaim2_conversation_get_gc(conv) == NULL)
- return;
-
-- icon = gaim_conv_im_get_icon(GAIM_CONV_IM(conv));
-+ icon = gaim2_conv_im_get_icon(GAIM_CONV_IM(conv));
-
- if (icon == NULL)
- return;
-
-- data = gaim_buddy_icon_get_data(icon, &len);
-+ data = gaim2_buddy_icon_get_data(icon, &len);
-
- loader = gdk_pixbuf_loader_new();
- gdk_pixbuf_loader_write(loader, data, len, NULL);
-@@ -5669,7 +5669,7 @@ gaim_gtkconv_update_buddy_icon(GaimConve
- gtkconv->u.im->anim = anim;
-
- if (err) {
-- gaim_debug(GAIM_DEBUG_ERROR, "gtkconv",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gtkconv",
- "Buddy icon error: %s\n", err->message);
- g_error_free(err);
- }
-@@ -5688,7 +5688,7 @@ gaim_gtkconv_update_buddy_icon(GaimConve
- start_anim(NULL, gtkconv);
- }
-
-- gaim_gtk_buddy_icon_get_scale_size(buf, prpl_info ? &prpl_info->icon_spec :
-+ gaim2_gtk_buddy_icon_get_scale_size(buf, prpl_info ? &prpl_info->icon_spec :
- NULL, &scale_width, &scale_height);
- scale = gdk_pixbuf_scale_simple(buf,
- MAX(gdk_pixbuf_get_width(buf) * scale_width /
-@@ -5733,26 +5733,26 @@ gaim_gtkconv_update_buddy_icon(GaimConve
-
- /* The buddy icon code needs badly to be fixed. */
- buf = gdk_pixbuf_animation_get_static_image(gtkconv->u.im->anim);
-- if(gaim_gtk_conv_window_is_active_conversation(conv))
-+ if(gaim2_gtk_conv_window_is_active_conversation(conv))
- gtk_window_set_icon(GTK_WINDOW(win->window), buf);
- }
-
- void
--gaim_gtkconv_update_buttons_by_protocol(GaimConversation *conv)
-+gaim2_gtkconv_update_buttons_by_protocol(Gaim2Conversation *conv)
- {
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- return;
-
- win = GAIM_GTK_CONVERSATION(conv)->win;
-
-- if (win != NULL && gaim_gtk_conv_window_is_active_conversation(conv))
-+ if (win != NULL && gaim2_gtk_conv_window_is_active_conversation(conv))
- gray_stuff_out(GAIM_GTK_CONVERSATION(conv));
- }
-
- int
--gaim_gtkconv_get_tab_at_xy(GaimGtkWindow *win, int x, int y, gboolean *to_right)
-+gaim2_gtkconv_get_tab_at_xy(Gaim2GtkWindow *win, int x, int y, gboolean *to_right)
- {
- gint nb_x, nb_y, x_rel, y_rel;
- GtkNotebook *notebook;
-@@ -5812,15 +5812,15 @@ gaim_gtkconv_get_tab_at_xy(GaimGtkWindow
- }
-
- static void
--close_on_tabs_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+close_on_tabs_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GList *l;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next) {
-- conv = (GaimConversation *)l->data;
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next) {
-+ conv = (Gaim2Conversation *)l->data;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- continue;
-@@ -5835,18 +5835,18 @@ close_on_tabs_pref_cb(const char *name,
- }
-
- static void
--spellcheck_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+spellcheck_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- #ifdef USE_GTKSPELL
- GList *cl;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- GtkSpell *spell;
-
-- for (cl = gaim_get_conversations(); cl != NULL; cl = cl->next) {
-+ for (cl = gaim2_get_conversations(); cl != NULL; cl = cl->next) {
-
-- conv = (GaimConversation *)cl->data;
-+ conv = (Gaim2Conversation *)cl->data;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- continue;
-@@ -5854,7 +5854,7 @@ spellcheck_pref_cb(const char *name, Gai
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- if (value)
-- gaim_gtk_setup_gtkspell(GTK_TEXT_VIEW(gtkconv->entry));
-+ gaim2_gtk_setup_gtkspell(GTK_TEXT_VIEW(gtkconv->entry));
- else {
- spell = gtkspell_get_from_text_view(GTK_TEXT_VIEW(gtkconv->entry));
- gtkspell_detach(spell);
-@@ -5864,16 +5864,16 @@ spellcheck_pref_cb(const char *name, Gai
- }
-
- static void
--tab_side_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+tab_side_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GList *l;
- GtkPositionType pos;
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
-
- pos = GPOINTER_TO_INT(value);
-
-- for (l = gaim_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
-+ for (l = gaim2_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
- win = l->data;
-
- gtk_notebook_set_tab_pos(GTK_NOTEBOOK(win->notebook), pos&~8);
-@@ -5881,17 +5881,17 @@ tab_side_pref_cb(const char *name, GaimP
- }
-
- static void
--show_timestamps_pref_cb(const char *name, GaimPrefType type,
-+show_timestamps_pref_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
- GList *l;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next)
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next)
- {
-- conv = (GaimConversation *)l->data;
-+ conv = (Gaim2Conversation *)l->data;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- continue;
-@@ -5909,17 +5909,17 @@ show_timestamps_pref_cb(const char *name
- }
-
- static void
--show_formatting_toolbar_pref_cb(const char *name, GaimPrefType type,
-+show_formatting_toolbar_pref_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
- GList *l;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next)
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next)
- {
-- conv = (GaimConversation *)l->data;
-+ conv = (Gaim2Conversation *)l->data;
-
- if (!GAIM_IS_GTK_CONVERSATION(conv))
- continue;
-@@ -5939,65 +5939,65 @@ show_formatting_toolbar_pref_cb(const ch
- }
-
- static void
--animate_buddy_icons_pref_cb(const char *name, GaimPrefType type,
-+animate_buddy_icons_pref_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
- GList *l;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/im/show_buddy_icons"))
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/im/show_buddy_icons"))
- return;
-
- /* Set the "animate" flag for each icon based on the new preference */
-- for (l = gaim_get_ims(); l != NULL; l = l->next) {
-- conv = (GaimConversation *)l->data;
-+ for (l = gaim2_get_ims(); l != NULL; l = l->next) {
-+ conv = (Gaim2Conversation *)l->data;
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtkconv->u.im->animate = GPOINTER_TO_INT(value);
- }
-
- /* Now either stop or start animation for the active conversation in each window */
-- for (l = gaim_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
-+ for (l = gaim2_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
- win = l->data;
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-- gaim_gtkconv_update_buddy_icon(conv);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-+ gaim2_gtkconv_update_buddy_icon(conv);
- }
- }
-
- static void
--show_buddy_icons_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+show_buddy_icons_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GList *l;
-
-- for (l = gaim_get_conversations(); l != NULL; l = l->next) {
-- GaimConversation *conv = l->data;
-+ for (l = gaim2_get_conversations(); l != NULL; l = l->next) {
-+ Gaim2Conversation *conv = l->data;
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_gtkconv_update_buddy_icon(conv);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_gtkconv_update_buddy_icon(conv);
- }
- }
-
- static void
--conv_placement_usetabs_cb(const char *name, GaimPrefType type,
-+conv_placement_usetabs_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
-- gaim_prefs_trigger_callback("/gaim/gtk/conversations/placement");
-+ gaim2_prefs_trigger_callback("/gaim2/gtk/conversations/placement");
- }
-
- static void
--account_status_changed_cb(GaimAccount *account, GaimStatus *oldstatus,
-- GaimStatus *newstatus)
-+account_status_changed_cb(Gaim2Account *account, Gaim2Status *oldstatus,
-+ Gaim2Status *newstatus)
- {
- GList *l;
-- GaimConversation *conv = NULL;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv = NULL;
-+ Gaim2GtkConversation *gtkconv;
-
-- if(strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/im/hide_new"), "away")!=0)
-+ if(strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/im/hide_new"), "away")!=0)
- return;
-
-- if(gaim_status_is_available(oldstatus) || !gaim_status_is_available(newstatus))
-+ if(gaim2_status_is_available(oldstatus) || !gaim2_status_is_available(newstatus))
- return;
-
- for (l = hidden_convwin->gtkconvs; l != NULL; l = l->next) {
-@@ -6005,32 +6005,32 @@ account_status_changed_cb(GaimAccount *a
-
- conv = gtkconv->active_conv;
-
-- if(!gaim_status_is_available(
-- gaim_account_get_active_status(
-- gaim_conversation_get_account(conv))))
-+ if(!gaim2_status_is_available(
-+ gaim2_account_get_active_status(
-+ gaim2_conversation_get_account(conv))))
- continue;
-
-- gaim_gtk_conv_window_remove_gtkconv(hidden_convwin, gtkconv);
-- gaim_gtkconv_placement_place(gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(hidden_convwin, gtkconv);
-+ gaim2_gtkconv_placement_place(gtkconv);
- }
- }
-
- static void
--hide_new_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+hide_new_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GList *l;
-- GaimConversation *conv = NULL;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv = NULL;
-+ Gaim2GtkConversation *gtkconv;
- gboolean when_away = FALSE;
-
- if(!hidden_convwin)
- return;
-
-- if(strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/im/hide_new"), "always")==0)
-+ if(strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/im/hide_new"), "always")==0)
- return;
-
-- if(strcmp(gaim_prefs_get_string("/gaim/gtk/conversations/im/hide_new"), "away")==0)
-+ if(strcmp(gaim2_prefs_get_string("/gaim2/gtk/conversations/im/hide_new"), "away")==0)
- when_away = TRUE;
-
- for (l = hidden_convwin->gtkconvs; l != NULL; l = l->next) {
-@@ -6038,53 +6038,53 @@ hide_new_pref_cb(const char *name, GaimP
-
- conv = gtkconv->active_conv;
-
-- if(when_away && !gaim_status_is_available(
-- gaim_account_get_active_status(
-- gaim_conversation_get_account(conv))))
-+ if(when_away && !gaim2_status_is_available(
-+ gaim2_account_get_active_status(
-+ gaim2_conversation_get_account(conv))))
- continue;
-
-- gaim_gtk_conv_window_remove_gtkconv(hidden_convwin, gtkconv);
-- gaim_gtkconv_placement_place(gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(hidden_convwin, gtkconv);
-+ gaim2_gtkconv_placement_place(gtkconv);
- }
- }
-
-
- static void
--conv_placement_pref_cb(const char *name, GaimPrefType type,
-+conv_placement_pref_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
-- GaimConvPlacementFunc func;
-+ Gaim2ConvPlacementFunc func;
-
-- if (strcmp(name, "/gaim/gtk/conversations/placement"))
-+ if (strcmp(name, "/gaim2/gtk/conversations/placement"))
- return;
-
-- func = gaim_gtkconv_placement_get_fnc(value);
-+ func = gaim2_gtkconv_placement_get_fnc(value);
-
- if (func == NULL)
- return;
-
-- gaim_gtkconv_placement_set_current_func(func);
-+ gaim2_gtkconv_placement_set_current_func(func);
- }
-
- static void
--account_signed_off_cb(GaimConnection *gc, gpointer event)
-+account_signed_off_cb(Gaim2Connection *gc, gpointer event)
- {
- GList *iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- for (iter = gaim_get_conversations(); iter; iter = iter->next)
-+ for (iter = gaim2_get_conversations(); iter; iter = iter->next)
- {
-- GaimConversation *conv = iter->data;
-+ Gaim2Conversation *conv = iter->data;
-
-- if (gaim_conversation_get_account(conv) == account)
-- gaim_conversation_update(conv, GPOINTER_TO_INT(event));
-+ if (gaim2_conversation_get_account(conv) == account)
-+ gaim2_conversation_update(conv, GPOINTER_TO_INT(event));
- }
- }
-
- void *
--gaim_gtk_conversations_get_handle(void)
-+gaim2_gtk_conversations_get_handle(void)
- {
- static int handle;
-
-@@ -6092,78 +6092,78 @@ gaim_gtk_conversations_get_handle(void)
- }
-
- void
--gaim_gtk_conversations_init(void)
-+gaim2_gtk_conversations_init(void)
- {
-- void *handle = gaim_gtk_conversations_get_handle();
-- void *blist_handle = gaim_blist_get_handle();
-+ void *handle = gaim2_gtk_conversations_get_handle();
-+ void *blist_handle = gaim2_blist_get_handle();
-
- /* Conversations */
-- gaim_prefs_add_none("/gaim/gtk/conversations");
-- gaim_prefs_add_bool("/gaim/gtk/conversations/use_smooth_scrolling", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/close_on_tabs", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/send_bold", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/send_italic", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/send_underline", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/spellcheck", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/show_incoming_formatting", TRUE);
--
-- gaim_prefs_add_bool("/gaim/gtk/conversations/show_timestamps", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/show_formatting_toolbar", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/passthrough_unknown_commands", FALSE);
--
-- gaim_prefs_add_string("/gaim/gtk/conversations/placement", "last");
-- gaim_prefs_add_int("/gaim/gtk/conversations/placement_number", 1);
-- gaim_prefs_add_string("/gaim/gtk/conversations/bgcolor", "");
-- gaim_prefs_add_string("/gaim/gtk/conversations/fgcolor", "");
-- gaim_prefs_add_string("/gaim/gtk/conversations/font_face", "");
-- gaim_prefs_add_int("/gaim/gtk/conversations/font_size", 3);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/tabs", TRUE);
-- gaim_prefs_add_int("/gaim/gtk/conversations/tab_side", GTK_POS_TOP);
-- gaim_prefs_add_int("/gaim/gtk/conversations/scrollback_lines", 4000);
-+ gaim2_prefs_add_none("/gaim2/gtk/conversations");
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/use_smooth_scrolling", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/close_on_tabs", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/send_bold", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/send_italic", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/send_underline", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/spellcheck", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/show_incoming_formatting", TRUE);
-+
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/show_timestamps", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/show_formatting_toolbar", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/passthrough_unknown_commands", FALSE);
-+
-+ gaim2_prefs_add_string("/gaim2/gtk/conversations/placement", "last");
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/placement_number", 1);
-+ gaim2_prefs_add_string("/gaim2/gtk/conversations/bgcolor", "");
-+ gaim2_prefs_add_string("/gaim2/gtk/conversations/fgcolor", "");
-+ gaim2_prefs_add_string("/gaim2/gtk/conversations/font_face", "");
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/font_size", 3);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/tabs", TRUE);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/tab_side", GTK_POS_TOP);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/scrollback_lines", 4000);
-
- /* Conversations -> Chat */
-- gaim_prefs_add_none("/gaim/gtk/conversations/chat");
-- gaim_prefs_add_int("/gaim/gtk/conversations/chat/default_width", 410);
-- gaim_prefs_add_int("/gaim/gtk/conversations/chat/default_height", 160);
-- gaim_prefs_add_int("/gaim/gtk/conversations/chat/entry_height", 50);
-+ gaim2_prefs_add_none("/gaim2/gtk/conversations/chat");
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/chat/default_width", 410);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/chat/default_height", 160);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/chat/entry_height", 50);
-
- /* Conversations -> IM */
-- gaim_prefs_add_none("/gaim/gtk/conversations/im");
-+ gaim2_prefs_add_none("/gaim2/gtk/conversations/im");
-
-- gaim_prefs_add_bool("/gaim/gtk/conversations/im/animate_buddy_icons", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/im/animate_buddy_icons", TRUE);
-
-- gaim_prefs_add_int("/gaim/gtk/conversations/im/default_width", 410);
-- gaim_prefs_add_int("/gaim/gtk/conversations/im/default_height", 160);
-- gaim_prefs_add_int("/gaim/gtk/conversations/im/entry_height", 50);
-- gaim_prefs_add_bool("/gaim/gtk/conversations/im/show_buddy_icons", TRUE);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/im/default_width", 410);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/im/default_height", 160);
-+ gaim2_prefs_add_int("/gaim2/gtk/conversations/im/entry_height", 50);
-+ gaim2_prefs_add_bool("/gaim2/gtk/conversations/im/show_buddy_icons", TRUE);
-
-- gaim_prefs_add_string("/gaim/gtk/conversations/im/hide_new", "never");
-+ gaim2_prefs_add_string("/gaim2/gtk/conversations/im/hide_new", "never");
-
- /* Connect callbacks. */
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/close_on_tabs",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/close_on_tabs",
- close_on_tabs_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/show_timestamps",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/show_timestamps",
- show_timestamps_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/show_formatting_toolbar",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/show_formatting_toolbar",
- show_formatting_toolbar_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/spellcheck",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/spellcheck",
- spellcheck_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/tab_side",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/tab_side",
- tab_side_pref_cb, NULL);
-
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/tabs",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/tabs",
- conv_placement_usetabs_cb, NULL);
-
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/placement",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/placement",
- conv_placement_pref_cb, NULL);
-- gaim_prefs_trigger_callback("/gaim/gtk/conversations/placement");
-+ gaim2_prefs_trigger_callback("/gaim2/gtk/conversations/placement");
-
- /* IM callbacks */
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/im/animate_buddy_icons",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/im/animate_buddy_icons",
- animate_buddy_icons_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/im/show_buddy_icons",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/im/show_buddy_icons",
- show_buddy_icons_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/conversations/im/hide_new",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/conversations/im/hide_new",
- hide_new_pref_cb, NULL);
-
-
-@@ -6171,74 +6171,74 @@ gaim_gtk_conversations_init(void)
- /**********************************************************************
- * Register signals
- **********************************************************************/
-- gaim_signal_register(handle, "conversation-dragging",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 2,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "conversation-dragging",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 2,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONV_WINDOW),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONV_WINDOW));
-
-- gaim_signal_register(handle, "displaying-im-msg",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 4,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "displaying-im-msg",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 4,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new(G_TYPE_INT));
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new(G_TYPE_INT));
-
-- gaim_signal_register(handle, "displayed-im-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT,
-+ gaim2_signal_register(handle, "displayed-im-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER_UINT,
- NULL, 4,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(G_TYPE_INT));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(G_TYPE_INT));
-
-- gaim_signal_register(handle, "displaying-chat-msg",
-- gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 4,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "displaying-chat-msg",
-+ gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 4,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING),
-- gaim_value_new(G_TYPE_INT));
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING),
-+ gaim2_value_new(G_TYPE_INT));
-
-- gaim_signal_register(handle, "displayed-chat-msg",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT,
-+ gaim2_signal_register(handle, "displayed-chat-msg",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER_UINT,
- NULL, 4,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new(G_TYPE_INT));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new(G_TYPE_INT));
-
-- gaim_signal_register(handle, "conversation-switched",
-- gaim_marshal_VOID__POINTER_POINTER, NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "conversation-switched",
-+ gaim2_marshal_VOID__POINTER_POINTER, NULL, 1,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_CONVERSATION));
-
- /**********************************************************************
- * Register commands
- **********************************************************************/
-- gaim_cmd_register("say", "S", GAIM_CMD_P_DEFAULT,
-+ gaim2_cmd_register("say", "S", GAIM_CMD_P_DEFAULT,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_IM, NULL,
- say_command_cb, _("say &lt;message&gt;: Send a message normally as if you weren't using a command."), NULL);
-- gaim_cmd_register("me", "S", GAIM_CMD_P_DEFAULT,
-+ gaim2_cmd_register("me", "S", GAIM_CMD_P_DEFAULT,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_IM, NULL,
- me_command_cb, _("me &lt;action&gt;: Send an IRC style action to a buddy or chat."), NULL);
-- gaim_cmd_register("debug", "w", GAIM_CMD_P_DEFAULT,
-+ gaim2_cmd_register("debug", "w", GAIM_CMD_P_DEFAULT,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_IM, NULL,
- debug_command_cb, _("debug &lt;option&gt;: Send various debug information to the current conversation."), NULL);
-- gaim_cmd_register("clear", "", GAIM_CMD_P_DEFAULT,
-+ gaim2_cmd_register("clear", "", GAIM_CMD_P_DEFAULT,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_IM, NULL,
- clear_command_cb, _("clear: Clears the conversation scrollback."), NULL);
-- gaim_cmd_register("help", "w", GAIM_CMD_P_DEFAULT,
-+ gaim2_cmd_register("help", "w", GAIM_CMD_P_DEFAULT,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, NULL,
- help_command_cb, _("help &lt;command&gt;: Help on a specific command."), NULL);
-
-@@ -6246,37 +6246,37 @@ gaim_gtk_conversations_init(void)
- * UI operations
- **********************************************************************/
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on", handle,
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on", handle,
- G_CALLBACK(account_signed_off_cb),
- GINT_TO_POINTER(GAIM_CONV_ACCOUNT_ONLINE));
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off", handle,
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off", handle,
- G_CALLBACK(account_signed_off_cb),
- GINT_TO_POINTER(GAIM_CONV_ACCOUNT_OFFLINE));
-
-- gaim_signal_connect(blist_handle, "buddy-added", handle,
-+ gaim2_signal_connect(blist_handle, "buddy-added", handle,
- G_CALLBACK(buddy_update_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-removed", handle,
-+ gaim2_signal_connect(blist_handle, "buddy-removed", handle,
- G_CALLBACK(buddy_update_cb), NULL);
-
-- gaim_signal_connect(gaim_conversations_get_handle(), "received-im-msg",
-+ gaim2_signal_connect(gaim2_conversations_get_handle(), "received-im-msg",
- handle, G_CALLBACK(received_im_msg_cb), NULL);
-
-- gaim_conversations_set_ui_ops(&conversation_ui_ops);
-+ gaim2_conversations_set_ui_ops(&conversation_ui_ops);
-
-- hidden_convwin = gaim_gtk_conv_window_new();
-+ hidden_convwin = gaim2_gtk_conv_window_new();
- window_list = g_list_remove(window_list, hidden_convwin);
-
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-status-changed",
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-status-changed",
- handle, GAIM_CALLBACK(account_status_changed_cb), NULL);
- }
-
- void
--gaim_gtk_conversations_uninit(void)
-+gaim2_gtk_conversations_uninit(void)
- {
-- gaim_prefs_disconnect_by_handle(gaim_gtk_conversations_get_handle());
-- gaim_signals_disconnect_by_handle(gaim_gtk_conversations_get_handle());
-- gaim_signals_unregister_by_instance(gaim_gtk_conversations_get_handle());
-- gaim_gtk_conv_window_destroy(hidden_convwin);
-+ gaim2_prefs_disconnect_by_handle(gaim2_gtk_conversations_get_handle());
-+ gaim2_signals_disconnect_by_handle(gaim2_gtk_conversations_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_gtk_conversations_get_handle());
-+ gaim2_gtk_conv_window_destroy(hidden_convwin);
- hidden_convwin=NULL;
- }
-
-@@ -6302,9 +6302,9 @@ gaim_gtk_conversations_uninit(void)
- * @file gtkconvwin.c GTK+ Conversation Window API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -6324,7 +6324,7 @@ gaim_gtk_conversations_uninit(void)
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
-
- #include <gdk/gdkkeysyms.h>
-@@ -6353,17 +6353,17 @@ gaim_gtk_conversations_uninit(void)
- #include "gtkimhtmltoolbar.h"
-
- static void
--do_close(GtkWidget *w, int resp, GaimGtkWindow *win)
-+do_close(GtkWidget *w, int resp, Gaim2GtkWindow *win)
- {
- gtk_widget_destroy(warn_close_dialog);
- warn_close_dialog = NULL;
-
- if (resp == GTK_RESPONSE_OK)
-- gaim_gtk_conv_window_destroy(win);
-+ gaim2_gtk_conv_window_destroy(win);
- }
-
- static void
--build_warn_close_dialog(GaimGtkWindow *gtkwin)
-+build_warn_close_dialog(Gaim2GtkWindow *gtkwin)
- {
- GtkWidget *label;
- GtkWidget *vbox, *hbox;
-@@ -6424,15 +6424,15 @@ build_warn_close_dialog(GaimGtkWindow *g
- static gboolean
- close_win_cb(GtkWidget *w, GdkEventAny *e, gpointer d)
- {
-- GaimGtkWindow *win = d;
-+ Gaim2GtkWindow *win = d;
- GList *l;
-
- /* If there are unread messages then show a warning dialog */
-- for (l = gaim_gtk_conv_window_get_gtkconvs(win);
-+ for (l = gaim2_gtk_conv_window_get_gtkconvs(win);
- l != NULL; l = l->next)
- {
-- GaimGtkConversation *gtkconv = l->data;
-- if (gaim_conversation_get_type(gtkconv->active_conv) == GAIM_CONV_TYPE_IM &&
-+ Gaim2GtkConversation *gtkconv = l->data;
-+ if (gaim2_conversation_get_type(gtkconv->active_conv) == GAIM_CONV_TYPE_IM &&
- gtkconv->unseen_state >= GAIM_UNSEEN_TEXT)
- {
- build_warn_close_dialog(win);
-@@ -6442,13 +6442,13 @@ close_win_cb(GtkWidget *w, GdkEventAny *
- }
- }
-
-- gaim_gtk_conv_window_destroy(win);
-+ gaim2_gtk_conv_window_destroy(win);
-
- return TRUE;
- }
-
- static void
--gtkconv_set_unseen(GaimGtkConversation *gtkconv, GaimUnseenState state)
-+gtkconv_set_unseen(Gaim2GtkConversation *gtkconv, Gaim2UnseenState state)
- {
- if (state == GAIM_UNSEEN_NONE)
- {
-@@ -6465,7 +6465,7 @@ gtkconv_set_unseen(GaimGtkConversation *
- }
-
- /* emit update signal to notify of count and possible unseen state change */
-- gaim_conversation_update(gtkconv->active_conv, GAIM_CONV_UPDATE_UNSEEN);
-+ gaim2_conversation_update(gtkconv->active_conv, GAIM_CONV_UPDATE_UNSEEN);
- }
-
- /*
-@@ -6476,8 +6476,8 @@ gtkconv_set_unseen(GaimGtkConversation *
- static gint
- focus_win_cb(GtkWidget *w, GdkEventFocus *e, gpointer d)
- {
-- GaimGtkWindow *win = d;
-- GaimGtkConversation *gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ Gaim2GtkWindow *win = d;
-+ Gaim2GtkConversation *gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
-
- gtkconv_set_unseen(gtkconv, GAIM_UNSEEN_NONE);
-
-@@ -6495,7 +6495,7 @@ tab_close_button_state_changed_cb(GtkWid
- #endif
-
- static void
--notebook_init_grab(GaimGtkWindow *gtkwin, GtkWidget *widget)
-+notebook_init_grab(Gaim2GtkWindow *gtkwin, GtkWidget *widget)
- {
- static GdkCursor *cursor = NULL;
-
-@@ -6523,7 +6523,7 @@ notebook_init_grab(GaimGtkWindow *gtkwin
- }
-
- static gboolean
--notebook_motion_cb(GtkWidget *widget, GdkEventButton *e, GaimGtkWindow *win)
-+notebook_motion_cb(GtkWidget *widget, GdkEventButton *e, Gaim2GtkWindow *win)
- {
-
- /*
-@@ -6541,17 +6541,17 @@ notebook_motion_cb(GtkWidget *widget, Gd
- }
- }
- else { /* Otherwise, draw the arrows. */
-- GaimGtkWindow *dest_win;
-+ Gaim2GtkWindow *dest_win;
- GtkNotebook *dest_notebook;
- GtkWidget *tab;
- gint nb_x, nb_y, page_num;
- gint arrow1_x, arrow1_y, arrow2_x, arrow2_y;
- gboolean horiz_tabs = FALSE;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
- gboolean to_right = FALSE;
-
- /* Get the window that the cursor is over. */
-- dest_win = gaim_gtk_conv_window_get_at_xy(e->x_root, e->y_root);
-+ dest_win = gaim2_gtk_conv_window_get_at_xy(e->x_root, e->y_root);
-
- if (dest_win == NULL) {
- dnd_hints_hide_all();
-@@ -6566,7 +6566,7 @@ notebook_motion_cb(GtkWidget *widget, Gd
- arrow1_x = arrow2_x = nb_x;
- arrow1_y = arrow2_y = nb_y;
-
-- page_num = gaim_gtkconv_get_tab_at_xy(dest_win,
-+ page_num = gaim2_gtkconv_get_tab_at_xy(dest_win,
- e->x_root, e->y_root, &to_right);
- to_right = to_right && (win != dest_win);
-
-@@ -6576,7 +6576,7 @@ notebook_motion_cb(GtkWidget *widget, Gd
- horiz_tabs = TRUE;
- }
-
-- gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(dest_win, page_num);
-+ gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(dest_win, page_num);
- tab = gtkconv->tabby;
-
- if (horiz_tabs) {
-@@ -6615,7 +6615,7 @@ notebook_motion_cb(GtkWidget *widget, Gd
- }
-
- static gboolean
--notebook_leave_cb(GtkWidget *widget, GdkEventCrossing *e, GaimGtkWindow *win)
-+notebook_leave_cb(GtkWidget *widget, GdkEventCrossing *e, Gaim2GtkWindow *win)
- {
- if (win->in_drag)
- return FALSE;
-@@ -6636,7 +6636,7 @@ notebook_leave_cb(GtkWidget *widget, Gdk
- * THANK YOU GALEON!
- */
- static gboolean
--notebook_press_cb(GtkWidget *widget, GdkEventButton *e, GaimGtkWindow *win)
-+notebook_press_cb(GtkWidget *widget, GdkEventButton *e, Gaim2GtkWindow *win)
- {
- gint nb_x, nb_y, x_rel, y_rel;
- int tab_clicked;
-@@ -6648,7 +6648,7 @@ notebook_press_cb(GtkWidget *widget, Gdk
-
-
- if (win->in_drag) {
-- gaim_debug(GAIM_DEBUG_WARNING, "gtkconv",
-+ gaim2_debug(GAIM_DEBUG_WARNING, "gtkconv",
- "Already in the middle of a window drag at tab_press_cb\n");
- return TRUE;
- }
-@@ -6657,7 +6657,7 @@ notebook_press_cb(GtkWidget *widget, Gdk
- * Make sure a tab was actually clicked. The arrow buttons
- * mess things up.
- */
-- tab_clicked = gaim_gtkconv_get_tab_at_xy(win, e->x_root, e->y_root, NULL);
-+ tab_clicked = gaim2_gtkconv_get_tab_at_xy(win, e->x_root, e->y_root, NULL);
-
- if (tab_clicked == -1)
- return FALSE;
-@@ -6711,11 +6711,11 @@ notebook_press_cb(GtkWidget *widget, Gdk
- }
-
- static gboolean
--notebook_release_cb(GtkWidget *widget, GdkEventButton *e, GaimGtkWindow *win)
-+notebook_release_cb(GtkWidget *widget, GdkEventButton *e, Gaim2GtkWindow *win)
- {
-- GaimGtkWindow *dest_win;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *dest_win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- gint dest_page_num = 0;
- gboolean new_window = FALSE;
- gboolean to_right = FALSE;
-@@ -6768,16 +6768,16 @@ notebook_release_cb(GtkWidget *widget, G
-
- dnd_hints_hide_all();
-
-- dest_win = gaim_gtk_conv_window_get_at_xy(e->x_root, e->y_root);
-+ dest_win = gaim2_gtk_conv_window_get_at_xy(e->x_root, e->y_root);
-
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- if (dest_win == NULL) {
- /* If the current window doesn't have any other conversations,
- * there isn't much point transferring the conv to a new window. */
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) > 1) {
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) > 1) {
- /* Make a new window to stick this to. */
-- dest_win = gaim_gtk_conv_window_new();
-+ dest_win = gaim2_gtk_conv_window_new();
- new_window = TRUE;
- }
- }
-@@ -6785,12 +6785,12 @@ notebook_release_cb(GtkWidget *widget, G
- if (dest_win == NULL)
- return FALSE;
-
-- gaim_signal_emit(gaim_gtk_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_gtk_conversations_get_handle(),
- "conversation-dragging", win, dest_win);
-
- /* Get the destination page number. */
- if (!new_window)
-- dest_page_num = gaim_gtkconv_get_tab_at_xy(dest_win,
-+ dest_page_num = gaim2_gtkconv_get_tab_at_xy(dest_win,
- e->x_root, e->y_root, &to_right);
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-@@ -6798,10 +6798,10 @@ notebook_release_cb(GtkWidget *widget, G
- if (win == dest_win) {
- gtk_notebook_reorder_child(GTK_NOTEBOOK(win->notebook), gtkconv->tab_cont, dest_page_num);
- } else {
-- gaim_gtk_conv_window_remove_gtkconv(win, gtkconv);
-- gaim_gtk_conv_window_add_gtkconv(dest_win, gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(win, gtkconv);
-+ gaim2_gtk_conv_window_add_gtkconv(dest_win, gtkconv);
- gtk_notebook_reorder_child(GTK_NOTEBOOK(dest_win->notebook), gtkconv->tab_cont, dest_page_num + to_right);
-- gaim_gtk_conv_window_switch_gtkconv(dest_win, gtkconv);
-+ gaim2_gtk_conv_window_switch_gtkconv(dest_win, gtkconv);
- if (new_window) {
- gint win_width, win_height;
-
-@@ -6812,7 +6812,7 @@ notebook_release_cb(GtkWidget *widget, G
- e->x_root - (win_width / 2),
- e->y_root - (win_height / 2));
-
-- gaim_gtk_conv_window_show(dest_win);
-+ gaim2_gtk_conv_window_show(dest_win);
- }
- }
-
-@@ -6826,16 +6826,16 @@ static void
- before_switch_conv_cb(GtkNotebook *notebook, GtkWidget *page, gint page_num,
- gpointer user_data)
- {
-- GaimGtkWindow *win;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
- win = user_data;
-- conv = gaim_gtk_conv_window_get_active_conversation(win);
-+ conv = gaim2_gtk_conv_window_get_active_conversation(win);
-
- g_return_if_fail(conv != NULL);
-
-- if (gaim_conversation_get_type(conv) != GAIM_CONV_TYPE_IM)
-+ if (gaim2_conversation_get_type(conv) != GAIM_CONV_TYPE_IM)
- return;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-@@ -6843,7 +6843,7 @@ before_switch_conv_cb(GtkNotebook *noteb
- stop_anim(NULL, gtkconv);
- }
- static void
--close_window(GtkWidget *w, GaimGtkWindow *win)
-+close_window(GtkWidget *w, Gaim2GtkWindow *win)
- {
- close_win_cb(w, NULL, win);
- }
-@@ -6851,43 +6851,43 @@ close_window(GtkWidget *w, GaimGtkWindow
- static void
- detach_tab_cb(GtkWidget *w, GObject *menu)
- {
-- GaimGtkWindow *win, *new_window;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win, *new_window;
-+ Gaim2GtkConversation *gtkconv;
-
- gtkconv = g_object_get_data(menu, "clicked_tab");
-
- if (!gtkconv)
- return;
-
-- win = gaim_gtkconv_get_window(gtkconv);
-+ win = gaim2_gtkconv_get_window(gtkconv);
- /* Nothing to do if there's only one tab in the window */
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) == 1)
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) == 1)
- return;
-
-- gaim_gtk_conv_window_remove_gtkconv(win, gtkconv);
-+ gaim2_gtk_conv_window_remove_gtkconv(win, gtkconv);
-
-- new_window = gaim_gtk_conv_window_new();
-- gaim_gtk_conv_window_add_gtkconv(new_window, gtkconv);
-- gaim_gtk_conv_window_show(new_window);
-+ new_window = gaim2_gtk_conv_window_new();
-+ gaim2_gtk_conv_window_add_gtkconv(new_window, gtkconv);
-+ gaim2_gtk_conv_window_show(new_window);
- }
-
- static void
- close_others_cb(GtkWidget *w, GObject *menu)
- {
- GList *iter;
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-
- gtkconv = g_object_get_data(menu, "clicked_tab");
-
- if (!gtkconv)
- return;
-
-- win = gaim_gtkconv_get_window(gtkconv);
-+ win = gaim2_gtkconv_get_window(gtkconv);
-
-- for (iter = gaim_gtk_conv_window_get_gtkconvs(win); iter; )
-+ for (iter = gaim2_gtk_conv_window_get_gtkconvs(win); iter; )
- {
-- GaimGtkConversation *gconv = iter->data;
-+ Gaim2GtkConversation *gconv = iter->data;
- iter = iter->next;
-
- if (gconv != gtkconv)
-@@ -6899,7 +6899,7 @@ close_others_cb(GtkWidget *w, GObject *m
-
- static void close_tab_cb(GtkWidget *w, GObject *menu)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- gtkconv = g_object_get_data(menu, "clicked_tab");
-
-@@ -6908,16 +6908,16 @@ static void close_tab_cb(GtkWidget *w, G
- }
-
- static gboolean
--right_click_menu_cb(GtkNotebook *notebook, GdkEventButton *event, GaimGtkWindow *win)
-+right_click_menu_cb(GtkNotebook *notebook, GdkEventButton *event, Gaim2GtkWindow *win)
- {
- GtkWidget *item, *menu;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
- if (event->type != GDK_BUTTON_PRESS || event->button != 3)
- return FALSE;
-
-- gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(win,
-- gaim_gtkconv_get_tab_at_xy(win, event->x_root, event->y_root, NULL));
-+ gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(win,
-+ gaim2_gtkconv_get_tab_at_xy(win, event->x_root, event->y_root, NULL));
-
- if (g_object_get_data(G_OBJECT(notebook->menu), "clicked_tab"))
- {
-@@ -6928,7 +6928,7 @@ right_click_menu_cb(GtkNotebook *noteboo
- g_object_set_data(G_OBJECT(notebook->menu), "clicked_tab", gtkconv);
-
- menu = notebook->menu;
-- gaim_separator(GTK_WIDGET(menu));
-+ gaim2_separator(GTK_WIDGET(menu));
-
- item = gtk_menu_item_new_with_label("Detach this tab");
- gtk_widget_show(item);
-@@ -6942,7 +6942,7 @@ right_click_menu_cb(GtkNotebook *noteboo
- g_signal_connect(G_OBJECT(item), "activate",
- G_CALLBACK(close_tab_cb), menu);
-
-- gaim_separator(menu);
-+ gaim2_separator(menu);
-
- item = gtk_menu_item_new_with_label("Close other tabs");
- gtk_widget_show(item);
-@@ -6963,13 +6963,13 @@ static void
- switch_conv_cb(GtkNotebook *notebook, GtkWidget *page, gint page_num,
- gpointer user_data)
- {
-- GaimGtkWindow *win;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- const char *sound_method;
-
- win = user_data;
-- gtkconv = gaim_gtk_conv_window_get_gtkconv_at_index(win, page_num);
-+ gtkconv = gaim2_gtk_conv_window_get_gtkconv_at_index(win, page_num);
- conv = gtkconv->active_conv;
-
- g_return_if_fail(conv != NULL);
-@@ -6977,31 +6977,31 @@ switch_conv_cb(GtkNotebook *notebook, Gt
- /*
- * Only set "unseen" to "none" if the window has focus
- */
-- if (gaim_gtk_conv_window_has_focus(win))
-+ if (gaim2_gtk_conv_window_has_focus(win))
- gtkconv_set_unseen(gtkconv, GAIM_UNSEEN_NONE);
-
- /* Update the menubar */
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(gtkconv->win->menu.logging),
-- gaim_conversation_is_logging(conv));
-+ gaim2_conversation_is_logging(conv));
-
- generate_send_to_items(win);
-
-- gaim_gtkconv_switch_active_conversation(conv);
-+ gaim2_gtkconv_switch_active_conversation(conv);
-
-- sound_method = gaim_prefs_get_string("/gaim/gtk/sound/method");
-+ sound_method = gaim2_prefs_get_string("/gaim2/gtk/sound/method");
- if (strcmp(sound_method, "none") != 0)
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.sounds),
- gtkconv->make_sound);
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.show_formatting_toolbar),
-- gaim_prefs_get_bool("/gaim/gtk/conversations/show_formatting_toolbar"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/conversations/show_formatting_toolbar"));
-
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.show_timestamps),
-- gaim_prefs_get_bool("/gaim/gtk/conversations/show_timestamps"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/conversations/show_timestamps"));
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM &&
-- gaim_prefs_get_bool("/gaim/gtk/conversations/im/show_buddy_icons"))
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM &&
-+ gaim2_prefs_get_bool("/gaim2/gtk/conversations/im/show_buddy_icons"))
- {
- gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(win->menu.show_icon),
- gtkconv->u.im->show_icon);
-@@ -7011,11 +7011,11 @@ switch_conv_cb(GtkNotebook *notebook, Gt
- * We pause icons when they are not visible. If this icon should
- * be animated then start it back up again.
- */
-- if ((gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) &&
-+ if ((gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM) &&
- (gtkconv->u.im->animate))
- start_anim(NULL, gtkconv);
-
-- gaim_signal_emit(gaim_gtk_conversations_get_handle(), "conversation-switched", conv);
-+ gaim2_signal_emit(gaim2_gtk_conversations_get_handle(), "conversation-switched", conv);
- }
-
- /**************************************************************************
-@@ -7023,20 +7023,20 @@ switch_conv_cb(GtkNotebook *notebook, Gt
- **************************************************************************/
-
- GList *
--gaim_gtk_conv_windows_get_list()
-+gaim2_gtk_conv_windows_get_list()
- {
- return window_list;
- }
-
--GaimGtkWindow *
--gaim_gtk_conv_window_new()
-+Gaim2GtkWindow *
-+gaim2_gtk_conv_window_new()
- {
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
- GtkPositionType pos;
- GtkWidget *testidea;
- GtkWidget *menubar;
-
-- win = g_malloc0(sizeof(GaimGtkWindow));
-+ win = g_malloc0(sizeof(Gaim2GtkWindow));
-
- window_list = g_list_append(window_list, win);
-
-@@ -7056,7 +7056,7 @@ gaim_gtk_conv_window_new()
- /* Create the notebook. */
- win->notebook = gtk_notebook_new();
-
-- pos = gaim_prefs_get_int("/gaim/gtk/conversations/tab_side");
-+ pos = gaim2_prefs_get_int("/gaim2/gtk/conversations/tab_side");
-
- #if 0
- gtk_notebook_set_tab_hborder(GTK_NOTEBOOK(win->notebook), 0);
-@@ -7102,18 +7102,18 @@ gaim_gtk_conv_window_new()
- }
-
- void
--gaim_gtk_conv_window_destroy(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_destroy(Gaim2GtkWindow *win)
- {
-- gaim_prefs_disconnect_by_handle(win);
-+ gaim2_prefs_disconnect_by_handle(win);
- window_list = g_list_remove(window_list, win);
-
- if (win->gtkconvs) {
- while (win->gtkconvs) {
- GList *nextgtk = win->gtkconvs->next;
-- GaimGtkConversation *gtkconv = win->gtkconvs->data;
-+ Gaim2GtkConversation *gtkconv = win->gtkconvs->data;
- GList *nextcore = gtkconv->convs->next;
-- GaimConversation *conv = gtkconv->convs->data;
-- gaim_conversation_destroy(conv);
-+ Gaim2Conversation *conv = gtkconv->convs->data;
-+ gaim2_conversation_destroy(conv);
- if (!nextgtk && !nextcore)
- /* we'll end up invoking ourselves when we destroy our last child */
- /* so don't destroy ourselves right now */
-@@ -7129,25 +7129,25 @@ gaim_gtk_conv_window_destroy(GaimGtkWind
- }
-
- void
--gaim_gtk_conv_window_show(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_show(Gaim2GtkWindow *win)
- {
- gtk_widget_show(win->window);
- }
-
- void
--gaim_gtk_conv_window_hide(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_hide(Gaim2GtkWindow *win)
- {
- gtk_widget_hide(win->window);
- }
-
- void
--gaim_gtk_conv_window_raise(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_raise(Gaim2GtkWindow *win)
- {
- gtk_window_present(GTK_WINDOW(win->window));
- }
-
- void
--gaim_gtk_conv_window_switch_gtkconv(GaimGtkWindow *win, GaimGtkConversation *gtkconv)
-+gaim2_gtk_conv_window_switch_gtkconv(Gaim2GtkWindow *win, Gaim2GtkConversation *gtkconv)
- {
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook),
- gtk_notebook_page_num(GTK_NOTEBOOK(win->notebook),
-@@ -7155,33 +7155,33 @@ gaim_gtk_conv_window_switch_gtkconv(Gaim
- }
-
- void
--gaim_gtk_conv_window_add_gtkconv(GaimGtkWindow *win, GaimGtkConversation *gtkconv)
-+gaim2_gtk_conv_window_add_gtkconv(Gaim2GtkWindow *win, Gaim2GtkConversation *gtkconv)
- {
-- GaimConversation *conv = gtkconv->active_conv;
-- GaimGtkConversation *focus_gtkconv;
-+ Gaim2Conversation *conv = gtkconv->active_conv;
-+ Gaim2GtkConversation *focus_gtkconv;
- GtkWidget *tabby, *menu_tabby;
- GtkWidget *tab_cont = gtkconv->tab_cont;
- GtkWidget *close_image;
-- GaimConversationType conv_type;
-+ Gaim2ConversationType conv_type;
- const char *name;
- const gchar *tmp_lab;
- gint close_button_width, close_button_height, focus_width, focus_pad;
- gboolean tabs_side = FALSE;
- gint angle = 0;
-
-- name = gaim_conversation_get_name(conv);
-- conv_type = gaim_conversation_get_type(conv);
-+ name = gaim2_conversation_get_name(conv);
-+ conv_type = gaim2_conversation_get_type(conv);
-
-
- win->gtkconvs = g_list_append(win->gtkconvs, gtkconv);
- gtkconv->win = win;
-
-- if (gaim_prefs_get_int("/gaim/gtk/conversations/tab_side") == GTK_POS_LEFT ||
-- gaim_prefs_get_int("/gaim/gtk/conversations/tab_side") == GTK_POS_RIGHT)
-+ if (gaim2_prefs_get_int("/gaim2/gtk/conversations/tab_side") == GTK_POS_LEFT ||
-+ gaim2_prefs_get_int("/gaim2/gtk/conversations/tab_side") == GTK_POS_RIGHT)
- tabs_side = TRUE;
-- else if (gaim_prefs_get_int("/gaim/gtk/conversations/tab_side") == (GTK_POS_LEFT|8))
-+ else if (gaim2_prefs_get_int("/gaim2/gtk/conversations/tab_side") == (GTK_POS_LEFT|8))
- angle = 90;
-- else if (gaim_prefs_get_int("/gaim/gtk/conversations/tab_side") == (GTK_POS_RIGHT|8))
-+ else if (gaim2_prefs_get_int("/gaim2/gtk/conversations/tab_side") == (GTK_POS_RIGHT|8))
- angle = 270;
-
- if (angle)
-@@ -7231,7 +7231,7 @@ gaim_gtk_conv_window_add_gtkconv(GaimGtk
- update_tab_icon(conv);
-
- /* Tab label. */
-- gtkconv->tab_label = gtk_label_new(tmp_lab = gaim_conversation_get_title(conv));
-+ gtkconv->tab_label = gtk_label_new(tmp_lab = gaim2_conversation_get_title(conv));
-
- #if GTK_CHECK_VERSION(2,6,0)
- if (!angle)
-@@ -7243,7 +7243,7 @@ gaim_gtk_conv_window_add_gtkconv(GaimGtk
- if (angle)
- gtk_label_set_angle(GTK_LABEL(gtkconv->tab_label), angle);
- #endif
-- gtkconv->menu_label = gtk_label_new(gaim_conversation_get_title(conv));
-+ gtkconv->menu_label = gtk_label_new(gaim2_conversation_get_title(conv));
- #if 0
- gtk_misc_set_alignment(GTK_MISC(gtkconv->tab_label), 0.00, 0.5);
- gtk_misc_set_padding(GTK_MISC(gtkconv->tab_label), 4, 0);
-@@ -7270,14 +7270,14 @@ gaim_gtk_conv_window_add_gtkconv(GaimGtk
- gtk_box_pack_start(GTK_BOX(tabby), gtkconv->icon, FALSE, FALSE, 0);
- else
- gtk_box_pack_start(GTK_BOX(tabby), gtkconv->close, FALSE, FALSE, 0);
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/close_on_tabs"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/close_on_tabs"))
- gtk_widget_show(gtkconv->close);
-
- gtk_widget_show(tabby);
- gtk_widget_show(menu_tabby);
-
-- if (gaim_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-- gaim_gtkconv_update_buddy_icon(conv);
-+ if (gaim2_conversation_get_type(conv) == GAIM_CONV_TYPE_IM)
-+ gaim2_gtkconv_update_buddy_icon(conv);
-
- /* Add this pane to the conversation's notebook. */
- gtk_notebook_append_page_menu(GTK_NOTEBOOK(win->notebook), tab_cont, tabby, menu_tabby);
-@@ -7286,30 +7286,30 @@ gaim_gtk_conv_window_add_gtkconv(GaimGtk
-
- gtk_widget_show(tab_cont);
-
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) == 1) {
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) == 1) {
- /* Er, bug in notebooks? Switch to the page manually. */
- gtk_notebook_set_current_page(GTK_NOTEBOOK(win->notebook), 0);
-
- gtk_notebook_set_show_tabs(GTK_NOTEBOOK(win->notebook),
-- gaim_prefs_get_bool("/gaim/gtk/conversations/tabs"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/conversations/tabs"));
- } else
- gtk_notebook_set_show_tabs(GTK_NOTEBOOK(win->notebook), TRUE);
-
-- focus_gtkconv = g_list_nth_data(gaim_gtk_conv_window_get_gtkconvs(win),
-+ focus_gtkconv = g_list_nth_data(gaim2_gtk_conv_window_get_gtkconvs(win),
- gtk_notebook_get_current_page(GTK_NOTEBOOK(win->notebook)));
- gtk_widget_grab_focus(focus_gtkconv->entry);
-
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) == 1)
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) == 1)
- update_send_to_selection(win);
- }
-
- void
--gaim_gtk_conv_window_remove_gtkconv(GaimGtkWindow *win, GaimGtkConversation *gtkconv)
-+gaim2_gtk_conv_window_remove_gtkconv(Gaim2GtkWindow *win, Gaim2GtkConversation *gtkconv)
- {
- unsigned int index;
-- GaimConversationType conv_type;
-+ Gaim2ConversationType conv_type;
-
-- conv_type = gaim_conversation_get_type(gtkconv->active_conv);
-+ conv_type = gaim2_conversation_get_type(gtkconv->active_conv);
- index = gtk_notebook_page_num(GTK_NOTEBOOK(win->notebook), gtkconv->tab_cont);
-
- g_object_ref(gtkconv->tab_cont);
-@@ -7318,30 +7318,30 @@ gaim_gtk_conv_window_remove_gtkconv(Gaim
- gtk_notebook_remove_page(GTK_NOTEBOOK(win->notebook), index);
-
- /* go back to tabless if need be */
-- if (gaim_gtk_conv_window_get_gtkconv_count(win) <= 2) {
-+ if (gaim2_gtk_conv_window_get_gtkconv_count(win) <= 2) {
- gtk_notebook_set_show_tabs(GTK_NOTEBOOK(win->notebook),
-- gaim_prefs_get_bool("/gaim/gtk/conversations/tabs"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/conversations/tabs"));
- }
-
- win->gtkconvs = g_list_remove(win->gtkconvs, gtkconv);
-
- if (!win->gtkconvs && win != hidden_convwin)
-- gaim_gtk_conv_window_destroy(win);
-+ gaim2_gtk_conv_window_destroy(win);
- }
-
--GaimGtkConversation *
--gaim_gtk_conv_window_get_gtkconv_at_index(const GaimGtkWindow *win, int index)
-+Gaim2GtkConversation *
-+gaim2_gtk_conv_window_get_gtkconv_at_index(const Gaim2GtkWindow *win, int index)
- {
- GtkWidget *tab_cont;
-
- if (index == -1)
- index = 0;
- tab_cont = gtk_notebook_get_nth_page(GTK_NOTEBOOK(win->notebook), index);
-- return tab_cont ? g_object_get_data(G_OBJECT(tab_cont), "GaimGtkConversation") : NULL;
-+ return tab_cont ? g_object_get_data(G_OBJECT(tab_cont), "Gaim2GtkConversation") : NULL;
- }
-
--GaimGtkConversation *
--gaim_gtk_conv_window_get_active_gtkconv(const GaimGtkWindow *win)
-+Gaim2GtkConversation *
-+gaim2_gtk_conv_window_get_active_gtkconv(const Gaim2GtkWindow *win)
- {
- int index;
- GtkWidget *tab_cont;
-@@ -7352,27 +7352,27 @@ gaim_gtk_conv_window_get_active_gtkconv(
- tab_cont = gtk_notebook_get_nth_page(GTK_NOTEBOOK(win->notebook), index);
- if (!tab_cont)
- return NULL;
-- return g_object_get_data(G_OBJECT(tab_cont), "GaimGtkConversation");
-+ return g_object_get_data(G_OBJECT(tab_cont), "Gaim2GtkConversation");
- }
-
-
--GaimConversation *
--gaim_gtk_conv_window_get_active_conversation(const GaimGtkWindow *win)
-+Gaim2Conversation *
-+gaim2_gtk_conv_window_get_active_conversation(const Gaim2GtkWindow *win)
- {
-- GaimGtkConversation *gtkconv;
-+ Gaim2GtkConversation *gtkconv;
-
-- gtkconv = gaim_gtk_conv_window_get_active_gtkconv(win);
-+ gtkconv = gaim2_gtk_conv_window_get_active_gtkconv(win);
- return gtkconv ? gtkconv->active_conv : NULL;
- }
-
- gboolean
--gaim_gtk_conv_window_is_active_conversation(const GaimConversation *conv)
-+gaim2_gtk_conv_window_is_active_conversation(const Gaim2Conversation *conv)
- {
-- return conv == gaim_gtk_conv_window_get_active_conversation(GAIM_GTK_CONVERSATION(conv)->win);
-+ return conv == gaim2_gtk_conv_window_get_active_conversation(GAIM_GTK_CONVERSATION(conv)->win);
- }
-
- gboolean
--gaim_gtk_conv_window_has_focus(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_has_focus(Gaim2GtkWindow *win)
- {
- gboolean has_focus = FALSE;
-
-@@ -7381,10 +7381,10 @@ gaim_gtk_conv_window_has_focus(GaimGtkWi
- return has_focus;
- }
-
--GaimGtkWindow *
--gaim_gtk_conv_window_get_at_xy(int x, int y)
-+Gaim2GtkWindow *
-+gaim2_gtk_conv_window_get_at_xy(int x, int y)
- {
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
- GdkWindow *gdkwin;
- GList *l;
-
-@@ -7393,7 +7393,7 @@ gaim_gtk_conv_window_get_at_xy(int x, in
- if (gdkwin)
- gdkwin = gdk_window_get_toplevel(gdkwin);
-
-- for (l = gaim_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
-+ for (l = gaim2_gtk_conv_windows_get_list(); l != NULL; l = l->next) {
- win = l->data;
-
- if (gdkwin == win->window->window)
-@@ -7404,28 +7404,28 @@ gaim_gtk_conv_window_get_at_xy(int x, in
- }
-
- GList *
--gaim_gtk_conv_window_get_gtkconvs(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_get_gtkconvs(Gaim2GtkWindow *win)
- {
- return win->gtkconvs;
- }
-
- guint
--gaim_gtk_conv_window_get_gtkconv_count(GaimGtkWindow *win)
-+gaim2_gtk_conv_window_get_gtkconv_count(Gaim2GtkWindow *win)
- {
- return g_list_length(win->gtkconvs);
- }
-
--GaimGtkWindow *
--gaim_gtk_conv_window_first_with_type(GaimConversationType type)
-+Gaim2GtkWindow *
-+gaim2_gtk_conv_window_first_with_type(Gaim2ConversationType type)
- {
- GList *wins, *convs;
-- GaimGtkWindow *win;
-- GaimGtkConversation *conv;
-+ Gaim2GtkWindow *win;
-+ Gaim2GtkConversation *conv;
-
- if (type == GAIM_CONV_TYPE_UNKNOWN)
- return NULL;
-
-- for (wins = gaim_gtk_conv_windows_get_list(); wins != NULL; wins = wins->next) {
-+ for (wins = gaim2_gtk_conv_windows_get_list(); wins != NULL; wins = wins->next) {
- win = wins->data;
-
- for (convs = win->gtkconvs;
-@@ -7434,7 +7434,7 @@ gaim_gtk_conv_window_first_with_type(Gai
-
- conv = convs->data;
-
-- if (gaim_conversation_get_type(conv->active_conv) == type)
-+ if (gaim2_conversation_get_type(conv->active_conv) == type)
- return win;
- }
- }
-@@ -7442,17 +7442,17 @@ gaim_gtk_conv_window_first_with_type(Gai
- return NULL;
- }
-
--GaimGtkWindow *
--gaim_gtk_conv_window_last_with_type(GaimConversationType type)
-+Gaim2GtkWindow *
-+gaim2_gtk_conv_window_last_with_type(Gaim2ConversationType type)
- {
- GList *wins, *convs;
-- GaimGtkWindow *win;
-- GaimGtkConversation *conv;
-+ Gaim2GtkWindow *win;
-+ Gaim2GtkConversation *conv;
-
- if (type == GAIM_CONV_TYPE_UNKNOWN)
- return NULL;
-
-- for (wins = g_list_last(gaim_gtk_conv_windows_get_list());
-+ for (wins = g_list_last(gaim2_gtk_conv_windows_get_list());
- wins != NULL;
- wins = wins->prev) {
-
-@@ -7464,7 +7464,7 @@ gaim_gtk_conv_window_last_with_type(Gaim
-
- conv = convs->data;
-
-- if (gaim_conversation_get_type(conv->active_conv) == type)
-+ if (gaim2_conversation_get_type(conv->active_conv) == type)
- return win;
- }
- }
-@@ -7480,84 +7480,84 @@ typedef struct
- {
- char *id;
- char *name;
-- GaimConvPlacementFunc fnc;
-+ Gaim2ConvPlacementFunc fnc;
-
- } ConvPlacementData;
-
- static GList *conv_placement_fncs = NULL;
--static GaimConvPlacementFunc place_conv = NULL;
-+static Gaim2ConvPlacementFunc place_conv = NULL;
-
- /* This one places conversations in the last made window. */
- static void
--conv_placement_last_created_win(GaimGtkConversation *conv)
-+conv_placement_last_created_win(Gaim2GtkConversation *conv)
- {
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
-
-- GList *l = g_list_last(gaim_gtk_conv_windows_get_list());
-+ GList *l = g_list_last(gaim2_gtk_conv_windows_get_list());
- win = l ? l->data : NULL;;
-
- if (win == NULL) {
-- win = gaim_gtk_conv_window_new();
-+ win = gaim2_gtk_conv_window_new();
-
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-- gaim_gtk_conv_window_show(win);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_show(win);
- } else {
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
- }
- }
-
- /* This one places conversations in the last made window of the same type. */
- static void
--conv_placement_last_created_win_type(GaimGtkConversation *conv)
-+conv_placement_last_created_win_type(Gaim2GtkConversation *conv)
- {
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
-
-- win = gaim_gtk_conv_window_last_with_type(gaim_conversation_get_type(conv->active_conv));
-+ win = gaim2_gtk_conv_window_last_with_type(gaim2_conversation_get_type(conv->active_conv));
-
- if (win == NULL) {
-- win = gaim_gtk_conv_window_new();
-+ win = gaim2_gtk_conv_window_new();
-
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-- gaim_gtk_conv_window_show(win);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_show(win);
- } else
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
- }
-
- /* This one places each conversation in its own window. */
- static void
--conv_placement_new_window(GaimGtkConversation *conv)
-+conv_placement_new_window(Gaim2GtkConversation *conv)
- {
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
-
-- win = gaim_gtk_conv_window_new();
-+ win = gaim2_gtk_conv_window_new();
-
-- gaim_gtk_conv_window_add_gtkconv(win, conv);
-+ gaim2_gtk_conv_window_add_gtkconv(win, conv);
-
-- gaim_gtk_conv_window_show(win);
-+ gaim2_gtk_conv_window_show(win);
- }
-
--static GaimGroup *
--conv_get_group(GaimGtkConversation *conv)
-+static Gaim2Group *
-+conv_get_group(Gaim2GtkConversation *conv)
- {
-- GaimGroup *group = NULL;
-+ Gaim2Group *group = NULL;
-
-- if (gaim_conversation_get_type(conv->active_conv) == GAIM_CONV_TYPE_IM) {
-- GaimBuddy *buddy;
-+ if (gaim2_conversation_get_type(conv->active_conv) == GAIM_CONV_TYPE_IM) {
-+ Gaim2Buddy *buddy;
-
-- buddy = gaim_find_buddy(gaim_conversation_get_account(conv->active_conv),
-- gaim_conversation_get_name(conv->active_conv));
-+ buddy = gaim2_find_buddy(gaim2_conversation_get_account(conv->active_conv),
-+ gaim2_conversation_get_name(conv->active_conv));
-
- if (buddy != NULL)
-- group = gaim_buddy_get_group(buddy);
-+ group = gaim2_buddy_get_group(buddy);
-
-- } else if (gaim_conversation_get_type(conv->active_conv) == GAIM_CONV_TYPE_CHAT) {
-- GaimChat *chat;
-+ } else if (gaim2_conversation_get_type(conv->active_conv) == GAIM_CONV_TYPE_CHAT) {
-+ Gaim2Chat *chat;
-
-- chat = gaim_blist_find_chat(gaim_conversation_get_account(conv->active_conv),
-- gaim_conversation_get_name(conv->active_conv));
-+ chat = gaim2_blist_find_chat(gaim2_conversation_get_account(conv->active_conv),
-+ gaim2_conversation_get_name(conv->active_conv));
-
- if (chat != NULL)
-- group = gaim_chat_get_group(chat);
-+ group = gaim2_chat_get_group(chat);
- }
-
- return group;
-@@ -7569,21 +7569,21 @@ conv_get_group(GaimGtkConversation *conv
- * open windows will get a new window.
- */
- static void
--conv_placement_by_group(GaimGtkConversation *conv)
-+conv_placement_by_group(Gaim2GtkConversation *conv)
- {
-- GaimConversationType type;
-- GaimGroup *group = NULL;
-+ Gaim2ConversationType type;
-+ Gaim2Group *group = NULL;
- GList *wl, *cl;
-
-- type = gaim_conversation_get_type(conv->active_conv);
-+ type = gaim2_conversation_get_type(conv->active_conv);
-
- group = conv_get_group(conv);
-
- /* Go through the list of IMs and find one with this group. */
-- for (wl = gaim_gtk_conv_windows_get_list(); wl != NULL; wl = wl->next) {
-- GaimGtkWindow *win2;
-- GaimGtkConversation *conv2;
-- GaimGroup *group2 = NULL;
-+ for (wl = gaim2_gtk_conv_windows_get_list(); wl != NULL; wl = wl->next) {
-+ Gaim2GtkWindow *win2;
-+ Gaim2GtkConversation *conv2;
-+ Gaim2Group *group2 = NULL;
-
- win2 = wl->data;
-
-@@ -7595,7 +7595,7 @@ conv_placement_by_group(GaimGtkConversat
- group2 = conv_get_group(conv2);
-
- if (group == group2) {
-- gaim_gtk_conv_window_add_gtkconv(win2, conv);
-+ gaim2_gtk_conv_window_add_gtkconv(win2, conv);
-
- return;
- }
-@@ -7608,19 +7608,19 @@ conv_placement_by_group(GaimGtkConversat
-
- /* This groups things by account. Otherwise, the same semantics as above */
- static void
--conv_placement_by_account(GaimGtkConversation *conv)
-+conv_placement_by_account(Gaim2GtkConversation *conv)
- {
-- GaimConversationType type;
-+ Gaim2ConversationType type;
- GList *wins, *convs;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- account = gaim_conversation_get_account(conv->active_conv);
-- type = gaim_conversation_get_type(conv->active_conv);
-+ account = gaim2_conversation_get_account(conv->active_conv);
-+ type = gaim2_conversation_get_type(conv->active_conv);
-
- /* Go through the list of IMs and find one with this group. */
-- for (wins = gaim_gtk_conv_windows_get_list(); wins != NULL; wins = wins->next) {
-- GaimGtkWindow *win2;
-- GaimGtkConversation *conv2;
-+ for (wins = gaim2_gtk_conv_windows_get_list(); wins != NULL; wins = wins->next) {
-+ Gaim2GtkWindow *win2;
-+ Gaim2GtkConversation *conv2;
-
- win2 = wins->data;
-
-@@ -7629,8 +7629,8 @@ conv_placement_by_account(GaimGtkConvers
- convs = convs->next) {
- conv2 = convs->data;
-
-- if (account == gaim_conversation_get_account(conv2->active_conv)) {
-- gaim_gtk_conv_window_add_gtkconv(win2, conv);
-+ if (account == gaim2_conversation_get_account(conv2->active_conv)) {
-+ gaim2_gtk_conv_window_add_gtkconv(win2, conv);
- return;
- }
- }
-@@ -7657,7 +7657,7 @@ get_conv_placement_data(const char *id)
-
- static void
- add_conv_placement_fnc(const char *id, const char *name,
-- GaimConvPlacementFunc fnc)
-+ Gaim2ConvPlacementFunc fnc)
- {
- ConvPlacementData *data;
-
-@@ -7688,7 +7688,7 @@ ensure_default_funcs(void)
- }
-
- GList *
--gaim_gtkconv_placement_get_options(void)
-+gaim2_gtkconv_placement_get_options(void)
- {
- GList *n, *list = NULL;
- ConvPlacementData *data;
-@@ -7706,8 +7706,8 @@ gaim_gtkconv_placement_get_options(void)
-
-
- void
--gaim_gtkconv_placement_add_fnc(const char *id, const char *name,
-- GaimConvPlacementFunc fnc)
-+gaim2_gtkconv_placement_add_fnc(const char *id, const char *name,
-+ Gaim2ConvPlacementFunc fnc)
- {
- g_return_if_fail(id != NULL);
- g_return_if_fail(name != NULL);
-@@ -7719,7 +7719,7 @@ gaim_gtkconv_placement_add_fnc(const cha
- }
-
- void
--gaim_gtkconv_placement_remove_fnc(const char *id)
-+gaim2_gtkconv_placement_remove_fnc(const char *id)
- {
- ConvPlacementData *data = get_conv_placement_data(id);
-
-@@ -7734,7 +7734,7 @@ gaim_gtkconv_placement_remove_fnc(const
- }
-
- const char *
--gaim_gtkconv_placement_get_name(const char *id)
-+gaim2_gtkconv_placement_get_name(const char *id)
- {
- ConvPlacementData *data;
-
-@@ -7748,8 +7748,8 @@ gaim_gtkconv_placement_get_name(const ch
- return data->name;
- }
-
--GaimConvPlacementFunc
--gaim_gtkconv_placement_get_fnc(const char *id)
-+Gaim2ConvPlacementFunc
-+gaim2_gtkconv_placement_get_fnc(const char *id)
- {
- ConvPlacementData *data;
-
-@@ -7764,25 +7764,25 @@ gaim_gtkconv_placement_get_fnc(const cha
- }
-
- void
--gaim_gtkconv_placement_set_current_func(GaimConvPlacementFunc func)
-+gaim2_gtkconv_placement_set_current_func(Gaim2ConvPlacementFunc func)
- {
- g_return_if_fail(func != NULL);
-
- /* If tabs are enabled, set the function, otherwise, NULL it out. */
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/tabs"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/tabs"))
- place_conv = func;
- else
- place_conv = NULL;
- }
-
--GaimConvPlacementFunc
--gaim_gtkconv_placement_get_current_func(void)
-+Gaim2ConvPlacementFunc
-+gaim2_gtkconv_placement_get_current_func(void)
- {
- return place_conv;
- }
-
- void
--gaim_gtkconv_placement_place(GaimGtkConversation *gtkconv)
-+gaim2_gtkconv_placement_place(Gaim2GtkConversation *gtkconv)
- {
- if (place_conv)
- place_conv(gtkconv);
-@@ -7791,7 +7791,7 @@ gaim_gtkconv_placement_place(GaimGtkConv
- }
-
- gboolean
--gaim_gtkconv_is_hidden(GaimGtkConversation *gtkconv)
-+gaim2_gtkconv_is_hidden(Gaim2GtkConversation *gtkconv)
- {
- g_return_val_if_fail(gtkconv != NULL, FALSE);
-
-@@ -7873,7 +7873,7 @@ generate_nick_colors(guint numcolors, Gd
- {
- GdkColor color = { 0, rand() % 65536, rand() % 65536, rand() % 65536 };
-
-- gaim_debug(GAIM_DEBUG_WARNING, NULL,
-+ gaim2_debug(GAIM_DEBUG_WARNING, NULL,
- "Looking for random colors to fill the list, I have found %i so far.\n",i);
-
- if (color_is_visible(color, background, MIN_COLOR_CONTRAST, MIN_BRIGHTNESS_CONTRAST) &&
-diff -prNu ./src/gtkconv.h ./src/gtkconv.h
---- ./src/gtkconv.h 2005-12-12 19:59:29.000000000 +0100
-+++ ./src/gtkconv.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkconv.h GTK+ Conversation API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,9 +25,9 @@
- #ifndef _GAIM_GTKCONVERSATION_H_
- #define _GAIM_GTKCONVERSATION_H_
-
--typedef struct _GaimGtkImPane GaimGtkImPane;
--typedef struct _GaimGtkChatPane GaimGtkChatPane;
--typedef struct _GaimGtkConversation GaimGtkConversation;
-+typedef struct _Gaim2GtkImPane Gaim2GtkImPane;
-+typedef struct _Gaim2GtkChatPane Gaim2GtkChatPane;
-+typedef struct _Gaim2GtkConversation Gaim2GtkConversation;
-
- /**
- * Unseen text states.
-@@ -39,7 +39,7 @@ typedef enum
- GAIM_UNSEEN_NO_LOG, /**< Unseen text with NO_LOG flag. */
- GAIM_UNSEEN_TEXT, /**< Unseen text in the conversation. */
- GAIM_UNSEEN_NICK /**< Unseen text and the nick was said. */
--} GaimUnseenState;
-+} Gaim2UnseenState;
-
- enum {
- CHAT_USERS_ICON_COLUMN,
-@@ -52,13 +52,13 @@ enum {
- };
-
- #define GAIM_GTK_CONVERSATION(conv) \
-- ((GaimGtkConversation *)(conv)->ui_data)
-+ ((Gaim2GtkConversation *)(conv)->ui_data)
-
- #define GAIM_IS_GTK_CONVERSATION(conv) \
-- (gaim_conversation_get_ui_ops(conv) == \
-- gaim_gtk_conversations_get_conv_ui_ops())
-+ (gaim2_conversation_get_ui_ops(conv) == \
-+ gaim2_gtk_conversations_get_conv_ui_ops())
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "conversation.h"
- #include "gtkconvwin.h"
-
-@@ -75,7 +75,7 @@ enum {
- /**
- * A GTK+ Instant Message pane.
- */
--struct _GaimGtkImPane
-+struct _Gaim2GtkImPane
- {
- GtkWidget *block;
- GtkWidget *send_file;
-@@ -97,7 +97,7 @@ struct _GaimGtkImPane
- /**
- * GTK+ Chat panes.
- */
--struct _GaimGtkChatPane
-+struct _Gaim2GtkChatPane
- {
- GtkWidget *count;
- GtkWidget *list;
-@@ -110,12 +110,12 @@ struct _GaimGtkChatPane
- /**
- * A GTK+ conversation pane.
- */
--struct _GaimGtkConversation
-+struct _Gaim2GtkConversation
- {
-- GaimConversation *active_conv;
-+ Gaim2Conversation *active_conv;
- GList *convs;
-
-- GaimGtkWindow *win;
-+ Gaim2GtkWindow *win;
-
- gboolean make_sound;
-
-@@ -140,7 +140,7 @@ struct _GaimGtkConversation
-
- GtkWidget *toolbar;
-
-- GaimUnseenState unseen_state;
-+ Gaim2UnseenState unseen_state;
- guint unseen_count;
-
- struct
-@@ -152,8 +152,8 @@ struct _GaimGtkConversation
-
- union
- {
-- GaimGtkImPane *im;
-- GaimGtkChatPane *chat;
-+ Gaim2GtkImPane *im;
-+ Gaim2GtkChatPane *chat;
-
- } u;
- };
-@@ -170,34 +170,34 @@ struct _GaimGtkConversation
- *
- * @return The GTK+ conversation operations structure.
- */
--GaimConversationUiOps *gaim_gtk_conversations_get_conv_ui_ops(void);
-+Gaim2ConversationUiOps *gaim2_gtk_conversations_get_conv_ui_ops(void);
-
- /**
- * Updates the buddy icon on a conversation.
- *
- * @param conv The conversation.
- */
--void gaim_gtkconv_update_buddy_icon(GaimConversation *conv);
-+void gaim2_gtkconv_update_buddy_icon(Gaim2Conversation *conv);
-
- /**
- * Sets the active conversation within a GTK-conversation.
- *
- * @param conv The conversation
- */
--void gaim_gtkconv_switch_active_conversation(GaimConversation *conv);
-+void gaim2_gtkconv_switch_active_conversation(Gaim2Conversation *conv);
-
- /**
- * Updates the tab positions on all conversation windows to reflect any
- * changed preferences.
- */
--void gaim_gtkconv_update_tabs(void);
-+void gaim2_gtkconv_update_tabs(void);
-
- /**
- * Updates conversation buttons by protocol.
- *
- * @param conv The conversation.
- */
--void gaim_gtkconv_update_buttons_by_protocol(GaimConversation *conv);
-+void gaim2_gtkconv_update_buttons_by_protocol(Gaim2Conversation *conv);
-
- /**
- * Returns a list of conversations of the given type which have an unseen
-@@ -212,11 +212,11 @@ void gaim_gtkconv_update_buttons_by_prot
- * @param hidden_only If TRUE, only consider hidden conversations.
- * @param max_count Maximum number of conversations to return, or 0 for
- * no maximum.
-- * @return List of GaimConversation matching criteria, or NULL.
-+ * @return List of Gaim2Conversation matching criteria, or NULL.
- */
- GList *
--gaim_gtk_conversations_find_unseen_list(GaimConversationType type,
-- GaimUnseenState min_state,
-+gaim2_gtk_conversations_find_unseen_list(Gaim2ConversationType type,
-+ Gaim2UnseenState min_state,
- gboolean hidden_only,
- guint max_count);
-
-@@ -225,24 +225,24 @@ gaim_gtk_conversations_find_unseen_list(
- * menu item will present that conversation to the user.
- *
- * @param menu Menu widget to add items to.
-- * @param convs List of GaimConversation to add to menu.
-+ * @param convs List of Gaim2Conversation to add to menu.
- * @return Number of conversations added to menu.
- */
- guint
--gaim_gtk_conversations_fill_menu(GtkWidget *menu, GList *convs);
-+gaim2_gtk_conversations_fill_menu(GtkWidget *menu, GList *convs);
-
- /**
-- * Presents a gaim conversation to the user.
-+ * Presents a gaim2 conversation to the user.
- *
- * @param conv The conversation.
- */
--void gaim_gtkconv_present_conversation(GaimConversation *conv);
-+void gaim2_gtkconv_present_conversation(Gaim2Conversation *conv);
-
--GaimGtkWindow *gaim_gtkconv_get_window(GaimGtkConversation *gtkconv);
--GdkPixbuf *gaim_gtkconv_get_tab_icon(GaimConversation *conv, gboolean small_icon);
--void gaim_gtkconv_new(GaimConversation *conv);
--int gaim_gtkconv_get_tab_at_xy(GaimGtkWindow *win, int x, int y, gboolean *to_right);
--gboolean gaim_gtkconv_is_hidden(GaimGtkConversation *gtkconv);
-+Gaim2GtkWindow *gaim2_gtkconv_get_window(Gaim2GtkConversation *gtkconv);
-+GdkPixbuf *gaim2_gtkconv_get_tab_icon(Gaim2Conversation *conv, gboolean small_icon);
-+void gaim2_gtkconv_new(Gaim2Conversation *conv);
-+int gaim2_gtkconv_get_tab_at_xy(Gaim2GtkWindow *win, int x, int y, gboolean *to_right);
-+gboolean gaim2_gtkconv_is_hidden(Gaim2GtkConversation *gtkconv);
- /*@}*/
-
- /**************************************************************************/
-@@ -255,17 +255,17 @@ gboolean gaim_gtkconv_is_hidden(GaimGtkC
- *
- * @return The conversations subsystem handle.
- */
--void *gaim_gtk_conversations_get_handle(void);
-+void *gaim2_gtk_conversations_get_handle(void);
-
- /**
- * Initializes the GTK+ conversations subsystem.
- */
--void gaim_gtk_conversations_init(void);
-+void gaim2_gtk_conversations_init(void);
-
- /**
- * Uninitialized the GTK+ conversation subsystem.
- */
--void gaim_gtk_conversations_uninit(void);
-+void gaim2_gtk_conversations_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/gtkconvwin.h ./src/gtkconvwin.h
---- ./src/gtkconvwin.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkconvwin.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkconvwin.h GTK+ Conversation Window API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,7 +25,7 @@
- #ifndef _GAIM_GTKCONVERSATION_WINDOW_H_
- #define _GAIM_GTKCONVERSATION_WINDOW_H_
-
--typedef struct _GaimGtkWindow GaimGtkWindow;
-+typedef struct _Gaim2GtkWindow Gaim2GtkWindow;
-
-
- /**************************************************************************
-@@ -37,7 +37,7 @@ typedef struct _GaimGtkWindow Gaim
- * A GTK+ representation of a graphical window containing one or more
- * conversations.
- */
--struct _GaimGtkWindow
-+struct _Gaim2GtkWindow
- {
- GtkWidget *window; /**< The window. */
- GtkWidget *notebook; /**< The notebook of conversations. */
-@@ -97,26 +97,26 @@ struct _GaimGtkWindow
- **************************************************************************/
- /*@{*/
-
--GaimGtkWindow * gaim_gtk_conv_window_new(void);
--void gaim_gtk_conv_window_destroy(GaimGtkWindow *win);
--GList *gaim_gtk_conv_windows_get_list(void);
--void gaim_gtk_conv_window_show(GaimGtkWindow *win);
--void gaim_gtk_conv_window_hide(GaimGtkWindow *win);
--void gaim_gtk_conv_window_raise(GaimGtkWindow *win);
--void gaim_gtk_conv_window_switch_gtkconv(GaimGtkWindow *win, GaimGtkConversation *gtkconv);
--void gaim_gtk_conv_window_add_gtkconv(GaimGtkWindow *win, GaimGtkConversation *gtkconv);
--void gaim_gtk_conv_window_remove_gtkconv(GaimGtkWindow *win, GaimGtkConversation *gtkconv);
--GaimGtkConversation *gaim_gtk_conv_window_get_gtkconv_at_index(const GaimGtkWindow *win, int index);
--GaimGtkConversation *gaim_gtk_conv_window_get_active_gtkconv(const GaimGtkWindow *win);
--GaimConversation *gaim_gtk_conv_window_get_active_conversation(const GaimGtkWindow *win);
--gboolean gaim_gtk_conv_window_is_active_conversation(const GaimConversation *conv);
--gboolean gaim_gtk_conv_window_has_focus(GaimGtkWindow *win);
--GaimGtkWindow *gaim_gtk_conv_window_get_at_xy(int x, int y);
--GList *gaim_gtk_conv_window_get_gtkconvs(GaimGtkWindow *win);
--guint gaim_gtk_conv_window_get_gtkconv_count(GaimGtkWindow *win);
-+Gaim2GtkWindow * gaim2_gtk_conv_window_new(void);
-+void gaim2_gtk_conv_window_destroy(Gaim2GtkWindow *win);
-+GList *gaim2_gtk_conv_windows_get_list(void);
-+void gaim2_gtk_conv_window_show(Gaim2GtkWindow *win);
-+void gaim2_gtk_conv_window_hide(Gaim2GtkWindow *win);
-+void gaim2_gtk_conv_window_raise(Gaim2GtkWindow *win);
-+void gaim2_gtk_conv_window_switch_gtkconv(Gaim2GtkWindow *win, Gaim2GtkConversation *gtkconv);
-+void gaim2_gtk_conv_window_add_gtkconv(Gaim2GtkWindow *win, Gaim2GtkConversation *gtkconv);
-+void gaim2_gtk_conv_window_remove_gtkconv(Gaim2GtkWindow *win, Gaim2GtkConversation *gtkconv);
-+Gaim2GtkConversation *gaim2_gtk_conv_window_get_gtkconv_at_index(const Gaim2GtkWindow *win, int index);
-+Gaim2GtkConversation *gaim2_gtk_conv_window_get_active_gtkconv(const Gaim2GtkWindow *win);
-+Gaim2Conversation *gaim2_gtk_conv_window_get_active_conversation(const Gaim2GtkWindow *win);
-+gboolean gaim2_gtk_conv_window_is_active_conversation(const Gaim2Conversation *conv);
-+gboolean gaim2_gtk_conv_window_has_focus(Gaim2GtkWindow *win);
-+Gaim2GtkWindow *gaim2_gtk_conv_window_get_at_xy(int x, int y);
-+GList *gaim2_gtk_conv_window_get_gtkconvs(Gaim2GtkWindow *win);
-+guint gaim2_gtk_conv_window_get_gtkconv_count(Gaim2GtkWindow *win);
-
--GaimGtkWindow *gaim_gtk_conv_window_first_with_type(GaimConversationType type);
--GaimGtkWindow *gaim_gtk_conv_window_last_with_type(GaimConversationType type);
-+Gaim2GtkWindow *gaim2_gtk_conv_window_first_with_type(Gaim2ConversationType type);
-+Gaim2GtkWindow *gaim2_gtk_conv_window_last_with_type(Gaim2ConversationType type);
-
- /*@}*/
-
-@@ -125,16 +125,16 @@ GaimGtkWindow *gaim_gtk_conv_window_last
- **************************************************************************/
- /*@{*/
-
--typedef void (*GaimConvPlacementFunc)(GaimGtkConversation *);
-+typedef void (*Gaim2ConvPlacementFunc)(Gaim2GtkConversation *);
-
--GList *gaim_gtkconv_placement_get_options(void);
--void gaim_gtkconv_placement_add_fnc(const char *id, const char *name, GaimConvPlacementFunc fnc);
--void gaim_gtkconv_placement_remove_fnc(const char *id);
--const char *gaim_gtkconv_placement_get_name(const char *id);
--GaimConvPlacementFunc gaim_gtkconv_placement_get_fnc(const char *id);
--void gaim_gtkconv_placement_set_current_func(GaimConvPlacementFunc func);
--GaimConvPlacementFunc gaim_gtkconv_placement_get_current_func(void);
--void gaim_gtkconv_placement_place(GaimGtkConversation *gtkconv);
-+GList *gaim2_gtkconv_placement_get_options(void);
-+void gaim2_gtkconv_placement_add_fnc(const char *id, const char *name, Gaim2ConvPlacementFunc fnc);
-+void gaim2_gtkconv_placement_remove_fnc(const char *id);
-+const char *gaim2_gtkconv_placement_get_name(const char *id);
-+Gaim2ConvPlacementFunc gaim2_gtkconv_placement_get_fnc(const char *id);
-+void gaim2_gtkconv_placement_set_current_func(Gaim2ConvPlacementFunc func);
-+Gaim2ConvPlacementFunc gaim2_gtkconv_placement_get_current_func(void);
-+void gaim2_gtkconv_placement_place(Gaim2GtkConversation *gtkconv);
-
- /*@}*/
-
-diff -prNu ./src/gtkdebug.c ./src/gtkdebug.c
---- ./src/gtkdebug.c 2005-11-27 04:17:05.000000000 +0100
-+++ ./src/gtkdebug.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkdebug.c GTK+ Debug API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "notify.h"
- #include "prefs.h"
-@@ -86,7 +86,7 @@ static void regex_show_all(DebugWindow *
- static gint
- debug_window_destroy(GtkWidget *w, GdkEvent *event, void *unused)
- {
-- gaim_prefs_disconnect_by_handle(gaim_gtk_debug_get_handle());
-+ gaim2_prefs_disconnect_by_handle(gaim2_gtk_debug_get_handle());
-
- #ifdef HAVE_REGEX_H
- if(debug_win->timer != 0) {
-@@ -95,19 +95,19 @@ debug_window_destroy(GtkWidget *w, GdkEv
- g_source_remove(debug_win->timer);
-
- text = gtk_entry_get_text(GTK_ENTRY(debug_win->expression));
-- gaim_prefs_set_string("/gaim/gtk/debug/regex", text);
-+ gaim2_prefs_set_string("/gaim2/gtk/debug/regex", text);
- }
-
- regfree(&debug_win->regex);
- #endif
-
- /* If the "Save Log" dialog is open then close it */
-- gaim_request_close_with_handle(debug_win);
-+ gaim2_request_close_with_handle(debug_win);
-
- g_free(debug_win);
- debug_win = NULL;
-
-- gaim_prefs_set_bool("/gaim/gtk/debug/enabled", FALSE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/debug/enabled", FALSE);
-
- return FALSE;
- }
-@@ -116,8 +116,8 @@ static gboolean
- configure_cb(GtkWidget *w, GdkEventConfigure *event, DebugWindow *win)
- {
- if (GTK_WIDGET_VISIBLE(w)) {
-- gaim_prefs_set_int("/gaim/gtk/debug/width", event->width);
-- gaim_prefs_set_int("/gaim/gtk/debug/height", event->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/debug/width", event->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/debug/height", event->height);
- }
-
- return FALSE;
-@@ -197,7 +197,7 @@ find_cb(GtkWidget *w, DebugWindow *win)
- gtk_entry_set_activates_default(GTK_ENTRY(f->entry), TRUE);
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), GTK_WIDGET(f->entry));
- g_signal_connect(G_OBJECT(f->entry), "changed",
-- G_CALLBACK(gaim_gtk_set_sensitive_if_input),
-+ G_CALLBACK(gaim2_gtk_set_sensitive_if_input),
- win->find);
- gtk_box_pack_start(GTK_BOX(hbox), f->entry, FALSE, FALSE, 0);
-
-@@ -214,12 +214,12 @@ save_writefile_cb(void *user_data, const
- char *tmp;
-
- if ((fp = g_fopen(filename, "w+")) == NULL) {
-- gaim_notify_error(win, NULL, _("Unable to open file."), NULL);
-+ gaim2_notify_error(win, NULL, _("Unable to open file."), NULL);
- return;
- }
-
- tmp = gtk_imhtml_get_text(GTK_IMHTML(win->text), NULL, NULL);
-- fprintf(fp, "Gaim Debug log : %s\n", gaim_date_full());
-+ fprintf(fp, "Gaim2 Debug log : %s\n", gaim2_date_full());
- fprintf(fp, "%s", tmp);
- g_free(tmp);
-
-@@ -229,7 +229,7 @@ save_writefile_cb(void *user_data, const
- static void
- save_cb(GtkWidget *w, DebugWindow *win)
- {
-- gaim_request_file(win, _("Save Debug Log"), "gaim-debug.log", TRUE,
-+ gaim2_request_file(win, _("Save Debug Log"), "gaim2-debug.log", TRUE,
- G_CALLBACK(save_writefile_cb), NULL, win);
- }
-
-@@ -263,11 +263,11 @@ timestamps_cb(GtkWidget *w, DebugWindow
- {
- win->timestamps = gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(w));
-
-- gaim_prefs_set_bool("/core/debug/timestamps", win->timestamps);
-+ gaim2_prefs_set_bool("/core/debug/timestamps", win->timestamps);
- }
-
- static void
--timestamps_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+timestamps_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(data), GPOINTER_TO_INT(value));
-@@ -319,7 +319,7 @@ regex_match(DebugWindow *win, const gcha
- /* I don't like having to do this, but we need it for highlighting. Plus
- * it makes the ^ and $ operators work :)
- */
-- plaintext = gaim_markup_strip_html(text);
-+ plaintext = gaim2_markup_strip_html(text);
-
- /* we do a first pass to see if it matches at all. If it does we append
- * it, and work out the offsets to highlight.
-@@ -457,7 +457,7 @@ regex_compile(DebugWindow *win) {
- }
-
- static void
--regex_pref_filter_cb(const gchar *name, GaimPrefType type,
-+regex_pref_filter_cb(const gchar *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
- DebugWindow *win = (DebugWindow *)data;
-@@ -472,7 +472,7 @@ regex_pref_filter_cb(const gchar *name,
- }
-
- static void
--regex_pref_expression_cb(const gchar *name, GaimPrefType type,
-+regex_pref_expression_cb(const gchar *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
- DebugWindow *win = (DebugWindow *)data;
-@@ -482,7 +482,7 @@ regex_pref_expression_cb(const gchar *na
- }
-
- static void
--regex_pref_invert_cb(const gchar *name, GaimPrefType type,
-+regex_pref_invert_cb(const gchar *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
- DebugWindow *win = (DebugWindow *)data;
-@@ -495,7 +495,7 @@ regex_pref_invert_cb(const gchar *name,
- }
-
- static void
--regex_pref_highlight_cb(const gchar *name, GaimPrefType type,
-+regex_pref_highlight_cb(const gchar *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
- DebugWindow *win = (DebugWindow *)data;
-@@ -541,7 +541,7 @@ regex_timer_cb(DebugWindow *win) {
- const gchar *text;
-
- text = gtk_entry_get_text(GTK_ENTRY(win->expression));
-- gaim_prefs_set_string("/gaim/gtk/debug/regex", text);
-+ gaim2_prefs_set_string("/gaim2/gtk/debug/regex", text);
-
- win->timer = 0;
-
-@@ -556,7 +556,7 @@ regex_changed_cb(GtkWidget *w, DebugWind
- }
-
- if(win->timer == 0)
-- win->timer = gaim_timeout_add(5000, (GSourceFunc)regex_timer_cb, win);
-+ win->timer = gaim2_timeout_add(5000, (GSourceFunc)regex_timer_cb, win);
-
- regex_compile(win);
- }
-@@ -577,18 +577,18 @@ regex_menu_cb(GtkWidget *item, const gch
-
- active = gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM(item));
-
-- gaim_prefs_set_bool(pref, active);
-+ gaim2_prefs_set_bool(pref, active);
- }
-
- static void
- regex_popup_cb(GtkEntry *entry, GtkWidget *menu, DebugWindow *win) {
-- gaim_separator(menu);
-- gaim_new_check_item(menu, _("Invert"),
-+ gaim2_separator(menu);
-+ gaim2_new_check_item(menu, _("Invert"),
- G_CALLBACK(regex_menu_cb),
-- "/gaim/gtk/debug/invert", win->invert);
-- gaim_new_check_item(menu, _("Highlight matches"),
-+ "/gaim2/gtk/debug/invert", win->invert);
-+ gaim2_new_check_item(menu, _("Highlight matches"),
- G_CALLBACK(regex_menu_cb),
-- "/gaim/gtk/debug/highlight", win->highlight);
-+ "/gaim2/gtk/debug/highlight", win->highlight);
- }
-
- static void
-@@ -597,7 +597,7 @@ regex_filter_toggled_cb(GtkToggleButton
-
- active = gtk_toggle_button_get_active(button);
-
-- gaim_prefs_set_bool("/gaim/gtk/debug/filter", active);
-+ gaim2_prefs_set_bool("/gaim2/gtk/debug/filter", active);
-
- if(!GTK_IS_IMHTML(win->text))
- return;
-@@ -624,11 +624,11 @@ debug_window_new(void)
-
- win = g_new0(DebugWindow, 1);
-
-- width = gaim_prefs_get_int("/gaim/gtk/debug/width");
-- height = gaim_prefs_get_int("/gaim/gtk/debug/height");
-+ width = gaim2_prefs_get_int("/gaim2/gtk/debug/width");
-+ height = gaim2_prefs_get_int("/gaim2/gtk/debug/height");
-
- GAIM_DIALOG(win->window);
-- gaim_debug_info("gtkdebug", "Setting dimensions to %d, %d\n",
-+ gaim2_debug_info("gtkdebug", "Setting dimensions to %d, %d\n",
- width, height);
-
- gtk_window_set_default_size(GTK_WINDOW(win->window), width, height);
-@@ -640,7 +640,7 @@ debug_window_new(void)
- g_signal_connect(G_OBJECT(win->window), "configure_event",
- G_CALLBACK(configure_cb), win);
-
-- handle = gaim_gtk_debug_get_handle();
-+ handle = gaim2_gtk_debug_get_handle();
-
- #ifdef HAVE_REGEX_H
- /* the list store for all the messages */
-@@ -660,7 +660,7 @@ debug_window_new(void)
- vbox = gtk_vbox_new(FALSE, 0);
- gtk_container_add(GTK_CONTAINER(win->window), vbox);
-
-- if (gaim_prefs_get_bool("/gaim/gtk/debug/toolbar")) {
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/debug/toolbar")) {
- /* Setup our top button bar thingie. */
- toolbar = gtk_toolbar_new();
- gtk_toolbar_set_tooltips(GTK_TOOLBAR(toolbar), TRUE);
-@@ -708,9 +708,9 @@ debug_window_new(void)
- win);
-
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button),
-- gaim_prefs_get_bool("/core/debug/timestamps"));
-+ gaim2_prefs_get_bool("/core/debug/timestamps"));
-
-- gaim_prefs_connect_callback(handle, "/core/debug/timestamps",
-+ gaim2_prefs_connect_callback(handle, "/core/debug/timestamps",
- timestamps_pref_cb, button);
-
- #ifdef HAVE_REGEX_H
-@@ -726,14 +726,14 @@ debug_window_new(void)
- G_CALLBACK(regex_filter_toggled_cb),
- win);
- /* we purposely disable the toggle button here in case
-- * /gaim/gtk/debug/expression has an empty string. If it does not have
-+ * /gaim2/gtk/debug/expression has an empty string. If it does not have
- * an empty string, the change signal will get called and make the
- * toggle button sensitive.
- */
- gtk_widget_set_sensitive(win->filter, FALSE);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(win->filter),
-- gaim_prefs_get_bool("/gaim/gtk/debug/filter"));
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/debug/filter",
-+ gaim2_prefs_get_bool("/gaim2/gtk/debug/filter"));
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/debug/filter",
- regex_pref_filter_cb, win);
-
- /* regex entry */
-@@ -748,28 +748,28 @@ debug_window_new(void)
- g_signal_connect(G_OBJECT(win->expression), "changed",
- G_CALLBACK(regex_changed_cb), win);
- gtk_entry_set_text(GTK_ENTRY(win->expression),
-- gaim_prefs_get_string("/gaim/gtk/debug/regex"));
-+ gaim2_prefs_get_string("/gaim2/gtk/debug/regex"));
- g_signal_connect(G_OBJECT(win->expression), "populate-popup",
- G_CALLBACK(regex_popup_cb), win);
- g_signal_connect(G_OBJECT(win->expression), "key-release-event",
- G_CALLBACK(regex_key_release_cb), win);
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/debug/regex",
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/debug/regex",
- regex_pref_expression_cb, win);
-
- /* connect the rest of our pref callbacks */
-- win->invert = gaim_prefs_get_bool("/gaim/gtk/debug/invert");
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/debug/invert",
-+ win->invert = gaim2_prefs_get_bool("/gaim2/gtk/debug/invert");
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/debug/invert",
- regex_pref_invert_cb, win);
-
-- win->highlight = gaim_prefs_get_bool("/gaim/gtk/debug/highlight");
-- gaim_prefs_connect_callback(handle, "/gaim/gtk/debug/highlight",
-+ win->highlight = gaim2_prefs_get_bool("/gaim2/gtk/debug/highlight");
-+ gaim2_prefs_connect_callback(handle, "/gaim2/gtk/debug/highlight",
- regex_pref_highlight_cb, win);
-
- #endif /* HAVE_REGEX_H */
- }
-
- /* Add the gtkimhtml */
-- frame = gaim_gtk_create_imhtml(FALSE, &win->text, NULL);
-+ frame = gaim2_gtk_create_imhtml(FALSE, &win->text, NULL);
- gtk_imhtml_set_format_functions(GTK_IMHTML(win->text),
- GTK_IMHTML_ALL ^ GTK_IMHTML_SMILEY ^ GTK_IMHTML_IMAGE);
- gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
-@@ -789,20 +789,20 @@ debug_window_new(void)
- }
-
- static void
--debug_enabled_cb(const char *name, GaimPrefType type, gpointer value,
-+debug_enabled_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- if (value)
-- gaim_gtk_debug_window_show();
-+ gaim2_gtk_debug_window_show();
- else
-- gaim_gtk_debug_window_hide();
-+ gaim2_gtk_debug_window_hide();
- }
-
- static void
--gaim_glib_log_handler(const gchar *domain, GLogLevelFlags flags,
-+gaim2_glib_log_handler(const gchar *domain, GLogLevelFlags flags,
- const gchar *msg, gpointer user_data)
- {
-- GaimDebugLevel level;
-+ Gaim2DebugLevel level;
- char *new_msg = NULL;
- char *new_domain = NULL;
-
-@@ -820,21 +820,21 @@ gaim_glib_log_handler(const gchar *domai
- level = GAIM_DEBUG_MISC;
- else
- {
-- gaim_debug_warning("gtkdebug",
-+ gaim2_debug_warning("gtkdebug",
- "Unknown glib logging level in %d\n", flags);
-
- level = GAIM_DEBUG_MISC; /* This will never happen. */
- }
-
- if (msg != NULL)
-- new_msg = gaim_utf8_try_convert(msg);
-+ new_msg = gaim2_utf8_try_convert(msg);
-
- if (domain != NULL)
-- new_domain = gaim_utf8_try_convert(domain);
-+ new_domain = gaim2_utf8_try_convert(domain);
-
- if (new_msg != NULL)
- {
-- gaim_debug(level, (new_domain != NULL ? new_domain : "g_log"),
-+ gaim2_debug(level, (new_domain != NULL ? new_domain : "g_log"),
- "%s\n", new_msg);
-
- g_free(new_msg);
-@@ -846,13 +846,13 @@ gaim_glib_log_handler(const gchar *domai
-
- #ifdef _WIN32
- static void
--gaim_glib_dummy_print_handler(const gchar *string)
-+gaim2_glib_dummy_print_handler(const gchar *string)
- {
- }
- #endif
-
- void
--gaim_gtk_debug_init(void)
-+gaim2_gtk_debug_init(void)
- {
- /* Debug window preferences. */
- /*
-@@ -862,30 +862,30 @@ gaim_gtk_debug_init(void)
- * configure event, which overrides the width and height! :P
- */
-
-- gaim_prefs_add_none("/gaim/gtk/debug");
-+ gaim2_prefs_add_none("/gaim2/gtk/debug");
-
- /* Controls printing to the debug window */
-- gaim_prefs_add_bool("/gaim/gtk/debug/enabled", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/debug/enabled", FALSE);
-
-- gaim_prefs_add_bool("/gaim/gtk/debug/toolbar", TRUE);
-- gaim_prefs_add_int("/gaim/gtk/debug/width", 450);
-- gaim_prefs_add_int("/gaim/gtk/debug/height", 250);
-+ gaim2_prefs_add_bool("/gaim2/gtk/debug/toolbar", TRUE);
-+ gaim2_prefs_add_int("/gaim2/gtk/debug/width", 450);
-+ gaim2_prefs_add_int("/gaim2/gtk/debug/height", 250);
-
- #ifdef HAVE_REGEX_H
-- gaim_prefs_add_string("/gaim/gtk/debug/regex", "");
-- gaim_prefs_add_bool("/gaim/gtk/debug/filter", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/debug/invert", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/debug/case_insensitive", FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/debug/highlight", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/debug/regex", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/debug/filter", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/debug/invert", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/debug/case_insensitive", FALSE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/debug/highlight", FALSE);
- #endif /* HAVE_REGEX_H */
-
-- gaim_prefs_connect_callback(NULL, "/gaim/gtk/debug/enabled",
-+ gaim2_prefs_connect_callback(NULL, "/gaim2/gtk/debug/enabled",
- debug_enabled_cb, NULL);
-
- #define REGISTER_G_LOG_HANDLER(name) \
- g_log_set_handler((name), G_LOG_LEVEL_MASK | G_LOG_FLAG_FATAL \
- | G_LOG_FLAG_RECURSION, \
-- gaim_glib_log_handler, NULL)
-+ gaim2_glib_log_handler, NULL)
-
- /* Register the glib/gtk log handlers. */
- REGISTER_G_LOG_HANDLER(NULL);
-@@ -898,30 +898,30 @@ gaim_gtk_debug_init(void)
- REGISTER_G_LOG_HANDLER("GThread");
-
- #ifdef _WIN32
-- if (!gaim_debug_is_enabled())
-- g_set_print_handler(gaim_glib_dummy_print_handler);
-+ if (!gaim2_debug_is_enabled())
-+ g_set_print_handler(gaim2_glib_dummy_print_handler);
- #endif
- }
-
- void
--gaim_gtk_debug_uninit(void)
-+gaim2_gtk_debug_uninit(void)
- {
-- gaim_debug_set_ui_ops(NULL);
-+ gaim2_debug_set_ui_ops(NULL);
- }
-
- void
--gaim_gtk_debug_window_show(void)
-+gaim2_gtk_debug_window_show(void)
- {
- if (debug_win == NULL)
- debug_win = debug_window_new();
-
- gtk_widget_show(debug_win->window);
-
-- gaim_prefs_set_bool("/gaim/gtk/debug/enabled", TRUE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/debug/enabled", TRUE);
- }
-
- void
--gaim_gtk_debug_window_hide(void)
-+gaim2_gtk_debug_window_hide(void)
- {
- if (debug_win != NULL) {
- gtk_widget_destroy(debug_win->window);
-@@ -930,7 +930,7 @@ gaim_gtk_debug_window_hide(void)
- }
-
- static void
--gaim_gtk_debug_print(GaimDebugLevel level, const char *category,
-+gaim2_gtk_debug_print(Gaim2DebugLevel level, const char *category,
- const char *format, va_list args)
- {
- #ifdef HAVE_REGEX_H
-@@ -940,13 +940,13 @@ gaim_gtk_debug_print(GaimDebugLevel leve
- gchar *arg_s, *ts_s;
- gchar *esc_s, *cat_s, *tmp, *s;
-
-- if (!gaim_prefs_get_bool("/gaim/gtk/debug/enabled") ||
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/debug/enabled") ||
- (debug_win == NULL))
- {
- return;
- }
-
-- timestamps = gaim_prefs_get_bool("/core/debug/timestamps");
-+ timestamps = gaim2_prefs_get_bool("/core/debug/timestamps");
-
- arg_s = g_strdup_vprintf(format, args);
-
-@@ -980,7 +980,7 @@ gaim_gtk_debug_print(GaimDebugLevel leve
- g_free(cat_s);
- g_free(esc_s);
-
-- tmp = gaim_utf8_try_convert(s);
-+ tmp = gaim2_utf8_try_convert(s);
- g_free(s);
- s = tmp;
-
-@@ -1002,19 +1002,19 @@ gaim_gtk_debug_print(GaimDebugLevel leve
- g_free(s);
- }
-
--static GaimDebugUiOps ops =
-+static Gaim2DebugUiOps ops =
- {
-- gaim_gtk_debug_print,
-+ gaim2_gtk_debug_print,
- };
-
--GaimDebugUiOps *
--gaim_gtk_debug_get_ui_ops(void)
-+Gaim2DebugUiOps *
-+gaim2_gtk_debug_get_ui_ops(void)
- {
- return &ops;
- }
-
- void *
--gaim_gtk_debug_get_handle() {
-+gaim2_gtk_debug_get_handle() {
- static int handle;
-
- return &handle;
-diff -prNu ./src/gtkdebug.h ./src/gtkdebug.h
---- ./src/gtkdebug.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkdebug.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkdebug.h GTK+ Debug API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,35 +30,35 @@
- /**
- * Initializes the GTK+ debug system.
- */
--void gaim_gtk_debug_init(void);
-+void gaim2_gtk_debug_init(void);
-
- /**
- * Uninitialized the GTK+ debug system.
- */
--void gaim_gtk_debug_uninit(void);
-+void gaim2_gtk_debug_uninit(void);
-
- /**
- * Get the handle for the GTK+ debug system.
- *
- * @return the handle to the debug system
- */
--void *gaim_gtk_debug_get_handle(void);
-+void *gaim2_gtk_debug_get_handle(void);
-
- /**
- * Shows the debug window.
- */
--void gaim_gtk_debug_window_show(void);
-+void gaim2_gtk_debug_window_show(void);
-
- /**
- * Hides the debug window.
- */
--void gaim_gtk_debug_window_hide(void);
-+void gaim2_gtk_debug_window_hide(void);
-
- /**
- * Returns the UI operations structure for GTK+ debug output.
- *
- * @return The GTK+ UI debug operations structure.
- */
--GaimDebugUiOps *gaim_gtk_debug_get_ui_ops(void);
-+Gaim2DebugUiOps *gaim2_gtk_debug_get_ui_ops(void);
-
- #endif /* _GAIM_GTKDEBUG_H_ */
-diff -prNu ./src/gtkdialogs.c ./src/gtkdialogs.c
---- ./src/gtkdialogs.c 2005-12-21 22:18:25.000000000 +0100
-+++ ./src/gtkdialogs.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkdialogs.c GTK+ Dialogs
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "debug.h"
- #include "notify.h"
-@@ -91,7 +91,7 @@ static struct developer patch_writers[]
- /* Order: Alphabetical by Last Name */
- static struct developer retired_developers[] = {
- {"Jim Duchek", N_("maintainer"), "jim@linuxpimps.com"},
-- {"Rob Flynn", N_("maintainer"), "gaim@robflynn.com"},
-+ {"Rob Flynn", N_("maintainer"), "gaim2@robflynn.com"},
- {"Adam Fritzler", N_("libfaim maintainer"), NULL},
- {"Syd Logan", N_("hacker and designated driver [lazy bum]"), NULL},
- {"Jim Seymour", N_("Jabber developer"), NULL},
-@@ -186,7 +186,7 @@ static struct translator past_translator
- };
-
- void
--gaim_gtkdialogs_destroy_all()
-+gaim2_gtkdialogs_destroy_all()
- {
- while (dialogwindows) {
- gtk_widget_destroy(dialogwindows->data);
-@@ -201,7 +201,7 @@ static void destroy_about()
- about = NULL;
- }
-
--void gaim_gtkdialogs_about()
-+void gaim2_gtkdialogs_about()
- {
- GtkWidget *hbox;
- GtkWidget *vbox;
-@@ -222,7 +222,7 @@ void gaim_gtkdialogs_about()
-
- GAIM_DIALOG(about);
- gtk_window_set_default_size(GTK_WINDOW(about), 450, -1);
-- gtk_window_set_title(GTK_WINDOW(about), _("About Gaim"));
-+ gtk_window_set_title(GTK_WINDOW(about), _("About Gaim2"));
- gtk_window_set_role(GTK_WINDOW(about), "about");
- gtk_window_set_resizable(GTK_WINDOW(about), TRUE);
- gtk_window_set_default_size(GTK_WINDOW(about), 340, 550); /* Golden ratio in da hizzy */
-@@ -236,17 +236,17 @@ void gaim_gtkdialogs_about()
-
- logo = gtk_image_new_from_stock(GAIM_STOCK_LOGO, gtk_icon_size_from_name(GAIM_ICON_SIZE_LOGO));
- obj = gtk_widget_get_accessible(logo);
-- atk_object_set_description(obj, "Gaim " VERSION);
-+ atk_object_set_description(obj, "Gaim2 " VERSION);
- gtk_box_pack_start(GTK_BOX(vbox), logo, FALSE, FALSE, 0);
-
-- frame = gaim_gtk_create_imhtml(FALSE, &text, NULL);
-+ frame = gaim2_gtk_create_imhtml(FALSE, &text, NULL);
- gtk_imhtml_set_format_functions(GTK_IMHTML(text), GTK_IMHTML_ALL ^ GTK_IMHTML_SMILEY);
- gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
-
- str = g_string_sized_new(4096);
-
- g_string_append(str,
-- _("Gaim is a modular messaging client capable of using "
-+ _("Gaim2 is a modular messaging client capable of using "
- "AIM, MSN, Yahoo!, Jabber, ICQ, IRC, SILC, "
- "Novell GroupWise, Lotus Sametime, Napster, Zephyr, and Gadu-Gadu "
- "all at once. It is written using "
-@@ -256,10 +256,10 @@ void gaim_gtkdialogs_about()
- GAIM_WEBSITE "\">" GAIM_WEBSITE "</A><BR/><BR/>");
- #ifdef _WIN32
- g_string_append_printf(str, _("<FONT SIZE=\"4\">IRC:</FONT> "
-- "#wingaim on irc.freenode.net<BR><BR>"));
-+ "#wingaim2 on irc.freenode.net<BR><BR>"));
- #else
- g_string_append_printf(str, _("<FONT SIZE=\"4\">IRC:</FONT> "
-- "#gaim on irc.freenode.net<BR><BR>"));
-+ "#gaim2 on irc.freenode.net<BR><BR>"));
- #endif
-
- /* Current Developers */
-@@ -377,9 +377,9 @@ void gaim_gtkdialogs_about()
- #endif
-
- #ifdef HAVE_SSL
-- g_string_append(str, " <b>SSL:</b> Gaim was compiled with SSL support.<br/>");
-+ g_string_append(str, " <b>SSL:</b> Gaim2 was compiled with SSL support.<br/>");
- #else
-- g_string_append(str, " <b>SSL:</b> Gaim was <b><i>NOT</i></b> compiled with any SSL support!<br/>");
-+ g_string_append(str, " <b>SSL:</b> Gaim2 was <b><i>NOT</i></b> compiled with any SSL support!<br/>");
- #endif
-
-
-@@ -514,76 +514,76 @@ g_string_append(str, "<br/> <b>Library
- }
-
- static void
--gaim_gtkdialogs_im_cb(gpointer data, GaimRequestFields *fields)
-+gaim2_gtkdialogs_im_cb(gpointer data, Gaim2RequestFields *fields)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *username;
-
-- account = gaim_request_fields_get_account(fields, "account");
-- username = gaim_request_fields_get_string(fields, "screenname");
-+ account = gaim2_request_fields_get_account(fields, "account");
-+ username = gaim2_request_fields_get_string(fields, "screenname");
-
-- gaim_gtkdialogs_im_with_user(account, username);
-+ gaim2_gtkdialogs_im_with_user(account, username);
- }
-
- void
--gaim_gtkdialogs_im(void)
-+gaim2_gtkdialogs_im(void)
- {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("screenname", _("_Name"), NULL, FALSE);
-- gaim_request_field_set_type_hint(field, "screenname");
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_string_new("screenname", _("_Name"), NULL, FALSE);
-+ gaim2_request_field_set_type_hint(field, "screenname");
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_account_new("account", _("_Account"), NULL);
-- gaim_request_field_set_type_hint(field, "account");
-- gaim_request_field_set_visible(field,
-- (gaim_connections_get_all() != NULL &&
-- gaim_connections_get_all()->next != NULL));
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_account_new("account", _("_Account"), NULL);
-+ gaim2_request_field_set_type_hint(field, "account");
-+ gaim2_request_field_set_visible(field,
-+ (gaim2_connections_get_all() != NULL &&
-+ gaim2_connections_get_all()->next != NULL));
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(gaim_get_blist(), _("New Instant Message"),
-+ gaim2_request_fields(gaim2_get_blist(), _("New Instant Message"),
- NULL,
- _("Please enter the screen name or alias of the person "
- "you would like to IM."),
- fields,
-- _("OK"), G_CALLBACK(gaim_gtkdialogs_im_cb),
-+ _("OK"), G_CALLBACK(gaim2_gtkdialogs_im_cb),
- _("Cancel"), NULL,
- NULL);
- }
-
- void
--gaim_gtkdialogs_im_with_user(GaimAccount *account, const char *username)
-+gaim2_gtkdialogs_im_with_user(Gaim2Account *account, const char *username)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(username != NULL);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, username, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, username, account);
-
- if (conv == NULL)
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, username);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, username);
-
-- gaim_gtkconv_present_conversation(conv);
-+ gaim2_gtkconv_present_conversation(conv);
- }
-
- static gboolean
--gaim_gtkdialogs_ee(const char *ee)
-+gaim2_gtkdialogs_ee(const char *ee)
- {
- GtkWidget *window;
- GtkWidget *hbox;
- GtkWidget *label;
- GtkWidget *img;
-- gchar *norm = gaim_strreplace(ee, "rocksmyworld", "");
-+ gchar *norm = gaim2_strreplace(ee, "rocksmyworld", "");
-
- label = gtk_label_new(NULL);
- if (!strcmp(norm, "zilding"))
-@@ -642,75 +642,75 @@ gaim_gtkdialogs_ee(const char *ee)
- }
-
- static void
--gaim_gtkdialogs_info_cb(gpointer data, GaimRequestFields *fields)
-+gaim2_gtkdialogs_info_cb(gpointer data, Gaim2RequestFields *fields)
- {
- char *username;
- gboolean found = FALSE;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- account = gaim_request_fields_get_account(fields, "account");
-+ account = gaim2_request_fields_get_account(fields, "account");
-
-- username = g_strdup(gaim_normalize(account,
-- gaim_request_fields_get_string(fields, "screenname")));
-+ username = g_strdup(gaim2_normalize(account,
-+ gaim2_request_fields_get_string(fields, "screenname")));
-
-- if (username != NULL && gaim_str_has_suffix(username, "rocksmyworld"))
-- found = gaim_gtkdialogs_ee(username);
-+ if (username != NULL && gaim2_str_has_suffix(username, "rocksmyworld"))
-+ found = gaim2_gtkdialogs_ee(username);
-
- if (!found && username != NULL && *username != '\0' && account != NULL)
-- serv_get_info(gaim_account_get_connection(account), username);
-+ serv_get_info(gaim2_account_get_connection(account), username);
-
- g_free(username);
- }
-
- void
--gaim_gtkdialogs_info(void)
-+gaim2_gtkdialogs_info(void)
- {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
--
-- fields = gaim_request_fields_new();
--
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
--
-- field = gaim_request_field_string_new("screenname", _("_Name"), NULL, FALSE);
-- gaim_request_field_set_type_hint(field, "screenname");
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
--
-- field = gaim_request_field_account_new("account", _("_Account"), NULL);
-- gaim_request_field_set_type_hint(field, "account");
-- gaim_request_field_set_visible(field,
-- (gaim_connections_get_all() != NULL &&
-- gaim_connections_get_all()->next != NULL));
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-+
-+ fields = gaim2_request_fields_new();
-+
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-+
-+ field = gaim2_request_field_string_new("screenname", _("_Name"), NULL, FALSE);
-+ gaim2_request_field_set_type_hint(field, "screenname");
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-+
-+ field = gaim2_request_field_account_new("account", _("_Account"), NULL);
-+ gaim2_request_field_set_type_hint(field, "account");
-+ gaim2_request_field_set_visible(field,
-+ (gaim2_connections_get_all() != NULL &&
-+ gaim2_connections_get_all()->next != NULL));
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(gaim_get_blist(), _("Get User Info"),
-+ gaim2_request_fields(gaim2_get_blist(), _("Get User Info"),
- NULL,
- _("Please enter the screen name or alias of the person "
- "whose info you would like to view."),
- fields,
-- _("OK"), G_CALLBACK(gaim_gtkdialogs_info_cb),
-+ _("OK"), G_CALLBACK(gaim2_gtkdialogs_info_cb),
- _("Cancel"), NULL,
- NULL);
- }
-
- static void
--gaim_gtkdialogs_log_cb(gpointer data, GaimRequestFields *fields)
-+gaim2_gtkdialogs_log_cb(gpointer data, Gaim2RequestFields *fields)
- {
- char *username;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- account = gaim_request_fields_get_account(fields, "account");
-+ account = gaim2_request_fields_get_account(fields, "account");
-
-- username = g_strdup(gaim_normalize(account,
-- gaim_request_fields_get_string(fields, "screenname")));
-+ username = g_strdup(gaim2_normalize(account,
-+ gaim2_request_fields_get_string(fields, "screenname")));
-
- if (username != NULL && *username != '\0' && account != NULL)
- {
-- GaimGtkBuddyList *gtkblist = gaim_gtk_blist_get_default_gtk_blist();
-+ Gaim2GtkBuddyList *gtkblist = gaim2_gtk_blist_get_default_gtk_blist();
- GdkCursor *cursor = gdk_cursor_new(GDK_WATCH);
-
- gdk_window_set_cursor(gtkblist->window->window, cursor);
-@@ -718,7 +718,7 @@ gaim_gtkdialogs_log_cb(gpointer data, Ga
- while (gtk_events_pending())
- gtk_main_iteration();
-
-- gaim_gtk_log_show(GAIM_LOG_IM, username, account);
-+ gaim2_gtk_log_show(GAIM_LOG_IM, username, account);
-
- gdk_window_set_cursor(gtkblist->window->window, NULL);
- }
-@@ -730,68 +730,68 @@ gaim_gtkdialogs_log_cb(gpointer data, Ga
- * TODO - This needs to deal with logs of all types, not just IM logs.
- */
- void
--gaim_gtkdialogs_log(void)
-+gaim2_gtkdialogs_log(void)
- {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
--
-- fields = gaim_request_fields_new();
--
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
--
-- field = gaim_request_field_string_new("screenname", _("_Name"), NULL, FALSE);
-- gaim_request_field_set_type_hint(field, "screenname-all");
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
--
-- field = gaim_request_field_account_new("account", _("_Account"), NULL);
-- gaim_request_field_set_type_hint(field, "account");
-- gaim_request_field_account_set_show_all(field, TRUE);
-- gaim_request_field_set_visible(field,
-- (gaim_accounts_get_all() != NULL &&
-- gaim_accounts_get_all()->next != NULL));
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-+
-+ fields = gaim2_request_fields_new();
-+
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-+
-+ field = gaim2_request_field_string_new("screenname", _("_Name"), NULL, FALSE);
-+ gaim2_request_field_set_type_hint(field, "screenname-all");
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-+
-+ field = gaim2_request_field_account_new("account", _("_Account"), NULL);
-+ gaim2_request_field_set_type_hint(field, "account");
-+ gaim2_request_field_account_set_show_all(field, TRUE);
-+ gaim2_request_field_set_visible(field,
-+ (gaim2_accounts_get_all() != NULL &&
-+ gaim2_accounts_get_all()->next != NULL));
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(gaim_get_blist(), _("View User Log"),
-+ gaim2_request_fields(gaim2_get_blist(), _("View User Log"),
- NULL,
- _("Please enter the screen name or alias of the person "
- "whose log you would like to view."),
- fields,
-- _("OK"), G_CALLBACK(gaim_gtkdialogs_log_cb),
-+ _("OK"), G_CALLBACK(gaim2_gtkdialogs_log_cb),
- _("Cancel"), NULL,
- NULL);
- }
-
- static void
--gaim_gtkdialogs_alias_contact_cb(GaimContact *contact, const char *new_alias)
-+gaim2_gtkdialogs_alias_contact_cb(Gaim2Contact *contact, const char *new_alias)
- {
-- gaim_contact_set_alias(contact, new_alias);
-+ gaim2_contact_set_alias(contact, new_alias);
- }
-
- void
--gaim_gtkdialogs_alias_contact(GaimContact *contact)
-+gaim2_gtkdialogs_alias_contact(Gaim2Contact *contact)
- {
- g_return_if_fail(contact != NULL);
-
-- gaim_request_input(NULL, _("Alias Contact"), NULL,
-+ gaim2_request_input(NULL, _("Alias Contact"), NULL,
- _("Enter an alias for this contact."),
- contact->alias, FALSE, FALSE, NULL,
-- _("Alias"), G_CALLBACK(gaim_gtkdialogs_alias_contact_cb),
-+ _("Alias"), G_CALLBACK(gaim2_gtkdialogs_alias_contact_cb),
- _("Cancel"), NULL, contact);
- }
-
- static void
--gaim_gtkdialogs_alias_buddy_cb(GaimBuddy *buddy, const char *new_alias)
-+gaim2_gtkdialogs_alias_buddy_cb(Gaim2Buddy *buddy, const char *new_alias)
- {
-- gaim_blist_alias_buddy(buddy, new_alias);
-+ gaim2_blist_alias_buddy(buddy, new_alias);
- serv_alias_buddy(buddy);
- }
-
- void
--gaim_gtkdialogs_alias_buddy(GaimBuddy *buddy)
-+gaim2_gtkdialogs_alias_buddy(Gaim2Buddy *buddy)
- {
- gchar *secondary;
-
-@@ -799,59 +799,59 @@ gaim_gtkdialogs_alias_buddy(GaimBuddy *b
-
- secondary = g_strdup_printf(_("Enter an alias for %s."), buddy->name);
-
-- gaim_request_input(NULL, _("Alias Buddy"), NULL,
-+ gaim2_request_input(NULL, _("Alias Buddy"), NULL,
- secondary, buddy->alias, FALSE, FALSE, NULL,
-- _("Alias"), G_CALLBACK(gaim_gtkdialogs_alias_buddy_cb),
-+ _("Alias"), G_CALLBACK(gaim2_gtkdialogs_alias_buddy_cb),
- _("Cancel"), NULL, buddy);
-
- g_free(secondary);
- }
-
- static void
--gaim_gtkdialogs_alias_chat_cb(GaimChat *chat, const char *new_alias)
-+gaim2_gtkdialogs_alias_chat_cb(Gaim2Chat *chat, const char *new_alias)
- {
-- gaim_blist_alias_chat(chat, new_alias);
-+ gaim2_blist_alias_chat(chat, new_alias);
- }
-
- void
--gaim_gtkdialogs_alias_chat(GaimChat *chat)
-+gaim2_gtkdialogs_alias_chat(Gaim2Chat *chat)
- {
- g_return_if_fail(chat != NULL);
-
-- gaim_request_input(NULL, _("Alias Chat"), NULL,
-+ gaim2_request_input(NULL, _("Alias Chat"), NULL,
- _("Enter an alias for this chat."),
- chat->alias, FALSE, FALSE, NULL,
-- _("Alias"), G_CALLBACK(gaim_gtkdialogs_alias_chat_cb),
-+ _("Alias"), G_CALLBACK(gaim2_gtkdialogs_alias_chat_cb),
- _("Cancel"), NULL, chat);
- }
-
- static void
--gaim_gtkdialogs_remove_contact_cb(GaimContact *contact)
-+gaim2_gtkdialogs_remove_contact_cb(Gaim2Contact *contact)
- {
-- GaimBlistNode *bnode, *cnode;
-- GaimGroup *group;
-+ Gaim2BlistNode *bnode, *cnode;
-+ Gaim2Group *group;
-
-- cnode = (GaimBlistNode *)contact;
-- group = (GaimGroup*)cnode->parent;
-+ cnode = (Gaim2BlistNode *)contact;
-+ group = (Gaim2Group*)cnode->parent;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *buddy = (GaimBuddy*)bnode;
-- if (gaim_account_is_connected(buddy->account))
-- gaim_account_remove_buddy(buddy->account, buddy, group);
-+ Gaim2Buddy *buddy = (Gaim2Buddy*)bnode;
-+ if (gaim2_account_is_connected(buddy->account))
-+ gaim2_account_remove_buddy(buddy->account, buddy, group);
- }
-- gaim_blist_remove_contact(contact);
-+ gaim2_blist_remove_contact(contact);
- }
-
- void
--gaim_gtkdialogs_remove_contact(GaimContact *contact)
-+gaim2_gtkdialogs_remove_contact(Gaim2Contact *contact)
- {
-- GaimBuddy *buddy = gaim_contact_get_priority_buddy(contact);
-+ Gaim2Buddy *buddy = gaim2_contact_get_priority_buddy(contact);
-
- g_return_if_fail(contact != NULL);
- g_return_if_fail(buddy != NULL);
-
-- if (((GaimBlistNode*)contact)->child == (GaimBlistNode*)buddy &&
-- !((GaimBlistNode*)buddy)->next) {
-- gaim_gtkdialogs_remove_buddy(buddy);
-+ if (((Gaim2BlistNode*)contact)->child == (Gaim2BlistNode*)buddy &&
-+ !((Gaim2BlistNode*)buddy)->next) {
-+ gaim2_gtkdialogs_remove_buddy(buddy);
- } else {
- gchar *text;
- text = g_strdup_printf(
-@@ -864,8 +864,8 @@ gaim_gtkdialogs_remove_contact(GaimConta
- "want to continue?", contact->totalsize - 1),
- buddy->name, contact->totalsize - 1);
-
-- gaim_request_action(contact, NULL, _("Remove Contact"), text, 0, contact, 2,
-- _("_Remove Contact"), G_CALLBACK(gaim_gtkdialogs_remove_contact_cb),
-+ gaim2_request_action(contact, NULL, _("Remove Contact"), text, 0, contact, 2,
-+ _("_Remove Contact"), G_CALLBACK(gaim2_gtkdialogs_remove_contact_cb),
- _("Cancel"), NULL);
-
- g_free(text);
-@@ -873,30 +873,30 @@ gaim_gtkdialogs_remove_contact(GaimConta
- }
-
- static void
--gaim_gtkdialogs_remove_group_cb(GaimGroup *group)
-+gaim2_gtkdialogs_remove_group_cb(Gaim2Group *group)
- {
-- GaimBlistNode *cnode, *bnode;
-+ Gaim2BlistNode *cnode, *bnode;
-
-- cnode = ((GaimBlistNode*)group)->child;
-+ cnode = ((Gaim2BlistNode*)group)->child;
-
- while (cnode) {
- if (GAIM_BLIST_NODE_IS_CONTACT(cnode)) {
- bnode = cnode->child;
- cnode = cnode->next;
- while (bnode) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- if (GAIM_BLIST_NODE_IS_BUDDY(bnode)) {
-- GaimConversation *conv;
-- buddy = (GaimBuddy*)bnode;
-+ Gaim2Conversation *conv;
-+ buddy = (Gaim2Buddy*)bnode;
- bnode = bnode->next;
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- buddy->name,
- buddy->account);
-- if (gaim_account_is_connected(buddy->account)) {
-- gaim_account_remove_buddy(buddy->account, buddy, group);
-- gaim_blist_remove_buddy(buddy);
-+ if (gaim2_account_is_connected(buddy->account)) {
-+ gaim2_account_remove_buddy(buddy->account, buddy, group);
-+ gaim2_blist_remove_buddy(buddy);
- if (conv)
-- gaim_conversation_update(conv,
-+ gaim2_conversation_update(conv,
- GAIM_CONV_UPDATE_REMOVE);
- }
- } else {
-@@ -904,20 +904,20 @@ gaim_gtkdialogs_remove_group_cb(GaimGrou
- }
- }
- } else if (GAIM_BLIST_NODE_IS_CHAT(cnode)) {
-- GaimChat *chat = (GaimChat *)cnode;
-+ Gaim2Chat *chat = (Gaim2Chat *)cnode;
- cnode = cnode->next;
-- if (gaim_account_is_connected(chat->account))
-- gaim_blist_remove_chat(chat);
-+ if (gaim2_account_is_connected(chat->account))
-+ gaim2_blist_remove_chat(chat);
- } else {
- cnode = cnode->next;
- }
- }
-
-- gaim_blist_remove_group(group);
-+ gaim2_blist_remove_group(group);
- }
-
- void
--gaim_gtkdialogs_remove_group(GaimGroup *group)
-+gaim2_gtkdialogs_remove_group(Gaim2Group *group)
- {
- gchar *text;
-
-@@ -926,8 +926,8 @@ gaim_gtkdialogs_remove_group(GaimGroup *
- text = g_strdup_printf(_("You are about to remove the group %s and all its members from your buddy list. Do you want to continue?"),
- group->name);
-
-- gaim_request_action(group, NULL, _("Remove Group"), text, 0, group, 2,
-- _("_Remove Group"), G_CALLBACK(gaim_gtkdialogs_remove_group_cb),
-+ gaim2_request_action(group, NULL, _("Remove Group"), text, 0, group, 2,
-+ _("_Remove Group"), G_CALLBACK(gaim2_gtkdialogs_remove_group_cb),
- _("Cancel"), NULL);
-
- g_free(text);
-@@ -935,31 +935,31 @@ gaim_gtkdialogs_remove_group(GaimGroup *
-
- /* XXX - Some of this should be moved into the core, methinks. */
- static void
--gaim_gtkdialogs_remove_buddy_cb(GaimBuddy *buddy)
-+gaim2_gtkdialogs_remove_buddy_cb(Gaim2Buddy *buddy)
- {
-- GaimGroup *group;
-- GaimConversation *conv;
-+ Gaim2Group *group;
-+ Gaim2Conversation *conv;
- gchar *name;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- group = gaim_buddy_get_group(buddy);
-+ group = gaim2_buddy_get_group(buddy);
- name = g_strdup(buddy->name); /* b->name is a crasher after remove_buddy */
- account = buddy->account;
-
-- gaim_debug_info("blist", "Removing '%s' from buddy list.\n", buddy->name);
-- /* TODO - Should remove from blist first... then call gaim_account_remove_buddy()? */
-- gaim_account_remove_buddy(buddy->account, buddy, group);
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_debug_info("blist", "Removing '%s' from buddy list.\n", buddy->name);
-+ /* TODO - Should remove from blist first... then call gaim2_account_remove_buddy()? */
-+ gaim2_account_remove_buddy(buddy->account, buddy, group);
-+ gaim2_blist_remove_buddy(buddy);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
- if (conv != NULL)
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_REMOVE);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_REMOVE);
-
- g_free(name);
- }
-
- void
--gaim_gtkdialogs_remove_buddy(GaimBuddy *buddy)
-+gaim2_gtkdialogs_remove_buddy(Gaim2Buddy *buddy)
- {
- gchar *text;
-
-@@ -968,50 +968,50 @@ gaim_gtkdialogs_remove_buddy(GaimBuddy *
- text = g_strdup_printf(_("You are about to remove %s from your buddy list. Do you want to continue?"),
- buddy->name);
-
-- gaim_request_action(buddy, NULL, _("Remove Buddy"), text, 0, buddy, 2,
-- _("_Remove Buddy"), G_CALLBACK(gaim_gtkdialogs_remove_buddy_cb),
-+ gaim2_request_action(buddy, NULL, _("Remove Buddy"), text, 0, buddy, 2,
-+ _("_Remove Buddy"), G_CALLBACK(gaim2_gtkdialogs_remove_buddy_cb),
- _("Cancel"), NULL);
-
- g_free(text);
- }
-
- static void
--gaim_gtkdialogs_remove_chat_cb(GaimChat *chat)
-+gaim2_gtkdialogs_remove_chat_cb(Gaim2Chat *chat)
- {
- char *name = NULL;
-- GaimAccount *account;
-- GaimConversation *conv = NULL;
-+ Gaim2Account *account;
-+ Gaim2Conversation *conv = NULL;
-
- account = chat->account;
-
- if (GAIM_PLUGIN_PROTOCOL_INFO(account->gc->prpl)->get_chat_name != NULL)
- name = GAIM_PLUGIN_PROTOCOL_INFO(account->gc->prpl)->get_chat_name(chat->components);
-
-- gaim_blist_remove_chat(chat);
-+ gaim2_blist_remove_chat(chat);
-
- if (name != NULL) {
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, name, account);
- g_free(name);
- }
-
- if (conv != NULL)
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_REMOVE);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_REMOVE);
- }
-
- void
--gaim_gtkdialogs_remove_chat(GaimChat *chat)
-+gaim2_gtkdialogs_remove_chat(Gaim2Chat *chat)
- {
- const gchar *name;
- gchar *text;
-
- g_return_if_fail(chat != NULL);
-
-- name = gaim_chat_get_name(chat);
-+ name = gaim2_chat_get_name(chat);
- text = g_strdup_printf(_("You are about to remove the chat %s from your buddy list. Do you want to continue?"),
- name ? name : "");
-
-- gaim_request_action(chat, NULL, _("Remove Chat"), text, 0, chat, 2,
-- _("_Remove Chat"), G_CALLBACK(gaim_gtkdialogs_remove_chat_cb),
-+ gaim2_request_action(chat, NULL, _("Remove Chat"), text, 0, chat, 2,
-+ _("_Remove Chat"), G_CALLBACK(gaim2_gtkdialogs_remove_chat_cb),
- _("Cancel"), NULL);
-
- g_free(text);
-diff -prNu ./src/gtkdialogs.h ./src/gtkdialogs.h
---- ./src/gtkdialogs.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkdialogs.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @defgroup gtkui GTK+ User Interface
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,26 +24,26 @@
- #ifndef _GAIM_GTKDIALOGS_H_
- #define _GAIM_GTKDIALOGS_H_
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "conversation.h"
-
- /* Functions in gtkdialogs.c (these should actually stay in this file) */
--void gaim_gtkdialogs_destroy_all(void);
--void gaim_gtkdialogs_about(void);
--void gaim_gtkdialogs_im(void);
--void gaim_gtkdialogs_im_with_user(GaimAccount *, const char *);
--void gaim_gtkdialogs_info(void);
--void gaim_gtkdialogs_log(void);
--void gaim_gtkdialogs_alias_contact(GaimContact *);
--void gaim_gtkdialogs_alias_buddy(GaimBuddy *);
--void gaim_gtkdialogs_alias_chat(GaimChat *);
--
--void gaim_gtkdialogs_remove_buddy(GaimBuddy *);
--void gaim_gtkdialogs_remove_group(GaimGroup *);
--void gaim_gtkdialogs_remove_chat(GaimChat *);
--void gaim_gtkdialogs_remove_contact(GaimContact *);
-+void gaim2_gtkdialogs_destroy_all(void);
-+void gaim2_gtkdialogs_about(void);
-+void gaim2_gtkdialogs_im(void);
-+void gaim2_gtkdialogs_im_with_user(Gaim2Account *, const char *);
-+void gaim2_gtkdialogs_info(void);
-+void gaim2_gtkdialogs_log(void);
-+void gaim2_gtkdialogs_alias_contact(Gaim2Contact *);
-+void gaim2_gtkdialogs_alias_buddy(Gaim2Buddy *);
-+void gaim2_gtkdialogs_alias_chat(Gaim2Chat *);
-+
-+void gaim2_gtkdialogs_remove_buddy(Gaim2Buddy *);
-+void gaim2_gtkdialogs_remove_group(Gaim2Group *);
-+void gaim2_gtkdialogs_remove_chat(Gaim2Chat *);
-+void gaim2_gtkdialogs_remove_contact(Gaim2Contact *);
-
- /* Everything after this should probably be moved elsewhere */
-
-diff -prNu ./src/gtkdnd-hints.c ./src/gtkdnd-hints.c
---- ./src/gtkdnd-hints.c 2005-04-25 06:22:11.000000000 +0200
-+++ ./src/gtkdnd-hints.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkdnd-hints.c GTK+ Drag-and-Drop arrow hints
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -122,7 +122,7 @@ dnd_hints_init(void)
- for (i = 0; hint_windows[i].filename != NULL; i++) {
- gchar *fname;
-
-- fname = g_build_filename(DATADIR, "pixmaps", "gaim",
-+ fname = g_build_filename(DATADIR, "pixmaps", "gaim2",
- hint_windows[i].filename, NULL);
-
- hint_windows[i].widget = dnd_hints_init_window(fname);
-diff -prNu ./src/gtkdnd-hints.h ./src/gtkdnd-hints.h
---- ./src/gtkdnd-hints.h 2004-12-02 21:35:32.000000000 +0100
-+++ ./src/gtkdnd-hints.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,7 +2,7 @@
- * @file gtkdnd-hints.h GTK+ Drag-and-Drop arrow hints
- * @ingroup gtkui
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/gtkeventloop.c ./src/gtkeventloop.c
---- ./src/gtkeventloop.c 2005-07-07 17:40:35.000000000 +0200
-+++ ./src/gtkeventloop.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file gtk_eventloop.c Gaim Event Loop API (gtk implementation)
-+ * @file gtk_eventloop.c Gaim2 Event Loop API (gtk implementation)
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,38 +30,38 @@
- #define GAIM_GTK_READ_COND (G_IO_IN | G_IO_HUP | G_IO_ERR)
- #define GAIM_GTK_WRITE_COND (G_IO_OUT | G_IO_HUP | G_IO_ERR | G_IO_NVAL)
-
--typedef struct _GaimGtkIOClosure {
-- GaimInputFunction function;
-+typedef struct _Gaim2GtkIOClosure {
-+ Gaim2InputFunction function;
- guint result;
- gpointer data;
-
--} GaimGtkIOClosure;
-+} Gaim2GtkIOClosure;
-
--static void gaim_gtk_io_destroy(gpointer data)
-+static void gaim2_gtk_io_destroy(gpointer data)
- {
- g_free(data);
- }
-
--static gboolean gaim_gtk_io_invoke(GIOChannel *source, GIOCondition condition, gpointer data)
-+static gboolean gaim2_gtk_io_invoke(GIOChannel *source, GIOCondition condition, gpointer data)
- {
-- GaimGtkIOClosure *closure = data;
-- GaimInputCondition gaim_cond = 0;
-+ Gaim2GtkIOClosure *closure = data;
-+ Gaim2InputCondition gaim2_cond = 0;
-
- if (condition & GAIM_GTK_READ_COND)
-- gaim_cond |= GAIM_INPUT_READ;
-+ gaim2_cond |= GAIM_INPUT_READ;
- if (condition & GAIM_GTK_WRITE_COND)
-- gaim_cond |= GAIM_INPUT_WRITE;
-+ gaim2_cond |= GAIM_INPUT_WRITE;
-
- #if 0
-- gaim_debug(GAIM_DEBUG_MISC, "gtk_eventloop",
-+ gaim2_debug(GAIM_DEBUG_MISC, "gtk_eventloop",
- "CLOSURE: callback for %d, fd is %d\n",
- closure->result, g_io_channel_unix_get_fd(source));
- #endif
-
- #ifdef _WIN32
-- if(! gaim_cond) {
-+ if(! gaim2_cond) {
- #if DEBUG
-- gaim_debug(GAIM_DEBUG_MISC, "gtk_eventloop",
-+ gaim2_debug(GAIM_DEBUG_MISC, "gtk_eventloop",
- "CLOSURE received GIOCondition of 0x%x, which does not"
- " match 0x%x (READ) or 0x%x (WRITE)\n",
- condition, GAIM_GTK_READ_COND, GAIM_GTK_WRITE_COND);
-@@ -72,15 +72,15 @@ static gboolean gaim_gtk_io_invoke(GIOCh
- #endif /* _WIN32 */
-
- closure->function(closure->data, g_io_channel_unix_get_fd(source),
-- gaim_cond);
-+ gaim2_cond);
-
- return TRUE;
- }
-
--static guint gaim_gtk_input_add(gint fd, GaimInputCondition condition, GaimInputFunction function,
-+static guint gaim2_gtk_input_add(gint fd, Gaim2InputCondition condition, Gaim2InputFunction function,
- gpointer data)
- {
-- GaimGtkIOClosure *closure = g_new0(GaimGtkIOClosure, 1);
-+ Gaim2GtkIOClosure *closure = g_new0(Gaim2GtkIOClosure, 1);
- GIOChannel *channel;
- GIOCondition cond = 0;
-
-@@ -94,10 +94,10 @@ static guint gaim_gtk_input_add(gint fd,
-
- channel = g_io_channel_unix_new(fd);
- closure->result = g_io_add_watch_full(channel, G_PRIORITY_DEFAULT, cond,
-- gaim_gtk_io_invoke, closure, gaim_gtk_io_destroy);
-+ gaim2_gtk_io_invoke, closure, gaim2_gtk_io_destroy);
-
- #if 0
-- gaim_debug(GAIM_DEBUG_MISC, "gtk_eventloop",
-+ gaim2_debug(GAIM_DEBUG_MISC, "gtk_eventloop",
- "CLOSURE: adding input watcher %d for fd %d\n",
- closure->result, fd);
- #endif
-@@ -106,16 +106,16 @@ static guint gaim_gtk_input_add(gint fd,
- return closure->result;
- }
-
--static GaimEventLoopUiOps eventloop_ops =
-+static Gaim2EventLoopUiOps eventloop_ops =
- {
- g_timeout_add,
- (guint (*)(guint))g_source_remove,
-- gaim_gtk_input_add,
-+ gaim2_gtk_input_add,
- (guint (*)(guint))g_source_remove
- };
-
--GaimEventLoopUiOps *
--gaim_gtk_eventloop_get_ui_ops(void)
-+Gaim2EventLoopUiOps *
-+gaim2_gtk_eventloop_get_ui_ops(void)
- {
- return &eventloop_ops;
- }
-diff -prNu ./src/gtkeventloop.h ./src/gtkeventloop.h
---- ./src/gtkeventloop.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gtkeventloop.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
-- * @file gtkeventloop.h Gaim GTK+ Event Loop Implementation
-+ * @file gtkeventloop.h Gaim2 GTK+ Event Loop Implementation
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,6 +32,6 @@
- *
- * @return The GTK+ event loop UI operations structure.
- */
--GaimEventLoopUiOps *gaim_gtk_eventloop_get_ui_ops(void);
-+Gaim2EventLoopUiOps *gaim2_gtk_eventloop_get_ui_ops(void);
-
- #endif /* _GAIM_GTKEVENTLOOP_H_ */
-diff -prNu ./src/gtkft.c ./src/gtkft.c
---- ./src/gtkft.c 2005-12-21 19:36:11.000000000 +0100
-+++ ./src/gtkft.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkft.c GTK+ File Transfer UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "debug.h"
- #include "notify.h"
-@@ -39,16 +39,16 @@
- #include "gtkutils.h"
-
- #define GAIM_GTKXFER(xfer) \
-- (GaimGtkXferUiData *)(xfer)->ui_data
-+ (Gaim2GtkXferUiData *)(xfer)->ui_data
-
--struct _GaimGtkXferDialog
-+struct _Gaim2GtkXferDialog
- {
- gboolean keep_open;
- gboolean auto_clear;
-
- gint num_transfers;
-
-- GaimXfer *selected_xfer;
-+ Gaim2Xfer *selected_xfer;
-
- GtkWidget *window;
- GtkWidget *tree;
-@@ -91,9 +91,9 @@ typedef struct
-
- char *name;
-
--} GaimGtkXferUiData;
-+} Gaim2GtkXferUiData;
-
--static GaimGtkXferDialog *xfer_dialog = NULL;
-+static Gaim2GtkXferDialog *xfer_dialog = NULL;
-
- enum
- {
-@@ -111,10 +111,10 @@ enum
- * Utility Functions
- **************************************************************************/
- static void
--get_xfer_info_strings(GaimXfer *xfer, char **kbsec, char **time_elapsed,
-+get_xfer_info_strings(Gaim2Xfer *xfer, char **kbsec, char **time_elapsed,
- char **time_remaining)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
- double kb_sent, kb_rem;
- double kbps = 0.0;
- time_t elapsed, now;
-@@ -122,7 +122,7 @@ get_xfer_info_strings(GaimXfer *xfer, ch
- data = GAIM_GTKXFER(xfer);
-
- if (data->end_time == -1 &&
-- (gaim_xfer_is_canceled(xfer) || gaim_xfer_is_completed(xfer)))
-+ (gaim2_xfer_is_canceled(xfer) || gaim2_xfer_is_completed(xfer)))
- data->end_time = time(NULL);
-
- if (data->end_time != -1)
-@@ -130,8 +130,8 @@ get_xfer_info_strings(GaimXfer *xfer, ch
- else
- now = time(NULL);
-
-- kb_sent = gaim_xfer_get_bytes_sent(xfer) / 1024.0;
-- kb_rem = gaim_xfer_get_bytes_remaining(xfer) / 1024.0;
-+ kb_sent = gaim2_xfer_get_bytes_sent(xfer) / 1024.0;
-+ kb_rem = gaim2_xfer_get_bytes_remaining(xfer) / 1024.0;
- elapsed = (now - data->start_time);
- kbps = (elapsed > 0 ? (kb_sent / elapsed) : 0);
-
-@@ -153,13 +153,13 @@ get_xfer_info_strings(GaimXfer *xfer, ch
- }
-
- if (time_remaining != NULL) {
-- if (gaim_xfer_get_size(xfer) == 0) {
-+ if (gaim2_xfer_get_size(xfer) == 0) {
- *time_remaining = g_strdup(_("Unknown"));
- }
-- else if (gaim_xfer_is_completed(xfer)) {
-+ else if (gaim2_xfer_is_completed(xfer)) {
- *time_remaining = g_strdup(_("Finished"));
- }
-- else if (gaim_xfer_is_canceled(xfer)) {
-+ else if (gaim2_xfer_is_canceled(xfer)) {
- *time_remaining = g_strdup(_("Canceled"));
- }
- else if (kb_sent <= 0) {
-@@ -181,9 +181,9 @@ get_xfer_info_strings(GaimXfer *xfer, ch
- }
-
- static void
--update_detailed_info(GaimGtkXferDialog *dialog, GaimXfer *xfer)
-+update_detailed_info(Gaim2GtkXferDialog *dialog, Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
- char *kbsec, *time_elapsed, *time_remaining;
- char *status, *utf8;
-
-@@ -195,11 +195,11 @@ update_detailed_info(GaimGtkXferDialog *
- get_xfer_info_strings(xfer, &kbsec, &time_elapsed, &time_remaining);
-
- status = g_strdup_printf("%ld%% (%ld of %ld bytes)",
-- (unsigned long)(gaim_xfer_get_progress(xfer)*100),
-- (unsigned long)gaim_xfer_get_bytes_sent(xfer),
-- (unsigned long)gaim_xfer_get_size(xfer));
-+ (unsigned long)(gaim2_xfer_get_progress(xfer)*100),
-+ (unsigned long)gaim2_xfer_get_bytes_sent(xfer),
-+ (unsigned long)gaim2_xfer_get_size(xfer));
-
-- if (gaim_xfer_is_completed(xfer)) {
-+ if (gaim2_xfer_is_completed(xfer)) {
-
- GdkPixbuf *pixbuf = NULL;
-
-@@ -214,7 +214,7 @@ update_detailed_info(GaimGtkXferDialog *
- g_object_unref(pixbuf);
- }
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
- gtk_label_set_markup(GTK_LABEL(dialog->local_user_desc_label),
- _("<b>Receiving As:</b>"));
- gtk_label_set_markup(GTK_LABEL(dialog->remote_user_desc_label),
-@@ -228,18 +228,18 @@ update_detailed_info(GaimGtkXferDialog *
- }
-
- gtk_label_set_text(GTK_LABEL(dialog->local_user_label),
-- gaim_account_get_username(xfer->account));
-+ gaim2_account_get_username(xfer->account));
- gtk_label_set_text(GTK_LABEL(dialog->remote_user_label), xfer->who);
- gtk_label_set_text(GTK_LABEL(dialog->protocol_label),
-- gaim_account_get_protocol_name(xfer->account));
-+ gaim2_account_get_protocol_name(xfer->account));
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
- gtk_label_set_text(GTK_LABEL(dialog->filename_label),
-- gaim_xfer_get_filename(xfer));
-+ gaim2_xfer_get_filename(xfer));
- } else {
- char *tmp;
-
-- tmp = g_path_get_basename(gaim_xfer_get_local_filename(xfer));
-+ tmp = g_path_get_basename(gaim2_xfer_get_local_filename(xfer));
- utf8 = g_filename_to_utf8(tmp, -1, NULL, NULL, NULL);
- g_free(tmp);
-
-@@ -247,7 +247,7 @@ update_detailed_info(GaimGtkXferDialog *
- g_free(utf8);
- }
-
-- utf8 = g_filename_to_utf8((gaim_xfer_get_local_filename(xfer)), -1, NULL, NULL, NULL);
-+ utf8 = g_filename_to_utf8((gaim2_xfer_get_local_filename(xfer)), -1, NULL, NULL, NULL);
- gtk_label_set_text(GTK_LABEL(dialog->localfile_label), utf8);
- g_free(utf8);
-
-@@ -259,7 +259,7 @@ update_detailed_info(GaimGtkXferDialog *
- time_remaining);
-
- gtk_progress_bar_set_fraction(GTK_PROGRESS_BAR(dialog->progress),
-- gaim_xfer_get_progress(xfer));
-+ gaim2_xfer_get_progress(xfer));
-
- g_free(kbsec);
- g_free(time_elapsed);
-@@ -268,7 +268,7 @@ update_detailed_info(GaimGtkXferDialog *
- }
-
- static void
--update_buttons(GaimGtkXferDialog *dialog, GaimXfer *xfer)
-+update_buttons(Gaim2GtkXferDialog *dialog, Gaim2Xfer *xfer)
- {
- if (dialog->selected_xfer == NULL) {
- gtk_widget_set_sensitive(dialog->expander, FALSE);
-@@ -286,19 +286,19 @@ update_buttons(GaimGtkXferDialog *dialog
- if (dialog->selected_xfer != xfer)
- return;
-
-- if (gaim_xfer_is_completed(xfer)) {
-+ if (gaim2_xfer_is_completed(xfer)) {
- gtk_widget_hide(dialog->stop_button);
- gtk_widget_show(dialog->remove_button);
-
- #ifdef _WIN32
- /* If using Win32... */
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
- gtk_widget_set_sensitive(dialog->open_button, TRUE);
- } else {
- gtk_widget_set_sensitive(dialog->open_button, FALSE);
- }
- #else
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
- gtk_widget_set_sensitive(dialog->open_button, TRUE);
- } else {
- gtk_widget_set_sensitive (dialog->open_button, FALSE);
-@@ -308,7 +308,7 @@ update_buttons(GaimGtkXferDialog *dialog
- gtk_widget_set_sensitive(dialog->resume_button, FALSE);
-
- gtk_widget_set_sensitive(dialog->remove_button, TRUE);
-- } else if (gaim_xfer_is_canceled(xfer)) {
-+ } else if (gaim2_xfer_is_canceled(xfer)) {
- gtk_widget_hide(dialog->stop_button);
- gtk_widget_show(dialog->remove_button);
-
-@@ -331,7 +331,7 @@ update_buttons(GaimGtkXferDialog *dialog
- }
-
- static void
--ensure_row_selected(GaimGtkXferDialog *dialog)
-+ensure_row_selected(Gaim2GtkXferDialog *dialog)
- {
- GtkTreeIter iter;
- GtkTreeSelection *selection;
-@@ -351,36 +351,36 @@ ensure_row_selected(GaimGtkXferDialog *d
- static gint
- delete_win_cb(GtkWidget *w, GdkEventAny *e, gpointer d)
- {
-- GaimGtkXferDialog *dialog;
-+ Gaim2GtkXferDialog *dialog;
-
-- dialog = (GaimGtkXferDialog *)d;
-+ dialog = (Gaim2GtkXferDialog *)d;
-
-- gaim_gtkxfer_dialog_hide(dialog);
-+ gaim2_gtkxfer_dialog_hide(dialog);
-
- return TRUE;
- }
-
- static void
--toggle_keep_open_cb(GtkWidget *w, GaimGtkXferDialog *dialog)
-+toggle_keep_open_cb(GtkWidget *w, Gaim2GtkXferDialog *dialog)
- {
- dialog->keep_open = !dialog->keep_open;
-- gaim_prefs_set_bool("/gaim/gtk/filetransfer/keep_open",
-+ gaim2_prefs_set_bool("/gaim2/gtk/filetransfer/keep_open",
- dialog->keep_open);
- }
-
- static void
--toggle_clear_finished_cb(GtkWidget *w, GaimGtkXferDialog *dialog)
-+toggle_clear_finished_cb(GtkWidget *w, Gaim2GtkXferDialog *dialog)
- {
- dialog->auto_clear = !dialog->auto_clear;
-- gaim_prefs_set_bool("/gaim/gtk/filetransfer/clear_finished",
-+ gaim2_prefs_set_bool("/gaim2/gtk/filetransfer/clear_finished",
- dialog->auto_clear);
- }
-
- static void
--selection_changed_cb(GtkTreeSelection *selection, GaimGtkXferDialog *dialog)
-+selection_changed_cb(GtkTreeSelection *selection, Gaim2GtkXferDialog *dialog)
- {
- GtkTreeIter iter;
-- GaimXfer *xfer = NULL;
-+ Gaim2Xfer *xfer = NULL;
-
- if (gtk_tree_selection_get_selected(selection, NULL, &iter)) {
- GValue val;
-@@ -410,14 +410,14 @@ selection_changed_cb(GtkTreeSelection *s
- }
-
- static void
--open_button_cb(GtkButton *button, GaimGtkXferDialog *dialog)
-+open_button_cb(GtkButton *button, Gaim2GtkXferDialog *dialog)
- {
- #ifdef _WIN32
- /* If using Win32... */
- int code;
- if (G_WIN32_HAVE_WIDECHAR_API ()) {
- wchar_t *wc_filename = g_utf8_to_utf16(
-- gaim_xfer_get_local_filename(
-+ gaim2_xfer_get_local_filename(
- dialog->selected_xfer),
- -1, NULL, NULL, NULL);
-
-@@ -427,7 +427,7 @@ open_button_cb(GtkButton *button, GaimGt
- g_free(wc_filename);
- } else {
- char *l_filename = g_locale_from_utf8(
-- gaim_xfer_get_local_filename(
-+ gaim2_xfer_get_local_filename(
- dialog->selected_xfer),
- -1, NULL, NULL, NULL);
-
-@@ -439,33 +439,33 @@ open_button_cb(GtkButton *button, GaimGt
-
- if (code == SE_ERR_ASSOCINCOMPLETE || code == SE_ERR_NOASSOC)
- {
-- gaim_notify_error(dialog, NULL,
-+ gaim2_notify_error(dialog, NULL,
- _("There is no application configured to open this type of file."), NULL);
- }
- else if (code < 32)
- {
-- gaim_notify_error(dialog, NULL,
-+ gaim2_notify_error(dialog, NULL,
- _("An error occurred while opening the file."), NULL);
-- gaim_debug_warning("ft", "filename: %s; code: %d\n",
-- gaim_xfer_get_local_filename(dialog->selected_xfer), code);
-+ gaim2_debug_warning("ft", "filename: %s; code: %d\n",
-+ gaim2_xfer_get_local_filename(dialog->selected_xfer), code);
- }
- #else
-- const char *filename = gaim_xfer_get_local_filename(dialog->selected_xfer);
-+ const char *filename = gaim2_xfer_get_local_filename(dialog->selected_xfer);
- char *command = NULL;
- char *tmp = NULL;
- GError *error = NULL;
-
-- if (gaim_running_gnome())
-+ if (gaim2_running_gnome())
- {
- char *escaped = g_shell_quote(filename);
- command = g_strdup_printf("gnome-open %s", escaped);
- g_free(escaped);
- }
-- else if (gaim_running_kde())
-+ else if (gaim2_running_kde())
- {
- char *escaped = g_shell_quote(filename);
-
-- if (gaim_str_has_suffix(filename, ".desktop"))
-+ if (gaim2_str_has_suffix(filename, ".desktop"))
- command = g_strdup_printf("kfmclient openURL %s 'text/plain'", escaped);
- else
- command = g_strdup_printf("kfmclient openURL %s", escaped);
-@@ -473,19 +473,19 @@ open_button_cb(GtkButton *button, GaimGt
- }
- else
- {
-- gaim_notify_uri(NULL, filename);
-+ gaim2_notify_uri(NULL, filename);
- return;
- }
-
-- if (gaim_program_is_valid(command))
-+ if (gaim2_program_is_valid(command))
- {
- gint exit_status;
- if (!g_spawn_command_line_sync(command, NULL, NULL, &exit_status, &error))
- {
- tmp = g_strdup_printf(_("Error launching %s: %s"),
-- gaim_xfer_get_local_filename(dialog->selected_xfer),
-+ gaim2_xfer_get_local_filename(dialog->selected_xfer),
- error->message);
-- gaim_notify_error(dialog, NULL, _("Unable to open file."), tmp);
-+ gaim2_notify_error(dialog, NULL, _("Unable to open file."), tmp);
- g_free(tmp);
- g_error_free(error);
- }
-@@ -494,7 +494,7 @@ open_button_cb(GtkButton *button, GaimGt
- char *primary = g_strdup_printf(_("Error running %s"), command);
- char *secondary = g_strdup_printf(_("Process returned error code %d"),
- exit_status);
-- gaim_notify_error(dialog, NULL, primary, secondary);
-+ gaim2_notify_error(dialog, NULL, primary, secondary);
- g_free(tmp);
- }
- }
-@@ -502,38 +502,38 @@ open_button_cb(GtkButton *button, GaimGt
- }
-
- static void
--pause_button_cb(GtkButton *button, GaimGtkXferDialog *dialog)
-+pause_button_cb(GtkButton *button, Gaim2GtkXferDialog *dialog)
- {
- }
-
- static void
--resume_button_cb(GtkButton *button, GaimGtkXferDialog *dialog)
-+resume_button_cb(GtkButton *button, Gaim2GtkXferDialog *dialog)
- {
- }
-
- static void
--remove_button_cb(GtkButton *button, GaimGtkXferDialog *dialog)
-+remove_button_cb(GtkButton *button, Gaim2GtkXferDialog *dialog)
- {
-- gaim_gtkxfer_dialog_remove_xfer(dialog, dialog->selected_xfer);
-+ gaim2_gtkxfer_dialog_remove_xfer(dialog, dialog->selected_xfer);
- }
-
- static void
--stop_button_cb(GtkButton *button, GaimGtkXferDialog *dialog)
-+stop_button_cb(GtkButton *button, Gaim2GtkXferDialog *dialog)
- {
-- gaim_xfer_cancel_local(dialog->selected_xfer);
-+ gaim2_xfer_cancel_local(dialog->selected_xfer);
- }
-
- static void
--close_button_cb(GtkButton *button, GaimGtkXferDialog *dialog)
-+close_button_cb(GtkButton *button, Gaim2GtkXferDialog *dialog)
- {
-- gaim_gtkxfer_dialog_hide(dialog);
-+ gaim2_gtkxfer_dialog_hide(dialog);
- }
-
- /**************************************************************************
- * Dialog Building Functions
- **************************************************************************/
- static GtkWidget *
--setup_tree(GaimGtkXferDialog *dialog)
-+setup_tree(Gaim2GtkXferDialog *dialog)
- {
- GtkWidget *sw;
- GtkWidget *tree;
-@@ -585,7 +585,7 @@ setup_tree(GaimGtkXferDialog *dialog)
- gtk_tree_view_append_column(GTK_TREE_VIEW(tree), column);
-
- /* Progress bar column */
-- renderer = gaim_gtk_cell_renderer_progress_new();
-+ renderer = gaim2_gtk_cell_renderer_progress_new();
- column = gtk_tree_view_column_new_with_attributes(_("Progress"), renderer,
- "percentage", COLUMN_PROGRESS, NULL);
- gtk_tree_view_column_set_resizable(GTK_TREE_VIEW_COLUMN(column), TRUE);
-@@ -621,7 +621,7 @@ setup_tree(GaimGtkXferDialog *dialog)
- }
-
- static GtkWidget *
--make_info_table(GaimGtkXferDialog *dialog)
-+make_info_table(Gaim2GtkXferDialog *dialog)
- {
- GtkWidget *table;
- GtkWidget *label;
-@@ -683,10 +683,10 @@ make_info_table(GaimGtkXferDialog *dialo
- return table;
- }
-
--GaimGtkXferDialog *
--gaim_gtkxfer_dialog_new(void)
-+Gaim2GtkXferDialog *
-+gaim2_gtkxfer_dialog_new(void)
- {
-- GaimGtkXferDialog *dialog;
-+ Gaim2GtkXferDialog *dialog;
- GtkWidget *window;
- GtkWidget *vbox1, *vbox2;
- GtkWidget *bbox;
-@@ -696,11 +696,11 @@ gaim_gtkxfer_dialog_new(void)
- GtkWidget *table;
- GtkWidget *checkbox;
-
-- dialog = g_new0(GaimGtkXferDialog, 1);
-+ dialog = g_new0(Gaim2GtkXferDialog, 1);
- dialog->keep_open =
-- gaim_prefs_get_bool("/gaim/gtk/filetransfer/keep_open");
-+ gaim2_prefs_get_bool("/gaim2/gtk/filetransfer/keep_open");
- dialog->auto_clear =
-- gaim_prefs_get_bool("/gaim/gtk/filetransfer/clear_finished");
-+ gaim2_prefs_get_bool("/gaim2/gtk/filetransfer/clear_finished");
-
- /* Create the window. */
- dialog->window = window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
-@@ -829,11 +829,11 @@ gaim_gtkxfer_dialog_new(void)
- }
-
- void
--gaim_gtkxfer_dialog_destroy(GaimGtkXferDialog *dialog)
-+gaim2_gtkxfer_dialog_destroy(Gaim2GtkXferDialog *dialog)
- {
- g_return_if_fail(dialog != NULL);
-
-- gaim_notify_close_with_handle(dialog);
-+ gaim2_notify_close_with_handle(dialog);
-
- gtk_widget_destroy(dialog->window);
-
-@@ -841,7 +841,7 @@ gaim_gtkxfer_dialog_destroy(GaimGtkXferD
- }
-
- void
--gaim_gtkxfer_dialog_show(GaimGtkXferDialog *dialog)
-+gaim2_gtkxfer_dialog_show(Gaim2GtkXferDialog *dialog)
- {
- g_return_if_fail(dialog != NULL);
-
-@@ -849,36 +849,36 @@ gaim_gtkxfer_dialog_show(GaimGtkXferDial
- }
-
- void
--gaim_gtkxfer_dialog_hide(GaimGtkXferDialog *dialog)
-+gaim2_gtkxfer_dialog_hide(Gaim2GtkXferDialog *dialog)
- {
- g_return_if_fail(dialog != NULL);
-
-- gaim_notify_close_with_handle(dialog);
-+ gaim2_notify_close_with_handle(dialog);
-
- gtk_widget_hide(dialog->window);
- }
-
- void
--gaim_show_xfer_dialog()
-+gaim2_show_xfer_dialog()
- {
-- GaimGtkXferDialog *dialog;
-+ Gaim2GtkXferDialog *dialog;
-
-- dialog = gaim_get_gtkxfer_dialog();
-+ dialog = gaim2_get_gtkxfer_dialog();
-
- if (dialog == NULL) {
-- dialog = gaim_gtkxfer_dialog_new();
-+ dialog = gaim2_gtkxfer_dialog_new();
-
-- gaim_set_gtkxfer_dialog(dialog);
-+ gaim2_set_gtkxfer_dialog(dialog);
- }
-
-- gaim_gtkxfer_dialog_show(dialog);
-+ gaim2_gtkxfer_dialog_show(dialog);
- }
-
- void
--gaim_gtkxfer_dialog_add_xfer(GaimGtkXferDialog *dialog, GaimXfer *xfer)
-+gaim2_gtkxfer_dialog_add_xfer(Gaim2GtkXferDialog *dialog, Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-- GaimXferType type;
-+ Gaim2GtkXferUiData *data;
-+ Gaim2XferType type;
- GdkPixbuf *pixbuf;
- char *size_str, *remaining_str;
- char *lfilename, *utf8;
-@@ -886,21 +886,21 @@ gaim_gtkxfer_dialog_add_xfer(GaimGtkXfer
- g_return_if_fail(dialog != NULL);
- g_return_if_fail(xfer != NULL);
-
-- gaim_xfer_ref(xfer);
-+ gaim2_xfer_ref(xfer);
-
- data = GAIM_GTKXFER(xfer);
- data->in_list = TRUE;
-
-- gaim_gtkxfer_dialog_show(dialog);
-+ gaim2_gtkxfer_dialog_show(dialog);
-
- data->start_time = time(NULL);
- data->last_updated_time = 0;
- data->end_time = -1;
-
-- type = gaim_xfer_get_type(xfer);
-+ type = gaim2_xfer_get_type(xfer);
-
-- size_str = gaim_str_size_to_units(gaim_xfer_get_size(xfer));
-- remaining_str = gaim_str_size_to_units(gaim_xfer_get_bytes_remaining(xfer));
-+ size_str = gaim2_str_size_to_units(gaim2_xfer_get_size(xfer));
-+ remaining_str = gaim2_str_size_to_units(gaim2_xfer_get_bytes_remaining(xfer));
-
- pixbuf = gtk_widget_render_icon(dialog->window,
- (type == GAIM_XFER_RECEIVE
-@@ -909,7 +909,7 @@ gaim_gtkxfer_dialog_add_xfer(GaimGtkXfer
- GTK_ICON_SIZE_MENU, NULL);
-
- gtk_list_store_append(dialog->model, &data->iter);
-- lfilename = g_path_get_basename(gaim_xfer_get_local_filename(xfer));
-+ lfilename = g_path_get_basename(gaim2_xfer_get_local_filename(xfer));
- utf8 = g_filename_to_utf8(lfilename, -1, NULL, NULL, NULL);
- g_free(lfilename);
- lfilename = utf8;
-@@ -917,7 +917,7 @@ gaim_gtkxfer_dialog_add_xfer(GaimGtkXfer
- COLUMN_STATUS, pixbuf,
- COLUMN_PROGRESS, 0.0,
- COLUMN_FILENAME, (type == GAIM_XFER_RECEIVE)
-- ? gaim_xfer_get_filename(xfer)
-+ ? gaim2_xfer_get_filename(xfer)
- : lfilename,
- COLUMN_SIZE, size_str,
- COLUMN_REMAINING, _("Waiting for transfer to begin"),
-@@ -938,10 +938,10 @@ gaim_gtkxfer_dialog_add_xfer(GaimGtkXfer
- }
-
- void
--gaim_gtkxfer_dialog_remove_xfer(GaimGtkXferDialog *dialog,
-- GaimXfer *xfer)
-+gaim2_gtkxfer_dialog_remove_xfer(Gaim2GtkXferDialog *dialog,
-+ Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
-
- g_return_if_fail(dialog != NULL);
- g_return_if_fail(xfer != NULL);
-@@ -961,18 +961,18 @@ gaim_gtkxfer_dialog_remove_xfer(GaimGtkX
- dialog->num_transfers--;
-
- if (dialog->num_transfers == 0 && !dialog->keep_open)
-- gaim_gtkxfer_dialog_hide(dialog);
-+ gaim2_gtkxfer_dialog_hide(dialog);
- else
- ensure_row_selected(dialog);
-
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-
- void
--gaim_gtkxfer_dialog_cancel_xfer(GaimGtkXferDialog *dialog,
-- GaimXfer *xfer)
-+gaim2_gtkxfer_dialog_cancel_xfer(Gaim2GtkXferDialog *dialog,
-+ Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
- GdkPixbuf *pixbuf;
- gchar *status;
-
-@@ -987,8 +987,8 @@ gaim_gtkxfer_dialog_cancel_xfer(GaimGtkX
- if (!data->in_list)
- return;
-
-- if ((gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_LOCAL) && (dialog->auto_clear)) {
-- gaim_gtkxfer_dialog_remove_xfer(dialog, xfer);
-+ if ((gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_LOCAL) && (dialog->auto_clear)) {
-+ gaim2_gtkxfer_dialog_remove_xfer(dialog, xfer);
- return;
- }
-
-@@ -1000,7 +1000,7 @@ gaim_gtkxfer_dialog_cancel_xfer(GaimGtkX
- GAIM_STOCK_FILE_CANCELED,
- GTK_ICON_SIZE_MENU, NULL);
-
-- if (gaim_xfer_is_canceled(xfer))
-+ if (gaim2_xfer_is_canceled(xfer))
- status = _("Canceled");
- else
- status = _("Failed");
-@@ -1016,10 +1016,10 @@ gaim_gtkxfer_dialog_cancel_xfer(GaimGtkX
- }
-
- void
--gaim_gtkxfer_dialog_update_xfer(GaimGtkXferDialog *dialog,
-- GaimXfer *xfer)
-+gaim2_gtkxfer_dialog_update_xfer(Gaim2GtkXferDialog *dialog,
-+ Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
- char *size_str, *remaining_str;
- GtkTreeSelection *selection;
- time_t current_time;
-@@ -1035,23 +1035,23 @@ gaim_gtkxfer_dialog_update_xfer(GaimGtkX
-
- current_time = time(NULL);
- if (((current_time - data->last_updated_time) == 0) &&
-- (!gaim_xfer_is_completed(xfer)))
-+ (!gaim2_xfer_is_completed(xfer)))
- {
- /* Don't update the window more than once per second */
- return;
- }
- data->last_updated_time = current_time;
-
-- size_str = gaim_str_size_to_units(gaim_xfer_get_size(xfer));
-- remaining_str = gaim_str_size_to_units(gaim_xfer_get_bytes_remaining(xfer));
-+ size_str = gaim2_str_size_to_units(gaim2_xfer_get_size(xfer));
-+ remaining_str = gaim2_str_size_to_units(gaim2_xfer_get_bytes_remaining(xfer));
-
- gtk_list_store_set(xfer_dialog->model, &data->iter,
-- COLUMN_PROGRESS, gaim_xfer_get_progress(xfer),
-+ COLUMN_PROGRESS, gaim2_xfer_get_progress(xfer),
- COLUMN_SIZE, size_str,
- COLUMN_REMAINING, remaining_str,
- -1);
-
-- if (gaim_xfer_is_completed(xfer))
-+ if (gaim2_xfer_is_completed(xfer))
- {
- GdkPixbuf *pixbuf;
-
-@@ -1072,8 +1072,8 @@ gaim_gtkxfer_dialog_update_xfer(GaimGtkX
- if (xfer == dialog->selected_xfer)
- update_detailed_info(xfer_dialog, xfer);
-
-- if (gaim_xfer_is_completed(xfer) && dialog->auto_clear)
-- gaim_gtkxfer_dialog_remove_xfer(dialog, xfer);
-+ if (gaim2_xfer_is_completed(xfer) && dialog->auto_clear)
-+ gaim2_gtkxfer_dialog_remove_xfer(dialog, xfer);
- else
- update_buttons(dialog, xfer);
- }
-@@ -1082,19 +1082,19 @@ gaim_gtkxfer_dialog_update_xfer(GaimGtkX
- * File Transfer UI Ops
- **************************************************************************/
- static void
--gaim_gtkxfer_new_xfer(GaimXfer *xfer)
-+gaim2_gtkxfer_new_xfer(Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
-
- /* This is where we're setting xfer->ui_data for the first time. */
-- data = g_new0(GaimGtkXferUiData, 1);
-+ data = g_new0(Gaim2GtkXferUiData, 1);
- xfer->ui_data = data;
- }
-
- static void
--gaim_gtkxfer_destroy(GaimXfer *xfer)
-+gaim2_gtkxfer_destroy(Gaim2Xfer *xfer)
- {
-- GaimGtkXferUiData *data;
-+ Gaim2GtkXferUiData *data;
-
- data = GAIM_GTKXFER(xfer);
- if (data) {
-@@ -1106,76 +1106,76 @@ gaim_gtkxfer_destroy(GaimXfer *xfer)
- }
-
- static void
--gaim_gtkxfer_add_xfer(GaimXfer *xfer)
-+gaim2_gtkxfer_add_xfer(Gaim2Xfer *xfer)
- {
- if (xfer_dialog == NULL)
-- xfer_dialog = gaim_gtkxfer_dialog_new();
-+ xfer_dialog = gaim2_gtkxfer_dialog_new();
-
-- gaim_gtkxfer_dialog_add_xfer(xfer_dialog, xfer);
-+ gaim2_gtkxfer_dialog_add_xfer(xfer_dialog, xfer);
- }
-
- static void
--gaim_gtkxfer_update_progress(GaimXfer *xfer, double percent)
-+gaim2_gtkxfer_update_progress(Gaim2Xfer *xfer, double percent)
- {
-- gaim_gtkxfer_dialog_update_xfer(xfer_dialog, xfer);
-+ gaim2_gtkxfer_dialog_update_xfer(xfer_dialog, xfer);
- }
-
- static void
--gaim_gtkxfer_cancel_local(GaimXfer *xfer)
-+gaim2_gtkxfer_cancel_local(Gaim2Xfer *xfer)
- {
- if (xfer_dialog)
-- gaim_gtkxfer_dialog_cancel_xfer(xfer_dialog, xfer);
-+ gaim2_gtkxfer_dialog_cancel_xfer(xfer_dialog, xfer);
- }
-
- static void
--gaim_gtkxfer_cancel_remote(GaimXfer *xfer)
-+gaim2_gtkxfer_cancel_remote(Gaim2Xfer *xfer)
- {
- if (xfer_dialog)
-- gaim_gtkxfer_dialog_cancel_xfer(xfer_dialog, xfer);
-+ gaim2_gtkxfer_dialog_cancel_xfer(xfer_dialog, xfer);
- }
-
--static GaimXferUiOps ops =
-+static Gaim2XferUiOps ops =
- {
-- gaim_gtkxfer_new_xfer,
-- gaim_gtkxfer_destroy,
-- gaim_gtkxfer_add_xfer,
-- gaim_gtkxfer_update_progress,
-- gaim_gtkxfer_cancel_local,
-- gaim_gtkxfer_cancel_remote
-+ gaim2_gtkxfer_new_xfer,
-+ gaim2_gtkxfer_destroy,
-+ gaim2_gtkxfer_add_xfer,
-+ gaim2_gtkxfer_update_progress,
-+ gaim2_gtkxfer_cancel_local,
-+ gaim2_gtkxfer_cancel_remote
- };
-
- /**************************************************************************
- * GTK+ File Transfer API
- **************************************************************************/
- void
--gaim_gtk_xfers_init(void)
-+gaim2_gtk_xfers_init(void)
- {
-- gaim_prefs_add_none("/gaim/gtk/filetransfer");
-- gaim_prefs_add_bool("/gaim/gtk/filetransfer/clear_finished", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/filetransfer/keep_open", FALSE);
-+ gaim2_prefs_add_none("/gaim2/gtk/filetransfer");
-+ gaim2_prefs_add_bool("/gaim2/gtk/filetransfer/clear_finished", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/filetransfer/keep_open", FALSE);
- }
-
- void
--gaim_gtk_xfers_uninit(void)
-+gaim2_gtk_xfers_uninit(void)
- {
- if (xfer_dialog != NULL)
-- gaim_gtkxfer_dialog_destroy(xfer_dialog);
-+ gaim2_gtkxfer_dialog_destroy(xfer_dialog);
- }
-
- void
--gaim_set_gtkxfer_dialog(GaimGtkXferDialog *dialog)
-+gaim2_set_gtkxfer_dialog(Gaim2GtkXferDialog *dialog)
- {
- xfer_dialog = dialog;
- }
-
--GaimGtkXferDialog *
--gaim_get_gtkxfer_dialog(void)
-+Gaim2GtkXferDialog *
-+gaim2_get_gtkxfer_dialog(void)
- {
- return xfer_dialog;
- }
-
--GaimXferUiOps *
--gaim_gtk_xfers_get_ui_ops(void)
-+Gaim2XferUiOps *
-+gaim2_gtk_xfers_get_ui_ops(void)
- {
- return &ops;
- }
-diff -prNu ./src/gtkft.h ./src/gtkft.h
---- ./src/gtkft.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkft.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkft.h GTK+ File Transfer UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,7 +33,7 @@
- * The structure is opaque, as nobody should be touching anything inside of
- * it.
- */
--typedef struct _GaimGtkXferDialog GaimGtkXferDialog;
-+typedef struct _Gaim2GtkXferDialog Gaim2GtkXferDialog;
-
- /**************************************************************************/
- /** @name GTK+ File Transfer Dialog API */
-@@ -45,33 +45,33 @@ typedef struct _GaimGtkXferDialog GaimGt
- *
- * @return The new dialog.
- */
--GaimGtkXferDialog *gaim_gtkxfer_dialog_new(void);
-+Gaim2GtkXferDialog *gaim2_gtkxfer_dialog_new(void);
-
- /**
- * Destroys a file transfer dialog.
- *
- * @param dialog The file transfer dialog.
- */
--void gaim_gtkxfer_dialog_destroy(GaimGtkXferDialog *dialog);
-+void gaim2_gtkxfer_dialog_destroy(Gaim2GtkXferDialog *dialog);
-
- /**
- * Displays the file transfer dialog.
- *
- * @param dialog The file transfer dialog to show.
- */
--void gaim_gtkxfer_dialog_show(GaimGtkXferDialog *dialog);
-+void gaim2_gtkxfer_dialog_show(Gaim2GtkXferDialog *dialog);
-
- /**
- * Hides the file transfer dialog.
- *
- * @param dialog The file transfer dialog to hide.
- */
--void gaim_gtkxfer_dialog_hide(GaimGtkXferDialog *dialog);
-+void gaim2_gtkxfer_dialog_hide(Gaim2GtkXferDialog *dialog);
-
- /**
- * Shows the file transfer dialog, creating a new one if necessary
- */
--void gaim_show_xfer_dialog(void);
-+void gaim2_show_xfer_dialog(void);
-
- /**
- * Adds a file transfer to the dialog.
-@@ -79,7 +79,7 @@ void gaim_show_xfer_dialog(void);
- * @param dialog The file transfer dialog.
- * @param xfer The file transfer.
- */
--void gaim_gtkxfer_dialog_add_xfer(GaimGtkXferDialog *dialog, GaimXfer *xfer);
-+void gaim2_gtkxfer_dialog_add_xfer(Gaim2GtkXferDialog *dialog, Gaim2Xfer *xfer);
-
- /**
- * Removes a file transfer from the dialog.
-@@ -87,8 +87,8 @@ void gaim_gtkxfer_dialog_add_xfer(GaimGt
- * @param dialog The file transfer dialog.
- * @param xfer The file transfer.
- */
--void gaim_gtkxfer_dialog_remove_xfer(GaimGtkXferDialog *dialog,
-- GaimXfer *xfer);
-+void gaim2_gtkxfer_dialog_remove_xfer(Gaim2GtkXferDialog *dialog,
-+ Gaim2Xfer *xfer);
-
- /**
- * Indicate in a file transfer dialog that a transfer was canceled.
-@@ -96,8 +96,8 @@ void gaim_gtkxfer_dialog_remove_xfer(Gai
- * @param dialog The file transfer dialog.
- * @param xfer The file transfer that was canceled.
- */
--void gaim_gtkxfer_dialog_cancel_xfer(GaimGtkXferDialog *dialog,
-- GaimXfer *xfer);
-+void gaim2_gtkxfer_dialog_cancel_xfer(Gaim2GtkXferDialog *dialog,
-+ Gaim2Xfer *xfer);
-
- /**
- * Updates the information for a transfer in the dialog.
-@@ -105,8 +105,8 @@ void gaim_gtkxfer_dialog_cancel_xfer(Gai
- * @param dialog The file transfer dialog.
- * @param xfer The file transfer.
- */
--void gaim_gtkxfer_dialog_update_xfer(GaimGtkXferDialog *dialog,
-- GaimXfer *xfer);
-+void gaim2_gtkxfer_dialog_update_xfer(Gaim2GtkXferDialog *dialog,
-+ Gaim2Xfer *xfer);
-
- /*@}*/
-
-@@ -118,33 +118,33 @@ void gaim_gtkxfer_dialog_update_xfer(Gai
- /**
- * Initializes the GTK+ file transfer system.
- */
--void gaim_gtk_xfers_init(void);
-+void gaim2_gtk_xfers_init(void);
-
- /**
- * Uninitializes the GTK+ file transfer system.
- */
--void gaim_gtk_xfers_uninit(void);
-+void gaim2_gtk_xfers_uninit(void);
-
- /**
-- * Sets gaim's main file transfer dialog.
-+ * Sets gaim2's main file transfer dialog.
- *
- * @param dialog The main dialog.
- */
--void gaim_set_gtkxfer_dialog(GaimGtkXferDialog *dialog);
-+void gaim2_set_gtkxfer_dialog(Gaim2GtkXferDialog *dialog);
-
- /**
-- * Returns gaim's main file transfer dialog.
-+ * Returns gaim2's main file transfer dialog.
- *
- * @return The main dialog.
- */
--GaimGtkXferDialog *gaim_get_gtkxfer_dialog(void);
-+Gaim2GtkXferDialog *gaim2_get_gtkxfer_dialog(void);
-
- /**
- * Returns the UI operations structure for the GTK+ file transfer UI.
- *
- * @return The GTK+ file transfer UI operations structure.
- */
--GaimXferUiOps *gaim_gtk_xfers_get_ui_ops(void);
-+Gaim2XferUiOps *gaim2_gtk_xfers_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/gtkgaim2.h ./src/gtkgaim2.h
---- ./src/gtkgaim2.h 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/gtkgaim2.h 2006-01-05 15:11:20.000000000 +0100
-@@ -0,0 +1,83 @@
-+/**
-+ * @file gtkgaim2.h UI definitions and includes
-+ * @ingroup gtkui
-+ *
-+ * gaim2
-+ *
-+ * Gaim2 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
-+ */
-+#ifndef _GAIM_GTKGAIM_H_
-+#define _GAIM_GTKGAIM_H_
-+
-+#ifndef _WIN32
-+# include <gdk/gdkx.h>
-+#endif
-+
-+#include <gtk/gtk.h>
-+
-+/**
-+ * Our UI's identifier.
-+ */
-+#define GAIM_GTK_UI "gtk-gaim2"
-+
-+#ifndef _WIN32
-+# define GAIM_ALERT_TITLE ""
-+#else
-+# define GAIM_ALERT_TITLE "Gaim2"
-+#endif
-+
-+/*
-+ * This is backwards-compatibility code for older versions of GTK+ (< 2.4.x)
-+ * It defines the new wrap behavior (unknown in earlier versions)
-+ * as the old (slightly buggy) wrap behavior.
-+ * It also includes our back-ported GtkExpander
-+ */
-+/** @cond */
-+#if (!GTK_CHECK_VERSION(2,4,0))
-+#define GTK_WRAP_WORD_CHAR GTK_WRAP_WORD
-+#include "gtkexpander.h"
-+#endif
-+/** @endcond */
-+
-+/*
-+ * We include the sources for GtkComboBox and GtkCellView because
-+ * they don't exist in older version of Gtk+, and we use them
-+ * in a few places.
-+ */
-+#if !GTK_CHECK_VERSION(2,6,0)
-+# include "gtkcellview.h"
-+# include "gtkcellviewmenuitem.h"
-+# if !GTK_CHECK_VERSION(2,4,0)
-+# include "gtkcelllayout.h"
-+# include "gtkcombobox.h"
-+# endif /* Gtk 2.4 */
-+#endif /* Gtk 2.6 */
-+
-+/*
-+ * Spacings between components, as defined by the
-+ * GNOME Human Interface Guidelines.
-+ */
-+#define GAIM_HIG_CAT_SPACE 18
-+#define GAIM_HIG_BORDER 12
-+#define GAIM_HIG_BOX_SPACE 6
-+
-+#define GAIM_INVISIBLE_CHAR (gunichar)0x25cf
-+
-+#endif /* _GAIM_GTKGAIM_H_ */
-+
-diff -prNu ./src/gtkgaim.h ./src/gtkgaim.h
---- ./src/gtkgaim.h 2006-01-04 03:38:56.000000000 +0100
-+++ ./src/gtkgaim.h 1970-01-01 01:00:00.000000000 +0100
-@@ -1,83 +0,0 @@
--/**
-- * @file gtkgaim.h UI definitions and includes
-- * @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
-- */
--#ifndef _GAIM_GTKGAIM_H_
--#define _GAIM_GTKGAIM_H_
--
--#ifndef _WIN32
--# include <gdk/gdkx.h>
--#endif
--
--#include <gtk/gtk.h>
--
--/**
-- * Our UI's identifier.
-- */
--#define GAIM_GTK_UI "gtk-gaim"
--
--#ifndef _WIN32
--# define GAIM_ALERT_TITLE ""
--#else
--# define GAIM_ALERT_TITLE "Gaim"
--#endif
--
--/*
-- * This is backwards-compatibility code for older versions of GTK+ (< 2.4.x)
-- * It defines the new wrap behavior (unknown in earlier versions)
-- * as the old (slightly buggy) wrap behavior.
-- * It also includes our back-ported GtkExpander
-- */
--/** @cond */
--#if (!GTK_CHECK_VERSION(2,4,0))
--#define GTK_WRAP_WORD_CHAR GTK_WRAP_WORD
--#include "gtkexpander.h"
--#endif
--/** @endcond */
--
--/*
-- * We include the sources for GtkComboBox and GtkCellView because
-- * they don't exist in older version of Gtk+, and we use them
-- * in a few places.
-- */
--#if !GTK_CHECK_VERSION(2,6,0)
--# include "gtkcellview.h"
--# include "gtkcellviewmenuitem.h"
--# if !GTK_CHECK_VERSION(2,4,0)
--# include "gtkcelllayout.h"
--# include "gtkcombobox.h"
--# endif /* Gtk 2.4 */
--#endif /* Gtk 2.6 */
--
--/*
-- * Spacings between components, as defined by the
-- * GNOME Human Interface Guidelines.
-- */
--#define GAIM_HIG_CAT_SPACE 18
--#define GAIM_HIG_BORDER 12
--#define GAIM_HIG_BOX_SPACE 6
--
--#define GAIM_INVISIBLE_CHAR (gunichar)0x25cf
--
--#endif /* _GAIM_GTKGAIM_H_ */
--
-diff -prNu ./src/gtkidle.c ./src/gtkidle.c
---- ./src/gtkidle.c 2005-12-08 21:59:33.000000000 +0100
-+++ ./src/gtkidle.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -43,7 +43,7 @@
- *
- * In Debian bug #271639, jwz says:
- *
-- * Gaim should simply ask xscreensaver how long the user has been idle:
-+ * Gaim2 should simply ask xscreensaver how long the user has been idle:
- * % xscreensaver-command -time
- * XScreenSaver 4.18: screen blanked since Tue Sep 14 14:10:45 2004
- *
-@@ -60,7 +60,7 @@
- */
- #ifdef USE_SCREENSAVER
- static time_t
--gaim_gtk_get_time_idle()
-+gaim2_gtk_get_time_idle()
- {
- # ifndef _WIN32
- /* Query xscreensaver */
-@@ -76,22 +76,22 @@ gaim_gtk_get_time_idle()
- return 0;
- # else
- /* Query windows */
-- return (GetTickCount() - wgaim_get_lastactive()) / 1000;
-+ return (GetTickCount() - wgaim2_get_lastactive()) / 1000;
- # endif /* _WIN32 */
- }
- #endif /* USE_SCREENSAVER */
-
--static GaimIdleUiOps ui_ops =
-+static Gaim2IdleUiOps ui_ops =
- {
- #ifdef USE_SCREENSAVER
-- gaim_gtk_get_time_idle
-+ gaim2_gtk_get_time_idle
- #else
- NULL
- #endif /* USE_SCREENSAVER */
- };
-
--GaimIdleUiOps *
--gaim_gtk_idle_get_ui_ops()
-+Gaim2IdleUiOps *
-+gaim2_gtk_idle_get_ui_ops()
- {
- return &ui_ops;
- }
-diff -prNu ./src/gtkidle.h ./src/gtkidle.h
---- ./src/gtkidle.h 2005-11-30 07:03:49.000000000 +0100
-+++ ./src/gtkidle.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkidle.h GTK+ Idle API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -37,7 +37,7 @@
- *
- * @return The UI operations structure.
- */
--GaimIdleUiOps *gaim_gtk_idle_get_ui_ops(void);
-+Gaim2IdleUiOps *gaim2_gtk_idle_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/gtkimhtml.c ./src/gtkimhtml.c
---- ./src/gtkimhtml.c 2005-12-29 16:55:30.000000000 +0100
-+++ ./src/gtkimhtml.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkimhtml.c GTK+ IMHtml
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -63,7 +63,7 @@
-
- #include <pango/pango-font.h>
-
--/* GTK+ < 2.4.x hack, see gtkgaim.h for details. */
-+/* GTK+ < 2.4.x hack, see gtkgaim2.h for details. */
- #if (!GTK_CHECK_VERSION(2,4,0))
- #define GTK_WRAP_WORD_CHAR GTK_WRAP_WORD
- #endif
-@@ -171,9 +171,9 @@ clipboard_win32_to_html(char *clipboard)
- #if 0 /* Debugging for Windows clipboard */
- FILE *fd;
-
-- gaim_debug_info("imhtml clipboard", "from clipboard: %s\n", clipboard);
-+ gaim2_debug_info("imhtml clipboard", "from clipboard: %s\n", clipboard);
-
-- fd = g_fopen("e:\\gaimcb.txt", "wb");
-+ fd = g_fopen("e:\\gaim2cb.txt", "wb");
- fprintf(fd, "%s", clipboard);
- fclose(fd);
- #endif
-@@ -209,7 +209,7 @@ clipboard_win32_to_html(char *clipboard)
- html = g_strstrip(html);
-
- #if 0 /* Debugging for Windows clipboard */
-- gaim_debug_info("imhtml clipboard", "HTML fragment: '%s'\n", html);
-+ gaim2_debug_info("imhtml clipboard", "HTML fragment: '%s'\n", html);
- #endif
-
- return html;
-@@ -242,7 +242,7 @@ clipboard_html_to_win32(char *html) {
- g_string_free(clipboard, FALSE);
-
- #if 0 /* Debugging for Windows clipboard */
-- gaim_debug_info("imhtml clipboard", "from gaim: %s\n", ret);
-+ gaim2_debug_info("imhtml clipboard", "from gaim2: %s\n", ret);
- #endif
-
- return ret;
-@@ -264,7 +264,7 @@ static void clipboard_copy_html_win32(Gt
- if (SetClipboardData(win_html_fmt, hdata) == NULL) {
- gchar *err_msg =
- g_win32_error_message(GetLastError());
-- gaim_debug_info("html clipboard",
-+ gaim2_debug_info("html clipboard",
- "Unable to set clipboard data: %s\n",
- err_msg ? err_msg : "Unknown Error");
- g_free(err_msg);
-@@ -312,7 +312,7 @@ static gboolean clipboard_paste_html_win
-
- if (error_reading_clipboard) {
- gchar *err_msg = g_win32_error_message(GetLastError());
-- gaim_debug_info("html clipboard",
-+ gaim2_debug_info("html clipboard",
- "Unable to read clipboard data: %s\n",
- err_msg ? err_msg : "Unknown Error");
- g_free(err_msg);
-@@ -467,7 +467,7 @@ gtk_imhtml_tip (gpointer data)
- char *tmp = pango_font_description_to_string(
- imhtml->tip_window->style->font_desc);
-
-- gaim_debug(GAIM_DEBUG_ERROR, "gtk_imhtml_tip",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gtk_imhtml_tip",
- "pango_context_load_font() couldn't load font: '%s'\n",
- tmp);
- g_free(tmp);
-@@ -875,7 +875,7 @@ ucs2_to_utf8_with_bom_check(gchar *data,
- utf8_ret = g_convert(data, len, "UTF-8", fromcode, NULL, NULL, &error);
-
- if (error) {
-- gaim_debug_warning("gtkimhtml", "g_convert error: %s\n", error->message);
-+ gaim2_debug_warning("gtkimhtml", "g_convert error: %s\n", error->message);
- g_error_free(error);
- }
- return utf8_ret;
-@@ -1050,7 +1050,7 @@ static void paste_received_cb (GtkClipbo
- {
- int i;
-
-- gaim_debug_misc("gtkimhtml", "In paste_received_cb():\n\tformat = %d, length = %d\n\t",
-+ gaim2_debug_misc("gtkimhtml", "In paste_received_cb():\n\tformat = %d, length = %d\n\t",
- selection_data->format, selection_data->length);
-
- for (i = 0; i < (/*(selection_data->format / 8) **/ selection_data->length); i++) {
-@@ -1075,13 +1075,13 @@ static void paste_received_cb (GtkClipbo
- g_free(text);
- text = utf8;
- if (!text) {
-- gaim_debug_warning("gtkimhtml", "g_convert from UCS-2 failed in paste_received_cb\n");
-+ gaim2_debug_warning("gtkimhtml", "g_convert from UCS-2 failed in paste_received_cb\n");
- return;
- }
- }
-
- if (!(*text) || !g_utf8_validate(text, -1, NULL)) {
-- gaim_debug_warning("gtkimhtml", "empty string or invalid UTF-8 in paste_received_cb\n");
-+ gaim2_debug_warning("gtkimhtml", "empty string or invalid UTF-8 in paste_received_cb\n");
- g_free(text);
- return;
- }
-@@ -1645,13 +1645,13 @@ gtk_imhtml_link_drag_rcv_cb(GtkWidget *w
- switch (info) {
- case GTK_IMHTML_DRAG_URL:
- /* TODO: Is it really ok to change sd->data...? */
-- gaim_str_strip_char((char *)sd->data, '\r');
-+ gaim2_str_strip_char((char *)sd->data, '\r');
-
- links = g_strsplit((char *)sd->data, "\n", 0);
- while((link = links[i]) != NULL){
-- if(gaim_str_has_prefix(link, "http://") ||
-- gaim_str_has_prefix(link, "https://") ||
-- gaim_str_has_prefix(link, "ftp://"))
-+ if(gaim2_str_has_prefix(link, "http://") ||
-+ gaim2_str_has_prefix(link, "https://") ||
-+ gaim2_str_has_prefix(link, "ftp://"))
- {
- gchar *label;
-
-@@ -1693,11 +1693,11 @@ gtk_imhtml_link_drag_rcv_cb(GtkWidget *w
- utf8 = ucs2_to_utf8_with_bom_check(text, sd->length);
-
- if (!utf8) {
-- gaim_debug_warning("gtkimhtml", "g_convert from UCS-2 failed in drag_rcv_cb\n");
-+ gaim2_debug_warning("gtkimhtml", "g_convert from UCS-2 failed in drag_rcv_cb\n");
- return;
- }
- } else if (!(*text) || !g_utf8_validate(text, -1, NULL)) {
-- gaim_debug_warning("gtkimhtml", "empty string or invalid UTF-8 in drag_rcv_cb\n");
-+ gaim2_debug_warning("gtkimhtml", "empty string or invalid UTF-8 in drag_rcv_cb\n");
- return;
- }
-
-@@ -1707,7 +1707,7 @@ gtk_imhtml_link_drag_rcv_cb(GtkWidget *w
- }
- case GTK_IMHTML_DRAG_TEXT:
- if (!(*text) || !g_utf8_validate(text, -1, NULL)) {
-- gaim_debug_warning("gtkimhtml", "empty string or invalid UTF-8 in drag_rcv_cb\n");
-+ gaim2_debug_warning("gtkimhtml", "empty string or invalid UTF-8 in drag_rcv_cb\n");
- return;
- } else {
- char *tmp = g_markup_escape_text(text, -1);
-@@ -2251,20 +2251,20 @@ static int gtk_imhtml_is_protocol(const
- }
-
- /*
-- <KingAnt> marv: The two IM image functions in oscar are gaim_odc_send_im and gaim_odc_incoming
-+ <KingAnt> marv: The two IM image functions in oscar are gaim2_odc_send_im and gaim2_odc_incoming
-
-
- [19:58] <Robot101> marv: images go into the imgstore, a refcounted... well.. hash. :)
- [19:59] <KingAnt> marv: I think the image tag used by the core is something like <img id="#"/>
- [19:59] Ro0tSiEgE robert42 RobFlynn Robot101 ross22 roz
--[20:00] <KingAnt> marv: Where the ID is the what is returned when you add the image to the imgstore using gaim_imgstore_add
-+[20:00] <KingAnt> marv: Where the ID is the what is returned when you add the image to the imgstore using gaim2_imgstore_add
- [20:00] <marv> Robot101: so how does the image get passed to serv_got_im() and serv_send_im()? just as the <img id="#" and then the prpl looks it up from the store?
- [20:00] <KingAnt> marv: Right
- [20:00] <marv> alright
-
- Here's my plan with IMImages. make gtk_imhtml_[append|insert]_text_with_images instead just
- gtkimhtml_[append|insert]_text (hrm maybe it should be called html instead of text), add a
--function for gaim to register for look up images, i.e. gtk_imhtml_set_get_img_fnc, so that
-+function for gaim2 to register for look up images, i.e. gtk_imhtml_set_get_img_fnc, so that
- images can be looked up like that, instead of passing a GSList of them.
- */
-
-@@ -3390,7 +3390,7 @@ gtk_imhtml_image_save(GtkWidget *w, GtkI
- * So, um, AIM Direct IM lets you send any file, not just images. You can
- * just insert a sound or a file or whatever in a conversation. It's
- * basically like file transfer, except there is an icon to open the file
-- * embedded in the conversation. Someone should make the Gaim core handle
-+ * embedded in the conversation. Someone should make the Gaim2 core handle
- * all of that.
- */
- static gboolean gtk_imhtml_image_clicked(GtkWidget *w, GdkEvent *event, GtkIMHtmlImage *image)
-@@ -3995,7 +3995,7 @@ gtk_imhtml_clear_formatting(GtkIMHtml *i
- * I had this crazy idea about changing the text cursor color to reflex the foreground color
- * of the text about to be entered. This is the place you'd do it, along with the place where
- * we actually set a new foreground color.
-- * I may not do this, because people will bitch about Gaim overriding their gtk theme's cursor
-+ * I may not do this, because people will bitch about Gaim2 overriding their gtk theme's cursor
- * colors.
- *
- * Just in case I do do this, I asked about what to set the secondary text cursor to.
-@@ -4392,7 +4392,7 @@ void gtk_imhtml_insert_smiley_at_iter(Gt
- GdkPixbufAnimation *annipixbuf = NULL;
- GtkWidget *icon = NULL;
- GtkTextChildAnchor *anchor;
-- char *unescaped = gaim_unescape_html(smiley);
-+ char *unescaped = gaim2_unescape_html(smiley);
- GtkIMHtmlSmiley *imhtml_smiley = gtk_imhtml_smiley_get(imhtml, sml, unescaped);
-
- if (imhtml->format_functions & GTK_IMHTML_SMILEY) {
-@@ -4660,7 +4660,7 @@ char *gtk_imhtml_get_markup_range(GtkIMH
- }
-
- if (tmp == NULL)
-- gaim_debug_warning("gtkimhtml", "empty queue, more closing tags than open tags!\n");
-+ gaim2_debug_warning("gtkimhtml", "empty queue, more closing tags than open tags!\n");
- else
- g_string_append(str, tag_to_html_end(GTK_TEXT_TAG(tag)));
-
-diff -prNu ./src/gtkimhtml.h ./src/gtkimhtml.h
---- ./src/gtkimhtml.h 2005-12-19 10:15:06.000000000 +0100
-+++ ./src/gtkimhtml.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,7 +2,7 @@
- * @file gtkimhtml.h GTK+ IM/HTML rendering component
- * @ingroup gtkui
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/gtkimhtmltoolbar.c ./src/gtkimhtmltoolbar.c
---- ./src/gtkimhtmltoolbar.c 2005-12-21 19:36:11.000000000 +0100
-+++ ./src/gtkimhtmltoolbar.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkimhtmltoolbar.c GTK+ IMHtml Toolbar
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "imgstore.h"
- #include "notify.h"
-@@ -121,7 +121,7 @@ static void apply_font(GtkWidget *widget
- but for now only works with font face */
- char *fontname;
- char *space;
-- GtkIMHtmlToolbar *toolbar = g_object_get_data(G_OBJECT(fontsel), "gaim_toolbar");
-+ GtkIMHtmlToolbar *toolbar = g_object_get_data(G_OBJECT(fontsel), "gaim2_toolbar");
-
- fontname = gtk_font_selection_dialog_get_font_name(GTK_FONT_SELECTION_DIALOG(fontsel));
-
-@@ -146,7 +146,7 @@ toggle_font(GtkWidget *font, GtkIMHtmlTo
- if (!toolbar->font_dialog) {
- toolbar->font_dialog = gtk_font_selection_dialog_new(_("Select Font"));
-
-- g_object_set_data(G_OBJECT(toolbar->font_dialog), "gaim_toolbar", toolbar);
-+ g_object_set_data(G_OBJECT(toolbar->font_dialog), "gaim2_toolbar", toolbar);
-
- if(fontname) {
- char *fonttif = g_strdup_printf("%s 12", fontname);
-@@ -198,7 +198,7 @@ static void cancel_toolbar_fgcolor(GtkWi
- static void do_fgcolor(GtkWidget *widget, GtkColorSelection *colorsel)
- {
- GdkColor text_color;
-- GtkIMHtmlToolbar *toolbar = g_object_get_data(G_OBJECT(colorsel), "gaim_toolbar");
-+ GtkIMHtmlToolbar *toolbar = g_object_get_data(G_OBJECT(colorsel), "gaim2_toolbar");
- char *open_tag;
-
- open_tag = g_malloc(30);
-@@ -231,7 +231,7 @@ toggle_fg_color(GtkWidget *color, GtkIMH
- g_free(color);
- }
-
-- g_object_set_data(G_OBJECT(colorsel), "gaim_toolbar", toolbar);
-+ g_object_set_data(G_OBJECT(colorsel), "gaim2_toolbar", toolbar);
-
- g_signal_connect(G_OBJECT(toolbar->fgcolor_dialog), "delete_event",
- G_CALLBACK(destroy_toolbar_fgcolor), toolbar);
-@@ -274,7 +274,7 @@ cancel_toolbar_bgcolor(GtkWidget *widget
- static void do_bgcolor(GtkWidget *widget, GtkColorSelection *colorsel)
- {
- GdkColor text_color;
-- GtkIMHtmlToolbar *toolbar = g_object_get_data(G_OBJECT(colorsel), "gaim_toolbar");
-+ GtkIMHtmlToolbar *toolbar = g_object_get_data(G_OBJECT(colorsel), "gaim2_toolbar");
- char *open_tag;
-
- open_tag = g_malloc(30);
-@@ -310,7 +310,7 @@ toggle_bg_color(GtkWidget *color, GtkIMH
- g_free(color);
- }
-
-- g_object_set_data(G_OBJECT(colorsel), "gaim_toolbar", toolbar);
-+ g_object_set_data(G_OBJECT(colorsel), "gaim2_toolbar", toolbar);
-
- g_signal_connect(G_OBJECT(toolbar->bgcolor_dialog), "delete_event",
- G_CALLBACK(destroy_toolbar_bgcolor), toolbar);
-@@ -335,7 +335,7 @@ clear_formatting_cb(GtkWidget *clear, Gt
- }
-
- static void
--cancel_link_cb(GtkIMHtmlToolbar *toolbar, GaimRequestFields *fields)
-+cancel_link_cb(GtkIMHtmlToolbar *toolbar, Gaim2RequestFields *fields)
- {
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toolbar->link), FALSE);
-
-@@ -347,19 +347,19 @@ close_link_dialog(GtkIMHtmlToolbar *tool
- {
- if (toolbar->link_dialog != NULL)
- {
-- gaim_request_close(GAIM_REQUEST_FIELDS, toolbar->link_dialog);
-+ gaim2_request_close(GAIM_REQUEST_FIELDS, toolbar->link_dialog);
- toolbar->link_dialog = NULL;
- }
- }
-
- static void
--do_insert_link_cb(GtkIMHtmlToolbar *toolbar, GaimRequestFields *fields)
-+do_insert_link_cb(GtkIMHtmlToolbar *toolbar, Gaim2RequestFields *fields)
- {
- const char *url, *description;
-
-- url = gaim_request_fields_get_string(fields, "url");
-+ url = gaim2_request_fields_get_string(fields, "url");
- if (GTK_IMHTML(toolbar->imhtml)->format_functions & GTK_IMHTML_LINKDESC)
-- description = gaim_request_fields_get_string(fields, "description");
-+ description = gaim2_request_fields_get_string(fields, "description");
- else
- description = NULL;
-
-@@ -379,29 +379,29 @@ static void
- insert_link_cb(GtkWidget *w, GtkIMHtmlToolbar *toolbar)
- {
- if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(toolbar->link))) {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
- GtkTextIter start, end;
- char *msg;
- char *desc = NULL;
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("url", _("_URL"), NULL, FALSE);
-- gaim_request_field_set_required(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_string_new("url", _("_URL"), NULL, FALSE);
-+ gaim2_request_field_set_required(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
- if(GTK_IMHTML(toolbar->imhtml)->format_functions & GTK_IMHTML_LINKDESC) {
- if (gtk_text_buffer_get_selection_bounds(GTK_IMHTML(toolbar->imhtml)->text_buffer, &start, &end)) {
- desc = gtk_imhtml_get_text(GTK_IMHTML(toolbar->imhtml), &start, &end);
- }
-- field = gaim_request_field_string_new("description", _("_Description"),
-+ field = gaim2_request_field_string_new("description", _("_Description"),
- desc, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- msg = g_strdup(_("Please enter the URL and description of the "
- "link that you want to insert. The description "
- "is optional."));
-@@ -411,7 +411,7 @@ insert_link_cb(GtkWidget *w, GtkIMHtmlTo
- }
-
- toolbar->link_dialog =
-- gaim_request_fields(toolbar, _("Insert Link"),
-+ gaim2_request_fields(toolbar, _("Insert Link"),
- NULL,
- msg,
- fields,
-@@ -459,7 +459,7 @@ do_insert_image_cb(GtkWidget *widget, in
- }
-
- #if !GTK_CHECK_VERSION(2,4,0) /* FILECHOOSER */
-- if (gaim_gtk_check_if_dir(filename, GTK_FILE_SELECTION(widget))) {
-+ if (gaim2_gtk_check_if_dir(filename, GTK_FILE_SELECTION(widget))) {
- g_free(filename);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toolbar->image), FALSE);
- return;
-@@ -470,7 +470,7 @@ do_insert_image_cb(GtkWidget *widget, in
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toolbar->image), FALSE);
-
- if (!g_file_get_contents(filename, &filedata, &size, &error)) {
-- gaim_notify_error(NULL, NULL, error->message, NULL);
-+ gaim2_notify_error(NULL, NULL, error->message, NULL);
-
- g_error_free(error);
- g_free(filename);
-@@ -480,12 +480,12 @@ do_insert_image_cb(GtkWidget *widget, in
-
- name = strrchr(filename, G_DIR_SEPARATOR) + 1;
-
-- id = gaim_imgstore_add(filedata, size, name);
-+ id = gaim2_imgstore_add(filedata, size, name);
- g_free(filedata);
-
- if (id == 0) {
- buf = g_strdup_printf(_("Failed to store image: %s\n"), filename);
-- gaim_notify_error(NULL, NULL, buf, NULL);
-+ gaim2_notify_error(NULL, NULL, buf, NULL);
-
- g_free(buf);
- g_free(filename);
-@@ -499,7 +499,7 @@ do_insert_image_cb(GtkWidget *widget, in
- gtk_text_buffer_get_iter_at_mark(gtk_text_view_get_buffer(GTK_TEXT_VIEW(toolbar->imhtml)),
- &iter, ins);
- gtk_imhtml_insert_image_at_iter(GTK_IMHTML(toolbar->imhtml), id, &iter);
-- gaim_imgstore_unref(id);
-+ gaim2_imgstore_unref(id);
- }
-
-
-@@ -653,9 +653,9 @@ insert_smiley_cb(GtkWidget *smiley, GtkI
- }
-
- if (toolbar->sml)
-- smileys = gaim_gtkthemes_get_proto_smileys(toolbar->sml);
-+ smileys = gaim2_gtkthemes_get_proto_smileys(toolbar->sml);
- else
-- smileys = gaim_gtkthemes_get_proto_smileys(NULL);
-+ smileys = gaim2_gtkthemes_get_proto_smileys(NULL);
-
- while(smileys) {
- GtkIMHtmlSmiley *smiley = smileys->data;
-@@ -910,7 +910,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- sg = gtk_size_group_new(GTK_SIZE_GROUP_BOTH);
-
- /* Bold */
-- button = gaim_pixbuf_toolbar_button_from_stock(GTK_STOCK_BOLD);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GTK_STOCK_BOLD);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button, _("Bold"), NULL);
-@@ -921,7 +921,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->bold = button;
-
- /* Italic */
-- button = gaim_pixbuf_toolbar_button_from_stock(GTK_STOCK_ITALIC);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GTK_STOCK_ITALIC);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button, _("Italic"), NULL);
-@@ -932,7 +932,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->italic = button;
-
- /* Underline */
-- button = gaim_pixbuf_toolbar_button_from_stock(GTK_STOCK_UNDERLINE);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GTK_STOCK_UNDERLINE);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button, _("Underline"), NULL);
-@@ -947,7 +947,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- gtk_box_pack_start(GTK_BOX(hbox), sep, FALSE, FALSE, 0);
-
- /* Increase font size */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_TEXT_BIGGER);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_TEXT_BIGGER);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button,
-@@ -959,7 +959,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->larger_size = button;
-
- /* Decrease font size */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_TEXT_SMALLER);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_TEXT_SMALLER);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button,
-@@ -976,7 +976,7 @@ static void gtk_imhtmltoolbar_init (GtkI
-
- /* Font Face */
-
-- button = gaim_pixbuf_toolbar_button_from_stock(GTK_STOCK_SELECT_FONT);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GTK_STOCK_SELECT_FONT);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button,
-@@ -988,7 +988,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->font = button;
-
- /* Foreground Color */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_FGCOLOR);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_FGCOLOR);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button,
-@@ -1000,7 +1000,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->fgcolor = button;
-
- /* Background Color */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_BGCOLOR);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_BGCOLOR);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button,
-@@ -1016,7 +1016,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- gtk_box_pack_start(GTK_BOX(hbox), sep, FALSE, FALSE, 0);
-
- /* Clear Formatting */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_CLEAR);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_CLEAR);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button,
-@@ -1032,7 +1032,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- gtk_box_pack_start(GTK_BOX(hbox), sep, FALSE, FALSE, 0);
-
- /* Insert Link */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_LINK);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_LINK);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button, _("Insert link"), NULL);
-@@ -1042,7 +1042,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->link = button;
-
- /* Insert IM Image */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_IMAGE);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_IMAGE);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button, _("Insert image"), NULL);
-@@ -1053,7 +1053,7 @@ static void gtk_imhtmltoolbar_init (GtkI
- toolbar->image = button;
-
- /* Insert Smiley */
-- button = gaim_pixbuf_toolbar_button_from_stock(GAIM_STOCK_SMILEY);
-+ button = gaim2_pixbuf_toolbar_button_from_stock(GAIM_STOCK_SMILEY);
- gtk_size_group_add_widget(sg, button);
- gtk_box_pack_start(GTK_BOX(hbox), button, FALSE, FALSE, 0);
- gtk_tooltips_set_tip(toolbar->tooltips, button, _("Insert smiley"), NULL);
-diff -prNu ./src/gtkimhtmltoolbar.h ./src/gtkimhtmltoolbar.h
---- ./src/gtkimhtmltoolbar.h 2005-08-15 08:52:45.000000000 +0200
-+++ ./src/gtkimhtmltoolbar.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
- * GtkIMHtmlToolbar
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/gtklog.c ./src/gtklog.c
---- ./src/gtklog.c 2005-12-21 19:36:11.000000000 +0100
-+++ ./src/gtklog.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtklog.c GTK+ Log viewer
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "gtkblist.h"
-@@ -35,14 +35,14 @@
- #include "util.h"
-
- static GHashTable *log_viewers = NULL;
--static void populate_log_tree(GaimGtkLogViewer *lv);
--static GaimGtkLogViewer *syslog_viewer = NULL;
-+static void populate_log_tree(Gaim2GtkLogViewer *lv);
-+static Gaim2GtkLogViewer *syslog_viewer = NULL;
-
- struct log_viewer_hash_t {
-- GaimLogType type;
-+ Gaim2LogType type;
- char *screenname;
-- GaimAccount *account;
-- GaimContact *contact;
-+ Gaim2Account *account;
-+ Gaim2Contact *contact;
- };
-
- static guint log_viewer_hash(gconstpointer data)
-@@ -53,7 +53,7 @@ static guint log_viewer_hash(gconstpoint
- return g_direct_hash(viewer->contact);
-
- return g_str_hash(viewer->screenname) +
-- g_str_hash(gaim_account_get_username(viewer->account));
-+ g_str_hash(gaim2_account_get_username(viewer->account));
- }
-
- static gboolean log_viewer_equal(gconstpointer y, gconstpointer z)
-@@ -75,15 +75,15 @@ static gboolean log_viewer_equal(gconstp
- return FALSE;
- }
-
-- normal = g_strdup(gaim_normalize(a->account, a->screenname));
-+ normal = g_strdup(gaim2_normalize(a->account, a->screenname));
- ret = (a->account == b->account) &&
-- !strcmp(normal, gaim_normalize(b->account, b->screenname));
-+ !strcmp(normal, gaim2_normalize(b->account, b->screenname));
- g_free(normal);
-
- return ret;
- }
-
--static void search_cb(GtkWidget *button, GaimGtkLogViewer *lv)
-+static void search_cb(GtkWidget *button, Gaim2GtkLogViewer *lv)
- {
- const char *search_term = gtk_entry_get_text(GTK_ENTRY(lv->entry));
- GList *logs;
-@@ -110,15 +110,15 @@ static void search_cb(GtkWidget *button,
- gtk_main_iteration();
-
- for (logs = lv->logs; logs != NULL; logs = logs->next) {
-- char *read = gaim_log_read((GaimLog*)logs->data, NULL);
-- if (read && *read && gaim_strcasestr(read, search_term)) {
-+ char *read = gaim2_log_read((Gaim2Log*)logs->data, NULL);
-+ if (read && *read && gaim2_strcasestr(read, search_term)) {
- GtkTreeIter iter;
-- GaimLog *log = logs->data;
-+ Gaim2Log *log = logs->data;
- char title[64];
- char *title_utf8; /* temporary variable for utf8 conversion */
-
-- gaim_strftime(title, sizeof(title), "%c", localtime(&log->time));
-- title_utf8 = gaim_utf8_try_convert(title);
-+ gaim2_strftime(title, sizeof(title), "%c", localtime(&log->time));
-+ title_utf8 = gaim2_utf8_try_convert(title);
- strncpy(title, title_utf8, sizeof(title));
- g_free(title_utf8);
-
-@@ -134,7 +134,7 @@ static void search_cb(GtkWidget *button,
- }
-
- static gboolean destroy_cb(GtkWidget *w, gint resp, struct log_viewer_hash_t *ht) {
-- GaimGtkLogViewer *lv = syslog_viewer;
-+ Gaim2GtkLogViewer *lv = syslog_viewer;
-
- if (ht != NULL) {
- lv = g_hash_table_lookup(log_viewers, ht);
-@@ -150,7 +150,7 @@ static gboolean destroy_cb(GtkWidget *w,
- while (lv->logs != NULL) {
- GList *logs2;
-
-- gaim_log_free((GaimLog *)lv->logs->data);
-+ gaim2_log_free((Gaim2Log *)lv->logs->data);
-
- logs2 = lv->logs->next;
- g_list_free_1(lv->logs);
-@@ -166,20 +166,20 @@ static gboolean destroy_cb(GtkWidget *w,
- return TRUE;
- }
-
--static void log_row_activated_cb(GtkTreeView *tv, GtkTreePath *path, GtkTreeViewColumn *col, GaimGtkLogViewer *viewer) {
-+static void log_row_activated_cb(GtkTreeView *tv, GtkTreePath *path, GtkTreeViewColumn *col, Gaim2GtkLogViewer *viewer) {
- if (gtk_tree_view_row_expanded(tv, path))
- gtk_tree_view_collapse_row(tv, path);
- else
- gtk_tree_view_expand_row(tv, path, FALSE);
- }
-
--static void log_select_cb(GtkTreeSelection *sel, GaimGtkLogViewer *viewer) {
-+static void log_select_cb(GtkTreeSelection *sel, Gaim2GtkLogViewer *viewer) {
- GtkTreeIter iter;
- GValue val;
- GtkTreeModel *model = GTK_TREE_MODEL(viewer->treestore);
-- GaimLog *log = NULL;
-+ Gaim2Log *log = NULL;
- GdkCursor *cursor;
-- GaimLogReadFlags flags;
-+ Gaim2LogReadFlags flags;
- char *read = NULL;
- char time[64];
-
-@@ -208,14 +208,14 @@ static void log_select_cb(GtkTreeSelecti
- char *title;
- char *title_utf8; /* temporary variable for utf8 conversion */
-
-- gaim_strftime(time, sizeof(time), "%c", localtime(&log->time));
-+ gaim2_strftime(time, sizeof(time), "%c", localtime(&log->time));
-
- if (log->type == GAIM_LOG_CHAT)
- title = g_strdup_printf(_("Conversation in %s on %s"), log->name, time);
- else
- title = g_strdup_printf(_("Conversation with %s on %s"), log->name, time);
-
-- title_utf8 = gaim_utf8_try_convert(title);
-+ title_utf8 = gaim2_utf8_try_convert(title);
- g_free(title);
-
- title = g_strdup_printf("<span size='larger' weight='bold'>%s</span>", title_utf8);
-@@ -225,12 +225,12 @@ static void log_select_cb(GtkTreeSelecti
- g_free(title);
- }
-
-- read = gaim_log_read(log, &flags);
-+ read = gaim2_log_read(log, &flags);
- viewer->flags = flags;
-
- gtk_imhtml_clear(GTK_IMHTML(viewer->imhtml));
- gtk_imhtml_set_protocol_name(GTK_IMHTML(viewer->imhtml),
-- gaim_account_get_protocol_name(log->account));
-+ gaim2_account_get_protocol_name(log->account));
- gtk_imhtml_append_text(GTK_IMHTML(viewer->imhtml), read,
- GTK_IMHTML_NO_COMMENTS | GTK_IMHTML_NO_TITLE | GTK_IMHTML_NO_SCROLL |
- ((flags & GAIM_LOG_READ_NO_NEWLINE) ? GTK_IMHTML_NO_NEWLINE : 0));
-@@ -252,7 +252,7 @@ static void log_select_cb(GtkTreeSelecti
- *
- * For now, I'll just make it a flat list.
- */
--static void populate_log_tree(GaimGtkLogViewer *lv)
-+static void populate_log_tree(Gaim2GtkLogViewer *lv)
- /* Logs are made from trees in real life.
- This is a tree made from logs */
- {
-@@ -264,16 +264,16 @@ static void populate_log_tree(GaimGtkLog
- GList *logs = lv->logs;
-
- while (logs != NULL) {
-- GaimLog *log = logs->data;
-+ Gaim2Log *log = logs->data;
-
-- gaim_strftime(month, sizeof(month), "%B %Y", localtime(&log->time));
-- gaim_strftime(title, sizeof(title), "%c", localtime(&log->time));
-+ gaim2_strftime(month, sizeof(month), "%B %Y", localtime(&log->time));
-+ gaim2_strftime(title, sizeof(title), "%c", localtime(&log->time));
-
- /* do utf8 conversions */
-- utf8_tmp = gaim_utf8_try_convert(month);
-+ utf8_tmp = gaim2_utf8_try_convert(month);
- strncpy(month, utf8_tmp, sizeof(month));
- g_free(utf8_tmp);
-- utf8_tmp = gaim_utf8_try_convert(title);
-+ utf8_tmp = gaim2_utf8_try_convert(title);
- strncpy(title, utf8_tmp, sizeof(title));
- g_free(utf8_tmp);
-
-@@ -293,10 +293,10 @@ static void populate_log_tree(GaimGtkLog
- }
- }
-
--static GaimGtkLogViewer *display_log_viewer(struct log_viewer_hash_t *ht, GList *logs,
-+static Gaim2GtkLogViewer *display_log_viewer(struct log_viewer_hash_t *ht, GList *logs,
- const char *title, GdkPixbuf *pixbuf, int log_size)
- {
-- GaimGtkLogViewer *lv;
-+ Gaim2GtkLogViewer *lv;
- GtkWidget *title_box;
- char *text;
- GtkWidget *pane;
-@@ -313,7 +313,7 @@ static GaimGtkLogViewer *display_log_vie
- GtkWidget *button;
- GtkWidget *size_label;
-
-- lv = g_new0(GaimGtkLogViewer, 1);
-+ lv = g_new0(Gaim2GtkLogViewer, 1);
- lv->logs = logs;
-
- if (logs == NULL)
-@@ -322,19 +322,19 @@ static GaimGtkLogViewer *display_log_vie
- const char *log_preferences = NULL;
-
- if (ht == NULL) {
-- if (!gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (!gaim2_prefs_get_bool("/core/logging/log_system"))
- log_preferences = _("System events will only be logged if the \"Log all status changes to system log\" preference is enabled.");
- } else {
- if (ht->type == GAIM_LOG_IM) {
-- if (!gaim_prefs_get_bool("/core/logging/log_ims"))
-+ if (!gaim2_prefs_get_bool("/core/logging/log_ims"))
- log_preferences = _("Instant messages will only be logged if the \"Log all instant messages\" preference is enabled.");
- } else if (ht->type == GAIM_LOG_CHAT) {
-- if (!gaim_prefs_get_bool("/core/logging/log_chats"))
-+ if (!gaim2_prefs_get_bool("/core/logging/log_chats"))
- log_preferences = _("Chats will only be logged if the \"Log all chats\" preference is enabled.");
- }
- }
-
-- gaim_notify_info(NULL, title, _("No logs were found"), log_preferences);
-+ gaim2_notify_info(NULL, title, _("No logs were found"), log_preferences);
- return NULL;
- }
-
-@@ -405,11 +405,11 @@ static GaimGtkLogViewer *display_log_vie
- g_signal_connect (G_OBJECT(lv->treeview), "row-activated",
- G_CALLBACK(log_row_activated_cb),
- lv);
-- gaim_set_accessible_label(lv->treeview, lv->label);
-+ gaim2_set_accessible_label(lv->treeview, lv->label);
-
- /* Log size ************/
- if(log_size) {
-- char *sz_txt = gaim_str_size_to_units(log_size);
-+ char *sz_txt = gaim2_str_size_to_units(log_size);
- text = g_strdup_printf("<span weight='bold'>%s</span> %s", _("Total log size:"), sz_txt);
- size_label = gtk_label_new(NULL);
- gtk_label_set_markup(GTK_LABEL(size_label), text);
-@@ -425,8 +425,8 @@ static GaimGtkLogViewer *display_log_vie
- gtk_paned_add2(GTK_PANED(pane), vbox);
-
- /* Viewer ************/
-- frame = gaim_gtk_create_imhtml(FALSE, &lv->imhtml, NULL);
-- gtk_widget_set_name(lv->imhtml, "gaim_gtklog_imhtml");
-+ frame = gaim2_gtk_create_imhtml(FALSE, &lv->imhtml, NULL);
-+ gtk_widget_set_name(lv->imhtml, "gaim2_gtklog_imhtml");
- gtk_widget_set_size_request(lv->imhtml, 320, 200);
- gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
- gtk_widget_show(frame);
-@@ -458,9 +458,9 @@ static GaimGtkLogViewer *display_log_vie
- return lv;
- }
-
--void gaim_gtk_log_show(GaimLogType type, const char *screenname, GaimAccount *account) {
-+void gaim2_gtk_log_show(Gaim2LogType type, const char *screenname, Gaim2Account *account) {
- struct log_viewer_hash_t *ht = g_new0(struct log_viewer_hash_t, 1);
-- GaimGtkLogViewer *lv = NULL;
-+ Gaim2GtkLogViewer *lv = NULL;
- const char *name = screenname;
- char *title;
-
-@@ -480,32 +480,32 @@ void gaim_gtk_log_show(GaimLogType type,
- }
-
- if (type == GAIM_LOG_CHAT) {
-- GaimChat *chat;
-+ Gaim2Chat *chat;
-
-- chat = gaim_blist_find_chat(account, screenname);
-+ chat = gaim2_blist_find_chat(account, screenname);
- if (chat != NULL)
-- name = gaim_chat_get_name(chat);
-+ name = gaim2_chat_get_name(chat);
-
- title = g_strdup_printf(_("Conversations in %s"), name);
- } else {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- buddy = gaim_find_buddy(account, screenname);
-+ buddy = gaim2_find_buddy(account, screenname);
- if (buddy != NULL)
-- name = gaim_buddy_get_contact_alias(buddy);
-+ name = gaim2_buddy_get_contact_alias(buddy);
-
- title = g_strdup_printf(_("Conversations with %s"), name);
- }
-
-- display_log_viewer(ht, gaim_log_get_logs(type, screenname, account),
-- title, gaim_gtk_create_prpl_icon(account), gaim_log_get_total_size(type, screenname, account));
-+ display_log_viewer(ht, gaim2_log_get_logs(type, screenname, account),
-+ title, gaim2_gtk_create_prpl_icon(account), gaim2_log_get_total_size(type, screenname, account));
- g_free(title);
- }
-
--void gaim_gtk_log_show_contact(GaimContact *contact) {
-+void gaim2_gtk_log_show_contact(Gaim2Contact *contact) {
- struct log_viewer_hash_t *ht = g_new0(struct log_viewer_hash_t, 1);
-- GaimBlistNode *child;
-- GaimGtkLogViewer *lv = NULL;
-+ Gaim2BlistNode *child;
-+ Gaim2GtkLogViewer *lv = NULL;
- GList *logs = NULL;
- char *filename;
- GdkPixbuf *pixbuf;
-@@ -530,27 +530,27 @@ void gaim_gtk_log_show_contact(GaimConta
- if (!GAIM_BLIST_NODE_IS_BUDDY(child))
- continue;
-
-- logs = g_list_concat(gaim_log_get_logs(GAIM_LOG_IM, ((GaimBuddy *)child)->name,
-- ((GaimBuddy *)child)->account), logs);
-- total_log_size += gaim_log_get_total_size(GAIM_LOG_IM, ((GaimBuddy *)child)->name, ((GaimBuddy *)child)->account);
-+ logs = g_list_concat(gaim2_log_get_logs(GAIM_LOG_IM, ((Gaim2Buddy *)child)->name,
-+ ((Gaim2Buddy *)child)->account), logs);
-+ total_log_size += gaim2_log_get_total_size(GAIM_LOG_IM, ((Gaim2Buddy *)child)->name, ((Gaim2Buddy *)child)->account);
- }
-- logs = g_list_sort(logs, gaim_log_compare);
-+ logs = g_list_sort(logs, gaim2_log_compare);
-
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "icons", "online.png", NULL);
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "icons", "online.png", NULL);
- pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-
- if (contact->alias != NULL)
- name = contact->alias;
- else if (contact->priority != NULL)
-- name = gaim_buddy_get_contact_alias(contact->priority);
-+ name = gaim2_buddy_get_contact_alias(contact->priority);
-
- title = g_strdup_printf(_("Conversations with %s"), name);
- display_log_viewer(ht, logs, title, pixbuf, total_log_size);
- g_free(title);
- }
-
--void gaim_gtk_syslog_show()
-+void gaim2_gtk_syslog_show()
- {
- GList *accounts = NULL;
- GList *logs = NULL;
-@@ -560,15 +560,15 @@ void gaim_gtk_syslog_show()
- return;
- }
-
-- for(accounts = gaim_accounts_get_all(); accounts != NULL; accounts = accounts->next) {
-+ for(accounts = gaim2_accounts_get_all(); accounts != NULL; accounts = accounts->next) {
-
-- GaimAccount *account = (GaimAccount *)accounts->data;
-- if(gaim_find_prpl(gaim_account_get_protocol_id(account)) == NULL)
-+ Gaim2Account *account = (Gaim2Account *)accounts->data;
-+ if(gaim2_find_prpl(gaim2_account_get_protocol_id(account)) == NULL)
- continue;
-
-- logs = g_list_concat(gaim_log_get_system_logs(account), logs);
-+ logs = g_list_concat(gaim2_log_get_system_logs(account), logs);
- }
-- logs = g_list_sort(logs, gaim_log_compare);
-+ logs = g_list_sort(logs, gaim2_log_compare);
-
- syslog_viewer = display_log_viewer(NULL, logs, _("System Log"), NULL, 0);
- }
-diff -prNu ./src/gtklog.h ./src/gtklog.h
---- ./src/gtklog.h 2005-12-29 18:44:08.000000000 +0100
-+++ ./src/gtklog.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtklog.h GTK+ Log viewer
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,17 +25,17 @@
- #ifndef _GAIM_GTKLOG_H_
- #define _GAIM_GTKLOG_H_
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "log.h"
-
- #include "account.h"
-
--typedef struct _GaimGtkLogViewer GaimGtkLogViewer;
-+typedef struct _Gaim2GtkLogViewer Gaim2GtkLogViewer;
-
- /**
- * A GTK+ Log Viewer. You can look at logs with it.
- */
--struct _GaimGtkLogViewer {
-+struct _Gaim2GtkLogViewer {
- GList *logs; /**< The list of logs viewed in this viewer */
-
- GtkWidget *window; /**< The viewer's window */
-@@ -44,16 +44,16 @@ struct _GaimGtkLogViewer {
- GtkWidget *imhtml; /**< The imhtml to display said logs */
- GtkWidget *entry; /**< The search entry, in which search terms
- * are entered */
-- GaimLogReadFlags flags; /**< The most recently used log flags */
-+ Gaim2LogReadFlags flags; /**< The most recently used log flags */
- char *search; /**< The string currently being searched for */
- GtkWidget *label; /**< The label at the top of the log viewer */
- };
-
-
-
--void gaim_gtk_log_show(GaimLogType type, const char *screenname, GaimAccount *account);
--void gaim_gtk_log_show_contact(GaimContact *contact);
-+void gaim2_gtk_log_show(Gaim2LogType type, const char *screenname, Gaim2Account *account);
-+void gaim2_gtk_log_show_contact(Gaim2Contact *contact);
-
--void gaim_gtk_syslog_show(void);
-+void gaim2_gtk_syslog_show(void);
-
- #endif
-diff -prNu ./src/gtkmain.c ./src/gtkmain.c
---- ./src/gtkmain.c 2005-12-29 02:36:34.000000000 +0100
-+++ ./src/gtkmain.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -22,7 +22,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "conversation.h"
-@@ -112,7 +112,7 @@ static int ignore_sig_list[] = {
- static int
- dologin_named(const char *name)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char **names;
- int i;
- int ret = -1;
-@@ -120,22 +120,22 @@ dologin_named(const char *name)
- if (name != NULL) { /* list of names given */
- names = g_strsplit(name, ",", 64);
- for (i = 0; names[i] != NULL; i++) {
-- account = gaim_accounts_find(names[i], NULL);
-+ account = gaim2_accounts_find(names[i], NULL);
- if (account != NULL) { /* found a user */
- ret = 0;
-- gaim_account_connect(account);
-+ gaim2_account_connect(account);
- }
- }
- g_strfreev(names);
- } else { /* no name given, use the first account */
- GList *accounts;
-
-- accounts = gaim_accounts_get_all();
-+ accounts = gaim2_accounts_get_all();
- if (accounts != NULL)
- {
-- account = (GaimAccount *)accounts->data;
-+ account = (Gaim2Account *)accounts->data;
- ret = 0;
-- gaim_account_connect(account);
-+ gaim2_account_connect(account);
- }
- }
-
-@@ -167,8 +167,8 @@ sighandler(int sig)
- {
- switch (sig) {
- case SIGHUP:
-- gaim_debug_warning("sighandler", "Caught signal %d\n", sig);
-- gaim_connections_disconnect_all();
-+ gaim2_debug_warning("sighandler", "Caught signal %d\n", sig);
-+ gaim2_connections_disconnect_all();
- break;
- case SIGSEGV:
- fprintf(stderr, segfault_message);
-@@ -179,10 +179,10 @@ sighandler(int sig)
- signal(SIGCHLD, sighandler); /* restore signal catching on this one! */
- break;
- default:
-- gaim_debug_warning("sighandler", "Caught signal %d\n", sig);
-- gaim_connections_disconnect_all();
-+ gaim2_debug_warning("sighandler", "Caught signal %d\n", sig);
-+ gaim2_connections_disconnect_all();
-
-- gaim_plugins_unload_all();
-+ gaim2_plugins_unload_all();
-
- if (gtk_main_level())
- gtk_main_quit();
-@@ -200,13 +200,13 @@ ui_main()
- char *icon_path;
- #endif
-
-- gaim_gtkthemes_init();
-+ gaim2_gtkthemes_init();
-
-- gaim_gtk_blist_setup_sort_methods();
-+ gaim2_gtk_blist_setup_sort_methods();
-
- #ifndef _WIN32
- /* use the nice PNG icon for all the windows */
-- icon_path = g_build_filename(DATADIR, "pixmaps", "gaim", "icons", "online.png", NULL);
-+ icon_path = g_build_filename(DATADIR, "pixmaps", "gaim2", "icons", "online.png", NULL);
- icon = gdk_pixbuf_new_from_file(icon_path, NULL);
- g_free(icon_path);
- if (icon) {
-@@ -215,7 +215,7 @@ ui_main()
- g_object_unref(G_OBJECT(icon));
- g_list_free(icons);
- } else {
-- gaim_debug_error("ui_main",
-+ gaim2_debug_error("ui_main",
- "Failed to load the default window icon!\n");
- }
- #endif
-@@ -226,75 +226,75 @@ ui_main()
- static void
- debug_init(void)
- {
-- gaim_debug_set_ui_ops(gaim_gtk_debug_get_ui_ops());
-- gaim_gtk_debug_init();
-+ gaim2_debug_set_ui_ops(gaim2_gtk_debug_get_ui_ops());
-+ gaim2_gtk_debug_init();
- }
-
- static void
--gaim_gtk_ui_init(void)
-+gaim2_gtk_ui_init(void)
- {
- /* Set the UI operation structures. */
-- gaim_accounts_set_ui_ops(gaim_gtk_accounts_get_ui_ops());
-- gaim_xfers_set_ui_ops(gaim_gtk_xfers_get_ui_ops());
-- gaim_blist_set_ui_ops(gaim_gtk_blist_get_ui_ops());
-- gaim_notify_set_ui_ops(gaim_gtk_notify_get_ui_ops());
-- gaim_privacy_set_ui_ops(gaim_gtk_privacy_get_ui_ops());
-- gaim_request_set_ui_ops(gaim_gtk_request_get_ui_ops());
-- gaim_sound_set_ui_ops(gaim_gtk_sound_get_ui_ops());
-- gaim_connections_set_ui_ops(gaim_gtk_connections_get_ui_ops());
-- gaim_whiteboard_set_ui_ops(gaim_gtk_whiteboard_get_ui_ops());
-+ gaim2_accounts_set_ui_ops(gaim2_gtk_accounts_get_ui_ops());
-+ gaim2_xfers_set_ui_ops(gaim2_gtk_xfers_get_ui_ops());
-+ gaim2_blist_set_ui_ops(gaim2_gtk_blist_get_ui_ops());
-+ gaim2_notify_set_ui_ops(gaim2_gtk_notify_get_ui_ops());
-+ gaim2_privacy_set_ui_ops(gaim2_gtk_privacy_get_ui_ops());
-+ gaim2_request_set_ui_ops(gaim2_gtk_request_get_ui_ops());
-+ gaim2_sound_set_ui_ops(gaim2_gtk_sound_get_ui_ops());
-+ gaim2_connections_set_ui_ops(gaim2_gtk_connections_get_ui_ops());
-+ gaim2_whiteboard_set_ui_ops(gaim2_gtk_whiteboard_get_ui_ops());
- #ifdef USE_SCREENSAVER
-- gaim_idle_set_ui_ops(gaim_gtk_idle_get_ui_ops());
-+ gaim2_idle_set_ui_ops(gaim2_gtk_idle_get_ui_ops());
- #endif
-
-- gaim_gtk_stock_init();
-- gaim_gtk_prefs_init();
-- gaim_gtk_account_init();
-- gaim_gtk_blist_init();
-- gaim_gtk_status_init();
-- gaim_gtk_conversations_init();
-- gaim_gtk_pounces_init();
-- gaim_gtk_privacy_init();
-- gaim_gtk_xfers_init();
-- gaim_gtk_roomlist_init();
-+ gaim2_gtk_stock_init();
-+ gaim2_gtk_prefs_init();
-+ gaim2_gtk_account_init();
-+ gaim2_gtk_blist_init();
-+ gaim2_gtk_status_init();
-+ gaim2_gtk_conversations_init();
-+ gaim2_gtk_pounces_init();
-+ gaim2_gtk_privacy_init();
-+ gaim2_gtk_xfers_init();
-+ gaim2_gtk_roomlist_init();
- #ifdef HAVE_VV
-- gaim_gtk_media_init();
-+ gaim2_gtk_media_init();
- #endif
- }
-
- static void
--gaim_gtk_quit(void)
-+gaim2_gtk_quit(void)
- {
- #ifdef USE_SM
- /* unplug */
-- gaim_gtk_session_end();
-+ gaim2_gtk_session_end();
- #endif
-
- /* Save the plugins we have loaded for next time. */
-- gaim_gtk_plugins_save();
-+ gaim2_gtk_plugins_save();
-
- /* Uninit */
-- gaim_gtk_conversations_uninit();
-- gaim_gtk_status_uninit();
-- gaim_gtk_blist_uninit();
-- gaim_gtk_account_uninit();
-- gaim_gtk_xfers_uninit();
-- gaim_gtk_debug_uninit();
-+ gaim2_gtk_conversations_uninit();
-+ gaim2_gtk_status_uninit();
-+ gaim2_gtk_blist_uninit();
-+ gaim2_gtk_account_uninit();
-+ gaim2_gtk_xfers_uninit();
-+ gaim2_gtk_debug_uninit();
-
- /* and end it all... */
- gtk_main_quit();
- }
-
--static GaimCoreUiOps core_ops =
-+static Gaim2CoreUiOps core_ops =
- {
-- gaim_gtk_prefs_init,
-+ gaim2_gtk_prefs_init,
- debug_init,
-- gaim_gtk_ui_init,
-- gaim_gtk_quit
-+ gaim2_gtk_ui_init,
-+ gaim2_gtk_quit
- };
-
--static GaimCoreUiOps *
--gaim_gtk_core_get_ui_ops(void)
-+static Gaim2CoreUiOps *
-+gaim2_gtk_core_get_ui_ops(void)
- {
- return &core_ops;
- }
-@@ -307,9 +307,9 @@ show_usage(const char *name, gboolean te
- GError *error = NULL;
-
- if (terse) {
-- text = g_strdup_printf(_("Gaim %s. Try `%s -h' for more information.\n"), VERSION, name);
-+ text = g_strdup_printf(_("Gaim2 %s. Try `%s -h' for more information.\n"), VERSION, name);
- } else {
-- text = g_strdup_printf(_("Gaim %s\n"
-+ text = g_strdup_printf(_("Gaim2 %s\n"
- "Usage: %s [OPTION]...\n\n"
- " -c, --config=DIR use DIR for config files\n"
- " -d, --debug print debugging messages to stdout\n"
-@@ -372,7 +372,7 @@ startup_notification_complete(void)
- #endif /* HAVE_STARTUP_NOTIFICATION */
-
- #ifndef _WIN32
--static char *gaim_find_binary_location(void *symbol, void *data)
-+static char *gaim2_find_binary_location(void *symbol, void *data)
- {
- static char *fullname = NULL;
- static gboolean first = TRUE;
-@@ -423,7 +423,7 @@ static char *gaim_find_binary_location(v
-
- /* FUCKING GET ME A TOWEL! */
- #ifdef _WIN32
--int gaim_main(HINSTANCE hint, int argc, char *argv[])
-+int gaim2_main(HINSTANCE hint, int argc, char *argv[])
- #else
- int main(int argc, char *argv[])
- #endif
-@@ -472,7 +472,7 @@ int main(int argc, char *argv[])
- #endif
-
- #ifndef _WIN32
-- br_set_locate_fallback_func(gaim_find_binary_location, argv[0]);
-+ br_set_locate_fallback_func(gaim2_find_binary_location, argv[0]);
- #endif
- #ifdef ENABLE_NLS
- bindtextdomain(PACKAGE, LOCALEDIR);
-@@ -486,11 +486,11 @@ int main(int argc, char *argv[])
- #ifndef DEBUG
- /* We translate this here in case the crash breaks gettext. */
- segfault_message = g_strdup(_(
-- "Gaim has segfaulted and attempted to dump a core file.\n"
-+ "Gaim2 has segfaulted and attempted to dump a core file.\n"
- "This is a bug in the software and has happened through\n"
- "no fault of your own.\n\n"
- "It is possible that this bug is already fixed in CVS.\n"
-- "If you can reproduce the crash, please notify the gaim\n"
-+ "If you can reproduce the crash, please notify the gaim2\n"
- "developers by reporting a bug at\n"
- GAIM_WEBSITE "bug.php\n\n"
- "Please make sure to specify what you were doing at the time\n"
-@@ -599,13 +599,13 @@ int main(int argc, char *argv[])
- }
- /* show version message */
- if (opt_version) {
-- printf("Gaim %s\n", VERSION);
-+ printf("Gaim2 %s\n", VERSION);
- return 0;
- }
-
- /* set a user-specified config directory */
- if (opt_config_dir_arg != NULL) {
-- gaim_util_set_user_dir(opt_config_dir_arg);
-+ gaim2_util_set_user_dir(opt_config_dir_arg);
- }
-
- /*
-@@ -613,13 +613,13 @@ int main(int argc, char *argv[])
- * Fire up this baby.
- */
-
-- gaim_debug_set_enabled(debug_enabled);
-+ gaim2_debug_set_enabled(debug_enabled);
-
- #ifdef _WIN32
-- wgaim_init(hint);
-+ wgaim2_init(hint);
- #endif
-
-- search_path = g_build_filename(gaim_user_dir(), "gtkrc-2.0", NULL);
-+ search_path = g_build_filename(gaim2_user_dir(), "gtkrc-2.0", NULL);
- gtk_rc_add_default_file(search_path);
- g_free(search_path);
-
-@@ -628,7 +628,7 @@ int main(int argc, char *argv[])
- if (!gui_check) {
- char *display = gdk_get_display();
-
-- printf("Gaim %s\n", VERSION);
-+ printf("Gaim2 %s\n", VERSION);
-
- g_warning("cannot open display: %s", display ? display : "unset");
- g_free(display);
-@@ -637,48 +637,48 @@ int main(int argc, char *argv[])
- }
-
- #ifdef _WIN32
-- /** TODO: Move this to a wgaim_gtk_init() if we need such a thing */
-- wgaim_gtkspell_init();
-+ /** TODO: Move this to a wgaim2_gtk_init() if we need such a thing */
-+ wgaim2_gtkspell_init();
- #endif
-
-- gaim_core_set_ui_ops(gaim_gtk_core_get_ui_ops());
-- gaim_eventloop_set_ui_ops(gaim_gtk_eventloop_get_ui_ops());
-+ gaim2_core_set_ui_ops(gaim2_gtk_core_get_ui_ops());
-+ gaim2_eventloop_set_ui_ops(gaim2_gtk_eventloop_get_ui_ops());
-
- /*
- * Set plugin search directories. Give priority to the plugins
- * in user's home directory.
- */
-- search_path = g_build_filename(gaim_user_dir(), "plugins", NULL);
-- gaim_plugins_add_search_path(search_path);
-+ search_path = g_build_filename(gaim2_user_dir(), "plugins", NULL);
-+ gaim2_plugins_add_search_path(search_path);
- g_free(search_path);
-- gaim_plugins_add_search_path(LIBDIR);
-+ gaim2_plugins_add_search_path(LIBDIR);
-
-- if (!gaim_core_init(GAIM_GTK_UI)) {
-+ if (!gaim2_core_init(GAIM_GTK_UI)) {
- fprintf(stderr,
-- "Initialization of the Gaim core failed. Dumping core.\n"
-+ "Initialization of the Gaim2 core failed. Dumping core.\n"
- "Please report this!\n");
- abort();
- }
-
-- /* TODO: Move blist loading into gaim_blist_init() */
-- gaim_set_blist(gaim_blist_new());
-- gaim_blist_load();
--
-- /* TODO: Move prefs loading into gaim_prefs_init() */
-- gaim_prefs_load();
-- gaim_prefs_update_old();
-- gaim_gtk_prefs_update_old();
-+ /* TODO: Move blist loading into gaim2_blist_init() */
-+ gaim2_set_blist(gaim2_blist_new());
-+ gaim2_blist_load();
-+
-+ /* TODO: Move prefs loading into gaim2_prefs_init() */
-+ gaim2_prefs_load();
-+ gaim2_prefs_update_old();
-+ gaim2_gtk_prefs_update_old();
-
- /* load plugins we had when we quit */
-- gaim_plugins_load_saved("/gaim/gtk/plugins/loaded");
-+ gaim2_plugins_load_saved("/gaim2/gtk/plugins/loaded");
-
-- /* TODO: Move pounces loading into gaim_pounces_init() */
-- gaim_pounces_load();
-+ /* TODO: Move pounces loading into gaim2_pounces_init() */
-+ gaim2_pounces_load();
-
- ui_main();
-
- #ifdef USE_SM
-- gaim_gtk_session_init(argv[0], opt_session_arg, opt_config_dir_arg);
-+ gaim2_gtk_session_init(argv[0], opt_session_arg, opt_config_dir_arg);
- #endif
- if (opt_session_arg != NULL) {
- g_free(opt_session_arg);
-@@ -693,10 +693,10 @@ int main(int argc, char *argv[])
- * We want to show the blist early in the init process so the
- * user feels warm and fuzzy (not cold and prickley).
- */
-- gaim_blist_show();
-+ gaim2_blist_show();
-
-- if (gaim_prefs_get_bool("/gaim/gtk/debug/enabled"))
-- gaim_gtk_debug_window_show();
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/debug/enabled"))
-+ gaim2_gtk_debug_window_show();
-
- if (opt_login) {
- dologin_ret = dologin_named(opt_login_arg);
-@@ -709,23 +709,23 @@ int main(int argc, char *argv[])
- if (opt_nologin)
- {
- /* Set all accounts to "offline" */
-- GaimSavedStatus *saved_status;
-- saved_status = gaim_savedstatus_find(_("Default"));
-+ Gaim2SavedStatus *saved_status;
-+ saved_status = gaim2_savedstatus_find(_("Default"));
- if (saved_status == NULL)
-- saved_status = gaim_savedstatus_new(_("Default"), GAIM_STATUS_OFFLINE);
-+ saved_status = gaim2_savedstatus_new(_("Default"), GAIM_STATUS_OFFLINE);
- else
-- gaim_savedstatus_set_type(saved_status, GAIM_STATUS_OFFLINE);
-- gaim_savedstatus_activate(saved_status);
-+ gaim2_savedstatus_set_type(saved_status, GAIM_STATUS_OFFLINE);
-+ gaim2_savedstatus_activate(saved_status);
- }
- else
- {
- /* Everything is good to go--sign on already */
-- gaim_accounts_restore_previous_statuses();
-+ gaim2_accounts_restore_previous_statuses();
- }
-
-- if (gaim_accounts_get_all_active() == NULL)
-+ if (gaim2_accounts_get_all_active() == NULL)
- {
-- gaim_gtk_accounts_window_show();
-+ gaim2_gtk_accounts_window_show();
- }
-
- #ifdef HAVE_STARTUP_NOTIFICATION
-@@ -739,7 +739,7 @@ int main(int argc, char *argv[])
- #endif
-
- #ifdef _WIN32
-- wgaim_cleanup();
-+ wgaim2_cleanup();
- #endif
-
- return 0;
-diff -prNu ./src/gtkmedia.c ./src/gtkmedia.c
---- ./src/gtkmedia.c 2005-11-12 16:27:41.000000000 +0100
-+++ ./src/gtkmedia.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkmedia.h Voice and Video UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -34,52 +34,52 @@
- typedef struct {
- GtkWidget *call_pane;
- GtkWidget *bbox;
--} GaimGtkVoiceChat;
-+} Gaim2GtkVoiceChat;
-
-
--static void gaim_gtk_media_new_voice_chat(GaimVoiceChat *vc)
-+static void gaim2_gtk_media_new_voice_chat(Gaim2VoiceChat *vc)
- {
-- GaimGtkVoiceChat *gvc = g_new0(GaimGtkVoiceChat, 1);
-- gaim_voice_chat_set_ui_data(vc, gvc);
-+ Gaim2GtkVoiceChat *gvc = g_new0(Gaim2GtkVoiceChat, 1);
-+ gaim2_voice_chat_set_ui_data(vc, gvc);
-
- }
-
--static void gaim_gtk_media_destroy(GaimVoiceChat *vc)
-+static void gaim2_gtk_media_destroy(Gaim2VoiceChat *vc)
- {
-- GaimConversation *conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, gaim_connection_get_account(gaim_voice_chat_get_connection(vc)),
-- gaim_voice_chat_get_name(vc));
-- GaimGtkVoiceChat *gvc = (GaimGtkVoiceChat*)gaim_voice_chat_get_ui_data(vc);
-- gaim_conversation_write(conv, NULL, _("Call ended."), GAIM_MESSAGE_SYSTEM, time(NULL));
-+ Gaim2Conversation *conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, gaim2_connection_get_account(gaim2_voice_chat_get_connection(vc)),
-+ gaim2_voice_chat_get_name(vc));
-+ Gaim2GtkVoiceChat *gvc = (Gaim2GtkVoiceChat*)gaim2_voice_chat_get_ui_data(vc);
-+ gaim2_conversation_write(conv, NULL, _("Call ended."), GAIM_MESSAGE_SYSTEM, time(NULL));
- gtk_widget_destroy(gvc->call_pane);
- g_free(gvc);
- }
-
--static void gaim_gtk_media_state_change(GaimVoiceChat *vc, GaimMediaState state)
-+static void gaim2_gtk_media_state_change(Gaim2VoiceChat *vc, Gaim2MediaState state)
- {
-- GaimGtkVoiceChat *gvc = (GaimGtkVoiceChat*)gaim_voice_chat_get_ui_data(vc);
-- GaimConversation *conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, gaim_connection_get_account(gaim_voice_chat_get_connection(vc)),
-- gaim_voice_chat_get_name(vc));
-- GaimGtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
-+ Gaim2GtkVoiceChat *gvc = (Gaim2GtkVoiceChat*)gaim2_voice_chat_get_ui_data(vc);
-+ Gaim2Conversation *conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, gaim2_connection_get_account(gaim2_voice_chat_get_connection(vc)),
-+ gaim2_voice_chat_get_name(vc));
-+ Gaim2GtkConversation *gtkconv = GAIM_GTK_CONVERSATION(conv);
- GtkWidget *hbox, *bbox;
- GtkWidget *button;
- char *msg = NULL;
-
- switch (state) {
- case GAIM_MEDIA_STATE_CALLING:
-- msg = g_strdup_printf(_("Calling %s"), gaim_voice_chat_get_name(vc));
-- gaim_conversation_write(conv, NULL, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ msg = g_strdup_printf(_("Calling %s"), gaim2_voice_chat_get_name(vc));
-+ gaim2_conversation_write(conv, NULL, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- hbox = gtk_hbox_new(FALSE, 6);
- button = gtk_button_new_with_label(_("End Call"));
-- g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim_voice_chat_terminate), vc);
-+ g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim2_voice_chat_terminate), vc);
- gvc->call_pane = hbox;
- gtk_box_pack_end(GTK_BOX(hbox), button, FALSE, 0, 0);
- gtk_box_pack_end(GTK_BOX(gtkconv->tab_cont), hbox, FALSE, 0, 0);
- gtk_widget_show_all(hbox);
- break;
- case GAIM_MEDIA_STATE_RECEIVING:
-- msg = g_strdup_printf(_("Receiving call from %s"), gaim_voice_chat_get_name(vc));
-- gaim_conversation_write(conv, NULL, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ msg = g_strdup_printf(_("Receiving call from %s"), gaim2_voice_chat_get_name(vc));
-+ gaim2_conversation_write(conv, NULL, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- hbox = gtk_hbox_new(FALSE, 6);
- bbox = gvc->bbox = gtk_hbutton_box_new();
-@@ -87,26 +87,26 @@ static void gaim_gtk_media_state_change(
- gtk_box_set_spacing(GTK_BOX(bbox), 6);
- gtk_container_add(GTK_CONTAINER(hbox), bbox);
- button = gtk_button_new_with_label(_("Reject Call"));
-- g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim_voice_chat_reject), vc);
-+ g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim2_voice_chat_reject), vc);
- gvc->call_pane = hbox;
- gtk_box_pack_end(GTK_BOX(bbox), button, FALSE, 0, 0);
- gtk_box_pack_end(GTK_BOX(gtkconv->tab_cont), hbox, FALSE, 0, 0);
-
- button = gtk_button_new_with_label(_("Accept call"));
-- g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim_voice_chat_accept), vc);
-+ g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim2_voice_chat_accept), vc);
- gtk_box_pack_end(GTK_BOX(bbox), button, FALSE, 0, 0);
-
- gtk_widget_show_all(hbox);
- break;
- case GAIM_MEDIA_STATE_IN_PROGRESS:
-- msg = g_strdup_printf(_("Connected to %s"), gaim_voice_chat_get_name(vc));
-- gaim_conversation_write(conv, NULL, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ msg = g_strdup_printf(_("Connected to %s"), gaim2_voice_chat_get_name(vc));
-+ gaim2_conversation_write(conv, NULL, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- if (gvc->bbox) {
- gtk_widget_destroy(gvc->bbox);
- gvc->bbox = NULL;
- button = gtk_button_new_with_label(_("End Call"));
-- g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim_voice_chat_terminate), vc);
-+ g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gaim2_voice_chat_terminate), vc);
- gtk_box_pack_end(GTK_BOX(gvc->call_pane), button, FALSE, 0, 0);
- gtk_widget_show(button);
- }
-@@ -120,17 +120,17 @@ static void gaim_gtk_media_state_change(
- }
-
-
--static GaimMediaUiOps ui_ops =
-+static Gaim2MediaUiOps ui_ops =
- {
-- gaim_gtk_media_new_voice_chat,
-- gaim_gtk_media_destroy,
-- gaim_gtk_media_state_change
-+ gaim2_gtk_media_new_voice_chat,
-+ gaim2_gtk_media_destroy,
-+ gaim2_gtk_media_state_change
- };
-
--void gaim_gtk_media_init(void)
-+void gaim2_gtk_media_init(void)
- {
-- gaim_debug_info("gtkmedia","Initialising\n");
-- gaim_media_set_ui_ops(&ui_ops);
-+ gaim2_debug_info("gtkmedia","Initialising\n");
-+ gaim2_media_set_ui_ops(&ui_ops);
- }
-
- #endif /* HAVE_VV */
-diff -prNu ./src/gtkmedia.h ./src/gtkmedia.h
---- ./src/gtkmedia.h 2005-11-12 16:27:41.000000000 +0100
-+++ ./src/gtkmedia.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkmedia.h Voice and Video UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -38,7 +38,7 @@
- /**
- * Initializes the GTK+ webcam system.
- */
--void gaim_gtk_media_init(void);
-+void gaim2_gtk_media_init(void);
- /*@}*/
-
- #endif /* HAVE_VV */
-diff -prNu ./src/gtkmenutray.c ./src/gtkmenutray.c
---- ./src/gtkmenutray.c 2005-11-09 00:34:54.000000000 +0100
-+++ ./src/gtkmenutray.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -46,7 +46,7 @@ static GObjectClass *parent_class = NULL
- * Item Stuff
- *****************************************************************************/
- static void
--gaim_gtk_menu_tray_select(GtkItem *item) {
-+gaim2_gtk_menu_tray_select(GtkItem *item) {
- /* this may look like nothing, but it's really overriding the
- * GtkMenuItem's select function so that it doesn't get highlighted like
- * a normal menu item would.
-@@ -54,7 +54,7 @@ gaim_gtk_menu_tray_select(GtkItem *item)
- }
-
- static void
--gaim_gtk_menu_tray_deselect(GtkItem *item) {
-+gaim2_gtk_menu_tray_deselect(GtkItem *item) {
- /* Probably not necessary, but I'd rather be safe than sorry. We're
- * overridding the select, so it makes sense to override deselect as well.
- */
-@@ -68,14 +68,14 @@ gaim_gtk_menu_tray_deselect(GtkItem *ite
- * Object Stuff
- *****************************************************************************/
- static void
--gaim_gtk_menu_tray_get_property(GObject *obj, guint param_id, GValue *value,
-+gaim2_gtk_menu_tray_get_property(GObject *obj, guint param_id, GValue *value,
- GParamSpec *pspec)
- {
-- GaimGtkMenuTray *menu_tray = GAIM_GTK_MENU_TRAY(obj);
-+ Gaim2GtkMenuTray *menu_tray = GAIM_GTK_MENU_TRAY(obj);
-
- switch(param_id) {
- case PROP_BOX:
-- g_value_set_object(value, gaim_gtk_menu_tray_get_box(menu_tray));
-+ g_value_set_object(value, gaim2_gtk_menu_tray_get_box(menu_tray));
- break;
- default:
- G_OBJECT_WARN_INVALID_PROPERTY_ID(obj, param_id, pspec);
-@@ -84,14 +84,14 @@ gaim_gtk_menu_tray_get_property(GObject
- }
-
- static void
--gaim_gtk_menu_tray_finalize(GObject *obj) {
-+gaim2_gtk_menu_tray_finalize(GObject *obj) {
- #if 0
- /* This _might_ be leaking, but I have a sneaking suspicion that the widget is
- * getting destroyed in GtkContainer's finalize function. But if were are
- * leaking here, be sure to figure out why this causes a crash.
- * -- Gary
- */
-- GaimGtkMenuTray *tray = GAIM_GTK_MENU_TRAY(obj);
-+ Gaim2GtkMenuTray *tray = GAIM_GTK_MENU_TRAY(obj);
-
- if(GTK_IS_WIDGET(tray->tray))
- gtk_widget_destroy(GTK_WIDGET(tray->tray));
-@@ -101,18 +101,18 @@ gaim_gtk_menu_tray_finalize(GObject *obj
- }
-
- static void
--gaim_gtk_menu_tray_class_init(GaimGtkMenuTrayClass *klass) {
-+gaim2_gtk_menu_tray_class_init(Gaim2GtkMenuTrayClass *klass) {
- GObjectClass *object_class = G_OBJECT_CLASS(klass);
- GtkItemClass *item_class = GTK_ITEM_CLASS(klass);
- GParamSpec *pspec;
-
- parent_class = g_type_class_peek_parent(klass);
-
-- object_class->finalize = gaim_gtk_menu_tray_finalize;
-- object_class->get_property = gaim_gtk_menu_tray_get_property;
-+ object_class->finalize = gaim2_gtk_menu_tray_finalize;
-+ object_class->get_property = gaim2_gtk_menu_tray_get_property;
-
-- item_class->select = gaim_gtk_menu_tray_select;
-- item_class->deselect = gaim_gtk_menu_tray_deselect;
-+ item_class->select = gaim2_gtk_menu_tray_select;
-+ item_class->deselect = gaim2_gtk_menu_tray_deselect;
-
- pspec = g_param_spec_object("box", "The box",
- "The box",
-@@ -122,7 +122,7 @@ gaim_gtk_menu_tray_class_init(GaimGtkMen
- }
-
- static void
--gaim_gtk_menu_tray_init(GaimGtkMenuTray *menu_tray) {
-+gaim2_gtk_menu_tray_init(Gaim2GtkMenuTray *menu_tray) {
- GtkWidget *widget = GTK_WIDGET(menu_tray);
- #if GTK_CHECK_VERSION(2,2,0)
- GtkSettings *settings;
-@@ -158,25 +158,25 @@ gaim_gtk_menu_tray_init(GaimGtkMenuTray
- * API
- *****************************************************************************/
- GType
--gaim_gtk_menu_tray_get_gtype(void) {
-+gaim2_gtk_menu_tray_get_gtype(void) {
- static GType type = 0;
-
- if(type == 0) {
- static const GTypeInfo info = {
-- sizeof(GaimGtkMenuTrayClass),
-+ sizeof(Gaim2GtkMenuTrayClass),
- NULL,
- NULL,
-- (GClassInitFunc)gaim_gtk_menu_tray_class_init,
-+ (GClassInitFunc)gaim2_gtk_menu_tray_class_init,
- NULL,
- NULL,
-- sizeof(GaimGtkMenuTray),
-+ sizeof(Gaim2GtkMenuTray),
- 0,
-- (GInstanceInitFunc)gaim_gtk_menu_tray_init,
-+ (GInstanceInitFunc)gaim2_gtk_menu_tray_init,
- NULL
- };
-
- type = g_type_register_static(GTK_TYPE_MENU_ITEM,
-- "GaimGtkMenuTray",
-+ "Gaim2GtkMenuTray",
- &info, 0);
- }
-
-@@ -184,18 +184,18 @@ gaim_gtk_menu_tray_get_gtype(void) {
- }
-
- GtkWidget *
--gaim_gtk_menu_tray_new() {
-+gaim2_gtk_menu_tray_new() {
- return g_object_new(GAIM_GTK_TYPE_MENU_TRAY, NULL);
- }
-
- GtkWidget *
--gaim_gtk_menu_tray_get_box(GaimGtkMenuTray *menu_tray) {
-+gaim2_gtk_menu_tray_get_box(Gaim2GtkMenuTray *menu_tray) {
- g_return_val_if_fail(GAIM_GTK_IS_MENU_TRAY(menu_tray), NULL);
- return menu_tray->tray;
- }
-
- static void
--gaim_gtk_menu_tray_add(GaimGtkMenuTray *menu_tray, GtkWidget *widget,
-+gaim2_gtk_menu_tray_add(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget,
- const char *tooltip, gboolean prepend)
- {
- g_return_if_fail(GAIM_GTK_IS_MENU_TRAY(menu_tray));
-@@ -211,7 +211,7 @@ gaim_gtk_menu_tray_add(GaimGtkMenuTray *
- widget = event;
- }
-
-- gaim_gtk_menu_tray_set_tooltip(menu_tray, widget, tooltip);
-+ gaim2_gtk_menu_tray_set_tooltip(menu_tray, widget, tooltip);
-
- if (prepend)
- gtk_box_pack_start(GTK_BOX(menu_tray->tray), widget, FALSE, FALSE, 0);
-@@ -220,19 +220,19 @@ gaim_gtk_menu_tray_add(GaimGtkMenuTray *
- }
-
- void
--gaim_gtk_menu_tray_append(GaimGtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip)
-+gaim2_gtk_menu_tray_append(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip)
- {
-- gaim_gtk_menu_tray_add(menu_tray, widget, tooltip, FALSE);
-+ gaim2_gtk_menu_tray_add(menu_tray, widget, tooltip, FALSE);
- }
-
- void
--gaim_gtk_menu_tray_prepend(GaimGtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip)
-+gaim2_gtk_menu_tray_prepend(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip)
- {
-- gaim_gtk_menu_tray_add(menu_tray, widget, tooltip, TRUE);
-+ gaim2_gtk_menu_tray_add(menu_tray, widget, tooltip, TRUE);
- }
-
- void
--gaim_gtk_menu_tray_set_tooltip(GaimGtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip)
-+gaim2_gtk_menu_tray_set_tooltip(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip)
- {
- if (!menu_tray->tooltips)
- return;
-diff -prNu ./src/gtkmenutray.h ./src/gtkmenutray.h
---- ./src/gtkmenutray.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkmenutray.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,7 +2,7 @@
- * @file gtkmenutray.h GTK+ Tray menu item
- * @ingroup gtkui
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -27,53 +27,53 @@
- #include <gtk/gtkmenuitem.h>
- #include <gtk/gtktooltips.h>
-
--#define GAIM_GTK_TYPE_MENU_TRAY (gaim_gtk_menu_tray_get_gtype())
--#define GAIM_GTK_MENU_TRAY(obj) (GTK_CHECK_CAST((obj), GAIM_GTK_TYPE_MENU_TRAY, GaimGtkMenuTray))
--#define GAIM_GTK_MENU_TRAY_CLASS(klass) (GTK_CHECK_CLASS_CAST((klass), GAIM_GTK_TYPE_MENU_TRAY, GaimGtkMenuTrayClass))
-+#define GAIM_GTK_TYPE_MENU_TRAY (gaim2_gtk_menu_tray_get_gtype())
-+#define GAIM_GTK_MENU_TRAY(obj) (GTK_CHECK_CAST((obj), GAIM_GTK_TYPE_MENU_TRAY, Gaim2GtkMenuTray))
-+#define GAIM_GTK_MENU_TRAY_CLASS(klass) (GTK_CHECK_CLASS_CAST((klass), GAIM_GTK_TYPE_MENU_TRAY, Gaim2GtkMenuTrayClass))
- #define GAIM_GTK_IS_MENU_TRAY(obj) (GTK_CHECK_TYPE((obj), GAIM_GTK_TYPE_MENU_TRAY))
- #define GAIM_GTK_IS_MENU_TRAY_CLASS(klass) (GTK_CHECK_CLASS_TYPE((klass), GAIM_GTK_TYPE_MENU_TRAY))
--#define GAIM_GTK_MENU_TRAY_GET_CLASS(obj) (GTK_CHECK_GET_CLASS((obj), GAIM_GTK_TYPE_MENU_TRAY, GaimGtkMenuTrayClass))
-+#define GAIM_GTK_MENU_TRAY_GET_CLASS(obj) (GTK_CHECK_GET_CLASS((obj), GAIM_GTK_TYPE_MENU_TRAY, Gaim2GtkMenuTrayClass))
-
--typedef struct _GaimGtkMenuTray GaimGtkMenuTray;
--typedef struct _GaimGtkMenuTrayClass GaimGtkMenuTrayClass;
-+typedef struct _Gaim2GtkMenuTray Gaim2GtkMenuTray;
-+typedef struct _Gaim2GtkMenuTrayClass Gaim2GtkMenuTrayClass;
-
--/** A GaimGtkMenuTray */
--struct _GaimGtkMenuTray {
-+/** A Gaim2GtkMenuTray */
-+struct _Gaim2GtkMenuTray {
- GtkMenuItem gparent; /**< The parent instance */
- GtkWidget *tray; /**< The tray */
- GtkTooltips *tooltips; /**< Tooltips */
- };
-
--/** A GaimGtkMenuTrayClass */
--struct _GaimGtkMenuTrayClass {
-+/** A Gaim2GtkMenuTrayClass */
-+struct _Gaim2GtkMenuTrayClass {
- GtkMenuItemClass gparent; /**< The parent class */
- };
-
- G_BEGIN_DECLS
-
- /**
-- * Registers the GaimGtkMenuTray class if necessary and returns the
-+ * Registers the Gaim2GtkMenuTray class if necessary and returns the
- * type ID assigned to it.
- *
-- * @return The GaimGtkMenuTray type ID
-+ * @return The Gaim2GtkMenuTray type ID
- */
--GType gaim_gtk_menu_tray_get_gtype(void);
-+GType gaim2_gtk_menu_tray_get_gtype(void);
-
- /**
-- * Creates a new GaimGtkMenuTray
-+ * Creates a new Gaim2GtkMenuTray
- *
-- * @return A new GaimGtkMenuTray
-+ * @return A new Gaim2GtkMenuTray
- */
--GtkWidget *gaim_gtk_menu_tray_new(void);
-+GtkWidget *gaim2_gtk_menu_tray_new(void);
-
- /**
-- * Gets the box for the GaimGtkMenuTray
-+ * Gets the box for the Gaim2GtkMenuTray
- *
-- * @param menu_tray The GaimGtkMenuTray
-+ * @param menu_tray The Gaim2GtkMenuTray
- *
- * @return The box that this menu tray is using
- */
--GtkWidget *gaim_gtk_menu_tray_get_box(GaimGtkMenuTray *menu_tray);
-+GtkWidget *gaim2_gtk_menu_tray_get_box(Gaim2GtkMenuTray *menu_tray);
-
- /**
- * Appends a widget into the tray
-@@ -82,7 +82,7 @@ GtkWidget *gaim_gtk_menu_tray_get_box(Ga
- * @param widget The widget
- * @param tooltip The tooltip for this widget (widget requires its own X-window)
- */
--void gaim_gtk_menu_tray_append(GaimGtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip);
-+void gaim2_gtk_menu_tray_append(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip);
-
- /**
- * Prepends a widget into the tray
-@@ -91,7 +91,7 @@ void gaim_gtk_menu_tray_append(GaimGtkMe
- * @param widget The widget
- * @param tooltip The tooltip for this widget (widget requires its own X-window)
- */
--void gaim_gtk_menu_tray_prepend(GaimGtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip);
-+void gaim2_gtk_menu_tray_prepend(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip);
-
- /**
- * Set the tooltip for a widget
-@@ -100,7 +100,7 @@ void gaim_gtk_menu_tray_prepend(GaimGtkM
- * @param widget The widget
- * @param tooltip The tooltip to set for the widget (widget requires its own X-window)
- */
--void gaim_gtk_menu_tray_set_tooltip(GaimGtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip);
-+void gaim2_gtk_menu_tray_set_tooltip(Gaim2GtkMenuTray *menu_tray, GtkWidget *widget, const char *tooltip);
-
- G_END_DECLS
-
-diff -prNu ./src/gtknickcolors.h ./src/gtknickcolors.h
---- ./src/gtknickcolors.h 2005-12-05 22:46:47.000000000 +0100
-+++ ./src/gtknickcolors.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,8 +2,8 @@
- * @file gtknickcolors.h GTK+ Conversation API
- * @ingroup gtkui
- *
-- * gaim
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * gaim2
-+ * Gaim2 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.
- *
-diff -prNu ./src/gtknotify.c ./src/gtknotify.c
---- ./src/gtknotify.c 2005-12-23 22:10:24.000000000 +0100
-+++ ./src/gtknotify.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtknotify.c GTK+ Notification API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include <gdk/gdkkeysyms.h>
-
-@@ -40,26 +40,26 @@
-
- typedef struct
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *url;
- GtkWidget *label;
- GtkTreeIter iter;
--} GaimNotifyMailData;
-+} Gaim2NotifyMailData;
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GtkListStore *model;
- GtkWidget *treeview;
- GtkWidget *window;
--} GaimNotifySearchResultsData;
-+} Gaim2NotifySearchResultsData;
-
- typedef struct
- {
-- GaimNotifySearchButton *button;
-- GaimNotifySearchResultsData *data;
-+ Gaim2NotifySearchButton *button;
-+ Gaim2NotifySearchResultsData *data;
-
--} GaimNotifySearchResultsButtonData;
-+} Gaim2NotifySearchResultsButtonData;
-
- enum
- {
-@@ -71,9 +71,9 @@ enum
- COLUMNS_GAIM_MAIL
- };
-
--typedef struct _GaimMailDialog GaimMailDialog;
-+typedef struct _Gaim2MailDialog Gaim2MailDialog;
-
--struct _GaimMailDialog
-+struct _Gaim2MailDialog
- {
- GtkWidget *dialog;
- GtkWidget *treeview;
-@@ -81,9 +81,9 @@ struct _GaimMailDialog
- GtkLabel *label;
- };
-
--static GaimMailDialog *mail_dialog = NULL;
-+static Gaim2MailDialog *mail_dialog = NULL;
-
--static void *gaim_gtk_notify_emails(GaimConnection *gc, size_t count, gboolean detailed,
-+static void *gaim2_gtk_notify_emails(Gaim2Connection *gc, size_t count, gboolean detailed,
- const char **subjects,
- const char **froms, const char **tos,
- const char **urls);
-@@ -91,22 +91,22 @@ static void *gaim_gtk_notify_emails(Gaim
- static void
- message_response_cb(GtkDialog *dialog, gint id, GtkWidget *widget)
- {
-- gaim_notify_close(GAIM_NOTIFY_MESSAGE, widget);
-+ gaim2_notify_close(GAIM_NOTIFY_MESSAGE, widget);
- }
-
- static void
--email_nondetailed_cb(GtkDialog *dialog, gint id, GaimNotifyMailData *data)
-+email_nondetailed_cb(GtkDialog *dialog, gint id, Gaim2NotifyMailData *data)
- {
- if (id == GTK_RESPONSE_OK)
-- gaim_notify_uri(NULL, data->url);
-- gaim_notify_close(GAIM_NOTIFY_EMAILS, data);
-+ gaim2_notify_uri(NULL, data->url);
-+ gaim2_notify_close(GAIM_NOTIFY_EMAILS, data);
- gtk_widget_destroy(GTK_WIDGET(dialog));
- }
-
- static void
--email_response_cb(GtkDialog *dlg, gint id, GaimMailDialog *dialog)
-+email_response_cb(GtkDialog *dlg, gint id, Gaim2MailDialog *dialog)
- {
-- GaimNotifyMailData *data = NULL;
-+ Gaim2NotifyMailData *data = NULL;
- GtkTreeIter iter;
-
- if (id == GTK_RESPONSE_YES)
-@@ -119,10 +119,10 @@ email_response_cb(GtkDialog *dlg, gint i
- {
- gtk_tree_model_get(GTK_TREE_MODEL(dialog->treemodel), &iter,
- GAIM_MAIL_DATA, &data, -1);
-- gaim_notify_uri(NULL, data->url);
-+ gaim2_notify_uri(NULL, data->url);
-
- gtk_tree_store_remove(dialog->treemodel, &iter);
-- gaim_notify_close(GAIM_NOTIFY_EMAILS, data);
-+ gaim2_notify_close(GAIM_NOTIFY_EMAILS, data);
-
- if (gtk_tree_model_get_iter_first(GTK_TREE_MODEL(mail_dialog->treemodel), &iter))
- return;
-@@ -138,10 +138,10 @@ email_response_cb(GtkDialog *dlg, gint i
- GAIM_MAIL_DATA, &data, -1);
-
- if (id == GTK_RESPONSE_ACCEPT)
-- gaim_notify_uri(NULL, data->url);
-+ gaim2_notify_uri(NULL, data->url);
-
- gtk_tree_store_remove(dialog->treemodel, &iter);
-- gaim_notify_close(GAIM_NOTIFY_EMAILS, data);
-+ gaim2_notify_close(GAIM_NOTIFY_EMAILS, data);
- }
- }
- gtk_widget_destroy(dialog->dialog);
-@@ -152,24 +152,24 @@ email_response_cb(GtkDialog *dlg, gint i
- static void
- formatted_close_cb(GtkWidget *win, GdkEvent *event, void *user_data)
- {
-- gaim_notify_close(GAIM_NOTIFY_FORMATTED, win);
-+ gaim2_notify_close(GAIM_NOTIFY_FORMATTED, win);
- }
-
- static void
--searchresults_close_cb(GaimNotifySearchResultsData *data, GdkEvent *event, void *user_data)
-+searchresults_close_cb(Gaim2NotifySearchResultsData *data, GdkEvent *event, void *user_data)
- {
-- gaim_notify_close(GAIM_NOTIFY_SEARCHRESULTS, data);
-+ gaim2_notify_close(GAIM_NOTIFY_SEARCHRESULTS, data);
- }
-
- static void
--searchresults_callback_wrapper_cb(GtkWidget *widget, GaimNotifySearchResultsButtonData *bd)
-+searchresults_callback_wrapper_cb(GtkWidget *widget, Gaim2NotifySearchResultsButtonData *bd)
- {
-- GaimNotifySearchResultsData *data = bd->data;
-+ Gaim2NotifySearchResultsData *data = bd->data;
-
- GtkTreeSelection *selection;
- GtkTreeModel *model;
- GtkTreeIter iter;
-- GaimNotifySearchButton *button;
-+ Gaim2NotifySearchButton *button;
- GList *row = NULL;
- gchar *str;
- int i;
-@@ -187,11 +187,11 @@ searchresults_callback_wrapper_cb(GtkWid
- }
-
- button = bd->button;
-- button->callback(gaim_account_get_connection(data->account), row);
-+ button->callback(gaim2_account_get_connection(data->account), row);
- }
-
- static void *
--gaim_gtk_notify_message(GaimNotifyMsgType type, const char *title,
-+gaim2_gtk_notify_message(Gaim2NotifyMsgType type, const char *title,
- const char *primary, const char *secondary)
- {
- GtkWidget *dialog;
-@@ -269,10 +269,10 @@ gaim_gtk_notify_message(GaimNotifyMsgTyp
- }
-
- static void *
--gaim_gtk_notify_email(GaimConnection *gc, const char *subject, const char *from,
-+gaim2_gtk_notify_email(Gaim2Connection *gc, const char *subject, const char *from,
- const char *to, const char *url)
- {
-- return gaim_gtk_notify_emails(gc, 1, (subject != NULL),
-+ return gaim2_gtk_notify_emails(gc, 1, (subject != NULL),
- (subject == NULL ? NULL : &subject),
- (from == NULL ? NULL : &from),
- (to == NULL ? NULL : &to),
-@@ -280,11 +280,11 @@ gaim_gtk_notify_email(GaimConnection *gc
- }
-
- static void *
--gaim_gtk_notify_emails(GaimConnection *gc, size_t count, gboolean detailed,
-+gaim2_gtk_notify_emails(Gaim2Connection *gc, size_t count, gboolean detailed,
- const char **subjects, const char **froms,
- const char **tos, const char **urls)
- {
-- GaimNotifyMailData *data = NULL;
-+ Gaim2NotifyMailData *data = NULL;
- GtkWidget *dialog;
- GtkWidget *vbox;
- GtkWidget *hbox;
-@@ -293,9 +293,9 @@ gaim_gtk_notify_emails(GaimConnection *g
- char *detail_text;
- char *label_text;
- GtkTreeIter iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- if (mail_dialog == NULL || !detailed)
- {
-@@ -356,7 +356,7 @@ gaim_gtk_notify_emails(GaimConnection *g
- gtk_scrolled_window_set_shadow_type (GTK_SCROLLED_WINDOW(sw), GTK_SHADOW_IN);
- gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw), GTK_POLICY_AUTOMATIC, GTK_POLICY_ALWAYS);
-
-- mail_dialog = g_new0(GaimMailDialog, 1);
-+ mail_dialog = g_new0(Gaim2MailDialog, 1);
- mail_dialog->dialog = dialog;
-
- mail_dialog->treemodel = gtk_tree_store_new(COLUMNS_GAIM_MAIL,
-@@ -418,10 +418,10 @@ gaim_gtk_notify_emails(GaimConnection *g
- if (subjects != NULL)
- subject_text = g_markup_escape_text(*subjects, -1);
-
-- data = g_new0(GaimNotifyMailData, 1);
-+ data = g_new0(Gaim2NotifyMailData, 1);
- data->url = g_strdup(*urls);
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
- if (pixbuf != NULL)
- {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
-@@ -446,7 +446,7 @@ gaim_gtk_notify_emails(GaimConnection *g
- }
- else
- {
-- data = g_new0(GaimNotifyMailData, 1);
-+ data = g_new0(Gaim2NotifyMailData, 1);
- data->url = g_strdup(*urls);
-
- g_signal_connect(G_OBJECT(dialog), "response",
-@@ -481,7 +481,7 @@ formatted_input_cb(GtkWidget *win, GdkEv
- {
- if (event->keyval == GDK_Escape)
- {
-- gaim_notify_close(GAIM_NOTIFY_FORMATTED, win);
-+ gaim2_notify_close(GAIM_NOTIFY_FORMATTED, win);
-
- return TRUE;
- }
-@@ -490,7 +490,7 @@ formatted_input_cb(GtkWidget *win, GdkEv
- }
-
- static void *
--gaim_gtk_notify_formatted(const char *title, const char *primary,
-+gaim2_gtk_notify_formatted(const char *title, const char *primary,
- const char *secondary, const char *text)
- {
- GtkWidget *window;
-@@ -536,8 +536,8 @@ gaim_gtk_notify_formatted(const char *ti
- gtk_widget_show(label);
-
- /* Add the imhtml */
-- frame = gaim_gtk_create_imhtml(FALSE, &imhtml, NULL);
-- gtk_widget_set_name(imhtml, "gaim_gtknotify_imhtml");
-+ frame = gaim2_gtk_create_imhtml(FALSE, &imhtml, NULL);
-+ gtk_widget_set_name(imhtml, "gaim2_gtknotify_imhtml");
- gtk_imhtml_set_format_functions(GTK_IMHTML(imhtml),
- gtk_imhtml_get_format_functions(GTK_IMHTML(imhtml)) | GTK_IMHTML_IMAGE);
- gtk_widget_set_size_request(imhtml, 300, 250);
-@@ -555,7 +555,7 @@ gaim_gtk_notify_formatted(const char *ti
- G_CALLBACK(formatted_input_cb), NULL);
-
- /* Add the text to the gtkimhtml */
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/show_incoming_formatting"))
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/show_incoming_formatting"))
- options |= GTK_IMHTML_NO_COLOURS | GTK_IMHTML_NO_FONTS | GTK_IMHTML_NO_SIZES;
-
- options |= GTK_IMHTML_NO_COMMENTS;
-@@ -564,7 +564,7 @@ gaim_gtk_notify_formatted(const char *ti
- options |= GTK_IMHTML_NO_SCROLL;
-
- /* Make sure URLs are clickable */
-- linked_text = gaim_markup_linkify(text);
-+ linked_text = gaim2_markup_linkify(text);
- gtk_imhtml_append_text(GTK_IMHTML(imhtml), linked_text, options);
- g_free(linked_text);
-
-@@ -575,10 +575,10 @@ gaim_gtk_notify_formatted(const char *ti
- }
-
- static void
--gaim_gtk_notify_searchresults_new_rows(GaimConnection *gc, GaimNotifySearchResults *results,
-+gaim2_gtk_notify_searchresults_new_rows(Gaim2Connection *gc, Gaim2NotifySearchResults *results,
- void *data_, gpointer user_data)
- {
-- GaimNotifySearchResultsData *data = data_;
-+ Gaim2NotifySearchResultsData *data = data_;
- GtkListStore *model = data->model;
- GtkTreeIter iter;
- GdkPixbuf *icon, *scaled;
-@@ -588,14 +588,14 @@ gaim_gtk_notify_searchresults_new_rows(G
-
- gtk_list_store_clear(data->model);
-
-- icon = gaim_gtk_create_prpl_icon(gaim_connection_get_account(gc));
-+ icon = gaim2_gtk_create_prpl_icon(gaim2_connection_get_account(gc));
- scaled = gdk_pixbuf_scale_simple(icon, 16, 16, GDK_INTERP_BILINEAR);
-
- /* +1 is for the automagically created Status column. */
-- col_num = gaim_notify_searchresults_get_columns_count(results) + 1;
-+ col_num = gaim2_notify_searchresults_get_columns_count(results) + 1;
-
-- for (i = 0; i < gaim_notify_searchresults_get_rows_count(results); i++) {
-- GList *row = gaim_notify_searchresults_row_get(results, i);
-+ for (i = 0; i < gaim2_notify_searchresults_get_rows_count(results); i++) {
-+ GList *row = gaim2_notify_searchresults_row_get(results, i);
-
- gtk_list_store_append(model, &iter);
- gtk_list_store_set(model, &iter, 0, scaled, -1);
-@@ -614,9 +614,9 @@ gaim_gtk_notify_searchresults_new_rows(G
- }
-
- static void *
--gaim_gtk_notify_searchresults(GaimConnection *gc, const char *title,
-+gaim2_gtk_notify_searchresults(Gaim2Connection *gc, const char *title,
- const char *primary, const char *secondary,
-- GaimNotifySearchResults *results)
-+ Gaim2NotifySearchResults *results)
- {
- GtkWidget *window;
- GtkWidget *treeview;
-@@ -631,14 +631,14 @@ gaim_gtk_notify_searchresults(GaimConnec
- GtkWidget *button_area;
- GtkWidget *label;
- GtkWidget *sw;
-- GaimNotifySearchResultsData *data;
-+ Gaim2NotifySearchResultsData *data;
- char *label_text;
- char *primary_esc, *secondary_esc;
-
- g_return_val_if_fail(gc != NULL, NULL);
- g_return_val_if_fail(results != NULL, NULL);
-
-- data = g_malloc(sizeof(GaimNotifySearchResultsData));
-+ data = g_malloc(sizeof(Gaim2NotifySearchResultsData));
-
- /* Create the window */
- window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
-@@ -673,7 +673,7 @@ gaim_gtk_notify_searchresults(GaimConnec
- g_free(label_text);
-
- /* +1 is for the automagically created Status column. */
-- col_num = gaim_notify_searchresults_get_columns_count(results) + 1;
-+ col_num = gaim2_notify_searchresults_get_columns_count(results) + 1;
-
- /* Setup the list model */
- col_types = g_new0(GType, col_num);
-@@ -712,7 +712,7 @@ gaim_gtk_notify_searchresults(GaimConnec
- renderer = gtk_cell_renderer_text_new();
-
- gtk_tree_view_insert_column_with_attributes(GTK_TREE_VIEW(treeview), -1,
-- gaim_notify_searchresults_column_get_title(results, i-1),
-+ gaim2_notify_searchresults_column_get_title(results, i-1),
- renderer, "text", i, NULL);
- }
-
-@@ -724,14 +724,14 @@ gaim_gtk_notify_searchresults(GaimConnec
- gtk_widget_show(button_area);
-
- for (i = 0; i < g_list_length(results->buttons); i++) {
-- GaimNotifySearchButton *b = g_list_nth_data(results->buttons, i);
-+ Gaim2NotifySearchButton *b = g_list_nth_data(results->buttons, i);
- GtkWidget *button = NULL;
- switch (b->type) {
- case GAIM_NOTIFY_BUTTON_LABELED:
- if(b->label) {
- button = gtk_button_new_with_label(b->label);
- } else {
-- gaim_debug_warning("gtknotify", "Missing button label");
-+ gaim2_debug_warning("gtknotify", "Missing button label");
- }
- break;
- case GAIM_NOTIFY_BUTTON_CONTINUE:
-@@ -753,15 +753,15 @@ gaim_gtk_notify_searchresults(GaimConnec
- button = gtk_button_new_from_stock(GAIM_STOCK_INVITE);
- break;
- default:
-- gaim_debug_warning("gtknotify", "Incorrect button type: %d\n", b->type);
-+ gaim2_debug_warning("gtknotify", "Incorrect button type: %d\n", b->type);
- }
- if (button != NULL) {
-- GaimNotifySearchResultsButtonData *bd;
-+ Gaim2NotifySearchResultsButtonData *bd;
-
- gtk_box_pack_start(GTK_BOX(button_area), button, FALSE, FALSE, 0);
- gtk_widget_show(button);
-
-- bd = g_new0(GaimNotifySearchResultsButtonData, 1);
-+ bd = g_new0(Gaim2NotifySearchResultsButtonData, 1);
- bd->button = b;
- bd->data = data;
-
-@@ -784,7 +784,7 @@ gaim_gtk_notify_searchresults(GaimConnec
- data->window = window;
-
- /* Insert rows. */
-- gaim_gtk_notify_searchresults_new_rows(gc, results, data, NULL);
-+ gaim2_gtk_notify_searchresults_new_rows(gc, results, data, NULL);
-
- /* Show the window */
- gtk_widget_show(window);
-@@ -792,31 +792,31 @@ gaim_gtk_notify_searchresults(GaimConnec
- }
-
- static void *
--gaim_gtk_notify_userinfo(GaimConnection *gc, const char *who,
-+gaim2_gtk_notify_userinfo(Gaim2Connection *gc, const char *who,
- const char *text)
- {
- char *primary;
- void *ui_handle;
-
- primary = g_strdup_printf(_("Info for %s"), who);
-- ui_handle = gaim_gtk_notify_formatted(_("Buddy Information"), primary, NULL, text);
-+ ui_handle = gaim2_gtk_notify_formatted(_("Buddy Information"), primary, NULL, text);
- g_free(primary);
- return ui_handle;
- }
-
- static void
--gaim_gtk_close_notify(GaimNotifyType type, void *ui_handle)
-+gaim2_gtk_close_notify(Gaim2NotifyType type, void *ui_handle)
- {
- if (type == GAIM_NOTIFY_EMAIL || type == GAIM_NOTIFY_EMAILS)
- {
-- GaimNotifyMailData *data = (GaimNotifyMailData *)ui_handle;
-+ Gaim2NotifyMailData *data = (Gaim2NotifyMailData *)ui_handle;
-
- g_free(data->url);
- g_free(data);
- }
- else if (type == GAIM_NOTIFY_SEARCHRESULTS)
- {
-- GaimNotifySearchResultsData *data = (GaimNotifySearchResultsData *)ui_handle;
-+ Gaim2NotifySearchResultsData *data = (Gaim2NotifySearchResultsData *)ui_handle;
-
- gtk_widget_destroy(data->window);
-
-@@ -835,13 +835,13 @@ uri_command(const char *command, gboolea
- gint ret = 0;
-
- escaped = g_markup_escape_text(command, -1);
-- gaim_debug_misc("gtknotify", "Executing %s\n", escaped);
-+ gaim2_debug_misc("gtknotify", "Executing %s\n", escaped);
-
-- if (!gaim_program_is_valid(command))
-+ if (!gaim2_program_is_valid(command))
- {
- tmp = g_strdup_printf(_("The browser command <b>%s</b> is invalid."),
- escaped ? escaped : "(none)");
-- gaim_notify_error(NULL, NULL, _("Unable to open URL"), tmp);
-+ gaim2_notify_error(NULL, NULL, _("Unable to open URL"), tmp);
- g_free(tmp);
-
- }
-@@ -853,7 +853,7 @@ uri_command(const char *command, gboolea
- {
- tmp = g_strdup_printf(_("Error launching <b>%s</b>: %s"),
- escaped, error->message);
-- gaim_notify_error(NULL, NULL, _("Unable to open URL"), tmp);
-+ gaim2_notify_error(NULL, NULL, _("Unable to open URL"), tmp);
- g_free(tmp);
- g_error_free(error);
- }
-@@ -866,7 +866,7 @@ uri_command(const char *command, gboolea
- {
- tmp = g_strdup_printf(_("Error launching <b>%s</b>: %s"),
- escaped, error->message);
-- gaim_notify_error(NULL, NULL, _("Unable to open URL"), tmp);
-+ gaim2_notify_error(NULL, NULL, _("Unable to open URL"), tmp);
- g_free(tmp);
- g_error_free(error);
- }
-@@ -879,7 +879,7 @@ uri_command(const char *command, gboolea
- #endif /* _WIN32 */
-
- static void *
--gaim_gtk_notify_uri(const char *uri)
-+gaim2_gtk_notify_uri(const char *uri)
- {
- #ifndef _WIN32
- char *escaped = g_shell_quote(uri);
-@@ -888,11 +888,11 @@ gaim_gtk_notify_uri(const char *uri)
- const char *web_browser;
- int place;
-
-- web_browser = gaim_prefs_get_string("/gaim/gtk/browsers/browser");
-- place = gaim_prefs_get_int("/gaim/gtk/browsers/place");
-+ web_browser = gaim2_prefs_get_string("/gaim2/gtk/browsers/browser");
-+ place = gaim2_prefs_get_int("/gaim2/gtk/browsers/place");
-
- /* if they are running gnome, use the gnome web browser */
-- if (gaim_running_gnome() == TRUE)
-+ if (gaim2_running_gnome() == TRUE)
- {
- command = g_strdup_printf("gnome-open %s", escaped);
- }
-@@ -987,18 +987,18 @@ gaim_gtk_notify_uri(const char *uri)
- {
- const char *web_command;
-
-- web_command = gaim_prefs_get_string("/gaim/gtk/browsers/command");
-+ web_command = gaim2_prefs_get_string("/gaim2/gtk/browsers/command");
-
- if (web_command == NULL || *web_command == '\0')
- {
-- gaim_notify_error(NULL, NULL, _("Unable to open URL"),
-+ gaim2_notify_error(NULL, NULL, _("Unable to open URL"),
- _("The 'Manual' browser command has been "
- "chosen, but no command has been set."));
- return NULL;
- }
-
- if (strstr(web_command, "%s"))
-- command = gaim_strreplace(web_command, "%s", escaped);
-+ command = gaim2_strreplace(web_command, "%s", escaped);
- else
- {
- /*
-@@ -1026,27 +1026,27 @@ gaim_gtk_notify_uri(const char *uri)
- g_free(command);
-
- #else /* !_WIN32 */
-- wgaim_notify_uri(uri);
-+ wgaim2_notify_uri(uri);
- #endif /* !_WIN32 */
-
- return NULL;
- }
-
--static GaimNotifyUiOps ops =
-+static Gaim2NotifyUiOps ops =
- {
-- gaim_gtk_notify_message,
-- gaim_gtk_notify_email,
-- gaim_gtk_notify_emails,
-- gaim_gtk_notify_formatted,
-- gaim_gtk_notify_searchresults,
-- gaim_gtk_notify_searchresults_new_rows,
-- gaim_gtk_notify_userinfo,
-- gaim_gtk_notify_uri,
-- gaim_gtk_close_notify
-+ gaim2_gtk_notify_message,
-+ gaim2_gtk_notify_email,
-+ gaim2_gtk_notify_emails,
-+ gaim2_gtk_notify_formatted,
-+ gaim2_gtk_notify_searchresults,
-+ gaim2_gtk_notify_searchresults_new_rows,
-+ gaim2_gtk_notify_userinfo,
-+ gaim2_gtk_notify_uri,
-+ gaim2_gtk_close_notify
- };
-
--GaimNotifyUiOps *
--gaim_gtk_notify_get_ui_ops(void)
-+Gaim2NotifyUiOps *
-+gaim2_gtk_notify_get_ui_ops(void)
- {
- return &ops;
- }
-diff -prNu ./src/gtknotify.h ./src/gtknotify.h
---- ./src/gtknotify.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gtknotify.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtknotify.h GTK+ Notification API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,6 +32,6 @@
- *
- * @return The GTK+ UI notify operations structure.
- */
--GaimNotifyUiOps *gaim_gtk_notify_get_ui_ops(void);
-+Gaim2NotifyUiOps *gaim2_gtk_notify_get_ui_ops(void);
-
- #endif /* _GAIM_GTKNOTIFY_H_ */
-diff -prNu ./src/gtkplugin.c ./src/gtkplugin.c
---- ./src/gtkplugin.c 2006-01-03 22:23:11.000000000 +0100
-+++ ./src/gtkplugin.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkplugin.c GTK+ Plugins support
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkplugin.h"
- #include "gtkpluginpref.h"
- #include "debug.h"
-@@ -40,7 +40,7 @@ static GtkWidget *pref_button = NULL;
- static GHashTable *plugin_pref_dialogs = NULL;
-
- GtkWidget *
--gaim_gtk_plugin_get_config_frame(GaimPlugin *plugin)
-+gaim2_gtk_plugin_get_config_frame(Gaim2Plugin *plugin)
- {
- GtkWidget *config = NULL;
-
-@@ -49,7 +49,7 @@ gaim_gtk_plugin_get_config_frame(GaimPlu
- if (GAIM_IS_GTK_PLUGIN(plugin) && plugin->info->ui_info
- && GAIM_GTK_PLUGIN_UI_INFO(plugin)->get_config_frame)
- {
-- GaimGtkPluginUiInfo *ui_info;
-+ Gaim2GtkPluginUiInfo *ui_info;
-
- ui_info = GAIM_GTK_PLUGIN_UI_INFO(plugin);
-
-@@ -58,7 +58,7 @@ gaim_gtk_plugin_get_config_frame(GaimPlu
- if (plugin->info->prefs_info
- && plugin->info->prefs_info->get_plugin_pref_frame)
- {
-- gaim_debug_warning("gtkplugin",
-+ gaim2_debug_warning("gtkplugin",
- "Plugin %s contains both, ui_info and "
- "prefs_info preferences; prefs_info will be "
- "ignored.", plugin->info->name);
-@@ -68,24 +68,24 @@ gaim_gtk_plugin_get_config_frame(GaimPlu
- if (config == NULL && plugin->info->prefs_info
- && plugin->info->prefs_info->get_plugin_pref_frame)
- {
-- GaimPluginPrefFrame *frame;
-+ Gaim2PluginPrefFrame *frame;
-
- frame = plugin->info->prefs_info->get_plugin_pref_frame(plugin);
-
-- config = gaim_gtk_plugin_pref_create_frame(frame);
-+ config = gaim2_gtk_plugin_pref_create_frame(frame);
- }
-
- return config;
- }
-
- void
--gaim_gtk_plugins_save(void)
-+gaim2_gtk_plugins_save(void)
- {
- GList *pl;
- GList *files = NULL;
-- GaimPlugin *p;
-+ Gaim2Plugin *p;
-
-- for (pl = gaim_plugins_get_loaded(); pl != NULL; pl = pl->next) {
-+ for (pl = gaim2_plugins_get_loaded(); pl != NULL; pl = pl->next) {
- p = pl->data;
-
- if (p->info->type != GAIM_PLUGIN_PROTOCOL &&
-@@ -95,7 +95,7 @@ gaim_gtk_plugins_save(void)
- }
- }
-
-- gaim_prefs_set_string_list("/gaim/gtk/plugins/loaded", files);
-+ gaim2_prefs_set_string_list("/gaim2/gtk/plugins/loaded", files);
- g_list_free(files);
- }
-
-@@ -105,12 +105,12 @@ update_plugin_list(void *data)
- GtkListStore *ls = GTK_LIST_STORE(data);
- GtkTreeIter iter;
- GList *probes;
-- GaimPlugin *plug;
-+ Gaim2Plugin *plug;
-
- gtk_list_store_clear(ls);
-- gaim_plugins_probe(G_MODULE_SUFFIX);
-+ gaim2_plugins_probe(G_MODULE_SUFFIX);
-
-- for (probes = gaim_plugins_get_all();
-+ for (probes = gaim2_plugins_get_all();
- probes != NULL;
- probes = probes->next)
- {
-@@ -140,16 +140,16 @@ update_plugin_list(void *data)
- g_free(summary);
-
- gtk_list_store_set(ls, &iter,
-- 0, gaim_plugin_is_loaded(plug),
-+ 0, gaim2_plugin_is_loaded(plug),
- 1, desc,
- 2, plug,
-- 3, gaim_plugin_is_unloadable(plug),
-+ 3, gaim2_plugin_is_unloadable(plug),
- -1);
- g_free(desc);
- }
- }
-
--static void pref_dialog_response_cb(GtkWidget *d, int response, GaimPlugin *plug)
-+static void pref_dialog_response_cb(GtkWidget *d, int response, Gaim2Plugin *plug)
- {
- switch (response) {
- case GTK_RESPONSE_CLOSE:
-@@ -169,7 +169,7 @@ static void plugin_load (GtkCellRenderer
- GtkTreeModel *model = (GtkTreeModel *)data;
- GtkTreeIter iter;
- GtkTreePath *path = gtk_tree_path_new_from_string(pth);
-- GaimPlugin *plug;
-+ Gaim2Plugin *plug;
- gchar buf[1024];
- gchar *name = NULL, *description = NULL;
- GtkWidget *dialog = NULL;
-@@ -179,24 +179,24 @@ static void plugin_load (GtkCellRenderer
- gtk_tree_model_get (model, &iter, 2, &plug, -1);
-
- /* Apparently, GTK+ won't honor the sensitive flag on cell renderers for booleans. */
-- if (gaim_plugin_is_unloadable(plug))
-+ if (gaim2_plugin_is_unloadable(plug))
- return;
-
- wait = gdk_cursor_new (GDK_WATCH);
- gdk_window_set_cursor(plugin_dialog->window, wait);
- gdk_cursor_unref(wait);
-
-- if (!gaim_plugin_is_loaded(plug))
-- gaim_plugin_load(plug);
-+ if (!gaim2_plugin_is_loaded(plug))
-+ gaim2_plugin_load(plug);
- else {
- if (plugin_pref_dialogs != NULL &&
- (dialog = g_hash_table_lookup(plugin_pref_dialogs, plug)))
- pref_dialog_response_cb(dialog, GTK_RESPONSE_DELETE_EVENT, plug);
-- gaim_plugin_unload(plug);
-+ gaim2_plugin_unload(plug);
- }
-
- gtk_widget_set_sensitive(pref_button,
-- gaim_plugin_is_loaded(plug)
-+ gaim2_plugin_is_loaded(plug)
- && ((GAIM_IS_GTK_PLUGIN(plug) && plug->info->ui_info
- && GAIM_GTK_PLUGIN_UI_INFO(plug)->get_config_frame)
- || (plug->info->prefs_info
-@@ -229,11 +229,11 @@ static void plugin_load (GtkCellRenderer
-
-
- gtk_list_store_set (GTK_LIST_STORE (model), &iter,
-- 0, gaim_plugin_is_loaded(plug),
-+ 0, gaim2_plugin_is_loaded(plug),
- -1);
-
- gtk_tree_path_free(path);
-- gaim_gtk_plugins_save();
-+ gaim2_gtk_plugins_save();
- }
-
- static gboolean ensure_plugin_visible(void *data)
-@@ -256,7 +256,7 @@ static void prefs_plugin_sel (GtkTreeSel
- gchar *buf, *pname, *pdesc, *pauth, *pweb;
- GtkTreeIter iter;
- GValue val;
-- GaimPlugin *plug;
-+ Gaim2Plugin *plug;
-
- if (!gtk_tree_selection_get_selected (sel, &model, &iter))
- {
-@@ -306,7 +306,7 @@ static void prefs_plugin_sel (GtkTreeSel
- }
-
- gtk_widget_set_sensitive(pref_button,
-- gaim_plugin_is_loaded(plug)
-+ gaim2_plugin_is_loaded(plug)
- && ((GAIM_IS_GTK_PLUGIN(plug) && plug->info->ui_info
- && GAIM_GTK_PLUGIN_UI_INFO(plug)->get_config_frame)
- || (plug->info->prefs_info
-@@ -328,7 +328,7 @@ static void prefs_plugin_sel (GtkTreeSel
-
- static void plugin_dialog_response_cb(GtkWidget *d, int response, GtkTreeSelection *sel)
- {
-- GaimPlugin *plug;
-+ Gaim2Plugin *plug;
- GtkWidget *dialog, *box;
- GtkTreeModel *model;
- GValue val;
-@@ -355,7 +355,7 @@ static void plugin_dialog_response_cb(Gt
- if (plugin_pref_dialogs != NULL &&
- g_hash_table_lookup(plugin_pref_dialogs, plug))
- break;
-- box = gaim_gtk_plugin_get_config_frame(plug);
-+ box = gaim2_gtk_plugin_get_config_frame(plug);
- if (box == NULL)
- break;
-
-@@ -371,7 +371,7 @@ static void plugin_dialog_response_cb(Gt
- g_signal_connect(G_OBJECT(dialog), "response", G_CALLBACK(pref_dialog_response_cb), plug);
- gtk_container_add(GTK_CONTAINER(GTK_DIALOG(dialog)->vbox), box);
- gtk_window_set_role(GTK_WINDOW(dialog), "plugin_config");
-- gtk_window_set_title(GTK_WINDOW(dialog), _(gaim_plugin_get_name(plug)));
-+ gtk_window_set_title(GTK_WINDOW(dialog), _(gaim2_plugin_get_name(plug)));
- gtk_widget_show_all(dialog);
- g_value_unset(&val);
- break;
-@@ -383,7 +383,7 @@ show_plugin_prefs_cb(GtkTreeView *view,
- {
- GtkTreeSelection *sel;
- GtkTreeIter iter;
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GtkTreeModel *model;
-
- sel = gtk_tree_view_get_selection(view);
-@@ -393,14 +393,14 @@ show_plugin_prefs_cb(GtkTreeView *view,
-
- gtk_tree_model_get(model, &iter, 2, &plugin, -1);
-
-- if (!gaim_plugin_is_loaded(plugin))
-+ if (!gaim2_plugin_is_loaded(plugin))
- return;
-
- /* Now show the pref-dialog for the plugin */
- plugin_dialog_response_cb(NULL, GAIM_RESPONSE_CONFIGURE, sel);
- }
-
--void gaim_gtk_plugin_dialog_show()
-+void gaim2_gtk_plugin_dialog_show()
- {
- GtkWidget *sw;
- GtkWidget *event_view;
-diff -prNu ./src/gtkplugin.h ./src/gtkplugin.h
---- ./src/gtkplugin.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkplugin.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkplugin.h GTK+ Plugin API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,17 +25,17 @@
- #ifndef _GAIM_GTKPLUGIN_H_
- #define _GAIM_GTKPLUGIN_H_
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "plugin.h"
-
--typedef struct _GaimGtkPluginUiInfo GaimGtkPluginUiInfo;
-+typedef struct _Gaim2GtkPluginUiInfo Gaim2GtkPluginUiInfo;
-
- /**
- * A GTK+ UI structure for plugins.
- */
--struct _GaimGtkPluginUiInfo
-+struct _Gaim2GtkPluginUiInfo
- {
-- GtkWidget *(*get_config_frame)(GaimPlugin *plugin);
-+ GtkWidget *(*get_config_frame)(Gaim2Plugin *plugin);
-
- int page_num; /**< Reserved */
- };
-@@ -47,7 +47,7 @@ struct _GaimGtkPluginUiInfo
- !strcmp((plugin)->info->ui_requirement, GAIM_GTK_PLUGIN_TYPE))
-
- #define GAIM_GTK_PLUGIN_UI_INFO(plugin) \
-- ((GaimGtkPluginUiInfo *)(plugin)->info->ui_info)
-+ ((Gaim2GtkPluginUiInfo *)(plugin)->info->ui_info)
-
- /**
- * Returns the configuration frame widget for a GTK+ plugin, if one
-@@ -58,16 +58,16 @@ struct _GaimGtkPluginUiInfo
- * @return The frame, if the plugin is a GTK+ plugin and provides a
- * configuration frame.
- */
--GtkWidget *gaim_gtk_plugin_get_config_frame(GaimPlugin *plugin);
-+GtkWidget *gaim2_gtk_plugin_get_config_frame(Gaim2Plugin *plugin);
-
- /**
- * Saves all loaded plugins.
- */
--void gaim_gtk_plugins_save(void);
-+void gaim2_gtk_plugins_save(void);
-
- /**
- * Shows the Plugins dialog
- */
--void gaim_gtk_plugin_dialog_show(void);
-+void gaim2_gtk_plugin_dialog_show(void);
-
- #endif /* _GAIM_GTKPLUGIN_H_ */
-diff -prNu ./src/gtkpluginpref.c ./src/gtkpluginpref.c
---- ./src/gtkpluginpref.c 2006-01-04 05:14:02.000000000 +0100
-+++ ./src/gtkpluginpref.c 2006-01-05 15:11:07.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkpluginpref.c GTK+ Plugin preferences
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -40,7 +40,7 @@ static gboolean
- entry_cb(GtkWidget *entry, gpointer data) {
- char *pref = data;
-
-- gaim_prefs_set_string(pref, gtk_entry_get_text(GTK_ENTRY(entry)));
-+ gaim2_prefs_set_string(pref, gtk_entry_get_text(GTK_ENTRY(entry)));
-
- return FALSE;
- }
-@@ -60,25 +60,25 @@ imhtml_cb(GtkTextBuffer *buffer, gpointe
-
- if (!text)
- text = "";
-- gaim_prefs_set_string(pref, text);
-+ gaim2_prefs_set_string(pref, text);
- g_free(text);
- }
-
- static void
--make_string_pref(GtkWidget *parent, GaimPluginPref *pref, GtkSizeGroup *sg) {
-+make_string_pref(GtkWidget *parent, Gaim2PluginPref *pref, GtkSizeGroup *sg) {
- GtkWidget *hbox, *gtk_label, *entry;
- gchar *pref_name, *pref_label;
-- GaimStringFormatType format;
-+ Gaim2StringFormatType format;
-
-- pref_name = gaim_plugin_pref_get_name(pref);
-- pref_label = gaim_plugin_pref_get_label(pref);
-- format = gaim_plugin_pref_get_format_type(pref);
-+ pref_name = gaim2_plugin_pref_get_name(pref);
-+ pref_label = gaim2_plugin_pref_get_label(pref);
-+ format = gaim2_plugin_pref_get_format_type(pref);
-
-- switch(gaim_plugin_pref_get_type(pref)) {
-+ switch(gaim2_plugin_pref_get_type(pref)) {
- case GAIM_PLUGIN_PREF_CHOICE:
-- gtk_label = gaim_gtk_prefs_dropdown_from_list(parent, pref_label,
-+ gtk_label = gaim2_gtk_prefs_dropdown_from_list(parent, pref_label,
- GAIM_PREF_STRING, pref_name,
-- gaim_plugin_pref_get_choices(pref));
-+ gaim2_plugin_pref_get_choices(pref));
- gtk_misc_set_alignment(GTK_MISC(gtk_label), 0, 0.5);
-
- if(sg)
-@@ -102,10 +102,10 @@ make_string_pref(GtkWidget *parent, Gaim
- if (format == GAIM_STRING_FORMAT_TYPE_NONE)
- {
- entry = gtk_entry_new();
-- gtk_entry_set_text(GTK_ENTRY(entry), gaim_prefs_get_string(pref_name));
-+ gtk_entry_set_text(GTK_ENTRY(entry), gaim2_prefs_get_string(pref_name));
- gtk_entry_set_max_length(GTK_ENTRY(entry),
-- gaim_plugin_pref_get_max_length(pref));
-- if (gaim_plugin_pref_get_masked(pref))
-+ gaim2_plugin_pref_get_max_length(pref));
-+ if (gaim2_plugin_pref_get_masked(pref))
- {
- gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE);
- gtk_entry_set_invisible_char(GTK_ENTRY(entry), GAIM_INVISIBLE_CHAR);
-@@ -121,11 +121,11 @@ make_string_pref(GtkWidget *parent, Gaim
- {
- GtkWidget *imhtml, *toolbar, *frame;
-
-- frame = gaim_gtk_create_imhtml(TRUE, &imhtml, &toolbar);
-+ frame = gaim2_gtk_create_imhtml(TRUE, &imhtml, &toolbar);
- if (!(format & GAIM_STRING_FORMAT_TYPE_HTML))
- gtk_widget_destroy(toolbar);
-
-- gtk_imhtml_append_text(GTK_IMHTML(imhtml), gaim_prefs_get_string(pref_name),
-+ gtk_imhtml_append_text(GTK_IMHTML(imhtml), gaim2_prefs_get_string(pref_name),
- (format & GAIM_STRING_FORMAT_TYPE_MULTILINE) ? 0 : GTK_IMHTML_NO_NEWLINE);
- gtk_label_set_mnemonic_widget(GTK_LABEL(gtk_label), imhtml);
- gtk_widget_show_all(frame);
-@@ -140,18 +140,18 @@ make_string_pref(GtkWidget *parent, Gaim
- }
-
- static void
--make_int_pref(GtkWidget *parent, GaimPluginPref *pref, GtkSizeGroup *sg) {
-+make_int_pref(GtkWidget *parent, Gaim2PluginPref *pref, GtkSizeGroup *sg) {
- GtkWidget *gtk_label;
- gchar *pref_name, *pref_label;
- gint max, min;
-
-- pref_name = gaim_plugin_pref_get_name(pref);
-- pref_label = gaim_plugin_pref_get_label(pref);
-+ pref_name = gaim2_plugin_pref_get_name(pref);
-+ pref_label = gaim2_plugin_pref_get_label(pref);
-
-- switch(gaim_plugin_pref_get_type(pref)) {
-+ switch(gaim2_plugin_pref_get_type(pref)) {
- case GAIM_PLUGIN_PREF_CHOICE:
-- gtk_label = gaim_gtk_prefs_dropdown_from_list(parent, pref_label,
-- GAIM_PREF_INT, pref_name, gaim_plugin_pref_get_choices(pref));
-+ gtk_label = gaim2_gtk_prefs_dropdown_from_list(parent, pref_label,
-+ GAIM_PREF_INT, pref_name, gaim2_plugin_pref_get_choices(pref));
- gtk_misc_set_alignment(GTK_MISC(gtk_label), 0, 0.5);
-
- if(sg)
-@@ -160,8 +160,8 @@ make_int_pref(GtkWidget *parent, GaimPlu
- break;
- case GAIM_PLUGIN_PREF_NONE:
- default:
-- gaim_plugin_pref_get_bounds(pref, &min, &max);
-- gaim_gtk_prefs_labeled_spin_button(parent, pref_label,
-+ gaim2_plugin_pref_get_bounds(pref, &min, &max);
-+ gaim2_gtk_prefs_labeled_spin_button(parent, pref_label,
- pref_name, min, max, sg);
- break;
- }
-@@ -169,8 +169,8 @@ make_int_pref(GtkWidget *parent, GaimPlu
-
-
- static void
--make_info_pref(GtkWidget *parent, GaimPluginPref *pref) {
-- GtkWidget *gtk_label = gtk_label_new(gaim_plugin_pref_get_label(pref));
-+make_info_pref(GtkWidget *parent, Gaim2PluginPref *pref) {
-+ GtkWidget *gtk_label = gtk_label_new(gaim2_plugin_pref_get_label(pref));
- gtk_misc_set_alignment(GTK_MISC(gtk_label), 0, 0);
- gtk_label_set_line_wrap(GTK_LABEL(gtk_label), TRUE);
- gtk_box_pack_start(GTK_BOX(parent), gtk_label, FALSE, FALSE, 0);
-@@ -179,8 +179,8 @@ make_info_pref(GtkWidget *parent, GaimPl
-
-
- GtkWidget *
--gaim_gtk_plugin_pref_create_frame(GaimPluginPrefFrame *frame) {
-- GaimPluginPref *pref;
-+gaim2_gtk_plugin_pref_create_frame(Gaim2PluginPrefFrame *frame) {
-+ Gaim2PluginPref *pref;
- GtkWidget *ret, *parent;
- GtkSizeGroup *sg;
- GList *pp;
-@@ -194,32 +194,32 @@ gaim_gtk_plugin_pref_create_frame(GaimPl
- gtk_container_set_border_width(GTK_CONTAINER(ret), GAIM_HIG_BORDER);
- gtk_widget_show(ret);
-
-- for(pp = gaim_plugin_pref_frame_get_prefs(frame);
-+ for(pp = gaim2_plugin_pref_frame_get_prefs(frame);
- pp != NULL;
- pp = pp->next)
- {
-- pref = (GaimPluginPref *)pp->data;
-+ pref = (Gaim2PluginPref *)pp->data;
-
-- name = gaim_plugin_pref_get_name(pref);
-- label = gaim_plugin_pref_get_label(pref);
-+ name = gaim2_plugin_pref_get_name(pref);
-+ label = gaim2_plugin_pref_get_label(pref);
-
- if(name == NULL) {
- if(label == NULL)
- continue;
-
-- if(gaim_plugin_pref_get_type(pref) == GAIM_PLUGIN_PREF_INFO) {
-+ if(gaim2_plugin_pref_get_type(pref) == GAIM_PLUGIN_PREF_INFO) {
- make_info_pref(parent, pref);
- } else {
-- parent = gaim_gtk_make_frame(ret, label);
-+ parent = gaim2_gtk_make_frame(ret, label);
- gtk_widget_show(parent);
- }
-
- continue;
- }
-
-- switch(gaim_prefs_get_type(name)) {
-+ switch(gaim2_prefs_get_type(name)) {
- case GAIM_PREF_BOOLEAN:
-- gaim_gtk_prefs_checkbox(label, name, parent);
-+ gaim2_gtk_prefs_checkbox(label, name, parent);
- break;
- case GAIM_PREF_INT:
- make_int_pref(parent, pref, sg);
-diff -prNu ./src/gtkpluginpref.h ./src/gtkpluginpref.h
---- ./src/gtkpluginpref.h 2004-08-20 07:11:30.000000000 +0200
-+++ ./src/gtkpluginpref.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkpluginpref.h GTK+ Plugin Preferences
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,19 +32,19 @@
-
- #include "pluginpref.h"
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- /**
-- * Creates a Gtk Preference frame for a GaimPluginPrefFrame
-+ * Creates a Gtk Preference frame for a Gaim2PluginPrefFrame
- *
-- * @param frame GaimPluginPrefFrame
-+ * @param frame Gaim2PluginPrefFrame
- * @return The gtk preference frame
- */
--GtkWidget *gaim_gtk_plugin_pref_create_frame(GaimPluginPrefFrame *frame);
-+GtkWidget *gaim2_gtk_plugin_pref_create_frame(Gaim2PluginPrefFrame *frame);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/gtkpounce.c ./src/gtkpounce.c
---- ./src/gtkpounce.c 2006-01-03 12:42:51.000000000 +0100
-+++ ./src/gtkpounce.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkpounce.c GTK+ Buddy Pounce API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "account.h"
- #include "conversation.h"
-@@ -48,7 +48,7 @@
- */
- enum
- {
-- /* Hidden column containing the GaimPounce */
-+ /* Hidden column containing the Gaim2Pounce */
- POUNCES_MANAGER_COLUMN_POUNCE,
- POUNCES_MANAGER_COLUMN_ICON,
- POUNCES_MANAGER_COLUMN_TARGET,
-@@ -60,8 +60,8 @@ enum
- typedef struct
- {
- /* Pounce data */
-- GaimPounce *pounce;
-- GaimAccount *account;
-+ Gaim2Pounce *pounce;
-+ Gaim2Account *account;
-
- /* The window */
- GtkWidget *window;
-@@ -102,7 +102,7 @@ typedef struct
- /* Buttons */
- GtkWidget *save_button;
-
--} GaimGtkPounceDialog;
-+} Gaim2GtkPounceDialog;
-
- typedef struct
- {
-@@ -119,7 +119,7 @@ static PouncesManager *pounces_manager =
- * Callbacks
- **************************************************************************/
- static gint
--delete_win_cb(GtkWidget *w, GdkEventAny *e, GaimGtkPounceDialog *dialog)
-+delete_win_cb(GtkWidget *w, GdkEventAny *e, Gaim2GtkPounceDialog *dialog)
- {
- gtk_widget_destroy(dialog->window);
- g_free(dialog);
-@@ -128,15 +128,15 @@ delete_win_cb(GtkWidget *w, GdkEventAny
- }
-
- static void
--delete_cb(GtkWidget *w, GaimGtkPounceDialog *dialog)
-+delete_cb(GtkWidget *w, Gaim2GtkPounceDialog *dialog)
- {
-- gaim_pounce_destroy(dialog->pounce);
-+ gaim2_pounce_destroy(dialog->pounce);
-
- delete_win_cb(NULL, NULL, dialog);
- }
-
- static void
--cancel_cb(GtkWidget *w, GaimGtkPounceDialog *dialog)
-+cancel_cb(GtkWidget *w, Gaim2GtkPounceDialog *dialog)
- {
- delete_win_cb(NULL, NULL, dialog);
- }
-@@ -158,7 +158,7 @@ filesel(GtkWidget *widget, gpointer data
- entry = (GtkWidget *)data;
- name = gtk_entry_get_text(GTK_ENTRY(entry));
-
-- gaim_request_file(entry, _("Select a file"), name, FALSE,
-+ gaim2_request_file(entry, _("Select a file"), name, FALSE,
- G_CALLBACK(pounce_update_entry_fields), NULL, entry);
- }
-
-@@ -170,38 +170,38 @@ pounce_test_sound(GtkWidget *w, GtkWidge
- filename = gtk_entry_get_text(GTK_ENTRY(entry));
-
- if (filename != NULL && *filename != '\0')
-- gaim_sound_play_file(filename, NULL);
-+ gaim2_sound_play_file(filename, NULL);
- else
-- gaim_sound_play_event(GAIM_SOUND_POUNCE_DEFAULT, NULL);
-+ gaim2_sound_play_event(GAIM_SOUND_POUNCE_DEFAULT, NULL);
- }
-
- static void
--add_pounce_to_treeview(GtkListStore *model, GaimPounce *pounce)
-+add_pounce_to_treeview(GtkListStore *model, Gaim2Pounce *pounce)
- {
- GtkTreeIter iter;
-- GaimAccount *account;
-- GaimPounceEvent events;
-+ Gaim2Account *account;
-+ Gaim2PounceEvent events;
- gboolean recurring;
- const char *pouncer;
- const char *pouncee;
- GdkPixbuf *pixbuf, *scale = NULL;
-
-- account = gaim_pounce_get_pouncer(pounce);
-+ account = gaim2_pounce_get_pouncer(pounce);
-
-- if (gaim_account_is_disconnected(account))
-+ if (gaim2_account_is_disconnected(account))
- return;
-
-- events = gaim_pounce_get_events(pounce);
-+ events = gaim2_pounce_get_events(pounce);
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
- GDK_INTERP_BILINEAR);
-
-- pouncer = gaim_account_get_username(account);
-- pouncee = gaim_pounce_get_pouncee(pounce);
-- recurring = gaim_pounce_get_save(pounce);
-+ pouncer = gaim2_account_get_username(account);
-+ pouncee = gaim2_pounce_get_pouncee(pounce);
-+ recurring = gaim2_pounce_get_save(pounce);
-
- gtk_list_store_append(model, &iter);
- gtk_list_store_set(model, &iter,
-@@ -220,7 +220,7 @@ populate_pounces_list(PouncesManager *di
-
- gtk_list_store_clear(dialog->model);
-
-- for (pounces = gaim_pounces_get_all(); pounces != NULL;
-+ for (pounces = gaim2_pounces_get_all(); pounces != NULL;
- pounces = g_list_next(pounces))
- {
- add_pounce_to_treeview(dialog->model, pounces->data);
-@@ -238,24 +238,24 @@ update_pounces(void)
- }
-
- static void
--signed_on_off_cb(GaimConnection *gc, gpointer user_data)
-+signed_on_off_cb(Gaim2Connection *gc, gpointer user_data)
- {
- update_pounces();
- }
-
- static void
--save_pounce_cb(GtkWidget *w, GaimGtkPounceDialog *dialog)
-+save_pounce_cb(GtkWidget *w, Gaim2GtkPounceDialog *dialog)
- {
- const char *name;
- const char *message, *command, *sound;
-- GaimPounceEvent events = GAIM_POUNCE_NONE;
-- GaimPounceOption options = GAIM_POUNCE_OPTION_NONE;
-+ Gaim2PounceEvent events = GAIM_POUNCE_NONE;
-+ Gaim2PounceOption options = GAIM_POUNCE_OPTION_NONE;
-
- name = gtk_entry_get_text(GTK_ENTRY(dialog->buddy_entry));
-
- if (*name == '\0')
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("Please enter a buddy to pounce."), NULL);
- return;
- }
-@@ -303,48 +303,48 @@ save_pounce_cb(GtkWidget *w, GaimGtkPoun
-
- if (dialog->pounce == NULL)
- {
-- dialog->pounce = gaim_pounce_new(GAIM_GTK_UI, dialog->account,
-+ dialog->pounce = gaim2_pounce_new(GAIM_GTK_UI, dialog->account,
- name, events, options);
- }
- else {
-- gaim_pounce_set_events(dialog->pounce, events);
-- gaim_pounce_set_options(dialog->pounce, options);
-- gaim_pounce_set_pouncer(dialog->pounce, dialog->account);
-- gaim_pounce_set_pouncee(dialog->pounce, name);
-+ gaim2_pounce_set_events(dialog->pounce, events);
-+ gaim2_pounce_set_options(dialog->pounce, options);
-+ gaim2_pounce_set_pouncer(dialog->pounce, dialog->account);
-+ gaim2_pounce_set_pouncee(dialog->pounce, name);
- }
-
- /* Actions */
-- gaim_pounce_action_set_enabled(dialog->pounce, "open-window",
-+ gaim2_pounce_action_set_enabled(dialog->pounce, "open-window",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->open_win)));
-- gaim_pounce_action_set_enabled(dialog->pounce, "popup-notify",
-+ gaim2_pounce_action_set_enabled(dialog->pounce, "popup-notify",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->popup)));
-- gaim_pounce_action_set_enabled(dialog->pounce, "send-message",
-+ gaim2_pounce_action_set_enabled(dialog->pounce, "send-message",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->send_msg)));
-- gaim_pounce_action_set_enabled(dialog->pounce, "execute-command",
-+ gaim2_pounce_action_set_enabled(dialog->pounce, "execute-command",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->exec_cmd)));
-- gaim_pounce_action_set_enabled(dialog->pounce, "play-sound",
-+ gaim2_pounce_action_set_enabled(dialog->pounce, "play-sound",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->play_sound)));
-
-- gaim_pounce_action_set_attribute(dialog->pounce, "send-message",
-+ gaim2_pounce_action_set_attribute(dialog->pounce, "send-message",
- "message", message);
-- gaim_pounce_action_set_attribute(dialog->pounce, "execute-command",
-+ gaim2_pounce_action_set_attribute(dialog->pounce, "execute-command",
- "command", command);
-- gaim_pounce_action_set_attribute(dialog->pounce, "play-sound",
-+ gaim2_pounce_action_set_attribute(dialog->pounce, "play-sound",
- "filename", sound);
-
- /* Set the defaults for next time. */
-- gaim_prefs_set_bool("/gaim/gtk/pounces/default_actions/open-window",
-+ gaim2_prefs_set_bool("/gaim2/gtk/pounces/default_actions/open-window",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->open_win)));
-- gaim_prefs_set_bool("/gaim/gtk/pounces/default_actions/popup-notify",
-+ gaim2_prefs_set_bool("/gaim2/gtk/pounces/default_actions/popup-notify",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->popup)));
-- gaim_prefs_set_bool("/gaim/gtk/pounces/default_actions/send-message",
-+ gaim2_prefs_set_bool("/gaim2/gtk/pounces/default_actions/send-message",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->send_msg)));
-- gaim_prefs_set_bool("/gaim/gtk/pounces/default_actions/execute-command",
-+ gaim2_prefs_set_bool("/gaim2/gtk/pounces/default_actions/execute-command",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->exec_cmd)));
-- gaim_prefs_set_bool("/gaim/gtk/pounces/default_actions/play-sound",
-+ gaim2_prefs_set_bool("/gaim2/gtk/pounces/default_actions/play-sound",
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->play_sound)));
-
-- gaim_pounce_set_save(dialog->pounce,
-+ gaim2_pounce_set_save(dialog->pounce,
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(dialog->save_pounce)));
-
- update_pounces();
-@@ -353,14 +353,14 @@ save_pounce_cb(GtkWidget *w, GaimGtkPoun
- }
-
- static void
--pounce_choose_cb(GtkWidget *item, GaimAccount *account,
-- GaimGtkPounceDialog *dialog)
-+pounce_choose_cb(GtkWidget *item, Gaim2Account *account,
-+ Gaim2GtkPounceDialog *dialog)
- {
- dialog->account = account;
- }
-
- static void
--buddy_changed_cb(GtkEntry *entry, GaimGtkPounceDialog *dialog)
-+buddy_changed_cb(GtkEntry *entry, Gaim2GtkPounceDialog *dialog)
- {
- if (dialog->save_button == NULL)
- return;
-@@ -383,27 +383,27 @@ static void
- pounce_dnd_recv(GtkWidget *widget, GdkDragContext *dc, gint x, gint y,
- GtkSelectionData *sd, guint info, guint t, gpointer data)
- {
-- GaimGtkPounceDialog *dialog;
-+ Gaim2GtkPounceDialog *dialog;
-
- if (sd->target == gdk_atom_intern("GAIM_BLIST_NODE", FALSE))
- {
-- GaimBlistNode *node = NULL;
-- GaimBuddy *buddy;
-+ Gaim2BlistNode *node = NULL;
-+ Gaim2Buddy *buddy;
-
- memcpy(&node, sd->data, sizeof(node));
-
- if (GAIM_BLIST_NODE_IS_CONTACT(node))
-- buddy = gaim_contact_get_priority_buddy((GaimContact *)node);
-+ buddy = gaim2_contact_get_priority_buddy((Gaim2Contact *)node);
- else if (GAIM_BLIST_NODE_IS_BUDDY(node))
-- buddy = (GaimBuddy *)node;
-+ buddy = (Gaim2Buddy *)node;
- else
- return;
-
-- dialog = (GaimGtkPounceDialog *)data;
-+ dialog = (Gaim2GtkPounceDialog *)data;
-
- gtk_entry_set_text(GTK_ENTRY(dialog->buddy_entry), buddy->name);
- dialog->account = buddy->account;
-- gaim_gtk_account_option_menu_set_selected(dialog->account_menu, buddy->account);
-+ gaim2_gtk_account_option_menu_set_selected(dialog->account_menu, buddy->account);
-
- gtk_drag_finish(dc, TRUE, (dc->action == GDK_ACTION_MOVE), t);
- }
-@@ -411,24 +411,24 @@ pounce_dnd_recv(GtkWidget *widget, GdkDr
- {
- char *protocol = NULL;
- char *username = NULL;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- if (gaim_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
-+ if (gaim2_gtk_parse_x_im_contact((const char *)sd->data, FALSE, &account,
- &protocol, &username, NULL))
- {
- if (account == NULL)
- {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("You are not currently signed on with an account that "
- "can add that buddy."), NULL);
- }
- else
- {
-- dialog = (GaimGtkPounceDialog *)data;
-+ dialog = (Gaim2GtkPounceDialog *)data;
-
- gtk_entry_set_text(GTK_ENTRY(dialog->buddy_entry), username);
- dialog->account = account;
-- gaim_gtk_account_option_menu_set_selected(dialog->account_menu, account);
-+ gaim2_gtk_account_option_menu_set_selected(dialog->account_menu, account);
- }
- }
-
-@@ -446,10 +446,10 @@ static const GtkTargetEntry dnd_targets[
- };
-
- void
--gaim_gtk_pounce_editor_show(GaimAccount *account, const char *name,
-- GaimPounce *cur_pounce)
-+gaim2_gtk_pounce_editor_show(Gaim2Account *account, const char *name,
-+ Gaim2Pounce *cur_pounce)
- {
-- GaimGtkPounceDialog *dialog;
-+ Gaim2GtkPounceDialog *dialog;
- GtkWidget *window;
- GtkWidget *label;
- GtkWidget *bbox;
-@@ -463,14 +463,14 @@ gaim_gtk_pounce_editor_show(GaimAccount
- GPtrArray *exec_widgets;
-
- g_return_if_fail((cur_pounce != NULL) || (account != NULL) ||
-- (gaim_connections_get_all() != NULL));
-+ (gaim2_connections_get_all() != NULL));
-
-- dialog = g_new0(GaimGtkPounceDialog, 1);
-+ dialog = g_new0(Gaim2GtkPounceDialog, 1);
-
- if (cur_pounce != NULL)
- {
- dialog->pounce = cur_pounce;
-- dialog->account = gaim_pounce_get_pouncer(cur_pounce);
-+ dialog->account = gaim2_pounce_get_pouncer(cur_pounce);
- }
- else if (account != NULL)
- {
-@@ -479,12 +479,12 @@ gaim_gtk_pounce_editor_show(GaimAccount
- }
- else
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = (GaimConnection *)gaim_connections_get_all()->data;
-+ gc = (Gaim2Connection *)gaim2_connections_get_all()->data;
-
- dialog->pounce = NULL;
-- dialog->account = gaim_connection_get_account(gc);
-+ dialog->account = gaim2_connection_get_account(gc);
- }
-
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-@@ -513,7 +513,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- gtk_box_pack_start(GTK_BOX(vbox1), vbox2, TRUE, TRUE, 0);
-
- /* Create the "Pounce on Whom" frame. */
-- frame = gaim_gtk_make_frame(vbox2, _("Pounce on Whom"));
-+ frame = gaim2_gtk_make_frame(vbox2, _("Pounce on Whom"));
-
- /* Account: */
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
-@@ -527,13 +527,13 @@ gaim_gtk_pounce_editor_show(GaimAccount
- gtk_size_group_add_widget(sg, label);
-
- dialog->account_menu =
-- gaim_gtk_account_option_menu_new(dialog->account, FALSE,
-+ gaim2_gtk_account_option_menu_new(dialog->account, FALSE,
- G_CALLBACK(pounce_choose_cb),
- NULL, dialog);
-
- gtk_box_pack_start(GTK_BOX(hbox), dialog->account_menu, FALSE, FALSE, 0);
- gtk_widget_show(dialog->account_menu);
-- gaim_set_accessible_label (dialog->account_menu, label);
-+ gaim2_set_accessible_label (dialog->account_menu, label);
-
- /* Buddy: */
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
-@@ -553,18 +553,18 @@ gaim_gtk_pounce_editor_show(GaimAccount
-
- g_signal_connect(G_OBJECT(dialog->buddy_entry), "changed",
- G_CALLBACK(buddy_changed_cb), dialog);
-- gaim_set_accessible_label (dialog->buddy_entry, label);
-+ gaim2_set_accessible_label (dialog->buddy_entry, label);
-
- if (cur_pounce != NULL) {
- gtk_entry_set_text(GTK_ENTRY(dialog->buddy_entry),
-- gaim_pounce_get_pouncee(cur_pounce));
-+ gaim2_pounce_get_pouncee(cur_pounce));
- }
- else if (name != NULL) {
- gtk_entry_set_text(GTK_ENTRY(dialog->buddy_entry), name);
- }
-
- /* Create the "Pounce When Buddy..." frame. */
-- frame = gaim_gtk_make_frame(vbox2, _("Pounce When Buddy..."));
-+ frame = gaim2_gtk_make_frame(vbox2, _("Pounce When Buddy..."));
-
- table = gtk_table_new(2, 4, FALSE);
- gtk_container_add(GTK_CONTAINER(frame), table);
-@@ -620,7 +620,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- gtk_widget_show(dialog->message_recv);
-
- /* Create the "Action" frame. */
-- frame = gaim_gtk_make_frame(vbox2, _("Action"));
-+ frame = gaim2_gtk_make_frame(vbox2, _("Action"));
-
- table = gtk_table_new(3, 5, FALSE);
- gtk_container_add(GTK_CONTAINER(frame), table);
-@@ -707,7 +707,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- dialog->send_msg);
-
- g_signal_connect(G_OBJECT(dialog->send_msg), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive),
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive),
- dialog->send_msg_entry);
-
- exec_widgets = g_ptr_array_new();
-@@ -715,7 +715,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- g_ptr_array_add(exec_widgets,dialog->exec_cmd_browse);
-
- g_signal_connect(G_OBJECT(dialog->exec_cmd), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive_array),
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive_array),
- exec_widgets);
- g_signal_connect(G_OBJECT(dialog->exec_cmd_browse), "clicked",
- G_CALLBACK(filesel),
-@@ -727,7 +727,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- g_ptr_array_add(sound_widgets,dialog->play_sound_test);
-
- g_signal_connect(G_OBJECT(dialog->play_sound), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive_array),
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive_array),
- sound_widgets);
- g_signal_connect(G_OBJECT(dialog->play_sound_browse), "clicked",
- G_CALLBACK(filesel),
-@@ -744,7 +744,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- G_CALLBACK(save_pounce_cb), dialog);
-
- /* Create the "Options" frame. */
-- frame = gaim_gtk_make_frame(vbox2, _("Options"));
-+ frame = gaim2_gtk_make_frame(vbox2, _("Options"));
-
- table = gtk_table_new(2, 1, FALSE);
- gtk_container_add(GTK_CONTAINER(frame), table);
-@@ -822,8 +822,8 @@ gaim_gtk_pounce_editor_show(GaimAccount
- /* Set the values of stuff. */
- if (cur_pounce != NULL)
- {
-- GaimPounceEvent events = gaim_pounce_get_events(cur_pounce);
-- GaimPounceOption options = gaim_pounce_get_options(cur_pounce);
-+ Gaim2PounceEvent events = gaim2_pounce_get_events(cur_pounce);
-+ Gaim2PounceOption options = gaim2_pounce_get_options(cur_pounce);
- const char *value;
-
- /* Options */
-@@ -852,34 +852,34 @@ gaim_gtk_pounce_editor_show(GaimAccount
-
- /* Actions */
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->open_win),
-- gaim_pounce_action_is_enabled(cur_pounce, "open-window"));
-+ gaim2_pounce_action_is_enabled(cur_pounce, "open-window"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->popup),
-- gaim_pounce_action_is_enabled(cur_pounce, "popup-notify"));
-+ gaim2_pounce_action_is_enabled(cur_pounce, "popup-notify"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->send_msg),
-- gaim_pounce_action_is_enabled(cur_pounce, "send-message"));
-+ gaim2_pounce_action_is_enabled(cur_pounce, "send-message"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->exec_cmd),
-- gaim_pounce_action_is_enabled(cur_pounce, "execute-command"));
-+ gaim2_pounce_action_is_enabled(cur_pounce, "execute-command"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->play_sound),
-- gaim_pounce_action_is_enabled(cur_pounce, "play-sound"));
-+ gaim2_pounce_action_is_enabled(cur_pounce, "play-sound"));
-
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->save_pounce),
-- gaim_pounce_get_save(cur_pounce));
-+ gaim2_pounce_get_save(cur_pounce));
-
-- if ((value = gaim_pounce_action_get_attribute(cur_pounce,
-+ if ((value = gaim2_pounce_action_get_attribute(cur_pounce,
- "send-message",
- "message")) != NULL)
- {
- gtk_entry_set_text(GTK_ENTRY(dialog->send_msg_entry), value);
- }
-
-- if ((value = gaim_pounce_action_get_attribute(cur_pounce,
-+ if ((value = gaim2_pounce_action_get_attribute(cur_pounce,
- "execute-command",
- "command")) != NULL)
- {
- gtk_entry_set_text(GTK_ENTRY(dialog->exec_cmd_entry), value);
- }
-
-- if ((value = gaim_pounce_action_get_attribute(cur_pounce,
-+ if ((value = gaim2_pounce_action_get_attribute(cur_pounce,
- "play-sound",
- "filename")) != NULL)
- {
-@@ -888,10 +888,10 @@ gaim_gtk_pounce_editor_show(GaimAccount
- }
- else
- {
-- GaimBuddy *buddy = NULL;
-+ Gaim2Buddy *buddy = NULL;
-
- if (name != NULL)
-- buddy = gaim_find_buddy(account, name);
-+ buddy = gaim2_find_buddy(account, name);
-
- /* Set some defaults */
- if (buddy == NULL)
-@@ -909,9 +909,9 @@ gaim_gtk_pounce_editor_show(GaimAccount
- else
- {
- gboolean default_set = FALSE;
-- GaimPresence *presence = gaim_buddy_get_presence(buddy);
-+ Gaim2Presence *presence = gaim2_buddy_get_presence(buddy);
-
-- if (gaim_presence_is_idle(presence))
-+ if (gaim2_presence_is_idle(presence))
- {
- gtk_toggle_button_set_active(
- GTK_TOGGLE_BUTTON(dialog->idle_return), TRUE);
-@@ -919,7 +919,7 @@ gaim_gtk_pounce_editor_show(GaimAccount
- default_set = TRUE;
- }
-
-- if (!gaim_presence_is_available(presence))
-+ if (!gaim2_presence_is_available(presence))
- {
- gtk_toggle_button_set_active(
- GTK_TOGGLE_BUTTON(dialog->away_return), TRUE);
-@@ -936,15 +936,15 @@ gaim_gtk_pounce_editor_show(GaimAccount
- }
-
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->open_win),
-- gaim_prefs_get_bool("/gaim/gtk/pounces/default_actions/open-window"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/pounces/default_actions/open-window"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->popup),
-- gaim_prefs_get_bool("/gaim/gtk/pounces/default_actions/popup-notify"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/pounces/default_actions/popup-notify"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->send_msg),
-- gaim_prefs_get_bool("/gaim/gtk/pounces/default_actions/send-message"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/pounces/default_actions/send-message"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->exec_cmd),
-- gaim_prefs_get_bool("/gaim/gtk/pounces/default_actions/execute-command"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/pounces/default_actions/execute-command"));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(dialog->play_sound),
-- gaim_prefs_get_bool("/gaim/gtk/pounces/default_actions/play-sound"));
-+ gaim2_prefs_get_bool("/gaim2/gtk/pounces/default_actions/play-sound"));
- }
-
- gtk_widget_show_all(vbox2);
-@@ -955,18 +955,18 @@ static gboolean
- pounces_manager_configure_cb(GtkWidget *widget, GdkEventConfigure *event, PouncesManager *dialog)
- {
- if (GTK_WIDGET_VISIBLE(widget)) {
-- gaim_prefs_set_int("/gaim/gtk/pounces/dialog/width", event->width);
-- gaim_prefs_set_int("/gaim/gtk/pounces/dialog/height", event->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/pounces/dialog/width", event->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/pounces/dialog/height", event->height);
- }
-
- return FALSE;
- }
-
- static gboolean
--pounces_manager_find_pounce(GtkTreeIter *iter, GaimPounce *pounce)
-+pounces_manager_find_pounce(GtkTreeIter *iter, Gaim2Pounce *pounce)
- {
- GtkTreeModel *model = GTK_TREE_MODEL(pounces_manager->model);
-- GaimPounce *p;
-+ Gaim2Pounce *p;
-
- if (!gtk_tree_model_get_iter_first(model, iter))
- return FALSE;
-@@ -991,7 +991,7 @@ pounces_manager_destroy_cb(GtkWidget *wi
- PouncesManager *dialog = user_data;
-
- dialog->window = NULL;
-- gaim_gtk_pounces_manager_hide();
-+ gaim2_gtk_pounces_manager_hide();
-
- return FALSE;
- }
-@@ -1006,25 +1006,25 @@ count_selected_helper(GtkTreeModel *mode
- #endif
-
- static void
--pounces_manager_connection_cb(GaimConnection *gc, GtkWidget *add_button)
-+pounces_manager_connection_cb(Gaim2Connection *gc, GtkWidget *add_button)
- {
-- gtk_widget_set_sensitive(add_button, (gaim_connections_get_all() != NULL));
-+ gtk_widget_set_sensitive(add_button, (gaim2_connections_get_all() != NULL));
- }
-
- static void
- pounces_manager_add_cb(GtkButton *button, gpointer user_data)
- {
-- gaim_gtk_pounce_editor_show(NULL, NULL, NULL);
-+ gaim2_gtk_pounce_editor_show(NULL, NULL, NULL);
- }
-
- static void
- pounces_manager_modify_foreach(GtkTreeModel *model, GtkTreePath *path,
- GtkTreeIter *iter, gpointer user_data)
- {
-- GaimPounce *pounce;
-+ Gaim2Pounce *pounce;
-
- gtk_tree_model_get(model, iter, POUNCES_MANAGER_COLUMN_POUNCE, &pounce, -1);
-- gaim_gtk_pounce_editor_show(NULL, NULL, pounce);
-+ gaim2_gtk_pounce_editor_show(NULL, NULL, pounce);
- }
-
- static void
-@@ -1039,32 +1039,32 @@ pounces_manager_modify_cb(GtkButton *but
- }
-
- static void
--pounces_manager_delete_confirm_cb(GaimPounce *pounce)
-+pounces_manager_delete_confirm_cb(Gaim2Pounce *pounce)
- {
- GtkTreeIter iter;
-
- if (pounces_manager_find_pounce(&iter, pounce))
- gtk_list_store_remove(pounces_manager->model, &iter);
-
-- gaim_pounce_destroy(pounce);
-+ gaim2_pounce_destroy(pounce);
- }
-
- static void
- pounces_manager_delete_foreach(GtkTreeModel *model, GtkTreePath *path,
- GtkTreeIter *iter, gpointer user_data)
- {
-- GaimPounce *pounce;
-- GaimAccount *account;
-+ Gaim2Pounce *pounce;
-+ Gaim2Account *account;
- const char *pouncer, *pouncee;
- char *buf;
-
- gtk_tree_model_get(model, iter, POUNCES_MANAGER_COLUMN_POUNCE, &pounce, -1);
-- account = gaim_pounce_get_pouncer(pounce);
-- pouncer = gaim_account_get_username(account);
-- pouncee = gaim_pounce_get_pouncee(pounce);
-+ account = gaim2_pounce_get_pouncer(pounce);
-+ pouncer = gaim2_account_get_username(account);
-+ pouncee = gaim2_pounce_get_pouncee(pounce);
-
- buf = g_strdup_printf(_("Are you sure you want to delete the pounce on %s for %s?"), pouncee, pouncer);
-- gaim_request_action(NULL, NULL, buf, NULL, 0, pounce, 2,
-+ gaim2_request_action(NULL, NULL, buf, NULL, 0, pounce, 2,
- _("Delete"), pounces_manager_delete_confirm_cb,
- _("Cancel"), g_free);
- g_free(buf);
-@@ -1084,7 +1084,7 @@ pounces_manager_delete_cb(GtkButton *but
- static void
- pounces_manager_close_cb(GtkButton *button, gpointer user_data)
- {
-- gaim_gtk_pounces_manager_hide();
-+ gaim2_gtk_pounces_manager_hide();
- }
-
- static void
-@@ -1109,7 +1109,7 @@ pounce_double_click_cb(GtkTreeView *tree
- PouncesManager *dialog = user_data;
- GtkTreePath *path;
- GtkTreeIter iter;
-- GaimPounce *pounce;
-+ Gaim2Pounce *pounce;
-
- /* Figure out which node was clicked */
- if (!gtk_tree_view_get_path_at_pos(GTK_TREE_VIEW(dialog->treeview), event->x, event->y, &path, NULL, NULL, NULL))
-@@ -1121,7 +1121,7 @@ pounce_double_click_cb(GtkTreeView *tree
- if ((pounce != NULL) && (event->button == 1) &&
- (event->type == GDK_2BUTTON_PRESS))
- {
-- gaim_gtk_pounce_editor_show(NULL, NULL, pounce);
-+ gaim2_gtk_pounce_editor_show(NULL, NULL, pounce);
- return TRUE;
- }
-
-@@ -1133,7 +1133,7 @@ pounces_manager_recurring_cb(GtkCellRend
- gpointer user_data)
- {
- PouncesManager *dialog = user_data;
-- GaimPounce *pounce;
-+ Gaim2Pounce *pounce;
- gboolean recurring;
- GtkTreeModel *model = GTK_TREE_MODEL(dialog->model);
- GtkTreeIter iter;
-@@ -1144,7 +1144,7 @@ pounces_manager_recurring_cb(GtkCellRend
- POUNCES_MANAGER_COLUMN_RECURRING, &recurring,
- -1);
-
-- gaim_pounce_set_save(pounce, !recurring);
-+ gaim2_pounce_set_save(pounce, !recurring);
-
- update_pounces();
- }
-@@ -1157,7 +1157,7 @@ search_func(GtkTreeModel *model, gint co
-
- gtk_tree_model_get(model, iter, column, &haystack, -1);
-
-- result = (gaim_strcasestr(haystack, key) == NULL);
-+ result = (gaim2_strcasestr(haystack, key) == NULL);
-
- g_free(haystack);
-
-@@ -1270,7 +1270,7 @@ create_pounces_list(PouncesManager *dial
- }
-
- void
--gaim_gtk_pounces_manager_show(void)
-+gaim2_gtk_pounces_manager_show(void)
- {
- PouncesManager *dialog;
- GtkWidget *bbox;
-@@ -1287,8 +1287,8 @@ gaim_gtk_pounces_manager_show(void)
-
- pounces_manager = dialog = g_new0(PouncesManager, 1);
-
-- width = gaim_prefs_get_int("/gaim/gtk/pounces/dialog/width");
-- height = gaim_prefs_get_int("/gaim/gtk/pounces/dialog/height");
-+ width = gaim2_prefs_get_int("/gaim2/gtk/pounces/dialog/width");
-+ height = gaim2_prefs_get_int("/gaim2/gtk/pounces/dialog/height");
-
- dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
- gtk_window_set_default_size(GTK_WINDOW(win), width, height);
-@@ -1320,10 +1320,10 @@ gaim_gtk_pounces_manager_show(void)
- /* Add button */
- button = gtk_button_new_from_stock(GTK_STOCK_ADD);
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
-- gtk_widget_set_sensitive(button, (gaim_connections_get_all() != NULL));
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gtk_widget_set_sensitive(button, (gaim2_connections_get_all() != NULL));
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- pounces_manager, GAIM_CALLBACK(pounces_manager_connection_cb), button);
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off",
- pounces_manager, GAIM_CALLBACK(pounces_manager_connection_cb), button);
- gtk_widget_show(button);
-
-@@ -1362,7 +1362,7 @@ gaim_gtk_pounces_manager_show(void)
- }
-
- void
--gaim_gtk_pounces_manager_hide(void)
-+gaim2_gtk_pounces_manager_hide(void)
- {
- if (pounces_manager == NULL)
- return;
-@@ -1370,37 +1370,37 @@ gaim_gtk_pounces_manager_hide(void)
- if (pounces_manager->window != NULL)
- gtk_widget_destroy(pounces_manager->window);
-
-- gaim_signals_disconnect_by_handle(pounces_manager);
-+ gaim2_signals_disconnect_by_handle(pounces_manager);
-
- g_free(pounces_manager);
- pounces_manager = NULL;
- }
-
- static void
--pounce_cb(GaimPounce *pounce, GaimPounceEvent events, void *data)
-+pounce_cb(Gaim2Pounce *pounce, Gaim2PounceEvent events, void *data)
- {
-- GaimConversation *conv;
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Conversation *conv;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
- const char *pouncee;
- const char *alias;
-
-- pouncee = gaim_pounce_get_pouncee(pounce);
-- account = gaim_pounce_get_pouncer(pounce);
-+ pouncee = gaim2_pounce_get_pouncee(pounce);
-+ account = gaim2_pounce_get_pouncer(pounce);
-
-- buddy = gaim_find_buddy(account, pouncee);
-+ buddy = gaim2_find_buddy(account, pouncee);
-
-- alias = gaim_buddy_get_alias(buddy);
-+ alias = gaim2_buddy_get_alias(buddy);
-
-- if (gaim_pounce_action_is_enabled(pounce, "open-window"))
-+ if (gaim2_pounce_action_is_enabled(pounce, "open-window"))
- {
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, pouncee, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, pouncee, account);
-
- if (conv == NULL)
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, pouncee);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, pouncee);
- }
-
-- if (gaim_pounce_action_is_enabled(pounce, "popup-notify"))
-+ if (gaim2_pounce_action_is_enabled(pounce, "popup-notify"))
- {
- char tmp[1024];
- const char *name_shown;
-@@ -1429,45 +1429,45 @@ pounce_cb(GaimPounce *pounce, GaimPounce
- (events & GAIM_POUNCE_MESSAGE_RECEIVED) ?
- _("%s has sent you a message. (%s)") :
- _("Unknown pounce event. Please report this!"),
-- alias, gaim_account_get_protocol_name(account));
-+ alias, gaim2_account_get_protocol_name(account));
-
- /*
- * Ok here is where I change the second argument, title, from
- * NULL to the account name if that's all we have or the account
- * alias if we have that
- */
-- if ((name_shown = gaim_account_get_alias(account)) == NULL)
-- name_shown = gaim_account_get_username(account);
-+ if ((name_shown = gaim2_account_get_alias(account)) == NULL)
-+ name_shown = gaim2_account_get_username(account);
-
-- gaim_notify_info(NULL, name_shown, tmp, gaim_date_full());
-+ gaim2_notify_info(NULL, name_shown, tmp, gaim2_date_full());
- }
-
-- if (gaim_pounce_action_is_enabled(pounce, "send-message"))
-+ if (gaim2_pounce_action_is_enabled(pounce, "send-message"))
- {
- const char *message;
-
-- message = gaim_pounce_action_get_attribute(pounce, "send-message",
-+ message = gaim2_pounce_action_get_attribute(pounce, "send-message",
- "message");
-
- if (message != NULL)
- {
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, pouncee, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, pouncee, account);
-
- if (conv == NULL)
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, pouncee);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, pouncee);
-
-- gaim_conversation_write(conv, NULL, message,
-+ gaim2_conversation_write(conv, NULL, message,
- GAIM_MESSAGE_SEND, time(NULL));
-
- serv_send_im(account->gc, (char *)pouncee, (char *)message, 0);
- }
- }
-
-- if (gaim_pounce_action_is_enabled(pounce, "execute-command"))
-+ if (gaim2_pounce_action_is_enabled(pounce, "execute-command"))
- {
- const char *command;
-
-- command = gaim_pounce_action_get_attribute(pounce,
-+ command = gaim2_pounce_action_get_attribute(pounce,
- "execute-command", "command");
-
- if (command != NULL)
-@@ -1534,7 +1534,7 @@ pounce_cb(GaimPounce *pounce, GaimPounce
- message = g_win32_error_message(GetLastError());
- }
-
-- gaim_debug_info("pounce",
-+ gaim2_debug_info("pounce",
- "Pounce execute command called for: "
- "%s\n%s%s%s",
- command,
-@@ -1546,71 +1546,71 @@ pounce_cb(GaimPounce *pounce, GaimPounce
- }
- }
-
-- if (gaim_pounce_action_is_enabled(pounce, "play-sound"))
-+ if (gaim2_pounce_action_is_enabled(pounce, "play-sound"))
- {
- const char *sound;
-
-- sound = gaim_pounce_action_get_attribute(pounce,
-+ sound = gaim2_pounce_action_get_attribute(pounce,
- "play-sound", "filename");
-
- if (sound != NULL)
-- gaim_sound_play_file(sound, account);
-+ gaim2_sound_play_file(sound, account);
- else
-- gaim_sound_play_event(GAIM_SOUND_POUNCE_DEFAULT, account);
-+ gaim2_sound_play_event(GAIM_SOUND_POUNCE_DEFAULT, account);
- }
- }
-
- static void
--free_pounce(GaimPounce *pounce)
-+free_pounce(Gaim2Pounce *pounce)
- {
- update_pounces();
- }
-
- static void
--new_pounce(GaimPounce *pounce)
-+new_pounce(Gaim2Pounce *pounce)
- {
-- gaim_pounce_action_register(pounce, "open-window");
-- gaim_pounce_action_register(pounce, "popup-notify");
-- gaim_pounce_action_register(pounce, "send-message");
-- gaim_pounce_action_register(pounce, "execute-command");
-- gaim_pounce_action_register(pounce, "play-sound");
-+ gaim2_pounce_action_register(pounce, "open-window");
-+ gaim2_pounce_action_register(pounce, "popup-notify");
-+ gaim2_pounce_action_register(pounce, "send-message");
-+ gaim2_pounce_action_register(pounce, "execute-command");
-+ gaim2_pounce_action_register(pounce, "play-sound");
-
- update_pounces();
- }
-
- void *
--gaim_gtk_pounces_get_handle() {
-+gaim2_gtk_pounces_get_handle() {
- static int handle;
-
- return &handle;
- }
-
- void
--gaim_gtk_pounces_init(void)
-+gaim2_gtk_pounces_init(void)
- {
-- gaim_pounces_register_handler(GAIM_GTK_UI, pounce_cb, new_pounce,
-+ gaim2_pounces_register_handler(GAIM_GTK_UI, pounce_cb, new_pounce,
- free_pounce);
-
-- gaim_prefs_add_none("/gaim/gtk/pounces");
-- gaim_prefs_add_none("/gaim/gtk/pounces/default_actions");
-- gaim_prefs_add_bool("/gaim/gtk/pounces/default_actions/open-window",
-+ gaim2_prefs_add_none("/gaim2/gtk/pounces");
-+ gaim2_prefs_add_none("/gaim2/gtk/pounces/default_actions");
-+ gaim2_prefs_add_bool("/gaim2/gtk/pounces/default_actions/open-window",
- FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/pounces/default_actions/popup-notify",
-+ gaim2_prefs_add_bool("/gaim2/gtk/pounces/default_actions/popup-notify",
- TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/pounces/default_actions/send-message",
-+ gaim2_prefs_add_bool("/gaim2/gtk/pounces/default_actions/send-message",
- FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/pounces/default_actions/execute-command",
-+ gaim2_prefs_add_bool("/gaim2/gtk/pounces/default_actions/execute-command",
- FALSE);
-- gaim_prefs_add_bool("/gaim/gtk/pounces/default_actions/play-sound",
-+ gaim2_prefs_add_bool("/gaim2/gtk/pounces/default_actions/play-sound",
- FALSE);
-- gaim_prefs_add_none("/gaim/gtk/pounces/dialog");
-- gaim_prefs_add_int("/gaim/gtk/pounces/dialog/width", 520);
-- gaim_prefs_add_int("/gaim/gtk/pounces/dialog/height", 321);
-+ gaim2_prefs_add_none("/gaim2/gtk/pounces/dialog");
-+ gaim2_prefs_add_int("/gaim2/gtk/pounces/dialog/width", 520);
-+ gaim2_prefs_add_int("/gaim2/gtk/pounces/dialog/height", 321);
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-- gaim_gtk_pounces_get_handle(),
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
-+ gaim2_gtk_pounces_get_handle(),
- GAIM_CALLBACK(signed_on_off_cb), NULL);
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off",
-- gaim_gtk_pounces_get_handle(),
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off",
-+ gaim2_gtk_pounces_get_handle(),
- GAIM_CALLBACK(signed_on_off_cb), NULL);
- }
-diff -prNu ./src/gtkpounce.h ./src/gtkpounce.h
---- ./src/gtkpounce.h 2005-11-19 14:53:09.000000000 +0100
-+++ ./src/gtkpounce.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkpounce.h GTK+ Buddy Pounce API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -34,29 +34,29 @@
- * @param name The optional name to pounce on.
- * @param cur_pounce The current buddy pounce, if editing an existing one.
- */
--void gaim_gtk_pounce_editor_show(GaimAccount *account, const char *name,
-- GaimPounce *cur_pounce);
-+void gaim2_gtk_pounce_editor_show(Gaim2Account *account, const char *name,
-+ Gaim2Pounce *cur_pounce);
-
- /**
- * Shows the pounces manager window.
- */
--void gaim_gtk_pounces_manager_show(void);
-+void gaim2_gtk_pounces_manager_show(void);
-
- /**
- * Hides the pounces manager window.
- */
--void gaim_gtk_pounces_manager_hide(void);
-+void gaim2_gtk_pounces_manager_hide(void);
-
- /**
- * Returns the gtkpounces handle
- *
- * @return The handle to the GTK+ pounces system
- */
--void *gaim_gtk_pounces_get_handle(void);
-+void *gaim2_gtk_pounces_get_handle(void);
-
- /**
- * Initializes the GTK+ pounces subsystem.
- */
--void gaim_gtk_pounces_init(void);
-+void gaim2_gtk_pounces_init(void);
-
- #endif /* _GAIM_GTKPOUNCE_H_ */
-diff -prNu ./src/gtkprefs.c ./src/gtkprefs.c
---- ./src/gtkprefs.c 2006-01-04 22:51:09.000000000 +0100
-+++ ./src/gtkprefs.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkprefs.c GTK+ Preferences
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "debug.h"
- #include "notify.h"
-@@ -83,11 +83,11 @@ update_spin_value(GtkWidget *w, GtkWidge
-
- value = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(spin));
-
-- gaim_prefs_set_int(key, value);
-+ gaim2_prefs_set_int(key, value);
- }
-
- GtkWidget *
--gaim_gtk_prefs_labeled_spin_button(GtkWidget *box, const gchar *title,
-+gaim2_gtk_prefs_labeled_spin_button(GtkWidget *box, const gchar *title,
- const char *key, int min, int max, GtkSizeGroup *sg)
- {
- GtkWidget *hbox;
-@@ -96,7 +96,7 @@ gaim_gtk_prefs_labeled_spin_button(GtkWi
- GtkObject *adjust;
- int val;
-
-- val = gaim_prefs_get_int(key);
-+ val = gaim2_prefs_get_int(key);
-
- hbox = gtk_hbox_new(FALSE, 5);
- gtk_box_pack_start(GTK_BOX(box), hbox, FALSE, FALSE, 5);
-@@ -126,7 +126,7 @@ gaim_gtk_prefs_labeled_spin_button(GtkWi
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
- }
-
-- gaim_set_accessible_label (spin, label);
-+ gaim2_set_accessible_label (spin, label);
-
- return hbox;
- }
-@@ -135,17 +135,17 @@ static void
- entry_set(GtkEntry *entry, gpointer data) {
- const char *key = (const char*)data;
-
-- gaim_prefs_set_string(key, gtk_entry_get_text(entry));
-+ gaim2_prefs_set_string(key, gtk_entry_get_text(entry));
- }
-
- GtkWidget *
--gaim_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title,
-+gaim2_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title,
- const char *key, GtkSizeGroup *sg)
- {
- GtkWidget *hbox, *label, *entry;
- const gchar *value;
-
-- value = gaim_prefs_get_string(key);
-+ value = gaim2_prefs_get_string(key);
-
- hbox = gtk_hbox_new(FALSE, 5);
- gtk_box_pack_start(GTK_BOX(page), hbox, FALSE, FALSE, 5);
-@@ -170,7 +170,7 @@ gaim_gtk_prefs_labeled_entry(GtkWidget *
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
- }
-
-- gaim_set_accessible_label(entry, label);
-+ gaim2_set_accessible_label(entry, label);
-
- return hbox;
- }
-@@ -180,29 +180,29 @@ dropdown_set(GObject *w, const char *key
- {
- const char *str_value;
- int int_value;
-- GaimPrefType type;
-+ Gaim2PrefType type;
-
- type = GPOINTER_TO_INT(g_object_get_data(w, "type"));
-
- if (type == GAIM_PREF_INT) {
- int_value = GPOINTER_TO_INT(g_object_get_data(w, "value"));
-
-- gaim_prefs_set_int(key, int_value);
-+ gaim2_prefs_set_int(key, int_value);
- }
- else if (type == GAIM_PREF_STRING) {
- str_value = (const char *)g_object_get_data(w, "value");
-
-- gaim_prefs_set_string(key, str_value);
-+ gaim2_prefs_set_string(key, str_value);
- }
- else if (type == GAIM_PREF_BOOLEAN) {
-- gaim_prefs_set_bool(key,
-+ gaim2_prefs_set_bool(key,
- GPOINTER_TO_INT(g_object_get_data(w, "value")));
- }
- }
-
- GtkWidget *
--gaim_gtk_prefs_dropdown_from_list(GtkWidget *box, const gchar *title,
-- GaimPrefType type, const char *key, GList *menuitems)
-+gaim2_gtk_prefs_dropdown_from_list(GtkWidget *box, const gchar *title,
-+ Gaim2PrefType type, const char *key, GList *menuitems)
- {
- GtkWidget *dropdown, *opt, *menu;
- GtkWidget *label = NULL;
-@@ -242,13 +242,13 @@ gaim_gtk_prefs_dropdown_from_list(GtkWid
-
- if (label != NULL) {
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), dropdown);
-- gaim_set_accessible_label (dropdown, label);
-+ gaim2_set_accessible_label (dropdown, label);
- }
-
- if (type == GAIM_PREF_INT)
-- stored_int = gaim_prefs_get_int(key);
-+ stored_int = gaim2_prefs_get_int(key);
- else if (type == GAIM_PREF_STRING)
-- stored_str = gaim_prefs_get_string(key);
-+ stored_str = gaim2_prefs_get_string(key);
-
- while (menuitems != NULL && (text = (char *) menuitems->data) != NULL) {
- menuitems = g_list_next(menuitems);
-@@ -283,7 +283,7 @@ gaim_gtk_prefs_dropdown_from_list(GtkWid
- (type == GAIM_PREF_STRING && stored_str != NULL &&
- !strcmp(stored_str, str_value)) ||
- (type == GAIM_PREF_BOOLEAN &&
-- (gaim_prefs_get_bool(key) == GPOINTER_TO_INT(menuitems->data)))) {
-+ (gaim2_prefs_get_bool(key) == GPOINTER_TO_INT(menuitems->data)))) {
-
- gtk_menu_set_active(GTK_MENU(menu), o);
- }
-@@ -301,7 +301,7 @@ gaim_gtk_prefs_dropdown_from_list(GtkWid
- }
-
- GtkWidget *
--gaim_gtk_prefs_dropdown(GtkWidget *box, const gchar *title, GaimPrefType type,
-+gaim2_gtk_prefs_dropdown(GtkWidget *box, const gchar *title, Gaim2PrefType type,
- const char *key, ...)
- {
- va_list ap;
-@@ -334,7 +334,7 @@ gaim_gtk_prefs_dropdown(GtkWidget *box,
-
- menuitems = g_list_reverse(menuitems);
-
-- dropdown = gaim_gtk_prefs_dropdown_from_list(box, title, type, key,
-+ dropdown = gaim2_gtk_prefs_dropdown_from_list(box, title, type, key,
- menuitems);
-
- g_list_free(menuitems);
-@@ -346,10 +346,10 @@ static void
- delete_prefs(GtkWidget *asdf, void *gdsa)
- {
- /* Close any "select sound" request dialogs */
-- gaim_request_close_with_handle(prefs);
-+ gaim2_request_close_with_handle(prefs);
-
- /* Unregister callbacks. */
-- gaim_prefs_disconnect_by_handle(prefs);
-+ gaim2_prefs_disconnect_by_handle(prefs);
-
- prefs = NULL;
- sound_entry = NULL;
-@@ -378,7 +378,7 @@ static void smiley_sel(GtkTreeSelection
- gtk_tree_model_get_value(model, &iter, 3, &val);
- path = gtk_tree_model_get_path(model, &iter);
- themename = g_value_get_string(&val);
-- gaim_prefs_set_string("/gaim/gtk/smileys/theme", themename);
-+ gaim2_prefs_set_string("/gaim2/gtk/smileys/theme", themename);
- g_value_unset (&val);
-
- /* current_smiley_theme is set in callback for the above pref change */
-@@ -418,7 +418,7 @@ static GtkTreeRowReference *theme_refres
- gtk_tree_row_reference_free(previous_smiley_row);
- previous_smiley_row = NULL;
-
-- gaim_gtkthemes_smiley_theme_probe();
-+ gaim2_gtkthemes_smiley_theme_probe();
-
- if (!(themes = smiley_themes))
- return NULL;
-@@ -482,7 +482,7 @@ static void theme_install_theme(char *pa
- else if ((tail = strrchr(path, '.')) == NULL)
- return;
-
-- destdir = g_strconcat(gaim_user_dir(), G_DIR_SEPARATOR_S "smileys", NULL);
-+ destdir = g_strconcat(gaim2_user_dir(), G_DIR_SEPARATOR_S "smileys", NULL);
-
- /* We'll check this just to make sure. This also lets us do something different on
- * other platforms, if need be */
-@@ -494,7 +494,7 @@ static void theme_install_theme(char *pa
- g_free(path_escaped);
- g_free(destdir_escaped);
- #else
-- if(!wgaim_gz_untar(path, destdir)) {
-+ if(!wgaim2_gz_untar(path, destdir)) {
- g_free(destdir);
- return;
- }
-@@ -509,7 +509,7 @@ static void theme_install_theme(char *pa
- /* Fire! */
- if (system(command))
- {
-- gaim_notify_error(NULL, NULL, _("Smiley theme failed to unpack."), NULL);
-+ gaim2_notify_error(NULL, NULL, _("Smiley theme failed to unpack."), NULL);
- }
-
- g_free(command);
-@@ -527,7 +527,7 @@ theme_got_url(void *data, const char *th
- FILE *f;
- gchar *path;
-
-- f = gaim_mkstemp(&path, TRUE);
-+ f = gaim2_mkstemp(&path, TRUE);
- fwrite(themedata, len, 1, f);
- fclose(f);
-
-@@ -551,7 +551,7 @@ static void theme_dnd_recv(GtkWidget *wi
- /* 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, "theme dnd", "%s\n",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "theme dnd", "%s\n",
- (converr ? converr->message :
- "g_filename_from_uri error"));
- return;
-@@ -568,7 +568,7 @@ static void theme_dnd_recv(GtkWidget *wi
-
- /* We'll check this just to make sure. This also lets us do something different on
- * other platforms, if need be */
-- gaim_url_fetch(name, TRUE, NULL, FALSE, theme_got_url, ".tgz");
-+ gaim2_url_fetch(name, TRUE, NULL, FALSE, theme_got_url, ".tgz");
- }
-
- gtk_drag_finish(dc, TRUE, FALSE, t);
-@@ -578,7 +578,7 @@ static void theme_dnd_recv(GtkWidget *wi
- }
-
- /* Does same as normal sort, except "none" is sorted first */
--static gint gaim_sort_smileys (GtkTreeModel *model,
-+static gint gaim2_sort_smileys (GtkTreeModel *model,
- GtkTreeIter *a,
- GtkTreeIter *b,
- gpointer userdata)
-@@ -658,7 +658,7 @@ theme_page()
-
- /* Custom sort so "none" theme is at top of list */
- gtk_tree_sortable_set_sort_func(GTK_TREE_SORTABLE(smiley_theme_store),
-- 3, gaim_sort_smileys, NULL, NULL);
-+ 3, gaim2_sort_smileys, NULL, NULL);
-
- gtk_tree_sortable_set_sort_column_id(GTK_TREE_SORTABLE(smiley_theme_store),
- 3, GTK_SORT_ASCENDING);
-@@ -689,7 +689,7 @@ theme_page()
-
- gtk_widget_show_all(ret);
-
-- gaim_set_accessible_label (view, label);
-+ gaim2_set_accessible_label (view, label);
-
- return ret;
- }
-@@ -704,21 +704,21 @@ formatting_toggle_cb(GtkIMHtml *imhtml,
- &bold, &italic, &uline);
-
- if (buttons & GTK_IMHTML_BOLD)
-- gaim_prefs_set_bool("/gaim/gtk/conversations/send_bold", bold);
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/send_bold", bold);
- if (buttons & GTK_IMHTML_ITALIC)
-- gaim_prefs_set_bool("/gaim/gtk/conversations/send_italic", italic);
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/send_italic", italic);
- if (buttons & GTK_IMHTML_UNDERLINE)
-- gaim_prefs_set_bool("/gaim/gtk/conversations/send_underline", uline);
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/send_underline", uline);
-
- if (buttons & GTK_IMHTML_GROW || buttons & GTK_IMHTML_SHRINK)
-- gaim_prefs_set_int("/gaim/gtk/conversations/font_size",
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/font_size",
- gtk_imhtml_get_current_fontsize(GTK_IMHTML(imhtml)));
- if (buttons & GTK_IMHTML_FACE) {
- char *face = gtk_imhtml_get_current_fontface(GTK_IMHTML(imhtml));
- if (!face)
- face = g_strdup("");
-
-- gaim_prefs_set_string("/gaim/gtk/conversations/font_face", face);
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/font_face", face);
- g_free(face);
- }
-
-@@ -727,7 +727,7 @@ formatting_toggle_cb(GtkIMHtml *imhtml,
- if (!color)
- color = g_strdup("");
-
-- gaim_prefs_set_string("/gaim/gtk/conversations/fgcolor", color);
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/fgcolor", color);
- g_free(color);
- }
-
-@@ -761,7 +761,7 @@ formatting_toggle_cb(GtkIMHtml *imhtml,
- if (!color)
- color = g_strdup("");
-
-- gaim_prefs_set_string("/gaim/gtk/conversations/bgcolor", color);
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/bgcolor", color);
- g_free(color);
- }
- }
-@@ -769,19 +769,19 @@ formatting_toggle_cb(GtkIMHtml *imhtml,
- static void
- formatting_clear_cb(GtkIMHtml *imhtml, void *data)
- {
-- gaim_prefs_set_bool("/gaim/gtk/conversations/send_bold", FALSE);
-- gaim_prefs_set_bool("/gaim/gtk/conversations/send_italic", FALSE);
-- gaim_prefs_set_bool("/gaim/gtk/conversations/send_underline", FALSE);
--
-- gaim_prefs_set_int("/gaim/gtk/conversations/font_size", 3);
--
-- gaim_prefs_set_string("/gaim/gtk/conversations/font_face", "");
-- gaim_prefs_set_string("/gaim/gtk/conversations/fgcolor", "");
-- gaim_prefs_set_string("/gaim/gtk/conversations/bgcolor", "");
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/send_bold", FALSE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/send_italic", FALSE);
-+ gaim2_prefs_set_bool("/gaim2/gtk/conversations/send_underline", FALSE);
-+
-+ gaim2_prefs_set_int("/gaim2/gtk/conversations/font_size", 3);
-+
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/font_face", "");
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/fgcolor", "");
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/bgcolor", "");
- }
-
- static void
--conversation_usetabs_cb(const char *name, GaimPrefType type, gpointer value,
-+conversation_usetabs_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- gboolean usetabs = GPOINTER_TO_INT(value);
-@@ -810,40 +810,40 @@ conv_page()
- ret = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
- gtk_container_set_border_width(GTK_CONTAINER(ret), GAIM_HIG_BORDER);
-
-- vbox = gaim_gtk_make_frame(ret, _("Conversations"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Conversations"));
-
-- gaim_gtk_prefs_dropdown(vbox, _("_Hide new IM conversations"),
-- GAIM_PREF_STRING, "/gaim/gtk/conversations/im/hide_new",
-+ gaim2_gtk_prefs_dropdown(vbox, _("_Hide new IM conversations"),
-+ GAIM_PREF_STRING, "/gaim2/gtk/conversations/im/hide_new",
- _("Never"), "never",
- _("When away"), "away",
- _("Always"), "always",
- NULL);
-
-- gaim_gtk_prefs_checkbox(_("Send unknown \"_slash\" commands as messages"),
-- "/gaim/gtk/conversations/passthrough_unknown_commands", vbox);
-- gaim_gtk_prefs_checkbox(_("Show _formatting on incoming messages"),
-- "/gaim/gtk/conversations/show_incoming_formatting", vbox);
--
-- iconpref1 = gaim_gtk_prefs_checkbox(_("Show buddy _icons"),
-- "/gaim/gtk/conversations/im/show_buddy_icons", vbox);
-- iconpref2 = gaim_gtk_prefs_checkbox(_("Enable buddy ic_on animation"),
-- "/gaim/gtk/conversations/im/animate_buddy_icons", vbox);
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/im/show_buddy_icons"))
-+ gaim2_gtk_prefs_checkbox(_("Send unknown \"_slash\" commands as messages"),
-+ "/gaim2/gtk/conversations/passthrough_unknown_commands", vbox);
-+ gaim2_gtk_prefs_checkbox(_("Show _formatting on incoming messages"),
-+ "/gaim2/gtk/conversations/show_incoming_formatting", vbox);
-+
-+ iconpref1 = gaim2_gtk_prefs_checkbox(_("Show buddy _icons"),
-+ "/gaim2/gtk/conversations/im/show_buddy_icons", vbox);
-+ iconpref2 = gaim2_gtk_prefs_checkbox(_("Enable buddy ic_on animation"),
-+ "/gaim2/gtk/conversations/im/animate_buddy_icons", vbox);
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/im/show_buddy_icons"))
- gtk_widget_set_sensitive(iconpref2, FALSE);
- g_signal_connect(G_OBJECT(iconpref1), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), iconpref2);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), iconpref2);
-
-- gaim_gtk_prefs_checkbox(_("_Notify buddies that you are typing to them"),
-+ gaim2_gtk_prefs_checkbox(_("_Notify buddies that you are typing to them"),
- "/core/conversations/im/send_typing", vbox);
- #ifdef USE_GTKSPELL
-- gaim_gtk_prefs_checkbox(_("Highlight _misspelled words"),
-- "/gaim/gtk/conversations/spellcheck", vbox);
-+ gaim2_gtk_prefs_checkbox(_("Highlight _misspelled words"),
-+ "/gaim2/gtk/conversations/spellcheck", vbox);
- #endif
-
-- gaim_gtk_prefs_checkbox(_("Use smooth-scrolling"), "/gaim/gtk/conversations/use_smooth_scrolling", vbox);
-+ gaim2_gtk_prefs_checkbox(_("Use smooth-scrolling"), "/gaim2/gtk/conversations/use_smooth_scrolling", vbox);
-
-- frame = gaim_gtk_create_imhtml(TRUE, &imhtml, &toolbar);
-- gtk_widget_set_name(imhtml, "gaim_gtkprefs_font_imhtml");
-+ frame = gaim2_gtk_create_imhtml(TRUE, &imhtml, &toolbar);
-+ gtk_widget_set_name(imhtml, "gaim2_gtkprefs_font_imhtml");
- gtk_imhtml_set_whole_buffer_formatting_only(GTK_IMHTML(imhtml), TRUE);
- gtk_imhtml_set_format_functions(GTK_IMHTML(imhtml),
- GTK_IMHTML_BOLD |
-@@ -860,17 +860,17 @@ conv_page()
-
- gtk_box_pack_start(GTK_BOX(vbox), frame, FALSE, FALSE, 0);
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/send_bold"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/send_bold"))
- gtk_imhtml_toggle_bold(GTK_IMHTML(imhtml));
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/send_italic"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/send_italic"))
- gtk_imhtml_toggle_italic(GTK_IMHTML(imhtml));
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/send_underline"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/send_underline"))
- gtk_imhtml_toggle_underline(GTK_IMHTML(imhtml));
-
-- gtk_imhtml_font_set_size(GTK_IMHTML(imhtml), gaim_prefs_get_int("/gaim/gtk/conversations/font_size"));
-- gtk_imhtml_toggle_forecolor(GTK_IMHTML(imhtml), gaim_prefs_get_string("/gaim/gtk/conversations/fgcolor"));
-- gtk_imhtml_toggle_background(GTK_IMHTML(imhtml), gaim_prefs_get_string("/gaim/gtk/conversations/bgcolor"));
-- gtk_imhtml_toggle_fontface(GTK_IMHTML(imhtml), gaim_prefs_get_string("/gaim/gtk/conversations/font_face"));
-+ gtk_imhtml_font_set_size(GTK_IMHTML(imhtml), gaim2_prefs_get_int("/gaim2/gtk/conversations/font_size"));
-+ gtk_imhtml_toggle_forecolor(GTK_IMHTML(imhtml), gaim2_prefs_get_string("/gaim2/gtk/conversations/fgcolor"));
-+ gtk_imhtml_toggle_background(GTK_IMHTML(imhtml), gaim2_prefs_get_string("/gaim2/gtk/conversations/bgcolor"));
-+ gtk_imhtml_toggle_fontface(GTK_IMHTML(imhtml), gaim2_prefs_get_string("/gaim2/gtk/conversations/font_face"));
-
- g_signal_connect_after(G_OBJECT(imhtml), "format_function_toggle",
- G_CALLBACK(formatting_toggle_cb), toolbar);
-@@ -878,10 +878,10 @@ conv_page()
- G_CALLBACK(formatting_clear_cb), NULL);
-
- /* All the tab options! */
-- vbox = gaim_gtk_make_frame(ret, _("Tab Options"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Tab Options"));
-
-- gaim_gtk_prefs_checkbox(_("Show IMs and chats in _tabbed windows"),
-- "/gaim/gtk/conversations/tabs", vbox);
-+ gaim2_gtk_prefs_checkbox(_("Show IMs and chats in _tabbed windows"),
-+ "/gaim2/gtk/conversations/tabs", vbox);
-
- /*
- * Connect a signal to the above preference. When conversations are not
-@@ -889,19 +889,19 @@ conv_page()
- */
- vbox2 = gtk_vbox_new(FALSE, 9);
- gtk_box_pack_start(GTK_BOX(vbox), vbox2, FALSE, FALSE, 0);
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/conversations/tabs",
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/conversations/tabs",
- conversation_usetabs_cb, vbox2);
-- if (!gaim_prefs_get_bool("/gaim/gtk/conversations/tabs"))
-+ if (!gaim2_prefs_get_bool("/gaim2/gtk/conversations/tabs"))
- gtk_widget_set_sensitive(vbox2, FALSE);
-
-- gaim_gtk_prefs_checkbox(_("Show close b_utton on tabs"),
-- "/gaim/gtk/conversations/close_on_tabs", vbox2);
-+ gaim2_gtk_prefs_checkbox(_("Show close b_utton on tabs"),
-+ "/gaim2/gtk/conversations/close_on_tabs", vbox2);
-
- hbox = gtk_hbox_new(FALSE, 9);
- gtk_box_pack_start(GTK_BOX(vbox2), hbox, FALSE, FALSE, 0);
-
-- label = gaim_gtk_prefs_dropdown(hbox, _("_Placement:"), GAIM_PREF_INT,
-- "/gaim/gtk/conversations/tab_side",
-+ label = gaim2_gtk_prefs_dropdown(hbox, _("_Placement:"), GAIM_PREF_INT,
-+ "/gaim2/gtk/conversations/tab_side",
- _("Top"), GTK_POS_TOP,
- _("Bottom"), GTK_POS_BOTTOM,
- _("Left"), GTK_POS_LEFT,
-@@ -912,9 +912,9 @@ conv_page()
- #endif
- NULL);
-
-- names = gaim_gtkconv_placement_get_options();
-- label = gaim_gtk_prefs_dropdown_from_list(hbox, _("N_ew conversations:"),
-- GAIM_PREF_STRING, "/gaim/gtk/conversations/placement", names);
-+ names = gaim2_gtkconv_placement_get_options();
-+ label = gaim2_gtk_prefs_dropdown_from_list(hbox, _("N_ew conversations:"),
-+ GAIM_PREF_STRING, "/gaim2/gtk/conversations/placement", names);
- g_list_free(names);
-
- gtk_widget_show_all(ret);
-@@ -924,11 +924,11 @@ conv_page()
-
- static void network_ip_changed(GtkEntry *entry, gpointer data)
- {
-- gaim_network_set_public_ip(gtk_entry_get_text(entry));
-+ gaim2_network_set_public_ip(gtk_entry_get_text(entry));
- }
-
- static void
--proxy_changed_cb(const char *name, GaimPrefType type, gpointer value,
-+proxy_changed_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GtkWidget *frame = data;
-@@ -943,13 +943,13 @@ proxy_changed_cb(const char *name, GaimP
- static void proxy_print_option(GtkEntry *entry, int entrynum)
- {
- if (entrynum == PROXYHOST)
-- gaim_prefs_set_string("/core/proxy/host", gtk_entry_get_text(entry));
-+ gaim2_prefs_set_string("/core/proxy/host", gtk_entry_get_text(entry));
- else if (entrynum == PROXYPORT)
-- gaim_prefs_set_int("/core/proxy/port", atoi(gtk_entry_get_text(entry)));
-+ gaim2_prefs_set_int("/core/proxy/port", atoi(gtk_entry_get_text(entry)));
- else if (entrynum == PROXYUSER)
-- gaim_prefs_set_string("/core/proxy/username", gtk_entry_get_text(entry));
-+ gaim2_prefs_set_string("/core/proxy/username", gtk_entry_get_text(entry));
- else if (entrynum == PROXYPASS)
-- gaim_prefs_set_string("/core/proxy/password", gtk_entry_get_text(entry));
-+ gaim2_prefs_set_string("/core/proxy/password", gtk_entry_get_text(entry));
- }
-
- static GtkWidget *
-@@ -959,16 +959,16 @@ network_page()
- GtkWidget *vbox, *hbox, *entry;
- GtkWidget *table, *label, *auto_ip_checkbox, *ports_checkbox, *spin_button, *stun_server_entry;
- GtkSizeGroup *sg;
-- GaimProxyInfo *proxy_info = NULL;
-+ Gaim2ProxyInfo *proxy_info = NULL;
-
- ret = gtk_vbox_new(FALSE, GAIM_HIG_BOX_SPACE);
- gtk_container_set_border_width (GTK_CONTAINER (ret), GAIM_HIG_BORDER);
-
-- vbox = gaim_gtk_make_frame (ret, _("IP Address"));
-+ vbox = gaim2_gtk_make_frame (ret, _("IP Address"));
-
-- stun_server_entry = gaim_gtk_prefs_labeled_entry(vbox,_("ST_UN server:"), "/core/network/stun_server", NULL);
-+ stun_server_entry = gaim2_gtk_prefs_labeled_entry(vbox,_("ST_UN server:"), "/core/network/stun_server", NULL);
-
-- auto_ip_checkbox = gaim_gtk_prefs_checkbox(_("_Autodetect IP address"),
-+ auto_ip_checkbox = gaim2_gtk_prefs_checkbox(_("_Autodetect IP address"),
- "/core/network/auto_ip", vbox);
-
- table = gtk_table_new(2, 1, FALSE);
-@@ -987,44 +987,44 @@ network_page()
- g_signal_connect(G_OBJECT(entry), "changed",
- G_CALLBACK(network_ip_changed), NULL);
-
-- if (gaim_network_get_public_ip() != NULL)
-+ if (gaim2_network_get_public_ip() != NULL)
- gtk_entry_set_text(GTK_ENTRY(entry),
-- gaim_network_get_public_ip());
-+ gaim2_network_get_public_ip());
-
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
-
-
-- if (gaim_prefs_get_bool("/core/network/auto_ip")) {
-+ if (gaim2_prefs_get_bool("/core/network/auto_ip")) {
- gtk_widget_set_sensitive(GTK_WIDGET(table), FALSE);
- }
-
- g_signal_connect(G_OBJECT(auto_ip_checkbox), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), table);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), table);
-
-- vbox = gaim_gtk_make_frame (ret, _("Ports"));
-+ vbox = gaim2_gtk_make_frame (ret, _("Ports"));
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
-- ports_checkbox = gaim_gtk_prefs_checkbox(_("_Manually specify range of ports to listen on"),
-+ ports_checkbox = gaim2_gtk_prefs_checkbox(_("_Manually specify range of ports to listen on"),
- "/core/network/ports_range_use", vbox);
-
-- spin_button = gaim_gtk_prefs_labeled_spin_button(vbox, _("_Start port:"),
-+ spin_button = gaim2_gtk_prefs_labeled_spin_button(vbox, _("_Start port:"),
- "/core/network/ports_range_start", 0, 65535, sg);
-- if (!gaim_prefs_get_bool("/core/network/ports_range_use"))
-+ if (!gaim2_prefs_get_bool("/core/network/ports_range_use"))
- gtk_widget_set_sensitive(GTK_WIDGET(spin_button), FALSE);
- g_signal_connect(G_OBJECT(ports_checkbox), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), spin_button);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), spin_button);
-
-- spin_button = gaim_gtk_prefs_labeled_spin_button(vbox, _("_End port:"),
-+ spin_button = gaim2_gtk_prefs_labeled_spin_button(vbox, _("_End port:"),
- "/core/network/ports_range_end", 0, 65535, sg);
-- if (!gaim_prefs_get_bool("/core/network/ports_range_use"))
-+ if (!gaim2_prefs_get_bool("/core/network/ports_range_use"))
- gtk_widget_set_sensitive(GTK_WIDGET(spin_button), FALSE);
- g_signal_connect(G_OBJECT(ports_checkbox), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), spin_button);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), spin_button);
-
-- if (!gaim_running_gnome()) {
-- vbox = gaim_gtk_make_frame(ret, _("Proxy Server"));
-+ if (!gaim2_running_gnome()) {
-+ vbox = gaim2_gtk_make_frame(ret, _("Proxy Server"));
- prefs_proxy_frame = gtk_vbox_new(FALSE, 0);
-- gaim_gtk_prefs_dropdown(vbox, _("Proxy _type:"), GAIM_PREF_STRING,
-+ gaim2_gtk_prefs_dropdown(vbox, _("Proxy _type:"), GAIM_PREF_STRING,
- "/core/proxy/type",
- _("No proxy"), "none",
- "SOCKS 4", "socks4",
-@@ -1033,9 +1033,9 @@ network_page()
- _("Use Environmental Settings"), "envvar",
- NULL);
- gtk_box_pack_start(GTK_BOX(vbox), prefs_proxy_frame, 0, 0, 0);
-- proxy_info = gaim_global_proxy_get_info();
-+ proxy_info = gaim2_global_proxy_get_info();
-
-- gaim_prefs_connect_callback(prefs, "/core/proxy/type",
-+ gaim2_prefs_connect_callback(prefs, "/core/proxy/type",
- proxy_changed_cb, prefs_proxy_frame);
-
- table = gtk_table_new(4, 2, FALSE);
-@@ -1055,13 +1055,13 @@ network_page()
- g_signal_connect(G_OBJECT(entry), "changed",
- G_CALLBACK(proxy_print_option), (void *)PROXYHOST);
-
-- if (proxy_info != NULL && gaim_proxy_info_get_host(proxy_info))
-+ if (proxy_info != NULL && gaim2_proxy_info_get_host(proxy_info))
- gtk_entry_set_text(GTK_ENTRY(entry),
-- gaim_proxy_info_get_host(proxy_info));
-+ gaim2_proxy_info_get_host(proxy_info));
-
- hbox = gtk_hbox_new(TRUE, 5);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
-
- label = gtk_label_new_with_mnemonic(_("_Port:"));
- gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5);
-@@ -1073,14 +1073,14 @@ network_page()
- g_signal_connect(G_OBJECT(entry), "changed",
- G_CALLBACK(proxy_print_option), (void *)PROXYPORT);
-
-- if (proxy_info != NULL && gaim_proxy_info_get_port(proxy_info) != 0) {
-+ if (proxy_info != NULL && gaim2_proxy_info_get_port(proxy_info) != 0) {
- char buf[128];
- g_snprintf(buf, sizeof(buf), "%d",
-- gaim_proxy_info_get_port(proxy_info));
-+ gaim2_proxy_info_get_port(proxy_info));
-
- gtk_entry_set_text(GTK_ENTRY(entry), buf);
- }
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
-
- label = gtk_label_new_with_mnemonic(_("_User:"));
- gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5);
-@@ -1092,13 +1092,13 @@ network_page()
- g_signal_connect(G_OBJECT(entry), "changed",
- G_CALLBACK(proxy_print_option), (void *)PROXYUSER);
-
-- if (proxy_info != NULL && gaim_proxy_info_get_username(proxy_info) != NULL)
-+ if (proxy_info != NULL && gaim2_proxy_info_get_username(proxy_info) != NULL)
- gtk_entry_set_text(GTK_ENTRY(entry),
-- gaim_proxy_info_get_username(proxy_info));
-+ gaim2_proxy_info_get_username(proxy_info));
-
- hbox = gtk_hbox_new(TRUE, 5);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
-
- label = gtk_label_new_with_mnemonic(_("Pa_ssword:"));
- gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5);
-@@ -1112,16 +1112,16 @@ network_page()
- g_signal_connect(G_OBJECT(entry), "changed",
- G_CALLBACK(proxy_print_option), (void *)PROXYPASS);
-
-- if (proxy_info != NULL && gaim_proxy_info_get_password(proxy_info) != NULL)
-+ if (proxy_info != NULL && gaim2_proxy_info_get_password(proxy_info) != NULL)
- gtk_entry_set_text(GTK_ENTRY(entry),
-- gaim_proxy_info_get_password(proxy_info));
-- gaim_set_accessible_label (entry, label);
-+ gaim2_proxy_info_get_password(proxy_info));
-+ gaim2_set_accessible_label (entry, label);
- }
-
- gtk_widget_show_all(ret);
- if (proxy_info == NULL ||
-- gaim_proxy_info_get_type(proxy_info) == GAIM_PROXY_NONE ||
-- gaim_proxy_info_get_type(proxy_info) == GAIM_PROXY_USE_ENVVAR)
-+ gaim2_proxy_info_get_type(proxy_info) == GAIM_PROXY_NONE ||
-+ gaim2_proxy_info_get_type(proxy_info) == GAIM_PROXY_USE_ENVVAR)
- gtk_widget_hide(table);
- return ret;
- }
-@@ -1130,7 +1130,7 @@ network_page()
- static gboolean manual_browser_set(GtkWidget *entry, GdkEventFocus *event, gpointer data) {
- const char *program = gtk_entry_get_text(GTK_ENTRY(entry));
-
-- gaim_prefs_set_string("/gaim/gtk/browsers/command", program);
-+ gaim2_prefs_set_string("/gaim2/gtk/browsers/command", program);
-
- /* carry on normally */
- return FALSE;
-@@ -1158,13 +1158,13 @@ static GList *get_available_browsers()
-
- GList *browsers = NULL;
- int i = 0;
-- char *browser_setting = (char *)gaim_prefs_get_string("/gaim/gtk/browsers/browser");
-+ char *browser_setting = (char *)gaim2_prefs_get_string("/gaim2/gtk/browsers/browser");
-
- browsers = g_list_prepend(browsers, "custom");
- browsers = g_list_prepend(browsers, _("Manual"));
-
- for (i = 0; i < num_possible_browsers; i++) {
-- if (gaim_program_is_valid(possible_browsers[i].command)) {
-+ if (gaim2_program_is_valid(possible_browsers[i].command)) {
- browsers = g_list_prepend(browsers,
- possible_browsers[i].command);
- browsers = g_list_prepend(browsers, _(possible_browsers[i].name));
-@@ -1174,13 +1174,13 @@ static GList *get_available_browsers()
- }
-
- if(browser_setting)
-- gaim_prefs_set_string("/gaim/gtk/browsers/browser", "custom");
-+ gaim2_prefs_set_string("/gaim2/gtk/browsers/browser", "custom");
-
- return browsers;
- }
-
- static void
--browser_changed1_cb(const char *name, GaimPrefType type, gpointer value,
-+browser_changed1_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GtkWidget *hbox = data;
-@@ -1190,7 +1190,7 @@ browser_changed1_cb(const char *name, Ga
- }
-
- static void
--browser_changed2_cb(const char *name, GaimPrefType type, gpointer value,
-+browser_changed2_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GtkWidget *hbox = data;
-@@ -1214,20 +1214,20 @@ browser_page()
- gtk_container_set_border_width (GTK_CONTAINER (ret), GAIM_HIG_BORDER);
-
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-- vbox = gaim_gtk_make_frame (ret, _("Browser Selection"));
-+ vbox = gaim2_gtk_make_frame (ret, _("Browser Selection"));
-
- browsers = get_available_browsers();
- if (browsers != NULL) {
-- label = gaim_gtk_prefs_dropdown_from_list(vbox,_("_Browser:"), GAIM_PREF_STRING,
-- "/gaim/gtk/browsers/browser",
-+ label = gaim2_gtk_prefs_dropdown_from_list(vbox,_("_Browser:"), GAIM_PREF_STRING,
-+ "/gaim2/gtk/browsers/browser",
- browsers);
- g_list_free(browsers);
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
- gtk_size_group_add_widget(sg, label);
-
- hbox = gtk_hbox_new(FALSE, 0);
-- label = gaim_gtk_prefs_dropdown(hbox, _("_Open link in:"), GAIM_PREF_INT,
-- "/gaim/gtk/browsers/place",
-+ label = gaim2_gtk_prefs_dropdown(hbox, _("_Open link in:"), GAIM_PREF_INT,
-+ "/gaim2/gtk/browsers/place",
- _("Browser default"), GAIM_BROWSER_DEFAULT,
- _("Existing window"), GAIM_BROWSER_CURRENT,
- _("New window"), GAIM_BROWSER_NEW_WINDOW,
-@@ -1237,9 +1237,9 @@ browser_page()
- gtk_size_group_add_widget(sg, label);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
-
-- if (!strcmp(gaim_prefs_get_string("/gaim/gtk/browsers/browser"), "custom"))
-+ if (!strcmp(gaim2_prefs_get_string("/gaim2/gtk/browsers/browser"), "custom"))
- gtk_widget_set_sensitive(hbox, FALSE);
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/browsers/browser",
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/browsers/browser",
- browser_changed1_cb, hbox);
- }
-
-@@ -1253,18 +1253,18 @@ browser_page()
- entry = gtk_entry_new();
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), entry);
-
-- if (strcmp(gaim_prefs_get_string("/gaim/gtk/browsers/browser"), "custom"))
-+ if (strcmp(gaim2_prefs_get_string("/gaim2/gtk/browsers/browser"), "custom"))
- gtk_widget_set_sensitive(hbox, FALSE);
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/browsers/browser",
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/browsers/browser",
- browser_changed2_cb, hbox);
-
- gtk_box_pack_start (GTK_BOX (hbox), entry, FALSE, FALSE, 0);
-
- gtk_entry_set_text(GTK_ENTRY(entry),
-- gaim_prefs_get_string("/gaim/gtk/browsers/command"));
-+ gaim2_prefs_get_string("/gaim2/gtk/browsers/command"));
- g_signal_connect(G_OBJECT(entry), "focus-out-event",
- G_CALLBACK(manual_browser_set), NULL);
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
-
- gtk_widget_show_all(ret);
- return ret;
-@@ -1281,22 +1281,22 @@ logging_page()
- ret = gtk_vbox_new(FALSE, GAIM_HIG_CAT_SPACE);
- gtk_container_set_border_width (GTK_CONTAINER (ret), GAIM_HIG_BORDER);
-
-- vbox = gaim_gtk_make_frame (ret, _("Logging"));
-- names = gaim_log_logger_get_options();
-+ vbox = gaim2_gtk_make_frame (ret, _("Logging"));
-+ names = gaim2_log_logger_get_options();
-
-- gaim_gtk_prefs_dropdown_from_list(vbox, _("Log _format:"), GAIM_PREF_STRING,
-+ gaim2_gtk_prefs_dropdown_from_list(vbox, _("Log _format:"), GAIM_PREF_STRING,
- "/core/logging/format", names);
-
- g_list_free(names);
-
-- gaim_gtk_prefs_checkbox(_("Log all _instant messages"),
-+ gaim2_gtk_prefs_checkbox(_("Log all _instant messages"),
- "/core/logging/log_ims", vbox);
-- gaim_gtk_prefs_checkbox(_("Log all c_hats"),
-+ gaim2_gtk_prefs_checkbox(_("Log all c_hats"),
- "/core/logging/log_chats", vbox);
-- gaim_gtk_prefs_checkbox(_("Log all _status changes to system log"),
-+ gaim2_gtk_prefs_checkbox(_("Log all _status changes to system log"),
- "/core/logging/log_system", vbox);
-
-- gaim_gtk_prefs_checkbox(_("Include _date in timestamps"),
-+ gaim2_gtk_prefs_checkbox(_("Include _date in timestamps"),
- "/core/logging/include_date_timestamps", vbox);
-
- gtk_widget_show_all(ret);
-@@ -1307,13 +1307,13 @@ logging_page()
- #ifndef _WIN32
- static gint sound_cmd_yeah(GtkEntry *entry, gpointer d)
- {
-- gaim_prefs_set_string("/gaim/gtk/sound/command",
-+ gaim2_prefs_set_string("/gaim2/gtk/sound/command",
- gtk_entry_get_text(GTK_ENTRY(entry)));
- return TRUE;
- }
-
- static void
--sound_changed1_cb(const char *name, GaimPrefType type, gpointer value,
-+sound_changed1_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GtkWidget *hbox = data;
-@@ -1323,7 +1323,7 @@ sound_changed1_cb(const char *name, Gaim
- }
-
- static void
--sound_changed2_cb(const char *name, GaimPrefType type, gpointer value,
-+sound_changed2_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- GtkWidget *vbox = data;
-@@ -1347,7 +1347,7 @@ event_toggled(GtkCellRendererToggle *cel
- 2, &pref,
- -1);
-
-- gaim_prefs_set_bool(pref, !gtk_cell_renderer_toggle_get_active(cell));
-+ gaim2_prefs_set_bool(pref, !gtk_cell_renderer_toggle_get_active(cell));
- g_free(pref);
-
- gtk_list_store_set(GTK_LIST_STORE (model), &iter,
-@@ -1363,16 +1363,16 @@ test_sound(GtkWidget *button, gpointer i
- char *pref;
- gboolean temp_value;
-
-- pref = g_strdup_printf("/gaim/gtk/sound/enabled/%s",
-- gaim_gtk_sound_get_event_option(sound_row_sel));
-+ pref = g_strdup_printf("/gaim2/gtk/sound/enabled/%s",
-+ gaim2_gtk_sound_get_event_option(sound_row_sel));
-
-- temp_value = gaim_prefs_get_bool(pref);
-+ temp_value = gaim2_prefs_get_bool(pref);
-
-- if (!temp_value) gaim_prefs_set_bool(pref, TRUE);
-+ if (!temp_value) gaim2_prefs_set_bool(pref, TRUE);
-
-- gaim_sound_play_event(sound_row_sel, NULL);
-+ gaim2_sound_play_event(sound_row_sel, NULL);
-
-- if (!temp_value) gaim_prefs_set_bool(pref, FALSE);
-+ if (!temp_value) gaim2_prefs_set_bool(pref, FALSE);
-
- g_free(pref);
- }
-@@ -1385,9 +1385,9 @@ reset_sound(GtkWidget *button, gpointer
- {
- gchar *pref;
-
-- pref = g_strdup_printf("/gaim/gtk/sound/file/%s",
-- gaim_gtk_sound_get_event_option(sound_row_sel));
-- gaim_prefs_set_string(pref, "");
-+ pref = g_strdup_printf("/gaim2/gtk/sound/file/%s",
-+ gaim2_gtk_sound_get_event_option(sound_row_sel));
-+ gaim2_prefs_set_string(pref, "");
- g_free(pref);
-
- gtk_entry_set_text(GTK_ENTRY(sound_entry), "(default)");
-@@ -1402,9 +1402,9 @@ sound_chosen_cb(void *user_data, const c
- sound = GPOINTER_TO_INT(user_data);
-
- /* Set it -- and forget it */
-- pref = g_strdup_printf("/gaim/gtk/sound/file/%s",
-- gaim_gtk_sound_get_event_option(sound));
-- gaim_prefs_set_string(pref, filename);
-+ pref = g_strdup_printf("/gaim2/gtk/sound/file/%s",
-+ gaim2_gtk_sound_get_event_option(sound));
-+ gaim2_prefs_set_string(pref, filename);
- g_free(pref);
-
- /*
-@@ -1420,15 +1420,15 @@ static void select_sound(GtkWidget *butt
- gchar *pref;
- const char *filename;
-
-- pref = g_strdup_printf("/gaim/gtk/sound/file/%s",
-- gaim_gtk_sound_get_event_option(sound_row_sel));
-- filename = gaim_prefs_get_string(pref);
-+ pref = g_strdup_printf("/gaim2/gtk/sound/file/%s",
-+ gaim2_gtk_sound_get_event_option(sound_row_sel));
-+ filename = gaim2_prefs_get_string(pref);
- g_free(pref);
-
- if (*filename == '\0')
- filename = NULL;
-
-- gaim_request_file(prefs, _("Sound Selection"), filename, FALSE,
-+ gaim2_request_file(prefs, _("Sound Selection"), filename, FALSE,
- G_CALLBACK(sound_chosen_cb), NULL, GINT_TO_POINTER(sound_row_sel));
- }
-
-@@ -1445,9 +1445,9 @@ static void prefs_sound_sel(GtkTreeSelec
- gtk_tree_model_get_value (model, &iter, 3, &val);
- sound_row_sel = g_value_get_uint(&val);
-
-- pref = g_strdup_printf("/gaim/gtk/sound/file/%s",
-- gaim_gtk_sound_get_event_option(sound_row_sel));
-- file = gaim_prefs_get_string(pref);
-+ pref = g_strdup_printf("/gaim2/gtk/sound/file/%s",
-+ gaim2_gtk_sound_get_event_option(sound_row_sel));
-+ file = gaim2_prefs_get_string(pref);
- g_free(pref);
- if (sound_entry)
- gtk_entry_set_text(GTK_ENTRY(sound_entry), (file && *file != '\0') ? file : "(default)");
-@@ -1484,9 +1484,9 @@ sound_page()
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
- #ifndef _WIN32
-- vbox = gaim_gtk_make_frame (ret, _("Sound Method"));
-- dd = gaim_gtk_prefs_dropdown(vbox, _("_Method:"), GAIM_PREF_STRING,
-- "/gaim/gtk/sound/method",
-+ vbox = gaim2_gtk_make_frame (ret, _("Sound Method"));
-+ dd = gaim2_gtk_prefs_dropdown(vbox, _("_Method:"), GAIM_PREF_STRING,
-+ "/gaim2/gtk/sound/method",
- _("Console beep"), "beep",
- #ifdef USE_AO
- _("Automatic"), "automatic",
-@@ -1512,7 +1512,7 @@ sound_page()
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), entry);
-
- gtk_editable_set_editable(GTK_EDITABLE(entry), TRUE);
-- cmd = gaim_prefs_get_string("/gaim/gtk/sound/command");
-+ cmd = gaim2_prefs_get_string("/gaim2/gtk/sound/command");
- if(cmd)
- gtk_entry_set_text(GTK_ENTRY(entry), cmd);
-
-@@ -1521,28 +1521,28 @@ sound_page()
- G_CALLBACK(sound_cmd_yeah), NULL);
-
- gtk_widget_set_sensitive(hbox,
-- !strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"),
-+ !strcmp(gaim2_prefs_get_string("/gaim2/gtk/sound/method"),
- "custom"));
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/sound/method",
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/sound/method",
- sound_changed1_cb, hbox);
-
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
- #endif /* _WIN32 */
-
-- vbox = gaim_gtk_make_frame (ret, _("Sound Options"));
-- gaim_gtk_prefs_checkbox(_("Sounds when conversation has _focus"),
-- "/gaim/gtk/sound/conv_focus", vbox);
-- gaim_gtk_prefs_checkbox(_("_Sounds while away"),
-+ vbox = gaim2_gtk_make_frame (ret, _("Sound Options"));
-+ gaim2_gtk_prefs_checkbox(_("Sounds when conversation has _focus"),
-+ "/gaim2/gtk/sound/conv_focus", vbox);
-+ gaim2_gtk_prefs_checkbox(_("_Sounds while away"),
- "/core/sound/while_away", vbox);
-
- #ifndef _WIN32
- gtk_widget_set_sensitive(vbox,
-- strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"), "none"));
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/sound/method",
-+ strcmp(gaim2_prefs_get_string("/gaim2/gtk/sound/method"), "none"));
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/sound/method",
- sound_changed2_cb, vbox);
- #endif
-
-- vbox = gaim_gtk_make_frame(ret, _("Sound Events"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Sound Events"));
-
- /* The following is an ugly hack to make the frame expand so the
- * sound events list is big enough to be usable */
-@@ -1561,9 +1561,9 @@ sound_page()
- event_store = gtk_list_store_new (4, G_TYPE_BOOLEAN, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_UINT);
-
- for (j=0; j < GAIM_NUM_SOUNDS; j++) {
-- char *pref = g_strdup_printf("/gaim/gtk/sound/enabled/%s",
-- gaim_gtk_sound_get_event_option(j));
-- const char *label = gaim_gtk_sound_get_event_label(j);
-+ char *pref = g_strdup_printf("/gaim2/gtk/sound/enabled/%s",
-+ gaim2_gtk_sound_get_event_option(j));
-+ const char *label = gaim2_gtk_sound_get_event_label(j);
-
- if (label == NULL) {
- g_free(pref);
-@@ -1572,7 +1572,7 @@ sound_page()
-
- gtk_list_store_append (event_store, &iter);
- gtk_list_store_set(event_store, &iter,
-- 0, gaim_prefs_get_bool(pref),
-+ 0, gaim2_prefs_get_bool(pref),
- 1, _(label),
- 2, pref,
- 3, j,
-@@ -1611,9 +1611,9 @@ sound_page()
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
- gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
- sound_entry = gtk_entry_new();
-- pref = g_strdup_printf("/gaim/gtk/sound/file/%s",
-- gaim_gtk_sound_get_event_option(0));
-- file = gaim_prefs_get_string(pref);
-+ pref = g_strdup_printf("/gaim2/gtk/sound/file/%s",
-+ gaim2_gtk_sound_get_event_option(0));
-+ file = gaim2_prefs_get_string(pref);
- g_free(pref);
- gtk_entry_set_text(GTK_ENTRY(sound_entry), (file && *file != '\0') ? file : "(default)");
- gtk_editable_set_editable(GTK_EDITABLE(sound_entry), FALSE);
-@@ -1634,8 +1634,8 @@ sound_page()
-
- #ifndef _WIN32
- gtk_widget_set_sensitive(vbox,
-- strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"), "none"));
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/sound/method",
-+ strcmp(gaim2_prefs_get_string("/gaim2/gtk/sound/method"), "none"));
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/sound/method",
- sound_changed2_cb, vbox);
- #endif
-
-@@ -1644,9 +1644,9 @@ sound_page()
-
-
- static void
--set_idle_away(GaimSavedStatus *status)
-+set_idle_away(Gaim2SavedStatus *status)
- {
-- gaim_prefs_set_int("/core/savedstatus/idleaway", gaim_savedstatus_get_creation_time(status));
-+ gaim2_prefs_set_int("/core/savedstatus/idleaway", gaim2_savedstatus_get_creation_time(status));
- }
-
- static GtkWidget *
-@@ -1668,12 +1668,12 @@ away_page()
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
- /* Idle stuff */
-- vbox = gaim_gtk_make_frame(ret, _("Idle"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Idle"));
-
-- dd = gaim_gtk_prefs_dropdown(vbox, _("Idle time _reporting:"),
-+ dd = gaim2_gtk_prefs_dropdown(vbox, _("Idle time _reporting:"),
- GAIM_PREF_STRING, "/core/away/idle_reporting",
- _("None"), "none",
-- _("Account usage"), "gaim",
-+ _("Account usage"), "gaim2",
- #ifdef USE_SCREENSAVER
- _("Mouse movement"), "system",
- #endif
-@@ -1682,9 +1682,9 @@ away_page()
- gtk_misc_set_alignment(GTK_MISC(dd), 0, 0.5);
-
- /* Away stuff */
-- vbox = gaim_gtk_make_frame(ret, _("Away"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Away"));
-
-- dd = gaim_gtk_prefs_dropdown(vbox, _("_Auto-reply:"),
-+ dd = gaim2_gtk_prefs_dropdown(vbox, _("_Auto-reply:"),
- GAIM_PREF_STRING, "/core/away/auto_reply",
- _("Never"), "never",
- _("When away"), "away",
-@@ -1695,16 +1695,16 @@ away_page()
-
- /* Auto-away stuff */
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-- vbox = gaim_gtk_make_frame(ret, _("Auto-away"));
-+ vbox = gaim2_gtk_make_frame(ret, _("Auto-away"));
-
-- button = gaim_gtk_prefs_checkbox(_("Change status when _idle"),
-+ button = gaim2_gtk_prefs_checkbox(_("Change status when _idle"),
- "/core/away/away_when_idle", vbox);
-
-- select = gaim_gtk_prefs_labeled_spin_button(vbox,
-+ select = gaim2_gtk_prefs_labeled_spin_button(vbox,
- _("_Minutes before changing status:"), "/core/away/mins_before_away",
- 1, 24 * 60, sg);
- g_signal_connect(G_OBJECT(button), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), select);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), select);
-
- hbox = gtk_hbox_new(FALSE, 0);
- gtk_container_add(GTK_CONTAINER(vbox), hbox);
-@@ -1713,17 +1713,17 @@ away_page()
- gtk_size_group_add_widget(sg, label);
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
- g_signal_connect(G_OBJECT(button), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), label);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), label);
- gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
-
- /* TODO: Show something useful if we don't have any saved statuses. */
-- menu = gaim_gtk_status_menu(gaim_savedstatus_get_idleaway(), G_CALLBACK(set_idle_away));
-+ menu = gaim2_gtk_status_menu(gaim2_savedstatus_get_idleaway(), G_CALLBACK(set_idle_away));
- gtk_box_pack_start(GTK_BOX(hbox), menu, FALSE, FALSE, 0);
- g_signal_connect(G_OBJECT(button), "clicked",
-- G_CALLBACK(gaim_gtk_toggle_sensitive), menu);
-+ G_CALLBACK(gaim2_gtk_toggle_sensitive), menu);
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), menu);
-
-- if (!gaim_prefs_get_bool("/core/away/away_when_idle")) {
-+ if (!gaim2_prefs_get_bool("/core/away/away_when_idle")) {
- gtk_widget_set_sensitive(GTK_WIDGET(menu), FALSE);
- gtk_widget_set_sensitive(GTK_WIDGET(select), FALSE);
- gtk_widget_set_sensitive(GTK_WIDGET(label), FALSE);
-@@ -1767,7 +1767,7 @@ static void prefs_notebook_init() {
- #ifndef _WIN32
- /* We use the registered default browser in windows */
- /* if the user is running gnome 2.x, hide the browsers tab */
-- if (gaim_running_gnome() == FALSE) {
-+ if (gaim2_running_gnome() == FALSE) {
- prefs_notebook_add_page(_("Browser"), NULL, browser_page(), &p, NULL, notebook_page++);
- }
- #endif
-@@ -1775,7 +1775,7 @@ static void prefs_notebook_init() {
- prefs_notebook_add_page(_("Away / Idle"), NULL, away_page(), &p, NULL, notebook_page++);
- }
-
--void gaim_gtk_prefs_show(void)
-+void gaim2_gtk_prefs_show(void)
- {
- GtkWidget *vbox;
- GtkWidget *bbox;
-@@ -1833,18 +1833,18 @@ void gaim_gtk_prefs_show(void)
- static void
- set_bool_pref(GtkWidget *w, const char *key)
- {
-- gaim_prefs_set_bool(key,
-+ gaim2_prefs_set_bool(key,
- gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(w)));
- }
-
- GtkWidget *
--gaim_gtk_prefs_checkbox(const char *text, const char *key, GtkWidget *page)
-+gaim2_gtk_prefs_checkbox(const char *text, const char *key, GtkWidget *page)
- {
- GtkWidget *button;
-
- button = gtk_check_button_new_with_mnemonic(text);
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button),
-- gaim_prefs_get_bool(key));
-+ gaim2_prefs_get_bool(key));
-
- gtk_box_pack_start(GTK_BOX(page), button, FALSE, FALSE, 0);
-
-@@ -1857,7 +1857,7 @@ gaim_gtk_prefs_checkbox(const char *text
- }
-
- static void
--smiley_theme_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+smiley_theme_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- const char *themename = value;
-@@ -1866,107 +1866,107 @@ smiley_theme_pref_cb(const char *name, G
- for (themes = smiley_themes; themes; themes = themes->next) {
- struct smiley_theme *smile = themes->data;
- if (smile->name && strcmp(themename, smile->name) == 0) {
-- gaim_gtkthemes_load_smiley_theme(smile->path, TRUE);
-+ gaim2_gtkthemes_load_smiley_theme(smile->path, TRUE);
- break;
- }
- }
- }
-
- void
--gaim_gtk_prefs_init(void)
-+gaim2_gtk_prefs_init(void)
- {
-- gaim_prefs_add_none("/gaim");
-- gaim_prefs_add_none("/gaim/gtk");
-- gaim_prefs_add_none("/plugins/gtk");
-+ gaim2_prefs_add_none("/gaim2");
-+ gaim2_prefs_add_none("/gaim2/gtk");
-+ gaim2_prefs_add_none("/plugins/gtk");
-
- #ifndef _WIN32
- /* Browsers */
-- gaim_prefs_add_none("/gaim/gtk/browsers");
-- gaim_prefs_add_int("/gaim/gtk/browsers/place", GAIM_BROWSER_DEFAULT);
-- gaim_prefs_add_string("/gaim/gtk/browsers/command", "");
-- gaim_prefs_add_string("/gaim/gtk/browsers/browser", "mozilla");
-+ gaim2_prefs_add_none("/gaim2/gtk/browsers");
-+ gaim2_prefs_add_int("/gaim2/gtk/browsers/place", GAIM_BROWSER_DEFAULT);
-+ gaim2_prefs_add_string("/gaim2/gtk/browsers/command", "");
-+ gaim2_prefs_add_string("/gaim2/gtk/browsers/browser", "mozilla");
- #endif
-
- /* Plugins */
-- gaim_prefs_add_none("/gaim/gtk/plugins");
-- gaim_prefs_add_string_list("/gaim/gtk/plugins/loaded", NULL);
-+ gaim2_prefs_add_none("/gaim2/gtk/plugins");
-+ gaim2_prefs_add_string_list("/gaim2/gtk/plugins/loaded", NULL);
-
- /* File locations */
-- gaim_prefs_add_none("/gaim/gtk/filelocations");
-- gaim_prefs_add_string("/gaim/gtk/filelocations/last_save_folder", "");
-- gaim_prefs_add_string("/gaim/gtk/filelocations/last_open_folder", "");
-- gaim_prefs_add_string("/gaim/gtk/filelocations/last_icon_folder", "");
-+ gaim2_prefs_add_none("/gaim2/gtk/filelocations");
-+ gaim2_prefs_add_string("/gaim2/gtk/filelocations/last_save_folder", "");
-+ gaim2_prefs_add_string("/gaim2/gtk/filelocations/last_open_folder", "");
-+ gaim2_prefs_add_string("/gaim2/gtk/filelocations/last_icon_folder", "");
-
- /* Smiley Themes */
-- gaim_prefs_add_none("/gaim/gtk/smileys");
-- gaim_prefs_add_string("/gaim/gtk/smileys/theme", "Default");
-+ gaim2_prefs_add_none("/gaim2/gtk/smileys");
-+ gaim2_prefs_add_string("/gaim2/gtk/smileys/theme", "Default");
-
- /* Smiley Callbacks */
-- gaim_prefs_connect_callback(prefs, "/gaim/gtk/smileys/theme",
-+ gaim2_prefs_connect_callback(prefs, "/gaim2/gtk/smileys/theme",
- smiley_theme_pref_cb, NULL);
- }
-
--void gaim_gtk_prefs_update_old() {
-+void gaim2_gtk_prefs_update_old() {
- /* Rename some old prefs */
-- gaim_prefs_rename("/gaim/gtk/logging/log_ims", "/core/logging/log_ims");
-- gaim_prefs_rename("/gaim/gtk/logging/log_chats", "/core/logging/log_chats");
-- gaim_prefs_rename("/core/conversations/placement",
-- "/gaim/gtk/conversations/placement");
-+ gaim2_prefs_rename("/gaim2/gtk/logging/log_ims", "/core/logging/log_ims");
-+ gaim2_prefs_rename("/gaim2/gtk/logging/log_chats", "/core/logging/log_chats");
-+ gaim2_prefs_rename("/core/conversations/placement",
-+ "/gaim2/gtk/conversations/placement");
-
-- gaim_prefs_rename("/gaim/gtk/debug/timestamps", "/core/debug/timestamps");
-- gaim_prefs_rename("/gaim/gtk/conversations/im/raise_on_events", "/plugins/gtk/X11/notify/method_raise");
-+ gaim2_prefs_rename("/gaim2/gtk/debug/timestamps", "/core/debug/timestamps");
-+ gaim2_prefs_rename("/gaim2/gtk/conversations/im/raise_on_events", "/plugins/gtk/X11/notify/method_raise");
-
-- gaim_prefs_rename_boolean_toggle("/gaim/gtk/conversations/ignore_colors",
-- "/gaim/gtk/conversations/show_incoming_formatting");
-+ gaim2_prefs_rename_boolean_toggle("/gaim2/gtk/conversations/ignore_colors",
-+ "/gaim2/gtk/conversations/show_incoming_formatting");
-
- /* this string pref moved into the core, try to be friendly */
-- gaim_prefs_rename("/gaim/gtk/idle/reporting_method", "/core/away/idle_reporting");
-+ gaim2_prefs_rename("/gaim2/gtk/idle/reporting_method", "/core/away/idle_reporting");
-
- /* Remove some no-longer-used prefs */
-- gaim_prefs_remove("/gaim/gtk/blist/auto_expand_contacts");
-- gaim_prefs_remove("/gaim/gtk/blist/button_style");
-- gaim_prefs_remove("/gaim/gtk/blist/grey_idle_buddies");
-- gaim_prefs_remove("/gaim/gtk/blist/raise_on_events");
-- gaim_prefs_remove("/gaim/gtk/blist/show_group_count");
-- gaim_prefs_remove("/gaim/gtk/blist/show_warning_level");
-- gaim_prefs_remove("/gaim/gtk/conversations/button_type");
-- gaim_prefs_remove("/gaim/gtk/conversations/ctrl_enter_sends");
-- gaim_prefs_remove("/gaim/gtk/conversations/enter_sends");
-- gaim_prefs_remove("/gaim/gtk/conversations/escape_closes");
-- gaim_prefs_remove("/gaim/gtk/conversations/html_shortcuts");
-- gaim_prefs_remove("/gaim/gtk/conversations/icons_on_tabs");
-- gaim_prefs_remove("/gaim/gtk/conversations/send_formatting");
-- gaim_prefs_remove("/gaim/gtk/conversations/show_smileys");
-- gaim_prefs_remove("/gaim/gtk/conversations/show_urls_as_links");
-- gaim_prefs_remove("/gaim/gtk/conversations/smiley_shortcuts");
-- gaim_prefs_remove("/gaim/gtk/conversations/use_custom_bgcolor");
-- gaim_prefs_remove("/gaim/gtk/conversations/use_custom_fgcolor");
-- gaim_prefs_remove("/gaim/gtk/conversations/use_custom_font");
-- gaim_prefs_remove("/gaim/gtk/conversations/use_custom_size");
-- gaim_prefs_remove("/gaim/gtk/conversations/chat/old_tab_complete");
-- gaim_prefs_remove("/gaim/gtk/conversations/chat/tab_completion");
-- gaim_prefs_remove("/gaim/gtk/conversations/im/hide_on_send");
-- gaim_prefs_remove("/gaim/gtk/conversations/chat/color_nicks");
-- gaim_prefs_remove("/gaim/gtk/conversations/chat/raise_on_events");
-- gaim_prefs_remove("/gaim/gtk/conversations/ignore_fonts");
-- gaim_prefs_remove("/gaim/gtk/conversations/ignore_font_sizes");
-- gaim_prefs_remove("/gaim/gtk/idle");
-- gaim_prefs_remove("/gaim/gtk/logging/individual_logs");
-- gaim_prefs_remove("/gaim/gtk/sound/signon");
-- gaim_prefs_remove("/gaim/gtk/sound/silent_signon");
-+ gaim2_prefs_remove("/gaim2/gtk/blist/auto_expand_contacts");
-+ gaim2_prefs_remove("/gaim2/gtk/blist/button_style");
-+ gaim2_prefs_remove("/gaim2/gtk/blist/grey_idle_buddies");
-+ gaim2_prefs_remove("/gaim2/gtk/blist/raise_on_events");
-+ gaim2_prefs_remove("/gaim2/gtk/blist/show_group_count");
-+ gaim2_prefs_remove("/gaim2/gtk/blist/show_warning_level");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/button_type");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/ctrl_enter_sends");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/enter_sends");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/escape_closes");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/html_shortcuts");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/icons_on_tabs");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/send_formatting");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/show_smileys");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/show_urls_as_links");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/smiley_shortcuts");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/use_custom_bgcolor");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/use_custom_fgcolor");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/use_custom_font");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/use_custom_size");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/chat/old_tab_complete");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/chat/tab_completion");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/im/hide_on_send");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/chat/color_nicks");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/chat/raise_on_events");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/ignore_fonts");
-+ gaim2_prefs_remove("/gaim2/gtk/conversations/ignore_font_sizes");
-+ gaim2_prefs_remove("/gaim2/gtk/idle");
-+ gaim2_prefs_remove("/gaim2/gtk/logging/individual_logs");
-+ gaim2_prefs_remove("/gaim2/gtk/sound/signon");
-+ gaim2_prefs_remove("/gaim2/gtk/sound/silent_signon");
-
- /* Convert old queuing prefs to hide_new 3-way pref. */
-- if (gaim_prefs_exists("/plugins/gtk/docklet/queue_messages") &&
-- gaim_prefs_get_bool("/plugins/gtk/docklet/queue_messages"))
-+ if (gaim2_prefs_exists("/plugins/gtk/docklet/queue_messages") &&
-+ gaim2_prefs_get_bool("/plugins/gtk/docklet/queue_messages"))
- {
-- gaim_prefs_set_string("/gaim/gtk/conversations/im/hide_new", "always");
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/im/hide_new", "always");
- }
-- else if (gaim_prefs_exists("/gaim/gtk/away/queue_messages") &&
-- gaim_prefs_get_bool("/gaim/gtk/away/queue_messages"))
-+ else if (gaim2_prefs_exists("/gaim2/gtk/away/queue_messages") &&
-+ gaim2_prefs_get_bool("/gaim2/gtk/away/queue_messages"))
- {
-- gaim_prefs_set_string("/gaim/gtk/conversations/im/hide_new", "away");
-+ gaim2_prefs_set_string("/gaim2/gtk/conversations/im/hide_new", "away");
- }
-- gaim_prefs_remove("/gaim/gtk/away/queue_messages");
-- gaim_prefs_remove("/gaim/gtk/away");
-- gaim_prefs_remove("/plugins/gtk/docklet/queue_messages");
-+ gaim2_prefs_remove("/gaim2/gtk/away/queue_messages");
-+ gaim2_prefs_remove("/gaim2/gtk/away");
-+ gaim2_prefs_remove("/plugins/gtk/docklet/queue_messages");
- }
-diff -prNu ./src/gtkprefs.h ./src/gtkprefs.h
---- ./src/gtkprefs.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkprefs.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkprefs.h GTK+ Preferences
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,21 +31,21 @@
- /**
- * Initializes all UI-specific preferences.
- */
--void gaim_gtk_prefs_init(void);
-+void gaim2_gtk_prefs_init(void);
-
- /**
- * Shows the preferences dialog.
- */
--void gaim_gtk_prefs_show(void);
-+void gaim2_gtk_prefs_show(void);
-
- /**
- * Add a new checkbox for a boolean preference
- *
- * @param title The text to be displayed as the checkbox label
-- * @param key The key of the gaim bool pref that will be represented by the checkbox
-+ * @param key The key of the gaim2 bool pref that will be represented by the checkbox
- * @param page The page to which the new checkbox will be added
- */
--GtkWidget *gaim_gtk_prefs_checkbox(const char *title, const char *key,
-+GtkWidget *gaim2_gtk_prefs_checkbox(const char *title, const char *key,
- GtkWidget *page);
-
- /**
-@@ -61,7 +61,7 @@ GtkWidget *gaim_gtk_prefs_checkbox(const
- * used to set the widgets to sensitive or insensitive based on the
- * value of a checkbox.
- */
--GtkWidget *gaim_gtk_prefs_labeled_spin_button(GtkWidget *page,
-+GtkWidget *gaim2_gtk_prefs_labeled_spin_button(GtkWidget *page,
- const gchar *title, const char *key, int min, int max, GtkSizeGroup *sg);
-
- /**
-@@ -76,7 +76,7 @@ GtkWidget *gaim_gtk_prefs_labeled_spin_b
- * the widgets to sensitive or insensitive based on the value of a
- * checkbox.
- */
--GtkWidget *gaim_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title,
-+GtkWidget *gaim2_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title,
- const char *key, GtkSizeGroup *sg);
-
- /**
-@@ -89,8 +89,8 @@ GtkWidget *gaim_gtk_prefs_labeled_entry(
- * @param ... The choices to be added to the dropdown, choices should be
- * paired as label/value
- */
--GtkWidget *gaim_gtk_prefs_dropdown(GtkWidget *page, const gchar *title,
-- GaimPrefType type, const char *key, ...);
-+GtkWidget *gaim2_gtk_prefs_dropdown(GtkWidget *page, const gchar *title,
-+ Gaim2PrefType type, const char *key, ...);
-
- /**
- * Add a new dropdown representing a preference of the specified type
-@@ -102,13 +102,13 @@ GtkWidget *gaim_gtk_prefs_dropdown(GtkWi
- * @param menuitems The choices to be added to the dropdown, choices should
- * be paired as label/value
- */
--GtkWidget *gaim_gtk_prefs_dropdown_from_list(GtkWidget *page,
-- const gchar * title, GaimPrefType type, const char *key,
-+GtkWidget *gaim2_gtk_prefs_dropdown_from_list(GtkWidget *page,
-+ const gchar * title, Gaim2PrefType type, const char *key,
- GList *menuitems);
-
- /**
- * Rename legacy prefs and delete some that no longer exist.
- */
--void gaim_gtk_prefs_update_old(void);
-+void gaim2_gtk_prefs_update_old(void);
-
- #endif /* _GAIM_GTKPREFS_H_ */
-diff -prNu ./src/gtkprivacy.c ./src/gtkprivacy.c
---- ./src/gtkprivacy.c 2005-12-21 22:18:25.000000000 +0100
-+++ ./src/gtkprivacy.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkprivacy.c GTK+ Privacy UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "connection.h"
- #include "debug.h"
-@@ -57,17 +57,17 @@ typedef struct
-
- gboolean in_allow_list;
-
-- GaimAccount *account;
-+ Gaim2Account *account;
-
--} GaimGtkPrivacyDialog;
-+} Gaim2GtkPrivacyDialog;
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *name;
- gboolean block;
-
--} GaimGtkPrivacyRequestData;
-+} Gaim2GtkPrivacyRequestData;
-
- static struct
- {
-@@ -85,10 +85,10 @@ static struct
-
- static size_t menu_entry_count = sizeof(menu_entries) / sizeof(*menu_entries);
-
--static GaimGtkPrivacyDialog *privacy_dialog = NULL;
-+static Gaim2GtkPrivacyDialog *privacy_dialog = NULL;
-
- static void
--rebuild_allow_list(GaimGtkPrivacyDialog *dialog)
-+rebuild_allow_list(Gaim2GtkPrivacyDialog *dialog)
- {
- GSList *l;
- GtkTreeIter iter;
-@@ -102,7 +102,7 @@ rebuild_allow_list(GaimGtkPrivacyDialog
- }
-
- static void
--rebuild_block_list(GaimGtkPrivacyDialog *dialog)
-+rebuild_block_list(Gaim2GtkPrivacyDialog *dialog)
- {
- GSList *l;
- GtkTreeIter iter;
-@@ -124,8 +124,8 @@ find_permit_block_by_name(GSList *list,
- for (l = list; l != NULL; l = l->next) {
- temp_name = (const char *)l->data;
-
-- /* Should this use gaim_normalize()? */
-- if (!gaim_utf8_strcasecmp(name, temp_name))
-+ /* Should this use gaim2_normalize()? */
-+ if (!gaim2_utf8_strcasecmp(name, temp_name))
- return temp_name;
- }
-
-@@ -133,13 +133,13 @@ find_permit_block_by_name(GSList *list,
- }
-
- static void
--user_selected_cb(GtkTreeSelection *sel, GaimGtkPrivacyDialog *dialog)
-+user_selected_cb(GtkTreeSelection *sel, Gaim2GtkPrivacyDialog *dialog)
- {
- gtk_widget_set_sensitive(dialog->remove_button, TRUE);
- }
-
- static GtkWidget *
--build_list(GaimGtkPrivacyDialog *dialog, GtkListStore *model,
-+build_list(Gaim2GtkPrivacyDialog *dialog, GtkListStore *model,
- GtkWidget **ret_treeview)
- {
- GtkWidget *sw;
-@@ -180,7 +180,7 @@ build_list(GaimGtkPrivacyDialog *dialog,
- }
-
- static GtkWidget *
--build_allow_list(GaimGtkPrivacyDialog *dialog)
-+build_allow_list(Gaim2GtkPrivacyDialog *dialog)
- {
- GtkWidget *widget;
- GtkWidget *list;
-@@ -199,7 +199,7 @@ build_allow_list(GaimGtkPrivacyDialog *d
- }
-
- static GtkWidget *
--build_block_list(GaimGtkPrivacyDialog *dialog)
-+build_block_list(Gaim2GtkPrivacyDialog *dialog)
- {
- GtkWidget *widget;
- GtkWidget *list;
-@@ -218,16 +218,16 @@ build_block_list(GaimGtkPrivacyDialog *d
- }
-
- static gint
--destroy_cb(GtkWidget *w, GdkEvent *event, GaimGtkPrivacyDialog *dialog)
-+destroy_cb(GtkWidget *w, GdkEvent *event, Gaim2GtkPrivacyDialog *dialog)
- {
-- gaim_gtk_privacy_dialog_hide();
-+ gaim2_gtk_privacy_dialog_hide();
-
- return 0;
- }
-
- static void
--select_account_cb(GtkWidget *dropdown, GaimAccount *account,
-- GaimGtkPrivacyDialog *dialog)
-+select_account_cb(GtkWidget *dropdown, Gaim2Account *account,
-+ Gaim2GtkPrivacyDialog *dialog)
- {
- int i;
-
-@@ -249,12 +249,12 @@ select_account_cb(GtkWidget *dropdown, G
- * Even better: the privacy API needs to not suck.
- */
- static void
--type_changed_cb(GtkOptionMenu *optmenu, GaimGtkPrivacyDialog *dialog)
-+type_changed_cb(GtkOptionMenu *optmenu, Gaim2GtkPrivacyDialog *dialog)
- {
- int new_type = menu_entries[gtk_option_menu_get_history(optmenu)].num;
-
- dialog->account->perm_deny = new_type;
-- serv_set_permit_deny(gaim_account_get_connection(dialog->account));
-+ serv_set_permit_deny(gaim2_account_get_connection(dialog->account));
-
- gtk_widget_hide(dialog->allow_widget);
- gtk_widget_hide(dialog->block_widget);
-@@ -271,21 +271,21 @@ type_changed_cb(GtkOptionMenu *optmenu,
- dialog->in_allow_list = FALSE;
- }
-
-- gaim_blist_schedule_save();
-- gaim_gtk_blist_refresh(gaim_get_blist());
-+ gaim2_blist_schedule_save();
-+ gaim2_gtk_blist_refresh(gaim2_get_blist());
- }
-
- static void
--add_cb(GtkWidget *button, GaimGtkPrivacyDialog *dialog)
-+add_cb(GtkWidget *button, Gaim2GtkPrivacyDialog *dialog)
- {
- if (dialog->in_allow_list)
-- gaim_gtk_request_add_permit(dialog->account, NULL);
-+ gaim2_gtk_request_add_permit(dialog->account, NULL);
- else
-- gaim_gtk_request_add_block(dialog->account, NULL);
-+ gaim2_gtk_request_add_block(dialog->account, NULL);
- }
-
- static void
--remove_cb(GtkWidget *button, GaimGtkPrivacyDialog *dialog)
-+remove_cb(GtkWidget *button, Gaim2GtkPrivacyDialog *dialog)
- {
- GtkTreeIter iter;
- GtkTreeModel *model;
-@@ -314,16 +314,16 @@ remove_cb(GtkWidget *button, GaimGtkPriv
-
- if (dialog->in_allow_list) {
- if (find_permit_block_by_name(dialog->account->permit, name))
-- gaim_privacy_permit_remove(dialog->account, name, FALSE);
-+ gaim2_privacy_permit_remove(dialog->account, name, FALSE);
- }
- else {
- if (find_permit_block_by_name(dialog->account->deny, name))
-- gaim_privacy_deny_remove(dialog->account, name, FALSE);
-+ gaim2_privacy_deny_remove(dialog->account, name, FALSE);
- }
- }
-
- static void
--clear_cb(GtkWidget *button, GaimGtkPrivacyDialog *dialog)
-+clear_cb(GtkWidget *button, Gaim2GtkPrivacyDialog *dialog)
- {
- GSList *l;
- if (dialog->in_allow_list)
-@@ -335,25 +335,25 @@ clear_cb(GtkWidget *button, GaimGtkPriva
- user = l->data;
- l = l->next;
- if (dialog->in_allow_list)
-- gaim_privacy_permit_remove(dialog->account, user, FALSE);
-+ gaim2_privacy_permit_remove(dialog->account, user, FALSE);
- else
-- gaim_privacy_deny_remove(dialog->account, user, FALSE);
-+ gaim2_privacy_deny_remove(dialog->account, user, FALSE);
- }
- }
-
- static void
--close_cb(GtkWidget *button, GaimGtkPrivacyDialog *dialog)
-+close_cb(GtkWidget *button, Gaim2GtkPrivacyDialog *dialog)
- {
- gtk_widget_destroy(dialog->win);
-
-- gaim_gtk_privacy_dialog_hide();
-+ gaim2_gtk_privacy_dialog_hide();
- }
-
- static gboolean
--check_account_func(GaimAccount *account)
-+check_account_func(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -361,25 +361,25 @@ check_account_func(GaimAccount *account)
- }
-
- gboolean
--gaim_gtk_privacy_is_showable()
-+gaim2_gtk_privacy_is_showable()
- {
- GList *c;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- for (c = gaim_connections_get_all(); c != NULL; c = c->next) {
-+ for (c = gaim2_connections_get_all(); c != NULL; c = c->next) {
- gc = c->data;
-
-- if (check_account_func(gaim_connection_get_account(gc)))
-+ if (check_account_func(gaim2_connection_get_account(gc)))
- return TRUE;
- }
-
- return FALSE;
- }
-
--static GaimGtkPrivacyDialog *
-+static Gaim2GtkPrivacyDialog *
- privacy_dialog_new(void)
- {
-- GaimGtkPrivacyDialog *dialog;
-+ Gaim2GtkPrivacyDialog *dialog;
- GtkWidget *bbox;
- GtkWidget *hbox;
- GtkWidget *vbox;
-@@ -390,7 +390,7 @@ privacy_dialog_new(void)
- int selected = 0;
- int i;
-
-- dialog = g_new0(GaimGtkPrivacyDialog, 1);
-+ dialog = g_new0(Gaim2GtkPrivacyDialog, 1);
-
- dialog->win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
- gtk_window_set_resizable(GTK_WINDOW(dialog->win), FALSE);
-@@ -425,13 +425,13 @@ privacy_dialog_new(void)
- gtk_widget_show(label);
-
- /* Accounts drop-down */
-- dropdown = gaim_gtk_account_option_menu_new(NULL, FALSE,
-+ dropdown = gaim2_gtk_account_option_menu_new(NULL, FALSE,
- G_CALLBACK(select_account_cb),
- check_account_func, dialog);
- gtk_box_pack_start(GTK_BOX(hbox), dropdown, FALSE, FALSE, 0);
- gtk_widget_show(dropdown);
-- gaim_set_accessible_label (dropdown, label);
-- dialog->account = gaim_gtk_account_option_menu_get_selected(dropdown);
-+ gaim2_set_accessible_label (dropdown, label);
-+ dialog->account = gaim2_gtk_account_option_menu_get_selected(dropdown);
-
- /* Add the drop-down list with the allow/block types. */
- dialog->type_menu = gtk_option_menu_new();
-@@ -442,7 +442,7 @@ privacy_dialog_new(void)
- menu = gtk_menu_new();
-
- for (i = 0; i < menu_entry_count; i++) {
-- gaim_new_item(menu, _(menu_entries[i].text));
-+ gaim2_new_item(menu, _(menu_entries[i].text));
-
- if (menu_entries[i].num == dialog->account->perm_deny)
- selected = i;
-@@ -524,9 +524,9 @@ privacy_dialog_new(void)
- }
-
- void
--gaim_gtk_privacy_dialog_show(void)
-+gaim2_gtk_privacy_dialog_show(void)
- {
-- g_return_if_fail(gaim_connections_get_all() != NULL);
-+ g_return_if_fail(gaim2_connections_get_all() != NULL);
-
- if (privacy_dialog == NULL)
- privacy_dialog = privacy_dialog_new();
-@@ -536,7 +536,7 @@ gaim_gtk_privacy_dialog_show(void)
- }
-
- void
--gaim_gtk_privacy_dialog_hide(void)
-+gaim2_gtk_privacy_dialog_hide(void)
- {
- if (privacy_dialog == NULL)
- return;
-@@ -546,7 +546,7 @@ gaim_gtk_privacy_dialog_hide(void)
- }
-
- static void
--destroy_request_data(GaimGtkPrivacyRequestData *data)
-+destroy_request_data(Gaim2GtkPrivacyRequestData *data)
- {
- if (data->name != NULL)
- g_free(data->name);
-@@ -555,18 +555,18 @@ destroy_request_data(GaimGtkPrivacyReque
- }
-
- static void
--confirm_permit_block_cb(GaimGtkPrivacyRequestData *data, int option)
-+confirm_permit_block_cb(Gaim2GtkPrivacyRequestData *data, int option)
- {
- if (data->block)
-- gaim_privacy_deny_add(data->account, data->name, FALSE);
-+ gaim2_privacy_deny_add(data->account, data->name, FALSE);
- else
-- gaim_privacy_permit_add(data->account, data->name, FALSE);
-+ gaim2_privacy_permit_add(data->account, data->name, FALSE);
-
- destroy_request_data(data);
- }
-
- static void
--add_permit_block_cb(GaimGtkPrivacyRequestData *data, const char *name)
-+add_permit_block_cb(Gaim2GtkPrivacyRequestData *data, const char *name)
- {
- data->name = g_strdup(name);
-
-@@ -574,19 +574,19 @@ add_permit_block_cb(GaimGtkPrivacyReques
- }
-
- void
--gaim_gtk_request_add_permit(GaimAccount *account, const char *name)
-+gaim2_gtk_request_add_permit(Gaim2Account *account, const char *name)
- {
-- GaimGtkPrivacyRequestData *data;
-+ Gaim2GtkPrivacyRequestData *data;
-
- g_return_if_fail(account != NULL);
-
-- data = g_new0(GaimGtkPrivacyRequestData, 1);
-+ data = g_new0(Gaim2GtkPrivacyRequestData, 1);
- data->account = account;
- data->name = g_strdup(name);
- data->block = FALSE;
-
- if (name == NULL) {
-- gaim_request_input(account, _("Permit User"),
-+ gaim2_request_input(account, _("Permit User"),
- _("Type a user you permit to contact you."),
- _("Please enter the name of the user you wish to be "
- "able to contact you."),
-@@ -602,7 +602,7 @@ gaim_gtk_request_add_permit(GaimAccount
- "%s to contact you?"), name);
-
-
-- gaim_request_action(account, _("Permit User"), primary, secondary,
-+ gaim2_request_action(account, _("Permit User"), primary, secondary,
- 0, data, 2,
- _("_Permit"), G_CALLBACK(confirm_permit_block_cb),
- _("Cancel"), G_CALLBACK(destroy_request_data));
-@@ -613,19 +613,19 @@ gaim_gtk_request_add_permit(GaimAccount
- }
-
- void
--gaim_gtk_request_add_block(GaimAccount *account, const char *name)
-+gaim2_gtk_request_add_block(Gaim2Account *account, const char *name)
- {
-- GaimGtkPrivacyRequestData *data;
-+ Gaim2GtkPrivacyRequestData *data;
-
- g_return_if_fail(account != NULL);
-
-- data = g_new0(GaimGtkPrivacyRequestData, 1);
-+ data = g_new0(Gaim2GtkPrivacyRequestData, 1);
- data->account = account;
- data->name = g_strdup(name);
- data->block = TRUE;
-
- if (name == NULL) {
-- gaim_request_input(account, _("Block User"),
-+ gaim2_request_input(account, _("Block User"),
- _("Type a user to block."),
- _("Please enter the name of the user you wish to block."),
- NULL, FALSE, FALSE, NULL,
-@@ -638,7 +638,7 @@ gaim_gtk_request_add_block(GaimAccount *
- char *secondary =
- g_strdup_printf(_("Are you sure you want to block %s?"), name);
-
-- gaim_request_action(account, _("Block User"), primary, secondary,
-+ gaim2_request_action(account, _("Block User"), primary, secondary,
- 0, data, 2,
- _("_Block"), G_CALLBACK(confirm_permit_block_cb),
- _("Cancel"), G_CALLBACK(destroy_request_data));
-@@ -649,34 +649,34 @@ gaim_gtk_request_add_block(GaimAccount *
- }
-
- static void
--gaim_gtk_permit_added_removed(GaimAccount *account, const char *name)
-+gaim2_gtk_permit_added_removed(Gaim2Account *account, const char *name)
- {
- if (privacy_dialog != NULL)
- rebuild_allow_list(privacy_dialog);
- }
-
- static void
--gaim_gtk_deny_added_removed(GaimAccount *account, const char *name)
-+gaim2_gtk_deny_added_removed(Gaim2Account *account, const char *name)
- {
- if (privacy_dialog != NULL)
- rebuild_block_list(privacy_dialog);
- }
-
--static GaimPrivacyUiOps privacy_ops =
-+static Gaim2PrivacyUiOps privacy_ops =
- {
-- gaim_gtk_permit_added_removed,
-- gaim_gtk_permit_added_removed,
-- gaim_gtk_deny_added_removed,
-- gaim_gtk_deny_added_removed
-+ gaim2_gtk_permit_added_removed,
-+ gaim2_gtk_permit_added_removed,
-+ gaim2_gtk_deny_added_removed,
-+ gaim2_gtk_deny_added_removed
- };
-
--GaimPrivacyUiOps *
--gaim_gtk_privacy_get_ui_ops(void)
-+Gaim2PrivacyUiOps *
-+gaim2_gtk_privacy_get_ui_ops(void)
- {
- return &privacy_ops;
- }
-
- void
--gaim_gtk_privacy_init(void)
-+gaim2_gtk_privacy_init(void)
- {
- }
-diff -prNu ./src/gtkprivacy.h ./src/gtkprivacy.h
---- ./src/gtkprivacy.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gtkprivacy.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkprivacy.h GTK+ Privacy UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,7 +30,7 @@
- /**
- * Initializes the GTK+ privacy subsystem.
- */
--void gaim_gtk_privacy_init(void);
-+void gaim2_gtk_privacy_init(void);
-
- /**
- * Determine if showing the privacy dialog is a valid action.
-@@ -38,17 +38,17 @@ void gaim_gtk_privacy_init(void);
- * @return TRUE if there are accounts online that support privacy.
- * Otherwise return FALSE.
- */
--gboolean gaim_gtk_privacy_is_showable(void);
-+gboolean gaim2_gtk_privacy_is_showable(void);
-
- /**
- * Shows the privacy dialog.
- */
--void gaim_gtk_privacy_dialog_show(void);
-+void gaim2_gtk_privacy_dialog_show(void);
-
- /**
- * Hides the privacy dialog.
- */
--void gaim_gtk_privacy_dialog_hide(void);
-+void gaim2_gtk_privacy_dialog_hide(void);
-
- /**
- * Requests confirmation to add a user to the allow list for an account,
-@@ -59,7 +59,7 @@ void gaim_gtk_privacy_dialog_hide(void);
- * @param account The account.
- * @param name The name of the user to add.
- */
--void gaim_gtk_request_add_permit(GaimAccount *account, const char *name);
-+void gaim2_gtk_request_add_permit(Gaim2Account *account, const char *name);
-
- /**
- * Requests confirmation to add a user to the block list for an account,
-@@ -70,13 +70,13 @@ void gaim_gtk_request_add_permit(GaimAcc
- * @param account The account.
- * @param name The name of the user to add.
- */
--void gaim_gtk_request_add_block(GaimAccount *account, const char *name);
-+void gaim2_gtk_request_add_block(Gaim2Account *account, const char *name);
-
- /**
- * Returns the UI operations structure for the GTK+ privacy subsystem.
- *
- * @return The GTK+ UI privacy operations structure.
- */
--GaimPrivacyUiOps *gaim_gtk_privacy_get_ui_ops(void);
-+Gaim2PrivacyUiOps *gaim2_gtk_privacy_get_ui_ops(void);
-
- #endif /* _GAIM_GTKPRIVACY_H_ */
-diff -prNu ./src/gtkrequest.c ./src/gtkrequest.c
---- ./src/gtkrequest.c 2005-12-28 10:04:51.000000000 +0100
-+++ ./src/gtkrequest.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkrequest.c GTK+ Request API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "prefs.h"
- #include "util.h"
-@@ -42,7 +42,7 @@
-
- typedef struct
- {
-- GaimRequestType type;
-+ Gaim2RequestType type;
-
- void *user_data;
- GtkWidget *dialog;
-@@ -65,7 +65,7 @@ typedef struct
-
- struct
- {
-- GaimRequestFields *fields;
-+ Gaim2RequestFields *fields;
-
- } multifield;
-
-@@ -78,7 +78,7 @@ typedef struct
-
- } u;
-
--} GaimGtkRequestData;
-+} Gaim2GtkRequestData;
-
- #ifndef NEW_STYLE_COMPLETION
- typedef struct
-@@ -87,11 +87,11 @@ typedef struct
-
- gboolean completion_started;
-
--} GaimGtkCompletionData;
-+} Gaim2GtkCompletionData;
- #endif
-
- static void
--generic_response_start(GaimGtkRequestData *data)
-+generic_response_start(Gaim2GtkRequestData *data)
- {
- GdkWindow *window = GTK_WIDGET(data->dialog)->window;
- GdkCursor *cursor;
-@@ -106,7 +106,7 @@ generic_response_start(GaimGtkRequestDat
- }
-
- static void
--input_response_cb(GtkDialog *dialog, gint id, GaimGtkRequestData *data)
-+input_response_cb(GtkDialog *dialog, gint id, Gaim2GtkRequestData *data)
- {
- const char *value;
- char *multiline_value = NULL;
-@@ -133,30 +133,30 @@ input_response_cb(GtkDialog *dialog, gin
- value = gtk_entry_get_text(GTK_ENTRY(data->u.input.entry));
-
- if (id < data->cb_count && data->cbs[id] != NULL)
-- ((GaimRequestInputCb)data->cbs[id])(data->user_data, value);
-+ ((Gaim2RequestInputCb)data->cbs[id])(data->user_data, value);
- else if (data->cbs[1] != NULL)
-- ((GaimRequestInputCb)data->cbs[1])(data->user_data, value);
-+ ((Gaim2RequestInputCb)data->cbs[1])(data->user_data, value);
-
- if (data->u.input.multiline)
- g_free(multiline_value);
-
-- gaim_request_close(GAIM_REQUEST_INPUT, data);
-+ gaim2_request_close(GAIM_REQUEST_INPUT, data);
- }
-
- static void
--action_response_cb(GtkDialog *dialog, gint id, GaimGtkRequestData *data)
-+action_response_cb(GtkDialog *dialog, gint id, Gaim2GtkRequestData *data)
- {
- generic_response_start(data);
-
- if (id < data->cb_count && data->cbs[id] != NULL)
-- ((GaimRequestActionCb)data->cbs[id])(data->user_data, id);
-+ ((Gaim2RequestActionCb)data->cbs[id])(data->user_data, id);
-
-- gaim_request_close(GAIM_REQUEST_INPUT, data);
-+ gaim2_request_close(GAIM_REQUEST_INPUT, data);
- }
-
-
- static void
--choice_response_cb(GtkDialog *dialog, gint id, GaimGtkRequestData *data)
-+choice_response_cb(GtkDialog *dialog, gint id, Gaim2GtkRequestData *data)
- {
- GtkWidget *radio = g_object_get_data(G_OBJECT(dialog), "radio");
- GSList *group = gtk_radio_button_get_group(GTK_RADIO_BUTTON(radio));
-@@ -166,21 +166,21 @@ choice_response_cb(GtkDialog *dialog, gi
- if (id < data->cb_count && data->cbs[id] != NULL)
- while (group) {
- if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(group->data))) {
-- ((GaimRequestChoiceCb)data->cbs[id])(data->user_data, GPOINTER_TO_INT(g_object_get_data(G_OBJECT(group->data), "choice_id")));
-+ ((Gaim2RequestChoiceCb)data->cbs[id])(data->user_data, GPOINTER_TO_INT(g_object_get_data(G_OBJECT(group->data), "choice_id")));
- break;
- }
- group = group->next;
- }
-- gaim_request_close(GAIM_REQUEST_INPUT, data);
-+ gaim2_request_close(GAIM_REQUEST_INPUT, data);
- }
-
- static gboolean
- field_string_focus_out_cb(GtkWidget *entry, GdkEventFocus *event,
-- GaimRequestField *field)
-+ Gaim2RequestField *field)
- {
- const char *value;
-
-- if (gaim_request_field_string_is_multiline(field))
-+ if (gaim2_request_field_string_is_multiline(field))
- {
- GtkTextBuffer *buffer;
- GtkTextIter start_iter, end_iter;
-@@ -195,7 +195,7 @@ field_string_focus_out_cb(GtkWidget *ent
- else
- value = gtk_entry_get_text(GTK_ENTRY(entry));
-
-- gaim_request_field_string_set_value(field,
-+ gaim2_request_field_string_set_value(field,
- (*value == '\0' ? NULL : value));
-
- return FALSE;
-@@ -203,45 +203,45 @@ field_string_focus_out_cb(GtkWidget *ent
-
- static gboolean
- field_int_focus_out_cb(GtkEntry *entry, GdkEventFocus *event,
-- GaimRequestField *field)
-+ Gaim2RequestField *field)
- {
-- gaim_request_field_int_set_value(field,
-+ gaim2_request_field_int_set_value(field,
- atoi(gtk_entry_get_text(entry)));
-
- return FALSE;
- }
-
- static void
--field_bool_cb(GtkToggleButton *button, GaimRequestField *field)
-+field_bool_cb(GtkToggleButton *button, Gaim2RequestField *field)
- {
-- gaim_request_field_bool_set_value(field,
-+ gaim2_request_field_bool_set_value(field,
- gtk_toggle_button_get_active(button));
- }
-
- static void
--field_choice_menu_cb(GtkOptionMenu *menu, GaimRequestField *field)
-+field_choice_menu_cb(GtkOptionMenu *menu, Gaim2RequestField *field)
- {
-- gaim_request_field_choice_set_value(field,
-+ gaim2_request_field_choice_set_value(field,
- gtk_option_menu_get_history(menu));
- }
-
- static void
--field_choice_option_cb(GtkRadioButton *button, GaimRequestField *field)
-+field_choice_option_cb(GtkRadioButton *button, Gaim2RequestField *field)
- {
- if (gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(button)))
-- gaim_request_field_choice_set_value(field,
-+ gaim2_request_field_choice_set_value(field,
- (g_slist_length(gtk_radio_button_get_group(button)) -
- g_slist_index(gtk_radio_button_get_group(button), button)) - 1);
- }
-
- static void
--field_account_cb(GObject *w, GaimAccount *account, GaimRequestField *field)
-+field_account_cb(GObject *w, Gaim2Account *account, Gaim2RequestField *field)
- {
-- gaim_request_field_account_set_value(field, account);
-+ gaim2_request_field_account_set_value(field, account);
- }
-
- static void
--multifield_ok_cb(GtkWidget *button, GaimGtkRequestData *data)
-+multifield_ok_cb(GtkWidget *button, Gaim2GtkRequestData *data)
- {
- generic_response_start(data);
-
-@@ -249,27 +249,27 @@ multifield_ok_cb(GtkWidget *button, Gaim
- gtk_widget_grab_focus(button);
-
- if (data->cbs[0] != NULL)
-- ((GaimRequestFieldsCb)data->cbs[0])(data->user_data,
-+ ((Gaim2RequestFieldsCb)data->cbs[0])(data->user_data,
- data->u.multifield.fields);
-
-- gaim_request_close(GAIM_REQUEST_FIELDS, data);
-+ gaim2_request_close(GAIM_REQUEST_FIELDS, data);
- }
-
- static void
--multifield_cancel_cb(GtkWidget *button, GaimGtkRequestData *data)
-+multifield_cancel_cb(GtkWidget *button, Gaim2GtkRequestData *data)
- {
- generic_response_start(data);
-
- if (data->cbs[1] != NULL)
-- ((GaimRequestFieldsCb)data->cbs[1])(data->user_data,
-+ ((Gaim2RequestFieldsCb)data->cbs[1])(data->user_data,
- data->u.multifield.fields);
-
-- gaim_request_close(GAIM_REQUEST_FIELDS, data);
-+ gaim2_request_close(GAIM_REQUEST_FIELDS, data);
- }
-
- static void
- destroy_multifield_cb(GtkWidget *dialog, GdkEvent *event,
-- GaimGtkRequestData *data)
-+ Gaim2GtkRequestData *data)
- {
- multifield_cancel_cb(NULL, data);
- }
-@@ -298,14 +298,14 @@ text_to_stock(const char *text)
- }
-
- static void *
--gaim_gtk_request_input(const char *title, const char *primary,
-+gaim2_gtk_request_input(const char *title, const char *primary,
- const char *secondary, const char *default_value,
- gboolean multiline, gboolean masked, gchar *hint,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data)
- {
-- GaimGtkRequestData *data;
-+ Gaim2GtkRequestData *data;
- GtkWidget *dialog;
- GtkWidget *vbox;
- GtkWidget *hbox;
-@@ -316,7 +316,7 @@ gaim_gtk_request_input(const char *title
- char *label_text;
- char *primary_esc, *secondary_esc;
-
-- data = g_new0(GaimGtkRequestData, 1);
-+ data = g_new0(Gaim2GtkRequestData, 1);
- data->type = GAIM_REQUEST_INPUT;
- data->user_data = user_data;
-
-@@ -388,9 +388,9 @@ gaim_gtk_request_input(const char *title
- GtkWidget *frame;
-
- /* imhtml */
-- frame = gaim_gtk_create_imhtml(TRUE, &entry, &toolbar);
-+ frame = gaim2_gtk_create_imhtml(TRUE, &entry, &toolbar);
- gtk_widget_set_size_request(entry, 320, 130);
-- gtk_widget_set_name(entry, "gaim_gtkrequest_imhtml");
-+ gtk_widget_set_name(entry, "gaim2_gtkrequest_imhtml");
- if (default_value != NULL)
- gtk_imhtml_append_text(GTK_IMHTML(entry), default_value, GTK_IMHTML_NO_SCROLL);
- gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
-@@ -423,8 +423,8 @@ gaim_gtk_request_input(const char *title
-
- gtk_box_pack_start(GTK_BOX(vbox), sw, TRUE, TRUE, 0);
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/spellcheck"))
-- gaim_gtk_setup_gtkspell(GTK_TEXT_VIEW(entry));
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/spellcheck"))
-+ gaim2_gtk_setup_gtkspell(GTK_TEXT_VIEW(entry));
-
- gtk_container_add(GTK_CONTAINER(sw), entry);
- }
-@@ -446,7 +446,7 @@ gaim_gtk_request_input(const char *title
- }
- }
-
-- gaim_set_accessible_label (entry, label);
-+ gaim2_set_accessible_label (entry, label);
- data->u.input.entry = entry;
-
- /* Show everything. */
-@@ -456,13 +456,13 @@ gaim_gtk_request_input(const char *title
- }
-
- static void *
--gaim_gtk_request_choice(const char *title, const char *primary,
-+gaim2_gtk_request_choice(const char *title, const char *primary,
- const char *secondary, unsigned int default_value,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data, va_list args)
- {
-- GaimGtkRequestData *data;
-+ Gaim2GtkRequestData *data;
- GtkWidget *dialog;
- GtkWidget *vbox, *vbox2;
- GtkWidget *hbox;
-@@ -473,7 +473,7 @@ gaim_gtk_request_choice(const char *titl
- char *radio_text;
- char *primary_esc, *secondary_esc;
-
-- data = g_new0(GaimGtkRequestData, 1);
-+ data = g_new0(Gaim2GtkRequestData, 1);
- data->type = GAIM_REQUEST_ACTION;
- data->user_data = user_data;
-
-@@ -559,11 +559,11 @@ gaim_gtk_request_choice(const char *titl
- }
-
- static void *
--gaim_gtk_request_action(const char *title, const char *primary,
-+gaim2_gtk_request_action(const char *title, const char *primary,
- const char *secondary, unsigned int default_action,
- void *user_data, size_t action_count, va_list actions)
- {
-- GaimGtkRequestData *data;
-+ Gaim2GtkRequestData *data;
- GtkWidget *dialog;
- GtkWidget *vbox;
- GtkWidget *hbox;
-@@ -574,7 +574,7 @@ gaim_gtk_request_action(const char *titl
- char *primary_esc, *secondary_esc;
- int i;
-
-- data = g_new0(GaimGtkRequestData, 1);
-+ data = g_new0(Gaim2GtkRequestData, 1);
- data->type = GAIM_REQUEST_ACTION;
- data->user_data = user_data;
-
-@@ -664,23 +664,23 @@ gaim_gtk_request_action(const char *titl
- }
-
- static void
--req_entry_field_changed_cb(GtkWidget *entry, GaimRequestField *field)
-+req_entry_field_changed_cb(GtkWidget *entry, Gaim2RequestField *field)
- {
-- GaimGtkRequestData *req_data;
-+ Gaim2GtkRequestData *req_data;
- const char *text = gtk_entry_get_text(GTK_ENTRY(entry));
-
-- gaim_request_field_string_set_value(field, (*text == '\0' ? NULL : text));
-+ gaim2_request_field_string_set_value(field, (*text == '\0' ? NULL : text));
-
-- req_data = (GaimGtkRequestData *)field->group->fields_list->ui_data;
-+ req_data = (Gaim2GtkRequestData *)field->group->fields_list->ui_data;
-
- gtk_widget_set_sensitive(req_data->ok_button,
-- gaim_request_fields_all_required_filled(field->group->fields_list));
-+ gaim2_request_fields_all_required_filled(field->group->fields_list));
- }
-
- #ifndef NEW_STYLE_COMPLETION
- static gboolean
- completion_entry_event(GtkEditable *entry, GdkEventKey *event,
-- GaimGtkCompletionData *data)
-+ Gaim2GtkCompletionData *data)
- {
- int pos, end_pos;
-
-@@ -749,7 +749,7 @@ completion_entry_event(GtkEditable *entr
- }
-
- static void
--destroy_completion_data(GtkWidget *w, GaimGtkCompletionData *data)
-+destroy_completion_data(GtkWidget *w, Gaim2GtkCompletionData *data)
- {
- g_list_foreach(data->completion->items, (GFunc)g_free, NULL);
- g_completion_free(data->completion);
-@@ -772,7 +772,7 @@ static gboolean screenname_completion_ma
- val1.g_type = 0;
- gtk_tree_model_get_value(model, iter, 2, &val1);
- tmp = g_value_get_string(&val1);
-- if (tmp != NULL && gaim_str_has_prefix(tmp, key))
-+ if (tmp != NULL && gaim2_str_has_prefix(tmp, key))
- {
- g_value_unset(&val1);
- return TRUE;
-@@ -782,7 +782,7 @@ static gboolean screenname_completion_ma
- val2.g_type = 0;
- gtk_tree_model_get_value(model, iter, 3, &val2);
- tmp = g_value_get_string(&val2);
-- if (tmp != NULL && gaim_str_has_prefix(tmp, key))
-+ if (tmp != NULL && gaim2_str_has_prefix(tmp, key))
- {
- g_value_unset(&val2);
- return TRUE;
-@@ -796,9 +796,9 @@ static gboolean screenname_completion_ma
- GtkTreeModel *model, GtkTreeIter *iter, gpointer *user_data)
- {
- GValue val;
-- GaimRequestField *screen_field = user_data[1];
-+ Gaim2RequestField *screen_field = user_data[1];
- GList *fields = screen_field->group->fields;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- val.g_type = 0;
- gtk_tree_model_get_value(model, iter, 1, &val);
-@@ -813,17 +813,17 @@ static gboolean screenname_completion_ma
- return TRUE;
-
- do {
-- GaimRequestField *field = fields->data;
-+ Gaim2RequestField *field = fields->data;
-
-- if (gaim_request_field_get_type(field) == GAIM_REQUEST_FIELD_ACCOUNT) {
-- const char *type_hint = gaim_request_field_get_type_hint(field);
-+ if (gaim2_request_field_get_type(field) == GAIM_REQUEST_FIELD_ACCOUNT) {
-+ const char *type_hint = gaim2_request_field_get_type_hint(field);
-
- if (type_hint != NULL && !strcmp(type_hint, "account")) {
- /* We found the corresponding account field. */
- GtkOptionMenu *optmenu = GTK_OPTION_MENU(field->ui_data);
-
- /* Set the account in the request API. */
-- gaim_request_field_account_set_value(field, account);
-+ gaim2_request_field_account_set_value(field, account);
-
- if (optmenu != NULL) {
- GList *items = GTK_MENU_SHELL(gtk_option_menu_get_menu(optmenu))->children;
-@@ -850,7 +850,7 @@ static gboolean screenname_completion_ma
-
- static void
- add_screenname_autocomplete_entry(GtkListStore *store, const char *buddy_alias, const char *contact_alias,
-- const GaimAccount *account, const char *screenname)
-+ const Gaim2Account *account, const char *screenname)
- {
- GtkTreeIter iter;
- gboolean completion_added = FALSE;
-@@ -925,14 +925,14 @@ add_screenname_autocomplete_entry(GtkLis
- }
- #endif /* NEW_STYLE_COMPLETION */
-
--static void get_log_set_name(GaimLogSet *set, gpointer value, gpointer **set_hash_data)
-+static void get_log_set_name(Gaim2LogSet *set, gpointer value, gpointer **set_hash_data)
- {
- /* 1. Don't show buddies because we will have gotten them already.
- * 2. Only show those with non-NULL accounts that are currently connected.
- * 3. The boxes that use this autocomplete code handle only IMs. */
- if (!set->buddy &&
- (GPOINTER_TO_INT(set_hash_data[1]) ||
-- (set->account != NULL && gaim_account_is_connected(set->account))) &&
-+ (set->account != NULL && gaim2_account_is_connected(set->account))) &&
- set->type == GAIM_LOG_IM) {
- #ifdef NEW_STYLE_COMPLETION
- add_screenname_autocomplete_entry((GtkListStore *)set_hash_data[0],
-@@ -947,20 +947,20 @@ static void get_log_set_name(GaimLogSet
- }
-
- static void
--setup_screenname_autocomplete(GtkWidget *entry, GaimRequestField *field, gboolean all)
-+setup_screenname_autocomplete(GtkWidget *entry, Gaim2RequestField *field, gboolean all)
- {
- #ifdef NEW_STYLE_COMPLETION
- /* Store the displayed completion value, the screenname, the UTF-8 normalized & casefolded screenname,
- * the UTF-8 normalized & casefolded value for comparison, and the account. */
- GtkListStore *store = gtk_list_store_new(5, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_POINTER);
-
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- GHashTable *sets;
- gpointer set_hash_data[] = {store, GINT_TO_POINTER(all)};
- GtkEntryCompletion *completion;
- gpointer *data;
-
-- for (gnode = gaim_get_blist()->root; gnode != NULL; gnode = gnode->next)
-+ for (gnode = gaim2_get_blist()->root; gnode != NULL; gnode = gnode->next)
- {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-@@ -972,14 +972,14 @@ setup_screenname_autocomplete(GtkWidget
-
- for (bnode = cnode->child; bnode != NULL; bnode = bnode->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)bnode;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)bnode;
-
-- if (!all && !gaim_account_is_connected(buddy->account))
-+ if (!all && !gaim2_account_is_connected(buddy->account))
- continue;
-
- add_screenname_autocomplete_entry(store,
-- ((GaimContact *)cnode)->alias,
-- gaim_buddy_get_contact_alias(buddy),
-+ ((Gaim2Contact *)cnode)->alias,
-+ gaim2_buddy_get_contact_alias(buddy),
- buddy->account,
- buddy->name
- );
-@@ -987,7 +987,7 @@ setup_screenname_autocomplete(GtkWidget
- }
- }
-
-- sets = gaim_log_get_log_sets();
-+ sets = gaim2_log_get_log_sets();
- g_hash_table_foreach(sets, (GHFunc)get_log_set_name, &set_hash_data);
- g_hash_table_destroy(sets);
-
-@@ -1014,19 +1014,19 @@ setup_screenname_autocomplete(GtkWidget
- gtk_entry_completion_set_text_column(completion, 0);
-
- #else /* !NEW_STYLE_COMPLETION */
-- GaimGtkCompletionData *data;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2GtkCompletionData *data;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- GList *item = g_list_append(NULL, NULL);
- GHashTable *sets;
- gpointer set_hash_data[2];
-
-- data = g_new0(GaimGtkCompletionData, 1);
-+ data = g_new0(Gaim2GtkCompletionData, 1);
-
- data->completion = g_completion_new(NULL);
-
- g_completion_set_compare(data->completion, g_ascii_strncasecmp);
-
-- for (gnode = gaim_get_blist()->root; gnode != NULL; gnode = gnode->next)
-+ for (gnode = gaim2_get_blist()->root; gnode != NULL; gnode = gnode->next)
- {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-@@ -1038,9 +1038,9 @@ setup_screenname_autocomplete(GtkWidget
-
- for (bnode = cnode->child; bnode != NULL; bnode = bnode->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)bnode;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)bnode;
-
-- if (!all && !gaim_account_is_connected(buddy->account))
-+ if (!all && !gaim2_account_is_connected(buddy->account))
- continue;
-
- item->data = g_strdup(buddy->name);
-@@ -1050,7 +1050,7 @@ setup_screenname_autocomplete(GtkWidget
- }
- g_list_free(item);
-
-- sets = gaim_log_get_log_sets();
-+ sets = gaim2_log_get_log_sets();
- item = NULL;
- set_hash_data[0] = &item;
- set_hash_data[1] = GINT_TO_POINTER(all);
-@@ -1068,19 +1068,19 @@ setup_screenname_autocomplete(GtkWidget
- }
-
- static void
--setup_entry_field(GtkWidget *entry, GaimRequestField *field)
-+setup_entry_field(GtkWidget *entry, Gaim2RequestField *field)
- {
- const char *type_hint;
-
- gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE);
-
-- if (gaim_request_field_is_required(field))
-+ if (gaim2_request_field_is_required(field))
- {
- g_signal_connect(G_OBJECT(entry), "changed",
- G_CALLBACK(req_entry_field_changed_cb), field);
- }
-
-- if ((type_hint = gaim_request_field_get_type_hint(field)) != NULL)
-+ if ((type_hint = gaim2_request_field_get_type_hint(field)) != NULL)
- {
- if (!strncmp(type_hint, "screenname", sizeof("screenname") - 1))
- {
-@@ -1090,14 +1090,14 @@ setup_entry_field(GtkWidget *entry, Gaim
- }
-
- static GtkWidget *
--create_string_field(GaimRequestField *field)
-+create_string_field(Gaim2RequestField *field)
- {
- const char *value;
- GtkWidget *widget;
-
-- value = gaim_request_field_string_get_default_value(field);
-+ value = gaim2_request_field_string_get_default_value(field);
-
-- if (gaim_request_field_string_is_multiline(field))
-+ if (gaim2_request_field_string_is_multiline(field))
- {
- GtkWidget *textview;
-
-@@ -1113,8 +1113,8 @@ create_string_field(GaimRequestField *fi
- gtk_text_view_set_wrap_mode(GTK_TEXT_VIEW(textview),
- GTK_WRAP_WORD_CHAR);
-
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/spellcheck"))
-- gaim_gtk_setup_gtkspell(GTK_TEXT_VIEW(textview));
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/spellcheck"))
-+ gaim2_gtk_setup_gtkspell(GTK_TEXT_VIEW(textview));
-
- gtk_container_add(GTK_CONTAINER(widget), textview);
- gtk_widget_show(textview);
-@@ -1131,7 +1131,7 @@ create_string_field(GaimRequestField *fi
- }
-
- gtk_text_view_set_editable(GTK_TEXT_VIEW(textview),
-- gaim_request_field_string_is_editable(field));
-+ gaim2_request_field_string_is_editable(field));
-
- g_signal_connect(G_OBJECT(textview), "focus-out-event",
- G_CALLBACK(field_string_focus_out_cb), field);
-@@ -1145,14 +1145,14 @@ create_string_field(GaimRequestField *fi
- if (value != NULL)
- gtk_entry_set_text(GTK_ENTRY(widget), value);
-
-- if (gaim_request_field_string_is_masked(field))
-+ if (gaim2_request_field_string_is_masked(field))
- {
- gtk_entry_set_visibility(GTK_ENTRY(widget), FALSE);
- gtk_entry_set_invisible_char(GTK_ENTRY(widget), GAIM_INVISIBLE_CHAR);
- }
-
- gtk_editable_set_editable(GTK_EDITABLE(widget),
-- gaim_request_field_string_is_editable(field));
-+ gaim2_request_field_string_is_editable(field));
-
- g_signal_connect(G_OBJECT(widget), "focus-out-event",
- G_CALLBACK(field_string_focus_out_cb), field);
-@@ -1162,7 +1162,7 @@ create_string_field(GaimRequestField *fi
- }
-
- static GtkWidget *
--create_int_field(GaimRequestField *field)
-+create_int_field(Gaim2RequestField *field)
- {
- int value;
- GtkWidget *widget;
-@@ -1171,7 +1171,7 @@ create_int_field(GaimRequestField *field
-
- setup_entry_field(widget, field);
-
-- value = gaim_request_field_int_get_default_value(field);
-+ value = gaim2_request_field_int_get_default_value(field);
-
- if (value != 0)
- {
-@@ -1189,15 +1189,15 @@ create_int_field(GaimRequestField *field
- }
-
- static GtkWidget *
--create_bool_field(GaimRequestField *field)
-+create_bool_field(Gaim2RequestField *field)
- {
- GtkWidget *widget;
-
- widget = gtk_check_button_new_with_label(
-- gaim_request_field_get_label(field));
-+ gaim2_request_field_get_label(field));
-
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(widget),
-- gaim_request_field_bool_get_default_value(field));
-+ gaim2_request_field_bool_get_default_value(field));
-
- g_signal_connect(G_OBJECT(widget), "toggled",
- G_CALLBACK(field_bool_cb), field);
-@@ -1206,13 +1206,13 @@ create_bool_field(GaimRequestField *fiel
- }
-
- static GtkWidget *
--create_choice_field(GaimRequestField *field)
-+create_choice_field(Gaim2RequestField *field)
- {
- GtkWidget *widget;
- GList *labels;
- GList *l;
-
-- labels = gaim_request_field_choice_get_labels(field);
-+ labels = gaim2_request_field_choice_get_labels(field);
-
- if (g_list_length(labels) > 5)
- {
-@@ -1236,7 +1236,7 @@ create_choice_field(GaimRequestField *fi
- gtk_widget_show(menu);
- gtk_option_menu_set_menu(GTK_OPTION_MENU(widget), menu);
- gtk_option_menu_set_history(GTK_OPTION_MENU(widget),
-- gaim_request_field_choice_get_default_value(field));
-+ gaim2_request_field_choice_get_default_value(field));
-
- g_signal_connect(G_OBJECT(widget), "changed",
- G_CALLBACK(field_choice_menu_cb), field);
-@@ -1265,7 +1265,7 @@ create_choice_field(GaimRequestField *fi
- if (first_radio == NULL)
- first_radio = radio;
-
-- if (i == gaim_request_field_choice_get_default_value(field))
-+ if (i == gaim2_request_field_choice_get_default_value(field))
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(radio), TRUE);
-
- gtk_box_pack_start(GTK_BOX(box), radio, TRUE, TRUE, 0);
-@@ -1280,7 +1280,7 @@ create_choice_field(GaimRequestField *fi
- }
-
- static GtkWidget *
--create_image_field(GaimRequestField *field)
-+create_image_field(Gaim2RequestField *field)
- {
- GtkWidget *widget;
- GdkPixbuf *buf, *scale;
-@@ -1288,15 +1288,15 @@ create_image_field(GaimRequestField *fie
-
- loader = gdk_pixbuf_loader_new();
- gdk_pixbuf_loader_write(loader,
-- (const guchar *)gaim_request_field_image_get_buffer(field),
-- gaim_request_field_image_get_size(field),
-+ (const guchar *)gaim2_request_field_image_get_buffer(field),
-+ gaim2_request_field_image_get_size(field),
- NULL);
- gdk_pixbuf_loader_close(loader, NULL);
- buf = gdk_pixbuf_loader_get_pixbuf(loader);
-
- scale = gdk_pixbuf_scale_simple(buf,
-- gaim_request_field_image_get_scale_x(field) * gdk_pixbuf_get_width(buf),
-- gaim_request_field_image_get_scale_y(field) * gdk_pixbuf_get_height(buf),
-+ gaim2_request_field_image_get_scale_x(field) * gdk_pixbuf_get_width(buf),
-+ gaim2_request_field_image_get_scale_y(field) * gdk_pixbuf_get_height(buf),
- GDK_INTERP_BILINEAR);
- widget = gtk_image_new_from_pixbuf(scale);
- g_object_unref(G_OBJECT(buf));
-@@ -1306,15 +1306,15 @@ create_image_field(GaimRequestField *fie
- }
-
- static GtkWidget *
--create_account_field(GaimRequestField *field)
-+create_account_field(Gaim2RequestField *field)
- {
- GtkWidget *widget;
-
-- widget = gaim_gtk_account_option_menu_new(
-- gaim_request_field_account_get_default_value(field),
-- gaim_request_field_account_get_show_all(field),
-+ widget = gaim2_gtk_account_option_menu_new(
-+ gaim2_request_field_account_get_default_value(field),
-+ gaim2_request_field_account_get_show_all(field),
- G_CALLBACK(field_account_cb),
-- gaim_request_field_account_get_filter(field),
-+ gaim2_request_field_account_get_filter(field),
- field);
-
- return widget;
-@@ -1324,24 +1324,24 @@ static void
- select_field_list_item(GtkTreeModel *model, GtkTreePath *path,
- GtkTreeIter *iter, gpointer data)
- {
-- GaimRequestField *field = (GaimRequestField *)data;
-+ Gaim2RequestField *field = (Gaim2RequestField *)data;
- const char *text;
-
- gtk_tree_model_get(model, iter, 1, &text, -1);
-
-- gaim_request_field_list_add_selected(field, text);
-+ gaim2_request_field_list_add_selected(field, text);
- }
-
- static void
--list_field_select_changed_cb(GtkTreeSelection *sel, GaimRequestField *field)
-+list_field_select_changed_cb(GtkTreeSelection *sel, Gaim2RequestField *field)
- {
-- gaim_request_field_list_clear_selected(field);
-+ gaim2_request_field_list_clear_selected(field);
-
- gtk_tree_selection_selected_foreach(sel, select_field_list_item, field);
- }
-
- static GtkWidget *
--create_list_field(GaimRequestField *field)
-+create_list_field(Gaim2RequestField *field)
- {
- GtkWidget *sw;
- GtkWidget *treeview;
-@@ -1371,7 +1371,7 @@ create_list_field(GaimRequestField *fiel
-
- sel = gtk_tree_view_get_selection(GTK_TREE_VIEW(treeview));
-
-- if (gaim_request_field_list_get_multi_select(field))
-+ if (gaim2_request_field_list_get_multi_select(field))
- gtk_tree_selection_set_mode(sel, GTK_SELECTION_MULTIPLE);
-
- g_signal_connect(G_OBJECT(sel), "changed",
-@@ -1384,18 +1384,18 @@ create_list_field(GaimRequestField *fiel
- gtk_tree_view_column_pack_start(column, renderer, TRUE);
- gtk_tree_view_column_add_attribute(column, renderer, "text", 1);
-
-- for (l = gaim_request_field_list_get_items(field); l != NULL; l = l->next)
-+ for (l = gaim2_request_field_list_get_items(field); l != NULL; l = l->next)
- {
- const char *text = (const char *)l->data;
-
- gtk_list_store_append(store, &iter);
-
- gtk_list_store_set(store, &iter,
-- 0, gaim_request_field_list_get_data(field, text),
-+ 0, gaim2_request_field_list_get_data(field, text),
- 1, text,
- -1);
-
-- if (gaim_request_field_list_is_selected(field, text))
-+ if (gaim2_request_field_list_is_selected(field, text))
- gtk_tree_selection_select_iter(sel, &iter);
- }
-
-@@ -1406,13 +1406,13 @@ create_list_field(GaimRequestField *fiel
- }
-
- static void *
--gaim_gtk_request_fields(const char *title, const char *primary,
-- const char *secondary, GaimRequestFields *fields,
-+gaim2_gtk_request_fields(const char *title, const char *primary,
-+ const char *secondary, Gaim2RequestFields *fields,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data)
- {
-- GaimGtkRequestData *data;
-+ Gaim2GtkRequestData *data;
- GtkWidget *win;
- GtkWidget *vbox;
- GtkWidget *vbox2;
-@@ -1426,13 +1426,13 @@ gaim_gtk_request_fields(const char *titl
- GtkWidget *sw;
- GtkSizeGroup *sg;
- GList *gl, *fl;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
- char *label_text;
- char *primary_esc, *secondary_esc;
- int total_fields = 0;
-
-- data = g_new0(GaimGtkRequestData, 1);
-+ data = g_new0(Gaim2GtkRequestData, 1);
- data->type = GAIM_REQUEST_FIELDS;
- data->user_data = user_data;
- data->u.multifield.fields = fields;
-@@ -1491,9 +1491,9 @@ gaim_gtk_request_fields(const char *titl
- g_free(label_text);
- }
-
-- for (gl = gaim_request_fields_get_groups(fields); gl != NULL;
-+ for (gl = gaim2_request_fields_get_groups(fields); gl != NULL;
- gl = gl->next)
-- total_fields += g_list_length(gaim_request_field_group_get_fields(gl->data));
-+ total_fields += g_list_length(gaim2_request_field_group_get_fields(gl->data));
-
- if(total_fields > 9) {
- sw = gtk_scrolled_window_new(NULL, NULL);
-@@ -1524,7 +1524,7 @@ gaim_gtk_request_fields(const char *titl
- gtk_widget_show(label);
- }
-
-- for (gl = gaim_request_fields_get_groups(fields);
-+ for (gl = gaim2_request_fields_get_groups(fields);
- gl != NULL;
- gl = gl->next)
- {
-@@ -1536,12 +1536,12 @@ gaim_gtk_request_fields(const char *titl
- size_t row_num = 0;
-
- group = gl->data;
-- field_list = gaim_request_field_group_get_fields(group);
-+ field_list = gaim2_request_field_group_get_fields(group);
-
-- if (gaim_request_field_group_get_title(group) != NULL)
-+ if (gaim2_request_field_group_get_title(group) != NULL)
- {
-- frame = gaim_gtk_make_frame(vbox2,
-- gaim_request_field_group_get_title(group));
-+ frame = gaim2_gtk_make_frame(vbox2,
-+ gaim2_request_field_group_get_title(group));
- }
- else
- frame = vbox2;
-@@ -1561,11 +1561,11 @@ gaim_gtk_request_fields(const char *titl
-
- for (fl = field_list; fl != NULL; fl = fl->next)
- {
-- GaimRequestFieldType type;
-+ Gaim2RequestFieldType type;
-
-- field = (GaimRequestField *)fl->data;
-+ field = (Gaim2RequestField *)fl->data;
-
-- type = gaim_request_field_get_type(field);
-+ type = gaim2_request_field_get_type(field);
-
- if (type == GAIM_REQUEST_FIELD_LABEL)
- {
-@@ -1576,7 +1576,7 @@ gaim_gtk_request_fields(const char *titl
- }
- else if ((type == GAIM_REQUEST_FIELD_LIST) ||
- (type == GAIM_REQUEST_FIELD_STRING &&
-- gaim_request_field_string_is_multiline(field)))
-+ gaim2_request_field_string_is_multiline(field)))
- {
- if (col_num > 0)
- rows++;
-@@ -1606,26 +1606,26 @@ gaim_gtk_request_fields(const char *titl
- col_num++, fl = fl->next)
- {
- size_t col_offset = col_num * 2;
-- GaimRequestFieldType type;
-+ Gaim2RequestFieldType type;
- GtkWidget *widget = NULL;
-
- label = NULL;
- field = fl->data;
-
-- if (!gaim_request_field_is_visible(field)) {
-+ if (!gaim2_request_field_is_visible(field)) {
- col_num--;
- continue;
- }
-
-- type = gaim_request_field_get_type(field);
-+ type = gaim2_request_field_get_type(field);
-
- if (type != GAIM_REQUEST_FIELD_BOOLEAN &&
-- gaim_request_field_get_label(field))
-+ gaim2_request_field_get_label(field))
- {
- char *text;
-
- text = g_strdup_printf("%s:",
-- gaim_request_field_get_label(field));
-+ gaim2_request_field_get_label(field));
-
- label = gtk_label_new(NULL);
- gtk_label_set_markup_with_mnemonic(GTK_LABEL(label), text);
-@@ -1638,7 +1638,7 @@ gaim_gtk_request_fields(const char *titl
- if (type == GAIM_REQUEST_FIELD_LABEL ||
- type == GAIM_REQUEST_FIELD_LIST ||
- (type == GAIM_REQUEST_FIELD_STRING &&
-- gaim_request_field_string_is_multiline(field)))
-+ gaim2_request_field_string_is_multiline(field)))
- {
- if(col_num > 0)
- row_num++;
-@@ -1683,7 +1683,7 @@ gaim_gtk_request_fields(const char *titl
- #endif
-
- if (type == GAIM_REQUEST_FIELD_STRING &&
-- gaim_request_field_string_is_multiline(field))
-+ gaim2_request_field_string_is_multiline(field))
- {
- gtk_table_attach(GTK_TABLE(table), widget,
- 0, 2 * cols,
-@@ -1759,7 +1759,7 @@ gaim_gtk_request_fields(const char *titl
- g_signal_connect(G_OBJECT(button), "clicked",
- G_CALLBACK(multifield_ok_cb), data);
-
-- if (!gaim_request_fields_all_required_filled(fields))
-+ if (!gaim2_request_fields_all_required_filled(fields))
- gtk_widget_set_sensitive(button, FALSE);
-
- gtk_widget_show(win);
-@@ -1768,21 +1768,21 @@ gaim_gtk_request_fields(const char *titl
- }
-
- static void
--file_yes_no_cb(GaimGtkRequestData *data, gint id)
-+file_yes_no_cb(Gaim2GtkRequestData *data, gint id)
- {
- /* Only call the callback if yes was selected, otherwise the request
- * (eg. file transfer) will be cancelled, then when a new filename is chosen
- * things go BOOM */
- if (id == 1) {
- if (data->cbs[1] != NULL)
-- ((GaimRequestFileCb)data->cbs[1])(data->user_data, data->u.file.name);
-- gaim_request_close(GAIM_REQUEST_FILE, data);
-+ ((Gaim2RequestFileCb)data->cbs[1])(data->user_data, data->u.file.name);
-+ gaim2_request_close(GAIM_REQUEST_FILE, data);
- }
- }
-
- #if GTK_CHECK_VERSION(2,4,0) /* FILECHOOSER */
- static void
--file_ok_check_if_exists_cb(GtkWidget *widget, gint response, GaimGtkRequestData *data)
-+file_ok_check_if_exists_cb(GtkWidget *widget, gint response, Gaim2GtkRequestData *data)
- {
- gchar *current_folder;
-
-@@ -1790,8 +1790,8 @@ file_ok_check_if_exists_cb(GtkWidget *wi
-
- if (response != GTK_RESPONSE_ACCEPT) {
- if (data->cbs[0] != NULL)
-- ((GaimRequestFileCb)data->cbs[0])(data->user_data, NULL);
-- gaim_request_close(GAIM_REQUEST_FILE, data);
-+ ((Gaim2RequestFileCb)data->cbs[0])(data->user_data, NULL);
-+ gaim2_request_close(GAIM_REQUEST_FILE, data);
- return;
- }
-
-@@ -1799,9 +1799,9 @@ file_ok_check_if_exists_cb(GtkWidget *wi
- current_folder = gtk_file_chooser_get_current_folder(GTK_FILE_CHOOSER(data->dialog));
- if (current_folder != NULL) {
- if (data->u.file.savedialog) {
-- gaim_prefs_set_string("/gaim/gtk/filelocations/last_save_folder", current_folder);
-+ gaim2_prefs_set_string("/gaim2/gtk/filelocations/last_save_folder", current_folder);
- } else {
-- gaim_prefs_set_string("/gaim/gtk/filelocations/last_open_folder", current_folder);
-+ gaim2_prefs_set_string("/gaim2/gtk/filelocations/last_open_folder", current_folder);
- }
- g_free(current_folder);
- }
-@@ -1809,7 +1809,7 @@ file_ok_check_if_exists_cb(GtkWidget *wi
- #else /* FILECHOOSER */
-
- static void
--file_ok_check_if_exists_cb(GtkWidget *button, GaimGtkRequestData *data)
-+file_ok_check_if_exists_cb(GtkWidget *button, Gaim2GtkRequestData *data)
- {
- const gchar *name;
- gchar *current_folder;
-@@ -1819,15 +1819,15 @@ file_ok_check_if_exists_cb(GtkWidget *bu
- name = gtk_file_selection_get_filename(GTK_FILE_SELECTION(data->dialog));
-
- /* If name is a directory then change directories */
-- if (gaim_gtk_check_if_dir(name, GTK_FILE_SELECTION(data->dialog)))
-+ if (gaim2_gtk_check_if_dir(name, GTK_FILE_SELECTION(data->dialog)))
- return;
-
- current_folder = g_path_get_dirname(name);
- if (current_folder != NULL) {
- if (data->u.file.savedialog) {
-- gaim_prefs_set_string("/gaim/gtk/filelocations/last_save_folder", current_folder);
-+ gaim2_prefs_set_string("/gaim2/gtk/filelocations/last_save_folder", current_folder);
- } else {
-- gaim_prefs_set_string("/gaim/gtk/filelocations/last_open_folder", current_folder);
-+ gaim2_prefs_set_string("/gaim2/gtk/filelocations/last_open_folder", current_folder);
- }
- g_free(current_folder);
- }
-@@ -1838,7 +1838,7 @@ file_ok_check_if_exists_cb(GtkWidget *bu
-
- if ((data->u.file.savedialog == TRUE) &&
- (g_file_test(data->u.file.name, G_FILE_TEST_EXISTS))) {
-- gaim_request_yes_no(data, NULL, _("That file already exists"),
-+ gaim2_request_yes_no(data, NULL, _("That file already exists"),
- _("Would you like to overwrite it?"), 0, data,
- G_CALLBACK(file_yes_no_cb),
- G_CALLBACK(file_yes_no_cb));
-@@ -1848,31 +1848,31 @@ file_ok_check_if_exists_cb(GtkWidget *bu
-
- #if !GTK_CHECK_VERSION(2,4,0) /* FILECHOOSER */
- static void
--file_cancel_cb(GaimGtkRequestData *data)
-+file_cancel_cb(Gaim2GtkRequestData *data)
- {
- generic_response_start(data);
-
- if (data->cbs[0] != NULL)
-- ((GaimRequestFileCb)data->cbs[0])(data->user_data, NULL);
-+ ((Gaim2RequestFileCb)data->cbs[0])(data->user_data, NULL);
-
-- gaim_request_close(GAIM_REQUEST_FILE, data);
-+ gaim2_request_close(GAIM_REQUEST_FILE, data);
- }
- #endif /* FILECHOOSER */
-
- static void *
--gaim_gtk_request_file(const char *title, const char *filename,
-+gaim2_gtk_request_file(const char *title, const char *filename,
- gboolean savedialog,
- GCallback ok_cb, GCallback cancel_cb,
- void *user_data)
- {
-- GaimGtkRequestData *data;
-+ Gaim2GtkRequestData *data;
- GtkWidget *filesel;
- const gchar *current_folder;
- #if GTK_CHECK_VERSION(2,4,0)
- gboolean folder_set = FALSE;
- #endif
-
-- data = g_new0(GaimGtkRequestData, 1);
-+ data = g_new0(Gaim2GtkRequestData, 1);
- data->type = GAIM_REQUEST_FILE;
- data->user_data = user_data;
- data->cb_count = 2;
-@@ -1896,9 +1896,9 @@ gaim_gtk_request_file(const char *title,
- gtk_dialog_set_default_response(GTK_DIALOG(filesel), GTK_RESPONSE_ACCEPT);
-
- if (savedialog) {
-- current_folder = gaim_prefs_get_string("/gaim/gtk/filelocations/last_save_folder");
-+ current_folder = gaim2_prefs_get_string("/gaim2/gtk/filelocations/last_save_folder");
- } else {
-- current_folder = gaim_prefs_get_string("/gaim/gtk/filelocations/last_open_folder");
-+ current_folder = gaim2_prefs_get_string("/gaim2/gtk/filelocations/last_open_folder");
- }
-
- if (filename != NULL)
-@@ -1909,7 +1909,7 @@ gaim_gtk_request_file(const char *title,
-
- #ifdef _WIN32
- if (!folder_set) {
-- char *my_documents = wgaim_get_special_folder(CSIDL_PERSONAL);
-+ char *my_documents = wgaim2_get_special_folder(CSIDL_PERSONAL);
-
- if (my_documents != NULL) {
- gtk_file_chooser_set_current_folder(
-@@ -1927,9 +1927,9 @@ gaim_gtk_request_file(const char *title,
- title ? title : (savedialog ? _("Save File...")
- : _("Open File...")));
- if (savedialog) {
-- current_folder = gaim_prefs_get_string("/gaim/gtk/filelocations/last_save_folder");
-+ current_folder = gaim2_prefs_get_string("/gaim2/gtk/filelocations/last_save_folder");
- } else {
-- current_folder = gaim_prefs_get_string("/gaim/gtk/filelocations/last_open_folder");
-+ current_folder = gaim2_prefs_get_string("/gaim2/gtk/filelocations/last_open_folder");
- }
- if (current_folder != NULL) {
- gchar *path = g_strdup_printf("%s%s", current_folder, G_DIR_SEPARATOR_S);
-@@ -1954,9 +1954,9 @@ gaim_gtk_request_file(const char *title,
- }
-
- static void
--gaim_gtk_close_request(GaimRequestType type, void *ui_handle)
-+gaim2_gtk_close_request(Gaim2RequestType type, void *ui_handle)
- {
-- GaimGtkRequestData *data = (GaimGtkRequestData *)ui_handle;
-+ Gaim2GtkRequestData *data = (Gaim2GtkRequestData *)ui_handle;
-
- if (data->cbs != NULL)
- g_free(data->cbs);
-@@ -1964,25 +1964,25 @@ gaim_gtk_close_request(GaimRequestType t
- gtk_widget_destroy(data->dialog);
-
- if (type == GAIM_REQUEST_FIELDS)
-- gaim_request_fields_destroy(data->u.multifield.fields);
-+ gaim2_request_fields_destroy(data->u.multifield.fields);
- else if (type == GAIM_REQUEST_FILE)
- g_free(data->u.file.name);
-
- g_free(data);
- }
-
--static GaimRequestUiOps ops =
-+static Gaim2RequestUiOps ops =
- {
-- gaim_gtk_request_input,
-- gaim_gtk_request_choice,
-- gaim_gtk_request_action,
-- gaim_gtk_request_fields,
-- gaim_gtk_request_file,
-- gaim_gtk_close_request
-+ gaim2_gtk_request_input,
-+ gaim2_gtk_request_choice,
-+ gaim2_gtk_request_action,
-+ gaim2_gtk_request_fields,
-+ gaim2_gtk_request_file,
-+ gaim2_gtk_close_request
- };
-
--GaimRequestUiOps *
--gaim_gtk_request_get_ui_ops(void)
-+Gaim2RequestUiOps *
-+gaim2_gtk_request_get_ui_ops(void)
- {
- return &ops;
- }
-diff -prNu ./src/gtkrequest.h ./src/gtkrequest.h
---- ./src/gtkrequest.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gtkrequest.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkrequest.h GTK+ Request API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,6 +32,6 @@
- *
- * @return The GTK+ UI request operations structure.
- */
--GaimRequestUiOps *gaim_gtk_request_get_ui_ops(void);
-+Gaim2RequestUiOps *gaim2_gtk_request_get_ui_ops(void);
-
- #endif /* _GAIM_GTKREQUEST_H_ */
-diff -prNu ./src/gtkroomlist.c ./src/gtkroomlist.c
---- ./src/gtkroomlist.c 2005-12-21 19:36:11.000000000 +0100
-+++ ./src/gtkroomlist.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkroomlist.c GTK+ Room List UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- */
-
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkutils.h"
- #include "gtkstock.h"
- #include "debug.h"
-@@ -34,15 +34,15 @@
-
- #include "gtkroomlist.h"
-
--typedef struct _GaimGtkRoomlist {
-- GaimGtkRoomlistDialog *dialog;
-+typedef struct _Gaim2GtkRoomlist {
-+ Gaim2GtkRoomlistDialog *dialog;
- GtkTreeStore *model;
- GtkWidget *tree;
- GHashTable *cats; /**< Meow. */
- gint num_rooms, total_rooms;
--} GaimGtkRoomlist;
-+} Gaim2GtkRoomlist;
-
--struct _GaimGtkRoomlistDialog {
-+struct _Gaim2GtkRoomlistDialog {
- GtkWidget *window;
- GtkWidget *account_widget;
- GtkWidget *progress;
-@@ -53,8 +53,8 @@ struct _GaimGtkRoomlistDialog {
- GtkWidget *join_button;
- GtkWidget *close_button;
-
-- GaimAccount *account;
-- GaimRoomlist *roomlist;
-+ Gaim2Account *account;
-+ Gaim2Roomlist *roomlist;
-
- gboolean pg_needs_pulse;
- gboolean pg_to_active;
-@@ -71,55 +71,55 @@ static GList *roomlists = NULL;
-
- static gint delete_win_cb(GtkWidget *w, GdkEventAny *e, gpointer d)
- {
-- GaimGtkRoomlistDialog *dialog;
-+ Gaim2GtkRoomlistDialog *dialog;
-
-- dialog = (GaimGtkRoomlistDialog *) d;
-+ dialog = (Gaim2GtkRoomlistDialog *) d;
-
-- if (dialog->roomlist && gaim_roomlist_get_in_progress(dialog->roomlist))
-- gaim_roomlist_cancel_get_list(dialog->roomlist);
-+ if (dialog->roomlist && gaim2_roomlist_get_in_progress(dialog->roomlist))
-+ gaim2_roomlist_cancel_get_list(dialog->roomlist);
-
- if (dialog->roomlist) {
- if (dialog->pg_to_active) {
-- gaim_timeout_remove(dialog->pg_update_to);
-+ gaim2_timeout_remove(dialog->pg_update_to);
- dialog->pg_to_active = FALSE;
- /* yes, that's right, unref it twice. */
-- gaim_roomlist_unref(dialog->roomlist);
-+ gaim2_roomlist_unref(dialog->roomlist);
- }
- }
-
- /* free stuff here */
- if (dialog->roomlist)
-- gaim_roomlist_unref(dialog->roomlist);
-+ gaim2_roomlist_unref(dialog->roomlist);
- g_free(dialog);
-
- return FALSE;
- }
-
--static void dialog_select_account_cb(GObject *w, GaimAccount *account,
-- GaimGtkRoomlistDialog *dialog)
-+static void dialog_select_account_cb(GObject *w, Gaim2Account *account,
-+ Gaim2GtkRoomlistDialog *dialog)
- {
- dialog->account = account;
- }
-
--static void list_button_cb(GtkButton *button, GaimGtkRoomlistDialog *dialog)
-+static void list_button_cb(GtkButton *button, Gaim2GtkRoomlistDialog *dialog)
- {
-- GaimConnection *gc;
-- GaimGtkRoomlist *rl;
-+ Gaim2Connection *gc;
-+ Gaim2GtkRoomlist *rl;
-
-- gc = gaim_account_get_connection(dialog->account);
-+ gc = gaim2_account_get_connection(dialog->account);
- if (!gc)
- return;
-
- if (dialog->roomlist != NULL) {
- rl = dialog->roomlist->ui_data;
- gtk_widget_destroy(rl->tree);
-- gaim_roomlist_unref(dialog->roomlist);
-+ gaim2_roomlist_unref(dialog->roomlist);
- }
-
-- dialog->roomlist = gaim_roomlist_get_list(gc);
-+ dialog->roomlist = gaim2_roomlist_get_list(gc);
- if (!dialog->roomlist)
- return;
-- gaim_roomlist_ref(dialog->roomlist);
-+ gaim2_roomlist_ref(dialog->roomlist);
- rl = dialog->roomlist->ui_data;
- rl->dialog = dialog;
-
-@@ -133,9 +133,9 @@ static void list_button_cb(GtkButton *bu
- gtk_widget_set_sensitive(dialog->join_button, FALSE);
- }
-
--static void stop_button_cb(GtkButton *button, GaimGtkRoomlistDialog *dialog)
-+static void stop_button_cb(GtkButton *button, Gaim2GtkRoomlistDialog *dialog)
- {
-- gaim_roomlist_cancel_get_list(dialog->roomlist);
-+ gaim2_roomlist_cancel_get_list(dialog->roomlist);
-
- if (dialog->account_widget)
- gtk_widget_set_sensitive(dialog->account_widget, TRUE);
-@@ -145,7 +145,7 @@ static void stop_button_cb(GtkButton *bu
- gtk_widget_set_sensitive(dialog->join_button, FALSE);
- }
-
--static void close_button_cb(GtkButton *button, GaimGtkRoomlistDialog *dialog)
-+static void close_button_cb(GtkButton *button, Gaim2GtkRoomlistDialog *dialog)
- {
- GtkWidget *window = dialog->window;
-
-@@ -154,8 +154,8 @@ static void close_button_cb(GtkButton *b
- }
-
- struct _menu_cb_info {
-- GaimRoomlist *list;
-- GaimRoomlistRoom *room;
-+ Gaim2Roomlist *list;
-+ Gaim2RoomlistRoom *room;
- };
-
- static void
-@@ -164,12 +164,12 @@ join_button_data_change_cb(gpointer data
- }
-
- static void
--selection_changed_cb(GtkTreeSelection *selection, GaimGtkRoomlist *grl) {
-+selection_changed_cb(GtkTreeSelection *selection, Gaim2GtkRoomlist *grl) {
- GtkTreeIter iter;
- GValue val;
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
- static struct _menu_cb_info *info;
-- GaimGtkRoomlistDialog *dialog;
-+ Gaim2GtkRoomlistDialog *dialog;
-
- dialog = grl->dialog;
-
-@@ -197,13 +197,13 @@ selection_changed_cb(GtkTreeSelection *s
-
- static void do_join_cb(GtkWidget *w, struct _menu_cb_info *info)
- {
-- gaim_roomlist_room_join(info->list, info->room);
-+ gaim2_roomlist_room_join(info->list, info->room);
- }
-
--static void join_button_cb(GtkButton *button, GaimGtkRoomlistDialog *dialog)
-+static void join_button_cb(GtkButton *button, Gaim2GtkRoomlistDialog *dialog)
- {
-- GaimRoomlist *rl = dialog->roomlist;
-- GaimGtkRoomlist *grl = rl->ui_data;
-+ Gaim2Roomlist *rl = dialog->roomlist;
-+ Gaim2GtkRoomlist *grl = rl->ui_data;
- struct _menu_cb_info *info;
-
- info = (struct _menu_cb_info*)g_object_get_data(G_OBJECT(button), "room-info");
-@@ -213,11 +213,11 @@ static void join_button_cb(GtkButton *bu
- }
-
- static void row_activated_cb(GtkTreeView *tv, GtkTreePath *path, GtkTreeViewColumn *arg2,
-- GaimRoomlist *list)
-+ Gaim2Roomlist *list)
- {
-- GaimGtkRoomlist *grl = list->ui_data;
-+ Gaim2GtkRoomlist *grl = list->ui_data;
- GtkTreeIter iter;
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
- GValue val;
- struct _menu_cb_info info;
-
-@@ -234,12 +234,12 @@ static void row_activated_cb(GtkTreeView
- do_join_cb(GTK_WIDGET(tv), &info);
- }
-
--static gboolean room_click_cb(GtkWidget *tv, GdkEventButton *event, GaimRoomlist *list)
-+static gboolean room_click_cb(GtkWidget *tv, GdkEventButton *event, Gaim2Roomlist *list)
- {
- GtkTreePath *path;
-- GaimGtkRoomlist *grl = list->ui_data;
-+ Gaim2GtkRoomlist *grl = list->ui_data;
- GValue val;
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
- GtkTreeIter iter;
- GtkWidget *menu;
- static struct _menu_cb_info info; /* XXX? */
-@@ -264,7 +264,7 @@ static gboolean room_click_cb(GtkWidget
-
-
- menu = gtk_menu_new();
-- gaim_new_item_from_stock(menu, _("_Join"), GAIM_STOCK_CHAT,
-+ gaim2_new_item_from_stock(menu, _("_Join"), GAIM_STOCK_CHAT,
- G_CALLBACK(do_join_cb), &info, 0, 0, NULL);
-
-
-@@ -276,8 +276,8 @@ static gboolean room_click_cb(GtkWidget
-
- static void row_expanded_cb(GtkTreeView *treeview, GtkTreeIter *arg1, GtkTreePath *arg2, gpointer user_data)
- {
-- GaimRoomlist *list = user_data;
-- GaimRoomlistRoom *category;
-+ Gaim2Roomlist *list = user_data;
-+ Gaim2RoomlistRoom *category;
- GValue val;
-
- val.g_type = 0;
-@@ -285,15 +285,15 @@ static void row_expanded_cb(GtkTreeView
- category = g_value_get_pointer(&val);
-
- if (!category->expanded_once) {
-- gaim_roomlist_expand_category(list, category);
-+ gaim2_roomlist_expand_category(list, category);
- category->expanded_once = TRUE;
- }
- }
-
--static gboolean account_filter_func(GaimAccount *account)
-+static gboolean account_filter_func(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -301,24 +301,24 @@ static gboolean account_filter_func(Gaim
- }
-
- gboolean
--gaim_gtk_roomlist_is_showable()
-+gaim2_gtk_roomlist_is_showable()
- {
- GList *c;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- for (c = gaim_connections_get_all(); c != NULL; c = c->next) {
-+ for (c = gaim2_connections_get_all(); c != NULL; c = c->next) {
- gc = c->data;
-
-- if (account_filter_func(gaim_connection_get_account(gc)))
-+ if (account_filter_func(gaim2_connection_get_account(gc)))
- return TRUE;
- }
-
- return FALSE;
- }
-
--GaimGtkRoomlistDialog *gaim_gtk_roomlist_dialog_new_with_account(GaimAccount *account)
-+Gaim2GtkRoomlistDialog *gaim2_gtk_roomlist_dialog_new_with_account(Gaim2Account *account)
- {
-- GaimGtkRoomlistDialog *dialog;
-+ Gaim2GtkRoomlistDialog *dialog;
- GtkWidget *window;
- GtkWidget *vbox;
- GtkWidget *vbox2;
-@@ -326,7 +326,7 @@ GaimGtkRoomlistDialog *gaim_gtk_roomlist
- GtkWidget *bbox;
- GtkWidget *label;
-
-- dialog = g_new0(GaimGtkRoomlistDialog, 1);
-+ dialog = g_new0(Gaim2GtkRoomlistDialog, 1);
- dialog->account = account;
-
- /* Create the window. */
-@@ -359,11 +359,11 @@ GaimGtkRoomlistDialog *gaim_gtk_roomlist
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
- gtk_widget_show(label);
-
-- dialog->account_widget = gaim_gtk_account_option_menu_new(dialog->account, FALSE,
-+ dialog->account_widget = gaim2_gtk_account_option_menu_new(dialog->account, FALSE,
- G_CALLBACK(dialog_select_account_cb), account_filter_func, dialog);
-
- if (!dialog->account) /* this is normally null, and we normally don't care what the first selected item is */
-- dialog->account = gaim_gtk_account_option_menu_get_selected(dialog->account_widget);
-+ dialog->account = gaim2_gtk_account_option_menu_get_selected(dialog->account_widget);
-
- gtk_box_pack_start(GTK_BOX(account_hbox), dialog->account_widget, TRUE, TRUE, 0);
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), GTK_WIDGET(dialog->account_widget));
-@@ -410,7 +410,7 @@ GaimGtkRoomlistDialog *gaim_gtk_roomlist
- gtk_widget_show(dialog->list_button);
-
- /* join button */
-- dialog->join_button = gaim_pixbuf_button_from_stock(_("_Join"), GAIM_STOCK_CHAT,
-+ dialog->join_button = gaim2_pixbuf_button_from_stock(_("_Join"), GAIM_STOCK_CHAT,
- GAIM_BUTTON_HORIZONTAL);
- gtk_box_pack_start(GTK_BOX(bbox), dialog->join_button, FALSE, FALSE, 0);
- g_signal_connect(G_OBJECT(dialog->join_button), "clicked",
-@@ -431,32 +431,32 @@ GaimGtkRoomlistDialog *gaim_gtk_roomlist
- return dialog;
- }
-
--GaimGtkRoomlistDialog *gaim_gtk_roomlist_dialog_new(void)
-+Gaim2GtkRoomlistDialog *gaim2_gtk_roomlist_dialog_new(void)
- {
-- return gaim_gtk_roomlist_dialog_new_with_account(NULL);
-+ return gaim2_gtk_roomlist_dialog_new_with_account(NULL);
- }
-
--static void gaim_gtk_roomlist_dialog_show_with_account(GaimAccount *account)
-+static void gaim2_gtk_roomlist_dialog_show_with_account(Gaim2Account *account)
- {
-- GaimGtkRoomlistDialog *dialog;
-+ Gaim2GtkRoomlistDialog *dialog;
-
-- dialog = gaim_gtk_roomlist_dialog_new_with_account(account);
-+ dialog = gaim2_gtk_roomlist_dialog_new_with_account(account);
- if (!dialog)
- return;
-
- list_button_cb(GTK_BUTTON(dialog->list_button), dialog);
- }
-
--void gaim_gtk_roomlist_dialog_show(void)
-+void gaim2_gtk_roomlist_dialog_show(void)
- {
-- gaim_gtk_roomlist_dialog_new();
-+ gaim2_gtk_roomlist_dialog_new();
- }
-
--static void gaim_gtk_roomlist_new(GaimRoomlist *list)
-+static void gaim2_gtk_roomlist_new(Gaim2Roomlist *list)
- {
-- GaimGtkRoomlist *rl;
-+ Gaim2GtkRoomlist *rl;
-
-- rl = g_new0(GaimGtkRoomlist, 1);
-+ rl = g_new0(Gaim2GtkRoomlist, 1);
-
- list->ui_data = rl;
-
-@@ -519,9 +519,9 @@ _search_func(GtkTreeModel *model, gint c
- return result;
- }
-
--static void gaim_gtk_roomlist_set_fields(GaimRoomlist *list, GList *fields)
-+static void gaim2_gtk_roomlist_set_fields(Gaim2Roomlist *list, GList *fields)
- {
-- GaimGtkRoomlist *grl = list->ui_data;
-+ Gaim2GtkRoomlist *grl = list->ui_data;
- gint columns = NUM_OF_COLUMNS;
- int j;
- GtkTreeStore *model;
-@@ -541,7 +541,7 @@ static void gaim_gtk_roomlist_set_fields
- types[ROOM_COLUMN] = G_TYPE_POINTER;
-
- for (j = NUM_OF_COLUMNS, l = fields; l; l = l->next, j++) {
-- GaimRoomlistField *f = l->data;
-+ Gaim2RoomlistField *f = l->data;
-
- switch (f->type) {
- case GAIM_ROOMLIST_FIELD_BOOL:
-@@ -583,7 +583,7 @@ static void gaim_gtk_roomlist_set_fields
- gtk_tree_view_append_column(GTK_TREE_VIEW(tree), column);
-
- for (j = NUM_OF_COLUMNS, l = fields; l; l = l->next, j++) {
-- GaimRoomlistField *f = l->data;
-+ Gaim2RoomlistField *f = l->data;
-
- if (f->hidden)
- continue;
-@@ -615,14 +615,14 @@ static void gaim_gtk_roomlist_set_fields
-
- }
-
--static gboolean gaim_gtk_progress_bar_pulse(gpointer data)
-+static gboolean gaim2_gtk_progress_bar_pulse(gpointer data)
- {
-- GaimRoomlist *list = data;
-- GaimGtkRoomlist *rl = list->ui_data;
-+ Gaim2Roomlist *list = data;
-+ Gaim2GtkRoomlist *rl = list->ui_data;
-
- if (!rl || !rl->dialog || !rl->dialog->pg_needs_pulse) {
- rl->dialog->pg_to_active = FALSE;
-- gaim_roomlist_unref(list);
-+ gaim2_roomlist_unref(list);
- return FALSE;
- }
-
-@@ -631,9 +631,9 @@ static gboolean gaim_gtk_progress_bar_pu
- return TRUE;
- }
-
--static void gaim_gtk_roomlist_add_room(GaimRoomlist *list, GaimRoomlistRoom *room)
-+static void gaim2_gtk_roomlist_add_room(Gaim2Roomlist *list, Gaim2RoomlistRoom *room)
- {
-- GaimGtkRoomlist *rl = list->ui_data;
-+ Gaim2GtkRoomlist *rl = list->ui_data;
- GtkTreeRowReference *rr, *parentrr = NULL;
- GtkTreePath *path;
- GtkTreeIter iter, parent, child;
-@@ -648,8 +648,8 @@ static void gaim_gtk_roomlist_add_room(G
- if (rl->dialog) {
- if (!rl->dialog->pg_to_active) {
- rl->dialog->pg_to_active = TRUE;
-- gaim_roomlist_ref(list);
-- rl->dialog->pg_update_to = g_timeout_add(100, gaim_gtk_progress_bar_pulse, list);
-+ gaim2_roomlist_ref(list);
-+ rl->dialog->pg_update_to = g_timeout_add(100, gaim2_gtk_progress_bar_pulse, list);
- gtk_progress_bar_pulse(GTK_PROGRESS_BAR(rl->dialog->progress));
- } else {
- rl->dialog->pg_needs_pulse = TRUE;
-@@ -659,7 +659,7 @@ static void gaim_gtk_roomlist_add_room(G
- parentrr = g_hash_table_lookup(rl->cats, room->parent);
- path = gtk_tree_row_reference_get_path(parentrr);
- if (path) {
-- GaimRoomlistRoom *tmproom = NULL;
-+ Gaim2RoomlistRoom *tmproom = NULL;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(rl->model), &parent, path);
- gtk_tree_path_free(path);
-@@ -693,16 +693,16 @@ static void gaim_gtk_roomlist_add_room(G
- gtk_tree_store_set(rl->model, &iter, ROOM_COLUMN, room, -1);
-
- for (j = NUM_OF_COLUMNS, l = room->fields, k = list->fields; l && k; j++, l = l->next, k = k->next) {
-- GaimRoomlistField *f = k->data;
-+ Gaim2RoomlistField *f = k->data;
- if (f->hidden)
- continue;
- gtk_tree_store_set(rl->model, &iter, j, l->data, -1);
- }
- }
-
--static void gaim_gtk_roomlist_in_progress(GaimRoomlist *list, gboolean flag)
-+static void gaim2_gtk_roomlist_in_progress(Gaim2Roomlist *list, gboolean flag)
- {
-- GaimGtkRoomlist *rl = list->ui_data;
-+ Gaim2GtkRoomlist *rl = list->ui_data;
-
- if (!rl || !rl->dialog)
- return;
-@@ -722,9 +722,9 @@ static void gaim_gtk_roomlist_in_progres
- }
- }
-
--static void gaim_gtk_roomlist_destroy(GaimRoomlist *list)
-+static void gaim2_gtk_roomlist_destroy(Gaim2Roomlist *list)
- {
-- GaimGtkRoomlist *rl;
-+ Gaim2GtkRoomlist *rl;
-
- roomlists = g_list_remove(roomlists, list);
-
-@@ -737,17 +737,17 @@ static void gaim_gtk_roomlist_destroy(Ga
- list->ui_data = NULL;
- }
-
--static GaimRoomlistUiOps ops = {
-- gaim_gtk_roomlist_dialog_show_with_account,
-- gaim_gtk_roomlist_new,
-- gaim_gtk_roomlist_set_fields,
-- gaim_gtk_roomlist_add_room,
-- gaim_gtk_roomlist_in_progress,
-- gaim_gtk_roomlist_destroy
-+static Gaim2RoomlistUiOps ops = {
-+ gaim2_gtk_roomlist_dialog_show_with_account,
-+ gaim2_gtk_roomlist_new,
-+ gaim2_gtk_roomlist_set_fields,
-+ gaim2_gtk_roomlist_add_room,
-+ gaim2_gtk_roomlist_in_progress,
-+ gaim2_gtk_roomlist_destroy
- };
-
-
--void gaim_gtk_roomlist_init(void)
-+void gaim2_gtk_roomlist_init(void)
- {
-- gaim_roomlist_set_ui_ops(&ops);
-+ gaim2_roomlist_set_ui_ops(&ops);
- }
-diff -prNu ./src/gtkroomlist.h ./src/gtkroomlist.h
---- ./src/gtkroomlist.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/gtkroomlist.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkroomlist.h GTK+ Room List UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,12 +28,12 @@
- #include "roomlist.h"
-
-
--typedef struct _GaimGtkRoomlistDialog GaimGtkRoomlistDialog;
-+typedef struct _Gaim2GtkRoomlistDialog Gaim2GtkRoomlistDialog;
-
- /**
- * Initializes the room list subsystem.
- */
--void gaim_gtk_roomlist_init(void);
-+void gaim2_gtk_roomlist_init(void);
-
- /**
- * Determines if showing the room list dialog is a valid action.
-@@ -41,19 +41,19 @@ void gaim_gtk_roomlist_init(void);
- * @return TRUE if there are accounts online that support listing
- * chat rooms. Otherwise return FALSE.
- */
--gboolean gaim_gtk_roomlist_is_showable(void);
-+gboolean gaim2_gtk_roomlist_is_showable(void);
-
- /**
- * Shows the roomlist dialog.
- */
--void gaim_gtk_roomlist_dialog_show(void);
-+void gaim2_gtk_roomlist_dialog_show(void);
-
- /**
- * Creates a new room list dialog.
- *
- * @return The new dialog.
- */
--GaimGtkRoomlistDialog *gaim_gtk_roomlist_dialog_new(void);
-+Gaim2GtkRoomlistDialog *gaim2_gtk_roomlist_dialog_new(void);
-
- /**
- * Creates a new room list dialog and fetch the list on
-@@ -62,6 +62,6 @@ GaimGtkRoomlistDialog *gaim_gtk_roomlist
- * @param account The account to force.
- * @return The new dialog.
- */
--GaimGtkRoomlistDialog *gaim_gtk_roomlist_dialog_new_with_account(GaimAccount *account);
-+Gaim2GtkRoomlistDialog *gaim2_gtk_roomlist_dialog_new_with_account(Gaim2Account *account);
-
- #endif /* _GAIM_GTKROOMLIST_H_ */
-diff -prNu ./src/gtksavedstatuses.c ./src/gtksavedstatuses.c
---- ./src/gtksavedstatuses.c 2006-01-05 01:39:52.000000000 +0100
-+++ ./src/gtksavedstatuses.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtksavedstatus.c GTK+ Saved Status Editor UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,7 +33,7 @@
-
- #include "gtkblist.h"
- #include "gtkexpander.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtkimhtml.h"
- #include "gtkimhtmltoolbar.h"
- #include "gtksavedstatuses.h"
-@@ -65,12 +65,12 @@ enum
- */
- enum
- {
-- /** A hidden column containing a pointer to the GaimAccount */
-+ /** A hidden column containing a pointer to the Gaim2Account */
- STATUS_EDITOR_COLUMN_ACCOUNT,
- STATUS_EDITOR_COLUMN_ENABLE_SUBSTATUS,
- STATUS_EDITOR_COLUMN_ICON,
- STATUS_EDITOR_COLUMN_SCREENNAME,
-- /** A hidden column containing the ID of this GaimStatusType. */
-+ /** A hidden column containing the ID of this Gaim2StatusType. */
- STATUS_EDITOR_COLUMN_STATUS_ID,
- STATUS_EDITOR_COLUMN_STATUS_NAME,
- STATUS_EDITOR_COLUMN_STATUS_MESSAGE,
-@@ -79,15 +79,15 @@ enum
-
- /**
- * These are used in the GtkComboBox to select the specific
-- * GaimStatusType when setting a substatus for a particular saved
-+ * Gaim2StatusType when setting a substatus for a particular saved
- * status.
- */
- enum
- {
-- /** A hidden column containing a pointer to the GaimAccount. */
-+ /** A hidden column containing a pointer to the Gaim2Account. */
- SUBSTATUS_COLUMN_ACCOUNT,
- SUBSTATUS_COLUMN_ICON,
-- /** A hidden column containing the ID of this GaimStatusType. */
-+ /** A hidden column containing the ID of this Gaim2StatusType. */
- SUBSTATUS_COLUMN_STATUS_ID,
- SUBSTATUS_COLUMN_STATUS_NAME,
- SUBSTATUS_NUM_COLUMNS
-@@ -120,7 +120,7 @@ typedef struct
- typedef struct
- {
- StatusEditor *status_editor;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- GtkWidget *window;
- GtkListStore *model;
-@@ -173,7 +173,7 @@ status_window_destroy_cb(GtkWidget *widg
- StatusWindow *dialog = user_data;
-
- dialog->window = NULL;
-- gaim_gtk_status_window_hide();
-+ gaim2_gtk_status_window_hide();
-
- return FALSE;
- }
-@@ -227,13 +227,13 @@ status_window_use_cb(GtkButton *button,
- &iter, list->data))
- {
- gchar *title;
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
- gtk_tree_model_get(GTK_TREE_MODEL(dialog->model), &iter,
- STATUS_WINDOW_COLUMN_TITLE, &title,
- -1);
-- saved_status = gaim_savedstatus_find(title);
-+ saved_status = gaim2_savedstatus_find(title);
- g_free(title);
-- gaim_savedstatus_activate(saved_status);
-+ gaim2_savedstatus_activate(saved_status);
- }
-
- g_list_foreach(list, (GFunc)gtk_tree_path_free, NULL);
-@@ -243,7 +243,7 @@ status_window_use_cb(GtkButton *button,
- static void
- status_window_add_cb(GtkButton *button, gpointer user_data)
- {
-- gaim_gtk_status_editor_show(NULL);
-+ gaim2_gtk_status_editor_show(NULL);
- }
-
- static void
-@@ -251,12 +251,12 @@ status_window_modify_foreach(GtkTreeMode
- GtkTreeIter *iter, gpointer user_data)
- {
- gchar *title;
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
-
- gtk_tree_model_get(model, iter, STATUS_WINDOW_COLUMN_TITLE, &title, -1);
-- saved_status = gaim_savedstatus_find(title);
-+ saved_status = gaim2_savedstatus_find(title);
- g_free(title);
-- gaim_gtk_status_editor_show(saved_status);
-+ gaim2_gtk_status_editor_show(saved_status);
- }
-
- static void
-@@ -278,7 +278,7 @@ status_window_delete_confirm_cb(char *ti
- if (status_window_find_savedstatus(&iter, title))
- gtk_list_store_remove(status_window->model, &iter);
-
-- gaim_savedstatus_delete(title);
-+ gaim2_savedstatus_delete(title);
-
- g_free(title);
- }
-@@ -293,7 +293,7 @@ status_window_delete_foreach(GtkTreeMode
- gtk_tree_model_get(model, iter, STATUS_WINDOW_COLUMN_TITLE, &title, -1);
-
- buf = g_strdup_printf(_("Are you sure you want to delete %s?"), title);
-- gaim_request_action(NULL, NULL, buf, NULL, 0, title, 2,
-+ gaim2_request_action(NULL, NULL, buf, NULL, 0, title, 2,
- _("Delete"), status_window_delete_confirm_cb,
- _("Cancel"), g_free);
- g_free(buf);
-@@ -313,7 +313,7 @@ status_window_delete_cb(GtkButton *butto
- static void
- status_window_close_cb(GtkButton *button, gpointer user_data)
- {
-- gaim_gtk_status_window_hide();
-+ gaim2_gtk_status_window_hide();
- }
-
- static void
-@@ -334,19 +334,19 @@ status_selected_cb(GtkTreeSelection *sel
- }
-
- static void
--add_status_to_saved_status_list(GtkListStore *model, GaimSavedStatus *saved_status)
-+add_status_to_saved_status_list(GtkListStore *model, Gaim2SavedStatus *saved_status)
- {
- GtkTreeIter iter;
- const char *title;
- const char *type;
- char *message;
-
-- if (gaim_savedstatus_is_transient(saved_status))
-+ if (gaim2_savedstatus_is_transient(saved_status))
- return;
-
-- title = gaim_savedstatus_get_title(saved_status);
-- type = gaim_primitive_get_name_from_type(gaim_savedstatus_get_type(saved_status));
-- message = gaim_markup_strip_html(gaim_savedstatus_get_message(saved_status));
-+ title = gaim2_savedstatus_get_title(saved_status);
-+ type = gaim2_primitive_get_name_from_type(gaim2_savedstatus_get_type(saved_status));
-+ message = gaim2_markup_strip_html(gaim2_savedstatus_get_message(saved_status));
-
- gtk_list_store_append(model, &iter);
- gtk_list_store_set(model, &iter,
-@@ -364,7 +364,7 @@ populate_saved_status_list(StatusWindow
-
- gtk_list_store_clear(dialog->model);
-
-- for (saved_statuses = gaim_savedstatuses_get_all(); saved_statuses != NULL;
-+ for (saved_statuses = gaim2_savedstatuses_get_all(); saved_statuses != NULL;
- saved_statuses = g_list_next(saved_statuses))
- {
- add_status_to_saved_status_list(dialog->model, saved_statuses->data);
-@@ -379,7 +379,7 @@ search_func(GtkTreeModel *model, gint co
-
- gtk_tree_model_get(model, iter, column, &haystack, -1);
-
-- result = (gaim_strcasestr(haystack, key) == NULL);
-+ result = (gaim2_strcasestr(haystack, key) == NULL);
-
- g_free(haystack);
-
-@@ -491,15 +491,15 @@ static gboolean
- configure_cb(GtkWidget *widget, GdkEventConfigure *event, StatusWindow *dialog)
- {
- if (GTK_WIDGET_VISIBLE(widget)) {
-- gaim_prefs_set_int("/gaim/gtk/status/dialog/width", event->width);
-- gaim_prefs_set_int("/gaim/gtk/status/dialog/height", event->height);
-+ gaim2_prefs_set_int("/gaim2/gtk/status/dialog/width", event->width);
-+ gaim2_prefs_set_int("/gaim2/gtk/status/dialog/height", event->height);
- }
-
- return FALSE;
- }
-
- void
--gaim_gtk_status_window_show(void)
-+gaim2_gtk_status_window_show(void)
- {
- StatusWindow *dialog;
- GtkWidget *bbox;
-@@ -516,8 +516,8 @@ gaim_gtk_status_window_show(void)
-
- status_window = dialog = g_new0(StatusWindow, 1);
-
-- width = gaim_prefs_get_int("/gaim/gtk/status/dialog/width");
-- height = gaim_prefs_get_int("/gaim/gtk/status/dialog/height");
-+ width = gaim2_prefs_get_int("/gaim2/gtk/status/dialog/width");
-+ height = gaim2_prefs_get_int("/gaim2/gtk/status/dialog/height");
-
- dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
- gtk_window_set_default_size(GTK_WINDOW(win), width, height);
-@@ -547,7 +547,7 @@ gaim_gtk_status_window_show(void)
- gtk_widget_show(bbox);
-
- /* Use button */
-- button = gaim_pixbuf_button_from_stock(_("_Use"), GTK_STOCK_EXECUTE,
-+ button = gaim2_pixbuf_button_from_stock(_("_Use"), GTK_STOCK_EXECUTE,
- GAIM_BUTTON_HORIZONTAL);
- dialog->use_button = button;
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
-@@ -597,7 +597,7 @@ gaim_gtk_status_window_show(void)
- }
-
- void
--gaim_gtk_status_window_hide(void)
-+gaim2_gtk_status_window_hide(void)
- {
- if (status_window == NULL)
- return;
-@@ -641,9 +641,9 @@ status_editor_ok_cb(GtkButton *button, g
- {
- StatusEditor *dialog = user_data;
- const char *title;
-- GaimStatusPrimitive type;
-+ Gaim2StatusPrimitive type;
- char *message, *unformatted;
-- GaimSavedStatus *saved_status = NULL;
-+ Gaim2SavedStatus *saved_status = NULL;
- GtkTreeModel *model;
- GtkTreeIter iter;
-
-@@ -654,17 +654,17 @@ status_editor_ok_cb(GtkButton *button, g
- * then show an error dialog and don't do anything.
- */
- if (((button == dialog->saveanduse_button) || (button == dialog->save_button)) &&
-- (gaim_savedstatus_find(title) != NULL) &&
-+ (gaim2_savedstatus_find(title) != NULL) &&
- ((dialog->original_title == NULL) || (strcmp(title, dialog->original_title))))
- {
-- gaim_notify_error(NULL, NULL, _("Title already in use. You must "
-+ gaim2_notify_error(NULL, NULL, _("Title already in use. You must "
- "choose a unique title."), NULL);
- return;
- }
-
- type = gtk_option_menu_get_history(dialog->type) + (GAIM_STATUS_UNSET + 1);
- message = gtk_imhtml_get_markup(dialog->message);
-- unformatted = gaim_markup_strip_html(message);
-+ unformatted = gaim2_markup_strip_html(message);
-
- /*
- * If we're editing an old status, then lookup the old status (it's
-@@ -675,7 +675,7 @@ status_editor_ok_cb(GtkButton *button, g
- {
- GtkTreeIter iter;
-
-- saved_status = gaim_savedstatus_find(dialog->original_title);
-+ saved_status = gaim2_savedstatus_find(dialog->original_title);
-
- if (status_window_find_savedstatus(&iter, dialog->original_title))
- {
-@@ -688,30 +688,30 @@ status_editor_ok_cb(GtkButton *button, g
- /* This is a new status */
- if ((button == dialog->saveanduse_button)
- || (button == dialog->save_button))
-- saved_status = gaim_savedstatus_new(title, type);
-+ saved_status = gaim2_savedstatus_new(title, type);
- else
-- saved_status = gaim_savedstatus_new(NULL, type);
-+ saved_status = gaim2_savedstatus_new(NULL, type);
- }
- else
- {
- /* Modify the old status */
- if (strcmp(title, dialog->original_title))
-- gaim_savedstatus_set_title(saved_status, title);
-- gaim_savedstatus_set_type(saved_status, type);
-+ gaim2_savedstatus_set_title(saved_status, title);
-+ gaim2_savedstatus_set_type(saved_status, type);
- }
-
- if (*unformatted != '\0')
-- gaim_savedstatus_set_message(saved_status, message);
-+ gaim2_savedstatus_set_message(saved_status, message);
-
- /* Set any substatuses */
- model = GTK_TREE_MODEL(dialog->model);
- if (gtk_tree_model_get_iter_first(model, &iter))
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- gboolean enabled;
- char *id;
- char *message;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
- gtk_tree_model_get(model, &iter,
- STATUS_EDITOR_COLUMN_ACCOUNT, &account,
-@@ -721,8 +721,8 @@ status_editor_ok_cb(GtkButton *button, g
- -1);
- if (enabled)
- {
-- type = gaim_account_get_status_type(account, id);
-- gaim_savedstatus_set_substatus(saved_status, account, type, message);
-+ type = gaim2_account_get_status_type(account, id);
-+ gaim2_savedstatus_set_substatus(saved_status, account, type, message);
- }
- g_free(id);
- g_free(message);
-@@ -737,8 +737,8 @@ status_editor_ok_cb(GtkButton *button, g
- -1);
- if (enabled)
- {
-- type = gaim_account_get_status_type(account, id);
-- gaim_savedstatus_set_substatus(saved_status, account, type, message);
-+ type = gaim2_account_get_status_type(account, id);
-+ gaim2_savedstatus_set_substatus(saved_status, account, type, message);
- }
- g_free(id);
- g_free(message);
-@@ -757,7 +757,7 @@ status_editor_ok_cb(GtkButton *button, g
-
- if ((button == dialog->saveanduse_button)
- || (button != dialog->save_button))
-- gaim_savedstatus_activate(saved_status);
-+ gaim2_savedstatus_activate(saved_status);
- }
-
- static void
-@@ -773,7 +773,7 @@ editor_title_changed_cb(GtkWidget *widge
- }
-
- static GtkWidget *
--create_status_type_menu(GaimStatusPrimitive type)
-+create_status_type_menu(Gaim2StatusPrimitive type)
- {
- int i;
- GtkWidget *dropdown;
-@@ -785,7 +785,7 @@ create_status_type_menu(GaimStatusPrimit
-
- for (i = GAIM_STATUS_UNSET + 1; i < GAIM_STATUS_NUM_PRIMITIVES; i++)
- {
-- item = gtk_menu_item_new_with_label(gaim_primitive_get_name_from_type(i));
-+ item = gtk_menu_item_new_with_label(gaim2_primitive_get_name_from_type(i));
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), item);
- gtk_widget_show(item);
- }
-@@ -797,14 +797,14 @@ create_status_type_menu(GaimStatusPrimit
- return dropdown;
- }
-
--static void edit_substatus(StatusEditor *status_editor, GaimAccount *account);
-+static void edit_substatus(StatusEditor *status_editor, Gaim2Account *account);
-
- static void
- edit_substatus_cb(GtkTreeView *tv, GtkTreePath *path, GtkTreeViewColumn *col, gpointer user_data)
- {
- StatusEditor *dialog = user_data;
- GtkTreeIter iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- gtk_tree_model_get_iter(GTK_TREE_MODEL(dialog->model), &iter, path);
- gtk_tree_model_get(GTK_TREE_MODEL(dialog->model), &iter,
-@@ -820,7 +820,7 @@ status_editor_substatus_cb(GtkCellRender
- StatusEditor *dialog = (StatusEditor *)data;
- GtkTreeIter iter;
- gboolean enabled;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- gtk_tree_model_get_iter_from_string(GTK_TREE_MODEL(dialog->model), &iter, path_str);
- gtk_tree_model_get(GTK_TREE_MODEL(dialog->model), &iter,
-@@ -836,11 +836,11 @@ status_editor_substatus_cb(GtkCellRender
- }
- else
- {
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
-
- /* Remove the substatus */
-- saved_status = gaim_savedstatus_find(dialog->original_title);
-- gaim_savedstatus_unset_substatus(saved_status, account);
-+ saved_status = gaim2_savedstatus_find(dialog->original_title);
-+ gaim2_savedstatus_unset_substatus(saved_status, account);
- gtk_list_store_set(dialog->model, &iter,
- STATUS_EDITOR_COLUMN_ENABLE_SUBSTATUS, enabled,
- STATUS_EDITOR_COLUMN_STATUS_ID, NULL,
-@@ -913,8 +913,8 @@ status_editor_add_columns(StatusEditor *
- }
-
- static void
--status_editor_set_account(GtkListStore *store, GaimAccount *account,
-- GtkTreeIter *iter, GaimSavedStatusSub *substatus)
-+status_editor_set_account(GtkListStore *store, Gaim2Account *account,
-+ GtkTreeIter *iter, Gaim2SavedStatusSub *substatus)
- {
- GdkPixbuf *pixbuf;
- GdkPixbuf *scale;
-@@ -922,32 +922,32 @@ status_editor_set_account(GtkListStore *
-
- scale = NULL;
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL)
- {
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16, GDK_INTERP_BILINEAR);
-
-- if (gaim_account_is_disconnected(account))
-+ if (gaim2_account_is_disconnected(account))
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.0, FALSE);
- }
-
- if (substatus != NULL)
- {
-- const GaimStatusType *type;
-+ const Gaim2StatusType *type;
-
-- type = gaim_savedstatus_substatus_get_type(substatus);
-- id = gaim_status_type_get_id(type);
-- name = gaim_status_type_get_name(type);
-- if (gaim_status_type_get_attr(type, "message"))
-- message = gaim_savedstatus_substatus_get_message(substatus);
-+ type = gaim2_savedstatus_substatus_get_type(substatus);
-+ id = gaim2_status_type_get_id(type);
-+ name = gaim2_status_type_get_name(type);
-+ if (gaim2_status_type_get_attr(type, "message"))
-+ message = gaim2_savedstatus_substatus_get_message(substatus);
- }
-
- gtk_list_store_set(store, iter,
- STATUS_EDITOR_COLUMN_ACCOUNT, account,
- STATUS_EDITOR_COLUMN_ENABLE_SUBSTATUS, (substatus != NULL),
- STATUS_EDITOR_COLUMN_ICON, scale,
-- STATUS_EDITOR_COLUMN_SCREENNAME, gaim_account_get_username(account),
-+ STATUS_EDITOR_COLUMN_SCREENNAME, gaim2_account_get_username(account),
- STATUS_EDITOR_COLUMN_STATUS_ID, id,
- STATUS_EDITOR_COLUMN_STATUS_NAME, name,
- STATUS_EDITOR_COLUMN_STATUS_MESSAGE, message,
-@@ -958,8 +958,8 @@ status_editor_set_account(GtkListStore *
- }
-
- static void
--status_editor_add_account(StatusEditor *dialog, GaimAccount *account,
-- GaimSavedStatusSub *substatus)
-+status_editor_add_account(StatusEditor *dialog, Gaim2Account *account,
-+ Gaim2SavedStatusSub *substatus)
- {
- GtkTreeIter iter;
-
-@@ -969,19 +969,19 @@ status_editor_add_account(StatusEditor *
- }
-
- static void
--status_editor_populate_list(StatusEditor *dialog, GaimSavedStatus *saved_status)
-+status_editor_populate_list(StatusEditor *dialog, Gaim2SavedStatus *saved_status)
- {
- GList *iter;
-- GaimSavedStatusSub *substatus;
-+ Gaim2SavedStatusSub *substatus;
-
- gtk_list_store_clear(dialog->model);
-
-- for (iter = gaim_accounts_get_all(); iter != NULL; iter = iter->next)
-+ for (iter = gaim2_accounts_get_all(); iter != NULL; iter = iter->next)
- {
-- GaimAccount *account = (GaimAccount *)iter->data;
-+ Gaim2Account *account = (Gaim2Account *)iter->data;
-
- if (saved_status != NULL)
-- substatus = gaim_savedstatus_get_substatus(saved_status, account);
-+ substatus = gaim2_savedstatus_get_substatus(saved_status, account);
- else
- substatus = NULL;
-
-@@ -990,7 +990,7 @@ status_editor_populate_list(StatusEditor
- }
-
- void
--gaim_gtk_status_editor_show(GaimSavedStatus *saved_status)
-+gaim2_gtk_status_editor_show(Gaim2SavedStatus *saved_status)
- {
- StatusEditor *dialog;
- GtkSizeGroup *sg;
-@@ -1012,7 +1012,7 @@ gaim_gtk_status_editor_show(GaimSavedSta
- dialog = g_new0(StatusEditor, 1);
-
- if (saved_status != NULL)
-- dialog->original_title = g_strdup(gaim_savedstatus_get_title(saved_status));
-+ dialog->original_title = g_strdup(gaim2_savedstatus_get_title(saved_status));
-
- dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
- gtk_window_set_role(GTK_WINDOW(win), "status");
-@@ -1062,7 +1062,7 @@ gaim_gtk_status_editor_show(GaimSavedSta
- gtk_size_group_add_widget(sg, label);
-
- if (saved_status != NULL)
-- dropdown = create_status_type_menu(gaim_savedstatus_get_type(saved_status));
-+ dropdown = create_status_type_menu(gaim2_savedstatus_get_type(saved_status));
- else
- dropdown = create_status_type_menu(GAIM_STATUS_AWAY);
- dialog->type = GTK_OPTION_MENU(dropdown);
-@@ -1080,14 +1080,14 @@ gaim_gtk_status_editor_show(GaimSavedSta
- gtk_widget_show(label);
- gtk_size_group_add_widget(sg, label);
-
-- frame = gaim_gtk_create_imhtml(TRUE, &text, &toolbar);
-+ frame = gaim2_gtk_create_imhtml(TRUE, &text, &toolbar);
- dialog->message = GTK_IMHTML(text);
- gtk_box_pack_start(GTK_BOX(hbox), frame, TRUE, TRUE, 0);
- gtk_widget_show(frame);
-
-- if ((saved_status != NULL) && (gaim_savedstatus_get_message(saved_status) != NULL))
-+ if ((saved_status != NULL) && (gaim2_savedstatus_get_message(saved_status) != NULL))
- gtk_imhtml_append_text(GTK_IMHTML(text),
-- gaim_savedstatus_get_message(saved_status), 0);
-+ gaim2_savedstatus_get_message(saved_status), 0);
-
- /* Different status message expander */
- expander = gtk_expander_new_with_mnemonic(_("Use a _different status for some accounts"));
-@@ -1147,7 +1147,7 @@ gaim_gtk_status_editor_show(GaimSavedSta
- G_CALLBACK(status_editor_cancel_cb), dialog);
-
- /* Use button */
-- button = gaim_pixbuf_button_from_stock(_("_Use"), GTK_STOCK_EXECUTE,
-+ button = gaim2_pixbuf_button_from_stock(_("_Use"), GTK_STOCK_EXECUTE,
- GAIM_BUTTON_HORIZONTAL);
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
- gtk_widget_show(button);
-@@ -1156,7 +1156,7 @@ gaim_gtk_status_editor_show(GaimSavedSta
- G_CALLBACK(status_editor_ok_cb), dialog);
-
- /* Save & Use button */
-- button = gaim_pixbuf_button_from_stock(_("Sa_ve & Use"), GTK_STOCK_OK,
-+ button = gaim2_pixbuf_button_from_stock(_("Sa_ve & Use"), GTK_STOCK_OK,
- GAIM_BUTTON_HORIZONTAL);
- dialog->saveanduse_button = GTK_BUTTON(button);
- gtk_box_pack_start(GTK_BOX(bbox), button, FALSE, FALSE, 0);
-@@ -1191,9 +1191,9 @@ substatus_selection_changed_cb(GtkComboB
- {
- SubStatusEditor *select = user_data;
- GtkTreeIter iter;
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *id;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
- if (!gtk_combo_box_get_active_iter(box, &iter))
- return;
-@@ -1201,10 +1201,10 @@ substatus_selection_changed_cb(GtkComboB
- SUBSTATUS_COLUMN_ACCOUNT, &account,
- SUBSTATUS_COLUMN_STATUS_ID, &id,
- -1);
-- type = gaim_account_get_status_type(account, id);
-+ type = gaim2_account_get_status_type(account, id);
- g_free(id);
-
-- if (gaim_status_type_get_attr(type, "message") == NULL)
-+ if (gaim2_status_type_get_attr(type, "message") == NULL)
- {
- gtk_widget_set_sensitive(GTK_WIDGET(select->message), FALSE);
- gtk_widget_set_sensitive(GTK_WIDGET(select->toolbar), FALSE);
-@@ -1239,10 +1239,10 @@ substatus_editor_cancel_cb(GtkButton *bu
- static gboolean
- status_editor_find_account_in_treemodel(GtkTreeIter *iter,
- StatusEditor *status_editor,
-- GaimAccount *account)
-+ Gaim2Account *account)
- {
- GtkTreeModel *model;
-- GaimAccount *cur;
-+ Gaim2Account *cur;
-
- g_return_val_if_fail(status_editor != NULL, FALSE);
- g_return_val_if_fail(account != NULL, FALSE);
-@@ -1272,8 +1272,8 @@ substatus_editor_ok_cb(GtkButton *button
- SubStatusEditor *dialog = user_data;
- StatusEditor *status_editor;
- GtkTreeIter iter;
-- GaimAccount *account;
-- GaimStatusType *type;
-+ Gaim2Account *account;
-+ Gaim2StatusType *type;
- char *id = NULL;
- char *message = NULL;
- const char *name = NULL;
-@@ -1283,10 +1283,10 @@ substatus_editor_ok_cb(GtkButton *button
- SUBSTATUS_COLUMN_ACCOUNT, &account,
- SUBSTATUS_COLUMN_STATUS_ID, &id,
- -1);
-- type = gaim_account_get_status_type(account, id);
-- if (gaim_status_type_get_attr(type, "message") != NULL)
-+ type = gaim2_account_get_status_type(account, id);
-+ if (gaim2_status_type_get_attr(type, "message") != NULL)
- message = gtk_imhtml_get_text(GTK_IMHTML(dialog->message), NULL, NULL);
-- name = gaim_status_type_get_name(type);
-+ name = gaim2_status_type_get_name(type);
-
- status_editor = dialog->status_editor;
-
-@@ -1307,7 +1307,7 @@ substatus_editor_ok_cb(GtkButton *button
- }
-
- static void
--edit_substatus(StatusEditor *status_editor, GaimAccount *account)
-+edit_substatus(StatusEditor *status_editor, Gaim2Account *account)
- {
- char *tmp;
- SubStatusEditor *dialog;
-@@ -1336,7 +1336,7 @@ edit_substatus(StatusEditor *status_edit
-
- dialog->window = win = gtk_window_new(GTK_WINDOW_TOPLEVEL);
- gtk_window_set_role(GTK_WINDOW(win), "substatus");
-- tmp = g_strdup_printf(_("Status for %s"), gaim_account_get_username(account));
-+ tmp = g_strdup_printf(_("Status for %s"), gaim2_account_get_username(account));
- gtk_window_set_title(GTK_WINDOW(win), tmp);
- g_free(tmp);
- gtk_window_set_resizable(GTK_WINDOW(win), FALSE);
-@@ -1398,7 +1398,7 @@ edit_substatus(StatusEditor *status_edit
- gtk_widget_show(label);
- gtk_size_group_add_widget(sg, label);
-
-- frame = gaim_gtk_create_imhtml(TRUE, &text, &toolbar);
-+ frame = gaim2_gtk_create_imhtml(TRUE, &text, &toolbar);
- dialog->message = GTK_IMHTML(text);
- dialog->toolbar = GTK_IMHTMLTOOLBAR(toolbar);
- gtk_box_pack_start(GTK_BOX(hbox), frame, TRUE, TRUE, 0);
-@@ -1431,34 +1431,34 @@ edit_substatus(StatusEditor *status_edit
- /* TODO: Get the current values from our parent's list store, not the saved_status! */
- if (status_editor->original_title != NULL)
- {
-- GaimSavedStatus *saved_status = NULL;
-- GaimSavedStatusSub *substatus = NULL;
-+ Gaim2SavedStatus *saved_status = NULL;
-+ Gaim2SavedStatusSub *substatus = NULL;
-
-- saved_status = gaim_savedstatus_find(status_editor->original_title);
-+ saved_status = gaim2_savedstatus_find(status_editor->original_title);
- if (saved_status != NULL)
-- substatus = gaim_savedstatus_get_substatus(saved_status, account);
-+ substatus = gaim2_savedstatus_get_substatus(saved_status, account);
-
- if (substatus != NULL)
- {
- gtk_imhtml_append_text(dialog->message,
-- gaim_savedstatus_substatus_get_message(substatus),
-+ gaim2_savedstatus_substatus_get_message(substatus),
- 0);
-- id = gaim_status_type_get_id(gaim_savedstatus_substatus_get_type(substatus));
-+ id = gaim2_status_type_get_id(gaim2_savedstatus_substatus_get_type(substatus));
- }
- }
-
-- for (list = gaim_account_get_status_types(account); list; list = list->next)
-+ for (list = gaim2_account_get_status_types(account); list; list = list->next)
- {
-- GaimStatusType *status_type;
-+ Gaim2StatusType *status_type;
- GdkPixbuf *pixbuf, *scale = NULL;
- const char *id, *name;
-
- status_type = list->data;
-- id = gaim_status_type_get_id(status_type);
-- pixbuf = gaim_gtk_create_prpl_icon_with_status(account, status_type);
-+ id = gaim2_status_type_get_id(status_type);
-+ pixbuf = gaim2_gtk_create_prpl_icon_with_status(account, status_type);
- if (pixbuf != NULL)
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16, GDK_INTERP_BILINEAR);
-- name = gaim_status_type_get_name(status_type);
-+ name = gaim2_status_type_get_name(status_type);
-
- gtk_list_store_append(dialog->model, &iter);
- gtk_list_store_set(dialog->model, &iter,
-@@ -1467,7 +1467,7 @@ edit_substatus(StatusEditor *status_edit
- SUBSTATUS_COLUMN_STATUS_ID, id,
- SUBSTATUS_COLUMN_STATUS_NAME, name,
- -1);
-- if (id && !strcmp(id, gaim_status_type_get_id(status_type)))
-+ if (id && !strcmp(id, gaim2_status_type_get_id(status_type)))
- {
- gtk_combo_box_set_active_iter(GTK_COMBO_BOX(combo), &iter);
- select = TRUE;
-@@ -1486,7 +1486,7 @@ edit_substatus(StatusEditor *status_edit
- **************************************************************************/
-
- static void
--status_menu_cb(GtkComboBox *widget, void(*callback)(GaimSavedStatus*))
-+status_menu_cb(GtkComboBox *widget, void(*callback)(Gaim2SavedStatus*))
- {
- GtkTreeIter iter;
- gchar *title = NULL;
-@@ -1496,11 +1496,11 @@ status_menu_cb(GtkComboBox *widget, void
-
- gtk_tree_model_get(gtk_combo_box_get_model(widget), &iter,
- STATUS_WINDOW_COLUMN_TITLE, &title, -1);
-- callback(gaim_savedstatus_find(title));
-+ callback(gaim2_savedstatus_find(title));
- g_free(title);
- }
-
--GtkWidget *gaim_gtk_status_menu(GaimSavedStatus *current_status, GCallback callback)
-+GtkWidget *gaim2_gtk_status_menu(Gaim2SavedStatus *current_status, GCallback callback)
- {
- GtkWidget *combobox;
- const GList *saved_statuses;
-@@ -1509,14 +1509,14 @@ GtkWidget *gaim_gtk_status_menu(GaimSave
-
- combobox = gtk_combo_box_new_text();
-
-- for (saved_statuses = gaim_savedstatuses_get_all(), i = 0;
-+ for (saved_statuses = gaim2_savedstatuses_get_all(), i = 0;
- saved_statuses != NULL;
- saved_statuses = g_list_next(saved_statuses))
- {
-- GaimSavedStatus *status = (GaimSavedStatus*)saved_statuses->data;
-- if (!gaim_savedstatus_is_transient(status)) {
-+ Gaim2SavedStatus *status = (Gaim2SavedStatus*)saved_statuses->data;
-+ if (!gaim2_savedstatus_is_transient(status)) {
- gtk_combo_box_append_text(GTK_COMBO_BOX(combobox),
-- gaim_savedstatus_get_title(status));
-+ gaim2_savedstatus_get_title(status));
- if (status == current_status)
- index = i;
- i++;
-@@ -1535,7 +1535,7 @@ GtkWidget *gaim_gtk_status_menu(GaimSave
- **************************************************************************/
-
- void *
--gaim_gtk_status_get_handle()
-+gaim2_gtk_status_get_handle()
- {
- static int handle;
-
-@@ -1543,16 +1543,16 @@ gaim_gtk_status_get_handle()
- }
-
- void
--gaim_gtk_status_init(void)
-+gaim2_gtk_status_init(void)
- {
-- gaim_prefs_add_none("/gaim/gtk/status");
-- gaim_prefs_add_none("/gaim/gtk/status/dialog");
-- gaim_prefs_add_int("/gaim/gtk/status/dialog/width", 550);
-- gaim_prefs_add_int("/gaim/gtk/status/dialog/height", 250);
-+ gaim2_prefs_add_none("/gaim2/gtk/status");
-+ gaim2_prefs_add_none("/gaim2/gtk/status/dialog");
-+ gaim2_prefs_add_int("/gaim2/gtk/status/dialog/width", 550);
-+ gaim2_prefs_add_int("/gaim2/gtk/status/dialog/height", 250);
- }
-
- void
--gaim_gtk_status_uninit(void)
-+gaim2_gtk_status_uninit(void)
- {
-- gaim_gtk_status_window_hide();
-+ gaim2_gtk_status_window_hide();
- }
-diff -prNu ./src/gtksavedstatuses.h ./src/gtksavedstatuses.h
---- ./src/gtksavedstatuses.h 2005-11-28 06:28:00.000000000 +0100
-+++ ./src/gtksavedstatuses.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtksavedstatuses.h GTK+ Saved Status Editor UI
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,12 +31,12 @@
- /**
- * Shows the status window.
- */
--void gaim_gtk_status_window_show(void);
-+void gaim2_gtk_status_window_show(void);
-
- /**
- * Hides the status window.
- */
--void gaim_gtk_status_window_hide(void);
-+void gaim2_gtk_status_window_hide(void);
-
- /**
- * Shows a status editor (used for adding a new saved status or
-@@ -45,24 +45,24 @@ void gaim_gtk_status_window_hide(void);
- * @param status The saved status to edit, or @c NULL if you
- * want to add a new saved status.
- */
--void gaim_gtk_status_editor_show(GaimSavedStatus *status);
-+void gaim2_gtk_status_editor_show(Gaim2SavedStatus *status);
-
- /**
- * Returns the gtkstatus handle.
- *
- * @return The handle to the GTK+ status system.
- */
--void *gaim_gtk_status_get_handle(void);
-+void *gaim2_gtk_status_get_handle(void);
-
- /**
- * Initializes the GTK+ status system.
- */
--void gaim_gtk_status_init(void);
-+void gaim2_gtk_status_init(void);
-
- /**
- * Uninitializes the GTK+ status system.
- */
--void gaim_gtk_status_uninit(void);
-+void gaim2_gtk_status_uninit(void);
-
- /**
- * Creates a dropdown menu of saved statuses and calls a callback
-@@ -72,6 +72,6 @@ void gaim_gtk_status_uninit(void);
- * @param callback The callback to call when the selection changes
- * @return The menu widget
- */
--GtkWidget *gaim_gtk_status_menu(GaimSavedStatus *status, GCallback callback);
-+GtkWidget *gaim2_gtk_status_menu(Gaim2SavedStatus *status, GCallback callback);
-
- #endif /* _GAIM_GTKSAVEDSTATUSES_H_ */
-diff -prNu ./src/gtksession.c ./src/gtksession.c
---- ./src/gtksession.c 2005-12-08 21:59:33.000000000 +0100
-+++ ./src/gtksession.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,7 +2,7 @@
- * @file gtksession.c X Windows session management API
- * @ingroup gtkui
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -52,7 +52,7 @@ struct ice_connection_info {
- };
-
- static void ice_process_messages(gpointer data, gint fd,
-- GaimInputCondition condition) {
-+ Gaim2InputCondition condition) {
- struct ice_connection_info *conninfo = (struct ice_connection_info*) data;
- IceProcessMessagesStatus status;
-
-@@ -60,17 +60,17 @@ static void ice_process_messages(gpointe
- status = IceProcessMessages(conninfo->connection, NULL, NULL);
-
- if (status == IceProcessMessagesIOError) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "ICE IO error, closing connection... ");
-
- /* IO error, please disconnect */
- IceSetShutdownNegotiation(conninfo->connection, False);
- IceCloseConnection(conninfo->connection);
-
-- gaim_debug(GAIM_DEBUG_INFO, NULL, "done.\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, NULL, "done.\n");
-
- /* cancel the handler */
-- gaim_input_remove(conninfo->input_id);
-+ gaim2_input_remove(conninfo->input_id);
- }
- }
-
-@@ -79,7 +79,7 @@ static void ice_connection_watch(IceConn
- struct ice_connection_info *conninfo = NULL;
-
- if (opening) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Handling new ICE connection... ");
-
- /* ensure ICE connection is not passed to child processes */
-@@ -89,20 +89,20 @@ static void ice_connection_watch(IceConn
- conninfo->connection = connection;
-
- /* watch the connection */
-- conninfo->input_id = gaim_input_add(IceConnectionNumber(connection), GAIM_INPUT_READ,
-+ conninfo->input_id = gaim2_input_add(IceConnectionNumber(connection), GAIM_INPUT_READ,
- ice_process_messages, conninfo);
- *watch_data = conninfo;
- } else {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Handling closed ICE connection... ");
-
- /* get the input ID back and stop watching it */
- conninfo = (struct ice_connection_info*) *watch_data;
-- gaim_input_remove(conninfo->input_id);
-+ gaim2_input_remove(conninfo->input_id);
- g_free(conninfo);
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, NULL, "done.\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, NULL, "done.\n");
- }
-
- /* We call any handler installed before (or after) ice_init but
-@@ -113,13 +113,13 @@ static void ice_connection_watch(IceConn
- */
-
- static void ice_io_error_handler(IceConn connection) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Handling ICE IO error... ");
-
- if (ice_installed_io_error_handler)
- (*ice_installed_io_error_handler)(connection);
-
-- gaim_debug(GAIM_DEBUG_INFO, NULL, "done.\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, NULL, "done.\n");
- }
-
- static void ice_init() {
-@@ -133,7 +133,7 @@ static void ice_init() {
-
- IceAddConnectionWatch(ice_connection_watch, NULL);
-
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "ICE initialized.\n");
- }
-
-@@ -145,7 +145,7 @@ static gchar **session_make_command(gcha
- gchar **ret;
-
- if (client_id) i += 2;
-- if (config_dir) i += 2; /* we will specify gaim's user dir */
-+ if (config_dir) i += 2; /* we will specify gaim2's user dir */
-
- ret = g_new(gchar *, i);
- ret[j++] = g_strdup(myself);
-@@ -173,7 +173,7 @@ static void session_save_yourself(SmcCon
- interact_style == SmInteractStyleNone && !shutdown &&
- !fast) {
- /* this is just a dry run, spit it back */
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Received first save_yourself\n");
- SmcSaveYourselfDone(conn, True);
- had_first_save = TRUE;
-@@ -183,7 +183,7 @@ static void session_save_yourself(SmcCon
- /* tum ti tum... don't add anything else here without *
- * reading SMlib.PS from an X.org ftp server near you */
-
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Received save_yourself\n");
-
- if (save_type == SmSaveGlobal || save_type == SmSaveBoth) {
-@@ -195,18 +195,18 @@ static void session_save_yourself(SmcCon
- }
-
- static void session_die(SmcConn conn, SmPointer data) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Received die\n");
-- gaim_core_quit();
-+ gaim2_core_quit();
- }
-
- static void session_save_complete(SmcConn conn, SmPointer data) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Received save_complete\n");
- }
-
- static void session_shutdown_cancelled(SmcConn conn, SmPointer data) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Received shutdown_cancelled\n");
- }
-
-@@ -279,7 +279,7 @@ static void session_set_array(SmcConn co
- /* setup functions */
-
- void
--gaim_gtk_session_init(gchar *argv0, gchar *previous_id, gchar *config_dir)
-+gaim2_gtk_session_init(gchar *argv0, gchar *previous_id, gchar *config_dir)
- {
- #ifdef USE_SM
- SmcCallbacks callbacks;
-@@ -290,13 +290,13 @@ gaim_gtk_session_init(gchar *argv0, gcha
-
- if (session != NULL) {
- /* session is already established, what the hell is going on? */
-- gaim_debug(GAIM_DEBUG_WARNING, "Session Management",
-- "Duplicated call to gaim_gtk_session_init!\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "Session Management",
-+ "Duplicated call to gaim2_gtk_session_init!\n");
- return;
- }
-
- if (g_getenv("SESSION_MANAGER") == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Session Management",
- "No SESSION_MANAGER found, aborting.\n");
- return;
- }
-@@ -314,10 +314,10 @@ gaim_gtk_session_init(gchar *argv0, gcha
- callbacks.shutdown_cancelled.client_data = NULL;
-
- if (previous_id) {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Connecting with previous ID %s\n", previous_id);
- } else {
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Connecting with no previous ID\n");
- }
-
-@@ -327,17 +327,17 @@ gaim_gtk_session_init(gchar *argv0, gcha
-
- if (session == NULL) {
- if (error[0] != '\0') {
-- gaim_debug(GAIM_DEBUG_ERROR, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Session Management",
- "Connection failed with error: %s\n", error);
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "Session Management",
- "Connetion failed with unknown error.\n");
- }
- return;
- }
-
- tmp = SmcVendor(session);
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Connected to manager (%s) with client ID %s\n",
- tmp, client_id);
- g_free(tmp);
-@@ -361,7 +361,7 @@ gaim_gtk_session_init(gchar *argv0, gcha
- session_set_string(session, SmProgram, g_get_prgname());
-
- myself = g_strdup(argv0);
-- gaim_debug(GAIM_DEBUG_MISC, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_MISC, "Session Management",
- "Using %s as command\n", myself);
-
- cmd = session_make_command(NULL, config_dir);
-@@ -386,7 +386,7 @@ gaim_gtk_session_init(gchar *argv0, gcha
- }
-
- void
--gaim_gtk_session_end()
-+gaim2_gtk_session_end()
- {
- #ifdef USE_SM
- if (session == NULL) /* no session to close */
-@@ -394,7 +394,7 @@ gaim_gtk_session_end()
-
- SmcCloseConnection(session, 0, NULL);
-
-- gaim_debug(GAIM_DEBUG_INFO, "Session Management",
-+ gaim2_debug(GAIM_DEBUG_INFO, "Session Management",
- "Connection closed.\n");
- #endif /* USE_SM */
- }
-diff -prNu ./src/gtksession.h ./src/gtksession.h
---- ./src/gtksession.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtksession.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtksession.h X Windows session management API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,22 +31,22 @@
- /*@{*/
-
- /**
-- * Register this instance of Gaim with the user's current session
-+ * Register this instance of Gaim2 with the user's current session
- * manager.
- *
- * @param argv0 The first argument passed into the program. This
-- * will be the name of the executable, e.g. 'gaim'
-+ * will be the name of the executable, e.g. 'gaim2'
- * @param previous_id An optional session ID to use. This can be NULL.
- * @param config_dir The path to the configuration directory used by
-- * this instance of this program, e.g. '/home/user/.gaim'
-+ * this instance of this program, e.g. '/home/user/.gaim2'
- */
--void gaim_gtk_session_init(gchar *argv0, gchar *previous_id, gchar *config_dir);
-+void gaim2_gtk_session_init(gchar *argv0, gchar *previous_id, gchar *config_dir);
-
- /**
-- * Unregister this instance of Gaim with the user's current session
-+ * Unregister this instance of Gaim2 with the user's current session
- * manager.
- */
--void gaim_gtk_session_end(void);
-+void gaim2_gtk_session_end(void);
-
- /*@}*/
-
-diff -prNu ./src/gtksound.c ./src/gtksound.c
---- ./src/gtksound.c 2005-12-08 21:59:49.000000000 +0100
-+++ ./src/gtksound.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtksound.h GTK+ Sound
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #ifdef _WIN32
- #include <windows.h>
-@@ -45,7 +45,7 @@
- #include "gtkconv.h"
- #include "gtksound.h"
-
--struct gaim_sound_event {
-+struct gaim2_sound_event {
- char *label;
- char *pref;
- char *def;
-@@ -57,7 +57,7 @@ static guint mute_login_sounds_timeout =
- static gboolean mute_login_sounds = FALSE;
- static gboolean sound_initialized = FALSE;
-
--static struct gaim_sound_event sounds[GAIM_NUM_SOUNDS] = {
-+static struct gaim2_sound_event sounds[GAIM_NUM_SOUNDS] = {
- {N_("Buddy logs in"), "login", "login.wav"},
- {N_("Buddy logs out"), "logout", "logout.wav"},
- {N_("Message received"), "im_recv", "receive.wav"},
-@@ -85,19 +85,19 @@ unmute_login_sounds_cb(gpointer data)
- }
-
- static gboolean
--chat_nick_matches_name(GaimConversation *conv, const char *aname)
-+chat_nick_matches_name(Gaim2Conversation *conv, const char *aname)
- {
-- GaimConvChat *chat = NULL;
-+ Gaim2ConvChat *chat = NULL;
- char *nick = NULL;
- char *name = NULL;
- gboolean ret = FALSE;
-- chat = gaim_conversation_get_chat_data(conv);
-+ chat = gaim2_conversation_get_chat_data(conv);
-
- if (chat==NULL)
- return ret;
-
-- nick = g_strdup(gaim_normalize(conv->account, chat->nick));
-- name = g_strdup(gaim_normalize(conv->account, aname));
-+ nick = g_strdup(gaim2_normalize(conv->account, chat->nick));
-+ name = g_strdup(gaim2_normalize(conv->account, aname));
-
- if (g_utf8_collate(nick, name) == 0)
- ret = TRUE;
-@@ -113,101 +113,101 @@ chat_nick_matches_name(GaimConversation
- * of conversation and checking for focus if conv_focus pref is set
- */
- static void
--play_conv_event(GaimConversation *conv, GaimSoundEventID event)
-+play_conv_event(Gaim2Conversation *conv, Gaim2SoundEventID event)
- {
- /* If we should not play the sound for some reason, then exit early */
- if (conv != NULL)
- {
-- GaimGtkConversation *gtkconv;
-- GaimGtkWindow *win;
-+ Gaim2GtkConversation *gtkconv;
-+ Gaim2GtkWindow *win;
- gboolean has_focus;
-
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- win = gtkconv->win;
-
-- has_focus = gaim_conversation_has_focus(conv);
-+ has_focus = gaim2_conversation_has_focus(conv);
-
- if (!gtkconv->make_sound ||
-- (has_focus && !gaim_prefs_get_bool("/gaim/gtk/sound/conv_focus")))
-+ (has_focus && !gaim2_prefs_get_bool("/gaim2/gtk/sound/conv_focus")))
- {
- return;
- }
- }
-
-- gaim_sound_play_event(event, conv ? gaim_conversation_get_account(conv) : NULL);
-+ gaim2_sound_play_event(event, conv ? gaim2_conversation_get_account(conv) : NULL);
- }
-
- static void
--buddy_state_cb(GaimBuddy *buddy, GaimSoundEventID event)
-+buddy_state_cb(Gaim2Buddy *buddy, Gaim2SoundEventID event)
- {
-- gaim_sound_play_event(event, gaim_buddy_get_account(buddy));
-+ gaim2_sound_play_event(event, gaim2_buddy_get_account(buddy));
- }
-
- static void
--im_msg_received_cb(GaimAccount *account, char *sender,
-- char *message, GaimConversation *conv,
-- int flags, GaimSoundEventID event)
-+im_msg_received_cb(Gaim2Account *account, char *sender,
-+ char *message, Gaim2Conversation *conv,
-+ int flags, Gaim2SoundEventID event)
- {
- if (conv==NULL)
-- gaim_sound_play_event(GAIM_SOUND_FIRST_RECEIVE, account);
-+ gaim2_sound_play_event(GAIM_SOUND_FIRST_RECEIVE, account);
- else
- play_conv_event(conv, event);
- }
-
- static void
--im_msg_sent_cb(GaimAccount *account, const char *receiver,
-- const char *message, GaimSoundEventID event)
-+im_msg_sent_cb(Gaim2Account *account, const char *receiver,
-+ const char *message, Gaim2SoundEventID event)
- {
-- GaimConversation *conv = gaim_find_conversation_with_account(
-+ Gaim2Conversation *conv = gaim2_find_conversation_with_account(
- GAIM_CONV_TYPE_ANY, receiver, account);
- play_conv_event(conv, event);
- }
-
- static void
--chat_buddy_join_cb(GaimConversation *conv, const char *name,
-- GaimConvChatBuddyFlags flags, GaimSoundEventID event)
-+chat_buddy_join_cb(Gaim2Conversation *conv, const char *name,
-+ Gaim2ConvChatBuddyFlags flags, Gaim2SoundEventID event)
- {
- if (!chat_nick_matches_name(conv, name))
- play_conv_event(conv, event);
- }
-
- static void
--chat_buddy_left_cb(GaimConversation *conv, const char *name,
-- const char *reason, GaimSoundEventID event)
-+chat_buddy_left_cb(Gaim2Conversation *conv, const char *name,
-+ const char *reason, Gaim2SoundEventID event)
- {
- if (!chat_nick_matches_name(conv, name))
- play_conv_event(conv, event);
- }
-
- static void
--chat_msg_sent_cb(GaimAccount *account, const char *message,
-- int id, GaimSoundEventID event)
-+chat_msg_sent_cb(Gaim2Account *account, const char *message,
-+ int id, Gaim2SoundEventID event)
- {
-- GaimConnection *conn = gaim_account_get_connection(account);
-- GaimConversation *conv = NULL;
-+ Gaim2Connection *conn = gaim2_account_get_connection(account);
-+ Gaim2Conversation *conv = NULL;
-
- if (conn!=NULL)
-- conv = gaim_find_chat(conn,id);
-+ conv = gaim2_find_chat(conn,id);
-
- play_conv_event(conv, event);
- }
-
- static void
--chat_msg_received_cb(GaimAccount *account, char *sender,
-- char *message, GaimConversation *conv,
-- GaimMessageFlags flags, GaimSoundEventID event)
-+chat_msg_received_cb(Gaim2Account *account, char *sender,
-+ char *message, Gaim2Conversation *conv,
-+ Gaim2MessageFlags flags, Gaim2SoundEventID event)
- {
-- GaimConvChat *chat;
-+ Gaim2ConvChat *chat;
-
-- chat = gaim_conversation_get_chat_data(conv);
-+ chat = gaim2_conversation_get_chat_data(conv);
-
-- if (chat!=NULL && gaim_conv_chat_is_user_ignored(chat, sender))
-+ if (chat!=NULL && gaim2_conv_chat_is_user_ignored(chat, sender))
- return;
-
- if (chat_nick_matches_name(conv, sender))
- return;
-
-- if (flags & GAIM_MESSAGE_NICK || gaim_utf8_has_word(message, chat->nick))
-+ if (flags & GAIM_MESSAGE_NICK || gaim2_utf8_has_word(message, chat->nick))
- play_conv_event(conv, GAIM_SOUND_CHAT_NICK);
- else
- play_conv_event(conv, event);
-@@ -219,18 +219,18 @@ chat_msg_received_cb(GaimAccount *accoun
- * your buddies logging in.
- */
- static void
--account_signon_cb(GaimConnection *gc, gpointer data)
-+account_signon_cb(Gaim2Connection *gc, gpointer data)
- {
- if (mute_login_sounds_timeout != 0)
- g_source_remove(mute_login_sounds_timeout);
- mute_login_sounds = TRUE;
-- mute_login_sounds_timeout = gaim_timeout_add(10000, unmute_login_sounds_cb, NULL);
-+ mute_login_sounds_timeout = gaim2_timeout_add(10000, unmute_login_sounds_cb, NULL);
- }
-
- static void
--_pref_sound_method_changed(const char *name, GaimPrefType type,
-+_pref_sound_method_changed(const char *name, Gaim2PrefType type,
- gpointer val, gpointer data) {
-- if(type != GAIM_PREF_STRING || strcmp(name, "/gaim/gtk/sound/method"))
-+ if(type != GAIM_PREF_STRING || strcmp(name, "/gaim2/gtk/sound/method"))
- return;
-
- sound_initialized = TRUE;
-@@ -249,14 +249,14 @@ _pref_sound_method_changed(const char *n
-
- if(ao_driver != -1) {
- ao_info *info = ao_driver_info(ao_driver);
-- gaim_debug_info("sound",
-+ gaim2_debug_info("sound",
- "Sound output driver loaded: %s\n", info->name);
- }
- #endif /* USE_AO */
- }
-
- const char *
--gaim_gtk_sound_get_event_option(GaimSoundEventID event)
-+gaim2_gtk_sound_get_event_option(Gaim2SoundEventID event)
- {
- if(event >= GAIM_NUM_SOUNDS)
- return 0;
-@@ -265,7 +265,7 @@ gaim_gtk_sound_get_event_option(GaimSoun
- }
-
- char *
--gaim_gtk_sound_get_event_label(GaimSoundEventID event)
-+gaim2_gtk_sound_get_event_label(Gaim2SoundEventID event)
- {
- if(event >= GAIM_NUM_SOUNDS)
- return NULL;
-@@ -274,7 +274,7 @@ gaim_gtk_sound_get_event_label(GaimSound
- }
-
- void *
--gaim_gtk_sound_get_handle()
-+gaim2_gtk_sound_get_handle()
- {
- static int handle;
-
-@@ -282,89 +282,89 @@ gaim_gtk_sound_get_handle()
- }
-
- static void
--gaim_gtk_sound_init(void)
-+gaim2_gtk_sound_init(void)
- {
-- void *gtk_sound_handle = gaim_gtk_sound_get_handle();
-- void *blist_handle = gaim_blist_get_handle();
-- void *conv_handle = gaim_conversations_get_handle();
-+ void *gtk_sound_handle = gaim2_gtk_sound_get_handle();
-+ void *blist_handle = gaim2_blist_get_handle();
-+ void *conv_handle = gaim2_conversations_get_handle();
-
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- gtk_sound_handle, GAIM_CALLBACK(account_signon_cb),
- NULL);
-
-- gaim_prefs_add_none("/gaim/gtk/sound");
-- gaim_prefs_add_none("/gaim/gtk/sound/enabled");
-- gaim_prefs_add_none("/gaim/gtk/sound/file");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/login", TRUE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/login", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/logout", TRUE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/logout", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/im_recv", TRUE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/im_recv", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/first_im_recv", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/first_im_recv", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/send_im", TRUE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/send_im", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/join_chat", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/join_chat", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/left_chat", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/left_chat", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/send_chat_msg", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/send_chat_msg", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/chat_msg_recv", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/chat_msg_recv", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/nick_said", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/nick_said", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/enabled/pounce_default", TRUE);
-- gaim_prefs_add_string("/gaim/gtk/sound/file/pounce_default", "");
-- gaim_prefs_add_bool("/gaim/gtk/sound/conv_focus", TRUE);
-- gaim_prefs_add_bool("/gaim/gtk/sound/mute", FALSE);
-- gaim_prefs_add_string("/gaim/gtk/sound/command", "");
-- gaim_prefs_add_string("/gaim/gtk/sound/method", "automatic");
-+ gaim2_prefs_add_none("/gaim2/gtk/sound");
-+ gaim2_prefs_add_none("/gaim2/gtk/sound/enabled");
-+ gaim2_prefs_add_none("/gaim2/gtk/sound/file");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/login", TRUE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/login", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/logout", TRUE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/logout", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/im_recv", TRUE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/im_recv", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/first_im_recv", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/first_im_recv", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/send_im", TRUE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/send_im", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/join_chat", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/join_chat", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/left_chat", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/left_chat", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/send_chat_msg", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/send_chat_msg", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/chat_msg_recv", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/chat_msg_recv", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/nick_said", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/nick_said", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/enabled/pounce_default", TRUE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/file/pounce_default", "");
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/conv_focus", TRUE);
-+ gaim2_prefs_add_bool("/gaim2/gtk/sound/mute", FALSE);
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/command", "");
-+ gaim2_prefs_add_string("/gaim2/gtk/sound/method", "automatic");
-
- #ifdef USE_AO
-- gaim_debug_info("sound", "Initializing sound output drivers.\n");
-+ gaim2_debug_info("sound", "Initializing sound output drivers.\n");
- ao_initialize();
- #endif /* USE_AO */
-
-- gaim_prefs_connect_callback(gaim_gtk_sound_get_handle(), "/gaim/gtk/sound/method",
-+ gaim2_prefs_connect_callback(gaim2_gtk_sound_get_handle(), "/gaim2/gtk/sound/method",
- _pref_sound_method_changed, NULL);
-
-- gaim_signal_connect(blist_handle, "buddy-signed-on",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-on",
- gtk_sound_handle, GAIM_CALLBACK(buddy_state_cb),
- GINT_TO_POINTER(GAIM_SOUND_BUDDY_ARRIVE));
-- gaim_signal_connect(blist_handle, "buddy-signed-off",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-off",
- gtk_sound_handle, GAIM_CALLBACK(buddy_state_cb),
- GINT_TO_POINTER(GAIM_SOUND_BUDDY_LEAVE));
-- gaim_signal_connect(conv_handle, "received-im-msg",
-+ gaim2_signal_connect(conv_handle, "received-im-msg",
- gtk_sound_handle, GAIM_CALLBACK(im_msg_received_cb),
- GINT_TO_POINTER(GAIM_SOUND_RECEIVE));
-- gaim_signal_connect(conv_handle, "sent-im-msg",
-+ gaim2_signal_connect(conv_handle, "sent-im-msg",
- gtk_sound_handle, GAIM_CALLBACK(im_msg_sent_cb),
- GINT_TO_POINTER(GAIM_SOUND_SEND));
-- gaim_signal_connect(conv_handle, "chat-buddy-joined",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-joined",
- gtk_sound_handle, GAIM_CALLBACK(chat_buddy_join_cb),
- GINT_TO_POINTER(GAIM_SOUND_CHAT_JOIN));
-- gaim_signal_connect(conv_handle, "chat-buddy-left",
-+ gaim2_signal_connect(conv_handle, "chat-buddy-left",
- gtk_sound_handle, GAIM_CALLBACK(chat_buddy_left_cb),
- GINT_TO_POINTER(GAIM_SOUND_CHAT_LEAVE));
-- gaim_signal_connect(conv_handle, "sent-chat-msg",
-+ gaim2_signal_connect(conv_handle, "sent-chat-msg",
- gtk_sound_handle, GAIM_CALLBACK(chat_msg_sent_cb),
- GINT_TO_POINTER(GAIM_SOUND_CHAT_YOU_SAY));
-- gaim_signal_connect(conv_handle, "received-chat-msg",
-+ gaim2_signal_connect(conv_handle, "received-chat-msg",
- gtk_sound_handle, GAIM_CALLBACK(chat_msg_received_cb),
- GINT_TO_POINTER(GAIM_SOUND_CHAT_SAY));
- }
-
- static void
--gaim_gtk_sound_uninit(void)
-+gaim2_gtk_sound_uninit(void)
- {
- #ifdef USE_AO
- ao_shutdown();
- #endif
- sound_initialized = FALSE;
-
-- gaim_signals_disconnect_by_handle(gaim_gtk_sound_get_handle());
-+ gaim2_signals_disconnect_by_handle(gaim2_gtk_sound_get_handle());
- }
-
- #ifdef USE_AO
-@@ -378,7 +378,7 @@ expire_old_child(gpointer data)
-
- if(ret == 0) {
- if(kill(pid, SIGKILL) < 0)
-- gaim_debug_error("gtksound", "Killing process %d failed (%s)\n",
-+ gaim2_debug_error("gtksound", "Killing process %d failed (%s)\n",
- pid, strerror(errno));
- }
-
-@@ -387,7 +387,7 @@ expire_old_child(gpointer data)
- #endif
-
- static void
--gaim_gtk_sound_play_file(const char *filename)
-+gaim2_gtk_sound_play_file(const char *filename)
- {
- const char *method;
- #ifdef USE_AO
-@@ -396,12 +396,12 @@ gaim_gtk_sound_play_file(const char *fil
- #endif
-
- if (!sound_initialized)
-- gaim_prefs_trigger_callback("/gaim/gtk/sound/method");
-+ gaim2_prefs_trigger_callback("/gaim2/gtk/sound/method");
-
-- if (gaim_prefs_get_bool("/gaim/gtk/sound/mute"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/sound/mute"))
- return;
-
-- method = gaim_prefs_get_string("/gaim/gtk/sound/method");
-+ method = gaim2_prefs_get_string("/gaim2/gtk/sound/method");
-
- if (!strcmp(method, "none")) {
- return;
-@@ -412,7 +412,7 @@ gaim_gtk_sound_play_file(const char *fil
-
- if (!g_file_test(filename, G_FILE_TEST_EXISTS)) {
- char *tmp = g_strdup_printf(_("Unable to play sound because the chosen file (%s) does not exist."), filename);
-- gaim_notify_error(NULL, NULL, tmp, NULL);
-+ gaim2_notify_error(NULL, NULL, tmp, NULL);
- g_free(tmp);
- return;
- }
-@@ -423,10 +423,10 @@ gaim_gtk_sound_play_file(const char *fil
- char *command;
- GError *error = NULL;
-
-- sound_cmd = gaim_prefs_get_string("/gaim/gtk/sound/command");
-+ sound_cmd = gaim2_prefs_get_string("/gaim2/gtk/sound/command");
-
- if (!sound_cmd || *sound_cmd == '\0') {
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("Unable to play sound because the "
- "'Command' sound method has been chosen, "
- "but no command has been set."), NULL);
-@@ -434,13 +434,13 @@ gaim_gtk_sound_play_file(const char *fil
- }
-
- if(strstr(sound_cmd, "%s"))
-- command = gaim_strreplace(sound_cmd, "%s", filename);
-+ command = gaim2_strreplace(sound_cmd, "%s", filename);
- else
- command = g_strdup_printf("%s %s", sound_cmd, filename);
-
- if(!g_spawn_command_line_async(command, &error)) {
- char *tmp = g_strdup_printf(_("Unable to play sound because the configured sound command could not be launched: %s"), error->message);
-- gaim_notify_error(NULL, NULL, tmp, NULL);
-+ gaim2_notify_error(NULL, NULL, tmp, NULL);
- g_free(tmp);
- g_error_free(error);
- }
-@@ -508,33 +508,33 @@ gaim_gtk_sound_play_file(const char *fil
- _exit(0);
- } else {
- /* Parent process */
-- gaim_timeout_add(PLAY_SOUND_TIMEOUT, expire_old_child, GINT_TO_POINTER(pid));
-+ gaim2_timeout_add(PLAY_SOUND_TIMEOUT, expire_old_child, GINT_TO_POINTER(pid));
- }
- #else /* USE_AO */
- gdk_beep();
- return;
- #endif /* USE_AO */
- #else /* _WIN32 */
-- gaim_debug_info("sound", "Playing %s\n", filename);
-+ gaim2_debug_info("sound", "Playing %s\n", filename);
-
- if (G_WIN32_HAVE_WIDECHAR_API ()) {
- wchar_t *wc_filename = g_utf8_to_utf16(filename,
- -1, NULL, NULL, NULL);
- if (!PlaySoundW(wc_filename, NULL, SND_ASYNC | SND_FILENAME))
-- gaim_debug(GAIM_DEBUG_ERROR, "sound", "Error playing sound.\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "sound", "Error playing sound.\n");
- g_free(wc_filename);
- } else {
- char *l_filename = g_locale_from_utf8(filename,
- -1, NULL, NULL, NULL);
- if (!PlaySoundA(l_filename, NULL, SND_ASYNC | SND_FILENAME))
-- gaim_debug(GAIM_DEBUG_ERROR, "sound", "Error playing sound.\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "sound", "Error playing sound.\n");
- g_free(l_filename);
- }
- #endif /* _WIN32 */
- }
-
- static void
--gaim_gtk_sound_play_event(GaimSoundEventID event)
-+gaim2_gtk_sound_play_event(Gaim2SoundEventID event)
- {
- char *enable_pref;
- char *file_pref;
-@@ -543,23 +543,23 @@ gaim_gtk_sound_play_event(GaimSoundEvent
- return;
-
- if (event >= GAIM_NUM_SOUNDS) {
-- gaim_debug_error("sound", "got request for unknown sound: %d\n", event);
-+ gaim2_debug_error("sound", "got request for unknown sound: %d\n", event);
- return;
- }
-
-- enable_pref = g_strdup_printf("/gaim/gtk/sound/enabled/%s",
-+ enable_pref = g_strdup_printf("/gaim2/gtk/sound/enabled/%s",
- sounds[event].pref);
-- file_pref = g_strdup_printf("/gaim/gtk/sound/file/%s", sounds[event].pref);
-+ file_pref = g_strdup_printf("/gaim2/gtk/sound/file/%s", sounds[event].pref);
-
- /* check NULL for sounds that don't have an option, ie buddy pounce */
-- if (gaim_prefs_get_bool(enable_pref)) {
-- char *filename = g_strdup(gaim_prefs_get_string(file_pref));
-+ if (gaim2_prefs_get_bool(enable_pref)) {
-+ char *filename = g_strdup(gaim2_prefs_get_string(file_pref));
- if(!filename || !strlen(filename)) {
- if(filename) g_free(filename);
-- filename = g_build_filename(DATADIR, "sounds", "gaim", sounds[event].def, NULL);
-+ filename = g_build_filename(DATADIR, "sounds", "gaim2", sounds[event].def, NULL);
- }
-
-- gaim_sound_play_file(filename, NULL);
-+ gaim2_sound_play_file(filename, NULL);
- g_free(filename);
- }
-
-@@ -567,16 +567,16 @@ gaim_gtk_sound_play_event(GaimSoundEvent
- g_free(file_pref);
- }
-
--static GaimSoundUiOps sound_ui_ops =
-+static Gaim2SoundUiOps sound_ui_ops =
- {
-- gaim_gtk_sound_init,
-- gaim_gtk_sound_uninit,
-- gaim_gtk_sound_play_file,
-- gaim_gtk_sound_play_event
-+ gaim2_gtk_sound_init,
-+ gaim2_gtk_sound_uninit,
-+ gaim2_gtk_sound_play_file,
-+ gaim2_gtk_sound_play_event
- };
-
--GaimSoundUiOps *
--gaim_gtk_sound_get_ui_ops(void)
-+Gaim2SoundUiOps *
-+gaim2_gtk_sound_get_ui_ops(void)
- {
- return &sound_ui_ops;
- }
-diff -prNu ./src/gtksound.h ./src/gtksound.h
---- ./src/gtksound.h 2005-12-21 08:27:04.000000000 +0100
-+++ ./src/gtksound.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtksound.h GTK+ Sound API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -38,7 +38,7 @@
- * @param event The event.
- * @return The option.
- */
--const char *gaim_gtk_sound_get_event_option(GaimSoundEventID event);
-+const char *gaim2_gtk_sound_get_event_option(Gaim2SoundEventID event);
-
- /**
- * Get the label for an event.
-@@ -46,21 +46,21 @@ const char *gaim_gtk_sound_get_event_opt
- * @param event The event.
- * @return The label.
- */
--char *gaim_gtk_sound_get_event_label(GaimSoundEventID event);
-+char *gaim2_gtk_sound_get_event_label(Gaim2SoundEventID event);
-
- /**
- * Gets GTK+ sound UI ops.
- *
- * @return The UI operations structure.
- */
--GaimSoundUiOps *gaim_gtk_sound_get_ui_ops(void);
-+Gaim2SoundUiOps *gaim2_gtk_sound_get_ui_ops(void);
-
- /**
- * Get the handle for the GTK+ sound system.
- *
- * @return The handle to the sound system
- */
--void *gaim_gtk_sound_get_handle(void);
-+void *gaim2_gtk_sound_get_handle(void);
-
- /*@}*/
-
-diff -prNu ./src/gtksourceiter.c ./src/gtksourceiter.c
---- ./src/gtksourceiter.c 2005-12-12 09:08:07.000000000 +0100
-+++ ./src/gtksourceiter.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
- * gtksourceiter.c
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/gtksourceiter.h ./src/gtksourceiter.h
---- ./src/gtksourceiter.h 2005-12-12 09:08:07.000000000 +0100
-+++ ./src/gtksourceiter.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*-
- * gtksourceiter.h
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/gtkstatusbox.c ./src/gtkstatusbox.c
---- ./src/gtkstatusbox.c 2006-01-05 06:16:36.000000000 +0100
-+++ ./src/gtkstatusbox.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkstatusbox.c GTK+ Status Selection Widget
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,7 +31,7 @@
- #include "status.h"
- #include "debug.h"
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "gtksavedstatuses.h"
- #include "gtkstock.h"
- #include "gtkstatusbox.h"
-@@ -48,24 +48,24 @@
-
- static void imhtml_changed_cb(GtkTextBuffer *buffer, void *data);
- static void imhtml_format_changed_cb(GtkIMHtml *imhtml, GtkIMHtmlButtons buttons, void *data);
--static void remove_typing_cb(GtkGaimStatusBox *box);
--static void update_size (GtkGaimStatusBox *box);
-+static void remove_typing_cb(GtkGaim2StatusBox *box);
-+static void update_size (GtkGaim2StatusBox *box);
-
--static void gtk_gaim_status_box_pulse_typing(GtkGaimStatusBox *status_box);
--static void gtk_gaim_status_box_refresh(GtkGaimStatusBox *status_box);
--static void gtk_gaim_status_box_regenerate(GtkGaimStatusBox *status_box);
--static void gtk_gaim_status_box_changed(GtkComboBox *box);
--static void gtk_gaim_status_box_size_request (GtkWidget *widget, GtkRequisition *requisition);
--static void gtk_gaim_status_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation);
--static gboolean gtk_gaim_status_box_expose_event (GtkWidget *widget, GdkEventExpose *event);
--static void gtk_gaim_status_box_forall (GtkContainer *container, gboolean include_internals, GtkCallback callback, gpointer callback_data);
-+static void gtk_gaim2_status_box_pulse_typing(GtkGaim2StatusBox *status_box);
-+static void gtk_gaim2_status_box_refresh(GtkGaim2StatusBox *status_box);
-+static void gtk_gaim2_status_box_regenerate(GtkGaim2StatusBox *status_box);
-+static void gtk_gaim2_status_box_changed(GtkComboBox *box);
-+static void gtk_gaim2_status_box_size_request (GtkWidget *widget, GtkRequisition *requisition);
-+static void gtk_gaim2_status_box_size_allocate (GtkWidget *widget, GtkAllocation *allocation);
-+static gboolean gtk_gaim2_status_box_expose_event (GtkWidget *widget, GdkEventExpose *event);
-+static void gtk_gaim2_status_box_forall (GtkContainer *container, gboolean include_internals, GtkCallback callback, gpointer callback_data);
-
- static void (*combo_box_size_request)(GtkWidget *widget, GtkRequisition *requisition);
- static void (*combo_box_size_allocate)(GtkWidget *widget, GtkAllocation *allocation);
- static void (*combo_box_forall) (GtkContainer *container, gboolean include_internals, GtkCallback callback, gpointer callback_data);
-
- enum {
-- TYPE_COLUMN, /* A GtkGaimStatusBoxItemType */
-+ TYPE_COLUMN, /* A GtkGaim2StatusBoxItemType */
- ICON_COLUMN, /* This is a GdkPixbuf (the other columns are strings) */
- TEXT_COLUMN, /* A string */
- TITLE_COLUMN, /* The plain-English title of this item */
-@@ -80,11 +80,11 @@ enum {
-
- GtkComboBoxClass *parent_class = NULL;
-
--static void gtk_gaim_status_box_class_init (GtkGaimStatusBoxClass *klass);
--static void gtk_gaim_status_box_init (GtkGaimStatusBox *status_box);
-+static void gtk_gaim2_status_box_class_init (GtkGaim2StatusBoxClass *klass);
-+static void gtk_gaim2_status_box_init (GtkGaim2StatusBox *status_box);
-
- GType
--gtk_gaim_status_box_get_type (void)
-+gtk_gaim2_status_box_get_type (void)
- {
- static GType status_box_type = 0;
-
-@@ -92,20 +92,20 @@ gtk_gaim_status_box_get_type (void)
- {
- static const GTypeInfo status_box_info =
- {
-- sizeof (GtkGaimStatusBoxClass),
-+ sizeof (GtkGaim2StatusBoxClass),
- NULL, /* base_init */
- NULL, /* base_finalize */
-- (GClassInitFunc) gtk_gaim_status_box_class_init,
-+ (GClassInitFunc) gtk_gaim2_status_box_class_init,
- NULL, /* class_finalize */
- NULL, /* class_data */
-- sizeof (GtkGaimStatusBox),
-+ sizeof (GtkGaim2StatusBox),
- 0,
-- (GInstanceInitFunc) gtk_gaim_status_box_init,
-+ (GInstanceInitFunc) gtk_gaim2_status_box_init,
- NULL /* value_table */
- };
-
- status_box_type = g_type_register_static(GTK_TYPE_COMBO_BOX,
-- "GtkGaimStatusBox",
-+ "GtkGaim2StatusBox",
- &status_box_info,
- 0);
- }
-@@ -114,10 +114,10 @@ gtk_gaim_status_box_get_type (void)
- }
-
- static void
--gtk_gaim_status_box_get_property(GObject *object, guint param_id,
-+gtk_gaim2_status_box_get_property(GObject *object, guint param_id,
- GValue *value, GParamSpec *psec)
- {
-- GtkGaimStatusBox *statusbox = GTK_GAIM_STATUS_BOX(object);
-+ GtkGaim2StatusBox *statusbox = GTK_GAIM_STATUS_BOX(object);
-
- switch (param_id) {
- case PROP_ACCOUNT:
-@@ -130,20 +130,20 @@ gtk_gaim_status_box_get_property(GObject
- }
-
- static void
--update_to_reflect_account_status(GtkGaimStatusBox *status_box, GaimAccount *account, GaimStatus *newstatus)
-+update_to_reflect_account_status(GtkGaim2StatusBox *status_box, Gaim2Account *account, Gaim2Status *newstatus)
- {
- const GList *l;
- int status_no = -1;
-- const GaimStatusType *statustype = NULL;
-+ const Gaim2StatusType *statustype = NULL;
- const char *message;
-
-- statustype = gaim_status_type_find_with_id((GList *)gaim_account_get_status_types(account),
-- (char *)gaim_status_type_get_id(gaim_status_get_type(newstatus)));
-+ statustype = gaim2_status_type_find_with_id((GList *)gaim2_account_get_status_types(account),
-+ (char *)gaim2_status_type_get_id(gaim2_status_get_type(newstatus)));
-
-- for (l = gaim_account_get_status_types(account); l != NULL; l = l->next) {
-- GaimStatusType *status_type = (GaimStatusType *)l->data;
-+ for (l = gaim2_account_get_status_types(account); l != NULL; l = l->next) {
-+ Gaim2StatusType *status_type = (Gaim2StatusType *)l->data;
-
-- if (!gaim_status_type_is_user_settable(status_type))
-+ if (!gaim2_status_type_is_user_settable(status_type))
- continue;
- status_no++;
- if (statustype == status_type)
-@@ -154,7 +154,7 @@ update_to_reflect_account_status(GtkGaim
- gtk_widget_set_sensitive(GTK_WIDGET(status_box), FALSE);
- gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), status_no);
-
-- message = gaim_status_get_attr_string(newstatus, "message");
-+ message = gaim2_status_get_attr_string(newstatus, "message");
-
- if (!message || !*message)
- {
-@@ -170,38 +170,38 @@ update_to_reflect_account_status(GtkGaim
- gtk_imhtml_append_text(GTK_IMHTML(status_box->imhtml), message, 0);
- }
- gtk_widget_set_sensitive(GTK_WIDGET(status_box), TRUE);
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
- }
-
- static void
--account_status_changed_cb(GaimAccount *account, GaimStatus *oldstatus, GaimStatus *newstatus, GtkGaimStatusBox *status_box)
-+account_status_changed_cb(Gaim2Account *account, Gaim2Status *oldstatus, Gaim2Status *newstatus, GtkGaim2StatusBox *status_box)
- {
- if (status_box->account == account)
- update_to_reflect_account_status(status_box, account, newstatus);
- }
-
- static void
--gtk_gaim_status_box_set_property(GObject *object, guint param_id,
-+gtk_gaim2_status_box_set_property(GObject *object, guint param_id,
- const GValue *value, GParamSpec *pspec)
- {
-- GtkGaimStatusBox *statusbox = GTK_GAIM_STATUS_BOX(object);
-+ GtkGaim2StatusBox *statusbox = GTK_GAIM_STATUS_BOX(object);
-
- switch (param_id) {
- case PROP_ACCOUNT:
- statusbox->account = g_value_get_pointer(value);
-
- if (statusbox->status_changed_signal) {
-- gaim_signal_disconnect(gaim_accounts_get_handle(), "account-status-changed",
-+ gaim2_signal_disconnect(gaim2_accounts_get_handle(), "account-status-changed",
- statusbox, GAIM_CALLBACK(account_status_changed_cb));
- statusbox->status_changed_signal = 0;
- }
-
- if (statusbox->account)
-- statusbox->status_changed_signal = gaim_signal_connect(gaim_accounts_get_handle(), "account-status-changed",
-+ statusbox->status_changed_signal = gaim2_signal_connect(gaim2_accounts_get_handle(), "account-status-changed",
- statusbox, GAIM_CALLBACK(account_status_changed_cb),
- statusbox);
-- gtk_gaim_status_box_regenerate(statusbox);
-+ gtk_gaim2_status_box_regenerate(statusbox);
-
- break;
- default:
-@@ -211,22 +211,22 @@ gtk_gaim_status_box_set_property(GObject
- }
-
- static void
--gtk_gaim_status_box_finalize(GObject *obj)
-+gtk_gaim2_status_box_finalize(GObject *obj)
- {
-- GtkGaimStatusBox *statusbox = GTK_GAIM_STATUS_BOX(obj);
-+ GtkGaim2StatusBox *statusbox = GTK_GAIM_STATUS_BOX(obj);
-
- if (statusbox->status_changed_signal) {
-- gaim_signal_disconnect(gaim_accounts_get_handle(), "account-status-changed",
-+ gaim2_signal_disconnect(gaim2_accounts_get_handle(), "account-status-changed",
- statusbox, GAIM_CALLBACK(account_status_changed_cb));
- statusbox->status_changed_signal = 0;
- }
-- gaim_prefs_disconnect_by_handle(statusbox);
-+ gaim2_prefs_disconnect_by_handle(statusbox);
-
- G_OBJECT_CLASS(parent_class)->finalize(obj);
- }
-
- static void
--gtk_gaim_status_box_class_init (GtkGaimStatusBoxClass *klass)
-+gtk_gaim2_status_box_class_init (GtkGaim2StatusBoxClass *klass)
- {
- GObjectClass *object_class;
- GtkComboBoxClass *combo_class;
-@@ -236,24 +236,24 @@ gtk_gaim_status_box_class_init (GtkGaimS
- parent_class = g_type_class_peek_parent(klass);
-
- combo_class = (GtkComboBoxClass*)klass;
-- combo_class->changed = gtk_gaim_status_box_changed;
-+ combo_class->changed = gtk_gaim2_status_box_changed;
-
- widget_class = (GtkWidgetClass*)klass;
- combo_box_size_request = widget_class->size_request;
-- widget_class->size_request = gtk_gaim_status_box_size_request;
-+ widget_class->size_request = gtk_gaim2_status_box_size_request;
- combo_box_size_allocate = widget_class->size_allocate;
-- widget_class->size_allocate = gtk_gaim_status_box_size_allocate;
-- widget_class->expose_event = gtk_gaim_status_box_expose_event;
-+ widget_class->size_allocate = gtk_gaim2_status_box_size_allocate;
-+ widget_class->expose_event = gtk_gaim2_status_box_expose_event;
-
- combo_box_forall = container_class->forall;
-- container_class->forall = gtk_gaim_status_box_forall;
-+ container_class->forall = gtk_gaim2_status_box_forall;
-
- object_class = (GObjectClass *)klass;
-
-- object_class->finalize = gtk_gaim_status_box_finalize;
-+ object_class->finalize = gtk_gaim2_status_box_finalize;
-
-- object_class->get_property = gtk_gaim_status_box_get_property;
-- object_class->set_property = gtk_gaim_status_box_set_property;
-+ object_class->get_property = gtk_gaim2_status_box_get_property;
-+ object_class->set_property = gtk_gaim2_status_box_set_property;
-
- g_object_class_install_property(object_class,
- PROP_ACCOUNT,
-@@ -266,7 +266,7 @@ gtk_gaim_status_box_class_init (GtkGaimS
- }
-
- static void
--gtk_gaim_status_box_refresh(GtkGaimStatusBox *status_box)
-+gtk_gaim2_status_box_refresh(GtkGaim2StatusBox *status_box)
- {
- char *text = NULL, *title;
- char aa_color[8];
-@@ -300,7 +300,7 @@ gtk_gaim_status_box_refresh(GtkGaimStatu
-
- if (status_box->account) {
- char *text2 = g_strdup_printf("%s\n<span size=\"smaller\">%s</span>",
-- gaim_account_get_username(status_box->account),
-+ gaim2_account_get_username(status_box->account),
- text ? text : title);
- g_free(text);
- text = text2;
-@@ -347,9 +347,9 @@ gtk_gaim_status_box_refresh(GtkGaimStatu
- * keyboard signals instead of the changed signal?
- */
- static void
--update_to_reflect_current_status(GtkGaimStatusBox *status_box)
-+update_to_reflect_current_status(GtkGaim2StatusBox *status_box)
- {
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
- guint index;
- const char *message;
-
-@@ -357,7 +357,7 @@ update_to_reflect_current_status(GtkGaim
- if (status_box->account)
- return;
-
-- saved_status = gaim_savedstatus_get_current();
-+ saved_status = gaim2_savedstatus_get_current();
-
- /*
- * Suppress the "changed" signal because the status
-@@ -365,11 +365,11 @@ update_to_reflect_current_status(GtkGaim
- */
- gtk_widget_set_sensitive(GTK_WIDGET(status_box), FALSE);
-
-- if (gaim_savedstatus_has_substatuses(saved_status))
-+ if (gaim2_savedstatus_has_substatuses(saved_status))
- index = 5;
- else
- {
-- switch (gaim_savedstatus_get_type(saved_status))
-+ switch (gaim2_savedstatus_get_type(saved_status))
- {
- case GAIM_STATUS_AVAILABLE:
- index = 0;
-@@ -390,7 +390,7 @@ update_to_reflect_current_status(GtkGaim
- }
- gtk_combo_box_set_active(GTK_COMBO_BOX(status_box), index);
-
-- message = gaim_savedstatus_get_message(saved_status);
-+ message = gaim2_savedstatus_get_message(saved_status);
- if (!message || !*message)
- {
- status_box->imhtml_visible = FALSE;
-@@ -420,13 +420,13 @@ update_to_reflect_current_status(GtkGaim
- }
-
- static void
--gtk_gaim_status_box_regenerate(GtkGaimStatusBox *status_box)
-+gtk_gaim2_status_box_regenerate(GtkGaim2StatusBox *status_box)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GdkPixbuf *pixbuf, *pixbuf2, *pixbuf3, *pixbuf4;
- GtkIconSize icon_size;
-
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons"))
- icon_size = gtk_icon_size_from_name(GAIM_ICON_SIZE_STATUS);
- else
- icon_size = gtk_icon_size_from_name(GAIM_ICON_SIZE_STATUS_SMALL);
-@@ -440,41 +440,41 @@ gtk_gaim_status_box_regenerate(GtkGaimSt
- if (account == NULL)
- {
- pixbuf = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_ONLINE,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- pixbuf2 = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_AWAY,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- pixbuf3 = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_OFFLINE,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- pixbuf4 = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_INVISIBLE,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- /* hacks */
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_AVAILABLE, pixbuf, _("Available"), NULL);
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_AWAY, pixbuf2, _("Away"), NULL);
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_INVISIBLE, pixbuf4, _("Invisible"), NULL);
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_OFFLINE, pixbuf3, _("Offline"), NULL);
-- gtk_gaim_status_box_add_separator(GTK_GAIM_STATUS_BOX(status_box));
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GTK_GAIM_STATUS_BOX_TYPE_CUSTOM, pixbuf, _("Custom..."), NULL);
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GTK_GAIM_STATUS_BOX_TYPE_SAVED, pixbuf, _("Saved..."), NULL);
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_AVAILABLE, pixbuf, _("Available"), NULL);
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_AWAY, pixbuf2, _("Away"), NULL);
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_INVISIBLE, pixbuf4, _("Invisible"), NULL);
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GAIM_STATUS_OFFLINE, pixbuf3, _("Offline"), NULL);
-+ gtk_gaim2_status_box_add_separator(GTK_GAIM_STATUS_BOX(status_box));
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GTK_GAIM_STATUS_BOX_TYPE_CUSTOM, pixbuf, _("Custom..."), NULL);
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box), GTK_GAIM_STATUS_BOX_TYPE_SAVED, pixbuf, _("Saved..."), NULL);
-
- update_to_reflect_current_status(status_box);
-
- } else {
- const GList *l;
-
-- for (l = gaim_account_get_status_types(account); l != NULL; l = l->next)
-+ for (l = gaim2_account_get_status_types(account); l != NULL; l = l->next)
- {
-- GaimStatusType *status_type = (GaimStatusType *)l->data;
-+ Gaim2StatusType *status_type = (Gaim2StatusType *)l->data;
-
-- if (!gaim_status_type_is_user_settable(status_type))
-+ if (!gaim2_status_type_is_user_settable(status_type))
- continue;
-
-- gtk_gaim_status_box_add(GTK_GAIM_STATUS_BOX(status_box),
-- gaim_status_type_get_primitive(status_type),
-- gaim_gtk_create_prpl_icon_with_status(account, status_type),
-- gaim_status_type_get_name(status_type),
-+ gtk_gaim2_status_box_add(GTK_GAIM_STATUS_BOX(status_box),
-+ gaim2_status_type_get_primitive(status_type),
-+ gaim2_gtk_create_prpl_icon_with_status(account, status_type),
-+ gaim2_status_type_get_name(status_type),
- NULL);
- }
-- update_to_reflect_account_status(status_box, account, gaim_account_get_active_status(account));
-+ update_to_reflect_account_status(status_box, account, gaim2_account_get_active_status(account));
- }
- }
-
-@@ -487,7 +487,7 @@ static gboolean scroll_event_cb(GtkWidge
- return TRUE;
- }
-
--static int imhtml_remove_focus(GtkWidget *w, GdkEventKey *event, GtkGaimStatusBox *box)
-+static int imhtml_remove_focus(GtkWidget *w, GdkEventKey *event, GtkGaim2StatusBox *box)
- {
- if (event->keyval == GDK_Tab || event->keyval == GDK_KP_Tab)
- {
-@@ -500,7 +500,7 @@ static int imhtml_remove_focus(GtkWidget
- }
- if (!box->typing)
- return FALSE;
-- gtk_gaim_status_box_pulse_typing(box);
-+ gtk_gaim2_status_box_pulse_typing(box);
- g_source_remove(box->typing);
- box->typing = g_timeout_add(TYPING_TIMEOUT, (GSourceFunc)remove_typing_cb, box);
-
-@@ -512,7 +512,7 @@ static gboolean
- dropdown_store_row_separator_func(GtkTreeModel *model,
- GtkTreeIter *iter, gpointer data)
- {
-- GtkGaimStatusBoxItemType type;
-+ GtkGaim2StatusBoxItemType type;
-
- gtk_tree_model_get(model, iter, TYPE_COLUMN, &type, -1);
-
-@@ -524,11 +524,11 @@ dropdown_store_row_separator_func(GtkTre
- #endif
-
- static void
--cache_pixbufs(GtkGaimStatusBox *status_box)
-+cache_pixbufs(GtkGaim2StatusBox *status_box)
- {
- GtkIconSize icon_size;
-
-- if (gaim_prefs_get_bool("/gaim/gtk/blist/show_buddy_icons"))
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/blist/show_buddy_icons"))
- icon_size = gtk_icon_size_from_name(GAIM_ICON_SIZE_STATUS_TWO_LINE);
- else
- icon_size = gtk_icon_size_from_name(GAIM_ICON_SIZE_STATUS_SMALL_TWO_LINE);
-@@ -537,7 +537,7 @@ cache_pixbufs(GtkGaimStatusBox *status_b
- gdk_pixbuf_unref(status_box->error_pixbuf);
-
- status_box->error_pixbuf = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_OFFLINE,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- if (status_box->connecting_pixbufs[0] != NULL)
- gdk_pixbuf_unref(status_box->connecting_pixbufs[0]);
- if (status_box->connecting_pixbufs[1] != NULL)
-@@ -549,13 +549,13 @@ cache_pixbufs(GtkGaimStatusBox *status_b
-
- status_box->connecting_index = 0;
- status_box->connecting_pixbufs[0] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_CONNECT0,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- status_box->connecting_pixbufs[1] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_CONNECT1,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- status_box->connecting_pixbufs[2] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_CONNECT2,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- status_box->connecting_pixbufs[3] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_CONNECT3,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
-
- if (status_box->typing_pixbufs[0] != NULL)
- gdk_pixbuf_unref(status_box->typing_pixbufs[0]);
-@@ -568,47 +568,47 @@ cache_pixbufs(GtkGaimStatusBox *status_b
-
- status_box->typing_index = 0;
- status_box->typing_pixbufs[0] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_TYPING0,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- status_box->typing_pixbufs[1] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_TYPING1,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- status_box->typing_pixbufs[2] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_TYPING2,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- status_box->typing_pixbufs[3] = gtk_widget_render_icon (GTK_WIDGET(status_box->vbox), GAIM_STOCK_STATUS_TYPING3,
-- icon_size, "GtkGaimStatusBox");
-+ icon_size, "GtkGaim2StatusBox");
- }
-
- static void
--current_status_pref_changed_cb(const char *name, GaimPrefType type,
-+current_status_pref_changed_cb(const char *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
-- GtkGaimStatusBox *box = data;
-+ GtkGaim2StatusBox *box = data;
- if (box->account)
- update_to_reflect_account_status(box, box->account,
-- gaim_account_get_active_status(box->account));
-+ gaim2_account_get_active_status(box->account));
- else
- update_to_reflect_current_status(box);
- }
-
- static void
--buddy_list_details_pref_changed_cb(const char *name, GaimPrefType type,
-+buddy_list_details_pref_changed_cb(const char *name, Gaim2PrefType type,
- gpointer val, gpointer data)
- {
-- GtkGaimStatusBox *status_box = (GtkGaimStatusBox *)data;
-+ GtkGaim2StatusBox *status_box = (GtkGaim2StatusBox *)data;
-
- cache_pixbufs(status_box);
-- gtk_gaim_status_box_regenerate(status_box);
-+ gtk_gaim2_status_box_regenerate(status_box);
- update_size(status_box);
- }
-
- static void
--spellcheck_prefs_cb(const char *name, GaimPrefType type,
-+spellcheck_prefs_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
- #ifdef USE_GTKSPELL
-- GtkGaimStatusBox *status_box = (GtkGaimStatusBox *)data;
-+ GtkGaim2StatusBox *status_box = (GtkGaim2StatusBox *)data;
-
- if (value)
-- gaim_gtk_setup_gtkspell(GTK_TEXT_VIEW(status_box->imhtml));
-+ gaim2_gtk_setup_gtkspell(GTK_TEXT_VIEW(status_box->imhtml));
- else
- {
- GtkSpell *spell;
-@@ -619,7 +619,7 @@ spellcheck_prefs_cb(const char *name, Ga
- }
-
- #if 0
--static gboolean button_released_cb(GtkWidget *widget, GdkEventButton *event, GtkGaimStatusBox *box)
-+static gboolean button_released_cb(GtkWidget *widget, GdkEventButton *event, GtkGaim2StatusBox *box)
- {
-
- if (event->button != 1)
-@@ -631,7 +631,7 @@ static gboolean button_released_cb(GtkWi
- return TRUE;
- }
-
--static gboolean button_pressed_cb(GtkWidget *widget, GdkEventButton *event, GtkGaimStatusBox *box)
-+static gboolean button_pressed_cb(GtkWidget *widget, GdkEventButton *event, GtkGaim2StatusBox *box)
- {
- if (event->button != 1)
- return FALSE;
-@@ -643,14 +643,14 @@ static gboolean button_pressed_cb(GtkWid
- #endif
-
- static void
--toggled_cb(GtkWidget *widget, GtkGaimStatusBox *box)
-+toggled_cb(GtkWidget *widget, GtkGaim2StatusBox *box)
- {
- gtk_combo_box_popup(GTK_COMBO_BOX(box));
- gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(box->toggle_button), FALSE);
- }
-
- static void
--gtk_gaim_status_box_init (GtkGaimStatusBox *status_box)
-+gtk_gaim2_status_box_init (GtkGaim2StatusBox *status_box)
- {
- GtkWidget *vbox;
- GtkCellRenderer *text_rend;
-@@ -678,7 +678,7 @@ gtk_gaim_status_box_init (GtkGaimStatusB
- gtk_cell_view_set_model(GTK_CELL_VIEW(status_box->cell_view), GTK_TREE_MODEL(status_box->store));
- gtk_combo_box_set_wrap_width(GTK_COMBO_BOX(status_box), 0);
- gtk_list_store_append(status_box->store, &(status_box->iter));
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- path = gtk_tree_path_new_from_string("0");
- gtk_cell_view_set_displayed_row(GTK_CELL_VIEW(status_box->cell_view), path);
- gtk_tree_path_free(path);
-@@ -727,8 +727,8 @@ gtk_gaim_status_box_init (GtkGaimStatusB
- g_signal_connect_swapped(G_OBJECT(status_box->imhtml), "message_send", G_CALLBACK(remove_typing_cb), status_box);
- gtk_imhtml_set_editable(GTK_IMHTML(status_box->imhtml), TRUE);
- #ifdef USE_GTKSPELL
-- if (gaim_prefs_get_bool("/gaim/gtk/conversations/spellcheck"))
-- gaim_gtk_setup_gtkspell(GTK_TEXT_VIEW(status_box->imhtml));
-+ if (gaim2_prefs_get_bool("/gaim2/gtk/conversations/spellcheck"))
-+ gaim2_gtk_setup_gtkspell(GTK_TEXT_VIEW(status_box->imhtml));
- #endif
- gtk_widget_set_parent(status_box->vbox, GTK_WIDGET(status_box));
- gtk_widget_set_parent(status_box->toggle_button, GTK_WIDGET(status_box));
-@@ -749,18 +749,18 @@ gtk_gaim_status_box_init (GtkGaimStatusB
- #endif
-
- cache_pixbufs(status_box);
-- gtk_gaim_status_box_regenerate(status_box);
-+ gtk_gaim2_status_box_regenerate(status_box);
-
-- gaim_prefs_connect_callback(status_box, "/core/savedstatus/current",
-+ gaim2_prefs_connect_callback(status_box, "/core/savedstatus/current",
- current_status_pref_changed_cb, status_box);
-- gaim_prefs_connect_callback(status_box, "/gaim/gtk/blist/show_buddy_icons",
-+ gaim2_prefs_connect_callback(status_box, "/gaim2/gtk/blist/show_buddy_icons",
- buddy_list_details_pref_changed_cb, status_box);
-- gaim_prefs_connect_callback(status_box, "/gaim/gtk/conversations/spellcheck",
-+ gaim2_prefs_connect_callback(status_box, "/gaim2/gtk/conversations/spellcheck",
- spellcheck_prefs_cb, status_box);
- }
-
- static void
--gtk_gaim_status_box_size_request(GtkWidget *widget,
-+gtk_gaim2_status_box_size_request(GtkWidget *widget,
- GtkRequisition *requisition)
- {
- GtkRequisition box_req;
-@@ -775,7 +775,7 @@ gtk_gaim_status_box_size_request(GtkWidg
- }
-
- static void
--gtk_gaim_status_box_size_allocate(GtkWidget *widget,
-+gtk_gaim2_status_box_size_allocate(GtkWidget *widget,
- GtkAllocation *allocation)
- {
- GtkRequisition req = {0,0};
-@@ -804,22 +804,22 @@ gtk_gaim_status_box_size_allocate(GtkWid
- }
-
- static gboolean
--gtk_gaim_status_box_expose_event(GtkWidget *widget,
-+gtk_gaim2_status_box_expose_event(GtkWidget *widget,
- GdkEventExpose *event)
- {
-- GtkGaimStatusBox *status_box = GTK_GAIM_STATUS_BOX(widget);
-+ GtkGaim2StatusBox *status_box = GTK_GAIM_STATUS_BOX(widget);
- gtk_container_propagate_expose(GTK_CONTAINER(widget), status_box->vbox, event);
- gtk_container_propagate_expose(GTK_CONTAINER(widget), status_box->toggle_button, event);
- return FALSE;
- }
-
- static void
--gtk_gaim_status_box_forall(GtkContainer *container,
-+gtk_gaim2_status_box_forall(GtkContainer *container,
- gboolean include_internals,
- GtkCallback callback,
- gpointer callback_data)
- {
-- GtkGaimStatusBox *status_box = GTK_GAIM_STATUS_BOX (container);
-+ GtkGaim2StatusBox *status_box = GTK_GAIM_STATUS_BOX (container);
-
- if (include_internals)
- {
-@@ -832,19 +832,19 @@ gtk_gaim_status_box_forall(GtkContainer
- }
-
- GtkWidget *
--gtk_gaim_status_box_new()
-+gtk_gaim2_status_box_new()
- {
- return g_object_new(GTK_GAIM_TYPE_STATUS_BOX, NULL);
- }
-
- GtkWidget *
--gtk_gaim_status_box_new_with_account(GaimAccount *account)
-+gtk_gaim2_status_box_new_with_account(Gaim2Account *account)
- {
- return g_object_new(GTK_GAIM_TYPE_STATUS_BOX, "account", account, NULL);
- }
-
- void
--gtk_gaim_status_box_add(GtkGaimStatusBox *status_box, GtkGaimStatusBoxItemType type, GdkPixbuf *pixbuf, const char *text, const char *sec_text)
-+gtk_gaim2_status_box_add(GtkGaim2StatusBox *status_box, GtkGaim2StatusBoxItemType type, GdkPixbuf *pixbuf, const char *text, const char *sec_text)
- {
- GtkTreeIter iter;
- char *t;
-@@ -873,7 +873,7 @@ gtk_gaim_status_box_add(GtkGaimStatusBox
- }
-
- void
--gtk_gaim_status_box_add_separator(GtkGaimStatusBox *status_box)
-+gtk_gaim2_status_box_add_separator(GtkGaim2StatusBox *status_box)
- {
- /* Don't do anything unless GTK actually supports
- * gtk_combo_box_set_row_separator_func */
-@@ -888,27 +888,27 @@ gtk_gaim_status_box_add_separator(GtkGai
- }
-
- void
--gtk_gaim_status_box_set_error(GtkGaimStatusBox *status_box, const gchar *error)
-+gtk_gaim2_status_box_set_error(GtkGaim2StatusBox *status_box, const gchar *error)
- {
- if (status_box->error)
- g_free(status_box->error);
- status_box->error = NULL;
- if (error != NULL)
- status_box->error = g_strdup(error);
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
-
- void
--gtk_gaim_status_box_set_connecting(GtkGaimStatusBox *status_box, gboolean connecting)
-+gtk_gaim2_status_box_set_connecting(GtkGaim2StatusBox *status_box, gboolean connecting)
- {
- if (!status_box)
- return;
- status_box->connecting = connecting;
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
-
- void
--gtk_gaim_status_box_pulse_connecting(GtkGaimStatusBox *status_box)
-+gtk_gaim2_status_box_pulse_connecting(GtkGaim2StatusBox *status_box)
- {
- if (!status_box)
- return;
-@@ -916,28 +916,28 @@ gtk_gaim_status_box_pulse_connecting(Gtk
- status_box->connecting_index = 0;
- else
- status_box->connecting_index++;
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
-
- static void
--gtk_gaim_status_box_pulse_typing(GtkGaimStatusBox *status_box)
-+gtk_gaim2_status_box_pulse_typing(GtkGaim2StatusBox *status_box)
- {
- if (status_box->typing_index == 3)
- status_box->typing_index = 0;
- else
- status_box->typing_index++;
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
-
--static GaimStatusType
--*find_status_type_by_index(const GaimAccount *account, gint active)
-+static Gaim2StatusType
-+*find_status_type_by_index(const Gaim2Account *account, gint active)
- {
-- const GList *l = gaim_account_get_status_types(account);
-+ const GList *l = gaim2_account_get_status_types(account);
- gint i;
-
- for (i = 0; l; l = l->next) {
-- GaimStatusType *status_type = l->data;
-- if (!gaim_status_type_is_user_settable(status_type))
-+ Gaim2StatusType *status_type = l->data;
-+ if (!gaim2_status_type_is_user_settable(status_type))
- continue;
-
- if (active == i)
-@@ -961,13 +961,13 @@ message_changed(const char *one, const c
- }
-
- static void
--activate_currently_selected_status(GtkGaimStatusBox *status_box)
-+activate_currently_selected_status(GtkGaim2StatusBox *status_box)
- {
-- GtkGaimStatusBoxItemType type;
-+ GtkGaim2StatusBoxItemType type;
- gchar *title;
- GtkTreeIter iter;
- char *message;
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
- gboolean changed = TRUE;
-
- if (!gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter))
-@@ -990,7 +990,7 @@ activate_currently_selected_status(GtkGa
- gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter,
- TITLE_COLUMN, &title, -1);
-
-- message = gtk_gaim_status_box_get_message(status_box);
-+ message = gtk_gaim2_status_box_get_message(status_box);
- if (!message || !*message)
- {
- gtk_widget_hide_all(status_box->vbox);
-@@ -999,52 +999,52 @@ activate_currently_selected_status(GtkGa
-
- if (status_box->account) {
- gint active;
-- GaimStatusType *status_type;
-- GaimStatus *status;
-+ Gaim2StatusType *status_type;
-+ Gaim2Status *status;
- const char *id = NULL;
-
-- status = gaim_account_get_active_status(status_box->account);
-+ status = gaim2_account_get_active_status(status_box->account);
-
- g_object_get(G_OBJECT(status_box), "active", &active, NULL);
-
- status_type = find_status_type_by_index(status_box->account, active);
-- id = gaim_status_type_get_id(status_type);
-+ id = gaim2_status_type_get_id(status_type);
-
-- if (strncmp(id, gaim_status_get_id(status), strlen(id)) == 0)
-+ if (strncmp(id, gaim2_status_get_id(status), strlen(id)) == 0)
- {
- /* Selected status and previous status is the same */
-- if (!message_changed(message, gaim_status_get_attr_string(status, "message")))
-+ if (!message_changed(message, gaim2_status_get_attr_string(status, "message")))
- changed = FALSE;
- }
-
- if (changed)
- {
- if (message)
-- gaim_account_set_status(status_box->account, id,
-+ gaim2_account_set_status(status_box->account, id,
- TRUE, "message", message, NULL);
- else
-- gaim_account_set_status(status_box->account, id,
-+ gaim2_account_set_status(status_box->account, id,
- TRUE, NULL);
- }
- } else {
- /* Save the newly selected status to prefs.xml and status.xml */
-
- /* Has the status been really changed? */
-- saved_status = gaim_savedstatus_get_current();
-- if (gaim_savedstatus_get_type(saved_status) == type)
-+ saved_status = gaim2_savedstatus_get_current();
-+ if (gaim2_savedstatus_get_type(saved_status) == type)
- {
-- if (!message_changed(gaim_savedstatus_get_message(saved_status), message))
-+ if (!message_changed(gaim2_savedstatus_get_message(saved_status), message))
- changed = FALSE;
- }
-
- if (changed)
- {
- /* Create a new transient saved status */
-- saved_status = gaim_savedstatus_new(NULL, type);
-- gaim_savedstatus_set_message(saved_status, message);
-+ saved_status = gaim2_savedstatus_new(NULL, type);
-+ gaim2_savedstatus_set_message(saved_status, message);
-
- /* Set the status for each account */
-- gaim_savedstatus_activate(saved_status);
-+ gaim2_savedstatus_activate(saved_status);
- }
- }
-
-@@ -1052,7 +1052,7 @@ activate_currently_selected_status(GtkGa
- g_free(message);
- }
-
--static void update_size(GtkGaimStatusBox *status_box)
-+static void update_size(GtkGaim2StatusBox *status_box)
- {
- GtkTextBuffer *buffer;
- GtkTextIter iter;
-@@ -1095,20 +1095,20 @@ static void update_size(GtkGaimStatusBox
- gtk_widget_set_size_request(status_box->vbox, -1, height);
- }
-
--static void remove_typing_cb(GtkGaimStatusBox *status_box)
-+static void remove_typing_cb(GtkGaim2StatusBox *status_box)
- {
- activate_currently_selected_status(status_box);
-
- g_source_remove(status_box->typing);
- status_box->typing = 0;
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
-
--static void gtk_gaim_status_box_changed(GtkComboBox *box)
-+static void gtk_gaim2_status_box_changed(GtkComboBox *box)
- {
-- GtkGaimStatusBox *status_box;
-+ GtkGaim2StatusBox *status_box;
- GtkTreeIter iter;
-- GtkGaimStatusBoxItemType type;
-+ GtkGaim2StatusBoxItemType type;
- char *text, *sec_text;
- GdkPixbuf *pixbuf;
- GList *accounts = NULL, *node;
-@@ -1139,14 +1139,14 @@ static void gtk_gaim_status_box_changed(
- {
- if (type == GTK_GAIM_STATUS_BOX_TYPE_CUSTOM)
- {
-- gaim_gtk_status_editor_show(NULL);
-+ gaim2_gtk_status_editor_show(NULL);
- update_to_reflect_current_status(status_box);
- return;
- }
-
- if (type == GTK_GAIM_STATUS_BOX_TYPE_SAVED)
- {
-- gaim_gtk_status_window_show();
-+ gaim2_gtk_status_window_show();
- update_to_reflect_current_status(status_box);
- return;
- }
-@@ -1160,17 +1160,17 @@ static void gtk_gaim_status_box_changed(
- if (status_box->account)
- accounts = g_list_prepend(accounts, status_box->account);
- else
-- accounts = gaim_accounts_get_all_active();
-+ accounts = gaim2_accounts_get_all_active();
- status_box->imhtml_visible = FALSE;
- for (node = accounts; node != NULL; node = node->next)
- {
-- GaimAccount *account;
-- GaimStatusType *status_type;
-+ Gaim2Account *account;
-+ Gaim2StatusType *status_type;
-
- account = node->data;
-- status_type = gaim_account_get_status_type_with_primitive(account, type);
-+ status_type = gaim2_account_get_status_type_with_primitive(account, type);
- if ((status_type != NULL) &&
-- (gaim_status_type_get_attr(status_type, "message") != NULL))
-+ (gaim2_status_type_get_attr(status_type, "message") != NULL))
- {
- status_box->imhtml_visible = TRUE;
- break;
-@@ -1199,21 +1199,21 @@ static void gtk_gaim_status_box_changed(
- if (GTK_WIDGET_IS_SENSITIVE(GTK_WIDGET(status_box)))
- activate_currently_selected_status(status_box); /* This is where we actually set the status */
- }
-- gtk_gaim_status_box_refresh(status_box);
-+ gtk_gaim2_status_box_refresh(status_box);
- }
-
- static void imhtml_changed_cb(GtkTextBuffer *buffer, void *data)
- {
-- GtkGaimStatusBox *box = (GtkGaimStatusBox*)data;
-+ GtkGaim2StatusBox *box = (GtkGaim2StatusBox*)data;
- if (GTK_WIDGET_IS_SENSITIVE(GTK_WIDGET(box)))
- {
- if (box->typing) {
-- gtk_gaim_status_box_pulse_typing(box);
-+ gtk_gaim2_status_box_pulse_typing(box);
- g_source_remove(box->typing);
- }
- box->typing = g_timeout_add(TYPING_TIMEOUT, (GSourceFunc)remove_typing_cb, box);
- }
-- gtk_gaim_status_box_refresh(box);
-+ gtk_gaim2_status_box_refresh(box);
- }
-
- static void imhtml_format_changed_cb(GtkIMHtml *imhtml, GtkIMHtmlButtons buttons, void *data)
-@@ -1221,17 +1221,17 @@ static void imhtml_format_changed_cb(Gtk
- imhtml_changed_cb(NULL, data);
- }
-
--GtkGaimStatusBoxItemType gtk_gaim_status_box_get_active_type(GtkGaimStatusBox *status_box)
-+GtkGaim2StatusBoxItemType gtk_gaim2_status_box_get_active_type(GtkGaim2StatusBox *status_box)
- {
- GtkTreeIter iter;
-- GtkGaimStatusBoxItemType type;
-+ GtkGaim2StatusBoxItemType type;
- gtk_combo_box_get_active_iter(GTK_COMBO_BOX(status_box), &iter);
- gtk_tree_model_get(GTK_TREE_MODEL(status_box->dropdown_store), &iter,
- TYPE_COLUMN, &type, -1);
- return type;
- }
-
--char *gtk_gaim_status_box_get_message(GtkGaimStatusBox *status_box)
-+char *gtk_gaim2_status_box_get_message(GtkGaim2StatusBox *status_box)
- {
- if (status_box->imhtml_visible)
- return gtk_imhtml_get_markup(GTK_IMHTML(status_box->imhtml));
-diff -prNu ./src/gtkstatusbox.h ./src/gtkstatusbox.h
---- ./src/gtkstatusbox.h 2005-12-22 05:21:30.000000000 +0100
-+++ ./src/gtkstatusbox.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkstatusbox.c GTK+ Status Selection Widget
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -37,35 +37,35 @@
-
- G_BEGIN_DECLS
-
--#define GTK_GAIM_TYPE_STATUS_BOX (gtk_gaim_status_box_get_type ())
--#define GTK_GAIM_STATUS_BOX(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_GAIM_TYPE_STATUS_BOX, GtkGaimStatusBox))
--#define GTK_GAIM_STATUS_BOX_CLASS(vtable) (G_TYPE_CHECK_CLASS_CAST ((vtable), GTK_GAIM_TYPE_STATUS_BOX, GtkGaimStatusBoxClass))
-+#define GTK_GAIM_TYPE_STATUS_BOX (gtk_gaim2_status_box_get_type ())
-+#define GTK_GAIM_STATUS_BOX(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_GAIM_TYPE_STATUS_BOX, GtkGaim2StatusBox))
-+#define GTK_GAIM_STATUS_BOX_CLASS(vtable) (G_TYPE_CHECK_CLASS_CAST ((vtable), GTK_GAIM_TYPE_STATUS_BOX, GtkGaim2StatusBoxClass))
- #define GTK_GAIM_IS_STATUS_BOX(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GTK_GAIM_TYPE_STATUS_BOX))
- #define GTK_GAIM_IS_STATUS_BOX_CLASS(vtable) (G_TYPE_CHECK_CLASS_TYPE ((vtable), GTK_GAIM_TYPE_STATUS_BOX))
--#define GTK_GAIM_STATUS_BOX_GET_CLASS(inst) (G_TYPE_INSTANCE_GET_CLASS ((inst), GTK_GAIM_TYPE_STATUS_BOX, GtkGaimStatusBoxClass))
-+#define GTK_GAIM_STATUS_BOX_GET_CLASS(inst) (G_TYPE_INSTANCE_GET_CLASS ((inst), GTK_GAIM_TYPE_STATUS_BOX, GtkGaim2StatusBoxClass))
-
- /**
- * This is a hidden field in the GtkStatusBox that identifies the
- * item in the list store. The item could be a normal
-- * GaimStatusPrimitive, or it could be something special like the
-+ * Gaim2StatusPrimitive, or it could be something special like the
- * "Custom..." item, or "Saved..." or a GtkSeparator.
- */
- typedef enum
- {
- /*
- * The first 0 through GAIM_STATUS_NUM_PRIMITIVES
-- * correspond to GaimStatusPrimitives.
-+ * correspond to Gaim2StatusPrimitives.
- */
- GTK_GAIM_STATUS_BOX_TYPE_SEPARATOR = GAIM_STATUS_NUM_PRIMITIVES,
- GTK_GAIM_STATUS_BOX_TYPE_CUSTOM,
- GTK_GAIM_STATUS_BOX_TYPE_SAVED,
- GTK_GAIM_STATUS_BOX_NUM_TYPES
--} GtkGaimStatusBoxItemType;
-+} GtkGaim2StatusBoxItemType;
-
--typedef struct _GtkGaimStatusBox GtkGaimStatusBox;
--typedef struct _GtkGaimStatusBoxClass GtkGaimStatusBoxClass;
-+typedef struct _GtkGaim2StatusBox GtkGaim2StatusBox;
-+typedef struct _GtkGaim2StatusBoxClass GtkGaim2StatusBoxClass;
-
--struct _GtkGaimStatusBox
-+struct _GtkGaim2StatusBox
- {
- GtkComboBox parent_instance;
-
-@@ -81,7 +81,7 @@ struct _GtkGaimStatusBox
- */
- GtkListStore *dropdown_store;
-
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- GtkWidget *vbox, *sw;
- GtkWidget *imhtml;
-@@ -116,7 +116,7 @@ struct _GtkGaimStatusBox
- GtkWidget *arrow;
- };
-
--struct _GtkGaimStatusBoxClass
-+struct _GtkGaim2StatusBoxClass
- {
- GtkComboBoxClass parent_class;
-
-@@ -131,28 +131,28 @@ struct _GtkGaimStatusBoxClass
- };
-
-
--GType gtk_gaim_status_box_get_type (void) G_GNUC_CONST;
--GtkWidget *gtk_gaim_status_box_new (void);
--GtkWidget *gtk_gaim_status_box_new_with_account (GaimAccount *);
-+GType gtk_gaim2_status_box_get_type (void) G_GNUC_CONST;
-+GtkWidget *gtk_gaim2_status_box_new (void);
-+GtkWidget *gtk_gaim2_status_box_new_with_account (Gaim2Account *);
-
- void
--gtk_gaim_status_box_add(GtkGaimStatusBox *status_box, GtkGaimStatusBoxItemType type, GdkPixbuf *pixbuf, const char *text, const char *sec_text);
-+gtk_gaim2_status_box_add(GtkGaim2StatusBox *status_box, GtkGaim2StatusBoxItemType type, GdkPixbuf *pixbuf, const char *text, const char *sec_text);
-
- void
--gtk_gaim_status_box_add_separator(GtkGaimStatusBox *status_box);
-+gtk_gaim2_status_box_add_separator(GtkGaim2StatusBox *status_box);
-
- void
--gtk_gaim_status_box_set_error(GtkGaimStatusBox *status_box, const gchar *error);
-+gtk_gaim2_status_box_set_error(GtkGaim2StatusBox *status_box, const gchar *error);
-
- void
--gtk_gaim_status_box_set_connecting(GtkGaimStatusBox *status_box, gboolean connecting);
-+gtk_gaim2_status_box_set_connecting(GtkGaim2StatusBox *status_box, gboolean connecting);
-
- void
--gtk_gaim_status_box_pulse_connecting(GtkGaimStatusBox *status_box);
-+gtk_gaim2_status_box_pulse_connecting(GtkGaim2StatusBox *status_box);
-
--GtkGaimStatusBoxItemType gtk_gaim_status_box_get_active_type(GtkGaimStatusBox *status_box);
-+GtkGaim2StatusBoxItemType gtk_gaim2_status_box_get_active_type(GtkGaim2StatusBox *status_box);
-
--char *gtk_gaim_status_box_get_message(GtkGaimStatusBox *status_box);
-+char *gtk_gaim2_status_box_get_message(GtkGaim2StatusBox *status_box);
-
- G_END_DECLS
-
-diff -prNu ./src/gtkstock.c ./src/gtkstock.c
---- ./src/gtkstock.c 2005-12-26 07:27:39.000000000 +0100
-+++ ./src/gtkstock.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkstock.c GTK+ Stock resources
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,7 +24,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "gtkstock.h"
-
-@@ -56,12 +56,12 @@ static struct StockIcon
- #endif
- { GAIM_STOCK_DEBUG, NULL, GTK_STOCK_PROPERTIES },
- { GAIM_STOCK_DOWNLOAD, NULL, GTK_STOCK_GO_DOWN },
-- { GAIM_STOCK_DIALOG_AUTH, "dialogs", "gaim_auth.png" },
-- { GAIM_STOCK_DIALOG_COOL, "dialogs", "gaim_cool.png" },
-- { GAIM_STOCK_DIALOG_ERROR, "dialogs", "gaim_error.png" },
-- { GAIM_STOCK_DIALOG_INFO, "dialogs", "gaim_info.png" },
-- { GAIM_STOCK_DIALOG_QUESTION, "dialogs", "gaim_question.png" },
-- { GAIM_STOCK_DIALOG_WARNING, "dialogs", "gaim_warning.png" },
-+ { GAIM_STOCK_DIALOG_AUTH, "dialogs", "gaim2_auth.png" },
-+ { GAIM_STOCK_DIALOG_COOL, "dialogs", "gaim2_cool.png" },
-+ { GAIM_STOCK_DIALOG_ERROR, "dialogs", "gaim2_error.png" },
-+ { GAIM_STOCK_DIALOG_INFO, "dialogs", "gaim2_info.png" },
-+ { GAIM_STOCK_DIALOG_QUESTION, "dialogs", "gaim2_question.png" },
-+ { GAIM_STOCK_DIALOG_WARNING, "dialogs", "gaim2_warning.png" },
- #if GTK_CHECK_VERSION(2,6,0)
- { GAIM_STOCK_DISCONNECT, NULL, GTK_STOCK_DISCONNECT },
- #else
-@@ -93,7 +93,7 @@ static struct StockIcon
- { GAIM_STOCK_INVITE, NULL, GTK_STOCK_JUMP_TO },
- { GAIM_STOCK_LINK, "buttons", "insert-link-small.png" },
- { GAIM_STOCK_LOG, NULL, GTK_STOCK_DND_MULTIPLE },
-- { GAIM_STOCK_LOGO, "gaim", "logo.png" },
-+ { GAIM_STOCK_LOGO, "gaim2", "logo.png" },
- { GAIM_STOCK_MODIFY, NULL, GTK_STOCK_PREFERENCES },
- #if GTK_CHECK_VERSION(2,6,0)
- { GAIM_STOCK_PAUSE, NULL, GTK_STOCK_MEDIA_PAUSE },
-@@ -115,21 +115,21 @@ static struct StockIcon
- { GAIM_STOCK_TEXT_BIGGER, "buttons", "text_bigger.png" },
- { GAIM_STOCK_TEXT_NORMAL, "buttons", "text_normal.png" },
- { GAIM_STOCK_TEXT_SMALLER, "buttons", "text_smaller.png" },
-- { GAIM_STOCK_TYPED, "gaim", "typed.png" },
-- { GAIM_STOCK_TYPING, "gaim", "typing.png" },
-- { GAIM_STOCK_VOICE_CHAT, "gaim", "phone.png" },
-- { GAIM_STOCK_STATUS_ONLINE, "gaim", "status-online.png" },
-- { GAIM_STOCK_STATUS_OFFLINE, "gaim", "status-offline.png" },
-- { GAIM_STOCK_STATUS_AWAY, "gaim", "status-away.png" },
-- { GAIM_STOCK_STATUS_INVISIBLE,"gaim", "status-invisible.png" },
-- { GAIM_STOCK_STATUS_TYPING0, "gaim", "status-typing0.png" },
-- { GAIM_STOCK_STATUS_TYPING1, "gaim", "status-typing1.png" },
-- { GAIM_STOCK_STATUS_TYPING2, "gaim", "status-typing2.png" },
-- { GAIM_STOCK_STATUS_TYPING3, "gaim", "status-typing3.png" },
-- { GAIM_STOCK_STATUS_CONNECT0, "gaim", "status-connect0.png" },
-- { GAIM_STOCK_STATUS_CONNECT1, "gaim", "status-connect1.png" },
-- { GAIM_STOCK_STATUS_CONNECT2, "gaim", "status-connect2.png" },
-- { GAIM_STOCK_STATUS_CONNECT3, "gaim", "status-connect3.png" },
-+ { GAIM_STOCK_TYPED, "gaim2", "typed.png" },
-+ { GAIM_STOCK_TYPING, "gaim2", "typing.png" },
-+ { GAIM_STOCK_VOICE_CHAT, "gaim2", "phone.png" },
-+ { GAIM_STOCK_STATUS_ONLINE, "gaim2", "status-online.png" },
-+ { GAIM_STOCK_STATUS_OFFLINE, "gaim2", "status-offline.png" },
-+ { GAIM_STOCK_STATUS_AWAY, "gaim2", "status-away.png" },
-+ { GAIM_STOCK_STATUS_INVISIBLE,"gaim2", "status-invisible.png" },
-+ { GAIM_STOCK_STATUS_TYPING0, "gaim2", "status-typing0.png" },
-+ { GAIM_STOCK_STATUS_TYPING1, "gaim2", "status-typing1.png" },
-+ { GAIM_STOCK_STATUS_TYPING2, "gaim2", "status-typing2.png" },
-+ { GAIM_STOCK_STATUS_TYPING3, "gaim2", "status-typing3.png" },
-+ { GAIM_STOCK_STATUS_CONNECT0, "gaim2", "status-connect0.png" },
-+ { GAIM_STOCK_STATUS_CONNECT1, "gaim2", "status-connect1.png" },
-+ { GAIM_STOCK_STATUS_CONNECT2, "gaim2", "status-connect2.png" },
-+ { GAIM_STOCK_STATUS_CONNECT3, "gaim2", "status-connect3.png" },
- { GAIM_STOCK_UPLOAD, NULL, GTK_STOCK_GO_UP },
- { GAIM_STOCK_WARN, NULL, GTK_STOCK_DIALOG_WARNING }
- };
-@@ -156,11 +156,11 @@ find_file(const char *dir, const char *b
- if (base == NULL)
- return NULL;
-
-- if (!strcmp(dir, "gaim"))
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", base, NULL);
-+ if (!strcmp(dir, "gaim2"))
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", base, NULL);
- else
- {
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", dir,
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", dir,
- base, NULL);
- }
-
-@@ -177,7 +177,7 @@ find_file(const char *dir, const char *b
- }
-
- static void
--gaim_gtk_stock_versionize(GdkPixbuf **original, GtkWidget *widget) {
-+gaim2_gtk_stock_versionize(GdkPixbuf **original, GtkWidget *widget) {
- GdkPixmap *pixmap;
- GtkStyle *style;
- PangoContext *context;
-@@ -213,7 +213,7 @@ gaim_gtk_stock_versionize(GdkPixbuf **or
- }
-
- void
--gaim_gtk_stock_init(void)
-+gaim2_gtk_stock_init(void)
- {
- static gboolean stock_initted = FALSE;
- GtkIconFactory *icon_factory;
-@@ -258,7 +258,7 @@ gaim_gtk_stock_init(void)
- g_free(filename);
-
- if (!strcmp(stock_icons[i].name, GAIM_STOCK_LOGO))
-- gaim_gtk_stock_versionize(&pixbuf, win);
-+ gaim2_gtk_stock_versionize(&pixbuf, win);
-
- iconset = gtk_icon_set_new_from_pixbuf(pixbuf);
-
-diff -prNu ./src/gtkstock.h ./src/gtkstock.h
---- ./src/gtkstock.h 2005-12-26 07:27:38.000000000 +0100
-+++ ./src/gtkstock.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkstock.h GTK+ Stock resources
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -29,90 +29,90 @@
- /** @name Stock images */
- /**************************************************************************/
- /*@{*/
--#define GAIM_STOCK_ABOUT "gaim-about"
--#define GAIM_STOCK_ACCOUNTS "gaim-accounts"
--#define GAIM_STOCK_ACTION "gaim-action"
--#define GAIM_STOCK_ALIAS "gaim-alias"
--#define GAIM_STOCK_AWAY "gaim-away"
--#define GAIM_STOCK_BGCOLOR "gaim-bgcolor"
--#define GAIM_STOCK_BLOCK "gaim-block"
--#define GAIM_STOCK_CHAT "gaim-chat"
--#define GAIM_STOCK_CLEAR "gaim-clear"
--#define GAIM_STOCK_CLOSE_TABS "gaim-close-tab"
--#define GAIM_STOCK_CONNECT "gaim-connect"
--#define GAIM_STOCK_DEBUG "gaim-debug"
--#define GAIM_STOCK_DIALOG_AUTH "gaim-dialog-auth"
--#define GAIM_STOCK_DIALOG_COOL "gaim-dialog-cool"
--#define GAIM_STOCK_DIALOG_ERROR "gaim-dialog-error"
--#define GAIM_STOCK_DIALOG_INFO "gaim-dialog-info"
--#define GAIM_STOCK_DIALOG_QUESTION "gaim-dialog-question"
--#define GAIM_STOCK_DIALOG_WARNING "gaim-dialog-warning"
--#define GAIM_STOCK_DISCONNECT "gaim-disconnect"
--#define GAIM_STOCK_DOWNLOAD "gaim-download"
--#define GAIM_STOCK_EDIT "gaim-edit"
--#define GAIM_STOCK_FGCOLOR "gaim-fgcolor"
--#define GAIM_STOCK_FILE_CANCELED "gaim-file-canceled"
--#define GAIM_STOCK_FILE_DONE "gaim-file-done"
--#define GAIM_STOCK_FILE_TRANSFER "gaim-file-transfer"
--#define GAIM_STOCK_ICON_AWAY "gaim-icon-away"
--#define GAIM_STOCK_ICON_AWAY_MSG "gaim-icon-away-msg"
--#define GAIM_STOCK_ICON_CONNECT "gaim-icon-away-connect"
--#define GAIM_STOCK_ICON_OFFLINE "gaim-icon-offline"
--#define GAIM_STOCK_ICON_ONLINE "gaim-icon-online"
--#define GAIM_STOCK_ICON_ONLINE_MSG "gaim-icon-online-msg"
--#define GAIM_STOCK_IGNORE "gaim-ignore"
--#define GAIM_STOCK_IM "gaim-im"
--#define GAIM_STOCK_IMAGE "gaim-image"
--#define GAIM_STOCK_INFO "gaim-info"
--#define GAIM_STOCK_INVITE "gaim-invite"
--#define GAIM_STOCK_LINK "gaim-link"
--#define GAIM_STOCK_LOG "gaim-log"
--#define GAIM_STOCK_LOGO "gaim-logo"
--#define GAIM_STOCK_MODIFY "gaim-modify"
--#define GAIM_STOCK_OPEN_MAIL "gaim-stock-open-mail"
--#define GAIM_STOCK_PAUSE "gaim-pause"
--#define GAIM_STOCK_PENDING "gaim-pending"
--#define GAIM_STOCK_PLUGIN "gaim-plugin"
--#define GAIM_STOCK_POUNCE "gaim-pounce"
--#define GAIM_STOCK_SEND "gaim-send"
--#define GAIM_STOCK_SIGN_OFF "gaim-sign-off"
--#define GAIM_STOCK_SIGN_ON "gaim-sign-on"
--#define GAIM_STOCK_SMILEY "gaim-smiley"
--#define GAIM_STOCK_STATUS_ONLINE "gaim-status-online"
--#define GAIM_STOCK_STATUS_AWAY "gaim-status-away"
--#define GAIM_STOCK_STATUS_INVISIBLE "gaim-status-invisible"
--#define GAIM_STOCK_STATUS_OFFLINE "gaim-status-offline"
--#define GAIM_STOCK_STATUS_TYPING0 "gaim-status-typing0"
--#define GAIM_STOCK_STATUS_TYPING1 "gaim-status-typing1"
--#define GAIM_STOCK_STATUS_TYPING2 "gaim-status-typing2"
--#define GAIM_STOCK_STATUS_TYPING3 "gaim-status-typing3"
--#define GAIM_STOCK_STATUS_CONNECT0 "gaim-status-connect0"
--#define GAIM_STOCK_STATUS_CONNECT1 "gaim-status-connect1"
--#define GAIM_STOCK_STATUS_CONNECT2 "gaim-status-connect2"
--#define GAIM_STOCK_STATUS_CONNECT3 "gaim-status-connect3"
--#define GAIM_STOCK_TEXT_BIGGER "gaim-text-bigger"
--#define GAIM_STOCK_TEXT_NORMAL "gaim-text-normal"
--#define GAIM_STOCK_TEXT_SMALLER "gaim-text-smaller"
--#define GAIM_STOCK_TYPED "gaim-typed"
--#define GAIM_STOCK_TYPING "gaim-typing"
--#define GAIM_STOCK_UPLOAD "gaim-upload"
--#define GAIM_STOCK_VOICE_CHAT "gaim-voice-chat"
--#define GAIM_STOCK_WARN "gaim-warn"
-+#define GAIM_STOCK_ABOUT "gaim2-about"
-+#define GAIM_STOCK_ACCOUNTS "gaim2-accounts"
-+#define GAIM_STOCK_ACTION "gaim2-action"
-+#define GAIM_STOCK_ALIAS "gaim2-alias"
-+#define GAIM_STOCK_AWAY "gaim2-away"
-+#define GAIM_STOCK_BGCOLOR "gaim2-bgcolor"
-+#define GAIM_STOCK_BLOCK "gaim2-block"
-+#define GAIM_STOCK_CHAT "gaim2-chat"
-+#define GAIM_STOCK_CLEAR "gaim2-clear"
-+#define GAIM_STOCK_CLOSE_TABS "gaim2-close-tab"
-+#define GAIM_STOCK_CONNECT "gaim2-connect"
-+#define GAIM_STOCK_DEBUG "gaim2-debug"
-+#define GAIM_STOCK_DIALOG_AUTH "gaim2-dialog-auth"
-+#define GAIM_STOCK_DIALOG_COOL "gaim2-dialog-cool"
-+#define GAIM_STOCK_DIALOG_ERROR "gaim2-dialog-error"
-+#define GAIM_STOCK_DIALOG_INFO "gaim2-dialog-info"
-+#define GAIM_STOCK_DIALOG_QUESTION "gaim2-dialog-question"
-+#define GAIM_STOCK_DIALOG_WARNING "gaim2-dialog-warning"
-+#define GAIM_STOCK_DISCONNECT "gaim2-disconnect"
-+#define GAIM_STOCK_DOWNLOAD "gaim2-download"
-+#define GAIM_STOCK_EDIT "gaim2-edit"
-+#define GAIM_STOCK_FGCOLOR "gaim2-fgcolor"
-+#define GAIM_STOCK_FILE_CANCELED "gaim2-file-canceled"
-+#define GAIM_STOCK_FILE_DONE "gaim2-file-done"
-+#define GAIM_STOCK_FILE_TRANSFER "gaim2-file-transfer"
-+#define GAIM_STOCK_ICON_AWAY "gaim2-icon-away"
-+#define GAIM_STOCK_ICON_AWAY_MSG "gaim2-icon-away-msg"
-+#define GAIM_STOCK_ICON_CONNECT "gaim2-icon-away-connect"
-+#define GAIM_STOCK_ICON_OFFLINE "gaim2-icon-offline"
-+#define GAIM_STOCK_ICON_ONLINE "gaim2-icon-online"
-+#define GAIM_STOCK_ICON_ONLINE_MSG "gaim2-icon-online-msg"
-+#define GAIM_STOCK_IGNORE "gaim2-ignore"
-+#define GAIM_STOCK_IM "gaim2-im"
-+#define GAIM_STOCK_IMAGE "gaim2-image"
-+#define GAIM_STOCK_INFO "gaim2-info"
-+#define GAIM_STOCK_INVITE "gaim2-invite"
-+#define GAIM_STOCK_LINK "gaim2-link"
-+#define GAIM_STOCK_LOG "gaim2-log"
-+#define GAIM_STOCK_LOGO "gaim2-logo"
-+#define GAIM_STOCK_MODIFY "gaim2-modify"
-+#define GAIM_STOCK_OPEN_MAIL "gaim2-stock-open-mail"
-+#define GAIM_STOCK_PAUSE "gaim2-pause"
-+#define GAIM_STOCK_PENDING "gaim2-pending"
-+#define GAIM_STOCK_PLUGIN "gaim2-plugin"
-+#define GAIM_STOCK_POUNCE "gaim2-pounce"
-+#define GAIM_STOCK_SEND "gaim2-send"
-+#define GAIM_STOCK_SIGN_OFF "gaim2-sign-off"
-+#define GAIM_STOCK_SIGN_ON "gaim2-sign-on"
-+#define GAIM_STOCK_SMILEY "gaim2-smiley"
-+#define GAIM_STOCK_STATUS_ONLINE "gaim2-status-online"
-+#define GAIM_STOCK_STATUS_AWAY "gaim2-status-away"
-+#define GAIM_STOCK_STATUS_INVISIBLE "gaim2-status-invisible"
-+#define GAIM_STOCK_STATUS_OFFLINE "gaim2-status-offline"
-+#define GAIM_STOCK_STATUS_TYPING0 "gaim2-status-typing0"
-+#define GAIM_STOCK_STATUS_TYPING1 "gaim2-status-typing1"
-+#define GAIM_STOCK_STATUS_TYPING2 "gaim2-status-typing2"
-+#define GAIM_STOCK_STATUS_TYPING3 "gaim2-status-typing3"
-+#define GAIM_STOCK_STATUS_CONNECT0 "gaim2-status-connect0"
-+#define GAIM_STOCK_STATUS_CONNECT1 "gaim2-status-connect1"
-+#define GAIM_STOCK_STATUS_CONNECT2 "gaim2-status-connect2"
-+#define GAIM_STOCK_STATUS_CONNECT3 "gaim2-status-connect3"
-+#define GAIM_STOCK_TEXT_BIGGER "gaim2-text-bigger"
-+#define GAIM_STOCK_TEXT_NORMAL "gaim2-text-normal"
-+#define GAIM_STOCK_TEXT_SMALLER "gaim2-text-smaller"
-+#define GAIM_STOCK_TYPED "gaim2-typed"
-+#define GAIM_STOCK_TYPING "gaim2-typing"
-+#define GAIM_STOCK_UPLOAD "gaim2-upload"
-+#define GAIM_STOCK_VOICE_CHAT "gaim2-voice-chat"
-+#define GAIM_STOCK_WARN "gaim2-warn"
- /*@}*/
-
- /**
- * For using icons that aren't one of the default GTK_ICON_SIZEs
- */
--#define GAIM_ICON_SIZE_DIALOG_COOL "gaim-icon-size-dialog-cool"
--#define GAIM_ICON_SIZE_LOGO "gaim-icon-size-logo"
--#define GAIM_ICON_SIZE_STATUS "gaim-icon-size-status"
--#define GAIM_ICON_SIZE_STATUS_TWO_LINE "gaim-icon-size-status-two-line"
--#define GAIM_ICON_SIZE_STATUS_SMALL "gaim-icon-size-status-small"
--#define GAIM_ICON_SIZE_STATUS_SMALL_TWO_LINE "gaim-icon-size-status-small-two-line"
-+#define GAIM_ICON_SIZE_DIALOG_COOL "gaim2-icon-size-dialog-cool"
-+#define GAIM_ICON_SIZE_LOGO "gaim2-icon-size-logo"
-+#define GAIM_ICON_SIZE_STATUS "gaim2-icon-size-status"
-+#define GAIM_ICON_SIZE_STATUS_TWO_LINE "gaim2-icon-size-status-two-line"
-+#define GAIM_ICON_SIZE_STATUS_SMALL "gaim2-icon-size-status-small"
-+#define GAIM_ICON_SIZE_STATUS_SMALL_TWO_LINE "gaim2-icon-size-status-small-two-line"
-
- /**
-- * Sets up the gaim stock repository.
-+ * Sets up the gaim2 stock repository.
- */
--void gaim_gtk_stock_init(void);
-+void gaim2_gtk_stock_init(void);
-
- #endif /* _GAIM_STOCK_H_ */
-diff -prNu ./src/gtkthemes.c ./src/gtkthemes.c
---- ./src/gtkthemes.c 2005-09-20 23:47:57.000000000 +0200
-+++ ./src/gtkthemes.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * Themes for Gaim
-+ * Themes for Gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -21,7 +21,7 @@
- *
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "conversation.h"
- #include "debug.h"
-@@ -36,7 +36,7 @@
- GSList *smiley_themes = NULL;
- struct smiley_theme *current_smiley_theme;
-
--gboolean gaim_gtkthemes_smileys_disabled()
-+gboolean gaim2_gtkthemes_smileys_disabled()
- {
- if (!current_smiley_theme)
- return 1;
-@@ -44,7 +44,7 @@ gboolean gaim_gtkthemes_smileys_disabled
- return strcmp(current_smiley_theme->name, "none") == 0;
- }
-
--void gaim_gtkthemes_smiley_themeize(GtkWidget *imhtml)
-+void gaim2_gtkthemes_smiley_themeize(GtkWidget *imhtml)
- {
- struct smiley_list *list;
- if (!current_smiley_theme)
-@@ -63,7 +63,7 @@ void gaim_gtkthemes_smiley_themeize(GtkW
- }
- }
-
--void gaim_gtkthemes_load_smiley_theme(const char *file, gboolean load)
-+void gaim2_gtkthemes_load_smiley_theme(const char *file, gboolean load)
- {
- FILE *f = g_fopen(file, "r");
- char buf[256];
-@@ -195,12 +195,12 @@ void gaim_gtkthemes_load_smiley_theme(co
- if (load) {
- GList *cnv;
-
-- for (cnv = gaim_get_conversations(); cnv != NULL; cnv = cnv->next) {
-- GaimConversation *conv = cnv->data;
-+ for (cnv = gaim2_get_conversations(); cnv != NULL; cnv = cnv->next) {
-+ Gaim2Conversation *conv = cnv->data;
-
- if (GAIM_IS_GTK_CONVERSATION(conv)) {
-- gaim_gtkthemes_smiley_themeize(GAIM_GTK_CONVERSATION(conv)->imhtml);
-- gaim_gtkthemes_smiley_themeize(GAIM_GTK_CONVERSATION(conv)->entry);
-+ gaim2_gtkthemes_smiley_themeize(GAIM_GTK_CONVERSATION(conv)->imhtml);
-+ gaim2_gtkthemes_smiley_themeize(GAIM_GTK_CONVERSATION(conv)->entry);
- }
- }
- }
-@@ -209,7 +209,7 @@ void gaim_gtkthemes_load_smiley_theme(co
- fclose(f);
- }
-
--void gaim_gtkthemes_smiley_theme_probe()
-+void gaim2_gtkthemes_smiley_theme_probe()
- {
- GDir *dir;
- const gchar *file;
-@@ -217,8 +217,8 @@ void gaim_gtkthemes_smiley_theme_probe()
- int l;
-
- char* probedirs[3];
-- probedirs[0] = g_build_filename(DATADIR, "pixmaps", "gaim", "smileys", NULL);
-- probedirs[1] = g_build_filename(gaim_user_dir(), "smileys", NULL);
-+ probedirs[0] = g_build_filename(DATADIR, "pixmaps", "gaim2", "smileys", NULL);
-+ probedirs[1] = g_build_filename(gaim2_user_dir(), "smileys", NULL);
- probedirs[2] = 0;
- for (l=0; probedirs[l]; l++) {
- dir = g_dir_open(probedirs[l], 0, NULL);
-@@ -230,7 +230,7 @@ void gaim_gtkthemes_smiley_theme_probe()
- * We set the second argument to FALSE so that it doesn't load
- * the theme yet.
- */
-- gaim_gtkthemes_load_smiley_theme(path, FALSE);
-+ gaim2_gtkthemes_load_smiley_theme(path, FALSE);
- g_free(path);
- }
- g_dir_close(dir);
-@@ -241,8 +241,8 @@ void gaim_gtkthemes_smiley_theme_probe()
- }
- }
-
--GSList *gaim_gtkthemes_get_proto_smileys(const char *id) {
-- GaimPlugin *proto;
-+GSList *gaim2_gtkthemes_get_proto_smileys(const char *id) {
-+ Gaim2Plugin *proto;
- struct smiley_list *list, *def;
-
- if ((current_smiley_theme == NULL) || (current_smiley_theme->list == NULL))
-@@ -253,7 +253,7 @@ GSList *gaim_gtkthemes_get_proto_smileys
- if (id == NULL)
- return def->smileys;
-
-- proto = gaim_find_prpl(id);
-+ proto = gaim2_find_prpl(id);
-
- while (list) {
- if (!strcmp(list->sml, "default"))
-@@ -267,18 +267,18 @@ GSList *gaim_gtkthemes_get_proto_smileys
- return list ? list->smileys : def->smileys;
- }
-
--void gaim_gtkthemes_init()
-+void gaim2_gtkthemes_init()
- {
- GSList *l;
- const char *current_theme =
-- gaim_prefs_get_string("/gaim/gtk/smileys/theme");
-+ gaim2_prefs_get_string("/gaim2/gtk/smileys/theme");
-
-- gaim_gtkthemes_smiley_theme_probe();
-+ gaim2_gtkthemes_smiley_theme_probe();
-
- for (l = smiley_themes; l; l = l->next) {
- struct smiley_theme *smile = l->data;
- if (smile->name && strcmp(current_theme, smile->name) == 0) {
-- gaim_gtkthemes_load_smiley_theme(smile->path, TRUE);
-+ gaim2_gtkthemes_load_smiley_theme(smile->path, TRUE);
- break;
- }
- }
-@@ -286,7 +286,7 @@ void gaim_gtkthemes_init()
- /* If we still don't have a smiley theme, choose the first one */
- if (!current_smiley_theme && smiley_themes) {
- struct smiley_theme *smile = smiley_themes->data;
-- gaim_gtkthemes_load_smiley_theme(smile->path, TRUE);
-+ gaim2_gtkthemes_load_smiley_theme(smile->path, TRUE);
- }
-
- }
-diff -prNu ./src/gtkthemes.h ./src/gtkthemes.h
---- ./src/gtkthemes.h 2005-12-16 10:02:17.000000000 +0100
-+++ ./src/gtkthemes.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkthemes.h GTK+ Smiley Theme API
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -44,10 +44,10 @@ struct smiley_theme {
- extern struct smiley_theme *current_smiley_theme;
- extern GSList *smiley_themes;
-
--void gaim_gtkthemes_init(void);
--gboolean gaim_gtkthemes_smileys_disabled(void);
--void gaim_gtkthemes_smiley_themeize(GtkWidget *);
--void gaim_gtkthemes_smiley_theme_probe(void);
--void gaim_gtkthemes_load_smiley_theme(const char *file, gboolean load);
--GSList *gaim_gtkthemes_get_proto_smileys(const char *id);
-+void gaim2_gtkthemes_init(void);
-+gboolean gaim2_gtkthemes_smileys_disabled(void);
-+void gaim2_gtkthemes_smiley_themeize(GtkWidget *);
-+void gaim2_gtkthemes_smiley_theme_probe(void);
-+void gaim2_gtkthemes_load_smiley_theme(const char *file, gboolean load);
-+GSList *gaim2_gtkthemes_get_proto_smileys(const char *id);
- #endif /* _GAIM_GTKDIALOGS_H_ */
-diff -prNu ./src/gtkutils.c ./src/gtkutils.c
---- ./src/gtkutils.c 2005-12-25 02:36:31.000000000 +0100
-+++ ./src/gtkutils.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkutils.h GTK+ utility functions
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #ifndef _WIN32
- # include <X11/Xlib.h>
-@@ -65,7 +65,7 @@ static guint accels_save_timer = 0;
- static gboolean
- url_clicked_idle_cb(gpointer data)
- {
-- gaim_notify_uri(NULL, data);
-+ gaim2_notify_uri(NULL, data);
- g_free(data);
- return FALSE;
- }
-@@ -77,16 +77,16 @@ url_clicked_cb(GtkWidget *w, const char
- }
-
- static GtkIMHtmlFuncs gtkimhtml_cbs = {
-- (GtkIMHtmlGetImageFunc)gaim_imgstore_get,
-- (GtkIMHtmlGetImageDataFunc)gaim_imgstore_get_data,
-- (GtkIMHtmlGetImageSizeFunc)gaim_imgstore_get_size,
-- (GtkIMHtmlGetImageFilenameFunc)gaim_imgstore_get_filename,
-- gaim_imgstore_ref,
-- gaim_imgstore_unref,
-+ (GtkIMHtmlGetImageFunc)gaim2_imgstore_get,
-+ (GtkIMHtmlGetImageDataFunc)gaim2_imgstore_get_data,
-+ (GtkIMHtmlGetImageSizeFunc)gaim2_imgstore_get_size,
-+ (GtkIMHtmlGetImageFilenameFunc)gaim2_imgstore_get_filename,
-+ gaim2_imgstore_ref,
-+ gaim2_imgstore_unref,
- };
-
- void
--gaim_setup_imhtml(GtkWidget *imhtml)
-+gaim2_setup_imhtml(GtkWidget *imhtml)
- {
- g_return_if_fail(imhtml != NULL);
- g_return_if_fail(GTK_IS_IMHTML(imhtml));
-@@ -94,13 +94,13 @@ gaim_setup_imhtml(GtkWidget *imhtml)
- g_signal_connect(G_OBJECT(imhtml), "url_clicked",
- G_CALLBACK(url_clicked_cb), NULL);
-
-- gaim_gtkthemes_smiley_themeize(imhtml);
-+ gaim2_gtkthemes_smiley_themeize(imhtml);
-
- gtk_imhtml_set_funcs(GTK_IMHTML(imhtml), &gtkimhtml_cbs);
- }
-
- GtkWidget *
--gaim_gtk_create_imhtml(gboolean editable, GtkWidget **imhtml_ret, GtkWidget **toolbar_ret)
-+gaim2_gtk_create_imhtml(gboolean editable, GtkWidget **imhtml_ret, GtkWidget **toolbar_ret)
- {
- GtkWidget *frame;
- GtkWidget *imhtml;
-@@ -147,8 +147,8 @@ gaim_gtk_create_imhtml(gboolean editable
- gtk_imhtml_set_format_functions(GTK_IMHTML(imhtml), GTK_IMHTML_ALL ^ GTK_IMHTML_IMAGE);
- gtk_text_view_set_wrap_mode(GTK_TEXT_VIEW(imhtml), GTK_WRAP_WORD_CHAR);
- #ifdef USE_GTKSPELL
-- if (editable && gaim_prefs_get_bool("/gaim/gtk/conversations/spellcheck"))
-- gaim_gtk_setup_gtkspell(GTK_TEXT_VIEW(imhtml));
-+ if (editable && gaim2_prefs_get_bool("/gaim2/gtk/conversations/spellcheck"))
-+ gaim2_gtk_setup_gtkspell(GTK_TEXT_VIEW(imhtml));
- #endif
- gtk_widget_show(imhtml);
-
-@@ -156,7 +156,7 @@ gaim_gtk_create_imhtml(gboolean editable
- gtk_imhtmltoolbar_attach(GTK_IMHTMLTOOLBAR(toolbar), imhtml);
- gtk_imhtmltoolbar_associate_smileys(GTK_IMHTMLTOOLBAR(toolbar), "default");
- }
-- gaim_setup_imhtml(imhtml);
-+ gaim2_setup_imhtml(imhtml);
-
- gtk_container_add(GTK_CONTAINER(sw), imhtml);
-
-@@ -170,7 +170,7 @@ gaim_gtk_create_imhtml(gboolean editable
- }
-
- void
--gaim_gtk_set_sensitive_if_input(GtkWidget *entry, GtkWidget *dialog)
-+gaim2_gtk_set_sensitive_if_input(GtkWidget *entry, GtkWidget *dialog)
- {
- const char *text = gtk_entry_get_text(GTK_ENTRY(entry));
- gtk_dialog_set_response_sensitive(GTK_DIALOG(dialog), GTK_RESPONSE_OK,
-@@ -178,7 +178,7 @@ gaim_gtk_set_sensitive_if_input(GtkWidge
- }
-
- void
--gaim_gtk_toggle_sensitive(GtkWidget *widget, GtkWidget *to_toggle)
-+gaim2_gtk_toggle_sensitive(GtkWidget *widget, GtkWidget *to_toggle)
- {
- gboolean sensitivity;
-
-@@ -191,7 +191,7 @@ gaim_gtk_toggle_sensitive(GtkWidget *wid
- }
-
- void
--gaim_gtk_toggle_sensitive_array(GtkWidget *w, GPtrArray *data)
-+gaim2_gtk_toggle_sensitive_array(GtkWidget *w, GPtrArray *data)
- {
- gboolean sensitivity;
- gpointer element;
-@@ -209,7 +209,7 @@ gaim_gtk_toggle_sensitive_array(GtkWidge
- }
-
- void
--gaim_gtk_toggle_showhide(GtkWidget *widget, GtkWidget *to_toggle)
-+gaim2_gtk_toggle_showhide(GtkWidget *widget, GtkWidget *to_toggle)
- {
- if (to_toggle == NULL)
- return;
-@@ -220,7 +220,7 @@ gaim_gtk_toggle_showhide(GtkWidget *widg
- gtk_widget_show(to_toggle);
- }
-
--void gaim_separator(GtkWidget *menu)
-+void gaim2_separator(GtkWidget *menu)
- {
- GtkWidget *menuitem;
-
-@@ -229,7 +229,7 @@ void gaim_separator(GtkWidget *menu)
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
- }
-
--GtkWidget *gaim_new_item(GtkWidget *menu, const char *str)
-+GtkWidget *gaim2_new_item(GtkWidget *menu, const char *str)
- {
- GtkWidget *menuitem;
- GtkWidget *label;
-@@ -248,11 +248,11 @@ GtkWidget *gaim_new_item(GtkWidget *menu
- gtk_widget_add_accelerator(menuitem, "activate", accel, str[0],
- GDK_MOD1_MASK, GTK_ACCEL_LOCKED);
- */
-- gaim_set_accessible_label (menuitem, label);
-+ gaim2_set_accessible_label (menuitem, label);
- return menuitem;
- }
-
--GtkWidget *gaim_new_check_item(GtkWidget *menu, const char *str,
-+GtkWidget *gaim2_new_check_item(GtkWidget *menu, const char *str,
- GtkSignalFunc sf, gpointer data, gboolean checked)
- {
- GtkWidget *menuitem;
-@@ -272,7 +272,7 @@ GtkWidget *gaim_new_check_item(GtkWidget
- }
-
- GtkWidget *
--gaim_pixbuf_toolbar_button_from_stock(const char *icon)
-+gaim2_pixbuf_toolbar_button_from_stock(const char *icon)
- {
- GtkWidget *button, *image, *bbox;
-
-@@ -292,8 +292,8 @@ gaim_pixbuf_toolbar_button_from_stock(co
- }
-
- GtkWidget *
--gaim_pixbuf_button_from_stock(const char *text, const char *icon,
-- GaimButtonOrientation style)
-+gaim2_pixbuf_button_from_stock(const char *text, const char *icon,
-+ Gaim2ButtonOrientation style)
- {
- GtkWidget *button, *image, *label, *bbox, *ibox, *lbox = NULL;
-
-@@ -325,7 +325,7 @@ gaim_pixbuf_button_from_stock(const char
- gtk_label_set_text_with_mnemonic(GTK_LABEL(label), text);
- gtk_label_set_mnemonic_widget(GTK_LABEL(label), button);
- gtk_box_pack_start(GTK_BOX(lbox), label, FALSE, TRUE, 0);
-- gaim_set_accessible_label (button, label);
-+ gaim2_set_accessible_label (button, label);
- }
-
- gtk_widget_show_all(bbox);
-@@ -334,7 +334,7 @@ gaim_pixbuf_button_from_stock(const char
- }
-
-
--GtkWidget *gaim_new_item_from_stock(GtkWidget *menu, const char *str, const char *icon, GtkSignalFunc sf, gpointer data, guint accel_key, guint accel_mods, char *mod)
-+GtkWidget *gaim2_new_item_from_stock(GtkWidget *menu, const char *str, const char *icon, GtkSignalFunc sf, gpointer data, guint accel_key, guint accel_mods, char *mod)
- {
- GtkWidget *menuitem;
- /*
-@@ -378,7 +378,7 @@ GtkWidget *gaim_new_item_from_stock(GtkW
- }
-
- GtkWidget *
--gaim_gtk_make_frame(GtkWidget *parent, const char *title)
-+gaim2_gtk_make_frame(GtkWidget *parent, const char *title)
- {
- GtkWidget *vbox, *label, *hbox;
- char labeltitle[256];
-@@ -395,7 +395,7 @@ gaim_gtk_make_frame(GtkWidget *parent, c
- gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
- gtk_box_pack_start(GTK_BOX(vbox), label, FALSE, FALSE, 0);
- gtk_widget_show(label);
-- gaim_set_accessible_label (vbox, label);
-+ gaim2_set_accessible_label (vbox, label);
-
- hbox = gtk_hbox_new(FALSE, GAIM_HIG_BOX_SPACE);
- gtk_box_pack_start (GTK_BOX (vbox), hbox, FALSE, FALSE, 0);
-@@ -432,11 +432,11 @@ protocol_menu_cb(GtkWidget *optmenu, GCa
- }
-
- GtkWidget *
--gaim_gtk_protocol_option_menu_new(const char *id, GCallback cb,
-+gaim2_gtk_protocol_option_menu_new(const char *id, GCallback cb,
- gpointer user_data)
- {
-- GaimPluginProtocolInfo *prpl_info;
-- GaimPlugin *plugin;
-+ Gaim2PluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *plugin;
- GtkWidget *hbox;
- GtkWidget *label;
- GtkWidget *optmenu;
-@@ -462,11 +462,11 @@ gaim_gtk_protocol_option_menu_new(const
-
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
-- for (p = gaim_plugins_get_protocols(), i = 0;
-+ for (p = gaim2_plugins_get_protocols(), i = 0;
- p != NULL;
- p = p->next, i++) {
-
-- plugin = (GaimPlugin *)p->data;
-+ plugin = (Gaim2Plugin *)p->data;
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(plugin);
-
- /* Create the item. */
-@@ -481,7 +481,7 @@ gaim_gtk_protocol_option_menu_new(const
- proto_name = prpl_info->list_icon(NULL, NULL);
- g_snprintf(buf, sizeof(buf), "%s.png", proto_name);
-
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status",
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status",
- "default", buf, NULL);
- pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-@@ -514,7 +514,7 @@ gaim_gtk_protocol_option_menu_new(const
-
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), item);
- gtk_widget_show(item);
-- gaim_set_accessible_label (item, label);
-+ gaim2_set_accessible_label (item, label);
-
- if (id != NULL && !strcmp(plugin->info->id, id))
- selected_index = i;
-@@ -533,8 +533,8 @@ gaim_gtk_protocol_option_menu_new(const
- return optmenu;
- }
-
--GaimAccount *
--gaim_gtk_account_option_menu_get_selected(GtkWidget *optmenu)
-+Gaim2Account *
-+gaim2_gtk_account_option_menu_get_selected(GtkWidget *optmenu)
- {
- GtkWidget *menu = gtk_option_menu_get_menu(GTK_OPTION_MENU(optmenu));
- GtkWidget *item = gtk_menu_get_active(GTK_MENU(menu));
-@@ -546,7 +546,7 @@ account_menu_cb(GtkWidget *optmenu, GCal
- {
- GtkWidget *menu;
- GtkWidget *item;
-- GaimAccount *account;
-+ Gaim2Account *account;
- gpointer user_data;
-
- menu = gtk_option_menu_get_menu(GTK_OPTION_MENU(optmenu));
-@@ -556,15 +556,15 @@ account_menu_cb(GtkWidget *optmenu, GCal
- user_data = g_object_get_data(G_OBJECT(optmenu), "user_data");
-
- if (cb != NULL)
-- ((void (*)(GtkWidget *, GaimAccount *, gpointer))cb)(item, account,
-+ ((void (*)(GtkWidget *, Gaim2Account *, gpointer))cb)(item, account,
- user_data);
- }
-
- static void
--create_account_menu(GtkWidget *optmenu, GaimAccount *default_account,
-- GaimFilterAccountFunc filter_func, gboolean show_all)
-+create_account_menu(GtkWidget *optmenu, Gaim2Account *default_account,
-+ Gaim2FilterAccountFunc filter_func, gboolean show_all)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GtkWidget *menu;
- GtkWidget *item;
- GtkWidget *image;
-@@ -581,9 +581,9 @@ create_account_menu(GtkWidget *optmenu,
- int i, selected_index = -1;
-
- if (show_all)
-- list = gaim_accounts_get_all();
-+ list = gaim2_accounts_get_all();
- else
-- list = gaim_connections_get_all();
-+ list = gaim2_connections_get_all();
-
- menu = gtk_menu_new();
- gtk_widget_show(menu);
-@@ -591,15 +591,15 @@ create_account_menu(GtkWidget *optmenu,
- sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
-
- for (p = list, i = 0; p != NULL; p = p->next, i++) {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimPlugin *plugin;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Plugin *plugin;
-
- if (show_all)
-- account = (GaimAccount *)p->data;
-+ account = (Gaim2Account *)p->data;
- else {
-- GaimConnection *gc = (GaimConnection *)p->data;
-+ Gaim2Connection *gc = (Gaim2Connection *)p->data;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- }
-
- if (filter_func && !filter_func(account)) {
-@@ -607,7 +607,7 @@ create_account_menu(GtkWidget *optmenu,
- continue;
- }
-
-- plugin = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ plugin = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- if (plugin != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(plugin);
-@@ -625,7 +625,7 @@ create_account_menu(GtkWidget *optmenu,
- proto_name = prpl_info->list_icon(account, NULL);
- g_snprintf(buf, sizeof(buf), "%s.png", proto_name);
-
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status",
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status",
- "default", buf, NULL);
- pixbuf = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-@@ -635,8 +635,8 @@ create_account_menu(GtkWidget *optmenu,
- scale = gdk_pixbuf_scale_simple(pixbuf, 16, 16,
- GDK_INTERP_BILINEAR);
-
-- if (gaim_account_is_disconnected(account) && show_all &&
-- gaim_connections_get_all())
-+ if (gaim2_account_is_disconnected(account) && show_all &&
-+ gaim2_connections_get_all())
- gdk_pixbuf_saturate_and_pixelate(scale, scale, 0.0, FALSE);
-
- image = gtk_image_new_from_pixbuf(scale);
-@@ -655,15 +655,15 @@ create_account_menu(GtkWidget *optmenu,
- gtk_box_pack_start(GTK_BOX(hbox), image, FALSE, FALSE, 0);
- gtk_widget_show(image);
-
-- if (gaim_account_get_alias(account)) {
-+ if (gaim2_account_get_alias(account)) {
- g_snprintf(buf, sizeof(buf), "%s (%s) (%s)",
-- gaim_account_get_username(account),
-- gaim_account_get_alias(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_alias(account),
-+ gaim2_account_get_protocol_name(account));
- } else {
- g_snprintf(buf, sizeof(buf), "%s (%s)",
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
- }
-
- /* Create the label. */
-@@ -677,7 +677,7 @@ create_account_menu(GtkWidget *optmenu,
-
- gtk_menu_shell_append(GTK_MENU_SHELL(menu), item);
- gtk_widget_show(item);
-- gaim_set_accessible_label (item, label);
-+ gaim2_set_accessible_label (item, label);
-
- if (default_account != NULL && account == default_account)
- selected_index = i;
-@@ -698,8 +698,8 @@ regenerate_account_menu(GtkWidget *optme
- GtkWidget *menu;
- GtkWidget *item;
- gboolean show_all;
-- GaimAccount *account;
-- GaimFilterAccountFunc filter_func;
-+ Gaim2Account *account;
-+ Gaim2FilterAccountFunc filter_func;
-
- menu = gtk_option_menu_get_menu(GTK_OPTION_MENU(optmenu));
- item = gtk_menu_get_active(GTK_MENU(menu));
-@@ -717,13 +717,13 @@ regenerate_account_menu(GtkWidget *optme
- }
-
- static void
--account_menu_sign_on_off_cb(GaimConnection *gc, GtkWidget *optmenu)
-+account_menu_sign_on_off_cb(Gaim2Connection *gc, GtkWidget *optmenu)
- {
- regenerate_account_menu(optmenu);
- }
-
- static void
--account_menu_added_removed_cb(GaimAccount *account, GtkWidget *optmenu)
-+account_menu_added_removed_cb(Gaim2Account *account, GtkWidget *optmenu)
- {
- regenerate_account_menu(optmenu);
- }
-@@ -732,19 +732,19 @@ static gboolean
- account_menu_destroyed_cb(GtkWidget *optmenu, GdkEvent *event,
- void *user_data)
- {
-- gaim_signals_disconnect_by_handle(optmenu);
-+ gaim2_signals_disconnect_by_handle(optmenu);
-
- return FALSE;
- }
-
- void
--gaim_gtk_account_option_menu_set_selected(GtkWidget *optmenu, GaimAccount *account)
-+gaim2_gtk_account_option_menu_set_selected(GtkWidget *optmenu, Gaim2Account *account)
- {
- GtkWidget *menu;
- GtkWidget *item;
- gboolean show_all;
-- GaimAccount *curaccount;
-- GaimFilterAccountFunc filter_func;
-+ Gaim2Account *curaccount;
-+ Gaim2FilterAccountFunc filter_func;
-
- menu = gtk_option_menu_get_menu(GTK_OPTION_MENU(optmenu));
- item = gtk_menu_get_active(GTK_MENU(menu));
-@@ -765,9 +765,9 @@ gaim_gtk_account_option_menu_set_selecte
- }
-
- GtkWidget *
--gaim_gtk_account_option_menu_new(GaimAccount *default_account,
-+gaim2_gtk_account_option_menu_new(Gaim2Account *default_account,
- gboolean show_all, GCallback cb,
-- GaimFilterAccountFunc filter_func,
-+ Gaim2FilterAccountFunc filter_func,
- gpointer user_data)
- {
- GtkWidget *optmenu;
-@@ -779,17 +779,17 @@ gaim_gtk_account_option_menu_new(GaimAcc
- g_signal_connect(G_OBJECT(optmenu), "destroy",
- G_CALLBACK(account_menu_destroyed_cb), NULL);
-
-- /* Register the gaim sign on/off event callbacks. */
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-on",
-+ /* Register the gaim2 sign on/off event callbacks. */
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-on",
- optmenu, GAIM_CALLBACK(account_menu_sign_on_off_cb),
- optmenu);
-- gaim_signal_connect(gaim_connections_get_handle(), "signed-off",
-+ gaim2_signal_connect(gaim2_connections_get_handle(), "signed-off",
- optmenu, GAIM_CALLBACK(account_menu_sign_on_off_cb),
- optmenu);
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-added",
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-added",
- optmenu, GAIM_CALLBACK(account_menu_added_removed_cb),
- optmenu);
-- gaim_signal_connect(gaim_accounts_get_handle(), "account-removed",
-+ gaim2_signal_connect(gaim2_accounts_get_handle(), "account-removed",
- optmenu, GAIM_CALLBACK(account_menu_added_removed_cb),
- optmenu);
-
-@@ -810,7 +810,7 @@ gaim_gtk_account_option_menu_new(GaimAcc
- }
-
- gboolean
--gaim_gtk_check_if_dir(const char *path, GtkFileSelection *filesel)
-+gaim2_gtk_check_if_dir(const char *path, GtkFileSelection *filesel)
- {
- char *dirname;
-
-@@ -830,7 +830,7 @@ gaim_gtk_check_if_dir(const char *path,
- }
-
- void
--gaim_gtk_setup_gtkspell(GtkTextView *textview)
-+gaim2_gtk_setup_gtkspell(GtkTextView *textview)
- {
- #ifdef USE_GTKSPELL
- GError *error = NULL;
-@@ -841,7 +841,7 @@ gaim_gtk_setup_gtkspell(GtkTextView *tex
-
- if (gtkspell_new_attach(textview, locale, &error) == NULL && error)
- {
-- gaim_debug_warning("gtkspell", "Failed to setup GtkSpell: %s\n",
-+ gaim2_debug_warning("gtkspell", "Failed to setup GtkSpell: %s\n",
- error->message);
- g_error_free(error);
- }
-@@ -849,24 +849,24 @@ gaim_gtk_setup_gtkspell(GtkTextView *tex
- }
-
- void
--gaim_gtk_save_accels_cb(GtkAccelGroup *accel_group, guint arg1,
-+gaim2_gtk_save_accels_cb(GtkAccelGroup *accel_group, guint arg1,
- GdkModifierType arg2, GClosure *arg3,
- gpointer data)
- {
-- gaim_debug(GAIM_DEBUG_MISC, "accels", "accel changed, scheduling save.\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "accels", "accel changed, scheduling save.\n");
-
- if (!accels_save_timer)
-- accels_save_timer = g_timeout_add(5000, gaim_gtk_save_accels, NULL);
-+ accels_save_timer = g_timeout_add(5000, gaim2_gtk_save_accels, NULL);
- }
-
- gboolean
--gaim_gtk_save_accels(gpointer data)
-+gaim2_gtk_save_accels(gpointer data)
- {
- char *filename = NULL;
-
-- filename = g_build_filename(gaim_user_dir(), G_DIR_SEPARATOR_S,
-+ filename = g_build_filename(gaim2_user_dir(), G_DIR_SEPARATOR_S,
- "accels", NULL);
-- gaim_debug(GAIM_DEBUG_MISC, "accels", "saving accels to %s\n", filename);
-+ gaim2_debug(GAIM_DEBUG_MISC, "accels", "saving accels to %s\n", filename);
- gtk_accel_map_save(filename);
- g_free(filename);
-
-@@ -875,19 +875,19 @@ gaim_gtk_save_accels(gpointer data)
- }
-
- void
--gaim_gtk_load_accels()
-+gaim2_gtk_load_accels()
- {
- char *filename = NULL;
-
-- filename = g_build_filename(gaim_user_dir(), G_DIR_SEPARATOR_S,
-+ filename = g_build_filename(gaim2_user_dir(), G_DIR_SEPARATOR_S,
- "accels", NULL);
- gtk_accel_map_load(filename);
- g_free(filename);
- }
-
- gboolean
--gaim_gtk_parse_x_im_contact(const char *msg, gboolean all_accounts,
-- GaimAccount **ret_account, char **ret_protocol,
-+gaim2_gtk_parse_x_im_contact(const char *msg, gboolean all_accounts,
-+ Gaim2Account **ret_account, char **ret_protocol,
- char **ret_username, char **ret_alias)
- {
- char *protocol = NULL;
-@@ -961,27 +961,27 @@ gaim_gtk_parse_x_im_contact(const char *
- if (ret_account != NULL)
- {
- GList *list;
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- GList *l;
- const char *protoname;
-
- if (all_accounts)
-- list = gaim_accounts_get_all();
-+ list = gaim2_accounts_get_all();
- else
-- list = gaim_connections_get_all();
-+ list = gaim2_connections_get_all();
-
- for (l = list; l != NULL; l = l->next)
- {
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimPlugin *plugin;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Plugin *plugin;
-
- if (all_accounts)
- {
-- account = (GaimAccount *)l->data;
-+ account = (Gaim2Account *)l->data;
-
-- plugin = gaim_plugins_find_with_id(
-- gaim_account_get_protocol_id(account));
-+ plugin = gaim2_plugins_find_with_id(
-+ gaim2_account_get_protocol_id(account));
-
- if (plugin == NULL)
- {
-@@ -994,8 +994,8 @@ gaim_gtk_parse_x_im_contact(const char *
- }
- else
- {
-- gc = (GaimConnection *)l->data;
-- account = gaim_connection_get_account(gc);
-+ gc = (Gaim2Connection *)l->data;
-+ account = gaim2_connection_get_account(gc);
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
- }
-@@ -1014,16 +1014,16 @@ gaim_gtk_parse_x_im_contact(const char *
- {
- for (l = list; l != NULL; l = l->next)
- {
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimPlugin *plugin;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Plugin *plugin;
-
- if (all_accounts)
- {
-- account = (GaimAccount *)l->data;
-+ account = (Gaim2Account *)l->data;
-
-- plugin = gaim_plugins_find_with_id(
-- gaim_account_get_protocol_id(account));
-+ plugin = gaim2_plugins_find_with_id(
-+ gaim2_account_get_protocol_id(account));
-
- if (plugin == NULL)
- {
-@@ -1036,8 +1036,8 @@ gaim_gtk_parse_x_im_contact(const char *
- }
- else
- {
-- gc = (GaimConnection *)l->data;
-- account = gaim_connection_get_account(gc);
-+ gc = (Gaim2Connection *)l->data;
-+ account = gaim2_connection_get_account(gc);
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
- }
-@@ -1069,7 +1069,7 @@ gaim_gtk_parse_x_im_contact(const char *
- }
-
- void
--gaim_set_accessible_label (GtkWidget *w, GtkWidget *l)
-+gaim2_set_accessible_label (GtkWidget *w, GtkWidget *l)
- {
- AtkObject *acc, *label;
- AtkObject *rel_obj[1];
-@@ -1106,7 +1106,7 @@ gaim_set_accessible_label (GtkWidget *w,
-
- #if GTK_CHECK_VERSION(2,2,0)
- static void
--gaim_gtk_menu_position_func(GtkMenu *menu,
-+gaim2_gtk_menu_position_func(GtkMenu *menu,
- gint *x,
- gint *y,
- gboolean *push_in,
-@@ -1257,7 +1257,7 @@ gaim_gtk_menu_position_func(GtkMenu *men
- #endif
-
- void
--gaim_gtk_treeview_popup_menu_position_func(GtkMenu *menu,
-+gaim2_gtk_treeview_popup_menu_position_func(GtkMenu *menu,
- gint *x,
- gint *y,
- gboolean *push_in,
-@@ -1277,7 +1277,7 @@ gaim_gtk_treeview_popup_menu_position_fu
- *x += rect.x+rect.width;
- *y += rect.y+rect.height+ythickness;
- #if GTK_CHECK_VERSION(2,2,0)
-- gaim_gtk_menu_position_func (menu, x, y, push_in, data);
-+ gaim2_gtk_menu_position_func (menu, x, y, push_in, data);
- #endif
- }
-
-@@ -1289,7 +1289,7 @@ enum {
-
- typedef struct {
- char *filename;
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *who;
- } _DndData;
-
-@@ -1298,8 +1298,8 @@ static void dnd_image_ok_callback(_DndDa
- char *filedata;
- size_t size;
- GError *err = NULL;
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
- GtkTextIter iter;
- int id;
- switch (choice) {
-@@ -1309,7 +1309,7 @@ static void dnd_image_ok_callback(_DndDa
- char *str;
-
- str = g_strdup_printf(_("The following error has occurred loading %s: %s"), data->filename, err->message);
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("Failed to load image"),
- str);
-
-@@ -1319,14 +1319,14 @@ static void dnd_image_ok_callback(_DndDa
- return;
- }
-
-- gaim_buddy_icons_set_for_user(data->account, data->who, filedata, size);
-+ gaim2_buddy_icons_set_for_user(data->account, data->who, filedata, size);
- g_free(filedata);
- break;
- case DND_FILE_TRANSFER:
-- serv_send_file(gaim_account_get_connection(data->account), data->who, data->filename);
-+ serv_send_file(gaim2_account_get_connection(data->account), data->who, data->filename);
- break;
- case DND_IM_IMAGE:
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, data->account, data->who);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, data->account, data->who);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
-
- if (!g_file_get_contents(data->filename, &filedata, &size,
-@@ -1334,7 +1334,7 @@ static void dnd_image_ok_callback(_DndDa
- char *str;
-
- str = g_strdup_printf(_("The following error has occurred loading %s: %s"), data->filename, err->message);
-- gaim_notify_error(NULL, NULL,
-+ gaim2_notify_error(NULL, NULL,
- _("Failed to load image"),
- str);
-
-@@ -1343,13 +1343,13 @@ static void dnd_image_ok_callback(_DndDa
-
- return;
- }
-- id = gaim_imgstore_add(filedata, size, data->filename);
-+ id = gaim2_imgstore_add(filedata, size, data->filename);
- g_free(filedata);
-
- gtk_text_buffer_get_iter_at_mark(GTK_IMHTML(gtkconv->entry)->text_buffer, &iter,
- gtk_text_buffer_get_insert(GTK_IMHTML(gtkconv->entry)->text_buffer));
- gtk_imhtml_insert_image_at_iter(GTK_IMHTML(gtkconv->entry), id, &iter);
-- gaim_imgstore_unref(id);
-+ gaim2_imgstore_unref(id);
-
- break;
- }
-@@ -1378,16 +1378,16 @@ static void dnd_set_icon_cancel_cb(_DndD
- }
-
- void
--gaim_dnd_file_manage(GtkSelectionData *sd, GaimAccount *account, const char *who)
-+gaim2_dnd_file_manage(GtkSelectionData *sd, Gaim2Account *account, const char *who)
- {
- GList *tmp;
- GdkPixbuf *pb;
-- GList *files = gaim_uri_list_extract_filenames((const gchar *)sd->data);
-- GaimConnection *gc = gaim_account_get_connection(account);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ GList *files = gaim2_uri_list_extract_filenames((const gchar *)sd->data);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- gboolean file_send_ok = FALSE;
- #ifndef _WIN32
-- GaimDesktopItem *item;
-+ Gaim2DesktopItem *item;
- #endif
-
- g_return_if_fail(account != NULL);
-@@ -1411,8 +1411,8 @@ gaim_dnd_file_manage(GtkSelectionData *s
- char *str;
-
- str = g_strdup_printf(_("Cannot send folder %s."), basename);
-- gaim_notify_error(NULL, NULL,
-- str,_("Gaim cannot transfer a folder. You will need to send the files within individually"));
-+ gaim2_notify_error(NULL, NULL,
-+ str,_("Gaim2 cannot transfer a folder. You will need to send the files within individually"));
-
- g_free(str);
-
-@@ -1439,7 +1439,7 @@ gaim_dnd_file_manage(GtkSelectionData *s
- ft = prpl_info->can_receive_file(gc, who);
-
- if (im && ft)
-- gaim_request_choice(NULL, NULL,
-+ gaim2_request_choice(NULL, NULL,
- _("You have dragged an image"),
- _("You can send this image as a file transfer, "
- "embed it into this message, or use it as the buddy icon for this user."),
-@@ -1449,11 +1449,11 @@ gaim_dnd_file_manage(GtkSelectionData *s
- _("Send image file"), DND_FILE_TRANSFER,
- _("Insert in message"), DND_IM_IMAGE, NULL);
- else if (!(im || ft))
-- gaim_request_yes_no(NULL, NULL, _("You have dragged an image"),
-+ gaim2_request_yes_no(NULL, NULL, _("You have dragged an image"),
- _("Would you like to set it as the buddy icon for this user?"),
- 0, data, (GCallback)dnd_set_icon_ok_cb, (GCallback)dnd_set_icon_cancel_cb);
- else
-- gaim_request_choice(NULL, NULL,
-+ gaim2_request_choice(NULL, NULL,
- _("You have dragged an image"),
- ft ? _("You can send this image as a file transfer or "
- "embed it into this message, or use it as the buddy icon for this user.") :
-@@ -1467,8 +1467,8 @@ gaim_dnd_file_manage(GtkSelectionData *s
-
- #ifndef _WIN32
- /* Are we trying to send a .desktop file? */
-- else if (gaim_str_has_suffix(basename, ".desktop") && (item = gaim_desktop_item_new_from_file(filename))) {
-- GaimDesktopItemType dtype;
-+ else if (gaim2_str_has_suffix(basename, ".desktop") && (item = gaim2_desktop_item_new_from_file(filename))) {
-+ Gaim2DesktopItemType dtype;
- char key[64];
- const char *itemname = NULL;
-
-@@ -1478,7 +1478,7 @@ gaim_dnd_file_manage(GtkSelectionData *s
- langs = g_get_language_names();
- for (i = 0; langs[i]; i++) {
- g_snprintf(key, sizeof(key), "Name[%s]", langs[i]);
-- itemname = gaim_desktop_item_get_string(item, key);
-+ itemname = gaim2_desktop_item_get_string(item, key);
- break;
- }
- #else
-@@ -1488,22 +1488,22 @@ gaim_dnd_file_manage(GtkSelectionData *s
- if (dot)
- *dot = '\0';
- g_snprintf(key, sizeof(key), "Name[%s]", lang);
-- itemname = gaim_desktop_item_get_string(item, key);
-+ itemname = gaim2_desktop_item_get_string(item, key);
- #endif
- if (!itemname)
-- itemname = gaim_desktop_item_get_string(item, "Name");
-+ itemname = gaim2_desktop_item_get_string(item, "Name");
-
-- dtype = gaim_desktop_item_get_entry_type(item);
-+ dtype = gaim2_desktop_item_get_entry_type(item);
- switch (dtype) {
-- GaimConversation *conv;
-- GaimGtkConversation *gtkconv;
-+ Gaim2Conversation *conv;
-+ Gaim2GtkConversation *gtkconv;
-
- case GAIM_DESKTOP_ITEM_TYPE_LINK:
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, who);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, who);
- gtkconv = GAIM_GTK_CONVERSATION(conv);
- gtk_imhtml_insert_link(GTK_IMHTML(gtkconv->entry),
- gtk_text_buffer_get_insert(GTK_IMHTML(gtkconv->entry)->text_buffer),
-- gaim_desktop_item_get_string(item, "URL"), itemname);
-+ gaim2_desktop_item_get_string(item, "URL"), itemname);
- break;
- default:
- /* I don't know if we really want to do anything here. Most of the desktop item types are crap like
-@@ -1511,12 +1511,12 @@ gaim_dnd_file_manage(GtkSelectionData *s
- * send. The only logical one is "Application," but do we really want to send a binary and nothing else?
- * Probably not. I'll just give an error and return. */
- /* The original patch sent the icon used by the launcher. That's probably wrong */
-- gaim_notify_error(NULL, NULL, _("Cannot send launcher"), _("You dragged a desktop launcher. "
-+ gaim2_notify_error(NULL, NULL, _("Cannot send launcher"), _("You dragged a desktop launcher. "
- "Most likely you wanted to send whatever this launcher points to instead of this launcher"
- " itself."));
- break;
- }
-- gaim_desktop_item_unref(item);
-+ gaim2_desktop_item_unref(item);
- return;
- }
- #endif /* _WIN32 */
-@@ -1528,12 +1528,12 @@ gaim_dnd_file_manage(GtkSelectionData *s
- g_list_free(files);
- }
-
--void gaim_gtk_buddy_icon_get_scale_size(GdkPixbuf *buf, GaimBuddyIconSpec *spec, int *width, int *height)
-+void gaim2_gtk_buddy_icon_get_scale_size(GdkPixbuf *buf, Gaim2BuddyIconSpec *spec, int *width, int *height)
- {
- *width = gdk_pixbuf_get_width(buf);
- *height = gdk_pixbuf_get_height(buf);
-
-- gaim_buddy_icon_get_scale_size(spec, width, height);
-+ gaim2_buddy_icon_get_scale_size(spec, width, height);
-
- /* and now for some arbitrary sanity checks */
- if(*width > 100)
-@@ -1543,10 +1543,10 @@ void gaim_gtk_buddy_icon_get_scale_size(
- }
-
- GdkPixbuf *
--gaim_gtk_create_prpl_icon(GaimAccount *account)
-+gaim2_gtk_create_prpl_icon(Gaim2Account *account)
- {
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- GdkPixbuf *status = NULL;
- char *filename = NULL;
- const char *protoname = NULL;
-@@ -1554,7 +1554,7 @@ gaim_gtk_create_prpl_icon(GaimAccount *a
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- if (prpl != NULL) {
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-@@ -1572,7 +1572,7 @@ gaim_gtk_create_prpl_icon(GaimAccount *a
- */
- g_snprintf(buf, sizeof(buf), "%s.png", protoname);
-
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status",
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status",
- "default", buf, NULL);
- status = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-@@ -1581,14 +1581,14 @@ gaim_gtk_create_prpl_icon(GaimAccount *a
- }
-
- GdkPixbuf *
--gaim_gtk_create_prpl_icon_with_status(GaimAccount *account, GaimStatusType *status_type)
-+gaim2_gtk_create_prpl_icon_with_status(Gaim2Account *account, Gaim2StatusType *status_type)
- {
- char basename2[BUFSIZ];
- char *filename;
- const char *type_name;
- GdkPixbuf *pixbuf, *scale = NULL, *emblem;
-
-- pixbuf = gaim_gtk_create_prpl_icon(account);
-+ pixbuf = gaim2_gtk_create_prpl_icon(account);
-
- if (pixbuf != NULL) {
- scale = gdk_pixbuf_scale_simple(pixbuf, 32, 32,
-@@ -1600,11 +1600,11 @@ gaim_gtk_create_prpl_icon_with_status(Ga
-
- /* TODO: let the prpl pick the emblem on a per status basis, and only
- * use the primitive as a fallback */
-- type_name = gaim_primitive_get_id_from_type(gaim_status_type_get_primitive(status_type));
-+ type_name = gaim2_primitive_get_id_from_type(gaim2_status_type_get_primitive(status_type));
-
- g_snprintf(basename2, sizeof(basename2), "%s.png",
- type_name);
-- filename = g_build_filename(DATADIR, "pixmaps", "gaim", "status", "default",
-+ filename = g_build_filename(DATADIR, "pixmaps", "gaim2", "status", "default",
- basename2, NULL);
- emblem = gdk_pixbuf_new_from_file(filename, NULL);
- g_free(filename);
-diff -prNu ./src/gtkutils.h ./src/gtkutils.h
---- ./src/gtkutils.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/gtkutils.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file gtkutils.h GTK+ utility functions
- * @ingroup gtkui
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,7 +26,7 @@
- #define _GAIM_GTKUTILS_H_
-
- #include "gtkconv.h"
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
- #include "prpl.h"
-
- typedef enum
-@@ -34,7 +34,7 @@ typedef enum
- GAIM_BUTTON_HORIZONTAL,
- GAIM_BUTTON_VERTICAL
-
--} GaimButtonOrientation;
-+} Gaim2ButtonOrientation;
-
- typedef enum
- {
-@@ -43,7 +43,7 @@ typedef enum
- GAIM_BUTTON_IMAGE,
- GAIM_BUTTON_TEXT_IMAGE
-
--} GaimButtonStyle;
-+} Gaim2ButtonStyle;
-
- #ifndef _WIN32
- typedef enum
-@@ -53,7 +53,7 @@ typedef enum
- GAIM_BROWSER_NEW_WINDOW,
- GAIM_BROWSER_NEW_TAB
-
--} GaimBrowserPlace;
-+} Gaim2BrowserPlace;
- #endif /* _WIN32 */
-
- /**
-@@ -62,7 +62,7 @@ typedef enum
- *
- * @param imhtml The gtkimhtml widget to setup.
- */
--void gaim_setup_imhtml(GtkWidget *imhtml);
-+void gaim2_setup_imhtml(GtkWidget *imhtml);
-
- /**
- * Create an GtkIMHtml widget and associated GtkIMHtmlToolbar widget. This
-@@ -80,7 +80,7 @@ void gaim_setup_imhtml(GtkWidget *imhtml
- * Otherwise this will be set to NULL.
- * @return The GtkFrame containing the toolbar and imhtml.
- */
--GtkWidget *gaim_gtk_create_imhtml(gboolean editable, GtkWidget **imhtml_ret, GtkWidget **toolbar_ret);
-+GtkWidget *gaim2_gtk_create_imhtml(gboolean editable, GtkWidget **imhtml_ret, GtkWidget **toolbar_ret);
-
- /**
- * Toggles the sensitivity of a widget.
-@@ -88,7 +88,7 @@ GtkWidget *gaim_gtk_create_imhtml(gboole
- * @param widget @c NULL. Used for signal handlers.
- * @param to_toggle The widget to toggle.
- */
--void gaim_gtk_toggle_sensitive(GtkWidget *widget, GtkWidget *to_toggle);
-+void gaim2_gtk_toggle_sensitive(GtkWidget *widget, GtkWidget *to_toggle);
-
- /**
- * Checks if text has been entered into a GtkTextEntry widget. If
-@@ -98,7 +98,7 @@ void gaim_gtk_toggle_sensitive(GtkWidget
- * @param entry The text entry widget.
- * @param dialog The dialog containing the text entry widget.
- */
--void gaim_gtk_set_sensitive_if_input(GtkWidget *entry, GtkWidget *dialog);
-+void gaim2_gtk_set_sensitive_if_input(GtkWidget *entry, GtkWidget *dialog);
-
- /**
- * Toggles the sensitivity of all widgets in a pointer array.
-@@ -106,7 +106,7 @@ void gaim_gtk_set_sensitive_if_input(Gtk
- * @param w @c NULL. Used for signal handlers.
- * @param data The array containing the widgets to toggle.
- */
--void gaim_gtk_toggle_sensitive_array(GtkWidget *w, GPtrArray *data);
-+void gaim2_gtk_toggle_sensitive_array(GtkWidget *w, GPtrArray *data);
-
- /**
- * Toggles the visibility of a widget.
-@@ -114,14 +114,14 @@ void gaim_gtk_toggle_sensitive_array(Gtk
- * @param widget @c NULL. Used for signal handlers.
- * @param to_toggle The widget to toggle.
- */
--void gaim_gtk_toggle_showhide(GtkWidget *widget, GtkWidget *to_toggle);
-+void gaim2_gtk_toggle_showhide(GtkWidget *widget, GtkWidget *to_toggle);
-
- /**
- * Adds a separator to a menu.
- *
- * @param menu The menu to add a separator to.
- */
--void gaim_separator(GtkWidget *menu);
-+void gaim2_separator(GtkWidget *menu);
-
- /**
- * Creates a menu item.
-@@ -131,7 +131,7 @@ void gaim_separator(GtkWidget *menu);
- *
- * @return The newly created menu item.
- */
--GtkWidget *gaim_new_item(GtkWidget *menu, const char *str);
-+GtkWidget *gaim2_new_item(GtkWidget *menu, const char *str);
-
- /**
- * Creates a check menu item.
-@@ -144,7 +144,7 @@ GtkWidget *gaim_new_item(GtkWidget *menu
- *
- * @return The newly created menu item.
- */
--GtkWidget *gaim_new_check_item(GtkWidget *menu, const char *str,
-+GtkWidget *gaim2_new_check_item(GtkWidget *menu, const char *str,
- GtkSignalFunc sf, gpointer data, gboolean checked);
-
- /**
-@@ -162,7 +162,7 @@ GtkWidget *gaim_new_check_item(GtkWidget
- *
- * @return The newly created menu item.
- */
--GtkWidget *gaim_new_item_from_stock(GtkWidget *menu, const char *str,
-+GtkWidget *gaim2_new_item_from_stock(GtkWidget *menu, const char *str,
- const char *icon, GtkSignalFunc sf,
- gpointer data, guint accel_key,
- guint accel_mods, char *mod);
-@@ -176,8 +176,8 @@ GtkWidget *gaim_new_item_from_stock(GtkW
- *
- * @return The button.
- */
--GtkWidget *gaim_pixbuf_button_from_stock(const char *text, const char *icon,
-- GaimButtonOrientation style);
-+GtkWidget *gaim2_pixbuf_button_from_stock(const char *text, const char *icon,
-+ Gaim2ButtonOrientation style);
-
- /**
- * Creates a toolbar button with the stock icon.
-@@ -186,7 +186,7 @@ GtkWidget *gaim_pixbuf_button_from_stock
- *
- * @return The button.
- */
--GtkWidget *gaim_pixbuf_toolbar_button_from_stock(const char *stock);
-+GtkWidget *gaim2_pixbuf_toolbar_button_from_stock(const char *stock);
-
- /**
- * Creates a HIG preferences frame.
-@@ -196,7 +196,7 @@ GtkWidget *gaim_pixbuf_toolbar_button_fr
- *
- * @return The vbox to put things into.
- */
--GtkWidget *gaim_gtk_make_frame(GtkWidget *parent, const char *title);
-+GtkWidget *gaim2_gtk_make_frame(GtkWidget *parent, const char *title);
-
- /**
- * Creates a drop-down option menu filled with protocols.
-@@ -207,7 +207,7 @@ GtkWidget *gaim_gtk_make_frame(GtkWidget
- *
- * @return The drop-down option menu.
- */
--GtkWidget *gaim_gtk_protocol_option_menu_new(const char *id,
-+GtkWidget *gaim2_gtk_protocol_option_menu_new(const char *id,
- GCallback cb,
- gpointer user_data);
-
-@@ -224,27 +224,27 @@ GtkWidget *gaim_gtk_protocol_option_menu
- *
- * @return The drop-down option menu.
- */
--GtkWidget *gaim_gtk_account_option_menu_new(GaimAccount *default_account,
-+GtkWidget *gaim2_gtk_account_option_menu_new(Gaim2Account *default_account,
- gboolean show_all, GCallback cb,
-- GaimFilterAccountFunc filter_func, gpointer user_data);
-+ Gaim2FilterAccountFunc filter_func, gpointer user_data);
-
- /**
- * Gets the currently selected account from an account drop down box.
- *
- * @param optmenu The GtkOptionMenu created by
-- * gaim_gtk_account_option_menu_new.
-- * @return Returns the GaimAccount that is currently selected.
-+ * gaim2_gtk_account_option_menu_new.
-+ * @return Returns the Gaim2Account that is currently selected.
- */
--GaimAccount *gaim_gtk_account_option_menu_get_selected(GtkWidget *optmenu);
-+Gaim2Account *gaim2_gtk_account_option_menu_get_selected(GtkWidget *optmenu);
-
- /**
- * Sets the currently selected account for an account drop down box.
- *
- * @param optmenu The GtkOptionMenu created by
-- * gaim_gtk_account_option_menu_new.
-- * @param account The GaimAccount to select.
-+ * gaim2_gtk_account_option_menu_new.
-+ * @param account The Gaim2Account to select.
- */
--void gaim_gtk_account_option_menu_set_selected(GtkWidget *optmenu, GaimAccount *account);
-+void gaim2_gtk_account_option_menu_set_selected(GtkWidget *optmenu, Gaim2Account *account);
-
- /**
- * Check if the given path is a directory or not. If it is, then modify
-@@ -256,34 +256,34 @@ void gaim_gtk_account_option_menu_set_se
- *
- * @return TRUE if given path is a directory, FALSE otherwise.
- */
--gboolean gaim_gtk_check_if_dir(const char *path, GtkFileSelection *filesel);
-+gboolean gaim2_gtk_check_if_dir(const char *path, GtkFileSelection *filesel);
-
- /**
- * Sets up GtkSpell for the given GtkTextView, reporting errors
- * if encountered.
- *
-- * This does nothing if Gaim is not compiled with GtkSpell support.
-+ * This does nothing if Gaim2 is not compiled with GtkSpell support.
- *
- * @param textview The textview widget to setup spellchecking for.
- */
--void gaim_gtk_setup_gtkspell(GtkTextView *textview);
-+void gaim2_gtk_setup_gtkspell(GtkTextView *textview);
-
- /**
- * Save menu accelerators callback
- */
--void gaim_gtk_save_accels_cb(GtkAccelGroup *accel_group, guint arg1,
-+void gaim2_gtk_save_accels_cb(GtkAccelGroup *accel_group, guint arg1,
- GdkModifierType arg2, GClosure *arg3,
- gpointer data);
-
- /**
- * Save menu accelerators
- */
--gboolean gaim_gtk_save_accels(gpointer data);
-+gboolean gaim2_gtk_save_accels(gpointer data);
-
- /**
- * Load menu accelerators
- */
--void gaim_gtk_load_accels(void);
-+void gaim2_gtk_load_accels(void);
-
- /**
- * Parses an application/x-im-contact MIME message and returns the
-@@ -301,8 +301,8 @@ void gaim_gtk_load_accels(void);
- * @return TRUE if the message was parsed for the minimum necessary data.
- * FALSE otherwise.
- */
--gboolean gaim_gtk_parse_x_im_contact(const char *msg, gboolean all_accounts,
-- GaimAccount **ret_account,
-+gboolean gaim2_gtk_parse_x_im_contact(const char *msg, gboolean all_accounts,
-+ Gaim2Account **ret_account,
- char **ret_protocol, char **ret_username,
- char **ret_alias);
-
-@@ -313,7 +313,7 @@ gboolean gaim_gtk_parse_x_im_contact(con
- * @param w The widget that we want to name.
- * @param l A GtkLabel that we want to use as the ATK name for the widget.
- */
--void gaim_set_accessible_label(GtkWidget *w, GtkWidget *l);
-+void gaim2_set_accessible_label(GtkWidget *w, GtkWidget *l);
-
- /**
- * A valid GtkMenuPositionFunc. This is used to determine where
-@@ -330,7 +330,7 @@ void gaim_set_accessible_label(GtkWidget
- * @param push_in This is an output parameter?
- * @param user_data Not used by this particular position function.
- */
--void gaim_gtk_treeview_popup_menu_position_func(GtkMenu *menu,
-+void gaim2_gtk_treeview_popup_menu_position_func(GtkMenu *menu,
- gint *x,
- gint *y,
- gboolean *push_in,
-@@ -343,12 +343,12 @@ void gaim_gtk_treeview_popup_menu_positi
- * @param account Account to be used (may be NULL if conv is not NULL)
- * @param who Buddy name (may be NULL if conv is not NULL)
- */
--void gaim_dnd_file_manage(GtkSelectionData *sd, GaimAccount *account, const char *who);
-+void gaim2_dnd_file_manage(GtkSelectionData *sd, Gaim2Account *account, const char *who);
-
- /**
-- * Convenience wrapper for gaim_buddy_icon_get_scale_size
-+ * Convenience wrapper for gaim2_buddy_icon_get_scale_size
- */
--void gaim_gtk_buddy_icon_get_scale_size(GdkPixbuf *buf, GaimBuddyIconSpec *spec, int *width, int *height);
-+void gaim2_gtk_buddy_icon_get_scale_size(GdkPixbuf *buf, Gaim2BuddyIconSpec *spec, int *width, int *height);
-
- /**
- * Returns the base image to represent the account, based on
-@@ -358,7 +358,7 @@ void gaim_gtk_buddy_icon_get_scale_size(
- *
- * @return The icon.
- */
--GdkPixbuf *gaim_gtk_create_prpl_icon(GaimAccount *account);
-+GdkPixbuf *gaim2_gtk_create_prpl_icon(Gaim2Account *account);
-
- /**
- * Create a protocol-icon with the status emblem.
-@@ -368,6 +368,6 @@ GdkPixbuf *gaim_gtk_create_prpl_icon(Gai
- *
- * @return The icon.
- */
--GdkPixbuf * gaim_gtk_create_prpl_icon_with_status(GaimAccount *account, GaimStatusType *status_type);
-+GdkPixbuf * gaim2_gtk_create_prpl_icon_with_status(Gaim2Account *account, Gaim2StatusType *status_type);
-
- #endif /* _GAIM_GTKUTILS_H_ */
-diff -prNu ./src/gtkwhiteboard.c ./src/gtkwhiteboard.c
---- ./src/gtkwhiteboard.c 2005-11-10 20:47:54.000000000 +0100
-+++ ./src/gtkwhiteboard.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,37 +31,37 @@
- /******************************************************************************
- * Prototypes
- *****************************************************************************/
--static void gaim_gtk_whiteboard_create(GaimWhiteboard *wb);
-+static void gaim2_gtk_whiteboard_create(Gaim2Whiteboard *wb);
-
--static void gaim_gtk_whiteboard_destroy(GaimWhiteboard *wb);
--static void gaim_gtk_whiteboard_exit(GtkWidget *widget, gpointer data);
-+static void gaim2_gtk_whiteboard_destroy(Gaim2Whiteboard *wb);
-+static void gaim2_gtk_whiteboard_exit(GtkWidget *widget, gpointer data);
-
--/*static void gaim_gtkwhiteboard_button_start_press(GtkButton *button, gpointer data); */
-+/*static void gaim2_gtkwhiteboard_button_start_press(GtkButton *button, gpointer data); */
-
--static gboolean gaim_gtk_whiteboard_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer data);
--static gboolean gaim_gtk_whiteboard_expose_event(GtkWidget *widget, GdkEventExpose *event, gpointer data);
-+static gboolean gaim2_gtk_whiteboard_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer data);
-+static gboolean gaim2_gtk_whiteboard_expose_event(GtkWidget *widget, GdkEventExpose *event, gpointer data);
-
--static gboolean gaim_gtk_whiteboard_brush_down(GtkWidget *widget, GdkEventButton *event, gpointer data);
--static gboolean gaim_gtk_whiteboard_brush_motion(GtkWidget *widget, GdkEventMotion *event, gpointer data);
--static gboolean gaim_gtk_whiteboard_brush_up(GtkWidget *widget, GdkEventButton *event, gpointer data);
-+static gboolean gaim2_gtk_whiteboard_brush_down(GtkWidget *widget, GdkEventButton *event, gpointer data);
-+static gboolean gaim2_gtk_whiteboard_brush_motion(GtkWidget *widget, GdkEventMotion *event, gpointer data);
-+static gboolean gaim2_gtk_whiteboard_brush_up(GtkWidget *widget, GdkEventButton *event, gpointer data);
-
--static void gaim_gtk_whiteboard_draw_brush_point(GaimWhiteboard *wb,
-+static void gaim2_gtk_whiteboard_draw_brush_point(Gaim2Whiteboard *wb,
- int x, int y, int color, int size);
--static void gaim_gtk_whiteboard_draw_brush_line(GaimWhiteboard *wb, int x0, int y0,
-+static void gaim2_gtk_whiteboard_draw_brush_line(Gaim2Whiteboard *wb, int x0, int y0,
- int x1, int y1, int color, int size);
-
--static void gaim_gtk_whiteboard_set_dimensions(GaimWhiteboard *wb, int width, int height);
--static void gaim_gtk_whiteboard_set_brush(GaimWhiteboard *wb, int size, int color);
--static void gaim_gtk_whiteboard_clear(GaimWhiteboard *wb);
-+static void gaim2_gtk_whiteboard_set_dimensions(Gaim2Whiteboard *wb, int width, int height);
-+static void gaim2_gtk_whiteboard_set_brush(Gaim2Whiteboard *wb, int size, int color);
-+static void gaim2_gtk_whiteboard_clear(Gaim2Whiteboard *wb);
-
--static void gaim_gtk_whiteboard_button_clear_press(GtkWidget *widget, gpointer data);
--static void gaim_gtk_whiteboard_button_save_press(GtkWidget *widget, gpointer data);
-+static void gaim2_gtk_whiteboard_button_clear_press(GtkWidget *widget, gpointer data);
-+static void gaim2_gtk_whiteboard_button_save_press(GtkWidget *widget, gpointer data);
-
--static void gaim_gtk_whiteboard_set_canvas_as_icon(GaimGtkWhiteboard *gtkwb);
-+static void gaim2_gtk_whiteboard_set_canvas_as_icon(Gaim2GtkWhiteboard *gtkwb);
-
--static void gaim_gtk_whiteboard_rgb24_to_rgb48(int color_rgb, GdkColor *color);
-+static void gaim2_gtk_whiteboard_rgb24_to_rgb48(int color_rgb, GdkColor *color);
-
--static void color_select_dialog(GtkWidget *widget, GaimGtkWhiteboard *gtkwb);
-+static void color_select_dialog(GtkWidget *widget, Gaim2GtkWhiteboard *gtkwb);
-
- /******************************************************************************
- * Globals
-@@ -78,26 +78,26 @@ static int LastY;
- static int MotionCount; /* Tracks how many brush motions made */
- static int BrushState = BRUSH_STATE_UP;
-
--static GaimWhiteboardUiOps ui_ops =
-+static Gaim2WhiteboardUiOps ui_ops =
- {
-- gaim_gtk_whiteboard_create,
-- gaim_gtk_whiteboard_destroy,
-- gaim_gtk_whiteboard_set_dimensions,
-- gaim_gtk_whiteboard_set_brush,
-- gaim_gtk_whiteboard_draw_brush_point,
-- gaim_gtk_whiteboard_draw_brush_line,
-- gaim_gtk_whiteboard_clear
-+ gaim2_gtk_whiteboard_create,
-+ gaim2_gtk_whiteboard_destroy,
-+ gaim2_gtk_whiteboard_set_dimensions,
-+ gaim2_gtk_whiteboard_set_brush,
-+ gaim2_gtk_whiteboard_draw_brush_point,
-+ gaim2_gtk_whiteboard_draw_brush_line,
-+ gaim2_gtk_whiteboard_clear
- };
-
- /******************************************************************************
- * API
- *****************************************************************************/
--GaimWhiteboardUiOps *gaim_gtk_whiteboard_get_ui_ops(void)
-+Gaim2WhiteboardUiOps *gaim2_gtk_whiteboard_get_ui_ops(void)
- {
- return &ui_ops;
- }
-
--void gaim_gtk_whiteboard_create(GaimWhiteboard *wb)
-+void gaim2_gtk_whiteboard_create(Gaim2Whiteboard *wb)
- {
- GtkWidget *window;
- GtkWidget *drawing_area;
-@@ -119,7 +119,7 @@ void gaim_gtk_whiteboard_create(GaimWhit
- GtkWidget *save_button;
- GtkWidget *color_button;
-
-- GaimGtkWhiteboard *gtkwb = g_new0(GaimGtkWhiteboard, 1);
-+ Gaim2GtkWhiteboard *gtkwb = g_new0(Gaim2GtkWhiteboard, 1);
-
- const char *window_title;
-
-@@ -127,14 +127,14 @@ void gaim_gtk_whiteboard_create(GaimWhit
- wb->ui_data = gtkwb;
-
- /* Get dimensions (default?) for the whiteboard canvas */
-- if (!gaim_whiteboard_get_dimensions(wb, &gtkwb->width, &gtkwb->height))
-+ if (!gaim2_whiteboard_get_dimensions(wb, &gtkwb->width, &gtkwb->height))
- {
- /* Give some initial board-size */
- gtkwb->width = 300;
- gtkwb->height = 250;
- }
-
-- if (!gaim_whiteboard_get_brush(wb, &gtkwb->brush_size, &gtkwb->brush_color))
-+ if (!gaim2_whiteboard_get_brush(wb, &gtkwb->brush_size, &gtkwb->brush_color))
- {
- /* Give some initial brush-info */
- gtkwb->brush_size = 2;
-@@ -148,7 +148,7 @@ void gaim_gtk_whiteboard_create(GaimWhit
- /* Try and set window title as the name of the buddy, else just use their
- * username
- */
-- window_title = gaim_contact_get_alias(gaim_buddy_get_contact(gaim_find_buddy(wb->account, wb->who)));
-+ window_title = gaim2_contact_get_alias(gaim2_buddy_get_contact(gaim2_find_buddy(wb->account, wb->who)));
- if(window_title)
- gtk_window_set_title((GtkWindow*)(window), window_title);
- else
-@@ -157,7 +157,7 @@ void gaim_gtk_whiteboard_create(GaimWhit
- gtk_window_set_resizable((GtkWindow*)(window), FALSE);
-
- g_signal_connect(G_OBJECT(window), "destroy",
-- G_CALLBACK(gaim_gtk_whiteboard_exit), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_exit), gtkwb);
-
- #if 0
- int i;
-@@ -209,20 +209,20 @@ void gaim_gtk_whiteboard_create(GaimWhit
-
- /* Signals used to handle backing pixmap */
- g_signal_connect(G_OBJECT(drawing_area), "expose_event",
-- G_CALLBACK(gaim_gtk_whiteboard_expose_event), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_expose_event), gtkwb);
-
- g_signal_connect(G_OBJECT(drawing_area), "configure_event",
-- G_CALLBACK(gaim_gtk_whiteboard_configure_event), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_configure_event), gtkwb);
-
- /* Event signals */
- g_signal_connect(G_OBJECT(drawing_area), "button_press_event",
-- G_CALLBACK(gaim_gtk_whiteboard_brush_down), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_brush_down), gtkwb);
-
- g_signal_connect(G_OBJECT(drawing_area), "motion_notify_event",
-- G_CALLBACK(gaim_gtk_whiteboard_brush_motion), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_brush_motion), gtkwb);
-
- g_signal_connect(G_OBJECT(drawing_area), "button_release_event",
-- G_CALLBACK(gaim_gtk_whiteboard_brush_up), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_brush_up), gtkwb);
-
- gtk_widget_set_events(drawing_area,
- GDK_EXPOSURE_MASK |
-@@ -243,7 +243,7 @@ void gaim_gtk_whiteboard_create(GaimWhit
- gtk_box_pack_start(GTK_BOX(vbox_controls), clear_button, FALSE, FALSE, GAIM_HIG_BOX_SPACE);
- gtk_widget_show(clear_button);
- g_signal_connect(G_OBJECT(clear_button), "clicked",
-- G_CALLBACK(gaim_gtk_whiteboard_button_clear_press), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_button_clear_press), gtkwb);
-
- /* Add a save button */
- save_button = gtk_button_new_from_stock(GTK_STOCK_SAVE);
-@@ -251,7 +251,7 @@ void gaim_gtk_whiteboard_create(GaimWhit
- gtk_widget_show(save_button);
-
- g_signal_connect(G_OBJECT(save_button), "clicked",
-- G_CALLBACK(gaim_gtk_whiteboard_button_save_press), gtkwb);
-+ G_CALLBACK(gaim2_gtk_whiteboard_button_save_press), gtkwb);
-
- /* Add a color selector */
- color_button = gtk_button_new_from_stock(GTK_STOCK_SELECT_COLOR);
-@@ -263,7 +263,7 @@ void gaim_gtk_whiteboard_create(GaimWhit
- /* Make all this (window) visible */
- gtk_widget_show(window);
-
-- gaim_gtk_whiteboard_set_canvas_as_icon(gtkwb);
-+ gaim2_gtk_whiteboard_set_canvas_as_icon(gtkwb);
-
- /* TODO Specific protocol/whiteboard assignment here? Needs a UI Op? */
- /* Set default brush size and color */
-@@ -273,9 +273,9 @@ void gaim_gtk_whiteboard_create(GaimWhit
- */
- }
-
--void gaim_gtk_whiteboard_destroy(GaimWhiteboard *wb)
-+void gaim2_gtk_whiteboard_destroy(Gaim2Whiteboard *wb)
- {
-- GaimGtkWhiteboard *gtkwb = wb->ui_data;
-+ Gaim2GtkWhiteboard *gtkwb = wb->ui_data;
-
- /* TODO Ask if user wants to save picture before the session is closed */
-
-@@ -293,16 +293,16 @@ void gaim_gtk_whiteboard_destroy(GaimWhi
- }
- }
-
--void gaim_gtk_whiteboard_exit(GtkWidget *widget, gpointer data)
-+void gaim2_gtk_whiteboard_exit(GtkWidget *widget, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)data;
-- GaimWhiteboard *wb = gtkwb->wb;
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)data;
-+ Gaim2Whiteboard *wb = gtkwb->wb;
-
- if(gtkwb->window && gtkwb->pixmap)
- {
- LocalShutdownRequest = TRUE;
-
-- gaim_gtk_whiteboard_destroy(wb);
-+ gaim2_gtk_whiteboard_destroy(wb);
- }
- else
- LocalShutdownRequest = FALSE;
-@@ -317,7 +317,7 @@ void gaim_gtk_whiteboard_exit(GtkWidget
- /* Destroy whiteboard core, if the local user exited the whiteboard window */
- if(wb && LocalShutdownRequest)
- {
-- gaim_whiteboard_destroy(wb);
-+ gaim2_whiteboard_destroy(wb);
- }
- }
-
-@@ -326,22 +326,22 @@ void gaim_gtk_whiteboard_exit(GtkWidget
- * and use new prpl_info member?)
- */
- #if 0
--void gaim_gtkwhiteboard_button_start_press(GtkButton *button, gpointer data)
-+void gaim2_gtkwhiteboard_button_start_press(GtkButton *button, gpointer data)
- {
-- GaimConversation *conv = data;
-- GaimAccount *account = gaim_conversation_get_account(conv);
-- GaimConnection *gc = gaim_account_get_connection(account);
-- char *to = (char*)(gaim_conversation_get_name(conv));
-+ Gaim2Conversation *conv = data;
-+ Gaim2Account *account = gaim2_conversation_get_account(conv);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ char *to = (char*)(gaim2_conversation_get_name(conv));
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- GaimWhiteboard *wb = gaim_whiteboard_get(account, to);
-+ Gaim2Whiteboard *wb = gaim2_whiteboard_get(account, to);
-
- /* Write a local message to this conversation showing that a request for a
- * Doodle session has been made
- */
-- gaim_conv_im_write(GAIM_CONV_IM(conv), "", _("Sent Doodle request."),
-+ gaim2_conv_im_write(GAIM_CONV_IM(conv), "", _("Sent Doodle request."),
- GAIM_MESSAGE_NICK | GAIM_MESSAGE_RECV, time(NULL));
-
- yahoo_doodle_command_send_request(gc, to);
-@@ -350,13 +350,13 @@ void gaim_gtkwhiteboard_button_start_pre
- /* Insert this 'session' in the list. At this point, it's only a requested
- * session.
- */
-- wb = gaim_whiteboard_create(account, to, DOODLE_STATE_REQUESTING);
-+ wb = gaim2_whiteboard_create(account, to, DOODLE_STATE_REQUESTING);
- }
- #endif
-
--gboolean gaim_gtk_whiteboard_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer data)
-+gboolean gaim2_gtk_whiteboard_configure_event(GtkWidget *widget, GdkEventConfigure *event, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)data;
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)data;
-
- GdkPixmap *pixmap = gtkwb->pixmap;
-
-@@ -380,9 +380,9 @@ gboolean gaim_gtk_whiteboard_configure_e
- return TRUE;
- }
-
--gboolean gaim_gtk_whiteboard_expose_event(GtkWidget *widget, GdkEventExpose *event, gpointer data)
-+gboolean gaim2_gtk_whiteboard_expose_event(GtkWidget *widget, GdkEventExpose *event, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)(data);
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)(data);
- GdkPixmap *pixmap = gtkwb->pixmap;
-
- gdk_draw_drawable(widget->window,
-@@ -395,12 +395,12 @@ gboolean gaim_gtk_whiteboard_expose_even
- return FALSE;
- }
-
--gboolean gaim_gtk_whiteboard_brush_down(GtkWidget *widget, GdkEventButton *event, gpointer data)
-+gboolean gaim2_gtk_whiteboard_brush_down(GtkWidget *widget, GdkEventButton *event, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)data;
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)data;
- GdkPixmap *pixmap = gtkwb->pixmap;
-
-- GaimWhiteboard *wb = gtkwb->wb;
-+ Gaim2Whiteboard *wb = gtkwb->wb;
- GList *draw_list = wb->draw_list;
-
- if(BrushState != BRUSH_STATE_UP)
-@@ -418,7 +418,7 @@ gboolean gaim_gtk_whiteboard_brush_down(
- /* Check if draw_list has contents; if so, clear it */
- if(draw_list)
- {
-- gaim_whiteboard_draw_list_destroy(draw_list);
-+ gaim2_whiteboard_draw_list_destroy(draw_list);
- draw_list = NULL;
- }
-
-@@ -431,7 +431,7 @@ gboolean gaim_gtk_whiteboard_brush_down(
- draw_list = g_list_append(draw_list, GINT_TO_POINTER(LastX));
- draw_list = g_list_append(draw_list, GINT_TO_POINTER(LastY));
-
-- gaim_gtk_whiteboard_draw_brush_point(gtkwb->wb,
-+ gaim2_gtk_whiteboard_draw_brush_point(gtkwb->wb,
- event->x, event->y,
- gtkwb->brush_color, gtkwb->brush_size);
- }
-@@ -441,7 +441,7 @@ gboolean gaim_gtk_whiteboard_brush_down(
- return TRUE;
- }
-
--gboolean gaim_gtk_whiteboard_brush_motion(GtkWidget *widget, GdkEventMotion *event, gpointer data)
-+gboolean gaim2_gtk_whiteboard_brush_motion(GtkWidget *widget, GdkEventMotion *event, gpointer data)
- {
- int x;
- int y;
-@@ -450,10 +450,10 @@ gboolean gaim_gtk_whiteboard_brush_motio
-
- GdkModifierType state;
-
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)data;
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)data;
- GdkPixmap *pixmap = gtkwb->pixmap;
-
-- GaimWhiteboard *wb = gtkwb->wb;
-+ Gaim2Whiteboard *wb = gtkwb->wb;
- GList *draw_list = wb->draw_list;
-
- if(event->is_hint)
-@@ -469,7 +469,7 @@ gboolean gaim_gtk_whiteboard_brush_motio
- {
- if((BrushState != BRUSH_STATE_DOWN) && (BrushState != BRUSH_STATE_MOTION))
- {
-- gaim_debug_error("gtkwhiteboard", "***Bad brush state transition %d to MOTION\n", BrushState);
-+ gaim2_debug_error("gtkwhiteboard", "***Bad brush state transition %d to MOTION\n", BrushState);
-
- BrushState = BRUSH_STATE_MOTION;
-
-@@ -491,12 +491,12 @@ gboolean gaim_gtk_whiteboard_brush_motio
- draw_list = g_list_append(draw_list, GINT_TO_POINTER(dy));
-
- /* Send draw list to the draw_list handler */
-- gaim_whiteboard_send_draw_list(gtkwb->wb, draw_list);
-+ gaim2_whiteboard_send_draw_list(gtkwb->wb, draw_list);
-
- /* The brush stroke is finished, clear the list for another one */
- if(draw_list)
- {
-- gaim_whiteboard_draw_list_destroy(draw_list);
-+ gaim2_whiteboard_draw_list_destroy(draw_list);
- draw_list = NULL;
- }
-
-@@ -513,7 +513,7 @@ gboolean gaim_gtk_whiteboard_brush_motio
- draw_list = g_list_append(draw_list, GINT_TO_POINTER(dx));
- draw_list = g_list_append(draw_list, GINT_TO_POINTER(dy));
-
-- gaim_gtk_whiteboard_draw_brush_line(gtkwb->wb,
-+ gaim2_gtk_whiteboard_draw_brush_line(gtkwb->wb,
- LastX, LastY,
- x, y,
- gtkwb->brush_color, gtkwb->brush_size);
-@@ -528,17 +528,17 @@ gboolean gaim_gtk_whiteboard_brush_motio
- return TRUE;
- }
-
--gboolean gaim_gtk_whiteboard_brush_up(GtkWidget *widget, GdkEventButton *event, gpointer data)
-+gboolean gaim2_gtk_whiteboard_brush_up(GtkWidget *widget, GdkEventButton *event, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)data;
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)data;
- GdkPixmap *pixmap = gtkwb->pixmap;
-
-- GaimWhiteboard *wb = gtkwb->wb;
-+ Gaim2Whiteboard *wb = gtkwb->wb;
- GList *draw_list = wb->draw_list;
-
- if((BrushState != BRUSH_STATE_DOWN) && (BrushState != BRUSH_STATE_MOTION))
- {
-- gaim_debug_error("gtkwhiteboard", "***Bad brush state transition %d to UP\n", BrushState);
-+ gaim2_debug_error("gtkwhiteboard", "***Bad brush state transition %d to UP\n", BrushState);
-
- BrushState = BRUSH_STATE_UP;
-
-@@ -570,13 +570,13 @@ gboolean gaim_gtk_whiteboard_brush_up(Gt
- */
-
- /* Send draw list to prpl draw_list handler */
-- gaim_whiteboard_send_draw_list(gtkwb->wb, draw_list);
-+ gaim2_whiteboard_send_draw_list(gtkwb->wb, draw_list);
-
-- gaim_gtk_whiteboard_set_canvas_as_icon(gtkwb);
-+ gaim2_gtk_whiteboard_set_canvas_as_icon(gtkwb);
-
- /* The brush stroke is finished, clear the list for another one */
- if(draw_list)
-- gaim_whiteboard_draw_list_destroy(draw_list);
-+ gaim2_whiteboard_draw_list_destroy(draw_list);
-
- wb->draw_list = NULL;
- }
-@@ -584,9 +584,9 @@ gboolean gaim_gtk_whiteboard_brush_up(Gt
- return TRUE;
- }
-
--void gaim_gtk_whiteboard_draw_brush_point(GaimWhiteboard *wb, int x, int y, int color, int size)
-+void gaim2_gtk_whiteboard_draw_brush_point(Gaim2Whiteboard *wb, int x, int y, int color, int size)
- {
-- GaimGtkWhiteboard *gtkwb = wb->ui_data;
-+ Gaim2GtkWhiteboard *gtkwb = wb->ui_data;
- GtkWidget *widget = gtkwb->drawing_area;
- GdkPixmap *pixmap = gtkwb->pixmap;
-
-@@ -601,7 +601,7 @@ void gaim_gtk_whiteboard_draw_brush_poin
- update_rect.height = size;
-
- /* Interpret and convert color */
-- gaim_gtk_whiteboard_rgb24_to_rgb48(color, &col);
-+ gaim2_gtk_whiteboard_rgb24_to_rgb48(color, &col);
-
- gdk_gc_set_rgb_fg_color(gfx_con, &col);
- /* gdk_gc_set_rgb_bg_color(gfx_con, &col); */
-@@ -637,7 +637,7 @@ void gaim_gtk_whiteboard_draw_brush_poin
- }
-
- /* Uses Bresenham's algorithm (as provided by Wikipedia) */
--void gaim_gtk_whiteboard_draw_brush_line(GaimWhiteboard *wb, int x0, int y0, int x1, int y1, int color, int size)
-+void gaim2_gtk_whiteboard_draw_brush_line(Gaim2Whiteboard *wb, int x0, int y0, int x1, int y1, int color, int size)
- {
- int temp;
-
-@@ -681,9 +681,9 @@ void gaim_gtk_whiteboard_draw_brush_line
- ystep = -1;
-
- if(steep)
-- gaim_gtk_whiteboard_draw_brush_point(wb, y, x, color, size);
-+ gaim2_gtk_whiteboard_draw_brush_point(wb, y, x, color, size);
- else
-- gaim_gtk_whiteboard_draw_brush_point(wb, x, y, color, size);
-+ gaim2_gtk_whiteboard_draw_brush_point(wb, x, y, color, size);
-
- while(x != x1)
- {
-@@ -697,31 +697,31 @@ void gaim_gtk_whiteboard_draw_brush_line
- }
-
- if(steep)
-- gaim_gtk_whiteboard_draw_brush_point(wb, y, x, color, size);
-+ gaim2_gtk_whiteboard_draw_brush_point(wb, y, x, color, size);
- else
-- gaim_gtk_whiteboard_draw_brush_point(wb, x, y, color, size);
-+ gaim2_gtk_whiteboard_draw_brush_point(wb, x, y, color, size);
- }
- }
-
--void gaim_gtk_whiteboard_set_dimensions(GaimWhiteboard *wb, int width, int height)
-+void gaim2_gtk_whiteboard_set_dimensions(Gaim2Whiteboard *wb, int width, int height)
- {
-- GaimGtkWhiteboard *gtkwb = wb->ui_data;
-+ Gaim2GtkWhiteboard *gtkwb = wb->ui_data;
-
- gtkwb->width = width;
- gtkwb->height = height;
- }
-
--void gaim_gtk_whiteboard_set_brush(GaimWhiteboard *wb, int size, int color)
-+void gaim2_gtk_whiteboard_set_brush(Gaim2Whiteboard *wb, int size, int color)
- {
-- GaimGtkWhiteboard *gtkwb = wb->ui_data;
-+ Gaim2GtkWhiteboard *gtkwb = wb->ui_data;
-
- gtkwb->brush_size = size;
- gtkwb->brush_color = color;
- }
-
--void gaim_gtk_whiteboard_clear(GaimWhiteboard *wb)
-+void gaim2_gtk_whiteboard_clear(Gaim2Whiteboard *wb)
- {
-- GaimGtkWhiteboard *gtkwb = wb->ui_data;
-+ Gaim2GtkWhiteboard *gtkwb = wb->ui_data;
- GdkPixmap *pixmap = gtkwb->pixmap;
- GtkWidget *drawing_area = gtkwb->drawing_area;
-
-@@ -738,21 +738,21 @@ void gaim_gtk_whiteboard_clear(GaimWhite
- drawing_area->allocation.height);
- }
-
--void gaim_gtk_whiteboard_button_clear_press(GtkWidget *widget, gpointer data)
-+void gaim2_gtk_whiteboard_button_clear_press(GtkWidget *widget, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)(data);
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)(data);
-
-- gaim_gtk_whiteboard_clear(gtkwb->wb);
-+ gaim2_gtk_whiteboard_clear(gtkwb->wb);
-
-- gaim_gtk_whiteboard_set_canvas_as_icon(gtkwb);
-+ gaim2_gtk_whiteboard_set_canvas_as_icon(gtkwb);
-
- /* Do protocol specific clearing procedures */
-- gaim_whiteboard_send_clear(gtkwb->wb);
-+ gaim2_whiteboard_send_clear(gtkwb->wb);
- }
-
--void gaim_gtk_whiteboard_button_save_press(GtkWidget *widget, gpointer data)
-+void gaim2_gtk_whiteboard_button_save_press(GtkWidget *widget, gpointer data)
- {
-- GaimGtkWhiteboard *gtkwb = (GaimGtkWhiteboard*)(data);
-+ Gaim2GtkWhiteboard *gtkwb = (Gaim2GtkWhiteboard*)(data);
- GdkPixbuf *pixbuf;
-
- GtkWidget *dialog;
-@@ -804,20 +804,20 @@ void gaim_gtk_whiteboard_button_save_pre
- gtkwb->width, gtkwb->height);
-
- if(gdk_pixbuf_save(pixbuf, filename, "jpeg", NULL, "quality", "100", NULL))
-- gaim_debug_info("gtkwhiteboard", "File Saved...\n");
-+ gaim2_debug_info("gtkwhiteboard", "File Saved...\n");
- else
-- gaim_debug_info("gtkwhiteboard", "File not Saved... Error\n");
-+ gaim2_debug_info("gtkwhiteboard", "File not Saved... Error\n");
- g_free(filename);
- }
- else if(result == GTK_RESPONSE_CANCEL)
- {
- gtk_widget_destroy(dialog);
-
-- gaim_debug_info("gtkwhiteboard", "File not Saved... Canceled\n");
-+ gaim2_debug_info("gtkwhiteboard", "File not Saved... Canceled\n");
- }
- }
-
--void gaim_gtk_whiteboard_set_canvas_as_icon(GaimGtkWhiteboard *gtkwb)
-+void gaim2_gtk_whiteboard_set_canvas_as_icon(Gaim2GtkWhiteboard *gtkwb)
- {
- GdkPixbuf *pixbuf;
-
-@@ -832,7 +832,7 @@ void gaim_gtk_whiteboard_set_canvas_as_i
- gtk_window_set_icon((GtkWindow*)(gtkwb->window), pixbuf);
- }
-
--void gaim_gtk_whiteboard_rgb24_to_rgb48(int color_rgb, GdkColor *color)
-+void gaim2_gtk_whiteboard_rgb24_to_rgb48(int color_rgb, GdkColor *color)
- {
- color->red = (color_rgb >> 8) | 0xFF;
- color->green = (color_rgb & 0xFF00) | 0xFF;
-@@ -840,21 +840,21 @@ void gaim_gtk_whiteboard_rgb24_to_rgb48(
- }
-
- static void
--change_color_cb(GtkColorSelection *selection, GaimGtkWhiteboard *gtkwb)
-+change_color_cb(GtkColorSelection *selection, Gaim2GtkWhiteboard *gtkwb)
- {
- GdkColor color;
- int old_size = 5;
- int old_color = 0;
- int new_color;
-- GaimWhiteboard *wb = gtkwb->wb;
-+ Gaim2Whiteboard *wb = gtkwb->wb;
-
- gtk_color_selection_get_current_color(selection, &color);
- new_color = (color.red & 0xFF00) << 8;
- new_color |= (color.green & 0xFF00);
- new_color |= (color.blue & 0xFF00) >> 8;
-
-- gaim_whiteboard_get_brush(wb, &old_size, &old_color);
-- gaim_whiteboard_send_brush(wb, old_size, new_color);
-+ gaim2_whiteboard_get_brush(wb, &old_size, &old_color);
-+ gaim2_whiteboard_send_brush(wb, old_size, new_color);
- }
-
- static void color_selection_dialog_destroy(GtkWidget *w, GtkWidget *destroy)
-@@ -862,7 +862,7 @@ static void color_selection_dialog_destr
- gtk_widget_destroy(destroy);
- }
-
--static void color_select_dialog(GtkWidget *widget, GaimGtkWhiteboard *gtkwb)
-+static void color_select_dialog(GtkWidget *widget, Gaim2GtkWhiteboard *gtkwb)
- {
- GdkColor color;
- GtkColorSelectionDialog *dialog;
-@@ -880,7 +880,7 @@ static void color_select_dialog(GtkWidge
-
- gtk_color_selection_set_has_palette(GTK_COLOR_SELECTION(dialog->colorsel), TRUE);
-
-- gaim_gtk_whiteboard_rgb24_to_rgb48(gtkwb->brush_color, &color);
-+ gaim2_gtk_whiteboard_rgb24_to_rgb48(gtkwb->brush_color, &color);
- gtk_color_selection_set_current_color(GTK_COLOR_SELECTION(dialog->colorsel), &color);
-
- gtk_widget_show_all(GTK_WIDGET(dialog));
-diff -prNu ./src/gtkwhiteboard.h ./src/gtkwhiteboard.h
---- ./src/gtkwhiteboard.h 2005-10-31 03:19:51.000000000 +0100
-+++ ./src/gtkwhiteboard.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
-- * @file gtkwhiteboard.h The GtkGaimWhiteboard frontend object
-+ * @file gtkwhiteboard.h The GtkGaim2Whiteboard frontend object
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,7 +25,7 @@
- #ifndef _GAIM_GTKWHITEBOARD_H_
- #define _GAIM_GTKWHITEBOARD_H_
-
--#include "gtkgaim.h"
-+#include "gtkgaim2.h"
-
- #include "whiteboard.h"
-
-@@ -41,11 +41,11 @@
- #define PALETTE_NUM_COLORS 7
-
- /**
-- * A GaimGtkWhiteboard
-+ * A Gaim2GtkWhiteboard
- */
--typedef struct _GaimGtkWhiteboard
-+typedef struct _Gaim2GtkWhiteboard
- {
-- GaimWhiteboard *wb; /**< backend data for this whiteboard */
-+ Gaim2Whiteboard *wb; /**< backend data for this whiteboard */
-
- GtkWidget *window; /**< Window for the Doodle session */
- GtkWidget *drawing_area; /**< Drawing area */
-@@ -56,14 +56,14 @@ typedef struct _GaimGtkWhiteboard
- int height; /**< Canvas height */
- int brush_color; /**< Foreground color */
- int brush_size; /**< Brush size */
--} GaimGtkWhiteboard;
-+} Gaim2GtkWhiteboard;
-
- #ifdef __cplusplus
- extern "C" {
- #endif /* __cplusplus */
-
- /*****************************************************************************/
--/** @name GaimGtkWhiteboard API */
-+/** @name Gaim2GtkWhiteboard API */
- /*****************************************************************************/
- /*@{*/
-
-@@ -72,7 +72,7 @@ extern "C" {
- *
- * @return The GtkWhiteboard UI Operations.
- */
--GaimWhiteboardUiOps *gaim_gtk_whiteboard_get_ui_ops( void );
-+Gaim2WhiteboardUiOps *gaim2_gtk_whiteboard_get_ui_ops( void );
-
- /*@}*/
-
-diff -prNu ./src/idle.c ./src/idle.c
---- ./src/idle.c 2005-12-20 07:41:56.000000000 +0100
-+++ ./src/idle.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -39,9 +39,9 @@ typedef enum
- GAIM_IDLE_AUTO_AWAY,
- GAIM_IDLE_AWAY_BUT_NOT_AUTO_AWAY
-
--} GaimAutoAwayState;
-+} Gaim2AutoAwayState;
-
--static GaimIdleUiOps *idle_ui_ops = NULL;
-+static Gaim2IdleUiOps *idle_ui_ops = NULL;
-
- /**
- * This is needed for the I'dle Mak'er plugin to work correctly. We
-@@ -57,29 +57,29 @@ static guint idle_timer = 0;
- static time_t last_active_time = 0;
-
- static void
--set_account_autoaway(GaimConnection *gc)
-+set_account_autoaway(Gaim2Connection *gc)
- {
-- GaimAccount *account;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-
- if (gc->is_auto_away)
- /* This account is already auto-away! */
- return;
-
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-- status = gaim_presence_get_active_status(presence);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-+ status = gaim2_presence_get_active_status(presence);
-
-- if (gaim_status_is_available(status))
-+ if (gaim2_status_is_available(status))
- {
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
-
-- gaim_debug_info("idle", "Making %s auto-away\n",
-- gaim_account_get_username(account));
-+ gaim2_debug_info("idle", "Making %s auto-away\n",
-+ gaim2_account_get_username(account));
-
-- saved_status = gaim_savedstatus_get_idleaway();
-- gaim_savedstatus_activate_for_account(saved_status, account);
-+ saved_status = gaim2_savedstatus_get_idleaway();
-+ gaim2_savedstatus_activate_for_account(saved_status, account);
-
- gc->is_auto_away = GAIM_IDLE_AUTO_AWAY;
- } else {
-@@ -88,16 +88,16 @@ set_account_autoaway(GaimConnection *gc)
- }
-
- static void
--unset_account_autoaway(GaimConnection *gc)
-+unset_account_autoaway(Gaim2Connection *gc)
- {
-- GaimAccount *account;
-- GaimPresence *presence;
-- GaimStatus *status;
-- GaimSavedStatus *saved_status;
--
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-- status = gaim_presence_get_active_status(presence);
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-+ Gaim2SavedStatus *saved_status;
-+
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-+ status = gaim2_presence_get_active_status(presence);
-
- if (!gc->is_auto_away)
- /* This account is already not auto-away! */
-@@ -108,66 +108,66 @@ unset_account_autoaway(GaimConnection *g
- } else {
- gc->is_auto_away = GAIM_IDLE_NOT_AWAY;
-
-- gaim_debug_info("idle", "%s returning from auto-away\n",
-- gaim_account_get_username(account));
-+ gaim2_debug_info("idle", "%s returning from auto-away\n",
-+ gaim2_account_get_username(account));
-
- /* Return our account to its previous status */
-- saved_status = gaim_savedstatus_get_current();
-- gaim_savedstatus_activate_for_account(saved_status, account);
-+ saved_status = gaim2_savedstatus_get_current();
-+ gaim2_savedstatus_activate_for_account(saved_status, account);
- }
- }
-
- static void
--set_account_idle(GaimConnection *gc, int time_idle)
-+set_account_idle(Gaim2Connection *gc, int time_idle)
- {
-- GaimAccount *account;
-- GaimPresence *presence;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
-
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-
-- if (gaim_presence_is_idle(presence))
-+ if (gaim2_presence_is_idle(presence))
- /* This account is already idle! */
- return;
-
-- gaim_debug_info("idle", "Setting %s idle %d seconds\n",
-- gaim_account_get_username(account), time_idle);
-- gaim_presence_set_idle(presence, TRUE, time(NULL) - time_idle);
-+ gaim2_debug_info("idle", "Setting %s idle %d seconds\n",
-+ gaim2_account_get_username(account), time_idle);
-+ gaim2_presence_set_idle(presence, TRUE, time(NULL) - time_idle);
- }
-
- static void
--set_account_unidle(GaimConnection *gc)
-+set_account_unidle(Gaim2Connection *gc)
- {
-- GaimAccount *account;
-- GaimPresence *presence;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
-
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-
-- if (!gaim_presence_is_idle(presence))
-+ if (!gaim2_presence_is_idle(presence))
- /* This account is already unidle! */
- return;
-
-- gaim_debug_info("idle", "Setting %s unidle\n",
-- gaim_account_get_username(account));
-- gaim_presence_set_idle(presence, FALSE, time(NULL));
-+ gaim2_debug_info("idle", "Setting %s unidle\n",
-+ gaim2_account_get_username(account));
-+ gaim2_presence_set_idle(presence, FALSE, time(NULL));
- }
-
- /*
- * This function should be called when you think your idle state
- * may have changed. Maybe you're over the 10-minute mark and
-- * Gaim should start reporting idle time to the server. Maybe
-+ * Gaim2 should start reporting idle time to the server. Maybe
- * you've returned from being idle. Maybe your auto-away message
- * should be set.
- *
- * There is no harm to calling this many many times, other than
- * it will be kinda slow. This is called every 5 seconds by a
-- * timer set when Gaim starts. It is also called when
-+ * timer set when Gaim2 starts. It is also called when
- * you send an IM, a chat, etc.
- *
- * This function has 3 sections.
- * 1. Get your idle time. It will query XScreenSaver or Windows
-- * or use the Gaim idle time. Whatever.
-+ * or use the Gaim2 idle time. Whatever.
- * 2. Set or unset your auto-away message.
- * 3. Report your current idle time to the IM server.
- */
-@@ -180,9 +180,9 @@ check_idleness()
- gboolean report_idle;
- GList *l;
-
-- gaim_signal_emit(gaim_blist_get_handle(), "update-idle");
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "update-idle");
-
-- idle_reporting = gaim_prefs_get_string("/core/away/idle_reporting");
-+ idle_reporting = gaim2_prefs_get_string("/core/away/idle_reporting");
- report_idle = TRUE;
- if (!strcmp(idle_reporting, "system") &&
- (idle_ui_ops != NULL) && (idle_ui_ops->get_time_idle != NULL))
-@@ -190,9 +190,9 @@ check_idleness()
- /* Use system idle time (mouse or keyboard movement, etc.) */
- time_idle = idle_ui_ops->get_time_idle();
- }
-- else if (!strcmp(idle_reporting, "gaim"))
-+ else if (!strcmp(idle_reporting, "gaim2"))
- {
-- /* Use 'Gaim idle' */
-+ /* Use 'Gaim2 idle' */
- time_idle = time(NULL) - last_active_time;
- }
- else
-@@ -203,29 +203,29 @@ check_idleness()
- }
-
- /* Auto-away stuff */
-- auto_away = gaim_prefs_get_bool("/core/away/away_when_idle");
-+ auto_away = gaim2_prefs_get_bool("/core/away/away_when_idle");
- if (auto_away &&
-- (time_idle > (60 * gaim_prefs_get_int("/core/away/mins_before_away"))))
-+ (time_idle > (60 * gaim2_prefs_get_int("/core/away/mins_before_away"))))
- {
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- set_account_autoaway(l->data);
- }
-- else if (time_idle < 60 * gaim_prefs_get_int("/core/away/mins_before_away"))
-+ else if (time_idle < 60 * gaim2_prefs_get_int("/core/away/mins_before_away"))
- {
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- unset_account_autoaway(l->data);
- }
-
- /* Idle reporting stuff */
- if (report_idle && (time_idle >= IDLEMARK) && !have_set_idle)
- {
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- set_account_idle(l->data, time_idle);
- have_set_idle = TRUE;
- }
- else if ((!report_idle || time_idle < IDLEMARK) && have_set_idle)
- {
-- for (l = gaim_connections_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_connections_get_all(); l != NULL; l = l->next)
- set_account_unidle(l->data);
- have_set_idle = FALSE;
- }
-@@ -234,7 +234,7 @@ check_idleness()
- }
-
- static void
--im_msg_sent_cb(GaimAccount *account, const char *receiver,
-+im_msg_sent_cb(Gaim2Account *account, const char *receiver,
- const char *message, void *data)
- {
- /* Check our idle time after an IM is sent */
-@@ -242,31 +242,31 @@ im_msg_sent_cb(GaimAccount *account, con
- }
-
- void
--gaim_idle_touch()
-+gaim2_idle_touch()
- {
- time(&last_active_time);
- }
-
- void
--gaim_idle_set(time_t time)
-+gaim2_idle_set(time_t time)
- {
- last_active_time = time;
- }
-
- void
--gaim_idle_set_ui_ops(GaimIdleUiOps *ops)
-+gaim2_idle_set_ui_ops(Gaim2IdleUiOps *ops)
- {
- idle_ui_ops = ops;
- }
-
--GaimIdleUiOps *
--gaim_idle_get_ui_ops(void)
-+Gaim2IdleUiOps *
-+gaim2_idle_get_ui_ops(void)
- {
- return idle_ui_ops;
- }
-
- static void *
--gaim_idle_get_handle()
-+gaim2_idle_get_handle()
- {
- static int handle;
-
-@@ -274,25 +274,25 @@ gaim_idle_get_handle()
- }
-
- void
--gaim_idle_init()
-+gaim2_idle_init()
- {
- /* Add the timer to check if we're idle */
-- idle_timer = gaim_timeout_add(IDLE_CHECK_INTERVAL * 1000, check_idleness, NULL);
-+ idle_timer = gaim2_timeout_add(IDLE_CHECK_INTERVAL * 1000, check_idleness, NULL);
-
-- gaim_signal_connect(gaim_conversations_get_handle(), "sent-im-msg",
-- gaim_idle_get_handle(),
-+ gaim2_signal_connect(gaim2_conversations_get_handle(), "sent-im-msg",
-+ gaim2_idle_get_handle(),
- GAIM_CALLBACK(im_msg_sent_cb), NULL);
-
-- gaim_idle_touch();
-+ gaim2_idle_touch();
- }
-
- void
--gaim_idle_uninit()
-+gaim2_idle_uninit()
- {
-- gaim_signals_disconnect_by_handle(gaim_idle_get_handle());
-+ gaim2_signals_disconnect_by_handle(gaim2_idle_get_handle());
-
- /* Remove the idle timer */
- if (idle_timer > 0)
-- gaim_timeout_remove(idle_timer);
-+ gaim2_timeout_remove(idle_timer);
- idle_timer = 0;
- }
-diff -prNu ./src/idle.h ./src/idle.h
---- ./src/idle.h 2005-11-30 07:03:49.000000000 +0100
-+++ ./src/idle.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file idle.h Idle API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,7 +31,7 @@
- typedef struct
- {
- time_t (*get_time_idle)(void);
--} GaimIdleUiOps;
-+} Gaim2IdleUiOps;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -47,14 +47,14 @@ extern "C" {
- * 'active'. The conversation code calls this when the
- * user sends an IM, for example.
- */
--void gaim_idle_touch(void);
-+void gaim2_idle_touch(void);
-
- /**
- * Fake our idle time by setting the time at which our
- * accounts purportedly became idle. This is used by
- * the I'dle Mak'er plugin.
- */
--void gaim_idle_set(time_t time);
-+void gaim2_idle_set(time_t time);
-
- /*@}*/
-
-@@ -68,24 +68,24 @@ void gaim_idle_set(time_t time);
- *
- * @param ops The UI operations structure.
- */
--void gaim_idle_set_ui_ops(GaimIdleUiOps *ops);
-+void gaim2_idle_set_ui_ops(Gaim2IdleUiOps *ops);
-
- /**
- * Returns the UI operations structure used for idle reporting.
- *
- * @return The UI operations structure in use.
- */
--GaimIdleUiOps *gaim_idle_get_ui_ops(void);
-+Gaim2IdleUiOps *gaim2_idle_get_ui_ops(void);
-
- /**
- * Initializes the idle system.
- */
--void gaim_idle_init(void);
-+void gaim2_idle_init(void);
-
- /**
- * Uninitializes the idle system.
- */
--void gaim_idle_uninit(void);
-+void gaim2_idle_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/imgstore.c ./src/imgstore.c
---- ./src/imgstore.c 2004-05-17 08:47:19.000000000 +0200
-+++ ./src/imgstore.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file imgstore.h IM Image Store API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -38,7 +38,7 @@ static int nextid = 0;
- * Now that this type is basicly private too, these two structs could
- * probably be combined.
- */
--struct _GaimStoredImage
-+struct _Gaim2StoredImage
- {
- char *data; /**< The image data. */
- size_t size; /**< The image data's size. */
-@@ -49,19 +49,19 @@ typedef struct
- {
- int id;
- int refcount;
-- GaimStoredImage *img;
--} GaimStoredImagePriv;
-+ Gaim2StoredImage *img;
-+} Gaim2StoredImagePriv;
-
- /* private functions */
-
--static GaimStoredImagePriv *gaim_imgstore_get_priv(int id) {
-+static Gaim2StoredImagePriv *gaim2_imgstore_get_priv(int id) {
- GSList *tmp = imgstore;
-- GaimStoredImagePriv *priv = NULL;
-+ Gaim2StoredImagePriv *priv = NULL;
-
- g_return_val_if_fail(id > 0, NULL);
-
- while (tmp && !priv) {
-- GaimStoredImagePriv *tmp_priv = tmp->data;
-+ Gaim2StoredImagePriv *tmp_priv = tmp->data;
-
- if (tmp_priv->id == id)
- priv = tmp_priv;
-@@ -70,13 +70,13 @@ static GaimStoredImagePriv *gaim_imgstor
- }
-
- if (!priv)
-- gaim_debug(GAIM_DEBUG_ERROR, "imgstore", "failed to find image id %d\n", id);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "imgstore", "failed to find image id %d\n", id);
-
- return priv;
- }
-
--static void gaim_imgstore_free_priv(GaimStoredImagePriv *priv) {
-- GaimStoredImage *img = NULL;
-+static void gaim2_imgstore_free_priv(Gaim2StoredImagePriv *priv) {
-+ Gaim2StoredImage *img = NULL;
-
- g_return_if_fail(priv != NULL);
-
-@@ -89,7 +89,7 @@ static void gaim_imgstore_free_priv(Gaim
- g_free(img);
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "imgstore", "freed image id %d\n", priv->id);
-+ gaim2_debug(GAIM_DEBUG_INFO, "imgstore", "freed image id %d\n", priv->id);
-
- g_free(priv);
-
-@@ -98,71 +98,71 @@ static void gaim_imgstore_free_priv(Gaim
-
- /* public functions */
-
--int gaim_imgstore_add(const void *data, size_t size, const char *filename) {
-- GaimStoredImagePriv *priv;
-- GaimStoredImage *img;
-+int gaim2_imgstore_add(const void *data, size_t size, const char *filename) {
-+ Gaim2StoredImagePriv *priv;
-+ Gaim2StoredImage *img;
-
- g_return_val_if_fail(data != NULL, 0);
- g_return_val_if_fail(size > 0, 0);
-
-- img = g_new0(GaimStoredImage, 1);
-+ img = g_new0(Gaim2StoredImage, 1);
- img->data = g_memdup(data, size);
- img->size = size;
- img->filename = g_strdup(filename);
-
-- priv = g_new0(GaimStoredImagePriv, 1);
-+ priv = g_new0(Gaim2StoredImagePriv, 1);
- priv->id = ++nextid;
- priv->refcount = 1;
- priv->img = img;
-
- imgstore = g_slist_append(imgstore, priv);
-- gaim_debug(GAIM_DEBUG_INFO, "imgstore", "added image id %d\n", priv->id);
-+ gaim2_debug(GAIM_DEBUG_INFO, "imgstore", "added image id %d\n", priv->id);
-
- return priv->id;
- }
-
--GaimStoredImage *gaim_imgstore_get(int id) {
-- GaimStoredImagePriv *priv = gaim_imgstore_get_priv(id);
-+Gaim2StoredImage *gaim2_imgstore_get(int id) {
-+ Gaim2StoredImagePriv *priv = gaim2_imgstore_get_priv(id);
-
- g_return_val_if_fail(priv != NULL, NULL);
-
-- gaim_debug(GAIM_DEBUG_INFO, "imgstore", "retrieved image id %d\n", priv->id);
-+ gaim2_debug(GAIM_DEBUG_INFO, "imgstore", "retrieved image id %d\n", priv->id);
-
- return priv->img;
- }
-
--gpointer gaim_imgstore_get_data(GaimStoredImage *i) {
-+gpointer gaim2_imgstore_get_data(Gaim2StoredImage *i) {
- return i->data;
- }
-
--size_t gaim_imgstore_get_size(GaimStoredImage *i) {
-+size_t gaim2_imgstore_get_size(Gaim2StoredImage *i) {
- return i->size;
- }
-
--const char *gaim_imgstore_get_filename(GaimStoredImage *i) {
-+const char *gaim2_imgstore_get_filename(Gaim2StoredImage *i) {
- return i->filename;
- }
-
--void gaim_imgstore_ref(int id) {
-- GaimStoredImagePriv *priv = gaim_imgstore_get_priv(id);
-+void gaim2_imgstore_ref(int id) {
-+ Gaim2StoredImagePriv *priv = gaim2_imgstore_get_priv(id);
-
- g_return_if_fail(priv != NULL);
-
- (priv->refcount)++;
-
-- gaim_debug(GAIM_DEBUG_INFO, "imgstore", "referenced image id %d (count now %d)\n", priv->id, priv->refcount);
-+ gaim2_debug(GAIM_DEBUG_INFO, "imgstore", "referenced image id %d (count now %d)\n", priv->id, priv->refcount);
- }
-
--void gaim_imgstore_unref(int id) {
-- GaimStoredImagePriv *priv = gaim_imgstore_get_priv(id);
-+void gaim2_imgstore_unref(int id) {
-+ Gaim2StoredImagePriv *priv = gaim2_imgstore_get_priv(id);
-
- g_return_if_fail(priv != NULL);
- g_return_if_fail(priv->refcount > 0);
-
- (priv->refcount)--;
-
-- gaim_debug(GAIM_DEBUG_INFO, "imgstore", "unreferenced image id %d (count now %d)\n", priv->id, priv->refcount);
-+ gaim2_debug(GAIM_DEBUG_INFO, "imgstore", "unreferenced image id %d (count now %d)\n", priv->id, priv->refcount);
-
- if (priv->refcount == 0)
-- gaim_imgstore_free_priv(priv);
-+ gaim2_imgstore_free_priv(priv);
- }
-diff -prNu ./src/imgstore.h ./src/imgstore.h
---- ./src/imgstore.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/imgstore.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file imgstore.h IM Image Store API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,8 +26,8 @@
- #ifndef _GAIM_IMGSTORE_H_
- #define _GAIM_IMGSTORE_H_
-
--struct _GaimStoredImage;
--typedef struct _GaimStoredImage GaimStoredImage;
-+struct _Gaim2StoredImage;
-+typedef struct _Gaim2StoredImage Gaim2StoredImage;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -36,7 +36,7 @@ extern "C" {
- /**
- * Add an image to the store. The caller owns a reference
- * to the image in the store, and must dereference the image
-- * with gaim_imgstore_unref for it to be freed.
-+ * with gaim2_imgstore_unref for it to be freed.
- *
- * @param data Pointer to the image data.
- * @param size Image data's size.
-@@ -44,7 +44,7 @@ extern "C" {
-
- * @return ID for the image.
- */
--int gaim_imgstore_add(const void *data, size_t size, const char *filename);
-+int gaim2_imgstore_add(const void *data, size_t size, const char *filename);
-
- /**
- * Retrieve an image from the store. The caller does not own a
-@@ -54,7 +54,7 @@ int gaim_imgstore_add(const void *data,
- *
- * @return A pointer to the requested image, or NULL if it was not found.
- */
--GaimStoredImage *gaim_imgstore_get(int id);
-+Gaim2StoredImage *gaim2_imgstore_get(int id);
-
- /**
- * Retrieves a pointer to the image's data.
-@@ -64,7 +64,7 @@ GaimStoredImage *gaim_imgstore_get(int i
- * @return A pointer to the data, which must not
- * be freed or modified.
- */
--gpointer gaim_imgstore_get_data(GaimStoredImage *i);
-+gpointer gaim2_imgstore_get_data(Gaim2StoredImage *i);
-
- /**
- * Retrieves the length of the image's data.
-@@ -72,9 +72,9 @@ gpointer gaim_imgstore_get_data(GaimStor
- * @param i The Image
- *
- * @return The size of the data that the pointer returned by
-- * gaim_imgstore_get_data points to.
-+ * gaim2_imgstore_get_data points to.
- */
--size_t gaim_imgstore_get_size(GaimStoredImage *i);
-+size_t gaim2_imgstore_get_size(Gaim2StoredImage *i);
-
- /**
- * Retrieves a pointer to the image's filename.
-@@ -84,7 +84,7 @@ size_t gaim_imgstore_get_size(GaimStored
- * @return A pointer to the filename, which must not
- * be freed or modified.
- */
--const char *gaim_imgstore_get_filename(GaimStoredImage *i);
-+const char *gaim2_imgstore_get_filename(Gaim2StoredImage *i);
-
- /**
- * Increment the reference count for an image in the store. The
-@@ -93,7 +93,7 @@ const char *gaim_imgstore_get_filename(G
- *
- * @param id The ID for the image.
- */
--void gaim_imgstore_ref(int id);
-+void gaim2_imgstore_ref(int id);
-
- /**
- * Decrement the reference count for an image in the store. The
-@@ -102,7 +102,7 @@ void gaim_imgstore_ref(int id);
- *
- * @param id The ID for the image.
- */
--void gaim_imgstore_unref(int id);
-+void gaim2_imgstore_unref(int id);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/internal.h ./src/internal.h
---- ./src/internal.h 2005-10-17 07:50:30.000000000 +0200
-+++ ./src/internal.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file internal.h Internal definitions and includes
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -162,7 +162,7 @@
- # endif
- #endif
-
--#define GAIM_WEBSITE "http://gaim.sourceforge.net/"
-+#define GAIM_WEBSITE "http://gaim2.sourceforge.net/"
-
- #ifndef _WIN32
- /* Everything needs to include this, because
-diff -prNu ./src/log.c ./src/log.c
---- ./src/log.c 2006-01-03 07:33:00.000000000 +0100
-+++ ./src/log.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file log.c Logging API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,61 +33,61 @@
-
- static GSList *loggers = NULL;
-
--static GaimLogLogger *html_logger;
--static GaimLogLogger *txt_logger;
--static GaimLogLogger *old_logger;
-+static Gaim2LogLogger *html_logger;
-+static Gaim2LogLogger *txt_logger;
-+static Gaim2LogLogger *old_logger;
-
--struct _gaim_logsize_user {
-+struct _gaim2_logsize_user {
- char *name;
-- GaimAccount *account;
-+ Gaim2Account *account;
- };
- static GHashTable *logsize_users = NULL;
-
- static void log_get_log_sets_common(GHashTable *sets);
-
--static void html_logger_write(GaimLog *log, GaimMessageFlags type,
-+static void html_logger_write(Gaim2Log *log, Gaim2MessageFlags type,
- const char *from, time_t time, const char *message);
--static void html_logger_finalize(GaimLog *log);
--static GList *html_logger_list(GaimLogType type, const char *sn, GaimAccount *account);
--static GList *html_logger_list_syslog(GaimAccount *account);
--static char *html_logger_read(GaimLog *log, GaimLogReadFlags *flags);
--
--static GList *old_logger_list(GaimLogType type, const char *sn, GaimAccount *account);
--static int old_logger_total_size(GaimLogType type, const char *name, GaimAccount *account);
--static char * old_logger_read (GaimLog *log, GaimLogReadFlags *flags);
--static int old_logger_size (GaimLog *log);
--static void old_logger_get_log_sets(GaimLogSetCallback cb, GHashTable *sets);
--static void old_logger_finalize(GaimLog *log);
-+static void html_logger_finalize(Gaim2Log *log);
-+static GList *html_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account);
-+static GList *html_logger_list_syslog(Gaim2Account *account);
-+static char *html_logger_read(Gaim2Log *log, Gaim2LogReadFlags *flags);
-+
-+static GList *old_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account);
-+static int old_logger_total_size(Gaim2LogType type, const char *name, Gaim2Account *account);
-+static char * old_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags);
-+static int old_logger_size (Gaim2Log *log);
-+static void old_logger_get_log_sets(Gaim2LogSetCallback cb, GHashTable *sets);
-+static void old_logger_finalize(Gaim2Log *log);
-
--static void txt_logger_write(GaimLog *log,
-- GaimMessageFlags type,
-+static void txt_logger_write(Gaim2Log *log,
-+ Gaim2MessageFlags type,
- const char *from, time_t time, const char *message);
--static void txt_logger_finalize(GaimLog *log);
--static GList *txt_logger_list(GaimLogType type, const char *sn, GaimAccount *account);
--static GList *txt_logger_list_syslog(GaimAccount *account);
--static char *txt_logger_read(GaimLog *log, GaimLogReadFlags *flags);
-+static void txt_logger_finalize(Gaim2Log *log);
-+static GList *txt_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account);
-+static GList *txt_logger_list_syslog(Gaim2Account *account);
-+static char *txt_logger_read(Gaim2Log *log, Gaim2LogReadFlags *flags);
-
- /**************************************************************************
- * PUBLIC LOGGING FUNCTIONS ***********************************************
- **************************************************************************/
-
--GaimLog *gaim_log_new(GaimLogType type, const char *name, GaimAccount *account,
-- GaimConversation *conv, time_t time)
-+Gaim2Log *gaim2_log_new(Gaim2LogType type, const char *name, Gaim2Account *account,
-+ Gaim2Conversation *conv, time_t time)
- {
-- GaimLog *log = g_new0(GaimLog, 1);
-- log->name = g_strdup(gaim_normalize(account, name));
-+ Gaim2Log *log = g_new0(Gaim2Log, 1);
-+ log->name = g_strdup(gaim2_normalize(account, name));
- log->account = account;
- log->conv = conv;
- log->time = time;
- log->type = type;
- log->logger_data = NULL;
-- log->logger = gaim_log_logger_get();
-+ log->logger = gaim2_log_logger_get();
- if (log->logger && log->logger->create)
- log->logger->create(log);
- return log;
- }
-
--void gaim_log_free(GaimLog *log)
-+void gaim2_log_free(Gaim2Log *log)
- {
- g_return_if_fail(log);
- if (log->logger && log->logger->finalize)
-@@ -96,10 +96,10 @@ void gaim_log_free(GaimLog *log)
- g_free(log);
- }
-
--void gaim_log_write(GaimLog *log, GaimMessageFlags type,
-+void gaim2_log_write(Gaim2Log *log, Gaim2MessageFlags type,
- const char *from, time_t time, const char *message)
- {
-- struct _gaim_logsize_user *lu;
-+ struct _gaim2_logsize_user *lu;
-
- g_return_if_fail(log);
- g_return_if_fail(log->logger);
-@@ -107,9 +107,9 @@ void gaim_log_write(GaimLog *log, GaimMe
-
- (log->logger->write)(log, type, from, time, message);
-
-- lu = g_new(struct _gaim_logsize_user, 1);
-+ lu = g_new(struct _gaim2_logsize_user, 1);
-
-- lu->name = g_strdup(gaim_normalize(log->account, log->name));
-+ lu->name = g_strdup(gaim2_normalize(log->account, log->name));
- lu->account = log->account;
- g_hash_table_remove(logsize_users, lu);
- g_free(lu->name);
-@@ -117,19 +117,19 @@ void gaim_log_write(GaimLog *log, GaimMe
-
- }
-
--char *gaim_log_read(GaimLog *log, GaimLogReadFlags *flags)
-+char *gaim2_log_read(Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
-- GaimLogReadFlags mflags;
-+ Gaim2LogReadFlags mflags;
- g_return_val_if_fail(log && log->logger, NULL);
- if (log->logger->read) {
- char *ret = (log->logger->read)(log, flags ? flags : &mflags);
-- gaim_str_strip_char(ret, '\r');
-+ gaim2_str_strip_char(ret, '\r');
- return ret;
- }
- return (_("<b><font color=\"red\">The logger has no read function</font></b>"));
- }
-
--int gaim_log_get_size(GaimLog *log)
-+int gaim2_log_get_size(Gaim2Log *log)
- {
- g_return_val_if_fail(log && log->logger, 0);
-
-@@ -138,32 +138,32 @@ int gaim_log_get_size(GaimLog *log)
- return 0;
- }
-
--static guint _gaim_logsize_user_hash(struct _gaim_logsize_user *lu)
-+static guint _gaim2_logsize_user_hash(struct _gaim2_logsize_user *lu)
- {
- return g_str_hash(lu->name);
- }
-
--static guint _gaim_logsize_user_equal(struct _gaim_logsize_user *lu1,
-- struct _gaim_logsize_user *lu2)
-+static guint _gaim2_logsize_user_equal(struct _gaim2_logsize_user *lu1,
-+ struct _gaim2_logsize_user *lu2)
- {
- return ((!strcmp(lu1->name, lu2->name)) && lu1->account == lu2->account);
- }
-
--static void _gaim_logsize_user_free_key(struct _gaim_logsize_user *lu)
-+static void _gaim2_logsize_user_free_key(struct _gaim2_logsize_user *lu)
- {
- g_free(lu->name);
- g_free(lu);
- }
-
--int gaim_log_get_total_size(GaimLogType type, const char *name, GaimAccount *account)
-+int gaim2_log_get_total_size(Gaim2LogType type, const char *name, Gaim2Account *account)
- {
- gpointer ptrsize;
- int size = 0;
- GSList *n;
-- struct _gaim_logsize_user *lu;
-+ struct _gaim2_logsize_user *lu;
-
-- lu = g_new(struct _gaim_logsize_user, 1);
-- lu->name = g_strdup(gaim_normalize(account, name));
-+ lu = g_new(struct _gaim2_logsize_user, 1);
-+ lu->name = g_strdup(gaim2_normalize(account, name));
- lu->account = account;
-
- if(g_hash_table_lookup_extended(logsize_users, lu, NULL, &ptrsize)) {
-@@ -172,7 +172,7 @@ int gaim_log_get_total_size(GaimLogType
- g_free(lu);
- } else {
- for (n = loggers; n; n = n->next) {
-- GaimLogLogger *logger = n->data;
-+ Gaim2LogLogger *logger = n->data;
-
- if(logger->total_size){
- size += (logger->total_size)(type, name, account);
-@@ -182,9 +182,9 @@ int gaim_log_get_total_size(GaimLogType
-
- while (logs) {
- GList *logs2 = logs->next;
-- GaimLog *log = (GaimLog*)(logs->data);
-- this_size += gaim_log_get_size(log);
-- gaim_log_free(log);
-+ Gaim2Log *log = (Gaim2Log*)(logs->data);
-+ this_size += gaim2_log_get_size(log);
-+ gaim2_log_free(log);
- g_list_free_1(logs);
- logs = logs2;
- }
-@@ -199,35 +199,35 @@ int gaim_log_get_total_size(GaimLogType
- }
-
- char *
--gaim_log_get_log_dir(GaimLogType type, const char *name, GaimAccount *account)
-+gaim2_log_get_log_dir(Gaim2LogType type, const char *name, Gaim2Account *account)
- {
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
- const char *prpl_name;
- char *acct_name;
- const char *target;
- char *dir;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
- if (!prpl)
- return NULL;
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
- prpl_name = prpl_info->list_icon(account, NULL);
-
-- acct_name = g_strdup(gaim_escape_filename(gaim_normalize(account,
-- gaim_account_get_username(account))));
-+ acct_name = g_strdup(gaim2_escape_filename(gaim2_normalize(account,
-+ gaim2_account_get_username(account))));
-
- if (type == GAIM_LOG_CHAT) {
-- char *temp = g_strdup_printf("%s.chat", gaim_normalize(account, name));
-- target = gaim_escape_filename(temp);
-+ char *temp = g_strdup_printf("%s.chat", gaim2_normalize(account, name));
-+ target = gaim2_escape_filename(temp);
- g_free(temp);
- } else if(type == GAIM_LOG_SYSTEM) {
- target = ".system";
- } else {
-- target = gaim_escape_filename(gaim_normalize(account, name));
-+ target = gaim2_escape_filename(gaim2_normalize(account, name));
- }
-
-- dir = g_build_filename(gaim_user_dir(), "logs", prpl_name, acct_name, target, NULL);
-+ dir = g_build_filename(gaim2_user_dir(), "logs", prpl_name, acct_name, target, NULL);
-
- g_free(acct_name);
-
-@@ -238,47 +238,47 @@ gaim_log_get_log_dir(GaimLogType type, c
- * LOGGER FUNCTIONS *********************************************************
- ****************************************************************************/
-
--static GaimLogLogger *current_logger = NULL;
-+static Gaim2LogLogger *current_logger = NULL;
-
--static void logger_pref_cb(const char *name, GaimPrefType type,
-+static void logger_pref_cb(const char *name, Gaim2PrefType type,
- gpointer value, gpointer data)
- {
-- GaimLogLogger *logger;
-+ Gaim2LogLogger *logger;
- GSList *l = loggers;
- while (l) {
- logger = l->data;
- if (!strcmp(logger->id, value)) {
-- gaim_log_logger_set(logger);
-+ gaim2_log_logger_set(logger);
- return;
- }
- l = l->next;
- }
-- gaim_log_logger_set(txt_logger);
-+ gaim2_log_logger_set(txt_logger);
- }
-
-
--GaimLogLogger *gaim_log_logger_new(const char *id, const char *name, int functions, ...)
-+Gaim2LogLogger *gaim2_log_logger_new(const char *id, const char *name, int functions, ...)
- {
- #if 0
-- void(*create)(GaimLog *),
-- void(*write)(GaimLog *, GaimMessageFlags, const char *, time_t, const char *),
-- void(*finalize)(GaimLog *),
-- GList*(*list)(GaimLogType type, const char*, GaimAccount*),
-- char*(*read)(GaimLog*, GaimLogReadFlags*),
-- int(*size)(GaimLog*),
-- int(*total_size)(GaimLogType type, const char *name, GaimAccount *account),
-- GList*(*list_syslog)(GaimAccount *account),
-- void(*get_log_sets)(GaimLogSetCallback cb, GHashTable *sets))
-+ void(*create)(Gaim2Log *),
-+ void(*write)(Gaim2Log *, Gaim2MessageFlags, const char *, time_t, const char *),
-+ void(*finalize)(Gaim2Log *),
-+ GList*(*list)(Gaim2LogType type, const char*, Gaim2Account*),
-+ char*(*read)(Gaim2Log*, Gaim2LogReadFlags*),
-+ int(*size)(Gaim2Log*),
-+ int(*total_size)(Gaim2LogType type, const char *name, Gaim2Account *account),
-+ GList*(*list_syslog)(Gaim2Account *account),
-+ void(*get_log_sets)(Gaim2LogSetCallback cb, GHashTable *sets))
- {
- #endif
-- GaimLogLogger *logger;
-+ Gaim2LogLogger *logger;
- va_list args;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
- g_return_val_if_fail(functions >= 1, NULL);
-
-- logger = g_new0(GaimLogLogger, 1);
-+ logger = g_new0(Gaim2LogLogger, 1);
- logger->id = g_strdup(id);
- logger->name = g_strdup(name);
-
-@@ -304,21 +304,21 @@ GaimLogLogger *gaim_log_logger_new(const
- logger->get_log_sets = va_arg(args, void *);
-
- if (functions > 9)
-- gaim_debug_info("log", "Dropping new functions for logger: %s (%s)\n", name, id);
-+ gaim2_debug_info("log", "Dropping new functions for logger: %s (%s)\n", name, id);
-
- va_end(args);
-
- return logger;
- }
-
--void gaim_log_logger_free(GaimLogLogger *logger)
-+void gaim2_log_logger_free(Gaim2LogLogger *logger)
- {
- g_free(logger->name);
- g_free(logger->id);
- g_free(logger);
- }
-
--void gaim_log_logger_add (GaimLogLogger *logger)
-+void gaim2_log_logger_add (Gaim2LogLogger *logger)
- {
- g_return_if_fail(logger);
- if (g_slist_find(loggers, logger))
-@@ -326,28 +326,28 @@ void gaim_log_logger_add (GaimLogLogger
- loggers = g_slist_append(loggers, logger);
- }
-
--void gaim_log_logger_remove (GaimLogLogger *logger)
-+void gaim2_log_logger_remove (Gaim2LogLogger *logger)
- {
- g_return_if_fail(logger);
- loggers = g_slist_remove(loggers, logger);
- }
-
--void gaim_log_logger_set (GaimLogLogger *logger)
-+void gaim2_log_logger_set (Gaim2LogLogger *logger)
- {
- g_return_if_fail(logger);
- current_logger = logger;
- }
-
--GaimLogLogger *gaim_log_logger_get()
-+Gaim2LogLogger *gaim2_log_logger_get()
- {
- return current_logger;
- }
-
--GList *gaim_log_logger_get_options(void)
-+GList *gaim2_log_logger_get_options(void)
- {
- GSList *n;
- GList *list = NULL;
-- GaimLogLogger *data;
-+ Gaim2LogLogger *data;
-
- for (n = loggers; n; n = n->next) {
- data = n->data;
-@@ -360,32 +360,32 @@ GList *gaim_log_logger_get_options(void)
- return list;
- }
-
--gint gaim_log_compare(gconstpointer y, gconstpointer z)
-+gint gaim2_log_compare(gconstpointer y, gconstpointer z)
- {
-- const GaimLog *a = y;
-- const GaimLog *b = z;
-+ const Gaim2Log *a = y;
-+ const Gaim2Log *b = z;
-
- return b->time - a->time;
- }
-
--GList *gaim_log_get_logs(GaimLogType type, const char *name, GaimAccount *account)
-+GList *gaim2_log_get_logs(Gaim2LogType type, const char *name, Gaim2Account *account)
- {
- GList *logs = NULL;
- GSList *n;
- for (n = loggers; n; n = n->next) {
-- GaimLogLogger *logger = n->data;
-+ Gaim2LogLogger *logger = n->data;
- if (!logger->list)
- continue;
- logs = g_list_concat(logger->list(type, name, account), logs);
- }
-
-- return g_list_sort(logs, gaim_log_compare);
-+ return g_list_sort(logs, gaim2_log_compare);
- }
-
--gint gaim_log_set_compare(gconstpointer y, gconstpointer z)
-+gint gaim2_log_set_compare(gconstpointer y, gconstpointer z)
- {
-- const GaimLogSet *a = y;
-- const GaimLogSet *b = z;
-+ const Gaim2LogSet *a = y;
-+ const Gaim2LogSet *b = z;
- gint ret = 0;
-
- /* This logic seems weird at first...
-@@ -394,7 +394,7 @@ gint gaim_log_set_compare(gconstpointer
- * exist if one logger knows the account and another
- * doesn't. */
- if (a->account != NULL && b->account != NULL) {
-- ret = strcmp(gaim_account_get_username(a->account), gaim_account_get_username(b->account));
-+ ret = strcmp(gaim2_account_get_username(a->account), gaim2_account_get_username(b->account));
- if (ret != 0)
- return ret;
- }
-@@ -409,10 +409,10 @@ gint gaim_log_set_compare(gconstpointer
- static guint
- log_set_hash(gconstpointer key)
- {
-- const GaimLogSet *set = key;
-+ const Gaim2LogSet *set = key;
-
-- /* The account isn't hashed because we need GaimLogSets with NULL accounts
-- * to be found when we search by a GaimLogSet that has a non-NULL account
-+ /* The account isn't hashed because we need Gaim2LogSets with NULL accounts
-+ * to be found when we search by a Gaim2LogSet that has a non-NULL account
- * but the same type and name. */
- return g_int_hash((gint *)&set->type) + g_str_hash(set->name);
- }
-@@ -423,31 +423,31 @@ log_set_equal(gconstpointer a, gconstpoi
- /* I realize that the choices made for GList and GHashTable
- * make sense for those data types, but I wish the comparison
- * functions were compatible. */
-- return !gaim_log_set_compare(a, b);
-+ return !gaim2_log_set_compare(a, b);
- }
-
- static void
--log_add_log_set_to_hash(GHashTable *sets, GaimLogSet *set)
-+log_add_log_set_to_hash(GHashTable *sets, Gaim2LogSet *set)
- {
-- GaimLogSet *existing_set = g_hash_table_lookup(sets, set);
-+ Gaim2LogSet *existing_set = g_hash_table_lookup(sets, set);
-
- if (existing_set == NULL)
- g_hash_table_insert(sets, set, set);
- else if (existing_set->account == NULL && set->account != NULL)
- g_hash_table_replace(sets, set, set);
- else
-- gaim_log_set_free(set);
-+ gaim2_log_set_free(set);
- }
-
--GHashTable *gaim_log_get_log_sets(void)
-+GHashTable *gaim2_log_get_log_sets(void)
- {
- GSList *n;
- GHashTable *sets = g_hash_table_new_full(log_set_hash, log_set_equal,
-- (GDestroyNotify)gaim_log_set_free, NULL);
-+ (GDestroyNotify)gaim2_log_set_free, NULL);
-
- /* Get the log sets from all the loggers. */
- for (n = loggers; n; n = n->next) {
-- GaimLogLogger *logger = n->data;
-+ Gaim2LogLogger *logger = n->data;
-
- if (!logger->get_log_sets)
- continue;
-@@ -457,11 +457,11 @@ GHashTable *gaim_log_get_log_sets(void)
-
- log_get_log_sets_common(sets);
-
-- /* Return the GHashTable of unique GaimLogSets. */
-+ /* Return the GHashTable of unique Gaim2LogSets. */
- return sets;
- }
-
--void gaim_log_set_free(GaimLogSet *set)
-+void gaim2_log_set_free(Gaim2LogSet *set)
- {
- g_return_if_fail(set != NULL);
-
-@@ -471,53 +471,53 @@ void gaim_log_set_free(GaimLogSet *set)
- g_free(set);
- }
-
--GList *gaim_log_get_system_logs(GaimAccount *account)
-+GList *gaim2_log_get_system_logs(Gaim2Account *account)
- {
- GList *logs = NULL;
- GSList *n;
- for (n = loggers; n; n = n->next) {
-- GaimLogLogger *logger = n->data;
-+ Gaim2LogLogger *logger = n->data;
- if (!logger->list_syslog)
- continue;
- logs = g_list_concat(logger->list_syslog(account), logs);
- }
-
-- return g_list_sort(logs, gaim_log_compare);
-+ return g_list_sort(logs, gaim2_log_compare);
- }
-
--void gaim_log_init(void)
-+void gaim2_log_init(void)
- {
-- gaim_prefs_add_none("/core/logging");
-- gaim_prefs_add_bool("/core/logging/log_ims", FALSE);
-- gaim_prefs_add_bool("/core/logging/log_chats", FALSE);
-- gaim_prefs_add_bool("/core/logging/log_system", FALSE);
-+ gaim2_prefs_add_none("/core/logging");
-+ gaim2_prefs_add_bool("/core/logging/log_ims", FALSE);
-+ gaim2_prefs_add_bool("/core/logging/log_chats", FALSE);
-+ gaim2_prefs_add_bool("/core/logging/log_system", FALSE);
-
-- gaim_prefs_add_string("/core/logging/format", "txt");
-- gaim_prefs_add_bool("/core/logging/include_date_timestamps", FALSE);
-+ gaim2_prefs_add_string("/core/logging/format", "txt");
-+ gaim2_prefs_add_bool("/core/logging/include_date_timestamps", FALSE);
-
-- html_logger = gaim_log_logger_new("html", _("HTML"), 8,
-+ html_logger = gaim2_log_logger_new("html", _("HTML"), 8,
- NULL,
- html_logger_write,
- html_logger_finalize,
- html_logger_list,
- html_logger_read,
-- gaim_log_common_sizer,
-+ gaim2_log_common_sizer,
- NULL,
- html_logger_list_syslog);
-- gaim_log_logger_add(html_logger);
-+ gaim2_log_logger_add(html_logger);
-
-- txt_logger = gaim_log_logger_new("txt", _("Plain text"), 8,
-+ txt_logger = gaim2_log_logger_new("txt", _("Plain text"), 8,
- NULL,
- txt_logger_write,
- txt_logger_finalize,
- txt_logger_list,
- txt_logger_read,
-- gaim_log_common_sizer,
-+ gaim2_log_common_sizer,
- NULL,
- txt_logger_list_syslog);
-- gaim_log_logger_add(txt_logger);
-+ gaim2_log_logger_add(txt_logger);
-
-- old_logger = gaim_log_logger_new("old", _("Old Gaim"), 9,
-+ old_logger = gaim2_log_logger_new("old", _("Old Gaim2"), 9,
- NULL,
- NULL,
- old_logger_finalize,
-@@ -527,36 +527,36 @@ void gaim_log_init(void)
- old_logger_total_size,
- NULL,
- old_logger_get_log_sets);
-- gaim_log_logger_add(old_logger);
-+ gaim2_log_logger_add(old_logger);
-
-- gaim_prefs_connect_callback(NULL, "/core/logging/format",
-+ gaim2_prefs_connect_callback(NULL, "/core/logging/format",
- logger_pref_cb, NULL);
-- gaim_prefs_trigger_callback("/core/logging/format");
-+ gaim2_prefs_trigger_callback("/core/logging/format");
-
-- logsize_users = g_hash_table_new_full((GHashFunc)_gaim_logsize_user_hash,
-- (GEqualFunc)_gaim_logsize_user_equal,
-- (GDestroyNotify)_gaim_logsize_user_free_key, NULL);
-+ logsize_users = g_hash_table_new_full((GHashFunc)_gaim2_logsize_user_hash,
-+ (GEqualFunc)_gaim2_logsize_user_equal,
-+ (GDestroyNotify)_gaim2_logsize_user_free_key, NULL);
- }
-
- /****************************************************************************
- * LOGGERS ******************************************************************
- ****************************************************************************/
-
--void gaim_log_common_writer(GaimLog *log, const char *ext)
-+void gaim2_log_common_writer(Gaim2Log *log, const char *ext)
- {
- char date[64];
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
-
- if (data == NULL)
- {
- /* This log is new */
- char *dir, *filename, *path;
-
-- dir = gaim_log_get_log_dir(log->type, log->name, log->account);
-+ dir = gaim2_log_get_log_dir(log->type, log->name, log->account);
- if (dir == NULL)
- return;
-
-- gaim_build_dir (dir, S_IRUSR | S_IWUSR | S_IXUSR);
-+ gaim2_build_dir (dir, S_IRUSR | S_IWUSR | S_IXUSR);
-
- strftime(date, sizeof(date), "%Y-%m-%d.%H%M%S", localtime(&log->time));
-
-@@ -566,16 +566,16 @@ void gaim_log_common_writer(GaimLog *log
- g_free(dir);
- g_free(filename);
-
-- log->logger_data = data = g_new0(GaimLogCommonLoggerData, 1);
-+ log->logger_data = data = g_new0(Gaim2LogCommonLoggerData, 1);
-
- data->file = g_fopen(path, "a");
- if (data->file == NULL)
- {
-- gaim_debug(GAIM_DEBUG_ERROR, "log",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "log",
- "Could not create log file %s\n", path);
-
- if (log->conv != NULL)
-- gaim_conversation_write(log->conv, NULL, _("Logging of this conversation failed."),
-+ gaim2_conversation_write(log->conv, NULL, _("Logging of this conversation failed."),
- GAIM_MESSAGE_ERROR, time(NULL));
-
- g_free(path);
-@@ -585,7 +585,7 @@ void gaim_log_common_writer(GaimLog *log
- }
- }
-
--GList *gaim_log_common_lister(GaimLogType type, const char *name, GaimAccount *account, const char *ext, GaimLogLogger *logger)
-+GList *gaim2_log_common_lister(Gaim2LogType type, const char *name, Gaim2Account *account, const char *ext, Gaim2LogLogger *logger)
- {
- GDir *dir;
- GList *list = NULL;
-@@ -595,7 +595,7 @@ GList *gaim_log_common_lister(GaimLogTyp
- if(!account)
- return NULL;
-
-- path = gaim_log_get_log_dir(type, name, account);
-+ path = gaim2_log_get_log_dir(type, name, account);
- if (path == NULL)
- return NULL;
-
-@@ -605,15 +605,15 @@ GList *gaim_log_common_lister(GaimLogTyp
- }
-
- while ((filename = g_dir_read_name(dir))) {
-- if (gaim_str_has_suffix(filename, ext) &&
-+ if (gaim2_str_has_suffix(filename, ext) &&
- strlen(filename) == 17 + strlen(ext)) {
-- GaimLog *log;
-- GaimLogCommonLoggerData *data;
-- time_t stamp = gaim_str_to_time(filename, FALSE);
-+ Gaim2Log *log;
-+ Gaim2LogCommonLoggerData *data;
-+ time_t stamp = gaim2_str_to_time(filename, FALSE);
-
-- log = gaim_log_new(type, name, account, NULL, stamp);
-+ log = gaim2_log_new(type, name, account, NULL, stamp);
- log->logger = logger;
-- log->logger_data = data = g_new0(GaimLogCommonLoggerData, 1);
-+ log->logger_data = data = g_new0(Gaim2LogCommonLoggerData, 1);
- data->path = g_build_filename(path, filename, NULL);
- list = g_list_prepend(list, log);
- }
-@@ -623,10 +623,10 @@ GList *gaim_log_common_lister(GaimLogTyp
- return list;
- }
-
--int gaim_log_common_sizer(GaimLog *log)
-+int gaim2_log_common_sizer(Gaim2Log *log)
- {
- struct stat st;
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
-
- if (!data->path || g_stat(data->path, &st))
- st.st_size = 0;
-@@ -638,7 +638,7 @@ int gaim_log_common_sizer(GaimLog *log)
- * functions because they use the same directory structure. */
- static void log_get_log_sets_common(GHashTable *sets)
- {
-- gchar *log_path = g_build_filename(gaim_user_dir(), "logs", NULL);
-+ gchar *log_path = g_build_filename(gaim2_user_dir(), "logs", NULL);
- GDir *log_dir = g_dir_open(log_path, 0, NULL);
- const gchar *protocol;
-
-@@ -661,20 +661,20 @@ static void log_get_log_sets_common(GHas
- }
-
- /* Using g_strdup() to cover the one-in-a-million chance that a
-- * prpl's list_icon function uses gaim_unescape_filename(). */
-- protocol_unescaped = g_strdup(gaim_unescape_filename(protocol));
-+ * prpl's list_icon function uses gaim2_unescape_filename(). */
-+ protocol_unescaped = g_strdup(gaim2_unescape_filename(protocol));
-
- /* Find all the accounts for protocol. */
-- for (account_iter = gaim_accounts_get_all() ; account_iter != NULL ; account_iter = account_iter->next) {
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ for (account_iter = gaim2_accounts_get_all() ; account_iter != NULL ; account_iter = account_iter->next) {
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id((GaimAccount *)account_iter->data));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id((Gaim2Account *)account_iter->data));
- if (!prpl)
- continue;
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-
-- if (!strcmp(protocol_unescaped, prpl_info->list_icon((GaimAccount *)account_iter->data, NULL)))
-+ if (!strcmp(protocol_unescaped, prpl_info->list_icon((Gaim2Account *)account_iter->data, NULL)))
- accounts = g_list_prepend(accounts, account_iter->data);
- }
- g_free(protocol_unescaped);
-@@ -683,7 +683,7 @@ static void log_get_log_sets_common(GHas
- gchar *username_path = g_build_filename(protocol_path, username, NULL);
- GDir *username_dir;
- const gchar *username_unescaped;
-- GaimAccount *account = NULL;
-+ Gaim2Account *account = NULL;
- gchar *name;
-
- if ((username_dir = g_dir_open(username_path, 0, NULL)) == NULL) {
-@@ -692,9 +692,9 @@ static void log_get_log_sets_common(GHas
- }
-
- /* Find the account for username in the list of accounts for protocol. */
-- username_unescaped = gaim_unescape_filename(username);
-+ username_unescaped = gaim2_unescape_filename(username);
- for (account_iter = g_list_first(accounts) ; account_iter != NULL ; account_iter = account_iter->next) {
-- if (!strcmp(((GaimAccount *)account_iter->data)->username, username_unescaped)) {
-+ if (!strcmp(((Gaim2Account *)account_iter->data)->username, username_unescaped)) {
- account = account_iter->data;
- break;
- }
-@@ -703,17 +703,17 @@ static void log_get_log_sets_common(GHas
- /* Don't worry about the cast, name will point to dynamically allocated memory shortly. */
- while ((name = (gchar *)g_dir_read_name(username_dir)) != NULL) {
- size_t len;
-- GaimLogSet *set = g_new0(GaimLogSet, 1);
-+ Gaim2LogSet *set = g_new0(Gaim2LogSet, 1);
-
- /* Unescape the filename. */
-- name = g_strdup(gaim_unescape_filename(name));
-+ name = g_strdup(gaim2_unescape_filename(name));
-
- /* Get the (possibly new) length of name. */
- len = strlen(name);
-
- set->account = account;
- set->name = name;
-- set->normalized_name = g_strdup(gaim_normalize(account, name));
-+ set->normalized_name = g_strdup(gaim2_normalize(account, name));
-
- /* Chat for .chat or .system at the end of the name to determine the type. */
- set->type = GAIM_LOG_IM;
-@@ -734,7 +734,7 @@ static void log_get_log_sets_common(GHas
-
- /* Determine if this (account, name) combination exists as a buddy. */
- if (account != NULL)
-- set->buddy = (gaim_find_buddy(account, name) != NULL);
-+ set->buddy = (gaim2_find_buddy(account, name) != NULL);
-
- log_add_log_set_to_hash(sets, set);
- }
-@@ -753,15 +753,15 @@ static void log_get_log_sets_common(GHas
- ** XML LOGGER **
- ****************/
-
--static const char *str_from_msg_type (GaimMessageFlags type)
-+static const char *str_from_msg_type (Gaim2MessageFlags type)
- {
-
- return "";
-
- }
-
--static void xml_logger_write(GaimLog *log,
-- GaimMessageFlags type,
-+static void xml_logger_write(Gaim2Log *log,
-+ Gaim2MessageFlags type,
- const char *from, time_t time, const char *message)
- {
- char date[64];
-@@ -772,7 +772,7 @@ static void xml_logger_write(GaimLog *lo
- * creating a new file there would result in empty files in the case
- * that you open a convo with someone, but don't say anything.
- */
-- char *dir = gaim_log_get_log_dir(log->type, log->name, log->account);
-+ char *dir = gaim2_log_get_log_dir(log->type, log->name, log->account);
- FILE *file;
-
- if (dir == NULL)
-@@ -780,14 +780,14 @@ static void xml_logger_write(GaimLog *lo
-
- strftime(date, sizeof(date), "%Y-%m-%d.%H%M%S.xml", localtime(&log->time));
-
-- gaim_build_dir (dir, S_IRUSR | S_IWUSR | S_IXUSR);
-+ gaim2_build_dir (dir, S_IRUSR | S_IWUSR | S_IXUSR);
-
- char *filename = g_build_filename(dir, date, NULL);
- g_free(dir);
-
- log->logger_data = g_fopen(filename, "a");
- if (!log->logger_data) {
-- gaim_debug(GAIM_DEBUG_ERROR, "log", "Could not create log file %s\n", filename);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "log", "Could not create log file %s\n", filename);
- g_free(filename);
- return;
- }
-@@ -804,12 +804,12 @@ static void xml_logger_write(GaimLog *lo
- if(!data->file)
- return;
-
-- if (gaim_prefs_get_bool("/core/logging/include_date_timestamps"))
-+ if (gaim2_prefs_get_bool("/core/logging/include_date_timestamps"))
- strftime(date, sizeof(date), "%Y-%m-%d %H:%M:%S", localtime(&time));
- else
- strftime(date, sizeof(date), "%H:%M:%S", localtime(&time));
-
-- gaim_markup_html_to_xhtml(message, &xhtml, NULL);
-+ gaim2_markup_html_to_xhtml(message, &xhtml, NULL);
- if (from)
- fprintf(log->logger_data, "<message %s %s from='%s' time='%s'>%s</message>\n",
- str_from_msg_type(type),
-@@ -826,7 +826,7 @@ static void xml_logger_write(GaimLog *lo
- g_free(xhtml);
- }
-
-- static void xml_logger_finalize(GaimLog *log)
-+ static void xml_logger_finalize(Gaim2Log *log)
- {
- if (log->logger_data) {
- fprintf(log->logger_data, "</conversation>\n");
-@@ -835,12 +835,12 @@ static void xml_logger_write(GaimLog *lo
- }
- }
-
--static GList *xml_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *xml_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
-- return gaim_log_common_lister(type, sn, account, ".xml", &xml_logger);
-+ return gaim2_log_common_lister(type, sn, account, ".xml", &xml_logger);
- }
-
--static GaimLogLogger xml_logger = {
-+static Gaim2LogLogger xml_logger = {
- N_("XML"), "xml",
- NULL,
- xml_logger_write,
-@@ -856,18 +856,18 @@ static GaimLogLogger xml_logger = {
- ** HTML LOGGER *************
- ****************************/
-
--static void html_logger_write(GaimLog *log, GaimMessageFlags type,
-+static void html_logger_write(Gaim2Log *log, Gaim2MessageFlags type,
- const char *from, time_t time, const char *message)
- {
- char *msg_fixed;
- char date[64];
-- GaimPlugin *plugin = gaim_find_prpl(gaim_account_get_protocol_id(log->account));
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2Plugin *plugin = gaim2_find_prpl(gaim2_account_get_protocol_id(log->account));
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
-
- if(!data) {
- const char *prpl =
- GAIM_PLUGIN_PROTOCOL_INFO(plugin)->list_icon(log->account, NULL);
-- gaim_log_common_writer(log, ".html");
-+ gaim2_log_common_writer(log, ".html");
-
- data = log->logger_data;
-
-@@ -880,11 +880,11 @@ static void html_logger_write(GaimLog *l
- fprintf(data->file, "<meta http-equiv=\"content-type\" content=\"text/html; charset=UTF-8\">");
- fprintf(data->file, "<title>");
- fprintf(data->file, "Conversation with %s at %s on %s (%s)",
-- log->name, date, gaim_account_get_username(log->account), prpl);
-+ log->name, date, gaim2_account_get_username(log->account), prpl);
- fprintf(data->file, "</title></head><body>");
- fprintf(data->file,
- "<h3>Conversation with %s at %s on %s (%s)</h3>\n",
-- log->name, date, gaim_account_get_username(log->account), prpl);
-+ log->name, date, gaim2_account_get_username(log->account), prpl);
-
- }
-
-@@ -892,13 +892,13 @@ static void html_logger_write(GaimLog *l
- if(!data->file)
- return;
-
-- gaim_markup_html_to_xhtml(message, &msg_fixed, NULL);
-+ gaim2_markup_html_to_xhtml(message, &msg_fixed, NULL);
-
- if(log->type == GAIM_LOG_SYSTEM){
- strftime(date, sizeof(date), "%Y-%m-%d %H:%M:%S", localtime(&time));
- fprintf(data->file, "---- %s @ %s ----<br/>\n", msg_fixed, date);
- } else {
-- if (gaim_prefs_get_bool("/core/logging/include_date_timestamps"))
-+ if (gaim2_prefs_get_bool("/core/logging/include_date_timestamps"))
- strftime(date, sizeof(date), "%Y-%m-%d %H:%M:%S", localtime(&time));
- else
- strftime(date, sizeof(date), "%H:%M:%S", localtime(&time));
-@@ -914,14 +914,14 @@ static void html_logger_write(GaimLog *l
- else if (type & GAIM_MESSAGE_RECV)
- fprintf(data->file, _("<font color=\"#A82F2F\"><font size=\"2\">(%s)</font> <b>%s &lt;AUTO-REPLY&gt;:</b></font> %s<br/>\n"), date, from, msg_fixed);
- } else if (type & GAIM_MESSAGE_RECV) {
-- if(gaim_message_meify(msg_fixed, -1))
-+ if(gaim2_message_meify(msg_fixed, -1))
- fprintf(data->file, "<font color=\"#062585\"><font size=\"2\">(%s)</font> <b>***%s</b></font> %s<br/>\n",
- date, from, msg_fixed);
- else
- fprintf(data->file, "<font color=\"#A82F2F\"><font size=\"2\">(%s)</font> <b>%s:</b></font> %s<br/>\n",
- date, from, msg_fixed);
- } else if (type & GAIM_MESSAGE_SEND) {
-- if(gaim_message_meify(msg_fixed, -1))
-+ if(gaim2_message_meify(msg_fixed, -1))
- fprintf(data->file, "<font color=\"#062585\"><font size=\"2\">(%s)</font> <b>***%s</b></font> %s<br/>\n",
- date, from, msg_fixed);
- else
-@@ -934,9 +934,9 @@ static void html_logger_write(GaimLog *l
- fflush(data->file);
- }
-
--static void html_logger_finalize(GaimLog *log)
-+static void html_logger_finalize(Gaim2Log *log)
- {
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
- if (data) {
- if(data->file) {
- fprintf(data->file, "</body></html>");
-@@ -947,20 +947,20 @@ static void html_logger_finalize(GaimLog
- }
- }
-
--static GList *html_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *html_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
-- return gaim_log_common_lister(type, sn, account, ".html", html_logger);
-+ return gaim2_log_common_lister(type, sn, account, ".html", html_logger);
- }
-
--static GList *html_logger_list_syslog(GaimAccount *account)
-+static GList *html_logger_list_syslog(Gaim2Account *account)
- {
-- return gaim_log_common_lister(GAIM_LOG_SYSTEM, ".system", account, ".html", html_logger);
-+ return gaim2_log_common_lister(GAIM_LOG_SYSTEM, ".system", account, ".html", html_logger);
- }
-
--static char *html_logger_read(GaimLog *log, GaimLogReadFlags *flags)
-+static char *html_logger_read(Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- char *read, *minus_header;
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
- *flags = GAIM_LOG_READ_NO_NEWLINE;
- if (!data || !data->path)
- return g_strdup(_("<font color=\"red\"><b>Unable to find log path!</b></font>"));
-@@ -982,13 +982,13 @@ static char *html_logger_read(GaimLog *l
- ** PLAIN TEXT LOGGER *******
- ****************************/
-
--static void txt_logger_write(GaimLog *log,
-- GaimMessageFlags type,
-+static void txt_logger_write(Gaim2Log *log,
-+ Gaim2MessageFlags type,
- const char *from, time_t time, const char *message)
- {
- char date[64];
-- GaimPlugin *plugin = gaim_find_prpl(gaim_account_get_protocol_id(log->account));
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2Plugin *plugin = gaim2_find_prpl(gaim2_account_get_protocol_id(log->account));
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
- char *stripped = NULL;
-
- if (data == NULL) {
-@@ -998,7 +998,7 @@ static void txt_logger_write(GaimLog *lo
- */
- const char *prpl =
- GAIM_PLUGIN_PROTOCOL_INFO(plugin)->list_icon(log->account, NULL);
-- gaim_log_common_writer(log, ".txt");
-+ gaim2_log_common_writer(log, ".txt");
-
- data = log->logger_data;
-
-@@ -1008,20 +1008,20 @@ static void txt_logger_write(GaimLog *lo
-
- strftime(date, sizeof(date), "%Y-%m-%d %H:%M:%S", localtime(&log->time));
- fprintf(data->file, "Conversation with %s at %s on %s (%s)\n",
-- log->name, date, gaim_account_get_username(log->account), prpl);
-+ log->name, date, gaim2_account_get_username(log->account), prpl);
- }
-
- /* if we can't write to the file, give up before we hurt ourselves */
- if(!data->file)
- return;
-
-- stripped = gaim_markup_strip_html(message);
-+ stripped = gaim2_markup_strip_html(message);
-
- if(log->type == GAIM_LOG_SYSTEM){
- strftime(date, sizeof(date), "%Y-%m-%d %H:%M:%S", localtime(&time));
- fprintf(data->file, "---- %s @ %s ----\n", stripped, date);
- } else {
-- if (gaim_prefs_get_bool("/core/logging/include_date_timestamps"))
-+ if (gaim2_prefs_get_bool("/core/logging/include_date_timestamps"))
- strftime(date, sizeof(date), "%Y-%m-%d %H:%M:%S", localtime(&time));
- else
- strftime(date, sizeof(date), "%H:%M:%S", localtime(&time));
-@@ -1032,7 +1032,7 @@ static void txt_logger_write(GaimLog *lo
- fprintf(data->file, _("(%s) %s <AUTO-REPLY>: %s\n"), date,
- from, stripped);
- } else {
-- if(gaim_message_meify(stripped, -1))
-+ if(gaim2_message_meify(stripped, -1))
- fprintf(data->file, "(%s) ***%s %s\n", date, from,
- stripped);
- else
-@@ -1056,9 +1056,9 @@ static void txt_logger_write(GaimLog *lo
- g_free(stripped);
- }
-
--static void txt_logger_finalize(GaimLog *log)
-+static void txt_logger_finalize(Gaim2Log *log)
- {
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
- if (data) {
- if(data->file)
- fclose(data->file);
-@@ -1068,20 +1068,20 @@ static void txt_logger_finalize(GaimLog
- }
- }
-
--static GList *txt_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *txt_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
-- return gaim_log_common_lister(type, sn, account, ".txt", txt_logger);
-+ return gaim2_log_common_lister(type, sn, account, ".txt", txt_logger);
- }
-
--static GList *txt_logger_list_syslog(GaimAccount *account)
-+static GList *txt_logger_list_syslog(Gaim2Account *account)
- {
-- return gaim_log_common_lister(GAIM_LOG_SYSTEM, ".system", account, ".txt", txt_logger);
-+ return gaim2_log_common_lister(GAIM_LOG_SYSTEM, ".system", account, ".txt", txt_logger);
- }
-
--static char *txt_logger_read(GaimLog *log, GaimLogReadFlags *flags)
-+static char *txt_logger_read(Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- char *read, *minus_header, *minus_header2;
-- GaimLogCommonLoggerData *data = log->logger_data;
-+ Gaim2LogCommonLoggerData *data = log->logger_data;
- *flags = 0;
- if (!data || !data->path)
- return g_strdup(_("<font color=\"red\"><b>Unable to find log path!</b></font>"));
-@@ -1110,35 +1110,35 @@ static char *txt_logger_read(GaimLog *lo
- */
-
- struct old_logger_data {
-- GaimStringref *pathref;
-+ Gaim2Stringref *pathref;
- int offset;
- int length;
- };
-
--static GList *old_logger_list(GaimLogType type, const char *sn, GaimAccount *account)
-+static GList *old_logger_list(Gaim2LogType type, const char *sn, Gaim2Account *account)
- {
- FILE *file;
- char buf[BUF_LONG];
- struct tm tm;
- char month[4];
- struct old_logger_data *data = NULL;
-- char *logfile = g_strdup_printf("%s.log", gaim_normalize(account, sn));
-- char *pathstr = g_build_filename(gaim_user_dir(), "logs", logfile, NULL);
-- GaimStringref *pathref = gaim_stringref_new(pathstr);
-+ char *logfile = g_strdup_printf("%s.log", gaim2_normalize(account, sn));
-+ char *pathstr = g_build_filename(gaim2_user_dir(), "logs", logfile, NULL);
-+ Gaim2Stringref *pathref = gaim2_stringref_new(pathstr);
- char *newlog;
- int logfound = 0;
- int lastoff = 0;
- int newlen;
- time_t lasttime = 0;
-
-- GaimLog *log = NULL;
-+ Gaim2Log *log = NULL;
- GList *list = NULL;
-
- g_free(logfile);
- g_free(pathstr);
-
-- if (!(file = g_fopen(gaim_stringref_value(pathref), "rb"))) {
-- gaim_stringref_unref(pathref);
-+ if (!(file = g_fopen(gaim2_stringref_value(pathref), "rb"))) {
-+ gaim2_stringref_unref(pathref);
- return NULL;
- }
-
-@@ -1173,13 +1173,13 @@ static GList *old_logger_list(GaimLogTyp
- newlen--;
-
- if (newlen != 0) {
-- log = gaim_log_new(GAIM_LOG_IM, sn, account, NULL, -1);
-+ log = gaim2_log_new(GAIM_LOG_IM, sn, account, NULL, -1);
- log->logger = old_logger;
- log->time = lasttime;
- data = g_new0(struct old_logger_data, 1);
- data->offset = lastoff;
- data->length = newlen;
-- data->pathref = gaim_stringref_ref(pathref);
-+ data->pathref = gaim2_stringref_ref(pathref);
- log->logger_data = data;
- list = g_list_prepend(list, log);
- }
-@@ -1224,27 +1224,27 @@ static GList *old_logger_list(GaimLogTyp
-
- if (logfound) {
- if ((newlen = ftell(file) - lastoff) != 0) {
-- log = gaim_log_new(GAIM_LOG_IM, sn, account, NULL, -1);
-+ log = gaim2_log_new(GAIM_LOG_IM, sn, account, NULL, -1);
- log->logger = old_logger;
- log->time = lasttime;
- data = g_new0(struct old_logger_data, 1);
- data->offset = lastoff;
- data->length = newlen;
-- data->pathref = gaim_stringref_ref(pathref);
-+ data->pathref = gaim2_stringref_ref(pathref);
- log->logger_data = data;
- list = g_list_prepend(list, log);
- }
- }
-
-- gaim_stringref_unref(pathref);
-+ gaim2_stringref_unref(pathref);
- fclose(file);
- return list;
- }
-
--static int old_logger_total_size(GaimLogType type, const char *name, GaimAccount *account)
-+static int old_logger_total_size(Gaim2LogType type, const char *name, Gaim2Account *account)
- {
-- char *logfile = g_strdup_printf("%s.log", gaim_normalize(account, name));
-- char *pathstr = g_build_filename(gaim_user_dir(), "logs", logfile, NULL);
-+ char *logfile = g_strdup_printf("%s.log", gaim2_normalize(account, name));
-+ char *pathstr = g_build_filename(gaim2_user_dir(), "logs", logfile, NULL);
- int size;
- struct stat st;
-
-@@ -1259,10 +1259,10 @@ static int old_logger_total_size(GaimLog
- return size;
- }
-
--static char * old_logger_read (GaimLog *log, GaimLogReadFlags *flags)
-+static char * old_logger_read (Gaim2Log *log, Gaim2LogReadFlags *flags)
- {
- struct old_logger_data *data = log->logger_data;
-- FILE *file = g_fopen(gaim_stringref_value(data->pathref), "rb");
-+ FILE *file = g_fopen(gaim2_stringref_value(data->pathref), "rb");
- char *tmp, *read = g_malloc(data->length + 1);
- fseek(file, data->offset, SEEK_SET);
- fread(read, data->length, 1, file);
-@@ -1279,18 +1279,18 @@ static char * old_logger_read (GaimLog *
- return read;
- }
-
--static int old_logger_size (GaimLog *log)
-+static int old_logger_size (Gaim2Log *log)
- {
- struct old_logger_data *data = log->logger_data;
- return data ? data->length : 0;
- }
-
--static void old_logger_get_log_sets(GaimLogSetCallback cb, GHashTable *sets)
-+static void old_logger_get_log_sets(Gaim2LogSetCallback cb, GHashTable *sets)
- {
-- char *log_path = g_build_filename(gaim_user_dir(), "logs", NULL);
-+ char *log_path = g_build_filename(gaim2_user_dir(), "logs", NULL);
- GDir *log_dir = g_dir_open(log_path, 0, NULL);
- gchar *name;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
- g_free(log_path);
- if (log_dir == NULL)
-@@ -1300,11 +1300,11 @@ static void old_logger_get_log_sets(Gaim
- while ((name = (gchar *)g_dir_read_name(log_dir)) != NULL) {
- size_t len;
- gchar *ext;
-- GaimLogSet *set;
-+ Gaim2LogSet *set;
- gboolean found = FALSE;
-
- /* Unescape the filename. */
-- name = g_strdup(gaim_unescape_filename(name));
-+ name = g_strdup(gaim2_unescape_filename(name));
-
- /* Get the (possibly new) length of name. */
- len = strlen(name);
-@@ -1321,7 +1321,7 @@ static void old_logger_get_log_sets(Gaim
- continue;
- }
-
-- set = g_new0(GaimLogSet, 1);
-+ set = g_new0(Gaim2LogSet, 1);
-
- /* Chat for .chat at the end of the name to determine the type. */
- *ext = '\0';
-@@ -1337,7 +1337,7 @@ static void old_logger_get_log_sets(Gaim
- set->name = set->normalized_name = name;
-
- /* Search the buddy list to find the account and to determine if this is a buddy. */
-- for (gnode = gaim_get_blist()->root; !found && gnode != NULL; gnode = gnode->next)
-+ for (gnode = gaim2_get_blist()->root; !found && gnode != NULL; gnode = gnode->next)
- {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-@@ -1349,7 +1349,7 @@ static void old_logger_get_log_sets(Gaim
-
- for (bnode = cnode->child; !found && bnode != NULL; bnode = bnode->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)bnode;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)bnode;
-
- if (!strcmp(buddy->name, name)) {
- set->account = buddy->account;
-@@ -1365,9 +1365,9 @@ static void old_logger_get_log_sets(Gaim
- g_dir_close(log_dir);
- }
-
--static void old_logger_finalize(GaimLog *log)
-+static void old_logger_finalize(Gaim2Log *log)
- {
- struct old_logger_data *data = log->logger_data;
-- gaim_stringref_unref(data->pathref);
-+ gaim2_stringref_unref(data->pathref);
- g_free(data);
- }
-diff -prNu ./src/log.h ./src/log.h
---- ./src/log.h 2005-09-11 07:14:52.000000000 +0200
-+++ ./src/log.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file log.h Logging API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,91 +32,91 @@
- * DATA STRUCTURES **************************************
- ********************************************************/
-
--typedef struct _GaimLog GaimLog;
--typedef struct _GaimLogLogger GaimLogLogger;
--typedef struct _GaimLogCommonLoggerData GaimLogCommonLoggerData;
--typedef struct _GaimLogSet GaimLogSet;
-+typedef struct _Gaim2Log Gaim2Log;
-+typedef struct _Gaim2LogLogger Gaim2LogLogger;
-+typedef struct _Gaim2LogCommonLoggerData Gaim2LogCommonLoggerData;
-+typedef struct _Gaim2LogSet Gaim2LogSet;
-
- typedef enum {
- GAIM_LOG_IM,
- GAIM_LOG_CHAT,
- GAIM_LOG_SYSTEM
--} GaimLogType;
-+} Gaim2LogType;
-
- typedef enum {
- GAIM_LOG_READ_NO_NEWLINE = 1
--} GaimLogReadFlags;
-+} Gaim2LogReadFlags;
-
- #include "account.h"
- #include "conversation.h"
-
--typedef void (*GaimLogSetCallback) (GHashTable *sets, GaimLogSet *set);
-+typedef void (*Gaim2LogSetCallback) (GHashTable *sets, Gaim2LogSet *set);
-
- /**
- * A log logger.
- *
-- * This struct gets filled out and is included in the GaimLog. It contains everything
-+ * This struct gets filled out and is included in the Gaim2Log. It contains everything
- * needed to write and read from logs.
- */
--struct _GaimLogLogger {
-+struct _Gaim2LogLogger {
- char *name; /**< The logger's name */
- char *id; /**< an identifier to refer to this logger */
-
- /** This gets called when the log is first created.
- I don't think this is actually needed. */
-- void (*create)(GaimLog *log);
-+ void (*create)(Gaim2Log *log);
-
- /** This is used to write to the log file */
-- void (*write)(GaimLog *log,
-- GaimMessageFlags type,
-+ void (*write)(Gaim2Log *log,
-+ Gaim2MessageFlags type,
- const char *from,
- time_t time,
- const char *message);
-
- /** Called when the log is destroyed */
-- void (*finalize)(GaimLog *log);
-+ void (*finalize)(Gaim2Log *log);
-
-- /** This function returns a sorted GList of available GaimLogs */
-- GList *(*list)(GaimLogType type, const char *name, GaimAccount *account);
-+ /** This function returns a sorted GList of available Gaim2Logs */
-+ GList *(*list)(Gaim2LogType type, const char *name, Gaim2Account *account);
-
- /** Given one of the logs returned by the logger's list function,
- * this returns the contents of the log in GtkIMHtml markup */
-- char *(*read)(GaimLog *log, GaimLogReadFlags *flags);
-+ char *(*read)(Gaim2Log *log, Gaim2LogReadFlags *flags);
-
- /** Given one of the logs returned by the logger's list function,
- * this returns the size of the log in bytes */
-- int (*size)(GaimLog *log);
-+ int (*size)(Gaim2Log *log);
-
- /** Returns the total size of all the logs. If this is undefined a default
- * implementation is used */
-- int (*total_size)(GaimLogType type, const char *name, GaimAccount *account);
-+ int (*total_size)(Gaim2LogType type, const char *name, Gaim2Account *account);
-
-- /** This function returns a sorted GList of available system GaimLogs */
-- GList *(*list_syslog)(GaimAccount *account);
-+ /** This function returns a sorted GList of available system Gaim2Logs */
-+ GList *(*list_syslog)(Gaim2Account *account);
-
-- /** Adds GaimLogSets to a GHashTable. By passing the data in the GaimLogSets
-- * to list, the caller can get every available GaimLog from the logger.
-- * Loggers using gaim_log_common_writer() (or otherwise storing their
-+ /** Adds Gaim2LogSets to a GHashTable. By passing the data in the Gaim2LogSets
-+ * to list, the caller can get every available Gaim2Log from the logger.
-+ * Loggers using gaim2_log_common_writer() (or otherwise storing their
- * logs in the same directory structure as the stock loggers) do not
- * need to implement this function.
- *
-- * Loggers which implement this function must create a GaimLogSet,
-- * then call @a cb with @a sets and the newly created GaimLogSet. */
-- void (*get_log_sets)(GaimLogSetCallback cb, GHashTable *sets);
-+ * Loggers which implement this function must create a Gaim2LogSet,
-+ * then call @a cb with @a sets and the newly created Gaim2LogSet. */
-+ void (*get_log_sets)(Gaim2LogSetCallback cb, GHashTable *sets);
- };
-
- /**
- * A log. Not the wooden type.
- */
--struct _GaimLog {
-- GaimLogType type; /**< The type of log this is */
-+struct _Gaim2Log {
-+ Gaim2LogType type; /**< The type of log this is */
- char *name; /**< The name of this log */
-- GaimAccount *account; /**< The account this log is taking
-+ Gaim2Account *account; /**< The account this log is taking
- place on */
-- GaimConversation *conv; /**< The conversation being logged */
-+ Gaim2Conversation *conv; /**< The conversation being logged */
- time_t time; /**< The time this conversation
- started */
-- GaimLogLogger *logger; /**< The logging mechanism this log
-+ Gaim2LogLogger *logger; /**< The logging mechanism this log
- is to use */
- void *logger_data; /**< Data used by the log logger */
- };
-@@ -125,7 +125,7 @@ struct _GaimLog {
- * A common logger_data struct containing a file handle and path, as well
- * as a pointer to something else for additional data.
- */
--struct _GaimLogCommonLoggerData {
-+struct _Gaim2LogCommonLoggerData {
- char *path;
- FILE *file;
- void *extra_data;
-@@ -134,13 +134,13 @@ struct _GaimLogCommonLoggerData {
- /**
- * Describes available logs.
- *
-- * By passing the elements of this struct to gaim_log_get_logs(), the caller
-- * can get all available GaimLogs.
-+ * By passing the elements of this struct to gaim2_log_get_logs(), the caller
-+ * can get all available Gaim2Logs.
- */
--struct _GaimLogSet {
-- GaimLogType type; /**< The type of logs available */
-+struct _Gaim2LogSet {
-+ Gaim2LogType type; /**< The type of logs available */
- char *name; /**< The name of the logs available */
-- GaimAccount *account; /**< The account the available logs
-+ Gaim2Account *account; /**< The account the available logs
- took place on. This will be
- @c NULL if the account no longer
- exists. (Depending on a
-@@ -175,15 +175,15 @@ extern "C" {
- * @param time The time this conversation started
- * @return The new log
- */
--GaimLog *gaim_log_new(GaimLogType type, const char *name, GaimAccount *account,
-- GaimConversation *conv, time_t time);
-+Gaim2Log *gaim2_log_new(Gaim2LogType type, const char *name, Gaim2Account *account,
-+ Gaim2Conversation *conv, time_t time);
-
- /**
- * Frees a log
- *
- * @param log The log to destroy
- */
--void gaim_log_free(GaimLog *log);
-+void gaim2_log_free(Gaim2Log *log);
-
- /**
- * Writes to a log file. Assumes you have checked preferences already.
-@@ -195,8 +195,8 @@ void gaim_log_free(GaimLog *log);
- * @param time A timestamp in UNIX time
- * @param message The message to log
- */
--void gaim_log_write(GaimLog *log,
-- GaimMessageFlags type,
-+void gaim2_log_write(Gaim2Log *log,
-+ Gaim2MessageFlags type,
- const char *from,
- time_t time,
- const char *message);
-@@ -207,9 +207,9 @@ void gaim_log_write(GaimLog *log,
- * @param log The log to read from
- * @param flags The returned logging flags.
- *
-- * @return The contents of this log in Gaim Markup.
-+ * @return The contents of this log in Gaim2 Markup.
- */
--char *gaim_log_read(GaimLog *log, GaimLogReadFlags *flags);
-+char *gaim2_log_read(Gaim2Log *log, Gaim2LogReadFlags *flags);
-
- /**
- * Returns a list of all available logs
-@@ -217,35 +217,35 @@ char *gaim_log_read(GaimLog *log, GaimLo
- * @param type The type of the log
- * @param name The name of the log
- * @param account The account
-- * @return A sorted list of GaimLogs
-+ * @return A sorted list of Gaim2Logs
- */
--GList *gaim_log_get_logs(GaimLogType type, const char *name, GaimAccount *account);
-+GList *gaim2_log_get_logs(Gaim2LogType type, const char *name, Gaim2Account *account);
-
- /**
-- * Returns a GHashTable of GaimLogSets.
-+ * Returns a GHashTable of Gaim2LogSets.
- *
- * A "log set" here means the information necessary to gather the
-- * GaimLogs for a given buddy/chat. This information would be passed
-- * to gaim_log_list to get a list of GaimLogs.
-+ * Gaim2Logs for a given buddy/chat. This information would be passed
-+ * to gaim2_log_list to get a list of Gaim2Logs.
- *
- * The primary use of this function is to get a list of everyone the
- * user has ever talked to (assuming he or she uses logging).
- *
- * The GHashTable that's returned will free all log sets in it when
-- * destroyed. If a GaimLogSet is removed from the GHashTable, it
-- * must be freed with gaim_log_set_free().
-+ * destroyed. If a Gaim2LogSet is removed from the GHashTable, it
-+ * must be freed with gaim2_log_set_free().
- *
-- * @return A GHashTable of all available unique GaimLogSets
-+ * @return A GHashTable of all available unique Gaim2LogSets
- */
--GHashTable *gaim_log_get_log_sets(void);
-+GHashTable *gaim2_log_get_log_sets(void);
-
- /**
- * Returns a list of all available system logs
- *
- * @param account The account
-- * @return A sorted list of GaimLogs
-+ * @return A sorted list of Gaim2Logs
- */
--GList *gaim_log_get_system_logs(GaimAccount *account);
-+GList *gaim2_log_get_system_logs(Gaim2Account *account);
-
- /**
- * Returns the size of a log
-@@ -253,7 +253,7 @@ GList *gaim_log_get_system_logs(GaimAcco
- * @param log The log
- * @return The size of the log, in bytes
- */
--int gaim_log_get_size(GaimLog *log);
-+int gaim2_log_get_size(Gaim2Log *log);
-
- /**
- * Returns the size, in bytes, of all available logs in this conversation
-@@ -263,44 +263,44 @@ int gaim_log_get_size(GaimLog *log);
- * @param account The account
- * @return The size in bytes
- */
--int gaim_log_get_total_size(GaimLogType type, const char *name, GaimAccount *account);
-+int gaim2_log_get_total_size(Gaim2LogType type, const char *name, Gaim2Account *account);
-
- /**
-- * Returns the default logger directory Gaim uses for a given account
-- * and username. This would be where Gaim stores logs created by
-+ * Returns the default logger directory Gaim2 uses for a given account
-+ * and username. This would be where Gaim2 stores logs created by
- * the built-in text or HTML loggers.
- *
- * @param type The type of the log.
- * @param name The name of the log.
- * @param account The account.
-- * @return The default logger directory for Gaim.
-+ * @return The default logger directory for Gaim2.
- */
--char *gaim_log_get_log_dir(GaimLogType type, const char *name, GaimAccount *account);
-+char *gaim2_log_get_log_dir(Gaim2LogType type, const char *name, Gaim2Account *account);
-
- /**
-- * Implements GCompareFunc for GaimLogs
-+ * Implements GCompareFunc for Gaim2Logs
- *
-- * @param y A GaimLog
-- * @param z Another GaimLog
-+ * @param y A Gaim2Log
-+ * @param z Another Gaim2Log
- * @return A value as specified by GCompareFunc
- */
--gint gaim_log_compare(gconstpointer y, gconstpointer z);
-+gint gaim2_log_compare(gconstpointer y, gconstpointer z);
-
- /**
-- * Implements GCompareFunc for GaimLogSets
-+ * Implements GCompareFunc for Gaim2LogSets
- *
-- * @param y A GaimLogSet
-- * @param z Another GaimLogSet
-+ * @param y A Gaim2LogSet
-+ * @param z Another Gaim2LogSet
- * @return A value as specified by GCompareFunc
- */
--gint gaim_log_set_compare(gconstpointer y, gconstpointer z);
-+gint gaim2_log_set_compare(gconstpointer y, gconstpointer z);
-
- /**
- * Frees a log set
- *
- * @param set The log set to destroy
- */
--void gaim_log_set_free(GaimLogSet *set);
-+void gaim2_log_set_free(Gaim2LogSet *set);
-
- /*@}*/
-
-@@ -310,22 +310,22 @@ void gaim_log_set_free(GaimLogSet *set);
- /*@{*/
-
- /**
-- * Opens a new log file in the standard Gaim log location
-+ * Opens a new log file in the standard Gaim2 log location
- * with the given file extension, named for the current time,
- * for writing. If a log file is already open, the existing
- * file handle is retained. The log's logger_data value is
-- * set to a GaimLogCommonLoggerData struct containing the log
-+ * set to a Gaim2LogCommonLoggerData struct containing the log
- * file handle and log path.
- *
- * @param log The log to write to.
- * @param ext The file extension to give to this log file.
- */
--void gaim_log_common_writer(GaimLog *log, const char *ext);
-+void gaim2_log_common_writer(Gaim2Log *log, const char *ext);
-
- /**
-- * Returns a sorted GList of GaimLogs of the requested type.
-+ * Returns a sorted GList of Gaim2Logs of the requested type.
- * This function should only be used with logs that are written
-- * with gaim_log_common_writer().
-+ * with gaim2_log_common_writer().
- *
- * @param type The type of the logs being listed.
- * @param name The name of the log.
-@@ -333,22 +333,22 @@ void gaim_log_common_writer(GaimLog *log
- * @param ext The file extension this log format uses.
- * @param logger A reference to the logger struct for this log.
- *
-- * @return A sorted GList of GaimLogs matching the parameters.
-+ * @return A sorted GList of Gaim2Logs matching the parameters.
- */
--GList *gaim_log_common_lister(GaimLogType type, const char *name,
-- GaimAccount *account, const char *ext,
-- GaimLogLogger *logger);
-+GList *gaim2_log_common_lister(Gaim2LogType type, const char *name,
-+ Gaim2Account *account, const char *ext,
-+ Gaim2LogLogger *logger);
-
- /**
-- * Returns the size of a given GaimLog.
-+ * Returns the size of a given Gaim2Log.
- * This function should only be used with logs that are written
-- * with gaim_log_common_writer().
-+ * with gaim2_log_common_writer().
- *
-- * @param log The GaimLog to size.
-+ * @param log The Gaim2Log to size.
- *
- * @return An integer indicating the size of the log in bytes.
- */
--int gaim_log_common_sizer(GaimLog *log);
-+int gaim2_log_common_sizer(Gaim2Log *log);
- /*@}*/
-
- /******************************************/
-@@ -365,7 +365,7 @@ int gaim_log_common_sizer(GaimLog *log);
- * functions are currently available (in order): @c create,
- * @c write, @c finalize, @c list, @c read, @c size,
- * @c total_size, @c list_syslog, @c get_log_sets. For
-- * details on these functions, see GaimLogLogger.
-+ * details on these functions, see Gaim2LogLogger.
- * Functions may not be skipped. For example, passing
- * @c create and @c write is acceptable (for a total of
- * two functions). Passing @c create and @c finalize,
-@@ -375,21 +375,21 @@ int gaim_log_common_sizer(GaimLog *log);
- *
- * @return The new logger
- */
--GaimLogLogger *gaim_log_logger_new(const char *id, const char *name, int functions, ...);
-+Gaim2LogLogger *gaim2_log_logger_new(const char *id, const char *name, int functions, ...);
-
- /**
- * Frees a logger
- *
- * @param logger The logger to free
- */
--void gaim_log_logger_free(GaimLogLogger *logger);
-+void gaim2_log_logger_free(Gaim2LogLogger *logger);
-
- /**
- * Adds a new logger
- *
- * @param logger The new logger to add
- */
--void gaim_log_logger_add (GaimLogLogger *logger);
-+void gaim2_log_logger_add (Gaim2LogLogger *logger);
-
- /**
- *
-@@ -397,7 +397,7 @@ void gaim_log_logger_add (GaimLogLogger
- *
- * @param logger The logger to remove
- */
--void gaim_log_logger_remove (GaimLogLogger *logger);
-+void gaim2_log_logger_remove (Gaim2LogLogger *logger);
-
- /**
- *
-@@ -405,7 +405,7 @@ void gaim_log_logger_remove (GaimLogLogg
- *
- * @param logger The logger to set
- */
--void gaim_log_logger_set (GaimLogLogger *logger);
-+void gaim2_log_logger_set (Gaim2LogLogger *logger);
-
- /**
- *
-@@ -413,7 +413,7 @@ void gaim_log_logger_set (GaimLogLogger
- *
- * @return logger The current logger
- */
--GaimLogLogger *gaim_log_logger_get (void);
-+Gaim2LogLogger *gaim2_log_logger_get (void);
-
- /**
- * Returns a GList containing the IDs and names of the registered
-@@ -421,12 +421,12 @@ GaimLogLogger *gaim_log_logger_get (void
- *
- * @return The list of IDs and names.
- */
--GList *gaim_log_logger_get_options(void);
-+GList *gaim2_log_logger_get_options(void);
-
- /**
- * Initializes the log subsystem.
- */
--void gaim_log_init(void);
-+void gaim2_log_init(void);
- /*@}*/
-
-
-diff -prNu ./src/Makefile.am ./src/Makefile.am
---- ./src/Makefile.am 2005-12-22 19:28:08.000000000 +0100
-+++ ./src/Makefile.am 2006-01-05 15:17:42.000000000 +0100
-@@ -66,7 +66,7 @@ else
- SUBDIRS = protocols
- endif
-
--gaim_coresources = \
-+gaim2_coresources = \
- account.c \
- accountopt.c \
- blist.c \
-@@ -113,7 +113,7 @@ gaim_coresources = \
- xmlnode.c \
- whiteboard.c
-
--gaim_coreheaders = \
-+gaim2_coreheaders = \
- account.h \
- accountopt.h \
- blist.h \
-@@ -183,14 +183,14 @@ dbus_headers = dbus-bindings.h dbus-gai
-
- dbus_exported = dbus-useful.h dbus-define-api.h account.h blist.h connection.h conversation.h core.h roomlist.h status.h server.h
-
--gaim_build_coreheaders = $(addprefix $(srcdir)/, $(gaim_coreheaders))
-+gaim2_build_coreheaders = $(addprefix $(srcdir)/, $(gaim2_coreheaders))
- dbus_build_exported = $(addprefix $(srcdir)/, $(dbus_exported))
-
--dbus-types.c: dbus-analyze-types.py $(gaim_coreheaders)
-- cat $(gaim_build_coreheaders) | $(PYTHON) $(srcdir)/dbus-analyze-types.py --pattern=GAIM_DBUS_DEFINE_TYPE\(%s\) > $@
-+dbus-types.c: dbus-analyze-types.py $(gaim2_coreheaders)
-+ cat $(gaim2_build_coreheaders) | $(PYTHON) $(srcdir)/dbus-analyze-types.py --pattern=GAIM_DBUS_DEFINE_TYPE\(%s\) > $@
-
- dbus-types.h: dbus-analyze-types.py $(dbus_coreheaders)
-- cat $(gaim_build_coreheaders) | $(PYTHON) $(srcdir)/dbus-analyze-types.py --pattern=GAIM_DBUS_DECLARE_TYPE\(%s\) > $@
-+ cat $(gaim2_build_coreheaders) | $(PYTHON) $(srcdir)/dbus-analyze-types.py --pattern=GAIM_DBUS_DECLARE_TYPE\(%s\) > $@
-
- dbus-bindings.c: dbus-analyze-functions.py $(dbus_exported)
- cat $(dbus_build_exported) | $(PYTHON) $(srcdir)/dbus-analyze-functions.py > $@
-@@ -207,8 +207,8 @@ libgaim_client_la_SOURCES = gaim-client.
- gaim-client-bindings.c: dbus-analyze-functions.py $(dbus_exported)
- cat $(dbus_build_exported) | $(PYTHON) $(srcdir)/dbus-analyze-functions.py --client > $@
-
--gaim-client-bindings.h: dbus-analyze-types.py dbus-analyze-functions.py $(gaim_coreheaders) $(dbus_exported)
-- cat $(gaim_build_coreheaders) | $(PYTHON) $(srcdir)/dbus-analyze-types.py --keyword=enum --verbatim > $@
-+gaim-client-bindings.h: dbus-analyze-types.py dbus-analyze-functions.py $(gaim2_coreheaders) $(dbus_exported)
-+ cat $(gaim2_build_coreheaders) | $(PYTHON) $(srcdir)/dbus-analyze-types.py --keyword=enum --verbatim > $@
- cat $(dbus_build_exported) | $(PYTHON) $(srcdir)/dbus-analyze-functions.py --client --headers >> $@
-
- $(libgaim_client_la_OBJECTS): gaim-client-bindings.h gaim-client-bindings.c
-@@ -226,9 +226,9 @@ gaim_client_example_LDADD = \
- $(GTK_LIBS) \
- $(DBUS_LIBS)
-
--gaim_clientbP = gaim-client-example
-+gaim2_clientbP = gaim-client-example
-
--gaim-client-example.$(OBJEXT): gaim-client-bindings.h
-+gaim2-client-example.$(OBJEXT): gaim-client-bindings.h
-
- # scripts
-
-@@ -249,10 +249,10 @@ dbus_session_DATA = gaim.service
-
- endif
-
--bin_PROGRAMS = gaim $(gaim_clientbP)
-+bin_PROGRAMS = gaim2 $(gaim2_clientbP)
-
--gaim_SOURCES = \
-- $(gaim_coresources) \
-+gaim2_SOURCES = \
-+ $(gaim2_coresources) \
- $(dbus_sources) \
- gtkblist.c \
- gtkcombobox.c \
-@@ -294,9 +294,9 @@ gaim_SOURCES = \
- gtkutils.c \
- gtkwhiteboard.c
-
--gaim_headers = \
-+gaim2_headers = \
- $(dbus_headers) \
-- gaim.h \
-+ gaim2.h \
- gtkcombobox.h \
- gtkcelllayout.h \
- gtkcellview.h \
-@@ -315,7 +315,7 @@ gaim_headers = \
- gtkeventloop.h \
- gtkexpander.h \
- gtkft.h \
-- gtkgaim.h \
-+ gtkgaim2.h \
- gtkidle.h \
- gtkimhtml.h \
- gtkimhtmltoolbar.h \
-@@ -342,19 +342,19 @@ gaim_headers = \
- internal.h \
- gtkwhiteboard.h
-
--gaimincludedir=$(includedir)/gaim
--gaiminclude_HEADERS = \
-- $(gaim_coreheaders) \
-- $(gaim_headers)
-+gaim2includedir=$(includedir)/gaim2
-+gaim2include_HEADERS = \
-+ $(gaim2_coreheaders) \
-+ $(gaim2_headers)
-
- if HAVE_VV
- MS_LIBS=$(top_srcdir)/src/mediastreamer/libmediastreamer.la
- MS_INCLUDES=-I$(top_srcdir)/src/mediastreamer
- endif
-
--gaim_DEPENDENCIES = @LIBOBJS@ $(STATIC_LINK_LIBS) $(MS_LIBS)
--gaim_LDFLAGS = -export-dynamic
--gaim_LDADD = \
-+gaim2_DEPENDENCIES = @LIBOBJS@ $(STATIC_LINK_LIBS) $(MS_LIBS)
-+gaim2_LDFLAGS = -export-dynamic
-+gaim2_LDADD = \
- @LIBOBJS@ \
- $(GTK_LIBS) \
- $(DBUS_LIBS) \
-@@ -371,7 +371,7 @@ gaim_LDADD = \
- AM_CPPFLAGS = \
- -DBR_PTHREADS=0 \
- -DDATADIR=\"$(datadir)\" \
-- -DLIBDIR=\"$(libdir)/gaim/\" \
-+ -DLIBDIR=\"$(libdir)/gaim2/\" \
- -DLOCALEDIR=\"$(datadir)/locale\" \
- -DSYSCONFDIR=\"$(sysconfdir)\" \
- -I$(top_srcdir)/plugins \
-diff -prNu ./src/media.c ./src/media.c
---- ./src/media.c 2005-12-22 02:34:41.000000000 +0100
-+++ ./src/media.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file media.c Voice and Video API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -37,11 +37,11 @@
- static void * dummy1 = ms_rtp_send_new;
- static void * dummy2 = ms_rtp_recv_new;
-
--struct _GaimVoiceChat {
-- GaimConnection *gc;
-+struct _Gaim2VoiceChat {
-+ Gaim2Connection *gc;
- char *name;
-
-- GaimMediaState state;
-+ Gaim2MediaState state;
-
- void *proto_data;
- void *ui_data;
-@@ -51,18 +51,18 @@ struct _GaimVoiceChat {
- MSSync *timer;
- };
-
--static GaimMediaUiOps *media_ui_ops = NULL;
-+static Gaim2MediaUiOps *media_ui_ops = NULL;
-
--void gaim_media_init()
-+void gaim2_media_init()
- {
- ms_init();
- ms_speex_codec_init();
- ortp_init();
- }
-
--GaimVoiceChat *gaim_voice_chat_new(GaimConnection *gc, const char *name)
-+Gaim2VoiceChat *gaim2_voice_chat_new(Gaim2Connection *gc, const char *name)
- {
-- GaimVoiceChat *vc = g_new0(GaimVoiceChat, 1);
-+ Gaim2VoiceChat *vc = g_new0(Gaim2VoiceChat, 1);
- SndCard *card;
-
- vc->gc = gc;
-@@ -80,69 +80,69 @@ GaimVoiceChat *gaim_voice_chat_new(GaimC
-
-
-
--void gaim_voice_chat_destroy(GaimVoiceChat *vc)
-+void gaim2_voice_chat_destroy(Gaim2VoiceChat *vc)
- {
- if (media_ui_ops)
- media_ui_ops->destroy(vc);
- g_free(vc);
- }
-
--const char *gaim_voice_chat_get_name(GaimVoiceChat *vc)
-+const char *gaim2_voice_chat_get_name(Gaim2VoiceChat *vc)
- {
- return vc->name;
- }
-
--void gaim_voice_chat_set_name(GaimVoiceChat *vc, const char *name)
-+void gaim2_voice_chat_set_name(Gaim2VoiceChat *vc, const char *name)
- {
- g_free(vc->name);
- vc->name = g_strdup(name);
- }
-
--GaimConnection *gaim_voice_chat_get_connection(GaimVoiceChat *vc)
-+Gaim2Connection *gaim2_voice_chat_get_connection(Gaim2VoiceChat *vc)
- {
- return vc->gc;
- }
-
--void *gaim_voice_chat_get_ui_data(GaimVoiceChat *vc)
-+void *gaim2_voice_chat_get_ui_data(Gaim2VoiceChat *vc)
- {
- return vc->ui_data;
- }
-
--void gaim_voice_chat_set_ui_data(GaimVoiceChat *vc, void *data)
-+void gaim2_voice_chat_set_ui_data(Gaim2VoiceChat *vc, void *data)
- {
- vc->ui_data = data;
- }
-
--void *gaim_voice_chat_get_proto_data(GaimVoiceChat *vc)
-+void *gaim2_voice_chat_get_proto_data(Gaim2VoiceChat *vc)
- {
- return vc->proto_data;
- }
-
--void gaim_voice_chat_set_proto_data(GaimVoiceChat *vc, void *data)
-+void gaim2_voice_chat_set_proto_data(Gaim2VoiceChat *vc, void *data)
- {
- vc->proto_data = data;
- }
-
--void gaim_media_set_ui_ops(GaimMediaUiOps *ops)
-+void gaim2_media_set_ui_ops(Gaim2MediaUiOps *ops)
- {
- media_ui_ops = ops;
- }
-
--GaimMediaUiOps *gaim_media_get_ui_ops(void)
-+Gaim2MediaUiOps *gaim2_media_get_ui_ops(void)
- {
- return media_ui_ops;
- }
-
-
--GaimMediaState gaim_voice_chat_get_state(GaimVoiceChat *vc)
-+Gaim2MediaState gaim2_voice_chat_get_state(Gaim2VoiceChat *vc)
- {
- return vc->state;
- }
-
--void gaim_voice_chat_accept(GaimVoiceChat *vc)
-+void gaim2_voice_chat_accept(Gaim2VoiceChat *vc)
- {
-- GaimConnection *gc = gaim_voice_chat_get_connection(vc);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_voice_chat_get_connection(vc);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -151,10 +151,10 @@ void gaim_voice_chat_accept(GaimVoiceCha
- prpl_info->media_prpl_ops->accept(vc);
- }
-
--void gaim_voice_chat_reject(GaimVoiceChat *vc)
-+void gaim2_voice_chat_reject(Gaim2VoiceChat *vc)
- {
-- GaimConnection *gc = gaim_voice_chat_get_connection(vc);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_voice_chat_get_connection(vc);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -164,10 +164,10 @@ void gaim_voice_chat_reject(GaimVoiceCha
- }
-
-
--void gaim_voice_chat_terminate(GaimVoiceChat *vc)
-+void gaim2_voice_chat_terminate(Gaim2VoiceChat *vc)
- {
-- GaimConnection *gc = gaim_voice_chat_get_connection(vc);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_voice_chat_get_connection(vc);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-@@ -177,7 +177,7 @@ void gaim_voice_chat_terminate(GaimVoice
- }
-
-
--void gaim_voice_chat_set_state(GaimVoiceChat *vc, GaimMediaState state)
-+void gaim2_voice_chat_set_state(Gaim2VoiceChat *vc, Gaim2MediaState state)
- {
- vc->state = state;
- printf("State: %d\n",state);
-@@ -185,21 +185,21 @@ void gaim_voice_chat_set_state(GaimVoice
- media_ui_ops->state_change(vc, state);
- }
-
--void gaim_voice_chat_get_filters(GaimVoiceChat *vc, MSFilter **microphone, MSFilter **speaker)
-+void gaim2_voice_chat_get_filters(Gaim2VoiceChat *vc, MSFilter **microphone, MSFilter **speaker)
- {
- if (microphone) *microphone = vc->microphone;
- if (speaker) *speaker = vc->speaker;
- }
-
--MSSync *gaim_voice_chat_get_timer(GaimVoiceChat *vc)
-+MSSync *gaim2_voice_chat_get_timer(Gaim2VoiceChat *vc)
- {
- return vc->timer;
- }
-
--void gaim_voice_chat_start_streams(GaimVoiceChat *vc)
-+void gaim2_voice_chat_start_streams(Gaim2VoiceChat *vc)
- {
-- GaimConnection *gc = gaim_voice_chat_get_connection(vc);
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc = gaim2_voice_chat_get_connection(vc);
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-diff -prNu ./src/media.h ./src/media.h
---- ./src/media.h 2005-12-22 20:39:22.000000000 +0100
-+++ ./src/media.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file media.h Voice and Video API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,8 +25,8 @@
- #ifndef _GAIM_MEDIA_H_
- #define _GAIM_MEDIA_H_
-
--typedef struct _GaimVoiceChat GaimVoiceChat;
--typedef struct _GaimMediaPrplOps GaimMediaPrplOps;
-+typedef struct _Gaim2VoiceChat Gaim2VoiceChat;
-+typedef struct _Gaim2MediaPrplOps Gaim2MediaPrplOps;
-
- #include "connection.h"
-
-@@ -43,26 +43,26 @@ typedef enum {
- GAIM_MEDIA_STATE_RECEIVING, /**< An incoming call is waiting to be answered */
- GAIM_MEDIA_STATE_IN_PROGRESS, /**< The call is connected */
- GAIM_MEDIA_STATE_ERROR, /**< Some error occured */
--} GaimMediaState;
-+} Gaim2MediaState;
-
- /**
- * UI Operations
- */
- typedef struct {
-- void (*new_voice_chat)(GaimVoiceChat *vc); /**< A new voice chat is created */
-- void (*destroy)(GaimVoiceChat *vc); /**< The voice chat has been destroyed */
-- void (*state_change)(GaimVoiceChat *vc, GaimMediaState state); /**< The state of the voice chat has changed */
--} GaimMediaUiOps;
-+ void (*new_voice_chat)(Gaim2VoiceChat *vc); /**< A new voice chat is created */
-+ void (*destroy)(Gaim2VoiceChat *vc); /**< The voice chat has been destroyed */
-+ void (*state_change)(Gaim2VoiceChat *vc, Gaim2MediaState state); /**< The state of the voice chat has changed */
-+} Gaim2MediaUiOps;
-
- /**
- * PRPL Operations
- */
--struct _GaimMediaPrplOps {
-- void (*call)(GaimConnection *gc, const char *who); /**< Request an outgoing call to 'who' */
-- void (*init_filters)(GaimVoiceChat *); /**< Create the media stream for the call */
-- void (*accept)(GaimVoiceChat *); /**< Accept an incoming call */
-- void (*reject)(GaimVoiceChat *); /**< Reject an incoming call */
-- void (*terminate)(GaimVoiceChat *); /**< Terminate an in-progress call */
-+struct _Gaim2MediaPrplOps {
-+ void (*call)(Gaim2Connection *gc, const char *who); /**< Request an outgoing call to 'who' */
-+ void (*init_filters)(Gaim2VoiceChat *); /**< Create the media stream for the call */
-+ void (*accept)(Gaim2VoiceChat *); /**< Accept an incoming call */
-+ void (*reject)(Gaim2VoiceChat *); /**< Reject an incoming call */
-+ void (*terminate)(Gaim2VoiceChat *); /**< Terminate an in-progress call */
- };
-
- #ifdef HAVE_VV
-@@ -70,7 +70,7 @@ struct _GaimMediaPrplOps {
- /**
- * Initializes mediastreamer and ortp
- */
--void gaim_media_init(void);
-+void gaim2_media_init(void);
-
- /**************************************************************************/
- /** @name Voice Chat API **************************************************/
-@@ -87,14 +87,14 @@ void gaim_media_init(void);
- * @param name The person on the other end of the call
- * @return The new voice chat
- */
--GaimVoiceChat *gaim_voice_chat_new(GaimConnection *gc, const char *name);
-+Gaim2VoiceChat *gaim2_voice_chat_new(Gaim2Connection *gc, const char *name);
-
- /**
- * Destroys a voice chat
- *
- * @param vc The voice chat to destroy
- */
--void gaim_voice_chat_destroy(GaimVoiceChat *vc);
-+void gaim2_voice_chat_destroy(Gaim2VoiceChat *vc);
-
- /**
- * Accessor function to get the name of the other user on the voice chat
-@@ -102,7 +102,7 @@ void gaim_voice_chat_destroy(GaimVoiceCh
- * @param vc The voice chat
- * @return The name
- */
--const char *gaim_voice_chat_get_name(GaimVoiceChat *vc);
-+const char *gaim2_voice_chat_get_name(Gaim2VoiceChat *vc);
-
- /**
- * Accessor function to set the name of the other user on the voice chat
-@@ -110,15 +110,15 @@ const char *gaim_voice_chat_get_name(Gai
- * @param vc The voice chat
- * @return The name
- */
--void gaim_voice_chat_set_name(GaimVoiceChat *vc, const char *name);
-+void gaim2_voice_chat_set_name(Gaim2VoiceChat *vc, const char *name);
-
- /**
-- * Accessor for the GaimConnection of the voice chat
-+ * Accessor for the Gaim2Connection of the voice chat
- *
- * @param vc The voice chat
-- * @return The GaimConnection
-+ * @return The Gaim2Connection
- */
--GaimConnection *gaim_voice_chat_get_connection(GaimVoiceChat *vc);
-+Gaim2Connection *gaim2_voice_chat_get_connection(Gaim2VoiceChat *vc);
-
- /**
- * Accessor for the UI data
-@@ -126,7 +126,7 @@ GaimConnection *gaim_voice_chat_get_conn
- * @param vc The voice chat
- * @return The UI data
- */
--void *gaim_voice_chat_get_ui_data(GaimVoiceChat *vc);
-+void *gaim2_voice_chat_get_ui_data(Gaim2VoiceChat *vc);
-
- /**
- * Mutator for the UI Data
-@@ -134,7 +134,7 @@ void *gaim_voice_chat_get_ui_data(GaimVo
- * @param vc The voice chat
- * @param data The data
- */
--void gaim_voice_chat_set_ui_data(GaimVoiceChat *vc, void *data);
-+void gaim2_voice_chat_set_ui_data(Gaim2VoiceChat *vc, void *data);
-
- /**
- * Accessor for the protocol data
-@@ -142,7 +142,7 @@ void gaim_voice_chat_set_ui_data(GaimVoi
- * @param vc The voice chat
- * @return The protocol data
- */
--void *gaim_voice_chat_get_proto_data(GaimVoiceChat *vc);
-+void *gaim2_voice_chat_get_proto_data(Gaim2VoiceChat *vc);
-
- /**
- * Mutator for the protocol data
-@@ -150,7 +150,7 @@ void *gaim_voice_chat_get_proto_data(Gai
- * @param vc The voice chat
- * @param data The protocol data
- */
--void gaim_voice_chat_set_proto_data(GaimVoiceChat *vc, void *data);
-+void gaim2_voice_chat_set_proto_data(Gaim2VoiceChat *vc, void *data);
-
- /**
- * Accessor for the state
-@@ -158,7 +158,7 @@ void gaim_voice_chat_set_proto_data(Gaim
- * @param vc The voice chat
- * @return The state
- */
--GaimMediaState gaim_voice_chat_get_state(GaimVoiceChat *vc);
-+Gaim2MediaState gaim2_voice_chat_get_state(Gaim2VoiceChat *vc);
-
- /**
- * Mutator for the state
-@@ -166,28 +166,28 @@ GaimMediaState gaim_voice_chat_get_state
- * @param vc The voice chat
- * @param state The state
- */
--void gaim_voice_chat_set_state(GaimVoiceChat *vc, GaimMediaState state);
-+void gaim2_voice_chat_set_state(Gaim2VoiceChat *vc, Gaim2MediaState state);
-
- /**
- * Accepts an incoming voice chat
- *
- * @param vc The voice chat
- */
--void gaim_voice_chat_accept(GaimVoiceChat *vc);
-+void gaim2_voice_chat_accept(Gaim2VoiceChat *vc);
-
- /**
- * Rejects an incoming voice chat
- *
- * @param vc The voice chat
- */
--void gaim_voice_chat_reject(GaimVoiceChat *vc);
-+void gaim2_voice_chat_reject(Gaim2VoiceChat *vc);
-
- /**
- * Terminates an in-progress voice chat
- *
- * @param vc The voice chat
- */
--void gaim_voice_chat_terminate(GaimVoiceChat *vc);
-+void gaim2_voice_chat_terminate(Gaim2VoiceChat *vc);
-
- /**
- * Accessor for the microphone and speaker MSFilter objects
-@@ -196,7 +196,7 @@ void gaim_voice_chat_terminate(GaimVoice
- * @param microphone A pointer to return the microphone filter in, or NULL.
- * @param speaker A poitner to reutrn the speaker filter in, or NULL.
- */
--void gaim_voice_chat_get_filters(GaimVoiceChat *vc, struct _MSFilter **microphone, struct _MSFilter **speaker);
-+void gaim2_voice_chat_get_filters(Gaim2VoiceChat *vc, struct _MSFilter **microphone, struct _MSFilter **speaker);
-
- /**
- * Accessor for the Mediastreamer timer
-@@ -204,14 +204,14 @@ void gaim_voice_chat_get_filters(GaimVoi
- * @param vc The voice chat
- * @return The timer
- */
--struct _MSSync *gaim_voice_chat_get_timer(GaimVoiceChat *vc);
-+struct _MSSync *gaim2_voice_chat_get_timer(Gaim2VoiceChat *vc);
-
- /**
- * Start the streams
- *
- * @param vc The voice chat
- */
--void gaim_voice_chat_start_streams(GaimVoiceChat *vc);
-+void gaim2_voice_chat_start_streams(Gaim2VoiceChat *vc);
-
- /*@}*/
-
-@@ -225,14 +225,14 @@ void gaim_voice_chat_start_streams(GaimV
- *
- * @param ops The ops struct.
- */
--void gaim_media_set_ui_ops(GaimMediaUiOps *ops);
-+void gaim2_media_set_ui_ops(Gaim2MediaUiOps *ops);
-
- /**
- * Returns the UI operations structure to be used for the buddy list.
- *
- * @return The UI operations structure.
- */
--GaimMediaUiOps *gaim_media_get_ui_ops(void);
-+Gaim2MediaUiOps *gaim2_media_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/mime.c ./src/mime.c
---- ./src/mime.c 2005-11-15 07:06:47.000000000 +0100
-+++ ./src/mime.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,8 +1,8 @@
-
- /*
-- Gaim
-+ Gaim2
-
-- Gaim is the legal property of its developers, whose names are too
-+ Gaim2 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
-
-@@ -30,7 +30,7 @@
- #include <glib/glist.h>
- #include <glib/gstring.h>
-
--/* this should become "util.h" if we ever get this into gaim proper */
-+/* this should become "util.h" if we ever get this into gaim2 proper */
- #include <debug.h>
- #include <util.h>
-
-@@ -49,15 +49,15 @@ struct mime_fields {
- };
-
-
--struct _GaimMimeDocument {
-+struct _Gaim2MimeDocument {
- struct mime_fields fields;
- GList *parts;
- };
-
-
--struct _GaimMimePart {
-+struct _Gaim2MimePart {
- struct mime_fields fields;
-- struct _GaimMimeDocument *doc;
-+ struct _Gaim2MimeDocument *doc;
- GString *data;
- };
-
-@@ -208,10 +208,10 @@ static void fields_destroy(struct mime_f
- }
-
-
--static GaimMimePart *part_new(GaimMimeDocument *doc) {
-- GaimMimePart *part;
-+static Gaim2MimePart *part_new(Gaim2MimeDocument *doc) {
-+ Gaim2MimePart *part;
-
-- part = g_new0(GaimMimePart, 1);
-+ part = g_new0(Gaim2MimePart, 1);
- fields_init(&part->fields);
- part->doc = doc;
- part->data = g_string_new(NULL);
-@@ -222,7 +222,7 @@ static GaimMimePart *part_new(GaimMimeDo
- }
-
-
--static void part_load(GaimMimePart *part,
-+static void part_load(Gaim2MimePart *part,
- const char *buf, gsize len) {
-
- char *b = (char *) buf;
-@@ -238,13 +238,13 @@ static void part_load(GaimMimePart *part
- }
-
-
--static void part_write(GaimMimePart *part, GString *str) {
-+static void part_write(Gaim2MimePart *part, GString *str) {
- fields_write(&part->fields, str);
- g_string_append_printf(str, "%s\r\n\r\n", part->data->str);
- }
-
-
--static void part_free(GaimMimePart *part) {
-+static void part_free(Gaim2MimePart *part) {
-
- fields_destroy(&part->fields);
-
-@@ -255,19 +255,19 @@ static void part_free(GaimMimePart *part
- }
-
-
--GaimMimePart *gaim_mime_part_new(GaimMimeDocument *doc) {
-+Gaim2MimePart *gaim2_mime_part_new(Gaim2MimeDocument *doc) {
- g_return_val_if_fail(doc != NULL, NULL);
- return part_new(doc);
- }
-
-
--const GList *gaim_mime_part_get_fields(GaimMimePart *part) {
-+const GList *gaim2_mime_part_get_fields(Gaim2MimePart *part) {
- g_return_val_if_fail(part != NULL, NULL);
- return part->fields.keys;
- }
-
-
--const char *gaim_mime_part_get_field(GaimMimePart *part,
-+const char *gaim2_mime_part_get_field(Gaim2MimePart *part,
- const char *field) {
-
- g_return_val_if_fail(part != NULL, NULL);
-@@ -275,7 +275,7 @@ const char *gaim_mime_part_get_field(Gai
- }
-
-
--char *gaim_mime_part_get_field_decoded(GaimMimePart *part,
-+char *gaim2_mime_part_get_field_decoded(Gaim2MimePart *part,
- const char *field) {
-
- const char *f;
-@@ -283,11 +283,11 @@ char *gaim_mime_part_get_field_decoded(G
- g_return_val_if_fail(part != NULL, NULL);
-
- f = fields_get(&part->fields, field);
-- return gaim_mime_decode_field(f);
-+ return gaim2_mime_decode_field(f);
- }
-
-
--void gaim_mime_part_set_field(GaimMimePart *part,
-+void gaim2_mime_part_set_field(Gaim2MimePart *part,
- const char *field,
- const char *value) {
- g_return_if_fail(part != NULL);
-@@ -295,7 +295,7 @@ void gaim_mime_part_set_field(GaimMimePa
- }
-
-
--const char *gaim_mime_part_get_data(GaimMimePart *part) {
-+const char *gaim2_mime_part_get_data(Gaim2MimePart *part) {
- g_return_val_if_fail(part != NULL, NULL);
- g_return_val_if_fail(part->data != NULL, NULL);
-
-@@ -303,7 +303,7 @@ const char *gaim_mime_part_get_data(Gaim
- }
-
-
--void gaim_mime_part_get_data_decoded(GaimMimePart *part,
-+void gaim2_mime_part_get_data_decoded(Gaim2MimePart *part,
- guchar **data, gsize *len) {
- const char *enc;
-
-@@ -313,7 +313,7 @@ void gaim_mime_part_get_data_decoded(Gai
-
- g_return_if_fail(part->data != NULL);
-
-- enc = gaim_mime_part_get_field(part, "content-transfer-encoding");
-+ enc = gaim2_mime_part_get_field(part, "content-transfer-encoding");
-
- if(! enc) {
- *data = (guchar *)g_strdup(part->data->str);
-@@ -328,16 +328,16 @@ void gaim_mime_part_get_data_decoded(Gai
- *len = part->data->len;
-
- } else if(! g_ascii_strcasecmp(enc, "base16")) {
-- *data = gaim_base16_decode(part->data->str, len);
-+ *data = gaim2_base16_decode(part->data->str, len);
-
- } else if(! g_ascii_strcasecmp(enc, "base64")) {
-- *data = gaim_base64_decode(part->data->str, len);
-+ *data = gaim2_base64_decode(part->data->str, len);
-
- } else if(! g_ascii_strcasecmp(enc, "quoted-printable")) {
-- *data = gaim_quotedp_decode(part->data->str, len);
-+ *data = gaim2_quotedp_decode(part->data->str, len);
-
- } else {
-- gaim_debug_warning("mime", "gaim_mime_part_get_data_decoded:"
-+ gaim2_debug_warning("mime", "gaim2_mime_part_get_data_decoded:"
- " unknown encoding '%s'\n", enc);
- *data = NULL;
- *len = 0;
-@@ -345,7 +345,7 @@ void gaim_mime_part_get_data_decoded(Gai
- }
-
-
--gsize gaim_mime_part_get_length(GaimMimePart *part) {
-+gsize gaim2_mime_part_get_length(Gaim2MimePart *part) {
- g_return_val_if_fail(part != NULL, 0);
- g_return_val_if_fail(part->data != NULL, 0);
-
-@@ -353,24 +353,24 @@ gsize gaim_mime_part_get_length(GaimMime
- }
-
-
--void gaim_mime_part_set_data(GaimMimePart *part, const char *data) {
-+void gaim2_mime_part_set_data(Gaim2MimePart *part, const char *data) {
- g_return_if_fail(part != NULL);
- g_string_free(part->data, TRUE);
- part->data = g_string_new(data);
- }
-
-
--GaimMimeDocument *gaim_mime_document_new() {
-- GaimMimeDocument *doc;
-+Gaim2MimeDocument *gaim2_mime_document_new() {
-+ Gaim2MimeDocument *doc;
-
-- doc = g_new0(GaimMimeDocument, 1);
-+ doc = g_new0(Gaim2MimeDocument, 1);
- fields_init(&doc->fields);
-
- return doc;
- }
-
-
--static void doc_parts_load(GaimMimeDocument *doc,
-+static void doc_parts_load(Gaim2MimeDocument *doc,
- const char *boundary,
- const char *buf, gsize len) {
-
-@@ -404,7 +404,7 @@ static void doc_parts_load(GaimMimeDocum
-
- sl = tail - b;
- if(sl) {
-- GaimMimePart *part = part_new(doc);
-+ Gaim2MimePart *part = part_new(doc);
- part_load(part, b, sl);
- }
- }
-@@ -414,16 +414,16 @@ static void doc_parts_load(GaimMimeDocum
- }
-
-
--GaimMimeDocument *gaim_mime_document_parsen(const char *buf, gsize len) {
-+Gaim2MimeDocument *gaim2_mime_document_parsen(const char *buf, gsize len) {
-
-- GaimMimeDocument *doc;
-+ Gaim2MimeDocument *doc;
-
- char *b = (char *) buf;
- gsize n = len;
-
- g_return_val_if_fail(buf != NULL, NULL);
-
-- doc = gaim_mime_document_new();
-+ doc = gaim2_mime_document_new();
-
- if(! len) return doc;
-
-@@ -431,7 +431,7 @@ GaimMimeDocument *gaim_mime_document_par
-
- {
- const char *ct = fields_get(&doc->fields, "content-type");
-- if(ct && gaim_str_has_prefix(ct, "multipart")) {
-+ if(ct && gaim2_str_has_prefix(ct, "multipart")) {
- char *bd = strrchr(ct, '=');
- if(bd++) {
- doc_parts_load(doc, bd, b, n);
-@@ -443,13 +443,13 @@ GaimMimeDocument *gaim_mime_document_par
- }
-
-
--GaimMimeDocument *gaim_mime_document_parse(const char *buf) {
-+Gaim2MimeDocument *gaim2_mime_document_parse(const char *buf) {
- g_return_val_if_fail(buf != NULL, NULL);
-- return gaim_mime_document_parsen(buf, strlen(buf));
-+ return gaim2_mime_document_parsen(buf, strlen(buf));
- }
-
-
--void gaim_mime_document_write(GaimMimeDocument *doc, GString *str) {
-+void gaim2_mime_document_write(Gaim2MimeDocument *doc, GString *str) {
- const char *bd = NULL;
-
- g_return_if_fail(doc != NULL);
-@@ -457,7 +457,7 @@ void gaim_mime_document_write(GaimMimeDo
-
- {
- const char *ct = fields_get(&doc->fields, "content-type");
-- if(ct && gaim_str_has_prefix(ct, "multipart")) {
-+ if(ct && gaim2_str_has_prefix(ct, "multipart")) {
- char *b = strrchr(ct, '=');
- if(b++) bd = b;
- }
-@@ -481,20 +481,20 @@ void gaim_mime_document_write(GaimMimeDo
- }
-
-
--const GList *gaim_mime_document_get_fields(GaimMimeDocument *doc) {
-+const GList *gaim2_mime_document_get_fields(Gaim2MimeDocument *doc) {
- g_return_val_if_fail(doc != NULL, NULL);
- return doc->fields.keys;
- }
-
-
--const char *gaim_mime_document_get_field(GaimMimeDocument *doc,
-+const char *gaim2_mime_document_get_field(Gaim2MimeDocument *doc,
- const char *field) {
- g_return_val_if_fail(doc != NULL, NULL);
- return fields_get(&doc->fields, field);
- }
-
-
--void gaim_mime_document_set_field(GaimMimeDocument *doc,
-+void gaim2_mime_document_set_field(Gaim2MimeDocument *doc,
- const char *field,
- const char *value) {
- g_return_if_fail(doc != NULL);
-@@ -502,13 +502,13 @@ void gaim_mime_document_set_field(GaimMi
- }
-
-
--const GList *gaim_mime_document_get_parts(GaimMimeDocument *doc) {
-+const GList *gaim2_mime_document_get_parts(Gaim2MimeDocument *doc) {
- g_return_val_if_fail(doc != NULL, NULL);
- return doc->parts;
- }
-
-
--void gaim_mime_document_free(GaimMimeDocument *doc) {
-+void gaim2_mime_document_free(Gaim2MimeDocument *doc) {
- if(! doc) return;
-
- fields_destroy(&doc->fields);
-diff -prNu ./src/mime.h ./src/mime.h
---- ./src/mime.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/mime.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,8 +1,8 @@
-
- /*
-- Gaim
-+ Gaim2
-
-- Gaim is the legal property of its developers, whose names are too
-+ Gaim2 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
-
-@@ -39,33 +39,33 @@
- */
-
-
--/** @typedef GaimMimeDocument
-+/** @typedef Gaim2MimeDocument
- A MIME document
- */
--typedef struct _GaimMimeDocument GaimMimeDocument;
-+typedef struct _Gaim2MimeDocument Gaim2MimeDocument;
-
-
--/** @typedef GaimMimePart
-+/** @typedef Gaim2MimePart
- A part of a multipart MIME document
- */
--typedef struct _GaimMimePart GaimMimePart;
-+typedef struct _Gaim2MimePart Gaim2MimePart;
-
-
- /** Allocate an empty MIME document */
--GaimMimeDocument *gaim_mime_document_new(void);
-+Gaim2MimeDocument *gaim2_mime_document_new(void);
-
-
- /** Frees memory used in a MIME document and all of its parts and fields
- @param doc the MIME document to free
- */
--void gaim_mime_document_free(GaimMimeDocument *doc);
-+void gaim2_mime_document_free(Gaim2MimeDocument *doc);
-
-
- /** Parse a MIME document from a NUL-terminated string
- @param buf the NULL-terminated string containing the MIME-encoded data
- @returns MIME document
- */
--GaimMimeDocument *gaim_mime_document_parse(const char *buf);
-+Gaim2MimeDocument *gaim2_mime_document_parse(const char *buf);
-
-
- /** Parse a MIME document from a string
-@@ -73,11 +73,11 @@ GaimMimeDocument *gaim_mime_document_par
- @param len length of buf
- @returns MIME document
- */
--GaimMimeDocument *gaim_mime_document_parsen(const char *buf, gsize len);
-+Gaim2MimeDocument *gaim2_mime_document_parsen(const char *buf, gsize len);
-
-
- /** Write (append) a MIME document onto a GString */
--void gaim_mime_document_write(GaimMimeDocument *doc, GString *str);
-+void gaim2_mime_document_write(Gaim2MimeDocument *doc, GString *str);
-
-
- /** The list of fields in the header of a document
-@@ -86,7 +86,7 @@ void gaim_mime_document_write(GaimMimeDo
- @returns list of strings indicating the fields (but not the values of
- the fields) in the header of doc
- */
--const GList *gaim_mime_document_get_fields(GaimMimeDocument *doc);
-+const GList *gaim2_mime_document_get_fields(Gaim2MimeDocument *doc);
-
-
- /** Get the value of a specific field in the header of a document
-@@ -96,7 +96,7 @@ const GList *gaim_mime_document_get_fiel
- @returns value associated with the indicated header field, or
- NULL if the field doesn't exist
- */
--const char *gaim_mime_document_get_field(GaimMimeDocument *doc,
-+const char *gaim2_mime_document_get_field(Gaim2MimeDocument *doc,
- const char *field);
-
-
-@@ -108,7 +108,7 @@ const char *gaim_mime_document_get_field
- @param value value to associate with the indicated header field,
- of NULL to remove the field
- */
--void gaim_mime_document_set_field(GaimMimeDocument *doc,
-+void gaim2_mime_document_set_field(Gaim2MimeDocument *doc,
- const char *field,
- const char *value);
-
-@@ -116,16 +116,16 @@ void gaim_mime_document_set_field(GaimMi
- /** The list of parts in a multipart document
-
- @param doc the MIME document
-- @returns list of GaimMimePart contained within doc
-+ @returns list of Gaim2MimePart contained within doc
- */
--const GList *gaim_mime_document_get_parts(GaimMimeDocument *doc);
-+const GList *gaim2_mime_document_get_parts(Gaim2MimeDocument *doc);
-
-
- /** Create and insert a new part into a MIME document
-
- @param doc the new part's parent MIME document
- */
--GaimMimePart *gaim_mime_part_new(GaimMimeDocument *doc);
-+Gaim2MimePart *gaim2_mime_part_new(Gaim2MimeDocument *doc);
-
-
- /** The list of fields in the header of a document part
-@@ -134,7 +134,7 @@ GaimMimePart *gaim_mime_part_new(GaimMim
- @returns list of strings indicating the fields (but not the values
- of the fields) in the header of part
- */
--const GList *gaim_mime_part_get_fields(GaimMimePart *part);
-+const GList *gaim2_mime_part_get_fields(Gaim2MimePart *part);
-
-
- /** Get the value of a specific field in the header of a document part
-@@ -144,13 +144,13 @@ const GList *gaim_mime_part_get_fields(G
- @returns value of the specified header field, or NULL if the
- field doesn't exist
- */
--const char *gaim_mime_part_get_field(GaimMimePart *part,
-+const char *gaim2_mime_part_get_field(Gaim2MimePart *part,
- const char *field);
-
-
- /** Get the decoded value of a specific field in the header of a
- document part */
--char *gaim_mime_part_get_field_decoded(GaimMimePart *part,
-+char *gaim2_mime_part_get_field_decoded(Gaim2MimePart *part,
- const char *field);
-
-
-@@ -161,7 +161,7 @@ char *gaim_mime_part_get_field_decoded(G
- @param value value to associate with the indicated header field,
- of NULL to remove the field
- */
--void gaim_mime_part_set_field(GaimMimePart *part,
-+void gaim2_mime_part_set_field(Gaim2MimePart *part,
- const char *field,
- const char *value);
-
-@@ -170,7 +170,7 @@ void gaim_mime_part_set_field(GaimMimePa
- @param part the MIME document part
- @returns NULL-terminated data found in the document part
- */
--const char *gaim_mime_part_get_data(GaimMimePart *part);
-+const char *gaim2_mime_part_get_data(Gaim2MimePart *part);
-
-
- /** Get the data portion of a MIME document part, after attempting to
-@@ -182,7 +182,7 @@ const char *gaim_mime_part_get_data(Gaim
- @param data Buffer for the data
- @param len The length of the buffer
- */
--void gaim_mime_part_get_data_decoded(GaimMimePart *part,
-+void gaim2_mime_part_get_data_decoded(Gaim2MimePart *part,
- guchar **data, gsize *len);
-
-
-@@ -191,10 +191,10 @@ void gaim_mime_part_get_data_decoded(Gai
- @param part the MIME document part
- @returns length of the data in the document part
- */
--gsize gaim_mime_part_get_length(GaimMimePart *part);
-+gsize gaim2_mime_part_get_length(Gaim2MimePart *part);
-
-
--void gaim_mime_part_set_data(GaimMimePart *part, const char *data);
-+void gaim2_mime_part_set_data(Gaim2MimePart *part, const char *data);
-
-
- #endif
-diff -prNu ./src/network.c ./src/network.c
---- ./src/network.c 2006-01-05 06:04:06.000000000 +0100
-+++ ./src/network.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file network.c Network Implementation
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -34,7 +34,7 @@
-
-
- const unsigned char *
--gaim_network_ip_atoi(const char *ip)
-+gaim2_network_ip_atoi(const char *ip)
- {
- static unsigned char ret[4];
- gchar *delimiter = ".";
-@@ -56,26 +56,26 @@ gaim_network_ip_atoi(const char *ip)
- }
-
- void
--gaim_network_set_public_ip(const char *ip)
-+gaim2_network_set_public_ip(const char *ip)
- {
- g_return_if_fail(ip != NULL);
-
- /* XXX - Ensure the IP address is valid */
-
-- gaim_prefs_set_string("/core/network/public_ip", ip);
-+ gaim2_prefs_set_string("/core/network/public_ip", ip);
- }
-
- const char *
--gaim_network_get_public_ip(void)
-+gaim2_network_get_public_ip(void)
- {
- const char *ip;
-- GaimStunNatDiscovery *stun;
-+ Gaim2StunNatDiscovery *stun;
-
-- ip = gaim_prefs_get_string("/core/network/public_ip");
-+ ip = gaim2_prefs_get_string("/core/network/public_ip");
-
- if (ip == NULL || *ip == '\0') {
- /* Check if STUN discovery was already done */
-- stun = gaim_stun_discover(NULL);
-+ stun = gaim2_stun_discover(NULL);
- if (stun != NULL && stun->status == GAIM_STUN_STATUS_DISCOVERED)
- return stun->publicip;
- return NULL;
-@@ -85,7 +85,7 @@ gaim_network_get_public_ip(void)
- }
-
- static const char *
--gaim_network_get_local_ip_from_fd(int fd)
-+gaim2_network_get_local_ip_from_fd(int fd)
- {
- struct sockaddr_in addr;
- socklen_t len;
-@@ -96,7 +96,7 @@ gaim_network_get_local_ip_from_fd(int fd
-
- len = sizeof(addr);
- if (getsockname(fd, (struct sockaddr *) &addr, &len) == -1) {
-- gaim_debug_warning("network", "getsockname: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "getsockname: %s\n", strerror(errno));
- return NULL;
- }
-
-@@ -107,7 +107,7 @@ gaim_network_get_local_ip_from_fd(int fd
- }
-
- const char *
--gaim_network_get_local_system_ip(int fd)
-+gaim2_network_get_local_system_ip(int fd)
- {
- struct hostent *host;
- char localhost[129];
-@@ -116,7 +116,7 @@ gaim_network_get_local_system_ip(int fd)
- const char *tmp = NULL;
-
- if (fd >= 0)
-- tmp = gaim_network_get_local_ip_from_fd(fd);
-+ tmp = gaim2_network_get_local_ip_from_fd(fd);
-
- if (tmp)
- return tmp;
-@@ -140,30 +140,30 @@ gaim_network_get_local_system_ip(int fd)
- }
-
- const char *
--gaim_network_get_my_ip(int fd)
-+gaim2_network_get_my_ip(int fd)
- {
- const char *ip = NULL;
-- GaimUPnPControlInfo* controlInfo = NULL;
-- GaimStunNatDiscovery *stun;
-+ Gaim2UPnPControlInfo* controlInfo = NULL;
-+ Gaim2StunNatDiscovery *stun;
-
- /* Check if the user specified an IP manually */
-- if (!gaim_prefs_get_bool("/core/network/auto_ip")) {
-- ip = gaim_network_get_public_ip();
-+ if (!gaim2_prefs_get_bool("/core/network/auto_ip")) {
-+ ip = gaim2_network_get_public_ip();
- if (ip != NULL)
- return ip;
- }
-
- if (ip == NULL || *ip == '\0') {
- /* Check if STUN discovery was already done */
-- stun = gaim_stun_discover(NULL);
-+ stun = gaim2_stun_discover(NULL);
- if (stun != NULL && stun->status == GAIM_STUN_STATUS_DISCOVERED)
- return stun->publicip;
- }
-
-
- /* attempt to get the ip from a NAT device */
-- if ((controlInfo = gaim_upnp_discover()) != NULL) {
-- ip = gaim_upnp_get_public_ip(controlInfo);
-+ if ((controlInfo = gaim2_upnp_discover()) != NULL) {
-+ ip = gaim2_upnp_get_public_ip(controlInfo);
-
- g_free(controlInfo->controlURL);
- g_free(controlInfo->serviceType);
-@@ -174,16 +174,16 @@ gaim_network_get_my_ip(int fd)
- }
-
- /* Just fetch the IP of the local system */
-- return gaim_network_get_local_system_ip(fd);
-+ return gaim2_network_get_local_system_ip(fd);
- }
-
-
- static int
--gaim_network_do_listen(unsigned short port, int socket_type)
-+gaim2_network_do_listen(unsigned short port, int socket_type)
- {
- int listenfd = -1;
- const int on = 1;
-- GaimUPnPControlInfo* controlInfo = NULL;
-+ Gaim2UPnPControlInfo* controlInfo = NULL;
- #if HAVE_GETADDRINFO
- int errnum;
- struct addrinfo hints, *res, *next;
-@@ -200,11 +200,11 @@ gaim_network_do_listen(unsigned short po
- errnum = getaddrinfo(NULL /* any IP */, serv, &hints, &res);
- if (errnum != 0) {
- #ifndef _WIN32
-- gaim_debug_warning("network", "getaddrinfo: %s\n", gai_strerror(errnum));
-+ gaim2_debug_warning("network", "getaddrinfo: %s\n", gai_strerror(errnum));
- if (errnum == EAI_SYSTEM)
-- gaim_debug_warning("network", "getaddrinfo: system error: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "getaddrinfo: system error: %s\n", strerror(errno));
- #else
-- gaim_debug_warning("network", "getaddrinfo: Error Code = %d\n", errnum);
-+ gaim2_debug_warning("network", "getaddrinfo: Error Code = %d\n", errnum);
- #endif
- return -1;
- }
-@@ -219,7 +219,7 @@ gaim_network_do_listen(unsigned short po
- if (listenfd < 0)
- continue;
- if (setsockopt(listenfd, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) != 0)
-- gaim_debug_warning("network", "setsockopt: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "setsockopt: %s\n", strerror(errno));
- if (bind(listenfd, next->ai_addr, next->ai_addrlen) == 0)
- break; /* success */
- /* XXX - It is unclear to me (datallah) whether we need to be
-@@ -235,41 +235,41 @@ gaim_network_do_listen(unsigned short po
- struct sockaddr_in sockin;
-
- if ((listenfd = socket(AF_INET, socket_type, 0)) < 0) {
-- gaim_debug_warning("network", "socket: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "socket: %s\n", strerror(errno));
- return -1;
- }
-
- if (setsockopt(listenfd, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) != 0)
-- gaim_debug_warning("network", "setsockopt: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "setsockopt: %s\n", strerror(errno));
-
- memset(&sockin, 0, sizeof(struct sockaddr_in));
- sockin.sin_family = PF_INET;
- sockin.sin_port = htons(port);
-
- if (bind(listenfd, (struct sockaddr *)&sockin, sizeof(struct sockaddr_in)) != 0) {
-- gaim_debug_warning("network", "bind: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "bind: %s\n", strerror(errno));
- close(listenfd);
- return -1;
- }
- #endif
-
- if (socket_type == SOCK_STREAM && listen(listenfd, 4) != 0) {
-- gaim_debug_warning("network", "listen: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "listen: %s\n", strerror(errno));
- close(listenfd);
- return -1;
- }
- fcntl(listenfd, F_SETFL, O_NONBLOCK);
-
-- if ((controlInfo = gaim_upnp_discover()) != NULL) {
-+ if ((controlInfo = gaim2_upnp_discover()) != NULL) {
- char *type_desc = (socket_type == SOCK_STREAM) ? "TCP" : "UDP";
-- if (!gaim_upnp_set_port_mapping(controlInfo,
-- gaim_network_get_port_from_fd(listenfd),
-+ if (!gaim2_upnp_set_port_mapping(controlInfo,
-+ gaim2_network_get_port_from_fd(listenfd),
- type_desc)) {
-- gaim_upnp_remove_port_mapping(controlInfo,
-- gaim_network_get_port_from_fd(listenfd),
-+ gaim2_upnp_remove_port_mapping(controlInfo,
-+ gaim2_network_get_port_from_fd(listenfd),
- type_desc);
-- gaim_upnp_set_port_mapping(controlInfo,
-- gaim_network_get_port_from_fd(listenfd),
-+ gaim2_upnp_set_port_mapping(controlInfo,
-+ gaim2_network_get_port_from_fd(listenfd),
- type_desc);
-
- }
-@@ -278,34 +278,34 @@ gaim_network_do_listen(unsigned short po
- g_free(controlInfo);
- }
-
-- gaim_debug_info("network", "Listening on port: %hu\n", gaim_network_get_port_from_fd(listenfd));
-+ gaim2_debug_info("network", "Listening on port: %hu\n", gaim2_network_get_port_from_fd(listenfd));
- return listenfd;
- }
-
- int
--gaim_network_listen(unsigned short port, int socket_type)
-+gaim2_network_listen(unsigned short port, int socket_type)
- {
- g_return_val_if_fail(port != 0, -1);
-
-- return gaim_network_do_listen(port, socket_type);
-+ return gaim2_network_do_listen(port, socket_type);
- }
-
- int
--gaim_network_listen_range(unsigned short start, unsigned short end,
-+gaim2_network_listen_range(unsigned short start, unsigned short end,
- int socket_type)
- {
- int ret = -1;
-
-- if (gaim_prefs_get_bool("/core/network/ports_range_use")) {
-- start = gaim_prefs_get_int("/core/network/ports_range_start");
-- end = gaim_prefs_get_int("/core/network/ports_range_end");
-+ if (gaim2_prefs_get_bool("/core/network/ports_range_use")) {
-+ start = gaim2_prefs_get_int("/core/network/ports_range_start");
-+ end = gaim2_prefs_get_int("/core/network/ports_range_end");
- } else {
- if (end < start)
- end = start;
- }
-
- for (; start <= end; start++) {
-- ret = gaim_network_do_listen(start, socket_type);
-+ ret = gaim2_network_do_listen(start, socket_type);
- if (ret >= 0)
- break;
- }
-@@ -314,7 +314,7 @@ gaim_network_listen_range(unsigned short
- }
-
- unsigned short
--gaim_network_get_port_from_fd(int fd)
-+gaim2_network_get_port_from_fd(int fd)
- {
- struct sockaddr_in addr;
- socklen_t len;
-@@ -323,7 +323,7 @@ gaim_network_get_port_from_fd(int fd)
-
- len = sizeof(addr);
- if (getsockname(fd, (struct sockaddr *) &addr, &len) == -1) {
-- gaim_debug_warning("network", "getsockname: %s\n", strerror(errno));
-+ gaim2_debug_warning("network", "getsockname: %s\n", strerror(errno));
- return 0;
- }
-
-@@ -331,12 +331,12 @@ gaim_network_get_port_from_fd(int fd)
- }
-
- void
--gaim_network_init(void)
-+gaim2_network_init(void)
- {
-- gaim_prefs_add_none ("/core/network");
-- gaim_prefs_add_bool ("/core/network/auto_ip", TRUE);
-- gaim_prefs_add_string("/core/network/public_ip", "");
-- gaim_prefs_add_bool ("/core/network/ports_range_use", FALSE);
-- gaim_prefs_add_int ("/core/network/ports_range_start", 1024);
-- gaim_prefs_add_int ("/core/network/ports_range_end", 2048);
-+ gaim2_prefs_add_none ("/core/network");
-+ gaim2_prefs_add_bool ("/core/network/auto_ip", TRUE);
-+ gaim2_prefs_add_string("/core/network/public_ip", "");
-+ gaim2_prefs_add_bool ("/core/network/ports_range_use", FALSE);
-+ gaim2_prefs_add_int ("/core/network/ports_range_start", 1024);
-+ gaim2_prefs_add_int ("/core/network/ports_range_end", 2048);
- }
-diff -prNu ./src/network.h ./src/network.h
---- ./src/network.h 2006-01-05 06:04:06.000000000 +0100
-+++ ./src/network.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file network.h Network API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -46,7 +46,7 @@ extern "C" {
- * is statically allocated and should not be
- * freed.
- */
--const unsigned char *gaim_network_ip_atoi(const char *ip);
-+const unsigned char *gaim2_network_ip_atoi(const char *ip);
-
- /**
- * Sets the IP address of the local system in preferences. This
-@@ -56,22 +56,22 @@ const unsigned char *gaim_network_ip_ato
- *
- * @param ip The local IP address.
- */
--void gaim_network_set_public_ip(const char *ip);
-+void gaim2_network_set_public_ip(const char *ip);
-
- /**
- * Returns the IP address of the local system set in preferences.
- *
-- * This returns the value set via gaim_network_set_public_ip().
-- * You probably want to use gaim_network_get_my_ip() instead.
-+ * This returns the value set via gaim2_network_set_public_ip().
-+ * You probably want to use gaim2_network_get_my_ip() instead.
- *
- * @return The local IP address set in preferences.
- */
--const char *gaim_network_get_public_ip(void);
-+const char *gaim2_network_get_public_ip(void);
-
- /**
- * Returns the IP address of the local system.
- *
-- * You probably want to use gaim_network_get_my_ip() instead.
-+ * You probably want to use gaim2_network_get_my_ip() instead.
- *
- * @note The returned string is a pointer to a static buffer. If this
- * function is called twice, it may be important to make a copy
-@@ -80,7 +80,7 @@ const char *gaim_network_get_public_ip(v
- * @param fd The fd to use to help figure out the IP, or else -1.
- * @return The local IP address.
- */
--const char *gaim_network_get_local_system_ip(int fd);
-+const char *gaim2_network_get_local_system_ip(int fd);
-
- /**
- * Returns the IP address that should be used anywhere a
-@@ -89,7 +89,7 @@ const char *gaim_network_get_local_syste
- *
- * If the user has manually specified an IP address via
- * preferences, then this IP is returned. Otherwise the
-- * IP address returned by gaim_network_get_local_system_ip()
-+ * IP address returned by gaim2_network_get_local_system_ip()
- * is returned.
- *
- * @note The returned string is a pointer to a static buffer. If this
-@@ -99,13 +99,13 @@ const char *gaim_network_get_local_syste
- * @param fd The fd to use to help figure out the IP, or -1.
- * @return The local IP address to be used.
- */
--const char *gaim_network_get_my_ip(int fd);
-+const char *gaim2_network_get_my_ip(int fd);
-
- /**
- * Attempts to open a listening port ONLY on the specified port number.
-- * You probably want to use gaim_network_listen_range() instead of this.
-+ * You probably want to use gaim2_network_listen_range() instead of this.
- * This function is useful, for example, if you wanted to write a telnet
-- * server as a Gaim plugin, and you HAD to listen on port 23. Why anyone
-+ * server as a Gaim2 plugin, and you HAD to listen on port 23. Why anyone
- * would want to do that is beyond me.
- *
- * This opens a listening port. The caller will want to set up a watcher
-@@ -121,7 +121,7 @@ const char *gaim_network_get_my_ip(int f
- * @return The file descriptor of the listening socket, or -1 if
- * no socket could be established.
- */
--int gaim_network_listen(unsigned short port, int socket_type);
-+int gaim2_network_listen(unsigned short port, int socket_type);
-
- /**
- * Opens a listening port selected from a range of ports. The range of
-@@ -148,7 +148,7 @@ int gaim_network_listen(unsigned short p
- * @return The file descriptor of the listening socket, or -1 if
- * no socket could be established.
- */
--int gaim_network_listen_range(unsigned short start, unsigned short end,
-+int gaim2_network_listen_range(unsigned short start, unsigned short end,
- int socket_type);
-
- /**
-@@ -156,15 +156,15 @@ int gaim_network_listen_range(unsigned s
- *
- * @param fd The file descriptor. This should be a tcp socket. The current
- * implementation probably dies on anything but IPv4. Perhaps this
-- * possible bug will inspire new and valuable contributors to Gaim.
-+ * possible bug will inspire new and valuable contributors to Gaim2.
- * @return The port number, in host byte order.
- */
--unsigned short gaim_network_get_port_from_fd(int fd);
-+unsigned short gaim2_network_get_port_from_fd(int fd);
-
- /**
- * Initializes the network subsystem.
- */
--void gaim_network_init(void);
-+void gaim2_network_init(void);
-
- /*@}*/
-
-diff -prNu ./src/notify.c ./src/notify.c
---- ./src/notify.c 2005-12-23 22:10:24.000000000 +0100
-+++ ./src/notify.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file notify.c Notification API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,33 +24,33 @@
- */
- #include "notify.h"
-
--static GaimNotifyUiOps *notify_ui_ops = NULL;
-+static Gaim2NotifyUiOps *notify_ui_ops = NULL;
- static GList *handles = NULL;
-
- typedef struct
- {
-- GaimNotifyType type;
-+ Gaim2NotifyType type;
- void *handle;
- void *ui_handle;
-- GaimNotifyCloseCallback cb;
-+ Gaim2NotifyCloseCallback cb;
- gpointer cb_user_data;
--} GaimNotifyInfo;
-+} Gaim2NotifyInfo;
-
- void *
--gaim_notify_message(void *handle, GaimNotifyMsgType type,
-+gaim2_notify_message(void *handle, Gaim2NotifyMsgType type,
- const char *title, const char *primary,
-- const char *secondary, GaimNotifyCloseCallback cb, gpointer user_data)
-+ const char *secondary, Gaim2NotifyCloseCallback cb, gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_val_if_fail(primary != NULL, NULL);
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_message != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_MESSAGE;
- info->handle = handle;
- info->ui_handle = ops->notify_message(type, title, primary,
-@@ -67,18 +67,18 @@ gaim_notify_message(void *handle, GaimNo
- }
-
- void *
--gaim_notify_email(void *handle, const char *subject, const char *from,
-- const char *to, const char *url, GaimNotifyCloseCallback cb,
-+gaim2_notify_email(void *handle, const char *subject, const char *from,
-+ const char *to, const char *url, Gaim2NotifyCloseCallback cb,
- gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_email != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_EMAIL;
- info->handle = handle;
- info->ui_handle = ops->notify_email(handle, subject, from, to, url);
-@@ -94,17 +94,17 @@ gaim_notify_email(void *handle, const ch
- }
-
- void *
--gaim_notify_emails(void *handle, size_t count, gboolean detailed,
-+gaim2_notify_emails(void *handle, size_t count, gboolean detailed,
- const char **subjects, const char **froms,
- const char **tos, const char **urls,
-- GaimNotifyCloseCallback cb, gpointer user_data)
-+ Gaim2NotifyCloseCallback cb, gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_val_if_fail(count != 0, NULL);
-
- if (count == 1) {
-- return gaim_notify_email(handle,
-+ return gaim2_notify_email(handle,
- (subjects == NULL ? NULL : *subjects),
- (froms == NULL ? NULL : *froms),
- (tos == NULL ? NULL : *tos),
-@@ -112,12 +112,12 @@ gaim_notify_emails(void *handle, size_t
- cb, user_data);
- }
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_emails != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_EMAILS;
- info->handle = handle;
- info->ui_handle = ops->notify_emails(handle, count, detailed, subjects,
-@@ -134,20 +134,20 @@ gaim_notify_emails(void *handle, size_t
- }
-
- void *
--gaim_notify_formatted(void *handle, const char *title, const char *primary,
-+gaim2_notify_formatted(void *handle, const char *title, const char *primary,
- const char *secondary, const char *text,
-- GaimNotifyCloseCallback cb, gpointer user_data)
-+ Gaim2NotifyCloseCallback cb, gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_val_if_fail(primary != NULL, NULL);
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_formatted != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_FORMATTED;
- info->handle = handle;
- info->ui_handle = ops->notify_formatted(title, primary, secondary, text);
-@@ -163,18 +163,18 @@ gaim_notify_formatted(void *handle, cons
- }
-
- void *
--gaim_notify_searchresults(GaimConnection *gc, const char *title,
-+gaim2_notify_searchresults(Gaim2Connection *gc, const char *title,
- const char *primary, const char *secondary,
-- GaimNotifySearchResults *results, GaimNotifyCloseCallback cb, gpointer user_data)
-+ Gaim2NotifySearchResults *results, Gaim2NotifyCloseCallback cb, gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_searchresults != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_SEARCHRESULTS;
- info->handle = gc;
- info->ui_handle = ops->notify_searchresults(gc, title, primary,
-@@ -191,14 +191,14 @@ gaim_notify_searchresults(GaimConnection
- }
-
- void
--gaim_notify_searchresults_free(GaimNotifySearchResults *results)
-+gaim2_notify_searchresults_free(Gaim2NotifySearchResults *results)
- {
- GList *l;
-
- g_return_if_fail(results != NULL);
-
- for (l = results->buttons; l; l = g_list_delete_link(l, l)) {
-- GaimNotifySearchButton *button = l->data;
-+ Gaim2NotifySearchButton *button = l->data;
- g_free(button);
- }
- results->buttons = NULL;
-@@ -213,7 +213,7 @@ gaim_notify_searchresults_free(GaimNotif
- results->rows = NULL;
-
- for (l = results->columns; l; l = g_list_delete_link(l, l)) {
-- GaimNotifySearchColumn *column = l->data;
-+ Gaim2NotifySearchColumn *column = l->data;
- g_free(column->title);
- g_free(column);
- }
-@@ -223,13 +223,13 @@ gaim_notify_searchresults_free(GaimNotif
- }
-
- void
--gaim_notify_searchresults_new_rows(GaimConnection *gc,
-- GaimNotifySearchResults *results,
-+gaim2_notify_searchresults_new_rows(Gaim2Connection *gc,
-+ Gaim2NotifySearchResults *results,
- void *data, gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_searchresults != NULL) {
- ops->notify_searchresults_new_rows(gc, results, data, user_data);
-@@ -237,16 +237,16 @@ gaim_notify_searchresults_new_rows(GaimC
- }
-
- void
--gaim_notify_searchresults_button_add(GaimNotifySearchResults *results,
-- GaimNotifySearchButtonType type,
-- GaimNotifySearchResultsCallback cb)
-+gaim2_notify_searchresults_button_add(Gaim2NotifySearchResults *results,
-+ Gaim2NotifySearchButtonType type,
-+ Gaim2NotifySearchResultsCallback cb)
- {
-- GaimNotifySearchButton *button;
-+ Gaim2NotifySearchButton *button;
-
- g_return_if_fail(results != NULL);
- g_return_if_fail(cb != NULL);
-
-- button = g_new0(GaimNotifySearchButton, 1);
-+ button = g_new0(Gaim2NotifySearchButton, 1);
- button->callback = cb;
- button->type = type;
-
-@@ -255,17 +255,17 @@ gaim_notify_searchresults_button_add(Gai
-
-
- void
--gaim_notify_searchresults_button_add_labeled(GaimNotifySearchResults *results,
-+gaim2_notify_searchresults_button_add_labeled(Gaim2NotifySearchResults *results,
- const char *label,
-- GaimNotifySearchResultsCallback cb) {
-- GaimNotifySearchButton *button;
-+ Gaim2NotifySearchResultsCallback cb) {
-+ Gaim2NotifySearchButton *button;
-
- g_return_if_fail(results != NULL);
- g_return_if_fail(cb != NULL);
- g_return_if_fail(label != NULL);
- g_return_if_fail(*label != '\0');
-
-- button = g_new0(GaimNotifySearchButton, 1);
-+ button = g_new0(Gaim2NotifySearchButton, 1);
- button->callback = cb;
- button->type = GAIM_NOTIFY_BUTTON_LABELED;
- button->label = g_strdup(label);
-@@ -274,17 +274,17 @@ gaim_notify_searchresults_button_add_lab
- }
-
-
--GaimNotifySearchResults *
--gaim_notify_searchresults_new()
-+Gaim2NotifySearchResults *
-+gaim2_notify_searchresults_new()
- {
-- GaimNotifySearchResults *rs = g_new0(GaimNotifySearchResults, 1);
-+ Gaim2NotifySearchResults *rs = g_new0(Gaim2NotifySearchResults, 1);
-
- return rs;
- }
-
- void
--gaim_notify_searchresults_column_add(GaimNotifySearchResults *results,
-- GaimNotifySearchColumn *column)
-+gaim2_notify_searchresults_column_add(Gaim2NotifySearchResults *results,
-+ Gaim2NotifySearchColumn *column)
- {
- g_return_if_fail(results != NULL);
- g_return_if_fail(column != NULL);
-@@ -292,7 +292,7 @@ gaim_notify_searchresults_column_add(Gai
- results->columns = g_list_append(results->columns, column);
- }
-
--void gaim_notify_searchresults_row_add(GaimNotifySearchResults *results,
-+void gaim2_notify_searchresults_row_add(Gaim2NotifySearchResults *results,
- GList *row)
- {
- g_return_if_fail(results != NULL);
-@@ -301,21 +301,21 @@ void gaim_notify_searchresults_row_add(G
- results->rows = g_list_append(results->rows, row);
- }
-
--GaimNotifySearchColumn *
--gaim_notify_searchresults_column_new(const char *title)
-+Gaim2NotifySearchColumn *
-+gaim2_notify_searchresults_column_new(const char *title)
- {
-- GaimNotifySearchColumn *sc;
-+ Gaim2NotifySearchColumn *sc;
-
- g_return_val_if_fail(title != NULL, NULL);
-
-- sc = g_new0(GaimNotifySearchColumn, 1);
-+ sc = g_new0(Gaim2NotifySearchColumn, 1);
- sc->title = g_strdup(title);
-
- return sc;
- }
-
- guint
--gaim_notify_searchresults_get_columns_count(GaimNotifySearchResults *results)
-+gaim2_notify_searchresults_get_columns_count(Gaim2NotifySearchResults *results)
- {
- g_return_val_if_fail(results != NULL, 0);
-
-@@ -323,7 +323,7 @@ gaim_notify_searchresults_get_columns_co
- }
-
- guint
--gaim_notify_searchresults_get_rows_count(GaimNotifySearchResults *results)
-+gaim2_notify_searchresults_get_rows_count(Gaim2NotifySearchResults *results)
- {
- g_return_val_if_fail(results != NULL, 0);
-
-@@ -331,16 +331,16 @@ gaim_notify_searchresults_get_rows_count
- }
-
- char *
--gaim_notify_searchresults_column_get_title(GaimNotifySearchResults *results,
-+gaim2_notify_searchresults_column_get_title(Gaim2NotifySearchResults *results,
- unsigned int column_id)
- {
- g_return_val_if_fail(results != NULL, NULL);
-
-- return ((GaimNotifySearchColumn *)g_list_nth_data(results->columns, column_id))->title;
-+ return ((Gaim2NotifySearchColumn *)g_list_nth_data(results->columns, column_id))->title;
- }
-
- GList *
--gaim_notify_searchresults_row_get(GaimNotifySearchResults *results,
-+gaim2_notify_searchresults_row_get(Gaim2NotifySearchResults *results,
- unsigned int row_id)
- {
- g_return_val_if_fail(results != NULL, NULL);
-@@ -349,25 +349,25 @@ gaim_notify_searchresults_row_get(GaimNo
- }
-
- void *
--gaim_notify_userinfo(GaimConnection *gc, const char *who,
-- const char *text, GaimNotifyCloseCallback cb, gpointer user_data)
-+gaim2_notify_userinfo(Gaim2Connection *gc, const char *who,
-+ const char *text, Gaim2NotifyCloseCallback cb, gpointer user_data)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_val_if_fail(who != NULL, NULL);
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_userinfo != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
- char *infotext = g_strdup(text);
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_USERINFO;
- info->handle = gc;
-
-- gaim_signal_emit(gaim_notify_get_handle(), "displaying-userinfo",
-- gaim_connection_get_account(gc), who, &infotext);
-+ gaim2_signal_emit(gaim2_notify_get_handle(), "displaying-userinfo",
-+ gaim2_connection_get_account(gc), who, &infotext);
-
- info->ui_handle = ops->notify_userinfo(gc, who, infotext);
- info->cb = cb;
-@@ -383,18 +383,18 @@ gaim_notify_userinfo(GaimConnection *gc,
- }
-
- void *
--gaim_notify_uri(void *handle, const char *uri)
-+gaim2_notify_uri(void *handle, const char *uri)
- {
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_val_if_fail(uri != NULL, NULL);
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- if (ops != NULL && ops->notify_uri != NULL) {
-- GaimNotifyInfo *info;
-+ Gaim2NotifyInfo *info;
-
-- info = g_new0(GaimNotifyInfo, 1);
-+ info = g_new0(Gaim2NotifyInfo, 1);
- info->type = GAIM_NOTIFY_URI;
- info->handle = handle;
- info->ui_handle = ops->notify_uri(uri);
-@@ -408,17 +408,17 @@ gaim_notify_uri(void *handle, const char
- }
-
- void
--gaim_notify_close(GaimNotifyType type, void *ui_handle)
-+gaim2_notify_close(Gaim2NotifyType type, void *ui_handle)
- {
- GList *l;
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_if_fail(ui_handle != NULL);
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- for (l = handles; l != NULL; l = l->next) {
-- GaimNotifyInfo *info = l->data;
-+ Gaim2NotifyInfo *info = l->data;
-
- if (info->ui_handle == ui_handle) {
- handles = g_list_remove(handles, info);
-@@ -437,17 +437,17 @@ gaim_notify_close(GaimNotifyType type, v
- }
-
- void
--gaim_notify_close_with_handle(void *handle)
-+gaim2_notify_close_with_handle(void *handle)
- {
- GList *l, *l_next;
-- GaimNotifyUiOps *ops;
-+ Gaim2NotifyUiOps *ops;
-
- g_return_if_fail(handle != NULL);
-
-- ops = gaim_notify_get_ui_ops();
-+ ops = gaim2_notify_get_ui_ops();
-
- for (l = handles; l != NULL; l = l_next) {
-- GaimNotifyInfo *info = l->data;
-+ Gaim2NotifyInfo *info = l->data;
-
- l_next = l->next;
-
-@@ -466,19 +466,19 @@ gaim_notify_close_with_handle(void *hand
- }
-
- void
--gaim_notify_set_ui_ops(GaimNotifyUiOps *ops)
-+gaim2_notify_set_ui_ops(Gaim2NotifyUiOps *ops)
- {
- notify_ui_ops = ops;
- }
-
--GaimNotifyUiOps *
--gaim_notify_get_ui_ops(void)
-+Gaim2NotifyUiOps *
-+gaim2_notify_get_ui_ops(void)
- {
- return notify_ui_ops;
- }
-
- void *
--gaim_notify_get_handle(void)
-+gaim2_notify_get_handle(void)
- {
- static int handle;
-
-@@ -486,20 +486,20 @@ gaim_notify_get_handle(void)
- }
-
- void
--gaim_notify_init(void)
-+gaim2_notify_init(void)
- {
-- gpointer handle = gaim_notify_get_handle();
-+ gpointer handle = gaim2_notify_get_handle();
-
-- gaim_signal_register(handle, "displaying-userinfo",
-- gaim_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_signal_register(handle, "displaying-userinfo",
-+ gaim2_marshal_VOID__POINTER_POINTER_POINTER, NULL, 3,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_ACCOUNT),
-- gaim_value_new(GAIM_TYPE_STRING),
-- gaim_value_new_outgoing(GAIM_TYPE_STRING));
-+ gaim2_value_new(GAIM_TYPE_STRING),
-+ gaim2_value_new_outgoing(GAIM_TYPE_STRING));
- }
-
- void
--gaim_notify_uninit(void)
-+gaim2_notify_uninit(void)
- {
-- gaim_signals_unregister_by_instance(gaim_notify_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_notify_get_handle());
- }
-diff -prNu ./src/notify.h ./src/notify.h
---- ./src/notify.h 2005-12-23 22:10:24.000000000 +0100
-+++ ./src/notify.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file notify.h Notification API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,7 +35,7 @@
- /**
- * Notification close callbacks.
- */
--typedef void (*GaimNotifyCloseCallback) (gpointer user_data);
-+typedef void (*Gaim2NotifyCloseCallback) (gpointer user_data);
-
-
- /**
-@@ -51,7 +51,7 @@ typedef enum
- GAIM_NOTIFY_USERINFO, /**< Formatted userinfo text. */
- GAIM_NOTIFY_URI /**< URI notification or display. */
-
--} GaimNotifyType;
-+} Gaim2NotifyType;
-
-
- /**
-@@ -63,7 +63,7 @@ typedef enum
- GAIM_NOTIFY_MSG_WARNING, /**< Warning notification. */
- GAIM_NOTIFY_MSG_INFO /**< Information notification. */
-
--} GaimNotifyMsgType;
-+} Gaim2NotifyMsgType;
-
-
- /**
-@@ -78,7 +78,7 @@ typedef enum
- GAIM_NOTIFY_BUTTON_IM,
- GAIM_NOTIFY_BUTTON_JOIN,
- GAIM_NOTIFY_BUTTON_INVITE
--} GaimNotifySearchButtonType;
-+} Gaim2NotifySearchButtonType;
-
-
- /**
-@@ -90,7 +90,7 @@ typedef struct
- GList *rows; /**< List of rows in the result. */
- GList *buttons; /**< List of buttons to display. */
-
--} GaimNotifySearchResults;
-+} Gaim2NotifySearchResults;
-
-
- /**
-@@ -100,16 +100,16 @@ typedef struct
- {
- char *title; /**< Title of the column. */
-
--} GaimNotifySearchColumn;
-+} Gaim2NotifySearchColumn;
-
-
- /**
- * Callback for a button in a search result.
- *
-- * @param c the GaimConnection passed to gaim_notify_searchresults
-+ * @param c the Gaim2Connection passed to gaim2_notify_searchresults
- * @param row the contents of the selected row
- */
--typedef void (*GaimNotifySearchResultsCallback)(GaimConnection *c, GList *row);
-+typedef void (*Gaim2NotifySearchResultsCallback)(Gaim2Connection *c, GList *row);
-
-
- /**
-@@ -117,10 +117,10 @@ typedef void (*GaimNotifySearchResultsCa
- */
- typedef struct
- {
-- GaimNotifySearchButtonType type;
-- GaimNotifySearchResultsCallback callback; /**< Function to be called when clicked. */
-+ Gaim2NotifySearchButtonType type;
-+ Gaim2NotifySearchResultsCallback callback; /**< Function to be called when clicked. */
- char *label; /**< only for GAIM_NOTIFY_BUTTON_LABELED */
--} GaimNotifySearchButton;
-+} Gaim2NotifySearchButton;
-
-
- /**
-@@ -128,14 +128,14 @@ typedef struct
- */
- typedef struct
- {
-- void *(*notify_message)(GaimNotifyMsgType type, const char *title,
-+ void *(*notify_message)(Gaim2NotifyMsgType type, const char *title,
- const char *primary, const char *secondary);
-
-- void *(*notify_email)(GaimConnection *gc,
-+ void *(*notify_email)(Gaim2Connection *gc,
- const char *subject, const char *from,
- const char *to, const char *url);
-
-- void *(*notify_emails)(GaimConnection *gc,
-+ void *(*notify_emails)(Gaim2Connection *gc,
- size_t count, gboolean detailed,
- const char **subjects, const char **froms,
- const char **tos, const char **urls);
-@@ -143,22 +143,22 @@ typedef struct
- void *(*notify_formatted)(const char *title, const char *primary,
- const char *secondary, const char *text);
-
-- void *(*notify_searchresults)(GaimConnection *gc, const char *title,
-+ void *(*notify_searchresults)(Gaim2Connection *gc, const char *title,
- const char *primary, const char *secondary,
-- GaimNotifySearchResults *results);
-+ Gaim2NotifySearchResults *results);
-
-- void (*notify_searchresults_new_rows)(GaimConnection *gc,
-- GaimNotifySearchResults *results,
-+ void (*notify_searchresults_new_rows)(Gaim2Connection *gc,
-+ Gaim2NotifySearchResults *results,
- void *data, gpointer user_data);
-
-- void *(*notify_userinfo)(GaimConnection *gc, const char *who,
-+ void *(*notify_userinfo)(Gaim2Connection *gc, const char *who,
- const char *text);
-
- void *(*notify_uri)(const char *uri);
-
-- void (*close_notify)(GaimNotifyType type, void *ui_handle);
-+ void (*close_notify)(Gaim2NotifyType type, void *ui_handle);
-
--} GaimNotifyUiOps;
-+} Gaim2NotifyUiOps;
-
-
- #ifdef __cplusplus
-@@ -176,35 +176,35 @@ extern "C" {
- * a window with a list of all found buddies, where you are given the
- * option of adding buddies to your buddy list.
- *
-- * @param gc The GaimConnection handle associated with the information.
-+ * @param gc The Gaim2Connection handle associated with the information.
- * @param title The title of the message. If this is NULL, the title
- * will be "Search Results."
- * @param primary The main point of the message.
- * @param secondary The secondary information.
-- * @param results The GaimNotifySearchResults instance.
-+ * @param results The Gaim2NotifySearchResults instance.
- * @param cb The callback to call when the user closes
- * the notification.
- * @param user_data The data to pass to the callback.
- *
- * @return A UI-specific handle.
- */
--void *gaim_notify_searchresults(GaimConnection *gc, const char *title,
-+void *gaim2_notify_searchresults(Gaim2Connection *gc, const char *title,
- const char *primary, const char *secondary,
-- GaimNotifySearchResults *results, GaimNotifyCloseCallback cb,
-+ Gaim2NotifySearchResults *results, Gaim2NotifyCloseCallback cb,
- gpointer user_data);
-
--void gaim_notify_searchresults_free(GaimNotifySearchResults *results);
-+void gaim2_notify_searchresults_free(Gaim2NotifySearchResults *results);
-
- /**
- * Replace old rows with the new. Reuse an existing window.
- *
-- * @param gc The GaimConnection structure.
-- * @param results The GaimNotifySearchResults structure.
-- * @param data Data returned by the gaim_notify_searchresults().
-+ * @param gc The Gaim2Connection structure.
-+ * @param results The Gaim2NotifySearchResults structure.
-+ * @param data Data returned by the gaim2_notify_searchresults().
- * @param user_data User defined data.
- */
--void gaim_notify_searchresults_new_rows(GaimConnection *gc,
-- GaimNotifySearchResults *results,
-+void gaim2_notify_searchresults_new_rows(Gaim2Connection *gc,
-+ Gaim2NotifySearchResults *results,
- void *data, gpointer user_data);
-
-
-@@ -215,9 +215,9 @@ void gaim_notify_searchresults_new_rows(
- * @param type Type of the button. (TODO: Only one button of a given type can be displayed.)
- * @param cb Function that will be called on the click event.
- */
--void gaim_notify_searchresults_button_add(GaimNotifySearchResults *results,
-- GaimNotifySearchButtonType type,
-- GaimNotifySearchResultsCallback cb);
-+void gaim2_notify_searchresults_button_add(Gaim2NotifySearchResults *results,
-+ Gaim2NotifySearchButtonType type,
-+ Gaim2NotifySearchResultsCallback cb);
-
-
- /**
-@@ -227,9 +227,9 @@ void gaim_notify_searchresults_button_ad
- * @param label The label to display
- * @param cb Function that will be called on the click event
- */
--void gaim_notify_searchresults_button_add_labeled(GaimNotifySearchResults *results,
-+void gaim2_notify_searchresults_button_add_labeled(Gaim2NotifySearchResults *results,
- const char *label,
-- GaimNotifySearchResultsCallback cb);
-+ Gaim2NotifySearchResultsCallback cb);
-
-
- /**
-@@ -237,7 +237,7 @@ void gaim_notify_searchresults_button_ad
- *
- * @return The new search results object.
- */
--GaimNotifySearchResults *gaim_notify_searchresults_new(void);
-+Gaim2NotifySearchResults *gaim2_notify_searchresults_new(void);
-
- /**
- * Returns a newly created search result column object.
-@@ -246,7 +246,7 @@ GaimNotifySearchResults *gaim_notify_sea
- *
- * @return The new search column object.
- */
--GaimNotifySearchColumn *gaim_notify_searchresults_column_new(const char *title);
-+Gaim2NotifySearchColumn *gaim2_notify_searchresults_column_new(const char *title);
-
- /**
- * Adds a new column to the search result object.
-@@ -254,8 +254,8 @@ GaimNotifySearchColumn *gaim_notify_sear
- * @param results The result object to which the column will be added.
- * @param column The column that will be added to the result object.
- */
--void gaim_notify_searchresults_column_add(GaimNotifySearchResults *results,
-- GaimNotifySearchColumn *column);
-+void gaim2_notify_searchresults_column_add(Gaim2NotifySearchResults *results,
-+ Gaim2NotifySearchColumn *column);
-
- /**
- * Adds a new row of the results to the search results object.
-@@ -263,7 +263,7 @@ void gaim_notify_searchresults_column_ad
- * @param results The search results object.
- * @param row The row of the results.
- */
--void gaim_notify_searchresults_row_add(GaimNotifySearchResults *results,
-+void gaim2_notify_searchresults_row_add(Gaim2NotifySearchResults *results,
- GList *row);
-
- /**
-@@ -273,7 +273,7 @@ void gaim_notify_searchresults_row_add(G
- *
- * @return Number of the result rows.
- */
--guint gaim_notify_searchresults_get_rows_count(GaimNotifySearchResults *results);
-+guint gaim2_notify_searchresults_get_rows_count(Gaim2NotifySearchResults *results);
-
- /**
- * Returns a number of the columns in the search results object.
-@@ -282,7 +282,7 @@ guint gaim_notify_searchresults_get_rows
- *
- * @return Number of the columns.
- */
--guint gaim_notify_searchresults_get_columns_count(GaimNotifySearchResults *results);
-+guint gaim2_notify_searchresults_get_columns_count(Gaim2NotifySearchResults *results);
-
- /**
- * Returns a row of the results from the search results object.
-@@ -292,7 +292,7 @@ guint gaim_notify_searchresults_get_colu
- *
- * @return Row of the results.
- */
--GList *gaim_notify_searchresults_row_get(GaimNotifySearchResults *results,
-+GList *gaim2_notify_searchresults_row_get(Gaim2NotifySearchResults *results,
- unsigned int row_id);
-
- /**
-@@ -303,7 +303,7 @@ GList *gaim_notify_searchresults_row_get
- *
- * @return Title of the column.
- */
--char *gaim_notify_searchresults_column_get_title(GaimNotifySearchResults *results,
-+char *gaim2_notify_searchresults_column_get_title(Gaim2NotifySearchResults *results,
- unsigned int column_id);
-
- /*@}*/
-@@ -327,9 +327,9 @@ char *gaim_notify_searchresults_column_g
- *
- * @return A UI-specific handle.
- */
--void *gaim_notify_message(void *handle, GaimNotifyMsgType type,
-+void *gaim2_notify_message(void *handle, Gaim2NotifyMsgType type,
- const char *title, const char *primary,
-- const char *secondary, GaimNotifyCloseCallback cb,
-+ const char *secondary, Gaim2NotifyCloseCallback cb,
- gpointer user_data);
-
- /**
-@@ -346,9 +346,9 @@ void *gaim_notify_message(void *handle,
- *
- * @return A UI-specific handle.
- */
--void *gaim_notify_email(void *handle, const char *subject,
-+void *gaim2_notify_email(void *handle, const char *subject,
- const char *from, const char *to,
-- const char *url, GaimNotifyCloseCallback cb,
-+ const char *url, Gaim2NotifyCloseCallback cb,
- gpointer user_data);
-
- /**
-@@ -368,10 +368,10 @@ void *gaim_notify_email(void *handle, co
- *
- * @return A UI-specific handle.
- */
--void *gaim_notify_emails(void *handle, size_t count, gboolean detailed,
-+void *gaim2_notify_emails(void *handle, size_t count, gboolean detailed,
- const char **subjects, const char **froms,
- const char **tos, const char **urls,
-- GaimNotifyCloseCallback cb, gpointer user_data);
-+ Gaim2NotifyCloseCallback cb, gpointer user_data);
-
- /**
- * Displays a notification with formatted text.
-@@ -390,9 +390,9 @@ void *gaim_notify_emails(void *handle, s
- *
- * @return A UI-specific handle.
- */
--void *gaim_notify_formatted(void *handle, const char *title,
-+void *gaim2_notify_formatted(void *handle, const char *title,
- const char *primary, const char *secondary,
-- const char *text, GaimNotifyCloseCallback cb, gpointer user_data);
-+ const char *text, Gaim2NotifyCloseCallback cb, gpointer user_data);
-
- /**
- * Displays user information with formatted text, passing information giving
-@@ -401,7 +401,7 @@ void *gaim_notify_formatted(void *handle
- * The text is essentially a stripped-down format of HTML, the same that
- * IMs may send.
- *
-- * @param gc The GaimConnection handle associated with the information.
-+ * @param gc The Gaim2Connection handle associated with the information.
- * @param who The username associated with the information.
- * @param text The formatted text.
- * @param cb The callback to call when the user closes
-@@ -410,8 +410,8 @@ void *gaim_notify_formatted(void *handle
- *
- * @return A UI-specific handle.
- */
--void *gaim_notify_userinfo(GaimConnection *gc, const char *who,
-- const char *text, GaimNotifyCloseCallback cb,
-+void *gaim2_notify_userinfo(Gaim2Connection *gc, const char *who,
-+ const char *text, Gaim2NotifyCloseCallback cb,
- gpointer user_data);
-
- /**
-@@ -424,7 +424,7 @@ void *gaim_notify_userinfo(GaimConnectio
- * the UI code displays a dialog instead of a webpage, or something
- * similar.
- */
--void *gaim_notify_uri(void *handle, const char *uri);
-+void *gaim2_notify_uri(void *handle, const char *uri);
-
- /**
- * Closes a notification.
-@@ -435,34 +435,34 @@ void *gaim_notify_uri(void *handle, cons
- * @param type The notification type.
- * @param ui_handle The notification UI handle.
- */
--void gaim_notify_close(GaimNotifyType type, void *ui_handle);
-+void gaim2_notify_close(Gaim2NotifyType type, void *ui_handle);
-
- /**
- * Closes all notifications registered with the specified handle.
- *
- * @param handle The handle.
- */
--void gaim_notify_close_with_handle(void *handle);
-+void gaim2_notify_close_with_handle(void *handle);
-
- /**
-- * A wrapper for gaim_notify_message that displays an information message.
-+ * A wrapper for gaim2_notify_message that displays an information message.
- */
--#define gaim_notify_info(handle, title, primary, secondary) \
-- gaim_notify_message((handle), GAIM_NOTIFY_MSG_INFO, (title), \
-+#define gaim2_notify_info(handle, title, primary, secondary) \
-+ gaim2_notify_message((handle), GAIM_NOTIFY_MSG_INFO, (title), \
- (primary), (secondary), NULL, NULL)
-
- /**
-- * A wrapper for gaim_notify_message that displays a warning message.
-+ * A wrapper for gaim2_notify_message that displays a warning message.
- */
--#define gaim_notify_warning(handle, title, primary, secondary) \
-- gaim_notify_message((handle), GAIM_NOTIFY_MSG_WARNING, (title), \
-+#define gaim2_notify_warning(handle, title, primary, secondary) \
-+ gaim2_notify_message((handle), GAIM_NOTIFY_MSG_WARNING, (title), \
- (primary), (secondary), NULL, NULL)
-
- /**
-- * A wrapper for gaim_notify_message that displays an error message.
-+ * A wrapper for gaim2_notify_message that displays an error message.
- */
--#define gaim_notify_error(handle, title, primary, secondary) \
-- gaim_notify_message((handle), GAIM_NOTIFY_MSG_ERROR, (title), \
-+#define gaim2_notify_error(handle, title, primary, secondary) \
-+ gaim2_notify_message((handle), GAIM_NOTIFY_MSG_ERROR, (title), \
- (primary), (secondary), NULL, NULL)
-
- /*@}*/
-@@ -478,7 +478,7 @@ void gaim_notify_close_with_handle(void
- *
- * @param ops The UI operations structure.
- */
--void gaim_notify_set_ui_ops(GaimNotifyUiOps *ops);
-+void gaim2_notify_set_ui_ops(Gaim2NotifyUiOps *ops);
-
- /**
- * Returns the UI operations structure to be used when displaying a
-@@ -486,7 +486,7 @@ void gaim_notify_set_ui_ops(GaimNotifyUi
- *
- * @return The UI operations structure.
- */
--GaimNotifyUiOps *gaim_notify_get_ui_ops(void);
-+Gaim2NotifyUiOps *gaim2_notify_get_ui_ops(void);
-
- /*@}*/
-
-@@ -500,17 +500,17 @@ GaimNotifyUiOps *gaim_notify_get_ui_ops(
- *
- * @return The notify subsystem handle.
- */
--void *gaim_notify_get_handle(void);
-+void *gaim2_notify_get_handle(void);
-
- /**
- * Initializes the notify subsystem.
- */
--void gaim_notify_init(void);
-+void gaim2_notify_init(void);
-
- /**
- * Uninitializes the notify subsystem.
- */
--void gaim_notify_uninit(void);
-+void gaim2_notify_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/ntlm.c ./src/ntlm.c
---- ./src/ntlm.c 2005-10-26 02:34:26.000000000 +0200
-+++ ./src/ntlm.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file ntlm.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -111,7 +111,7 @@ struct type3_message {
- #endif
- };
-
--gchar *gaim_ntlm_gen_type1(gchar *hostname, gchar *domain) {
-+gchar *gaim2_ntlm_gen_type1(gchar *hostname, gchar *domain) {
- char *msg = g_malloc0(sizeof(struct type1_message) + strlen(hostname) + strlen(domain));
- struct type1_message *tmsg = (struct type1_message*)msg;
- tmsg->protocol[0] = 'N';
-@@ -131,13 +131,13 @@ gchar *gaim_ntlm_gen_type1(gchar *hostna
- memcpy(msg+sizeof(struct type1_message),hostname,strlen(hostname));
- memcpy(msg+sizeof(struct type1_message)+strlen(hostname),domain,strlen(domain));
-
-- return gaim_base64_encode((guchar*)msg, sizeof(struct type1_message) + strlen(hostname) + strlen(domain));
-+ return gaim2_base64_encode((guchar*)msg, sizeof(struct type1_message) + strlen(hostname) + strlen(domain));
- }
-
--gchar *gaim_ntlm_parse_type2(gchar *type2) {
-+gchar *gaim2_ntlm_parse_type2(gchar *type2) {
- gsize retlen;
- static gchar nonce[8];
-- struct type2_message *tmsg = (struct type2_message*)gaim_base64_decode((char*)type2, &retlen);
-+ struct type2_message *tmsg = (struct type2_message*)gaim2_base64_decode((char*)type2, &retlen);
- memcpy(nonce, tmsg->nonce, 8);
- g_free(tmsg);
- return nonce;
-@@ -156,18 +156,18 @@ static void setup_des_key(unsigned char
- }
-
- /*
-- * helper function for gaim cipher.c
-+ * helper function for gaim2 cipher.c
- */
- static void des_ecb_encrypt(char *plaintext, char *result, char *key) {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- gsize outlen;
-
-- cipher = gaim_ciphers_find_cipher("des");
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_set_key(context, (guchar*)key);
-- gaim_cipher_context_encrypt(context, (guchar*)plaintext, 8, (guchar*)result, &outlen);
-- gaim_cipher_context_destroy(context);
-+ cipher = gaim2_ciphers_find_cipher("des");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_set_key(context, (guchar*)key);
-+ gaim2_cipher_context_encrypt(context, (guchar*)plaintext, 8, (guchar*)result, &outlen);
-+ gaim2_cipher_context_destroy(context);
- }
-
- /*
-@@ -188,7 +188,7 @@ static void calc_resp(unsigned char *key
- des_ecb_encrypt((char*)plaintext, (char*)(results+16), (char*)key);
- }
-
--gchar *gaim_ntlm_gen_type3(gchar *username, gchar *passw, gchar *hostname, gchar *domain, gchar *nonce) {
-+gchar *gaim2_ntlm_gen_type3(gchar *username, gchar *passw, gchar *hostname, gchar *domain, gchar *nonce) {
- char lm_pw[14];
- unsigned char lm_hpw[21];
- gchar key[8];
-@@ -200,8 +200,8 @@ gchar *gaim_ntlm_gen_type3(gchar *userna
- unsigned char nt_hpw[21];
- int lennt;
- char nt_pw[128];
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- char *tmp = 0;
- int idx = 0;
-
-@@ -262,11 +262,11 @@ gchar *gaim_ntlm_gen_type3(gchar *userna
- nt_pw[2*idx+1] = 0;
- }
-
-- cipher = gaim_ciphers_find_cipher("md4");
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, (guchar*)nt_pw, 2*lennt);
-- gaim_cipher_context_digest(context, 21, (guchar*)nt_hpw, NULL);
-- gaim_cipher_context_destroy(context);
-+ cipher = gaim2_ciphers_find_cipher("md4");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, (guchar*)nt_pw, 2*lennt);
-+ gaim2_cipher_context_digest(context, 21, (guchar*)nt_hpw, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- memset(nt_hpw+16, 0, 5);
-
-@@ -275,7 +275,7 @@ gchar *gaim_ntlm_gen_type3(gchar *userna
- calc_resp(nt_hpw, (guchar*)nonce, nt_resp);
- memcpy(tmp, lm_resp, 0x18);
- memcpy(tmp+0x18, nt_resp, 0x18);
-- tmp = gaim_base64_encode((guchar*) tmsg, tmsg->msg_len);
-+ tmp = gaim2_base64_encode((guchar*) tmsg, tmsg->msg_len);
- g_free(tmsg);
- return tmp;
- }
-diff -prNu ./src/ntlm.h ./src/ntlm.h
---- ./src/ntlm.h 2005-08-30 20:22:28.000000000 +0200
-+++ ./src/ntlm.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file ntlm.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005, Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -33,7 +33,7 @@
- * @param domain The domain to authenticate to
- * @return base64 encoded string to send to the server. has to be freed with g_free
- */
--gchar *gaim_ntlm_gen_type1(gchar *hostname, gchar *domain);
-+gchar *gaim2_ntlm_gen_type1(gchar *hostname, gchar *domain);
-
- /**
- * Parses the ntlm type 2 message
-@@ -41,7 +41,7 @@ gchar *gaim_ntlm_gen_type1(gchar *hostna
- * @param type2 String containing the base64 encoded type2 message
- * @return The nonce for use in message type3
- */
--gchar *gaim_ntlm_parse_type2(gchar *type2);
-+gchar *gaim2_ntlm_parse_type2(gchar *type2);
-
- /**
- * Generates a type3 message
-@@ -50,9 +50,9 @@ gchar *gaim_ntlm_parse_type2(gchar *type
- * @param passw The password
- * @param hostname The hostname
- * @param domain The domain to authenticate against
-- * @param nonce The nonce returned by gaim_ntlm_parse_type2
-+ * @param nonce The nonce returned by gaim2_ntlm_parse_type2
- * @return A base64 encoded type3 message
- */
--gchar *gaim_ntlm_gen_type3(gchar *username, gchar *passw, gchar *hostname, gchar *domain, gchar *nonce);
-+gchar *gaim2_ntlm_gen_type3(gchar *username, gchar *passw, gchar *hostname, gchar *domain, gchar *nonce);
-
- #endif /* _GAIM_NTLM_H */
-diff -prNu ./src/plugin.c ./src/plugin.c
---- ./src/plugin.c 2006-01-03 21:30:22.000000000 +0100
-+++ ./src/plugin.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -36,18 +36,18 @@ typedef struct
- GHashTable *commands;
- size_t command_count;
-
--} GaimPluginIpcInfo;
-+} Gaim2PluginIpcInfo;
-
- typedef struct
- {
-- GaimCallback func;
-- GaimSignalMarshalFunc marshal;
-+ Gaim2Callback func;
-+ Gaim2SignalMarshalFunc marshal;
-
- int num_params;
-- GaimValue **params;
-- GaimValue *ret_value;
-+ Gaim2Value **params;
-+ Gaim2Value *ret_value;
-
--} GaimPluginIpcCommand;
-+} Gaim2PluginIpcCommand;
-
- static GList *search_paths = NULL;
- static GList *plugins = NULL;
-@@ -65,9 +65,9 @@ static GList *plugin_loaders = NULL;
- */
- static void (*probe_cb)(void *) = NULL;
- static void *probe_cb_data = NULL;
--static void (*load_cb)(GaimPlugin *, void *) = NULL;
-+static void (*load_cb)(Gaim2Plugin *, void *) = NULL;
- static void *load_cb_data = NULL;
--static void (*unload_cb)(GaimPlugin *, void *) = NULL;
-+static void (*unload_cb)(Gaim2Plugin *, void *) = NULL;
- static void *unload_cb_data = NULL;
-
- #ifdef GAIM_PLUGINS
-@@ -104,7 +104,7 @@ is_native(const char *filename)
- }
-
- static char *
--gaim_plugin_get_basename(const char *filename)
-+gaim2_plugin_get_basename(const char *filename)
- {
- const char *basename;
- const char *last_period;
-@@ -123,7 +123,7 @@ gaim_plugin_get_basename(const char *fil
- }
-
- static gboolean
--loader_supports_file(GaimPlugin *loader, const char *filename)
-+loader_supports_file(Gaim2Plugin *loader, const char *filename)
- {
- GList *exts;
-
-@@ -136,16 +136,16 @@ loader_supports_file(GaimPlugin *loader,
- return FALSE;
- }
-
--static GaimPlugin *
--find_loader_for_plugin(const GaimPlugin *plugin)
-+static Gaim2Plugin *
-+find_loader_for_plugin(const Gaim2Plugin *plugin)
- {
-- GaimPlugin *loader;
-+ Gaim2Plugin *loader;
- GList *l;
-
- if (plugin->path == NULL)
- return NULL;
-
-- for (l = gaim_plugins_get_loaded(); l != NULL; l = l->next) {
-+ for (l = gaim2_plugins_get_loaded(); l != NULL; l = l->next) {
- loader = l->data;
-
- if (loader->info->type == GAIM_PLUGIN_LOADER &&
-@@ -166,7 +166,7 @@ find_loader_for_plugin(const GaimPlugin
- * Negative if a before b, 0 if equal, positive if a after b.
- */
- static gint
--compare_prpl(GaimPlugin *a, GaimPlugin *b)
-+compare_prpl(Gaim2Plugin *a, Gaim2Plugin *b)
- {
- if(GAIM_IS_PROTOCOL_PLUGIN(a)) {
- if(GAIM_IS_PROTOCOL_PLUGIN(b))
-@@ -181,12 +181,12 @@ compare_prpl(GaimPlugin *a, GaimPlugin *
- }
- }
-
--GaimPlugin *
--gaim_plugin_new(gboolean native, const char *path)
-+Gaim2Plugin *
-+gaim2_plugin_new(gboolean native, const char *path)
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
-
-- plugin = g_new0(GaimPlugin, 1);
-+ plugin = g_new0(Gaim2Plugin, 1);
-
- plugin->native_plugin = native;
- plugin->path = (path == NULL ? NULL : g_strdup(path));
-@@ -194,33 +194,33 @@ gaim_plugin_new(gboolean native, const c
- return plugin;
- }
-
--GaimPlugin *
--gaim_plugin_probe(const char *filename)
-+Gaim2Plugin *
-+gaim2_plugin_probe(const char *filename)
- {
- #ifdef GAIM_PLUGINS
-- GaimPlugin *plugin = NULL;
-- GaimPlugin *loader;
-+ Gaim2Plugin *plugin = NULL;
-+ Gaim2Plugin *loader;
- gpointer unpunned;
- gchar *basename = NULL;
-- gboolean (*gaim_init_plugin)(GaimPlugin *);
-+ gboolean (*gaim2_init_plugin)(Gaim2Plugin *);
-
-- gaim_debug_misc("plugins", "probing %s\n", filename);
-+ gaim2_debug_misc("plugins", "probing %s\n", filename);
- g_return_val_if_fail(filename != NULL, NULL);
-
- if (!g_file_test(filename, G_FILE_TEST_EXISTS))
- return NULL;
-
- /* If this plugin has already been probed then exit */
-- basename = gaim_plugin_get_basename(filename);
-- plugin = gaim_plugins_find_with_basename(basename);
-+ basename = gaim2_plugin_get_basename(filename);
-+ plugin = gaim2_plugins_find_with_basename(basename);
- g_free(basename);
- if (plugin != NULL)
- {
- if (!strcmp(filename, plugin->path))
- return plugin;
-- else if (!gaim_plugin_is_unloadable(plugin))
-+ else if (!gaim2_plugin_is_unloadable(plugin))
- {
-- gaim_debug_info("plugins", "Not loading %s. "
-+ gaim2_debug_info("plugins", "Not loading %s. "
- "Another plugin with the same name (%s) has already been loaded.\n",
- filename, plugin->path);
- return plugin;
-@@ -232,11 +232,11 @@ gaim_plugin_probe(const char *filename)
- * will be loadable, but unless it fails in one of the silent
- * ways and the first one didn't, it's not any worse. The user
- * will still see a greyed-out plugin, which is what we want. */
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
- }
- }
-
-- plugin = gaim_plugin_new(has_file_extension(filename, G_MODULE_SUFFIX), filename);
-+ plugin = gaim2_plugin_new(has_file_extension(filename, G_MODULE_SUFFIX), filename);
-
- if (plugin->native_plugin) {
- const char *error;
-@@ -261,7 +261,7 @@ gaim_plugin_probe(const char *filename)
- if (plugin->handle == NULL)
- {
- const char *error = g_module_error();
-- if (error != NULL && gaim_str_has_prefix(error, filename))
-+ if (error != NULL && gaim2_str_has_prefix(error, filename))
- {
- error = error + strlen(filename);
-
-@@ -276,13 +276,13 @@ gaim_plugin_probe(const char *filename)
- if (error == NULL || !*error)
- {
- plugin->error = g_strdup(_("Unknown error"));
-- gaim_debug_error("plugins", "%s is unloadable: Unknown error\n",
-+ gaim2_debug_error("plugins", "%s is unloadable: Unknown error\n",
- plugin->path);
- }
- else
- {
- plugin->error = g_strdup(error);
-- gaim_debug_error("plugins", "%s is unloadable: %s\n",
-+ gaim2_debug_error("plugins", "%s is unloadable: %s\n",
- plugin->path, plugin->error);
- }
- #if GLIB_CHECK_VERSION(2,3,3)
-@@ -297,7 +297,7 @@ gaim_plugin_probe(const char *filename)
- /* Restore the original error mode */
- SetErrorMode(old_error_mode);
- #endif
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
- return NULL;
- }
- else
-@@ -310,18 +310,18 @@ gaim_plugin_probe(const char *filename)
- }
- }
-
-- if (!g_module_symbol(plugin->handle, "gaim_init_plugin",
-+ if (!g_module_symbol(plugin->handle, "gaim2_init_plugin",
- &unpunned))
- {
-- gaim_debug_error("plugins", "%s is not usable because the "
-- "'gaim_init_plugin' symbol could not be "
-+ gaim2_debug_error("plugins", "%s is not usable because the "
-+ "'gaim2_init_plugin' symbol could not be "
- "found. Does the plugin call the "
- "GAIM_INIT_PLUGIN() macro?\n", plugin->path);
-
- g_module_close(plugin->handle);
- error = g_module_error();
- if (error != NULL)
-- gaim_debug_error("plugins", "Error closing module %s: %s\n",
-+ gaim2_debug_error("plugins", "Error closing module %s: %s\n",
- plugin->path, error);
- plugin->handle = NULL;
-
-@@ -329,10 +329,10 @@ gaim_plugin_probe(const char *filename)
- /* Restore the original error mode */
- SetErrorMode(old_error_mode);
- #endif
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
- return NULL;
- }
-- gaim_init_plugin = unpunned;
-+ gaim2_init_plugin = unpunned;
-
- #ifdef _WIN32
- /* Restore the original error mode */
-@@ -343,16 +343,16 @@ gaim_plugin_probe(const char *filename)
- loader = find_loader_for_plugin(plugin);
-
- if (loader == NULL) {
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
- return NULL;
- }
-
-- gaim_init_plugin = GAIM_PLUGIN_LOADER_INFO(loader)->probe;
-+ gaim2_init_plugin = GAIM_PLUGIN_LOADER_INFO(loader)->probe;
- }
-
-- if (!gaim_init_plugin(plugin) || plugin->info == NULL)
-+ if (!gaim2_init_plugin(plugin) || plugin->info == NULL)
- {
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
- return NULL;
- }
-
-@@ -361,14 +361,14 @@ gaim_plugin_probe(const char *filename)
- {
- if (plugin->info->magic >= 2 && plugin->info->magic <= 4)
- {
-- struct _GaimPluginInfo2
-+ struct _Gaim2PluginInfo2
- {
- unsigned int api_version;
-- GaimPluginType type;
-+ Gaim2PluginType type;
- char *ui_requirement;
- unsigned long flags;
- GList *dependencies;
-- GaimPluginPriority priority;
-+ Gaim2PluginPriority priority;
-
- char *id;
- char *name;
-@@ -378,18 +378,18 @@ gaim_plugin_probe(const char *filename)
- char *author;
- char *homepage;
-
-- gboolean (*load)(GaimPlugin *plugin);
-- gboolean (*unload)(GaimPlugin *plugin);
-- void (*destroy)(GaimPlugin *plugin);
-+ gboolean (*load)(Gaim2Plugin *plugin);
-+ gboolean (*unload)(Gaim2Plugin *plugin);
-+ void (*destroy)(Gaim2Plugin *plugin);
-
- void *ui_info;
- void *extra_info;
-- GaimPluginUiInfo *prefs_info;
-- GList *(*actions)(GaimPlugin *plugin, gpointer context);
-- } *info2 = (struct _GaimPluginInfo2 *)plugin->info;
-+ Gaim2PluginUiInfo *prefs_info;
-+ GList *(*actions)(Gaim2Plugin *plugin, gpointer context);
-+ } *info2 = (struct _Gaim2PluginInfo2 *)plugin->info;
-
- /* This leaks... but only for ancient plugins, so deal with it. */
-- plugin->info = g_new0(GaimPluginInfo, 1);
-+ plugin->info = g_new0(Gaim2PluginInfo, 1);
-
- /* We don't really need all these to display the plugin info, but
- * I'm copying them all for good measure. */
-@@ -420,15 +420,15 @@ gaim_plugin_probe(const char *filename)
-
- plugin->error = g_strdup_printf(_("Plugin magic mismatch %d (need %d)"),
- plugin->info->magic, GAIM_PLUGIN_MAGIC);
-- gaim_debug_error("plugins", "%s is unloadable: Plugin magic mismatch %d (need %d)\n",
-+ gaim2_debug_error("plugins", "%s is unloadable: Plugin magic mismatch %d (need %d)\n",
- plugin->path, plugin->info->magic, GAIM_PLUGIN_MAGIC);
- plugin->unloadable = TRUE;
- return plugin;
- }
-
-- gaim_debug_error("plugins", "%s is unloadable: Plugin magic mismatch %d (need %d)\n",
-+ gaim2_debug_error("plugins", "%s is unloadable: Plugin magic mismatch %d (need %d)\n",
- plugin->path, plugin->info->magic, GAIM_PLUGIN_MAGIC);
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
- return NULL;
- }
-
-@@ -438,7 +438,7 @@ gaim_plugin_probe(const char *filename)
- plugin->error = g_strdup_printf(_("ABI version mismatch %d.%d.x (need %d.%d.x)"),
- plugin->info->major_version, plugin->info->minor_version,
- GAIM_MAJOR_VERSION, GAIM_MINOR_VERSION);
-- gaim_debug_error("plugins", "%s is unloadable: ABI version mismatch %d.%d.x (need %d.%d.x)\n",
-+ gaim2_debug_error("plugins", "%s is unloadable: ABI version mismatch %d.%d.x (need %d.%d.x)\n",
- plugin->path, plugin->info->major_version, plugin->info->minor_version,
- GAIM_MAJOR_VERSION, GAIM_MINOR_VERSION);
- plugin->unloadable = TRUE;
-@@ -452,7 +452,7 @@ gaim_plugin_probe(const char *filename)
- (GAIM_PLUGIN_PROTOCOL_INFO(plugin)->close == NULL)))
- {
- plugin->error = g_strdup(_("Plugin does not implement all required functions"));
-- gaim_debug_error("plugins", "%s is unloadable: Plugin does not implement all required functions\n",
-+ gaim2_debug_error("plugins", "%s is unloadable: Plugin does not implement all required functions\n",
- plugin->path);
- plugin->unloadable = TRUE;
- return plugin;
-@@ -467,14 +467,14 @@ gaim_plugin_probe(const char *filename)
- static gint
- compare_plugins(gconstpointer a, gconstpointer b)
- {
-- const GaimPlugin *plugina = a;
-- const GaimPlugin *pluginb = b;
-+ const Gaim2Plugin *plugina = a;
-+ const Gaim2Plugin *pluginb = b;
-
- return strcmp(plugina->info->name, pluginb->info->name);
- }
-
- gboolean
--gaim_plugin_load(GaimPlugin *plugin)
-+gaim2_plugin_load(Gaim2Plugin *plugin)
- {
- #ifdef GAIM_PLUGINS
- GList *dep_list = NULL;
-@@ -482,10 +482,10 @@ gaim_plugin_load(GaimPlugin *plugin)
-
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-- if (gaim_plugin_is_loaded(plugin))
-+ if (gaim2_plugin_is_loaded(plugin))
- return TRUE;
-
-- if (gaim_plugin_is_unloadable(plugin))
-+ if (gaim2_plugin_is_unloadable(plugin))
- return FALSE;
-
- g_return_val_if_fail(plugin->error == NULL, FALSE);
-@@ -498,9 +498,9 @@ gaim_plugin_load(GaimPlugin *plugin)
- for (l = plugin->info->dependencies; l != NULL; l = l->next)
- {
- const char *dep_name = (const char *)l->data;
-- GaimPlugin *dep_plugin;
-+ Gaim2Plugin *dep_plugin;
-
-- dep_plugin = gaim_plugins_find_with_id(dep_name);
-+ dep_plugin = gaim2_plugins_find_with_id(dep_name);
-
- if (dep_plugin == NULL)
- {
-@@ -511,8 +511,8 @@ gaim_plugin_load(GaimPlugin *plugin)
- "Please install this plugin and try again."),
- dep_name);
-
-- gaim_notify_error(NULL, NULL,
-- _("Gaim was unable to load your plugin."),
-+ gaim2_notify_error(NULL, NULL,
-+ _("Gaim2 was unable to load your plugin."),
- buf);
-
- if (dep_list != NULL)
-@@ -527,11 +527,11 @@ gaim_plugin_load(GaimPlugin *plugin)
- /* Second pass: load all the required plugins. */
- for (l = dep_list; l != NULL; l = l->next)
- {
-- GaimPlugin *dep_plugin = (GaimPlugin *)l->data;
-+ Gaim2Plugin *dep_plugin = (Gaim2Plugin *)l->data;
-
-- if (!gaim_plugin_is_loaded(dep_plugin))
-+ if (!gaim2_plugin_is_loaded(dep_plugin))
- {
-- if (!gaim_plugin_load(dep_plugin))
-+ if (!gaim2_plugin_load(dep_plugin))
- {
- char buf[BUFSIZ];
-
-@@ -539,8 +539,8 @@ gaim_plugin_load(GaimPlugin *plugin)
- _("The required plugin %s was unable to load."),
- plugin->info->name);
-
-- gaim_notify_error(NULL, NULL,
-- _("Gaim was unable to load your plugin."),
-+ gaim2_notify_error(NULL, NULL,
-+ _("Gaim2 was unable to load your plugin."),
- buf);
-
- if (dep_list != NULL)
-@@ -563,8 +563,8 @@ gaim_plugin_load(GaimPlugin *plugin)
- }
- }
- else {
-- GaimPlugin *loader;
-- GaimPluginLoaderInfo *loader_info;
-+ Gaim2Plugin *loader;
-+ Gaim2PluginLoaderInfo *loader_info;
-
- loader = find_loader_for_plugin(plugin);
-
-@@ -588,7 +588,7 @@ gaim_plugin_load(GaimPlugin *plugin)
- if (load_cb != NULL)
- load_cb(plugin, load_cb_data);
-
-- gaim_signal_emit(gaim_plugins_get_handle(), "plugin-load", plugin);
-+ gaim2_signal_emit(gaim2_plugins_get_handle(), "plugin-load", plugin);
-
- return TRUE;
-
-@@ -598,7 +598,7 @@ gaim_plugin_load(GaimPlugin *plugin)
- }
-
- gboolean
--gaim_plugin_unload(GaimPlugin *plugin)
-+gaim2_plugin_unload(Gaim2Plugin *plugin)
- {
- #ifdef GAIM_PLUGINS
- g_return_val_if_fail(plugin != NULL, FALSE);
-@@ -607,13 +607,13 @@ gaim_plugin_unload(GaimPlugin *plugin)
- if ((plugin->info != NULL) && GAIM_IS_PROTOCOL_PLUGIN(plugin))
- protocol_plugins = g_list_remove(protocol_plugins, plugin);
-
-- g_return_val_if_fail(gaim_plugin_is_loaded(plugin), FALSE);
-+ g_return_val_if_fail(gaim2_plugin_is_loaded(plugin), FALSE);
-
-- gaim_debug_info("plugins", "Unloading plugin %s\n", plugin->info->name);
-+ gaim2_debug_info("plugins", "Unloading plugin %s\n", plugin->info->name);
-
- /* cancel any pending dialogs the plugin has */
-- gaim_request_close_with_handle(plugin);
-- gaim_notify_close_with_handle(plugin);
-+ gaim2_request_close_with_handle(plugin);
-+ gaim2_notify_close_with_handle(plugin);
-
- plugin->loaded = FALSE;
-
-@@ -622,16 +622,16 @@ gaim_plugin_unload(GaimPlugin *plugin)
- plugin->info->unload(plugin);
-
- if (plugin->info->type == GAIM_PLUGIN_PROTOCOL) {
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2PluginProtocolInfo *prpl_info;
- GList *l;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(plugin);
-
- for (l = prpl_info->user_splits; l != NULL; l = l->next)
-- gaim_account_user_split_destroy(l->data);
-+ gaim2_account_user_split_destroy(l->data);
-
- for (l = prpl_info->protocol_options; l != NULL; l = l->next)
-- gaim_account_option_destroy(l->data);
-+ gaim2_account_option_destroy(l->data);
-
- if (prpl_info->user_splits != NULL) {
- g_list_free(prpl_info->user_splits);
-@@ -645,8 +645,8 @@ gaim_plugin_unload(GaimPlugin *plugin)
- }
- }
- else {
-- GaimPlugin *loader;
-- GaimPluginLoaderInfo *loader_info;
-+ Gaim2Plugin *loader;
-+ Gaim2PluginLoaderInfo *loader_info;
-
- loader = find_loader_for_plugin(plugin);
-
-@@ -659,16 +659,16 @@ gaim_plugin_unload(GaimPlugin *plugin)
- loader_info->unload(plugin);
- }
-
-- gaim_signals_disconnect_by_handle(plugin);
-- gaim_plugin_ipc_unregister_all(plugin);
-+ gaim2_signals_disconnect_by_handle(plugin);
-+ gaim2_plugin_ipc_unregister_all(plugin);
-
- /* TODO */
- if (unload_cb != NULL)
- unload_cb(plugin, unload_cb_data);
-
-- gaim_signal_emit(gaim_plugins_get_handle(), "plugin-unload", plugin);
-+ gaim2_signal_emit(gaim2_plugins_get_handle(), "plugin-unload", plugin);
-
-- gaim_prefs_disconnect_by_handle(plugin);
-+ gaim2_prefs_disconnect_by_handle(plugin);
-
- return TRUE;
- #else
-@@ -677,16 +677,16 @@ gaim_plugin_unload(GaimPlugin *plugin)
- }
-
- gboolean
--gaim_plugin_reload(GaimPlugin *plugin)
-+gaim2_plugin_reload(Gaim2Plugin *plugin)
- {
- #ifdef GAIM_PLUGINS
- g_return_val_if_fail(plugin != NULL, FALSE);
-- g_return_val_if_fail(gaim_plugin_is_loaded(plugin), FALSE);
-+ g_return_val_if_fail(gaim2_plugin_is_loaded(plugin), FALSE);
-
-- if (!gaim_plugin_unload(plugin))
-+ if (!gaim2_plugin_unload(plugin))
- return FALSE;
-
-- if (!gaim_plugin_load(plugin))
-+ if (!gaim2_plugin_load(plugin))
- return FALSE;
-
- return TRUE;
-@@ -696,13 +696,13 @@ gaim_plugin_reload(GaimPlugin *plugin)
- }
-
- void
--gaim_plugin_destroy(GaimPlugin *plugin)
-+gaim2_plugin_destroy(Gaim2Plugin *plugin)
- {
- #ifdef GAIM_PLUGINS
- g_return_if_fail(plugin != NULL);
-
-- if (gaim_plugin_is_loaded(plugin))
-- gaim_plugin_unload(plugin);
-+ if (gaim2_plugin_is_loaded(plugin))
-+ gaim2_plugin_unload(plugin);
-
- plugins = g_list_remove(plugins, plugin);
-
-@@ -727,9 +727,9 @@ gaim_plugin_destroy(GaimPlugin *plugin)
- {
- if (plugin->info != NULL && plugin->info->type == GAIM_PLUGIN_LOADER)
- {
-- GaimPluginLoaderInfo *loader_info;
-+ Gaim2PluginLoaderInfo *loader_info;
- GList *exts, *l, *next_l;
-- GaimPlugin *p2;
-+ Gaim2Plugin *p2;
-
- loader_info = GAIM_PLUGIN_LOADER_INFO(plugin);
-
-@@ -739,7 +739,7 @@ gaim_plugin_destroy(GaimPlugin *plugin)
- exts != NULL;
- exts = exts->next) {
-
-- for (l = gaim_plugins_get_all(); l != NULL; l = next_l)
-+ for (l = gaim2_plugins_get_all(); l != NULL; l = next_l)
- {
- next_l = l->next;
-
-@@ -748,7 +748,7 @@ gaim_plugin_destroy(GaimPlugin *plugin)
- if (p2->path != NULL &&
- has_file_extension(p2->path, exts->data))
- {
-- gaim_plugin_destroy(p2);
-+ gaim2_plugin_destroy(p2);
- }
- }
- }
-@@ -767,8 +767,8 @@ gaim_plugin_destroy(GaimPlugin *plugin)
- }
- else
- {
-- GaimPlugin *loader;
-- GaimPluginLoaderInfo *loader_info;
-+ Gaim2Plugin *loader;
-+ Gaim2PluginLoaderInfo *loader_info;
-
- loader = find_loader_for_plugin(plugin);
-
-@@ -789,7 +789,7 @@ gaim_plugin_destroy(GaimPlugin *plugin)
- }
-
- gboolean
--gaim_plugin_is_loaded(const GaimPlugin *plugin)
-+gaim2_plugin_is_loaded(const Gaim2Plugin *plugin)
- {
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-@@ -797,7 +797,7 @@ gaim_plugin_is_loaded(const GaimPlugin *
- }
-
- gboolean
--gaim_plugin_is_unloadable(const GaimPlugin *plugin)
-+gaim2_plugin_is_unloadable(const Gaim2Plugin *plugin)
- {
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-@@ -805,7 +805,7 @@ gaim_plugin_is_unloadable(const GaimPlug
- }
-
- const gchar *
--gaim_plugin_get_id(const GaimPlugin *plugin) {
-+gaim2_plugin_get_id(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -813,7 +813,7 @@ gaim_plugin_get_id(const GaimPlugin *plu
- }
-
- const gchar *
--gaim_plugin_get_name(const GaimPlugin *plugin) {
-+gaim2_plugin_get_name(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -821,7 +821,7 @@ gaim_plugin_get_name(const GaimPlugin *p
- }
-
- const gchar *
--gaim_plugin_get_version(const GaimPlugin *plugin) {
-+gaim2_plugin_get_version(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -829,7 +829,7 @@ gaim_plugin_get_version(const GaimPlugin
- }
-
- const gchar *
--gaim_plugin_get_summary(const GaimPlugin *plugin) {
-+gaim2_plugin_get_summary(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -837,7 +837,7 @@ gaim_plugin_get_summary(const GaimPlugin
- }
-
- const gchar *
--gaim_plugin_get_description(const GaimPlugin *plugin) {
-+gaim2_plugin_get_description(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -845,7 +845,7 @@ gaim_plugin_get_description(const GaimPl
- }
-
- const gchar *
--gaim_plugin_get_author(const GaimPlugin *plugin) {
-+gaim2_plugin_get_author(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -853,7 +853,7 @@ gaim_plugin_get_author(const GaimPlugin
- }
-
- const gchar *
--gaim_plugin_get_homepage(const GaimPlugin *plugin) {
-+gaim2_plugin_get_homepage(const Gaim2Plugin *plugin) {
- g_return_val_if_fail(plugin, NULL);
- g_return_val_if_fail(plugin->info, NULL);
-
-@@ -866,30 +866,30 @@ gaim_plugin_get_homepage(const GaimPlugi
- static void
- destroy_ipc_info(void *data)
- {
-- GaimPluginIpcCommand *ipc_command = (GaimPluginIpcCommand *)data;
-+ Gaim2PluginIpcCommand *ipc_command = (Gaim2PluginIpcCommand *)data;
- int i;
-
- if (ipc_command->params != NULL)
- {
- for (i = 0; i < ipc_command->num_params; i++)
-- gaim_value_destroy(ipc_command->params[i]);
-+ gaim2_value_destroy(ipc_command->params[i]);
-
- g_free(ipc_command->params);
- }
-
- if (ipc_command->ret_value != NULL)
-- gaim_value_destroy(ipc_command->ret_value);
-+ gaim2_value_destroy(ipc_command->ret_value);
-
- g_free(ipc_command);
- }
-
- gboolean
--gaim_plugin_ipc_register(GaimPlugin *plugin, const char *command,
-- GaimCallback func, GaimSignalMarshalFunc marshal,
-- GaimValue *ret_value, int num_params, ...)
-+gaim2_plugin_ipc_register(Gaim2Plugin *plugin, const char *command,
-+ Gaim2Callback func, Gaim2SignalMarshalFunc marshal,
-+ Gaim2Value *ret_value, int num_params, ...)
- {
-- GaimPluginIpcInfo *ipc_info;
-- GaimPluginIpcCommand *ipc_command;
-+ Gaim2PluginIpcInfo *ipc_info;
-+ Gaim2PluginIpcCommand *ipc_command;
-
- g_return_val_if_fail(plugin != NULL, FALSE);
- g_return_val_if_fail(command != NULL, FALSE);
-@@ -898,14 +898,14 @@ gaim_plugin_ipc_register(GaimPlugin *plu
-
- if (plugin->ipc_data == NULL)
- {
-- ipc_info = plugin->ipc_data = g_new0(GaimPluginIpcInfo, 1);
-+ ipc_info = plugin->ipc_data = g_new0(Gaim2PluginIpcInfo, 1);
- ipc_info->commands = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, destroy_ipc_info);
- }
- else
-- ipc_info = (GaimPluginIpcInfo *)plugin->ipc_data;
-+ ipc_info = (Gaim2PluginIpcInfo *)plugin->ipc_data;
-
-- ipc_command = g_new0(GaimPluginIpcCommand, 1);
-+ ipc_command = g_new0(Gaim2PluginIpcCommand, 1);
- ipc_command->func = func;
- ipc_command->marshal = marshal;
- ipc_command->num_params = num_params;
-@@ -916,12 +916,12 @@ gaim_plugin_ipc_register(GaimPlugin *plu
- va_list args;
- int i;
-
-- ipc_command->params = g_new0(GaimValue *, num_params);
-+ ipc_command->params = g_new0(Gaim2Value *, num_params);
-
- va_start(args, num_params);
-
- for (i = 0; i < num_params; i++)
-- ipc_command->params[i] = va_arg(args, GaimValue *);
-+ ipc_command->params[i] = va_arg(args, Gaim2Value *);
-
- va_end(args);
- }
-@@ -934,19 +934,19 @@ gaim_plugin_ipc_register(GaimPlugin *plu
- }
-
- void
--gaim_plugin_ipc_unregister(GaimPlugin *plugin, const char *command)
-+gaim2_plugin_ipc_unregister(Gaim2Plugin *plugin, const char *command)
- {
-- GaimPluginIpcInfo *ipc_info;
-+ Gaim2PluginIpcInfo *ipc_info;
-
- g_return_if_fail(plugin != NULL);
- g_return_if_fail(command != NULL);
-
-- ipc_info = (GaimPluginIpcInfo *)plugin->ipc_data;
-+ ipc_info = (Gaim2PluginIpcInfo *)plugin->ipc_data;
-
- if (ipc_info == NULL ||
- g_hash_table_lookup(ipc_info->commands, command) == NULL)
- {
-- gaim_debug_error("plugins",
-+ gaim2_debug_error("plugins",
- "IPC command '%s' was not registered for plugin %s\n",
- command, plugin->info->name);
- return;
-@@ -966,16 +966,16 @@ gaim_plugin_ipc_unregister(GaimPlugin *p
- }
-
- void
--gaim_plugin_ipc_unregister_all(GaimPlugin *plugin)
-+gaim2_plugin_ipc_unregister_all(Gaim2Plugin *plugin)
- {
-- GaimPluginIpcInfo *ipc_info;
-+ Gaim2PluginIpcInfo *ipc_info;
-
- g_return_if_fail(plugin != NULL);
-
- if (plugin->ipc_data == NULL)
- return; /* Silently ignore it. */
-
-- ipc_info = (GaimPluginIpcInfo *)plugin->ipc_data;
-+ ipc_info = (Gaim2PluginIpcInfo *)plugin->ipc_data;
-
- g_hash_table_destroy(ipc_info->commands);
- g_free(ipc_info);
-@@ -984,23 +984,23 @@ gaim_plugin_ipc_unregister_all(GaimPlugi
- }
-
- gboolean
--gaim_plugin_ipc_get_params(GaimPlugin *plugin, const char *command,
-- GaimValue **ret_value, int *num_params,
-- GaimValue ***params)
-+gaim2_plugin_ipc_get_params(Gaim2Plugin *plugin, const char *command,
-+ Gaim2Value **ret_value, int *num_params,
-+ Gaim2Value ***params)
- {
-- GaimPluginIpcInfo *ipc_info;
-- GaimPluginIpcCommand *ipc_command;
-+ Gaim2PluginIpcInfo *ipc_info;
-+ Gaim2PluginIpcCommand *ipc_command;
-
- g_return_val_if_fail(plugin != NULL, FALSE);
- g_return_val_if_fail(command != NULL, FALSE);
-
-- ipc_info = (GaimPluginIpcInfo *)plugin->ipc_data;
-+ ipc_info = (Gaim2PluginIpcInfo *)plugin->ipc_data;
-
- if (ipc_info == NULL ||
- (ipc_command = g_hash_table_lookup(ipc_info->commands,
- command)) == NULL)
- {
-- gaim_debug_error("plugins",
-+ gaim2_debug_error("plugins",
- "IPC command '%s' was not registered for plugin %s\n",
- command, plugin->info->name);
-
-@@ -1020,11 +1020,11 @@ gaim_plugin_ipc_get_params(GaimPlugin *p
- }
-
- void *
--gaim_plugin_ipc_call(GaimPlugin *plugin, const char *command,
-+gaim2_plugin_ipc_call(Gaim2Plugin *plugin, const char *command,
- gboolean *ok, ...)
- {
-- GaimPluginIpcInfo *ipc_info;
-- GaimPluginIpcCommand *ipc_command;
-+ Gaim2PluginIpcInfo *ipc_info;
-+ Gaim2PluginIpcCommand *ipc_command;
- va_list args;
- void *ret_value;
-
-@@ -1034,13 +1034,13 @@ gaim_plugin_ipc_call(GaimPlugin *plugin,
- g_return_val_if_fail(plugin != NULL, NULL);
- g_return_val_if_fail(command != NULL, NULL);
-
-- ipc_info = (GaimPluginIpcInfo *)plugin->ipc_data;
-+ ipc_info = (Gaim2PluginIpcInfo *)plugin->ipc_data;
-
- if (ipc_info == NULL ||
- (ipc_command = g_hash_table_lookup(ipc_info->commands,
- command)) == NULL)
- {
-- gaim_debug_error("plugins",
-+ gaim2_debug_error("plugins",
- "IPC command '%s' was not registered for plugin %s\n",
- command, plugin->info->name);
-
-@@ -1061,38 +1061,38 @@ gaim_plugin_ipc_call(GaimPlugin *plugin,
- * Plugins subsystem
- **************************************************************************/
- void *
--gaim_plugins_get_handle(void) {
-+gaim2_plugins_get_handle(void) {
- static int handle;
-
- return &handle;
- }
-
- void
--gaim_plugins_init(void) {
-- void *handle = gaim_plugins_get_handle();
-+gaim2_plugins_init(void) {
-+ void *handle = gaim2_plugins_get_handle();
-
-- gaim_signal_register(handle, "plugin-load",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_signal_register(handle, "plugin-load",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_PLUGIN));
-- gaim_signal_register(handle, "plugin-unload",
-- gaim_marshal_VOID__POINTER,
-+ gaim2_signal_register(handle, "plugin-unload",
-+ gaim2_marshal_VOID__POINTER,
- NULL, 1,
-- gaim_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_new(GAIM_TYPE_SUBTYPE,
- GAIM_SUBTYPE_PLUGIN));
- }
-
- void
--gaim_plugins_uninit(void) {
-- gaim_signals_disconnect_by_handle(gaim_plugins_get_handle());
-+gaim2_plugins_uninit(void) {
-+ gaim2_signals_disconnect_by_handle(gaim2_plugins_get_handle());
- }
-
- /**************************************************************************
- * Plugins API
- **************************************************************************/
- void
--gaim_plugins_add_search_path(const char *path)
-+gaim2_plugins_add_search_path(const char *path)
- {
- g_return_if_fail(path != NULL);
-
-@@ -1103,42 +1103,42 @@ gaim_plugins_add_search_path(const char
- }
-
- void
--gaim_plugins_unload_all(void)
-+gaim2_plugins_unload_all(void)
- {
- #ifdef GAIM_PLUGINS
-
- while (loaded_plugins != NULL)
-- gaim_plugin_unload(loaded_plugins->data);
-+ gaim2_plugin_unload(loaded_plugins->data);
-
- #endif /* GAIM_PLUGINS */
- }
-
- void
--gaim_plugins_destroy_all(void)
-+gaim2_plugins_destroy_all(void)
- {
- #ifdef GAIM_PLUGINS
-
- while (plugins != NULL)
-- gaim_plugin_destroy(plugins->data);
-+ gaim2_plugin_destroy(plugins->data);
-
- #endif /* GAIM_PLUGINS */
- }
-
- void
--gaim_plugins_load_saved(const char *key)
-+gaim2_plugins_load_saved(const char *key)
- {
- #ifdef GAIM_PLUGINS
- GList *f, *files;
-
- g_return_if_fail(key != NULL);
-
-- files = gaim_prefs_get_string_list(key);
-+ files = gaim2_prefs_get_string_list(key);
-
- for (f = files; f; f = f->next)
- {
- char *filename;
- char *basename;
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
-
- if (f->data == NULL)
- continue;
-@@ -1156,21 +1156,21 @@ gaim_plugins_load_saved(const char *key)
- if (basename != NULL)
- basename++;
-
-- if ((plugin = gaim_plugins_find_with_filename(filename)) != NULL)
-+ if ((plugin = gaim2_plugins_find_with_filename(filename)) != NULL)
- {
-- gaim_debug_info("plugins", "Loading saved plugin %s\n",
-+ gaim2_debug_info("plugins", "Loading saved plugin %s\n",
- plugin->path);
-- gaim_plugin_load(plugin);
-+ gaim2_plugin_load(plugin);
- }
-- else if ((plugin = gaim_plugins_find_with_basename(basename)) != NULL)
-+ else if ((plugin = gaim2_plugins_find_with_basename(basename)) != NULL)
- {
-- gaim_debug_info("plugins", "Loading saved plugin %s\n",
-+ gaim2_debug_info("plugins", "Loading saved plugin %s\n",
- plugin->path);
-- gaim_plugin_load(plugin);
-+ gaim2_plugin_load(plugin);
- }
- else
- {
-- gaim_debug_error("plugins", "Unable to find saved plugin %s\n",
-+ gaim2_debug_error("plugins", "Unable to find saved plugin %s\n",
- filename);
- }
-
-@@ -1183,13 +1183,13 @@ gaim_plugins_load_saved(const char *key)
-
-
- void
--gaim_plugins_probe(const char *ext)
-+gaim2_plugins_probe(const char *ext)
- {
- #ifdef GAIM_PLUGINS
- GDir *dir;
- const gchar *file;
- gchar *path;
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GList *cur;
- const char *search_path;
-
-@@ -1210,7 +1210,7 @@ gaim_plugins_probe(const char *ext)
- path = g_build_filename(search_path, file, NULL);
-
- if (ext == NULL || has_file_extension(file, ext))
-- plugin = gaim_plugin_probe(path);
-+ plugin = gaim2_plugin_probe(path);
-
- g_free(path);
- }
-@@ -1222,7 +1222,7 @@ gaim_plugins_probe(const char *ext)
- /* See if we have any plugins waiting to load */
- while (load_queue != NULL)
- {
-- plugin = (GaimPlugin *)load_queue->data;
-+ plugin = (Gaim2Plugin *)load_queue->data;
-
- load_queue = g_list_remove(load_queue, plugin);
-
-@@ -1232,9 +1232,9 @@ gaim_plugins_probe(const char *ext)
- if (plugin->info->type == GAIM_PLUGIN_LOADER)
- {
- /* We'll just load this right now. */
-- if (!gaim_plugin_load(plugin))
-+ if (!gaim2_plugin_load(plugin))
- {
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
-
- continue;
- }
-@@ -1245,24 +1245,24 @@ gaim_plugins_probe(const char *ext)
- cur != NULL;
- cur = cur->next)
- {
-- gaim_plugins_probe(cur->data);
-+ gaim2_plugins_probe(cur->data);
- }
- }
- else if (plugin->info->type == GAIM_PLUGIN_PROTOCOL)
- {
- /* We'll just load this right now. */
-- if (!gaim_plugin_load(plugin))
-+ if (!gaim2_plugin_load(plugin))
- {
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
-
- continue;
- }
-
- /* Make sure we don't load two PRPLs with the same name? */
-- if (gaim_find_prpl(plugin->info->id))
-+ if (gaim2_find_prpl(plugin->info->id))
- {
- /* Nothing to see here--move along, move along */
-- gaim_plugin_destroy(plugin);
-+ gaim2_plugin_destroy(plugin);
-
- continue;
- }
-@@ -1278,7 +1278,7 @@ gaim_plugins_probe(const char *ext)
- }
-
- gboolean
--gaim_plugin_register(GaimPlugin *plugin)
-+gaim2_plugin_register(Gaim2Plugin *plugin)
- {
- g_return_val_if_fail(plugin != NULL, FALSE);
-
-@@ -1289,26 +1289,26 @@ gaim_plugin_register(GaimPlugin *plugin)
- /* Ensure the plugin has the requisite information */
- if (plugin->info->type == GAIM_PLUGIN_LOADER)
- {
-- GaimPluginLoaderInfo *loader_info;
-+ Gaim2PluginLoaderInfo *loader_info;
-
- loader_info = GAIM_PLUGIN_LOADER_INFO(plugin);
-
- if (loader_info == NULL)
- {
-- gaim_debug_error("plugins", "%s is unloadable\n",
-+ gaim2_debug_error("plugins", "%s is unloadable\n",
- plugin->path);
- return FALSE;
- }
- }
- else if (plugin->info->type == GAIM_PLUGIN_PROTOCOL)
- {
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(plugin);
-
- if (prpl_info == NULL)
- {
-- gaim_debug_error("plugins", "%s is unloadable\n",
-+ gaim2_debug_error("plugins", "%s is unloadable\n",
- plugin->path);
- return FALSE;
- }
-@@ -1335,7 +1335,7 @@ gaim_plugin_register(GaimPlugin *plugin)
- }
-
- gboolean
--gaim_plugins_enabled(void)
-+gaim2_plugins_enabled(void)
- {
- #ifdef GAIM_PLUGINS
- return TRUE;
-@@ -1345,7 +1345,7 @@ gaim_plugins_enabled(void)
- }
-
- void
--gaim_plugins_register_probe_notify_cb(void (*func)(void *), void *data)
-+gaim2_plugins_register_probe_notify_cb(void (*func)(void *), void *data)
- {
- /* TODO */
- probe_cb = func;
-@@ -1353,7 +1353,7 @@ gaim_plugins_register_probe_notify_cb(vo
- }
-
- void
--gaim_plugins_unregister_probe_notify_cb(void (*func)(void *))
-+gaim2_plugins_unregister_probe_notify_cb(void (*func)(void *))
- {
- /* TODO */
- probe_cb = NULL;
-@@ -1361,7 +1361,7 @@ gaim_plugins_unregister_probe_notify_cb(
- }
-
- void
--gaim_plugins_register_load_notify_cb(void (*func)(GaimPlugin *, void *),
-+gaim2_plugins_register_load_notify_cb(void (*func)(Gaim2Plugin *, void *),
- void *data)
- {
- /* TODO */
-@@ -1370,7 +1370,7 @@ gaim_plugins_register_load_notify_cb(voi
- }
-
- void
--gaim_plugins_unregister_load_notify_cb(void (*func)(GaimPlugin *, void *))
-+gaim2_plugins_unregister_load_notify_cb(void (*func)(Gaim2Plugin *, void *))
- {
- /* TODO */
- load_cb = NULL;
-@@ -1378,7 +1378,7 @@ gaim_plugins_unregister_load_notify_cb(v
- }
-
- void
--gaim_plugins_register_unload_notify_cb(void (*func)(GaimPlugin *, void *),
-+gaim2_plugins_register_unload_notify_cb(void (*func)(Gaim2Plugin *, void *),
- void *data)
- {
- /* TODO */
-@@ -1387,17 +1387,17 @@ gaim_plugins_register_unload_notify_cb(v
- }
-
- void
--gaim_plugins_unregister_unload_notify_cb(void (*func)(GaimPlugin *, void *))
-+gaim2_plugins_unregister_unload_notify_cb(void (*func)(Gaim2Plugin *, void *))
- {
- /* TODO */
- unload_cb = NULL;
- unload_cb_data = NULL;
- }
-
--GaimPlugin *
--gaim_plugins_find_with_name(const char *name)
-+Gaim2Plugin *
-+gaim2_plugins_find_with_name(const char *name)
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GList *l;
-
- for (l = plugins; l != NULL; l = l->next) {
-@@ -1410,10 +1410,10 @@ gaim_plugins_find_with_name(const char *
- return NULL;
- }
-
--GaimPlugin *
--gaim_plugins_find_with_filename(const char *filename)
-+Gaim2Plugin *
-+gaim2_plugins_find_with_filename(const char *filename)
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GList *l;
-
- for (l = plugins; l != NULL; l = l->next) {
-@@ -1426,25 +1426,25 @@ gaim_plugins_find_with_filename(const ch
- return NULL;
- }
-
--GaimPlugin *
--gaim_plugins_find_with_basename(const char *basename)
-+Gaim2Plugin *
-+gaim2_plugins_find_with_basename(const char *basename)
- {
- #ifdef GAIM_PLUGINS
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GList *l;
- char *basename_no_ext;
- char *tmp;
-
- g_return_val_if_fail(basename != NULL, NULL);
-
-- basename_no_ext = gaim_plugin_get_basename(basename);
-+ basename_no_ext = gaim2_plugin_get_basename(basename);
-
- for (l = plugins; l != NULL; l = l->next)
- {
-- plugin = (GaimPlugin *)l->data;
-+ plugin = (Gaim2Plugin *)l->data;
-
- if (plugin->path != NULL) {
-- tmp = gaim_plugin_get_basename(plugin->path);
-+ tmp = gaim2_plugin_get_basename(plugin->path);
- if (!strcmp(tmp, basename_no_ext))
- {
- g_free(tmp);
-@@ -1461,10 +1461,10 @@ gaim_plugins_find_with_basename(const ch
- return NULL;
- }
-
--GaimPlugin *
--gaim_plugins_find_with_id(const char *id)
-+Gaim2Plugin *
-+gaim2_plugins_find_with_id(const char *id)
- {
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
- GList *l;
-
- g_return_val_if_fail(id != NULL, NULL);
-@@ -1481,28 +1481,28 @@ gaim_plugins_find_with_id(const char *id
- }
-
- GList *
--gaim_plugins_get_loaded(void)
-+gaim2_plugins_get_loaded(void)
- {
- return loaded_plugins;
- }
-
- GList *
--gaim_plugins_get_protocols(void)
-+gaim2_plugins_get_protocols(void)
- {
- return protocol_plugins;
- }
-
- GList *
--gaim_plugins_get_all(void)
-+gaim2_plugins_get_all(void)
- {
- return plugins;
- }
-
-
--GaimPluginAction *
--gaim_plugin_action_new(char* label, void (*callback)(GaimPluginAction *))
-+Gaim2PluginAction *
-+gaim2_plugin_action_new(char* label, void (*callback)(Gaim2PluginAction *))
- {
-- GaimPluginAction *act = g_new0(GaimPluginAction, 1);
-+ Gaim2PluginAction *act = g_new0(Gaim2PluginAction, 1);
-
- act->label = label;
- act->callback = callback;
-diff -prNu ./src/plugin.h ./src/plugin.h
---- ./src/plugin.h 2006-01-03 13:03:02.000000000 +0100
-+++ ./src/plugin.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file plugin.h Plugin API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,14 +30,14 @@
- #include "signals.h"
- #include "value.h"
-
--typedef struct _GaimPlugin GaimPlugin;
--typedef struct _GaimPluginInfo GaimPluginInfo;
--typedef struct _GaimPluginUiInfo GaimPluginUiInfo;
--typedef struct _GaimPluginLoaderInfo GaimPluginLoaderInfo;
-+typedef struct _Gaim2Plugin Gaim2Plugin;
-+typedef struct _Gaim2PluginInfo Gaim2PluginInfo;
-+typedef struct _Gaim2PluginUiInfo Gaim2PluginUiInfo;
-+typedef struct _Gaim2PluginLoaderInfo Gaim2PluginLoaderInfo;
-
--typedef struct _GaimPluginAction GaimPluginAction;
-+typedef struct _Gaim2PluginAction Gaim2PluginAction;
-
--typedef int GaimPluginPriority; /**< Plugin priority. */
-+typedef int Gaim2PluginPriority; /**< Plugin priority. */
-
- #include "pluginpref.h"
-
-@@ -51,7 +51,7 @@ typedef enum
- GAIM_PLUGIN_LOADER, /**< Loader plugin. */
- GAIM_PLUGIN_PROTOCOL /**< Protocol plugin. */
-
--} GaimPluginType;
-+} Gaim2PluginType;
-
- #define GAIM_PRIORITY_DEFAULT 0
- #define GAIM_PRIORITY_HIGHEST 9999
-@@ -66,16 +66,16 @@ typedef enum
- *
- * This is used in the version 2.0 API and up.
- */
--struct _GaimPluginInfo
-+struct _Gaim2PluginInfo
- {
- unsigned int magic;
- unsigned int major_version;
- unsigned int minor_version;
-- GaimPluginType type;
-+ Gaim2PluginType type;
- char *ui_requirement;
- unsigned long flags;
- GList *dependencies;
-- GaimPluginPriority priority;
-+ Gaim2PluginPriority priority;
-
- char *id;
- char *name;
-@@ -89,39 +89,39 @@ struct _GaimPluginInfo
- * If a plugin defines a 'load' function, and it returns FALSE,
- * then the plugin will not be loaded.
- */
-- gboolean (*load)(GaimPlugin *plugin);
-- gboolean (*unload)(GaimPlugin *plugin);
-- void (*destroy)(GaimPlugin *plugin);
-+ gboolean (*load)(Gaim2Plugin *plugin);
-+ gboolean (*unload)(Gaim2Plugin *plugin);
-+ void (*destroy)(Gaim2Plugin *plugin);
-
- void *ui_info; /**< Used only by UI-specific plugins to build a preference screen with a custom UI */
- void *extra_info;
-- GaimPluginUiInfo *prefs_info; /**< Used by any plugin to display preferences. If #ui_info has been specified, this will be ignored. */
-- GList *(*actions)(GaimPlugin *plugin, gpointer context);
-+ Gaim2PluginUiInfo *prefs_info; /**< Used by any plugin to display preferences. If #ui_info has been specified, this will be ignored. */
-+ GList *(*actions)(Gaim2Plugin *plugin, gpointer context);
- };
-
- /**
- * Extra information for loader plugins.
- */
--struct _GaimPluginLoaderInfo
-+struct _Gaim2PluginLoaderInfo
- {
- GList *exts;
-
-- gboolean (*probe)(GaimPlugin *plugin);
-- gboolean (*load)(GaimPlugin *plugin);
-- gboolean (*unload)(GaimPlugin *plugin);
-- void (*destroy)(GaimPlugin *plugin);
-+ gboolean (*probe)(Gaim2Plugin *plugin);
-+ gboolean (*load)(Gaim2Plugin *plugin);
-+ gboolean (*unload)(Gaim2Plugin *plugin);
-+ void (*destroy)(Gaim2Plugin *plugin);
- };
-
- /**
- * A plugin handle.
- */
--struct _GaimPlugin
-+struct _Gaim2Plugin
- {
- gboolean native_plugin; /**< Native C plugin. */
- gboolean loaded; /**< The loaded state. */
- void *handle; /**< The module handle. */
- char *path; /**< The path to the plugin. */
-- GaimPluginInfo *info; /**< The plugin information. */
-+ Gaim2PluginInfo *info; /**< The plugin information. */
- char *error;
- void *ipc_data; /**< IPC data. */
- void *extra; /**< Plugin-specific data. */
-@@ -129,33 +129,33 @@ struct _GaimPlugin
- };
-
- #define GAIM_PLUGIN_LOADER_INFO(plugin) \
-- ((GaimPluginLoaderInfo *)(plugin)->info->extra_info)
-+ ((Gaim2PluginLoaderInfo *)(plugin)->info->extra_info)
-
--struct _GaimPluginUiInfo {
-- GaimPluginPrefFrame *(*get_plugin_pref_frame)(GaimPlugin *plugin);
-+struct _Gaim2PluginUiInfo {
-+ Gaim2PluginPrefFrame *(*get_plugin_pref_frame)(Gaim2Plugin *plugin);
-
- int page_num; /**< Reserved */
-- GaimPluginPrefFrame *frame; /**< Reserved */
-+ Gaim2PluginPrefFrame *frame; /**< Reserved */
- };
-
- #define GAIM_PLUGIN_HAS_PREF_FRAME(plugin) \
- ((plugin)->info != NULL && (plugin)->info->prefs_info != NULL)
-
- #define GAIM_PLUGIN_UI_INFO(plugin) \
-- ((GaimPluginUiInfo*)(plugin)->info->prefs_info)
-+ ((Gaim2PluginUiInfo*)(plugin)->info->prefs_info)
-
-
- /**
-- * The structure used in the actions member of GaimPluginInfo
-+ * The structure used in the actions member of Gaim2PluginInfo
- */
--struct _GaimPluginAction {
-+struct _Gaim2PluginAction {
- char *label;
-- void (*callback)(GaimPluginAction *);
-+ void (*callback)(Gaim2PluginAction *);
-
- /** set to the owning plugin */
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
-
-- /** NULL for plugin actions menu, set to the GaimConnection for
-+ /** NULL for plugin actions menu, set to the Gaim2Connection for
- account actions menu */
- gpointer context;
- };
-@@ -173,20 +173,20 @@ struct _GaimPluginAction {
- */
- #if !defined(GAIM_PLUGINS) || defined(GAIM_STATIC_PRPL)
- # define GAIM_INIT_PLUGIN(pluginname, initfunc, plugininfo) \
-- gboolean gaim_init_##pluginname##_plugin(void);\
-- gboolean gaim_init_##pluginname##_plugin(void) { \
-- GaimPlugin *plugin = gaim_plugin_new(TRUE, NULL); \
-+ gboolean gaim2_init_##pluginname##_plugin(void);\
-+ gboolean gaim2_init_##pluginname##_plugin(void) { \
-+ Gaim2Plugin *plugin = gaim2_plugin_new(TRUE, NULL); \
- plugin->info = &(plugininfo); \
- initfunc((plugin)); \
-- return gaim_plugin_register(plugin); \
-+ return gaim2_plugin_register(plugin); \
- }
- #else /* GAIM_PLUGINS && !GAIM_STATIC_PRPL */
- # define GAIM_INIT_PLUGIN(pluginname, initfunc, plugininfo) \
-- G_MODULE_EXPORT gboolean gaim_init_plugin(GaimPlugin *plugin); \
-- G_MODULE_EXPORT gboolean gaim_init_plugin(GaimPlugin *plugin) { \
-+ G_MODULE_EXPORT gboolean gaim2_init_plugin(Gaim2Plugin *plugin); \
-+ G_MODULE_EXPORT gboolean gaim2_init_plugin(Gaim2Plugin *plugin) { \
- plugin->info = &(plugininfo); \
- initfunc((plugin)); \
-- return gaim_plugin_register(plugin); \
-+ return gaim2_plugin_register(plugin); \
- }
- #endif
-
-@@ -206,9 +206,9 @@ extern "C" {
- * @param native Whether or not the plugin is native.
- * @param path The path to the plugin, or @c NULL if statically compiled.
- *
-- * @return A new GaimPlugin structure.
-+ * @return A new Gaim2Plugin structure.
- */
--GaimPlugin *gaim_plugin_new(gboolean native, const char *path);
-+Gaim2Plugin *gaim2_plugin_new(gboolean native, const char *path);
-
- /**
- * Probes a plugin, retrieving the information on it and adding it to the
-@@ -218,10 +218,10 @@ GaimPlugin *gaim_plugin_new(gboolean nat
- *
- * @return The plugin handle.
- *
-- * @see gaim_plugin_load()
-- * @see gaim_plugin_destroy()
-+ * @see gaim2_plugin_load()
-+ * @see gaim2_plugin_destroy()
- */
--GaimPlugin *gaim_plugin_probe(const char *filename);
-+Gaim2Plugin *gaim2_plugin_probe(const char *filename);
-
- /**
- * Registers a plugin and prepares it for loading.
-@@ -236,7 +236,7 @@ GaimPlugin *gaim_plugin_probe(const char
- * @c FALSE is returned (this happens if the plugin does not contain
- * the necessary information).
- */
--gboolean gaim_plugin_register(GaimPlugin *plugin);
-+gboolean gaim2_plugin_register(Gaim2Plugin *plugin);
-
- /**
- * Attempts to load a previously probed plugin.
-@@ -245,10 +245,10 @@ gboolean gaim_plugin_register(GaimPlugin
- *
- * @return @c TRUE if successful, or @c FALSE otherwise.
- *
-- * @see gaim_plugin_reload()
-- * @see gaim_plugin_unload()
-+ * @see gaim2_plugin_reload()
-+ * @see gaim2_plugin_unload()
- */
--gboolean gaim_plugin_load(GaimPlugin *plugin);
-+gboolean gaim2_plugin_load(Gaim2Plugin *plugin);
-
- /**
- * Unloads the specified plugin.
-@@ -257,10 +257,10 @@ gboolean gaim_plugin_load(GaimPlugin *pl
- *
- * @return @c TRUE if successful, or @c FALSE otherwise.
- *
-- * @see gaim_plugin_load()
-- * @see gaim_plugin_reload()
-+ * @see gaim2_plugin_load()
-+ * @see gaim2_plugin_reload()
- */
--gboolean gaim_plugin_unload(GaimPlugin *plugin);
-+gboolean gaim2_plugin_unload(Gaim2Plugin *plugin);
-
- /**
- * Reloads a plugin.
-@@ -269,17 +269,17 @@ gboolean gaim_plugin_unload(GaimPlugin *
- *
- * @return @c TRUE if successful, or @c FALSE otherwise.
- *
-- * @see gaim_plugin_load()
-- * @see gaim_plugin_unload()
-+ * @see gaim2_plugin_load()
-+ * @see gaim2_plugin_unload()
- */
--gboolean gaim_plugin_reload(GaimPlugin *plugin);
-+gboolean gaim2_plugin_reload(Gaim2Plugin *plugin);
-
- /**
- * Unloads a plugin and destroys the structure from memory.
- *
- * @param plugin The plugin handle.
- */
--void gaim_plugin_destroy(GaimPlugin *plugin);
-+void gaim2_plugin_destroy(Gaim2Plugin *plugin);
-
- /**
- * Returns whether or not a plugin is currently loaded.
-@@ -288,7 +288,7 @@ void gaim_plugin_destroy(GaimPlugin *plu
- *
- * @return @c TRUE if loaded, or @c FALSE otherwise.
- */
--gboolean gaim_plugin_is_loaded(const GaimPlugin *plugin);
-+gboolean gaim2_plugin_is_loaded(const Gaim2Plugin *plugin);
-
- /**
- * Returns whether or not a plugin is unloadable.
-@@ -302,7 +302,7 @@ gboolean gaim_plugin_is_loaded(const Gai
- * @return @c TRUE if the plugin is known to be unloadable,\
- * @c FALSE otherwise
- */
--gboolean gaim_plugin_is_unloadable(const GaimPlugin *plugin);
-+gboolean gaim2_plugin_is_unloadable(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's id.
-@@ -311,7 +311,7 @@ gboolean gaim_plugin_is_unloadable(const
- *
- * @return The plugin's id.
- */
--const gchar *gaim_plugin_get_id(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_id(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's name.
-@@ -320,7 +320,7 @@ const gchar *gaim_plugin_get_id(const Ga
- *
- * @return THe name of the plugin, or @c NULL.
- */
--const gchar *gaim_plugin_get_name(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_name(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's version.
-@@ -329,7 +329,7 @@ const gchar *gaim_plugin_get_name(const
- *
- * @return The plugin's version or @c NULL.
- */
--const gchar *gaim_plugin_get_version(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_version(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's summary.
-@@ -338,7 +338,7 @@ const gchar *gaim_plugin_get_version(con
- *
- * @return The plugin's summary.
- */
--const gchar *gaim_plugin_get_summary(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_summary(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's description.
-@@ -347,7 +347,7 @@ const gchar *gaim_plugin_get_summary(con
- *
- * @return The plugin's description.
- */
--const gchar *gaim_plugin_get_description(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_description(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's author.
-@@ -356,7 +356,7 @@ const gchar *gaim_plugin_get_description
- *
- * @return The plugin's author.
- */
--const gchar *gaim_plugin_get_author(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_author(const Gaim2Plugin *plugin);
-
- /**
- * Returns a plugin's homepage.
-@@ -365,7 +365,7 @@ const gchar *gaim_plugin_get_author(cons
- *
- * @return The plugin's homepage.
- */
--const gchar *gaim_plugin_get_homepage(const GaimPlugin *plugin);
-+const gchar *gaim2_plugin_get_homepage(const Gaim2Plugin *plugin);
-
- /*@}*/
-
-@@ -388,10 +388,10 @@ const gchar *gaim_plugin_get_homepage(co
- * @return TRUE if the function was registered successfully, or
- * FALSE otherwise.
- */
--gboolean gaim_plugin_ipc_register(GaimPlugin *plugin, const char *command,
-- GaimCallback func,
-- GaimSignalMarshalFunc marshal,
-- GaimValue *ret_value, int num_params, ...);
-+gboolean gaim2_plugin_ipc_register(Gaim2Plugin *plugin, const char *command,
-+ Gaim2Callback func,
-+ Gaim2SignalMarshalFunc marshal,
-+ Gaim2Value *ret_value, int num_params, ...);
-
- /**
- * Unregisters an IPC command in a plugin.
-@@ -399,14 +399,14 @@ gboolean gaim_plugin_ipc_register(GaimPl
- * @param plugin The plugin to unregister the command from.
- * @param command The name of the command.
- */
--void gaim_plugin_ipc_unregister(GaimPlugin *plugin, const char *command);
-+void gaim2_plugin_ipc_unregister(Gaim2Plugin *plugin, const char *command);
-
- /**
- * Unregisters all IPC commands in a plugin.
- *
- * @param plugin The plugin to unregister the commands from.
- */
--void gaim_plugin_ipc_unregister_all(GaimPlugin *plugin);
-+void gaim2_plugin_ipc_unregister_all(Gaim2Plugin *plugin);
-
- /**
- * Returns a list of value types used for an IPC command.
-@@ -419,9 +419,9 @@ void gaim_plugin_ipc_unregister_all(Gaim
- *
- * @return TRUE if the command was found, or FALSE otherwise.
- */
--gboolean gaim_plugin_ipc_get_params(GaimPlugin *plugin, const char *command,
-- GaimValue **ret_value, int *num_params,
-- GaimValue ***params);
-+gboolean gaim2_plugin_ipc_get_params(Gaim2Plugin *plugin, const char *command,
-+ Gaim2Value **ret_value, int *num_params,
-+ Gaim2Value ***params);
-
- /**
- * Executes an IPC command.
-@@ -434,7 +434,7 @@ gboolean gaim_plugin_ipc_get_params(Gaim
- * @return The return value, which will be NULL if the command doesn't
- * return a value.
- */
--void *gaim_plugin_ipc_call(GaimPlugin *plugin, const char *command,
-+void *gaim2_plugin_ipc_call(Gaim2Plugin *plugin, const char *command,
- gboolean *ok, ...);
-
- /*@}*/
-@@ -449,41 +449,41 @@ void *gaim_plugin_ipc_call(GaimPlugin *p
- *
- * @param path The new search path.
- */
--void gaim_plugins_add_search_path(const char *path);
-+void gaim2_plugins_add_search_path(const char *path);
-
- /**
- * Unloads all loaded plugins.
- */
--void gaim_plugins_unload_all(void);
-+void gaim2_plugins_unload_all(void);
-
- /**
- * Destroys all registered plugins.
- */
--void gaim_plugins_destroy_all(void);
-+void gaim2_plugins_destroy_all(void);
-
- /**
- * Attempts to load all the plugins in the specified preference key
-- * that were loaded when gaim last quit.
-+ * that were loaded when gaim2 last quit.
- *
- * @param key The preference key containing the list of plugins.
- */
--void gaim_plugins_load_saved(const char *key);
-+void gaim2_plugins_load_saved(const char *key);
-
- /**
- * Probes for plugins in the registered module paths.
- *
- * @param ext The extension type to probe for, or @c NULL for all.
- *
-- * @see gaim_plugin_set_probe_path()
-+ * @see gaim2_plugin_set_probe_path()
- */
--void gaim_plugins_probe(const char *ext);
-+void gaim2_plugins_probe(const char *ext);
-
- /**
- * Returns whether or not plugin support is enabled.
- *
- * @return TRUE if plugin support is enabled, or FALSE otherwise.
- */
--gboolean gaim_plugins_enabled(void);
-+gboolean gaim2_plugins_enabled(void);
-
- /**
- * Registers a function that will be called when probing is finished.
-@@ -491,14 +491,14 @@ gboolean gaim_plugins_enabled(void);
- * @param func The callback function.
- * @param data Data to pass to the callback.
- */
--void gaim_plugins_register_probe_notify_cb(void (*func)(void *), void *data);
-+void gaim2_plugins_register_probe_notify_cb(void (*func)(void *), void *data);
-
- /**
- * Unregisters a function that would be called when probing is finished.
- *
- * @param func The callback function.
- */
--void gaim_plugins_unregister_probe_notify_cb(void (*func)(void *));
-+void gaim2_plugins_unregister_probe_notify_cb(void (*func)(void *));
-
- /**
- * Registers a function that will be called when a plugin is loaded.
-@@ -506,7 +506,7 @@ void gaim_plugins_unregister_probe_notif
- * @param func The callback function.
- * @param data Data to pass to the callback.
- */
--void gaim_plugins_register_load_notify_cb(void (*func)(GaimPlugin *, void *),
-+void gaim2_plugins_register_load_notify_cb(void (*func)(Gaim2Plugin *, void *),
- void *data);
-
- /**
-@@ -514,7 +514,7 @@ void gaim_plugins_register_load_notify_c
- *
- * @param func The callback function.
- */
--void gaim_plugins_unregister_load_notify_cb(void (*func)(GaimPlugin *, void *));
-+void gaim2_plugins_unregister_load_notify_cb(void (*func)(Gaim2Plugin *, void *));
-
- /**
- * Registers a function that will be called when a plugin is unloaded.
-@@ -522,7 +522,7 @@ void gaim_plugins_unregister_load_notify
- * @param func The callback function.
- * @param data Data to pass to the callback.
- */
--void gaim_plugins_register_unload_notify_cb(void (*func)(GaimPlugin *, void *),
-+void gaim2_plugins_register_unload_notify_cb(void (*func)(Gaim2Plugin *, void *),
- void *data);
-
- /**
-@@ -530,7 +530,7 @@ void gaim_plugins_register_unload_notify
- *
- * @param func The callback function.
- */
--void gaim_plugins_unregister_unload_notify_cb(void (*func)(GaimPlugin *,
-+void gaim2_plugins_unregister_unload_notify_cb(void (*func)(Gaim2Plugin *,
- void *));
-
- /**
-@@ -540,7 +540,7 @@ void gaim_plugins_unregister_unload_noti
- *
- * @return The plugin if found, or @c NULL if not found.
- */
--GaimPlugin *gaim_plugins_find_with_name(const char *name);
-+Gaim2Plugin *gaim2_plugins_find_with_name(const char *name);
-
- /**
- * Finds a plugin with the specified filename (filename with a path).
-@@ -549,7 +549,7 @@ GaimPlugin *gaim_plugins_find_with_name(
- *
- * @return The plugin if found, or @c NULL if not found.
- */
--GaimPlugin *gaim_plugins_find_with_filename(const char *filename);
-+Gaim2Plugin *gaim2_plugins_find_with_filename(const char *filename);
-
- /**
- * Finds a plugin with the specified basename (filename without a path).
-@@ -558,7 +558,7 @@ GaimPlugin *gaim_plugins_find_with_filen
- *
- * @return The plugin if found, or @c NULL if not found.
- */
--GaimPlugin *gaim_plugins_find_with_basename(const char *basename);
-+Gaim2Plugin *gaim2_plugins_find_with_basename(const char *basename);
-
- /**
- * Finds a plugin with the specified plugin ID.
-@@ -567,14 +567,14 @@ GaimPlugin *gaim_plugins_find_with_basen
- *
- * @return The plugin if found, or @c NULL if not found.
- */
--GaimPlugin *gaim_plugins_find_with_id(const char *id);
-+Gaim2Plugin *gaim2_plugins_find_with_id(const char *id);
-
- /**
- * Returns a list of all loaded plugins.
- *
- * @return A list of all loaded plugins.
- */
--GList *gaim_plugins_get_loaded(void);
-+GList *gaim2_plugins_get_loaded(void);
-
- /**
- * Returns a list of all valid protocol plugins. A protocol
-@@ -584,14 +584,14 @@ GList *gaim_plugins_get_loaded(void);
- *
- * @return A list of all protocol plugins.
- */
--GList *gaim_plugins_get_protocols(void);
-+GList *gaim2_plugins_get_protocols(void);
-
- /**
- * Returns a list of all plugins, whether loaded or not.
- *
- * @return A list of all plugins.
- */
--GList *gaim_plugins_get_all(void);
-+GList *gaim2_plugins_get_all(void);
-
- /*@}*/
-
-@@ -605,24 +605,24 @@ GList *gaim_plugins_get_all(void);
- *
- * @return The plugin sybsystem handle.
- */
--void *gaim_plugins_get_handle(void);
-+void *gaim2_plugins_get_handle(void);
-
- /**
- * Initializes the plugin subsystem
- */
--void gaim_plugins_init(void);
-+void gaim2_plugins_init(void);
-
- /**
- * Uninitializes the plugin subsystem
- */
--void gaim_plugins_uninit(void);
-+void gaim2_plugins_uninit(void);
-
- /*@}*/
-
- /**
-- * Allocates and returns a new GaimPluginAction.
-+ * Allocates and returns a new Gaim2PluginAction.
- */
--GaimPluginAction *gaim_plugin_action_new(char* label, void (*callback)(GaimPluginAction *));
-+Gaim2PluginAction *gaim2_plugin_action_new(char* label, void (*callback)(Gaim2PluginAction *));
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/pluginpref.c ./src/pluginpref.c
---- ./src/pluginpref.c 2006-01-04 05:14:02.000000000 +0100
-+++ ./src/pluginpref.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,43 +30,43 @@
- #include "pluginpref.h"
- #include "prefs.h"
-
--struct _GaimPluginPrefFrame {
-+struct _Gaim2PluginPrefFrame {
- GList *prefs;
- };
-
--struct _GaimPluginPref {
-+struct _Gaim2PluginPref {
- char *name;
- char *label;
-
-- GaimPluginPrefType type;
-+ Gaim2PluginPrefType type;
-
- int min;
- int max;
- GList *choices;
- unsigned int max_length;
- gboolean masked;
-- GaimStringFormatType format;
-+ Gaim2StringFormatType format;
- };
-
--GaimPluginPrefFrame *
--gaim_plugin_pref_frame_new() {
-- GaimPluginPrefFrame *frame;
-+Gaim2PluginPrefFrame *
-+gaim2_plugin_pref_frame_new() {
-+ Gaim2PluginPrefFrame *frame;
-
-- frame = g_new0(GaimPluginPrefFrame, 1);
-+ frame = g_new0(Gaim2PluginPrefFrame, 1);
-
- return frame;
- }
-
- void
--gaim_plugin_pref_frame_destroy(GaimPluginPrefFrame *frame) {
-- GaimPluginPref *pref;
-+gaim2_plugin_pref_frame_destroy(Gaim2PluginPrefFrame *frame) {
-+ Gaim2PluginPref *pref;
- GList *l;
-
- g_return_if_fail(frame);
-
- for(l = frame->prefs; l != NULL; l = l->next) {
-- pref = (GaimPluginPref *)l->data;
-- gaim_plugin_pref_destroy(pref);
-+ pref = (Gaim2PluginPref *)l->data;
-+ gaim2_plugin_pref_destroy(pref);
- }
-
- g_list_free(frame->prefs);
-@@ -77,7 +77,7 @@ gaim_plugin_pref_frame_destroy(GaimPlugi
- }
-
- void
--gaim_plugin_pref_frame_add(GaimPluginPrefFrame *frame, GaimPluginPref *pref) {
-+gaim2_plugin_pref_frame_add(Gaim2PluginPrefFrame *frame, Gaim2PluginPref *pref) {
- g_return_if_fail(frame);
- g_return_if_fail(pref);
-
-@@ -85,54 +85,54 @@ gaim_plugin_pref_frame_add(GaimPluginPre
- }
-
- GList *
--gaim_plugin_pref_frame_get_prefs(GaimPluginPrefFrame *frame) {
-+gaim2_plugin_pref_frame_get_prefs(Gaim2PluginPrefFrame *frame) {
- g_return_val_if_fail(frame, NULL);
- g_return_val_if_fail(frame->prefs, NULL);
-
- return frame->prefs;
- }
-
--GaimPluginPref *
--gaim_plugin_pref_new() {
-- GaimPluginPref *pref;
-+Gaim2PluginPref *
-+gaim2_plugin_pref_new() {
-+ Gaim2PluginPref *pref;
-
-- pref = g_new0(GaimPluginPref, 1);
-+ pref = g_new0(Gaim2PluginPref, 1);
-
- return pref;
- }
-
--GaimPluginPref *
--gaim_plugin_pref_new_with_name(char *name) {
-- GaimPluginPref *pref;
-+Gaim2PluginPref *
-+gaim2_plugin_pref_new_with_name(char *name) {
-+ Gaim2PluginPref *pref;
-
- g_return_val_if_fail(name, NULL);
-
-- pref = g_new0(GaimPluginPref, 1);
-+ pref = g_new0(Gaim2PluginPref, 1);
- pref->name = g_strdup(name);
-
- return pref;
- }
-
--GaimPluginPref *
--gaim_plugin_pref_new_with_label(char *label) {
-- GaimPluginPref *pref;
-+Gaim2PluginPref *
-+gaim2_plugin_pref_new_with_label(char *label) {
-+ Gaim2PluginPref *pref;
-
- g_return_val_if_fail(label, NULL);
-
-- pref = g_new0(GaimPluginPref, 1);
-+ pref = g_new0(Gaim2PluginPref, 1);
- pref->label = g_strdup(label);
-
- return pref;
- }
-
--GaimPluginPref *
--gaim_plugin_pref_new_with_name_and_label(char *name, char *label) {
-- GaimPluginPref *pref;
-+Gaim2PluginPref *
-+gaim2_plugin_pref_new_with_name_and_label(char *name, char *label) {
-+ Gaim2PluginPref *pref;
-
- g_return_val_if_fail(name, NULL);
- g_return_val_if_fail(label, NULL);
-
-- pref = g_new0(GaimPluginPref, 1);
-+ pref = g_new0(Gaim2PluginPref, 1);
- pref->name = g_strdup(name);
- pref->label = g_strdup(label);
-
-@@ -140,7 +140,7 @@ gaim_plugin_pref_new_with_name_and_label
- }
-
- void
--gaim_plugin_pref_destroy(GaimPluginPref *pref) {
-+gaim2_plugin_pref_destroy(Gaim2PluginPref *pref) {
- g_return_if_fail(pref);
-
- if(pref->name) {
-@@ -162,7 +162,7 @@ gaim_plugin_pref_destroy(GaimPluginPref
- }
-
- void
--gaim_plugin_pref_set_name(GaimPluginPref *pref, char *name) {
-+gaim2_plugin_pref_set_name(Gaim2PluginPref *pref, char *name) {
- g_return_if_fail(pref);
- g_return_if_fail(name);
-
-@@ -173,14 +173,14 @@ gaim_plugin_pref_set_name(GaimPluginPref
- }
-
- char *
--gaim_plugin_pref_get_name(GaimPluginPref *pref) {
-+gaim2_plugin_pref_get_name(Gaim2PluginPref *pref) {
- g_return_val_if_fail(pref, NULL);
-
- return pref->name;
- }
-
- void
--gaim_plugin_pref_set_label(GaimPluginPref *pref, char *label) {
-+gaim2_plugin_pref_set_label(Gaim2PluginPref *pref, char *label) {
- g_return_if_fail(pref);
- g_return_if_fail(label);
-
-@@ -191,22 +191,22 @@ gaim_plugin_pref_set_label(GaimPluginPre
- }
-
- char *
--gaim_plugin_pref_get_label(GaimPluginPref *pref) {
-+gaim2_plugin_pref_get_label(Gaim2PluginPref *pref) {
- g_return_val_if_fail(pref, NULL);
-
- return pref->label;
- }
-
- void
--gaim_plugin_pref_set_bounds(GaimPluginPref *pref, int min, int max) {
-+gaim2_plugin_pref_set_bounds(Gaim2PluginPref *pref, int min, int max) {
- int tmp;
-
- g_return_if_fail(pref);
- g_return_if_fail(pref->name);
-
-- if(gaim_prefs_get_type(pref->name) != GAIM_PREF_INT) {
-- gaim_debug(GAIM_DEBUG_INFO, "pluginpref",
-- "gaim_plugin_pref_set_bounds: %s is not an integer pref\n",
-+ if(gaim2_prefs_get_type(pref->name) != GAIM_PREF_INT) {
-+ gaim2_debug(GAIM_DEBUG_INFO, "pluginpref",
-+ "gaim2_plugin_pref_set_bounds: %s is not an integer pref\n",
- pref->name);
- return;
- }
-@@ -221,13 +221,13 @@ gaim_plugin_pref_set_bounds(GaimPluginPr
- pref->max = max;
- }
-
--void gaim_plugin_pref_get_bounds(GaimPluginPref *pref, int *min, int *max) {
-+void gaim2_plugin_pref_get_bounds(Gaim2PluginPref *pref, int *min, int *max) {
- g_return_if_fail(pref);
- g_return_if_fail(pref->name);
-
-- if(gaim_prefs_get_type(pref->name) != GAIM_PREF_INT) {
-- gaim_debug(GAIM_DEBUG_INFO, "pluginpref",
-- "gaim_plugin_pref_get_bounds: %s is not an integer pref\n",
-+ if(gaim2_prefs_get_type(pref->name) != GAIM_PREF_INT) {
-+ gaim2_debug(GAIM_DEBUG_INFO, "pluginpref",
-+ "gaim2_plugin_pref_get_bounds: %s is not an integer pref\n",
- pref->name);
- return;
- }
-@@ -237,21 +237,21 @@ void gaim_plugin_pref_get_bounds(GaimPlu
- }
-
- void
--gaim_plugin_pref_set_type(GaimPluginPref *pref, GaimPluginPrefType type) {
-+gaim2_plugin_pref_set_type(Gaim2PluginPref *pref, Gaim2PluginPrefType type) {
- g_return_if_fail(pref);
-
- pref->type = type;
- }
-
--GaimPluginPrefType
--gaim_plugin_pref_get_type(GaimPluginPref *pref) {
-+Gaim2PluginPrefType
-+gaim2_plugin_pref_get_type(Gaim2PluginPref *pref) {
- g_return_val_if_fail(pref, GAIM_PLUGIN_PREF_NONE);
-
- return pref->type;
- }
-
- void
--gaim_plugin_pref_add_choice(GaimPluginPref *pref, char *label, gpointer choice) {
-+gaim2_plugin_pref_add_choice(Gaim2PluginPref *pref, char *label, gpointer choice) {
- g_return_if_fail(pref);
- g_return_if_fail(label);
- g_return_if_fail(choice);
-@@ -261,42 +261,42 @@ gaim_plugin_pref_add_choice(GaimPluginPr
- }
-
- GList *
--gaim_plugin_pref_get_choices(GaimPluginPref *pref) {
-+gaim2_plugin_pref_get_choices(Gaim2PluginPref *pref) {
- g_return_val_if_fail(pref, NULL);
-
- return pref->choices;
- }
-
- void
--gaim_plugin_pref_set_max_length(GaimPluginPref *pref, unsigned int max_length) {
-+gaim2_plugin_pref_set_max_length(Gaim2PluginPref *pref, unsigned int max_length) {
- g_return_if_fail(pref);
-
- pref->max_length = max_length;
- }
-
- unsigned int
--gaim_plugin_pref_get_max_length(GaimPluginPref *pref) {
-+gaim2_plugin_pref_get_max_length(Gaim2PluginPref *pref) {
- g_return_val_if_fail(pref, 0);
-
- return pref->max_length;
- }
-
- void
--gaim_plugin_pref_set_masked(GaimPluginPref *pref, gboolean masked) {
-+gaim2_plugin_pref_set_masked(Gaim2PluginPref *pref, gboolean masked) {
- g_return_if_fail(pref);
-
- pref->masked = masked;
- }
-
- gboolean
--gaim_plugin_pref_get_masked(GaimPluginPref *pref) {
-+gaim2_plugin_pref_get_masked(Gaim2PluginPref *pref) {
- g_return_val_if_fail(pref, FALSE);
-
- return pref->masked;
- }
-
- void
--gaim_plugin_pref_set_format_type(GaimPluginPref *pref, GaimStringFormatType format)
-+gaim2_plugin_pref_set_format_type(Gaim2PluginPref *pref, Gaim2StringFormatType format)
- {
- g_return_if_fail(pref);
- g_return_if_fail(pref->type == GAIM_PLUGIN_PREF_STRING_FORMAT);
-@@ -304,8 +304,8 @@ gaim_plugin_pref_set_format_type(GaimPlu
- pref->format = format;
- }
-
--GaimStringFormatType
--gaim_plugin_pref_get_format_type(GaimPluginPref *pref)
-+Gaim2StringFormatType
-+gaim2_plugin_pref_get_format_type(Gaim2PluginPref *pref)
- {
- g_return_val_if_fail(pref, 0);
-
-diff -prNu ./src/pluginpref.h ./src/pluginpref.h
---- ./src/pluginpref.h 2006-01-04 05:14:02.000000000 +0100
-+++ ./src/pluginpref.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file pluginpref.h Plugin Preferences API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,15 +26,15 @@
- #ifndef _GAIM_PLUGINPREF_H_
- #define _GAIM_PLUGINPREF_H_
-
--typedef struct _GaimPluginPrefFrame GaimPluginPrefFrame;
--typedef struct _GaimPluginPref GaimPluginPref;
-+typedef struct _Gaim2PluginPrefFrame Gaim2PluginPrefFrame;
-+typedef struct _Gaim2PluginPref Gaim2PluginPref;
-
- typedef enum {
- GAIM_PLUGIN_PREF_NONE,
- GAIM_PLUGIN_PREF_CHOICE,
- GAIM_PLUGIN_PREF_INFO, /**< no-value label */
- GAIM_PLUGIN_PREF_STRING_FORMAT
--} GaimPluginPrefType;
-+} Gaim2PluginPrefType;
-
- #include <glib.h>
- #include "prefs.h"
-@@ -51,16 +51,16 @@ extern "C" {
- /**
- * Create a new plugin preference frame
- *
-- * @return a new GaimPluginPrefFrame
-+ * @return a new Gaim2PluginPrefFrame
- */
--GaimPluginPrefFrame *gaim_plugin_pref_frame_new(void);
-+Gaim2PluginPrefFrame *gaim2_plugin_pref_frame_new(void);
-
- /**
- * Destroy a plugin preference frame
- *
- * @param frame The plugin frame to destroy
- */
--void gaim_plugin_pref_frame_destroy(GaimPluginPrefFrame *frame);
-+void gaim2_plugin_pref_frame_destroy(Gaim2PluginPrefFrame *frame);
-
- /**
- * Adds a plugin preference to a plugin preference frame
-@@ -68,7 +68,7 @@ void gaim_plugin_pref_frame_destroy(Gaim
- * @param frame The plugin frame to add the preference to
- * @param pref The preference to add to the frame
- */
--void gaim_plugin_pref_frame_add(GaimPluginPrefFrame *frame, GaimPluginPref *pref);
-+void gaim2_plugin_pref_frame_add(Gaim2PluginPrefFrame *frame, Gaim2PluginPref *pref);
-
- /**
- * Get the plugin preferences from a plugin preference frame
-@@ -76,46 +76,46 @@ void gaim_plugin_pref_frame_add(GaimPlug
- * @param frame The plugin frame to get the plugin preferences from
- * @return a GList of plugin preferences
- */
--GList *gaim_plugin_pref_frame_get_prefs(GaimPluginPrefFrame *frame);
-+GList *gaim2_plugin_pref_frame_get_prefs(Gaim2PluginPrefFrame *frame);
-
- /**
- * Create a new plugin preference
- *
-- * @return a new GaimPluginPref
-+ * @return a new Gaim2PluginPref
- */
--GaimPluginPref *gaim_plugin_pref_new(void);
-+Gaim2PluginPref *gaim2_plugin_pref_new(void);
-
- /**
- * Create a new plugin preference with name
- *
- * @param name The name of the pref
-- * @return a new GaimPluginPref
-+ * @return a new Gaim2PluginPref
- */
--GaimPluginPref *gaim_plugin_pref_new_with_name(char *name);
-+Gaim2PluginPref *gaim2_plugin_pref_new_with_name(char *name);
-
- /**
- * Create a new plugin preference with label
- *
- * @param label The label to be displayed
-- * @return a new GaimPluginPref
-+ * @return a new Gaim2PluginPref
- */
--GaimPluginPref *gaim_plugin_pref_new_with_label(char *label);
-+Gaim2PluginPref *gaim2_plugin_pref_new_with_label(char *label);
-
- /**
- * Create a new plugin preference with name and label
- *
- * @param name The name of the pref
- * @param label The label to be displayed
-- * @return a new GaimPluginPref
-+ * @return a new Gaim2PluginPref
- */
--GaimPluginPref *gaim_plugin_pref_new_with_name_and_label(char *name, char *label);
-+Gaim2PluginPref *gaim2_plugin_pref_new_with_name_and_label(char *name, char *label);
-
- /**
- * Destroy a plugin preference
- *
- * @param pref The preference to destroy
- */
--void gaim_plugin_pref_destroy(GaimPluginPref *pref);
-+void gaim2_plugin_pref_destroy(Gaim2PluginPref *pref);
-
- /**
- * Set a plugin pref name
-@@ -123,7 +123,7 @@ void gaim_plugin_pref_destroy(GaimPlugin
- * @param pref The plugin pref
- * @param name The name of the pref
- */
--void gaim_plugin_pref_set_name(GaimPluginPref *pref, char *name);
-+void gaim2_plugin_pref_set_name(Gaim2PluginPref *pref, char *name);
-
- /**
- * Get a plugin pref name
-@@ -131,7 +131,7 @@ void gaim_plugin_pref_set_name(GaimPlugi
- * @param pref The plugin pref
- * @return The name of the pref
- */
--char *gaim_plugin_pref_get_name(GaimPluginPref *pref);
-+char *gaim2_plugin_pref_get_name(Gaim2PluginPref *pref);
-
- /**
- * Set a plugin pref label
-@@ -139,7 +139,7 @@ char *gaim_plugin_pref_get_name(GaimPlug
- * @param pref The plugin pref
- * @param label The label for the plugin pref
- */
--void gaim_plugin_pref_set_label(GaimPluginPref *pref, char *label);
-+void gaim2_plugin_pref_set_label(Gaim2PluginPref *pref, char *label);
-
- /**
- * Get a plugin pref label
-@@ -147,7 +147,7 @@ void gaim_plugin_pref_set_label(GaimPlug
- * @param pref The plugin pref
- * @return The label for the plugin pref
- */
--char *gaim_plugin_pref_get_label(GaimPluginPref *pref);
-+char *gaim2_plugin_pref_get_label(Gaim2PluginPref *pref);
-
- /**
- * Set the bounds for an integer pref
-@@ -156,7 +156,7 @@ char *gaim_plugin_pref_get_label(GaimPlu
- * @param min The min value
- * @param max The max value
- */
--void gaim_plugin_pref_set_bounds(GaimPluginPref *pref, int min, int max);
-+void gaim2_plugin_pref_set_bounds(Gaim2PluginPref *pref, int min, int max);
-
- /**
- * Get the bounds for an integer pref
-@@ -165,7 +165,7 @@ void gaim_plugin_pref_set_bounds(GaimPlu
- * @param min The min value
- * @param max The max value
- */
--void gaim_plugin_pref_get_bounds(GaimPluginPref *pref, int *min, int *max);
-+void gaim2_plugin_pref_get_bounds(Gaim2PluginPref *pref, int *min, int *max);
-
- /**
- * Set the type of a plugin pref
-@@ -173,7 +173,7 @@ void gaim_plugin_pref_get_bounds(GaimPlu
- * @param pref The plugin pref
- * @param type The type
- */
--void gaim_plugin_pref_set_type(GaimPluginPref *pref, GaimPluginPrefType type);
-+void gaim2_plugin_pref_set_type(Gaim2PluginPref *pref, Gaim2PluginPrefType type);
-
- /**
- * Get the type of a plugin pref
-@@ -181,7 +181,7 @@ void gaim_plugin_pref_set_type(GaimPlugi
- * @param pref The plugin pref
- * @return The type
- */
--GaimPluginPrefType gaim_plugin_pref_get_type(GaimPluginPref *pref);
-+Gaim2PluginPrefType gaim2_plugin_pref_get_type(Gaim2PluginPref *pref);
-
- /**
- * Set the choices for a choices plugin pref
-@@ -190,7 +190,7 @@ GaimPluginPrefType gaim_plugin_pref_get_
- * @param label The label for the choice
- * @param choice A gpointer of the choice
- */
--void gaim_plugin_pref_add_choice(GaimPluginPref *pref, char *label, gpointer choice);
-+void gaim2_plugin_pref_add_choice(Gaim2PluginPref *pref, char *label, gpointer choice);
-
- /**
- * Get the choices for a choices plugin pref
-@@ -198,7 +198,7 @@ void gaim_plugin_pref_add_choice(GaimPlu
- * @param pref The plugin pref
- * @return GList of the choices
- */
--GList *gaim_plugin_pref_get_choices(GaimPluginPref *pref);
-+GList *gaim2_plugin_pref_get_choices(Gaim2PluginPref *pref);
-
- /**
- * Set the max length for a string plugin pref
-@@ -206,7 +206,7 @@ GList *gaim_plugin_pref_get_choices(Gaim
- * @param pref The plugin pref
- * @param max_length The max length of the string
- */
--void gaim_plugin_pref_set_max_length(GaimPluginPref *pref, unsigned int max_length);
-+void gaim2_plugin_pref_set_max_length(Gaim2PluginPref *pref, unsigned int max_length);
-
- /**
- * Get the max length for a string plugin pref
-@@ -214,7 +214,7 @@ void gaim_plugin_pref_set_max_length(Gai
- * @param pref The plugin pref
- * @return the max length
- */
--unsigned int gaim_plugin_pref_get_max_length(GaimPluginPref *pref);
-+unsigned int gaim2_plugin_pref_get_max_length(Gaim2PluginPref *pref);
-
- /**
- * Sets the masking of a string plugin pref
-@@ -222,7 +222,7 @@ unsigned int gaim_plugin_pref_get_max_le
- * @param pref The plugin pref
- * @param mask The value to set
- */
--void gaim_plugin_pref_set_masked(GaimPluginPref *pref, gboolean mask);
-+void gaim2_plugin_pref_set_masked(Gaim2PluginPref *pref, gboolean mask);
-
- /**
- * Gets the masking of a string plugin pref
-@@ -230,7 +230,7 @@ void gaim_plugin_pref_set_masked(GaimPlu
- * @param pref The plugin pref
- * @return The masking
- */
--gboolean gaim_plugin_pref_get_masked(GaimPluginPref *pref);
-+gboolean gaim2_plugin_pref_get_masked(Gaim2PluginPref *pref);
-
- /**
- * Sets the format type for a formattable-string plugin pref. You need to set the
-@@ -239,7 +239,7 @@ gboolean gaim_plugin_pref_get_masked(Gai
- * @param pref The plugin pref
- * @param format The format of the string
- */
--void gaim_plugin_pref_set_format_type(GaimPluginPref *pref, GaimStringFormatType format);
-+void gaim2_plugin_pref_set_format_type(Gaim2PluginPref *pref, Gaim2StringFormatType format);
-
- /**
- * Gets the format type of the formattable-string plugin pref.
-@@ -247,7 +247,7 @@ void gaim_plugin_pref_set_format_type(Ga
- * @param pref The plugin pref
- * @return The format of the pref
- */
--GaimStringFormatType gaim_plugin_pref_get_format_type(GaimPluginPref *pref);
-+Gaim2StringFormatType gaim2_plugin_pref_get_format_type(Gaim2PluginPref *pref);
-
- /*@}*/
-
-diff -prNu ./src/pounce.c ./src/pounce.c
---- ./src/pounce.c 2006-01-03 12:42:51.000000000 +0100
-+++ ./src/pounce.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file pounce.c Buddy Pounce API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,9 +35,9 @@ typedef struct
- {
- GString *buffer;
-
-- GaimPounce *pounce;
-- GaimPounceEvent events;
-- GaimPounceOption options;
-+ Gaim2Pounce *pounce;
-+ Gaim2PounceEvent events;
-+ Gaim2PounceOption options;
-
- char *ui_name;
- char *pouncee;
-@@ -58,16 +58,16 @@ typedef struct
-
- GHashTable *atts;
-
--} GaimPounceActionData;
-+} Gaim2PounceActionData;
-
- typedef struct
- {
- char *ui;
-- GaimPounceCb cb;
-- void (*new_pounce)(GaimPounce *);
-- void (*free_pounce)(GaimPounce *);
-+ Gaim2PounceCb cb;
-+ void (*new_pounce)(Gaim2Pounce *);
-+ void (*free_pounce)(Gaim2Pounce *);
-
--} GaimPounceHandler;
-+} Gaim2PounceHandler;
-
-
- static GHashTable *pounce_handlers = NULL;
-@@ -80,10 +80,10 @@ static gboolean pounces_loaded = FALS
- * Private utility functions *
- *********************************************************************/
-
--static GaimPounceActionData *
--find_action_data(const GaimPounce *pounce, const char *name)
-+static Gaim2PounceActionData *
-+find_action_data(const Gaim2Pounce *pounce, const char *name)
- {
-- GaimPounceActionData *action;
-+ Gaim2PounceActionData *action;
-
- g_return_val_if_fail(pounce != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
-@@ -96,7 +96,7 @@ find_action_data(const GaimPounce *pounc
- static void
- free_action_data(gpointer data)
- {
-- GaimPounceActionData *action_data = data;
-+ Gaim2PounceActionData *action_data = data;
-
- g_free(action_data->name);
-
-@@ -129,11 +129,11 @@ static void
- action_parameter_list_to_xmlnode(gpointer key, gpointer value, gpointer user_data)
- {
- const char *action;
-- GaimPounceActionData *action_data;
-+ Gaim2PounceActionData *action_data;
- xmlnode *node, *child;
-
- action = (const char *)key;
-- action_data = (GaimPounceActionData *)value;
-+ action_data = (Gaim2PounceActionData *)value;
- node = (xmlnode *)user_data;
-
- if (!action_data->enabled)
-@@ -164,26 +164,26 @@ add_option_to_xmlnode(xmlnode *node, con
- }
-
- static xmlnode *
--pounce_to_xmlnode(GaimPounce *pounce)
-+pounce_to_xmlnode(Gaim2Pounce *pounce)
- {
- xmlnode *node, *child;
-- GaimAccount *pouncer;
-- GaimPounceEvent events;
-- GaimPounceOption options;
--
-- pouncer = gaim_pounce_get_pouncer(pounce);
-- events = gaim_pounce_get_events(pounce);
-- options = gaim_pounce_get_options(pounce);
-+ Gaim2Account *pouncer;
-+ Gaim2PounceEvent events;
-+ Gaim2PounceOption options;
-+
-+ pouncer = gaim2_pounce_get_pouncer(pounce);
-+ events = gaim2_pounce_get_events(pounce);
-+ options = gaim2_pounce_get_options(pounce);
-
- node = xmlnode_new("pounce");
- xmlnode_set_attrib(node, "ui", pounce->ui_type);
-
- child = xmlnode_new_child(node, "account");
- xmlnode_set_attrib(child, "protocol", pouncer->protocol_id);
-- xmlnode_insert_data(child, gaim_account_get_username(pouncer), -1);
-+ xmlnode_insert_data(child, gaim2_account_get_username(pouncer), -1);
-
- child = xmlnode_new_child(node, "pouncee");
-- xmlnode_insert_data(child, gaim_pounce_get_pouncee(pounce), -1);
-+ xmlnode_insert_data(child, gaim2_pounce_get_pouncee(pounce), -1);
-
- /* Write pounce options */
- child = xmlnode_new_child(node, "options");
-@@ -215,7 +215,7 @@ pounce_to_xmlnode(GaimPounce *pounce)
- child = xmlnode_new_child(node, "actions");
- g_hash_table_foreach(pounce->actions, action_parameter_list_to_xmlnode, child);
-
-- if (gaim_pounce_get_save(pounce))
-+ if (gaim2_pounce_get_save(pounce))
- child = xmlnode_new_child(node, "save");
-
- return node;
-@@ -230,7 +230,7 @@ pounces_to_xmlnode(void)
- node = xmlnode_new("pounces");
- xmlnode_set_attrib(node, "version", "1.0");
-
-- for (cur = gaim_pounces_get_all(); cur != NULL; cur = cur->next)
-+ for (cur = gaim2_pounces_get_all(); cur != NULL; cur = cur->next)
- {
- child = pounce_to_xmlnode(cur->data);
- xmlnode_insert_child(node, child);
-@@ -247,14 +247,14 @@ sync_pounces(void)
-
- if (!pounces_loaded)
- {
-- gaim_debug_error("pounce", "Attempted to save buddy pounces before "
-+ gaim2_debug_error("pounce", "Attempted to save buddy pounces before "
- "they were read!\n");
- return;
- }
-
- node = pounces_to_xmlnode();
- data = xmlnode_to_formatted_str(node, NULL);
-- gaim_util_write_data_to_file("pounces.xml", data, -1);
-+ gaim2_util_write_data_to_file("pounces.xml", data, -1);
- g_free(data);
- xmlnode_free(node);
- }
-@@ -271,7 +271,7 @@ static void
- schedule_pounces_save(void)
- {
- if (save_timer == 0)
-- save_timer = gaim_timeout_add(5000, save_cb, NULL);
-+ save_timer = gaim2_timeout_add(5000, save_cb, NULL);
- }
-
-
-@@ -326,7 +326,7 @@ start_element_handler(GMarkupParseContex
- const char *ui = g_hash_table_lookup(atts, "ui");
-
- if (ui == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Unset 'ui' parameter for pounce!\n");
- }
- else
-@@ -338,7 +338,7 @@ start_element_handler(GMarkupParseContex
- const char *protocol_id = g_hash_table_lookup(atts, "protocol");
-
- if (protocol_id == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Unset 'protocol' parameter for account!\n");
- }
- else
-@@ -348,7 +348,7 @@ start_element_handler(GMarkupParseContex
- const char *type = g_hash_table_lookup(atts, "type");
-
- if (type == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Unset 'type' parameter for option!\n");
- }
- else
-@@ -358,7 +358,7 @@ start_element_handler(GMarkupParseContex
- const char *type = g_hash_table_lookup(atts, "type");
-
- if (type == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Unset 'type' parameter for event!\n");
- }
- else
-@@ -368,7 +368,7 @@ start_element_handler(GMarkupParseContex
- const char *type = g_hash_table_lookup(atts, "type");
-
- if (type == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Unset 'type' parameter for action!\n");
- }
- else
-@@ -378,7 +378,7 @@ start_element_handler(GMarkupParseContex
- const char *param_name = g_hash_table_lookup(atts, "name");
-
- if (param_name == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Unset 'name' parameter for param!\n");
- }
- else
-@@ -440,8 +440,8 @@ end_element_handler(GMarkupParseContext
- }
- else if (!strcmp(element_name, "action")) {
- if (data->pounce != NULL) {
-- gaim_pounce_action_register(data->pounce, data->action_name);
-- gaim_pounce_action_set_enabled(data->pounce, data->action_name, TRUE);
-+ gaim2_pounce_action_register(data->pounce, data->action_name);
-+ gaim2_pounce_action_set_enabled(data->pounce, data->action_name, TRUE);
- }
-
- g_free(data->action_name);
-@@ -449,7 +449,7 @@ end_element_handler(GMarkupParseContext
- }
- else if (!strcmp(element_name, "param")) {
- if (data->pounce != NULL) {
-- gaim_pounce_action_set_attribute(data->pounce, data->action_name,
-+ gaim2_pounce_action_set_attribute(data->pounce, data->action_name,
- data->param_name, buffer);
- }
-
-@@ -457,9 +457,9 @@ end_element_handler(GMarkupParseContext
- data->param_name = NULL;
- }
- else if (!strcmp(element_name, "events")) {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
-- account = gaim_accounts_find(data->account_name, data->protocol_id);
-+ account = gaim2_accounts_find(data->account_name, data->protocol_id);
-
- g_free(data->account_name);
- g_free(data->protocol_id);
-@@ -468,7 +468,7 @@ end_element_handler(GMarkupParseContext
- data->protocol_id = NULL;
-
- if (account == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Account for pounce not found!\n");
- /*
- * This pounce has effectively been removed, so make
-@@ -477,11 +477,11 @@ end_element_handler(GMarkupParseContext
- schedule_pounces_save();
- }
- else {
-- gaim_debug(GAIM_DEBUG_INFO, "pounce",
-+ gaim2_debug(GAIM_DEBUG_INFO, "pounce",
- "Creating pounce: %s, %s\n", data->ui_name,
- data->pouncee);
-
-- data->pounce = gaim_pounce_new(data->ui_name, account,
-+ data->pounce = gaim2_pounce_new(data->ui_name, account,
- data->pouncee, data->events,
- data->options);
- }
-@@ -491,7 +491,7 @@ end_element_handler(GMarkupParseContext
- }
- else if (!strcmp(element_name, "save")) {
- if (data->pounce != NULL)
-- gaim_pounce_set_save(data->pounce, TRUE);
-+ gaim2_pounce_set_save(data->pounce, TRUE);
- }
- else if (!strcmp(element_name, "pounce")) {
- data->pounce = NULL;
-@@ -543,9 +543,9 @@ static GMarkupParser pounces_parser =
- };
-
- gboolean
--gaim_pounces_load(void)
-+gaim2_pounces_load(void)
- {
-- gchar *filename = g_build_filename(gaim_user_dir(), "pounces.xml", NULL);
-+ gchar *filename = g_build_filename(gaim2_user_dir(), "pounces.xml", NULL);
- gchar *contents = NULL;
- gsize length;
- GMarkupParseContext *context;
-@@ -558,7 +558,7 @@ gaim_pounces_load(void)
- }
-
- if (!g_file_get_contents(filename, &contents, &length, &error)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce",
- "Error reading pounces: %s\n", error->message);
-
- g_free(filename);
-@@ -584,7 +584,7 @@ gaim_pounces_load(void)
- }
-
- if (!g_markup_parse_context_end_parse(context, NULL)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "pounce", "Error parsing %s\n",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "pounce", "Error parsing %s\n",
- filename);
-
- g_markup_parse_context_free(context);
-@@ -605,20 +605,20 @@ gaim_pounces_load(void)
- }
-
-
--GaimPounce *
--gaim_pounce_new(const char *ui_type, GaimAccount *pouncer,
-- const char *pouncee, GaimPounceEvent event,
-- GaimPounceOption option)
-+Gaim2Pounce *
-+gaim2_pounce_new(const char *ui_type, Gaim2Account *pouncer,
-+ const char *pouncee, Gaim2PounceEvent event,
-+ Gaim2PounceOption option)
- {
-- GaimPounce *pounce;
-- GaimPounceHandler *handler;
-+ Gaim2Pounce *pounce;
-+ Gaim2PounceHandler *handler;
-
- g_return_val_if_fail(ui_type != NULL, NULL);
- g_return_val_if_fail(pouncer != NULL, NULL);
- g_return_val_if_fail(pouncee != NULL, NULL);
- g_return_val_if_fail(event != 0, NULL);
-
-- pounce = g_new0(GaimPounce, 1);
-+ pounce = g_new0(Gaim2Pounce, 1);
-
- pounce->ui_type = g_strdup(ui_type);
- pounce->pouncer = pouncer;
-@@ -642,9 +642,9 @@ gaim_pounce_new(const char *ui_type, Gai
- }
-
- void
--gaim_pounce_destroy(GaimPounce *pounce)
-+gaim2_pounce_destroy(Gaim2Pounce *pounce)
- {
-- GaimPounceHandler *handler;
-+ Gaim2PounceHandler *handler;
-
- g_return_if_fail(pounce != NULL);
-
-@@ -666,27 +666,27 @@ gaim_pounce_destroy(GaimPounce *pounce)
- }
-
- void
--gaim_pounce_destroy_all_by_account(GaimAccount *account)
-+gaim2_pounce_destroy_all_by_account(Gaim2Account *account)
- {
-- GaimAccount *pouncer;
-- GaimPounce *pounce;
-+ Gaim2Account *pouncer;
-+ Gaim2Pounce *pounce;
- GList *l, *l_next;
-
- g_return_if_fail(account != NULL);
-
-- for (l = gaim_pounces_get_all(); l != NULL; l = l_next)
-+ for (l = gaim2_pounces_get_all(); l != NULL; l = l_next)
- {
-- pounce = (GaimPounce *)l->data;
-+ pounce = (Gaim2Pounce *)l->data;
- l_next = l->next;
-
-- pouncer = gaim_pounce_get_pouncer(pounce);
-+ pouncer = gaim2_pounce_get_pouncer(pounce);
- if (pouncer == account)
-- gaim_pounce_destroy(pounce);
-+ gaim2_pounce_destroy(pounce);
- }
- }
-
- void
--gaim_pounce_set_events(GaimPounce *pounce, GaimPounceEvent events)
-+gaim2_pounce_set_events(Gaim2Pounce *pounce, Gaim2PounceEvent events)
- {
- g_return_if_fail(pounce != NULL);
- g_return_if_fail(events != GAIM_POUNCE_NONE);
-@@ -697,7 +697,7 @@ gaim_pounce_set_events(GaimPounce *pounc
- }
-
- void
--gaim_pounce_set_options(GaimPounce *pounce, GaimPounceOption options)
-+gaim2_pounce_set_options(Gaim2Pounce *pounce, Gaim2PounceOption options)
- {
- g_return_if_fail(pounce != NULL);
-
-@@ -707,7 +707,7 @@ gaim_pounce_set_options(GaimPounce *poun
- }
-
- void
--gaim_pounce_set_pouncer(GaimPounce *pounce, GaimAccount *pouncer)
-+gaim2_pounce_set_pouncer(Gaim2Pounce *pounce, Gaim2Account *pouncer)
- {
- g_return_if_fail(pounce != NULL);
- g_return_if_fail(pouncer != NULL);
-@@ -718,7 +718,7 @@ gaim_pounce_set_pouncer(GaimPounce *poun
- }
-
- void
--gaim_pounce_set_pouncee(GaimPounce *pounce, const char *pouncee)
-+gaim2_pounce_set_pouncee(Gaim2Pounce *pounce, const char *pouncee)
- {
- g_return_if_fail(pounce != NULL);
- g_return_if_fail(pouncee != NULL);
-@@ -732,7 +732,7 @@ gaim_pounce_set_pouncee(GaimPounce *poun
- }
-
- void
--gaim_pounce_set_save(GaimPounce *pounce, gboolean save)
-+gaim2_pounce_set_save(Gaim2Pounce *pounce, gboolean save)
- {
- g_return_if_fail(pounce != NULL);
-
-@@ -742,9 +742,9 @@ gaim_pounce_set_save(GaimPounce *pounce,
- }
-
- void
--gaim_pounce_action_register(GaimPounce *pounce, const char *name)
-+gaim2_pounce_action_register(Gaim2Pounce *pounce, const char *name)
- {
-- GaimPounceActionData *action_data;
-+ Gaim2PounceActionData *action_data;
-
- g_return_if_fail(pounce != NULL);
- g_return_if_fail(name != NULL);
-@@ -752,7 +752,7 @@ gaim_pounce_action_register(GaimPounce *
- if (g_hash_table_lookup(pounce->actions, name) != NULL)
- return;
-
-- action_data = g_new0(GaimPounceActionData, 1);
-+ action_data = g_new0(Gaim2PounceActionData, 1);
-
- action_data->name = g_strdup(name);
- action_data->enabled = FALSE;
-@@ -765,10 +765,10 @@ gaim_pounce_action_register(GaimPounce *
- }
-
- void
--gaim_pounce_action_set_enabled(GaimPounce *pounce, const char *action,
-+gaim2_pounce_action_set_enabled(Gaim2Pounce *pounce, const char *action,
- gboolean enabled)
- {
-- GaimPounceActionData *action_data;
-+ Gaim2PounceActionData *action_data;
-
- g_return_if_fail(pounce != NULL);
- g_return_if_fail(action != NULL);
-@@ -783,10 +783,10 @@ gaim_pounce_action_set_enabled(GaimPounc
- }
-
- void
--gaim_pounce_action_set_attribute(GaimPounce *pounce, const char *action,
-+gaim2_pounce_action_set_attribute(Gaim2Pounce *pounce, const char *action,
- const char *attr, const char *value)
- {
-- GaimPounceActionData *action_data;
-+ Gaim2PounceActionData *action_data;
-
- g_return_if_fail(pounce != NULL);
- g_return_if_fail(action != NULL);
-@@ -806,7 +806,7 @@ gaim_pounce_action_set_attribute(GaimPou
- }
-
- void
--gaim_pounce_set_data(GaimPounce *pounce, void *data)
-+gaim2_pounce_set_data(Gaim2Pounce *pounce, void *data)
- {
- g_return_if_fail(pounce != NULL);
-
-@@ -815,24 +815,24 @@ gaim_pounce_set_data(GaimPounce *pounce,
- schedule_pounces_save();
- }
-
--GaimPounceEvent
--gaim_pounce_get_events(const GaimPounce *pounce)
-+Gaim2PounceEvent
-+gaim2_pounce_get_events(const Gaim2Pounce *pounce)
- {
- g_return_val_if_fail(pounce != NULL, GAIM_POUNCE_NONE);
-
- return pounce->events;
- }
-
--GaimPounceOption
--gaim_pounce_get_options(const GaimPounce *pounce)
-+Gaim2PounceOption
-+gaim2_pounce_get_options(const Gaim2Pounce *pounce)
- {
- g_return_val_if_fail(pounce != NULL, GAIM_POUNCE_OPTION_NONE);
-
- return pounce->options;
- }
-
--GaimAccount *
--gaim_pounce_get_pouncer(const GaimPounce *pounce)
-+Gaim2Account *
-+gaim2_pounce_get_pouncer(const Gaim2Pounce *pounce)
- {
- g_return_val_if_fail(pounce != NULL, NULL);
-
-@@ -840,7 +840,7 @@ gaim_pounce_get_pouncer(const GaimPounce
- }
-
- const char *
--gaim_pounce_get_pouncee(const GaimPounce *pounce)
-+gaim2_pounce_get_pouncee(const Gaim2Pounce *pounce)
- {
- g_return_val_if_fail(pounce != NULL, NULL);
-
-@@ -848,7 +848,7 @@ gaim_pounce_get_pouncee(const GaimPounce
- }
-
- gboolean
--gaim_pounce_get_save(const GaimPounce *pounce)
-+gaim2_pounce_get_save(const Gaim2Pounce *pounce)
- {
- g_return_val_if_fail(pounce != NULL, FALSE);
-
-@@ -856,9 +856,9 @@ gaim_pounce_get_save(const GaimPounce *p
- }
-
- gboolean
--gaim_pounce_action_is_enabled(const GaimPounce *pounce, const char *action)
-+gaim2_pounce_action_is_enabled(const Gaim2Pounce *pounce, const char *action)
- {
-- GaimPounceActionData *action_data;
-+ Gaim2PounceActionData *action_data;
-
- g_return_val_if_fail(pounce != NULL, FALSE);
- g_return_val_if_fail(action != NULL, FALSE);
-@@ -871,10 +871,10 @@ gaim_pounce_action_is_enabled(const Gaim
- }
-
- const char *
--gaim_pounce_action_get_attribute(const GaimPounce *pounce,
-+gaim2_pounce_action_get_attribute(const Gaim2Pounce *pounce,
- const char *action, const char *attr)
- {
-- GaimPounceActionData *action_data;
-+ Gaim2PounceActionData *action_data;
-
- g_return_val_if_fail(pounce != NULL, NULL);
- g_return_val_if_fail(action != NULL, NULL);
-@@ -888,7 +888,7 @@ gaim_pounce_action_get_attribute(const G
- }
-
- void *
--gaim_pounce_get_data(const GaimPounce *pounce)
-+gaim2_pounce_get_data(const Gaim2Pounce *pounce)
- {
- g_return_val_if_fail(pounce != NULL, NULL);
-
-@@ -896,12 +896,12 @@ gaim_pounce_get_data(const GaimPounce *p
- }
-
- void
--gaim_pounce_execute(const GaimAccount *pouncer, const char *pouncee,
-- GaimPounceEvent events)
-+gaim2_pounce_execute(const Gaim2Account *pouncer, const char *pouncee,
-+ Gaim2PounceEvent events)
- {
-- GaimPounce *pounce;
-- GaimPounceHandler *handler;
-- GaimPresence *presence;
-+ Gaim2Pounce *pounce;
-+ Gaim2PounceHandler *handler;
-+ Gaim2Presence *presence;
- GList *l, *l_next;
- char *norm_pouncee;
-
-@@ -909,31 +909,31 @@ gaim_pounce_execute(const GaimAccount *p
- g_return_if_fail(pouncee != NULL);
- g_return_if_fail(events != GAIM_POUNCE_NONE);
-
-- norm_pouncee = g_strdup(gaim_normalize(pouncer, pouncee));
-+ norm_pouncee = g_strdup(gaim2_normalize(pouncer, pouncee));
-
-- for (l = gaim_pounces_get_all(); l != NULL; l = l_next)
-+ for (l = gaim2_pounces_get_all(); l != NULL; l = l_next)
- {
-- pounce = (GaimPounce *)l->data;
-+ pounce = (Gaim2Pounce *)l->data;
- l_next = l->next;
-
-- presence = gaim_account_get_presence(pouncer);
-+ presence = gaim2_account_get_presence(pouncer);
-
-- if ((gaim_pounce_get_events(pounce) & events) &&
-- (gaim_pounce_get_pouncer(pounce) == pouncer) &&
-- !gaim_utf8_strcasecmp(gaim_normalize(pouncer, gaim_pounce_get_pouncee(pounce)),
-+ if ((gaim2_pounce_get_events(pounce) & events) &&
-+ (gaim2_pounce_get_pouncer(pounce) == pouncer) &&
-+ !gaim2_utf8_strcasecmp(gaim2_normalize(pouncer, gaim2_pounce_get_pouncee(pounce)),
- norm_pouncee) &&
- (pounce->options == GAIM_POUNCE_OPTION_NONE ||
- (pounce->options & GAIM_POUNCE_OPTION_AWAY &&
-- !gaim_presence_is_available(presence))))
-+ !gaim2_presence_is_available(presence))))
- {
- handler = g_hash_table_lookup(pounce_handlers, pounce->ui_type);
-
- if (handler != NULL && handler->cb != NULL)
- {
-- handler->cb(pounce, events, gaim_pounce_get_data(pounce));
-+ handler->cb(pounce, events, gaim2_pounce_get_data(pounce));
-
-- if (!gaim_pounce_get_save(pounce))
-- gaim_pounce_destroy(pounce);
-+ if (!gaim2_pounce_get_save(pounce))
-+ gaim2_pounce_destroy(pounce);
- }
- }
- }
-@@ -941,11 +941,11 @@ gaim_pounce_execute(const GaimAccount *p
- g_free(norm_pouncee);
- }
-
--GaimPounce *
--gaim_find_pounce(const GaimAccount *pouncer, const char *pouncee,
-- GaimPounceEvent events)
-+Gaim2Pounce *
-+gaim2_find_pounce(const Gaim2Account *pouncer, const char *pouncee,
-+ Gaim2PounceEvent events)
- {
-- GaimPounce *pounce = NULL;
-+ Gaim2Pounce *pounce = NULL;
- GList *l;
- char *norm_pouncee;
-
-@@ -953,15 +953,15 @@ gaim_find_pounce(const GaimAccount *poun
- g_return_val_if_fail(pouncee != NULL, NULL);
- g_return_val_if_fail(events != GAIM_POUNCE_NONE, NULL);
-
-- norm_pouncee = g_strdup(gaim_normalize(pouncer, pouncee));
-+ norm_pouncee = g_strdup(gaim2_normalize(pouncer, pouncee));
-
-- for (l = gaim_pounces_get_all(); l != NULL; l = l->next)
-+ for (l = gaim2_pounces_get_all(); l != NULL; l = l->next)
- {
-- pounce = (GaimPounce *)l->data;
-+ pounce = (Gaim2Pounce *)l->data;
-
-- if ((gaim_pounce_get_events(pounce) & events) &&
-- (gaim_pounce_get_pouncer(pounce) == pouncer) &&
-- !gaim_utf8_strcasecmp(gaim_normalize(pouncer, gaim_pounce_get_pouncee(pounce)),
-+ if ((gaim2_pounce_get_events(pounce) & events) &&
-+ (gaim2_pounce_get_pouncer(pounce) == pouncer) &&
-+ !gaim2_utf8_strcasecmp(gaim2_normalize(pouncer, gaim2_pounce_get_pouncee(pounce)),
- norm_pouncee))
- {
- break;
-@@ -976,16 +976,16 @@ gaim_find_pounce(const GaimAccount *poun
- }
-
- void
--gaim_pounces_register_handler(const char *ui, GaimPounceCb cb,
-- void (*new_pounce)(GaimPounce *pounce),
-- void (*free_pounce)(GaimPounce *pounce))
-+gaim2_pounces_register_handler(const char *ui, Gaim2PounceCb cb,
-+ void (*new_pounce)(Gaim2Pounce *pounce),
-+ void (*free_pounce)(Gaim2Pounce *pounce))
- {
-- GaimPounceHandler *handler;
-+ Gaim2PounceHandler *handler;
-
- g_return_if_fail(ui != NULL);
- g_return_if_fail(cb != NULL);
-
-- handler = g_new0(GaimPounceHandler, 1);
-+ handler = g_new0(Gaim2PounceHandler, 1);
-
- handler->ui = g_strdup(ui);
- handler->cb = cb;
-@@ -996,7 +996,7 @@ gaim_pounces_register_handler(const char
- }
-
- void
--gaim_pounces_unregister_handler(const char *ui)
-+gaim2_pounces_unregister_handler(const char *ui)
- {
- g_return_if_fail(ui != NULL);
-
-@@ -1004,7 +1004,7 @@ gaim_pounces_unregister_handler(const ch
- }
-
- GList *
--gaim_pounces_get_all(void)
-+gaim2_pounces_get_all(void)
- {
- return pounces;
- }
-@@ -1012,71 +1012,71 @@ gaim_pounces_get_all(void)
- static void
- free_pounce_handler(gpointer user_data)
- {
-- GaimPounceHandler *handler = (GaimPounceHandler *)user_data;
-+ Gaim2PounceHandler *handler = (Gaim2PounceHandler *)user_data;
-
- g_free(handler->ui);
- g_free(handler);
- }
-
- static void
--buddy_state_cb(GaimBuddy *buddy, GaimPounceEvent event)
-+buddy_state_cb(Gaim2Buddy *buddy, Gaim2PounceEvent event)
- {
-- gaim_pounce_execute(buddy->account, buddy->name, event);
-+ gaim2_pounce_execute(buddy->account, buddy->name, event);
- }
-
- static void
--buddy_status_changed_cb(GaimBuddy *buddy, GaimStatus *old_status,
-- GaimStatus *status)
-+buddy_status_changed_cb(Gaim2Buddy *buddy, Gaim2Status *old_status,
-+ Gaim2Status *status)
- {
- gboolean old_available, available;
-
-- available = gaim_status_is_available(status);
-- old_available = gaim_status_is_available(old_status);
-+ available = gaim2_status_is_available(status);
-+ old_available = gaim2_status_is_available(old_status);
-
- if (available && !old_available)
-- gaim_pounce_execute(buddy->account, buddy->name,
-+ gaim2_pounce_execute(buddy->account, buddy->name,
- GAIM_POUNCE_AWAY_RETURN);
- else if (!available && old_available)
-- gaim_pounce_execute(buddy->account, buddy->name,
-+ gaim2_pounce_execute(buddy->account, buddy->name,
- GAIM_POUNCE_AWAY);
- }
-
- static void
--buddy_idle_changed_cb(GaimBuddy *buddy, gboolean old_idle, gboolean idle)
-+buddy_idle_changed_cb(Gaim2Buddy *buddy, gboolean old_idle, gboolean idle)
- {
- if (idle && !old_idle)
-- gaim_pounce_execute(buddy->account, buddy->name,
-+ gaim2_pounce_execute(buddy->account, buddy->name,
- GAIM_POUNCE_IDLE);
- else if (!idle && old_idle)
-- gaim_pounce_execute(buddy->account, buddy->name,
-+ gaim2_pounce_execute(buddy->account, buddy->name,
- GAIM_POUNCE_IDLE_RETURN);
- }
-
- static void
--buddy_typing_cb(GaimAccount *account, const char *name, void *data)
-+buddy_typing_cb(Gaim2Account *account, const char *name, void *data)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
- if (conv != NULL)
- {
-- GaimPounceEvent event;
-+ Gaim2PounceEvent event;
-
-- event = (gaim_conv_im_get_typing_state(GAIM_CONV_IM(conv)) == GAIM_TYPING
-+ event = (gaim2_conv_im_get_typing_state(GAIM_CONV_IM(conv)) == GAIM_TYPING
- ? GAIM_POUNCE_TYPING : GAIM_POUNCE_TYPING_STOPPED);
-
-- gaim_pounce_execute(account, name, event);
-+ gaim2_pounce_execute(account, name, event);
- }
- }
-
- static void
--received_message_cb(GaimAccount *account, const char *name, void *data)
-+received_message_cb(Gaim2Account *account, const char *name, void *data)
- {
-- gaim_pounce_execute(account, name, GAIM_POUNCE_MESSAGE_RECEIVED);
-+ gaim2_pounce_execute(account, name, GAIM_POUNCE_MESSAGE_RECEIVED);
- }
-
- void *
--gaim_pounces_get_handle(void)
-+gaim2_pounces_get_handle(void)
- {
- static int pounce_handle;
-
-@@ -1084,44 +1084,44 @@ gaim_pounces_get_handle(void)
- }
-
- void
--gaim_pounces_init(void)
-+gaim2_pounces_init(void)
- {
-- void *handle = gaim_pounces_get_handle();
-- void *blist_handle = gaim_blist_get_handle();
-- void *conv_handle = gaim_conversations_get_handle();
-+ void *handle = gaim2_pounces_get_handle();
-+ void *blist_handle = gaim2_blist_get_handle();
-+ void *conv_handle = gaim2_conversations_get_handle();
-
- pounce_handlers = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, free_pounce_handler);
-
-- gaim_signal_connect(blist_handle, "buddy-idle-changed",
-+ gaim2_signal_connect(blist_handle, "buddy-idle-changed",
- handle, GAIM_CALLBACK(buddy_idle_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-status-changed",
-+ gaim2_signal_connect(blist_handle, "buddy-status-changed",
- handle, GAIM_CALLBACK(buddy_status_changed_cb), NULL);
-- gaim_signal_connect(blist_handle, "buddy-signed-on",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-on",
- handle, GAIM_CALLBACK(buddy_state_cb),
- GINT_TO_POINTER(GAIM_POUNCE_SIGNON));
-- gaim_signal_connect(blist_handle, "buddy-signed-off",
-+ gaim2_signal_connect(blist_handle, "buddy-signed-off",
- handle, GAIM_CALLBACK(buddy_state_cb),
- GINT_TO_POINTER(GAIM_POUNCE_SIGNOFF));
-
-- gaim_signal_connect(conv_handle, "buddy-typing",
-+ gaim2_signal_connect(conv_handle, "buddy-typing",
- handle, GAIM_CALLBACK(buddy_typing_cb), NULL);
-- gaim_signal_connect(conv_handle, "buddy-typing-stopped",
-+ gaim2_signal_connect(conv_handle, "buddy-typing-stopped",
- handle, GAIM_CALLBACK(buddy_typing_cb), NULL);
-
-- gaim_signal_connect(conv_handle, "received-im-msg",
-+ gaim2_signal_connect(conv_handle, "received-im-msg",
- handle, GAIM_CALLBACK(received_message_cb), NULL);
- }
-
- void
--gaim_pounces_uninit()
-+gaim2_pounces_uninit()
- {
- if (save_timer != 0)
- {
-- gaim_timeout_remove(save_timer);
-+ gaim2_timeout_remove(save_timer);
- save_timer = 0;
- sync_pounces();
- }
-
-- gaim_signals_disconnect_by_handle(gaim_pounces_get_handle());
-+ gaim2_signals_disconnect_by_handle(gaim2_pounces_get_handle());
- }
-diff -prNu ./src/pounce.h ./src/pounce.h
---- ./src/pounce.h 2006-01-03 12:42:51.000000000 +0100
-+++ ./src/pounce.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file pounce.h Buddy Pounce API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,7 +25,7 @@
- #ifndef _GAIM_POUNCE_H_
- #define _GAIM_POUNCE_H_
-
--typedef struct _GaimPounce GaimPounce;
-+typedef struct _Gaim2Pounce Gaim2Pounce;
-
- #include <glib.h>
- #include "account.h"
-@@ -46,16 +46,16 @@ typedef enum
- GAIM_POUNCE_TYPING_STOPPED = 0x80, /**< The buddy stopped typing. */
- GAIM_POUNCE_MESSAGE_RECEIVED = 0x100 /**< The buddy sent a message */
-
--} GaimPounceEvent;
-+} Gaim2PounceEvent;
-
- typedef enum
- {
- GAIM_POUNCE_OPTION_NONE = 0x00, /**< No Option */
- GAIM_POUNCE_OPTION_AWAY = 0x01 /**< Pounce only when away */
--} GaimPounceOption;
-+} Gaim2PounceOption;
-
- /** A pounce callback. */
--typedef void (*GaimPounceCb)(GaimPounce *, GaimPounceEvent, void *);
-+typedef void (*Gaim2PounceCb)(Gaim2Pounce *, Gaim2PounceEvent, void *);
-
- /**
- * A buddy pounce structure.
-@@ -65,13 +65,13 @@ typedef void (*GaimPounceCb)(GaimPounce
- * signs on or returns from away. Such responses are handled in the
- * UI. The events themselves are done in the core.
- */
--struct _GaimPounce
-+struct _Gaim2Pounce
- {
- char *ui_type; /**< The type of UI. */
-
-- GaimPounceEvent events; /**< The event(s) to pounce on. */
-- GaimPounceOption options; /**< The pounce options */
-- GaimAccount *pouncer; /**< The user who is pouncing. */
-+ Gaim2PounceEvent events; /**< The event(s) to pounce on. */
-+ Gaim2PounceOption options; /**< The pounce options */
-+ Gaim2Account *pouncer; /**< The user who is pouncing. */
-
- char *pouncee; /**< The buddy to pounce on. */
-
-@@ -101,23 +101,23 @@ extern "C" {
- *
- * @return The new buddy pounce structure.
- */
--GaimPounce *gaim_pounce_new(const char *ui_type, GaimAccount *pouncer,
-- const char *pouncee, GaimPounceEvent event,
-- GaimPounceOption option);
-+Gaim2Pounce *gaim2_pounce_new(const char *ui_type, Gaim2Account *pouncer,
-+ const char *pouncee, Gaim2PounceEvent event,
-+ Gaim2PounceOption option);
-
- /**
- * Destroys a buddy pounce.
- *
- * @param pounce The buddy pounce.
- */
--void gaim_pounce_destroy(GaimPounce *pounce);
-+void gaim2_pounce_destroy(Gaim2Pounce *pounce);
-
- /**
- * Destroys all buddy pounces for the account
- *
- * @param account The account to remove all pounces from.
- */
--void gaim_pounce_destroy_all_by_account(GaimAccount *account);
-+void gaim2_pounce_destroy_all_by_account(Gaim2Account *account);
-
- /**
- * Sets the events a pounce should watch for.
-@@ -125,7 +125,7 @@ void gaim_pounce_destroy_all_by_account(
- * @param pounce The buddy pounce.
- * @param events The events to watch for.
- */
--void gaim_pounce_set_events(GaimPounce *pounce, GaimPounceEvent events);
-+void gaim2_pounce_set_events(Gaim2Pounce *pounce, Gaim2PounceEvent events);
-
- /**
- * Sets the options for a pounce.
-@@ -133,7 +133,7 @@ void gaim_pounce_set_events(GaimPounce *
- * @param pounce The buddy pounce.
- * @param options The options for the pounce.
- */
--void gaim_pounce_set_options(GaimPounce *pounce, GaimPounceOption options);
-+void gaim2_pounce_set_options(Gaim2Pounce *pounce, Gaim2PounceOption options);
-
- /**
- * Sets the account that will do the pouncing.
-@@ -141,7 +141,7 @@ void gaim_pounce_set_options(GaimPounce
- * @param pounce The buddy pounce.
- * @param pouncer The account that will pounce.
- */
--void gaim_pounce_set_pouncer(GaimPounce *pounce, GaimAccount *pouncer);
-+void gaim2_pounce_set_pouncer(Gaim2Pounce *pounce, Gaim2Account *pouncer);
-
- /**
- * Sets the buddy a pounce should pounce on.
-@@ -149,7 +149,7 @@ void gaim_pounce_set_pouncer(GaimPounce
- * @param pounce The buddy pounce.
- * @param pouncee The buddy to pounce on.
- */
--void gaim_pounce_set_pouncee(GaimPounce *pounce, const char *pouncee);
-+void gaim2_pounce_set_pouncee(Gaim2Pounce *pounce, const char *pouncee);
-
- /**
- * Sets whether or not the pounce should be saved after execution.
-@@ -157,7 +157,7 @@ void gaim_pounce_set_pouncee(GaimPounce
- * @param pounce The buddy pounce.
- * @param save @c TRUE if the pounce should be saved, or @c FALSE otherwise.
- */
--void gaim_pounce_set_save(GaimPounce *pounce, gboolean save);
-+void gaim2_pounce_set_save(Gaim2Pounce *pounce, gboolean save);
-
- /**
- * Registers an action type for the pounce.
-@@ -165,7 +165,7 @@ void gaim_pounce_set_save(GaimPounce *po
- * @param pounce The buddy pounce.
- * @param name The action name.
- */
--void gaim_pounce_action_register(GaimPounce *pounce, const char *name);
-+void gaim2_pounce_action_register(Gaim2Pounce *pounce, const char *name);
-
- /**
- * Enables or disables an action for a pounce.
-@@ -174,7 +174,7 @@ void gaim_pounce_action_register(GaimPou
- * @param action The name of the action.
- * @param enabled The enabled state.
- */
--void gaim_pounce_action_set_enabled(GaimPounce *pounce, const char *action,
-+void gaim2_pounce_action_set_enabled(Gaim2Pounce *pounce, const char *action,
- gboolean enabled);
-
- /**
-@@ -187,7 +187,7 @@ void gaim_pounce_action_set_enabled(Gaim
- * @param attr The attribute name.
- * @param value The value.
- */
--void gaim_pounce_action_set_attribute(GaimPounce *pounce, const char *action,
-+void gaim2_pounce_action_set_attribute(Gaim2Pounce *pounce, const char *action,
- const char *attr, const char *value);
-
- /**
-@@ -196,7 +196,7 @@ void gaim_pounce_action_set_attribute(Ga
- * @param pounce The buddy pounce.
- * @param data Data specific to the pounce.
- */
--void gaim_pounce_set_data(GaimPounce *pounce, void *data);
-+void gaim2_pounce_set_data(Gaim2Pounce *pounce, void *data);
-
- /**
- * Returns the events a pounce should watch for.
-@@ -205,7 +205,7 @@ void gaim_pounce_set_data(GaimPounce *po
- *
- * @return The events the pounce is watching for.
- */
--GaimPounceEvent gaim_pounce_get_events(const GaimPounce *pounce);
-+Gaim2PounceEvent gaim2_pounce_get_events(const Gaim2Pounce *pounce);
-
- /**
- * Returns the options for a pounce.
-@@ -214,7 +214,7 @@ GaimPounceEvent gaim_pounce_get_events(c
- *
- * @return The options for the pounce.
- */
--GaimPounceOption gaim_pounce_get_options(const GaimPounce *pounce);
-+Gaim2PounceOption gaim2_pounce_get_options(const Gaim2Pounce *pounce);
-
- /**
- * Returns the account that will do the pouncing.
-@@ -223,7 +223,7 @@ GaimPounceOption gaim_pounce_get_options
- *
- * @return The account that will pounce.
- */
--GaimAccount *gaim_pounce_get_pouncer(const GaimPounce *pounce);
-+Gaim2Account *gaim2_pounce_get_pouncer(const Gaim2Pounce *pounce);
-
- /**
- * Returns the buddy a pounce should pounce on.
-@@ -232,7 +232,7 @@ GaimAccount *gaim_pounce_get_pouncer(con
- *
- * @return The buddy to pounce on.
- */
--const char *gaim_pounce_get_pouncee(const GaimPounce *pounce);
-+const char *gaim2_pounce_get_pouncee(const Gaim2Pounce *pounce);
-
- /**
- * Returns whether or not the pounce should save after execution.
-@@ -242,7 +242,7 @@ const char *gaim_pounce_get_pouncee(cons
- * @return @c TRUE if the pounce should be saved after execution, or
- * @c FALSE otherwise.
- */
--gboolean gaim_pounce_get_save(const GaimPounce *pounce);
-+gboolean gaim2_pounce_get_save(const Gaim2Pounce *pounce);
-
- /**
- * Returns whether or not an action is enabled.
-@@ -252,7 +252,7 @@ gboolean gaim_pounce_get_save(const Gaim
- *
- * @return @c TRUE if the action is enabled, or @c FALSE otherwise.
- */
--gboolean gaim_pounce_action_is_enabled(const GaimPounce *pounce,
-+gboolean gaim2_pounce_action_is_enabled(const Gaim2Pounce *pounce,
- const char *action);
-
- /**
-@@ -264,7 +264,7 @@ gboolean gaim_pounce_action_is_enabled(c
- *
- * @return The attribute value, if it exists, or @c NULL.
- */
--const char *gaim_pounce_action_get_attribute(const GaimPounce *pounce,
-+const char *gaim2_pounce_action_get_attribute(const Gaim2Pounce *pounce,
- const char *action,
- const char *attr);
-
-@@ -275,7 +275,7 @@ const char *gaim_pounce_action_get_attri
- *
- * @return The data specific to a buddy pounce.
- */
--void *gaim_pounce_get_data(const GaimPounce *pounce);
-+void *gaim2_pounce_get_data(const Gaim2Pounce *pounce);
-
- /**
- * Executes a pounce with the specified pouncer, pouncee, and event type.
-@@ -284,8 +284,8 @@ void *gaim_pounce_get_data(const GaimPou
- * @param pouncee The buddy that is being pounced.
- * @param events The events that triggered the pounce.
- */
--void gaim_pounce_execute(const GaimAccount *pouncer, const char *pouncee,
-- GaimPounceEvent events);
-+void gaim2_pounce_execute(const Gaim2Account *pouncer, const char *pouncee,
-+ Gaim2PounceEvent events);
-
- /*@}*/
-
-@@ -303,8 +303,8 @@ void gaim_pounce_execute(const GaimAccou
- *
- * @return The pounce if found, or @c NULL otherwise.
- */
--GaimPounce *gaim_find_pounce(const GaimAccount *pouncer,
-- const char *pouncee, GaimPounceEvent events);
-+Gaim2Pounce *gaim2_find_pounce(const Gaim2Account *pouncer,
-+ const char *pouncee, Gaim2PounceEvent events);
-
-
- /**
-@@ -312,7 +312,7 @@ GaimPounce *gaim_find_pounce(const GaimA
- *
- * @return @c TRUE if the pounces could be loaded.
- */
--gboolean gaim_pounces_load(void);
-+gboolean gaim2_pounces_load(void);
-
- /**
- * Registers a pounce handler for a UI.
-@@ -322,40 +322,40 @@ gboolean gaim_pounces_load(void);
- * @param new_pounce The function called when a pounce is created.
- * @param free_pounce The function called when a pounce is freed.
- */
--void gaim_pounces_register_handler(const char *ui, GaimPounceCb cb,
-- void (*new_pounce)(GaimPounce *pounce),
-- void (*free_pounce)(GaimPounce *pounce));
-+void gaim2_pounces_register_handler(const char *ui, Gaim2PounceCb cb,
-+ void (*new_pounce)(Gaim2Pounce *pounce),
-+ void (*free_pounce)(Gaim2Pounce *pounce));
-
- /**
- * Unregisters a pounce handle for a UI.
- *
- * @param ui The UI name.
- */
--void gaim_pounces_unregister_handler(const char *ui);
-+void gaim2_pounces_unregister_handler(const char *ui);
-
- /**
- * Returns a list of all registered buddy pounces.
- *
- * @return The list of buddy pounces.
- */
--GList *gaim_pounces_get_all(void);
-+GList *gaim2_pounces_get_all(void);
-
- /**
- * Returns the buddy pounce subsystem handle.
- *
- * @return The subsystem handle.
- */
--void *gaim_pounces_get_handle(void);
-+void *gaim2_pounces_get_handle(void);
-
- /**
- * Initializes the pounces subsystem.
- */
--void gaim_pounces_init(void);
-+void gaim2_pounces_init(void);
-
- /**
- * Uninitializes the pounces subsystem.
- */
--void gaim_pounces_uninit(void);
-+void gaim2_pounces_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/prefix.h ./src/prefix.h
---- ./src/prefix.h 2004-11-25 21:48:16.000000000 +0100
-+++ ./src/prefix.h 2006-01-05 15:11:20.000000000 +0100
-@@ -3,9 +3,9 @@
- * upgrading these files.
- *
- * Added this comment.
-- * Added "gaim_ ## " to the namespace
-- * Changed the lib macro to use /lib/gaim instead of just /lib
-- * (why does gaim do that in the -DLIBDIR autoconf thing anyway?)
-+ * Added "gaim2_ ## " to the namespace
-+ * Changed the lib macro to use /lib/gaim2 instead of just /lib
-+ * (why does gaim2 do that in the -DLIBDIR autoconf thing anyway?)
- *
- */
-
-@@ -44,7 +44,7 @@ extern "C" {
- * --> expands br_locate to foobar_br_locate
- */
- #undef BR_NAMESPACE
--#define BR_NAMESPACE(funcName) gaim_ ## funcName
-+#define BR_NAMESPACE(funcName) gaim2_ ## funcName
-
-
- #ifdef ENABLE_BINRELOC
-@@ -76,7 +76,7 @@ extern "C" {
- #define BINDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/bin")))
- #define SBINDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/sbin")))
- #define DATADIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/share")))
-- #define LIBDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/lib/gaim")))
-+ #define LIBDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/lib/gaim2")))
- #define LIBEXECDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/libexec")))
- #define ETCDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/etc")))
- #define SYSCONFDIR (br_thread_local_store (br_prepend_prefix ((void *) "", "/etc")))
-diff -prNu ./src/prefs.c ./src/prefs.c
---- ./src/prefs.c 2005-12-22 05:03:06.000000000 +0100
-+++ ./src/prefs.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -41,15 +41,15 @@
- #endif
-
- struct pref_cb {
-- GaimPrefCallback func;
-+ Gaim2PrefCallback func;
- gpointer data;
- guint id;
- void *handle;
- };
-
--/* TODO: This should use GaimValues? */
--struct gaim_pref {
-- GaimPrefType type;
-+/* TODO: This should use Gaim2Values? */
-+struct gaim2_pref {
-+ Gaim2PrefType type;
- char *name;
- union {
- gpointer generic;
-@@ -59,13 +59,13 @@ struct gaim_pref {
- GList *stringlist;
- } value;
- GSList *callbacks;
-- struct gaim_pref *parent;
-- struct gaim_pref *sibling;
-- struct gaim_pref *first_child;
-+ struct gaim2_pref *parent;
-+ struct gaim2_pref *sibling;
-+ struct gaim2_pref *first_child;
- };
-
-
--static struct gaim_pref prefs = {
-+static struct gaim2_pref prefs = {
- GAIM_PREF_NONE,
- NULL,
- { NULL },
-@@ -85,7 +85,7 @@ static gboolean prefs_loaded = FALSE;
- *********************************************************************/
-
- static struct
--gaim_pref *find_pref(const char *name)
-+gaim2_pref *find_pref(const char *name)
- {
- if (!name || name[0] != '/')
- return NULL;
-@@ -105,10 +105,10 @@ gaim_pref *find_pref(const char *name)
- * tree structure. Yay recursion!
- */
- static void
--pref_to_xmlnode(xmlnode *parent, struct gaim_pref *pref)
-+pref_to_xmlnode(xmlnode *parent, struct gaim2_pref *pref)
- {
- xmlnode *node, *childnode;
-- struct gaim_pref *child;
-+ struct gaim2_pref *child;
- char buf[20];
- GList *cur;
-
-@@ -149,7 +149,7 @@ static xmlnode *
- prefs_to_xmlnode(void)
- {
- xmlnode *node;
-- struct gaim_pref *pref, *child;
-+ struct gaim2_pref *pref, *child;
-
- pref = &prefs;
-
-@@ -175,16 +175,16 @@ sync_prefs(void)
- {
- /*
- * TODO: Call schedule_prefs_save()? Ideally we wouldn't need to.
-- * (prefs.xml should be loaded when gaim_prefs_init is called)
-+ * (prefs.xml should be loaded when gaim2_prefs_init is called)
- */
-- gaim_debug_error("prefs", "Attempted to save prefs before "
-+ gaim2_debug_error("prefs", "Attempted to save prefs before "
- "they were read!\n");
- return;
- }
-
- node = prefs_to_xmlnode();
- data = xmlnode_to_formatted_str(node, NULL);
-- gaim_util_write_data_to_file("prefs.xml", data, -1);
-+ gaim2_util_write_data_to_file("prefs.xml", data, -1);
- g_free(data);
- xmlnode_free(node);
- }
-@@ -201,7 +201,7 @@ static void
- schedule_prefs_save(void)
- {
- if (save_timer == 0)
-- save_timer = gaim_timeout_add(5000, save_cb, NULL);
-+ save_timer = gaim2_timeout_add(5000, save_cb, NULL);
- }
-
-
-@@ -219,7 +219,7 @@ prefs_start_element_handler (GMarkupPars
- gpointer user_data,
- GError **error)
- {
-- GaimPrefType pref_type = GAIM_PREF_NONE;
-+ Gaim2PrefType pref_type = GAIM_PREF_NONE;
- int i;
- const char *pref_name = NULL, *pref_value = NULL;
- GString *pref_name_full;
-@@ -248,7 +248,7 @@ prefs_start_element_handler (GMarkupPars
- }
-
- if(!strcmp(element_name, "item")) {
-- struct gaim_pref *pref;
-+ struct gaim2_pref *pref;
-
- pref_name_full = g_string_new("");
-
-@@ -278,19 +278,19 @@ prefs_start_element_handler (GMarkupPars
-
- switch(pref_type) {
- case GAIM_PREF_NONE:
-- gaim_prefs_add_none(pref_name_full->str);
-+ gaim2_prefs_add_none(pref_name_full->str);
- break;
- case GAIM_PREF_BOOLEAN:
-- gaim_prefs_set_bool(pref_name_full->str, atoi(pref_value));
-+ gaim2_prefs_set_bool(pref_name_full->str, atoi(pref_value));
- break;
- case GAIM_PREF_INT:
-- gaim_prefs_set_int(pref_name_full->str, atoi(pref_value));
-+ gaim2_prefs_set_int(pref_name_full->str, atoi(pref_value));
- break;
- case GAIM_PREF_STRING:
-- gaim_prefs_set_string(pref_name_full->str, pref_value);
-+ gaim2_prefs_set_string(pref_name_full->str, pref_value);
- break;
- case GAIM_PREF_STRING_LIST:
-- gaim_prefs_set_string_list(pref_name_full->str, NULL);
-+ gaim2_prefs_set_string_list(pref_name_full->str, NULL);
- break;
- }
- prefs_stack = g_list_prepend(prefs_stack, g_strdup(pref_name));
-@@ -318,9 +318,9 @@ static GMarkupParser prefs_parser = {
- };
-
- gboolean
--gaim_prefs_load()
-+gaim2_prefs_load()
- {
-- gchar *filename = g_build_filename(gaim_user_dir(), "prefs.xml", NULL);
-+ gchar *filename = g_build_filename(gaim2_user_dir(), "prefs.xml", NULL);
- gchar *contents = NULL;
- gsize length;
- GMarkupParseContext *context;
-@@ -331,7 +331,7 @@ gaim_prefs_load()
- return FALSE;
- }
-
-- gaim_debug_info("prefs", "Reading %s\n", filename);
-+ gaim2_debug_info("prefs", "Reading %s\n", filename);
-
- if(!g_file_get_contents(filename, &contents, &length, &error)) {
- #ifndef _WIN32
-@@ -340,12 +340,12 @@ gaim_prefs_load()
-
- error = NULL;
-
-- filename = g_build_filename(SYSCONFDIR, "gaim", "prefs.xml", NULL);
-+ filename = g_build_filename(SYSCONFDIR, "gaim2", "prefs.xml", NULL);
-
-- gaim_debug_info("prefs", "Reading %s\n", filename);
-+ gaim2_debug_info("prefs", "Reading %s\n", filename);
-
- if (!g_file_get_contents(filename, &contents, &length, &error)) {
-- gaim_debug_error("prefs", "Error reading prefs: %s\n",
-+ gaim2_debug_error("prefs", "Error reading prefs: %s\n",
- error->message);
- g_error_free(error);
- g_free(filename);
-@@ -354,7 +354,7 @@ gaim_prefs_load()
- return FALSE;
- }
- #else /* _WIN32 */
-- gaim_debug_error("prefs", "Error reading prefs: %s\n",
-+ gaim2_debug_error("prefs", "Error reading prefs: %s\n",
- error->message);
- g_error_free(error);
- g_free(filename);
-@@ -376,7 +376,7 @@ gaim_prefs_load()
- }
-
- if(!g_markup_parse_context_end_parse(context, NULL)) {
-- gaim_debug_error("prefs", "Error parsing %s\n", filename);
-+ gaim2_debug_error("prefs", "Error parsing %s\n", filename);
- g_markup_parse_context_free(context);
- g_free(contents);
- g_free(filename);
-@@ -385,7 +385,7 @@ gaim_prefs_load()
- return FALSE;
- }
-
-- gaim_debug_info("prefs", "Finished reading %s\n", filename);
-+ gaim2_debug_info("prefs", "Finished reading %s\n", filename);
- g_markup_parse_context_free(context);
- g_free(contents);
- g_free(filename);
-@@ -397,14 +397,14 @@ gaim_prefs_load()
-
-
- static void
--prefs_save_cb(const char *name, GaimPrefType type, gpointer val,
-+prefs_save_cb(const char *name, Gaim2PrefType type, gpointer val,
- gpointer user_data)
- {
-
- if(!prefs_loaded)
- return;
-
-- gaim_debug_misc("prefs", "%s changed, scheduling save.\n", name);
-+ gaim2_debug_misc("prefs", "%s changed, scheduling save.\n", name);
-
- schedule_prefs_save();
- }
-@@ -446,10 +446,10 @@ get_path_basename(const char *name)
- }
-
- static char *
--pref_full_name(struct gaim_pref *pref)
-+pref_full_name(struct gaim2_pref *pref)
- {
- GString *name;
-- struct gaim_pref *parent;
-+ struct gaim2_pref *parent;
- char *ret;
-
- if(!pref)
-@@ -470,11 +470,11 @@ pref_full_name(struct gaim_pref *pref)
- return ret;
- }
-
--static struct gaim_pref *
-+static struct gaim2_pref *
- find_pref_parent(const char *name)
- {
- char *parent_name = get_path_dirname(name);
-- struct gaim_pref *ret = &prefs;
-+ struct gaim2_pref *ret = &prefs;
-
- if(strcmp(parent_name, "/")) {
- ret = find_pref(parent_name);
-@@ -485,7 +485,7 @@ find_pref_parent(const char *name)
- }
-
- static void
--free_pref_value(struct gaim_pref *pref)
-+free_pref_value(struct gaim2_pref *pref)
- {
- switch(pref->type) {
- case GAIM_PREF_BOOLEAN:
-@@ -511,12 +511,12 @@ free_pref_value(struct gaim_pref *pref)
- }
- }
-
--static struct gaim_pref *
--add_pref(GaimPrefType type, const char *name)
-+static struct gaim2_pref *
-+add_pref(Gaim2PrefType type, const char *name)
- {
-- struct gaim_pref *parent;
-- struct gaim_pref *me;
-- struct gaim_pref *sibling;
-+ struct gaim2_pref *parent;
-+ struct gaim2_pref *me;
-+ struct gaim2_pref *sibling;
- char *my_name;
-
- parent = find_pref_parent(name);
-@@ -533,7 +533,7 @@ add_pref(GaimPrefType type, const char *
- }
- }
-
-- me = g_new0(struct gaim_pref, 1);
-+ me = g_new0(struct gaim2_pref, 1);
- me->type = type;
- me->name = my_name;
-
-@@ -553,15 +553,15 @@ add_pref(GaimPrefType type, const char *
- }
-
- void
--gaim_prefs_add_none(const char *name)
-+gaim2_prefs_add_none(const char *name)
- {
- add_pref(GAIM_PREF_NONE, name);
- }
-
- void
--gaim_prefs_add_bool(const char *name, gboolean value)
-+gaim2_prefs_add_bool(const char *name, gboolean value)
- {
-- struct gaim_pref *pref = add_pref(GAIM_PREF_BOOLEAN, name);
-+ struct gaim2_pref *pref = add_pref(GAIM_PREF_BOOLEAN, name);
-
- if(!pref)
- return;
-@@ -570,9 +570,9 @@ gaim_prefs_add_bool(const char *name, gb
- }
-
- void
--gaim_prefs_add_int(const char *name, int value)
-+gaim2_prefs_add_int(const char *name, int value)
- {
-- struct gaim_pref *pref = add_pref(GAIM_PREF_INT, name);
-+ struct gaim2_pref *pref = add_pref(GAIM_PREF_INT, name);
-
- if(!pref)
- return;
-@@ -581,9 +581,9 @@ gaim_prefs_add_int(const char *name, int
- }
-
- void
--gaim_prefs_add_string(const char *name, const char *value)
-+gaim2_prefs_add_string(const char *name, const char *value)
- {
-- struct gaim_pref *pref = add_pref(GAIM_PREF_STRING, name);
-+ struct gaim2_pref *pref = add_pref(GAIM_PREF_STRING, name);
-
- if(!pref)
- return;
-@@ -592,9 +592,9 @@ gaim_prefs_add_string(const char *name,
- }
-
- void
--gaim_prefs_add_string_list(const char *name, GList *value)
-+gaim2_prefs_add_string_list(const char *name, GList *value)
- {
-- struct gaim_pref *pref = add_pref(GAIM_PREF_STRING_LIST, name);
-+ struct gaim2_pref *pref = add_pref(GAIM_PREF_STRING_LIST, name);
- GList *tmp;
-
- if(!pref)
-@@ -606,7 +606,7 @@ gaim_prefs_add_string_list(const char *n
- }
-
- static void
--remove_pref(struct gaim_pref *pref)
-+remove_pref(struct gaim2_pref *pref)
- {
- char *name;
-
-@@ -619,7 +619,7 @@ remove_pref(struct gaim_pref *pref)
- if(pref->parent->first_child == pref) {
- pref->parent->first_child = pref->sibling;
- } else {
-- struct gaim_pref *sib = pref->parent->first_child;
-+ struct gaim2_pref *sib = pref->parent->first_child;
- while(sib && sib->sibling != pref)
- sib = sib->sibling;
- if(sib)
-@@ -628,7 +628,7 @@ remove_pref(struct gaim_pref *pref)
-
- name = pref_full_name(pref);
-
-- gaim_debug_info("prefs", "removing pref /%s\n", name);
-+ gaim2_debug_info("prefs", "removing pref /%s\n", name);
-
- g_hash_table_remove(prefs_hash, name);
- g_free(name);
-@@ -641,9 +641,9 @@ remove_pref(struct gaim_pref *pref)
- }
-
- void
--gaim_prefs_remove(const char *name)
-+gaim2_prefs_remove(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(!pref)
- return;
-@@ -652,16 +652,16 @@ gaim_prefs_remove(const char *name)
- }
-
- void
--gaim_prefs_destroy()
-+gaim2_prefs_destroy()
- {
-- gaim_prefs_remove("/");
-+ gaim2_prefs_remove("/");
- }
-
- static void
--do_callbacks(const char* name, struct gaim_pref *pref)
-+do_callbacks(const char* name, struct gaim2_pref *pref)
- {
- GSList *cbs;
-- struct gaim_pref *cb_pref;
-+ struct gaim2_pref *cb_pref;
- for(cb_pref = pref; cb_pref; cb_pref = cb_pref->parent) {
- for(cbs = cb_pref->callbacks; cbs; cbs = cbs->next) {
- struct pref_cb *cb = cbs->data;
-@@ -671,13 +671,13 @@ do_callbacks(const char* name, struct ga
- }
-
- void
--gaim_prefs_trigger_callback(const char *name)
-+gaim2_prefs_trigger_callback(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(!pref) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_trigger_callback: Unknown pref %s\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_trigger_callback: Unknown pref %s\n", name);
- return;
- }
-
-@@ -685,13 +685,13 @@ gaim_prefs_trigger_callback(const char *
- }
-
- void
--gaim_prefs_set_generic(const char *name, gpointer value)
-+gaim2_prefs_set_generic(const char *name, gpointer value)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(!pref) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_set_generic: Unknown pref %s\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_set_generic: Unknown pref %s\n", name);
- return;
- }
-
-@@ -700,14 +700,14 @@ gaim_prefs_set_generic(const char *name,
- }
-
- void
--gaim_prefs_set_bool(const char *name, gboolean value)
-+gaim2_prefs_set_bool(const char *name, gboolean value)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(pref) {
- if(pref->type != GAIM_PREF_BOOLEAN) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_set_bool: %s not a boolean pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_set_bool: %s not a boolean pref\n", name);
- return;
- }
-
-@@ -716,19 +716,19 @@ gaim_prefs_set_bool(const char *name, gb
- do_callbacks(name, pref);
- }
- } else {
-- gaim_prefs_add_bool(name, value);
-+ gaim2_prefs_add_bool(name, value);
- }
- }
-
- void
--gaim_prefs_set_int(const char *name, int value)
-+gaim2_prefs_set_int(const char *name, int value)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(pref) {
- if(pref->type != GAIM_PREF_INT) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_set_int: %s not an integer pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_set_int: %s not an integer pref\n", name);
- return;
- }
-
-@@ -737,19 +737,19 @@ gaim_prefs_set_int(const char *name, int
- do_callbacks(name, pref);
- }
- } else {
-- gaim_prefs_add_int(name, value);
-+ gaim2_prefs_add_int(name, value);
- }
- }
-
- void
--gaim_prefs_set_string(const char *name, const char *value)
-+gaim2_prefs_set_string(const char *name, const char *value)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(pref) {
- if(pref->type != GAIM_PREF_STRING) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_set_string: %s not a string pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_set_string: %s not a string pref\n", name);
- return;
- }
-
-@@ -761,20 +761,20 @@ gaim_prefs_set_string(const char *name,
- do_callbacks(name, pref);
- }
- } else {
-- gaim_prefs_add_string(name, value);
-+ gaim2_prefs_add_string(name, value);
- }
- }
-
- void
--gaim_prefs_set_string_list(const char *name, GList *value)
-+gaim2_prefs_set_string_list(const char *name, GList *value)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
- if(pref) {
- GList *tmp;
-
- if(pref->type != GAIM_PREF_STRING_LIST) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_set_string_list: %s not a string list pref\n",
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_set_string_list: %s not a string list pref\n",
- name);
- return;
- }
-@@ -792,14 +792,14 @@ gaim_prefs_set_string_list(const char *n
- do_callbacks(name, pref);
-
- } else {
-- gaim_prefs_add_string_list(name, value);
-+ gaim2_prefs_add_string_list(name, value);
- }
- }
-
- gboolean
--gaim_prefs_exists(const char *name)
-+gaim2_prefs_exists(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if (pref != NULL)
- return TRUE;
-@@ -807,10 +807,10 @@ gaim_prefs_exists(const char *name)
- return FALSE;
- }
-
--GaimPrefType
--gaim_prefs_get_type(const char *name)
-+Gaim2PrefType
-+gaim2_prefs_get_type(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if (pref == NULL)
- return GAIM_PREF_NONE;
-@@ -819,17 +819,17 @@ gaim_prefs_get_type(const char *name)
- }
-
- gboolean
--gaim_prefs_get_bool(const char *name)
-+gaim2_prefs_get_bool(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(!pref) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_bool: Unknown pref %s\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_bool: Unknown pref %s\n", name);
- return FALSE;
- } else if(pref->type != GAIM_PREF_BOOLEAN) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_bool: %s not a boolean pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_bool: %s not a boolean pref\n", name);
- return FALSE;
- }
-
-@@ -837,17 +837,17 @@ gaim_prefs_get_bool(const char *name)
- }
-
- int
--gaim_prefs_get_int(const char *name)
-+gaim2_prefs_get_int(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(!pref) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_int: Unknown pref %s\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_int: Unknown pref %s\n", name);
- return 0;
- } else if(pref->type != GAIM_PREF_INT) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_int: %s not an integer pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_int: %s not an integer pref\n", name);
- return 0;
- }
-
-@@ -855,17 +855,17 @@ gaim_prefs_get_int(const char *name)
- }
-
- const char *
--gaim_prefs_get_string(const char *name)
-+gaim2_prefs_get_string(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
-
- if(!pref) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_string: Unknown pref %s\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_string: Unknown pref %s\n", name);
- return NULL;
- } else if(pref->type != GAIM_PREF_STRING) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_string: %s not a string pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_string: %s not a string pref\n", name);
- return NULL;
- }
-
-@@ -873,18 +873,18 @@ gaim_prefs_get_string(const char *name)
- }
-
- GList *
--gaim_prefs_get_string_list(const char *name)
-+gaim2_prefs_get_string_list(const char *name)
- {
-- struct gaim_pref *pref = find_pref(name);
-+ struct gaim2_pref *pref = find_pref(name);
- GList *ret = NULL, *tmp;
-
- if(!pref) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_string_list: Unknown pref %s\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_string_list: Unknown pref %s\n", name);
- return NULL;
- } else if(pref->type != GAIM_PREF_STRING_LIST) {
-- gaim_debug_error("prefs",
-- "gaim_prefs_get_string_list: %s not a string list pref\n", name);
-+ gaim2_debug_error("prefs",
-+ "gaim2_prefs_get_string_list: %s not a string list pref\n", name);
- return NULL;
- }
-
-@@ -895,9 +895,9 @@ gaim_prefs_get_string_list(const char *n
- }
-
- void
--gaim_prefs_rename(const char *oldname, const char *newname)
-+gaim2_prefs_rename(const char *oldname, const char *newname)
- {
-- struct gaim_pref *oldpref, *newpref;
-+ struct gaim2_pref *oldpref, *newpref;
-
- oldpref = find_pref(oldname);
- newpref = find_pref(newname);
-@@ -906,7 +906,7 @@ gaim_prefs_rename(const char *oldname, c
- if(!oldpref)
- return;
-
-- gaim_debug_info("prefs", "Renaming %s to %s\n", oldname, newname);
-+ gaim2_debug_info("prefs", "Renaming %s to %s\n", oldname, newname);
-
- g_return_if_fail(newpref != NULL); /* the new one needs to be created first */
- g_return_if_fail(oldpref->type == newpref->type);
-@@ -916,16 +916,16 @@ gaim_prefs_rename(const char *oldname, c
- case GAIM_PREF_NONE:
- break;
- case GAIM_PREF_BOOLEAN:
-- gaim_prefs_set_bool(newname, oldpref->value.boolean);
-+ gaim2_prefs_set_bool(newname, oldpref->value.boolean);
- break;
- case GAIM_PREF_INT:
-- gaim_prefs_set_int(newname, oldpref->value.integer);
-+ gaim2_prefs_set_int(newname, oldpref->value.integer);
- break;
- case GAIM_PREF_STRING:
-- gaim_prefs_set_string(newname, oldpref->value.string);
-+ gaim2_prefs_set_string(newname, oldpref->value.string);
- break;
- case GAIM_PREF_STRING_LIST:
-- gaim_prefs_set_string_list(newname, oldpref->value.stringlist);
-+ gaim2_prefs_set_string_list(newname, oldpref->value.stringlist);
- break;
- }
-
-@@ -933,9 +933,9 @@ gaim_prefs_rename(const char *oldname, c
- }
-
- void
--gaim_prefs_rename_boolean_toggle(const char *oldname, const char *newname)
-+gaim2_prefs_rename_boolean_toggle(const char *oldname, const char *newname)
- {
-- struct gaim_pref *oldpref, *newpref;
-+ struct gaim2_pref *oldpref, *newpref;
-
- oldpref = find_pref(oldname);
- newpref = find_pref(newname);
-@@ -944,23 +944,23 @@ gaim_prefs_rename_boolean_toggle(const c
- if(!oldpref)
- return;
-
-- gaim_debug_info("prefs", "Renaming and toggling %s to %s\n", oldname, newname);
-+ gaim2_debug_info("prefs", "Renaming and toggling %s to %s\n", oldname, newname);
-
- g_return_if_fail(newpref != NULL); /* the new one needs to be created */
- g_return_if_fail(oldpref->type == newpref->type);
- g_return_if_fail(oldpref->type == GAIM_PREF_BOOLEAN);
- g_return_if_fail(oldpref->first_child == NULL); /* can't rename parents */
-
-- gaim_prefs_set_bool(newname, !(oldpref->value.boolean));
-+ gaim2_prefs_set_bool(newname, !(oldpref->value.boolean));
-
- remove_pref(oldpref);
-
- }
-
- guint
--gaim_prefs_connect_callback(void *handle, const char *name, GaimPrefCallback func, gpointer data)
-+gaim2_prefs_connect_callback(void *handle, const char *name, Gaim2PrefCallback func, gpointer data)
- {
-- struct gaim_pref *pref;
-+ struct gaim2_pref *pref;
- struct pref_cb *cb;
- static guint cb_id = 0;
-
-@@ -981,10 +981,10 @@ gaim_prefs_connect_callback(void *handle
- }
-
- static gboolean
--disco_callback_helper(struct gaim_pref *pref, guint callback_id)
-+disco_callback_helper(struct gaim2_pref *pref, guint callback_id)
- {
- GSList *cbs;
-- struct gaim_pref *child;
-+ struct gaim2_pref *child;
-
- if(!pref)
- return FALSE;
-@@ -1007,16 +1007,16 @@ disco_callback_helper(struct gaim_pref *
- }
-
- void
--gaim_prefs_disconnect_callback(guint callback_id)
-+gaim2_prefs_disconnect_callback(guint callback_id)
- {
- disco_callback_helper(&prefs, callback_id);
- }
-
- static void
--disco_callback_helper_handle(struct gaim_pref *pref, void *handle)
-+disco_callback_helper_handle(struct gaim2_pref *pref, void *handle)
- {
- GSList *cbs;
-- struct gaim_pref *child;
-+ struct gaim2_pref *child;
-
- if(!pref)
- return;
-@@ -1037,7 +1037,7 @@ disco_callback_helper_handle(struct gaim
- }
-
- void
--gaim_prefs_disconnect_by_handle(void *handle)
-+gaim2_prefs_disconnect_by_handle(void *handle)
- {
- g_return_if_fail(handle != NULL);
-
-@@ -1045,36 +1045,36 @@ gaim_prefs_disconnect_by_handle(void *ha
- }
-
- void
--gaim_prefs_update_old()
-+gaim2_prefs_update_old()
- {
- /* Remove some no-longer-used prefs */
-- gaim_prefs_remove("/core/away/auto_response/enabled");
-- gaim_prefs_remove("/core/away/auto_response/idle_only");
-- gaim_prefs_remove("/core/away/auto_response/in_active_conv");
-- gaim_prefs_remove("/core/away/auto_response/sec_before_resend");
-- gaim_prefs_remove("/core/away/auto_response");
-- gaim_prefs_remove("/core/away/default_message");
-- gaim_prefs_remove("/core/buddies/use_server_alias");
-- gaim_prefs_remove("/core/conversations/away_back_on_send");
-- gaim_prefs_remove("/core/conversations/send_urls_as_links");
-- gaim_prefs_remove("/core/conversations/im/show_login");
-- gaim_prefs_remove("/core/conversations/chat/show_join");
-- gaim_prefs_remove("/core/conversations/chat/show_leave");
-- gaim_prefs_remove("/core/conversations/combine_chat_im");
-- gaim_prefs_remove("/core/conversations/use_alias_for_title");
-- gaim_prefs_remove("/core/logging/log_signon_signoff");
-- gaim_prefs_remove("/core/logging/log_idle_state");
-- gaim_prefs_remove("/core/logging/log_away_state");
-- gaim_prefs_remove("/core/logging/log_own_states");
-- gaim_prefs_remove("/plugins/core/autorecon/hide_connected_error");
-- gaim_prefs_remove("/plugins/core/autorecon/hide_connecting_error");
-- gaim_prefs_remove("/plugins/core/autorecon/hide_reconnecting_dialog");
-- gaim_prefs_remove("/plugins/core/autorecon/restore_state");
-- gaim_prefs_remove("/plugins/core/autorecon");
-+ gaim2_prefs_remove("/core/away/auto_response/enabled");
-+ gaim2_prefs_remove("/core/away/auto_response/idle_only");
-+ gaim2_prefs_remove("/core/away/auto_response/in_active_conv");
-+ gaim2_prefs_remove("/core/away/auto_response/sec_before_resend");
-+ gaim2_prefs_remove("/core/away/auto_response");
-+ gaim2_prefs_remove("/core/away/default_message");
-+ gaim2_prefs_remove("/core/buddies/use_server_alias");
-+ gaim2_prefs_remove("/core/conversations/away_back_on_send");
-+ gaim2_prefs_remove("/core/conversations/send_urls_as_links");
-+ gaim2_prefs_remove("/core/conversations/im/show_login");
-+ gaim2_prefs_remove("/core/conversations/chat/show_join");
-+ gaim2_prefs_remove("/core/conversations/chat/show_leave");
-+ gaim2_prefs_remove("/core/conversations/combine_chat_im");
-+ gaim2_prefs_remove("/core/conversations/use_alias_for_title");
-+ gaim2_prefs_remove("/core/logging/log_signon_signoff");
-+ gaim2_prefs_remove("/core/logging/log_idle_state");
-+ gaim2_prefs_remove("/core/logging/log_away_state");
-+ gaim2_prefs_remove("/core/logging/log_own_states");
-+ gaim2_prefs_remove("/plugins/core/autorecon/hide_connected_error");
-+ gaim2_prefs_remove("/plugins/core/autorecon/hide_connecting_error");
-+ gaim2_prefs_remove("/plugins/core/autorecon/hide_reconnecting_dialog");
-+ gaim2_prefs_remove("/plugins/core/autorecon/restore_state");
-+ gaim2_prefs_remove("/plugins/core/autorecon");
- }
-
- void *
--gaim_prefs_get_handle(void)
-+gaim2_prefs_get_handle(void)
- {
- static int handle;
-
-@@ -1082,71 +1082,71 @@ gaim_prefs_get_handle(void)
- }
-
- void
--gaim_prefs_init(void)
-+gaim2_prefs_init(void)
- {
-- void *handle = gaim_prefs_get_handle();
-+ void *handle = gaim2_prefs_get_handle();
-
- prefs_hash = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, NULL);
-
-- gaim_prefs_connect_callback(handle, "/", prefs_save_cb, NULL);
-+ gaim2_prefs_connect_callback(handle, "/", prefs_save_cb, NULL);
-
-- gaim_prefs_add_none("/core");
-- gaim_prefs_add_none("/plugins");
-- gaim_prefs_add_none("/plugins/core");
-- gaim_prefs_add_none("/plugins/lopl");
-- gaim_prefs_add_none("/plugins/prpl");
-+ gaim2_prefs_add_none("/core");
-+ gaim2_prefs_add_none("/plugins");
-+ gaim2_prefs_add_none("/plugins/core");
-+ gaim2_prefs_add_none("/plugins/lopl");
-+ gaim2_prefs_add_none("/plugins/prpl");
-
- /* Away */
-- gaim_prefs_add_none("/core/away");
-- gaim_prefs_add_string("/core/away/idle_reporting", "system");
-- gaim_prefs_add_bool("/core/away/away_when_idle", TRUE);
-- gaim_prefs_add_int("/core/away/mins_before_away", 5);
-+ gaim2_prefs_add_none("/core/away");
-+ gaim2_prefs_add_string("/core/away/idle_reporting", "system");
-+ gaim2_prefs_add_bool("/core/away/away_when_idle", TRUE);
-+ gaim2_prefs_add_int("/core/away/mins_before_away", 5);
-
- /* Away -> Auto-Reply */
-- if (!gaim_prefs_exists("/core/away/auto_response/enabled") ||
-- !gaim_prefs_exists("/core/away/auto_response/idle_only"))
-+ if (!gaim2_prefs_exists("/core/away/auto_response/enabled") ||
-+ !gaim2_prefs_exists("/core/away/auto_response/idle_only"))
- {
-- gaim_prefs_add_string("/core/away/auto_reply", "awayidle");
-+ gaim2_prefs_add_string("/core/away/auto_reply", "awayidle");
- }
- else
- {
-- if (!gaim_prefs_get_bool("/core/away/auto_response/enabled"))
-+ if (!gaim2_prefs_get_bool("/core/away/auto_response/enabled"))
- {
-- gaim_prefs_add_string("/core/away/auto_reply", "never");
-+ gaim2_prefs_add_string("/core/away/auto_reply", "never");
- }
- else
- {
-- if (gaim_prefs_get_bool("/core/away/auto_response/idle_only"))
-+ if (gaim2_prefs_get_bool("/core/away/auto_response/idle_only"))
- {
-- gaim_prefs_add_string("/core/away/auto_reply", "awayidle");
-+ gaim2_prefs_add_string("/core/away/auto_reply", "awayidle");
- }
- else
- {
-- gaim_prefs_add_string("/core/away/auto_reply", "away");
-+ gaim2_prefs_add_string("/core/away/auto_reply", "away");
- }
- }
- }
-
- /* Buddies */
-- gaim_prefs_add_none("/core/buddies");
-+ gaim2_prefs_add_none("/core/buddies");
-
- /* Contact Priority Settings */
-- gaim_prefs_add_none("/core/contact");
-- gaim_prefs_add_bool("/core/contact/last_match", FALSE);
-- gaim_prefs_remove("/core/contact/offline_score");
-- gaim_prefs_remove("/core/contact/away_score");
-- gaim_prefs_remove("/core/contact/idle_score");
-+ gaim2_prefs_add_none("/core/contact");
-+ gaim2_prefs_add_bool("/core/contact/last_match", FALSE);
-+ gaim2_prefs_remove("/core/contact/offline_score");
-+ gaim2_prefs_remove("/core/contact/away_score");
-+ gaim2_prefs_remove("/core/contact/idle_score");
- }
-
- void
--gaim_prefs_uninit()
-+gaim2_prefs_uninit()
- {
- if (save_timer != 0)
- {
-- gaim_timeout_remove(save_timer);
-+ gaim2_timeout_remove(save_timer);
- save_timer = 0;
- sync_prefs();
- }
-
-- gaim_prefs_disconnect_by_handle(gaim_prefs_get_handle());
-+ gaim2_prefs_disconnect_by_handle(gaim2_prefs_get_handle());
- }
-diff -prNu ./src/prefs.h ./src/prefs.h
---- ./src/prefs.h 2006-01-04 05:14:02.000000000 +0100
-+++ ./src/prefs.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file prefs.h Prefs API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -36,12 +36,12 @@ typedef enum
- GAIM_STRING_FORMAT_TYPE_NONE = 0,
- GAIM_STRING_FORMAT_TYPE_MULTILINE = 1 << 0,
- GAIM_STRING_FORMAT_TYPE_HTML = 1 << 1
--} GaimStringFormatType;
-+} Gaim2StringFormatType;
-
- /**
- * Pref data types.
- */
--typedef enum _GaimPrefType
-+typedef enum _Gaim2PrefType
- {
- GAIM_PREF_NONE,
- GAIM_PREF_BOOLEAN,
-@@ -49,13 +49,13 @@ typedef enum _GaimPrefType
- GAIM_PREF_STRING,
- GAIM_PREF_STRING_LIST
-
--} GaimPrefType;
-+} Gaim2PrefType;
-
- /**
- * Pref change callback type
- */
-
--typedef void (*GaimPrefCallback) (const char *name, GaimPrefType type,
-+typedef void (*Gaim2PrefCallback) (const char *name, Gaim2PrefType type,
- gpointer val, gpointer data);
-
- #ifdef __cplusplus
-@@ -72,24 +72,24 @@ extern "C" {
- *
- * @return The prefs subsystem handle.
- */
--void *gaim_prefs_get_handle(void);
-+void *gaim2_prefs_get_handle(void);
-
- /**
- * Initialize core prefs
- */
--void gaim_prefs_init(void);
-+void gaim2_prefs_init(void);
-
- /**
- * Uninitializes the prefs subsystem.
- */
--void gaim_prefs_uninit(void);
-+void gaim2_prefs_uninit(void);
-
- /**
- * Add a new typeless pref.
- *
- * @param name The name of the pref
- */
--void gaim_prefs_add_none(const char *name);
-+void gaim2_prefs_add_none(const char *name);
-
- /**
- * Add a new boolean pref.
-@@ -97,7 +97,7 @@ void gaim_prefs_add_none(const char *nam
- * @param name The name of the pref
- * @param value The initial value to set
- */
--void gaim_prefs_add_bool(const char *name, gboolean value);
-+void gaim2_prefs_add_bool(const char *name, gboolean value);
-
- /**
- * Add a new integer pref.
-@@ -105,7 +105,7 @@ void gaim_prefs_add_bool(const char *nam
- * @param name The name of the pref
- * @param value The initial value to set
- */
--void gaim_prefs_add_int(const char *name, int value);
-+void gaim2_prefs_add_int(const char *name, int value);
-
- /**
- * Add a new string pref.
-@@ -113,7 +113,7 @@ void gaim_prefs_add_int(const char *name
- * @param name The name of the pref
- * @param value The initial value to set
- */
--void gaim_prefs_add_string(const char *name, const char *value);
-+void gaim2_prefs_add_string(const char *name, const char *value);
-
- /**
- * Add a new string list pref.
-@@ -121,14 +121,14 @@ void gaim_prefs_add_string(const char *n
- * @param name The name of the pref
- * @param value The initial value to set
- */
--void gaim_prefs_add_string_list(const char *name, GList *value);
-+void gaim2_prefs_add_string_list(const char *name, GList *value);
-
- /**
- * Remove a pref.
- *
- * @param name The name of the pref
- */
--void gaim_prefs_remove(const char *name);
-+void gaim2_prefs_remove(const char *name);
-
- /**
- * Rename a pref
-@@ -136,7 +136,7 @@ void gaim_prefs_remove(const char *name)
- * @param oldname The old name of the pref
- * @param newname The new name for the pref
- */
--void gaim_prefs_rename(const char *oldname, const char *newname);
-+void gaim2_prefs_rename(const char *oldname, const char *newname);
-
- /**
- * Rename a boolean pref, toggling it's value
-@@ -144,12 +144,12 @@ void gaim_prefs_rename(const char *oldna
- * @param oldname The old name of the pref
- * @param newname The new name for the pref
- */
--void gaim_prefs_rename_boolean_toggle(const char *oldname, const char *newname);
-+void gaim2_prefs_rename_boolean_toggle(const char *oldname, const char *newname);
-
- /**
- * Remove all prefs.
- */
--void gaim_prefs_destroy(void);
-+void gaim2_prefs_destroy(void);
-
- /**
- * Set raw pref value
-@@ -157,7 +157,7 @@ void gaim_prefs_destroy(void);
- * @param name The name of the pref
- * @param value The value to set
- */
--void gaim_prefs_set_generic(const char *name, gpointer value);
-+void gaim2_prefs_set_generic(const char *name, gpointer value);
-
- /**
- * Set boolean pref value
-@@ -165,7 +165,7 @@ void gaim_prefs_set_generic(const char *
- * @param name The name of the pref
- * @param value The value to set
- */
--void gaim_prefs_set_bool(const char *name, gboolean value);
-+void gaim2_prefs_set_bool(const char *name, gboolean value);
-
- /**
- * Set integer pref value
-@@ -173,7 +173,7 @@ void gaim_prefs_set_bool(const char *nam
- * @param name The name of the pref
- * @param value The value to set
- */
--void gaim_prefs_set_int(const char *name, int value);
-+void gaim2_prefs_set_int(const char *name, int value);
-
- /**
- * Set string pref value
-@@ -181,7 +181,7 @@ void gaim_prefs_set_int(const char *name
- * @param name The name of the pref
- * @param value The value to set
- */
--void gaim_prefs_set_string(const char *name, const char *value);
-+void gaim2_prefs_set_string(const char *name, const char *value);
-
- /**
- * Set string pref value
-@@ -189,7 +189,7 @@ void gaim_prefs_set_string(const char *n
- * @param name The name of the pref
- * @param value The value to set
- */
--void gaim_prefs_set_string_list(const char *name, GList *value);
-+void gaim2_prefs_set_string_list(const char *name, GList *value);
-
- /**
- * Check if a pref exists
-@@ -197,7 +197,7 @@ void gaim_prefs_set_string_list(const ch
- * @param name The name of the pref
- * @return TRUE if the pref exists. Otherwise FALSE.
- */
--gboolean gaim_prefs_exists(const char *name);
-+gboolean gaim2_prefs_exists(const char *name);
-
- /**
- * Get pref type
-@@ -205,7 +205,7 @@ gboolean gaim_prefs_exists(const char *n
- * @param name The name of the pref
- * @return The type of the pref
- */
--GaimPrefType gaim_prefs_get_type(const char *name);
-+Gaim2PrefType gaim2_prefs_get_type(const char *name);
-
- /**
- * Get boolean pref value
-@@ -213,7 +213,7 @@ GaimPrefType gaim_prefs_get_type(const c
- * @param name The name of the pref
- * @return The value of the pref
- */
--gboolean gaim_prefs_get_bool(const char *name);
-+gboolean gaim2_prefs_get_bool(const char *name);
-
- /**
- * Get integer pref value
-@@ -221,7 +221,7 @@ gboolean gaim_prefs_get_bool(const char
- * @param name The name of the pref
- * @return The value of the pref
- */
--int gaim_prefs_get_int(const char *name);
-+int gaim2_prefs_get_int(const char *name);
-
- /**
- * Get string pref value
-@@ -229,7 +229,7 @@ int gaim_prefs_get_int(const char *name)
- * @param name The name of the pref
- * @return The value of the pref
- */
--const char *gaim_prefs_get_string(const char *name);
-+const char *gaim2_prefs_get_string(const char *name);
-
- /**
- * Get string list pref value
-@@ -237,38 +237,38 @@ const char *gaim_prefs_get_string(const
- * @param name The name of the pref
- * @return The value of the pref
- */
--GList *gaim_prefs_get_string_list(const char *name);
-+GList *gaim2_prefs_get_string_list(const char *name);
-
- /**
- * Add a callback to a pref (and its children)
- */
--guint gaim_prefs_connect_callback(void *handle, const char *name, GaimPrefCallback cb,
-+guint gaim2_prefs_connect_callback(void *handle, const char *name, Gaim2PrefCallback cb,
- gpointer data);
-
- /**
- * Remove a callback to a pref
- */
--void gaim_prefs_disconnect_callback(guint callback_id);
-+void gaim2_prefs_disconnect_callback(guint callback_id);
-
- /**
- * Remove all pref callbacks by handle
- */
--void gaim_prefs_disconnect_by_handle(void *handle);
-+void gaim2_prefs_disconnect_by_handle(void *handle);
-
- /**
- * Trigger callbacks as if the pref changed
- */
--void gaim_prefs_trigger_callback(const char *name);
-+void gaim2_prefs_trigger_callback(const char *name);
-
- /**
- * Read preferences
- */
--gboolean gaim_prefs_load(void);
-+gboolean gaim2_prefs_load(void);
-
- /**
- * Rename legacy prefs and delete some that no longer exist.
- */
--void gaim_prefs_update_old(void);
-+void gaim2_prefs_update_old(void);
-
- /*@}*/
-
-diff -prNu ./src/privacy.c ./src/privacy.c
---- ./src/privacy.c 2005-10-22 22:48:18.000000000 +0200
-+++ ./src/privacy.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,10 +26,10 @@
- #include "server.h"
- #include "util.h"
-
--static GaimPrivacyUiOps *privacy_ops = NULL;
-+static Gaim2PrivacyUiOps *privacy_ops = NULL;
-
- gboolean
--gaim_privacy_permit_add(GaimAccount *account, const char *who,
-+gaim2_privacy_permit_add(Gaim2Account *account, const char *who,
- gboolean local_only)
- {
- GSList *l;
-@@ -38,10 +38,10 @@ gaim_privacy_permit_add(GaimAccount *acc
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(who != NULL, FALSE);
-
-- name = g_strdup(gaim_normalize(account, who));
-+ name = g_strdup(gaim2_normalize(account, who));
-
- for (l = account->permit; l != NULL; l = l->next) {
-- if (!gaim_utf8_strcasecmp(name, gaim_normalize(account, (char *)l->data)))
-+ if (!gaim2_utf8_strcasecmp(name, gaim2_normalize(account, (char *)l->data)))
- break;
- }
-
-@@ -52,19 +52,19 @@ gaim_privacy_permit_add(GaimAccount *acc
-
- account->permit = g_slist_append(account->permit, g_strdup(who));
-
-- if (!local_only && gaim_account_is_connected(account))
-- serv_add_permit(gaim_account_get_connection(account), who);
-+ if (!local_only && gaim2_account_is_connected(account))
-+ serv_add_permit(gaim2_account_get_connection(account), who);
-
- if (privacy_ops != NULL && privacy_ops->permit_added != NULL)
- privacy_ops->permit_added(account, who);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- return TRUE;
- }
-
- gboolean
--gaim_privacy_permit_remove(GaimAccount *account, const char *who,
-+gaim2_privacy_permit_remove(Gaim2Account *account, const char *who,
- gboolean local_only)
- {
- GSList *l;
-@@ -73,10 +73,10 @@ gaim_privacy_permit_remove(GaimAccount *
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(who != NULL, FALSE);
-
-- name = g_strdup(gaim_normalize(account, who));
-+ name = g_strdup(gaim2_normalize(account, who));
-
- for (l = account->permit; l != NULL; l = l->next) {
-- if (!gaim_utf8_strcasecmp(name, gaim_normalize(account, (char *)l->data)))
-+ if (!gaim2_utf8_strcasecmp(name, gaim2_normalize(account, (char *)l->data)))
- break;
- }
-
-@@ -88,19 +88,19 @@ gaim_privacy_permit_remove(GaimAccount *
- g_free(l->data);
- account->permit = g_slist_delete_link(account->permit, l);
-
-- if (!local_only && gaim_account_is_connected(account))
-- serv_rem_permit(gaim_account_get_connection(account), who);
-+ if (!local_only && gaim2_account_is_connected(account))
-+ serv_rem_permit(gaim2_account_get_connection(account), who);
-
- if (privacy_ops != NULL && privacy_ops->permit_removed != NULL)
- privacy_ops->permit_removed(account, who);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- return TRUE;
- }
-
- gboolean
--gaim_privacy_deny_add(GaimAccount *account, const char *who,
-+gaim2_privacy_deny_add(Gaim2Account *account, const char *who,
- gboolean local_only)
- {
- GSList *l;
-@@ -109,10 +109,10 @@ gaim_privacy_deny_add(GaimAccount *accou
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(who != NULL, FALSE);
-
-- name = g_strdup(gaim_normalize(account, who));
-+ name = g_strdup(gaim2_normalize(account, who));
-
- for (l = account->deny; l != NULL; l = l->next) {
-- if (!gaim_utf8_strcasecmp(name, gaim_normalize(account, (char *)l->data)))
-+ if (!gaim2_utf8_strcasecmp(name, gaim2_normalize(account, (char *)l->data)))
- break;
- }
-
-@@ -123,19 +123,19 @@ gaim_privacy_deny_add(GaimAccount *accou
-
- account->deny = g_slist_append(account->deny, g_strdup(who));
-
-- if (!local_only && gaim_account_is_connected(account))
-- serv_add_deny(gaim_account_get_connection(account), who);
-+ if (!local_only && gaim2_account_is_connected(account))
-+ serv_add_deny(gaim2_account_get_connection(account), who);
-
- if (privacy_ops != NULL && privacy_ops->deny_added != NULL)
- privacy_ops->deny_added(account, who);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- return TRUE;
- }
-
- gboolean
--gaim_privacy_deny_remove(GaimAccount *account, const char *who,
-+gaim2_privacy_deny_remove(Gaim2Account *account, const char *who,
- gboolean local_only)
- {
- GSList *l;
-@@ -144,10 +144,10 @@ gaim_privacy_deny_remove(GaimAccount *ac
- g_return_val_if_fail(account != NULL, FALSE);
- g_return_val_if_fail(who != NULL, FALSE);
-
-- name = g_strdup(gaim_normalize(account, who));
-+ name = g_strdup(gaim2_normalize(account, who));
-
- for (l = account->deny; l != NULL; l = l->next) {
-- if (!gaim_utf8_strcasecmp(name, gaim_normalize(account, (char *)l->data)))
-+ if (!gaim2_utf8_strcasecmp(name, gaim2_normalize(account, (char *)l->data)))
- break;
- }
-
-@@ -159,19 +159,19 @@ gaim_privacy_deny_remove(GaimAccount *ac
- g_free(l->data);
- account->deny = g_slist_delete_link(account->deny, l);
-
-- if (!local_only && gaim_account_is_connected(account))
-- serv_rem_deny(gaim_account_get_connection(account), who);
-+ if (!local_only && gaim2_account_is_connected(account))
-+ serv_rem_deny(gaim2_account_get_connection(account), who);
-
- if (privacy_ops != NULL && privacy_ops->deny_removed != NULL)
- privacy_ops->deny_removed(account, who);
-
-- gaim_blist_schedule_save();
-+ gaim2_blist_schedule_save();
-
- return TRUE;
- }
-
- gboolean
--gaim_privacy_check(GaimAccount *account, const char *who)
-+gaim2_privacy_check(Gaim2Account *account, const char *who)
- {
- GSList *list;
-
-@@ -184,20 +184,20 @@ gaim_privacy_check(GaimAccount *account,
-
- case GAIM_PRIVACY_ALLOW_USERS:
- for (list=account->permit; list!=NULL; list=list->next) {
-- if (!gaim_utf8_strcasecmp(who, gaim_normalize(account, (char *)list->data)))
-+ if (!gaim2_utf8_strcasecmp(who, gaim2_normalize(account, (char *)list->data)))
- return TRUE;
- }
- return FALSE;
-
- case GAIM_PRIVACY_DENY_USERS:
- for (list=account->deny; list!=NULL; list=list->next) {
-- if (!gaim_utf8_strcasecmp(who, gaim_normalize( account, (char *)list->data )))
-+ if (!gaim2_utf8_strcasecmp(who, gaim2_normalize( account, (char *)list->data )))
- return FALSE;
- }
- return TRUE;
-
- case GAIM_PRIVACY_ALLOW_BUDDYLIST:
-- return (gaim_find_buddy(account, who) != NULL);
-+ return (gaim2_find_buddy(account, who) != NULL);
-
- default:
- g_return_val_if_reached(TRUE);
-@@ -205,18 +205,18 @@ gaim_privacy_check(GaimAccount *account,
- }
-
- void
--gaim_privacy_set_ui_ops(GaimPrivacyUiOps *ops)
-+gaim2_privacy_set_ui_ops(Gaim2PrivacyUiOps *ops)
- {
- privacy_ops = ops;
- }
-
--GaimPrivacyUiOps *
--gaim_privacy_get_ui_ops(void)
-+Gaim2PrivacyUiOps *
-+gaim2_privacy_get_ui_ops(void)
- {
- return privacy_ops;
- }
-
- void
--gaim_privacy_init(void)
-+gaim2_privacy_init(void)
- {
- }
-diff -prNu ./src/privacy.h ./src/privacy.h
---- ./src/privacy.h 2005-07-18 17:49:12.000000000 +0200
-+++ ./src/privacy.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file privacy.h Privacy API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,14 +30,14 @@
- /**
- * Privacy data types.
- */
--typedef enum _GaimPrivacyType
-+typedef enum _Gaim2PrivacyType
- {
- GAIM_PRIVACY_ALLOW_ALL = 1,
- GAIM_PRIVACY_DENY_ALL,
- GAIM_PRIVACY_ALLOW_USERS,
- GAIM_PRIVACY_DENY_USERS,
- GAIM_PRIVACY_ALLOW_BUDDYLIST
--} GaimPrivacyType;
-+} Gaim2PrivacyType;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -48,12 +48,12 @@ extern "C" {
- */
- typedef struct
- {
-- void (*permit_added)(GaimAccount *account, const char *name);
-- void (*permit_removed)(GaimAccount *account, const char *name);
-- void (*deny_added)(GaimAccount *account, const char *name);
-- void (*deny_removed)(GaimAccount *account, const char *name);
-+ void (*permit_added)(Gaim2Account *account, const char *name);
-+ void (*permit_removed)(Gaim2Account *account, const char *name);
-+ void (*deny_added)(Gaim2Account *account, const char *name);
-+ void (*deny_removed)(Gaim2Account *account, const char *name);
-
--} GaimPrivacyUiOps;
-+} Gaim2PrivacyUiOps;
-
- /**
- * Adds a user to the account's permit list.
-@@ -65,7 +65,7 @@ typedef struct
- *
- * @return TRUE if the user was added successfully, or @c FALSE otherwise.
- */
--gboolean gaim_privacy_permit_add(GaimAccount *account, const char *name,
-+gboolean gaim2_privacy_permit_add(Gaim2Account *account, const char *name,
- gboolean local_only);
-
- /**
-@@ -78,7 +78,7 @@ gboolean gaim_privacy_permit_add(GaimAcc
- *
- * @return TRUE if the user was removed successfully, or @c FALSE otherwise.
- */
--gboolean gaim_privacy_permit_remove(GaimAccount *account, const char *name,
-+gboolean gaim2_privacy_permit_remove(Gaim2Account *account, const char *name,
- gboolean local_only);
-
- /**
-@@ -91,7 +91,7 @@ gboolean gaim_privacy_permit_remove(Gaim
- *
- * @return TRUE if the user was added successfully, or @c FALSE otherwise.
- */
--gboolean gaim_privacy_deny_add(GaimAccount *account, const char *name,
-+gboolean gaim2_privacy_deny_add(Gaim2Account *account, const char *name,
- gboolean local_only);
-
- /**
-@@ -104,7 +104,7 @@ gboolean gaim_privacy_deny_add(GaimAccou
- *
- * @return TRUE if the user was removed successfully, or @c FALSE otherwise.
- */
--gboolean gaim_privacy_deny_remove(GaimAccount *account, const char *name,
-+gboolean gaim2_privacy_deny_remove(Gaim2Account *account, const char *name,
- gboolean local_only);
-
-
-@@ -116,26 +116,26 @@ gboolean gaim_privacy_deny_remove(GaimAc
- *
- * @return @c FALSE if the specified account's privacy settings block the user or @c TRUE otherwise. The meaning of "block" is protocol-dependent and generally relates to status and/or sending of messages.
- */
--gboolean gaim_privacy_check(GaimAccount *account, const char *who);
-+gboolean gaim2_privacy_check(Gaim2Account *account, const char *who);
-
- /**
- * Sets the UI operations structure for the privacy subsystem.
- *
- * @param ops The UI operations structure.
- */
--void gaim_privacy_set_ui_ops(GaimPrivacyUiOps *ops);
-+void gaim2_privacy_set_ui_ops(Gaim2PrivacyUiOps *ops);
-
- /**
- * Returns the UI operations structure for the privacy subsystem.
- *
- * @return The UI operations structure.
- */
--GaimPrivacyUiOps *gaim_privacy_get_ui_ops(void);
-+Gaim2PrivacyUiOps *gaim2_privacy_get_ui_ops(void);
-
- /**
- * Initializes the privacy subsystem.
- */
--void gaim_privacy_init(void);
-+void gaim2_privacy_init(void);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/protocols/bonjour/bonjour.c ./src/protocols/bonjour/bonjour.c
---- ./src/protocols/bonjour/bonjour.c 2005-12-25 20:09:21.000000000 +0100
-+++ ./src/protocols/bonjour/bonjour.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim - Bonjour Protocol Plugin
-+ * gaim2 - Bonjour Protocol Plugin
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -50,14 +50,14 @@ static char *default_lastname;
- static char *default_hostname;
-
- static void
--bonjour_removeallfromlocal(GaimConnection *gc)
-+bonjour_removeallfromlocal(Gaim2Connection *gc)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimBuddyList *blist;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *buddy;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *buddy;
-
-- blist = gaim_get_blist();
-+ blist = gaim2_get_blist();
- if (blist == NULL)
- return;
-
-@@ -74,24 +74,24 @@ bonjour_removeallfromlocal(GaimConnectio
- {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
- if (buddy->account != account)
- continue;
-- gaim_prpl_got_user_status(account, buddy->name, "offline", NULL);
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_prpl_got_user_status(account, buddy->name, "offline", NULL);
-+ gaim2_blist_remove_buddy(buddy);
- }
- }
- }
- }
-
- static void
--bonjour_login(GaimAccount *account)
-+bonjour_login(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-- GaimGroup *bonjour_group = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ Gaim2Group *bonjour_group = NULL;
- BonjourData *bd = NULL;
-- GaimStatus *status;
-- GaimPresence *presence;
-+ Gaim2Status *status;
-+ Gaim2Presence *presence;
-
- gc->flags |= GAIM_CONNECTION_HTML;
- gc->proto_data = g_new0(BonjourData, 1);
-@@ -99,12 +99,12 @@ bonjour_login(GaimAccount *account)
-
- /* Start waiting for jabber connections (iChat style) */
- bd->jabber_data = g_new(BonjourJabber, 1);
-- bd->jabber_data->port = gaim_account_get_int(account, "port", BONJOUR_DEFAULT_PORT_INT);
-+ bd->jabber_data->port = gaim2_account_get_int(account, "port", BONJOUR_DEFAULT_PORT_INT);
- bd->jabber_data->account = account;
-
- if (bonjour_jabber_start(bd->jabber_data) == -1) {
- /* Send a message about the connection error */
-- gaim_connection_error(gc, _("Unable to listen for incoming IM connections\n"));
-+ gaim2_connection_error(gc, _("Unable to listen for incoming IM connections\n"));
-
- /* Free the data */
- g_free(bd->jabber_data);
-@@ -114,47 +114,47 @@ bonjour_login(GaimAccount *account)
-
- /* Connect to the mDNS daemon looking for buddies in the LAN */
- bd->dns_sd_data = bonjour_dns_sd_new();
-- bd->dns_sd_data->name = (sw_string)gaim_account_get_username(account);
-+ bd->dns_sd_data->name = (sw_string)gaim2_account_get_username(account);
- bd->dns_sd_data->txtvers = g_strdup("1");
- bd->dns_sd_data->version = g_strdup("1");
-- bd->dns_sd_data->first = g_strdup(gaim_account_get_string(account, "first", default_firstname));
-- bd->dns_sd_data->last = g_strdup(gaim_account_get_string(account, "last", default_lastname));
-- bd->dns_sd_data->port_p2pj = gaim_account_get_int(account, "port", BONJOUR_DEFAULT_PORT_INT);
-+ bd->dns_sd_data->first = g_strdup(gaim2_account_get_string(account, "first", default_firstname));
-+ bd->dns_sd_data->last = g_strdup(gaim2_account_get_string(account, "last", default_lastname));
-+ bd->dns_sd_data->port_p2pj = gaim2_account_get_int(account, "port", BONJOUR_DEFAULT_PORT_INT);
- bd->dns_sd_data->phsh = g_strdup("");
-- bd->dns_sd_data->email = g_strdup(gaim_account_get_string(account, "email", ""));
-+ bd->dns_sd_data->email = g_strdup(gaim2_account_get_string(account, "email", ""));
- bd->dns_sd_data->vc = g_strdup("");
- bd->dns_sd_data->jid = g_strdup("");
- bd->dns_sd_data->AIM = g_strdup("");
-
-- status = gaim_account_get_active_status(account);
-- presence = gaim_account_get_presence(account);
-- if (gaim_presence_is_available(presence))
-+ status = gaim2_account_get_active_status(account);
-+ presence = gaim2_account_get_presence(account);
-+ if (gaim2_presence_is_available(presence))
- bd->dns_sd_data->status = g_strdup("avail");
-- else if (gaim_presence_is_idle(presence))
-+ else if (gaim2_presence_is_idle(presence))
- bd->dns_sd_data->status = g_strdup("away");
- else
- bd->dns_sd_data->status = g_strdup("dnd");
-- bd->dns_sd_data->msg = g_strdup(gaim_status_get_attr_string(status, "message"));
-+ bd->dns_sd_data->msg = g_strdup(gaim2_status_get_attr_string(status, "message"));
-
- bd->dns_sd_data->account = account;
- if (!bonjour_dns_sd_start(bd->dns_sd_data))
- {
-- gaim_connection_error(gc, _("Unable to establish connection with the local mDNS server. Is it running?"));
-+ gaim2_connection_error(gc, _("Unable to establish connection with the local mDNS server. Is it running?"));
- return;
- }
-
- /* Create a group for bonjour buddies */
-- bonjour_group = gaim_group_new(BONJOUR_GROUP_NAME);
-- gaim_blist_add_group(bonjour_group, NULL);
-+ bonjour_group = gaim2_group_new(BONJOUR_GROUP_NAME);
-+ gaim2_blist_add_group(bonjour_group, NULL);
-
-- /* Show the buddy list by telling Gaim we have already connected */
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ /* Show the buddy list by telling Gaim2 we have already connected */
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
- }
-
- static void
--bonjour_close(GaimConnection *connection)
-+bonjour_close(Gaim2Connection *connection)
- {
-- GaimGroup *bonjour_group = gaim_find_group(BONJOUR_GROUP_NAME);
-+ Gaim2Group *bonjour_group = gaim2_find_group(BONJOUR_GROUP_NAME);
- BonjourData *bd = (BonjourData*)connection->proto_data;
-
- /* Stop looking for buddies in the LAN */
-@@ -175,18 +175,18 @@ bonjour_close(GaimConnection *connection
- bonjour_removeallfromlocal(connection);
-
- /* Delete the bonjour group */
-- gaim_blist_remove_group(bonjour_group);
-+ gaim2_blist_remove_group(bonjour_group);
-
- }
-
- static const char *
--bonjour_list_icon(GaimAccount *account, GaimBuddy *buddy)
-+bonjour_list_icon(Gaim2Account *account, Gaim2Buddy *buddy)
- {
- return BONJOUR_ICON_NAME;
- }
-
- static int
--bonjour_send_im(GaimConnection *connection, const char *to, const char *msg, GaimMessageFlags flags)
-+bonjour_send_im(Gaim2Connection *connection, const char *to, const char *msg, Gaim2MessageFlags flags)
- {
- if(!to || !msg)
- return 0;
-@@ -195,24 +195,24 @@ bonjour_send_im(GaimConnection *connecti
- }
-
- static void
--bonjour_set_status(GaimAccount *account, GaimStatus *status)
-+bonjour_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- BonjourData *bd;
- gboolean disconnected;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- int primitive;
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- const char *message, *bonjour_status;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- bd = gc->proto_data;
-- disconnected = gaim_account_is_disconnected(account);
-- type = gaim_status_get_type(status);
-- primitive = gaim_status_type_get_primitive(type);
-- presence = gaim_account_get_presence(account);
-+ disconnected = gaim2_account_is_disconnected(account);
-+ type = gaim2_status_get_type(status);
-+ primitive = gaim2_status_type_get_primitive(type);
-+ presence = gaim2_account_get_presence(account);
-
-- message = gaim_status_get_attr_string(status, "message");
-+ message = gaim2_status_get_attr_string(status, "message");
- if (message == NULL)
- message = "";
-
-@@ -223,9 +223,9 @@ bonjour_set_status(GaimAccount *account,
- * -away ("dnd")
- * Each of them can have an optional message.
- */
-- if (gaim_presence_is_available(presence))
-+ if (gaim2_presence_is_available(presence))
- bonjour_status = "avail";
-- else if (gaim_presence_is_idle(presence))
-+ else if (gaim2_presence_is_idle(presence))
- bonjour_status = "away";
- else
- bonjour_status = "dnd";
-@@ -234,28 +234,28 @@ bonjour_set_status(GaimAccount *account,
- }
-
- static GList *
--bonjour_status_types(GaimAccount *account)
-+bonjour_status_types(Gaim2Account *account)
- {
- GList *status_types = NULL;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
- BONJOUR_STATUS_ID_AVAILABLE,
- NULL, TRUE, TRUE, FALSE,
- "message", _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ gaim2_value_new(GAIM_TYPE_STRING), NULL);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AWAY,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AWAY,
- BONJOUR_STATUS_ID_AWAY,
- NULL, TRUE, TRUE, FALSE,
- "message", _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ gaim2_value_new(GAIM_TYPE_STRING), NULL);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_OFFLINE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_OFFLINE,
- BONJOUR_STATUS_ID_OFFLINE,
- NULL, TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-@@ -264,9 +264,9 @@ bonjour_status_types(GaimAccount *accoun
- }
-
- static void
--bonjour_convo_closed(GaimConnection *connection, const char *who)
-+bonjour_convo_closed(Gaim2Connection *connection, const char *who)
- {
-- GaimBuddy *buddy = gaim_find_buddy(connection->account, who);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(connection->account, who);
-
- if (buddy == NULL)
- {
-@@ -281,50 +281,50 @@ bonjour_convo_closed(GaimConnection *con
- }
-
- static void
--bonjour_list_emblems(GaimBuddy *buddy,
-+bonjour_list_emblems(Gaim2Buddy *buddy,
- const char **se, const char **sw,
- const char **nw, const char **ne)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
-
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
-- if (gaim_presence_is_online(presence) && !gaim_presence_is_available(presence))
-+ if (gaim2_presence_is_online(presence) && !gaim2_presence_is_available(presence))
- *se = "away";
- }
-
- static char *
--bonjour_status_text(GaimBuddy *buddy)
-+bonjour_status_text(Gaim2Buddy *buddy)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
-
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
-- if (gaim_presence_is_online(presence) && !gaim_presence_is_available(presence))
-+ if (gaim2_presence_is_online(presence) && !gaim2_presence_is_available(presence))
- return g_strdup("Away");
-
- return NULL;
- }
-
- static char *
--bonjour_tooltip_text(GaimBuddy *buddy)
-+bonjour_tooltip_text(Gaim2Buddy *buddy)
- {
- GString *ret;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- const char *status_description;
- const char *message;
-
-- presence = gaim_buddy_get_presence(buddy);
-- status = gaim_presence_get_active_status(presence);
-- message = gaim_status_get_attr_string(status, "message");
--
-- if (gaim_presence_is_available(presence))
-- status_description = gaim_status_get_name(status);
-- else if (gaim_presence_is_idle(presence))
-+ presence = gaim2_buddy_get_presence(buddy);
-+ status = gaim2_presence_get_active_status(presence);
-+ message = gaim2_status_get_attr_string(status, "message");
-+
-+ if (gaim2_presence_is_available(presence))
-+ status_description = gaim2_status_get_name(status);
-+ else if (gaim2_presence_is_idle(presence))
- status_description = _("Idle");
- else
-- status_description = gaim_status_get_name(status);
-+ status_description = gaim2_status_get_name(status);
-
- ret = g_string_new("");
- g_string_append_printf(ret, _("\n<b>Status:</b> %s"), status_description);
-@@ -335,7 +335,7 @@ bonjour_tooltip_text(GaimBuddy *buddy)
- }
-
- static gboolean
--plugin_unload(GaimPlugin *plugin)
-+plugin_unload(Gaim2Plugin *plugin)
- {
- g_free(default_firstname);
- g_free(default_lastname);
-@@ -344,9 +344,9 @@ plugin_unload(GaimPlugin *plugin)
- return TRUE;
- }
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_NO_PASSWORD,
- NULL, /* user_splits */
-@@ -411,7 +411,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -460,10 +460,10 @@ initialize_default_account_values()
- else if (((fullname = getlogin()) != NULL) && (fullname[0] != '\0'))
- ;
- else
-- fullname = _("Gaim User");
-+ fullname = _("Gaim2 User");
-
- #else
-- FARPROC myNetUserGetInfo = wgaim_find_and_loadproc("Netapi32.dll",
-+ FARPROC myNetUserGetInfo = wgaim2_find_and_loadproc("Netapi32.dll",
- "NetUserGetInfo");
-
- if (myNetUserGetInfo) {
-@@ -472,9 +472,9 @@ initialize_default_account_values()
- wchar_t *servername = NULL;
- wchar_t username[UNLEN + 1] = {'\0'};
- DWORD dwLenUsername = sizeof(username);
-- FARPROC myNetServerEnum = wgaim_find_and_loadproc(
-+ FARPROC myNetServerEnum = wgaim2_find_and_loadproc(
- "Netapi32.dll", "NetServerEnum");
-- FARPROC myNetApiBufferFree = wgaim_find_and_loadproc(
-+ FARPROC myNetApiBufferFree = wgaim2_find_and_loadproc(
- "Netapi32.dll", "NetApiBufferFree");
-
- if (myNetServerEnum && myNetApiBufferFree) {
-@@ -492,12 +492,12 @@ initialize_default_account_values()
- && dwEntriesRead > 0) {
- servername = server_info->sv100_name;
- } else {
-- gaim_debug_warning("bonjour", "Unable to look up domain controller. NET_API_STATUS = %d, Entries Read = %d, Total Entries = %d\n", nStatus, dwEntriesRead, dwTotalEntries);
-+ gaim2_debug_warning("bonjour", "Unable to look up domain controller. NET_API_STATUS = %d, Entries Read = %d, Total Entries = %d\n", nStatus, dwEntriesRead, dwTotalEntries);
- }
- }
-
- if (!GetUserNameW(&username, &dwLenUsername)) {
-- gaim_debug_warning("bonjour",
-+ gaim2_debug_warning("bonjour",
- "Unable to look up username\n");
- }
-
-@@ -517,7 +517,7 @@ initialize_default_account_values()
- }
-
- if (!fullname)
-- fullname = g_strdup(_("Gaim User"));
-+ fullname = g_strdup(_("Gaim2 User"));
- #endif
-
- /* Split the real name into a first and last name */
-@@ -540,35 +540,35 @@ initialize_default_account_values()
- /* Try to figure out a good host name to use */
- /* TODO: Avoiding 'localhost,' if possible */
- if (gethostname(hostname, 255) != 0) {
-- gaim_debug_warning("bonjour", "Error %d when getting host name. Using \"localhost.\"\n", errno);
-+ gaim2_debug_warning("bonjour", "Error %d when getting host name. Using \"localhost.\"\n", errno);
- strcpy(hostname, "localhost");
- }
- default_hostname = g_strdup(hostname);
- }
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountUserSplit *split;
-- GaimAccountOption *option;
-+ Gaim2AccountUserSplit *split;
-+ Gaim2AccountOption *option;
-
- initialize_default_account_values();
-
- /* Creating the user splits */
-- split = gaim_account_user_split_new(_("Hostname"), default_hostname, '@');
-+ split = gaim2_account_user_split_new(_("Hostname"), default_hostname, '@');
- prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-
- /* Creating the options for the protocol */
-- option = gaim_account_option_int_new(_("Port"), "port", 5298);
-+ option = gaim2_account_option_int_new(_("Port"), "port", 5298);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("First name"), "first", default_firstname);
-+ option = gaim2_account_option_string_new(_("First name"), "first", default_firstname);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Last name"), "last", default_lastname);
-+ option = gaim2_account_option_string_new(_("Last name"), "last", default_lastname);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Email"), "email", "");
-+ option = gaim2_account_option_string_new(_("Email"), "email", "");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
- my_protocol = plugin;
-diff -prNu ./src/protocols/bonjour/bonjour.h ./src/protocols/bonjour/bonjour.h
---- ./src/protocols/bonjour/bonjour.h 2005-10-26 00:27:27.000000000 +0200
-+++ ./src/protocols/bonjour/bonjour.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
-- * @file bonjour.h The Gaim interface to mDNS and peer to peer Jabber.
-+ * @file bonjour.h The Gaim2 interface to mDNS and peer to peer Jabber.
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/bonjour/buddy.c ./src/protocols/bonjour/buddy.c
---- ./src/protocols/bonjour/buddy.c 2005-09-14 04:58:30.000000000 +0200
-+++ ./src/protocols/bonjour/buddy.c 2006-01-05 15:11:07.000000000 +0100
-@@ -85,14 +85,14 @@ bonjour_buddy_check(BonjourBuddy *buddy)
- * the buddy.
- */
- void
--bonjour_buddy_add_to_gaim(GaimAccount *account, BonjourBuddy *bonjour_buddy)
-+bonjour_buddy_add_to_gaim2(Gaim2Account *account, BonjourBuddy *bonjour_buddy)
- {
-- GaimBuddy *buddy;
-- GaimGroup *group;
-+ Gaim2Buddy *buddy;
-+ Gaim2Group *group;
- const char *status_id, *first, *last;
- char *alias;
-
-- /* Translate between the Bonjour status and the Gaim status */
-+ /* Translate between the Bonjour status and the Gaim2 status */
- if (g_ascii_strcasecmp("dnd", bonjour_buddy->status) == 0)
- status_id = BONJOUR_STATUS_ID_AWAY;
- else
-@@ -112,32 +112,32 @@ bonjour_buddy_add_to_gaim(GaimAccount *a
- (last && *last ? last : ""));
-
- /* Make sure the Bonjour group exists in our buddy list */
-- group = gaim_find_group(BONJOUR_GROUP_NAME); /* Use the buddy's domain, instead? */
-+ group = gaim2_find_group(BONJOUR_GROUP_NAME); /* Use the buddy's domain, instead? */
- if (group == NULL)
- {
-- group = gaim_group_new(BONJOUR_GROUP_NAME);
-- gaim_blist_add_group(group, NULL);
-+ group = gaim2_group_new(BONJOUR_GROUP_NAME);
-+ gaim2_blist_add_group(group, NULL);
- }
-
- /* Make sure the buddy exists in our buddy list */
-- buddy = gaim_find_buddy(account, bonjour_buddy->name);
-+ buddy = gaim2_find_buddy(account, bonjour_buddy->name);
- if (buddy == NULL)
- {
-- buddy = gaim_buddy_new(account, bonjour_buddy->name, alias);
-+ buddy = gaim2_buddy_new(account, bonjour_buddy->name, alias);
- buddy->proto_data = bonjour_buddy;
-- gaim_blist_node_set_flags((GaimBlistNode *)buddy, GAIM_BLIST_NODE_FLAG_NO_SAVE);
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-+ gaim2_blist_node_set_flags((Gaim2BlistNode *)buddy, GAIM_BLIST_NODE_FLAG_NO_SAVE);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
- }
-
- /* Set the user's status */
- if (bonjour_buddy->msg != NULL)
-- gaim_prpl_got_user_status(account, buddy->name, status_id,
-+ gaim2_prpl_got_user_status(account, buddy->name, status_id,
- "message", bonjour_buddy->msg,
- NULL);
- else
-- gaim_prpl_got_user_status(account, buddy->name, status_id,
-+ gaim2_prpl_got_user_status(account, buddy->name, status_id,
- NULL);
-- gaim_prpl_got_user_idle(account, buddy->name, FALSE, 0);
-+ gaim2_prpl_got_user_idle(account, buddy->name, FALSE, 0);
-
- g_free(alias);
- }
-diff -prNu ./src/protocols/bonjour/buddy.h ./src/protocols/bonjour/buddy.h
---- ./src/protocols/bonjour/buddy.h 2005-09-14 04:58:30.000000000 +0200
-+++ ./src/protocols/bonjour/buddy.h 2006-01-05 15:11:21.000000000 +0100
-@@ -55,7 +55,7 @@ gboolean bonjour_buddy_check(BonjourBudd
- /**
- * If the buddy doesn't previoulsy exists, it is created. Else, its data is changed (???)
- */
--void bonjour_buddy_add_to_gaim(GaimAccount *account, BonjourBuddy *buddy);
-+void bonjour_buddy_add_to_gaim2(Gaim2Account *account, BonjourBuddy *buddy);
-
- /**
- * Deletes a buddy from memory.
-diff -prNu ./src/protocols/bonjour/dns_sd.c ./src/protocols/bonjour/dns_sd.c
---- ./src/protocols/bonjour/dns_sd.c 2005-11-15 06:04:30.000000000 +0100
-+++ ./src/protocols/bonjour/dns_sd.c 2006-01-05 15:11:07.000000000 +0100
-@@ -48,22 +48,22 @@ static sw_result HOWL_API
- _publish_reply(sw_discovery discovery, sw_discovery_oid oid,
- sw_discovery_publish_status status, sw_opaque extra)
- {
-- gaim_debug_warning("bonjour", "_publish_reply --> Start\n");
-+ gaim2_debug_warning("bonjour", "_publish_reply --> Start\n");
-
- /* Check the answer from the mDNS daemon */
- switch (status)
- {
- case SW_DISCOVERY_PUBLISH_STARTED :
-- gaim_debug_info("bonjour", "_publish_reply --> Service started\n");
-+ gaim2_debug_info("bonjour", "_publish_reply --> Service started\n");
- break;
- case SW_DISCOVERY_PUBLISH_STOPPED :
-- gaim_debug_info("bonjour", "_publish_reply --> Service stopped\n");
-+ gaim2_debug_info("bonjour", "_publish_reply --> Service stopped\n");
- break;
- case SW_DISCOVERY_PUBLISH_NAME_COLLISION :
-- gaim_debug_info("bonjour", "_publish_reply --> Name collision\n");
-+ gaim2_debug_info("bonjour", "_publish_reply --> Name collision\n");
- break;
- case SW_DISCOVERY_PUBLISH_INVALID :
-- gaim_debug_info("bonjour", "_publish_reply --> Service invalid\n");
-+ gaim2_debug_info("bonjour", "_publish_reply --> Service invalid\n");
- break;
- }
-
-@@ -79,7 +79,7 @@ _resolve_reply(sw_discovery discovery, s
- sw_opaque extra)
- {
- BonjourBuddy *buddy;
-- GaimAccount *account = (GaimAccount*)extra;
-+ Gaim2Account *account = (Gaim2Account*)extra;
- gchar *txtvers = NULL;
- gchar *version = NULL;
- gchar *first = NULL;
-@@ -152,7 +152,7 @@ _resolve_reply(sw_discovery discovery, s
- }
-
- /* Add or update the buddy in our buddy list */
-- bonjour_buddy_add_to_gaim(account, buddy);
-+ bonjour_buddy_add_to_gaim2(account, buddy);
-
- /* Free all the temporal strings */
- g_free(txtvers);
-@@ -178,49 +178,49 @@ _browser_reply(sw_discovery discovery, s
- sw_opaque_t extra)
- {
- sw_discovery_resolve_id rid;
-- GaimAccount *account = (GaimAccount*)extra;
-- GaimBuddy *gb = NULL;
-+ Gaim2Account *account = (Gaim2Account*)extra;
-+ Gaim2Buddy *gb = NULL;
-
- switch (status)
- {
- case SW_DISCOVERY_BROWSE_INVALID:
-- gaim_debug_warning("bonjour", "_browser_reply --> Invalid\n");
-+ gaim2_debug_warning("bonjour", "_browser_reply --> Invalid\n");
- break;
- case SW_DISCOVERY_BROWSE_RELEASE:
-- gaim_debug_warning("bonjour", "_browser_reply --> Release\n");
-+ gaim2_debug_warning("bonjour", "_browser_reply --> Release\n");
- break;
- case SW_DISCOVERY_BROWSE_ADD_DOMAIN:
-- gaim_debug_warning("bonjour", "_browser_reply --> Add domain\n");
-+ gaim2_debug_warning("bonjour", "_browser_reply --> Add domain\n");
- break;
- case SW_DISCOVERY_BROWSE_ADD_DEFAULT_DOMAIN:
-- gaim_debug_warning("bonjour", "_browser_reply --> Add default domain\n");
-+ gaim2_debug_warning("bonjour", "_browser_reply --> Add default domain\n");
- break;
- case SW_DISCOVERY_BROWSE_REMOVE_DOMAIN:
-- gaim_debug_warning("bonjour", "_browser_reply --> Remove domain\n");
-+ gaim2_debug_warning("bonjour", "_browser_reply --> Remove domain\n");
- break;
- case SW_DISCOVERY_BROWSE_ADD_SERVICE:
- /* A new peer has join the network and uses iChat bonjour */
-- gaim_debug_info("bonjour", "_browser_reply --> Add service\n");
-+ gaim2_debug_info("bonjour", "_browser_reply --> Add service\n");
- if (g_ascii_strcasecmp(name, account->username) != 0)
- {
- if (sw_discovery_resolve(discovery, interface_index, name, type,
- domain, _resolve_reply, extra, &rid) != SW_OKAY)
- {
-- gaim_debug_warning("bonjour", "_browser_reply --> Cannot send resolve\n");
-+ gaim2_debug_warning("bonjour", "_browser_reply --> Cannot send resolve\n");
- }
- }
- break;
- case SW_DISCOVERY_BROWSE_REMOVE_SERVICE:
-- gaim_debug_info("bonjour", "_browser_reply --> Remove service\n");
-- gb = gaim_find_buddy((GaimAccount*)extra, name);
-+ gaim2_debug_info("bonjour", "_browser_reply --> Remove service\n");
-+ gb = gaim2_find_buddy((Gaim2Account*)extra, name);
- if (gb != NULL)
- {
- bonjour_buddy_delete(gb->proto_data);
-- gaim_blist_remove_buddy(gb);
-+ gaim2_blist_remove_buddy(gb);
- }
- break;
- case SW_DISCOVERY_BROWSE_RESOLVED:
-- gaim_debug_info("bonjour", "_browse_reply --> Resolved\n");
-+ gaim2_debug_info("bonjour", "_browse_reply --> Resolved\n");
- break;
- default:
- break;
-@@ -238,7 +238,7 @@ _dns_sd_publish(BonjourDnsSd *data, Publ
- /* Fill the data for the service */
- if (sw_text_record_init(&dns_data) != SW_OKAY)
- {
-- gaim_debug_error("bonjour", "Unable to initialize the data for the mDNS.\n");
-+ gaim2_debug_error("bonjour", "Unable to initialize the data for the mDNS.\n");
- return -1;
- }
-
-@@ -271,7 +271,7 @@ _dns_sd_publish(BonjourDnsSd *data, Publ
- }
- if (publish_result != SW_OKAY)
- {
-- gaim_debug_error("bonjour", "Unable to publish or change the status of the _presence._tcp service.");
-+ gaim2_debug_error("bonjour", "Unable to publish or change the status of the _presence._tcp service.");
- return -1;
- }
-
-@@ -282,7 +282,7 @@ _dns_sd_publish(BonjourDnsSd *data, Publ
- }
-
- static void
--_dns_sd_handle_packets(gpointer data, gint source, GaimInputCondition condition)
-+_dns_sd_handle_packets(gpointer data, gint source, Gaim2InputCondition condition)
- {
- sw_discovery_read_socket((sw_discovery)data);
- }
-@@ -335,18 +335,18 @@ bonjour_dns_sd_send_status(BonjourDnsSd
- gboolean
- bonjour_dns_sd_start(BonjourDnsSd *data)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- gint dns_sd_socket;
- sw_discovery_oid session_id;
-
- account = data->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- /* Initialize the dns-sd data and session */
- if (sw_discovery_init(&data->session) != SW_OKAY)
- {
-- gaim_debug_error("bonjour", "Unable to initialize an mDNS session.\n");
-+ gaim2_debug_error("bonjour", "Unable to initialize an mDNS session.\n");
- return FALSE;
- }
-
-@@ -357,14 +357,14 @@ bonjour_dns_sd_start(BonjourDnsSd *data)
- if (sw_discovery_browse(data->session, 0, ICHAT_SERVICE, NULL, _browser_reply,
- data->account, &session_id) != SW_OKAY)
- {
-- gaim_debug_error("bonjour", "Unable to get service.");
-+ gaim2_debug_error("bonjour", "Unable to get service.");
- return FALSE;
- }
-
- /* Get the socket that communicates with the mDNS daemon and bind it to a */
- /* callback that will handle the dns_sd packets */
- dns_sd_socket = sw_discovery_socket(data->session);
-- gc->inpa = gaim_input_add(dns_sd_socket, GAIM_INPUT_READ,
-+ gc->inpa = gaim2_input_add(dns_sd_socket, GAIM_INPUT_READ,
- _dns_sd_handle_packets, data->session);
-
- return TRUE;
-@@ -376,8 +376,8 @@ bonjour_dns_sd_start(BonjourDnsSd *data)
- void
- bonjour_dns_sd_stop(BonjourDnsSd *data)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-
- if (data->session == NULL)
- return;
-@@ -385,8 +385,8 @@ bonjour_dns_sd_stop(BonjourDnsSd *data)
- sw_discovery_cancel(data->session, data->session_id);
-
- account = data->account;
-- gc = gaim_account_get_connection(account);
-- gaim_input_remove(gc->inpa);
-+ gc = gaim2_account_get_connection(account);
-+ gaim2_input_remove(gc->inpa);
-
- g_free(data->session);
- data->session = NULL;
-diff -prNu ./src/protocols/bonjour/dns_sd.h ./src/protocols/bonjour/dns_sd.h
---- ./src/protocols/bonjour/dns_sd.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/protocols/bonjour/dns_sd.h 2006-01-05 15:11:21.000000000 +0100
-@@ -32,7 +32,7 @@ typedef struct _BonjourDnsSd
- {
- sw_discovery session;
- sw_discovery_oid session_id;
-- GaimAccount *account;
-+ Gaim2Account *account;
- gchar *name;
- gchar *txtvers;
- gchar *version;
-diff -prNu ./src/protocols/bonjour/jabber.c ./src/protocols/bonjour/jabber.c
---- ./src/protocols/bonjour/jabber.c 2006-01-05 06:29:51.000000000 +0100
-+++ ./src/protocols/bonjour/jabber.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim - Bonjour Protocol Plugin
-+ * gaim2 - Bonjour Protocol Plugin
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -46,7 +46,7 @@
- #include "buddy.h"
-
- static gint
--_connect_to_buddy(GaimBuddy *gb)
-+_connect_to_buddy(Gaim2Buddy *gb)
- {
- gint socket_fd;
- gint retorno = 0;
-@@ -62,7 +62,7 @@ _connect_to_buddy(GaimBuddy *gb)
-
- retorno = connect(socket_fd, (struct sockaddr*)&buddy_address, sizeof(struct sockaddr));
- if (retorno == -1) {
-- gaim_debug_warning("bonjour", "connect error: %s\n", strerror(errno));
-+ gaim2_debug_warning("bonjour", "connect error: %s\n", strerror(errno));
- }
- fcntl(socket_fd, F_SETFL, O_NONBLOCK);
-
-@@ -71,7 +71,7 @@ _connect_to_buddy(GaimBuddy *gb)
-
- #if 0 /* this isn't used anywhere... */
- static const char *
--_font_size_gaim_to_ichat(int size)
-+_font_size_gaim2_to_ichat(int size)
- {
- switch (size) {
- case 1:
-@@ -95,7 +95,7 @@ _font_size_gaim_to_ichat(int size)
- #endif
-
- static const char *
--_font_size_ichat_to_gaim(int size)
-+_font_size_ichat_to_gaim2(int size)
- {
- if (size > 24) {
- return "7";
-@@ -114,7 +114,7 @@ _font_size_ichat_to_gaim(int size)
- return "1";
- }
- static void
--_jabber_parse_and_write_message_to_ui(char *message, GaimConnection *connection, GaimBuddy *gb)
-+_jabber_parse_and_write_message_to_ui(char *message, Gaim2Connection *connection, Gaim2Buddy *gb)
- {
- xmlnode *body_node = NULL;
- char *body = NULL;
-@@ -163,13 +163,13 @@ _jabber_parse_and_write_message_to_ui(ch
- font_size = xmlnode_get_attrib(html_body_font_node, "ABSZ");
- if (font_size != NULL)
- {
-- font_size = _font_size_ichat_to_gaim(atoi(font_size));
-+ font_size = _font_size_ichat_to_gaim2(atoi(font_size));
- }
- font_color = xmlnode_get_attrib(html_body_font_node, "color");
- html_body = xmlnode_get_data(html_body_font_node);
- if (html_body == NULL)
- {
-- /* This is the kind of formated messages that Gaim creates */
-+ /* This is the kind of formated messages that Gaim2 creates */
- html_body = xmlnode_to_str(html_body_font_node, &garbage);
- }
- } else {
-@@ -220,13 +220,13 @@ _jabber_parse_and_write_message_to_ui(ch
-
- struct _check_buddy_by_address_t {
- char *address;
-- GaimBuddy **gb;
-+ Gaim2Buddy **gb;
- };
-
- static void
- _check_buddy_by_address(gpointer key, gpointer value, gpointer data)
- {
-- GaimBuddy *gb = (GaimBuddy*)value;
-+ Gaim2Buddy *gb = (Gaim2Buddy*)value;
- BonjourBuddy *bb = (BonjourBuddy*)gb->proto_data;
- struct _check_buddy_by_address_t *d = (struct _check_buddy_by_address_t *)data;
-
-@@ -253,7 +253,7 @@ _read_data(gint socket, char **message)
-
- if (parcial_message_length == -1)
- {
-- gaim_debug_warning("bonjour", "receive error: %s\n", strerror(errno));
-+ gaim2_debug_warning("bonjour", "receive error: %s\n", strerror(errno));
- if (total_message_length == 0) {
- return -1;
- }
-@@ -262,7 +262,7 @@ _read_data(gint socket, char **message)
- *message = data->str;
- g_string_free(data, FALSE);
- if (total_message_length != 0)
-- gaim_debug_info("bonjour", "Receive: -%s- %d bytes\n", *message, total_message_length);
-+ gaim2_debug_info("bonjour", "Receive: -%s- %d bytes\n", *message, total_message_length);
-
- return total_message_length;
- }
-@@ -288,13 +288,13 @@ _send_data(gint socket, char *message)
- }
-
- static void
--_client_socket_handler(gpointer data, gint socket, GaimInputCondition condition)
-+_client_socket_handler(gpointer data, gint socket, Gaim2InputCondition condition)
- {
- char *message = NULL;
- gint message_length;
-- GaimBuddy *gb = (GaimBuddy*)data;
-- GaimAccount *account = gb->account;
-- GaimConversation *conversation;
-+ Gaim2Buddy *gb = (Gaim2Buddy*)data;
-+ Gaim2Account *account = gb->account;
-+ Gaim2Conversation *conversation;
- char *closed_conv_message;
- BonjourBuddy *bb = (BonjourBuddy*)gb->proto_data;
- gboolean closed_conversation = FALSE;
-@@ -334,7 +334,7 @@ _client_socket_handler(gpointer data, gi
- /* If we haven't done it yet, we have to sent the start of the stream to the other buddy */
- if (!(bb->conversation->stream_started)) {
- if (send(bb->conversation->socket, DOCTYPE, strlen(DOCTYPE), 0) == -1) {
-- gaim_debug_error("bonjour", "Unable to start a conversation with %s\n", bb->name);
-+ gaim2_debug_error("bonjour", "Unable to start a conversation with %s\n", bb->name);
- }
- }
- }
-@@ -346,16 +346,16 @@ _client_socket_handler(gpointer data, gi
- /* Close the socket, clear the watcher and free memory */
- if (bb->conversation != NULL) {
- close(bb->conversation->socket);
-- gaim_input_remove(bb->conversation->watcher_id);
-+ gaim2_input_remove(bb->conversation->watcher_id);
- g_free(bb->conversation->buddy_name);
- g_free(bb->conversation);
- bb->conversation = NULL;
- }
-
- /* Inform the user that the conversation has been closed */
-- conversation = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, gb->name, account);
-+ conversation = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, gb->name, account);
- closed_conv_message = g_strconcat(gb->name, " has closed the conversation.", NULL);
-- gaim_conversation_write(conversation, NULL, closed_conv_message, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conversation, NULL, closed_conv_message, GAIM_MESSAGE_SYSTEM, time(NULL));
- } else {
- /* Parse the message to get the data and send to the ui */
- _jabber_parse_and_write_message_to_ui(message, account->gc, gb);
-@@ -363,15 +363,15 @@ _client_socket_handler(gpointer data, gi
- }
-
- static void
--_server_socket_handler(gpointer data, int server_socket, GaimInputCondition condition)
-+_server_socket_handler(gpointer data, int server_socket, Gaim2InputCondition condition)
- {
-- GaimBuddy *gb = NULL;
-+ Gaim2Buddy *gb = NULL;
- struct sockaddr_in their_addr; /* connector's address information */
- socklen_t sin_size = sizeof(struct sockaddr);
- int client_socket;
- BonjourBuddy *bb = NULL;
- char *address_text = NULL;
-- GaimBuddyList *bl = gaim_get_blist();
-+ Gaim2BuddyList *bl = gaim2_get_blist();
- struct _check_buddy_by_address_t *cbba;
-
- /* Check that it is a read condition */
-@@ -394,7 +394,7 @@ _server_socket_handler(gpointer data, in
- g_free(cbba);
- if (gb == NULL)
- {
-- gaim_debug_info("bonjour", "We don't like invisible buddies, this is not a superheros comic\n");
-+ gaim2_debug_info("bonjour", "We don't like invisible buddies, this is not a superheros comic\n");
- close(client_socket);
- return;
- }
-@@ -418,7 +418,7 @@ _server_socket_handler(gpointer data, in
- }
-
- /* Open a watcher for the client socket */
-- bb->conversation->watcher_id = gaim_input_add(client_socket, GAIM_INPUT_READ,
-+ bb->conversation->watcher_id = gaim2_input_add(client_socket, GAIM_INPUT_READ,
- _client_socket_handler, gb);
- } else {
- close(client_socket);
-@@ -435,20 +435,20 @@ bonjour_jabber_start(BonjourJabber *data
- /* Open a listening socket for incoming conversations */
- if ((data->socket = socket(PF_INET, SOCK_STREAM, 0)) < 0)
- {
-- gaim_debug_error("bonjour", "Cannot get socket\n");
-+ gaim2_debug_error("bonjour", "Cannot get socket\n");
- error_message = strerror(errno);
-- gaim_debug_error("bonjour", "%s\n", error_message);
-- gaim_connection_error(data->account->gc, "Cannot open socket");
-+ gaim2_debug_error("bonjour", "%s\n", error_message);
-+ gaim2_connection_error(data->account->gc, "Cannot open socket");
- return -1;
- }
-
- /* Make the socket reusable */
- if (setsockopt(data->socket, SOL_SOCKET, SO_REUSEADDR, &yes, sizeof(int)) != 0)
- {
-- gaim_debug_error("bonjour", "Cannot make socket reusable\n");
-+ gaim2_debug_error("bonjour", "Cannot make socket reusable\n");
- error_message = strerror(errno);
-- gaim_debug_error("bonjour", "%s\n", error_message);
-- gaim_connection_error(data->account->gc, "Error setting socket options");
-+ gaim2_debug_error("bonjour", "%s\n", error_message);
-+ gaim2_connection_error(data->account->gc, "Error setting socket options");
- return -1;
- }
-
-@@ -458,34 +458,34 @@ bonjour_jabber_start(BonjourJabber *data
-
- if (bind(data->socket, (struct sockaddr*)&my_addr, sizeof(struct sockaddr)) != 0)
- {
-- gaim_debug_error("bonjour", "Cannot bind socket\n");
-+ gaim2_debug_error("bonjour", "Cannot bind socket\n");
- error_message = strerror(errno);
-- gaim_debug_error("bonjour", "%s\n", error_message);
-- gaim_connection_error(data->account->gc, "Cannot bind socket to port");
-+ gaim2_debug_error("bonjour", "%s\n", error_message);
-+ gaim2_connection_error(data->account->gc, "Cannot bind socket to port");
- return -1;
- }
-
- if (listen(data->socket, 10) != 0)
- {
-- gaim_debug_error("bonjour", "Cannot listen to socket\n");
-+ gaim2_debug_error("bonjour", "Cannot listen to socket\n");
- error_message = strerror(errno);
-- gaim_debug_error("bonjour", "%s\n", error_message);
-- gaim_connection_error(data->account->gc, "Cannot listen to socket");
-+ gaim2_debug_error("bonjour", "%s\n", error_message);
-+ gaim2_connection_error(data->account->gc, "Cannot listen to socket");
- return -1;
- }
-
- #if 0
- /* TODO: Why isn't this being used? */
-- data->socket = gaim_network_listen(data->port, SOCK_STREAM);
-+ data->socket = gaim2_network_listen(data->port, SOCK_STREAM);
-
- if (data->socket == -1)
- {
-- gaim_debug_error("bonjour", "No se ha podido crear el socket\n");
-+ gaim2_debug_error("bonjour", "No se ha podido crear el socket\n");
- }
- #endif
-
- /* Open a watcher in the socket we have just opened */
-- data->watcher_id = gaim_input_add(data->socket, GAIM_INPUT_READ, _server_socket_handler, data);
-+ data->watcher_id = gaim2_input_add(data->socket, GAIM_INPUT_READ, _server_socket_handler, data);
-
- return 0;
- }
-@@ -501,14 +501,14 @@ bonjour_jabber_send_message(BonjourJabbe
- xmlnode *message_html_body_node = NULL;
- xmlnode *message_html_body_font_node = NULL;
- xmlnode *message_x_node = NULL;
-- GaimBuddy *gb = NULL;
-+ Gaim2Buddy *gb = NULL;
- BonjourBuddy *bb = NULL;
- char *conv_message = NULL;
-- GaimConversation *conversation = NULL;
-+ Gaim2Conversation *conversation = NULL;
- char *message_from_ui = NULL;
- char *stripped_message = NULL;
-
-- gb = gaim_find_buddy(data->account, to);
-+ gb = gaim2_find_buddy(data->account, to);
- if (gb == NULL)
- /* You can not send a message to an offline buddy */
- return -10000;
-@@ -517,7 +517,7 @@ bonjour_jabber_send_message(BonjourJabbe
-
- /* Enclose the message from the UI within a "font" node */
- message_body_node = xmlnode_new("body");
-- stripped_message = gaim_markup_strip_html(body);
-+ stripped_message = gaim2_markup_strip_html(body);
- xmlnode_insert_data(message_body_node, stripped_message, strlen(stripped_message));
-
- message_from_ui = g_strconcat("<font>", body, "</font>", NULL);
-@@ -552,7 +552,7 @@ bonjour_jabber_send_message(BonjourJabbe
- bb->conversation->start_step_two = FALSE;
- bb->conversation->stream_started = FALSE;
- bb->conversation->buddy_name = g_strdup(gb->name);
-- bb->conversation->watcher_id = gaim_input_add(bb->conversation->socket,
-+ bb->conversation->watcher_id = gaim2_input_add(bb->conversation->socket,
- GAIM_INPUT_READ, _client_socket_handler, gb);
- }
-
-@@ -562,13 +562,13 @@ bonjour_jabber_send_message(BonjourJabbe
- /* Start the stream */
- if (send(bb->conversation->socket, DOCTYPE, strlen(DOCTYPE), 0) == -1)
- {
-- gaim_debug_error("bonjour", "Unable to start a conversation\n");
-- gaim_debug_warning("bonjour", "send error: %s\n", strerror(errno));
-+ gaim2_debug_error("bonjour", "Unable to start a conversation\n");
-+ gaim2_debug_warning("bonjour", "send error: %s\n", strerror(errno));
- conv_message = g_strdup("Unable to send the message, the conversation couldn't be started.");
-- conversation = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, bb->name, data->account);
-- gaim_conversation_write(conversation, NULL, conv_message, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ conversation = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, bb->name, data->account);
-+ gaim2_conversation_write(conversation, NULL, conv_message, GAIM_MESSAGE_SYSTEM, time(NULL));
- close(bb->conversation->socket);
-- gaim_input_remove(bb->conversation->watcher_id);
-+ gaim2_input_remove(bb->conversation->watcher_id);
-
- /* Free all the data related to the conversation */
- g_free(bb->conversation->buddy_name);
-@@ -588,7 +588,7 @@ bonjour_jabber_send_message(BonjourJabbe
- }
-
- void
--bonjour_jabber_close_conversation(BonjourJabber *data, GaimBuddy *gb)
-+bonjour_jabber_close_conversation(BonjourJabber *data, Gaim2Buddy *gb)
- {
- BonjourBuddy *bb = (BonjourBuddy*)gb->proto_data;
-
-@@ -599,7 +599,7 @@ bonjour_jabber_close_conversation(Bonjou
-
- /* Close the socket and remove the watcher */
- close(bb->conversation->socket);
-- gaim_input_remove(bb->conversation->watcher_id);
-+ gaim2_input_remove(bb->conversation->watcher_id);
-
- /* Free all the data related to the conversation */
- g_free(bb->conversation->buddy_name);
-@@ -611,28 +611,28 @@ bonjour_jabber_close_conversation(Bonjou
- void
- bonjour_jabber_stop(BonjourJabber *data)
- {
-- GaimBuddy *gb = NULL;
-+ Gaim2Buddy *gb = NULL;
- BonjourBuddy *bb = NULL;
- GSList *buddies;
- GSList *l;
-
- /* Close the server socket and remove all the watcher */
- close(data->socket);
-- gaim_input_remove(data->watcher_id);
-+ gaim2_input_remove(data->watcher_id);
-
- /* Close all the sockets and remove all the watchers after sending end streams */
- if (data->account->gc != NULL)
- {
-- buddies = gaim_find_buddies(data->account, data->account->username);
-+ buddies = gaim2_find_buddies(data->account, data->account->username);
- for (l = buddies; l; l = l->next)
- {
-- gb = (GaimBuddy*)l->data;
-+ gb = (Gaim2Buddy*)l->data;
- bb = (BonjourBuddy*)gb->proto_data;
- if (bb->conversation != NULL)
- {
- send(bb->conversation->socket, STREAM_END, strlen(STREAM_END), 0);
- close(bb->conversation->socket);
-- gaim_input_remove(bb->conversation->watcher_id);
-+ gaim2_input_remove(bb->conversation->watcher_id);
- }
- }
- g_slist_free(buddies);
-diff -prNu ./src/protocols/bonjour/jabber.h ./src/protocols/bonjour/jabber.h
---- ./src/protocols/bonjour/jabber.h 2005-11-05 21:45:35.000000000 +0100
-+++ ./src/protocols/bonjour/jabber.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
-- * @file jabber.h The Gaim interface to mDNS and peer to peer Jabber.
-+ * @file jabber.h The Gaim2 interface to mDNS and peer to peer Jabber.
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -39,7 +39,7 @@ typedef struct _BonjourJabber
- gint port;
- gint socket;
- gint watcher_id;
-- GaimAccount* account;
-+ Gaim2Account* account;
- } BonjourJabber;
-
- typedef struct _BonjourJabberConversation
-@@ -61,7 +61,7 @@ gint bonjour_jabber_start(BonjourJabber
-
- int bonjour_jabber_send_message(BonjourJabber *data, const gchar *to, const gchar *body);
-
--void bonjour_jabber_close_conversation(BonjourJabber *data, GaimBuddy *gb);
-+void bonjour_jabber_close_conversation(BonjourJabber *data, Gaim2Buddy *gb);
-
- void bonjour_jabber_stop(BonjourJabber *data);
-
-diff -prNu ./src/protocols/bonjour/Makefile.am ./src/protocols/bonjour/Makefile.am
---- ./src/protocols/bonjour/Makefile.am 2005-11-03 14:43:04.000000000 +0100
-+++ ./src/protocols/bonjour/Makefile.am 2006-01-05 13:02:43.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- BONJOURSOURCES = \
- bonjour.c \
-diff -prNu ./src/protocols/gg/buddylist.c ./src/protocols/gg/buddylist.c
---- ./src/protocols/gg/buddylist.c 2005-11-08 20:45:09.000000000 +0100
-+++ ./src/protocols/gg/buddylist.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file buddylist.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -28,20 +28,20 @@
- #include "buddylist.h"
-
-
--/* void ggp_buddylist_send(GaimConnection *gc) {{{ */
--void ggp_buddylist_send(GaimConnection *gc)
-+/* void ggp_buddylist_send(Gaim2Connection *gc) {{{ */
-+void ggp_buddylist_send(Gaim2Connection *gc)
- {
- GGPInfo *info = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-
-- GaimBuddyList *blist;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *buddy;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *buddy;
- uin_t *userlist = NULL;
- gchar *types = NULL;
- int size = 0;
-
-- if ((blist = gaim_get_blist()) == NULL)
-+ if ((blist = gaim2_get_blist()) == NULL)
- return;
-
- for (gnode = blist->root; gnode != NULL; gnode = gnode->next) {
-@@ -56,7 +56,7 @@ void ggp_buddylist_send(GaimConnection *
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
-
- if (buddy->account != account)
- continue;
-@@ -66,7 +66,7 @@ void ggp_buddylist_send(GaimConnection *
- types = (gchar *) g_renew(gchar, types, size);
- userlist[size - 1] = ggp_str_to_uin(buddy->name);
- types[size - 1] = GG_USER_NORMAL;
-- gaim_debug_info("gg", "ggp_buddylist_send: adding %d\n",
-+ gaim2_debug_info("gg", "ggp_buddylist_send: adding %d\n",
- userlist[size - 1]);
- }
- }
-@@ -77,16 +77,16 @@ void ggp_buddylist_send(GaimConnection *
- g_free(userlist);
- g_free(types);
-
-- gaim_debug_info("gg", "send: ret=%d; size=%d\n", ret, size);
-+ gaim2_debug_info("gg", "send: ret=%d; size=%d\n", ret, size);
- }
- }
- /* }}} */
-
--/* void ggp_buddylist_load(GaimConnection *gc, char *buddylist) {{{ */
--void ggp_buddylist_load(GaimConnection *gc, char *buddylist)
-+/* void ggp_buddylist_load(Gaim2Connection *gc, char *buddylist) {{{ */
-+void ggp_buddylist_load(Gaim2Connection *gc, char *buddylist)
- {
-- GaimBuddy *buddy;
-- GaimGroup *group;
-+ Gaim2Buddy *buddy;
-+ Gaim2Group *group;
- gchar **users_tbl;
- int i;
-
-@@ -107,9 +107,9 @@ void ggp_buddylist_load(GaimConnection *
- show = charset_convert(data_tbl[3], "CP1250", "UTF-8");
- name = data_tbl[6];
-
-- gaim_debug_info("gg", "got buddy: name=%s show=%s\n", name, show);
-+ gaim2_debug_info("gg", "got buddy: name=%s show=%s\n", name, show);
-
-- if (gaim_find_buddy(gaim_connection_get_account(gc), name)) {
-+ if (gaim2_find_buddy(gaim2_connection_get_account(gc), name)) {
- g_free(show);
- g_strfreev(data_tbl);
- continue;
-@@ -127,15 +127,15 @@ void ggp_buddylist_load(GaimConnection *
- g_strfreev(group_tbl);
- }
-
-- buddy = gaim_buddy_new(gaim_connection_get_account(gc), name,
-+ buddy = gaim2_buddy_new(gaim2_connection_get_account(gc), name,
- strlen(show) ? show : NULL);
-
-- if (!(group = gaim_find_group(g))) {
-- group = gaim_group_new(g);
-- gaim_blist_add_group(group, NULL);
-+ if (!(group = gaim2_find_group(g))) {
-+ group = gaim2_group_new(g);
-+ gaim2_blist_add_group(group, NULL);
- }
-
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
- g_free(g);
-
- g_free(show);
-@@ -148,15 +148,15 @@ void ggp_buddylist_load(GaimConnection *
- }
- /* }}} */
-
--/* void ggp_buddylist_offline(GaimConnection *gc) {{{ */
--void ggp_buddylist_offline(GaimConnection *gc)
-+/* void ggp_buddylist_offline(Gaim2Connection *gc) {{{ */
-+void ggp_buddylist_offline(Gaim2Connection *gc)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimBuddyList *blist;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *buddy;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *buddy;
-
-- if ((blist = gaim_get_blist()) == NULL)
-+ if ((blist = gaim2_get_blist()) == NULL)
- return;
-
- for (gnode = blist->root; gnode != NULL; gnode = gnode->next) {
-@@ -171,16 +171,16 @@ void ggp_buddylist_offline(GaimConnectio
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
-
- if (buddy->account != account)
- continue;
-
-- gaim_prpl_got_user_status(
-- gaim_connection_get_account(gc),
-+ gaim2_prpl_got_user_status(
-+ gaim2_connection_get_account(gc),
- buddy->name, "offline", NULL);
-
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "ggp_buddylist_offline: gone: %s\n",
- buddy->name);
- }
-@@ -189,25 +189,25 @@ void ggp_buddylist_offline(GaimConnectio
- }
- /* }}} */
-
--/* char *ggp_buddylist_dump(GaimAccount *account) {{{ */
--char *ggp_buddylist_dump(GaimAccount *account)
-+/* char *ggp_buddylist_dump(Gaim2Account *account) {{{ */
-+char *ggp_buddylist_dump(Gaim2Account *account)
- {
-- GaimBuddyList *blist;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimGroup *group;
-- GaimBuddy *buddy;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Group *group;
-+ Gaim2Buddy *buddy;
-
- char *buddylist = g_strdup("");
- char *ptr;
-
-- if ((blist = gaim_get_blist()) == NULL)
-+ if ((blist = gaim2_get_blist()) == NULL)
- return NULL;
-
- for (gnode = blist->root; gnode != NULL; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-
-- group = (GaimGroup *)gnode;
-+ group = (Gaim2Group *)gnode;
-
- for (cnode = gnode->child; cnode != NULL; cnode = cnode->next) {
- if (!GAIM_BLIST_NODE_IS_CONTACT(cnode))
-@@ -220,7 +220,7 @@ char *ggp_buddylist_dump(GaimAccount *ac
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
- if (buddy->account != account)
- continue;
-
-diff -prNu ./src/protocols/gg/buddylist.h ./src/protocols/gg/buddylist.h
---- ./src/protocols/gg/buddylist.h 2005-11-08 20:45:09.000000000 +0100
-+++ ./src/protocols/gg/buddylist.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file buddylist.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -28,17 +28,17 @@
- #include "account.h"
-
- void
--ggp_buddylist_send(GaimConnection *gc);
-+ggp_buddylist_send(Gaim2Connection *gc);
-
- /**
- * Load buddylist from server into the rooster.
- *
-- * @param gc GaimConnection
-+ * @param gc Gaim2Connection
- * @param buddylist Pointer to the buddylist that will be loaded.
- */
--/* void ggp_buddylist_load(GaimConnection *gc, char *buddylist) {{{ */
-+/* void ggp_buddylist_load(Gaim2Connection *gc, char *buddylist) {{{ */
- void
--ggp_buddylist_load(GaimConnection *gc, char *buddylist);
-+ggp_buddylist_load(Gaim2Connection *gc, char *buddylist);
-
- /**
- * Set offline status for all buddies.
-@@ -46,7 +46,7 @@ ggp_buddylist_load(GaimConnection *gc, c
- * @param gc Connection handler
- */
- void
--ggp_buddylist_offline(GaimConnection *gc);
-+ggp_buddylist_offline(Gaim2Connection *gc);
-
- /**
- * Get all the buddies in the current account.
-@@ -56,7 +56,7 @@ ggp_buddylist_offline(GaimConnection *gc
- * @return List of buddies.
- */
- char *
--ggp_buddylist_dump(GaimAccount *account);
-+ggp_buddylist_dump(Gaim2Account *account);
-
-
- #endif /* _GAIM_GG_BUDDYLIST_H */
-diff -prNu ./src/protocols/gg/confer.c ./src/protocols/gg/confer.c
---- ./src/protocols/gg/confer.c 2005-12-06 20:50:47.000000000 +0100
-+++ ./src/protocols/gg/confer.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file confer.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -26,22 +26,22 @@
- #include "utils.h"
- #include "confer.h"
-
--/* GaimConversation *ggp_confer_find_by_name(GaimConnection *gc, const gchar *name) {{{ */
--GaimConversation *ggp_confer_find_by_name(GaimConnection *gc, const gchar *name)
-+/* Gaim2Conversation *ggp_confer_find_by_name(Gaim2Connection *gc, const gchar *name) {{{ */
-+Gaim2Conversation *ggp_confer_find_by_name(Gaim2Connection *gc, const gchar *name)
- {
- g_return_val_if_fail(gc != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
-
-- return gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, name,
-- gaim_connection_get_account(gc));
-+ return gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, name,
-+ gaim2_connection_get_account(gc));
- }
- /* }}} */
-
--/* void ggp_confer_participants_add_uin(GaimConnection *gc, const gchar *chat_name, const uin_t uin) {{{ */
--void ggp_confer_participants_add_uin(GaimConnection *gc, const gchar *chat_name,
-+/* void ggp_confer_participants_add_uin(Gaim2Connection *gc, const gchar *chat_name, const uin_t uin) {{{ */
-+void ggp_confer_participants_add_uin(Gaim2Connection *gc, const gchar *chat_name,
- const uin_t uin)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- GGPInfo *info = gc->proto_data;
- GGPChat *chat;
- GList *l;
-@@ -56,20 +56,20 @@ void ggp_confer_participants_add_uin(Gai
- continue;
-
- if (g_list_find(chat->participants, str_uin) == NULL) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- chat->participants = g_list_append(
- chat->participants, str_uin);
-
- conv = ggp_confer_find_by_name(gc, chat_name);
-
-- buddy = gaim_find_buddy(gaim_connection_get_account(gc), str_uin);
-+ buddy = gaim2_find_buddy(gaim2_connection_get_account(gc), str_uin);
- if (buddy != NULL) {
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(conv),
-- gaim_buddy_get_alias(buddy), NULL,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(conv),
-+ gaim2_buddy_get_alias(buddy), NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- } else {
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(conv),
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(conv),
- str_uin, NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- }
-@@ -81,8 +81,8 @@ void ggp_confer_participants_add_uin(Gai
- }
- /* }}} */
-
--/* void ggp_confer_participants_add(GaimConnection *gc, const gchar *chat_name, const uin_t *recipients, int count) {{{ */
--void ggp_confer_participants_add(GaimConnection *gc, const gchar *chat_name,
-+/* void ggp_confer_participants_add(Gaim2Connection *gc, const gchar *chat_name, const uin_t *recipients, int count) {{{ */
-+void ggp_confer_participants_add(Gaim2Connection *gc, const gchar *chat_name,
- const uin_t *recipients, int count)
- {
- GGPInfo *info = gc->proto_data;
-@@ -97,8 +97,8 @@ void ggp_confer_participants_add(GaimCon
-
- for (i = 0; i < count; i++) {
- gchar *str_uin = g_strdup_printf("%lu", (unsigned long int)recipients[i]);
-- GaimConversation *conv;
-- GaimBuddy *buddy;
-+ Gaim2Conversation *conv;
-+ Gaim2Buddy *buddy;
-
- if (g_list_find(chat->participants, str_uin) != NULL) {
- g_free(str_uin);
-@@ -108,13 +108,13 @@ void ggp_confer_participants_add(GaimCon
- chat->participants = g_list_append(chat->participants, str_uin);
- conv = ggp_confer_find_by_name(gc, chat_name);
-
-- buddy = gaim_find_buddy(gaim_connection_get_account(gc), str_uin);
-+ buddy = gaim2_find_buddy(gaim2_connection_get_account(gc), str_uin);
- if (buddy != NULL) {
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(conv),
-- gaim_buddy_get_alias(buddy), NULL,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(conv),
-+ gaim2_buddy_get_alias(buddy), NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- } else {
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(conv),
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(conv),
- str_uin, NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- }
-@@ -125,8 +125,8 @@ void ggp_confer_participants_add(GaimCon
- }
- /* }}} */
-
--/* const char *ggp_confer_find_by_participants(GaimConnection *gc, const uin_t *recipients, int count) {{{ */
--const char *ggp_confer_find_by_participants(GaimConnection *gc,
-+/* const char *ggp_confer_find_by_participants(Gaim2Connection *gc, const uin_t *recipients, int count) {{{ */
-+const char *ggp_confer_find_by_participants(Gaim2Connection *gc,
- const uin_t *recipients, int count)
- {
- GGPInfo *info = gc->proto_data;
-@@ -164,8 +164,8 @@ const char *ggp_confer_find_by_participa
- }
- /* }}} */
-
--/* const char *ggp_confer_add_new(GaimConnection *gc, const char *name) {{{ */
--const char *ggp_confer_add_new(GaimConnection *gc, const char *name)
-+/* const char *ggp_confer_add_new(Gaim2Connection *gc, const char *name) {{{ */
-+const char *ggp_confer_add_new(Gaim2Connection *gc, const char *name)
- {
- GGPInfo *info = gc->proto_data;
- GGPChat *chat;
-diff -prNu ./src/protocols/gg/confer.h ./src/protocols/gg/confer.h
---- ./src/protocols/gg/confer.h 2005-11-08 20:45:09.000000000 +0100
-+++ ./src/protocols/gg/confer.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file confer.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -29,34 +29,34 @@
- /**
- * Finds a CHAT conversation for the current account with the specified name.
- *
-- * @param gc GaimConnection instance.
-+ * @param gc Gaim2Connection instance.
- * @param name Name of the conversation.
- *
-- * @return GaimConversation or NULL if not found.
-+ * @return Gaim2Conversation or NULL if not found.
- */
--GaimConversation *
--ggp_confer_find_by_name(GaimConnection *gc, const gchar *name);
-+Gaim2Conversation *
-+ggp_confer_find_by_name(Gaim2Connection *gc, const gchar *name);
-
- /**
- * Adds the specified UIN to the specified conversation.
- *
-- * @param gc GaimConnection.
-+ * @param gc Gaim2Connection.
- * @param chat_name Name of the conversation.
- */
- void
--ggp_confer_participants_add_uin(GaimConnection *gc, const gchar *chat_name,
-+ggp_confer_participants_add_uin(Gaim2Connection *gc, const gchar *chat_name,
- const uin_t uin);
-
- /**
- * Add the specified UINs to the specified conversation.
- *
-- * @param gc GaimConnection.
-+ * @param gc Gaim2Connection.
- * @param chat_name Name of the conversation.
- * @param recipients List of the UINs.
- * @param count Number of the UINs.
- */
- void
--ggp_confer_participants_add(GaimConnection *gc, const gchar *chat_name,
-+ggp_confer_participants_add(Gaim2Connection *gc, const gchar *chat_name,
- const uin_t *recipients, int count);
-
- /**
-@@ -65,27 +65,27 @@ ggp_confer_participants_add(GaimConnecti
- * TODO: This function should be rewritten to better handle situations when
- * somebody adds more people to the converation.
- *
-- * @param gc GaimConnection.
-+ * @param gc Gaim2Connection.
- * @param recipients List of the people in the conversation.
- * @param count Number of people.
- *
- * @return Name of the conversation.
- */
- const char*
--ggp_confer_find_by_participants(GaimConnection *gc, const uin_t *recipients,
-+ggp_confer_find_by_participants(Gaim2Connection *gc, const uin_t *recipients,
- int count);
-
- /**
- * Adds a new conversation to the internal list of conversations.
- * If name is NULL then it will be automagically generated.
- *
-- * @param gc GaimConnection.
-+ * @param gc Gaim2Connection.
- * @param name Name of the conversation.
- *
- * @return Name of the conversation.
- */
- const char*
--ggp_confer_add_new(GaimConnection *gc, const char *name);
-+ggp_confer_add_new(Gaim2Connection *gc, const char *name);
-
-
- #endif /* _GAIM_GG_CONFER_H */
-diff -prNu ./src/protocols/gg/gg.c ./src/protocols/gg/gg.c
---- ./src/protocols/gg/gg.c 2006-01-04 19:52:34.000000000 +0100
-+++ ./src/protocols/gg/gg.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file gg.c Gadu-Gadu protocol plugin
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -54,7 +54,7 @@
- #include "buddylist.h"
- #include "utils.h"
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
- /* ---------------------------------------------------------------------- */
- /* ----- EXTERNAL CALLBACKS --------------------------------------------- */
-@@ -65,35 +65,35 @@ static GaimPlugin *my_protocol = NULL;
-
- /*
- */
--/* static void ggp_async_token_handler(gpointer _gc, gint fd, GaimInputCondition cond) {{{ */
--static void ggp_async_token_handler(gpointer _gc, gint fd, GaimInputCondition cond)
-+/* static void ggp_async_token_handler(gpointer _gc, gint fd, Gaim2InputCondition cond) {{{ */
-+static void ggp_async_token_handler(gpointer _gc, gint fd, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = _gc;
-+ Gaim2Connection *gc = _gc;
- GGPInfo *info = gc->proto_data;
- GGPToken *token = info->token;
- GGPTokenCallback cb;
-
- struct gg_token *t = NULL;
-
-- gaim_debug_info("gg", "token_handler: token->req->fd = %d\n", token->req->fd);
-- gaim_debug_info("gg", "token_handler: token->req: check = %d; state = %d;\n",
-+ gaim2_debug_info("gg", "token_handler: token->req->fd = %d\n", token->req->fd);
-+ gaim2_debug_info("gg", "token_handler: token->req: check = %d; state = %d;\n",
- token->req->check, token->req->state);
-
- if (gg_token_watch_fd(token->req) == -1 || token->req->state == GG_STATE_ERROR) {
-- gaim_debug_error("gg", "token error (1): %d\n", token->req->error);
-- gaim_input_remove(token->inpa);
-+ gaim2_debug_error("gg", "token error (1): %d\n", token->req->error);
-+ gaim2_input_remove(token->inpa);
- gg_token_free(token->req);
- token->req = NULL;
-
-- gaim_notify_error(gaim_connection_get_account(gc),
-+ gaim2_notify_error(gaim2_connection_get_account(gc),
- _("Token Error"),
- _("Unable to fetch the token.\n"), NULL);
- return;
- }
-
- if (token->req->state != GG_STATE_DONE) {
-- gaim_input_remove(token->inpa);
-- token->inpa = gaim_input_add(token->req->fd,
-+ gaim2_input_remove(token->inpa);
-+ token->inpa = gaim2_input_add(token->req->fd,
- (token->req->check == 1)
- ? GAIM_INPUT_WRITE
- : GAIM_INPUT_READ,
-@@ -102,25 +102,25 @@ static void ggp_async_token_handler(gpoi
- }
-
- if (!(t = token->req->data) || !token->req->body) {
-- gaim_debug_error("gg", "token error (2): %d\n", token->req->error);
-- gaim_input_remove(token->inpa);
-+ gaim2_debug_error("gg", "token error (2): %d\n", token->req->error);
-+ gaim2_input_remove(token->inpa);
- gg_token_free(token->req);
- token->req = NULL;
-
-- gaim_notify_error(gaim_connection_get_account(gc),
-+ gaim2_notify_error(gaim2_connection_get_account(gc),
- _("Token Error"),
- _("Unable to fetch the token.\n"), NULL);
- return;
- }
-
-- gaim_input_remove(token->inpa);
-+ gaim2_input_remove(token->inpa);
-
- token->id = g_strdup(t->tokenid);
- token->size = token->req->body_size;
- token->data = g_new0(char, token->size);
- memcpy(token->data, token->req->body, token->size);
-
-- gaim_debug_info("gg", "TOKEN! tokenid = %s; size = %d\n",
-+ gaim2_debug_info("gg", "TOKEN! tokenid = %s; size = %d\n",
- token->id, token->size);
-
- gg_token_free(token->req);
-@@ -135,14 +135,14 @@ static void ggp_async_token_handler(gpoi
-
- /*
- */
--/* static void ggp_token_request(GaimConnection *gc, GGPTokenCallback cb) {{{ */
--static void ggp_token_request(GaimConnection *gc, GGPTokenCallback cb)
-+/* static void ggp_token_request(Gaim2Connection *gc, GGPTokenCallback cb) {{{ */
-+static void ggp_token_request(Gaim2Connection *gc, GGPTokenCallback cb)
- {
- GGPInfo *info = gc->proto_data;
- struct gg_http *req;
-
- if ((req = gg_token(1)) == NULL) {
-- gaim_notify_error(gaim_connection_get_account(gc),
-+ gaim2_notify_error(gaim2_connection_get_account(gc),
- _("Token Error"),
- _("Unable to fetch the token.\n"), NULL);
- return;
-@@ -152,7 +152,7 @@ static void ggp_token_request(GaimConnec
- info->token->cb = cb;
-
- info->token->req = req;
-- info->token->inpa = gaim_input_add(req->fd, GAIM_INPUT_READ,
-+ info->token->inpa = gaim2_input_add(req->fd, GAIM_INPUT_READ,
- ggp_async_token_handler, gc);
- }
- /* }}} */
-@@ -165,13 +165,13 @@ static void ggp_token_request(GaimConnec
- *
- * @param Current action handler.
- */
--/* static void ggp_action_buddylist_get(GaimPluginAction *action) {{{ */
--static void ggp_action_buddylist_get(GaimPluginAction *action)
-+/* static void ggp_action_buddylist_get(Gaim2PluginAction *action) {{{ */
-+static void ggp_action_buddylist_get(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
- GGPInfo *info = gc->proto_data;
-
-- gaim_debug_info("gg", "Downloading...\n");
-+ gaim2_debug_info("gg", "Downloading...\n");
-
- gg_userlist_request(info->session, GG_USERLIST_GET, NULL);
- }
-@@ -182,15 +182,15 @@ static void ggp_action_buddylist_get(Gai
- *
- * @param action Current action handler.
- */
--/* static void ggp_action_buddylist_put(GaimPluginAction *action) {{{ */
--static void ggp_action_buddylist_put(GaimPluginAction *action)
-+/* static void ggp_action_buddylist_put(Gaim2PluginAction *action) {{{ */
-+static void ggp_action_buddylist_put(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
- GGPInfo *info = gc->proto_data;
-
-- char *buddylist = ggp_buddylist_dump(gaim_connection_get_account(gc));
-+ char *buddylist = ggp_buddylist_dump(gaim2_connection_get_account(gc));
-
-- gaim_debug_info("gg", "Uploading...\n");
-+ gaim2_debug_info("gg", "Uploading...\n");
-
- if (buddylist == NULL)
- return;
-@@ -205,13 +205,13 @@ static void ggp_action_buddylist_put(Gai
- *
- * @param action Current action handler.
- */
--/* static void ggp_action_buddylist_delete(GaimPluginAction *action) {{{ */
--static void ggp_action_buddylist_delete(GaimPluginAction *action)
-+/* static void ggp_action_buddylist_delete(Gaim2PluginAction *action) {{{ */
-+static void ggp_action_buddylist_delete(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
- GGPInfo *info = gc->proto_data;
-
-- gaim_debug_info("gg", "Deleting...\n");
-+ gaim2_debug_info("gg", "Deleting...\n");
-
- gg_userlist_request(info->session, GG_USERLIST_PUT, NULL);
- }
-@@ -219,20 +219,20 @@ static void ggp_action_buddylist_delete(
-
- /*
- */
--/* static void ggp_callback_buddylist_save_ok(GaimConnection *gc, gchar *file) {{{ */
--static void ggp_callback_buddylist_save_ok(GaimConnection *gc, gchar *file)
-+/* static void ggp_callback_buddylist_save_ok(Gaim2Connection *gc, gchar *file) {{{ */
-+static void ggp_callback_buddylist_save_ok(Gaim2Connection *gc, gchar *file)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-
- FILE *fh;
- char *buddylist = ggp_buddylist_dump(account);
- gchar *msg;
-
-- gaim_debug_info("gg", "Saving...\n");
-- gaim_debug_info("gg", "file = %s\n", file);
-+ gaim2_debug_info("gg", "Saving...\n");
-+ gaim2_debug_info("gg", "file = %s\n", file);
-
- if (buddylist == NULL) {
-- gaim_notify_info(account, _("Save Buddylist..."),
-+ gaim2_notify_info(account, _("Save Buddylist..."),
- _("Your buddylist is empty, nothing was written to the file."),
- NULL);
- return;
-@@ -240,8 +240,8 @@ static void ggp_callback_buddylist_save_
-
- if ((fh = g_fopen(file, "wb")) == NULL) {
- msg = g_strconcat(_("Couldn't open file"), ": ", file, "\n", NULL);
-- gaim_debug_error("gg", "Could not open file: %s\n", file);
-- gaim_notify_error(account, _("Couldn't open file"), msg, NULL);
-+ gaim2_debug_error("gg", "Could not open file: %s\n", file);
-+ gaim2_notify_error(account, _("Couldn't open file"), msg, NULL);
- g_free(msg);
- g_free(file);
- return;
-@@ -251,30 +251,30 @@ static void ggp_callback_buddylist_save_
- fclose(fh);
- g_free(buddylist);
-
-- gaim_notify_info(account, _("Save Buddylist..."),
-+ gaim2_notify_info(account, _("Save Buddylist..."),
- _("Buddylist saved successfully!"), NULL);
- }
- /* }}} */
-
- /*
- */
--/* static void ggp_callback_buddylist_load_ok(GaimConnection *gc, gchar *file) {{{ */
--static void ggp_callback_buddylist_load_ok(GaimConnection *gc, gchar *file)
-+/* static void ggp_callback_buddylist_load_ok(Gaim2Connection *gc, gchar *file) {{{ */
-+static void ggp_callback_buddylist_load_ok(Gaim2Connection *gc, gchar *file)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- GError *error = NULL;
- char *buddylist = NULL;
- gsize length;
-
-- gaim_debug_info("gg", "file_name = %s\n", file);
-+ gaim2_debug_info("gg", "file_name = %s\n", file);
-
- if (!g_file_get_contents(file, &buddylist, &length, &error)) {
-- gaim_notify_error(account,
-+ gaim2_notify_error(account,
- _("Couldn't load buddylist"),
- _("Couldn't load buddylist"),
- error->message);
-
-- gaim_debug_error("gg",
-+ gaim2_debug_error("gg",
- "Couldn't load buddylist. file = %s; error = %s\n",
- file, error->message);
-
-@@ -286,7 +286,7 @@ static void ggp_callback_buddylist_load_
- ggp_buddylist_load(gc, buddylist);
- g_free(buddylist);
-
-- gaim_notify_info(account,
-+ gaim2_notify_info(account,
- _("Load Buddylist..."),
- _("Buddylist loaded successfully!"), NULL);
- }
-@@ -294,35 +294,35 @@ static void ggp_callback_buddylist_load_
-
- /*
- */
--/* static void ggp_action_buddylist_save(GaimPluginAction *action) {{{ */
--static void ggp_action_buddylist_save(GaimPluginAction *action)
-+/* static void ggp_action_buddylist_save(Gaim2PluginAction *action) {{{ */
-+static void ggp_action_buddylist_save(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
-
-- gaim_request_file(action, _("Save buddylist..."), NULL, TRUE,
-+ gaim2_request_file(action, _("Save buddylist..."), NULL, TRUE,
- G_CALLBACK(ggp_callback_buddylist_save_ok), NULL, gc);
- }
- /* }}} */
-
- /*
- */
--/* static void ggp_action_buddylist_load(GaimPluginAction *action) {{{ */
--static void ggp_action_buddylist_load(GaimPluginAction *action)
-+/* static void ggp_action_buddylist_load(Gaim2PluginAction *action) {{{ */
-+static void ggp_action_buddylist_load(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
-
-- gaim_request_file(action, "Load buddylist from file...", NULL, FALSE,
-+ gaim2_request_file(action, "Load buddylist from file...", NULL, FALSE,
- G_CALLBACK(ggp_callback_buddylist_load_ok), NULL, gc);
- }
- /* }}} */
-
- /*
- */
--/* static void ggp_callback_register_account_ok(GaimConnection *gc, GaimRequestFields *fields) {{{ */
--static void ggp_callback_register_account_ok(GaimConnection *gc,
-- GaimRequestFields *fields)
-+/* static void ggp_callback_register_account_ok(Gaim2Connection *gc, Gaim2RequestFields *fields) {{{ */
-+static void ggp_callback_register_account_ok(Gaim2Connection *gc,
-+ Gaim2RequestFields *fields)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GGPInfo *info = gc->proto_data;
- struct gg_http *h = NULL;
- struct gg_pubdir *s;
-@@ -330,47 +330,47 @@ static void ggp_callback_register_accoun
- gchar *email, *p1, *p2, *t;
- GGPToken *token = info->token;
-
-- email = charset_convert(gaim_request_fields_get_string(fields, "email"),
-+ email = charset_convert(gaim2_request_fields_get_string(fields, "email"),
- "UTF-8", "CP1250");
-- p1 = charset_convert(gaim_request_fields_get_string(fields, "password1"),
-+ p1 = charset_convert(gaim2_request_fields_get_string(fields, "password1"),
- "UTF-8", "CP1250");
-- p2 = charset_convert(gaim_request_fields_get_string(fields, "password2"),
-+ p2 = charset_convert(gaim2_request_fields_get_string(fields, "password2"),
- "UTF-8", "CP1250");
-- t = charset_convert(gaim_request_fields_get_string(fields, "token"),
-+ t = charset_convert(gaim2_request_fields_get_string(fields, "token"),
- "UTF-8", "CP1250");
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- if (email == NULL || p1 == NULL || p2 == NULL || t == NULL ||
- *email == '\0' || *p1 == '\0' || *p2 == '\0' || *t == '\0') {
-- gaim_connection_error(gc, _("Fill in the registration fields."));
-+ gaim2_connection_error(gc, _("Fill in the registration fields."));
- goto exit_err;
- }
-
- if (g_utf8_collate(p1, p2) != 0) {
-- gaim_connection_error(gc, _("Passwords do not match."));
-+ gaim2_connection_error(gc, _("Passwords do not match."));
- goto exit_err;
- }
-
-- gaim_debug_info("gg", "register_account_ok: token_id = %d; t = %s\n",
-+ gaim2_debug_info("gg", "register_account_ok: token_id = %d; t = %s\n",
- token->id, t);
- h = gg_register3(email, p1, token->id, t, 0);
- if (h == NULL || !(s = h->data) || !s->success) {
-- gaim_connection_error(gc,
-+ gaim2_connection_error(gc,
- _("Unable to register new account. Error occurred.\n"));
- goto exit_err;
- }
-
- uin = s->uin;
-- gaim_debug_info("gg", "registered uin: %d\n", uin);
-+ gaim2_debug_info("gg", "registered uin: %d\n", uin);
-
- g_free(t);
- t = g_strdup_printf("%u", uin);
-- gaim_account_set_username(account, t);
-+ gaim2_account_set_username(account, t);
- /* Save the password if remembering passwords for the account */
-- gaim_account_set_password(account, p1);
-+ gaim2_account_set_password(account, p1);
-
-- gaim_notify_info(NULL, _("New Gadu-Gadu Account Registered"),
-+ gaim2_notify_info(NULL, _("New Gadu-Gadu Account Registered"),
- _("Registration completed successfully!"), NULL);
-
- /* TODO: the currently open Accounts Window will not be updated withthe
-@@ -379,7 +379,7 @@ static void ggp_callback_register_accoun
- */
-
- /* Need to disconnect or actually log in. For now, we disconnect. */
-- gaim_connection_destroy(gc);
-+ gaim2_connection_destroy(gc);
-
- exit_err:
- gg_register_free(h);
-@@ -394,14 +394,14 @@ exit_err:
-
- /*
- */
--/* static void ggp_callback_register_account_cancel(GaimConnection *gc, GaimRequestFields *fields) {{{ */
--static void ggp_callback_register_account_cancel(GaimConnection *gc,
-- GaimRequestFields *fields)
-+/* static void ggp_callback_register_account_cancel(Gaim2Connection *gc, Gaim2RequestFields *fields) {{{ */
-+static void ggp_callback_register_account_cancel(Gaim2Connection *gc,
-+ Gaim2RequestFields *fields)
- {
- GGPInfo *info = gc->proto_data;
- GGPToken *token = info->token;
-
-- gaim_connection_destroy(gc);
-+ gaim2_connection_destroy(gc);
-
- g_free(token->id);
- g_free(token->data);
-@@ -412,50 +412,50 @@ static void ggp_callback_register_accoun
-
- /*
- */
--/* static void ggp_register_user_dialog(GaimConnection *gc) {{{ */
--static void ggp_register_user_dialog(GaimConnection *gc)
-+/* static void ggp_register_user_dialog(Gaim2Connection *gc) {{{ */
-+static void ggp_register_user_dialog(Gaim2Connection *gc)
- {
-- GaimAccount *account;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2Account *account;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- GGPInfo *info = gc->proto_data;
- GGPToken *token = info->token;
-
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("email",
-+ field = gaim2_request_field_string_new("email",
- _("e-Mail"), "", FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("password1",
-+ field = gaim2_request_field_string_new("password1",
- _("Password"), "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("password2",
-+ field = gaim2_request_field_string_new("password2",
- _("Password (retype)"), "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("token",
-+ field = gaim2_request_field_string_new("token",
- _("Enter current token"), "", FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
- /* original size: 60x24 */
-- field = gaim_request_field_image_new("token_img",
-+ field = gaim2_request_field_image_new("token_img",
- _("Current token"), token->data, token->size);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(account,
-+ gaim2_request_fields(account,
- _("Register New Gadu-Gadu Account"),
- _("Register New Gadu-Gadu Account"),
- _("Please, fill in the following fields"),
-@@ -470,8 +470,8 @@ static void ggp_register_user_dialog(Gai
-
- /*
- */
--/* static void ggp_callback_show_next(GaimConnection *gc, GList *row) {{{ */
--static void ggp_callback_show_next(GaimConnection *gc, GList *row)
-+/* static void ggp_callback_show_next(Gaim2Connection *gc, GList *row) {{{ */
-+static void ggp_callback_show_next(Gaim2Connection *gc, GList *row)
- {
- GGPInfo *info = gc->proto_data;
-
-@@ -483,18 +483,18 @@ static void ggp_callback_show_next(GaimC
-
- /*
- */
--/* static void ggp_callback_add_buddy(GaimConnection *gc, GList *row) {{{ */
--static void ggp_callback_add_buddy(GaimConnection *gc, GList *row)
-+/* static void ggp_callback_add_buddy(Gaim2Connection *gc, GList *row) {{{ */
-+static void ggp_callback_add_buddy(Gaim2Connection *gc, GList *row)
- {
-- gaim_blist_request_add_buddy(gaim_connection_get_account(gc),
-+ gaim2_blist_request_add_buddy(gaim2_connection_get_account(gc),
- g_list_nth_data(row, 0), NULL, NULL);
- }
- /* }}} */
-
- /*
- */
--/* static void ggp_callback_find_buddies(GaimConnection *gc, GaimRequestFields *fields) {{{ */
--static void ggp_callback_find_buddies(GaimConnection *gc, GaimRequestFields *fields)
-+/* static void ggp_callback_find_buddies(Gaim2Connection *gc, Gaim2RequestFields *fields) {{{ */
-+static void ggp_callback_find_buddies(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
- GGPInfo *info = gc->proto_data;
- GGPSearchForm *form;
-@@ -503,22 +503,22 @@ static void ggp_callback_find_buddies(Ga
- info->search_form = form;
-
- form->lastname = charset_convert(
-- gaim_request_fields_get_string(fields, "lastname"),
-+ gaim2_request_fields_get_string(fields, "lastname"),
- "UTF-8", "CP1250");
- form->firstname = charset_convert(
-- gaim_request_fields_get_string(fields, "firstname"),
-+ gaim2_request_fields_get_string(fields, "firstname"),
- "UTF-8", "CP1250");
- form->nickname = charset_convert(
-- gaim_request_fields_get_string(fields, "nickname"),
-+ gaim2_request_fields_get_string(fields, "nickname"),
- "UTF-8", "CP1250");
- form->city = charset_convert(
-- gaim_request_fields_get_string(fields, "city"),
-+ gaim2_request_fields_get_string(fields, "city"),
- "UTF-8", "CP1250");
- form->birthyear = charset_convert(
-- gaim_request_fields_get_string(fields, "year"),
-+ gaim2_request_fields_get_string(fields, "year"),
- "UTF-8", "CP1250");
-
-- switch (gaim_request_fields_get_choice(fields, "gender")) {
-+ switch (gaim2_request_fields_get_choice(fields, "gender")) {
- case 1:
- form->gender = g_strdup(GG_PUBDIR50_GENDER_MALE);
- break;
-@@ -530,7 +530,7 @@ static void ggp_callback_find_buddies(Ga
- break;
- }
-
-- form->active = gaim_request_fields_get_bool(fields, "active")
-+ form->active = gaim2_request_fields_get_bool(fields, "active")
- ? g_strdup(GG_PUBDIR50_ACTIVE_TRUE) : NULL;
-
- form->offset = g_strdup("0");
-@@ -541,62 +541,62 @@ static void ggp_callback_find_buddies(Ga
-
- /*
- */
--/* static void ggp_find_buddies(GaimPluginAction *action) {{{ */
--static void ggp_find_buddies(GaimPluginAction *action)
-+/* static void ggp_find_buddies(Gaim2PluginAction *action) {{{ */
-+static void ggp_find_buddies(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
- GGPInfo *info = gc->proto_data;
-
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- if (info->search_form != NULL) {
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Unable to initiate a new search"),
- _("You have a pending search. Please wait for it to finish."));
- return;
- }
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("lastname",
-+ field = gaim2_request_field_string_new("lastname",
- _("Last name"), NULL, FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("firstname",
-+ field = gaim2_request_field_string_new("firstname",
- _("First name"), NULL, FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("nickname",
-+ field = gaim2_request_field_string_new("nickname",
- _("Nickname"), NULL, FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("city",
-+ field = gaim2_request_field_string_new("city",
- _("City"), NULL, FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("year",
-+ field = gaim2_request_field_string_new("year",
- _("Year of birth"), NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_choice_new("gender", _("Gender"), 0);
-- gaim_request_field_choice_add(field, _("Male or female"));
-- gaim_request_field_choice_add(field, _("Male"));
-- gaim_request_field_choice_add(field, _("Female"));
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_choice_new("gender", _("Gender"), 0);
-+ gaim2_request_field_choice_add(field, _("Male or female"));
-+ gaim2_request_field_choice_add(field, _("Male"));
-+ gaim2_request_field_choice_add(field, _("Female"));
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_bool_new("active",
-+ field = gaim2_request_field_bool_new("active",
- _("Only online"), FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(gc,
-+ gaim2_request_fields(gc,
- _("Find buddies"),
- _("Find buddies"),
- _("Please, enter your search criteria below"),
-@@ -611,67 +611,67 @@ static void ggp_find_buddies(GaimPluginA
-
- /*
- */
--/* static void ggp_callback_change_passwd_ok(GaimConnection *gc, GaimRequestFields *fields) {{{ */
--static void ggp_callback_change_passwd_ok(GaimConnection *gc, GaimRequestFields *fields)
-+/* static void ggp_callback_change_passwd_ok(Gaim2Connection *gc, Gaim2RequestFields *fields) {{{ */
-+static void ggp_callback_change_passwd_ok(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GGPInfo *info = gc->proto_data;
- struct gg_http *h;
- gchar *cur, *p1, *p2, *t;
-
- cur = charset_convert(
-- gaim_request_fields_get_string(fields, "password_cur"),
-+ gaim2_request_fields_get_string(fields, "password_cur"),
- "UTF-8", "CP1250");
- p1 = charset_convert(
-- gaim_request_fields_get_string(fields, "password1"),
-+ gaim2_request_fields_get_string(fields, "password1"),
- "UTF-8", "CP1250");
- p2 = charset_convert(
-- gaim_request_fields_get_string(fields, "password2"),
-+ gaim2_request_fields_get_string(fields, "password2"),
- "UTF-8", "CP1250");
- t = charset_convert(
-- gaim_request_fields_get_string(fields, "token"),
-+ gaim2_request_fields_get_string(fields, "token"),
- "UTF-8", "CP1250");
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- if (cur == NULL || p1 == NULL || p2 == NULL || t == NULL ||
- *cur == '\0' || *p1 == '\0' || *p2 == '\0' || *t == '\0') {
-- gaim_notify_error(account, NULL, _("Fill in the fields."), NULL);
-+ gaim2_notify_error(account, NULL, _("Fill in the fields."), NULL);
- goto exit_err;
- }
-
- if (g_utf8_collate(p1, p2) != 0) {
-- gaim_notify_error(account, NULL,
-+ gaim2_notify_error(account, NULL,
- _("New passwords do not match."), NULL);
- goto exit_err;
- }
-
-- if (g_utf8_collate(cur, gaim_account_get_password(account)) != 0) {
-- gaim_notify_error(account, NULL,
-+ if (g_utf8_collate(cur, gaim2_account_get_password(account)) != 0) {
-+ gaim2_notify_error(account, NULL,
- _("Your current password is different from the one that you specified."),
- NULL);
- goto exit_err;
- }
-
-- gaim_debug_info("gg", "Changing password\n");
-+ gaim2_debug_info("gg", "Changing password\n");
-
- /* XXX: this e-mail should be a pref... */
- h = gg_change_passwd4(ggp_get_uin(account),
-- "user@example.net", gaim_account_get_password(account),
-+ "user@example.net", gaim2_account_get_password(account),
- p1, info->token->id, t, 0);
-
- if (h == NULL) {
-- gaim_notify_error(account, NULL,
-+ gaim2_notify_error(account, NULL,
- _("Unable to change password. Error occured.\n"),
- NULL);
- goto exit_err;
- }
-
-- gaim_account_set_password(account, p1);
-+ gaim2_account_set_password(account, p1);
-
- gg_change_passwd_free(h);
-
-- gaim_notify_info(account, _("Change password for the Gadu-Gadu account"),
-+ gaim2_notify_info(account, _("Change password for the Gadu-Gadu account"),
- _("Password was changed successfully!"), NULL);
-
- exit_err:
-@@ -687,12 +687,12 @@ exit_err:
-
- /*
- */
--/* static void ggp_change_passwd_dialog(GaimConnection *gc) {{{ */
--static void ggp_change_passwd_dialog(GaimConnection *gc)
-+/* static void ggp_change_passwd_dialog(Gaim2Connection *gc) {{{ */
-+static void ggp_change_passwd_dialog(Gaim2Connection *gc)
- {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- GGPInfo *info = gc->proto_data;
- GGPToken *token = info->token;
-@@ -700,40 +700,40 @@ static void ggp_change_passwd_dialog(Gai
- char *msg;
-
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("password_cur",
-+ field = gaim2_request_field_string_new("password_cur",
- _("Current password"), "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("password1",
-+ field = gaim2_request_field_string_new("password1",
- _("Password"), "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("password2",
-+ field = gaim2_request_field_string_new("password2",
- _("Password (retype)"), "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("token",
-+ field = gaim2_request_field_string_new("token",
- _("Enter current token"), "", FALSE);
-- gaim_request_field_string_set_masked(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
- /* original size: 60x24 */
-- field = gaim_request_field_image_new("token_img",
-+ field = gaim2_request_field_image_new("token_img",
- _("Current token"), token->data, token->size);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
- msg = g_strdup_printf("%s %d",
- _("Please, enter your current password and your new password for UIN: "),
-- ggp_get_uin(gaim_connection_get_account(gc)));
-+ ggp_get_uin(gaim2_connection_get_account(gc)));
-
-- gaim_request_fields(gc,
-+ gaim2_request_fields(gc,
- _("Change Gadu-Gadu Password"),
- _("Change Gadu-Gadu Password"),
- msg,
-@@ -746,10 +746,10 @@ static void ggp_change_passwd_dialog(Gai
-
- /*
- */
--/* static void ggp_change_passwd(GaimPluginAction *action) {{{ */
--static void ggp_change_passwd(GaimPluginAction *action)
-+/* static void ggp_change_passwd(Gaim2PluginAction *action) {{{ */
-+static void ggp_change_passwd(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *)action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *)action->context;
-
- ggp_token_request(gc, ggp_change_passwd_dialog);
- }
-@@ -759,16 +759,16 @@ static void ggp_change_passwd(GaimPlugin
-
- /*
- */
--/* static void ggp_callback_add_to_chat_ok(GaimConnection *gc, GaimRequestFields *fields) {{{ */
--static void ggp_callback_add_to_chat_ok(GaimConnection *gc, GaimRequestFields *fields)
-+/* static void ggp_callback_add_to_chat_ok(Gaim2Connection *gc, Gaim2RequestFields *fields) {{{ */
-+static void ggp_callback_add_to_chat_ok(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
- GGPInfo *info = gc->proto_data;
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
- const GList *sel, *l;
-
-- field = gaim_request_fields_get_field(fields, "name");
-- sel = gaim_request_field_list_get_selected(field);
-- gaim_debug_info("gg", "selected chat %s for buddy %s\n",
-+ field = gaim2_request_fields_get_field(fields, "name");
-+ sel = gaim2_request_field_list_get_selected(field);
-+ gaim2_debug_info("gg", "selected chat %s for buddy %s\n",
- sel->data, info->tmp_buddy);
-
- for (l = info->chats; l != NULL; l = l->next) {
-@@ -785,43 +785,43 @@ static void ggp_callback_add_to_chat_ok(
-
- /*
- */
--/* static void ggp_bmenu_add_to_chat(GaimBlistNode *node, gpointer ignored) {{{ */
--static void ggp_bmenu_add_to_chat(GaimBlistNode *node, gpointer ignored)
-+/* static void ggp_bmenu_add_to_chat(Gaim2BlistNode *node, gpointer ignored) {{{ */
-+static void ggp_bmenu_add_to_chat(Gaim2BlistNode *node, gpointer ignored)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- GGPInfo *info;
-
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- GList *l;
- gchar *msg;
-
-- buddy = (GaimBuddy *)node;
-- gc = gaim_account_get_connection(gaim_buddy_get_account(buddy));
-+ buddy = (Gaim2Buddy *)node;
-+ gc = gaim2_account_get_connection(gaim2_buddy_get_account(buddy));
- info = gc->proto_data;
-
- /* TODO: It tmp_buddy != NULL then stop! */
-- info->tmp_buddy = g_strdup(gaim_buddy_get_name(buddy));
-+ info->tmp_buddy = g_strdup(gaim2_buddy_get_name(buddy));
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_list_new("name", "Chat name");
-+ field = gaim2_request_field_list_new("name", "Chat name");
- for (l = info->chats; l != NULL; l = l->next) {
- GGPChat *chat = l->data;
-- gaim_debug_info("gg", "adding chat %s\n", chat->name);
-- gaim_request_field_list_add(field, g_strdup(chat->name),
-+ gaim2_debug_info("gg", "adding chat %s\n", chat->name);
-+ gaim2_request_field_list_add(field, g_strdup(chat->name),
- g_strdup(chat->name));
- }
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
- msg = g_strdup_printf(_("Select a chat for buddy: %s"),
-- gaim_buddy_get_name(buddy));
-- gaim_request_fields(gc,
-+ gaim2_buddy_get_name(buddy));
-+ gaim2_request_fields(gc,
- _("Add to chat..."),
- _("Add to chat..."),
- msg,
-@@ -836,30 +836,30 @@ static void ggp_bmenu_add_to_chat(GaimBl
-
- /*
- */
--/* static void ggp_bmenu_block(GaimBlistNode *node, gpointer ignored) {{{ */
--static void ggp_bmenu_block(GaimBlistNode *node, gpointer ignored)
-+/* static void ggp_bmenu_block(Gaim2BlistNode *node, gpointer ignored) {{{ */
-+static void ggp_bmenu_block(Gaim2BlistNode *node, gpointer ignored)
- {
-- GaimConnection *gc;
-- GaimBuddy *buddy;
-+ Gaim2Connection *gc;
-+ Gaim2Buddy *buddy;
- GGPInfo *info;
- uin_t uin;
-
-- buddy = (GaimBuddy *)node;
-- gc = gaim_account_get_connection(gaim_buddy_get_account(buddy));
-+ buddy = (Gaim2Buddy *)node;
-+ gc = gaim2_account_get_connection(gaim2_buddy_get_account(buddy));
- info = gc->proto_data;
-
-- uin = ggp_str_to_uin(gaim_buddy_get_name(buddy));
-+ uin = ggp_str_to_uin(gaim2_buddy_get_name(buddy));
-
-- if (gaim_blist_node_get_bool(node, "blocked")) {
-- gaim_blist_node_set_bool(node, "blocked", FALSE);
-+ if (gaim2_blist_node_get_bool(node, "blocked")) {
-+ gaim2_blist_node_set_bool(node, "blocked", FALSE);
- gg_remove_notify_ex(info->session, uin, GG_USER_BLOCKED);
- gg_add_notify_ex(info->session, uin, GG_USER_NORMAL);
-- gaim_debug_info("gg", "send: uin=%d; mode=NORMAL\n", uin);
-+ gaim2_debug_info("gg", "send: uin=%d; mode=NORMAL\n", uin);
- } else {
-- gaim_blist_node_set_bool(node, "blocked", TRUE);
-+ gaim2_blist_node_set_bool(node, "blocked", TRUE);
- gg_remove_notify_ex(info->session, uin, GG_USER_NORMAL);
- gg_add_notify_ex(info->session, uin, GG_USER_BLOCKED);
-- gaim_debug_info("gg", "send: uin=%d; mode=BLOCKED\n", uin);
-+ gaim2_debug_info("gg", "send: uin=%d; mode=BLOCKED\n", uin);
- }
- }
- /* }}} */
-@@ -871,13 +871,13 @@ static void ggp_bmenu_block(GaimBlistNod
- /**
- * Handle change of the status of the buddy.
- *
-- * @param gc GaimConnection
-+ * @param gc Gaim2Connection
- * @param uin UIN of the buddy.
- * @param status ID of the status.
- * @param descr Description.
- */
--/* static void ggp_generic_status_handler(GaimConnection *gc, uin_t uin, int status, const char *descr) {{{ */
--static void ggp_generic_status_handler(GaimConnection *gc, uin_t uin,
-+/* static void ggp_generic_status_handler(Gaim2Connection *gc, uin_t uin, int status, const char *descr) {{{ */
-+static void ggp_generic_status_handler(Gaim2Connection *gc, uin_t uin,
- int status, const char *descr)
- {
- gchar *from;
-@@ -904,14 +904,14 @@ static void ggp_generic_status_handler(G
- break;
- default:
- st = "available";
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "GG_EVENT_NOTIFY: Unknown status: %d\n", status);
- break;
- }
-
-- gaim_debug_info("gg", "st = %s\n", st);
-+ gaim2_debug_info("gg", "st = %s\n", st);
- msg = charset_convert(descr, "CP1250", "UTF-8");
-- gaim_prpl_got_user_status(gaim_connection_get_account(gc),
-+ gaim2_prpl_got_user_status(gaim2_connection_get_account(gc),
- from, st, "message", msg, NULL);
- g_free(from);
- g_free(msg);
-@@ -920,10 +920,10 @@ static void ggp_generic_status_handler(G
-
- /*
- */
--/* static void ggp_sr_close_cb(GaimAccount *account) {{{ */
--static void ggp_sr_close_cb(GaimAccount *account)
-+/* static void ggp_sr_close_cb(Gaim2Account *account) {{{ */
-+static void ggp_sr_close_cb(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- GGPInfo *info = gc->proto_data;
- GGPSearchForm *f;
-
-@@ -948,57 +948,57 @@ static void ggp_sr_close_cb(GaimAccount
-
- /*
- */
--/* static void ggp_pubdir_reply_handler(GaimConnection *gc, gg_pubdir50_t req) {{{ */
--static void ggp_pubdir_reply_handler(GaimConnection *gc, gg_pubdir50_t req)
-+/* static void ggp_pubdir_reply_handler(Gaim2Connection *gc, gg_pubdir50_t req) {{{ */
-+static void ggp_pubdir_reply_handler(Gaim2Connection *gc, gg_pubdir50_t req)
- {
- GGPInfo *info = gc->proto_data;
-- GaimNotifySearchResults *results;
-- GaimNotifySearchColumn *column;
-+ Gaim2NotifySearchResults *results;
-+ Gaim2NotifySearchColumn *column;
- int res_count = 0;
- int start;
- int i;
-
- res_count = gg_pubdir50_count(req);
- if (res_count < 1) {
-- gaim_debug_info("gg", "GG_EVENT_PUBDIR50_SEARCH_REPLY: Nothing found\n");
-- gaim_notify_error(gc, NULL,
-+ gaim2_debug_info("gg", "GG_EVENT_PUBDIR50_SEARCH_REPLY: Nothing found\n");
-+ gaim2_notify_error(gc, NULL,
- _("No matching users found"),
- _("There are no users matching your search criteria."));
- return;
- }
- res_count = (res_count > 20) ? 20 : res_count;
-
-- results = gaim_notify_searchresults_new();
-+ results = gaim2_notify_searchresults_new();
-
- if (results == NULL) {
-- gaim_debug_error("gg", "ggp_pubdir_reply_handler: "
-+ gaim2_debug_error("gg", "ggp_pubdir_reply_handler: "
- "Unable to display the search results.\n");
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Unable to display the search results."),
- NULL);
-- ggp_sr_close_cb(gaim_connection_get_account(gc));
-+ ggp_sr_close_cb(gaim2_connection_get_account(gc));
- return;
- }
-
-- column = gaim_notify_searchresults_column_new(_("UIN"));
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new(_("UIN"));
-+ gaim2_notify_searchresults_column_add(results, column);
-
-- column = gaim_notify_searchresults_column_new(_("First name"));
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new(_("First name"));
-+ gaim2_notify_searchresults_column_add(results, column);
-
-- column = gaim_notify_searchresults_column_new(_("Nickname"));
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new(_("Nickname"));
-+ gaim2_notify_searchresults_column_add(results, column);
-
-- column = gaim_notify_searchresults_column_new(_("City"));
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new(_("City"));
-+ gaim2_notify_searchresults_column_add(results, column);
-
-- column = gaim_notify_searchresults_column_new(_("Birth year"));
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new(_("Birth year"));
-+ gaim2_notify_searchresults_column_add(results, column);
-
-- gaim_debug_info("gg", "Going with %d entries\n", res_count);
-+ gaim2_debug_info("gg", "Going with %d entries\n", res_count);
-
- start = (int)ggp_str_to_uin(gg_pubdir50_get(req, 0, GG_PUBDIR50_START));
-- gaim_debug_info("gg", "start = %d\n", start);
-+ gaim2_debug_info("gg", "start = %d\n", start);
-
- for (i = 0; i < res_count; i++) {
- GList *row = NULL;
-@@ -1017,7 +1017,7 @@ static void ggp_pubdir_reply_handler(Gai
- row = g_list_append(row,
- (birth && strncmp(birth, "0", 1)) ? birth : g_strdup("-"));
-
-- gaim_notify_searchresults_row_add(results, row);
-+ gaim2_notify_searchresults_row_add(results, row);
-
- if (i == res_count - 1) {
- g_free(info->search_form->last_uin);
-@@ -1026,30 +1026,30 @@ static void ggp_pubdir_reply_handler(Gai
- }
- }
-
-- gaim_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_CONTINUE,
-+ gaim2_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_CONTINUE,
- ggp_callback_show_next);
-- gaim_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_ADD,
-+ gaim2_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_ADD,
- ggp_callback_add_buddy);
- if (info->searchresults_window == NULL) {
-- void *h = gaim_notify_searchresults(gc,
-+ void *h = gaim2_notify_searchresults(gc,
- _("Gadu-Gadu Public Directory"),
- _("Search results"), NULL, results,
-- (GaimNotifyCloseCallback)ggp_sr_close_cb,
-- gaim_connection_get_account(gc));
-+ (Gaim2NotifyCloseCallback)ggp_sr_close_cb,
-+ gaim2_connection_get_account(gc));
-
- if (h == NULL) {
-- gaim_debug_error("gg", "ggp_pubdir_reply_handler: "
-+ gaim2_debug_error("gg", "ggp_pubdir_reply_handler: "
- "Unable to display the search results.\n");
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Unable to display the search results."),
- NULL);
-- ggp_sr_close_cb(gaim_connection_get_account(gc));
-+ ggp_sr_close_cb(gaim2_connection_get_account(gc));
- return;
- }
-
- info->searchresults_window = h;
- } else {
-- gaim_notify_searchresults_new_rows(gc, results,
-+ gaim2_notify_searchresults_new_rows(gc, results,
- info->searchresults_window, NULL);
- }
- }
-@@ -1058,14 +1058,14 @@ static void ggp_pubdir_reply_handler(Gai
- /**
- * Dispatch a message received from a buddy.
- *
-- * @param gc GaimConnection.
-+ * @param gc Gaim2Connection.
- * @param ev Gadu-Gadu event structure.
- */
--/* static void ggp_recv_message_handler(GaimConnection *gc, const struct gg_event *ev) {{{ */
--static void ggp_recv_message_handler(GaimConnection *gc, const struct gg_event *ev)
-+/* static void ggp_recv_message_handler(Gaim2Connection *gc, const struct gg_event *ev) {{{ */
-+static void ggp_recv_message_handler(Gaim2Connection *gc, const struct gg_event *ev)
- {
- GGPInfo *info = gc->proto_data;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- gchar *from;
- gchar *msg;
- gchar *tmp;
-@@ -1074,11 +1074,11 @@ static void ggp_recv_message_handler(Gai
-
- msg = charset_convert((const char *)ev->event.msg.message,
- "CP1250", "UTF-8");
-- gaim_str_strip_char(msg, '\r');
-+ gaim2_str_strip_char(msg, '\r');
- tmp = g_markup_escape_text(msg, -1);
- g_free(msg);
-
-- gaim_debug_info("gg", "msg form (%s): %s (class = %d; rcpt_count = %d)\n",
-+ gaim2_debug_info("gg", "msg form (%s): %s (class = %d; rcpt_count = %d)\n",
- from, tmp, ev->event.msg.msgclass,
- ev->event.msg.recipients_count);
-
-@@ -1104,7 +1104,7 @@ static void ggp_recv_message_handler(Gai
- ev->event.msg.recipients_count);
- }
- conv = ggp_confer_find_by_name(gc, chat_name);
-- chat_id = gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-+ chat_id = gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-
- buddy_name = ggp_buddy_get_name(gc, ev->event.msg.sender);
- serv_got_chat_in(gc, chat_id, buddy_name,
-@@ -1118,18 +1118,18 @@ static void ggp_recv_message_handler(Gai
-
- /*
- */
--/* static void ggp_callback_recv(gpointer _gc, gint fd, GaimInputCondition cond) {{{ */
--static void ggp_callback_recv(gpointer _gc, gint fd, GaimInputCondition cond)
-+/* static void ggp_callback_recv(gpointer _gc, gint fd, Gaim2InputCondition cond) {{{ */
-+static void ggp_callback_recv(gpointer _gc, gint fd, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = _gc;
-+ Gaim2Connection *gc = _gc;
- GGPInfo *info = gc->proto_data;
- struct gg_event *ev;
- int i;
-
- if (!(ev = gg_watch_fd(info->session))) {
-- gaim_debug_error("gg",
-+ gaim2_debug_error("gg",
- "ggp_callback_recv: gg_watch_fd failed -- CRITICAL!\n");
-- gaim_connection_error(gc, _("Unable to read socket"));
-+ gaim2_connection_error(gc, _("Unable to read socket"));
- return;
- }
-
-@@ -1141,7 +1141,7 @@ static void ggp_callback_recv(gpointer _
- ggp_recv_message_handler(gc, ev);
- break;
- case GG_EVENT_ACK:
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "message sent to: %ld, delivery status=%d, seq=%d\n",
- ev->event.ack.recipient, ev->event.ack.status,
- ev->event.ack.seq);
-@@ -1152,7 +1152,7 @@ static void ggp_callback_recv(gpointer _
- struct gg_notify_reply *n;
- char *descr;
-
-- gaim_debug_info("gg", "notify_pre: (%d) status: %d\n",
-+ gaim2_debug_info("gg", "notify_pre: (%d) status: %d\n",
- ev->event.notify->uin,
- ev->event.notify->status);
-
-@@ -1163,7 +1163,7 @@ static void ggp_callback_recv(gpointer _
- descr = (ev->type == GG_EVENT_NOTIFY) ? NULL
- : ev->event.notify_descr.descr;
-
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "notify: (%d) status: %d; descr: %s\n",
- n->uin, n->status, descr);
-
-@@ -1173,13 +1173,13 @@ static void ggp_callback_recv(gpointer _
- }
- break;
- case GG_EVENT_NOTIFY60:
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "notify60_pre: (%d) status=%d; version=%d; descr=%s\n",
- ev->event.notify60->uin, ev->event.notify60->status,
- ev->event.notify60->version, ev->event.notify60->descr);
-
- for (i = 0; ev->event.notify60[i].uin; i++) {
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "notify60: (%d) status=%d; version=%d; descr=%s\n",
- ev->event.notify60[i].uin,
- ev->event.notify60[i].status,
-@@ -1192,7 +1192,7 @@ static void ggp_callback_recv(gpointer _
- }
- break;
- case GG_EVENT_STATUS:
-- gaim_debug_info("gg", "status: (%d) status=%d; descr=%s\n",
-+ gaim2_debug_info("gg", "status: (%d) status=%d; descr=%s\n",
- ev->event.status.uin, ev->event.status.status,
- ev->event.status.descr);
-
-@@ -1200,7 +1200,7 @@ static void ggp_callback_recv(gpointer _
- ev->event.status.status, ev->event.status.descr);
- break;
- case GG_EVENT_STATUS60:
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "status60: (%d) status=%d; version=%d; descr=%s\n",
- ev->event.status60.uin, ev->event.status60.status,
- ev->event.status60.version, ev->event.status60.descr);
-@@ -1210,16 +1210,16 @@ static void ggp_callback_recv(gpointer _
- break;
- case GG_EVENT_USERLIST:
- if (ev->event.userlist.type == GG_USERLIST_GET_REPLY) {
-- gaim_debug_info("gg", "GG_USERLIST_GET_REPLY\n");
-- gaim_notify_info(gc, NULL,
-+ gaim2_debug_info("gg", "GG_USERLIST_GET_REPLY\n");
-+ gaim2_notify_info(gc, NULL,
- _("Buddy list downloaded"),
- _("Your buddy list was downloaded from the server."));
- if (ev->event.userlist.reply != NULL) {
- ggp_buddylist_load(gc, ev->event.userlist.reply);
- }
- } else {
-- gaim_debug_info("gg", "GG_USERLIST_PUT_REPLY\n");
-- gaim_notify_info(gc, NULL,
-+ gaim2_debug_info("gg", "GG_USERLIST_PUT_REPLY\n");
-+ gaim2_notify_info(gc, NULL,
- _("Buddy list uploaded"),
- _("Your buddy list was stored on the server."));
- }
-@@ -1228,7 +1228,7 @@ static void ggp_callback_recv(gpointer _
- ggp_pubdir_reply_handler(gc, ev->event.pubdir50);
- break;
- default:
-- gaim_debug_error("gg",
-+ gaim2_debug_error("gg",
- "unsupported event type=%d\n", ev->type);
- break;
- }
-@@ -1239,54 +1239,54 @@ static void ggp_callback_recv(gpointer _
-
- /*
- */
--/* static void ggp_async_login_handler(gpointer _gc, gint fd, GaimInputCondition cond) {{{ */
--static void ggp_async_login_handler(gpointer _gc, gint fd, GaimInputCondition cond)
-+/* static void ggp_async_login_handler(gpointer _gc, gint fd, Gaim2InputCondition cond) {{{ */
-+static void ggp_async_login_handler(gpointer _gc, gint fd, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = _gc;
-+ Gaim2Connection *gc = _gc;
- GGPInfo *info = gc->proto_data;
- struct gg_event *ev;
-
-- gaim_debug_info("gg", "login_handler: session: check = %d; state = %d;\n",
-+ gaim2_debug_info("gg", "login_handler: session: check = %d; state = %d;\n",
- info->session->check, info->session->state);
-
- switch (info->session->state) {
- case GG_STATE_RESOLVING:
-- gaim_debug_info("gg", "GG_STATE_RESOLVING\n");
-+ gaim2_debug_info("gg", "GG_STATE_RESOLVING\n");
- break;
- case GG_STATE_CONNECTING_HUB:
-- gaim_debug_info("gg", "GG_STATE_CONNECTING_HUB\n");
-+ gaim2_debug_info("gg", "GG_STATE_CONNECTING_HUB\n");
- break;
- case GG_STATE_READING_DATA:
-- gaim_debug_info("gg", "GG_STATE_READING_DATA\n");
-+ gaim2_debug_info("gg", "GG_STATE_READING_DATA\n");
- break;
- case GG_STATE_CONNECTING_GG:
-- gaim_debug_info("gg", "GG_STATE_CONNECTING_GG\n");
-+ gaim2_debug_info("gg", "GG_STATE_CONNECTING_GG\n");
- break;
- case GG_STATE_READING_KEY:
-- gaim_debug_info("gg", "GG_STATE_READING_KEY\n");
-+ gaim2_debug_info("gg", "GG_STATE_READING_KEY\n");
- break;
- case GG_STATE_READING_REPLY:
-- gaim_debug_info("gg", "GG_STATE_READING_REPLY\n");
-+ gaim2_debug_info("gg", "GG_STATE_READING_REPLY\n");
- break;
- default:
-- gaim_debug_error("gg", "unknown state = %d\n",
-+ gaim2_debug_error("gg", "unknown state = %d\n",
- info->session->state);
- break;
- }
-
- if (!(ev = gg_watch_fd(info->session))) {
-- gaim_debug_error("gg", "login_handler: gg_watch_fd failed!\n");
-- gaim_connection_error(gc, _("Unable to read socket"));
-+ gaim2_debug_error("gg", "login_handler: gg_watch_fd failed!\n");
-+ gaim2_connection_error(gc, _("Unable to read socket"));
- return;
- }
-- gaim_debug_info("gg", "login_handler: session->fd = %d\n", info->session->fd);
-- gaim_debug_info("gg", "login_handler: session: check = %d; state = %d;\n",
-+ gaim2_debug_info("gg", "login_handler: session->fd = %d\n", info->session->fd);
-+ gaim2_debug_info("gg", "login_handler: session: check = %d; state = %d;\n",
- info->session->check, info->session->state);
-
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
-
- /** XXX I think that this shouldn't be done if ev->type is GG_EVENT_CONN_FAILED or GG_EVENT_CONN_SUCCESS -datallah */
-- gc->inpa = gaim_input_add(info->session->fd,
-+ gc->inpa = gaim2_input_add(info->session->fd,
- (info->session->check == 1) ? GAIM_INPUT_WRITE
- : GAIM_INPUT_READ,
- ggp_async_login_handler, gc);
-@@ -1294,26 +1294,26 @@ static void ggp_async_login_handler(gpoi
- switch (ev->type) {
- case GG_EVENT_NONE:
- /* Nothing happened. */
-- gaim_debug_info("gg", "GG_EVENT_NONE\n");
-+ gaim2_debug_info("gg", "GG_EVENT_NONE\n");
- break;
- case GG_EVENT_CONN_SUCCESS:
-- gaim_debug_info("gg", "GG_EVENT_CONN_SUCCESS\n");
-- gaim_input_remove(gc->inpa);
-- gc->inpa = gaim_input_add(info->session->fd,
-+ gaim2_debug_info("gg", "GG_EVENT_CONN_SUCCESS\n");
-+ gaim2_input_remove(gc->inpa);
-+ gc->inpa = gaim2_input_add(info->session->fd,
- GAIM_INPUT_READ,
- ggp_callback_recv, gc);
-
- /* gg_change_status(info->session, GG_STATUS_AVAIL); */
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
- ggp_buddylist_send(gc);
- break;
- case GG_EVENT_CONN_FAILED:
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
- gc->inpa = 0;
-- gaim_connection_error(gc, _("Connection failed."));
-+ gaim2_connection_error(gc, _("Connection failed."));
- break;
- default:
-- gaim_debug_error("gg", "strange event: %d\n", ev->type);
-+ gaim2_debug_error("gg", "strange event: %d\n", ev->type);
- break;
- }
-
-@@ -1322,21 +1322,21 @@ static void ggp_async_login_handler(gpoi
- /* }}} */
-
- /* ---------------------------------------------------------------------- */
--/* ----- GaimPluginProtocolInfo ----------------------------------------- */
-+/* ----- Gaim2PluginProtocolInfo ----------------------------------------- */
- /* ---------------------------------------------------------------------- */
-
--/* static const char *ggp_list_icon(GaimAccount *account, GaimBuddy *buddy) {{{ */
--static const char *ggp_list_icon(GaimAccount *account, GaimBuddy *buddy)
-+/* static const char *ggp_list_icon(Gaim2Account *account, Gaim2Buddy *buddy) {{{ */
-+static const char *ggp_list_icon(Gaim2Account *account, Gaim2Buddy *buddy)
- {
- return "gadu-gadu";
- }
- /* }}} */
-
--/* static void ggp_list_emblems(GaimBuddy *b, const char **se, const char **sw, const char **nw, const char **ne) {{{ */
--static void ggp_list_emblems(GaimBuddy *b, const char **se, const char **sw,
-+/* static void ggp_list_emblems(Gaim2Buddy *b, const char **se, const char **sw, const char **nw, const char **ne) {{{ */
-+static void ggp_list_emblems(Gaim2Buddy *b, const char **se, const char **sw,
- const char **nw, const char **ne)
- {
-- GaimPresence *presence = gaim_buddy_get_presence(b);
-+ Gaim2Presence *presence = gaim2_buddy_get_presence(b);
-
- /*
- * Note to myself:
-@@ -1349,37 +1349,37 @@ static void ggp_list_emblems(GaimBuddy *
-
- if (!GAIM_BUDDY_IS_ONLINE(b)) {
- *se = "offline";
-- } else if (gaim_presence_is_status_primitive_active(presence, GAIM_STATUS_AWAY)) {
-+ } else if (gaim2_presence_is_status_primitive_active(presence, GAIM_STATUS_AWAY)) {
- *se = "away";
-- } else if (gaim_presence_is_status_active(presence, "blocked")) {
-+ } else if (gaim2_presence_is_status_active(presence, "blocked")) {
- *se = "blocked";
- } else {
- *se = "offline";
-- gaim_debug_error("gg", "ggp_list_emblems: unknown status\n");
-+ gaim2_debug_error("gg", "ggp_list_emblems: unknown status\n");
- }
- }
- /* }}} */
-
--/* static char *ggp_status_text(GaimBuddy *b) {{{ */
--static char *ggp_status_text(GaimBuddy *b)
-+/* static char *ggp_status_text(Gaim2Buddy *b) {{{ */
-+static char *ggp_status_text(Gaim2Buddy *b)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
- const char *msg;
- char *text;
- char *tmp;
-
-- status = gaim_presence_get_active_status(gaim_buddy_get_presence(b));
-+ status = gaim2_presence_get_active_status(gaim2_buddy_get_presence(b));
-
-- msg = gaim_status_get_attr_string(status, "message");
-+ msg = gaim2_status_get_attr_string(status, "message");
-
- if (msg != NULL) {
-- tmp = gaim_markup_strip_html(msg);
-+ tmp = gaim2_markup_strip_html(msg);
- text = g_markup_escape_text(tmp, -1);
- g_free(tmp);
-
- return text;
- } else {
-- tmp = g_strdup(gaim_status_get_name(status));
-+ tmp = g_strdup(gaim2_status_get_name(status));
- text = g_markup_escape_text(tmp, -1);
- g_free(tmp);
-
-@@ -1388,20 +1388,20 @@ static char *ggp_status_text(GaimBuddy *
- }
- /* }}} */
-
--/* static char *ggp_tooltip_text(GaimBuddy *b) {{{ */
--static char *ggp_tooltip_text(GaimBuddy *b)
-+/* static char *ggp_tooltip_text(Gaim2Buddy *b) {{{ */
-+static char *ggp_tooltip_text(Gaim2Buddy *b)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
- char *text;
- gchar *ret;
- const char *msg, *name;
-
-- status = gaim_presence_get_active_status(gaim_buddy_get_presence(b));
-- msg = gaim_status_get_attr_string(status, "message");
-- name = gaim_status_get_name(status);
-+ status = gaim2_presence_get_active_status(gaim2_buddy_get_presence(b));
-+ msg = gaim2_status_get_attr_string(status, "message");
-+ name = gaim2_status_get_name(status);
-
- if (msg != NULL) {
-- char *tmp = gaim_markup_strip_html(msg);
-+ char *tmp = gaim2_markup_strip_html(msg);
- text = g_markup_escape_text(tmp, -1);
- g_free(tmp);
-
-@@ -1418,15 +1418,15 @@ static char *ggp_tooltip_text(GaimBuddy
- }
- /* }}} */
-
--/* static GList *ggp_status_types(GaimAccount *account) {{{ */
--static GList *ggp_status_types(GaimAccount *account)
-+/* static GList *ggp_status_types(Gaim2Account *account) {{{ */
-+static GList *ggp_status_types(Gaim2Account *account)
- {
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- GList *types = NULL;
-
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_AVAILABLE, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-@@ -1434,28 +1434,28 @@ static GList *ggp_status_types(GaimAccou
- * Without this selecting Invisible as own status doesn't
- * work. It's not used and not needed to show status of buddies.
- */
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_INVISIBLE, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_AWAY, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
- /* This status is wrong. It shouldn't exist. This prpl must not be
- * using the privacy stuff correctly. -- rlaager */
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_INVISIBLE, "blocked", _("Blocked"), TRUE, FALSE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING), NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_OFFLINE, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-@@ -1463,27 +1463,27 @@ static GList *ggp_status_types(GaimAccou
- }
- /* }}} */
-
--/* static GList *ggp_blist_node_menu(GaimBlistNode *node) {{{ */
--static GList *ggp_blist_node_menu(GaimBlistNode *node)
-+/* static GList *ggp_blist_node_menu(Gaim2BlistNode *node) {{{ */
-+static GList *ggp_blist_node_menu(Gaim2BlistNode *node)
- {
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
- GList *m = NULL;
-
- if (!GAIM_BLIST_NODE_IS_BUDDY(node))
- return NULL;
-
-- act = gaim_blist_node_action_new(_("Add to chat"),
-+ act = gaim2_blist_node_action_new(_("Add to chat"),
- ggp_bmenu_add_to_chat, NULL, NULL);
- m = g_list_append(m, act);
-
- /* Using a blist node boolean here is also wrong.
- * Once the Block and Unblock actions are added to the core,
- * this will have to go. -- rlaager */
-- if (gaim_blist_node_get_bool(node, "blocked")) {
-- act = gaim_blist_node_action_new(_("Unblock"),
-+ if (gaim2_blist_node_get_bool(node, "blocked")) {
-+ act = gaim2_blist_node_action_new(_("Unblock"),
- ggp_bmenu_block, NULL, NULL);
- } else {
-- act = gaim_blist_node_action_new(_("Block"),
-+ act = gaim2_blist_node_action_new(_("Block"),
- ggp_bmenu_block, NULL, NULL);
- }
- m = g_list_append(m, act);
-@@ -1492,8 +1492,8 @@ static GList *ggp_blist_node_menu(GaimBl
- }
- /* }}} */
-
--/* static GList *ggp_chat_info(GaimConnection *gc) {{{ */
--static GList *ggp_chat_info(GaimConnection *gc)
-+/* static GList *ggp_chat_info(Gaim2Connection *gc) {{{ */
-+static GList *ggp_chat_info(Gaim2Connection *gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -1508,10 +1508,10 @@ static GList *ggp_chat_info(GaimConnecti
- }
- /* }}} */
-
--/* static void ggp_login(GaimAccount *account) {{{ */
--static void ggp_login(GaimAccount *account)
-+/* static void ggp_login(Gaim2Account *account) {{{ */
-+static void ggp_login(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- struct gg_login_params *glp = g_new0(struct gg_login_params, 1);
- GGPInfo *info = g_new0(GGPInfo, 1);
-
-@@ -1525,7 +1525,7 @@ static void ggp_login(GaimAccount *accou
- gc->proto_data = info;
-
- glp->uin = ggp_get_uin(account);
-- glp->password = (char *)gaim_account_get_password(account);
-+ glp->password = (char *)gaim2_account_get_password(account);
-
- glp->async = 1;
- glp->status = GG_STATUS_AVAIL;
-@@ -1533,21 +1533,21 @@ static void ggp_login(GaimAccount *accou
-
- info->session = gg_login(glp);
- if (info->session == NULL) {
-- gaim_connection_error(gc, _("Connection failed."));
-+ gaim2_connection_error(gc, _("Connection failed."));
- g_free(glp);
- return;
- }
-- gc->inpa = gaim_input_add(info->session->fd, GAIM_INPUT_READ,
-+ gc->inpa = gaim2_input_add(info->session->fd, GAIM_INPUT_READ,
- ggp_async_login_handler, gc);
- }
- /* }}} */
-
--/* static void ggp_close(GaimConnection *gc) {{{ */
--static void ggp_close(GaimConnection *gc)
-+/* static void ggp_close(Gaim2Connection *gc) {{{ */
-+static void ggp_close(Gaim2Connection *gc)
- {
-
- if (gc == NULL) {
-- gaim_debug_info("gg", "gc == NULL\n");
-+ gaim2_debug_info("gg", "gc == NULL\n");
- return;
- }
-
-@@ -1564,17 +1564,17 @@ static void ggp_close(GaimConnection *gc
- }
-
- if (gc->inpa > 0)
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
-
- ggp_buddylist_offline(gc);
-
-- gaim_debug_info("gg", "Connection closed.\n");
-+ gaim2_debug_info("gg", "Connection closed.\n");
- }
- /* }}} */
-
--/* static int ggp_send_im(GaimConnection *gc, const char *who, const char *msg, GaimMessageFlags flags) {{{ */
--static int ggp_send_im(GaimConnection *gc, const char *who, const char *msg,
-- GaimMessageFlags flags)
-+/* static int ggp_send_im(Gaim2Connection *gc, const char *who, const char *msg, Gaim2MessageFlags flags) {{{ */
-+static int ggp_send_im(Gaim2Connection *gc, const char *who, const char *msg,
-+ Gaim2MessageFlags flags)
- {
- GGPInfo *info = gc->proto_data;
- char *tmp, *plain;
-@@ -1582,8 +1582,8 @@ static int ggp_send_im(GaimConnection *g
- if (strlen(msg) == 0)
- return 1;
-
-- plain = gaim_unescape_html(msg);
-- gaim_debug_info("gg", "ggp_send_im: msg = %s\n", msg);
-+ plain = gaim2_unescape_html(msg);
-+ gaim2_debug_info("gg", "ggp_send_im: msg = %s\n", msg);
- tmp = charset_convert(plain, "UTF-8", "CP1250");
- g_free(plain);
-
-@@ -1599,14 +1599,14 @@ static int ggp_send_im(GaimConnection *g
- }
- /* }}} */
-
--/* static void ggp_get_info(GaimConnection *gc, const char *name) { {{{ */
--static void ggp_get_info(GaimConnection *gc, const char *name)
-+/* static void ggp_get_info(Gaim2Connection *gc, const char *name) { {{{ */
-+static void ggp_get_info(Gaim2Connection *gc, const char *name)
- {
- GGPInfo *info = gc->proto_data;
- GGPSearchForm *form;
-
- if (info->search_form != NULL) {
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Unable to initiate a new search"),
- _("You have a pending search. Please wait for it to finish."));
- return;
-@@ -1623,26 +1623,26 @@ static void ggp_get_info(GaimConnection
- }
- /* }}} */
-
--/* static void ggp_set_status(GaimAccount *account, GaimStatus *status) {{{ */
--static void ggp_set_status(GaimAccount *account, GaimStatus *status)
-+/* static void ggp_set_status(Gaim2Account *account, Gaim2Status *status) {{{ */
-+static void ggp_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimStatusPrimitive prim;
-- GaimConnection *gc;
-+ Gaim2StatusPrimitive prim;
-+ Gaim2Connection *gc;
- GGPInfo *info;
- const char *status_id, *msg;
- int new_status, new_status_descr;
-
-- prim = gaim_status_type_get_primitive(gaim_status_get_type(status));
-+ prim = gaim2_status_type_get_primitive(gaim2_status_get_type(status));
-
-- if (!gaim_status_is_active(status))
-+ if (!gaim2_status_is_active(status))
- return;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- info = gc->proto_data;
-
-- status_id = gaim_status_get_id(status);
-+ status_id = gaim2_status_get_id(status);
-
-- gaim_debug_info("gg", "ggp_set_status: Requested status = %s\n",
-+ gaim2_debug_info("gg", "ggp_set_status: Requested status = %s\n",
- status_id);
-
- if (strcmp(status_id, "available") == 0) {
-@@ -1657,21 +1657,21 @@ static void ggp_set_status(GaimAccount *
- } else {
- new_status = GG_STATUS_AVAIL;
- new_status_descr = GG_STATUS_AVAIL_DESCR;
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "ggp_set_status: uknown status requested (status_id=%s)\n",
- status_id);
- }
-
-- msg = gaim_status_get_attr_string(status, "message");
-+ msg = gaim2_status_get_attr_string(status, "message");
-
- if (msg == NULL) {
-- gaim_debug_info("gg", "ggp_set_status: msg == NULL\n");
-+ gaim2_debug_info("gg", "ggp_set_status: msg == NULL\n");
- gg_change_status(info->session, new_status);
- } else {
- char *tmp = charset_convert(msg, "UTF-8", "CP1250");
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "ggp_set_status: msg != NULL. msg = %s\n", tmp);
-- gaim_debug_info("gg",
-+ gaim2_debug_info("gg",
- "ggp_set_status: gg_change_status_descr() = %d\n",
- gg_change_status_descr(info->session, new_status_descr, tmp));
- g_free(tmp);
-@@ -1680,8 +1680,8 @@ static void ggp_set_status(GaimAccount *
- }
- /* }}} */
-
--/* static void ggp_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group) {{{ */
--static void ggp_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+/* static void ggp_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group) {{{ */
-+static void ggp_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- GGPInfo *info = gc->proto_data;
-
-@@ -1689,9 +1689,9 @@ static void ggp_add_buddy(GaimConnection
- }
- /* }}} */
-
--/* static void ggp_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group) {{{ */
--static void ggp_remove_buddy(GaimConnection *gc, GaimBuddy *buddy,
-- GaimGroup *group)
-+/* static void ggp_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group) {{{ */
-+static void ggp_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy,
-+ Gaim2Group *group)
- {
- GGPInfo *info = gc->proto_data;
-
-@@ -1699,8 +1699,8 @@ static void ggp_remove_buddy(GaimConnect
- }
- /* }}} */
-
--/* static void ggp_join_chat(GaimConnection *gc, GHashTable *data) {{{ */
--static void ggp_join_chat(GaimConnection *gc, GHashTable *data)
-+/* static void ggp_join_chat(Gaim2Connection *gc, GHashTable *data) {{{ */
-+static void ggp_join_chat(Gaim2Connection *gc, GHashTable *data)
- {
- GGPInfo *info = gc->proto_data;
- GGPChat *chat;
-@@ -1712,13 +1712,13 @@ static void ggp_join_chat(GaimConnection
- if (chat_name == NULL)
- return;
-
-- gaim_debug_info("gg", "joined %s chat\n", chat_name);
-+ gaim2_debug_info("gg", "joined %s chat\n", chat_name);
-
- for (l = info->chats; l != NULL; l = l->next) {
- chat = l->data;
-
- if (chat != NULL && g_utf8_collate(chat->name, chat_name) == 0) {
-- gaim_notify_error(gc, _("Chat error"),
-+ gaim2_notify_error(gc, _("Chat error"),
- _("This chat name is already in use"), NULL);
- return;
- }
-@@ -1735,10 +1735,10 @@ static char *ggp_get_chat_name(GHashTabl
- }
- /* }}} */
-
--/* static int ggp_chat_send(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags) {{{ */
--static int ggp_chat_send(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags)
-+/* static int ggp_chat_send(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags) {{{ */
-+static int ggp_chat_send(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- GGPInfo *info = gc->proto_data;
- GGPChat *chat = NULL;
- GList *l;
-@@ -1746,14 +1746,14 @@ static int ggp_chat_send(GaimConnection
- uin_t *uins;
- int count = 0;
-
-- if ((conv = gaim_find_chat(gc, id)) == NULL)
-+ if ((conv = gaim2_find_chat(gc, id)) == NULL)
- return -EINVAL;
-
- for (l = info->chats; l != NULL; l = l->next) {
- chat = l->data;
-
- if (g_utf8_collate(chat->name, conv->name) == 0) {
-- gaim_debug_info("gg", "found conv!\n");
-+ gaim2_debug_info("gg", "found conv!\n");
- break;
- }
-
-@@ -1761,7 +1761,7 @@ static int ggp_chat_send(GaimConnection
- }
-
- if (chat == NULL) {
-- gaim_debug_error("gg",
-+ gaim2_debug_error("gg",
- "ggp_chat_send: Hm... that's strange. No such chat?\n");
- return -EINVAL;
- }
-@@ -1775,7 +1775,7 @@ static int ggp_chat_send(GaimConnection
- uins[count++] = uin;
- }
-
-- plain = gaim_unescape_html(message);
-+ plain = gaim2_unescape_html(message);
- msg = charset_convert(plain, "UTF-8", "CP1250");
- g_free(plain);
- gg_send_message_confer(info->session, GG_CLASS_CHAT, count, uins,
-@@ -1784,32 +1784,32 @@ static int ggp_chat_send(GaimConnection
- g_free(uins);
-
- serv_got_chat_in(gc, id,
-- gaim_account_get_username(gaim_connection_get_account(gc)),
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)),
- 0, message, time(NULL));
-
- return 0;
- }
- /* }}} */
-
--/* static void ggp_keepalive(GaimConnection *gc) {{{ */
--static void ggp_keepalive(GaimConnection *gc)
-+/* static void ggp_keepalive(Gaim2Connection *gc) {{{ */
-+static void ggp_keepalive(Gaim2Connection *gc)
- {
- GGPInfo *info = gc->proto_data;
-
-- /* gaim_debug_info("gg", "Keeping connection alive....\n"); */
-+ /* gaim2_debug_info("gg", "Keeping connection alive....\n"); */
-
- if (gg_ping(info->session) < 0) {
-- gaim_debug_info("gg", "Not connected to the server "
-+ gaim2_debug_info("gg", "Not connected to the server "
- "or gg_session is not correct\n");
-- gaim_connection_error(gc, _("Not connected to the server."));
-+ gaim2_connection_error(gc, _("Not connected to the server."));
- }
- }
- /* }}} */
-
--/* static void ggp_register_user(GaimAccount *account) {{{ */
--static void ggp_register_user(GaimAccount *account)
-+/* static void ggp_register_user(Gaim2Account *account) {{{ */
-+static void ggp_register_user(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- GGPInfo *info;
-
- info = gc->proto_data = g_new0(GGPInfo, 1);
-@@ -1818,41 +1818,41 @@ static void ggp_register_user(GaimAccoun
- }
- /* }}} */
-
--/* static GList *ggp_actions(GaimPlugin *plugin, gpointer context) {{{ */
--static GList *ggp_actions(GaimPlugin *plugin, gpointer context)
-+/* static GList *ggp_actions(Gaim2Plugin *plugin, gpointer context) {{{ */
-+static GList *ggp_actions(Gaim2Plugin *plugin, gpointer context)
- {
- GList *m = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- act = gaim_plugin_action_new(_("Find buddies..."),
-+ act = gaim2_plugin_action_new(_("Find buddies..."),
- ggp_find_buddies);
- m = g_list_append(m, act);
-
- m = g_list_append(m, NULL);
-
-- act = gaim_plugin_action_new(_("Change password..."),
-+ act = gaim2_plugin_action_new(_("Change password..."),
- ggp_change_passwd);
- m = g_list_append(m, act);
-
- m = g_list_append(m, NULL);
-
-- act = gaim_plugin_action_new(_("Upload buddylist to Server"),
-+ act = gaim2_plugin_action_new(_("Upload buddylist to Server"),
- ggp_action_buddylist_put);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Download buddylist from Server"),
-+ act = gaim2_plugin_action_new(_("Download buddylist from Server"),
- ggp_action_buddylist_get);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Delete buddylist from Server"),
-+ act = gaim2_plugin_action_new(_("Delete buddylist from Server"),
- ggp_action_buddylist_delete);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Save buddylist to file..."),
-+ act = gaim2_plugin_action_new(_("Save buddylist to file..."),
- ggp_action_buddylist_save);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Load buddylist from file..."),
-+ act = gaim2_plugin_action_new(_("Load buddylist from file..."),
- ggp_action_buddylist_load);
- m = g_list_append(m, act);
-
-@@ -1861,7 +1861,7 @@ static GList *ggp_actions(GaimPlugin *pl
- /* }}} */
-
- /* prpl_info setup {{{ */
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_REGISTER_NOSCREENNAME,
- NULL, /* user_splits */
-@@ -1927,8 +1927,8 @@ static GaimPluginProtocolInfo prpl_info
- };
- /* }}} */
-
--/* GaimPluginInfo setup {{{ */
--static GaimPluginInfo info = {
-+/* Gaim2PluginInfo setup {{{ */
-+static Gaim2PluginInfo info = {
- GAIM_PLUGIN_MAGIC, /* magic */
- GAIM_MAJOR_VERSION, /* major_version */
- GAIM_MINOR_VERSION, /* minor_version */
-@@ -1958,46 +1958,46 @@ static GaimPluginInfo info = {
- };
- /* }}} */
-
--/* static void gaim_gg_debug_handler(int level, const char * format, va_list args) {{{ */
--static void gaim_gg_debug_handler(int level, const char * format, va_list args) {
-- GaimDebugLevel gaim_level;
-+/* static void gaim2_gg_debug_handler(int level, const char * format, va_list args) {{{ */
-+static void gaim2_gg_debug_handler(int level, const char * format, va_list args) {
-+ Gaim2DebugLevel gaim2_level;
- char *msg = g_strdup_vprintf(format, args);
-
- /* This is pretty pointless since the GG_DEBUG levels don't correspond to
-- * the gaim ones */
-+ * the gaim2 ones */
- switch (level) {
- case GG_DEBUG_FUNCTION:
-- gaim_level = GAIM_DEBUG_INFO;
-+ gaim2_level = GAIM_DEBUG_INFO;
- break;
- case GG_DEBUG_MISC:
- case GG_DEBUG_NET:
- case GG_DEBUG_DUMP:
- case GG_DEBUG_TRAFFIC:
- default:
-- gaim_level = GAIM_DEBUG_MISC;
-+ gaim2_level = GAIM_DEBUG_MISC;
- break;
- }
-
-- gaim_debug(gaim_level, "gg", msg);
-+ gaim2_debug(gaim2_level, "gg", msg);
- g_free(msg);
- }
- /* }}} */
-
- /*
- */
--/* static void init_plugin(GaimPlugin *plugin) {{{ */
--static void init_plugin(GaimPlugin *plugin)
-+/* static void init_plugin(Gaim2Plugin *plugin) {{{ */
-+static void init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_string_new(_("Nickname"),
-+ option = gaim2_account_option_string_new(_("Nickname"),
- "nick", _("Gadu-Gadu User"));
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
- my_protocol = plugin;
-
-- gg_debug_handler = gaim_gg_debug_handler;
-+ gg_debug_handler = gaim2_gg_debug_handler;
- }
- /* }}} */
-
-diff -prNu ./src/protocols/gg/gg.h ./src/protocols/gg/gg.h
---- ./src/protocols/gg/gg.h 2005-11-08 20:45:09.000000000 +0100
-+++ ./src/protocols/gg/gg.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file gg.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -35,7 +35,7 @@ typedef struct
-
- } GGPChat;
-
--typedef void (*GGPTokenCallback)(GaimConnection *);
-+typedef void (*GGPTokenCallback)(Gaim2Connection *);
-
- typedef struct
- {
-diff -prNu ./src/protocols/gg/lib/libgadu.c ./src/protocols/gg/lib/libgadu.c
---- ./src/protocols/gg/lib/libgadu.c 2005-11-25 01:32:45.000000000 +0100
-+++ ./src/protocols/gg/lib/libgadu.c 2006-01-05 15:11:05.000000000 +0100
-@@ -87,7 +87,7 @@ __attribute__ ((unused))
- #ifdef _WIN32
- /**
- * Deal with the fact that you can't select() on a win32 file fd.
-- * This makes it practically impossible to tie into gaim's event loop.
-+ * This makes it practically impossible to tie into gaim2's event loop.
- *
- * -This is thanks to Tor Lillqvist.
- * XXX - Move this to where the rest of the the win32 compatiblity stuff goes when we push the changes back to libgadu.
-diff -prNu ./src/protocols/gg/lib/libgadu-config.h ./src/protocols/gg/lib/libgadu-config.h
---- ./src/protocols/gg/lib/libgadu-config.h 2005-12-19 13:48:12.000000000 +0100
-+++ ./src/protocols/gg/lib/libgadu-config.h 2006-01-05 15:11:21.000000000 +0100
-@@ -28,7 +28,7 @@
- #undef __GG_LIBGADU_HAVE_PTHREAD
-
- /* Defined if libgadu was compiled and linked with TLS support. */
--/* Always undefined in Gaim. */
-+/* Always undefined in Gaim2. */
- #undef __GG_LIBGADU_HAVE_OPENSSL
-
- /* Include file containing uintXX_t declarations. */
-diff -prNu ./src/protocols/gg/Makefile.am ./src/protocols/gg/Makefile.am
---- ./src/protocols/gg/Makefile.am 2005-09-01 22:05:01.000000000 +0200
-+++ ./src/protocols/gg/Makefile.am 2006-01-05 13:03:06.000000000 +0100
-@@ -1,6 +1,6 @@
- EXTRA_DIST = Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- GGSOURCES = \
- lib/common.c \
-diff -prNu ./src/protocols/gg/search.c ./src/protocols/gg/search.c
---- ./src/protocols/gg/search.c 2005-11-08 20:45:09.000000000 +0100
-+++ ./src/protocols/gg/search.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file search.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -48,65 +48,65 @@ GGPSearchForm *ggp_search_form_new()
- }
- /* }}} */
-
--/* void ggp_search_start(GaimConnection *gc, GGPSearchForm *form) {{{ */
--void ggp_search_start(GaimConnection *gc, GGPSearchForm *form)
-+/* void ggp_search_start(Gaim2Connection *gc, GGPSearchForm *form) {{{ */
-+void ggp_search_start(Gaim2Connection *gc, GGPSearchForm *form)
- {
- GGPInfo *info = gc->proto_data;
- gg_pubdir50_t req;
-
-- gaim_debug_info("gg", "It's time to perform a search...\n");
-+ gaim2_debug_info("gg", "It's time to perform a search...\n");
-
- if ((req = gg_pubdir50_new(GG_PUBDIR50_SEARCH)) == NULL) {
-- gaim_debug_error("gg",
-+ gaim2_debug_error("gg",
- "ggp_bmenu_show_details: Unable to create req variable.\n");
- return;
- }
-
- if (form->uin != NULL) {
-- gaim_debug_info("gg", " uin: %s\n", form->uin);
-+ gaim2_debug_info("gg", " uin: %s\n", form->uin);
- gg_pubdir50_add(req, GG_PUBDIR50_UIN, form->uin);
- } else {
- if (form->lastname != NULL) {
-- gaim_debug_info("gg", " lastname: %s\n", form->lastname);
-+ gaim2_debug_info("gg", " lastname: %s\n", form->lastname);
- gg_pubdir50_add(req, GG_PUBDIR50_LASTNAME, form->lastname);
- }
-
- if (form->firstname != NULL) {
-- gaim_debug_info("gg", " firstname: %s\n", form->firstname);
-+ gaim2_debug_info("gg", " firstname: %s\n", form->firstname);
- gg_pubdir50_add(req, GG_PUBDIR50_FIRSTNAME, form->firstname);
- }
-
- if (form->nickname != NULL) {
-- gaim_debug_info("gg", " nickname: %s\n", form->nickname);
-+ gaim2_debug_info("gg", " nickname: %s\n", form->nickname);
- gg_pubdir50_add(req, GG_PUBDIR50_NICKNAME, form->nickname);
- }
-
- if (form->city != NULL) {
-- gaim_debug_info("gg", " city: %s\n", form->city);
-+ gaim2_debug_info("gg", " city: %s\n", form->city);
- gg_pubdir50_add(req, GG_PUBDIR50_CITY, form->city);
- }
-
- if (form->birthyear != NULL) {
-- gaim_debug_info("gg", " birthyear: %s\n", form->birthyear);
-+ gaim2_debug_info("gg", " birthyear: %s\n", form->birthyear);
- gg_pubdir50_add(req, GG_PUBDIR50_BIRTHYEAR, form->birthyear);
- }
-
- if (form->gender != NULL) {
-- gaim_debug_info("gg", " gender: %s\n", form->gender);
-+ gaim2_debug_info("gg", " gender: %s\n", form->gender);
- gg_pubdir50_add(req, GG_PUBDIR50_GENDER, form->gender);
- }
-
- if (form->active != NULL) {
-- gaim_debug_info("gg", " active: %s\n", form->active);
-+ gaim2_debug_info("gg", " active: %s\n", form->active);
- gg_pubdir50_add(req, GG_PUBDIR50_ACTIVE, form->active);
- }
- }
-
-- gaim_debug_info("gg", "offset: %s\n", form->offset);
-+ gaim2_debug_info("gg", "offset: %s\n", form->offset);
- gg_pubdir50_add(req, GG_PUBDIR50_START, g_strdup(form->offset));
-
- if (gg_pubdir50(info->session, req) == 0) {
-- gaim_debug_warning("gg", "ggp_bmenu_show_details: Search failed.\n");
-+ gaim2_debug_warning("gg", "ggp_bmenu_show_details: Search failed.\n");
- return;
- }
-
-diff -prNu ./src/protocols/gg/search.h ./src/protocols/gg/search.h
---- ./src/protocols/gg/search.h 2005-12-04 19:19:53.000000000 +0100
-+++ ./src/protocols/gg/search.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file search.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -58,11 +58,11 @@ ggp_search_form_new(void);
- /**
- * Initiate a search in the public directory.
- *
-- * @param gc GaimConnection.
-+ * @param gc Gaim2Connection.
- * @param form Filled in GGPSearchForm.
- */
- void
--ggp_search_start(GaimConnection *gc, GGPSearchForm *form);
-+ggp_search_start(Gaim2Connection *gc, GGPSearchForm *form);
-
- /*
- * Return converted to the UTF-8 value of the specified field.
-diff -prNu ./src/protocols/gg/utils.c ./src/protocols/gg/utils.c
---- ./src/protocols/gg/utils.c 2005-12-06 20:50:47.000000000 +0100
-+++ ./src/protocols/gg/utils.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file utils.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -62,7 +62,7 @@ char *charset_convert(const gchar *locst
- msg = g_convert_with_fallback(locstr, strlen(locstr), encdst, encsrc,
- "?", NULL, NULL, &err);
- if (err != NULL) {
-- gaim_debug_error("gg", "Error converting from %s to %s: %s\n",
-+ gaim2_debug_error("gg", "Error converting from %s to %s: %s\n",
- encsrc, encdst, err->message);
- g_error_free(err);
- }
-@@ -75,25 +75,25 @@ char *charset_convert(const gchar *locst
- }
- /* }}} */
-
--/* ggp_get_uin(GaimAccount *account) {{{ */
--uin_t ggp_get_uin(GaimAccount *account)
-+/* ggp_get_uin(Gaim2Account *account) {{{ */
-+uin_t ggp_get_uin(Gaim2Account *account)
- {
-- return ggp_str_to_uin(gaim_account_get_username(account));
-+ return ggp_str_to_uin(gaim2_account_get_username(account));
- }
- /* }}} */
-
--/* char *ggp_buddy_get_name(GaimConnection *gc, const uin_t uin) {{{ */
--char *ggp_buddy_get_name(GaimConnection *gc, const uin_t uin)
-+/* char *ggp_buddy_get_name(Gaim2Connection *gc, const uin_t uin) {{{ */
-+char *ggp_buddy_get_name(Gaim2Connection *gc, const uin_t uin)
- {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- gchar *str_uin;
-
- str_uin = g_strdup_printf("%lu", (unsigned long int)uin);
-
-- buddy = gaim_find_buddy(gaim_connection_get_account(gc), str_uin);
-+ buddy = gaim2_find_buddy(gaim2_connection_get_account(gc), str_uin);
- if (buddy != NULL) {
- g_free(str_uin);
-- return g_strdup(gaim_buddy_get_alias(buddy));
-+ return g_strdup(gaim2_buddy_get_alias(buddy));
- } else {
- return str_uin;
- }
-diff -prNu ./src/protocols/gg/utils.h ./src/protocols/gg/utils.h
---- ./src/protocols/gg/utils.h 2005-12-06 20:50:47.000000000 +0100
-+++ ./src/protocols/gg/utils.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file utils.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Bartosz Oler <bartosz@bzimage.us>
- *
-@@ -68,18 +68,18 @@ charset_convert(const gchar *locstr, con
- * @return UIN of an account.
- */
- uin_t
--ggp_get_uin(GaimAccount *account);
-+ggp_get_uin(Gaim2Account *account);
-
- /**
- * Returns the best name of a buddy from the buddylist.
- *
-- * @param gc GaimConnection instance.
-+ * @param gc Gaim2Connection instance.
- * @param uin UIN of the buddy.
- *
- * @return Name of the buddy, or UIN converted to string.
- */
- char *
--ggp_buddy_get_name(GaimConnection *gc, const uin_t uin);
-+ggp_buddy_get_name(Gaim2Connection *gc, const uin_t uin);
-
- #endif /* _GAIM_GG_UTILS_H */
-
-diff -prNu ./src/protocols/irc/cmds.c ./src/protocols/irc/cmds.c
---- ./src/protocols/irc/cmds.c 2005-12-29 02:30:08.000000000 +0100
-+++ ./src/protocols/irc/cmds.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file cmds.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003, Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -34,17 +34,17 @@ static void irc_do_mode(struct irc_conn
-
- int irc_cmd_default(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
- {
-- GaimConversation *convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, target, irc->account);
-+ Gaim2Conversation *convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, target, irc->account);
- char *buf;
-
- if (!convo)
- return 1;
-
- buf = g_strdup_printf(_("Unknown command: %s"), cmd);
-- if (gaim_conversation_get_type(convo) == GAIM_CONV_TYPE_IM)
-- gaim_conv_im_write(GAIM_CONV_IM(convo), "", buf, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ if (gaim2_conversation_get_type(convo) == GAIM_CONV_TYPE_IM)
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), "", buf, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- else
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", buf, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "", buf, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- g_free(buf);
-
- return 1;
-@@ -55,8 +55,8 @@ int irc_cmd_away(struct irc_conn *irc, c
- char *buf, *message;
-
- if (args[0] && strcmp(cmd, "back")) {
-- message = gaim_markup_strip_html(args[0]);
-- gaim_util_chrreplace(message, '\n', ' ');
-+ message = gaim2_markup_strip_html(args[0]);
-+ gaim2_util_chrreplace(message, '\n', ' ');
- buf = irc_format(irc, "v:", "AWAY", message);
- g_free(message);
- } else {
-@@ -70,10 +70,10 @@ int irc_cmd_away(struct irc_conn *irc, c
-
- int irc_cmd_ctcp_action(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- char *action, *escaped, *dst, **newargs;
- const char *src;
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
- if (!args || !args[0] || !gc)
- return 0;
-@@ -107,19 +107,19 @@ int irc_cmd_ctcp_action(struct irc_conn
- g_free(newargs[1]);
- g_free(newargs);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, target, irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, target, irc->account);
- if (convo) {
- escaped = g_markup_escape_text(args[0], -1);
- action = g_strdup_printf("/me %s", escaped);
- g_free(escaped);
- if (action[strlen(action) - 1] == '\n')
- action[strlen(action) - 1] = '\0';
-- if (gaim_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT)
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
-- gaim_connection_get_display_name(gc),
-+ if (gaim2_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT)
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
-+ gaim2_connection_get_display_name(gc),
- 0, action, time(NULL));
- else
-- gaim_conv_im_write(GAIM_CONV_IM(convo), gaim_connection_get_display_name(gc),
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), gaim2_connection_get_display_name(gc),
- action, 0, time(NULL));
- g_free(action);
- }
-@@ -161,12 +161,12 @@ int irc_cmd_join(struct irc_conn *irc, c
- int irc_cmd_kick(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
- {
- char *buf;
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
- if (!args || !args[0])
- return 0;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, target, irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, target, irc->account);
- if (!convo)
- return 0;
-
-@@ -182,14 +182,14 @@ int irc_cmd_kick(struct irc_conn *irc, c
-
- int irc_cmd_list(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
- {
-- gaim_roomlist_show_with_account(irc->account);
-+ gaim2_roomlist_show_with_account(irc->account);
-
- return 0;
- }
-
- int irc_cmd_mode(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *buf;
-
- if (!args)
-@@ -207,8 +207,8 @@ int irc_cmd_mode(struct irc_conn *irc, c
- } else if (!strcmp(cmd, "umode")) {
- if (!args[0])
- return 0;
-- gc = gaim_account_get_connection(irc->account);
-- buf = irc_format(irc, "vnv", "MODE", gaim_connection_get_display_name(gc), args[0]);
-+ gc = gaim2_account_get_connection(irc->account);
-+ buf = irc_format(irc, "vnv", "MODE", gaim2_connection_get_display_name(gc), args[0]);
- } else {
- return 0;
- }
-@@ -270,7 +270,7 @@ int irc_cmd_op(struct irc_conn *irc, con
- sign = "-";
- mode = "v";
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "invalid 'op' command '%s'\n", cmd);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "invalid 'op' command '%s'\n", cmd);
- return 0;
- }
-
-@@ -363,7 +363,7 @@ int irc_cmd_quit(struct irc_conn *irc, c
-
- if (!irc->quitting) {
- /*
-- * Use gaim_account_get_string(irc->account, "quitmsg", IRC_DEFAULT_QUIT)
-+ * Use gaim2_account_get_string(irc->account, "quitmsg", IRC_DEFAULT_QUIT)
- * and uncomment the appropriate account preference in irc.c if we
- * decide we want custom quit messages.
- */
-@@ -393,18 +393,18 @@ int irc_cmd_quote(struct irc_conn *irc,
-
- int irc_cmd_query(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
- {
-- GaimConversation *convo;
-- GaimConnection *gc;
-+ Gaim2Conversation *convo;
-+ Gaim2Connection *gc;
-
- if (!args || !args[0])
- return 0;
-
-- convo = gaim_conversation_new(GAIM_CONV_TYPE_IM, irc->account, args[0]);
-+ convo = gaim2_conversation_new(GAIM_CONV_TYPE_IM, irc->account, args[0]);
-
- if (args[1]) {
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- irc_cmd_privmsg(irc, cmd, target, args);
-- gaim_conv_im_write(GAIM_CONV_IM(convo), gaim_connection_get_display_name(gc),
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), gaim2_connection_get_display_name(gc),
- args[1], GAIM_MESSAGE_SEND, time(NULL));
- }
-
-@@ -463,28 +463,28 @@ int irc_cmd_topic(struct irc_conn *irc,
- {
- char *buf;
- const char *topic;
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
- if (!args)
- return 0;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, target, irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, target, irc->account);
- if (!convo)
- return 0;
-
- if (!args[0]) {
-- topic = gaim_conv_chat_get_topic (GAIM_CONV_CHAT(convo));
-+ topic = gaim2_conv_chat_get_topic (GAIM_CONV_CHAT(convo));
-
- if (topic) {
- char *tmp, *tmp2;
- tmp = g_markup_escape_text(topic, -1);
-- tmp2 = gaim_markup_linkify(tmp);
-+ tmp2 = gaim2_markup_linkify(tmp);
- buf = g_strdup_printf(_("current topic is: %s"), tmp2);
- g_free(tmp);
- g_free(tmp2);
- } else
- buf = g_strdup(_("No topic is set"));
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), target, buf, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), target, buf, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- g_free(buf);
-
- return 0;
-diff -prNu ./src/protocols/irc/dcc_send.c ./src/protocols/irc/dcc_send.c
---- ./src/protocols/irc/dcc_send.c 2006-01-05 06:04:06.000000000 +0100
-+++ ./src/protocols/irc/dcc_send.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,10 +1,10 @@
- /**
- * @file dcc_send.c Functions used in sending files with DCC SEND
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2004, Timothy T Ringenbach <omarvo@hotmail.com>
-- * Copyright (C) 2003, Robbert Haarman <gaim@inglorion.net>
-+ * Copyright (C) 2003, Robbert Haarman <gaim2@inglorion.net>
- *
- * 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
-@@ -36,7 +36,7 @@ struct irc_xfer_rx_data {
- gchar *ip;
- };
-
--static void irc_dccsend_recv_destroy(GaimXfer *xfer)
-+static void irc_dccsend_recv_destroy(Gaim2Xfer *xfer)
- {
- struct irc_xfer_rx_data *xd = xfer->data;
-
-@@ -51,24 +51,24 @@ static void irc_dccsend_recv_destroy(Gai
- * It sends the acknowledgement (in the form of a total byte count as an
- * unsigned 4 byte integer in network byte order)
- */
--static void irc_dccsend_recv_ack(GaimXfer *xfer, const guchar *data, size_t size) {
-+static void irc_dccsend_recv_ack(Gaim2Xfer *xfer, const guchar *data, size_t size) {
- unsigned long l;
-
- l = htonl(xfer->bytes_sent);
- write(xfer->fd, &l, sizeof(l));
- }
-
--static void irc_dccsend_recv_init(GaimXfer *xfer) {
-+static void irc_dccsend_recv_init(Gaim2Xfer *xfer) {
- struct irc_xfer_rx_data *xd = xfer->data;
-
-- gaim_xfer_start(xfer, -1, xd->ip, xfer->remote_port);
-+ gaim2_xfer_start(xfer, -1, xd->ip, xfer->remote_port);
- g_free(xd->ip);
- xd->ip = NULL;
- }
-
- /* This function makes the necessary arrangements for receiving files */
- void irc_dccsend_recv(struct irc_conn *irc, const char *from, const char *msg) {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct irc_xfer_rx_data *xd;
- gchar **token;
- struct in_addr addr;
-@@ -107,11 +107,11 @@ void irc_dccsend_recv(struct irc_conn *i
- }
- i++;
-
-- xfer = gaim_xfer_new(irc->account, GAIM_XFER_RECEIVE, from);
-+ xfer = gaim2_xfer_new(irc->account, GAIM_XFER_RECEIVE, from);
- xd = g_new0(struct irc_xfer_rx_data, 1);
- xfer->data = xd;
-
-- gaim_xfer_set_filename(xfer, filename->str);
-+ gaim2_xfer_set_filename(xfer, filename->str);
- xfer->remote_port = atoi(token[i+1]);
-
- nip = strtoul(token[i], NULL, 10);
-@@ -121,18 +121,18 @@ void irc_dccsend_recv(struct irc_conn *i
- } else {
- xd->ip = g_strdup(token[i]);
- }
-- gaim_debug(GAIM_DEBUG_INFO, "irc", "Receiving file from %s\n",
-+ gaim2_debug(GAIM_DEBUG_INFO, "irc", "Receiving file from %s\n",
- xd->ip);
-- gaim_xfer_set_size(xfer, token[i+2] ? atoi(token[i+2]) : 0);
-+ gaim2_xfer_set_size(xfer, token[i+2] ? atoi(token[i+2]) : 0);
-
-- gaim_xfer_set_init_fnc(xfer, irc_dccsend_recv_init);
-- gaim_xfer_set_ack_fnc(xfer, irc_dccsend_recv_ack);
-+ gaim2_xfer_set_init_fnc(xfer, irc_dccsend_recv_init);
-+ gaim2_xfer_set_ack_fnc(xfer, irc_dccsend_recv_ack);
-
-- gaim_xfer_set_end_fnc(xfer, irc_dccsend_recv_destroy);
-- gaim_xfer_set_request_denied_fnc(xfer, irc_dccsend_recv_destroy);
-- gaim_xfer_set_cancel_send_fnc(xfer, irc_dccsend_recv_destroy);
-+ gaim2_xfer_set_end_fnc(xfer, irc_dccsend_recv_destroy);
-+ gaim2_xfer_set_request_denied_fnc(xfer, irc_dccsend_recv_destroy);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, irc_dccsend_recv_destroy);
-
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- g_strfreev(token);
- g_string_free(filename, TRUE);
- }
-@@ -148,7 +148,7 @@ struct irc_xfer_send_data {
- guint rxlen;
- };
-
--static void irc_dccsend_send_destroy(GaimXfer *xfer)
-+static void irc_dccsend_send_destroy(Gaim2Xfer *xfer)
- {
- struct irc_xfer_send_data *xd = xfer->data;
-
-@@ -156,7 +156,7 @@ static void irc_dccsend_send_destroy(Gai
- return;
-
- if (xd->inpa > 0)
-- gaim_input_remove(xd->inpa);
-+ gaim2_input_remove(xd->inpa);
- if (xd->fd != -1)
- close(xd->fd);
-
-@@ -167,15 +167,15 @@ static void irc_dccsend_send_destroy(Gai
- }
-
- /* just in case you were wondering, this is why DCC is gay */
--static void irc_dccsend_send_read(gpointer data, int source, GaimInputCondition cond)
-+static void irc_dccsend_send_read(gpointer data, int source, Gaim2InputCondition cond)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
- struct irc_xfer_send_data *xd = xfer->data;
- char *buffer[16];
- int len;
-
- if ((len = read(source, buffer, sizeof(buffer))) <= 0) {
-- gaim_input_remove(xd->inpa);
-+ gaim2_input_remove(xd->inpa);
- xd->inpa = 0;
- return;
- }
-@@ -202,11 +202,11 @@ static void irc_dccsend_send_read(gpoint
- xd->rxqueue = NULL;
- }
-
-- if (acked >= gaim_xfer_get_size(xfer)) {
-- gaim_input_remove(xd->inpa);
-+ if (acked >= gaim2_xfer_get_size(xfer)) {
-+ gaim2_input_remove(xd->inpa);
- xd->inpa = 0;
-- gaim_xfer_set_completed(xfer, TRUE);
-- gaim_xfer_end(xfer);
-+ gaim2_xfer_set_completed(xfer, TRUE);
-+ gaim2_xfer_end(xfer);
- return;
- }
-
-@@ -214,19 +214,19 @@ static void irc_dccsend_send_read(gpoint
- }
- }
-
--static gssize irc_dccsend_send_write(const guchar *buffer, size_t size, GaimXfer *xfer)
-+static gssize irc_dccsend_send_write(const guchar *buffer, size_t size, Gaim2Xfer *xfer)
- {
- gssize s;
-
-- s = MIN(gaim_xfer_get_bytes_remaining(xfer), size);
-+ s = MIN(gaim2_xfer_get_bytes_remaining(xfer), size);
- if (!s)
- return 0;
-
- return write(xfer->fd, buffer, s);
- }
-
--static void irc_dccsend_send_connected(gpointer data, int source, GaimInputCondition cond) {
-- GaimXfer *xfer = (GaimXfer *) data;
-+static void irc_dccsend_send_connected(gpointer data, int source, Gaim2InputCondition cond) {
-+ Gaim2Xfer *xfer = (Gaim2Xfer *) data;
- struct irc_xfer_send_data *xd = xfer->data;
- int conn;
-
-@@ -236,26 +236,26 @@ static void irc_dccsend_send_connected(g
- * to the nonblocking nature of the listening socket, so we'll
- * just try again next time */
- /* Let's print an error message anyway */
-- gaim_debug_warning("irc", "accept: %s\n", strerror(errno));
-+ gaim2_debug_warning("irc", "accept: %s\n", strerror(errno));
- return;
- }
-
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- close(xd->fd);
- xd->fd = -1;
-
-- xd->inpa = gaim_input_add(conn, GAIM_INPUT_READ, irc_dccsend_send_read, xfer);
-+ xd->inpa = gaim2_input_add(conn, GAIM_INPUT_READ, irc_dccsend_send_read, xfer);
- /* Start the transfer */
-- gaim_xfer_start(xfer, conn, NULL, 0);
-+ gaim2_xfer_start(xfer, conn, NULL, 0);
- }
-
- /*
- * This function is called after the user has selected a file to send.
- */
--static void irc_dccsend_send_init(GaimXfer *xfer) {
-+static void irc_dccsend_send_init(Gaim2Xfer *xfer) {
- struct irc_xfer_send_data *xd = xfer->data;
-- GaimConnection *gc = gaim_account_get_connection(gaim_xfer_get_account(xfer));
-+ Gaim2Connection *gc = gaim2_account_get_connection(gaim2_xfer_get_account(xfer));
- struct irc_conn *irc = gc->proto_data;
- int sock;
- const char *arg[2];
-@@ -266,26 +266,26 @@ static void irc_dccsend_send_init(GaimXf
- xfer->filename = g_path_get_basename(xfer->local_filename);
-
- /* Create a listening socket */
-- sock = gaim_network_listen_range(0, 0, SOCK_STREAM);
-+ sock = gaim2_network_listen_range(0, 0, SOCK_STREAM);
-
- if (sock < 0) {
-- gaim_notify_error(gc, NULL, _("File Transfer Failed"),
-- _("Gaim could not open a listening port."));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_notify_error(gc, NULL, _("File Transfer Failed"),
-+ _("Gaim2 could not open a listening port."));
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-
- xd->fd = sock;
-
-- port = gaim_network_get_port_from_fd(sock);
-- gaim_debug_misc("irc", "port is %hu\n", port);
-+ port = gaim2_network_get_port_from_fd(sock);
-+ gaim2_debug_misc("irc", "port is %hu\n", port);
- /* Monitor the listening socket */
-- xfer->watcher = gaim_input_add(sock, GAIM_INPUT_READ,
-+ xfer->watcher = gaim2_input_add(sock, GAIM_INPUT_READ,
- irc_dccsend_send_connected, xfer);
-
- /* Send the intended recipient the DCC request */
- arg[0] = xfer->who;
-- inet_aton(gaim_network_get_my_ip(irc->fd), &addr);
-+ inet_aton(gaim2_network_get_my_ip(irc->fd), &addr);
- arg[1] = tmp = g_strdup_printf("\001DCC SEND \"%s\" %u %hu %" G_GSIZE_FORMAT "\001",
- xfer->filename, ntohl(addr.s_addr),
- port, xfer->size);
-@@ -294,38 +294,38 @@ static void irc_dccsend_send_init(GaimXf
- g_free(tmp);
- }
-
--GaimXfer *irc_dccsend_new_xfer(GaimConnection *gc, const char *who) {
-- GaimXfer *xfer;
-+Gaim2Xfer *irc_dccsend_new_xfer(Gaim2Connection *gc, const char *who) {
-+ Gaim2Xfer *xfer;
- struct irc_xfer_send_data *xd;
-
- /* Build the file transfer handle */
-- xfer = gaim_xfer_new(gaim_connection_get_account(gc), GAIM_XFER_SEND, who);
-+ xfer = gaim2_xfer_new(gaim2_connection_get_account(gc), GAIM_XFER_SEND, who);
-
- xd = g_new0(struct irc_xfer_send_data, 1);
- xd->fd = -1;
- xfer->data = xd;
-
- /* Setup our I/O op functions */
-- gaim_xfer_set_init_fnc(xfer, irc_dccsend_send_init);
-- gaim_xfer_set_write_fnc(xfer, irc_dccsend_send_write);
-- gaim_xfer_set_end_fnc(xfer, irc_dccsend_send_destroy);
-- gaim_xfer_set_request_denied_fnc(xfer, irc_dccsend_send_destroy);
-- gaim_xfer_set_cancel_send_fnc(xfer, irc_dccsend_send_destroy);
-+ gaim2_xfer_set_init_fnc(xfer, irc_dccsend_send_init);
-+ gaim2_xfer_set_write_fnc(xfer, irc_dccsend_send_write);
-+ gaim2_xfer_set_end_fnc(xfer, irc_dccsend_send_destroy);
-+ gaim2_xfer_set_request_denied_fnc(xfer, irc_dccsend_send_destroy);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, irc_dccsend_send_destroy);
-
- return xfer;
- }
-
- /**
-- * Gaim calls this function when the user selects Send File from the
-+ * Gaim2 calls this function when the user selects Send File from the
- * buddy menu
-- * It sets up the GaimXfer struct and tells Gaim to go ahead
-+ * It sets up the Gaim2Xfer struct and tells Gaim2 to go ahead
- */
--void irc_dccsend_send_file(GaimConnection *gc, const char *who, const char *file) {
-- GaimXfer *xfer = irc_dccsend_new_xfer(gc, who);
-+void irc_dccsend_send_file(Gaim2Connection *gc, const char *who, const char *file) {
-+ Gaim2Xfer *xfer = irc_dccsend_new_xfer(gc, who);
-
- /* Perform the request */
- if (file)
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
- else
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-diff -prNu ./src/protocols/irc/irc.c ./src/protocols/irc/irc.c
---- ./src/protocols/irc/irc.c 2005-12-25 20:09:22.000000000 +0100
-+++ ./src/protocols/irc/irc.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file irc.c
- *
-- * gaim
-+ * gaim2
- *
-- * Copyright (C) 2003, Robbert Haarman <gaim@inglorion.net>
-+ * Copyright (C) 2003, Robbert Haarman <gaim2@inglorion.net>
- * Copyright (C) 2003, Ethan Blanton <eblanton@cs.purdue.edu>
- * Copyright (C) 2000-2003, Rob Flynn <rob@tgflinux.com>
- * Copyright (C) 1998-1999, Mark Spencer <markster@marko.net>
-@@ -39,48 +39,48 @@
-
- static void irc_buddy_append(char *name, struct irc_buddy *ib, GString *string);
-
--static const char *irc_blist_icon(GaimAccount *a, GaimBuddy *b);
--static void irc_blist_emblems(GaimBuddy *b, const char **se, const char **sw, const char **nw, const char **ne);
--static GList *irc_status_types(GaimAccount *account);
--static GList *irc_actions(GaimPlugin *plugin, gpointer context);
--/* static GList *irc_chat_info(GaimConnection *gc); */
--static void irc_login(GaimAccount *account);
--static void irc_login_cb_ssl(gpointer data, GaimSslConnection *gsc, GaimInputCondition cond);
--static void irc_login_cb(gpointer data, gint source, GaimInputCondition cond);
--static void irc_ssl_connect_failure(GaimSslConnection *gsc, GaimSslErrorType error, gpointer data);
--static void irc_close(GaimConnection *gc);
--static int irc_im_send(GaimConnection *gc, const char *who, const char *what, GaimMessageFlags flags);
--static int irc_chat_send(GaimConnection *gc, int id, const char *what, GaimMessageFlags flags);
--static void irc_chat_join (GaimConnection *gc, GHashTable *data);
--static void irc_input_cb(gpointer data, gint source, GaimInputCondition cond);
--static void irc_input_cb_ssl(gpointer data, GaimSslConnection *gsc, GaimInputCondition cond);
-+static const char *irc_blist_icon(Gaim2Account *a, Gaim2Buddy *b);
-+static void irc_blist_emblems(Gaim2Buddy *b, const char **se, const char **sw, const char **nw, const char **ne);
-+static GList *irc_status_types(Gaim2Account *account);
-+static GList *irc_actions(Gaim2Plugin *plugin, gpointer context);
-+/* static GList *irc_chat_info(Gaim2Connection *gc); */
-+static void irc_login(Gaim2Account *account);
-+static void irc_login_cb_ssl(gpointer data, Gaim2SslConnection *gsc, Gaim2InputCondition cond);
-+static void irc_login_cb(gpointer data, gint source, Gaim2InputCondition cond);
-+static void irc_ssl_connect_failure(Gaim2SslConnection *gsc, Gaim2SslErrorType error, gpointer data);
-+static void irc_close(Gaim2Connection *gc);
-+static int irc_im_send(Gaim2Connection *gc, const char *who, const char *what, Gaim2MessageFlags flags);
-+static int irc_chat_send(Gaim2Connection *gc, int id, const char *what, Gaim2MessageFlags flags);
-+static void irc_chat_join (Gaim2Connection *gc, GHashTable *data);
-+static void irc_input_cb(gpointer data, gint source, Gaim2InputCondition cond);
-+static void irc_input_cb_ssl(gpointer data, Gaim2SslConnection *gsc, Gaim2InputCondition cond);
-
- static guint irc_nick_hash(const char *nick);
- static gboolean irc_nick_equal(const char *nick1, const char *nick2);
- static void irc_buddy_free(struct irc_buddy *ib);
-
--static GaimPlugin *_irc_plugin = NULL;
-+static Gaim2Plugin *_irc_plugin = NULL;
-
- static const char *status_chars = "@+%&";
-
--static void irc_view_motd(GaimPluginAction *action)
-+static void irc_view_motd(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- struct irc_conn *irc;
- char *title;
-
- if (gc == NULL || gc->proto_data == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "got MOTD request for NULL gc\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "got MOTD request for NULL gc\n");
- return;
- }
- irc = gc->proto_data;
- if (irc->motd == NULL) {
-- gaim_notify_error(gc, _("Error displaying MOTD"), _("No MOTD available"),
-+ gaim2_notify_error(gc, _("Error displaying MOTD"), _("No MOTD available"),
- _("There is no MOTD associated with this connection."));
- return;
- }
- title = g_strdup_printf(_("MOTD for %s"), irc->server);
-- gaim_notify_formatted(gc, title, title, NULL, irc->motd->str, NULL, NULL);
-+ gaim2_notify_formatted(gc, title, title, NULL, irc->motd->str, NULL, NULL);
- }
-
- int irc_send(struct irc_conn *irc, const char *buf)
-@@ -88,17 +88,17 @@ int irc_send(struct irc_conn *irc, const
- int ret;
-
- if (irc->gsc) {
-- ret = gaim_ssl_write(irc->gsc, buf, strlen(buf));
-+ ret = gaim2_ssl_write(irc->gsc, buf, strlen(buf));
- } else {
- if (irc->fd < 0)
- return -1;
- ret = write(irc->fd, buf, strlen(buf));
- }
-
-- /* gaim_debug(GAIM_DEBUG_MISC, "irc", "sent%s: %s",
-+ /* gaim2_debug(GAIM_DEBUG_MISC, "irc", "sent%s: %s",
- irc->gsc ? " (ssl)" : "", buf); */
- if (ret < 0) {
-- gaim_connection_error(gaim_account_get_connection(irc->account),
-+ gaim2_connection_error(gaim2_account_get_connection(irc->account),
- _("Server has disconnected"));
- }
-
-@@ -144,52 +144,52 @@ static void irc_ison_one(struct irc_conn
- }
-
-
--static const char *irc_blist_icon(GaimAccount *a, GaimBuddy *b)
-+static const char *irc_blist_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- return "irc";
- }
-
--static void irc_blist_emblems(GaimBuddy *b, const char **se, const char **sw, const char **nw, const char **ne)
-+static void irc_blist_emblems(Gaim2Buddy *b, const char **se, const char **sw, const char **nw, const char **ne)
- {
-- GaimPresence *presence = gaim_buddy_get_presence(b);
-+ Gaim2Presence *presence = gaim2_buddy_get_presence(b);
-
-- if (gaim_presence_is_online(presence) == FALSE) {
-+ if (gaim2_presence_is_online(presence) == FALSE) {
- *se = "offline";
- }
- }
-
--static GList *irc_status_types(GaimAccount *account)
-+static GList *irc_status_types(Gaim2Account *account)
- {
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- GList *types = NULL;
-
-- type = gaim_status_type_new(GAIM_STATUS_AVAILABLE, NULL, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AVAILABLE, NULL, NULL, TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_AWAY, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_OFFLINE, NULL, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_OFFLINE, NULL, NULL, TRUE);
- types = g_list_append(types, type);
-
- return types;
- }
-
--static GList *irc_actions(GaimPlugin *plugin, gpointer context)
-+static GList *irc_actions(Gaim2Plugin *plugin, gpointer context)
- {
- GList *list = NULL;
-- GaimPluginAction *act = NULL;
-+ Gaim2PluginAction *act = NULL;
-
-- act = gaim_plugin_action_new(_("View MOTD"), irc_view_motd);
-+ act = gaim2_plugin_action_new(_("View MOTD"), irc_view_motd);
- list = g_list_append(list, act);
-
- return list;
- }
-
--static GList *irc_chat_join_info(GaimConnection *gc)
-+static GList *irc_chat_join_info(Gaim2Connection *gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -209,7 +209,7 @@ static GList *irc_chat_join_info(GaimCon
- return m;
- }
-
--static GHashTable *irc_chat_info_defaults(GaimConnection *gc, const char *chat_name)
-+static GHashTable *irc_chat_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
-
-@@ -221,19 +221,19 @@ static GHashTable *irc_chat_info_default
- return defaults;
- }
-
--static void irc_login(GaimAccount *account)
-+static void irc_login(Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- struct irc_conn *irc;
- char **userparts;
-- const char *username = gaim_account_get_username(account);
-+ const char *username = gaim2_account_get_username(account);
- int err;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- gc->flags |= GAIM_CONNECTION_NO_NEWLINES;
-
- if (strpbrk(username, " \t\v\r\n") != NULL) {
-- gaim_connection_error(gc, _("IRC nicks may not contain whitespace"));
-+ gaim2_connection_error(gc, _("IRC nicks may not contain whitespace"));
- return;
- }
-
-@@ -242,7 +242,7 @@ static void irc_login(GaimAccount *accou
- irc->account = account;
-
- userparts = g_strsplit(username, "@", 2);
-- gaim_connection_set_display_name(gc, userparts[0]);
-+ gaim2_connection_set_display_name(gc, userparts[0]);
- irc->server = g_strdup(userparts[1]);
- g_strfreev(userparts);
-
-@@ -253,42 +253,42 @@ static void irc_login(GaimAccount *accou
- irc->msgs = g_hash_table_new(g_str_hash, g_str_equal);
- irc_msg_table_build(irc);
-
-- gaim_connection_update_progress(gc, _("Connecting"), 1, 2);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 1, 2);
-
-- if (gaim_account_get_bool(account, "ssl", FALSE)) {
-- if (gaim_ssl_is_supported()) {
-- irc->gsc = gaim_ssl_connect(account, irc->server,
-- gaim_account_get_int(account, "port", IRC_DEFAULT_SSL_PORT),
-+ if (gaim2_account_get_bool(account, "ssl", FALSE)) {
-+ if (gaim2_ssl_is_supported()) {
-+ irc->gsc = gaim2_ssl_connect(account, irc->server,
-+ gaim2_account_get_int(account, "port", IRC_DEFAULT_SSL_PORT),
- irc_login_cb_ssl, irc_ssl_connect_failure, gc);
- } else {
-- gaim_connection_error(gc, _("SSL support unavailable"));
-+ gaim2_connection_error(gc, _("SSL support unavailable"));
- }
- }
-
- if (!irc->gsc) {
-
-- err = gaim_proxy_connect(account, irc->server,
-- gaim_account_get_int(account, "port", IRC_DEFAULT_PORT),
-+ err = gaim2_proxy_connect(account, irc->server,
-+ gaim2_account_get_int(account, "port", IRC_DEFAULT_PORT),
- irc_login_cb, gc);
-
-- if (err || !gaim_account_get_connection(account)) {
-- gaim_connection_error(gc, _("Couldn't create socket"));
-+ if (err || !gaim2_account_get_connection(account)) {
-+ gaim2_connection_error(gc, _("Couldn't create socket"));
- return;
- }
- }
- }
-
--static gboolean do_login(GaimConnection *gc) {
-+static gboolean do_login(Gaim2Connection *gc) {
- char *buf;
- char hostname[256];
- const char *username, *realname;
- struct irc_conn *irc = gc->proto_data;
-- const char *pass = gaim_connection_get_password(gc);
-+ const char *pass = gaim2_connection_get_password(gc);
-
- if (pass && *pass) {
- buf = irc_format(irc, "vv", "PASS", pass);
- if (irc_send(irc, buf) < 0) {
-- gaim_connection_error(gc, "Error sending password");
-+ gaim2_connection_error(gc, "Error sending password");
- g_free(buf);
- return FALSE;
- }
-@@ -297,19 +297,19 @@ static gboolean do_login(GaimConnection
-
- gethostname(hostname, sizeof(hostname));
- hostname[sizeof(hostname) - 1] = '\0';
-- username = gaim_account_get_string(irc->account, "username", "");
-- realname = gaim_account_get_string(irc->account, "realname", "");
-+ username = gaim2_account_get_string(irc->account, "username", "");
-+ realname = gaim2_account_get_string(irc->account, "realname", "");
- buf = irc_format(irc, "vvvv:", "USER", strlen(username) ? username : g_get_user_name(), hostname, irc->server,
- strlen(realname) ? realname : IRC_DEFAULT_ALIAS);
- if (irc_send(irc, buf) < 0) {
-- gaim_connection_error(gc, "Error registering with server");
-+ gaim2_connection_error(gc, "Error registering with server");
- g_free(buf);
- return FALSE;
- }
- g_free(buf);
-- buf = irc_format(irc, "vn", "NICK", gaim_connection_get_display_name(gc));
-+ buf = irc_format(irc, "vn", "NICK", gaim2_connection_get_display_name(gc));
- if (irc_send(irc, buf) < 0) {
-- gaim_connection_error(gc, "Error sending nickname");
-+ gaim2_connection_error(gc, "Error sending nickname");
- g_free(buf);
- return FALSE;
- }
-@@ -318,32 +318,32 @@ static gboolean do_login(GaimConnection
- return TRUE;
- }
-
--static void irc_login_cb_ssl(gpointer data, GaimSslConnection *gsc,
-- GaimInputCondition cond)
-+static void irc_login_cb_ssl(gpointer data, Gaim2SslConnection *gsc,
-+ Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct irc_conn *irc = gc->proto_data;
-
-- if(!g_list_find(gaim_connections_get_all(), gc)) {
-- gaim_ssl_close(gsc);
-+ if(!g_list_find(gaim2_connections_get_all(), gc)) {
-+ gaim2_ssl_close(gsc);
- return;
- }
-
- irc->gsc = gsc;
-
- if (do_login(gc)) {
-- gaim_ssl_input_add(gsc, irc_input_cb_ssl, gc);
-+ gaim2_ssl_input_add(gsc, irc_input_cb_ssl, gc);
- }
- }
-
--static void irc_login_cb(gpointer data, gint source, GaimInputCondition cond)
-+static void irc_login_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct irc_conn *irc = gc->proto_data;
-- GList *connections = gaim_connections_get_all();
-+ GList *connections = gaim2_connections_get_all();
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Couldn't connect to host"));
-+ gaim2_connection_error(gc, _("Couldn't connect to host"));
- return;
- }
-
-@@ -355,30 +355,30 @@ static void irc_login_cb(gpointer data,
- irc->fd = source;
-
- if (do_login(gc)) {
-- gc->inpa = gaim_input_add(irc->fd, GAIM_INPUT_READ, irc_input_cb, gc);
-+ gc->inpa = gaim2_input_add(irc->fd, GAIM_INPUT_READ, irc_input_cb, gc);
- }
- }
-
- static void
--irc_ssl_connect_failure(GaimSslConnection *gsc, GaimSslErrorType error,
-+irc_ssl_connect_failure(Gaim2SslConnection *gsc, Gaim2SslErrorType error,
- gpointer data)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct irc_conn *irc = gc->proto_data;
-
- switch(error) {
- case GAIM_SSL_CONNECT_FAILED:
-- gaim_connection_error(gc, _("Connection Failed"));
-+ gaim2_connection_error(gc, _("Connection Failed"));
- break;
- case GAIM_SSL_HANDSHAKE_FAILED:
-- gaim_connection_error(gc, _("SSL Handshake Failed"));
-+ gaim2_connection_error(gc, _("SSL Handshake Failed"));
- break;
- }
-
- irc->gsc = NULL;
- }
-
--static void irc_close(GaimConnection *gc)
-+static void irc_close(Gaim2Connection *gc)
- {
- struct irc_conn *irc = gc->proto_data;
-
-@@ -388,16 +388,16 @@ static void irc_close(GaimConnection *gc
- irc_cmd_quit(irc, "quit", NULL, NULL);
-
- if (gc->inpa)
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
-
- g_free(irc->inbuf);
- if (irc->gsc) {
-- gaim_ssl_close(irc->gsc);
-+ gaim2_ssl_close(irc->gsc);
- } else if (irc->fd > 0) {
- close(irc->fd);
- }
- if (irc->timer)
-- gaim_timeout_remove(irc->timer);
-+ gaim2_timeout_remove(irc->timer);
- g_hash_table_destroy(irc->cmds);
- g_hash_table_destroy(irc->msgs);
- g_hash_table_destroy(irc->buddies);
-@@ -407,7 +407,7 @@ static void irc_close(GaimConnection *gc
- g_free(irc);
- }
-
--static int irc_im_send(GaimConnection *gc, const char *who, const char *what, GaimMessageFlags flags)
-+static int irc_im_send(Gaim2Connection *gc, const char *who, const char *what, Gaim2MessageFlags flags)
- {
- struct irc_conn *irc = gc->proto_data;
- char *plain;
-@@ -418,7 +418,7 @@ static int irc_im_send(GaimConnection *g
- else
- args[0] = who;
-
-- plain = gaim_unescape_html(what);
-+ plain = gaim2_unescape_html(what);
- args[1] = plain;
-
- irc_cmd_privmsg(irc, "msg", NULL, args);
-@@ -426,7 +426,7 @@ static int irc_im_send(GaimConnection *g
- return 1;
- }
-
--static void irc_get_info(GaimConnection *gc, const char *who)
-+static void irc_get_info(Gaim2Connection *gc, const char *who)
- {
- struct irc_conn *irc = gc->proto_data;
- const char *args[2];
-@@ -435,23 +435,23 @@ static void irc_get_info(GaimConnection
- irc_cmd_whois(irc, "whois", NULL, args);
- }
-
--static void irc_set_status(GaimAccount *account, GaimStatus *status)
-+static void irc_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- struct irc_conn *irc = NULL;
- const char *args[1];
-- const char *status_id = gaim_status_get_id(status);
-+ const char *status_id = gaim2_status_get_id(status);
-
- if (gc)
- irc = gc->proto_data;
-
-- if (!gaim_status_is_active(status))
-+ if (!gaim2_status_is_active(status))
- return;
-
- args[0] = NULL;
-
- if (!strcmp(status_id, "away")) {
-- args[0] = gaim_status_get_attr_string(status, "message");
-+ args[0] = gaim2_status_get_attr_string(status, "message");
- if ((args[0] == NULL) || (*args[0] == '\0'))
- args[0] = _("Away");
- irc_cmd_away(irc, "away", NULL, args);
-@@ -460,7 +460,7 @@ static void irc_set_status(GaimAccount *
- }
- }
-
--static void irc_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void irc_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- struct irc_conn *irc = (struct irc_conn *)gc->proto_data;
- struct irc_buddy *ib = g_new0(struct irc_buddy, 1);
-@@ -474,7 +474,7 @@ static void irc_add_buddy(GaimConnection
- irc_ison_one(irc, ib);
- }
-
--static void irc_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void irc_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- struct irc_conn *irc = (struct irc_conn *)gc->proto_data;
- g_hash_table_remove(irc->buddies, buddy->name);
-@@ -503,16 +503,16 @@ static void read_input(struct irc_conn *
- }
- }
-
--static void irc_input_cb_ssl(gpointer data, GaimSslConnection *gsc,
-- GaimInputCondition cond)
-+static void irc_input_cb_ssl(gpointer data, Gaim2SslConnection *gsc,
-+ Gaim2InputCondition cond)
- {
-
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct irc_conn *irc = gc->proto_data;
- int len;
-
-- if(!g_list_find(gaim_connections_get_all(), gc)) {
-- gaim_ssl_close(gsc);
-+ if(!g_list_find(gaim2_connections_get_all(), gc)) {
-+ gaim2_ssl_close(gsc);
- return;
- }
-
-@@ -521,20 +521,20 @@ static void irc_input_cb_ssl(gpointer da
- irc->inbuf = g_realloc(irc->inbuf, irc->inbuflen);
- }
-
-- if ((len = gaim_ssl_read(gsc, irc->inbuf + irc->inbufused, IRC_INITIAL_BUFSIZE - 1)) < 0) {
-- gaim_connection_error(gc, _("Read error"));
-+ if ((len = gaim2_ssl_read(gsc, irc->inbuf + irc->inbufused, IRC_INITIAL_BUFSIZE - 1)) < 0) {
-+ gaim2_connection_error(gc, _("Read error"));
- return;
- } else if (len == 0) {
-- gaim_connection_error(gc, _("Server has disconnected"));
-+ gaim2_connection_error(gc, _("Server has disconnected"));
- return;
- }
-
- read_input(irc, len);
- }
-
--static void irc_input_cb(gpointer data, gint source, GaimInputCondition cond)
-+static void irc_input_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct irc_conn *irc = gc->proto_data;
- int len;
-
-@@ -544,17 +544,17 @@ static void irc_input_cb(gpointer data,
- }
-
- if ((len = read(irc->fd, irc->inbuf + irc->inbufused, IRC_INITIAL_BUFSIZE - 1)) < 0) {
-- gaim_connection_error(gc, _("Read error"));
-+ gaim2_connection_error(gc, _("Read error"));
- return;
- } else if (len == 0) {
-- gaim_connection_error(gc, _("Server has disconnected"));
-+ gaim2_connection_error(gc, _("Server has disconnected"));
- return;
- }
-
- read_input(irc, len);
- }
-
--static void irc_chat_join (GaimConnection *gc, GHashTable *data)
-+static void irc_chat_join (Gaim2Connection *gc, GHashTable *data)
- {
- struct irc_conn *irc = gc->proto_data;
- const char *args[2];
-@@ -568,46 +568,46 @@ static char *irc_get_chat_name(GHashTabl
- return g_strdup(g_hash_table_lookup(data, "channel"));
- }
-
--static void irc_chat_invite(GaimConnection *gc, int id, const char *message, const char *name)
-+static void irc_chat_invite(Gaim2Connection *gc, int id, const char *message, const char *name)
- {
- struct irc_conn *irc = gc->proto_data;
-- GaimConversation *convo = gaim_find_chat(gc, id);
-+ Gaim2Conversation *convo = gaim2_find_chat(gc, id);
- const char *args[2];
-
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got chat invite request for bogus chat\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Got chat invite request for bogus chat\n");
- return;
- }
- args[0] = name;
-- args[1] = gaim_conversation_get_name(convo);
-- irc_cmd_invite(irc, "invite", gaim_conversation_get_name(convo), args);
-+ args[1] = gaim2_conversation_get_name(convo);
-+ irc_cmd_invite(irc, "invite", gaim2_conversation_get_name(convo), args);
- }
-
-
--static void irc_chat_leave (GaimConnection *gc, int id)
-+static void irc_chat_leave (Gaim2Connection *gc, int id)
- {
- struct irc_conn *irc = gc->proto_data;
-- GaimConversation *convo = gaim_find_chat(gc, id);
-+ Gaim2Conversation *convo = gaim2_find_chat(gc, id);
- const char *args[2];
-
- if (!convo)
- return;
-
-- args[0] = gaim_conversation_get_name(convo);
-+ args[0] = gaim2_conversation_get_name(convo);
- args[1] = NULL;
-- irc_cmd_part(irc, "part", gaim_conversation_get_name(convo), args);
-+ irc_cmd_part(irc, "part", gaim2_conversation_get_name(convo), args);
- serv_got_chat_left(gc, id);
- }
-
--static int irc_chat_send(GaimConnection *gc, int id, const char *what, GaimMessageFlags flags)
-+static int irc_chat_send(Gaim2Connection *gc, int id, const char *what, Gaim2MessageFlags flags)
- {
- struct irc_conn *irc = gc->proto_data;
-- GaimConversation *convo = gaim_find_chat(gc, id);
-+ Gaim2Conversation *convo = gaim2_find_chat(gc, id);
- const char *args[2];
- char *tmp;
-
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "chat send on nonexistent chat\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "chat send on nonexistent chat\n");
- return -EINVAL;
- }
- #if 0
-@@ -615,13 +615,13 @@ static int irc_chat_send(GaimConnection
- return irc_parse_cmd(irc, convo->name, what + 1);
- }
- #endif
-- tmp = gaim_unescape_html(what);
-+ tmp = gaim2_unescape_html(what);
- args[0] = convo->name;
- args[1] = tmp;
-
- irc_cmd_privmsg(irc, "msg", NULL, args);
-
-- serv_got_chat_in(gc, id, gaim_connection_get_display_name(gc), 0, what, time(NULL));
-+ serv_got_chat_in(gc, id, gaim2_connection_get_display_name(gc), 0, what, time(NULL));
- g_free(tmp);
- return 0;
- }
-@@ -640,7 +640,7 @@ static guint irc_nick_hash(const char *n
-
- static gboolean irc_nick_equal(const char *nick1, const char *nick2)
- {
-- return (gaim_utf8_strcasecmp(nick1, nick2) == 0);
-+ return (gaim2_utf8_strcasecmp(nick1, nick2) == 0);
- }
-
- static void irc_buddy_free(struct irc_buddy *ib)
-@@ -649,14 +649,14 @@ static void irc_buddy_free(struct irc_bu
- g_free(ib);
- }
-
--static void irc_chat_set_topic(GaimConnection *gc, int id, const char *topic)
-+static void irc_chat_set_topic(Gaim2Connection *gc, int id, const char *topic)
- {
- char *buf;
- const char *name = NULL;
- struct irc_conn *irc;
-
- irc = gc->proto_data;
-- name = gaim_conversation_get_name(gaim_find_chat(gc, id));
-+ name = gaim2_conversation_get_name(gaim2_find_chat(gc, id));
-
- if (name == NULL)
- return;
-@@ -666,30 +666,30 @@ static void irc_chat_set_topic(GaimConne
- g_free(buf);
- }
-
--static GaimRoomlist *irc_roomlist_get_list(GaimConnection *gc)
-+static Gaim2Roomlist *irc_roomlist_get_list(Gaim2Connection *gc)
- {
- struct irc_conn *irc;
- GList *fields = NULL;
-- GaimRoomlistField *f;
-+ Gaim2RoomlistField *f;
- char *buf;
-
- irc = gc->proto_data;
-
- if (irc->roomlist)
-- gaim_roomlist_unref(irc->roomlist);
-+ gaim2_roomlist_unref(irc->roomlist);
-
-- irc->roomlist = gaim_roomlist_new(gaim_connection_get_account(gc));
-+ irc->roomlist = gaim2_roomlist_new(gaim2_connection_get_account(gc));
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "channel", TRUE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "channel", TRUE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Users"), "users", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Users"), "users", FALSE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, _("Topic"), "topic", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, _("Topic"), "topic", FALSE);
- fields = g_list_append(fields, f);
-
-- gaim_roomlist_set_fields(irc->roomlist, fields);
-+ gaim2_roomlist_set_fields(irc->roomlist, fields);
-
- buf = irc_format(irc, "v", "LIST");
- irc_send(irc, buf);
-@@ -698,9 +698,9 @@ static GaimRoomlist *irc_roomlist_get_li
- return irc->roomlist;
- }
-
--static void irc_roomlist_cancel(GaimRoomlist *list)
-+static void irc_roomlist_cancel(Gaim2Roomlist *list)
- {
-- GaimConnection *gc = gaim_account_get_connection(list->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(list->account);
- struct irc_conn *irc;
-
- if (gc == NULL)
-@@ -708,15 +708,15 @@ static void irc_roomlist_cancel(GaimRoom
-
- irc = gc->proto_data;
-
-- gaim_roomlist_set_in_progress(list, FALSE);
-+ gaim2_roomlist_set_in_progress(list, FALSE);
-
- if (irc->roomlist == list) {
- irc->roomlist = NULL;
-- gaim_roomlist_unref(list);
-+ gaim2_roomlist_unref(list);
- }
- }
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_CHAT_TOPIC | OPT_PROTO_PASSWORD_OPTIONAL,
- NULL, /* user_splits */
-@@ -764,7 +764,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* rename_group */
- NULL, /* buddy_free */
- NULL, /* convo_closed */
-- gaim_normalize_nocase, /* normalize */
-+ gaim2_normalize_nocase, /* normalize */
- NULL, /* set_buddy_icon */
- NULL, /* remove_group */
- NULL, /* get_cb_real_name */
-@@ -782,7 +782,7 @@ static GaimPluginProtocolInfo prpl_info
- };
-
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -811,38 +811,38 @@ static GaimPluginInfo info =
- irc_actions
- };
-
--static void _init_plugin(GaimPlugin *plugin)
-+static void _init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountUserSplit *split;
-- GaimAccountOption *option;
-+ Gaim2AccountUserSplit *split;
-+ Gaim2AccountOption *option;
-
-- split = gaim_account_user_split_new(_("Server"), IRC_DEFAULT_SERVER, '@');
-+ split = gaim2_account_user_split_new(_("Server"), IRC_DEFAULT_SERVER, '@');
- prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-
-- option = gaim_account_option_int_new(_("Port"), "port", IRC_DEFAULT_PORT);
-+ option = gaim2_account_option_int_new(_("Port"), "port", IRC_DEFAULT_PORT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Encodings"), "encoding", IRC_DEFAULT_CHARSET);
-+ option = gaim2_account_option_string_new(_("Encodings"), "encoding", IRC_DEFAULT_CHARSET);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Username"), "username", "");
-+ option = gaim2_account_option_string_new(_("Username"), "username", "");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Real name"), "realname", "");
-+ option = gaim2_account_option_string_new(_("Real name"), "realname", "");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
- /*
-- option = gaim_account_option_string_new(_("Quit message"), "quitmsg", IRC_DEFAULT_QUIT);
-+ option = gaim2_account_option_string_new(_("Quit message"), "quitmsg", IRC_DEFAULT_QUIT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
- */
-
-- option = gaim_account_option_bool_new(_("Use SSL"), "ssl", FALSE);
-+ option = gaim2_account_option_bool_new(_("Use SSL"), "ssl", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
- _irc_plugin = plugin;
-
-- gaim_prefs_remove("/plugins/prpl/irc/quitmsg");
-- gaim_prefs_remove("/plugins/prpl/irc");
-+ gaim2_prefs_remove("/plugins/prpl/irc/quitmsg");
-+ gaim2_prefs_remove("/plugins/prpl/irc");
-
- irc_register_commands();
- }
-diff -prNu ./src/protocols/irc/irc.h ./src/protocols/irc/irc.h
---- ./src/protocols/irc/irc.h 2005-11-24 14:00:13.000000000 +0100
-+++ ./src/protocols/irc/irc.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file irc.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003, Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -34,7 +34,7 @@
- #define IRC_DEFAULT_SSL_PORT 994
-
- #define IRC_DEFAULT_CHARSET "UTF-8"
--#define IRC_DEFAULT_ALIAS "gaim"
-+#define IRC_DEFAULT_ALIAS "gaim2"
-
- #define IRC_DEFAULT_QUIT "Leaving."
-
-@@ -45,7 +45,7 @@ enum { IRC_USEROPT_SERVER, IRC_USEROPT_P
- enum irc_state { IRC_STATE_NEW, IRC_STATE_ESTABLISHED };
-
- struct irc_conn {
-- GaimAccount *account;
-+ Gaim2Account *account;
- GHashTable *msgs;
- GHashTable *cmds;
- char *server;
-@@ -73,8 +73,8 @@ struct irc_conn {
- int idle;
- time_t signon;
- } whois;
-- GaimRoomlist *roomlist;
-- GaimSslConnection *gsc;
-+ Gaim2Roomlist *roomlist;
-+ Gaim2SslConnection *gsc;
-
- gboolean quitting;
- };
-@@ -169,7 +169,7 @@ int irc_cmd_topic(struct irc_conn *irc,
- int irc_cmd_wallops(struct irc_conn *irc, const char *cmd, const char *target, const char **args);
- int irc_cmd_whois(struct irc_conn *irc, const char *cmd, const char *target, const char **args);
-
--GaimXfer *irc_dccsend_new_xfer(GaimConnection *gc, const char *who);
--void irc_dccsend_send_file(GaimConnection *gc, const char *who, const char *file);
-+Gaim2Xfer *irc_dccsend_new_xfer(Gaim2Connection *gc, const char *who);
-+void irc_dccsend_send_file(Gaim2Connection *gc, const char *who, const char *file);
- void irc_dccsend_recv(struct irc_conn *irc, const char *from, const char *msg);
- #endif /* _GAIM_IRC_H */
-diff -prNu ./src/protocols/irc/Makefile.am ./src/protocols/irc/Makefile.am
---- ./src/protocols/irc/Makefile.am 2005-04-29 19:04:26.000000000 +0200
-+++ ./src/protocols/irc/Makefile.am 2006-01-05 13:03:32.000000000 +0100
-@@ -1,6 +1,6 @@
- EXTRA_DIST = PROTOCOL Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- IRCSOURCES = irc.c parse.c cmds.c msgs.c irc.h dcc_send.c
-
-diff -prNu ./src/protocols/irc/msgs.c ./src/protocols/irc/msgs.c
---- ./src/protocols/irc/msgs.c 2005-11-24 21:47:45.000000000 +0100
-+++ ./src/protocols/irc/msgs.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file msgs.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003, Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -33,7 +33,7 @@
-
- static char *irc_mask_nick(const char *mask);
- static char *irc_mask_userhost(const char *mask);
--static void irc_chat_remove_buddy(GaimConversation *convo, char *data[2]);
-+static void irc_chat_remove_buddy(Gaim2Conversation *convo, char *data[2]);
- static void irc_buddy_status(char *name, struct irc_buddy *ib, struct irc_conn *irc);
-
- static char *irc_mask_nick(const char *mask)
-@@ -54,15 +54,15 @@ static char *irc_mask_userhost(const cha
- return g_strdup(strchr(mask, '!') + 1);
- }
-
--static void irc_chat_remove_buddy(GaimConversation *convo, char *data[2])
-+static void irc_chat_remove_buddy(Gaim2Conversation *convo, char *data[2])
- {
- char *escaped, *message;
-
- escaped = g_markup_escape_text(data[1], -1);
- message = g_strdup_printf("quit: %s", escaped);
-
-- if (gaim_conv_chat_find_user(GAIM_CONV_CHAT(convo), data[0]))
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo), data[0], message);
-+ if (gaim2_conv_chat_find_user(GAIM_CONV_CHAT(convo), data[0]))
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo), data[0], message);
-
- g_free(escaped);
- g_free(message);
-@@ -70,24 +70,24 @@ static void irc_chat_remove_buddy(GaimCo
-
- void irc_msg_default(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- gaim_debug(GAIM_DEBUG_INFO, "irc", "Unrecognized message: %s\n", args[0]);
-+ gaim2_debug(GAIM_DEBUG_INFO, "irc", "Unrecognized message: %s\n", args[0]);
- }
-
- void irc_msg_away(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *msg;
-
- if (!args || !args[1])
- return;
-
-- if (irc->whois.nick && !gaim_utf8_strcasecmp(irc->whois.nick, args[1])) {
-+ if (irc->whois.nick && !gaim2_utf8_strcasecmp(irc->whois.nick, args[1])) {
- /* We're doing a whois, show this in the whois dialog */
- irc_msg_whois(irc, name, from, args);
- return;
- }
-
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- if (gc) {
- msg = g_markup_escape_text(args[2], -1);
- serv_got_im(gc, args[1], msg, GAIM_MESSAGE_AUTO_RESP, time(NULL));
-@@ -97,43 +97,43 @@ void irc_msg_away(struct irc_conn *irc,
-
- void irc_msg_badmode(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-
- if (!args || !args[1] || !gc)
- return;
-
-- gaim_notify_error(gc, NULL, _("Bad mode"), args[1]);
-+ gaim2_notify_error(gc, NULL, _("Bad mode"), args[1]);
- }
-
- void irc_msg_banned(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- char *buf;
-
- if (!args || !args[1] || !gc)
- return;
-
- buf = g_strdup_printf(_("You are banned from %s."), args[1]);
-- gaim_notify_error(gc, _("Banned"), _("Banned"), buf);
-+ gaim2_notify_error(gc, _("Banned"), _("Banned"), buf);
- g_free(buf);
- }
-
- void irc_msg_banfull(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
- char *buf, *nick;
-
- if (!args || !args[0] || !args[1] || !args[2])
- return;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
- if (!convo)
- return;
-
- nick = g_markup_escape_text(args[2], -1);
- buf = g_strdup_printf(_("Cannot ban %s: banlist is full"), nick);
- g_free(nick);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", buf,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "", buf,
- GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG,
- time(NULL));
- g_free(buf);
-@@ -141,19 +141,19 @@ void irc_msg_banfull(struct irc_conn *ir
-
- void irc_msg_chanmode(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
- char *buf, *escaped;
-
- if (!args || !args[1] || !args[2])
- return;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
- if (!convo) /* XXX punt on channels we are not in for now */
- return;
-
- escaped = (args[3] != NULL) ? g_markup_escape_text(args[3], -1) : NULL;
- buf = g_strdup_printf("mode for %s: %s %s", args[1], args[2], escaped ? escaped : "");
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "", buf, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(escaped);
- g_free(buf);
-
-@@ -163,12 +163,12 @@ void irc_msg_chanmode(struct irc_conn *i
- void irc_msg_whois(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
- if (!irc->whois.nick) {
-- gaim_debug(GAIM_DEBUG_WARNING, "irc", "Unexpected WHOIS reply for %s\n", args[1]);
-+ gaim2_debug(GAIM_DEBUG_WARNING, "irc", "Unexpected WHOIS reply for %s\n", args[1]);
- return;
- }
-
-- if (gaim_utf8_strcasecmp(irc->whois.nick, args[1])) {
-- gaim_debug(GAIM_DEBUG_WARNING, "irc", "Got WHOIS reply for %s while waiting for %s\n", args[1], irc->whois.nick);
-+ if (gaim2_utf8_strcasecmp(irc->whois.nick, args[1])) {
-+ gaim2_debug(GAIM_DEBUG_WARNING, "irc", "Got WHOIS reply for %s while waiting for %s\n", args[1], irc->whois.nick);
- return;
- }
-
-@@ -195,16 +195,16 @@ void irc_msg_whois(struct irc_conn *irc,
-
- void irc_msg_endwhois(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GString *info;
- char *str, *tmp;
-
- if (!irc->whois.nick) {
-- gaim_debug(GAIM_DEBUG_WARNING, "irc", "Unexpected End of WHOIS for %s\n", args[1]);
-+ gaim2_debug(GAIM_DEBUG_WARNING, "irc", "Unexpected End of WHOIS for %s\n", args[1]);
- return;
- }
-- if (gaim_utf8_strcasecmp(irc->whois.nick, args[1])) {
-- gaim_debug(GAIM_DEBUG_WARNING, "irc", "Received end of WHOIS for %s, expecting %s\n", args[1], irc->whois.nick);
-+ if (gaim2_utf8_strcasecmp(irc->whois.nick, args[1])) {
-+ gaim2_debug(GAIM_DEBUG_WARNING, "irc", "Received end of WHOIS for %s, expecting %s\n", args[1], irc->whois.nick);
- return;
- }
-
-@@ -240,7 +240,7 @@ void irc_msg_endwhois(struct irc_conn *i
- g_free(irc->whois.channels);
- }
- if (irc->whois.idle) {
-- gchar *timex = gaim_str_seconds_to_string(irc->whois.idle);
-+ gchar *timex = gaim2_str_seconds_to_string(irc->whois.idle);
- g_string_append_printf(info, _("<b>Idle for:</b> %s<br>"), timex);
- g_free(timex);
- g_string_append_printf(info, _("<b>%s:</b> %s"), _("Online since"), ctime(&irc->whois.signon));
-@@ -249,10 +249,10 @@ void irc_msg_endwhois(struct irc_conn *i
- g_string_append_printf(info, _("<br><b>Defining adjective:</b> Glorious<br>"));
- }
-
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- str = g_string_free(info, FALSE);
-
-- gaim_notify_userinfo(gc, irc->whois.nick, str, NULL, NULL);
-+ gaim2_notify_userinfo(gc, irc->whois.nick, str, NULL, NULL);
-
- g_free(irc->whois.nick);
- g_free(str);
-@@ -265,34 +265,34 @@ void irc_msg_list(struct irc_conn *irc,
- return;
-
- if (!strcmp(name, "321")) {
-- gaim_roomlist_set_in_progress(irc->roomlist, TRUE);
-+ gaim2_roomlist_set_in_progress(irc->roomlist, TRUE);
- return;
- }
-
- if (!strcmp(name, "323")) {
-- gaim_roomlist_set_in_progress(irc->roomlist, FALSE);
-- gaim_roomlist_unref(irc->roomlist);
-+ gaim2_roomlist_set_in_progress(irc->roomlist, FALSE);
-+ gaim2_roomlist_unref(irc->roomlist);
- irc->roomlist = NULL;
- }
-
- if (!strcmp(name, "322")) {
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
-
- if (!args[0] || !args[1] || !args[2] || !args[3])
- return;
-
-- room = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, args[1], NULL);
-- gaim_roomlist_room_add_field(irc->roomlist, room, args[1]);
-- gaim_roomlist_room_add_field(irc->roomlist, room, GINT_TO_POINTER(strtol(args[2], NULL, 10)));
-- gaim_roomlist_room_add_field(irc->roomlist, room, args[3]);
-- gaim_roomlist_room_add(irc->roomlist, room);
-+ room = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, args[1], NULL);
-+ gaim2_roomlist_room_add_field(irc->roomlist, room, args[1]);
-+ gaim2_roomlist_room_add_field(irc->roomlist, room, GINT_TO_POINTER(strtol(args[2], NULL, 10)));
-+ gaim2_roomlist_room_add_field(irc->roomlist, room, args[3]);
-+ gaim2_roomlist_room_add(irc->roomlist, room);
- }
- }
-
- void irc_msg_topic(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
- char *chan, *topic, *msg, *nick, *tmp, *tmp2;
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
- if (!strcmp(name, "topic")) {
- chan = args[0];
-@@ -302,26 +302,26 @@ void irc_msg_topic(struct irc_conn *irc,
- topic = irc_mirc2txt (args[2]);
- }
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, chan, irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, chan, irc->account);
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got a topic for %s, which doesn't exist\n", chan);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Got a topic for %s, which doesn't exist\n", chan);
- }
-
- /* If this is an interactive update, print it out */
- tmp = g_markup_escape_text(topic, -1);
-- tmp2 = gaim_markup_linkify(tmp);
-+ tmp2 = gaim2_markup_linkify(tmp);
- g_free(tmp);
- if (!strcmp(name, "topic")) {
- nick = irc_mask_nick(from);
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), nick, topic);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo), nick, topic);
- msg = g_strdup_printf(_("%s has changed the topic to: %s"), nick, tmp2);
- g_free(nick);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), from, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), from, msg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- } else {
- msg = g_strdup_printf(_("The topic for %s is: %s"), chan, tmp2);
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, topic);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", msg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, topic);
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "", msg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- }
- g_free(tmp2);
-@@ -330,26 +330,26 @@ void irc_msg_topic(struct irc_conn *irc,
-
- void irc_msg_unknown(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- char *buf;
-
- if (!args || !args[1] || !gc)
- return;
-
- buf = g_strdup_printf(_("Unknown message '%s'"), args[1]);
-- gaim_notify_error(gc, _("Unknown message"), buf, _("Gaim has sent a message the IRC server did not understand."));
-+ gaim2_notify_error(gc, _("Unknown message"), buf, _("Gaim2 has sent a message the IRC server did not understand."));
- g_free(buf);
- }
-
- void irc_msg_names(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
- char *names, *cur, *end, *tmp, *msg;
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
- if (!strcmp(name, "366")) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, irc->nameconv ? irc->nameconv : args[1], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, irc->nameconv ? irc->nameconv : args[1], irc->account);
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got a NAMES list for %s, which doesn't exist\n", args[2]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Got a NAMES list for %s, which doesn't exist\n", args[2]);
- g_string_free(irc->names, TRUE);
- irc->names = NULL;
- g_free(irc->nameconv);
-@@ -361,10 +361,10 @@ void irc_msg_names(struct irc_conn *irc,
- irc->names = NULL;
- if (irc->nameconv) {
- msg = g_strdup_printf(_("Users on %s: %s"), args[1], names ? names : "");
-- if (gaim_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ if (gaim2_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- else
-- gaim_conv_im_write(GAIM_CONV_IM(convo), "", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), "", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- g_free(msg);
- g_free(irc->nameconv);
- irc->nameconv = NULL;
-@@ -373,7 +373,7 @@ void irc_msg_names(struct irc_conn *irc,
- GList *flags = NULL;
-
- while (*cur) {
-- GaimConvChatBuddyFlags f = GAIM_CBFLAGS_NONE;
-+ Gaim2ConvChatBuddyFlags f = GAIM_CBFLAGS_NONE;
- end = strchr(cur, ' ');
- if (!end)
- end = cur + strlen(cur);
-@@ -398,7 +398,7 @@ void irc_msg_names(struct irc_conn *irc,
- if (users != NULL) {
- GList *l;
-
-- gaim_conv_chat_add_users(GAIM_CONV_CHAT(convo), users, NULL, flags, FALSE);
-+ gaim2_conv_chat_add_users(GAIM_CONV_CHAT(convo), users, NULL, flags, FALSE);
-
- for (l = users; l != NULL; l = l->next)
- g_free(l->data);
-@@ -418,12 +418,12 @@ void irc_msg_names(struct irc_conn *irc,
-
- void irc_msg_motd(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *escaped;
- if (!strcmp(name, "375")) {
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- if (gc)
-- gaim_connection_set_display_name(gc, args[0]);
-+ gaim2_connection_set_display_name(gc, args[0]);
- }
-
- if (!irc->motd)
-@@ -436,36 +436,36 @@ void irc_msg_motd(struct irc_conn *irc,
-
- void irc_msg_endmotd(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-- GaimStatus *status;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2Connection *gc;
-+ Gaim2Status *status;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- if (!gc)
- return;
-
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- /* If we're away then set our away message */
-- status = gaim_account_get_active_status(irc->account);
-- if (!gaim_status_get_type(status) != GAIM_STATUS_AVAILABLE)
-+ status = gaim2_account_get_active_status(irc->account);
-+ if (!gaim2_status_get_type(status) != GAIM_STATUS_AVAILABLE)
- {
-- GaimPluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-+ Gaim2PluginProtocolInfo *prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
- prpl_info->set_status(irc->account, status);
- }
-
- /* this used to be in the core, but it's not now */
-- for (gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for (gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for(bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if(b->account == gc->account) {
- struct irc_buddy *ib = g_new0(struct irc_buddy, 1);
- ib->name = g_strdup(b->name);
-@@ -477,52 +477,52 @@ void irc_msg_endmotd(struct irc_conn *ir
-
- irc_blist_timeout(irc);
- if (!irc->timer)
-- irc->timer = gaim_timeout_add(45000, (GSourceFunc)irc_blist_timeout, (gpointer)irc);
-+ irc->timer = gaim2_timeout_add(45000, (GSourceFunc)irc_blist_timeout, (gpointer)irc);
- }
-
- void irc_msg_time(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- if (gc == NULL || args == NULL || args[2] == NULL)
- return;
-
-- gaim_notify_message(gc, GAIM_NOTIFY_MSG_INFO, _("Time Response"),
-+ gaim2_notify_message(gc, GAIM_NOTIFY_MSG_INFO, _("Time Response"),
- _("The IRC server's local time is:"),
- args[2], NULL, NULL);
- }
-
- void irc_msg_nochan(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-
- if (gc == NULL || args == NULL || args[1] == NULL)
- return;
-
-- gaim_notify_error(gc, NULL, _("No such channel"), args[1]);
-+ gaim2_notify_error(gc, NULL, _("No such channel"), args[1]);
- }
-
- void irc_msg_nonick(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-- GaimConversation *convo;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *convo;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, args[1], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, args[1], irc->account);
- if (convo) {
-- if (gaim_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT) /* does this happen? */
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), args[1], _("no such channel"),
-+ if (gaim2_conversation_get_type(convo) == GAIM_CONV_TYPE_CHAT) /* does this happen? */
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), args[1], _("no such channel"),
- GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- else
-- gaim_conv_im_write(GAIM_CONV_IM(convo), args[1], _("User is not logged in"),
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), args[1], _("User is not logged in"),
- GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- } else {
-- if ((gc = gaim_account_get_connection(irc->account)) == NULL)
-+ if ((gc = gaim2_account_get_connection(irc->account)) == NULL)
- return;
-- gaim_notify_error(gc, NULL, _("No such nick or channel"), args[1]);
-+ gaim2_notify_error(gc, NULL, _("No such nick or channel"), args[1]);
- }
-
-- if (irc->whois.nick && !gaim_utf8_strcasecmp(irc->whois.nick, args[1])) {
-+ if (irc->whois.nick && !gaim2_utf8_strcasecmp(irc->whois.nick, args[1])) {
- g_free(irc->whois.nick);
- irc->whois.nick = NULL;
- }
-@@ -530,48 +530,48 @@ void irc_msg_nonick(struct irc_conn *irc
-
- void irc_msg_nosend(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc;
-- GaimConversation *convo;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *convo;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
- if (convo) {
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), args[1], args[2], GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), args[1], args[2], GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- } else {
-- if ((gc = gaim_account_get_connection(irc->account)) == NULL)
-+ if ((gc = gaim2_account_get_connection(irc->account)) == NULL)
- return;
-- gaim_notify_error(gc, NULL, _("Could not send"), args[2]);
-+ gaim2_notify_error(gc, NULL, _("Could not send"), args[2]);
- }
- }
-
- void irc_msg_notinchan(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConversation *convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
-+ Gaim2Conversation *convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
-
-- gaim_debug(GAIM_DEBUG_INFO, "irc", "We're apparently not in %s, but tried to use it\n", args[1]);
-+ gaim2_debug(GAIM_DEBUG_INFO, "irc", "We're apparently not in %s, but tried to use it\n", args[1]);
- if (convo) {
- /*g_slist_remove(irc->gc->buddy_chats, convo);
-- gaim_conversation_set_account(convo, NULL);*/
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), args[1], args[2], GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conversation_set_account(convo, NULL);*/
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), args[1], args[2], GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- }
- }
-
- void irc_msg_notop(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
- if (!args || !args[1] || !args[2])
- return;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[1], irc->account);
- if (!convo)
- return;
-
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", args[2], GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "", args[2], GAIM_MESSAGE_SYSTEM, time(NULL));
- }
-
- void irc_msg_invite(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- GHashTable *components = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free);
- char *nick = irc_mask_nick(from);
-
-@@ -589,14 +589,14 @@ void irc_msg_invite(struct irc_conn *irc
-
- void irc_msg_inviteonly(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- char *buf;
-
- if (!args || !args[1] || !gc)
- return;
-
- buf = g_strdup_printf(_("Joining %s requires an invitation."), args[1]);
-- gaim_notify_error(gc, _("Invitation only"), _("Invitation only"), buf);
-+ gaim2_notify_error(gc, _("Invitation only"), _("Invitation only"), buf);
- g_free(buf);
- }
-
-@@ -625,25 +625,25 @@ void irc_msg_ison(struct irc_conn *irc,
-
- static void irc_buddy_status(char *name, struct irc_buddy *ib, struct irc_conn *irc)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-- GaimBuddy *buddy = gaim_find_buddy(irc->account, name);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(irc->account, name);
-
- if (!gc || !buddy)
- return;
-
- if (ib->online && !ib->flag) {
-- gaim_prpl_got_user_status(irc->account, name, "offline", NULL);
-+ gaim2_prpl_got_user_status(irc->account, name, "offline", NULL);
- ib->online = FALSE;
- } else if (!ib->online && ib->flag) {
-- gaim_prpl_got_user_status(irc->account, name, "available", NULL);
-+ gaim2_prpl_got_user_status(irc->account, name, "available", NULL);
- ib->online = TRUE;
- }
- }
-
- void irc_msg_join(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-- GaimConversation *convo;
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-+ Gaim2Conversation *convo;
- char *nick = irc_mask_nick(from), *userhost;
- struct irc_buddy *ib;
- static int id = 1;
-@@ -653,22 +653,22 @@ void irc_msg_join(struct irc_conn *irc,
- return;
- }
-
-- if (!gaim_utf8_strcasecmp(nick, gaim_connection_get_display_name(gc))) {
-+ if (!gaim2_utf8_strcasecmp(nick, gaim2_connection_get_display_name(gc))) {
- /* We are joining a channel for the first time */
- serv_got_joined_chat(gc, id++, args[0]);
- g_free(nick);
- return;
- }
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
- if (convo == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "JOIN for %s failed\n", args[0]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "JOIN for %s failed\n", args[0]);
- g_free(nick);
- return;
- }
-
- userhost = irc_mask_userhost(from);
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(convo), nick, userhost, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(convo), nick, userhost, GAIM_CBFLAGS_NONE, TRUE);
-
- if ((ib = g_hash_table_lookup(irc->buddies, nick)) != NULL) {
- ib->flag = TRUE;
-@@ -681,8 +681,8 @@ void irc_msg_join(struct irc_conn *irc,
-
- void irc_msg_kick(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-- GaimConversation *convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-+ Gaim2Conversation *convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
- char *nick = irc_mask_nick(from), *buf, *reason;
-
- if (!gc) {
-@@ -691,20 +691,20 @@ void irc_msg_kick(struct irc_conn *irc,
- }
-
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Recieved a KICK for unknown channel %s\n", args[0]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Recieved a KICK for unknown channel %s\n", args[0]);
- g_free(nick);
- return;
- }
-
- reason = g_markup_escape_text(args[2], -1);
-- if (!gaim_utf8_strcasecmp(gaim_connection_get_display_name(gc), args[1])) {
-+ if (!gaim2_utf8_strcasecmp(gaim2_connection_get_display_name(gc), args[1])) {
- buf = g_strdup_printf(_("You have been kicked by %s: (%s)"), nick, reason);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), args[0], buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), args[0], buf, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(buf);
-- serv_got_chat_left(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
-+ serv_got_chat_left(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
- } else {
- buf = g_strdup_printf(_("Kicked by %s (%s)"), nick, reason);
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo), args[1], buf);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo), args[1], buf);
- g_free(buf);
- }
-
-@@ -715,24 +715,24 @@ void irc_msg_kick(struct irc_conn *irc,
-
- void irc_msg_mode(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
- char *nick = irc_mask_nick(from), *buf;
-
- if (*args[0] == '#' || *args[0] == '&') { /* Channel */
- char *escaped;
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "MODE received for %s, which we are not in\n", args[0]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "MODE received for %s, which we are not in\n", args[0]);
- g_free(nick);
- return;
- }
- escaped = (args[2] != NULL) ? g_markup_escape_text(args[2], -1) : NULL;
- buf = g_strdup_printf(_("mode (%s %s) by %s"), args[1], escaped ? escaped : "", nick);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), args[0], buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), args[0], buf, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(escaped);
- g_free(buf);
- if(args[2]) {
-- GaimConvChatBuddyFlags newflag, flags;
-+ Gaim2ConvChatBuddyFlags newflag, flags;
- char *mcur, *cur, *end, *user;
- gboolean add = FALSE;
- mcur = args[1];
-@@ -747,7 +747,7 @@ void irc_msg_mode(struct irc_conn *irc,
- if (!end)
- end = cur + strlen(cur);
- user = g_strndup(cur, end - cur);
-- flags = gaim_conv_chat_user_get_flags(GAIM_CONV_CHAT(convo), user);
-+ flags = gaim2_conv_chat_user_get_flags(GAIM_CONV_CHAT(convo), user);
- newflag = GAIM_CBFLAGS_NONE;
- if (*mcur == 'o')
- newflag = GAIM_CBFLAGS_OP;
-@@ -760,7 +760,7 @@ void irc_msg_mode(struct irc_conn *irc,
- flags |= newflag;
- else
- flags &= ~newflag;
-- gaim_conv_chat_user_set_flags(GAIM_CONV_CHAT(convo), user, flags);
-+ gaim2_conv_chat_user_set_flags(GAIM_CONV_CHAT(convo), user, flags);
- }
- g_free(user);
- cur = end;
-@@ -777,8 +777,8 @@ void irc_msg_mode(struct irc_conn *irc,
-
- void irc_msg_nick(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-- GaimConversation *conv;
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-+ Gaim2Conversation *conv;
- GSList *chats;
- char *nick = irc_mask_nick(from);
-
-@@ -788,29 +788,29 @@ void irc_msg_nick(struct irc_conn *irc,
- }
- chats = gc->buddy_chats;
-
-- if (!gaim_utf8_strcasecmp(nick, gaim_connection_get_display_name(gc))) {
-- gaim_connection_set_display_name(gc, args[0]);
-+ if (!gaim2_utf8_strcasecmp(nick, gaim2_connection_get_display_name(gc))) {
-+ gaim2_connection_set_display_name(gc, args[0]);
- }
-
- while (chats) {
-- GaimConvChat *chat = GAIM_CONV_CHAT(chats->data);
-+ Gaim2ConvChat *chat = GAIM_CONV_CHAT(chats->data);
- /* This is ugly ... */
-- if (gaim_conv_chat_find_user(chat, nick))
-- gaim_conv_chat_rename_user(chat, nick, args[0]);
-+ if (gaim2_conv_chat_find_user(chat, nick))
-+ gaim2_conv_chat_rename_user(chat, nick, args[0]);
- chats = chats->next;
- }
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, nick,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, nick,
- irc->account);
- if (conv != NULL)
-- gaim_conversation_set_name(conv, args[0]);
-+ gaim2_conversation_set_name(conv, args[0]);
-
- g_free(nick);
- }
-
- void irc_msg_badnick(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- gaim_connection_error(gaim_account_get_connection(irc->account),
-+ gaim2_connection_error(gaim2_account_get_connection(irc->account),
- _("Your selected account name was rejected by the server. It probably contains invalid characters."));
- }
-
-@@ -845,40 +845,40 @@ void irc_msg_notice(struct irc_conn *irc
-
- void irc_msg_nochangenick(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-
- if (!args || !args[2] || !gc)
- return;
-
-- gaim_notify_error(gc, _("Cannot change nick"), _("Could not change nick"), args[2]);
-+ gaim2_notify_error(gc, _("Cannot change nick"), _("Could not change nick"), args[2]);
- }
-
- void irc_msg_part(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-- GaimConversation *convo;
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-+ Gaim2Conversation *convo;
- char *nick, *msg, *escaped;
-
- if (!args || !args[0] || !gc)
- return;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
- if (!convo) {
-- gaim_debug(GAIM_DEBUG_INFO, "irc", "Got a PART on %s, which doesn't exist -- probably closed\n", args[0]);
-+ gaim2_debug(GAIM_DEBUG_INFO, "irc", "Got a PART on %s, which doesn't exist -- probably closed\n", args[0]);
- return;
- }
-
- escaped = (args[1] && *args[1]) ? g_markup_escape_text(args[1], -1) : NULL;
- nick = irc_mask_nick(from);
-- if (!gaim_utf8_strcasecmp(nick, gaim_connection_get_display_name(gc))) {
-+ if (!gaim2_utf8_strcasecmp(nick, gaim2_connection_get_display_name(gc))) {
- msg = g_strdup_printf(_("You have parted the channel%s%s"),
- (args[1] && *args[1]) ? ": " : "",
- (escaped && *escaped) ? escaped : "");
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), args[0], msg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), args[0], msg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
-- serv_got_chat_left(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
-+ serv_got_chat_left(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
- } else {
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo), nick, escaped);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo), nick, escaped);
- }
- g_free(escaped);
- g_free(nick);
-@@ -897,8 +897,8 @@ void irc_msg_ping(struct irc_conn *irc,
-
- void irc_msg_pong(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConversation *convo;
-- GaimConnection *gc;
-+ Gaim2Conversation *convo;
-+ Gaim2Connection *gc;
- char **parts, *msg;
- time_t oldstamp;
-
-@@ -918,28 +918,28 @@ void irc_msg_pong(struct irc_conn *irc,
- msg = g_strdup_printf(_("PING reply -- Lag: %lu seconds"), time(NULL) - oldstamp);
- }
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, parts[0], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, parts[0], irc->account);
- g_strfreev(parts);
- if (convo) {
-- if (gaim_conversation_get_type (convo) == GAIM_CONV_TYPE_CHAT)
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "PONG", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ if (gaim2_conversation_get_type (convo) == GAIM_CONV_TYPE_CHAT)
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), "PONG", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- else
-- gaim_conv_im_write(GAIM_CONV_IM(convo), "PONG", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), "PONG", msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- } else {
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- if (!gc) {
- g_free(msg);
- return;
- }
-- gaim_notify_info(gc, NULL, "PONG", msg);
-+ gaim2_notify_info(gc, NULL, "PONG", msg);
- }
- g_free(msg);
- }
-
- void irc_msg_privmsg(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-- GaimConversation *convo;
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-+ Gaim2Conversation *convo;
- char *nick = irc_mask_nick(from), *tmp, *msg;
- int notice = 0;
-
-@@ -967,16 +967,16 @@ void irc_msg_privmsg(struct irc_conn *ir
- msg = tmp;
- }
-
-- if (!gaim_utf8_strcasecmp(args[0], gaim_connection_get_display_name(gc))) {
-+ if (!gaim2_utf8_strcasecmp(args[0], gaim2_connection_get_display_name(gc))) {
- serv_got_im(gc, nick, msg, 0, time(NULL));
- } else if (notice) {
- serv_got_im(gc, nick, msg, 0, time(NULL));
- } else {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0], irc->account);
- if (convo)
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)), nick, 0, msg, time(NULL));
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)), nick, 0, msg, time(NULL));
- else
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got a PRIVMSG on %s, which does not exist\n", args[0]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Got a PRIVMSG on %s, which does not exist\n", args[0]);
- }
- g_free(msg);
- g_free(nick);
-@@ -984,20 +984,20 @@ void irc_msg_privmsg(struct irc_conn *ir
-
- void irc_msg_regonly(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- char *msg;
-
- if (!args || !args[1] || !args[2] || !gc)
- return;
-
- msg = g_strdup_printf(_("Cannot join %s:"), args[1]);
-- gaim_notify_error(gc, _("Cannot join channel"), msg, args[2]);
-+ gaim2_notify_error(gc, _("Cannot join channel"), msg, args[2]);
- g_free(msg);
- }
-
- void irc_msg_quit(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- struct irc_buddy *ib;
- char *data[2];
-
-@@ -1020,17 +1020,17 @@ void irc_msg_quit(struct irc_conn *irc,
-
- void irc_msg_unavailable(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
-
- if (!args || !args[1])
- return;
-
-- gaim_notify_error(gc, NULL, _("Nick or channel is temporarily unavailable."), args[1]);
-+ gaim2_notify_error(gc, NULL, _("Nick or channel is temporarily unavailable."), args[1]);
- }
-
- void irc_msg_wallops(struct irc_conn *irc, const char *name, const char *from, char **args)
- {
-- GaimConnection *gc = gaim_account_get_connection(irc->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(irc->account);
- char *nick, *msg;
-
- if (!args || !args[0] || !gc)
-@@ -1039,7 +1039,7 @@ void irc_msg_wallops(struct irc_conn *ir
- nick = irc_mask_nick(from);
- msg = g_strdup_printf (_("Wallops from %s"), nick);
- g_free(nick);
-- gaim_notify_info(gc, NULL, msg, args[0]);
-+ gaim2_notify_info(gc, NULL, msg, args[0]);
- g_free(msg);
- }
-
-diff -prNu ./src/protocols/irc/parse.c ./src/protocols/irc/parse.c
---- ./src/protocols/irc/parse.c 2005-12-04 18:44:01.000000000 +0100
-+++ ./src/protocols/irc/parse.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file parse.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003, Ethan Blanton <eblanton@cs.purdue.edu>
- *
-@@ -146,14 +146,14 @@ static struct _irc_user_cmd {
- { NULL, NULL, NULL, NULL }
- };
-
--static GaimCmdRet irc_parse_gaim_cmd(GaimConversation *conv, const gchar *cmd,
-+static Gaim2CmdRet irc_parse_gaim2_cmd(Gaim2Conversation *conv, const gchar *cmd,
- gchar **args, gchar **error, void *data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- struct irc_conn *irc;
- struct _irc_user_cmd *cmdent;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
- if (!gc)
- return GAIM_CMD_RET_FAILED;
-
-@@ -162,14 +162,14 @@ static GaimCmdRet irc_parse_gaim_cmd(Gai
- if ((cmdent = g_hash_table_lookup(irc->cmds, cmd)) == NULL)
- return GAIM_CMD_RET_FAILED;
-
-- (cmdent->cb)(irc, cmd, gaim_conversation_get_name(conv), (const char **)args);
-+ (cmdent->cb)(irc, cmd, gaim2_conversation_get_name(conv), (const char **)args);
-
- return GAIM_CMD_RET_OK;
- }
-
- static void irc_register_command(struct _irc_user_cmd *c)
- {
-- GaimCmdFlag f;
-+ Gaim2CmdFlag f;
- char args[10];
- char *format;
- size_t i;
-@@ -195,8 +195,8 @@ static void irc_register_command(struct
-
- args[i] = '\0';
-
-- gaim_cmd_register(c->name, args, GAIM_CMD_P_PRPL, f, "prpl-irc",
-- irc_parse_gaim_cmd, _(c->help), NULL);
-+ gaim2_cmd_register(c->name, args, GAIM_CMD_P_PRPL, f, "prpl-irc",
-+ irc_parse_gaim2_cmd, _(c->help), NULL);
- }
-
- void irc_register_commands(void)
-@@ -214,7 +214,7 @@ static char *irc_send_convert(struct irc
- gchar **encodings;
- const gchar *enclist;
-
-- enclist = gaim_account_get_string(irc->account, "encoding", IRC_DEFAULT_CHARSET);
-+ enclist = gaim2_account_get_string(irc->account, "encoding", IRC_DEFAULT_CHARSET);
- encodings = g_strsplit(enclist, ",", 2);
-
- if (encodings[0] == NULL || !strcasecmp("UTF-8", encodings[0])) {
-@@ -224,8 +224,8 @@ static char *irc_send_convert(struct irc
-
- utf8 = g_convert(string, strlen(string), encodings[0], "UTF-8", NULL, NULL, &err);
- if (err) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Send conversion error: %s\n", err->message);
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Sending as UTF-8 instead of %s\n", encodings[0]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Send conversion error: %s\n", err->message);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Sending as UTF-8 instead of %s\n", encodings[0]);
- utf8 = g_strdup(string);
- g_error_free(err);
- }
-@@ -241,12 +241,12 @@ static char *irc_recv_convert(struct irc
- gchar **encodings;
- int i;
-
-- enclist = gaim_account_get_string(irc->account, "encoding", IRC_DEFAULT_CHARSET);
-+ enclist = gaim2_account_get_string(irc->account, "encoding", IRC_DEFAULT_CHARSET);
- encodings = g_strsplit(enclist, ",", -1);
-
- if (encodings[0] == NULL) {
- g_strfreev(encodings);
-- return gaim_utf8_salvage(string);
-+ return gaim2_utf8_salvage(string);
- }
-
- for (i = 0; encodings[i] != NULL; i++) {
-@@ -268,7 +268,7 @@ static char *irc_recv_convert(struct irc
- }
- g_strfreev(encodings);
-
-- return gaim_utf8_salvage(string);
-+ return gaim2_utf8_salvage(string);
- }
-
- /* XXX tag closings are not necessarily correctly nested here! If we
-@@ -376,7 +376,7 @@ char *irc_mirc2html(const char *string)
- decoded = g_string_append(decoded, "</FONT>");
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Unexpected mIRC formatting character %d\n", *cur);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Unexpected mIRC formatting character %d\n", *cur);
- }
- } while (*cur);
-
-@@ -412,7 +412,7 @@ gboolean irc_ischannel(const char *strin
-
- char *irc_parse_ctcp(struct irc_conn *irc, const char *from, const char *to, const char *msg, int notice)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *cur = msg + 1;
- char *buf, *ctcp;
- time_t timestamp;
-@@ -433,21 +433,21 @@ char *irc_parse_ctcp(struct irc_conn *ir
- if (notice) { /* reply */
- /* TODO: Should this read in the timestamp as a double? */
- sscanf(cur, "PING %lu", &timestamp);
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- if (!gc)
- return NULL;
- buf = g_strdup_printf(_("Reply time from %s: %lu seconds"), from, time(NULL) - timestamp);
-- gaim_notify_info(gc, _("PONG"), _("CTCP PING reply"), buf);
-+ gaim2_notify_info(gc, _("PONG"), _("CTCP PING reply"), buf);
- g_free(buf);
- return NULL;
- } else {
- buf = irc_format(irc, "vt:", "NOTICE", from, msg);
- irc_send(irc, buf);
- g_free(buf);
-- gc = gaim_account_get_connection(irc->account);
-+ gc = gaim2_account_get_connection(irc->account);
- }
- } else if (!strncmp(cur, "VERSION", 7) && !notice) {
-- buf = irc_format(irc, "vt:", "NOTICE", from, "\001VERSION Gaim IRC\001");
-+ buf = irc_format(irc, "vt:", "NOTICE", from, "\001VERSION Gaim2 IRC\001");
- irc_send(irc, buf);
- g_free(buf);
- } else if (!strncmp(cur, "DCC SEND ", 9)) {
-@@ -467,7 +467,7 @@ void irc_msg_table_build(struct irc_conn
- int i;
-
- if (!irc || !irc->msgs) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Attempt to build a message table on a bogus structure\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Attempt to build a message table on a bogus structure\n");
- return;
- }
-
-@@ -481,7 +481,7 @@ void irc_cmd_table_build(struct irc_conn
- int i;
-
- if (!irc || !irc->cmds) {
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Attempt to build a command table on a bogus structure\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Attempt to build a command table on a bogus structure\n");
- return;
- }
-
-@@ -518,7 +518,7 @@ char *irc_format(struct irc_conn *irc, c
- g_free(tmp);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "Invalid format character '%c'\n", *cur);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "Invalid format character '%c'\n", *cur);
- break;
- }
- }
-@@ -541,10 +541,10 @@ void irc_parse_msg(struct irc_conn *irc,
- } else if (!strncmp(input, "ERROR ", 6)) {
- if (g_utf8_validate(input, -1, NULL)) {
- char *tmp = g_strdup_printf("%s\n%s", _("Disconnected."), input);
-- gaim_connection_error(gaim_account_get_connection(irc->account), tmp);
-+ gaim2_connection_error(gaim2_account_get_connection(irc->account), tmp);
- g_free(tmp);
- } else
-- gaim_connection_error(gaim_account_get_connection(irc->account), _("Disconnected."));
-+ gaim2_connection_error(gaim2_account_get_connection(irc->account), _("Disconnected."));
- return;
- }
-
-@@ -598,7 +598,7 @@ void irc_parse_msg(struct irc_conn *irc,
- cur = cur + strlen(cur);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "irc", "invalid message format character '%c'\n", fmt[i]);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "irc", "invalid message format character '%c'\n", fmt[i]);
- break;
- }
- }
-@@ -614,5 +614,5 @@ void irc_parse_msg(struct irc_conn *irc,
-
- static void irc_parse_error_cb(struct irc_conn *irc, char *input)
- {
-- gaim_debug(GAIM_DEBUG_WARNING, "irc", "Unrecognized string: %s\n", input);
-+ gaim2_debug(GAIM_DEBUG_WARNING, "irc", "Unrecognized string: %s\n", input);
- }
-diff -prNu ./src/protocols/jabber/auth.c ./src/protocols/jabber/auth.c
---- ./src/protocols/jabber/auth.c 2005-12-18 19:21:27.000000000 +0100
-+++ ./src/protocols/jabber/auth.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -41,16 +41,16 @@ jabber_process_starttls(JabberStream *js
- xmlnode *starttls;
-
- if((starttls = xmlnode_get_child(packet, "starttls"))) {
-- if(gaim_account_get_bool(js->gc->account, "use_tls", TRUE) &&
-- gaim_ssl_is_supported()) {
-+ if(gaim2_account_get_bool(js->gc->account, "use_tls", TRUE) &&
-+ gaim2_ssl_is_supported()) {
- jabber_send_raw(js,
- "<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>", -1);
- return TRUE;
- } else if(xmlnode_get_child(starttls, "required")) {
-- if(gaim_ssl_is_supported()) {
-- gaim_connection_error(js->gc, _("Server requires TLS/SSL for login. Select \"Use TLS if available\" in account properties"));
-+ if(gaim2_ssl_is_supported()) {
-+ gaim2_connection_error(js->gc, _("Server requires TLS/SSL for login. Select \"Use TLS if available\" in account properties"));
- } else {
-- gaim_connection_error(js->gc, _("Server requires TLS/SSL for login. No TLS/SSL support found."));
-+ gaim2_connection_error(js->gc, _("Server requires TLS/SSL for login. No TLS/SSL support found."));
- }
- return TRUE;
- }
-@@ -74,9 +74,9 @@ static void finish_plaintext_authenticat
- response = g_string_append(response, js->user->node);
- response = g_string_append_len(response, "\0", 1);
- response = g_string_append(response,
-- gaim_connection_get_password(js->gc));
-+ gaim2_connection_get_password(js->gc));
-
-- enc_out = gaim_base64_encode((guchar *)response->str, response->len);
-+ enc_out = gaim2_base64_encode((guchar *)response->str, response->len);
-
- xmlnode_set_attrib(auth, "mechanism", "PLAIN");
- xmlnode_insert_data(auth, enc_out, -1);
-@@ -96,22 +96,22 @@ static void finish_plaintext_authenticat
- x = xmlnode_new_child(query, "resource");
- xmlnode_insert_data(x, js->user->resource, -1);
- x = xmlnode_new_child(query, "password");
-- xmlnode_insert_data(x, gaim_connection_get_password(js->gc), -1);
-+ xmlnode_insert_data(x, gaim2_connection_get_password(js->gc), -1);
- jabber_iq_set_callback(iq, auth_old_result_cb, NULL);
- jabber_iq_send(iq);
- }
- }
-
--static void allow_plaintext_auth(GaimAccount *account)
-+static void allow_plaintext_auth(Gaim2Account *account)
- {
-- gaim_account_set_bool(account, "auth_plain_in_clear", TRUE);
-+ gaim2_account_set_bool(account, "auth_plain_in_clear", TRUE);
-
- finish_plaintext_authentication(account->gc->proto_data);
- }
-
--static void disallow_plaintext_auth(GaimAccount *account)
-+static void disallow_plaintext_auth(Gaim2Account *account)
- {
-- gaim_connection_error(account->gc, _("Server requires plaintext authentication over an unencrypted stream"));
-+ gaim2_connection_error(account->gc, _("Server requires plaintext authentication over an unencrypted stream"));
- }
-
- #ifdef HAVE_CYRUS_SASL
-@@ -152,7 +152,7 @@ static int jabber_sasl_cb_simple(void *c
- static int jabber_sasl_cb_secret(sasl_conn_t *conn, void *ctx, int id, sasl_secret_t **secret)
- {
- JabberStream *js = (JabberStream *)ctx;
-- const char *pw = gaim_account_get_password(js->gc->account);
-+ const char *pw = gaim2_account_get_password(js->gc->account);
- size_t len;
- static sasl_secret_t *x = NULL;
-
-@@ -172,9 +172,9 @@ static int jabber_sasl_cb_secret(sasl_co
- return SASL_OK;
- }
-
--static void allow_cyrus_plaintext_auth(GaimAccount *account)
-+static void allow_cyrus_plaintext_auth(Gaim2Account *account)
- {
-- gaim_account_set_bool(account, "auth_plain_in_clear", TRUE);
-+ gaim2_account_set_bool(account, "auth_plain_in_clear", TRUE);
-
- jabber_auth_start_cyrus(account->gc->proto_data);
- }
-@@ -196,7 +196,7 @@ static void jabber_auth_start_cyrus(Jabb
- secprops.maxbufsize = -1;
-
- if (!js->gsc) {
-- plaintext = gaim_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE);
-+ plaintext = gaim2_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE);
- if (!plaintext)
- secprops.security_flags |= SASL_SEC_NOPLAINTEXT;
- } else {
-@@ -216,7 +216,7 @@ static void jabber_auth_start_cyrus(Jabb
- js->sasl_state = sasl_client_new("xmpp", js->user->domain, NULL, NULL, js->sasl_cb, 0, &js->sasl);
- if (js->sasl_state==SASL_OK) {
- sasl_setprop(js->sasl, SASL_SEC_PROPS, &secprops);
-- gaim_debug_info("sasl", "Mechs found: %s\n", js->sasl_mechs->str);
-+ gaim2_debug_info("sasl", "Mechs found: %s\n", js->sasl_mechs->str);
- js->sasl_state = sasl_client_start(js->sasl, js->sasl_mechs->str, NULL, &clientout, &coutlen, &mech);
- }
- switch (js->sasl_state) {
-@@ -228,11 +228,11 @@ static void jabber_auth_start_cyrus(Jabb
- /* No mechanisms do what we want. See if we can add
- * plaintext ones to the list. */
-
-- if (!gaim_account_get_password(js->gc->account)) {
-- gaim_connection_error(js->gc, _("Server couldn't authenticate you without a password"));
-+ if (!gaim2_account_get_password(js->gc->account)) {
-+ gaim2_connection_error(js->gc, _("Server couldn't authenticate you without a password"));
- return;
- } else if (!plaintext) {
-- gaim_request_yes_no(js->gc, _("Plaintext Authentication"),
-+ gaim2_request_yes_no(js->gc, _("Plaintext Authentication"),
- _("Plaintext Authentication"),
- _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
- 2, js->gc->account,
-@@ -240,7 +240,7 @@ static void jabber_auth_start_cyrus(Jabb
- disallow_plaintext_auth);
- return;
- } else {
-- gaim_connection_error(js->gc, _("Server does not use any supported authentication method"));
-+ gaim2_connection_error(js->gc, _("Server does not use any supported authentication method"));
- return;
- }
- /* not reached */
-@@ -253,7 +253,7 @@ static void jabber_auth_start_cyrus(Jabb
-
- /* For everything else, fail the mechanism and try again */
- default:
-- gaim_debug_info("sasl", "sasl_state is %d, failing the mech and trying again\n", js->sasl_state);
-+ gaim2_debug_info("sasl", "sasl_state is %d, failing the mech and trying again\n", js->sasl_state);
- if (strlen(mech)>0) {
- char *pos;
- pos = strstr(js->sasl_mechs->str,mech);
-@@ -273,7 +273,7 @@ static void jabber_auth_start_cyrus(Jabb
- if (coutlen == 0) {
- xmlnode_insert_data(auth, "=", -1);
- } else {
-- enc_out = gaim_base64_encode((unsigned char*)clientout, coutlen);
-+ enc_out = gaim2_base64_encode((unsigned char*)clientout, coutlen);
- xmlnode_insert_data(auth, enc_out, -1);
- g_free(enc_out);
- }
-@@ -281,7 +281,7 @@ static void jabber_auth_start_cyrus(Jabb
- jabber_send(js, auth);
- xmlnode_free(auth);
- } else {
-- gaim_connection_error(js->gc, "SASL authentication failed\n");
-+ gaim2_connection_error(js->gc, "SASL authentication failed\n");
- }
- }
-
-@@ -289,7 +289,7 @@ static int
- jabber_sasl_cb_log(void *context, int level, const char *message)
- {
- if(level <= SASL_LOG_TRACE)
-- gaim_debug_info("sasl", "%s\n", message);
-+ gaim2_debug_info("sasl", "%s\n", message);
-
- return SASL_OK;
- }
-@@ -316,7 +316,7 @@ jabber_auth_start(JabberStream *js, xmln
- mechs = xmlnode_get_child(packet, "mechanisms");
-
- if(!mechs) {
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- return;
- }
-
-@@ -362,7 +362,7 @@ jabber_auth_start(JabberStream *js, xmln
- js->sasl_cb[id].context = (void *)js;
- id++;
-
-- if (gaim_account_get_password(js->gc->account)) {
-+ if (gaim2_account_get_password(js->gc->account)) {
- js->sasl_cb[id].id = SASL_CB_PASS;
- js->sasl_cb[id].proc = jabber_sasl_cb_secret;
- js->sasl_cb[id].context = (void *)js;
-@@ -392,8 +392,8 @@ jabber_auth_start(JabberStream *js, xmln
- } else if(plain) {
- js->auth_type = JABBER_AUTH_PLAIN;
-
-- if(js->gsc == NULL && !gaim_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE)) {
-- gaim_request_yes_no(js->gc, _("Plaintext Authentication"),
-+ if(js->gsc == NULL && !gaim2_account_get_bool(js->gc->account, "auth_plain_in_clear", FALSE)) {
-+ gaim2_request_yes_no(js->gc, _("Plaintext Authentication"),
- _("Plaintext Authentication"),
- _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
- 2, js->gc->account, allow_plaintext_auth,
-@@ -402,7 +402,7 @@ jabber_auth_start(JabberStream *js, xmln
- }
- finish_plaintext_authentication(js);
- } else {
-- gaim_connection_error(js->gc,
-+ gaim2_connection_error(js->gc,
- _("Server does not use any supported authentication method"));
- }
- #endif
-@@ -425,7 +425,7 @@ static void auth_old_result_cb(JabberStr
- js->gc->wants_to_die = TRUE;
- }
-
-- gaim_connection_error(js->gc, msg);
-+ gaim2_connection_error(js->gc, msg);
- g_free(msg);
- }
- }
-@@ -435,14 +435,14 @@ static void auth_old_cb(JabberStream *js
- JabberIq *iq;
- xmlnode *query, *x;
- const char *type = xmlnode_get_attrib(packet, "type");
-- const char *pw = gaim_connection_get_password(js->gc);
-+ const char *pw = gaim2_connection_get_password(js->gc);
-
- if(!type) {
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- return;
- } else if(!strcmp(type, "error")) {
- char *msg = jabber_parse_error(js, packet);
-- gaim_connection_error(js->gc, msg);
-+ gaim2_connection_error(js->gc, msg);
- g_free(msg);
- } else if(!strcmp(type, "result")) {
- query = xmlnode_get_child(packet, "query");
-@@ -461,7 +461,7 @@ static void auth_old_cb(JabberStream *js
- x = xmlnode_new_child(query, "digest");
- s = g_strdup_printf("%s%s", js->stream_id, pw);
-
-- gaim_cipher_digest_region("sha1", (guchar *)s, strlen(s),
-+ gaim2_cipher_digest_region("sha1", (guchar *)s, strlen(s),
- sizeof(hashval), hashval, NULL);
-
- p = h;
-@@ -473,9 +473,9 @@ static void auth_old_cb(JabberStream *js
- jabber_iq_send(iq);
-
- } else if(xmlnode_get_child(query, "password")) {
-- if(js->gsc == NULL && !gaim_account_get_bool(js->gc->account,
-+ if(js->gsc == NULL && !gaim2_account_get_bool(js->gc->account,
- "auth_plain_in_clear", FALSE)) {
-- gaim_request_yes_no(js->gc, _("Plaintext Authentication"),
-+ gaim2_request_yes_no(js->gc, _("Plaintext Authentication"),
- _("Plaintext Authentication"),
- _("This server requires plaintext authentication over an unencrypted connection. Allow this and continue authentication?"),
- 2, js->gc->account, allow_plaintext_auth,
-@@ -484,7 +484,7 @@ static void auth_old_cb(JabberStream *js
- }
- finish_plaintext_authentication(js);
- } else {
-- gaim_connection_error(js->gc,
-+ gaim2_connection_error(js->gc,
- _("Server does not use any supported authentication method"));
- return;
- }
-@@ -536,8 +536,8 @@ static char *
- generate_response_value(JabberID *jid, const char *passwd, const char *nonce,
- const char *cnonce, const char *a2, const char *realm)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar result[16];
- size_t a1len;
-
-@@ -552,37 +552,37 @@ generate_response_value(JabberID *jid, c
- convpasswd = g_strdup(passwd);
- }
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
- x = g_strdup_printf("%s:%s:%s", convnode, realm, convpasswd ? convpasswd : "");
-- gaim_cipher_context_append(context, (const guchar *)x, strlen(x));
-- gaim_cipher_context_digest(context, sizeof(result), result, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)x, strlen(x));
-+ gaim2_cipher_context_digest(context, sizeof(result), result, NULL);
-
- a1 = g_strdup_printf("xxxxxxxxxxxxxxxx:%s:%s", nonce, cnonce);
- a1len = strlen(a1);
- g_memmove(a1, result, 16);
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)a1, a1len);
-- gaim_cipher_context_digest(context, sizeof(result), result, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)a1, a1len);
-+ gaim2_cipher_context_digest(context, sizeof(result), result, NULL);
-
-- ha1 = gaim_base16_encode(result, 16);
-+ ha1 = gaim2_base16_encode(result, 16);
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)a2, strlen(a2));
-- gaim_cipher_context_digest(context, sizeof(result), result, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)a2, strlen(a2));
-+ gaim2_cipher_context_digest(context, sizeof(result), result, NULL);
-
-- ha2 = gaim_base16_encode(result, 16);
-+ ha2 = gaim2_base16_encode(result, 16);
-
- kd = g_strdup_printf("%s:%s:00000001:%s:auth:%s", ha1, nonce, cnonce, ha2);
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)kd, strlen(kd));
-- gaim_cipher_context_digest(context, sizeof(result), result, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)kd, strlen(kd));
-+ gaim2_cipher_context_digest(context, sizeof(result), result, NULL);
-+ gaim2_cipher_context_destroy(context);
-
-- z = gaim_base16_encode(result, 16);
-+ z = gaim2_base16_encode(result, 16);
-
- g_free(convnode);
- g_free(convpasswd);
-@@ -606,12 +606,12 @@ jabber_auth_handle_challenge(JabberStrea
- GHashTable *parts;
-
- if(!enc_in) {
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- return;
- }
-
-- dec_in = (char *)gaim_base64_decode(enc_in, NULL);
-- gaim_debug(GAIM_DEBUG_MISC, "jabber", "decoded challenge (%d): %s\n",
-+ dec_in = (char *)gaim2_base64_decode(enc_in, NULL);
-+ gaim2_debug(GAIM_DEBUG_MISC, "jabber", "decoded challenge (%d): %s\n",
- strlen(dec_in), dec_in);
-
- parts = parse_challenge(dec_in);
-@@ -627,7 +627,7 @@ jabber_auth_handle_challenge(JabberStrea
- "<response xmlns='urn:ietf:params:xml:ns:xmpp-sasl' />",
- -1);
- } else {
-- gaim_connection_error(js->gc, _("Invalid challenge from server"));
-+ gaim2_connection_error(js->gc, _("Invalid challenge from server"));
- }
- g_free(js->expected_rspauth);
- } else {
-@@ -656,12 +656,12 @@ jabber_auth_handle_challenge(JabberStrea
-
- a2 = g_strdup_printf("AUTHENTICATE:xmpp/%s", realm);
- auth_resp = generate_response_value(js->user,
-- gaim_connection_get_password(js->gc), nonce, cnonce, a2, realm);
-+ gaim2_connection_get_password(js->gc), nonce, cnonce, a2, realm);
- g_free(a2);
-
- a2 = g_strdup_printf(":xmpp/%s", realm);
- js->expected_rspauth = generate_response_value(js->user,
-- gaim_connection_get_password(js->gc), nonce, cnonce, a2, realm);
-+ gaim2_connection_get_password(js->gc), nonce, cnonce, a2, realm);
- g_free(a2);
-
-
-@@ -678,9 +678,9 @@ jabber_auth_handle_challenge(JabberStrea
- g_free(auth_resp);
- g_free(cnonce);
-
-- enc_out = gaim_base64_encode((guchar *)response->str, response->len);
-+ enc_out = gaim2_base64_encode((guchar *)response->str, response->len);
-
-- gaim_debug(GAIM_DEBUG_MISC, "jabber", "decoded response (%d): %s\n", response->len, response->str);
-+ gaim2_debug(GAIM_DEBUG_MISC, "jabber", "decoded response (%d): %s\n", response->len, response->str);
-
- buf = g_strdup_printf("<response xmlns='urn:ietf:params:xml:ns:xmpp-sasl'>%s</response>", enc_out);
-
-@@ -707,20 +707,20 @@ jabber_auth_handle_challenge(JabberStrea
- gsize declen;
- xmlnode *response;
-
-- dec_in = gaim_base64_decode(enc_in, &declen);
-+ dec_in = gaim2_base64_decode(enc_in, &declen);
-
- js->sasl_state = sasl_client_step(js->sasl, (char*)dec_in, declen,
- NULL, &c_out, &clen);
- g_free(dec_in);
- if (js->sasl_state != SASL_CONTINUE && js->sasl_state != SASL_OK) {
-- gaim_debug_error("jabber", "Error is %d : %s\n",js->sasl_state,sasl_errdetail(js->sasl));
-- gaim_connection_error(js->gc, _("SASL error"));
-+ gaim2_debug_error("jabber", "Error is %d : %s\n",js->sasl_state,sasl_errdetail(js->sasl));
-+ gaim2_connection_error(js->gc, _("SASL error"));
- return;
- } else {
- response = xmlnode_new("response");
- xmlnode_set_attrib(response, "xmlns", "urn:ietf:params:xml:ns:xmpp-sasl");
- if (c_out) {
-- enc_out = gaim_base64_encode((unsigned char*)c_out, clen);
-+ enc_out = gaim2_base64_encode((unsigned char*)c_out, clen);
- xmlnode_insert_data(response, enc_out, -1);
- g_free(enc_out);
- }
-@@ -739,7 +739,7 @@ void jabber_auth_handle_success(JabberSt
- #endif
-
- if(!ns || strcmp(ns, "urn:ietf:params:xml:ns:xmpp-sasl")) {
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- return;
- }
-
-@@ -751,7 +751,7 @@ void jabber_auth_handle_success(JabberSt
- js->sasl_state = sasl_client_step(js->sasl, NULL, 0, NULL, NULL, NULL);
- if (js->sasl_state != SASL_OK) {
- /* This should never happen! */
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- }
- }
- /* If we've negotiated a security layer, we need to enable it */
-@@ -770,9 +770,9 @@ void jabber_auth_handle_failure(JabberSt
- char *msg = jabber_parse_error(js, packet);
-
- if(!msg) {
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- } else {
-- gaim_connection_error(js->gc, msg);
-+ gaim2_connection_error(js->gc, msg);
- g_free(msg);
- }
- }
-diff -prNu ./src/protocols/jabber/auth.h ./src/protocols/jabber/auth.h
---- ./src/protocols/jabber/auth.h 2004-02-19 15:57:39.000000000 +0100
-+++ ./src/protocols/jabber/auth.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file auth.h Authentication routines
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/jabber/buddy.c ./src/protocols/jabber/buddy.c
---- ./src/protocols/jabber/buddy.c 2006-01-01 17:25:16.000000000 +0100
-+++ ./src/protocols/jabber/buddy.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -356,7 +356,7 @@ static xmlnode *insert_tag_to_parent_tag
- /*
- * Send vCard info to Jabber server
- */
--void jabber_set_info(GaimConnection *gc, const char *info)
-+void jabber_set_info(Gaim2Connection *gc, const char *info)
- {
- JabberIq *iq;
- JabberStream *js = gc->proto_data;
-@@ -371,7 +371,7 @@ void jabber_set_info(GaimConnection *gc,
- * Send only if there's actually any *information* to send
- */
- vc_node = info ? xmlnode_from_str(info, -1) : NULL;
-- avatar_file = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(gc->account));
-+ avatar_file = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(gc->account));
-
- if(!vc_node && avatar_file) {
- vc_node = xmlnode_new("vCard");
-@@ -395,9 +395,9 @@ void jabber_set_info(GaimConnection *gc,
- avatar_data = (guchar *) avatar_data_tmp;
- photo = xmlnode_new_child(vc_node, "PHOTO");
- binval = xmlnode_new_child(photo, "BINVAL");
-- enc = gaim_base64_encode(avatar_data, avatar_len);
-+ enc = gaim2_base64_encode(avatar_data, avatar_len);
-
-- gaim_cipher_digest_region("sha1", (guchar *)avatar_data,
-+ gaim2_cipher_digest_region("sha1", (guchar *)avatar_data,
- avatar_len, sizeof(hashval),
- hashval, NULL);
-
-@@ -423,15 +423,15 @@ void jabber_set_info(GaimConnection *gc,
- }
- }
-
--void jabber_set_buddy_icon(GaimConnection *gc, const char *iconfile)
-+void jabber_set_buddy_icon(Gaim2Connection *gc, const char *iconfile)
- {
-- GaimPresence *gpresence;
-- GaimStatus *status;
-+ Gaim2Presence *gpresence;
-+ Gaim2Status *status;
-
-- jabber_set_info(gc, gaim_account_get_user_info(gc->account));
-+ jabber_set_info(gc, gaim2_account_get_user_info(gc->account));
-
-- gpresence = gaim_account_get_presence(gc->account);
-- status = gaim_presence_get_active_status(gpresence);
-+ gpresence = gaim2_account_get_presence(gc->account);
-+ status = gaim2_presence_get_active_status(gpresence);
- jabber_presence_send(gc->account, status);
- }
-
-@@ -445,11 +445,11 @@ void jabber_set_buddy_icon(GaimConnectio
- * the caller.
- */
- static void
--jabber_format_info(GaimConnection *gc, GaimRequestFields *fields)
-+jabber_format_info(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- xmlnode *vc_node;
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
- const char *text;
- char *p;
- const struct vcard_template *vc_tp;
-@@ -464,14 +464,14 @@ jabber_format_info(GaimConnection *gc, G
- if (*vc_tp->label == '\0')
- continue;
-
-- field = gaim_request_fields_get_field(fields, vc_tp->tag);
-- text = gaim_request_field_string_get_value(field);
-+ field = gaim2_request_fields_get_field(fields, vc_tp->tag);
-+ text = gaim2_request_field_string_get_value(field);
-
-
- if (text != NULL && *text != '\0') {
- xmlnode *xp;
-
-- gaim_debug(GAIM_DEBUG_INFO, "jabber",
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber",
- "Setting %s to '%s'\n", vc_tp->tag, text);
-
- if ((xp = insert_tag_to_parent_tag(vc_node,
-@@ -485,10 +485,10 @@ jabber_format_info(GaimConnection *gc, G
- p = xmlnode_to_str(vc_node, NULL);
- xmlnode_free(vc_node);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- if (account != NULL) {
-- gaim_account_set_user_info(account, p);
-+ gaim2_account_set_user_info(account, p);
-
- if (gc != NULL)
- serv_set_info(gc, p);
-@@ -500,29 +500,29 @@ jabber_format_info(GaimConnection *gc, G
- /*
- * This gets executed by the proto action
- *
-- * Creates a new GaimRequestFields struct, gets the XML-formatted user_info
-+ * Creates a new Gaim2RequestFields struct, gets the XML-formatted user_info
- * string (if any) into GSLists for the (multi-entry) edit dialog and
- * calls the set_vcard dialog.
- */
--void jabber_setup_set_info(GaimPluginAction *action)
-+void jabber_setup_set_info(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
- const struct vcard_template *vc_tp;
- char *user_info;
- char *cdata;
- xmlnode *x_vc_data = NULL;
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
- /*
- * Get existing, XML-formatted, user info
- */
-- if((user_info = g_strdup(gaim_account_get_user_info(gc->account))) != NULL)
-+ if((user_info = g_strdup(gaim2_account_get_user_info(gc->account))) != NULL)
- x_vc_data = xmlnode_from_str(user_info, -1);
- else
- user_info = g_strdup("");
-@@ -547,16 +547,16 @@ void jabber_setup_set_info(GaimPluginAct
- cdata = NULL;
-
- if(strcmp(vc_tp->tag, "DESC") == 0) {
-- field = gaim_request_field_string_new(vc_tp->tag,
-+ field = gaim2_request_field_string_new(vc_tp->tag,
- _(vc_tp->label), cdata,
- TRUE);
- } else {
-- field = gaim_request_field_string_new(vc_tp->tag,
-+ field = gaim2_request_field_string_new(vc_tp->tag,
- _(vc_tp->label), cdata,
- FALSE);
- }
-
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
-
- if(x_vc_data != NULL)
-@@ -564,7 +564,7 @@ void jabber_setup_set_info(GaimPluginAct
-
- g_free(user_info);
-
-- gaim_request_fields(gc, _("Edit Jabber vCard"),
-+ gaim2_request_fields(gc, _("Edit Jabber vCard"),
- _("Edit Jabber vCard"),
- _("All items below are optional. Enter only the "
- "information with which you feel comfortable."),
-@@ -594,7 +594,7 @@ static void jabber_vcard_parse(JabberStr
- char *bare_jid;
- char *text;
- xmlnode *vcard;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- GSList *imgids = NULL;
-
- if(!from)
-@@ -608,7 +608,7 @@ static void jabber_vcard_parse(JabberStr
- resource_name = jabber_get_resource(from);
- bare_jid = jabber_get_bare_jid(from);
-
-- b = gaim_find_buddy(js->gc->account, bare_jid);
-+ b = gaim2_find_buddy(js->gc->account, bare_jid);
-
-
- info_text = g_string_new("");
-@@ -618,7 +618,7 @@ static void jabber_vcard_parse(JabberStr
- if(jbr) {
- char *purdy = NULL;
- if(jbr->status)
-- purdy = gaim_strdup_withhtml(jbr->status);
-+ purdy = gaim2_strdup_withhtml(jbr->status);
- g_string_append_printf(info_text, "<b>%s:</b> %s%s%s<br/>",
- _("Status"), jabber_buddy_state_get_name(jbr->state),
- purdy ? ": " : "",
-@@ -634,7 +634,7 @@ static void jabber_vcard_parse(JabberStr
- char *purdy = NULL;
- jbr = resources->data;
- if(jbr->status)
-- purdy = gaim_strdup_withhtml(jbr->status);
-+ purdy = gaim2_strdup_withhtml(jbr->status);
- g_string_append_printf(info_text, "<b>%s:</b> %s<br/>",
- _("Resource"), jbr->name);
- g_string_append_printf(info_text, "<b>%s:</b> %s%s%s<br/><br/>",
-@@ -689,7 +689,7 @@ static void jabber_vcard_parse(JabberStr
- } else if(text && !strcmp(child->name, "NICKNAME")) {
- serv_got_alias(js->gc, from, text);
- if(b) {
-- gaim_blist_node_set_string((GaimBlistNode*)b, "servernick", text);
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)b, "servernick", text);
- }
- g_string_append_printf(info_text, "<b>%s:</b> %s<br/>",
- _("Nickname"), text);
-@@ -752,7 +752,7 @@ static void jabber_vcard_parse(JabberStr
- g_free(number);
- }
- } else if((number = xmlnode_get_data(child))) {
-- /* lots of clients (including gaim) do this, but it's
-+ /* lots of clients (including gaim2) do this, but it's
- * out of spec */
- g_string_append_printf(info_text,
- "<b>%s:</b> %s<br/>", _("Telephone"), number);
-@@ -770,7 +770,7 @@ static void jabber_vcard_parse(JabberStr
- g_free(userid);
- }
- } else if((userid = xmlnode_get_data(child))) {
-- /* lots of clients (including gaim) do this, but it's
-+ /* lots of clients (including gaim2) do this, but it's
- * out of spec */
- g_string_append_printf(info_text,
- "<b>%s:</b> <a href='mailto:%s'>%s</a><br/>",
-@@ -821,23 +821,23 @@ static void jabber_vcard_parse(JabberStr
- char *p, hash[41];
- gboolean photo = (strcmp(child->name, "PHOTO") == 0);
-
-- data = gaim_base64_decode(bintext, &size);
-+ data = gaim2_base64_decode(bintext, &size);
-
-- imgids = g_slist_prepend(imgids, GINT_TO_POINTER(gaim_imgstore_add(data, size, "logo.png")));
-+ imgids = g_slist_prepend(imgids, GINT_TO_POINTER(gaim2_imgstore_add(data, size, "logo.png")));
- g_string_append_printf(info_text,
- "<b>%s:</b> <img id='%d'><br/>",
- photo ? _("Photo") : _("Logo"),
- GPOINTER_TO_INT(imgids->data));
-
-- gaim_buddy_icons_set_for_user(js->gc->account, bare_jid,
-+ gaim2_buddy_icons_set_for_user(js->gc->account, bare_jid,
- data, size);
-
-- gaim_cipher_digest_region("sha1", (guchar *)data, size,
-+ gaim2_cipher_digest_region("sha1", (guchar *)data, size,
- sizeof(hashval), hashval, NULL);
- p = hash;
- for(i=0; i<20; i++, p+=2)
- snprintf(p, 3, "%02x", hashval[i]);
-- gaim_blist_node_set_string((GaimBlistNode*)b, "avatar_hash", hash);
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)b, "avatar_hash", hash);
-
- g_free(data);
- g_free(bintext);
-@@ -847,12 +847,12 @@ static void jabber_vcard_parse(JabberStr
- }
- }
-
-- text = gaim_strdup_withhtml(info_text->str);
-+ text = gaim2_strdup_withhtml(info_text->str);
-
-- gaim_notify_userinfo(js->gc, from, text, NULL, NULL);
-+ gaim2_notify_userinfo(js->gc, from, text, NULL, NULL);
-
- while(imgids) {
-- gaim_imgstore_unref(GPOINTER_TO_INT(imgids->data));
-+ gaim2_imgstore_unref(GPOINTER_TO_INT(imgids->data));
- imgids = g_slist_delete_link(imgids, imgids);
- }
- g_string_free(info_text, TRUE);
-@@ -876,7 +876,7 @@ static void jabber_buddy_get_info_for_ji
- jabber_iq_send(iq);
- }
-
--void jabber_buddy_get_info(GaimConnection *gc, const char *who)
-+void jabber_buddy_get_info(Gaim2Connection *gc, const char *who)
- {
- JabberStream *js = gc->proto_data;
- char *bare_jid = jabber_get_bare_jid(who);
-@@ -887,7 +887,7 @@ void jabber_buddy_get_info(GaimConnectio
- }
- }
-
--void jabber_buddy_get_info_chat(GaimConnection *gc, int id,
-+void jabber_buddy_get_info_chat(Gaim2Connection *gc, int id,
- const char *resource)
- {
- JabberStream *js = gc->proto_data;
-@@ -906,20 +906,20 @@ void jabber_buddy_get_info_chat(GaimConn
- static void jabber_buddy_set_invisibility(JabberStream *js, const char *who,
- gboolean invisible)
- {
-- GaimPresence *gpresence;
-- GaimAccount *account;
-- GaimStatus *status;
-+ Gaim2Presence *gpresence;
-+ Gaim2Account *account;
-+ Gaim2Status *status;
- JabberBuddy *jb = jabber_buddy_find(js, who, TRUE);
- xmlnode *presence;
- JabberBuddyState state;
- const char *msg;
- int priority;
-
-- account = gaim_connection_get_account(js->gc);
-- gpresence = gaim_account_get_presence(account);
-- status = gaim_presence_get_active_status(gpresence);
-+ account = gaim2_connection_get_account(js->gc);
-+ gpresence = gaim2_account_get_presence(account);
-+ status = gaim2_presence_get_active_status(gpresence);
-
-- gaim_status_to_jabber(status, &state, &msg, &priority);
-+ gaim2_status_to_jabber(status, &state, &msg, &priority);
- presence = jabber_presence_create(state, msg, priority);
-
- xmlnode_set_attrib(presence, "to", who);
-@@ -934,93 +934,93 @@ static void jabber_buddy_set_invisibilit
- xmlnode_free(presence);
- }
-
--static void jabber_buddy_make_invisible(GaimBlistNode *node, gpointer data)
-+static void jabber_buddy_make_invisible(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- JabberStream *js;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- js = gc->proto_data;
-
- jabber_buddy_set_invisibility(js, buddy->name, TRUE);
- }
-
--static void jabber_buddy_make_visible(GaimBlistNode *node, gpointer data)
-+static void jabber_buddy_make_visible(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- JabberStream *js;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- js = gc->proto_data;
-
- jabber_buddy_set_invisibility(js, buddy->name, FALSE);
- }
-
--static void jabber_buddy_cancel_presence_notification(GaimBlistNode *node,
-+static void jabber_buddy_cancel_presence_notification(Gaim2BlistNode *node,
- gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- JabberStream *js;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- js = gc->proto_data;
-
- /* I wonder if we should prompt the user before doing this */
- jabber_presence_subscription_set(js, buddy->name, "unsubscribed");
- }
-
--static void jabber_buddy_rerequest_auth(GaimBlistNode *node, gpointer data)
-+static void jabber_buddy_rerequest_auth(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- JabberStream *js;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- js = gc->proto_data;
-
- jabber_presence_subscription_set(js, buddy->name, "subscribe");
- }
-
-
--static void jabber_buddy_unsubscribe(GaimBlistNode *node, gpointer data)
-+static void jabber_buddy_unsubscribe(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- JabberStream *js;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- js = gc->proto_data;
-
- jabber_presence_subscription_set(js, buddy->name, "unsubscribe");
- }
-
-
--static GList *jabber_buddy_menu(GaimBuddy *buddy)
-+static GList *jabber_buddy_menu(Gaim2Buddy *buddy)
- {
-- GaimConnection *gc = gaim_account_get_connection(buddy->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(buddy->account);
- JabberStream *js = gc->proto_data;
- JabberBuddy *jb = jabber_buddy_find(js, buddy->name, TRUE);
-
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
- if(!jb)
- return m;
-@@ -1029,23 +1029,23 @@ static GList *jabber_buddy_menu(GaimBudd
-
- if(js->protocol_version == JABBER_PROTO_0_9 /* && NOT ME */) {
- if(jb->invisible & JABBER_INVIS_BUDDY) {
-- act = gaim_blist_node_action_new(_("Un-hide From"),
-+ act = gaim2_blist_node_action_new(_("Un-hide From"),
- jabber_buddy_make_visible, NULL, NULL);
- } else {
-- act = gaim_blist_node_action_new(_("Temporarily Hide From"),
-+ act = gaim2_blist_node_action_new(_("Temporarily Hide From"),
- jabber_buddy_make_invisible, NULL, NULL);
- }
- m = g_list_append(m, act);
- }
-
- if(jb->subscription & JABBER_SUB_FROM /* && NOT ME */) {
-- act = gaim_blist_node_action_new(_("Cancel Presence Notification"),
-+ act = gaim2_blist_node_action_new(_("Cancel Presence Notification"),
- jabber_buddy_cancel_presence_notification, NULL, NULL);
- m = g_list_append(m, act);
- }
-
- if(!(jb->subscription & JABBER_SUB_TO)) {
-- act = gaim_blist_node_action_new(_("(Re-)Request authorization"),
-+ act = gaim2_blist_node_action_new(_("(Re-)Request authorization"),
- jabber_buddy_rerequest_auth, NULL, NULL);
- m = g_list_append(m, act);
-
-@@ -1053,7 +1053,7 @@ static GList *jabber_buddy_menu(GaimBudd
-
- /* shouldn't this just happen automatically when the buddy is
- removed? */
-- act = gaim_blist_node_action_new(_("Unsubscribe"),
-+ act = gaim2_blist_node_action_new(_("Unsubscribe"),
- jabber_buddy_unsubscribe, NULL, NULL);
- m = g_list_append(m, act);
- }
-@@ -1062,10 +1062,10 @@ static GList *jabber_buddy_menu(GaimBudd
- }
-
- GList *
--jabber_blist_node_menu(GaimBlistNode *node)
-+jabber_blist_node_menu(Gaim2BlistNode *node)
- {
- if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- return jabber_buddy_menu((GaimBuddy *) node);
-+ return jabber_buddy_menu((Gaim2Buddy *) node);
- } else {
- return NULL;
- }
-@@ -1181,27 +1181,27 @@ const char *jabber_buddy_state_get_statu
- return NULL;
- }
-
--static void user_search_result_add_buddy_cb(GaimConnection *gc, GList *row)
-+static void user_search_result_add_buddy_cb(Gaim2Connection *gc, GList *row)
- {
- /* XXX find out the jid */
-- gaim_blist_request_add_buddy(gaim_connection_get_account(gc),
-+ gaim2_blist_request_add_buddy(gaim2_connection_get_account(gc),
- g_list_nth_data(row, 0), NULL, NULL);
- }
-
- static void user_search_result_cb(JabberStream *js, xmlnode *packet, gpointer data)
- {
-- GaimNotifySearchResults *results;
-- GaimNotifySearchColumn *column;
-+ Gaim2NotifySearchResults *results;
-+ Gaim2NotifySearchColumn *column;
- xmlnode *x, *query, *item, *field;
-
- /* XXX error checking? */
- if(!(query = xmlnode_get_child(packet, "query")))
- return;
-
-- results = gaim_notify_searchresults_new();
-+ results = gaim2_notify_searchresults_new();
- if((x = xmlnode_get_child_with_namespace(query, "x", "jabber:x:data"))) {
- xmlnode *reported;
-- gaim_debug_info("jabber", "new-skool\n");
-+ gaim2_debug_info("jabber", "new-skool\n");
- if((reported = xmlnode_get_child(x, "reported"))) {
- xmlnode *field = xmlnode_get_child(reported, "field");
- while(field) {
-@@ -1209,8 +1209,8 @@ static void user_search_result_cb(Jabber
- const char *var = xmlnode_get_attrib(field, "var");
- const char *label = xmlnode_get_attrib(field, "label");
- if(var) {
-- column = gaim_notify_searchresults_column_new(label ? label : var);
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new(label ? label : var);
-+ gaim2_notify_searchresults_column_add(results, column);
- }
- field = xmlnode_get_next_twin(field);
- }
-@@ -1227,24 +1227,24 @@ static void user_search_result_cb(Jabber
- }
- field = xmlnode_get_next_twin(field);
- }
-- gaim_notify_searchresults_row_add(results, row);
-+ gaim2_notify_searchresults_row_add(results, row);
-
- item = xmlnode_get_next_twin(item);
- }
- } else {
- /* old skool */
-- gaim_debug_info("jabber", "old-skool\n");
-+ gaim2_debug_info("jabber", "old-skool\n");
-
-- column = gaim_notify_searchresults_column_new("JID");
-- gaim_notify_searchresults_column_add(results, column);
-- column = gaim_notify_searchresults_column_new("First");
-- gaim_notify_searchresults_column_add(results, column);
-- column = gaim_notify_searchresults_column_new("Last");
-- gaim_notify_searchresults_column_add(results, column);
-- column = gaim_notify_searchresults_column_new("Nickname");
-- gaim_notify_searchresults_column_add(results, column);
-- column = gaim_notify_searchresults_column_new("E-Mail");
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new("JID");
-+ gaim2_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new("First");
-+ gaim2_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new("Last");
-+ gaim2_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new("Nickname");
-+ gaim2_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new("E-Mail");
-+ gaim2_notify_searchresults_column_add(results, column);
-
- for(item = xmlnode_get_child(query, "item"); item; item = xmlnode_get_next_twin(item)) {
- const char *jid;
-@@ -1263,15 +1263,15 @@ static void user_search_result_cb(Jabber
- row = g_list_append(row, node ? xmlnode_get_data(node) : NULL);
- node = xmlnode_get_child(item, "email");
- row = g_list_append(row, node ? xmlnode_get_data(node) : NULL);
-- gaim_debug_info("jabber", "row=%d\n", row);
-- gaim_notify_searchresults_row_add(results, row);
-+ gaim2_debug_info("jabber", "row=%d\n", row);
-+ gaim2_notify_searchresults_row_add(results, row);
- }
- }
-
-- gaim_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_ADD,
-+ gaim2_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_ADD,
- user_search_result_add_buddy_cb);
-
-- gaim_notify_searchresults(js->gc, NULL, NULL, _("The following are the results of your search"), results, NULL, NULL);
-+ gaim2_notify_searchresults(js->gc, NULL, NULL, _("The following are the results of your search"), results, NULL, NULL);
- }
-
- static void user_search_x_data_cb(JabberStream *js, xmlnode *result, gpointer data)
-@@ -1293,13 +1293,13 @@ struct user_search_info {
- char *directory_server;
- };
-
--static void user_search_cancel_cb(struct user_search_info *usi, GaimRequestFields *fields)
-+static void user_search_cancel_cb(struct user_search_info *usi, Gaim2RequestFields *fields)
- {
- g_free(usi->directory_server);
- g_free(usi);
- }
-
--static void user_search_cb(struct user_search_info *usi, GaimRequestFields *fields)
-+static void user_search_cb(struct user_search_info *usi, Gaim2RequestFields *fields)
- {
- JabberStream *js = usi->js;
- JabberIq *iq;
-@@ -1309,12 +1309,12 @@ static void user_search_cb(struct user_s
- iq = jabber_iq_new_query(js, JABBER_IQ_SET, "jabber:iq:search");
- query = xmlnode_get_child(iq->node, "query");
-
-- for(groups = gaim_request_fields_get_groups(fields); groups; groups = groups->next) {
-- for(flds = gaim_request_field_group_get_fields(groups->data);
-+ for(groups = gaim2_request_fields_get_groups(fields); groups; groups = groups->next) {
-+ for(flds = gaim2_request_field_group_get_fields(groups->data);
- flds; flds = flds->next) {
-- GaimRequestField *field = flds->data;
-- const char *id = gaim_request_field_get_id(field);
-- const char *value = gaim_request_field_string_get_value(field);
-+ Gaim2RequestField *field = flds->data;
-+ const char *id = gaim2_request_field_get_id(field);
-+ const char *value = gaim2_request_field_string_get_value(field);
-
- if(value && (!strcmp(id, "first") || !strcmp(id, "last") || !strcmp(id, "nick") || !strcmp(id, "email"))) {
- xmlnode *y = xmlnode_new_child(query, id);
-@@ -1351,14 +1351,14 @@ static void user_search_fields_result_cb
- struct user_search_info *usi;
- xmlnode *instnode;
- char *instructions;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- /* old skool */
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
- if((instnode = xmlnode_get_child(query, "instructions")))
- instructions = xmlnode_get_data(instnode);
-@@ -1367,31 +1367,31 @@ static void user_search_fields_result_cb
- "for any matching Jabber users."));
-
- if(xmlnode_get_child(query, "first")) {
-- field = gaim_request_field_string_new("first", _("First Name"),
-+ field = gaim2_request_field_string_new("first", _("First Name"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "last")) {
-- field = gaim_request_field_string_new("last", _("Last Name"),
-+ field = gaim2_request_field_string_new("last", _("Last Name"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "nick")) {
-- field = gaim_request_field_string_new("nick", _("Nickname"),
-+ field = gaim2_request_field_string_new("nick", _("Nickname"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "email")) {
-- field = gaim_request_field_string_new("email", _("E-Mail Address"),
-+ field = gaim2_request_field_string_new("email", _("E-Mail Address"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
-
- usi = g_new0(struct user_search_info, 1);
- usi->js = js;
- usi->directory_server = g_strdup(from);
-
-- gaim_request_fields(js->gc, _("Search for Jabber users"),
-+ gaim2_request_fields(js->gc, _("Search for Jabber users"),
- _("Search for Jabber users"), instructions, fields,
- _("Search"), G_CALLBACK(user_search_cb),
- _("Cancel"), G_CALLBACK(user_search_cancel_cb), usi);
-@@ -1406,7 +1406,7 @@ static void jabber_user_search_ok(Jabber
-
- /* XXX: should probably better validate the directory we're given */
- if(!directory || !*directory) {
-- gaim_notify_error(js->gc, _("Invalid Directory"), _("Invalid Directory"), NULL);
-+ gaim2_notify_error(js->gc, _("Invalid Directory"), _("Invalid Directory"), NULL);
- return;
- }
-
-@@ -1418,12 +1418,12 @@ static void jabber_user_search_ok(Jabber
- jabber_iq_send(iq);
- }
-
--void jabber_user_search_begin(GaimPluginAction *action)
-+void jabber_user_search_begin(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- JabberStream *js = gc->proto_data;
-
-- gaim_request_input(gc, _("Enter a User Directory"), _("Enter a User Directory"),
-+ gaim2_request_input(gc, _("Enter a User Directory"), _("Enter a User Directory"),
- _("Select a user directory to search"),
- js->user_directories ? js->user_directories->data : "users.jabber.org",
- FALSE, FALSE, NULL,
-diff -prNu ./src/protocols/jabber/buddy.h ./src/protocols/jabber/buddy.h
---- ./src/protocols/jabber/buddy.h 2006-01-01 17:25:17.000000000 +0100
-+++ ./src/protocols/jabber/buddy.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file buddy.h Buddy handlers
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -73,15 +73,15 @@ JabberBuddyResource *jabber_buddy_track_
- void jabber_buddy_resource_free(JabberBuddyResource *jbr);
- void jabber_buddy_remove_resource(JabberBuddy *jb, const char *resource);
- const char *jabber_buddy_get_status_msg(JabberBuddy *jb);
--void jabber_buddy_get_info(GaimConnection *gc, const char *who);
--void jabber_buddy_get_info_chat(GaimConnection *gc, int id,
-+void jabber_buddy_get_info(Gaim2Connection *gc, const char *who);
-+void jabber_buddy_get_info_chat(Gaim2Connection *gc, int id,
- const char *resource);
-
--GList *jabber_blist_node_menu(GaimBlistNode *node);
-+GList *jabber_blist_node_menu(Gaim2BlistNode *node);
-
--void jabber_set_info(GaimConnection *gc, const char *info);
--void jabber_setup_set_info(GaimPluginAction *action);
--void jabber_set_buddy_icon(GaimConnection *gc, const char *iconfile);
-+void jabber_set_info(Gaim2Connection *gc, const char *info);
-+void jabber_setup_set_info(Gaim2PluginAction *action);
-+void jabber_set_buddy_icon(Gaim2Connection *gc, const char *iconfile);
-
- const char *jabber_buddy_state_get_name(JabberBuddyState state);
- const char *jabber_buddy_state_get_status_id(JabberBuddyState state);
-@@ -89,6 +89,6 @@ const char *jabber_buddy_state_get_show(
- JabberBuddyState jabber_buddy_status_id_get_state(const char *id);
- JabberBuddyState jabber_buddy_show_get_state(const char *id);
-
--void jabber_user_search_begin(GaimPluginAction *);
-+void jabber_user_search_begin(Gaim2PluginAction *);
-
- #endif /* _GAIM_JABBER_BUDDY_H_ */
-diff -prNu ./src/protocols/jabber/chat.c ./src/protocols/jabber/chat.c
---- ./src/protocols/jabber/chat.c 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/jabber/chat.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -32,7 +32,7 @@
- #include "presence.h"
- #include "xdata.h"
-
--GList *jabber_chat_info(GaimConnection *gc)
-+GList *jabber_chat_info(Gaim2Connection *gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -64,7 +64,7 @@ GList *jabber_chat_info(GaimConnection *
- return m;
- }
-
--GHashTable *jabber_chat_info_defaults(GaimConnection *gc, const char *chat_name)
-+GHashTable *jabber_chat_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
- JabberStream *js = gc->proto_data;
-@@ -133,17 +133,17 @@ JabberChat *jabber_chat_find_by_id(Jabbe
- return chat;
- }
-
--JabberChat *jabber_chat_find_by_conv(GaimConversation *conv)
-+JabberChat *jabber_chat_find_by_conv(Gaim2Conversation *conv)
- {
-- GaimAccount *account = gaim_conversation_get_account(conv);
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Account *account = gaim2_conversation_get_account(conv);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- JabberStream *js = gc->proto_data;
-- int id = gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-+ int id = gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-
- return jabber_chat_find_by_id(js, id);
- }
-
--void jabber_chat_invite(GaimConnection *gc, int id, const char *msg,
-+void jabber_chat_invite(Gaim2Connection *gc, int id, const char *msg,
- const char *name)
- {
- JabberStream *js = gc->proto_data;
-@@ -195,15 +195,15 @@ char *jabber_get_chat_name(GHashTable *d
- return chat_name;
- }
-
--void jabber_chat_join(GaimConnection *gc, GHashTable *data)
-+void jabber_chat_join(Gaim2Connection *gc, GHashTable *data)
- {
- JabberChat *chat;
- char *room, *server, *handle, *passwd;
- xmlnode *presence, *x;
- char *tmp, *room_jid, *full_jid;
- JabberStream *js = gc->proto_data;
-- GaimPresence *gpresence;
-- GaimStatus *status;
-+ Gaim2Presence *gpresence;
-+ Gaim2Status *status;
- JabberBuddyState state;
- const char *msg;
- int priority;
-@@ -221,19 +221,19 @@ void jabber_chat_join(GaimConnection *gc
-
- if(!jabber_nodeprep_validate(room)) {
- char *buf = g_strdup_printf(_("%s is not a valid room name"), room);
-- gaim_notify_error(gc, _("Invalid Room Name"), _("Invalid Room Name"),
-+ gaim2_notify_error(gc, _("Invalid Room Name"), _("Invalid Room Name"),
- buf);
- g_free(buf);
- return;
- } else if(!jabber_nameprep_validate(server)) {
- char *buf = g_strdup_printf(_("%s is not a valid server name"), server);
-- gaim_notify_error(gc, _("Invalid Server Name"),
-+ gaim2_notify_error(gc, _("Invalid Server Name"),
- _("Invalid Server Name"), buf);
- g_free(buf);
- return;
- } else if(!jabber_resourceprep_validate(handle)) {
- char *buf = g_strdup_printf(_("%s is not a valid room handle"), handle);
-- gaim_notify_error(gc, _("Invalid Room Handle"),
-+ gaim2_notify_error(gc, _("Invalid Room Handle"),
- _("Invalid Room Handle"), buf);
- }
-
-@@ -256,10 +256,10 @@ void jabber_chat_join(GaimConnection *gc
-
- g_hash_table_insert(js->chats, room_jid, chat);
-
-- gpresence = gaim_account_get_presence(gc->account);
-- status = gaim_presence_get_active_status(gpresence);
-+ gpresence = gaim2_account_get_presence(gc->account);
-+ status = gaim2_presence_get_active_status(gpresence);
-
-- gaim_status_to_jabber(status, &state, &msg, &priority);
-+ gaim2_status_to_jabber(status, &state, &msg, &priority);
-
- presence = jabber_presence_create(state, msg, priority);
- full_jid = g_strdup_printf("%s/%s", room_jid, handle);
-@@ -278,7 +278,7 @@ void jabber_chat_join(GaimConnection *gc
- xmlnode_free(presence);
- }
-
--void jabber_chat_leave(GaimConnection *gc, int id)
-+void jabber_chat_leave(Gaim2Connection *gc, int id)
- {
- JabberStream *js = gc->proto_data;
- JabberChat *chat = jabber_chat_find_by_id(js, id);
-@@ -304,7 +304,7 @@ void jabber_chat_destroy(JabberChat *cha
- void jabber_chat_free(JabberChat *chat)
- {
- if(chat->config_dialog_handle)
-- gaim_request_close(chat->config_dialog_type, chat->config_dialog_handle);
-+ gaim2_request_close(chat->config_dialog_type, chat->config_dialog_handle);
-
- g_free(chat->room);
- g_free(chat->server);
-@@ -313,12 +313,12 @@ void jabber_chat_free(JabberChat *chat)
- g_free(chat);
- }
-
--gboolean jabber_chat_find_buddy(GaimConversation *conv, const char *name)
-+gboolean jabber_chat_find_buddy(Gaim2Conversation *conv, const char *name)
- {
-- return gaim_conv_chat_find_user(GAIM_CONV_CHAT(conv), name);
-+ return gaim2_conv_chat_find_user(GAIM_CONV_CHAT(conv), name);
- }
-
--char *jabber_chat_buddy_real_name(GaimConnection *gc, int id, const char *who)
-+char *jabber_chat_buddy_real_name(Gaim2Connection *gc, int id, const char *who)
- {
- JabberStream *js = gc->proto_data;
- JabberChat *chat;
-@@ -392,7 +392,7 @@ static void jabber_chat_room_configure_c
- } else if(!strcmp(type, "error")) {
- char *msg = jabber_parse_error(js, packet);
-
-- gaim_notify_error(js->gc, _("Configuration error"), _("Configuration error"), msg);
-+ gaim2_notify_error(js->gc, _("Configuration error"), _("Configuration error"), msg);
-
- if(msg)
- g_free(msg);
-@@ -401,7 +401,7 @@ static void jabber_chat_room_configure_c
-
- msg = g_strdup_printf("Unable to configure room %s", from);
-
-- gaim_notify_info(js->gc, _("Unable to configure"), _("Unable to configure"), msg);
-+ gaim2_notify_info(js->gc, _("Unable to configure"), _("Unable to configure"), msg);
- g_free(msg);
-
- }
-@@ -417,7 +417,7 @@ void jabber_chat_request_room_configure(
- chat->config_dialog_handle = NULL;
-
- if(!chat->muc) {
-- gaim_notify_error(chat->js->gc, _("Room Configuration Error"), _("Room Configuration Error"),
-+ gaim2_notify_error(chat->js->gc, _("Room Configuration Error"), _("Room Configuration Error"),
- _("This room is not capable of being configured"));
- return;
- }
-@@ -468,7 +468,7 @@ static void jabber_chat_register_x_data_
- if(type && !strcmp(type, "error")) {
- char *msg = jabber_parse_error(js, packet);
-
-- gaim_notify_error(js->gc, _("Registration error"), _("Registration error"), msg);
-+ gaim2_notify_error(js->gc, _("Registration error"), _("Registration error"), msg);
-
- if(msg)
- g_free(msg);
-@@ -537,7 +537,7 @@ static void jabber_chat_register_cb(Jabb
- } else if(!strcmp(type, "error")) {
- char *msg = jabber_parse_error(js, packet);
-
-- gaim_notify_error(js->gc, _("Registration error"), _("Registration error"), msg);
-+ gaim2_notify_error(js->gc, _("Registration error"), _("Registration error"), msg);
-
- if(msg)
- g_free(msg);
-@@ -546,7 +546,7 @@ static void jabber_chat_register_cb(Jabb
-
- msg = g_strdup_printf("Unable to configure room %s", from);
-
-- gaim_notify_info(js->gc, _("Unable to configure"), _("Unable to configure"), msg);
-+ gaim2_notify_info(js->gc, _("Unable to configure"), _("Unable to configure"), msg);
- g_free(msg);
-
- }
-@@ -578,30 +578,30 @@ void jabber_chat_change_topic(JabberChat
- jm = g_new0(JabberMessage, 1);
- jm->js = chat->js;
- jm->type = JABBER_MESSAGE_GROUPCHAT;
-- jm->subject = gaim_markup_strip_html(topic);
-+ jm->subject = gaim2_markup_strip_html(topic);
- jm->to = g_strdup_printf("%s@%s", chat->room, chat->server);
- jabber_message_send(jm);
- jabber_message_free(jm);
- } else {
-- const char *cur = gaim_conv_chat_get_topic(GAIM_CONV_CHAT(chat->conv));
-+ const char *cur = gaim2_conv_chat_get_topic(GAIM_CONV_CHAT(chat->conv));
- char *buf, *tmp, *tmp2;
-
- if(cur) {
- tmp = g_markup_escape_text(cur, -1);
-- tmp2 = gaim_markup_linkify(tmp);
-+ tmp2 = gaim2_markup_linkify(tmp);
- buf = g_strdup_printf(_("current topic is: %s"), tmp2);
- g_free(tmp);
- g_free(tmp2);
- } else
- buf = g_strdup(_("No topic is set"));
-- gaim_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "", buf,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "", buf,
- GAIM_MESSAGE_SYSTEM | GAIM_MESSAGE_NO_LOG, time(NULL));
- g_free(buf);
- }
-
- }
-
--void jabber_chat_set_topic(GaimConnection *gc, int id, const char *topic)
-+void jabber_chat_set_topic(Gaim2Connection *gc, int id, const char *topic)
- {
- JabberStream *js = gc->proto_data;
- JabberChat *chat = jabber_chat_find_by_id(js, id);
-@@ -617,23 +617,23 @@ void jabber_chat_change_nick(JabberChat
- {
- xmlnode *presence;
- char *full_jid;
-- GaimPresence *gpresence;
-- GaimStatus *status;
-+ Gaim2Presence *gpresence;
-+ Gaim2Status *status;
- JabberBuddyState state;
- const char *msg;
- int priority;
-
- if(!chat->muc) {
-- gaim_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "",
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "",
- _("Nick changing not supported in non-MUC chatrooms"),
- GAIM_MESSAGE_SYSTEM, time(NULL));
- return;
- }
-
-- gpresence = gaim_account_get_presence(chat->js->gc->account);
-- status = gaim_presence_get_active_status(gpresence);
-+ gpresence = gaim2_account_get_presence(chat->js->gc->account);
-+ status = gaim2_presence_get_active_status(gpresence);
-
-- gaim_status_to_jabber(status, &state, &msg, &priority);
-+ gaim2_status_to_jabber(status, &state, &msg, &priority);
-
- presence = jabber_presence_create(state, msg, priority);
- full_jid = g_strdup_printf("%s@%s/%s", chat->room, chat->server, nick);
-@@ -674,10 +674,10 @@ static void roomlist_disco_result_cb(Jab
-
- if(!(type = xmlnode_get_attrib(packet, "type")) || strcmp(type, "result")) {
- char *err = jabber_parse_error(js,packet);
-- gaim_notify_error(js->gc, _("Error"),
-+ gaim2_notify_error(js->gc, _("Error"),
- _("Error retrieving room list"), err);
-- gaim_roomlist_set_in_progress(js->roomlist, FALSE);
-- gaim_roomlist_unref(js->roomlist);
-+ gaim2_roomlist_set_in_progress(js->roomlist, FALSE);
-+ gaim2_roomlist_unref(js->roomlist);
- js->roomlist = NULL;
- g_free(err);
- return;
-@@ -685,10 +685,10 @@ static void roomlist_disco_result_cb(Jab
-
- if(!(query = xmlnode_get_child(packet, "query"))) {
- char *err = jabber_parse_error(js, packet);
-- gaim_notify_error(js->gc, _("Error"),
-+ gaim2_notify_error(js->gc, _("Error"),
- _("Error retrieving room list"), err);
-- gaim_roomlist_set_in_progress(js->roomlist, FALSE);
-- gaim_roomlist_unref(js->roomlist);
-+ gaim2_roomlist_set_in_progress(js->roomlist, FALSE);
-+ gaim2_roomlist_unref(js->roomlist);
- js->roomlist = NULL;
- g_free(err);
- return;
-@@ -697,7 +697,7 @@ static void roomlist_disco_result_cb(Jab
- for(item = xmlnode_get_child(query, "item"); item;
- item = xmlnode_get_next_twin(item)) {
- const char *name;
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
- JabberID *jid;
-
- if(!(jid = jabber_id_new(xmlnode_get_attrib(item, "jid"))))
-@@ -705,23 +705,23 @@ static void roomlist_disco_result_cb(Jab
- name = xmlnode_get_attrib(item, "name");
-
-
-- room = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, jid->node, NULL);
-- gaim_roomlist_room_add_field(js->roomlist, room, jid->node);
-- gaim_roomlist_room_add_field(js->roomlist, room, jid->domain);
-- gaim_roomlist_room_add_field(js->roomlist, room, name ? name : "");
-- gaim_roomlist_room_add(js->roomlist, room);
-+ room = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, jid->node, NULL);
-+ gaim2_roomlist_room_add_field(js->roomlist, room, jid->node);
-+ gaim2_roomlist_room_add_field(js->roomlist, room, jid->domain);
-+ gaim2_roomlist_room_add_field(js->roomlist, room, name ? name : "");
-+ gaim2_roomlist_room_add(js->roomlist, room);
-
- jabber_id_free(jid);
- }
-- gaim_roomlist_set_in_progress(js->roomlist, FALSE);
-- gaim_roomlist_unref(js->roomlist);
-+ gaim2_roomlist_set_in_progress(js->roomlist, FALSE);
-+ gaim2_roomlist_unref(js->roomlist);
- js->roomlist = NULL;
- }
-
- static void roomlist_cancel_cb(JabberStream *js, const char *server) {
- if(js->roomlist) {
-- gaim_roomlist_set_in_progress(js->roomlist, FALSE);
-- gaim_roomlist_unref(js->roomlist);
-+ gaim2_roomlist_set_in_progress(js->roomlist, FALSE);
-+ gaim2_roomlist_unref(js->roomlist);
- js->roomlist = NULL;
- }
- }
-@@ -734,11 +734,11 @@ static void roomlist_ok_cb(JabberStream
- return;
-
- if(!server || !*server) {
-- gaim_notify_error(js->gc, _("Invalid Server"), _("Invalid Server"), NULL);
-+ gaim2_notify_error(js->gc, _("Invalid Server"), _("Invalid Server"), NULL);
- return;
- }
-
-- gaim_roomlist_set_in_progress(js->roomlist, TRUE);
-+ gaim2_roomlist_set_in_progress(js->roomlist, TRUE);
-
- iq = jabber_iq_new_query(js, JABBER_IQ_GET, "http://jabber.org/protocol/disco#items");
-
-@@ -749,30 +749,30 @@ static void roomlist_ok_cb(JabberStream
- jabber_iq_send(iq);
- }
-
--GaimRoomlist *jabber_roomlist_get_list(GaimConnection *gc)
-+Gaim2Roomlist *jabber_roomlist_get_list(Gaim2Connection *gc)
- {
- JabberStream *js = gc->proto_data;
- GList *fields = NULL;
-- GaimRoomlistField *f;
-+ Gaim2RoomlistField *f;
-
- if(js->roomlist)
-- gaim_roomlist_unref(js->roomlist);
-+ gaim2_roomlist_unref(js->roomlist);
-
-- js->roomlist = gaim_roomlist_new(gaim_connection_get_account(js->gc));
-+ js->roomlist = gaim2_roomlist_new(gaim2_connection_get_account(js->gc));
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "room", TRUE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "room", TRUE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "server", TRUE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "server", TRUE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, _("Description"), "description", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, _("Description"), "description", FALSE);
- fields = g_list_append(fields, f);
-
-- gaim_roomlist_set_fields(js->roomlist, fields);
-+ gaim2_roomlist_set_fields(js->roomlist, fields);
-
-
-- gaim_request_input(gc, _("Enter a Conference Server"), _("Enter a Conference Server"),
-+ gaim2_request_input(gc, _("Enter a Conference Server"), _("Enter a Conference Server"),
- _("Select a conference server to query"),
- js->chat_servers ? js->chat_servers->data : "conference.jabber.org",
- FALSE, FALSE, NULL,
-@@ -782,19 +782,19 @@ GaimRoomlist *jabber_roomlist_get_list(G
- return js->roomlist;
- }
-
--void jabber_roomlist_cancel(GaimRoomlist *list)
-+void jabber_roomlist_cancel(Gaim2Roomlist *list)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- JabberStream *js;
-
-- gc = gaim_account_get_connection(list->account);
-+ gc = gaim2_account_get_connection(list->account);
- js = gc->proto_data;
-
-- gaim_roomlist_set_in_progress(list, FALSE);
-+ gaim2_roomlist_set_in_progress(list, FALSE);
-
- if (js->roomlist == list) {
- js->roomlist = NULL;
-- gaim_roomlist_unref(list);
-+ gaim2_roomlist_unref(list);
- }
- }
-
-diff -prNu ./src/protocols/jabber/chat.h ./src/protocols/jabber/chat.h
---- ./src/protocols/jabber/chat.h 2005-08-31 21:08:33.000000000 +0200
-+++ ./src/protocols/jabber/chat.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file chat.h Chat stuff
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -42,34 +42,34 @@ typedef struct _JabberChat {
- char *server;
- char *handle;
- int id;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- gboolean muc;
- gboolean xhtml;
-- GaimRequestType config_dialog_type;
-+ Gaim2RequestType config_dialog_type;
- void *config_dialog_handle;
- GHashTable *members;
- } JabberChat;
-
--GList *jabber_chat_info(GaimConnection *gc);
--GHashTable *jabber_chat_info_defaults(GaimConnection *gc, const char *chat_name);
-+GList *jabber_chat_info(Gaim2Connection *gc);
-+GHashTable *jabber_chat_info_defaults(Gaim2Connection *gc, const char *chat_name);
- char *jabber_get_chat_name(GHashTable *data);
--void jabber_chat_join(GaimConnection *gc, GHashTable *data);
-+void jabber_chat_join(Gaim2Connection *gc, GHashTable *data);
- JabberChat *jabber_chat_find(JabberStream *js, const char *room,
- const char *server);
- JabberChat *jabber_chat_find_by_id(JabberStream *js, int id);
--JabberChat *jabber_chat_find_by_conv(GaimConversation *conv);
-+JabberChat *jabber_chat_find_by_conv(Gaim2Conversation *conv);
- void jabber_chat_destroy(JabberChat *chat);
- void jabber_chat_free(JabberChat *chat);
--gboolean jabber_chat_find_buddy(GaimConversation *conv, const char *name);
--void jabber_chat_invite(GaimConnection *gc, int id, const char *message,
-+gboolean jabber_chat_find_buddy(Gaim2Conversation *conv, const char *name);
-+void jabber_chat_invite(Gaim2Connection *gc, int id, const char *message,
- const char *name);
--void jabber_chat_leave(GaimConnection *gc, int id);
--char *jabber_chat_buddy_real_name(GaimConnection *gc, int id, const char *who);
-+void jabber_chat_leave(Gaim2Connection *gc, int id);
-+char *jabber_chat_buddy_real_name(Gaim2Connection *gc, int id, const char *who);
- void jabber_chat_request_room_configure(JabberChat *chat);
- void jabber_chat_create_instant_room(JabberChat *chat);
- void jabber_chat_register(JabberChat *chat);
- void jabber_chat_change_topic(JabberChat *chat, const char *topic);
--void jabber_chat_set_topic(GaimConnection *gc, int id, const char *topic);
-+void jabber_chat_set_topic(Gaim2Connection *gc, int id, const char *topic);
- void jabber_chat_change_nick(JabberChat *chat, const char *nick);
- void jabber_chat_part(JabberChat *chat, const char *msg);
- void jabber_chat_track_handle(JabberChat *chat, const char *handle,
-@@ -82,8 +82,8 @@ gboolean jabber_chat_affiliate_user(Jabb
- gboolean jabber_chat_kick_user(JabberChat *chat, const char *who,
- const char *why);
-
--GaimRoomlist *jabber_roomlist_get_list(GaimConnection *gc);
--void jabber_roomlist_cancel(GaimRoomlist *list);
-+Gaim2Roomlist *jabber_roomlist_get_list(Gaim2Connection *gc);
-+void jabber_roomlist_cancel(Gaim2Roomlist *list);
-
- void jabber_chat_disco_traffic(JabberChat *chat);
-
-diff -prNu ./src/protocols/jabber/disco.c ./src/protocols/jabber/disco.c
---- ./src/protocols/jabber/disco.c 2005-10-17 03:43:09.000000000 +0200
-+++ ./src/protocols/jabber/disco.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/jabber/disco.h ./src/protocols/jabber/disco.h
---- ./src/protocols/jabber/disco.h 2004-02-22 00:59:48.000000000 +0100
-+++ ./src/protocols/jabber/disco.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file iq.h JabberID handlers
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/jabber/iq.c ./src/protocols/jabber/iq.c
---- ./src/protocols/jabber/iq.c 2005-12-01 20:55:35.000000000 +0100
-+++ ./src/protocols/jabber/iq.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -192,13 +192,13 @@ static void jabber_iq_time_parse(JabberS
- xmlnode_insert_data(xmlnode_new_child(query, "utc"), buf, -1);
-
- strftime(buf, sizeof(buf), "%Z", now);
-- if((utf8 = gaim_utf8_try_convert(buf))) {
-+ if((utf8 = gaim2_utf8_try_convert(buf))) {
- xmlnode_insert_data(xmlnode_new_child(query, "tz"), utf8, -1);
- g_free(utf8);
- }
-
- strftime(buf, sizeof(buf), "%d %b %Y %T", now);
-- if((utf8 = gaim_utf8_try_convert(buf))) {
-+ if((utf8 = gaim2_utf8_try_convert(buf))) {
- xmlnode_insert_data(xmlnode_new_child(query, "display"), utf8, -1);
- g_free(utf8);
- }
-@@ -218,7 +218,7 @@ static void jabber_iq_version_parse(Jabb
-
- if(type && !strcmp(type, "get")) {
-
-- if(!gaim_prefs_get_bool("/plugins/prpl/jabber/hide_os")) {
-+ if(!gaim2_prefs_get_bool("/plugins/prpl/jabber/hide_os")) {
- struct utsname osinfo;
-
- uname(&osinfo);
-diff -prNu ./src/protocols/jabber/iq.h ./src/protocols/jabber/iq.h
---- ./src/protocols/jabber/iq.h 2003-10-31 03:43:58.000000000 +0100
-+++ ./src/protocols/jabber/iq.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file iq.h JabberID handlers
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/jabber/jabber.c ./src/protocols/jabber/jabber.c
---- ./src/protocols/jabber/jabber.c 2006-01-03 01:23:24.000000000 +0100
-+++ ./src/protocols/jabber/jabber.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -52,7 +52,7 @@
-
- #define JABBER_CONNECT_STEPS (js->gsc ? 8 : 5)
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
- static void jabber_stream_init(JabberStream *js)
- {
-@@ -76,7 +76,7 @@ jabber_session_initialized_cb(JabberStre
- if(type && !strcmp(type, "result")) {
- jabber_stream_set_state(js, JABBER_STREAM_CONNECTED);
- } else {
-- gaim_connection_error(js->gc, _("Error initializing session"));
-+ gaim2_connection_error(js->gc, _("Error initializing session"));
- }
- }
-
-@@ -107,7 +107,7 @@ static void jabber_bind_result_cb(Jabber
- JabberBuddy *my_jb = NULL;
- jabber_id_free(js->user);
- if(!(js->user = jabber_id_new(full_jid))) {
-- gaim_connection_error(js->gc, _("Invalid response from server."));
-+ gaim2_connection_error(js->gc, _("Invalid response from server."));
- }
- if((my_jb = jabber_buddy_find(js, full_jid, TRUE)))
- my_jb->subscription |= JABBER_SUB_BOTH;
-@@ -115,7 +115,7 @@ static void jabber_bind_result_cb(Jabber
- }
- } else {
- char *msg = jabber_parse_error(js, packet);
-- gaim_connection_error(js->gc, msg);
-+ gaim2_connection_error(js->gc, msg);
- g_free(msg);
- }
-
-@@ -158,7 +158,7 @@ static void jabber_stream_handle_error(J
- {
- char *msg = jabber_parse_error(js, packet);
-
-- gaim_connection_error(js->gc, msg);
-+ gaim2_connection_error(js->gc, msg);
- g_free(msg);
- }
-
-@@ -189,7 +189,7 @@ void jabber_process_packet(JabberStream
- if(js->state == JABBER_STREAM_AUTHENTICATING && !js->gsc)
- tls_init(js);
- } else {
-- gaim_debug(GAIM_DEBUG_WARNING, "jabber", "Unknown packet: %s\n",
-+ gaim2_debug(GAIM_DEBUG_WARNING, "jabber", "Unknown packet: %s\n",
- packet->name);
- }
- }
-@@ -200,7 +200,7 @@ void jabber_send_raw(JabberStream *js, c
-
- /* because printing a tab to debug every minute gets old */
- if(strcmp(data, "\t"))
-- gaim_debug(GAIM_DEBUG_MISC, "jabber", "Sending%s: %s\n",
-+ gaim2_debug(GAIM_DEBUG_MISC, "jabber", "Sending%s: %s\n",
- js->gsc ? " (ssl)" : "", data);
-
- /* If we've got a security layer, we need to encode the data,
-@@ -229,18 +229,18 @@ void jabber_send_raw(JabberStream *js, c
- pos += towrite;
-
- if (js->gsc)
-- ret = gaim_ssl_write(js->gsc, out, olen);
-+ ret = gaim2_ssl_write(js->gsc, out, olen);
- else
- ret = write(js->fd, out, olen);
- if (ret < 0)
-- gaim_connection_error(js->gc, _("Write error"));
-+ gaim2_connection_error(js->gc, _("Write error"));
- }
- return;
- }
- #endif
-
- if(js->gsc) {
-- ret = gaim_ssl_write(js->gsc, data, len == -1 ? strlen(data) : len);
-+ ret = gaim2_ssl_write(js->gsc, data, len == -1 ? strlen(data) : len);
- } else {
- if(js->fd < 0)
- return;
-@@ -248,7 +248,7 @@ void jabber_send_raw(JabberStream *js, c
- }
-
- if(ret < 0)
-- gaim_connection_error(js->gc, _("Write error"));
-+ gaim2_connection_error(js->gc, _("Write error"));
-
- }
-
-@@ -262,43 +262,43 @@ void jabber_send(JabberStream *js, xmlno
- g_free(txt);
- }
-
--static void jabber_keepalive(GaimConnection *gc)
-+static void jabber_keepalive(Gaim2Connection *gc)
- {
- jabber_send_raw(gc->proto_data, "\t", -1);
- }
-
- static void
--jabber_recv_cb_ssl(gpointer data, GaimSslConnection *gsc,
-- GaimInputCondition cond)
-+jabber_recv_cb_ssl(gpointer data, Gaim2SslConnection *gsc,
-+ Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- JabberStream *js = gc->proto_data;
- int len;
- static char buf[4096];
-
-- if(!g_list_find(gaim_connections_get_all(), gc)) {
-- gaim_ssl_close(gsc);
-+ if(!g_list_find(gaim2_connections_get_all(), gc)) {
-+ gaim2_ssl_close(gsc);
- return;
- }
-
-- if((len = gaim_ssl_read(gsc, buf, sizeof(buf) - 1)) > 0) {
-+ if((len = gaim2_ssl_read(gsc, buf, sizeof(buf) - 1)) > 0) {
- buf[len] = '\0';
-- gaim_debug(GAIM_DEBUG_INFO, "jabber", "Recv (ssl)(%d): %s\n", len, buf);
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber", "Recv (ssl)(%d): %s\n", len, buf);
- jabber_parser_process(js, buf, len);
- } else {
-- gaim_connection_error(gc, _("Read Error"));
-+ gaim2_connection_error(gc, _("Read Error"));
- }
- }
-
- static void
--jabber_recv_cb(gpointer data, gint source, GaimInputCondition condition)
-+jabber_recv_cb(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- JabberStream *js = gc->proto_data;
- int len;
- static char buf[4096];
-
-- if(!g_list_find(gaim_connections_get_all(), gc))
-+ if(!g_list_find(gaim2_connections_get_all(), gc))
- return;
-
- if((len = read(js->fd, buf, sizeof(buf) - 1)) > 0) {
-@@ -308,29 +308,29 @@ jabber_recv_cb(gpointer data, gint sourc
- int olen;
- sasl_decode(js->sasl, buf, len, &out, &olen);
- if (olen>0) {
-- gaim_debug(GAIM_DEBUG_INFO, "jabber", "RecvSASL (%d): %s\n", olen, out);
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber", "RecvSASL (%d): %s\n", olen, out);
- jabber_parser_process(js,out,olen);
- }
- return;
- }
- #endif
- buf[len] = '\0';
-- gaim_debug(GAIM_DEBUG_INFO, "jabber", "Recv (%d): %s\n", len, buf);
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber", "Recv (%d): %s\n", len, buf);
- jabber_parser_process(js, buf, len);
- } else {
-- gaim_connection_error(gc, _("Read Error"));
-+ gaim2_connection_error(gc, _("Read Error"));
- }
- }
-
- static void
--jabber_login_callback_ssl(gpointer data, GaimSslConnection *gsc,
-- GaimInputCondition cond)
-+jabber_login_callback_ssl(gpointer data, Gaim2SslConnection *gsc,
-+ Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- JabberStream *js = gc->proto_data;
-
-- if(!g_list_find(gaim_connections_get_all(), gc)) {
-- gaim_ssl_close(gsc);
-+ if(!g_list_find(gaim2_connections_get_all(), gc)) {
-+ gaim2_ssl_close(gsc);
- return;
- }
-
-@@ -340,22 +340,22 @@ jabber_login_callback_ssl(gpointer data,
- jabber_send_raw(js, "<?xml version='1.0' ?>", -1);
-
- jabber_stream_set_state(js, JABBER_STREAM_INITIALIZING);
-- gaim_ssl_input_add(gsc, jabber_recv_cb_ssl, gc);
-+ gaim2_ssl_input_add(gsc, jabber_recv_cb_ssl, gc);
- }
-
-
- static void
--jabber_login_callback(gpointer data, gint source, GaimInputCondition cond)
-+jabber_login_callback(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- JabberStream *js = gc->proto_data;
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Couldn't connect to host"));
-+ gaim2_connection_error(gc, _("Couldn't connect to host"));
- return;
- }
-
-- if(!g_list_find(gaim_connections_get_all(), gc)) {
-+ if(!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -366,22 +366,22 @@ jabber_login_callback(gpointer data, gin
- jabber_send_raw(js, "<?xml version='1.0' ?>", -1);
-
- jabber_stream_set_state(js, JABBER_STREAM_INITIALIZING);
-- gc->inpa = gaim_input_add(js->fd, GAIM_INPUT_READ, jabber_recv_cb, gc);
-+ gc->inpa = gaim2_input_add(js->fd, GAIM_INPUT_READ, jabber_recv_cb, gc);
- }
-
- static void
--jabber_ssl_connect_failure(GaimSslConnection *gsc, GaimSslErrorType error,
-+jabber_ssl_connect_failure(Gaim2SslConnection *gsc, Gaim2SslErrorType error,
- gpointer data)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- JabberStream *js = gc->proto_data;
-
- switch(error) {
- case GAIM_SSL_CONNECT_FAILED:
-- gaim_connection_error(gc, _("Connection Failed"));
-+ gaim2_connection_error(gc, _("Connection Failed"));
- break;
- case GAIM_SSL_HANDSHAKE_FAILED:
-- gaim_connection_error(gc, _("SSL Handshake Failed"));
-+ gaim2_connection_error(gc, _("SSL Handshake Failed"));
- break;
- }
-
-@@ -390,9 +390,9 @@ jabber_ssl_connect_failure(GaimSslConnec
-
- static void tls_init(JabberStream *js)
- {
-- gaim_input_remove(js->gc->inpa);
-+ gaim2_input_remove(js->gc->inpa);
- js->gc->inpa = 0;
-- js->gsc = gaim_ssl_connect_fd(js->gc->account, js->fd,
-+ js->gsc = gaim2_ssl_connect_fd(js->gc->account, js->fd,
- jabber_login_callback_ssl, jabber_ssl_connect_failure, js->gc);
- }
-
-@@ -400,17 +400,17 @@ static void jabber_login_connect(JabberS
- {
- int rc;
-
-- rc = gaim_proxy_connect(js->gc->account, server,
-+ rc = gaim2_proxy_connect(js->gc->account, server,
- port, jabber_login_callback, js->gc);
-
- if (rc != 0)
-- gaim_connection_error(js->gc, _("Unable to create socket"));
-+ gaim2_connection_error(js->gc, _("Unable to create socket"));
- }
-
--static void srv_resolved_cb(GaimSrvResponse *resp, int results, gpointer data)
-+static void srv_resolved_cb(Gaim2SrvResponse *resp, int results, gpointer data)
- {
- JabberStream *js = (JabberStream*)data;
-- int config_port = gaim_account_get_int(js->gc->account, "port", 0);
-+ int config_port = gaim2_account_get_int(js->gc->account, "port", 0);
-
- if(results) {
- jabber_login_connect(js, resp->hostname, config_port ? config_port : resp->port);
-@@ -423,10 +423,10 @@ static void srv_resolved_cb(GaimSrvRespo
-
-
- static void
--jabber_login(GaimAccount *account)
-+jabber_login(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-- const char *connect_server = gaim_account_get_string(account,
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ const char *connect_server = gaim2_account_get_string(account,
- "connect_server", "");
- JabberStream *js;
- JabberBuddy *my_jb = NULL;
-@@ -444,11 +444,11 @@ jabber_login(GaimAccount *account)
- js->chats = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, (GDestroyNotify)jabber_chat_free);
- js->chat_servers = g_list_append(NULL, g_strdup("conference.jabber.org"));
-- js->user = jabber_id_new(gaim_account_get_username(account));
-+ js->user = jabber_id_new(gaim2_account_get_username(account));
- js->next_id = g_random_int();
-
- if(!js->user) {
-- gaim_connection_error(gc, _("Invalid Jabber ID"));
-+ gaim2_connection_error(gc, _("Invalid Jabber ID"));
- return;
- }
-
-@@ -461,24 +461,24 @@ jabber_login(GaimAccount *account)
- }
- me = g_strdup_printf("%s@%s/%s", js->user->node, js->user->domain,
- js->user->resource);
-- gaim_account_set_username(account, me);
-+ gaim2_account_set_username(account, me);
- g_free(me);
- }
-
-- if((my_jb = jabber_buddy_find(js, gaim_account_get_username(account), TRUE)))
-+ if((my_jb = jabber_buddy_find(js, gaim2_account_get_username(account), TRUE)))
- my_jb->subscription |= JABBER_SUB_BOTH;
-
- jabber_stream_set_state(js, JABBER_STREAM_CONNECTING);
-
- /* if they've got old-ssl mode going, we probably want to ignore SRV lookups */
-- if(gaim_account_get_bool(js->gc->account, "old_ssl", FALSE)) {
-- if(gaim_ssl_is_supported()) {
-- js->gsc = gaim_ssl_connect(js->gc->account,
-+ if(gaim2_account_get_bool(js->gc->account, "old_ssl", FALSE)) {
-+ if(gaim2_ssl_is_supported()) {
-+ js->gsc = gaim2_ssl_connect(js->gc->account,
- connect_server[0] ? connect_server : js->user->domain,
-- gaim_account_get_int(account, "port", 5223), jabber_login_callback_ssl,
-+ gaim2_account_get_int(account, "port", 5223), jabber_login_callback_ssl,
- jabber_ssl_connect_failure, js->gc);
- } else {
-- gaim_connection_error(js->gc, _("SSL support unavailable"));
-+ gaim2_connection_error(js->gc, _("SSL support unavailable"));
- }
- }
-
-@@ -486,9 +486,9 @@ jabber_login(GaimAccount *account)
- * invoke the magic of SRV lookups, to figure out host and port */
- if(!js->gsc) {
- if(connect_server[0]) {
-- jabber_login_connect(js, connect_server, gaim_account_get_int(account, "port", 5222));
-+ jabber_login_connect(js, connect_server, gaim2_account_get_int(account, "port", 5222));
- } else {
-- gaim_srv_resolve("xmpp-client", "tcp", js->user->domain, srv_resolved_cb, js);
-+ gaim2_srv_resolve("xmpp-client", "tcp", js->user->domain, srv_resolved_cb, js);
- }
- }
- }
-@@ -498,9 +498,9 @@ static gboolean
- conn_close_cb(gpointer data)
- {
- JabberStream *js = data;
-- GaimAccount *account = gaim_connection_get_account(js->gc);
-+ Gaim2Account *account = gaim2_connection_get_account(js->gc);
-
-- gaim_account_disconnect(account);
-+ gaim2_account_disconnect(account);
-
- return FALSE;
- }
-@@ -508,7 +508,7 @@ conn_close_cb(gpointer data)
- static void
- jabber_connection_schedule_close(JabberStream *js)
- {
-- gaim_timeout_add(0, conn_close_cb, js);
-+ gaim2_timeout_add(0, conn_close_cb, js);
- }
-
- static void
-@@ -520,7 +520,7 @@ jabber_registration_result_cb(JabberStre
- if(!strcmp(type, "result")) {
- buf = g_strdup_printf(_("Registration of %s@%s successful"),
- js->user->node, js->user->domain);
-- gaim_notify_info(NULL, _("Registration Successful"),
-+ gaim2_notify_info(NULL, _("Registration Successful"),
- _("Registration Successful"), buf);
- g_free(buf);
- } else {
-@@ -529,7 +529,7 @@ jabber_registration_result_cb(JabberStre
- if(!msg)
- msg = g_strdup(_("Unknown Error"));
-
-- gaim_notify_error(NULL, _("Registration Failed"),
-+ gaim2_notify_error(NULL, _("Registration Failed"),
- _("Registration Failed"), msg);
- g_free(msg);
- }
-@@ -537,7 +537,7 @@ jabber_registration_result_cb(JabberStre
- }
-
- static void
--jabber_register_cb(JabberStream *js, GaimRequestFields *fields)
-+jabber_register_cb(JabberStream *js, Gaim2RequestFields *fields)
- {
- GList *groups, *flds;
- xmlnode *query, *y;
-@@ -547,13 +547,13 @@ jabber_register_cb(JabberStream *js, Gai
- iq = jabber_iq_new_query(js, JABBER_IQ_SET, "jabber:iq:register");
- query = xmlnode_get_child(iq->node, "query");
-
-- for(groups = gaim_request_fields_get_groups(fields); groups;
-+ for(groups = gaim2_request_fields_get_groups(fields); groups;
- groups = groups->next) {
-- for(flds = gaim_request_field_group_get_fields(groups->data);
-+ for(flds = gaim2_request_field_group_get_fields(groups->data);
- flds; flds = flds->next) {
-- GaimRequestField *field = flds->data;
-- const char *id = gaim_request_field_get_id(field);
-- const char *value = gaim_request_field_string_get_value(field);
-+ Gaim2RequestField *field = flds->data;
-+ const char *id = gaim2_request_field_get_id(field);
-+ const char *value = gaim2_request_field_string_get_value(field);
-
- if(!strcmp(id, "username")) {
- y = xmlnode_new_child(query, "username");
-@@ -597,7 +597,7 @@ jabber_register_cb(JabberStream *js, Gai
-
- username = g_strdup_printf("%s@%s/%s", js->user->node, js->user->domain,
- js->user->resource);
-- gaim_account_set_username(js->gc->account, username);
-+ gaim2_account_set_username(js->gc->account, username);
- g_free(username);
-
- jabber_iq_set_callback(iq, jabber_registration_result_cb, NULL);
-@@ -607,7 +607,7 @@ jabber_register_cb(JabberStream *js, Gai
- }
-
- static void
--jabber_register_cancel_cb(JabberStream *js, GaimRequestFields *fields)
-+jabber_register_cancel_cb(JabberStream *js, Gaim2RequestFields *fields)
- {
- jabber_connection_schedule_close(js);
- }
-@@ -629,19 +629,19 @@ static void jabber_register_x_data_cb(Ja
- void jabber_register_parse(JabberStream *js, xmlnode *packet)
- {
- if(js->registration) {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
- xmlnode *query, *x, *y;
- char *instructions;
-
- /* get rid of the login thingy */
-- gaim_connection_set_state(js->gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(js->gc, GAIM_CONNECTED);
-
- query = xmlnode_get_child(packet, "query");
-
- if(xmlnode_get_child(query, "registered")) {
-- gaim_notify_error(NULL, _("Already Registered"),
-+ gaim2_notify_error(NULL, _("Already Registered"),
- _("Already Registered"), NULL);
- jabber_connection_schedule_close(js);
- return;
-@@ -658,7 +658,7 @@ void jabber_register_parse(JabberStream
- if((url = xmlnode_get_child(x, "url"))) {
- char *href;
- if((href = xmlnode_get_data(url))) {
-- gaim_notify_uri(NULL, href);
-+ gaim2_notify_uri(NULL, href);
- g_free(href);
- js->gc->wants_to_die = TRUE;
- jabber_connection_schedule_close(js);
-@@ -669,78 +669,78 @@ void jabber_register_parse(JabberStream
-
- /* as a last resort, use the old jabber:iq:register syntax */
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("username", _("Username"),
-+ field = gaim2_request_field_string_new("username", _("Username"),
- js->user->node, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("password", _("Password"),
-- gaim_connection_get_password(js->gc), FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_string_new("password", _("Password"),
-+ gaim2_connection_get_password(js->gc), FALSE);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
- if(xmlnode_get_child(query, "name")) {
-- field = gaim_request_field_string_new("name", _("Name"),
-- gaim_account_get_alias(js->gc->account), FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_string_new("name", _("Name"),
-+ gaim2_account_get_alias(js->gc->account), FALSE);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "email")) {
-- field = gaim_request_field_string_new("email", _("E-Mail"),
-+ field = gaim2_request_field_string_new("email", _("E-Mail"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "nick")) {
-- field = gaim_request_field_string_new("nick", _("Nickname"),
-+ field = gaim2_request_field_string_new("nick", _("Nickname"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "first")) {
-- field = gaim_request_field_string_new("first", _("First Name"),
-+ field = gaim2_request_field_string_new("first", _("First Name"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "last")) {
-- field = gaim_request_field_string_new("last", _("Last Name"),
-+ field = gaim2_request_field_string_new("last", _("Last Name"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "address")) {
-- field = gaim_request_field_string_new("address", _("Address"),
-+ field = gaim2_request_field_string_new("address", _("Address"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "city")) {
-- field = gaim_request_field_string_new("city", _("City"),
-+ field = gaim2_request_field_string_new("city", _("City"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "state")) {
-- field = gaim_request_field_string_new("state", _("State"),
-+ field = gaim2_request_field_string_new("state", _("State"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "zip")) {
-- field = gaim_request_field_string_new("zip", _("Postal Code"),
-+ field = gaim2_request_field_string_new("zip", _("Postal Code"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "phone")) {
-- field = gaim_request_field_string_new("phone", _("Phone"),
-+ field = gaim2_request_field_string_new("phone", _("Phone"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "url")) {
-- field = gaim_request_field_string_new("url", _("URL"),
-+ field = gaim2_request_field_string_new("url", _("URL"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
- if(xmlnode_get_child(query, "date")) {
-- field = gaim_request_field_string_new("date", _("Date"),
-+ field = gaim2_request_field_string_new("date", _("Date"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
- }
-
- if((y = xmlnode_get_child(query, "instructions")))
-@@ -749,7 +749,7 @@ void jabber_register_parse(JabberStream
- instructions = g_strdup(_("Please fill out the information below "
- "to register your new account."));
-
-- gaim_request_fields(js->gc, _("Register New Jabber Account"),
-+ gaim2_request_fields(js->gc, _("Register New Jabber Account"),
- _("Register New Jabber Account"), instructions, fields,
- _("Register"), G_CALLBACK(jabber_register_cb),
- _("Cancel"), G_CALLBACK(jabber_register_cancel_cb), js);
-@@ -764,12 +764,12 @@ void jabber_register_start(JabberStream
- jabber_iq_send(iq);
- }
-
--static void jabber_register_account(GaimAccount *account)
-+static void jabber_register_account(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- JabberStream *js;
- JabberBuddy *my_jb = NULL;
-- const char *connect_server = gaim_account_get_string(account,
-+ const char *connect_server = gaim2_account_get_string(account,
- "connect_server", "");
- const char *server;
- int rc;
-@@ -781,11 +781,11 @@ static void jabber_register_account(Gaim
- g_free, g_free);
- js->disco_callbacks = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, g_free);
-- js->user = jabber_id_new(gaim_account_get_username(account));
-+ js->user = jabber_id_new(gaim2_account_get_username(account));
- js->next_id = g_random_int();
-
- if(!js->user) {
-- gaim_connection_error(gc, _("Invalid Jabber ID"));
-+ gaim2_connection_error(gc, _("Invalid Jabber ID"));
- return;
- }
-
-@@ -798,48 +798,48 @@ static void jabber_register_account(Gaim
- }
- me = g_strdup_printf("%s@%s/%s", js->user->node, js->user->domain,
- js->user->resource);
-- gaim_account_set_username(account, me);
-+ gaim2_account_set_username(account, me);
- g_free(me);
- }
-
-- if((my_jb = jabber_buddy_find(js, gaim_account_get_username(account), TRUE)))
-+ if((my_jb = jabber_buddy_find(js, gaim2_account_get_username(account), TRUE)))
- my_jb->subscription |= JABBER_SUB_BOTH;
-
- server = connect_server[0] ? connect_server : js->user->domain;
-
- jabber_stream_set_state(js, JABBER_STREAM_CONNECTING);
-
-- if(gaim_account_get_bool(account, "old_ssl", FALSE)) {
-- if(gaim_ssl_is_supported()) {
-- js->gsc = gaim_ssl_connect(account, server,
-- gaim_account_get_int(account, "port", 5222),
-+ if(gaim2_account_get_bool(account, "old_ssl", FALSE)) {
-+ if(gaim2_ssl_is_supported()) {
-+ js->gsc = gaim2_ssl_connect(account, server,
-+ gaim2_account_get_int(account, "port", 5222),
- jabber_login_callback_ssl, jabber_ssl_connect_failure, gc);
- } else {
-- gaim_connection_error(gc, _("SSL support unavailable"));
-+ gaim2_connection_error(gc, _("SSL support unavailable"));
- }
- }
-
- if(!js->gsc) {
-- rc = gaim_proxy_connect(account, server,
-- gaim_account_get_int(account, "port", 5222),
-+ rc = gaim2_proxy_connect(account, server,
-+ gaim2_account_get_int(account, "port", 5222),
- jabber_login_callback, gc);
-
- if (rc != 0)
-- gaim_connection_error(gc, _("Unable to create socket"));
-+ gaim2_connection_error(gc, _("Unable to create socket"));
- }
- }
-
--static void jabber_close(GaimConnection *gc)
-+static void jabber_close(Gaim2Connection *gc)
- {
- JabberStream *js = gc->proto_data;
-
- jabber_send_raw(js, "</stream:stream>", -1);
-
- if(js->gsc) {
-- gaim_ssl_close(js->gsc);
-+ gaim2_ssl_close(js->gsc);
- } else if (js->fd > 0) {
- if(js->gc->inpa)
-- gaim_input_remove(js->gc->inpa);
-+ gaim2_input_remove(js->gc->inpa);
- close(js->fd);
- }
-
-@@ -882,25 +882,25 @@ static void jabber_close(GaimConnection
-
- void jabber_stream_set_state(JabberStream *js, JabberStreamState state)
- {
-- GaimPresence *gpresence;
-- GaimStatus *status;
-+ Gaim2Presence *gpresence;
-+ Gaim2Status *status;
-
- js->state = state;
- switch(state) {
- case JABBER_STREAM_OFFLINE:
- break;
- case JABBER_STREAM_CONNECTING:
-- gaim_connection_update_progress(js->gc, _("Connecting"), 1,
-+ gaim2_connection_update_progress(js->gc, _("Connecting"), 1,
- JABBER_CONNECT_STEPS);
- break;
- case JABBER_STREAM_INITIALIZING:
-- gaim_connection_update_progress(js->gc, _("Initializing Stream"),
-+ gaim2_connection_update_progress(js->gc, _("Initializing Stream"),
- js->gsc ? 5 : 2, JABBER_CONNECT_STEPS);
- jabber_stream_init(js);
- jabber_parser_setup(js);
- break;
- case JABBER_STREAM_AUTHENTICATING:
-- gaim_connection_update_progress(js->gc, _("Authenticating"),
-+ gaim2_connection_update_progress(js->gc, _("Authenticating"),
- js->gsc ? 6 : 3, JABBER_CONNECT_STEPS);
- if(js->protocol_version == JABBER_PROTO_0_9 && js->registration) {
- jabber_register_start(js);
-@@ -909,16 +909,16 @@ void jabber_stream_set_state(JabberStrea
- }
- break;
- case JABBER_STREAM_REINITIALIZING:
-- gaim_connection_update_progress(js->gc, _("Re-initializing Stream"),
-+ gaim2_connection_update_progress(js->gc, _("Re-initializing Stream"),
- 6, JABBER_CONNECT_STEPS);
- jabber_stream_init(js);
- break;
- case JABBER_STREAM_CONNECTED:
- jabber_roster_request(js);
-- gpresence = gaim_account_get_presence(js->gc->account);
-- status = gaim_presence_get_active_status(gpresence);
-+ gpresence = gaim2_account_get_presence(js->gc->account);
-+ status = gaim2_presence_get_active_status(gpresence);
- jabber_presence_send(js->gc->account, status);
-- gaim_connection_set_state(js->gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(js->gc, GAIM_CONNECTED);
- jabber_disco_items_server(js);
- break;
- }
-@@ -926,23 +926,23 @@ void jabber_stream_set_state(JabberStrea
-
- char *jabber_get_next_id(JabberStream *js)
- {
-- return g_strdup_printf("gaim%x", js->next_id++);
-+ return g_strdup_printf("gaim2%x", js->next_id++);
- }
-
-
--static void jabber_idle_set(GaimConnection *gc, int idle)
-+static void jabber_idle_set(Gaim2Connection *gc, int idle)
- {
- JabberStream *js = gc->proto_data;
-
- js->idle = idle ? time(NULL) - idle : idle;
- }
-
--static const char *jabber_list_icon(GaimAccount *a, GaimBuddy *b)
-+static const char *jabber_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- return "jabber";
- }
-
--static void jabber_list_emblems(GaimBuddy *b, const char **se, const char **sw,
-+static void jabber_list_emblems(Gaim2Buddy *b, const char **se, const char **sw,
- const char **nw, const char **ne)
- {
- JabberStream *js;
-@@ -963,16 +963,16 @@ static void jabber_list_emblems(GaimBudd
- else
- *se = "offline";
- } else {
-- GaimStatusType *status_type = gaim_status_get_type(gaim_presence_get_active_status(gaim_buddy_get_presence(b)));
-- GaimStatusPrimitive primitive = gaim_status_type_get_primitive(status_type);
-+ Gaim2StatusType *status_type = gaim2_status_get_type(gaim2_presence_get_active_status(gaim2_buddy_get_presence(b)));
-+ Gaim2StatusPrimitive primitive = gaim2_status_type_get_primitive(status_type);
-
- if(primitive > GAIM_STATUS_AVAILABLE) {
-- *se = gaim_status_type_get_id(status_type);
-+ *se = gaim2_status_type_get_id(status_type);
- }
- }
- }
-
--static char *jabber_status_text(GaimBuddy *b)
-+static char *jabber_status_text(Gaim2Buddy *b)
- {
- JabberBuddy *jb = jabber_buddy_find(b->account->gc->proto_data, b->name,
- FALSE);
-@@ -985,11 +985,11 @@ static char *jabber_status_text(GaimBudd
- } else {
- char *stripped;
-
-- if(!(stripped = gaim_markup_strip_html(jabber_buddy_get_status_msg(jb)))) {
-- GaimStatus *status = gaim_presence_get_active_status(gaim_buddy_get_presence(b));
-+ if(!(stripped = gaim2_markup_strip_html(jabber_buddy_get_status_msg(jb)))) {
-+ Gaim2Status *status = gaim2_presence_get_active_status(gaim2_buddy_get_presence(b));
-
-- if(!gaim_status_is_available(status))
-- stripped = g_strdup(gaim_status_get_name(status));
-+ if(!gaim2_status_is_available(status))
-+ stripped = g_strdup(gaim2_status_get_name(status));
- }
-
- if(stripped) {
-@@ -1001,7 +1001,7 @@ static char *jabber_status_text(GaimBudd
- return ret;
- }
-
--static char *jabber_tooltip_text(GaimBuddy *b)
-+static char *jabber_tooltip_text(Gaim2Buddy *b)
- {
- JabberBuddy *jb;
- GString *ret;
-@@ -1045,8 +1045,8 @@ static char *jabber_tooltip_text(GaimBud
-
- if(jbr->status) {
- char *tmp;
-- text = gaim_strreplace(jbr->status, "\n", "<br />\n");
-- tmp = gaim_markup_strip_html(text);
-+ text = gaim2_strreplace(jbr->status, "\n", "<br />\n");
-+ tmp = gaim2_markup_strip_html(text);
- g_free(text);
- text = g_markup_escape_text(tmp, -1);
- g_free(tmp);
-@@ -1076,59 +1076,59 @@ static char *jabber_tooltip_text(GaimBud
- return g_string_free(ret, FALSE);
- }
-
--static GList *jabber_status_types(GaimAccount *account)
-+static GList *jabber_status_types(Gaim2Account *account)
- {
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- GList *types = NULL;
-- GaimValue *priority_value;
-+ Gaim2Value *priority_value;
-
-- priority_value = gaim_value_new(GAIM_TYPE_INT);
-- gaim_value_set_int(priority_value, 1);
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
-+ priority_value = gaim2_value_new(GAIM_TYPE_INT);
-+ gaim2_value_set_int(priority_value, 1);
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
- jabber_buddy_state_get_status_id(JABBER_BUDDY_STATE_ONLINE),
- NULL, TRUE, TRUE, FALSE,
- "priority", _("Priority"), priority_value,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- priority_value = gaim_value_new(GAIM_TYPE_INT);
-- gaim_value_set_int(priority_value, 1);
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
-+ priority_value = gaim2_value_new(GAIM_TYPE_INT);
-+ gaim2_value_set_int(priority_value, 1);
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
- jabber_buddy_state_get_status_id(JABBER_BUDDY_STATE_CHAT),
- _("Chatty"), TRUE, TRUE, FALSE,
- "priority", _("Priority"), priority_value,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- priority_value = gaim_value_new(GAIM_TYPE_INT);
-- gaim_value_set_int(priority_value, 0);
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AWAY,
-+ priority_value = gaim2_value_new(GAIM_TYPE_INT);
-+ gaim2_value_set_int(priority_value, 0);
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AWAY,
- jabber_buddy_state_get_status_id(JABBER_BUDDY_STATE_AWAY),
- NULL, TRUE, TRUE, FALSE,
- "priority", _("Priority"), priority_value,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- priority_value = gaim_value_new(GAIM_TYPE_INT);
-- gaim_value_set_int(priority_value, 0);
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_EXTENDED_AWAY,
-+ priority_value = gaim2_value_new(GAIM_TYPE_INT);
-+ gaim2_value_set_int(priority_value, 0);
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_EXTENDED_AWAY,
- jabber_buddy_state_get_status_id(JABBER_BUDDY_STATE_XA),
- NULL, TRUE, TRUE, FALSE,
- "priority", _("Priority"), priority_value,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- priority_value = gaim_value_new(GAIM_TYPE_INT);
-- gaim_value_set_int(priority_value, 0);
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_UNAVAILABLE,
-+ priority_value = gaim2_value_new(GAIM_TYPE_INT);
-+ gaim2_value_set_int(priority_value, 0);
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_UNAVAILABLE,
- jabber_buddy_state_get_status_id(JABBER_BUDDY_STATE_DND),
- _("Do Not Disturb"), TRUE, TRUE, FALSE,
- "priority", _("Priority"), priority_value,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-@@ -1137,10 +1137,10 @@ static GList *jabber_status_types(GaimAc
- m = g_list_append(m, _("Invisible"));
- */
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_OFFLINE,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_OFFLINE,
- jabber_buddy_state_get_status_id(JABBER_BUDDY_STATE_UNAVAILABLE),
- NULL, FALSE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-@@ -1156,29 +1156,29 @@ jabber_password_change_result_cb(JabberS
- type = xmlnode_get_attrib(packet, "type");
-
- if(type && !strcmp(type, "result")) {
-- gaim_notify_info(js->gc, _("Password Changed"), _("Password Changed"),
-+ gaim2_notify_info(js->gc, _("Password Changed"), _("Password Changed"),
- _("Your password has been changed."));
- } else {
- char *msg = jabber_parse_error(js, packet);
-
-- gaim_notify_error(js->gc, _("Error changing password"),
-+ gaim2_notify_error(js->gc, _("Error changing password"),
- _("Error changing password"), msg);
- g_free(msg);
- }
- }
-
- static void jabber_password_change_cb(JabberStream *js,
-- GaimRequestFields *fields)
-+ Gaim2RequestFields *fields)
- {
- const char *p1, *p2;
- JabberIq *iq;
- xmlnode *query, *y;
-
-- p1 = gaim_request_fields_get_string(fields, "password1");
-- p2 = gaim_request_fields_get_string(fields, "password2");
-+ p1 = gaim2_request_fields_get_string(fields, "password1");
-+ p2 = gaim2_request_fields_get_string(fields, "password2");
-
- if(strcmp(p1, p2)) {
-- gaim_notify_error(js->gc, NULL, _("New passwords do not match."), NULL);
-+ gaim2_notify_error(js->gc, NULL, _("New passwords do not match."), NULL);
- return;
- }
-
-@@ -1197,71 +1197,71 @@ static void jabber_password_change_cb(Ja
-
- jabber_iq_send(iq);
-
-- gaim_account_set_password(js->gc->account, p1);
-+ gaim2_account_set_password(js->gc->account, p1);
- }
-
--static void jabber_password_change(GaimPluginAction *action)
-+static void jabber_password_change(Gaim2PluginAction *action)
- {
-
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- JabberStream *js = gc->proto_data;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
--
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-+
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
-- field = gaim_request_field_string_new("password1", _("Password"),
-+ field = gaim2_request_field_string_new("password1", _("Password"),
- "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- field = gaim_request_field_string_new("password2", _("Password (again)"),
-+ field = gaim2_request_field_string_new("password2", _("Password (again)"),
- "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
-- gaim_request_fields(js->gc, _("Change Jabber Password"),
-+ gaim2_request_fields(js->gc, _("Change Jabber Password"),
- _("Change Jabber Password"), _("Please enter your new password"),
- fields, _("OK"), G_CALLBACK(jabber_password_change_cb),
- _("Cancel"), NULL, js);
- }
-
--static GList *jabber_actions(GaimPlugin *plugin, gpointer context)
-+static GList *jabber_actions(Gaim2Plugin *plugin, gpointer context)
- {
- GList *m = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- act = gaim_plugin_action_new(_("Set User Info..."),
-+ act = gaim2_plugin_action_new(_("Set User Info..."),
- jabber_setup_set_info);
- m = g_list_append(m, act);
-
- /* if (js->protocol_options & CHANGE_PASSWORD) { */
-- act = gaim_plugin_action_new(_("Change Password..."),
-+ act = gaim2_plugin_action_new(_("Change Password..."),
- jabber_password_change);
- m = g_list_append(m, act);
- /* } */
-
-- act = gaim_plugin_action_new(_("Search for Users..."),
-+ act = gaim2_plugin_action_new(_("Search for Users..."),
- jabber_user_search_begin);
- m = g_list_append(m, act);
-
- return m;
- }
-
--static GaimChat *jabber_find_blist_chat(GaimAccount *account, const char *name)
-+static Gaim2Chat *jabber_find_blist_chat(Gaim2Account *account, const char *name)
- {
-- GaimBlistNode *gnode, *cnode;
-+ Gaim2BlistNode *gnode, *cnode;
- JabberID *jid;
-
- if(!(jid = jabber_id_new(name)))
- return NULL;
-
-- for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for(gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
-- GaimChat *chat = (GaimChat*)cnode;
-+ Gaim2Chat *chat = (Gaim2Chat*)cnode;
- const char *room, *server;
- if(!GAIM_BLIST_NODE_IS_CHAT(cnode))
- continue;
-@@ -1285,7 +1285,7 @@ static GaimChat *jabber_find_blist_chat(
- return NULL;
- }
-
--static void jabber_convo_closed(GaimConnection *gc, const char *who)
-+static void jabber_convo_closed(Gaim2Connection *gc, const char *who)
- {
- JabberStream *js = gc->proto_data;
- JabberID *jid;
-@@ -1452,7 +1452,7 @@ char *jabber_parse_error(JabberStream *j
- }
- }
-
--static GaimCmdRet jabber_cmd_chat_config(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_config(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1460,7 +1460,7 @@ static GaimCmdRet jabber_cmd_chat_config
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_register(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_register(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1468,7 +1468,7 @@ static GaimCmdRet jabber_cmd_chat_regist
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_topic(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_topic(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1476,7 +1476,7 @@ static GaimCmdRet jabber_cmd_chat_topic(
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_nick(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_nick(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1488,7 +1488,7 @@ static GaimCmdRet jabber_cmd_chat_nick(G
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_part(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_part(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1496,7 +1496,7 @@ static GaimCmdRet jabber_cmd_chat_part(G
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_ban(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_ban(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1512,7 +1512,7 @@ static GaimCmdRet jabber_cmd_chat_ban(Ga
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_affiliate(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_affiliate(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1539,20 +1539,20 @@ static GaimCmdRet jabber_cmd_chat_affili
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_invite(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_invite(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- if(!args || !args[0])
- return GAIM_CMD_RET_FAILED;
-
-- jabber_chat_invite(gaim_conversation_get_gc(conv),
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)), args[1] ? args[1] : "",
-+ jabber_chat_invite(gaim2_conversation_get_gc(conv),
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)), args[1] ? args[1] : "",
- args[0]);
-
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_join(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_join(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1569,13 +1569,13 @@ static GaimCmdRet jabber_cmd_chat_join(G
- if(args[1])
- g_hash_table_replace(components, "password", args[1]);
-
-- jabber_chat_join(gaim_conversation_get_gc(conv), components);
-+ jabber_chat_join(gaim2_conversation_get_gc(conv), components);
-
- g_hash_table_destroy(components);
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_kick(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_kick(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1591,7 +1591,7 @@ static GaimCmdRet jabber_cmd_chat_kick(G
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet jabber_cmd_chat_msg(GaimConversation *conv,
-+static Gaim2CmdRet jabber_cmd_chat_msg(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- JabberChat *chat = jabber_chat_find_by_conv(conv);
-@@ -1599,86 +1599,86 @@ static GaimCmdRet jabber_cmd_chat_msg(Ga
-
- who = g_strdup_printf("%s@%s/%s", chat->room, chat->server, args[0]);
-
-- jabber_message_send_im(gaim_conversation_get_gc(conv), who, args[1], 0);
-+ jabber_message_send_im(gaim2_conversation_get_gc(conv), who, args[1], 0);
-
- g_free(who);
- return GAIM_CMD_RET_OK;
- }
-
--static gboolean jabber_offline_message(const GaimBuddy *buddy)
-+static gboolean jabber_offline_message(const Gaim2Buddy *buddy)
- {
- return TRUE;
- }
-
- static void jabber_register_commands(void)
- {
-- gaim_cmd_register("config", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("config", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-jabber", jabber_cmd_chat_config,
- _("config: Configure a chat room."), NULL);
-- gaim_cmd_register("configure", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("configure", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-jabber", jabber_cmd_chat_config,
- _("configure: Configure a chat room."), NULL);
-- gaim_cmd_register("nick", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("nick", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-jabber", jabber_cmd_chat_nick,
- _("nick &lt;new nickname&gt;: Change your nickname."),
- NULL);
-- gaim_cmd_register("part", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("part", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_part, _("part [room]: Leave the room."),
- NULL);
-- gaim_cmd_register("register", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("register", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-jabber", jabber_cmd_chat_register,
- _("register: Register with a chat room."), NULL);
- /* XXX: there needs to be a core /topic cmd, methinks */
-- gaim_cmd_register("topic", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("topic", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_topic,
- _("topic [new topic]: View or change the topic."),
- NULL);
-- gaim_cmd_register("ban", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("ban", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_ban,
- _("ban &lt;user&gt; [room]: Ban a user from the room."),
- NULL);
-- gaim_cmd_register("affiliate", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("affiliate", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_affiliate,
- _("affiliate &lt;user&gt; &lt;owner|admin|member|outcast|none&gt;: Set a user's affiliation with the room."),
- NULL);
-- gaim_cmd_register("invite", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("invite", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_invite,
- _("invite &lt;user&gt; [message]: Invite a user to the room."),
- NULL);
-- gaim_cmd_register("join", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("join", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_join,
- _("join: &lt;room&gt; [server]: Join a chat on this server."),
- NULL);
-- gaim_cmd_register("kick", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("kick", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-jabber",
- jabber_cmd_chat_kick,
- _("kick &lt;user&gt; [room]: Kick a user from the room."),
- NULL);
-- gaim_cmd_register("msg", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("msg", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-jabber", jabber_cmd_chat_msg,
- _("msg &lt;user&gt; &lt;message&gt;: Send a private message to another user."),
- NULL);
- }
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_CHAT_TOPIC | OPT_PROTO_UNIQUE_CHATNAME,
- NULL, /* user_splits */
-@@ -1743,7 +1743,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -1775,47 +1775,47 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountUserSplit *split;
-- GaimAccountOption *option;
-+ Gaim2AccountUserSplit *split;
-+ Gaim2AccountOption *option;
-
-- split = gaim_account_user_split_new(_("Server"), "jabber.org", '@');
-+ split = gaim2_account_user_split_new(_("Server"), "jabber.org", '@');
- prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-
-- split = gaim_account_user_split_new(_("Resource"), "Home", '/');
-+ split = gaim2_account_user_split_new(_("Resource"), "Home", '/');
- prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-
-- option = gaim_account_option_bool_new(_("Use TLS if available"), "use_tls",
-+ option = gaim2_account_option_bool_new(_("Use TLS if available"), "use_tls",
- TRUE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_bool_new(_("Require TLS"), "require_tls", TRUE);
-+ option = gaim2_account_option_bool_new(_("Require TLS"), "require_tls", TRUE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_bool_new(_("Force old (port 5223) SSL"), "old_ssl", FALSE);
-+ option = gaim2_account_option_bool_new(_("Force old (port 5223) SSL"), "old_ssl", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_bool_new(
-+ option = gaim2_account_option_bool_new(
- _("Allow plaintext auth over unencrypted streams"),
- "auth_plain_in_clear", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_int_new(_("Connect port"), "port", 5222);
-+ option = gaim2_account_option_int_new(_("Connect port"), "port", 5222);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_string_new(_("Connect server"),
-+ option = gaim2_account_option_string_new(_("Connect server"),
- "connect_server", NULL);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
- my_protocol = plugin;
-
-- gaim_prefs_remove("/plugins/prpl/jabber");
-+ gaim2_prefs_remove("/plugins/prpl/jabber");
-
- /* XXX - If any other plugin wants SASL this won't be good ... */
- #ifdef HAVE_CYRUS_SASL
-diff -prNu ./src/protocols/jabber/jabber.h ./src/protocols/jabber/jabber.h
---- ./src/protocols/jabber/jabber.h 2005-12-17 03:24:05.000000000 +0100
-+++ ./src/protocols/jabber/jabber.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file jabber.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -86,7 +86,7 @@ typedef struct _JabberStream
-
- GHashTable *chats;
- GList *chat_servers;
-- GaimRoomlist *roomlist;
-+ Gaim2Roomlist *roomlist;
- GList *user_directories;
-
- GHashTable *iq_callbacks;
-@@ -100,8 +100,8 @@ typedef struct _JabberStream
- time_t idle;
-
- JabberID *user;
-- GaimConnection *gc;
-- GaimSslConnection *gsc;
-+ Gaim2Connection *gc;
-+ Gaim2SslConnection *gsc;
-
- gboolean registration;
-
-diff -prNu ./src/protocols/jabber/jutil.c ./src/protocols/jabber/jutil.c
---- ./src/protocols/jabber/jutil.c 2005-08-25 04:33:44.000000000 +0200
-+++ ./src/protocols/jabber/jutil.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -182,9 +182,9 @@ char *jabber_get_bare_jid(const char *in
- return out;
- }
-
--const char *jabber_normalize(const GaimAccount *account, const char *in)
-+const char *jabber_normalize(const Gaim2Account *account, const char *in)
- {
-- GaimConnection *gc = account ? account->gc : NULL;
-+ Gaim2Connection *gc = account ? account->gc : NULL;
- JabberStream *js = gc ? gc->proto_data : NULL;
- static char buf[3072]; /* maximum legal length of a jabber jid */
- JabberID *jid;
-@@ -214,19 +214,19 @@ const char *jabber_normalize(const GaimA
- return buf;
- }
-
--GaimConversation *
--jabber_find_unnormalized_conv(const char *name, GaimAccount *account)
-+Gaim2Conversation *
-+jabber_find_unnormalized_conv(const char *name, Gaim2Account *account)
- {
-- GaimConversation *c = NULL;
-+ Gaim2Conversation *c = NULL;
- GList *cnv;
-
- g_return_val_if_fail(name != NULL, NULL);
-
-- for(cnv = gaim_get_conversations(); cnv; cnv = cnv->next) {
-- c = (GaimConversation*)cnv->data;
-- if(gaim_conversation_get_type(c) == GAIM_CONV_TYPE_IM &&
-- !gaim_utf8_strcasecmp(name, gaim_conversation_get_name(c)) &&
-- account == gaim_conversation_get_account(c))
-+ for(cnv = gaim2_get_conversations(); cnv; cnv = cnv->next) {
-+ c = (Gaim2Conversation*)cnv->data;
-+ if(gaim2_conversation_get_type(c) == GAIM_CONV_TYPE_IM &&
-+ !gaim2_utf8_strcasecmp(name, gaim2_conversation_get_name(c)) &&
-+ account == gaim2_conversation_get_account(c))
- return c;
- }
-
-diff -prNu ./src/protocols/jabber/jutil.h ./src/protocols/jabber/jutil.h
---- ./src/protocols/jabber/jutil.h 2004-09-05 19:10:39.000000000 +0200
-+++ ./src/protocols/jabber/jutil.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file jutil.h utility functions
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -39,12 +39,12 @@ void jabber_id_free(JabberID *jid);
- char *jabber_get_resource(const char *jid);
- char *jabber_get_bare_jid(const char *jid);
-
--const char *jabber_normalize(const GaimAccount *account, const char *in);
-+const char *jabber_normalize(const Gaim2Account *account, const char *in);
-
- gboolean jabber_nodeprep_validate(const char *);
- gboolean jabber_nameprep_validate(const char *);
- gboolean jabber_resourceprep_validate(const char *);
-
--GaimConversation *jabber_find_unnormalized_conv(const char *name, GaimAccount *account);
-+Gaim2Conversation *jabber_find_unnormalized_conv(const char *name, Gaim2Account *account);
-
- #endif /* _GAIM_JABBER_JUTIL_H_ */
-diff -prNu ./src/protocols/jabber/Makefile.am ./src/protocols/jabber/Makefile.am
---- ./src/protocols/jabber/Makefile.am 2005-12-17 03:24:05.000000000 +0100
-+++ ./src/protocols/jabber/Makefile.am 2006-01-05 13:03:48.000000000 +0100
-@@ -3,7 +3,7 @@ EXTRA_DIST = \
- win32/posix.uname.c \
- win32/utsname.h
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- JABBERSOURCES = auth.c \
- auth.h \
-diff -prNu ./src/protocols/jabber/message.c ./src/protocols/jabber/message.c
---- ./src/protocols/jabber/message.c 2005-11-24 21:47:45.000000000 +0100
-+++ ./src/protocols/jabber/message.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -70,12 +70,12 @@ static void handle_chat(JabberMessage *j
- from = g_strdup(jm->from);
- } else if(jid->node) {
- if(jid->resource) {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- from = g_strdup_printf("%s@%s", jid->node, jid->domain);
- conv = jabber_find_unnormalized_conv(from, jm->js->gc->account);
- if(conv) {
-- gaim_conversation_set_name(conv, jm->from);
-+ gaim2_conversation_set_name(conv, jm->from);
- }
- g_free(from);
- }
-@@ -147,7 +147,7 @@ static void handle_headline(JabberMessag
- }
- }
-
-- gaim_notify_formatted(jm->js->gc, title, jm->subject ? jm->subject : title,
-+ gaim2_notify_formatted(jm->js->gc, title, jm->subject ? jm->subject : title,
- NULL, body->str, NULL, NULL);
-
- g_free(title);
-@@ -168,17 +168,17 @@ static void handle_groupchat(JabberMessa
- return;
-
- if(jm->subject) {
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(chat->conv), jid->resource,
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(chat->conv), jid->resource,
- jm->subject);
- if(!jm->xhtml && !jm->body) {
- char *msg, *tmp, *tmp2;
- tmp = g_markup_escape_text(jm->subject, -1);
-- tmp2 = gaim_markup_linkify(tmp);
-+ tmp2 = gaim2_markup_linkify(tmp);
- if(jid->resource)
- msg = g_strdup_printf(_("%s has set the topic to: %s"), jid->resource, tmp2);
- else
- msg = g_strdup_printf(_("The topic is: %s"), tmp2);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "", msg, GAIM_MESSAGE_SYSTEM, jm->sent);
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "", msg, GAIM_MESSAGE_SYSTEM, jm->sent);
- g_free(tmp);
- g_free(tmp2);
- g_free(msg);
-@@ -191,7 +191,7 @@ static void handle_groupchat(JabberMessa
- jm->delayed ? GAIM_MESSAGE_DELAYED : 0,
- jm->xhtml ? jm->xhtml : jm->body, jm->sent);
- else if(chat->muc)
-- gaim_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "",
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(chat->conv), "",
- jm->xhtml ? jm->xhtml : jm->body,
- GAIM_MESSAGE_SYSTEM, jm->sent);
- }
-@@ -230,7 +230,7 @@ static void handle_error(JabberMessage *
- buf = g_strdup_printf(_("Message delivery to %s failed: %s"),
- jm->from, jm->error);
-
-- gaim_notify_formatted(jm->js->gc, _("Jabber Message Error"), _("Jabber Message Error"), buf,
-+ gaim2_notify_formatted(jm->js->gc, _("Jabber Message Error"), _("Jabber Message Error"), buf,
- jm->xhtml ? jm->xhtml : jm->body, NULL, NULL);
-
- g_free(buf);
-@@ -311,7 +311,7 @@ void jabber_message_parse(JabberStream *
- const char *timestamp = xmlnode_get_attrib(child, "stamp");
- jm->delayed = TRUE;
- if(timestamp)
-- jm->sent = gaim_str_to_time(timestamp, TRUE);
-+ jm->sent = gaim2_str_to_time(timestamp, TRUE);
- } else if(xmlns && !strcmp(xmlns, "jabber:x:conference") &&
- jm->type != JABBER_MESSAGE_GROUPCHAT_INVITE &&
- jm->type != JABBER_MESSAGE_ERROR) {
-@@ -364,7 +364,7 @@ void jabber_message_parse(JabberStream *
- handle_error(jm);
- break;
- case JABBER_MESSAGE_OTHER:
-- gaim_debug(GAIM_DEBUG_INFO, "jabber",
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber",
- "Received message of unknown type: %s\n", type);
- break;
- }
-@@ -432,7 +432,7 @@ void jabber_message_send(JabberMessage *
- if(child) {
- xmlnode_insert_child(message, child);
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "jabber",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "jabber",
- "XHTML translation/validation failed, returning: %s\n",
- jm->xhtml);
- }
-@@ -443,8 +443,8 @@ void jabber_message_send(JabberMessage *
- xmlnode_free(message);
- }
-
--int jabber_message_send_im(GaimConnection *gc, const char *who, const char *msg,
-- GaimMessageFlags flags)
-+int jabber_message_send_im(Gaim2Connection *gc, const char *who, const char *msg,
-+ Gaim2MessageFlags flags)
- {
- JabberMessage *jm;
- JabberBuddy *jb;
-@@ -473,7 +473,7 @@ int jabber_message_send_im(GaimConnectio
-
- buf = g_strdup_printf("<html xmlns='http://jabber.org/protocol/xhtml-im'><body xmlns='http://www.w3.org/1999/xhtml'>%s</body></html>", msg);
-
-- gaim_markup_html_to_xhtml(buf, &xhtml, &jm->body);
-+ gaim2_markup_html_to_xhtml(buf, &xhtml, &jm->body);
- g_free(buf);
-
- if(!jbr || jbr->capabilities & JABBER_CAP_XHTML)
-@@ -486,7 +486,7 @@ int jabber_message_send_im(GaimConnectio
- return 1;
- }
-
--int jabber_message_send_chat(GaimConnection *gc, int id, const char *msg, GaimMessageFlags flags)
-+int jabber_message_send_chat(Gaim2Connection *gc, int id, const char *msg, Gaim2MessageFlags flags)
- {
- JabberChat *chat;
- JabberMessage *jm;
-@@ -508,7 +508,7 @@ int jabber_message_send_chat(GaimConnect
- jm->to = g_strdup_printf("%s@%s", chat->room, chat->server);
-
- buf = g_strdup_printf("<html xmlns='http://jabber.org/protocol/xhtml-im'><body xmlns='http://www.w3.org/1999/xhtml'>%s</body></html>", msg);
-- gaim_markup_html_to_xhtml(buf, &jm->xhtml, &jm->body);
-+ gaim2_markup_html_to_xhtml(buf, &jm->xhtml, &jm->body);
- g_free(buf);
-
- if(!chat->xhtml) {
-@@ -522,7 +522,7 @@ int jabber_message_send_chat(GaimConnect
- return 1;
- }
-
--int jabber_send_typing(GaimConnection *gc, const char *who, int typing)
-+int jabber_send_typing(Gaim2Connection *gc, const char *who, int typing)
- {
- JabberMessage *jm;
- JabberBuddy *jb;
-diff -prNu ./src/protocols/jabber/message.h ./src/protocols/jabber/message.h
---- ./src/protocols/jabber/message.h 2005-11-24 21:47:45.000000000 +0100
-+++ ./src/protocols/jabber/message.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file message.h Message handlers
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -57,11 +57,11 @@ void jabber_message_free(JabberMessage *
- void jabber_message_send(JabberMessage *jm);
-
- void jabber_message_parse(JabberStream *js, xmlnode *packet);
--int jabber_message_send_im(GaimConnection *gc, const char *who, const char *msg,
-- GaimMessageFlags flags);
--int jabber_message_send_chat(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags);
-+int jabber_message_send_im(Gaim2Connection *gc, const char *who, const char *msg,
-+ Gaim2MessageFlags flags);
-+int jabber_message_send_chat(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags);
-
--int jabber_send_typing(GaimConnection *gc, const char *who, int typing);
-+int jabber_send_typing(Gaim2Connection *gc, const char *who, int typing);
-
-
- #endif /* _GAIM_JABBER_MESSAGE_H_ */
-diff -prNu ./src/protocols/jabber/oob.c ./src/protocols/jabber/oob.c
---- ./src/protocols/jabber/oob.c 2005-12-04 19:42:21.000000000 +0100
-+++ ./src/protocols/jabber/oob.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -41,13 +41,13 @@ typedef struct _JabberOOBXfer {
-
- } JabberOOBXfer;
-
--static void jabber_oob_xfer_init(GaimXfer *xfer)
-+static void jabber_oob_xfer_init(Gaim2Xfer *xfer)
- {
- JabberOOBXfer *jox = xfer->data;
-- gaim_xfer_start(xfer, -1, jox->address, jox->port);
-+ gaim2_xfer_start(xfer, -1, jox->address, jox->port);
- }
-
--static void jabber_oob_xfer_free(GaimXfer *xfer)
-+static void jabber_oob_xfer_free(Gaim2Xfer *xfer)
- {
- JabberOOBXfer *jox = xfer->data;
- jox->js->oob_file_transfers = g_list_remove(jox->js->oob_file_transfers,
-@@ -62,7 +62,7 @@ static void jabber_oob_xfer_free(GaimXfe
- xfer->data = NULL;
- }
-
--static void jabber_oob_xfer_end(GaimXfer *xfer)
-+static void jabber_oob_xfer_end(Gaim2Xfer *xfer)
- {
- JabberOOBXfer *jox = xfer->data;
- JabberIq *iq;
-@@ -76,7 +76,7 @@ static void jabber_oob_xfer_end(GaimXfer
- jabber_oob_xfer_free(xfer);
- }
-
--static void jabber_oob_xfer_start(GaimXfer *xfer)
-+static void jabber_oob_xfer_start(Gaim2Xfer *xfer)
- {
- JabberOOBXfer *jox = xfer->data;
-
-@@ -86,7 +86,7 @@ static void jabber_oob_xfer_start(GaimXf
- g_free(buf);
- }
-
--static gssize jabber_oob_xfer_read(guchar **buffer, GaimXfer *xfer) {
-+static gssize jabber_oob_xfer_read(guchar **buffer, Gaim2Xfer *xfer) {
- JabberOOBXfer *jox = xfer->data;
- char test;
- int size;
-@@ -100,9 +100,9 @@ static gssize jabber_oob_xfer_read(gucha
- gchar *lenstr = strstr(jox->headers->str, "Content-Length: ");
- if(lenstr) {
- sscanf(lenstr, "Content-Length: %d", &size);
-- gaim_xfer_set_size(xfer, size);
-+ gaim2_xfer_set_size(xfer, size);
- }
-- gaim_xfer_set_read_fnc(xfer, NULL);
-+ gaim2_xfer_set_read_fnc(xfer, NULL);
- return 0;
- } else
- jox->newline = TRUE;
-@@ -111,14 +111,14 @@ static gssize jabber_oob_xfer_read(gucha
- jox->newline = FALSE;
- return 0;
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "jabber", "Read error on oob xfer!\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "jabber", "Read error on oob xfer!\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
-
- return 0;
- }
-
--static void jabber_oob_xfer_recv_error(GaimXfer *xfer, const char *code) {
-+static void jabber_oob_xfer_recv_error(Gaim2Xfer *xfer, const char *code) {
- JabberOOBXfer *jox = xfer->data;
- JabberIq *iq;
- xmlnode *y, *z;
-@@ -142,17 +142,17 @@ static void jabber_oob_xfer_recv_error(G
- jabber_oob_xfer_free(xfer);
- }
-
--static void jabber_oob_xfer_recv_denied(GaimXfer *xfer) {
-+static void jabber_oob_xfer_recv_denied(Gaim2Xfer *xfer) {
- jabber_oob_xfer_recv_error(xfer, "406");
- }
-
--static void jabber_oob_xfer_recv_canceled(GaimXfer *xfer) {
-+static void jabber_oob_xfer_recv_canceled(Gaim2Xfer *xfer) {
- jabber_oob_xfer_recv_error(xfer, "404");
- }
-
- void jabber_oob_parse(JabberStream *js, xmlnode *packet) {
- JabberOOBXfer *jox;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- char *filename;
- char *url;
- xmlnode *querynode, *urlnode;
-@@ -166,33 +166,33 @@ void jabber_oob_parse(JabberStream *js,
- url = xmlnode_get_data(urlnode);
-
- jox = g_new0(JabberOOBXfer, 1);
-- gaim_url_parse(url, &jox->address, &jox->port, &jox->page, NULL, NULL);
-+ gaim2_url_parse(url, &jox->address, &jox->port, &jox->page, NULL, NULL);
- g_free(url);
- jox->js = js;
- jox->headers = g_string_new("");
- jox->iq_id = g_strdup(xmlnode_get_attrib(packet, "id"));
-
-- xfer = gaim_xfer_new(js->gc->account, GAIM_XFER_RECEIVE,
-+ xfer = gaim2_xfer_new(js->gc->account, GAIM_XFER_RECEIVE,
- xmlnode_get_attrib(packet, "from"));
- xfer->data = jox;
-
- if(!(filename = g_strdup(g_strrstr(jox->page, "/"))))
- filename = g_strdup(jox->page);
-
-- gaim_xfer_set_filename(xfer, filename);
-+ gaim2_xfer_set_filename(xfer, filename);
-
- g_free(filename);
-
-- gaim_xfer_set_init_fnc(xfer, jabber_oob_xfer_init);
-- gaim_xfer_set_end_fnc(xfer, jabber_oob_xfer_end);
-- gaim_xfer_set_request_denied_fnc(xfer, jabber_oob_xfer_recv_denied);
-- gaim_xfer_set_cancel_recv_fnc(xfer, jabber_oob_xfer_recv_canceled);
-- gaim_xfer_set_read_fnc(xfer, jabber_oob_xfer_read);
-- gaim_xfer_set_start_fnc(xfer, jabber_oob_xfer_start);
-+ gaim2_xfer_set_init_fnc(xfer, jabber_oob_xfer_init);
-+ gaim2_xfer_set_end_fnc(xfer, jabber_oob_xfer_end);
-+ gaim2_xfer_set_request_denied_fnc(xfer, jabber_oob_xfer_recv_denied);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, jabber_oob_xfer_recv_canceled);
-+ gaim2_xfer_set_read_fnc(xfer, jabber_oob_xfer_read);
-+ gaim2_xfer_set_start_fnc(xfer, jabber_oob_xfer_start);
-
- js->oob_file_transfers = g_list_append(js->oob_file_transfers, xfer);
-
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
-
-diff -prNu ./src/protocols/jabber/oob.h ./src/protocols/jabber/oob.h
---- ./src/protocols/jabber/oob.h 2003-10-31 03:43:58.000000000 +0100
-+++ ./src/protocols/jabber/oob.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file jutil.h utility functions
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/jabber/parser.c ./src/protocols/jabber/parser.c
---- ./src/protocols/jabber/parser.c 2004-02-19 15:57:41.000000000 +0100
-+++ ./src/protocols/jabber/parser.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber XML parser stuff
-+ * gaim2 - Jabber XML parser stuff
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -128,7 +128,7 @@ void jabber_parser_process(JabberStream
- if(!g_markup_parse_context_parse(js->context, buf, len, NULL)) {
- g_markup_parse_context_free(js->context);
- js->context = NULL;
-- gaim_connection_error(js->gc, _("XML Parse error"));
-+ gaim2_connection_error(js->gc, _("XML Parse error"));
- }
- }
-
-diff -prNu ./src/protocols/jabber/parser.h ./src/protocols/jabber/parser.h
---- ./src/protocols/jabber/parser.h 2003-09-29 17:23:19.000000000 +0200
-+++ ./src/protocols/jabber/parser.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file parser.h XML parser functions
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/jabber/presence.c ./src/protocols/jabber/presence.c
---- ./src/protocols/jabber/presence.c 2006-01-01 17:25:17.000000000 +0100
-+++ ./src/protocols/jabber/presence.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -54,14 +54,14 @@ static void chats_send_presence_foreach(
- g_free(chat_full_jid);
- }
-
--void jabber_presence_fake_to_self(JabberStream *js, const GaimStatus *gstatus) {
-+void jabber_presence_fake_to_self(JabberStream *js, const Gaim2Status *gstatus) {
- char *my_base_jid;
-
- if(!js->user)
- return;
-
- my_base_jid = g_strdup_printf("%s@%s", js->user->node, js->user->domain);
-- if(gaim_find_buddy(js->gc->account, my_base_jid)) {
-+ if(gaim2_find_buddy(js->gc->account, my_base_jid)) {
- JabberBuddy *jb;
- JabberBuddyResource *jbr;
- if((jb = jabber_buddy_find(js, my_base_jid, TRUE))) {
-@@ -69,7 +69,7 @@ void jabber_presence_fake_to_self(Jabber
- const char *msg;
- int priority;
-
-- gaim_status_to_jabber(gstatus, &state, &msg, &priority);
-+ gaim2_status_to_jabber(gstatus, &state, &msg, &priority);
-
- if (state == JABBER_BUDDY_STATE_UNAVAILABLE || state == JABBER_BUDDY_STATE_UNKNOWN) {
- jabber_buddy_remove_resource(jb, js->user->resource);
-@@ -77,9 +77,9 @@ void jabber_presence_fake_to_self(Jabber
- jabber_buddy_track_resource(jb, js->user->resource, priority, state, msg);
- }
- if((jbr = jabber_buddy_find_resource(jb, NULL))) {
-- gaim_prpl_got_user_status(js->gc->account, my_base_jid, jabber_buddy_state_get_status_id(jbr->state), "priority", jbr->priority, jbr->status ? "message" : NULL, jbr->status, NULL);
-+ gaim2_prpl_got_user_status(js->gc->account, my_base_jid, jabber_buddy_state_get_status_id(jbr->state), "priority", jbr->priority, jbr->status ? "message" : NULL, jbr->status, NULL);
- } else {
-- gaim_prpl_got_user_status(js->gc->account, my_base_jid, "offline", msg ? "message" : NULL, msg, NULL);
-+ gaim2_prpl_got_user_status(js->gc->account, my_base_jid, "offline", msg ? "message" : NULL, msg, NULL);
- }
- }
- }
-@@ -87,9 +87,9 @@ void jabber_presence_fake_to_self(Jabber
- }
-
-
--void jabber_presence_send(GaimAccount *account, GaimStatus *status)
-+void jabber_presence_send(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc = NULL;
-+ Gaim2Connection *gc = NULL;
- JabberStream *js = NULL;
- gboolean disconnected;
- int primitive;
-@@ -99,22 +99,22 @@ void jabber_presence_send(GaimAccount *a
- JabberBuddyState state;
- int priority;
-
-- if(!gaim_status_is_active(status))
-+ if(!gaim2_status_is_active(status))
- return;
-
-- disconnected = gaim_account_is_disconnected(account);
-- primitive = gaim_status_type_get_primitive(gaim_status_get_type(status));
-+ disconnected = gaim2_account_is_disconnected(account);
-+ primitive = gaim2_status_type_get_primitive(gaim2_status_get_type(status));
-
- if(disconnected)
- return;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- js = gc->proto_data;
-
-- gaim_status_to_jabber(status, &state, &msg, &priority);
-+ gaim2_status_to_jabber(status, &state, &msg, &priority);
-
- if(msg)
-- gaim_markup_html_to_xhtml(msg, NULL, &stripped);
-+ gaim2_markup_html_to_xhtml(msg, NULL, &stripped);
-
- presence = jabber_presence_create(state, stripped, priority);
- g_free(stripped);
-@@ -172,19 +172,19 @@ xmlnode *jabber_presence_create(JabberBu
-
- struct _jabber_add_permit {
- JabberStream *js;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *who;
- };
-
- static void authorize_add_cb(struct _jabber_add_permit *jap)
- {
-- if(g_list_find(gaim_connections_get_all(), jap->gc)) {
-- GaimBuddy *buddy = NULL;
-+ if(g_list_find(gaim2_connections_get_all(), jap->gc)) {
-+ Gaim2Buddy *buddy = NULL;
-
- jabber_presence_subscription_set(jap->gc->proto_data, jap->who,
- "subscribed");
-
-- buddy = gaim_find_buddy(jap->gc->account, jap->who);
-+ buddy = gaim2_find_buddy(jap->gc->account, jap->who);
-
- if (buddy) {
- JabberBuddy *jb = NULL;
-@@ -192,16 +192,16 @@ static void authorize_add_cb(struct _jab
- jb = jabber_buddy_find(jap->js, jap->who, TRUE);
-
- if ((jb->subscription & JABBER_SUB_TO) == 0) {
-- gaim_account_request_add(jap->gc->account,
-+ gaim2_account_request_add(jap->gc->account,
- jap->who, NULL,
- NULL, NULL);
- } else {
-- gaim_account_notify_added(jap->gc->account,
-+ gaim2_account_notify_added(jap->gc->account,
- jap->who, NULL,
- NULL, NULL);
- }
- } else {
-- gaim_account_request_add(jap->gc->account, jap->who,
-+ gaim2_account_request_add(jap->gc->account, jap->who,
- NULL, NULL, NULL);
- }
- }
-@@ -212,7 +212,7 @@ static void authorize_add_cb(struct _jab
-
- static void deny_add_cb(struct _jabber_add_permit *jap)
- {
-- if(g_list_find(gaim_connections_get_all(), jap->gc)) {
-+ if(g_list_find(gaim2_connections_get_all(), jap->gc)) {
- jabber_presence_subscription_set(jap->gc->proto_data, jap->who,
- "unsubscribed");
- }
-@@ -224,7 +224,7 @@ static void deny_add_cb(struct _jabber_a
- static void jabber_vcard_parse_avatar(JabberStream *js, xmlnode *packet, gpointer blah)
- {
- JabberBuddy *jb = NULL;
-- GaimBuddy *b = NULL;
-+ Gaim2Buddy *b = NULL;
- xmlnode *vcard, *photo, *binval;
- char *text;
- guchar *data;
-@@ -244,20 +244,20 @@ static void jabber_vcard_parse_avatar(Ja
- (( (binval = xmlnode_get_child(photo, "BINVAL")) &&
- (text = xmlnode_get_data(binval))) ||
- (text = xmlnode_get_data(photo)))) {
-- data = gaim_base64_decode(text, &size);
-+ data = gaim2_base64_decode(text, &size);
-
-- gaim_buddy_icons_set_for_user(js->gc->account, from, data, size);
-- if((b = gaim_find_buddy(js->gc->account, from))) {
-+ gaim2_buddy_icons_set_for_user(js->gc->account, from, data, size);
-+ if((b = gaim2_find_buddy(js->gc->account, from))) {
- unsigned char hashval[20];
- char hash[41], *p;
- int i;
-
-- gaim_cipher_digest_region("sha1", (guchar *)data, size,
-+ gaim2_cipher_digest_region("sha1", (guchar *)data, size,
- sizeof(hashval), hashval, NULL);
- p = hash;
- for(i=0; i<20; i++, p+=2)
- snprintf(p, 3, "%02x", hashval[i]);
-- gaim_blist_node_set_string((GaimBlistNode*)b, "avatar_hash", hash);
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)b, "avatar_hash", hash);
- }
- g_free(text);
- }
-@@ -277,9 +277,9 @@ void jabber_presence_parse(JabberStream
- JabberChat *chat;
- JabberBuddy *jb;
- JabberBuddyResource *jbr = NULL, *found_jbr = NULL;
-- GaimConvChatBuddyFlags flags = GAIM_CBFLAGS_NONE;
-+ Gaim2ConvChatBuddyFlags flags = GAIM_CBFLAGS_NONE;
- gboolean delayed = FALSE;
-- GaimBuddy *b = NULL;
-+ Gaim2Buddy *b = NULL;
- char *buddy_name;
- JabberBuddyState state = JABBER_BUDDY_STATE_UNKNOWN;
- xmlnode *y;
-@@ -309,12 +309,12 @@ void jabber_presence_parse(JabberStream
-
- msg = g_strdup_printf(_("The user %s wants to add %s to his or "
- "her buddy list."),
-- from, gaim_account_get_username(js->gc->account));
-+ from, gaim2_account_get_username(js->gc->account));
- jap->gc = js->gc;
- jap->who = g_strdup(from);
- jap->js = js;
-
-- gaim_request_action(js->gc, NULL, msg, NULL, GAIM_DEFAULT_ACTION_NONE,
-+ gaim2_request_action(js->gc, NULL, msg, NULL, GAIM_DEFAULT_ACTION_NONE,
- jap, 2,
- _("_Authorize"), G_CALLBACK(authorize_add_cb),
- _("_Deny"), G_CALLBACK(deny_add_cb));
-@@ -373,7 +373,7 @@ void jabber_presence_parse(JabberStream
- chat = jabber_chat_find(js, jid->node, jid->domain);
- chat->config_dialog_type = GAIM_REQUEST_ACTION;
- chat->config_dialog_handle =
-- gaim_request_action(js->gc, _("Create New Room"),
-+ gaim2_request_action(js->gc, _("Create New Room"),
- _("Create New Room"),
- _("You are creating a new room. Would you like to "
- "configure it, or accept the default settings?"),
-@@ -421,7 +421,7 @@ void jabber_presence_parse(JabberStream
- } else {
- title = g_strdup_printf(_("Error joining chat %s"), from);
- }
-- gaim_notify_error(js->gc, title, title, msg);
-+ gaim2_notify_error(js->gc, title, title, msg);
- g_free(title);
- g_free(msg);
-
-@@ -476,7 +476,7 @@ void jabber_presence_parse(JabberStream
- g_free(chat->handle);
- chat->handle = g_strdup(nick);
- }
-- gaim_conv_chat_rename_user(GAIM_CONV_CHAT(chat->conv), jid->resource, nick);
-+ gaim2_conv_chat_rename_user(GAIM_CONV_CHAT(chat->conv), jid->resource, nick);
- jabber_chat_remove_handle(chat, jid->resource);
- break;
- } else if(!strcmp(code, "307")) {
-@@ -495,7 +495,7 @@ void jabber_presence_parse(JabberStream
- serv_got_chat_left(js->gc, chat->id);
- jabber_chat_destroy(chat);
- } else {
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(chat->conv), jid->resource,
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(chat->conv), jid->resource,
- status);
- jabber_chat_remove_handle(chat, jid->resource);
- }
-@@ -505,7 +505,7 @@ void jabber_presence_parse(JabberStream
- chat->id = i++;
- chat->muc = muc;
- chat->conv = serv_got_joined_chat(js->gc, chat->id, room_jid);
-- gaim_conv_chat_set_nick(GAIM_CONV_CHAT(chat->conv), chat->handle);
-+ gaim2_conv_chat_set_nick(GAIM_CONV_CHAT(chat->conv), chat->handle);
-
- jabber_chat_disco_traffic(chat);
- }
-@@ -516,17 +516,17 @@ void jabber_presence_parse(JabberStream
- jabber_chat_track_handle(chat, jid->resource, real_jid, affiliation, role);
-
- if(!jabber_chat_find_buddy(chat->conv, jid->resource))
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(chat->conv), jid->resource,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(chat->conv), jid->resource,
- real_jid, flags, !delayed);
- else
-- gaim_conv_chat_user_set_flags(GAIM_CONV_CHAT(chat->conv), jid->resource,
-+ gaim2_conv_chat_user_set_flags(GAIM_CONV_CHAT(chat->conv), jid->resource,
- flags);
- }
- g_free(room_jid);
- } else {
- buddy_name = g_strdup_printf("%s%s%s", jid->node ? jid->node : "",
- jid->node ? "@" : "", jid->domain);
-- if((b = gaim_find_buddy(js->gc->account, buddy_name)) == NULL) {
-+ if((b = gaim2_find_buddy(js->gc->account, buddy_name)) == NULL) {
- jabber_id_free(jid);
- if(avatar_hash)
- g_free(avatar_hash);
-@@ -536,7 +536,7 @@ void jabber_presence_parse(JabberStream
- }
-
- if(avatar_hash) {
-- const char *avatar_hash2 = gaim_blist_node_get_string((GaimBlistNode*)b, "avatar_hash");
-+ const char *avatar_hash2 = gaim2_blist_node_get_string((Gaim2BlistNode*)b, "avatar_hash");
- if(!avatar_hash2 || strcmp(avatar_hash, avatar_hash2)) {
- JabberIq *iq;
- xmlnode *vcard;
-@@ -564,11 +564,11 @@ void jabber_presence_parse(JabberStream
- if(state == JABBER_BUDDY_STATE_ERROR ||
- (type && (!strcmp(type, "unavailable") ||
- !strcmp(type, "unsubscribed")))) {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- jabber_buddy_remove_resource(jb, jid->resource);
- if((conv = jabber_find_unnormalized_conv(from, js->gc->account)))
-- gaim_conversation_set_name(conv, buddy_name);
-+ gaim2_conversation_set_name(conv, buddy_name);
-
- } else {
- jbr = jabber_buddy_track_resource(jb, jid->resource, priority,
-@@ -577,10 +577,10 @@ void jabber_presence_parse(JabberStream
-
- if((found_jbr = jabber_buddy_find_resource(jb, NULL))) {
- if(!jbr || jbr == found_jbr) {
-- gaim_prpl_got_user_status(js->gc->account, buddy_name, jabber_buddy_state_get_status_id(state), "priority", found_jbr->priority, found_jbr->status ? "message" : NULL, found_jbr->status, NULL);
-+ gaim2_prpl_got_user_status(js->gc->account, buddy_name, jabber_buddy_state_get_status_id(state), "priority", found_jbr->priority, found_jbr->status ? "message" : NULL, found_jbr->status, NULL);
- }
- } else {
-- gaim_prpl_got_user_status(js->gc->account, buddy_name, "offline", status ? "message" : NULL, status, NULL);
-+ gaim2_prpl_got_user_status(js->gc->account, buddy_name, "offline", status ? "message" : NULL, status, NULL);
- }
- g_free(buddy_name);
- }
-@@ -601,7 +601,7 @@ void jabber_presence_subscription_set(Ja
- xmlnode_free(presence);
- }
-
--void gaim_status_to_jabber(const GaimStatus *status, JabberBuddyState *state, const char **msg, int *priority)
-+void gaim2_status_to_jabber(const Gaim2Status *status, JabberBuddyState *state, const char **msg, int *priority)
- {
- const char *status_id = NULL;
-
-@@ -613,19 +613,19 @@ void gaim_status_to_jabber(const GaimSta
- *state = JABBER_BUDDY_STATE_UNAVAILABLE;
- } else {
- if(state) {
-- status_id = gaim_status_get_id(status);
-+ status_id = gaim2_status_get_id(status);
- *state = jabber_buddy_status_id_get_state(status_id);
- }
-
- if(msg)
-- *msg = gaim_status_get_attr_string(status, "message");
-+ *msg = gaim2_status_get_attr_string(status, "message");
-
- /* if the message is blank, then there really isn't a message */
- if(*msg && !**msg)
- *msg = NULL;
-
- if(priority)
-- *priority = gaim_status_get_attr_int(status, "priority");
-+ *priority = gaim2_status_get_attr_int(status, "priority");
- }
-
- }
-diff -prNu ./src/protocols/jabber/presence.h ./src/protocols/jabber/presence.h
---- ./src/protocols/jabber/presence.h 2004-11-20 06:12:59.000000000 +0100
-+++ ./src/protocols/jabber/presence.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file presence.h Presence
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -26,12 +26,12 @@
- #include "jabber.h"
- #include "xmlnode.h"
-
--void jabber_presence_send(GaimAccount *account, GaimStatus *status);
-+void jabber_presence_send(Gaim2Account *account, Gaim2Status *status);
- xmlnode *jabber_presence_create(JabberBuddyState state, const char *msg, int priority);
- void jabber_presence_parse(JabberStream *js, xmlnode *packet);
- void jabber_presence_subscription_set(JabberStream *js, const char *who,
- const char *type);
--void jabber_presence_fake_to_self(JabberStream *js, const GaimStatus *status);
--void gaim_status_to_jabber(const GaimStatus *status, JabberBuddyState *state, const char **msg, int *priority);
-+void jabber_presence_fake_to_self(JabberStream *js, const Gaim2Status *status);
-+void gaim2_status_to_jabber(const Gaim2Status *status, JabberBuddyState *state, const char **msg, int *priority);
-
- #endif /* _GAIM_JABBER_PRESENCE_H_ */
-diff -prNu ./src/protocols/jabber/roster.c ./src/protocols/jabber/roster.c
---- ./src/protocols/jabber/roster.c 2005-12-01 21:09:27.000000000 +0100
-+++ ./src/protocols/jabber/roster.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -39,24 +39,24 @@ void jabber_roster_request(JabberStream
- jabber_iq_send(iq);
- }
-
--static void remove_gaim_buddies(JabberStream *js, const char *jid)
-+static void remove_gaim2_buddies(JabberStream *js, const char *jid)
- {
- GSList *buddies, *l;
-
-- buddies = gaim_find_buddies(js->gc->account, jid);
-+ buddies = gaim2_find_buddies(js->gc->account, jid);
-
- for(l = buddies; l; l = l->next)
-- gaim_blist_remove_buddy(l->data);
-+ gaim2_blist_remove_buddy(l->data);
-
- g_slist_free(buddies);
- }
-
--static void add_gaim_buddies_in_groups(JabberStream *js, const char *jid,
-+static void add_gaim2_buddies_in_groups(JabberStream *js, const char *jid,
- const char *alias, GSList *groups)
- {
- GSList *buddies, *g2, *l;
-
-- buddies = gaim_find_buddies(js->gc->account, jid);
-+ buddies = gaim2_find_buddies(js->gc->account, jid);
-
- g2 = groups;
-
-@@ -68,37 +68,37 @@ static void add_gaim_buddies_in_groups(J
- }
-
- while(buddies) {
-- GaimBuddy *b = buddies->data;
-- GaimGroup *g = gaim_buddy_get_group(b);
-+ Gaim2Buddy *b = buddies->data;
-+ Gaim2Group *g = gaim2_buddy_get_group(b);
-
- buddies = g_slist_remove(buddies, b);
-
- if((l = g_slist_find_custom(g2, g->name, (GCompareFunc)strcmp))) {
- const char *servernick;
-
-- if((servernick = gaim_blist_node_get_string((GaimBlistNode*)b, "servernick")))
-+ if((servernick = gaim2_blist_node_get_string((Gaim2BlistNode*)b, "servernick")))
- serv_got_alias(js->gc, jid, servernick);
-
- if(alias && (!b->alias || strcmp(b->alias, alias)))
-- gaim_blist_alias_buddy(b, alias);
-+ gaim2_blist_alias_buddy(b, alias);
- g_free(l->data);
- g2 = g_slist_delete_link(g2, l);
- } else {
-- gaim_blist_remove_buddy(b);
-+ gaim2_blist_remove_buddy(b);
- }
- }
-
- while(g2) {
-- GaimBuddy *b = gaim_buddy_new(js->gc->account, jid, alias);
-- GaimGroup *g = gaim_find_group(g2->data);
-+ Gaim2Buddy *b = gaim2_buddy_new(js->gc->account, jid, alias);
-+ Gaim2Group *g = gaim2_find_group(g2->data);
-
- if(!g) {
-- g = gaim_group_new(g2->data);
-- gaim_blist_add_group(g, NULL);
-+ g = gaim2_group_new(g2->data);
-+ gaim2_blist_add_group(g, NULL);
- }
-
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-- gaim_blist_alias_buddy(b, alias);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
-+ gaim2_blist_alias_buddy(b, alias);
- g_free(g2->data);
- g2 = g_slist_delete_link(g2, g2);
- }
-@@ -122,7 +122,7 @@ void jabber_roster_parse(JabberStream *j
-
- invalid = g_utf8_collate(from_norm,
- jabber_normalize(js->gc->account,
-- gaim_account_get_username(js->gc->account)));
-+ gaim2_account_get_username(js->gc->account)));
-
- g_free(from_norm);
-
-@@ -158,7 +158,7 @@ void jabber_roster_parse(JabberStream *j
- const char *username;
-
- jid_norm = g_strdup(jabber_normalize(js->gc->account, jid));
-- username = gaim_account_get_username(js->gc->account);
-+ username = gaim2_account_get_username(js->gc->account);
- me = g_utf8_collate(jid_norm,
- jabber_normalize(js->gc->account,
- username));
-@@ -183,7 +183,7 @@ void jabber_roster_parse(JabberStream *j
- /*
- if ((jb->subscription & JABBER_SUB_FROM) ||
- (jb->subscription & JABBER_SUB_NONE)) {
-- gaim_prpl_got_user_status(js->gc->account, jid, "offline", NULL);
-+ gaim2_prpl_got_user_status(js->gc->account, jid, "offline", NULL);
- }
- */
- }
-@@ -194,7 +194,7 @@ void jabber_roster_parse(JabberStream *j
- jb->subscription &= ~JABBER_SUB_PENDING;
-
- if(jb->subscription == JABBER_SUB_REMOVE) {
-- remove_gaim_buddies(js, jid);
-+ remove_gaim2_buddies(js, jid);
- } else {
- GSList *groups = NULL;
- for(group = xmlnode_get_child(item, "group"); group; group = xmlnode_get_next_twin(group)) {
-@@ -204,7 +204,7 @@ void jabber_roster_parse(JabberStream *j
- group_name = g_strdup("");
- groups = g_slist_append(groups, group_name);
- }
-- add_gaim_buddies_in_groups(js, jid, name, groups);
-+ add_gaim2_buddies_in_groups(js, jid, name, groups);
- }
- }
- }
-@@ -212,8 +212,8 @@ void jabber_roster_parse(JabberStream *j
- static void jabber_roster_update(JabberStream *js, const char *name,
- GSList *grps)
- {
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
- GSList *groups = NULL, *l;
- JabberIq *iq;
- xmlnode *query, *item, *group;
-@@ -221,18 +221,18 @@ static void jabber_roster_update(JabberS
- if(grps) {
- groups = grps;
- } else {
-- GSList *buddies = gaim_find_buddies(js->gc->account, name);
-+ GSList *buddies = gaim2_find_buddies(js->gc->account, name);
- if(!buddies)
- return;
- while(buddies) {
- b = buddies->data;
-- g = gaim_buddy_get_group(b);
-+ g = gaim2_buddy_get_group(b);
- groups = g_slist_append(groups, g->name);
- buddies = g_slist_remove(buddies, b);
- }
- }
-
-- if(!(b = gaim_find_buddy(js->gc->account, name)))
-+ if(!(b = gaim2_find_buddy(js->gc->account, name)))
- return;
-
- iq = jabber_iq_new_query(js, JABBER_IQ_SET, "jabber:iq:roster");
-@@ -256,8 +256,8 @@ static void jabber_roster_update(JabberS
- jabber_iq_send(iq);
- }
-
--void jabber_roster_add_buddy(GaimConnection *gc, GaimBuddy *buddy,
-- GaimGroup *group)
-+void jabber_roster_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy,
-+ Gaim2Group *group)
- {
- JabberStream *js = gc->proto_data;
- char *who;
-@@ -282,16 +282,16 @@ void jabber_roster_add_buddy(GaimConnect
-
- my_bare_jid = g_strdup_printf("%s@%s", js->user->node, js->user->domain);
- if(!strcmp(who, my_bare_jid)) {
-- GaimPresence *gpresence;
-- GaimStatus *status;
-+ Gaim2Presence *gpresence;
-+ Gaim2Status *status;
-
-- gpresence = gaim_account_get_presence(js->gc->account);
-- status = gaim_presence_get_active_status(gpresence);
-+ gpresence = gaim2_account_get_presence(js->gc->account);
-+ status = gaim2_presence_get_active_status(gpresence);
- jabber_presence_fake_to_self(js, status);
- } else if(!jb || !(jb->subscription & JABBER_SUB_TO)) {
- jabber_presence_subscription_set(js, who, "subscribe");
- } else if((jbr =jabber_buddy_find_resource(jb, NULL))) {
-- gaim_prpl_got_user_status(gc->account, who,
-+ gaim2_prpl_got_user_status(gc->account, who,
- jabber_buddy_state_get_status_id(jbr->state),
- "priority", jbr->priority, jbr->status ? "message" : NULL, jbr->status, NULL);
- }
-@@ -300,32 +300,32 @@ void jabber_roster_add_buddy(GaimConnect
- g_free(who);
- }
-
--void jabber_roster_alias_change(GaimConnection *gc, const char *name, const char *alias)
-+void jabber_roster_alias_change(Gaim2Connection *gc, const char *name, const char *alias)
- {
-- GaimBuddy *b = gaim_find_buddy(gc->account, name);
-+ Gaim2Buddy *b = gaim2_find_buddy(gc->account, name);
- char *a;
-
- a = g_strdup(alias);
-- gaim_blist_alias_buddy(b, a);
-+ gaim2_blist_alias_buddy(b, a);
- g_free(a);
-
- jabber_roster_update(gc->proto_data, name, NULL);
- }
-
--void jabber_roster_group_change(GaimConnection *gc, const char *name,
-+void jabber_roster_group_change(Gaim2Connection *gc, const char *name,
- const char *old_group, const char *new_group)
- {
- GSList *buddies, *groups = NULL;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
-
- if(!old_group || !new_group || !strcmp(old_group, new_group))
- return;
-
-- buddies = gaim_find_buddies(gc->account, name);
-+ buddies = gaim2_find_buddies(gc->account, name);
- while(buddies) {
- b = buddies->data;
-- g = gaim_buddy_get_group(b);
-+ g = gaim2_buddy_get_group(b);
- if(!strcmp(g->name, old_group))
- groups = g_slist_append(groups, (char*)new_group); /* ick */
- else
-@@ -336,29 +336,29 @@ void jabber_roster_group_change(GaimConn
- g_slist_free(groups);
- }
-
--void jabber_roster_group_rename(GaimConnection *gc, const char *old_name,
-- GaimGroup *group, GList *moved_buddies)
-+void jabber_roster_group_rename(Gaim2Connection *gc, const char *old_name,
-+ Gaim2Group *group, GList *moved_buddies)
- {
- GList *l;
- for(l = moved_buddies; l; l = l->next) {
-- GaimBuddy *buddy = l->data;
-+ Gaim2Buddy *buddy = l->data;
- jabber_roster_group_change(gc, buddy->name, old_name, group->name);
- }
- }
-
--void jabber_roster_remove_buddy(GaimConnection *gc, GaimBuddy *buddy,
-- GaimGroup *group) {
-- GSList *buddies = gaim_find_buddies(gc->account, buddy->name);
-+void jabber_roster_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy,
-+ Gaim2Group *group) {
-+ GSList *buddies = gaim2_find_buddies(gc->account, buddy->name);
- GSList *groups = NULL;
-
- buddies = g_slist_remove(buddies, buddy);
- if(g_slist_length(buddies)) {
-- GaimBuddy *tmpbuddy;
-- GaimGroup *tmpgroup;
-+ Gaim2Buddy *tmpbuddy;
-+ Gaim2Group *tmpgroup;
-
- while(buddies) {
- tmpbuddy = buddies->data;
-- tmpgroup = gaim_buddy_get_group(tmpbuddy);
-+ tmpgroup = gaim2_buddy_get_group(tmpbuddy);
- groups = g_slist_append(groups, tmpgroup->name);
- buddies = g_slist_remove(buddies, tmpbuddy);
- }
-diff -prNu ./src/protocols/jabber/roster.h ./src/protocols/jabber/roster.h
---- ./src/protocols/jabber/roster.h 2004-06-15 04:37:25.000000000 +0200
-+++ ./src/protocols/jabber/roster.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file roster.h Roster manipulation
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -28,15 +28,15 @@ void jabber_roster_request(JabberStream
-
- void jabber_roster_parse(JabberStream *js, xmlnode *packet);
-
--void jabber_roster_add_buddy(GaimConnection *gc, GaimBuddy *buddy,
-- GaimGroup *group);
--void jabber_roster_alias_change(GaimConnection *gc, const char *name,
-+void jabber_roster_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy,
-+ Gaim2Group *group);
-+void jabber_roster_alias_change(Gaim2Connection *gc, const char *name,
- const char *alias);
--void jabber_roster_group_change(GaimConnection *gc, const char *name,
-+void jabber_roster_group_change(Gaim2Connection *gc, const char *name,
- const char *old_group, const char *new_group);
--void jabber_roster_group_rename(GaimConnection *gc, const char *old_name,
-- GaimGroup *group, GList *moved_buddies);
--void jabber_roster_remove_buddy(GaimConnection *gc, GaimBuddy *buddy,
-- GaimGroup *group);
-+void jabber_roster_group_rename(Gaim2Connection *gc, const char *old_name,
-+ Gaim2Group *group, GList *moved_buddies);
-+void jabber_roster_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy,
-+ Gaim2Group *group);
-
- #endif /* _GAIM_JABBER_ROSTER_H_ */
-diff -prNu ./src/protocols/jabber/si.c ./src/protocols/jabber/si.c
---- ./src/protocols/jabber/si.c 2006-01-05 06:04:06.000000000 +0100
-+++ ./src/protocols/jabber/si.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -58,13 +58,13 @@ typedef struct _JabberSIXfer {
- } stream_method;
-
- GList *streamhosts;
-- GaimProxyInfo *gpi;
-+ Gaim2ProxyInfo *gpi;
-
- char *rxqueue;
- size_t rxlen;
- } JabberSIXfer;
-
--static GaimXfer*
-+static Gaim2Xfer*
- jabber_si_xfer_find(JabberStream *js, const char *sid, const char *from)
- {
- GList *xfers;
-@@ -73,7 +73,7 @@ jabber_si_xfer_find(JabberStream *js, co
- return NULL;
-
- for(xfers = js->file_transfers; xfers; xfers = xfers->next) {
-- GaimXfer *xfer = xfers->data;
-+ Gaim2Xfer *xfer = xfers->data;
- JabberSIXfer *jsx = xfer->data;
- if(jsx->stream_id && xfer->who &&
- !strcmp(jsx->stream_id, sid) && !strcmp(xfer->who, from))
-@@ -84,17 +84,17 @@ jabber_si_xfer_find(JabberStream *js, co
- }
-
-
--static void jabber_si_bytestreams_attempt_connect(GaimXfer *xfer);
-+static void jabber_si_bytestreams_attempt_connect(Gaim2Xfer *xfer);
-
--static void jabber_si_bytestreams_connect_cb(gpointer data, gint source, GaimInputCondition cond)
-+static void jabber_si_bytestreams_connect_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
- JabberSIXfer *jsx = xfer->data;
- JabberIq *iq;
- xmlnode *query, *su;
- struct bytestreams_streamhost *streamhost = jsx->streamhosts->data;
-
-- gaim_proxy_info_destroy(jsx->gpi);
-+ gaim2_proxy_info_destroy(jsx->gpi);
-
- if(source < 0) {
- jsx->streamhosts = g_list_remove(jsx->streamhosts, streamhost);
-@@ -114,10 +114,10 @@ static void jabber_si_bytestreams_connec
-
- jabber_iq_send(iq);
-
-- gaim_xfer_start(xfer, source, NULL, -1);
-+ gaim2_xfer_start(xfer, source, NULL, -1);
- }
-
--static void jabber_si_bytestreams_attempt_connect(GaimXfer *xfer)
-+static void jabber_si_bytestreams_attempt_connect(Gaim2Xfer *xfer)
- {
- JabberSIXfer *jsx = xfer->data;
- struct bytestreams_streamhost *streamhost;
-@@ -142,22 +142,22 @@ static void jabber_si_bytestreams_attemp
-
- jabber_iq_send(iq);
-
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
-
- return;
- }
-
- streamhost = jsx->streamhosts->data;
-
-- jsx->gpi = gaim_proxy_info_new();
-- gaim_proxy_info_set_type(jsx->gpi, GAIM_PROXY_SOCKS5);
-- gaim_proxy_info_set_host(jsx->gpi, streamhost->host);
-- gaim_proxy_info_set_port(jsx->gpi, streamhost->port);
-+ jsx->gpi = gaim2_proxy_info_new();
-+ gaim2_proxy_info_set_type(jsx->gpi, GAIM_PROXY_SOCKS5);
-+ gaim2_proxy_info_set_host(jsx->gpi, streamhost->host);
-+ gaim2_proxy_info_set_port(jsx->gpi, streamhost->port);
-
- dstaddr = g_strdup_printf("%s%s%s@%s/%s", jsx->stream_id, xfer->who, jsx->js->user->node,
- jsx->js->user->domain, jsx->js->user->resource);
-
-- gaim_cipher_digest_region("sha1", (guchar *)dstaddr, strlen(dstaddr),
-+ gaim2_cipher_digest_region("sha1", (guchar *)dstaddr, strlen(dstaddr),
- sizeof(hashval), hashval, NULL);
- g_free(dstaddr);
- dstaddr = g_malloc(41);
-@@ -165,13 +165,13 @@ static void jabber_si_bytestreams_attemp
- for(i=0; i<20; i++, p+=2)
- snprintf(p, 3, "%02x", hashval[i]);
-
-- gaim_proxy_connect_socks5(jsx->gpi, dstaddr, 0, jabber_si_bytestreams_connect_cb, xfer);
-+ gaim2_proxy_connect_socks5(jsx->gpi, dstaddr, 0, jabber_si_bytestreams_connect_cb, xfer);
- g_free(dstaddr);
- }
-
- void jabber_bytestreams_parse(JabberStream *js, xmlnode *packet)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- JabberSIXfer *jsx;
- xmlnode *query, *streamhost;
- const char *sid, *from;
-@@ -219,9 +219,9 @@ void jabber_bytestreams_parse(JabberStre
-
- static void
- jabber_si_xfer_bytestreams_send_read_again_cb(gpointer data, gint source,
-- GaimInputCondition cond)
-+ Gaim2InputCondition cond)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
- JabberSIXfer *jsx = xfer->data;
- int i;
- char buffer[256];
-@@ -230,15 +230,15 @@ jabber_si_xfer_bytestreams_send_read_aga
- unsigned char hashval[20];
- const char *host;
-
-- gaim_debug_info("jabber", "in jabber_si_xfer_bytestreams_send_read_again_cb\n");
-+ gaim2_debug_info("jabber", "in jabber_si_xfer_bytestreams_send_read_again_cb\n");
-
- if(jsx->rxlen < 5) {
-- gaim_debug_info("jabber", "reading the first 5 bytes\n");
-+ gaim2_debug_info("jabber", "reading the first 5 bytes\n");
- if((len = read(source, buffer, 5 - jsx->rxlen)) <= 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
- jsx->rxqueue = g_realloc(jsx->rxqueue, len + jsx->rxlen);
-@@ -247,19 +247,19 @@ jabber_si_xfer_bytestreams_send_read_aga
- return;
- } else if(jsx->rxqueue[0] != 0x05 || jsx->rxqueue[1] != 0x01 ||
- jsx->rxqueue[3] != 0x03) {
-- gaim_debug_info("jabber", "invalid socks5 stuff\n");
-- gaim_input_remove(xfer->watcher);
-+ gaim2_debug_info("jabber", "invalid socks5 stuff\n");
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- } else if(jsx->rxlen - 5 < jsx->rxqueue[4] + 2) {
-- gaim_debug_info("jabber", "reading umpteen more bytes\n");
-+ gaim2_debug_info("jabber", "reading umpteen more bytes\n");
- if((len = read(source, buffer, jsx->rxqueue[4] + 5 + 2 - jsx->rxlen)) <= 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
- jsx->rxqueue = g_realloc(jsx->rxqueue, len + jsx->rxlen);
-@@ -270,14 +270,14 @@ jabber_si_xfer_bytestreams_send_read_aga
- if(jsx->rxlen - 5 < jsx->rxqueue[4] + 2)
- return;
-
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
-
- dstaddr = g_strdup_printf("%s%s@%s/%s%s", jsx->stream_id,
- jsx->js->user->node, jsx->js->user->domain,
- jsx->js->user->resource, xfer->who);
-
-- gaim_cipher_digest_region("sha1", (guchar *)dstaddr, strlen(dstaddr),
-+ gaim2_cipher_digest_region("sha1", (guchar *)dstaddr, strlen(dstaddr),
- sizeof(hashval), hashval, NULL);
- g_free(dstaddr);
- dstaddr = g_malloc(41);
-@@ -287,13 +287,13 @@ jabber_si_xfer_bytestreams_send_read_aga
-
- if(jsx->rxqueue[4] != 40 || strncmp(dstaddr, jsx->rxqueue+5, 40) ||
- jsx->rxqueue[45] != 0x00 || jsx->rxqueue[46] != 0x00) {
-- gaim_debug_error("jabber", "someone connected with the wrong info!\n");
-+ gaim2_debug_error("jabber", "someone connected with the wrong info!\n");
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
-- host = gaim_network_get_my_ip(jsx->js->fd);
-+ host = gaim2_network_get_my_ip(jsx->js->fd);
-
- buffer[0] = 0x05;
- buffer[1] = 0x00;
-@@ -306,30 +306,30 @@ jabber_si_xfer_bytestreams_send_read_aga
-
- write(source, buffer, strlen(host)+7);
-
-- gaim_xfer_start(xfer, source, NULL, -1);
-+ gaim2_xfer_start(xfer, source, NULL, -1);
- }
-
- static void
- jabber_si_xfer_bytestreams_send_read_cb(gpointer data, gint source,
-- GaimInputCondition cond)
-+ Gaim2InputCondition cond)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
- JabberSIXfer *jsx = xfer->data;
- int i;
- int len;
- char buffer[256];
-
-- gaim_debug_info("jabber", "in jabber_si_xfer_bytestreams_send_read_cb\n");
-+ gaim2_debug_info("jabber", "in jabber_si_xfer_bytestreams_send_read_cb\n");
-
- xfer->fd = source;
-
- if(jsx->rxlen < 2) {
-- gaim_debug_info("jabber", "reading those first two bytes\n");
-+ gaim2_debug_info("jabber", "reading those first two bytes\n");
- if((len = read(source, buffer, 2 - jsx->rxlen)) <= 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
- jsx->rxqueue = g_realloc(jsx->rxqueue, len + jsx->rxlen);
-@@ -337,12 +337,12 @@ jabber_si_xfer_bytestreams_send_read_cb(
- jsx->rxlen += len;
- return;
- } else if(jsx->rxlen - 2 < jsx->rxqueue[1]) {
-- gaim_debug_info("jabber", "reading the next umpteen bytes\n");
-+ gaim2_debug_info("jabber", "reading the next umpteen bytes\n");
- if((len = read(source, buffer, jsx->rxqueue[1] + 2 - jsx->rxlen)) <= 0) {
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
- jsx->rxqueue = g_realloc(jsx->rxqueue, len + jsx->rxlen);
-@@ -353,28 +353,28 @@ jabber_si_xfer_bytestreams_send_read_cb(
- if(jsx->rxlen -2 < jsx->rxqueue[1])
- return;
-
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
-
-
-- gaim_debug_info("jabber", "checking to make sure we're socks FIVE\n");
-+ gaim2_debug_info("jabber", "checking to make sure we're socks FIVE\n");
-
- if(jsx->rxqueue[0] != 0x05) {
- close(source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
-- gaim_debug_info("jabber", "going to test %hhu different methods\n", jsx->rxqueue[1]);
-+ gaim2_debug_info("jabber", "going to test %hhu different methods\n", jsx->rxqueue[1]);
-
- for(i=0; i<jsx->rxqueue[1]; i++) {
-
-- gaim_debug_info("jabber", "testing %hhu\n", jsx->rxqueue[i+2]);
-+ gaim2_debug_info("jabber", "testing %hhu\n", jsx->rxqueue[i+2]);
- if(jsx->rxqueue[i+2] == 0x00) {
- buffer[0] = 0x05;
- buffer[1] = 0x00;
- write(source, buffer, 2);
-- xfer->watcher = gaim_input_add(source, GAIM_INPUT_READ,
-+ xfer->watcher = gaim2_input_add(source, GAIM_INPUT_READ,
- jabber_si_xfer_bytestreams_send_read_again_cb, xfer);
- g_free(jsx->rxqueue);
- jsx->rxqueue = NULL;
-@@ -390,33 +390,33 @@ jabber_si_xfer_bytestreams_send_read_cb(
- g_free(jsx->rxqueue);
- jsx->rxqueue = NULL;
- jsx->rxlen = 0;
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- }
-
- static void
- jabber_si_xfer_bytestreams_send_connected_cb(gpointer data, gint source,
-- GaimInputCondition cond)
-+ Gaim2InputCondition cond)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
- int acceptfd;
-
-- gaim_debug_info("jabber", "in jabber_si_xfer_bytestreams_send_connected_cb\n");
-+ gaim2_debug_info("jabber", "in jabber_si_xfer_bytestreams_send_connected_cb\n");
-
- if((acceptfd = accept(source, NULL, 0)) == -1) {
-- gaim_debug_warning("jabber", "accept: %s\n", strerror(errno));
-+ gaim2_debug_warning("jabber", "accept: %s\n", strerror(errno));
- return;
- }
-
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- close(source);
-
-- xfer->watcher = gaim_input_add(acceptfd, GAIM_INPUT_READ,
-+ xfer->watcher = gaim2_input_add(acceptfd, GAIM_INPUT_READ,
- jabber_si_xfer_bytestreams_send_read_cb, xfer);
- }
-
-
- static void
--jabber_si_xfer_bytestreams_send_init(GaimXfer *xfer)
-+jabber_si_xfer_bytestreams_send_init(Gaim2Xfer *xfer)
- {
- JabberSIXfer *jsx = xfer->data;
- JabberIq *iq;
-@@ -436,18 +436,18 @@ jabber_si_xfer_bytestreams_send_init(Gai
- xmlnode_set_attrib(streamhost, "jid", jid);
- g_free(jid);
-
-- if((fd = gaim_network_listen_range(0, 0, SOCK_STREAM)) < 0) {
-+ if((fd = gaim2_network_listen_range(0, 0, SOCK_STREAM)) < 0) {
- /* XXX: couldn't open a port, we're fscked */
- return;
- }
-
-- xmlnode_set_attrib(streamhost, "host", gaim_network_get_my_ip(jsx->js->fd));
-- xfer->local_port = gaim_network_get_port_from_fd(fd);
-+ xmlnode_set_attrib(streamhost, "host", gaim2_network_get_my_ip(jsx->js->fd));
-+ xfer->local_port = gaim2_network_get_port_from_fd(fd);
- port = g_strdup_printf("%hu", xfer->local_port);
- xmlnode_set_attrib(streamhost, "port", port);
- g_free(port);
-
-- xfer->watcher = gaim_input_add(fd, GAIM_INPUT_READ,
-+ xfer->watcher = gaim2_input_add(fd, GAIM_INPUT_READ,
- jabber_si_xfer_bytestreams_send_connected_cb, xfer);
-
- /* XXX: insert proxies here */
-@@ -460,21 +460,21 @@ jabber_si_xfer_bytestreams_send_init(Gai
- static void jabber_si_xfer_send_method_cb(JabberStream *js, xmlnode *packet,
- gpointer data)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
- xmlnode *si, *feature, *x, *field, *value;
-
- if(!(si = xmlnode_get_child_with_namespace(packet, "si", "http://jabber.org/protocol/si"))) {
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
- if(!(feature = xmlnode_get_child_with_namespace(si, "feature", "http://jabber.org/protocol/feature-neg"))) {
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
- if(!(x = xmlnode_get_child_with_namespace(feature, "x", "jabber:x:data"))) {
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
-@@ -493,10 +493,10 @@ static void jabber_si_xfer_send_method_c
- }
- }
- }
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- }
-
--static void jabber_si_xfer_send_request(GaimXfer *xfer)
-+static void jabber_si_xfer_send_request(Gaim2Xfer *xfer)
- {
- JabberSIXfer *jsx = xfer->data;
- JabberIq *iq;
-@@ -546,7 +546,7 @@ static void jabber_si_xfer_send_request(
- jabber_iq_send(iq);
- }
-
--static void jabber_si_xfer_free(GaimXfer *xfer)
-+static void jabber_si_xfer_free(Gaim2Xfer *xfer)
- {
- JabberSIXfer *jsx = xfer->data;
- JabberStream *js = jsx->js;
-@@ -560,21 +560,21 @@ static void jabber_si_xfer_free(GaimXfer
- xfer->data = NULL;
- }
-
--static void jabber_si_xfer_cancel_send(GaimXfer *xfer)
-+static void jabber_si_xfer_cancel_send(Gaim2Xfer *xfer)
- {
- jabber_si_xfer_free(xfer);
-- gaim_debug(GAIM_DEBUG_INFO, "jabber", "in jabber_si_xfer_cancel_send\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber", "in jabber_si_xfer_cancel_send\n");
- }
-
-
--static void jabber_si_xfer_cancel_recv(GaimXfer *xfer)
-+static void jabber_si_xfer_cancel_recv(Gaim2Xfer *xfer)
- {
- jabber_si_xfer_free(xfer);
-- gaim_debug(GAIM_DEBUG_INFO, "jabber", "in jabber_si_xfer_cancel_recv\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "jabber", "in jabber_si_xfer_cancel_recv\n");
- }
-
-
--static void jabber_si_xfer_end(GaimXfer *xfer)
-+static void jabber_si_xfer_end(Gaim2Xfer *xfer)
- {
- jabber_si_xfer_free(xfer);
- }
-@@ -583,23 +583,23 @@ static void jabber_si_xfer_end(GaimXfer
- static void jabber_si_xfer_send_disco_cb(JabberStream *js, const char *who,
- JabberCapabilities capabilities, gpointer data)
- {
-- GaimXfer *xfer = data;
-+ Gaim2Xfer *xfer = data;
-
- if(capabilities & JABBER_CAP_SI_FILE_XFER) {
- jabber_si_xfer_send_request(xfer);
- } else {
- char *msg = g_strdup_printf(_("Unable to send file to %s, user does not support file transfers"), who);
-- gaim_notify_error(js->gc, _("File Send Failed"),
-+ gaim2_notify_error(js->gc, _("File Send Failed"),
- _("File Send Failed"), msg);
- g_free(msg);
- }
- }
-
--static void jabber_si_xfer_init(GaimXfer *xfer)
-+static void jabber_si_xfer_init(Gaim2Xfer *xfer)
- {
- JabberSIXfer *jsx = xfer->data;
- JabberIq *iq;
-- if(gaim_xfer_get_type(xfer) == GAIM_XFER_SEND) {
-+ if(gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND) {
- JabberBuddy *jb;
- JabberBuddyResource *jbr = NULL;
-
-@@ -655,52 +655,52 @@ static void jabber_si_xfer_init(GaimXfer
- }
- }
-
--GaimXfer *jabber_si_new_xfer(GaimConnection *gc, const char *who)
-+Gaim2Xfer *jabber_si_new_xfer(Gaim2Connection *gc, const char *who)
- {
- JabberStream *js;
-
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- JabberSIXfer *jsx;
-
- js = gc->proto_data;
-
-- xfer = gaim_xfer_new(gc->account, GAIM_XFER_SEND, who);
-+ xfer = gaim2_xfer_new(gc->account, GAIM_XFER_SEND, who);
-
- xfer->data = jsx = g_new0(JabberSIXfer, 1);
- jsx->js = js;
-
-- gaim_xfer_set_init_fnc(xfer, jabber_si_xfer_init);
-- gaim_xfer_set_cancel_send_fnc(xfer, jabber_si_xfer_cancel_send);
-- gaim_xfer_set_end_fnc(xfer, jabber_si_xfer_end);
-+ gaim2_xfer_set_init_fnc(xfer, jabber_si_xfer_init);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, jabber_si_xfer_cancel_send);
-+ gaim2_xfer_set_end_fnc(xfer, jabber_si_xfer_end);
-
- js->file_transfers = g_list_append(js->file_transfers, xfer);
-
- return xfer;
- }
-
--void jabber_si_xfer_send(GaimConnection *gc, const char *who, const char *file)
-+void jabber_si_xfer_send(Gaim2Connection *gc, const char *who, const char *file)
- {
- JabberStream *js;
-
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- js = gc->proto_data;
-
-- if(!gaim_find_buddy(gc->account, who) || !jabber_buddy_find(js, who, FALSE))
-+ if(!gaim2_find_buddy(gc->account, who) || !jabber_buddy_find(js, who, FALSE))
- return;
-
- xfer = jabber_si_new_xfer(gc, who);
-
- if (file)
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
- else
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
- void jabber_si_parse(JabberStream *js, xmlnode *packet)
- {
- JabberSIXfer *jsx;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- xmlnode *si, *file, *feature, *x, *field, *option, *value;
- const char *stream_id, *filename, *filesize_c, *profile, *from;
- size_t filesize = 0;
-@@ -772,20 +772,20 @@ void jabber_si_parse(JabberStream *js, x
- jsx->stream_id = g_strdup(stream_id);
- jsx->iq_id = g_strdup(xmlnode_get_attrib(packet, "id"));
-
-- xfer = gaim_xfer_new(js->gc->account, GAIM_XFER_RECEIVE, from);
-+ xfer = gaim2_xfer_new(js->gc->account, GAIM_XFER_RECEIVE, from);
- xfer->data = jsx;
-
-- gaim_xfer_set_filename(xfer, filename);
-+ gaim2_xfer_set_filename(xfer, filename);
- if(filesize > 0)
-- gaim_xfer_set_size(xfer, filesize);
-+ gaim2_xfer_set_size(xfer, filesize);
-
-- gaim_xfer_set_init_fnc(xfer, jabber_si_xfer_init);
-- gaim_xfer_set_cancel_recv_fnc(xfer, jabber_si_xfer_cancel_recv);
-- gaim_xfer_set_end_fnc(xfer, jabber_si_xfer_end);
-+ gaim2_xfer_set_init_fnc(xfer, jabber_si_xfer_init);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, jabber_si_xfer_cancel_recv);
-+ gaim2_xfer_set_end_fnc(xfer, jabber_si_xfer_end);
-
- js->file_transfers = g_list_append(js->file_transfers, xfer);
-
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
-
-diff -prNu ./src/protocols/jabber/si.h ./src/protocols/jabber/si.h
---- ./src/protocols/jabber/si.h 2005-11-19 01:26:12.000000000 +0100
-+++ ./src/protocols/jabber/si.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file jutil.h utility functions
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-@@ -28,7 +28,7 @@
-
- void jabber_bytestreams_parse(JabberStream *js, xmlnode *packet);
- void jabber_si_parse(JabberStream *js, xmlnode *packet);
--GaimXfer *jabber_si_new_xfer(GaimConnection *gc, const char *who);
--void jabber_si_xfer_send(GaimConnection *gc, const char *who, const char *file);
-+Gaim2Xfer *jabber_si_new_xfer(Gaim2Connection *gc, const char *who);
-+void jabber_si_xfer_send(Gaim2Connection *gc, const char *who, const char *file);
-
- #endif /* _GAIM_JABBER_SI_H_ */
-diff -prNu ./src/protocols/jabber/xdata.c ./src/protocols/jabber/xdata.c
---- ./src/protocols/jabber/xdata.c 2004-03-04 18:07:56.000000000 +0100
-+++ ./src/protocols/jabber/xdata.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Jabber Protocol Plugin
-+ * gaim2 - Jabber Protocol Plugin
- *
- * Copyright (C) 2003, Nathan Walp <faceprint@faceprint.com>
- *
-@@ -42,7 +42,7 @@ struct jabber_x_data_data {
- JabberStream *js;
- };
-
--static void jabber_x_data_ok_cb(struct jabber_x_data_data *data, GaimRequestFields *fields) {
-+static void jabber_x_data_ok_cb(struct jabber_x_data_data *data, Gaim2RequestFields *fields) {
- xmlnode *result = xmlnode_new("x");
- jabber_x_data_cb cb = data->cb;
- gpointer user_data = data->user_data;
-@@ -52,18 +52,18 @@ static void jabber_x_data_ok_cb(struct j
- xmlnode_set_attrib(result, "xmlns", "jabber:x:data");
- xmlnode_set_attrib(result, "type", "submit");
-
-- for(groups = gaim_request_fields_get_groups(fields); groups; groups = groups->next) {
-- for(flds = gaim_request_field_group_get_fields(groups->data); flds; flds = flds->next) {
-+ for(groups = gaim2_request_fields_get_groups(fields); groups; groups = groups->next) {
-+ for(flds = gaim2_request_field_group_get_fields(groups->data); flds; flds = flds->next) {
- xmlnode *fieldnode, *valuenode;
-- GaimRequestField *field = flds->data;
-- const char *id = gaim_request_field_get_id(field);
-+ Gaim2RequestField *field = flds->data;
-+ const char *id = gaim2_request_field_get_id(field);
- jabber_x_data_field_type type = GPOINTER_TO_INT(g_hash_table_lookup(data->fields, id));
-
- switch(type) {
- case JABBER_X_DATA_TEXT_SINGLE:
- case JABBER_X_DATA_JID_SINGLE:
- {
-- const char *value = gaim_request_field_string_get_value(field);
-+ const char *value = gaim2_request_field_string_get_value(field);
- fieldnode = xmlnode_new_child(result, "field");
- xmlnode_set_attrib(fieldnode, "var", id);
- valuenode = xmlnode_new_child(fieldnode, "value");
-@@ -74,7 +74,7 @@ static void jabber_x_data_ok_cb(struct j
- case JABBER_X_DATA_TEXT_MULTI:
- {
- char **pieces, **p;
-- const char *value = gaim_request_field_string_get_value(field);
-+ const char *value = gaim2_request_field_string_get_value(field);
- fieldnode = xmlnode_new_child(result, "field");
- xmlnode_set_attrib(fieldnode, "var", id);
-
-@@ -89,13 +89,13 @@ static void jabber_x_data_ok_cb(struct j
- case JABBER_X_DATA_LIST_SINGLE:
- case JABBER_X_DATA_LIST_MULTI:
- {
-- const GList *selected = gaim_request_field_list_get_selected(field);
-+ const GList *selected = gaim2_request_field_list_get_selected(field);
- char *value;
- fieldnode = xmlnode_new_child(result, "field");
- xmlnode_set_attrib(fieldnode, "var", id);
-
- while(selected) {
-- value = gaim_request_field_list_get_data(field, selected->data);
-+ value = gaim2_request_field_list_get_data(field, selected->data);
- valuenode = xmlnode_new_child(fieldnode, "value");
- if(value)
- xmlnode_insert_data(valuenode, value, -1);
-@@ -107,7 +107,7 @@ static void jabber_x_data_ok_cb(struct j
- fieldnode = xmlnode_new_child(result, "field");
- xmlnode_set_attrib(fieldnode, "var", id);
- valuenode = xmlnode_new_child(fieldnode, "value");
-- if(gaim_request_field_bool_get_value(field))
-+ if(gaim2_request_field_bool_get_value(field))
- xmlnode_insert_data(valuenode, "1", -1);
- else
- xmlnode_insert_data(valuenode, "0", -1);
-@@ -128,7 +128,7 @@ static void jabber_x_data_ok_cb(struct j
- cb(js, result, user_data);
- }
-
--static void jabber_x_data_cancel_cb(struct jabber_x_data_data *data, GaimRequestFields *fields) {
-+static void jabber_x_data_cancel_cb(struct jabber_x_data_data *data, Gaim2RequestFields *fields) {
- xmlnode *result = xmlnode_new("x");
- jabber_x_data_cb cb = data->cb;
- gpointer user_data = data->user_data;
-@@ -150,9 +150,9 @@ void *jabber_x_data_request(JabberStream
- {
- void *handle;
- xmlnode *fn, *x;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *group;
-- GaimRequestField *field;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *group;
-+ Gaim2RequestField *field;
-
- char *title = NULL;
- char *instructions = NULL;
-@@ -164,9 +164,9 @@ void *jabber_x_data_request(JabberStream
- data->cb = cb;
- data->js = js;
-
-- fields = gaim_request_fields_new();
-- group = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, group);
-+ fields = gaim2_request_fields_new();
-+ group = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, group);
-
- for(fn = xmlnode_get_child(packet, "field"); fn; fn = xmlnode_get_next_twin(fn)) {
- xmlnode *valuenode;
-@@ -193,10 +193,10 @@ void *jabber_x_data_request(JabberStream
- if((valuenode = xmlnode_get_child(fn, "value")))
- value = xmlnode_get_data(valuenode);
-
-- field = gaim_request_field_string_new(var, label,
-+ field = gaim2_request_field_string_new(var, label,
- value ? value : "", FALSE);
-- gaim_request_field_string_set_masked(field, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_string_set_masked(field, TRUE);
-+ gaim2_request_field_group_add_field(group, field);
-
- g_hash_table_replace(data->fields, g_strdup(var), GINT_TO_POINTER(JABBER_X_DATA_TEXT_SINGLE));
-
-@@ -215,9 +215,9 @@ void *jabber_x_data_request(JabberStream
- g_free(value);
- }
-
-- field = gaim_request_field_string_new(var, label,
-+ field = gaim2_request_field_string_new(var, label,
- str->str, TRUE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
- g_hash_table_replace(data->fields, g_strdup(var), GINT_TO_POINTER(JABBER_X_DATA_TEXT_MULTI));
-
-@@ -226,10 +226,10 @@ void *jabber_x_data_request(JabberStream
- xmlnode *optnode;
- GList *selected = NULL;
-
-- field = gaim_request_field_list_new(var, label);
-+ field = gaim2_request_field_list_new(var, label);
-
- if(!strcmp(type, "list-multi")) {
-- gaim_request_field_list_set_multi_select(field, TRUE);
-+ gaim2_request_field_list_set_multi_select(field, TRUE);
- g_hash_table_replace(data->fields, g_strdup(var),
- GINT_TO_POINTER(JABBER_X_DATA_LIST_MULTI));
- } else {
-@@ -257,11 +257,11 @@ void *jabber_x_data_request(JabberStream
-
- data->values = g_slist_prepend(data->values, value);
-
-- gaim_request_field_list_add(field, lbl, value);
-+ gaim2_request_field_list_add(field, lbl, value);
- if(g_list_find_custom(selected, value, (GCompareFunc)strcmp))
-- gaim_request_field_list_add_selected(field, lbl);
-+ gaim2_request_field_list_add_selected(field, lbl);
- }
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
- while(selected) {
- g_free(selected->data);
-@@ -278,8 +278,8 @@ void *jabber_x_data_request(JabberStream
- !g_ascii_strcasecmp(value, "true") || !g_ascii_strcasecmp(value, "1")))
- def = TRUE;
-
-- field = gaim_request_field_bool_new(var, label, def);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_bool_new(var, label, def);
-+ gaim2_request_field_group_add_field(group, field);
-
- g_hash_table_replace(data->fields, g_strdup(var), GINT_TO_POINTER(JABBER_X_DATA_BOOLEAN));
-
-@@ -289,8 +289,8 @@ void *jabber_x_data_request(JabberStream
- if((valuenode = xmlnode_get_child(fn, "value")))
- value = xmlnode_get_data(valuenode);
-
-- field = gaim_request_field_label_new("", value);
-- gaim_request_field_group_add_field(group, field);
-+ field = gaim2_request_field_label_new("", value);
-+ gaim2_request_field_group_add_field(group, field);
-
- if(value)
- g_free(value);
-@@ -298,10 +298,10 @@ void *jabber_x_data_request(JabberStream
- if((valuenode = xmlnode_get_child(fn, "value")))
- value = xmlnode_get_data(valuenode);
-
-- field = gaim_request_field_string_new(var, "", value ? value : "",
-+ field = gaim2_request_field_string_new(var, "", value ? value : "",
- FALSE);
-- gaim_request_field_set_visible(field, FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_set_visible(field, FALSE);
-+ gaim2_request_field_group_add_field(group, field);
-
- g_hash_table_replace(data->fields, g_strdup(var), GINT_TO_POINTER(JABBER_X_DATA_TEXT_SINGLE));
-
-@@ -311,12 +311,12 @@ void *jabber_x_data_request(JabberStream
- if((valuenode = xmlnode_get_child(fn, "value")))
- value = xmlnode_get_data(valuenode);
-
-- field = gaim_request_field_string_new(var, label,
-+ field = gaim2_request_field_string_new(var, label,
- value ? value : "", FALSE);
-- gaim_request_field_group_add_field(group, field);
-+ gaim2_request_field_group_add_field(group, field);
-
- if(!strcmp(type, "jid-single")) {
-- gaim_request_field_set_type_hint(field, "screenname");
-+ gaim2_request_field_set_type_hint(field, "screenname");
- g_hash_table_replace(data->fields, g_strdup(var), GINT_TO_POINTER(JABBER_X_DATA_JID_SINGLE));
- } else {
- g_hash_table_replace(data->fields, g_strdup(var), GINT_TO_POINTER(JABBER_X_DATA_TEXT_SINGLE));
-@@ -333,7 +333,7 @@ void *jabber_x_data_request(JabberStream
- if((x = xmlnode_get_child(packet, "instructions")))
- instructions = xmlnode_get_data(x);
-
-- handle = gaim_request_fields(js->gc, title, title, instructions, fields,
-+ handle = gaim2_request_fields(js->gc, title, title, instructions, fields,
- _("OK"), G_CALLBACK(jabber_x_data_ok_cb),
- _("Cancel"), G_CALLBACK(jabber_x_data_cancel_cb), data);
-
-diff -prNu ./src/protocols/jabber/xdata.h ./src/protocols/jabber/xdata.h
---- ./src/protocols/jabber/xdata.h 2004-03-04 18:07:56.000000000 +0100
-+++ ./src/protocols/jabber/xdata.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file xdata.h utility functions
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2003 Nathan Walp <faceprint@faceprint.com>
- *
-diff -prNu ./src/protocols/msn/cmdproc.c ./src/protocols/msn/cmdproc.c
---- ./src/protocols/msn/cmdproc.c 2005-01-11 18:25:01.000000000 +0100
-+++ ./src/protocols/msn/cmdproc.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file cmdproc.c MSN command processor functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -94,7 +94,7 @@ show_debug_cmd(MsnCmdProc *cmdproc, gboo
- show[len - 2] = '\0';
- }
-
-- gaim_debug_misc("msn", "%c: %s %03d: %s\n", tmp,
-+ gaim2_debug_misc("msn", "%c: %s %03d: %s\n", tmp,
- names[servconn->type], servconn->num, show);
-
- g_free(show);
-@@ -230,7 +230,7 @@ msn_cmdproc_process_msg(MsnCmdProc *cmdp
-
- if (msn_message_get_content_type(msg) == NULL)
- {
-- gaim_debug_misc("msn", "failed to find message content\n");
-+ gaim2_debug_misc("msn", "failed to find message content\n");
- return;
- }
-
-@@ -239,7 +239,7 @@ msn_cmdproc_process_msg(MsnCmdProc *cmdp
-
- if (cb == NULL)
- {
-- gaim_debug_warning("msn", "Unhandled content-type '%s'\n",
-+ gaim2_debug_warning("msn", "Unhandled content-type '%s'\n",
- msn_message_get_content_type(msg));
-
- return;
-@@ -259,7 +259,7 @@ msn_cmdproc_process_cmd(MsnCmdProc *cmdp
-
- if (trans != NULL)
- if (trans->timer)
-- gaim_timeout_remove(trans->timer);
-+ gaim2_timeout_remove(trans->timer);
-
- if (g_ascii_isdigit(cmd->command[0]))
- {
-@@ -285,7 +285,7 @@ msn_cmdproc_process_cmd(MsnCmdProc *cmdp
- #if 1
- msn_error_handle(cmdproc->session, error);
- #else
-- gaim_debug_warning("msn", "Unhandled error '%s'\n",
-+ gaim2_debug_warning("msn", "Unhandled error '%s'\n",
- cmd->command);
- #endif
- }
-@@ -314,7 +314,7 @@ msn_cmdproc_process_cmd(MsnCmdProc *cmdp
- }
- else
- {
-- gaim_debug_warning("msn", "Unhandled command '%s'\n",
-+ gaim2_debug_warning("msn", "Unhandled command '%s'\n",
- cmd->command);
- }
-
-diff -prNu ./src/protocols/msn/cmdproc.h ./src/protocols/msn/cmdproc.h
---- ./src/protocols/msn/cmdproc.h 2005-01-07 03:48:33.000000000 +0100
-+++ ./src/protocols/msn/cmdproc.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file cmdproc.h MSN command processor functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/command.c ./src/protocols/msn/command.c
---- ./src/protocols/msn/command.c 2005-11-28 12:47:50.000000000 +0100
-+++ ./src/protocols/msn/command.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file command.c MSN command functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/command.h ./src/protocols/msn/command.h
---- ./src/protocols/msn/command.h 2005-11-21 12:33:22.000000000 +0100
-+++ ./src/protocols/msn/command.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file command.h MSN command functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/dialog.c ./src/protocols/msn/dialog.c
---- ./src/protocols/msn/dialog.c 2005-12-04 19:42:21.000000000 +0100
-+++ ./src/protocols/msn/dialog.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file dialog.c Dialog functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -27,7 +27,7 @@
-
- typedef struct
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *who;
- char *group;
- gboolean add;
-@@ -37,7 +37,7 @@ typedef struct
- static void
- msn_add_cb(MsnAddRemData *data)
- {
-- if (g_list_find(gaim_connections_get_all(), data->gc) != NULL)
-+ if (g_list_find(gaim2_connections_get_all(), data->gc) != NULL)
- {
- MsnSession *session = data->gc->proto_data;
- MsnUserList *userlist = session->userlist;
-@@ -55,7 +55,7 @@ msn_add_cb(MsnAddRemData *data)
- static void
- msn_rem_cb(MsnAddRemData *data)
- {
-- if (g_list_find(gaim_connections_get_all(), data->gc) != NULL)
-+ if (g_list_find(gaim2_connections_get_all(), data->gc) != NULL)
- {
- MsnSession *session = data->gc->proto_data;
- MsnUserList *userlist = session->userlist;
-@@ -74,15 +74,15 @@ void
- msn_show_sync_issue(MsnSession *session, const char *passport,
- const char *group_name)
- {
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- MsnAddRemData *data;
- char *msg, *reason;
-- GaimBuddy *buddy;
-- GaimGroup *group = NULL;
-+ Gaim2Buddy *buddy;
-+ Gaim2Group *group = NULL;
-
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- data = g_new0(MsnAddRemData, 1);
- data->who = g_strdup(passport);
-@@ -90,8 +90,8 @@ msn_show_sync_issue(MsnSession *session,
- data->gc = gc;
-
- msg = g_strdup_printf(_("Buddy list synchronization issue in %s (%s)"),
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
-
- if (group_name != NULL)
- {
-@@ -109,21 +109,21 @@ msn_show_sync_issue(MsnSession *session,
- passport);
- }
-
-- gaim_request_action(gc, NULL, msg, reason, GAIM_DEFAULT_ACTION_NONE,
-+ gaim2_request_action(gc, NULL, msg, reason, GAIM_DEFAULT_ACTION_NONE,
- data, 2,
- _("Yes"), G_CALLBACK(msn_add_cb),
- _("No"), G_CALLBACK(msn_rem_cb));
-
- if (group_name != NULL)
-- group = gaim_find_group(group_name);
-+ group = gaim2_find_group(group_name);
-
- if (group != NULL)
-- buddy = gaim_find_buddy_in_group(account, passport, group);
-+ buddy = gaim2_find_buddy_in_group(account, passport, group);
- else
-- buddy = gaim_find_buddy(account, passport);
-+ buddy = gaim2_find_buddy(account, passport);
-
- if (buddy != NULL)
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
-
- g_free(reason);
- g_free(msg);
-diff -prNu ./src/protocols/msn/dialog.h ./src/protocols/msn/dialog.h
---- ./src/protocols/msn/dialog.h 2004-09-19 05:02:20.000000000 +0200
-+++ ./src/protocols/msn/dialog.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file dialog.h Dialog functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/directconn.c ./src/protocols/msn/directconn.c
---- ./src/protocols/msn/directconn.c 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/msn/directconn.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file directconn.c MSN direct connection functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -97,7 +97,7 @@ create_listener(int port)
-
- if (getaddrinfo(NULL, port_str, &hints, &res) != 0)
- {
-- gaim_debug_error("msn", "Could not get address info: %s.\n",
-+ gaim2_debug_error("msn", "Could not get address info: %s.\n",
- port_str);
- return -1;
- }
-@@ -119,7 +119,7 @@ create_listener(int port)
-
- if (c == NULL)
- {
-- gaim_debug_error("msn", "Could not find socket: %s.\n", port_str);
-+ gaim2_debug_error("msn", "Could not find socket: %s.\n", port_str);
- return -1;
- }
-
-@@ -262,19 +262,19 @@ msn_directconn_send_msg(MsnDirectConn *d
- static void
- msn_directconn_process_msg(MsnDirectConn *directconn, MsnMessage *msg)
- {
-- gaim_debug_info("msn", "directconn: process_msg\n");
-+ gaim2_debug_info("msn", "directconn: process_msg\n");
-
- msn_slplink_process_msg(directconn->slplink, msg);
- }
-
- static void
--read_cb(gpointer data, gint source, GaimInputCondition cond)
-+read_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
- MsnDirectConn* directconn;
- char *body;
- size_t len, body_len;
-
-- gaim_debug_info("msn", "read_cb: %d, %d\n", source, cond);
-+ gaim2_debug_info("msn", "read_cb: %d, %d\n", source, cond);
-
- directconn = data;
-
-@@ -284,10 +284,10 @@ read_cb(gpointer data, gint source, Gaim
- if (len <= 0)
- {
- /* ERROR */
-- gaim_debug_error("msn", "error reading\n");
-+ gaim2_debug_error("msn", "error reading\n");
-
- if (directconn->inpa)
-- gaim_input_remove(directconn->inpa);
-+ gaim2_input_remove(directconn->inpa);
-
- close(directconn->fd);
-
-@@ -298,15 +298,15 @@ read_cb(gpointer data, gint source, Gaim
-
- body_len = GUINT32_FROM_LE(body_len);
-
-- gaim_debug_info("msn", "body_len=%d\n", body_len);
-+ gaim2_debug_info("msn", "body_len=%d\n", body_len);
-
- if (body_len <= 0)
- {
- /* ERROR */
-- gaim_debug_error("msn", "error reading\n");
-+ gaim2_debug_error("msn", "error reading\n");
-
- if (directconn->inpa)
-- gaim_input_remove(directconn->inpa);
-+ gaim2_input_remove(directconn->inpa);
-
- close(directconn->fd);
-
-@@ -322,11 +322,11 @@ read_cb(gpointer data, gint source, Gaim
- /* Let's read the data. */
- len = read(directconn->fd, body, body_len);
-
-- gaim_debug_info("msn", "len=%d\n", len);
-+ gaim2_debug_info("msn", "len=%d\n", len);
- }
- else
- {
-- gaim_debug_error("msn", "Failed to allocate memory for read\n");
-+ gaim2_debug_error("msn", "Failed to allocate memory for read\n");
- len = 0;
- }
-
-@@ -354,10 +354,10 @@ read_cb(gpointer data, gint source, Gaim
- else
- {
- /* ERROR */
-- gaim_debug_error("msn", "error reading\n");
-+ gaim2_debug_error("msn", "error reading\n");
-
- if (directconn->inpa)
-- gaim_input_remove(directconn->inpa);
-+ gaim2_input_remove(directconn->inpa);
-
- close(directconn->fd);
-
-@@ -366,12 +366,12 @@ read_cb(gpointer data, gint source, Gaim
- }
-
- static void
--connect_cb(gpointer data, gint source, GaimInputCondition cond)
-+connect_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
- MsnDirectConn* directconn;
- int fd;
-
-- gaim_debug_misc("msn", "directconn: connect_cb: %d, %d.\n", source, cond);
-+ gaim2_debug_misc("msn", "directconn: connect_cb: %d, %d.\n", source, cond);
-
- directconn = data;
-
-@@ -390,7 +390,7 @@ connect_cb(gpointer data, gint source, G
-
- if (fd > 0)
- {
-- directconn->inpa = gaim_input_add(fd, GAIM_INPUT_READ, read_cb,
-+ directconn->inpa = gaim2_input_add(fd, GAIM_INPUT_READ, read_cb,
- directconn);
-
- if (TRUE)
-@@ -408,10 +408,10 @@ connect_cb(gpointer data, gint source, G
- else
- {
- /* ERROR */
-- gaim_debug_error("msn", "could not add input\n");
-+ gaim2_debug_error("msn", "could not add input\n");
-
- if (directconn->inpa)
-- gaim_input_remove(directconn->inpa);
-+ gaim2_input_remove(directconn->inpa);
-
- close(directconn->fd);
- }
-@@ -436,7 +436,7 @@ msn_directconn_connect(MsnDirectConn *di
- }
- #endif
-
-- r = gaim_proxy_connect(session->account, host, port, connect_cb,
-+ r = gaim2_proxy_connect(session->account, host, port, connect_cb,
- directconn);
-
- if (r == 0)
-@@ -460,7 +460,7 @@ msn_directconn_listen(MsnDirectConn *dir
-
- directconn->fd = fd;
-
-- directconn->inpa = gaim_input_add(fd, GAIM_INPUT_READ,
-+ directconn->inpa = gaim2_input_add(fd, GAIM_INPUT_READ,
- connect_cb, directconn);
-
- directconn->port = port;
-@@ -477,7 +477,7 @@ msn_directconn_new(MsnSlpLink *slplink)
- directconn->slplink = slplink;
-
- if (slplink->directconn != NULL)
-- gaim_debug_info("msn", "got_transresp: LEAK\n");
-+ gaim2_debug_info("msn", "got_transresp: LEAK\n");
-
- slplink->directconn = directconn;
-
-diff -prNu ./src/protocols/msn/directconn.h ./src/protocols/msn/directconn.h
---- ./src/protocols/msn/directconn.h 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/directconn.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file directconn.h MSN direct connection functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/error.c ./src/protocols/msn/error.c
---- ./src/protocols/msn/error.c 2005-12-04 18:47:37.000000000 +0100
-+++ ./src/protocols/msn/error.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file error.c Error functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,7 +35,7 @@ msn_error_get_text(unsigned int type)
- _("Unable to parse message"));
- case 200:
- g_snprintf(msg, sizeof(msg),
-- _("Syntax Error (probably a Gaim bug)"));
-+ _("Syntax Error (probably a Gaim2 bug)"));
- break;
- case 201:
- g_snprintf(msg, sizeof(msg),
-@@ -236,5 +236,5 @@ msn_error_handle(MsnSession *session, un
- g_snprintf(buf, sizeof(buf), _("MSN Error: %s\n"),
- msn_error_get_text(type));
-
-- gaim_notify_error(session->account->gc, NULL, buf, NULL);
-+ gaim2_notify_error(session->account->gc, NULL, buf, NULL);
- }
-diff -prNu ./src/protocols/msn/error.h ./src/protocols/msn/error.h
---- ./src/protocols/msn/error.h 2005-01-07 03:48:33.000000000 +0100
-+++ ./src/protocols/msn/error.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file error.h Error functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/group.c ./src/protocols/msn/group.c
---- ./src/protocols/msn/group.c 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/group.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file group.c Group functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/group.h ./src/protocols/msn/group.h
---- ./src/protocols/msn/group.h 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/group.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file group.h Group functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/history.c ./src/protocols/msn/history.c
---- ./src/protocols/msn/history.c 2004-12-02 17:07:26.000000000 +0100
-+++ ./src/protocols/msn/history.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file history.c MSN history functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/history.h ./src/protocols/msn/history.h
---- ./src/protocols/msn/history.h 2004-08-25 03:43:54.000000000 +0200
-+++ ./src/protocols/msn/history.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file history.h MSN history functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/httpconn.c ./src/protocols/msn/httpconn.c
---- ./src/protocols/msn/httpconn.c 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/msn/httpconn.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file httpmethod.c HTTP connection method
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,7 +33,7 @@ typedef struct
-
- } MsnHttpQueueData;
-
--static void read_cb(gpointer data, gint source, GaimInputCondition cond);
-+static void read_cb(gpointer data, gint source, Gaim2InputCondition cond);
- void msn_httpconn_process_queue(MsnHttpConn *httpconn);
- gboolean msn_httpconn_parse_data(MsnHttpConn *httpconn, const char *buf,
- size_t size, char **ret_buf, size_t *ret_size,
-@@ -48,7 +48,7 @@ msn_httpconn_new(MsnServConn *servconn)
-
- httpconn = g_new0(MsnHttpConn, 1);
-
-- gaim_debug_info("msn", "new httpconn (%p)\n", httpconn);
-+ gaim2_debug_info("msn", "new httpconn (%p)\n", httpconn);
-
- /* TODO: Remove this */
- httpconn->session = servconn->session;
-@@ -63,7 +63,7 @@ msn_httpconn_destroy(MsnHttpConn *httpco
- {
- g_return_if_fail(httpconn != NULL);
-
-- gaim_debug_info("msn", "destroy httpconn (%p)\n", httpconn);
-+ gaim2_debug_info("msn", "destroy httpconn (%p)\n", httpconn);
-
- if (httpconn->connected)
- msn_httpconn_disconnect(httpconn);
-@@ -83,29 +83,29 @@ msn_httpconn_destroy(MsnHttpConn *httpco
- static char *
- msn_httpconn_proxy_auth(MsnHttpConn *httpconn)
- {
-- GaimAccount *account;
-- GaimProxyInfo *gpi;
-+ Gaim2Account *account;
-+ Gaim2ProxyInfo *gpi;
- const char *username, *password;
- char *auth = NULL;
-
- account = httpconn->session->account;
-
-- if (gaim_account_get_proxy_info(account) == NULL)
-- gpi = gaim_global_proxy_get_info();
-+ if (gaim2_account_get_proxy_info(account) == NULL)
-+ gpi = gaim2_global_proxy_get_info();
- else
-- gpi = gaim_account_get_proxy_info(account);
-+ gpi = gaim2_account_get_proxy_info(account);
-
-- if (gpi == NULL || !(gaim_proxy_info_get_type(gpi) == GAIM_PROXY_HTTP ||
-- gaim_proxy_info_get_type(gpi) == GAIM_PROXY_USE_ENVVAR))
-+ if (gpi == NULL || !(gaim2_proxy_info_get_type(gpi) == GAIM_PROXY_HTTP ||
-+ gaim2_proxy_info_get_type(gpi) == GAIM_PROXY_USE_ENVVAR))
- return NULL;
-
-- username = gaim_proxy_info_get_username(gpi);
-- password = gaim_proxy_info_get_password(gpi);
-+ username = gaim2_proxy_info_get_username(gpi);
-+ password = gaim2_proxy_info_get_password(gpi);
-
- if (username != NULL) {
- char *tmp;
- auth = g_strdup_printf("%s:%s", username, password ? password : "");
-- tmp = gaim_base64_encode((const guchar *)auth, strlen(auth));
-+ tmp = gaim2_base64_encode((const guchar *)auth, strlen(auth));
- g_free(auth);
- auth = g_strdup_printf("Proxy-Authorization: Basic %s\r\n", tmp);
- g_free(tmp);
-@@ -125,7 +125,7 @@ write_raw(MsnHttpConn *httpconn, const c
- ssize_t res; /* result of the write operation */
-
- #ifdef MSN_DEBUG_HTTP
-- gaim_debug_misc("msn", "Writing HTTP (header): {%s}\n", header);
-+ gaim2_debug_misc("msn", "Writing HTTP (header): {%s}\n", header);
- #endif
-
- buf = g_strdup_printf("%s\r\n", header);
-@@ -217,12 +217,12 @@ do_poll(gpointer data)
- g_return_val_if_fail(httpconn != NULL, TRUE);
-
- #if 0
-- gaim_debug_info("msn", "polling from %s\n", httpconn->session_id);
-+ gaim2_debug_info("msn", "polling from %s\n", httpconn->session_id);
- #endif
-
- if ((httpconn->host == NULL) || (httpconn->full_session_id == NULL))
- {
-- gaim_debug_warning("msn", "Attempted HTTP poll before session is established\n");
-+ gaim2_debug_warning("msn", "Attempted HTTP poll before session is established\n");
- return TRUE;
- }
-
-@@ -233,7 +233,7 @@ do_poll(gpointer data)
- }
-
- static void
--connect_cb(gpointer data, gint source, GaimInputCondition cond)
-+connect_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
- MsnHttpConn *httpconn = data;
-
-@@ -241,17 +241,17 @@ connect_cb(gpointer data, gint source, G
-
- if (source > 0)
- {
-- httpconn->inpa = gaim_input_add(httpconn->fd, GAIM_INPUT_READ,
-+ httpconn->inpa = gaim2_input_add(httpconn->fd, GAIM_INPUT_READ,
- read_cb, data);
-
-- httpconn->timer = gaim_timeout_add(2000, do_poll, httpconn);
-+ httpconn->timer = gaim2_timeout_add(2000, do_poll, httpconn);
-
- httpconn->waiting_response = FALSE;
- msn_httpconn_process_queue(httpconn);
- }
- else
- {
-- gaim_debug_error("msn", "HTTP: Connection error\n");
-+ gaim2_debug_error("msn", "HTTP: Connection error\n");
- msn_servconn_got_error(httpconn->servconn, MSN_SERVCONN_ERROR_CONNECT);
- }
- }
-@@ -268,7 +268,7 @@ msn_httpconn_connect(MsnHttpConn *httpco
- if (httpconn->connected)
- msn_httpconn_disconnect(httpconn);
-
-- r = gaim_proxy_connect(httpconn->session->account,
-+ r = gaim2_proxy_connect(httpconn->session->account,
- "gateway.messenger.hotmail.com", 80, connect_cb,
- httpconn);
-
-@@ -290,13 +290,13 @@ msn_httpconn_disconnect(MsnHttpConn *htt
- return;
-
- if (httpconn->timer)
-- gaim_timeout_remove(httpconn->timer);
-+ gaim2_timeout_remove(httpconn->timer);
-
- httpconn->timer = 0;
-
- if (httpconn->inpa > 0)
- {
-- gaim_input_remove(httpconn->inpa);
-+ gaim2_input_remove(httpconn->inpa);
- httpconn->inpa = 0;
- }
-
-@@ -311,7 +311,7 @@ msn_httpconn_disconnect(MsnHttpConn *htt
- }
-
- static void
--read_cb(gpointer data, gint source, GaimInputCondition cond)
-+read_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
- MsnHttpConn *httpconn;
- MsnServConn *servconn;
-@@ -331,7 +331,7 @@ read_cb(gpointer data, gint source, Gaim
-
- if (len <= 0)
- {
-- gaim_debug_error("msn", "HTTP: Read error\n");
-+ gaim2_debug_error("msn", "HTTP: Read error\n");
- msn_servconn_got_error(httpconn->servconn, MSN_SERVCONN_ERROR_READ);
-
- return;
-@@ -359,7 +359,7 @@ read_cb(gpointer data, gint source, Gaim
-
- if (error)
- {
-- gaim_debug_error("msn", "HTTP: Special error\n");
-+ gaim2_debug_error("msn", "HTTP: Special error\n");
- msn_servconn_got_error(httpconn->servconn, MSN_SERVCONN_ERROR_READ);
-
- return;
-@@ -374,7 +374,7 @@ read_cb(gpointer data, gint source, Gaim
- {
- /* Nothing to do here */
- #if 0
-- gaim_debug_info("msn", "HTTP: nothing to do here\n");
-+ gaim2_debug_info("msn", "HTTP: nothing to do here\n");
- #endif
- g_free(result_msg);
- return;
-@@ -524,7 +524,7 @@ msn_httpconn_write(MsnHttpConn *httpconn
-
- if (host == NULL || httpconn->full_session_id == NULL)
- {
-- gaim_debug_warning("msn", "Attempted HTTP write before session is established\n");
-+ gaim2_debug_warning("msn", "Attempted HTTP write before session is established\n");
- return -1;
- }
-
-@@ -576,7 +576,7 @@ msn_httpconn_parse_data(MsnHttpConn *htt
- size_t size, char **ret_buf, size_t *ret_size,
- gboolean *error)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *s, *c;
- char *header, *body;
- const char *body_start;
-@@ -592,12 +592,12 @@ msn_httpconn_parse_data(MsnHttpConn *htt
- g_return_val_if_fail(error != NULL, FALSE);
-
- #if 0
-- gaim_debug_info("msn", "HTTP: parsing data {%s}\n", buf);
-+ gaim2_debug_info("msn", "HTTP: parsing data {%s}\n", buf);
- #endif
-
- httpconn->waiting_response = FALSE;
-
-- gc = gaim_account_get_connection(httpconn->session->account);
-+ gc = gaim2_account_get_connection(httpconn->session->account);
-
- /* Healthy defaults. */
- body = NULL;
-@@ -646,7 +646,7 @@ msn_httpconn_parse_data(MsnHttpConn *htt
- body_start = s;
- body_len = size - (body_start - buf);
-
-- if ((s = gaim_strcasestr(header, "Content-Length: ")) != NULL)
-+ if ((s = gaim2_strcasestr(header, "Content-Length: ")) != NULL)
- {
- int tmp_len;
-
-@@ -668,7 +668,7 @@ msn_httpconn_parse_data(MsnHttpConn *htt
- g_free(header);
-
- #if 0
-- gaim_debug_warning("msn",
-+ gaim2_debug_warning("msn",
- "body length (%d) != content length (%d)\n",
- body_len, tmp_len);
- #endif
-@@ -681,12 +681,12 @@ msn_httpconn_parse_data(MsnHttpConn *htt
- memcpy(body, body_start, body_len);
-
- #ifdef MSN_DEBUG_HTTP
-- gaim_debug_misc("msn", "Incoming HTTP buffer (header): {%s\r\n}\n",
-+ gaim2_debug_misc("msn", "Incoming HTTP buffer (header): {%s\r\n}\n",
- header);
- #endif
-
- /* Now we should be able to process the data. */
-- if ((s = gaim_strcasestr(header, "X-MSN-Messenger: ")) != NULL)
-+ if ((s = gaim2_strcasestr(header, "X-MSN-Messenger: ")) != NULL)
- {
- char *full_session_id, *gw_ip, *session_action;
- char *t, *session_id;
-@@ -700,7 +700,7 @@ msn_httpconn_parse_data(MsnHttpConn *htt
- {
- msn_session_set_error(httpconn->session,
- MSN_ERROR_HTTP_MALFORMED, NULL);
-- gaim_debug_error("msn", "Malformed X-MSN-Messenger field.\n{%s}",
-+ gaim2_debug_error("msn", "Malformed X-MSN-Messenger field.\n{%s}",
- buf);
-
- g_free(body);
-diff -prNu ./src/protocols/msn/httpconn.h ./src/protocols/msn/httpconn.h
---- ./src/protocols/msn/httpconn.h 2005-01-07 03:48:33.000000000 +0100
-+++ ./src/protocols/msn/httpconn.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file httpconn.h HTTP connection
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/Makefile.am ./src/protocols/msn/Makefile.am
---- ./src/protocols/msn/Makefile.am 2005-04-29 19:04:26.000000000 +0200
-+++ ./src/protocols/msn/Makefile.am 2006-01-05 13:03:59.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- MSNSOURCES = \
- cmdproc.c \
-diff -prNu ./src/protocols/msn/msg.c ./src/protocols/msn/msg.c
---- ./src/protocols/msn/msg.c 2005-11-28 12:47:50.000000000 +0100
-+++ ./src/protocols/msn/msg.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file msg.c Message functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,7 +33,7 @@ msn_message_new(MsnMsgType type)
- msg->type = type;
-
- #ifdef MSN_DEBUG_MSG
-- gaim_debug_info("msn", "message new (%p)(%d)\n", msg, type);
-+ gaim2_debug_info("msn", "message new (%p)(%d)\n", msg, type);
- #endif
-
- msg->attr_table = g_hash_table_new_full(g_str_hash, g_str_equal,
-@@ -57,7 +57,7 @@ msn_message_destroy(MsnMessage *msg)
- }
-
- #ifdef MSN_DEBUG_MSG
-- gaim_debug_info("msn", "message destroy (%p)\n", msg);
-+ gaim2_debug_info("msn", "message destroy (%p)\n", msg);
- #endif
-
- if (msg->remote_user != NULL)
-@@ -86,7 +86,7 @@ msn_message_ref(MsnMessage *msg)
- msg->ref_count++;
-
- #ifdef MSN_DEBUG_MSG
-- gaim_debug_info("msn", "message ref (%p)[%d]\n", msg, msg->ref_count);
-+ gaim2_debug_info("msn", "message ref (%p)[%d]\n", msg, msg->ref_count);
- #endif
-
- return msg;
-@@ -101,7 +101,7 @@ msn_message_unref(MsnMessage *msg)
- msg->ref_count--;
-
- #ifdef MSN_DEBUG_MSG
-- gaim_debug_info("msn", "message unref (%p)[%d]\n", msg, msg->ref_count);
-+ gaim2_debug_info("msn", "message unref (%p)[%d]\n", msg, msg->ref_count);
- #endif
-
- if (msg->ref_count == 0)
-@@ -121,14 +121,14 @@ msn_message_new_plain(const char *messag
- char *message_cr;
-
- msg = msn_message_new(MSN_MSG_TEXT);
-- msn_message_set_attr(msg, "User-Agent", "Gaim/" VERSION);
-+ msn_message_set_attr(msg, "User-Agent", "Gaim2/" VERSION);
- msn_message_set_content_type(msg, "text/plain");
- msn_message_set_charset(msg, "UTF-8");
- msn_message_set_flag(msg, 'A');
- msn_message_set_attr(msg, "X-MMS-IM-Format",
- "FN=MS%20Sans%20Serif; EF=; CO=0; PF=0");
-
-- message_cr = gaim_str_add_cr(message);
-+ message_cr = gaim2_str_add_cr(message);
- msn_message_set_bin_data(msg, message_cr, strlen(message_cr));
- g_free(message_cr);
-
-@@ -781,7 +781,7 @@ msn_message_show_readable(MsnMessage *ms
- }
- }
-
-- gaim_debug_info("msn", "Message %s:\n{%s}\n", info, str->str);
-+ gaim2_debug_info("msn", "Message %s:\n{%s}\n", info, str->str);
-
- g_string_free(str, TRUE);
- }
-diff -prNu ./src/protocols/msn/msg.h ./src/protocols/msn/msg.h
---- ./src/protocols/msn/msg.h 2005-08-21 19:14:22.000000000 +0200
-+++ ./src/protocols/msn/msg.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file msg.h Message functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/msn.c ./src/protocols/msn/msn.c
---- ./src/protocols/msn/msn.c 2005-12-25 20:09:22.000000000 +0100
-+++ ./src/protocols/msn/msn.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file msn.c The MSN protocol plugin
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -50,14 +50,14 @@
-
- typedef struct
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *passport;
-
- } MsnMobileData;
-
- typedef struct
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *name;
-
- } MsnGetInfoData;
-@@ -75,7 +75,7 @@ typedef struct
- } MsnGetInfoStepTwoData;
-
- static const char *
--msn_normalize(const GaimAccount *account, const char *str)
-+msn_normalize(const Gaim2Account *account, const char *str)
- {
- static char buf[BUF_LEN];
- char *tmp;
-@@ -92,60 +92,60 @@ msn_normalize(const GaimAccount *account
- return buf;
- }
-
--static GaimCmdRet
--msn_cmd_nudge(GaimConversation *conv, const gchar *cmd, gchar **args, gchar **error, void *data)
-+static Gaim2CmdRet
-+msn_cmd_nudge(Gaim2Conversation *conv, const gchar *cmd, gchar **args, gchar **error, void *data)
- {
-- GaimAccount *account = gaim_conversation_get_account(conv);
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Account *account = gaim2_conversation_get_account(conv);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- MsnMessage *msg;
- MsnSession *session;
- MsnSwitchBoard *swboard;
-
- msg = msn_message_new_nudge();
- session = gc->proto_data;
-- swboard = msn_session_get_swboard(session, gaim_conversation_get_name(conv), MSN_SB_FLAG_IM);
-+ swboard = msn_session_get_swboard(session, gaim2_conversation_get_name(conv), MSN_SB_FLAG_IM);
-
- if (session == NULL || swboard == NULL)
- return GAIM_CMD_RET_FAILED;
-
- msn_switchboard_send_msg(swboard, msg, TRUE);
-
-- gaim_conversation_write(conv, NULL, _("You have just sent a Nudge!"), GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, _("You have just sent a Nudge!"), GAIM_MESSAGE_SYSTEM, time(NULL));
-
- return GAIM_CMD_RET_OK;
- }
-
- static void
--msn_act_id(GaimConnection *gc, const char *entry)
-+msn_act_id(Gaim2Connection *gc, const char *entry)
- {
- MsnCmdProc *cmdproc;
- MsnSession *session;
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *alias;
-
- session = gc->proto_data;
- cmdproc = session->notification->cmdproc;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- if(entry && strlen(entry))
-- alias = gaim_url_encode(entry);
-+ alias = gaim2_url_encode(entry);
- else
- alias = "";
-
- if (strlen(alias) > BUDDY_ALIAS_MAXLEN)
- {
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Your new MSN friendly name is too long."), NULL);
- return;
- }
-
- msn_cmdproc_send(cmdproc, "REA", "%s %s",
-- gaim_account_get_username(account),
-+ gaim2_account_get_username(account),
- alias);
- }
-
- static void
--msn_set_prp(GaimConnection *gc, const char *type, const char *entry)
-+msn_set_prp(Gaim2Connection *gc, const char *type, const char *entry)
- {
- MsnCmdProc *cmdproc;
- MsnSession *session;
-@@ -160,42 +160,42 @@ msn_set_prp(GaimConnection *gc, const ch
- else
- {
- msn_cmdproc_send(cmdproc, "PRP", "%s %s", type,
-- gaim_url_encode(entry));
-+ gaim2_url_encode(entry));
- }
- }
-
- static void
--msn_set_home_phone_cb(GaimConnection *gc, const char *entry)
-+msn_set_home_phone_cb(Gaim2Connection *gc, const char *entry)
- {
- msn_set_prp(gc, "PHH", entry);
- }
-
- static void
--msn_set_work_phone_cb(GaimConnection *gc, const char *entry)
-+msn_set_work_phone_cb(Gaim2Connection *gc, const char *entry)
- {
- msn_set_prp(gc, "PHW", entry);
- }
-
- static void
--msn_set_mobile_phone_cb(GaimConnection *gc, const char *entry)
-+msn_set_mobile_phone_cb(Gaim2Connection *gc, const char *entry)
- {
- msn_set_prp(gc, "PHM", entry);
- }
-
- static void
--enable_msn_pages_cb(GaimConnection *gc)
-+enable_msn_pages_cb(Gaim2Connection *gc)
- {
- msn_set_prp(gc, "MOB", "Y");
- }
-
- static void
--disable_msn_pages_cb(GaimConnection *gc)
-+disable_msn_pages_cb(Gaim2Connection *gc)
- {
- msn_set_prp(gc, "MOB", "N");
- }
-
- static void
--send_to_mobile(GaimConnection *gc, const char *who, const char *entry)
-+send_to_mobile(Gaim2Connection *gc, const char *who, const char *entry)
- {
- MsnTransaction *trans;
- MsnSession *session;
-@@ -237,73 +237,73 @@ close_mobile_page_cb(MsnMobileData *data
- /* -- */
-
- static void
--msn_show_set_friendly_name(GaimPluginAction *action)
-+msn_show_set_friendly_name(Gaim2PluginAction *action)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = (GaimConnection *) action->context;
-+ gc = (Gaim2Connection *) action->context;
-
-- gaim_request_input(gc, NULL, _("Set your friendly name."),
-+ gaim2_request_input(gc, NULL, _("Set your friendly name."),
- _("This is the name that other MSN buddies will "
- "see you as."),
-- gaim_connection_get_display_name(gc), FALSE, FALSE, NULL,
-+ gaim2_connection_get_display_name(gc), FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(msn_act_id),
- _("Cancel"), NULL, gc);
- }
-
- static void
--msn_show_set_home_phone(GaimPluginAction *action)
-+msn_show_set_home_phone(Gaim2PluginAction *action)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSession *session;
-
-- gc = (GaimConnection *) action->context;
-+ gc = (Gaim2Connection *) action->context;
- session = gc->proto_data;
-
-- gaim_request_input(gc, NULL, _("Set your home phone number."), NULL,
-+ gaim2_request_input(gc, NULL, _("Set your home phone number."), NULL,
- msn_user_get_home_phone(session->user), FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(msn_set_home_phone_cb),
- _("Cancel"), NULL, gc);
- }
-
- static void
--msn_show_set_work_phone(GaimPluginAction *action)
-+msn_show_set_work_phone(Gaim2PluginAction *action)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSession *session;
-
-- gc = (GaimConnection *) action->context;
-+ gc = (Gaim2Connection *) action->context;
- session = gc->proto_data;
-
-- gaim_request_input(gc, NULL, _("Set your work phone number."), NULL,
-+ gaim2_request_input(gc, NULL, _("Set your work phone number."), NULL,
- msn_user_get_work_phone(session->user), FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(msn_set_work_phone_cb),
- _("Cancel"), NULL, gc);
- }
-
- static void
--msn_show_set_mobile_phone(GaimPluginAction *action)
-+msn_show_set_mobile_phone(Gaim2PluginAction *action)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSession *session;
-
-- gc = (GaimConnection *) action->context;
-+ gc = (Gaim2Connection *) action->context;
- session = gc->proto_data;
-
-- gaim_request_input(gc, NULL, _("Set your mobile phone number."), NULL,
-+ gaim2_request_input(gc, NULL, _("Set your mobile phone number."), NULL,
- msn_user_get_mobile_phone(session->user), FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(msn_set_mobile_phone_cb),
- _("Cancel"), NULL, gc);
- }
-
- static void
--msn_show_set_mobile_pages(GaimPluginAction *action)
-+msn_show_set_mobile_pages(Gaim2PluginAction *action)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = (GaimConnection *) action->context;
-+ gc = (Gaim2Connection *) action->context;
-
-- gaim_request_action(gc, NULL, _("Allow MSN Mobile pages?"),
-+ gaim2_request_action(gc, NULL, _("Allow MSN Mobile pages?"),
- _("Do you want to allow or disallow people on "
- "your buddy list to send you MSN Mobile pages "
- "to your cell phone or other mobile device?"),
-@@ -314,36 +314,36 @@ msn_show_set_mobile_pages(GaimPluginActi
- }
-
- static void
--msn_show_hotmail_inbox(GaimPluginAction *action)
-+msn_show_hotmail_inbox(Gaim2PluginAction *action)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSession *session;
-
-- gc = (GaimConnection *) action->context;
-+ gc = (Gaim2Connection *) action->context;
- session = gc->proto_data;
-
- if (session->passport_info.file == NULL)
- {
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("This Hotmail account may not be active."), NULL);
- return;
- }
-
-- gaim_notify_uri(gc, session->passport_info.file);
-+ gaim2_notify_uri(gc, session->passport_info.file);
- }
-
- static void
--show_send_to_mobile_cb(GaimBlistNode *node, gpointer ignored)
-+show_send_to_mobile_cb(Gaim2BlistNode *node, gpointer ignored)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- MsnSession *session;
- MsnMobileData *data;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- session = gc->proto_data;
-
-@@ -351,7 +351,7 @@ show_send_to_mobile_cb(GaimBlistNode *no
- data->gc = gc;
- data->passport = buddy->name;
-
-- gaim_request_input(gc, NULL, _("Send a mobile message."), NULL,
-+ gaim2_request_input(gc, NULL, _("Send a mobile message."), NULL,
- NULL, TRUE, FALSE, NULL,
- _("Page"), G_CALLBACK(send_to_mobile_cb),
- _("Close"), G_CALLBACK(close_mobile_page_cb),
-@@ -359,18 +359,18 @@ show_send_to_mobile_cb(GaimBlistNode *no
- }
-
- static void
--initiate_chat_cb(GaimBlistNode *node, gpointer data)
-+initiate_chat_cb(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- MsnSession *session;
- MsnSwitchBoard *swboard;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- session = gc->proto_data;
-
-@@ -383,36 +383,36 @@ initiate_chat_cb(GaimBlistNode *node, gp
- swboard->conv = serv_got_joined_chat(gc, swboard->chat_id, "MSN Chat");
- swboard->flag = MSN_SB_FLAG_IM;
-
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv),
-- gaim_account_get_username(buddy->account), NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv),
-+ gaim2_account_get_username(buddy->account), NULL, GAIM_CBFLAGS_NONE, TRUE);
- }
-
- static void
--t_msn_xfer_init(GaimXfer *xfer)
-+t_msn_xfer_init(Gaim2Xfer *xfer)
- {
- MsnSlpLink *slplink;
- const char *filename;
- FILE *fp;
-
-- filename = gaim_xfer_get_local_filename(xfer);
-+ filename = gaim2_xfer_get_local_filename(xfer);
-
- slplink = xfer->data;
-
- if ((fp = g_fopen(filename, "rb")) == NULL)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- const char *who;
- char *msg;
-
- account = slplink->session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- who = slplink->remote_user;
-
- msg = g_strdup_printf(_("Error reading %s: \n%s.\n"),
- filename, strerror(errno));
-- gaim_xfer_error(gaim_xfer_get_type(xfer), account, xfer->who, msg);
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_error(gaim2_xfer_get_type(xfer), account, xfer->who, msg);
-+ gaim2_xfer_cancel_local(xfer);
- g_free(msg);
-
- return;
-@@ -422,47 +422,47 @@ t_msn_xfer_init(GaimXfer *xfer)
- msn_slplink_request_ft(slplink, xfer);
- }
-
--static GaimXfer*
--msn_new_xfer(GaimConnection *gc, const char *who)
-+static Gaim2Xfer*
-+msn_new_xfer(Gaim2Connection *gc, const char *who)
- {
- MsnSession *session;
- MsnSlpLink *slplink;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- session = gc->proto_data;
-
-- xfer = gaim_xfer_new(gc->account, GAIM_XFER_SEND, who);
-+ xfer = gaim2_xfer_new(gc->account, GAIM_XFER_SEND, who);
-
- slplink = msn_session_get_slplink(session, who);
-
- xfer->data = slplink;
-
-- gaim_xfer_set_init_fnc(xfer, t_msn_xfer_init);
-+ gaim2_xfer_set_init_fnc(xfer, t_msn_xfer_init);
-
- return xfer;
- }
-
- static void
--msn_send_file(GaimConnection *gc, const char *who, const char *file)
-+msn_send_file(Gaim2Connection *gc, const char *who, const char *file)
- {
-- GaimXfer *xfer = msn_new_xfer(gc, who);
-+ Gaim2Xfer *xfer = msn_new_xfer(gc, who);
-
- if (file)
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
- else
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
- static gboolean
--msn_can_receive_file(GaimConnection *gc, const char *who)
-+msn_can_receive_file(Gaim2Connection *gc, const char *who)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *normal;
- gboolean ret;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- normal = g_strdup(msn_normalize(account, gaim_account_get_username(account)));
-+ normal = g_strdup(msn_normalize(account, gaim2_account_get_username(account)));
-
- ret = strcmp(normal, msn_normalize(account, who));
-
-@@ -476,29 +476,29 @@ msn_can_receive_file(GaimConnection *gc,
- **************************************************************************/
-
- static const char *
--msn_list_icon(GaimAccount *a, GaimBuddy *b)
-+msn_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- return "msn";
- }
-
- static void
--msn_list_emblems(GaimBuddy *b, const char **se, const char **sw,
-+msn_list_emblems(Gaim2Buddy *b, const char **se, const char **sw,
- const char **nw, const char **ne)
- {
- MsnUser *user;
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- const char *emblems[4] = { NULL, NULL, NULL, NULL };
- int i = 0;
-
- user = b->proto_data;
-- presence = gaim_buddy_get_presence(b);
-+ presence = gaim2_buddy_get_presence(b);
-
-- if (!gaim_presence_is_online(presence))
-+ if (!gaim2_presence_is_online(presence))
- emblems[i++] = "offline";
-- else if (gaim_presence_is_status_active(presence, "busy") ||
-- gaim_presence_is_status_active(presence, "phone"))
-+ else if (gaim2_presence_is_status_active(presence, "busy") ||
-+ gaim2_presence_is_status_active(presence, "phone"))
- emblems[i++] = "occupied";
-- else if (!gaim_presence_is_available(presence))
-+ else if (!gaim2_presence_is_available(presence))
- emblems[i++] = "away";
-
- if (user == NULL)
-@@ -520,38 +520,38 @@ msn_list_emblems(GaimBuddy *b, const cha
- }
-
- static char *
--msn_status_text(GaimBuddy *buddy)
-+msn_status_text(Gaim2Buddy *buddy)
- {
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-
-- presence = gaim_buddy_get_presence(buddy);
-- status = gaim_presence_get_active_status(presence);
-+ presence = gaim2_buddy_get_presence(buddy);
-+ status = gaim2_presence_get_active_status(presence);
-
-- if (!gaim_presence_is_available(presence) && !gaim_presence_is_idle(presence))
-+ if (!gaim2_presence_is_available(presence) && !gaim2_presence_is_idle(presence))
- {
-- return g_strdup(gaim_status_get_name(status));
-+ return g_strdup(gaim2_status_get_name(status));
- }
-
- return NULL;
- }
-
- static char *
--msn_tooltip_text(GaimBuddy *buddy)
-+msn_tooltip_text(Gaim2Buddy *buddy)
- {
- MsnUser *user;
-- GaimPresence *presence = gaim_buddy_get_presence(buddy);
-- GaimStatus *status = gaim_presence_get_active_status(presence);
-+ Gaim2Presence *presence = gaim2_buddy_get_presence(buddy);
-+ Gaim2Status *status = gaim2_presence_get_active_status(presence);
- GString *s;
-
- user = buddy->proto_data;
-
- s = g_string_new("");
-- if (gaim_presence_is_online(presence))
-+ if (gaim2_presence_is_online(presence))
- {
- g_string_append_printf(s, _("\n<b>%s:</b> %s"), _("Status"),
-- gaim_presence_is_idle(presence) ?
-- _("Idle") : gaim_status_get_name(status));
-+ gaim2_presence_is_idle(presence) ?
-+ _("Idle") : gaim2_status_get_name(status));
- }
-
- if (user)
-@@ -568,40 +568,40 @@ msn_tooltip_text(GaimBuddy *buddy)
- }
-
- static GList *
--msn_status_types(GaimAccount *account)
-+msn_status_types(Gaim2Account *account)
- {
-- GaimStatusType *status;
-+ Gaim2StatusType *status;
- GList *types = NULL;
-
-- status = gaim_status_type_new_full(GAIM_STATUS_AVAILABLE,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_AVAILABLE,
- NULL, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_AWAY,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_AWAY,
- NULL, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_AWAY,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_AWAY,
- "brb", _("Be Right Back"), FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_UNAVAILABLE,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_UNAVAILABLE,
- "busy", _("Busy"), FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_UNAVAILABLE,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_UNAVAILABLE,
- "phone", _("On the Phone"), FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_AWAY,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_AWAY,
- "lunch", _("Out to Lunch"), FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_INVISIBLE,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_INVISIBLE,
- NULL, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-- status = gaim_status_type_new_full(GAIM_STATUS_OFFLINE,
-+ status = gaim2_status_type_new_full(GAIM_STATUS_OFFLINE,
- NULL, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, status);
-
-@@ -609,50 +609,50 @@ msn_status_types(GaimAccount *account)
- }
-
- static GList *
--msn_actions(GaimPlugin *plugin, gpointer context)
-+msn_actions(Gaim2Plugin *plugin, gpointer context)
- {
-- GaimConnection *gc = (GaimConnection *)context;
-- GaimAccount *account;
-+ Gaim2Connection *gc = (Gaim2Connection *)context;
-+ Gaim2Account *account;
- const char *user;
-
- GList *m = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- act = gaim_plugin_action_new(_("Set Friendly Name..."),
-+ act = gaim2_plugin_action_new(_("Set Friendly Name..."),
- msn_show_set_friendly_name);
- m = g_list_append(m, act);
- m = g_list_append(m, NULL);
-
-- act = gaim_plugin_action_new(_("Set Home Phone Number..."),
-+ act = gaim2_plugin_action_new(_("Set Home Phone Number..."),
- msn_show_set_home_phone);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Set Work Phone Number..."),
-+ act = gaim2_plugin_action_new(_("Set Work Phone Number..."),
- msn_show_set_work_phone);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Set Mobile Phone Number..."),
-+ act = gaim2_plugin_action_new(_("Set Mobile Phone Number..."),
- msn_show_set_mobile_phone);
- m = g_list_append(m, act);
- m = g_list_append(m, NULL);
-
- #if 0
-- act = gaim_plugin_action_new(_("Enable/Disable Mobile Devices..."),
-+ act = gaim2_plugin_action_new(_("Enable/Disable Mobile Devices..."),
- msn_show_set_mobile_support);
- m = g_list_append(m, act);
- #endif
-
-- act = gaim_plugin_action_new(_("Allow/Disallow Mobile Pages..."),
-+ act = gaim2_plugin_action_new(_("Allow/Disallow Mobile Pages..."),
- msn_show_set_mobile_pages);
- m = g_list_append(m, act);
-
-- account = gaim_connection_get_account(gc);
-- user = msn_normalize(account, gaim_account_get_username(account));
-+ account = gaim2_connection_get_account(gc);
-+ user = msn_normalize(account, gaim2_account_get_username(account));
-
- if (strstr(user, "@hotmail.com") != NULL)
- {
- m = g_list_append(m, NULL);
-- act = gaim_plugin_action_new(_("Open Hotmail Inbox"),
-+ act = gaim2_plugin_action_new(_("Open Hotmail Inbox"),
- msn_show_hotmail_inbox);
- m = g_list_append(m, act);
- }
-@@ -661,12 +661,12 @@ msn_actions(GaimPlugin *plugin, gpointer
- }
-
- static GList *
--msn_buddy_menu(GaimBuddy *buddy)
-+msn_buddy_menu(Gaim2Buddy *buddy)
- {
- MsnUser *user;
-
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
- g_return_val_if_fail(buddy != NULL, NULL);
-
-@@ -676,16 +676,16 @@ msn_buddy_menu(GaimBuddy *buddy)
- {
- if (user->mobile)
- {
-- act = gaim_blist_node_action_new(_("Send to Mobile"),
-+ act = gaim2_blist_node_action_new(_("Send to Mobile"),
- show_send_to_mobile_cb, NULL, NULL);
- m = g_list_append(m, act);
- }
- }
-
- if (g_ascii_strcasecmp(buddy->name,
-- gaim_account_get_username(buddy->account)))
-+ gaim2_account_get_username(buddy->account)))
- {
-- act = gaim_blist_node_action_new(_("Initiate _Chat"),
-+ act = gaim2_blist_node_action_new(_("Initiate _Chat"),
- initiate_chat_cb, NULL, NULL);
- m = g_list_append(m, act);
- }
-@@ -694,11 +694,11 @@ msn_buddy_menu(GaimBuddy *buddy)
- }
-
- static GList *
--msn_blist_node_menu(GaimBlistNode *node)
-+msn_blist_node_menu(Gaim2BlistNode *node)
- {
- if(GAIM_BLIST_NODE_IS_BUDDY(node))
- {
-- return msn_buddy_menu((GaimBuddy *) node);
-+ return msn_buddy_menu((Gaim2Buddy *) node);
- }
- else
- {
-@@ -707,33 +707,33 @@ msn_blist_node_menu(GaimBlistNode *node)
- }
-
- static void
--msn_login(GaimAccount *account)
-+msn_login(Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSession *session;
- const char *username;
- const char *host;
- gboolean http_method = FALSE;
- int port;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
-- if (!gaim_ssl_is_supported())
-+ if (!gaim2_ssl_is_supported())
- {
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc,
-+ gaim2_connection_error(gc,
- _("SSL support is needed for MSN. Please install a supported "
-- "SSL library. See http://gaim.sf.net/faq-ssl.php for more "
-+ "SSL library. See http://gaim2.sf.net/faq-ssl.php for more "
- "information."));
-
- return;
- }
-
-- if (gaim_account_get_bool(account, "http_method", FALSE))
-+ if (gaim2_account_get_bool(account, "http_method", FALSE))
- http_method = TRUE;
-
-- host = gaim_account_get_string(account, "server", MSN_SERVER);
-- port = gaim_account_get_int(account, "port", MSN_PORT);
-+ host = gaim2_account_get_string(account, "server", MSN_SERVER);
-+ port = gaim2_account_get_int(account, "port", MSN_PORT);
-
- session = msn_session_new(account);
-
-@@ -744,17 +744,17 @@ msn_login(GaimAccount *account)
-
- /* Hmm, I don't like this. */
- /* XXX shx: Me neither */
-- username = msn_normalize(account, gaim_account_get_username(account));
-+ username = msn_normalize(account, gaim2_account_get_username(account));
-
-- if (strcmp(username, gaim_account_get_username(account)))
-- gaim_account_set_username(account, username);
-+ if (strcmp(username, gaim2_account_get_username(account)))
-+ gaim2_account_set_username(account, username);
-
- if (!msn_session_connect(session, host, port, http_method))
-- gaim_connection_error(gc, _("Failed to connect to server."));
-+ gaim2_connection_error(gc, _("Failed to connect to server."));
- }
-
- static void
--msn_close(GaimConnection *gc)
-+msn_close(Gaim2Connection *gc)
- {
- MsnSession *session;
-
-@@ -768,15 +768,15 @@ msn_close(GaimConnection *gc)
- }
-
- static int
--msn_send_im(GaimConnection *gc, const char *who, const char *message,
-- GaimMessageFlags flags)
-+msn_send_im(Gaim2Connection *gc, const char *who, const char *message,
-+ Gaim2MessageFlags flags)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnMessage *msg;
- char *msgformat;
- char *msgtext;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- msn_import_html(message, &msgformat, &msgtext);
-
-@@ -794,7 +794,7 @@ msn_send_im(GaimConnection *gc, const ch
- g_free(msgformat);
- g_free(msgtext);
-
-- if (g_ascii_strcasecmp(who, gaim_account_get_username(account)))
-+ if (g_ascii_strcasecmp(who, gaim2_account_get_username(account)))
- {
- MsnSession *session;
- MsnSwitchBoard *swboard;
-@@ -835,20 +835,20 @@ msn_send_im(GaimConnection *gc, const ch
- }
-
- static int
--msn_send_typing(GaimConnection *gc, const char *who, int typing)
-+msn_send_typing(Gaim2Connection *gc, const char *who, int typing)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnSession *session;
- MsnSwitchBoard *swboard;
- MsnMessage *msg;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- session = gc->proto_data;
-
- if (!typing)
- return 0;
-
-- if (!g_ascii_strcasecmp(who, gaim_account_get_username(account)))
-+ if (!g_ascii_strcasecmp(who, gaim2_account_get_username(account)))
- {
- /* We'll just fake it, since we're sending to ourself. */
- serv_got_typing(gc, who, MSN_TYPING_RECV_TIMEOUT, GAIM_TYPING);
-@@ -867,7 +867,7 @@ msn_send_typing(GaimConnection *gc, cons
- msn_message_set_content_type(msg, "text/x-msmsgscontrol");
- msn_message_set_flag(msg, 'U');
- msn_message_set_attr(msg, "TypingUser",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- msn_message_set_bin_data(msg, "\r\n", 2);
-
- msn_switchboard_send_msg(swboard, msg, FALSE);
-@@ -878,12 +878,12 @@ msn_send_typing(GaimConnection *gc, cons
- }
-
- static void
--msn_set_status(GaimAccount *account, GaimStatus *status)
-+msn_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSession *session;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (gc != NULL)
- {
-@@ -893,7 +893,7 @@ msn_set_status(GaimAccount *account, Gai
- }
-
- static void
--msn_set_idle(GaimConnection *gc, int idle)
-+msn_set_idle(Gaim2Connection *gc, int idle)
- {
- MsnSession *session;
-
-@@ -953,7 +953,7 @@ fake_userlist_add_buddy(MsnUserList *use
- #endif
-
- static void
--msn_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+msn_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- MsnSession *session;
- MsnUserList *userlist;
-@@ -969,7 +969,7 @@ msn_add_buddy(GaimConnection *gc, GaimBu
- fake_userlist_add_buddy(session->sync_userlist, who, MSN_LIST_FL,
- group ? group->name : NULL);
- #else
-- gaim_debug_error("msn", "msn_add_buddy called before connected\n");
-+ gaim2_debug_error("msn", "msn_add_buddy called before connected\n");
- #endif
-
- return;
-@@ -977,18 +977,18 @@ msn_add_buddy(GaimConnection *gc, GaimBu
-
- #if 0
- if (group != NULL && group->name != NULL)
-- gaim_debug_info("msn", "msn_add_buddy: %s, %s\n", who, group->name);
-+ gaim2_debug_info("msn", "msn_add_buddy: %s, %s\n", who, group->name);
- else
-- gaim_debug_info("msn", "msn_add_buddy: %s\n", who);
-+ gaim2_debug_info("msn", "msn_add_buddy: %s\n", who);
- #endif
-
- #if 0
- /* Which is the max? */
- if (session->fl_users_count >= 150)
- {
-- gaim_debug_info("msn", "Too many buddies\n");
-+ gaim2_debug_info("msn", "Too many buddies\n");
- /* Buddy list full */
-- /* TODO: gaim should be notified of this */
-+ /* TODO: gaim2 should be notified of this */
- return;
- }
- #endif
-@@ -1001,7 +1001,7 @@ msn_add_buddy(GaimConnection *gc, GaimBu
- }
-
- static void
--msn_rem_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+msn_rem_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- MsnSession *session;
- MsnUserList *userlist;
-@@ -1017,7 +1017,7 @@ msn_rem_buddy(GaimConnection *gc, GaimBu
- }
-
- static void
--msn_add_permit(GaimConnection *gc, const char *who)
-+msn_add_permit(Gaim2Connection *gc, const char *who)
- {
- MsnSession *session;
- MsnUserList *userlist;
-@@ -1037,7 +1037,7 @@ msn_add_permit(GaimConnection *gc, const
- }
-
- static void
--msn_add_deny(GaimConnection *gc, const char *who)
-+msn_add_deny(Gaim2Connection *gc, const char *who)
- {
- MsnSession *session;
- MsnUserList *userlist;
-@@ -1057,7 +1057,7 @@ msn_add_deny(GaimConnection *gc, const c
- }
-
- static void
--msn_rem_permit(GaimConnection *gc, const char *who)
-+msn_rem_permit(Gaim2Connection *gc, const char *who)
- {
- MsnSession *session;
- MsnUserList *userlist;
-@@ -1078,7 +1078,7 @@ msn_rem_permit(GaimConnection *gc, const
- }
-
- static void
--msn_rem_deny(GaimConnection *gc, const char *who)
-+msn_rem_deny(Gaim2Connection *gc, const char *who)
- {
- MsnSession *session;
- MsnUserList *userlist;
-@@ -1099,13 +1099,13 @@ msn_rem_deny(GaimConnection *gc, const c
- }
-
- static void
--msn_set_permit_deny(GaimConnection *gc)
-+msn_set_permit_deny(Gaim2Connection *gc)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnSession *session;
- MsnCmdProc *cmdproc;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- session = gc->proto_data;
- cmdproc = session->notification->cmdproc;
-
-@@ -1121,7 +1121,7 @@ msn_set_permit_deny(GaimConnection *gc)
- }
-
- static void
--msn_chat_invite(GaimConnection *gc, int id, const char *msg,
-+msn_chat_invite(Gaim2Connection *gc, int id, const char *msg,
- const char *who)
- {
- MsnSession *session;
-@@ -1137,7 +1137,7 @@ msn_chat_invite(GaimConnection *gc, int
- swboard = msn_switchboard_new(session);
- msn_switchboard_request(swboard);
- swboard->chat_id = id;
-- swboard->conv = gaim_find_chat(gc, id);
-+ swboard->conv = gaim2_find_chat(gc, id);
- }
-
- swboard->flag |= MSN_SB_FLAG_IM;
-@@ -1146,11 +1146,11 @@ msn_chat_invite(GaimConnection *gc, int
- }
-
- static void
--msn_chat_leave(GaimConnection *gc, int id)
-+msn_chat_leave(Gaim2Connection *gc, int id)
- {
- MsnSession *session;
- MsnSwitchBoard *swboard;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- session = gc->proto_data;
-
-@@ -1174,16 +1174,16 @@ msn_chat_leave(GaimConnection *gc, int i
- }
-
- static int
--msn_chat_send(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags)
-+msn_chat_send(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnSession *session;
- MsnSwitchBoard *swboard;
- MsnMessage *msg;
- char *msgformat;
- char *msgtext;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- session = gc->proto_data;
- swboard = msn_session_find_swboard_with_id(session, id);
-
-@@ -1213,14 +1213,14 @@ msn_chat_send(GaimConnection *gc, int id
- g_free(msgformat);
- g_free(msgtext);
-
-- serv_got_chat_in(gc, id, gaim_account_get_username(account), 0,
-+ serv_got_chat_in(gc, id, gaim2_account_get_username(account), 0,
- message, time(NULL));
-
- return 0;
- }
-
- static void
--msn_keepalive(GaimConnection *gc)
-+msn_keepalive(Gaim2Connection *gc)
- {
- MsnSession *session;
-
-@@ -1237,7 +1237,7 @@ msn_keepalive(GaimConnection *gc)
- }
-
- static void
--msn_group_buddy(GaimConnection *gc, const char *who,
-+msn_group_buddy(Gaim2Connection *gc, const char *who,
- const char *old_group_name, const char *new_group_name)
- {
- MsnSession *session;
-@@ -1250,8 +1250,8 @@ msn_group_buddy(GaimConnection *gc, cons
- }
-
- static void
--msn_rename_group(GaimConnection *gc, const char *old_name,
-- GaimGroup *group, GList *moved_buddies)
-+msn_rename_group(Gaim2Connection *gc, const char *old_name,
-+ Gaim2Group *group, GList *moved_buddies)
- {
- MsnSession *session;
- MsnCmdProc *cmdproc;
-@@ -1260,7 +1260,7 @@ msn_rename_group(GaimConnection *gc, con
-
- session = gc->proto_data;
- cmdproc = session->notification->cmdproc;
-- enc_new_group_name = gaim_url_encode(group->name);
-+ enc_new_group_name = gaim2_url_encode(group->name);
-
- old_gid = msn_userlist_find_group_id(session->userlist, old_name);
-
-@@ -1276,11 +1276,11 @@ msn_rename_group(GaimConnection *gc, con
- }
-
- static void
--msn_convo_closed(GaimConnection *gc, const char *who)
-+msn_convo_closed(Gaim2Connection *gc, const char *who)
- {
- MsnSession *session;
- MsnSwitchBoard *swboard;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- session = gc->proto_data;
-
-@@ -1308,7 +1308,7 @@ msn_convo_closed(GaimConnection *gc, con
- }
-
- static void
--msn_set_buddy_icon(GaimConnection *gc, const char *filename)
-+msn_set_buddy_icon(Gaim2Connection *gc, const char *filename)
- {
- MsnSession *session;
- MsnUser *user;
-@@ -1322,7 +1322,7 @@ msn_set_buddy_icon(GaimConnection *gc, c
- }
-
- static void
--msn_remove_group(GaimConnection *gc, GaimGroup *group)
-+msn_remove_group(Gaim2Connection *gc, Gaim2Group *group)
- {
- MsnSession *session;
- MsnCmdProc *cmdproc;
-@@ -1341,19 +1341,19 @@ static char *
- msn_tooltip_info_text(MsnGetInfoData *info_data)
- {
- GString *s;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
-
- s = g_string_sized_new(80); /* wild guess */
-
-- b = gaim_find_buddy(gaim_connection_get_account(info_data->gc),
-+ b = gaim2_find_buddy(gaim2_connection_get_account(info_data->gc),
- info_data->name);
-
- if (b)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- char *statustext = msn_tooltip_text(b);
-
-- presence = gaim_buddy_get_presence(b);
-+ presence = gaim2_buddy_get_presence(b);
-
- if (b->alias && b->alias[0])
- {
-@@ -1374,7 +1374,7 @@ msn_tooltip_info_text(MsnGetInfoData *in
- if (statustext)
- {
- char *tmp;
-- tmp = gaim_strreplace((*statustext == '\n' ? statustext + 1 : statustext),
-+ tmp = gaim2_strreplace((*statustext == '\n' ? statustext + 1 : statustext),
- "\n", "<br>");
- g_free(statustext);
- g_string_append_printf(s, "%s<br>", tmp);
-@@ -1439,7 +1439,7 @@ msn_got_info(void *data, const char *url
- MsnGetInfoStepTwoData *info2_data = NULL;
- #endif
-
-- gaim_debug_info("msn", "In msn_got_info\n");
-+ gaim2_debug_info("msn", "In msn_got_info\n");
-
- tooltip_text = msn_tooltip_info_text(info_data);
- title = _("MSN Profile");
-@@ -1449,7 +1449,7 @@ msn_got_info(void *data, const char *url
- g_snprintf(buf, 1024, "<html><body>%s<b>%s</b></body></html>",
- tooltip_text, _("Error retrieving profile"));
-
-- gaim_notify_userinfo(info_data->gc, info_data->name, buf, NULL, NULL);
-+ gaim2_notify_userinfo(info_data->gc, info_data->name, buf, NULL, NULL);
-
- g_free(tooltip_text);
- return;
-@@ -1458,7 +1458,7 @@ msn_got_info(void *data, const char *url
- url_buffer = g_strdup(url_text);
-
- /* If they have a homepage link, MSN masks it such that we need to
-- * fetch the url out before gaim_markup_strip_html() nukes it */
-+ * fetch the url out before gaim2_markup_strip_html() nukes it */
- if ((p = strstr(url_text,
- "Take a look at my </font><A class=viewDesc title=\"")) != NULL)
- {
-@@ -1469,7 +1469,7 @@ msn_got_info(void *data, const char *url
- }
-
- /*
-- * gaim_markup_strip_html() doesn't strip out character entities like &nbsp;
-+ * gaim2_markup_strip_html() doesn't strip out character entities like &nbsp;
- * and &#183;
- */
- while ((p = strstr(url_buffer, "&nbsp;")) != NULL)
-@@ -1487,7 +1487,7 @@ msn_got_info(void *data, const char *url
- }
-
- /* Nuke the nasty \r's that just get in the way */
-- gaim_str_strip_char(url_buffer, '\r');
-+ gaim2_str_strip_char(url_buffer, '\r');
-
- /* MSN always puts in &#39; for apostrophes...replace them */
- while ((p = strstr(url_buffer, "&#39;")) != NULL)
-@@ -1498,32 +1498,32 @@ msn_got_info(void *data, const char *url
- }
-
- /* Nuke the html, it's easier than trying to parse the horrid stuff */
-- stripped = gaim_markup_strip_html(url_buffer);
-+ stripped = gaim2_markup_strip_html(url_buffer);
- stripped_len = strlen(stripped);
-
-- gaim_debug_misc("msn", "stripped = %p\n", stripped);
-- gaim_debug_misc("msn", "url_buffer = %p\n", url_buffer);
-+ gaim2_debug_misc("msn", "stripped = %p\n", stripped);
-+ gaim2_debug_misc("msn", "url_buffer = %p\n", url_buffer);
-
- /* Gonna re-use the memory we've already got for url_buffer */
- /* No we're not. */
- s = g_string_sized_new(strlen(url_buffer));
-
- /* Extract their Name and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "\nName\n", 0, "\t", 0, "Undisclosed", _("Name"), 0, NULL);
-
- if (found)
- has_info = TRUE;
-
- /* Extract their Age and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "\tAge\n", 0, "\n", 0, "Undisclosed", _("Age"), 0, NULL);
-
- if (found)
- has_info = TRUE;
-
- /* Extract their Gender and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "\nGender\n", 0, "\t", 0, "Undisclosed", _("Gender"), 0,
- NULL);
-
-@@ -1531,7 +1531,7 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Extract their MaritalStatus and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "\tMarital Status\n", 0, "\n", 0, "Undisclosed",
- _("Marital Status"), 0, NULL);
-
-@@ -1539,7 +1539,7 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Extract their Location and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "\nLocation\n", 0, "\n", 0, "Undisclosed", _("Location"), 0,
- NULL);
-
-@@ -1547,7 +1547,7 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Extract their Occupation and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Occupation\n", 6, "\n", 0, "Undisclosed", _("Occupation"),
- 0, NULL);
-
-@@ -1563,27 +1563,27 @@ msn_got_info(void *data, const char *url
- */
-
- /* Check if they have A Little About Me */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " A Little About Me \n\n", 0, "Favorite Things", '\n', NULL,
- _("A Little About Me"), 0, NULL);
-
- if (!found)
- {
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " A Little About Me \n\n", 0, "Hobbies and Interests", '\n',
- NULL, _("A Little About Me"), 0, NULL);
- }
-
- if (!found)
- {
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " A Little About Me \n\n", 0, "Favorite Quote", '\n', NULL,
- _("A Little About Me"), 0, NULL);
- }
-
- if (!found)
- {
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " A Little About Me \n\n", 0, "My Homepage \n\nTake a look",
- '\n',
- NULL, _("A Little About Me"), 0, NULL);
-@@ -1591,7 +1591,7 @@ msn_got_info(void *data, const char *url
-
- if (!found)
- {
-- gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " A Little About Me \n\n", 0, "last updated", '\n', NULL,
- _("A Little About Me"), 0, NULL);
- }
-@@ -1600,27 +1600,27 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Check if they have Favorite Things */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Favorite Things \n\n", 0, "Hobbies and Interests", '\n', NULL,
- _("Favorite Things"), 0, NULL);
-
- if (!found)
- {
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Favorite Things \n\n", 0, "Favorite Quote", '\n', NULL,
- _("Favorite Things"), 0, NULL);
- }
-
- if (!found)
- {
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Favorite Things \n\n", 0, "My Homepage \n\nTake a look", '\n',
- NULL, _("Favorite Things"), 0, NULL);
- }
-
- if (!found)
- {
-- gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Favorite Things \n\n", 0, "last updated", '\n', NULL,
- _("Favorite Things"), 0, NULL);
- }
-@@ -1629,20 +1629,20 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Check if they have Hobbies and Interests */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Hobbies and Interests \n\n", 0, "Favorite Quote", '\n', NULL,
- _("Hobbies and Interests"), 0, NULL);
-
- if (!found)
- {
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Hobbies and Interests \n\n", 0, "My Homepage \n\nTake a look",
- '\n', NULL, _("Hobbies and Interests"), 0, NULL);
- }
-
- if (!found)
- {
-- gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " Hobbies and Interests \n\n", 0, "last updated", '\n', NULL,
- _("Hobbies and Interests"), 0, NULL);
- }
-@@ -1651,13 +1651,13 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Check if they have Favorite Quote */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "Favorite Quote \n\n", 0, "My Homepage \n\nTake a look", '\n', NULL,
- _("Favorite Quote"), 0, NULL);
-
- if (!found)
- {
-- gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "Favorite Quote \n\n", 0, "last updated", '\n', NULL,
- _("Favorite Quote"), 0, NULL);
- }
-@@ -1666,7 +1666,7 @@ msn_got_info(void *data, const char *url
- has_info = TRUE;
-
- /* Extract the last updated date and put it in */
-- found = gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found = gaim2_markup_extract_info_field(stripped, stripped_len, s,
- " last updated:", 1, "\n", 0, NULL, _("Last Updated"), 0,
- NULL);
-
-@@ -1695,8 +1695,8 @@ msn_got_info(void *data, const char *url
- * exists.
- */
- char *p = strstr(url_buffer, "Unknown Member </TITLE>");
-- GaimBuddy *b = gaim_find_buddy
-- (gaim_connection_get_account(info_data->gc), info_data->name);
-+ Gaim2Buddy *b = gaim2_find_buddy
-+ (gaim2_connection_get_account(info_data->gc), info_data->name);
- g_string_append_printf(s, "<br><b>%s</b><br>%s<br><br>",
- _("Error retrieving profile"),
- ((p && b)?
-@@ -1705,7 +1705,7 @@ msn_got_info(void *data, const char *url
- "This either means that the user does not exist, "
- "or that the user exists "
- "but has not created a public profile."):
-- _("Gaim could not find " /* This should never happen */
-+ _("Gaim2 could not find " /* This should never happen */
- "any information in the user's profile. "
- "The user most likely does not exist.")));
- }
-@@ -1735,7 +1735,7 @@ msn_got_info(void *data, const char *url
- /* Try to put the photo in there too, if there's one */
- if (photo_url_text)
- {
-- gaim_url_fetch(photo_url_text, FALSE, NULL, FALSE, msn_got_photo,
-+ gaim2_url_fetch(photo_url_text, FALSE, NULL, FALSE, msn_got_photo,
- info2_data);
- }
- else
-@@ -1767,14 +1767,14 @@ msn_got_photo(void *data, const char *ur
- || strstr(url_text, "404 Not Found"))
- {
-
-- gaim_debug_info("msn", "Error getting %s: %s\n",
-+ gaim2_debug_info("msn", "Error getting %s: %s\n",
- photo_url_text, url_text);
- }
- else
- {
- char buf[1024];
-- gaim_debug_info("msn", "%s is %d bytes\n", photo_url_text, len);
-- id = gaim_imgstore_add(url_text, len, NULL);
-+ gaim2_debug_info("msn", "%s is %d bytes\n", photo_url_text, len);
-+ id = gaim2_imgstore_add(url_text, len, NULL);
- g_snprintf(buf, sizeof(buf), "<img id=\"%d\"><br>", id);
- g_string_prepend(s, buf);
- }
-@@ -1784,7 +1784,7 @@ msn_got_photo(void *data, const char *ur
- #endif
-
- g_string_prepend(s, tooltip_text);
-- gaim_notify_userinfo(info_data->gc, info_data->name, s->str, NULL, NULL);
-+ gaim2_notify_userinfo(info_data->gc, info_data->name, s->str, NULL, NULL);
-
- g_free(stripped);
- g_free(url_buffer);
-@@ -1796,12 +1796,12 @@ msn_got_photo(void *data, const char *ur
- g_free(photo_url_text);
- g_free(info2_data);
- if (id != -1)
-- gaim_imgstore_unref(id);
-+ gaim2_imgstore_unref(id);
- #endif
- }
-
- static void
--msn_get_info(GaimConnection *gc, const char *name)
-+msn_get_info(Gaim2Connection *gc, const char *name)
- {
- MsnGetInfoData *data;
- char *url;
-@@ -1812,14 +1812,14 @@ msn_get_info(GaimConnection *gc, const c
-
- url = g_strdup_printf("%s%s", PROFILE_URL, name);
-
-- gaim_url_fetch(url, FALSE,
-+ gaim2_url_fetch(url, FALSE,
- "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)",
- TRUE, msn_got_info, data);
-
- g_free(url);
- }
-
--static gboolean msn_load(GaimPlugin *plugin)
-+static gboolean msn_load(Gaim2Plugin *plugin)
- {
- msn_notification_init();
- msn_switchboard_init();
-@@ -1828,7 +1828,7 @@ static gboolean msn_load(GaimPlugin *plu
- return TRUE;
- }
-
--static gboolean msn_unload(GaimPlugin *plugin)
-+static gboolean msn_unload(Gaim2Plugin *plugin)
- {
- msn_notification_end();
- msn_switchboard_end();
-@@ -1837,7 +1837,7 @@ static gboolean msn_unload(GaimPlugin *p
- return TRUE;
- }
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_MAIL_CHECK,
- NULL, /* user_splits */
-@@ -1902,7 +1902,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -1934,30 +1934,30 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_string_new(_("Login server"), "server",
-+ option = gaim2_account_option_string_new(_("Login server"), "server",
- MSN_SERVER);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_int_new(_("Port"), "port", 1863);
-+ option = gaim2_account_option_int_new(_("Port"), "port", 1863);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_bool_new(_("Use HTTP Method"),
-+ option = gaim2_account_option_bool_new(_("Use HTTP Method"),
- "http_method", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- gaim_cmd_register("nudge", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("nudge", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-msn", msn_cmd_nudge,
- _("nudge: nudge a user to get their attention"), NULL);
-
-- gaim_prefs_remove("/plugins/prpl/msn");
-+ gaim2_prefs_remove("/plugins/prpl/msn");
- }
-
- GAIM_INIT_PLUGIN(msn, init_plugin, info);
-diff -prNu ./src/protocols/msn/msn.h ./src/protocols/msn/msn.h
---- ./src/protocols/msn/msn.h 2005-10-08 02:51:51.000000000 +0200
-+++ ./src/protocols/msn/msn.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file msn.h The MSN protocol plugin
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -76,7 +76,7 @@
- #define MSN_FT_GUID "{5D3E02AB-6190-11d3-BBBB-00C04F795683}"
-
- #define MSN_CLIENTINFO \
-- "Client-Name: Gaim/" VERSION "\r\n" \
-+ "Client-Name: Gaim2/" VERSION "\r\n" \
- "Chat-Logging: Y\r\n"
-
-
-diff -prNu ./src/protocols/msn/nexus.c ./src/protocols/msn/nexus.c
---- ./src/protocols/msn/nexus.c 2005-12-12 06:48:08.000000000 +0100
-+++ ./src/protocols/msn/nexus.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file nexus.c MSN Nexus functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -62,13 +62,13 @@ msn_nexus_destroy(MsnNexus *nexus)
- **************************************************************************/
-
- static size_t
--msn_ssl_read(GaimSslConnection *gsc, char **dest_buffer)
-+msn_ssl_read(Gaim2SslConnection *gsc, char **dest_buffer)
- {
- gssize size = 0, s;
- char *buffer = NULL;
- char temp_buf[4096];
-
-- while ((s = gaim_ssl_read(gsc, temp_buf, sizeof(temp_buf))) > 0)
-+ while ((s = gaim2_ssl_read(gsc, temp_buf, sizeof(temp_buf))) > 0)
- {
- buffer = g_realloc(buffer, size + s + 1);
-
-@@ -89,7 +89,7 @@ msn_ssl_read(GaimSslConnection *gsc, cha
- **************************************************************************/
-
- static void
--login_error_cb(GaimSslConnection *gsc, GaimSslErrorType error, void *data)
-+login_error_cb(Gaim2SslConnection *gsc, Gaim2SslErrorType error, void *data)
- {
- MsnNexus *nexus;
- MsnSession *session;
-@@ -106,8 +106,8 @@ login_error_cb(GaimSslConnection *gsc, G
- }
-
- static void
--login_connect_cb(gpointer data, GaimSslConnection *gsc,
-- GaimInputCondition cond)
-+login_connect_cb(gpointer data, Gaim2SslConnection *gsc,
-+ Gaim2InputCondition cond)
- {
- MsnNexus *nexus;
- MsnSession *session;
-@@ -126,10 +126,10 @@ login_connect_cb(gpointer data, GaimSslC
- msn_session_set_login_step(session, MSN_LOGIN_STEP_GET_COOKIE);
-
- username =
-- g_strdup(gaim_url_encode(gaim_account_get_username(session->account)));
-+ g_strdup(gaim2_url_encode(gaim2_account_get_username(session->account)));
-
- password =
-- g_strdup(gaim_url_encode(gaim_connection_get_password(session->account->gc)));
-+ g_strdup(gaim2_url_encode(gaim2_connection_get_password(session->account->gc)));
-
- ctint = strtoul((char *)g_hash_table_lookup(nexus->challenge_data, "ct"), NULL, 10) + 200;
-
-@@ -161,7 +161,7 @@ login_connect_cb(gpointer data, GaimSslC
- buffer = g_strdup_printf("%s,pwd=XXXXXXXX,%s\r\n", head, tail);
- request_str = g_strdup_printf("%s,pwd=%s,%s\r\n", head, password, tail);
-
-- gaim_debug_misc("msn", "Sending: {%s}\n", buffer);
-+ gaim2_debug_misc("msn", "Sending: {%s}\n", buffer);
-
- g_free(buffer);
- g_free(head);
-@@ -169,7 +169,7 @@ login_connect_cb(gpointer data, GaimSslC
- g_free(username);
- g_free(password);
-
-- if ((s = gaim_ssl_write(gsc, request_str, strlen(request_str))) <= 0)
-+ if ((s = gaim2_ssl_write(gsc, request_str, strlen(request_str))) <= 0)
- {
- g_free(request_str);
-
-@@ -181,9 +181,9 @@ login_connect_cb(gpointer data, GaimSslC
- if ((s = msn_ssl_read(gsc, &buffer)) <= 0)
- return;
-
-- gaim_ssl_close(gsc);
-+ gaim2_ssl_close(gsc);
-
-- gaim_debug_misc("msn", "ssl buffer: {%s}", buffer);
-+ gaim2_debug_misc("msn", "ssl buffer: {%s}", buffer);
-
- if (strstr(buffer, "HTTP/1.1 302") != NULL)
- {
-@@ -217,7 +217,7 @@ login_connect_cb(gpointer data, GaimSslC
- g_free(nexus->login_host);
- nexus->login_host = g_strdup(location);
-
-- gaim_ssl_connect(session->account, nexus->login_host,
-+ gaim2_ssl_connect(session->account, nexus->login_host,
- GAIM_SSL_DEFAULT_PORT, login_connect_cb,
- login_error_cb, nexus);
- }
-@@ -238,7 +238,7 @@ login_connect_cb(gpointer data, GaimSslC
- c = error + strlen(error);
-
- temp = g_strndup(error, c - error);
-- error = gaim_url_decode(temp);
-+ error = gaim2_url_decode(temp);
- g_free(temp);
- }
- }
-@@ -293,8 +293,8 @@ login_connect_cb(gpointer data, GaimSslC
- **************************************************************************/
-
- static void
--nexus_connect_cb(gpointer data, GaimSslConnection *gsc,
-- GaimInputCondition cond)
-+nexus_connect_cb(gpointer data, Gaim2SslConnection *gsc,
-+ Gaim2InputCondition cond)
- {
- MsnNexus *nexus;
- MsnSession *session;
-@@ -314,7 +314,7 @@ nexus_connect_cb(gpointer data, GaimSslC
-
- request_str = g_strdup_printf("GET /rdr/pprdr.asp\r\n\r\n");
-
-- if ((s = gaim_ssl_write(gsc, request_str, strlen(request_str))) <= 0)
-+ if ((s = gaim2_ssl_write(gsc, request_str, strlen(request_str))) <= 0)
- {
- g_free(request_str);
- return;
-@@ -354,10 +354,10 @@ nexus_connect_cb(gpointer data, GaimSslC
-
- g_free(buffer);
-
-- gaim_ssl_close(gsc);
-+ gaim2_ssl_close(gsc);
-
- /* Now begin the connection to the login server. */
-- gaim_ssl_connect(session->account, nexus->login_host,
-+ gaim2_ssl_connect(session->account, nexus->login_host,
- GAIM_SSL_DEFAULT_PORT, login_connect_cb,
- login_error_cb, nexus);
- }
-@@ -365,7 +365,7 @@ nexus_connect_cb(gpointer data, GaimSslC
- void
- msn_nexus_connect(MsnNexus *nexus)
- {
-- gaim_ssl_connect(nexus->session->account, "nexus.passport.com",
-+ gaim2_ssl_connect(nexus->session->account, "nexus.passport.com",
- GAIM_SSL_DEFAULT_PORT, nexus_connect_cb,
- login_error_cb, nexus);
- }
-diff -prNu ./src/protocols/msn/nexus.h ./src/protocols/msn/nexus.h
---- ./src/protocols/msn/nexus.h 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/nexus.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file nexus.h MSN Nexus functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/notification.c ./src/protocols/msn/notification.c
---- ./src/protocols/msn/notification.c 2005-11-06 22:52:00.000000000 +0100
-+++ ./src/protocols/msn/notification.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file notification.c Notification server functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -91,7 +91,7 @@ connect_cb(MsnServConn *servconn)
- {
- MsnCmdProc *cmdproc;
- MsnSession *session;
-- GaimAccount *account;
-+ Gaim2Account *account;
- char **a, **c, *vers;
- int i;
-
-@@ -155,13 +155,13 @@ msn_notification_disconnect(MsnNotificat
- static void
- group_error_helper(MsnSession *session, const char *msg, int group_id, int error)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- char *reason = NULL;
- char *title = NULL;
-
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (error == 224)
- {
-@@ -185,9 +185,9 @@ group_error_helper(MsnSession *session,
- }
-
- title = g_strdup_printf(_("%s on %s (%s)"), msg,
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-- gaim_notify_error(gc, NULL, title, reason);
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
-+ gaim2_notify_error(gc, NULL, title, reason);
- g_free(title);
- g_free(reason);
- }
-@@ -211,31 +211,31 @@ msn_got_login_params(MsnSession *session
- static void
- cvr_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- account = cmdproc->session->account;
-
- msn_cmdproc_send(cmdproc, "USR", "TWN I %s",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- }
-
- static void
- usr_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
- MsnSession *session;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-
- session = cmdproc->session;
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (!g_ascii_strcasecmp(cmd->params[1], "OK"))
- {
- /* OK */
-- const char *friendly = gaim_url_decode(cmd->params[3]);
-+ const char *friendly = gaim2_url_decode(cmd->params[3]);
-
-- gaim_connection_set_display_name(gc, friendly);
-+ gaim2_connection_set_display_name(gc, friendly);
-
- msn_session_set_login_step(session, MSN_LOGIN_STEP_SYN);
-
-@@ -296,7 +296,7 @@ static void
- ver_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
- MsnSession *session;
-- GaimAccount *account;
-+ Gaim2Account *account;
- gboolean protocol_supported = FALSE;
- char proto_str[8];
- size_t i;
-@@ -324,7 +324,7 @@ ver_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- msn_cmdproc_send(cmdproc, "CVR",
- "0x0409 winnt 5.1 i386 MSNMSGR 6.0.0602 MSMSGS %s",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- }
-
- /**************************************************************************
-@@ -405,23 +405,23 @@ chl_cmd(MsnCmdProc *cmdproc, MsnCommand
- MsnTransaction *trans;
- char buf[33];
- const char *challenge_resp;
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar digest[16];
- int i;
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
-- gaim_cipher_context_append(context, (const guchar *)cmd->params[1],
-+ gaim2_cipher_context_append(context, (const guchar *)cmd->params[1],
- strlen(cmd->params[1]));
-
- challenge_resp = "VT6PX?UQTM4WM%YR";
-
-- gaim_cipher_context_append(context, (const guchar *)challenge_resp,
-+ gaim2_cipher_context_append(context, (const guchar *)challenge_resp,
- strlen(challenge_resp));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- for (i = 0; i < 16; i++)
- g_snprintf(buf + (i*2), 3, "%02x", digest[i]);
-@@ -450,7 +450,7 @@ add_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- list = cmd->params[1];
- passport = cmd->params[3];
-- friendly = gaim_url_decode(cmd->params[4]);
-+ friendly = gaim2_url_decode(cmd->params[4]);
-
- session = cmdproc->session;
-
-@@ -479,8 +479,8 @@ static void
- add_error(MsnCmdProc *cmdproc, MsnTransaction *trans, int error)
- {
- MsnSession *session;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- const char *list, *passport;
- char *reason = NULL;
- char *msg = NULL;
-@@ -488,7 +488,7 @@ add_error(MsnCmdProc *cmdproc, MsnTransa
-
- session = cmdproc->session;
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- params = g_strsplit(trans->params, " ", 0);
-
- list = params[0];
-@@ -496,16 +496,16 @@ add_error(MsnCmdProc *cmdproc, MsnTransa
-
- if (!strcmp(list, "FL"))
- msg = g_strdup_printf(_("Unable to add user on %s (%s)"),
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
- else if (!strcmp(list, "BL"))
- msg = g_strdup_printf(_("Unable to block user on %s (%s)"),
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
- else if (!strcmp(list, "AL"))
- msg = g_strdup_printf(_("Unable to permit user on %s (%s)"),
-- gaim_account_get_username(account),
-- gaim_account_get_protocol_name(account));
-+ gaim2_account_get_username(account),
-+ gaim2_account_get_protocol_name(account));
-
- if (!strcmp(list, "FL"))
- {
-@@ -535,18 +535,18 @@ add_error(MsnCmdProc *cmdproc, MsnTransa
-
- if (msg != NULL)
- {
-- gaim_notify_error(gc, NULL, msg, reason);
-+ gaim2_notify_error(gc, NULL, msg, reason);
- g_free(msg);
- }
-
- if (!strcmp(list, "FL"))
- {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- buddy = gaim_find_buddy(account, passport);
-+ buddy = gaim2_find_buddy(account, passport);
-
- if (buddy != NULL)
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- }
-
- g_free(reason);
-@@ -566,7 +566,7 @@ adg_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- group_id = atoi(cmd->params[3]);
-
-- group_name = gaim_url_decode(cmd->params[2]);
-+ group_name = gaim2_url_decode(cmd->params[2]);
-
- group = msn_group_new(session->userlist, group_id, group_name);
-
-@@ -611,19 +611,19 @@ static void
- iln_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
- MsnSession *session;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- MsnUser *user;
- MsnObject *msnobj;
- const char *state, *passport, *friendly;
-
- session = cmdproc->session;
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- state = cmd->params[1];
- passport = cmd->params[2];
-- friendly = gaim_url_decode(cmd->params[3]);
-+ friendly = gaim2_url_decode(cmd->params[3]);
-
- user = msn_userlist_find_user(session->userlist, passport);
-
-@@ -633,7 +633,7 @@ iln_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- if (session->protocol_ver >= 9 && cmd->param_count == 6)
- {
-- msnobj = msn_object_new_from_string(gaim_url_decode(cmd->params[5]));
-+ msnobj = msn_object_new_from_string(gaim2_url_decode(cmd->params[5]));
- msn_user_set_object(user, msnobj);
- }
-
-@@ -645,7 +645,7 @@ static void
- ipg_cmd_post(MsnCmdProc *cmdproc, MsnCommand *cmd, char *payload, size_t len)
- {
- #if 0
-- gaim_debug_misc("msn", "Incoming Page: {%s}\n", payload);
-+ gaim2_debug_misc("msn", "Incoming Page: {%s}\n", payload);
- #endif
- }
-
-@@ -660,8 +660,8 @@ static void
- nln_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
- MsnSession *session;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- MsnUser *user;
- MsnObject *msnobj;
- int clientid;
-@@ -669,11 +669,11 @@ nln_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- session = cmdproc->session;
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- state = cmd->params[0];
- passport = cmd->params[1];
-- friendly = gaim_url_decode(cmd->params[2]);
-+ friendly = gaim2_url_decode(cmd->params[2]);
-
- user = msn_userlist_find_user(session->userlist, passport);
-
-@@ -686,7 +686,7 @@ nln_cmd(MsnCmdProc *cmdproc, MsnCommand
- if (cmd->param_count == 5)
- {
- msnobj =
-- msn_object_new_from_string(gaim_url_decode(cmd->params[4]));
-+ msn_object_new_from_string(gaim2_url_decode(cmd->params[4]));
- msn_user_set_object(user, msnobj);
- }
- else
-@@ -736,7 +736,7 @@ not_cmd_post(MsnCmdProc *cmdproc, MsnCom
- {
- #if 0
- MSN_SET_PARAMS("NOT %d\r\n%s", cmdproc->servconn->payload, payload);
-- gaim_debug_misc("msn", "Notification: {%s}\n", payload);
-+ gaim2_debug_misc("msn", "Notification: {%s}\n", payload);
- #endif
- }
-
-@@ -753,14 +753,14 @@ rea_cmd(MsnCmdProc *cmdproc, MsnCommand
- /* TODO: This might be for us too */
-
- MsnSession *session;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *friendly;
-
- session = cmdproc->session;
- gc = session->account->gc;
-- friendly = gaim_url_decode(cmd->params[3]);
-+ friendly = gaim2_url_decode(cmd->params[3]);
-
-- gaim_connection_set_display_name(gc, friendly);
-+ gaim2_connection_set_display_name(gc, friendly);
- }
-
- static void
-@@ -777,11 +777,11 @@ prp_cmd(MsnCmdProc *cmdproc, MsnCommand
- {
- value = cmd->params[3];
- if (!strcmp(type, "PHH"))
-- msn_user_set_home_phone(session->user, gaim_url_decode(value));
-+ msn_user_set_home_phone(session->user, gaim2_url_decode(value));
- else if (!strcmp(type, "PHW"))
-- msn_user_set_work_phone(session->user, gaim_url_decode(value));
-+ msn_user_set_work_phone(session->user, gaim2_url_decode(value));
- else if (!strcmp(type, "PHM"))
-- msn_user_set_mobile_phone(session->user, gaim_url_decode(value));
-+ msn_user_set_mobile_phone(session->user, gaim2_url_decode(value));
- }
- else
- {
-@@ -803,7 +803,7 @@ reg_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- session = cmdproc->session;
- group_id = atoi(cmd->params[2]);
-- group_name = gaim_url_decode(cmd->params[3]);
-+ group_name = gaim2_url_decode(cmd->params[3]);
-
- msn_userlist_rename_group_id(session->userlist, group_id, group_name);
- }
-@@ -926,11 +926,11 @@ static void
- url_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
- MsnSession *session;
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *rru;
- const char *url;
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar digest[16];
- FILE *fd;
- char *buf;
-@@ -947,14 +947,14 @@ url_cmd(MsnCmdProc *cmdproc, MsnCommand
- buf = g_strdup_printf("%s%lu%s",
- session->passport_info.mspauth,
- time(NULL) - session->passport_info.sl,
-- gaim_connection_get_password(account->gc));
-+ gaim2_connection_get_password(account->gc));
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
-- gaim_cipher_context_append(context, (const guchar *)buf, strlen(buf));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_append(context, (const guchar *)buf, strlen(buf));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- g_free(buf);
-
-@@ -972,9 +972,9 @@ url_cmd(MsnCmdProc *cmdproc, MsnCommand
- g_free(session->passport_info.file);
- }
-
-- if ((fd = gaim_mkstemp(&session->passport_info.file, FALSE)) == NULL)
-+ if ((fd = gaim2_mkstemp(&session->passport_info.file, FALSE)) == NULL)
- {
-- gaim_debug_error("msn",
-+ gaim2_debug_error("msn",
- "Error opening temp passport file: %s\n",
- strerror(errno));
- }
-@@ -994,9 +994,9 @@ url_cmd(MsnCmdProc *cmdproc, MsnCommand
- url);
- fprintf(fd, "<input type=\"hidden\" name=\"mode\" value=\"ttl\">\n");
- fprintf(fd, "<input type=\"hidden\" name=\"login\" value=\"%s\">\n",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- fprintf(fd, "<input type=\"hidden\" name=\"username\" value=\"%s\">\n",
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
- fprintf(fd, "<input type=\"hidden\" name=\"sid\" value=\"%s\">\n",
- session->passport_info.sid);
- fprintf(fd, "<input type=\"hidden\" name=\"kv\" value=\"%s\">\n",
-@@ -1017,7 +1017,7 @@ url_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- if (fclose(fd))
- {
-- gaim_debug_error("msn",
-+ gaim2_debug_error("msn",
- "Error closing temp passport file: %s\n",
- strerror(errno));
-
-@@ -1095,7 +1095,7 @@ xfr_cmd(MsnCmdProc *cmdproc, MsnCommand
- if (strcmp(cmd->params[1], "SB") && strcmp(cmd->params[1], "NS"))
- {
- /* Maybe we can have a generic bad command error. */
-- gaim_debug_error("msn", "Bad XFR command (%s)\n", cmd->params[1]);
-+ gaim2_debug_error("msn", "Bad XFR command (%s)\n", cmd->params[1]);
- return;
- }
-
-@@ -1103,7 +1103,7 @@ xfr_cmd(MsnCmdProc *cmdproc, MsnCommand
-
- if (!strcmp(cmd->params[1], "SB"))
- {
-- gaim_debug_error("msn", "This shouldn't be handled here.\n");
-+ gaim2_debug_error("msn", "This shouldn't be handled here.\n");
- }
- else if (!strcmp(cmd->params[1], "NS"))
- {
-@@ -1178,7 +1178,7 @@ static void
- initial_email_msg(MsnCmdProc *cmdproc, MsnMessage *msg)
- {
- MsnSession *session;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GHashTable *table;
- const char *unread;
-
-@@ -1200,7 +1200,7 @@ initial_email_msg(MsnCmdProc *cmdproc, M
- return;
- }
-
-- if (!gaim_account_get_check_mail(session->account))
-+ if (!gaim2_account_get_check_mail(session->account))
- return;
-
- table = msn_message_get_hashtable_from_body(msg);
-@@ -1219,7 +1219,7 @@ initial_email_msg(MsnCmdProc *cmdproc, M
- passport = msn_user_get_passport(session->user);
- url = session->passport_info.file;
-
-- gaim_notify_emails(gc, atoi(unread), FALSE, NULL, NULL,
-+ gaim2_notify_emails(gc, atoi(unread), FALSE, NULL, NULL,
- &passport, &url, NULL, NULL);
- }
- }
-@@ -1231,7 +1231,7 @@ static void
- email_msg(MsnCmdProc *cmdproc, MsnMessage *msg)
- {
- MsnSession *session;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GHashTable *table;
- char *from, *subject, *tmp;
-
-@@ -1253,7 +1253,7 @@ email_msg(MsnCmdProc *cmdproc, MsnMessag
- return;
- }
-
-- if (!gaim_account_get_check_mail(session->account))
-+ if (!gaim2_account_get_check_mail(session->account))
- return;
-
- table = msn_message_get_hashtable_from_body(msg);
-@@ -1262,13 +1262,13 @@ email_msg(MsnCmdProc *cmdproc, MsnMessag
-
- tmp = g_hash_table_lookup(table, "From");
- if (tmp != NULL)
-- from = gaim_mime_decode_field(tmp);
-+ from = gaim2_mime_decode_field(tmp);
-
- tmp = g_hash_table_lookup(table, "Subject");
- if (tmp != NULL)
-- subject = gaim_mime_decode_field(tmp);
-+ subject = gaim2_mime_decode_field(tmp);
-
-- gaim_notify_email(gc,
-+ gaim2_notify_email(gc,
- (subject != NULL ? subject : ""),
- (from != NULL ? from : ""),
- msn_user_get_passport(session->user),
-@@ -1324,7 +1324,7 @@ system_msg(MsnCmdProc *cmdproc, MsnMessa
- }
-
- if (*buf != '\0')
-- gaim_notify_info(cmdproc->session->account->gc, NULL, buf, NULL);
-+ gaim2_notify_info(cmdproc->session->account->gc, NULL, buf, NULL);
- }
-
- g_hash_table_destroy(table);
-diff -prNu ./src/protocols/msn/notification.h ./src/protocols/msn/notification.h
---- ./src/protocols/msn/notification.h 2005-01-07 03:48:33.000000000 +0100
-+++ ./src/protocols/msn/notification.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file notification.h Notification server functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/object.c ./src/protocols/msn/object.c
---- ./src/protocols/msn/object.c 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/msn/object.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file object.c MSNObject API
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/object.h ./src/protocols/msn/object.h
---- ./src/protocols/msn/object.h 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/msn/object.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file object.h MSNObject API
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/page.c ./src/protocols/msn/page.c
---- ./src/protocols/msn/page.c 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/page.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file page.c Paging functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/page.h ./src/protocols/msn/page.h
---- ./src/protocols/msn/page.h 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/page.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file page.h Paging functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/servconn.c ./src/protocols/msn/servconn.c
---- ./src/protocols/msn/servconn.c 2005-11-24 17:04:45.000000000 +0100
-+++ ./src/protocols/msn/servconn.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file servconn.c Server connection functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,7 +25,7 @@
- #include "servconn.h"
- #include "error.h"
-
--static void read_cb(gpointer data, gint source, GaimInputCondition cond);
-+static void read_cb(gpointer data, gint source, Gaim2InputCondition cond);
-
- /**************************************************************************
- * Main
-@@ -133,7 +133,7 @@ msn_servconn_got_error(MsnServConn *serv
- reason = _("Unknown error"); break;
- }
-
-- gaim_debug_error("msn", "Connection error from %s server (%s): %s\n",
-+ gaim2_debug_error("msn", "Connection error from %s server (%s): %s\n",
- name, servconn->host, reason);
- tmp = g_strdup_printf(_("Connection error from %s server:\n%s"),
- name, reason);
-@@ -160,7 +160,7 @@ msn_servconn_got_error(MsnServConn *serv
- **************************************************************************/
-
- static void
--connect_cb(gpointer data, gint source, GaimInputCondition cond)
-+connect_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
- MsnServConn *servconn = data;
-
-@@ -180,7 +180,7 @@ connect_cb(gpointer data, gint source, G
-
- /* Someone wants to know we connected. */
- servconn->connect_cb(servconn);
-- servconn->inpa = gaim_input_add(servconn->fd, GAIM_INPUT_READ,
-+ servconn->inpa = gaim2_input_add(servconn->fd, GAIM_INPUT_READ,
- read_cb, data);
- }
- else
-@@ -226,7 +226,7 @@ msn_servconn_connect(MsnServConn *servco
- return TRUE;
- }
-
-- r = gaim_proxy_connect(session->account, host, port, connect_cb,
-+ r = gaim2_proxy_connect(session->account, host, port, connect_cb,
- servconn);
-
- if (r == 0)
-@@ -263,7 +263,7 @@ msn_servconn_disconnect(MsnServConn *ser
-
- if (servconn->inpa > 0)
- {
-- gaim_input_remove(servconn->inpa);
-+ gaim2_input_remove(servconn->inpa);
- servconn->inpa = 0;
- }
-
-@@ -319,7 +319,7 @@ msn_servconn_write(MsnServConn *servconn
- }
-
- static void
--read_cb(gpointer data, gint source, GaimInputCondition cond)
-+read_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
- MsnServConn *servconn;
- MsnSession *session;
-@@ -334,7 +334,7 @@ read_cb(gpointer data, gint source, Gaim
-
- if (len <= 0)
- {
-- gaim_debug_error("msn", "servconn read error, len: %d error: %s\n", len, strerror(errno));
-+ gaim2_debug_error("msn", "servconn read error, len: %d error: %s\n", len, strerror(errno));
- msn_servconn_got_error(servconn, MSN_SERVCONN_ERROR_READ);
-
- return;
-@@ -427,7 +427,7 @@ create_listener(int port)
-
- if (getaddrinfo(NULL, port_str, &hints, &res) != 0)
- {
-- gaim_debug_error("msn", "Could not get address info: %s.\n",
-+ gaim2_debug_error("msn", "Could not get address info: %s.\n",
- port_str);
- return -1;
- }
-@@ -449,7 +449,7 @@ create_listener(int port)
-
- if (c == NULL)
- {
-- gaim_debug_error("msn", "Could not find socket: %s.\n", port_str);
-+ gaim2_debug_error("msn", "Could not find socket: %s.\n", port_str);
- return -1;
- }
-
-diff -prNu ./src/protocols/msn/servconn.h ./src/protocols/msn/servconn.h
---- ./src/protocols/msn/servconn.h 2005-01-07 03:48:33.000000000 +0100
-+++ ./src/protocols/msn/servconn.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file servconn.h Server connection functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/session.c ./src/protocols/msn/session.c
---- ./src/protocols/msn/session.c 2005-11-06 22:52:00.000000000 +0100
-+++ ./src/protocols/msn/session.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file session.c MSN session functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,7 +28,7 @@
- #include "dialog.h"
-
- MsnSession *
--msn_session_new(GaimAccount *account)
-+msn_session_new(Gaim2Account *account)
- {
- MsnSession *session;
-
-@@ -41,7 +41,7 @@ msn_session_new(GaimAccount *account)
- session->userlist = msn_userlist_new(session);
-
- session->user = msn_user_new(session->userlist,
-- gaim_account_get_username(account), NULL);
-+ gaim2_account_get_username(account), NULL);
-
- session->protocol_ver = 9;
- session->conv_seq = 1;
-@@ -112,7 +112,7 @@ msn_session_connect(MsnSession *session,
-
- if (session->notification == NULL)
- {
-- gaim_debug_error("msn", "This shouldn't happen\n");
-+ gaim2_debug_error("msn", "This shouldn't happen\n");
- g_return_val_if_reached(FALSE);
- }
-
-@@ -162,7 +162,7 @@ msn_session_find_swboard(MsnSession *ses
- }
-
- MsnSwitchBoard *
--msn_session_find_swboard_with_conv(MsnSession *session, GaimConversation *conv)
-+msn_session_find_swboard_with_conv(MsnSession *session, Gaim2Conversation *conv)
- {
- GList *l;
-
-@@ -227,8 +227,8 @@ msn_session_get_swboard(MsnSession *sess
- static void
- msn_session_sync_users(MsnSession *session)
- {
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimConnection *gc = gaim_account_get_connection(session->account);
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Connection *gc = gaim2_account_get_connection(session->account);
-
- g_return_if_fail(gc != NULL);
-
-@@ -236,8 +236,8 @@ msn_session_sync_users(MsnSession *sessi
- * being logged in. This no longer happens, so we manually iterate
- * over the whole buddy list to identify sync issues. */
-
-- for (gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-- GaimGroup *group = (GaimGroup *)gnode;
-+ for (gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
-+ Gaim2Group *group = (Gaim2Group *)gnode;
- const char *group_name = group->name;
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-@@ -245,10 +245,10 @@ msn_session_sync_users(MsnSession *sessi
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for(bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if(b->account == gc->account) {
- MsnUser *remote_user;
- gboolean found = FALSE;
-@@ -290,10 +290,10 @@ void
- msn_session_set_error(MsnSession *session, MsnErrorType error,
- const char *info)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *msg;
-
-- gc = gaim_account_get_connection(session->account);
-+ gc = gaim2_account_get_connection(session->account);
-
- switch (error)
- {
-@@ -337,7 +337,7 @@ msn_session_set_error(MsnSession *sessio
-
- msn_session_disconnect(session);
-
-- gaim_connection_error(gc, msg);
-+ gaim2_connection_error(gc, msg);
-
- g_free(msg);
- }
-@@ -363,7 +363,7 @@ get_login_step_text(MsnSession *session)
- void
- msn_session_set_login_step(MsnSession *session, MsnLoginStep step)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- /* Prevent the connection progress going backwards, eg. if we get
- * transferred several times during login */
-@@ -380,24 +380,24 @@ msn_session_set_login_step(MsnSession *s
-
- session->login_step = step;
-
-- gaim_connection_update_progress(gc, get_login_step_text(session), step,
-+ gaim2_connection_update_progress(gc, get_login_step_text(session), step,
- MSN_LOGIN_STEPS);
- }
-
- void
- msn_session_finish_login(MsnSession *session)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- char *icon;
-
- if (session->logged_in)
- return;
-
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
-- icon = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(session->account));
-+ icon = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(session->account));
- msn_user_set_buddy_icon(session->user, icon);
- g_free(icon);
-
-@@ -405,7 +405,7 @@ msn_session_finish_login(MsnSession *ses
-
- msn_change_status(session);
-
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- /* Sync users */
- msn_session_sync_users(session);
-diff -prNu ./src/protocols/msn/session.h ./src/protocols/msn/session.h
---- ./src/protocols/msn/session.h 2005-11-06 22:52:00.000000000 +0100
-+++ ./src/protocols/msn/session.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file session.h MSN session functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -78,7 +78,7 @@ typedef enum
-
- struct _MsnSession
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnUser *user;
-
- guint protocol_ver;
-@@ -123,7 +123,7 @@ struct _MsnSession
- *
- * @return The new MSN session.
- */
--MsnSession *msn_session_new(GaimAccount *account);
-+MsnSession *msn_session_new(Gaim2Account *account);
-
- /**
- * Destroys an MSN session.
-@@ -173,7 +173,7 @@ MsnSwitchBoard *msn_session_find_swboard
- * @return The switchboard, if found.
- */
- MsnSwitchBoard *msn_session_find_swboard_with_conv(MsnSession *session,
-- GaimConversation *conv);
-+ Gaim2Conversation *conv);
- /**
- * Finds a switchboard with the given chat ID.
- *
-diff -prNu ./src/protocols/msn/slp.c ./src/protocols/msn/slp.c
---- ./src/protocols/msn/slp.c 2005-12-22 05:07:21.000000000 +0100
-+++ ./src/protocols/msn/slp.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file msnslp.c MSNSLP support
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -73,13 +73,13 @@ get_token(const char *str, const char *s
- **************************************************************************/
-
- static void
--msn_xfer_init(GaimXfer *xfer)
-+msn_xfer_init(Gaim2Xfer *xfer)
- {
- MsnSlpCall *slpcall;
- /* MsnSlpLink *slplink; */
- char *content;
-
-- gaim_debug_info("msn", "xfer_init\n");
-+ gaim2_debug_info("msn", "xfer_init\n");
-
- slpcall = xfer->data;
-
-@@ -95,7 +95,7 @@ msn_xfer_init(GaimXfer *xfer)
- }
-
- void
--msn_xfer_cancel(GaimXfer *xfer)
-+msn_xfer_cancel(Gaim2Xfer *xfer)
- {
- MsnSlpCall *slpcall;
- char *content;
-@@ -105,7 +105,7 @@ msn_xfer_cancel(GaimXfer *xfer)
-
- slpcall = xfer->data;
-
-- if (gaim_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_LOCAL)
-+ if (gaim2_xfer_get_status(xfer) == GAIM_XFER_STATUS_CANCEL_LOCAL)
- {
- if (slpcall->started)
- {
-@@ -130,24 +130,24 @@ msn_xfer_cancel(GaimXfer *xfer)
- void
- msn_xfer_progress_cb(MsnSlpCall *slpcall, gsize total_length, gsize len, gsize offset)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- xfer = slpcall->xfer;
-
- xfer->bytes_sent = (offset + len);
- xfer->bytes_remaining = total_length - (offset + len);
-
-- gaim_xfer_update_progress(xfer);
-+ gaim2_xfer_update_progress(xfer);
- }
-
- void
- msn_xfer_end_cb(MsnSlpCall *slpcall)
- {
-- if ((gaim_xfer_get_status(slpcall->xfer) != GAIM_XFER_STATUS_DONE) &&
-- (gaim_xfer_get_status(slpcall->xfer) != GAIM_XFER_STATUS_CANCEL_REMOTE) &&
-- (gaim_xfer_get_status(slpcall->xfer) != GAIM_XFER_STATUS_CANCEL_LOCAL))
-+ if ((gaim2_xfer_get_status(slpcall->xfer) != GAIM_XFER_STATUS_DONE) &&
-+ (gaim2_xfer_get_status(slpcall->xfer) != GAIM_XFER_STATUS_CANCEL_REMOTE) &&
-+ (gaim2_xfer_get_status(slpcall->xfer) != GAIM_XFER_STATUS_CANCEL_LOCAL))
- {
-- gaim_xfer_cancel_remote(slpcall->xfer);
-+ gaim2_xfer_cancel_remote(slpcall->xfer);
- }
- }
-
-@@ -155,7 +155,7 @@ void
- msn_xfer_completed_cb(MsnSlpCall *slpcall, const guchar *body,
- gsize size)
- {
-- gaim_xfer_set_completed(slpcall->xfer, TRUE);
-+ gaim2_xfer_set_completed(slpcall->xfer, TRUE);
- }
-
- /**************************************************************************
-@@ -181,7 +181,7 @@ got_transresp(MsnSlpCall *slpcall, const
-
- for (c = ip_addrs; *c != NULL; c++)
- {
-- gaim_debug_info("msn", "ip_addr = %s\n", *c);
-+ gaim2_debug_info("msn", "ip_addr = %s\n", *c);
- if (msn_directconn_connect(directconn, *c, port))
- break;
- }
-@@ -267,7 +267,7 @@ got_sessionreq(MsnSlpCall *slpcall, cons
-
- slplink = slpcall->slplink;
-
-- msnobj_data = (char *)gaim_base64_decode(context, &len);
-+ msnobj_data = (char *)gaim2_base64_decode(context, &len);
- obj = msn_object_new_from_string(msnobj_data);
- type = msn_object_get_type(obj);
- sha1c = msn_object_get_sha1c(obj);
-@@ -275,7 +275,7 @@ got_sessionreq(MsnSlpCall *slpcall, cons
-
- if (!(type == MSN_OBJECT_USERTILE))
- {
-- gaim_debug_error("msn", "Wrong object?\n");
-+ gaim2_debug_error("msn", "Wrong object?\n");
- msn_object_destroy(obj);
- g_return_if_reached();
- }
-@@ -284,7 +284,7 @@ got_sessionreq(MsnSlpCall *slpcall, cons
-
- if (file_name == NULL)
- {
-- gaim_debug_error("msn", "Wrong object.\n");
-+ gaim2_debug_error("msn", "Wrong object.\n");
- msn_object_destroy(obj);
- g_return_if_reached();
- }
-@@ -319,8 +319,8 @@ got_sessionreq(MsnSlpCall *slpcall, cons
- else if (!strcmp(euf_guid, "5D3E02AB-6190-11D3-BBBB-00C04F795683"))
- {
- /* File Transfer */
-- GaimAccount *account;
-- GaimXfer *xfer;
-+ Gaim2Account *account;
-+ Gaim2Xfer *xfer;
- char *bin;
- gsize bin_len;
- guint32 file_size;
-@@ -336,10 +336,10 @@ got_sessionreq(MsnSlpCall *slpcall, cons
-
- slpcall->pending = TRUE;
-
-- xfer = gaim_xfer_new(account, GAIM_XFER_RECEIVE,
-+ xfer = gaim2_xfer_new(account, GAIM_XFER_RECEIVE,
- slpcall->slplink->remote_user);
-
-- bin = (char *)gaim_base64_decode(context, &bin_len);
-+ bin = (char *)gaim2_base64_decode(context, &bin_len);
- file_size = GUINT32_FROM_LE(*((gsize *)bin + 2));
-
- uni_name = (gunichar2 *)(bin + 20);
-@@ -353,16 +353,16 @@ got_sessionreq(MsnSlpCall *slpcall, cons
-
- g_free(bin);
-
-- gaim_xfer_set_filename(xfer, file_name);
-- gaim_xfer_set_size(xfer, file_size);
-- gaim_xfer_set_init_fnc(xfer, msn_xfer_init);
-- gaim_xfer_set_request_denied_fnc(xfer, msn_xfer_cancel);
-- gaim_xfer_set_cancel_recv_fnc(xfer, msn_xfer_cancel);
-+ gaim2_xfer_set_filename(xfer, file_name);
-+ gaim2_xfer_set_size(xfer, file_size);
-+ gaim2_xfer_set_init_fnc(xfer, msn_xfer_init);
-+ gaim2_xfer_set_request_denied_fnc(xfer, msn_xfer_cancel);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, msn_xfer_cancel);
-
- slpcall->xfer = xfer;
- xfer->data = slpcall;
-
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
- }
-
-@@ -441,7 +441,7 @@ got_invite(MsnSlpCall *slpcall,
- char *ip_port;
- int port;
-
-- /* ip_addr = gaim_prefs_get_string("/core/ft/public_ip"); */
-+ /* ip_addr = gaim2_prefs_get_string("/core/ft/public_ip"); */
- ip_port = "5190";
- listening = "true";
- nonce = rand_guid();
-@@ -578,7 +578,7 @@ got_ok(MsnSlpCall *slpcall,
- else if (!strcmp(type, "application/x-msnmsgr-transreqbody"))
- {
- /* Do we get this? */
-- gaim_debug_info("msn", "OK with transreqbody\n");
-+ gaim2_debug_info("msn", "OK with transreqbody\n");
- }
- else if (!strcmp(type, "application/x-msnmsgr-transrespbody"))
- {
-@@ -617,7 +617,7 @@ msn_slp_sip_recv(MsnSlpLink *slplink, co
-
- if (body == NULL)
- {
-- gaim_debug_warning("msn", "received bogus message\n");
-+ gaim2_debug_warning("msn", "received bogus message\n");
- return NULL;
- }
-
-@@ -688,7 +688,7 @@ msn_slp_sip_recv(MsnSlpLink *slplink, co
- temp[offset] = '\0';
- }
-
-- gaim_debug_error("msn", "Received non-OK result: %s\n", temp);
-+ gaim2_debug_error("msn", "Received non-OK result: %s\n", temp);
-
- slpcall->wasted = TRUE;
-
-@@ -749,7 +749,7 @@ msn_p2p_msg(MsnCmdProc *cmdproc, MsnMess
- if (slplink->swboard != NULL)
- slplink->swboard->slplink = slplink;
- else
-- gaim_debug_error("msn", "msn_p2p_msg, swboard is NULL, ouch!\n");
-+ gaim2_debug_error("msn", "msn_p2p_msg, swboard is NULL, ouch!\n");
- }
-
- msn_slplink_process_msg(slplink, msg);
-@@ -760,23 +760,23 @@ got_emoticon(MsnSlpCall *slpcall,
- const guchar *data, gsize size)
- {
-
-- GaimConversation *conv;
-- GaimConnection *gc;
-+ Gaim2Conversation *conv;
-+ Gaim2Connection *gc;
- const char *who;
-
- gc = slpcall->slplink->session->account->gc;
- who = slpcall->slplink->remote_user;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, who, gc->account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, who, gc->account);
-
- /* FIXME: it would be better if we wrote the data as we received it
- instead of all at once, calling write multiple times and
- close once at the very end
- */
-- gaim_conv_custom_smiley_write(conv, slpcall->data_info, data, size);
-- gaim_conv_custom_smiley_close(conv, slpcall->data_info );
-+ gaim2_conv_custom_smiley_write(conv, slpcall->data_info, data, size);
-+ gaim2_conv_custom_smiley_close(conv, slpcall->data_info );
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "Got smiley: %s\n", slpcall->data_info);
-+ gaim2_debug_info("msn", "Got smiley: %s\n", slpcall->data_info);
- #endif
- }
-
-@@ -792,7 +792,7 @@ msn_emoticon_msg(MsnCmdProc *cmdproc, Ms
- guint tok;
- size_t body_len;
-
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- session = cmdproc->servconn->session;
-
-@@ -811,14 +811,14 @@ msn_emoticon_msg(MsnCmdProc *cmdproc, Ms
- }
-
- smile = tokens[tok];
-- obj = msn_object_new_from_string(gaim_url_decode(tokens[tok + 1]));
-+ obj = msn_object_new_from_string(gaim2_url_decode(tokens[tok + 1]));
-
- who = msn_object_get_creator(obj);
- sha1c = msn_object_get_sha1c(obj);
-
- slplink = msn_session_get_slplink(session, who);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY, who,
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY, who,
- session->account);
-
- /* If the conversation doesn't exist then this is a custom smiley
-@@ -828,10 +828,10 @@ msn_emoticon_msg(MsnCmdProc *cmdproc, Ms
- * the conversation doesn't exist then we cannot associate the new
- * smiley with its GtkIMHtml widget. */
- if (!conv) {
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, session->account, who);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, session->account, who);
- }
-
-- if (gaim_conv_custom_smiley_add(conv, smile, "sha1", sha1c, TRUE)) {
-+ if (gaim2_conv_custom_smiley_add(conv, smile, "sha1", sha1c, TRUE)) {
- msn_slplink_request_object(slplink, smile, got_emoticon, NULL, obj);
- }
-
-@@ -844,22 +844,22 @@ msn_emoticon_msg(MsnCmdProc *cmdproc, Ms
- }
-
- static gboolean
--buddy_icon_cached(GaimConnection *gc, MsnObject *obj)
-+buddy_icon_cached(Gaim2Connection *gc, MsnObject *obj)
- {
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
- const char *old;
- const char *new;
-
- g_return_val_if_fail(obj != NULL, FALSE);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- buddy = gaim_find_buddy(account, msn_object_get_creator(obj));
-+ buddy = gaim2_find_buddy(account, msn_object_get_creator(obj));
- if (buddy == NULL)
- return FALSE;
-
-- old = gaim_blist_node_get_string((GaimBlistNode *)buddy, "icon_checksum");
-+ old = gaim2_blist_node_get_string((Gaim2BlistNode *)buddy, "icon_checksum");
- new = msn_object_get_sha1c(obj);
-
- if (new == NULL)
-@@ -867,7 +867,7 @@ buddy_icon_cached(GaimConnection *gc, Ms
-
- /* If the old and new checksums are the same, and the file actually exists,
- * then return TRUE */
-- if (old != NULL && !strcmp(old, new) && (gaim_buddy_icons_find(account, gaim_buddy_get_name(buddy)) != NULL))
-+ if (old != NULL && !strcmp(old, new) && (gaim2_buddy_icons_find(account, gaim2_buddy_get_name(buddy)) != NULL))
- return TRUE;
-
- return FALSE;
-@@ -881,13 +881,13 @@ msn_release_buddy_icon_request(MsnUserLi
- g_return_if_fail(userlist != NULL);
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "Releasing buddy icon request\n");
-+ gaim2_debug_info("msn", "Releasing buddy icon request\n");
- #endif
-
- while (userlist->buddy_icon_window > 0)
- {
- GQueue *queue;
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *username;
-
- queue = userlist->buddy_icon_requests;
-@@ -904,7 +904,7 @@ msn_release_buddy_icon_request(MsnUserLi
- userlist->buddy_icon_window--;
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "buddy_icon_window=%d\n",
-+ gaim2_debug_info("msn", "buddy_icon_window=%d\n",
- userlist->buddy_icon_window);
- #endif
- }
-@@ -913,7 +913,7 @@ msn_release_buddy_icon_request(MsnUserLi
- void
- msn_queue_buddy_icon_request(MsnUser *user)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnObject *obj;
- GQueue *queue;
-
-@@ -929,14 +929,14 @@ msn_queue_buddy_icon_request(MsnUser *us
- GSList *sl, *list;
-
- /* TODO: I think we need better buddy icon core functions. */
-- gaim_buddy_icons_set_for_user(account, user->passport, NULL, -1);
-+ gaim2_buddy_icons_set_for_user(account, user->passport, NULL, -1);
-
-- list = gaim_find_buddies(account, user->passport);
-+ list = gaim2_find_buddies(account, user->passport);
-
- for (sl = list; sl != NULL; sl = sl->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)sl->data;
-- gaim_blist_node_remove_setting((GaimBlistNode*)buddy, "icon_checksum");
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)sl->data;
-+ gaim2_blist_node_remove_setting((Gaim2BlistNode*)buddy, "icon_checksum");
- }
- g_slist_free(list);
-
-@@ -951,14 +951,14 @@ msn_queue_buddy_icon_request(MsnUser *us
- queue = userlist->buddy_icon_requests;
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "Queueing buddy icon request: %s\n",
-+ gaim2_debug_info("msn", "Queueing buddy icon request: %s\n",
- user->passport);
- #endif
-
- g_queue_push_tail(queue, user);
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "buddy_icon_window=%d\n",
-+ gaim2_debug_info("msn", "buddy_icon_window=%d\n",
- userlist->buddy_icon_window);
- #endif
-
-@@ -973,29 +973,29 @@ got_user_display(MsnSlpCall *slpcall,
- {
- MsnUserList *userlist;
- const char *info;
-- GaimAccount *account;
-+ Gaim2Account *account;
- GSList *sl, *list;
-
- g_return_if_fail(slpcall != NULL);
-
- info = slpcall->data_info;
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "Got User Display: %s\n", info);
-+ gaim2_debug_info("msn", "Got User Display: %s\n", info);
- #endif
-
- userlist = slpcall->slplink->session->userlist;
- account = slpcall->slplink->session->account;
-
- /* TODO: I think we need better buddy icon core functions. */
-- gaim_buddy_icons_set_for_user(account, slpcall->slplink->remote_user,
-+ gaim2_buddy_icons_set_for_user(account, slpcall->slplink->remote_user,
- (void *)data, size);
-
-- list = gaim_find_buddies(account, slpcall->slplink->remote_user);
-+ list = gaim2_find_buddies(account, slpcall->slplink->remote_user);
-
- for (sl = list; sl != NULL; sl = sl->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)sl->data;
-- gaim_blist_node_set_string((GaimBlistNode*)buddy, "icon_checksum", info);
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)sl->data;
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)buddy, "icon_checksum", info);
- }
- g_slist_free(list);
-
-@@ -1003,7 +1003,7 @@ got_user_display(MsnSlpCall *slpcall,
- /* Free one window slot */
- userlist->buddy_icon_window++;
-
-- gaim_debug_info("msn", "buddy_icon_window=%d\n",
-+ gaim2_debug_info("msn", "buddy_icon_window=%d\n",
- userlist->buddy_icon_window);
-
- msn_release_buddy_icon_request(userlist);
-@@ -1018,7 +1018,7 @@ end_user_display(MsnSlpCall *slpcall)
- g_return_if_fail(slpcall != NULL);
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "End User Display\n");
-+ gaim2_debug_info("msn", "End User Display\n");
- #endif
-
- /* Maybe the slplink was destroyed. */
-@@ -1035,7 +1035,7 @@ end_user_display(MsnSlpCall *slpcall)
- userlist->buddy_icon_window++;
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "buddy_icon_window=%d\n",
-+ gaim2_debug_info("msn", "buddy_icon_window=%d\n",
- userlist->buddy_icon_window);
- #endif
-
-@@ -1045,7 +1045,7 @@ end_user_display(MsnSlpCall *slpcall)
- void
- msn_request_user_display(MsnUser *user)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- MsnSession *session;
- MsnSlpLink *slplink;
- MsnObject *obj;
-@@ -1061,7 +1061,7 @@ msn_request_user_display(MsnUser *user)
- info = msn_object_get_sha1c(obj);
-
- if (g_ascii_strcasecmp(user->passport,
-- gaim_account_get_username(account)))
-+ gaim2_account_get_username(account)))
- {
- msn_slplink_request_object(slplink, info, got_user_display,
- end_user_display, obj);
-@@ -1076,7 +1076,7 @@ msn_request_user_display(MsnUser *user)
- GSList *sl, *list;
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "Requesting our own user display\n");
-+ gaim2_debug_info("msn", "Requesting our own user display\n");
- #endif
-
- my_obj = msn_user_get_object(session->user);
-@@ -1091,15 +1091,15 @@ msn_request_user_display(MsnUser *user)
- g_file_get_contents(filename, &data, &len, NULL);
-
- /* TODO: I think we need better buddy icon core functions. */
-- gaim_buddy_icons_set_for_user(account, user->passport, (void *)data, len);
-+ gaim2_buddy_icons_set_for_user(account, user->passport, (void *)data, len);
- g_free(data);
-
-- list = gaim_find_buddies(account, user->passport);
-+ list = gaim2_find_buddies(account, user->passport);
-
- for (sl = list; sl != NULL; sl = sl->next)
- {
-- GaimBuddy *buddy = (GaimBuddy *)sl->data;
-- gaim_blist_node_set_string((GaimBlistNode*)buddy, "icon_checksum", info);
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)sl->data;
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)buddy, "icon_checksum", info);
- }
- g_slist_free(list);
-
-@@ -1107,7 +1107,7 @@ msn_request_user_display(MsnUser *user)
- session->userlist->buddy_icon_window++;
-
- #ifdef MSN_DEBUG_UD
-- gaim_debug_info("msn", "buddy_icon_window=%d\n",
-+ gaim2_debug_info("msn", "buddy_icon_window=%d\n",
- session->userlist->buddy_icon_window);
- #endif
-
-diff -prNu ./src/protocols/msn/slpcall.c ./src/protocols/msn/slpcall.c
---- ./src/protocols/msn/slpcall.c 2005-10-30 17:59:25.000000000 +0100
-+++ ./src/protocols/msn/slpcall.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slpcall.c SLP Call Functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -61,14 +61,14 @@ msn_slp_call_new(MsnSlpLink *slplink)
- slpcall = g_new0(MsnSlpCall, 1);
-
- #ifdef MSN_DEBUG_SLPCALL
-- gaim_debug_info("msn", "slpcall_new: slpcall(%p)\n", slpcall);
-+ gaim2_debug_info("msn", "slpcall_new: slpcall(%p)\n", slpcall);
- #endif
-
- slpcall->slplink = slplink;
-
- msn_slplink_add_slpcall(slplink, slpcall);
-
-- slpcall->timer = gaim_timeout_add(MSN_SLPCALL_TIMEOUT, msn_slp_call_timeout, slpcall);
-+ slpcall->timer = gaim2_timeout_add(MSN_SLPCALL_TIMEOUT, msn_slp_call_timeout, slpcall);
-
- return slpcall;
- }
-@@ -79,13 +79,13 @@ msn_slp_call_destroy(MsnSlpCall *slpcall
- GList *e;
-
- #ifdef MSN_DEBUG_SLPCALL
-- gaim_debug_info("msn", "slpcall_destroy: slpcall(%p)\n", slpcall);
-+ gaim2_debug_info("msn", "slpcall_destroy: slpcall(%p)\n", slpcall);
- #endif
-
- g_return_if_fail(slpcall != NULL);
-
- if (slpcall->timer)
-- gaim_timeout_remove(slpcall->timer);
-+ gaim2_timeout_remove(slpcall->timer);
-
- if (slpcall->id != NULL)
- g_free(slpcall->id);
-@@ -102,7 +102,7 @@ msn_slp_call_destroy(MsnSlpCall *slpcall
- e = e->next;
-
- #ifdef MSN_DEBUG_SLPCALL_VERBOSE
-- gaim_debug_info("msn", "slpcall_destroy: trying slpmsg(%p)\n",
-+ gaim2_debug_info("msn", "slpcall_destroy: trying slpmsg(%p)\n",
- slpmsg);
- #endif
-
-@@ -203,7 +203,7 @@ msn_slp_call_timeout(gpointer data)
- slpcall = data;
-
- #ifdef MSN_DEBUG_SLPCALL
-- gaim_debug_info("msn", "slpcall_timeout: slpcall(%p)\n", slpcall);
-+ gaim2_debug_info("msn", "slpcall_timeout: slpcall(%p)\n", slpcall);
- #endif
-
- if (!slpcall->pending && !slpcall->progress)
-@@ -243,7 +243,7 @@ msn_slp_process_msg(MsnSlpLink *slplink,
- if (slpcall != NULL)
- {
- if (slpcall->timer)
-- gaim_timeout_remove(slpcall->timer);
-+ gaim2_timeout_remove(slpcall->timer);
-
- slpcall->cb(slpcall, body, body_len);
-
-diff -prNu ./src/protocols/msn/slpcall.h ./src/protocols/msn/slpcall.h
---- ./src/protocols/msn/slpcall.h 2005-07-21 07:49:47.000000000 +0200
-+++ ./src/protocols/msn/slpcall.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slpcall.h SLP Call functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/slp.h ./src/protocols/msn/slp.h
---- ./src/protocols/msn/slp.h 2005-08-11 22:45:36.000000000 +0200
-+++ ./src/protocols/msn/slp.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slp.h MSNSLP support
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -40,7 +40,7 @@ void send_bye(MsnSlpCall *slpcall, const
- void msn_xfer_completed_cb(MsnSlpCall *slpcall,
- const guchar *body, gsize size);
-
--void msn_xfer_cancel(GaimXfer *xfer);
-+void msn_xfer_cancel(Gaim2Xfer *xfer);
- void msn_xfer_end_cb(MsnSlpCall *slpcall);
-
- void msn_queue_buddy_icon_request(MsnUser *user);
-diff -prNu ./src/protocols/msn/slplink.c ./src/protocols/msn/slplink.c
---- ./src/protocols/msn/slplink.c 2005-10-04 07:03:02.000000000 +0200
-+++ ./src/protocols/msn/slplink.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slplink.c MSNSLP Link support
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -68,7 +68,7 @@ msn_slplink_new(MsnSession *session, con
- slplink = g_new0(MsnSlpLink, 1);
-
- #ifdef MSN_DEBUG_SLPLINK
-- gaim_debug_info("msn", "slplink_new: slplink(%p)\n", slplink);
-+ gaim2_debug_info("msn", "slplink_new: slplink(%p)\n", slplink);
- #endif
-
- slplink->session = session;
-@@ -91,7 +91,7 @@ msn_slplink_destroy(MsnSlpLink *slplink)
- MsnSession *session;
-
- #ifdef MSN_DEBUG_SLPLINK
-- gaim_debug_info("msn", "slplink_destroy: slplink(%p)\n", slplink);
-+ gaim2_debug_info("msn", "slplink_destroy: slplink(%p)\n", slplink);
- #endif
-
- g_return_if_fail(slplink != NULL);
-@@ -483,7 +483,7 @@ send_file_cb(MsnSlpSession *slpsession)
- #ifdef MSN_DEBUG_SLP
- slpmsg->info = "SLP FILE";
- #endif
-- msn_slpmsg_open_file(slpmsg, gaim_xfer_get_local_filename(slpcall->xfer));
-+ msn_slpmsg_open_file(slpmsg, gaim2_xfer_get_local_filename(slpcall->xfer));
-
- msn_slplink_send_slpmsg(slpcall->slplink, slpmsg);
- }
-@@ -506,7 +506,7 @@ msn_slplink_process_msg(MsnSlpLink *slpl
-
- if (msg->msnslp_header.total_size < msg->msnslp_header.length)
- {
-- gaim_debug_error("msn", "This can't be good\n");
-+ gaim2_debug_error("msn", "This can't be good\n");
- g_return_if_reached();
- }
-
-@@ -537,14 +537,14 @@ msn_slplink_process_msg(MsnSlpLink *slpl
- {
- if (slpmsg->flags == 0x20 || slpmsg->flags == 0x1000030)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- xfer = slpmsg->slpcall->xfer;
-
- if (xfer != NULL)
- {
- slpmsg->fp =
-- g_fopen(gaim_xfer_get_local_filename(slpmsg->slpcall->xfer),
-+ g_fopen(gaim2_xfer_get_local_filename(slpmsg->slpcall->xfer),
- "wb");
- }
- }
-@@ -555,7 +555,7 @@ msn_slplink_process_msg(MsnSlpLink *slpl
- slpmsg->buffer = g_try_malloc(slpmsg->size);
- if (slpmsg->buffer == NULL)
- {
-- gaim_debug_error("msn", "Failed to allocate buffer for slpmsg\n");
-+ gaim2_debug_error("msn", "Failed to allocate buffer for slpmsg\n");
- return;
- }
- }
-@@ -568,7 +568,7 @@ msn_slplink_process_msg(MsnSlpLink *slpl
- if (slpmsg == NULL)
- {
- /* Probably the transfer was canceled */
-- gaim_debug_error("msn", "Couldn't find slpmsg\n");
-+ gaim2_debug_error("msn", "Couldn't find slpmsg\n");
- return;
- }
-
-@@ -581,7 +581,7 @@ msn_slplink_process_msg(MsnSlpLink *slpl
- {
- if ((offset + len) > slpmsg->size)
- {
-- gaim_debug_error("msn", "Oversized slpmsg\n");
-+ gaim2_debug_error("msn", "Oversized slpmsg\n");
- g_return_if_reached();
- }
- else
-@@ -684,7 +684,7 @@ gen_context(const char *file_name, const
- size = st.st_size;
-
- if(!file_name) {
-- u8 = gaim_utf8_try_convert(g_basename(file_path));
-+ u8 = gaim2_utf8_try_convert(g_basename(file_path));
- file_name = u8;
- }
-
-@@ -720,21 +720,21 @@ gen_context(const char *file_name, const
- n += 4;
-
- g_free(uni);
-- ret = gaim_base64_encode(base, len);
-+ ret = gaim2_base64_encode(base, len);
- g_free(base);
- return ret;
- }
-
- void
--msn_slplink_request_ft(MsnSlpLink *slplink, GaimXfer *xfer)
-+msn_slplink_request_ft(MsnSlpLink *slplink, Gaim2Xfer *xfer)
- {
- MsnSlpCall *slpcall;
- char *context;
- const char *fn;
- const char *fp;
-
-- fn = gaim_xfer_get_filename(xfer);
-- fp = gaim_xfer_get_local_filename(xfer);
-+ fn = gaim2_xfer_get_filename(xfer);
-+ fp = gaim2_xfer_get_local_filename(xfer);
-
- g_return_if_fail(slplink != NULL);
- g_return_if_fail(fp != NULL);
-@@ -750,7 +750,7 @@ msn_slplink_request_ft(MsnSlpLink *slpli
-
- slpcall->pending = TRUE;
-
-- gaim_xfer_set_cancel_send_fnc(xfer, msn_xfer_cancel);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, msn_xfer_cancel);
-
- xfer->data = slpcall;
-
-@@ -777,7 +777,7 @@ msn_slplink_request_object(MsnSlpLink *s
- g_return_if_fail(obj != NULL);
-
- msnobj_data = msn_object_to_string(obj);
-- msnobj_base64 = gaim_base64_encode((const guchar *)msnobj_data, strlen(msnobj_data));
-+ msnobj_base64 = gaim2_base64_encode((const guchar *)msnobj_data, strlen(msnobj_data));
- g_free(msnobj_data);
-
- slpcall = msn_slp_call_new(slplink);
-diff -prNu ./src/protocols/msn/slplink.h ./src/protocols/msn/slplink.h
---- ./src/protocols/msn/slplink.h 2005-02-16 21:14:12.000000000 +0100
-+++ ./src/protocols/msn/slplink.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slplink.h MSNSLP Link support
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -79,7 +79,7 @@ MsnSlpMessage *msn_slplink_message_find(
- void msn_slplink_append_slp_msg(MsnSlpLink *slplink, MsnSlpMessage *slpmsg);
- void msn_slplink_remove_slp_msg(MsnSlpLink *slplink,
- MsnSlpMessage *slpmsg);
--void msn_slplink_request_ft(MsnSlpLink *slplink, GaimXfer *xfer);
-+void msn_slplink_request_ft(MsnSlpLink *slplink, Gaim2Xfer *xfer);
-
- void msn_slplink_request_object(MsnSlpLink *slplink,
- const char *info,
-diff -prNu ./src/protocols/msn/slpmsg.c ./src/protocols/msn/slpmsg.c
---- ./src/protocols/msn/slpmsg.c 2005-08-21 19:14:22.000000000 +0200
-+++ ./src/protocols/msn/slpmsg.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slpmsg.h SLP Message functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -37,7 +37,7 @@ msn_slpmsg_new(MsnSlpLink *slplink)
- slpmsg = g_new0(MsnSlpMessage, 1);
-
- #ifdef MSN_DEBUG_SLPMSG
-- gaim_debug_info("msn", "slpmsg new (%p)\n", slpmsg);
-+ gaim2_debug_info("msn", "slpmsg new (%p)\n", slpmsg);
- #endif
-
- slpmsg->slplink = slplink;
-@@ -57,7 +57,7 @@ msn_slpmsg_destroy(MsnSlpMessage *slpmsg
- g_return_if_fail(slpmsg != NULL);
-
- #ifdef MSN_DEBUG_SLPMSG
-- gaim_debug_info("msn", "slpmsg destroy (%p)\n", slpmsg);
-+ gaim2_debug_info("msn", "slpmsg destroy (%p)\n", slpmsg);
- #endif
-
- slplink = slpmsg->slplink;
-@@ -84,7 +84,7 @@ msn_slpmsg_destroy(MsnSlpMessage *slpmsg
- MsnMessage *msg = cur->data;
-
- #ifdef MSN_DEBUG_SLPMSG
-- gaim_debug_info("msn", "Unlink slpmsg callbacks.\n");
-+ gaim2_debug_info("msn", "Unlink slpmsg callbacks.\n");
- #endif
-
- msg->ack_cb = NULL;
-diff -prNu ./src/protocols/msn/slpmsg.h ./src/protocols/msn/slpmsg.h
---- ./src/protocols/msn/slpmsg.h 2005-08-21 19:14:22.000000000 +0200
-+++ ./src/protocols/msn/slpmsg.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slpmsg.h SLP Message functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/slpsession.c ./src/protocols/msn/slpsession.c
---- ./src/protocols/msn/slpsession.c 2005-12-08 21:57:32.000000000 +0100
-+++ ./src/protocols/msn/slpsession.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slpsession.h SLP Session functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/slpsession.h ./src/protocols/msn/slpsession.h
---- ./src/protocols/msn/slpsession.h 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/slpsession.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file slpsession.h SLP Session functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/state.c ./src/protocols/msn/state.c
---- ./src/protocols/msn/state.c 2005-11-06 22:52:00.000000000 +0100
-+++ ./src/protocols/msn/state.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file state.c State functions and definitions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -41,7 +41,7 @@ static const char *away_text[] =
- void
- msn_change_status(MsnSession *session)
- {
-- GaimAccount *account = session->account;
-+ Gaim2Account *account = session->account;
- MsnCmdProc *cmdproc;
- MsnUser *user;
- MsnObject *msnobj;
-@@ -74,7 +74,7 @@ msn_change_status(MsnSession *session)
- msnobj_str = msn_object_to_string(msnobj);
-
- msn_cmdproc_send(cmdproc, "CHG", "%s %d %s", state_text,
-- MSN_CLIENT_ID, gaim_url_encode(msnobj_str));
-+ MSN_CLIENT_ID, gaim2_url_encode(msnobj_str));
-
- g_free(msnobj_str);
- }
-@@ -98,16 +98,16 @@ msn_state_get_text(MsnAwayType state)
- }
-
- MsnAwayType
--msn_state_from_account(GaimAccount *account)
-+msn_state_from_account(Gaim2Account *account)
- {
- MsnAwayType msnstatus;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- const char *status_id;
-
-- presence = gaim_account_get_presence(account);
-- status = gaim_presence_get_active_status(presence);
-- status_id = gaim_status_get_id(status);
-+ presence = gaim2_account_get_presence(account);
-+ status = gaim2_presence_get_active_status(presence);
-+ status_id = gaim2_status_get_id(status);
-
- if (!strcmp(status_id, "away"))
- msnstatus = MSN_AWAY;
-@@ -124,7 +124,7 @@ msn_state_from_account(GaimAccount *acco
- else
- msnstatus = MSN_ONLINE;
-
-- if ((msnstatus == MSN_ONLINE) && gaim_presence_is_idle(presence))
-+ if ((msnstatus == MSN_ONLINE) && gaim2_presence_is_idle(presence))
- msnstatus = MSN_IDLE;
-
- return msnstatus;
-diff -prNu ./src/protocols/msn/state.h ./src/protocols/msn/state.h
---- ./src/protocols/msn/state.h 2005-11-21 12:44:55.000000000 +0100
-+++ ./src/protocols/msn/state.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file state.h State functions and definitions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -59,6 +59,6 @@ const char *msn_away_get_text(MsnAwayTyp
-
- const char *msn_state_get_text(MsnAwayType state);
-
--MsnAwayType msn_state_from_account(GaimAccount *account);
-+MsnAwayType msn_state_from_account(Gaim2Account *account);
-
- #endif /* _MSN_STATE_H_ */
-diff -prNu ./src/protocols/msn/switchboard.c ./src/protocols/msn/switchboard.c
---- ./src/protocols/msn/switchboard.c 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/msn/switchboard.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file switchboard.c MSN switchboard functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -71,7 +71,7 @@ msn_switchboard_destroy(MsnSwitchBoard *
- GList *l;
-
- #ifdef MSN_DEBUG_SB
-- gaim_debug_info("msn", "switchboard_destroy: swboard(%p)\n", swboard);
-+ gaim2_debug_info("msn", "switchboard_destroy: swboard(%p)\n", swboard);
- #endif
-
- g_return_if_fail(swboard != NULL);
-@@ -210,7 +210,7 @@ static void
- msn_switchboard_add_user(MsnSwitchBoard *swboard, const char *user)
- {
- MsnCmdProc *cmdproc;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- g_return_if_fail(swboard != NULL);
-
-@@ -222,39 +222,39 @@ msn_switchboard_add_user(MsnSwitchBoard
- swboard->empty = FALSE;
-
- #ifdef MSN_DEBUG_CHAT
-- gaim_debug_info("msn", "user=[%s], total=%d\n", user,
-+ gaim2_debug_info("msn", "user=[%s], total=%d\n", user,
- swboard->current_users);
- #endif
-
- if (!(swboard->flag & MSN_SB_FLAG_IM) && (swboard->conv != NULL))
- {
- /* This is a helper switchboard. */
-- gaim_debug_error("msn", "switchboard_add_user: conv != NULL\n");
-+ gaim2_debug_error("msn", "switchboard_add_user: conv != NULL\n");
- return;
- }
-
- if ((swboard->conv != NULL) &&
-- (gaim_conversation_get_type(swboard->conv) == GAIM_CONV_TYPE_CHAT))
-+ (gaim2_conversation_get_type(swboard->conv) == GAIM_CONV_TYPE_CHAT))
- {
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv), user, NULL,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv), user, NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- }
- else if (swboard->current_users > 1 || swboard->total_users > 1)
- {
- if (swboard->conv == NULL ||
-- gaim_conversation_get_type(swboard->conv) != GAIM_CONV_TYPE_CHAT)
-+ gaim2_conversation_get_type(swboard->conv) != GAIM_CONV_TYPE_CHAT)
- {
- GList *l;
-
- #ifdef MSN_DEBUG_CHAT
-- gaim_debug_info("msn", "[chat] Switching to chat.\n");
-+ gaim2_debug_info("msn", "[chat] Switching to chat.\n");
- #endif
-
- #if 0
- /* this is bad - it causes msn_switchboard_close to be called on the
- * switchboard we're in the middle of using :( */
- if (swboard->conv != NULL)
-- gaim_conversation_destroy(swboard->conv);
-+ gaim2_conversation_destroy(swboard->conv);
- #endif
-
- cmdproc->session->conv_seq++;
-@@ -271,19 +271,19 @@ msn_switchboard_add_user(MsnSwitchBoard
- tmp_user = l->data;
-
- #ifdef MSN_DEBUG_CHAT
-- gaim_debug_info("msn", "[chat] Adding [%s].\n", tmp_user);
-+ gaim2_debug_info("msn", "[chat] Adding [%s].\n", tmp_user);
- #endif
-
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv),
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv),
- tmp_user, NULL, GAIM_CBFLAGS_NONE, TRUE);
- }
-
- #ifdef MSN_DEBUG_CHAT
-- gaim_debug_info("msn", "[chat] We add ourselves.\n");
-+ gaim2_debug_info("msn", "[chat] We add ourselves.\n");
- #endif
-
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv),
-- gaim_account_get_username(account),
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(swboard->conv),
-+ gaim2_account_get_username(account),
- NULL, GAIM_CBFLAGS_NONE, TRUE);
-
- g_free(swboard->im_user);
-@@ -293,45 +293,45 @@ msn_switchboard_add_user(MsnSwitchBoard
- else if (swboard->conv == NULL)
- {
- /* XXX - I think this should probably be GAIM_CONV_TYPE_CHAT, but I'm hedging */
-- swboard->conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
-+ swboard->conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
- user, account);
- }
- else
- {
-- gaim_debug_warning("msn", "switchboard_add_user: This should not happen!\n");
-+ gaim2_debug_warning("msn", "switchboard_add_user: This should not happen!\n");
- }
- }
-
--static GaimConversation *
-+static Gaim2Conversation *
- msn_switchboard_get_conv(MsnSwitchBoard *swboard)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- g_return_val_if_fail(swboard != NULL, NULL);
-
- if (swboard->conv != NULL)
- return swboard->conv;
-
-- gaim_debug_error("msn", "Switchboard with unassigned conversation\n");
-+ gaim2_debug_error("msn", "Switchboard with unassigned conversation\n");
-
- account = swboard->session->account;
-
- /* XXX - I think this should probably be GAIM_CONV_TYPE_IM, but I'm hedging */
-- return gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ return gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- swboard->im_user, account);
- }
-
- static void
--msn_switchboard_report_user(MsnSwitchBoard *swboard, GaimMessageFlags flags, const char *msg)
-+msn_switchboard_report_user(MsnSwitchBoard *swboard, Gaim2MessageFlags flags, const char *msg)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- g_return_if_fail(swboard != NULL);
- g_return_if_fail(msg != NULL);
-
- if ((conv = msn_switchboard_get_conv(swboard)) != NULL)
- {
-- gaim_conversation_write(conv, NULL, msg, flags, time(NULL));
-+ gaim2_conversation_write(conv, NULL, msg, flags, time(NULL));
- }
- }
-
-@@ -340,7 +340,7 @@ swboard_error_helper(MsnSwitchBoard *swb
- {
- g_return_if_fail(swboard != NULL);
-
-- gaim_debug_info("msg", "Error: Unable to call the user %s\n", passport);
-+ gaim2_debug_info("msg", "Error: Unable to call the user %s\n", passport);
-
- /* TODO: if current_users > 0, this is probably a chat and an invite failed,
- * we should report that in the chat or something */
-@@ -573,7 +573,7 @@ queue_msg(MsnSwitchBoard *swboard, MsnMe
- g_return_if_fail(swboard != NULL);
- g_return_if_fail(msg != NULL);
-
-- gaim_debug_info("msn", "Appending message to queue.\n");
-+ gaim2_debug_info("msn", "Appending message to queue.\n");
-
- g_queue_push_tail(swboard->msg_queue, msg);
-
-@@ -587,11 +587,11 @@ process_queue(MsnSwitchBoard *swboard)
-
- g_return_if_fail(swboard != NULL);
-
-- gaim_debug_info("msn", "Processing queue\n");
-+ gaim2_debug_info("msn", "Processing queue\n");
-
- while ((msg = g_queue_pop_head(swboard->msg_queue)) != NULL)
- {
-- gaim_debug_info("msn", "Sending message\n");
-+ gaim2_debug_info("msn", "Sending message\n");
- release_msg(swboard, msg);
- msn_message_unref(msg);
- }
-@@ -644,7 +644,7 @@ bye_cmd(MsnCmdProc *cmdproc, MsnCommand
- user = cmd->params[0];
-
- if (!(swboard->flag & MSN_SB_FLAG_IM) && (swboard->conv != NULL))
-- gaim_debug_error("msn_switchboard", "bye_cmd: helper bug\n");
-+ gaim2_debug_error("msn_switchboard", "bye_cmd: helper bug\n");
-
- if (swboard->conv == NULL)
- {
-@@ -652,10 +652,10 @@ bye_cmd(MsnCmdProc *cmdproc, MsnCommand
- msn_switchboard_destroy(swboard);
- }
- else if ((swboard->current_users > 1) ||
-- (gaim_conversation_get_type(swboard->conv) == GAIM_CONV_TYPE_CHAT))
-+ (gaim2_conversation_get_type(swboard->conv) == GAIM_CONV_TYPE_CHAT))
- {
- /* This is a switchboard used for a chat */
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(swboard->conv), user, NULL);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(swboard->conv), user, NULL);
- swboard->current_users--;
- if (swboard->current_users == 0)
- msn_switchboard_destroy(swboard);
-@@ -670,8 +670,8 @@ bye_cmd(MsnCmdProc *cmdproc, MsnCommand
- static void
- iro_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- MsnSwitchBoard *swboard;
-
- account = cmdproc->session->account;
-@@ -687,8 +687,8 @@ static void
- joi_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
- MsnSession *session;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- MsnSwitchBoard *swboard;
- const char *passport;
-
-@@ -768,7 +768,7 @@ ack_cmd(MsnCmdProc *cmdproc, MsnCommand
- static void
- out_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSwitchBoard *swboard;
-
- gc = cmdproc->session->account->gc;
-@@ -809,7 +809,7 @@ usr_cmd(MsnCmdProc *cmdproc, MsnCommand
- static void
- plain_msg(MsnCmdProc *cmdproc, MsnMessage *msg)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSwitchBoard *swboard;
- const char *body;
- char *body_str;
-@@ -838,7 +838,7 @@ plain_msg(MsnCmdProc *cmdproc, MsnMessag
- #if 0
- if ((value = msn_message_get_attr(msg, "User-Agent")) != NULL)
- {
-- gaim_debug_misc("msn", "User-Agent = '%s'\n", value);
-+ gaim2_debug_misc("msn", "User-Agent = '%s'\n", value);
- }
- #endif
-
-@@ -864,19 +864,19 @@ plain_msg(MsnCmdProc *cmdproc, MsnMessag
-
- if (swboard->current_users > 1 ||
- ((swboard->conv != NULL) &&
-- gaim_conversation_get_type(swboard->conv) == GAIM_CONV_TYPE_CHAT))
-+ gaim2_conversation_get_type(swboard->conv) == GAIM_CONV_TYPE_CHAT))
- {
- /* If current_users is always ok as it should then there is no need to
- * check if this is a chat. */
- if (swboard->current_users <= 1)
-- gaim_debug_misc("msn", "plain_msg: current_users(%d)\n",
-+ gaim2_debug_misc("msn", "plain_msg: current_users(%d)\n",
- swboard->current_users);
-
- serv_got_chat_in(gc, swboard->chat_id, passport, 0, body_final,
- time(NULL));
- if (swboard->conv == NULL)
- {
-- swboard->conv = gaim_find_chat(gc, swboard->chat_id);
-+ swboard->conv = gaim2_find_chat(gc, swboard->chat_id);
- swboard->flag |= MSN_SB_FLAG_IM;
- }
- }
-@@ -885,8 +885,8 @@ plain_msg(MsnCmdProc *cmdproc, MsnMessag
- serv_got_im(gc, passport, body_final, 0, time(NULL));
- if (swboard->conv == NULL)
- {
-- swboard->conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-- passport, gaim_connection_get_account(gc));
-+ swboard->conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ passport, gaim2_connection_get_account(gc));
- swboard->flag |= MSN_SB_FLAG_IM;
- }
- }
-@@ -897,7 +897,7 @@ plain_msg(MsnCmdProc *cmdproc, MsnMessag
- static void
- control_msg(MsnCmdProc *cmdproc, MsnMessage *msg)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- MsnSwitchBoard *swboard;
- const char *value;
- char *passport;
-@@ -938,16 +938,16 @@ nudge_msg(MsnCmdProc *cmdproc, MsnMessag
- {
- MsnSwitchBoard *swboard;
- char *username, *str;
-- GaimAccount *account;
-- GaimBuddy *buddy;
-+ Gaim2Account *account;
-+ Gaim2Buddy *buddy;
- const char *user;
-
- swboard = cmdproc->data;
- account = cmdproc->session->account;
- user = msg->remote_user;
-
-- if ((buddy = gaim_find_buddy(account, user)) != NULL)
-- username = g_markup_escape_text(gaim_buddy_get_alias(buddy), -1);
-+ if ((buddy = gaim2_find_buddy(account, user)) != NULL)
-+ username = g_markup_escape_text(gaim2_buddy_get_alias(buddy), -1);
- else
- username = g_markup_escape_text(user, -1);
-
-@@ -965,7 +965,7 @@ connect_cb(MsnServConn *servconn)
- {
- MsnSwitchBoard *swboard;
- MsnCmdProc *cmdproc;
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- cmdproc = servconn->cmdproc;
- g_return_if_fail(cmdproc != NULL);
-@@ -979,13 +979,13 @@ connect_cb(MsnServConn *servconn)
- swboard->empty = FALSE;
-
- msn_cmdproc_send(cmdproc, "ANS", "%s %s %s",
-- gaim_account_get_username(account),
-+ gaim2_account_get_username(account),
- swboard->auth_key, swboard->session_id);
- }
- else
- {
- msn_cmdproc_send(cmdproc, "USR", "%s %s",
-- gaim_account_get_username(account),
-+ gaim2_account_get_username(account),
- swboard->auth_key);
- }
- }
-@@ -1053,7 +1053,7 @@ cal_error(MsnCmdProc *cmdproc, MsnTransa
-
- if (error == 215)
- {
-- gaim_debug_info("msn", "Invited user already in switchboard\n");
-+ gaim2_debug_info("msn", "Invited user already in switchboard\n");
- return;
- }
- else if (error == 217)
-diff -prNu ./src/protocols/msn/switchboard.h ./src/protocols/msn/switchboard.h
---- ./src/protocols/msn/switchboard.h 2005-10-30 17:59:25.000000000 +0100
-+++ ./src/protocols/msn/switchboard.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file switchboard.h MSN switchboard functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -75,7 +75,7 @@ struct _MsnSwitchBoard
- char *auth_key;
- char *session_id;
-
-- GaimConversation *conv; /**< The conversation that displays the
-+ Gaim2Conversation *conv; /**< The conversation that displays the
- messages of this switchboard, or @c NULL if
- this is a helper switchboard. */
-
-diff -prNu ./src/protocols/msn/sync.c ./src/protocols/msn/sync.c
---- ./src/protocols/msn/sync.c 2004-12-30 16:55:19.000000000 +0100
-+++ ./src/protocols/msn/sync.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file sync.c MSN list synchronization functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,7 +30,7 @@ static MsnTable *cbs_table;
- static void
- blp_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
- {
-- GaimConnection *gc = cmdproc->session->account->gc;
-+ Gaim2Connection *gc = cmdproc->session->account->gc;
- const char *list_name;
-
- list_name = cmd->params[0];
-@@ -68,11 +68,11 @@ prp_cmd(MsnCmdProc *cmdproc, MsnCommand
- if (cmd->param_count == 2)
- {
- if (!strcmp(type, "PHH"))
-- msn_user_set_home_phone(session->user, gaim_url_decode(value));
-+ msn_user_set_home_phone(session->user, gaim2_url_decode(value));
- else if (!strcmp(type, "PHW"))
-- msn_user_set_work_phone(session->user, gaim_url_decode(value));
-+ msn_user_set_work_phone(session->user, gaim2_url_decode(value));
- else if (!strcmp(type, "PHM"))
-- msn_user_set_mobile_phone(session->user, gaim_url_decode(value));
-+ msn_user_set_mobile_phone(session->user, gaim2_url_decode(value));
- }
- else
- {
-@@ -90,12 +90,12 @@ lsg_cmd(MsnCmdProc *cmdproc, MsnCommand
- {
- MsnSession *session = cmdproc->session;
- MsnGroup *group;
-- GaimGroup *g;
-+ Gaim2Group *g;
- const char *name;
- int group_id;
-
- group_id = atoi(cmd->params[0]);
-- name = gaim_url_decode(cmd->params[1]);
-+ name = gaim2_url_decode(cmd->params[1]);
-
- group = msn_group_new(session->userlist, group_id, name);
-
-@@ -104,10 +104,10 @@ lsg_cmd(MsnCmdProc *cmdproc, MsnCommand
- /* Group of ungroupped buddies */
- return;
-
-- if ((g = gaim_find_group(name)) == NULL)
-+ if ((g = gaim2_find_group(name)) == NULL)
- {
-- g = gaim_group_new(name);
-- gaim_blist_add_group(g, NULL);
-+ g = gaim2_group_new(name);
-+ gaim2_blist_add_group(g, NULL);
- }
- }
-
-@@ -121,7 +121,7 @@ lst_cmd(MsnCmdProc *cmdproc, MsnCommand
- MsnUser *user;
-
- passport = cmd->params[0];
-- friend = gaim_url_decode(cmd->params[1]);
-+ friend = gaim2_url_decode(cmd->params[1]);
- list_op = atoi(cmd->params[2]);
-
- user = msn_user_new(session->userlist, passport, friend);
-@@ -197,11 +197,11 @@ bpr_cmd(MsnCmdProc *cmdproc, MsnCommand
- user->mobile = TRUE;
- }
- else if (!strcmp(type, "PHH"))
-- msn_user_set_home_phone(user, gaim_url_decode(value));
-+ msn_user_set_home_phone(user, gaim2_url_decode(value));
- else if (!strcmp(type, "PHW"))
-- msn_user_set_work_phone(user, gaim_url_decode(value));
-+ msn_user_set_work_phone(user, gaim2_url_decode(value));
- else if (!strcmp(type, "PHM"))
-- msn_user_set_mobile_phone(user, gaim_url_decode(value));
-+ msn_user_set_mobile_phone(user, gaim2_url_decode(value));
- }
- }
-
-diff -prNu ./src/protocols/msn/sync.h ./src/protocols/msn/sync.h
---- ./src/protocols/msn/sync.h 2004-06-06 05:42:54.000000000 +0200
-+++ ./src/protocols/msn/sync.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file sync.h MSN list synchronization functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/table.c ./src/protocols/msn/table.c
---- ./src/protocols/msn/table.c 2004-12-11 21:01:58.000000000 +0100
-+++ ./src/protocols/msn/table.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file table.c MSN helper structure
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/table.h ./src/protocols/msn/table.h
---- ./src/protocols/msn/table.h 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/msn/table.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file table.h MSN helper structure
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/transaction.c ./src/protocols/msn/transaction.c
---- ./src/protocols/msn/transaction.c 2005-01-07 03:48:33.000000000 +0100
-+++ ./src/protocols/msn/transaction.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file transaction.c MSN transaction functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -79,7 +79,7 @@ msn_transaction_destroy(MsnTransaction *
- g_hash_table_destroy(trans->callbacks);
-
- if (trans->timer)
-- gaim_timeout_remove(trans->timer);
-+ gaim2_timeout_remove(trans->timer);
-
- g_free(trans);
- }
-@@ -102,7 +102,7 @@ msn_transaction_to_string(MsnTransaction
- void
- msn_transaction_queue_cmd(MsnTransaction *trans, MsnCommand *cmd)
- {
-- gaim_debug_info("msn", "queueing command.\n");
-+ gaim2_debug_info("msn", "queueing command.\n");
- trans->pendent_cmd = cmd;
- msn_command_ref(cmd);
- }
-@@ -115,7 +115,7 @@ msn_transaction_unqueue_cmd(MsnTransacti
- if (!cmdproc->servconn->connected)
- return;
-
-- gaim_debug_info("msn", "unqueueing command.\n");
-+ gaim2_debug_info("msn", "unqueueing command.\n");
- cmd = trans->pendent_cmd;
-
- g_return_if_fail(cmd != NULL);
-@@ -193,7 +193,7 @@ transaction_timeout(gpointer data)
- g_return_val_if_fail(trans != NULL, FALSE);
-
- #if 0
-- gaim_debug_info("msn", "timed out: %s %d %s\n", trans->command, trans->trId, trans->params);
-+ gaim2_debug_info("msn", "timed out: %s %d %s\n", trans->command, trans->trId, trans->params);
- #endif
-
- if (trans->timeout_cb != NULL)
-@@ -207,11 +207,11 @@ msn_transaction_set_timeout_cb(MsnTransa
- {
- if (trans->timer)
- {
-- gaim_debug_error("msn", "This shouldn't be happening\n");
-- gaim_timeout_remove(trans->timer);
-+ gaim2_debug_error("msn", "This shouldn't be happening\n");
-+ gaim2_timeout_remove(trans->timer);
- }
- trans->timeout_cb = cb;
-- trans->timer = gaim_timeout_add(60000, transaction_timeout, trans);
-+ trans->timer = gaim2_timeout_add(60000, transaction_timeout, trans);
- }
-
- void
-diff -prNu ./src/protocols/msn/transaction.h ./src/protocols/msn/transaction.h
---- ./src/protocols/msn/transaction.h 2004-12-23 21:13:54.000000000 +0100
-+++ ./src/protocols/msn/transaction.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file transaction.h MSN transaction functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/user.c ./src/protocols/msn/user.c
---- ./src/protocols/msn/user.c 2005-12-04 18:35:01.000000000 +0100
-+++ ./src/protocols/msn/user.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file user.c User functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -88,19 +88,19 @@ msn_user_destroy(MsnUser *user)
- void
- msn_user_update(MsnUser *user)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-
- account = user->userlist->session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (user->status != NULL)
-- gaim_prpl_got_user_status(account, user->passport, user->status, NULL);
-+ gaim2_prpl_got_user_status(account, user->passport, user->status, NULL);
-
- if (user->idle)
-- gaim_prpl_got_user_idle(account, user->passport, TRUE, -1);
-+ gaim2_prpl_got_user_idle(account, user->passport, TRUE, -1);
- else
-- gaim_prpl_got_user_idle(account, user->passport, FALSE, 0);
-+ gaim2_prpl_got_user_idle(account, user->passport, FALSE, 0);
- }
-
- void
-@@ -177,7 +177,7 @@ msn_user_set_buddy_icon(MsnUser *user, c
- }
- else if ((fp = g_fopen(filename, "rb")) != NULL)
- {
-- GaimCipherContext *ctx;
-+ Gaim2CipherContext *ctx;
- char *buf;
- gsize len;
- char *base64;
-@@ -204,12 +204,12 @@ msn_user_set_buddy_icon(MsnUser *user, c
- /* Compute the SHA1D field. */
- memset(digest, 0, sizeof(digest));
-
-- ctx = gaim_cipher_context_new_by_name("sha1", NULL);
-- gaim_cipher_context_append(ctx, (const guchar *)buf, st.st_size);
-- gaim_cipher_context_digest(ctx, sizeof(digest), digest, NULL);
-+ ctx = gaim2_cipher_context_new_by_name("sha1", NULL);
-+ gaim2_cipher_context_append(ctx, (const guchar *)buf, st.st_size);
-+ gaim2_cipher_context_digest(ctx, sizeof(digest), digest, NULL);
- g_free(buf);
-
-- base64 = gaim_base64_encode(digest, sizeof(digest));
-+ base64 = gaim2_base64_encode(digest, sizeof(digest));
- msn_object_set_sha1d(msnobj, base64);
- g_free(base64);
-
-@@ -227,19 +227,19 @@ msn_user_set_buddy_icon(MsnUser *user, c
-
- memset(digest, 0, sizeof(digest));
-
-- gaim_cipher_context_reset(ctx, NULL);
-- gaim_cipher_context_append(ctx, (const guchar *)buf, strlen(buf));
-- gaim_cipher_context_digest(ctx, sizeof(digest), digest, NULL);
-- gaim_cipher_context_destroy(ctx);
-+ gaim2_cipher_context_reset(ctx, NULL);
-+ gaim2_cipher_context_append(ctx, (const guchar *)buf, strlen(buf));
-+ gaim2_cipher_context_digest(ctx, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_destroy(ctx);
- g_free(buf);
-
-- base64 = gaim_base64_encode(digest, sizeof(digest));
-+ base64 = gaim2_base64_encode(digest, sizeof(digest));
- msn_object_set_sha1c(msnobj, base64);
- g_free(base64);
- }
- else
- {
-- gaim_debug_error("msn", "Unable to open buddy icon %s!\n", filename);
-+ gaim2_debug_error("msn", "Unable to open buddy icon %s!\n", filename);
- msn_user_set_object(user, NULL);
- }
- }
-@@ -248,9 +248,9 @@ void
- msn_user_add_group_id(MsnUser *user, int id)
- {
- MsnUserList *userlist;
-- GaimAccount *account;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Account *account;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
- const char *passport;
- const char *group_name;
-
-@@ -265,21 +265,21 @@ msn_user_add_group_id(MsnUser *user, int
-
- group_name = msn_userlist_find_group_name(userlist, id);
-
-- g = gaim_find_group(group_name);
-+ g = gaim2_find_group(group_name);
-
- if ((id == 0) && (g == NULL))
- {
-- g = gaim_group_new(group_name);
-- gaim_blist_add_group(g, NULL);
-+ g = gaim2_group_new(group_name);
-+ gaim2_blist_add_group(g, NULL);
- }
-
-- b = gaim_find_buddy_in_group(account, passport, g);
-+ b = gaim2_find_buddy_in_group(account, passport, g);
-
- if (b == NULL)
- {
-- b = gaim_buddy_new(account, passport, NULL);
-+ b = gaim2_buddy_new(account, passport, NULL);
-
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- }
-
- b->proto_data = user;
-diff -prNu ./src/protocols/msn/user.h ./src/protocols/msn/user.h
---- ./src/protocols/msn/user.h 2004-12-30 16:55:19.000000000 +0100
-+++ ./src/protocols/msn/user.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file user.h User functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/userlist.c ./src/protocols/msn/userlist.c
---- ./src/protocols/msn/userlist.c 2005-12-07 02:47:31.000000000 +0100
-+++ ./src/protocols/msn/userlist.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file userlist.c MSN user list support
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,7 +28,7 @@ const char *lists[] = { "FL", "AL", "BL"
-
- typedef struct
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *who;
- char *friendly;
-
-@@ -40,21 +40,21 @@ typedef struct
- static void
- msn_accept_add_cb(MsnPermitAdd *pa)
- {
-- if (g_list_find(gaim_connections_get_all(), pa->gc) != NULL)
-+ if (g_list_find(gaim2_connections_get_all(), pa->gc) != NULL)
- {
- MsnSession *session = pa->gc->proto_data;
- MsnUserList *userlist = session->userlist;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- msn_userlist_add_buddy(userlist, pa->who, MSN_LIST_AL, NULL);
-
-- buddy = gaim_find_buddy(pa->gc->account, pa->who);
-+ buddy = gaim2_find_buddy(pa->gc->account, pa->who);
-
- if (buddy != NULL)
-- gaim_account_notify_added(pa->gc->account, pa->who,
-+ gaim2_account_notify_added(pa->gc->account, pa->who,
- NULL, pa->friendly, NULL);
- else
-- gaim_account_request_add(pa->gc->account, pa->who,
-+ gaim2_account_request_add(pa->gc->account, pa->who,
- NULL, pa->friendly, NULL);
- }
-
-@@ -66,7 +66,7 @@ msn_accept_add_cb(MsnPermitAdd *pa)
- static void
- msn_cancel_add_cb(MsnPermitAdd *pa)
- {
-- if (g_list_find(gaim_connections_get_all(), pa->gc) != NULL)
-+ if (g_list_find(gaim2_connections_get_all(), pa->gc) != NULL)
- {
- MsnSession *session = pa->gc->proto_data;
- MsnUserList *userlist = session->userlist;
-@@ -80,7 +80,7 @@ msn_cancel_add_cb(MsnPermitAdd *pa)
- }
-
- static void
--got_new_entry(GaimConnection *gc, const char *passport, const char *friendly)
-+got_new_entry(Gaim2Connection *gc, const char *passport, const char *friendly)
- {
- MsnPermitAdd *pa;
- char *msg;
-@@ -96,17 +96,17 @@ got_new_entry(GaimConnection *gc, const
- _("The user %s (%s) wants to add %s to his or her "
- "buddy list."),
- passport, friendly,
-- gaim_account_get_username(gc->account));
-+ gaim2_account_get_username(gc->account));
- }
- else
- {
- msg = g_strdup_printf(
- _("The user %s wants to add %s to his or "
- "her buddy list."),
-- passport, gaim_account_get_username(gc->account));
-+ passport, gaim2_account_get_username(gc->account));
- }
-
-- gaim_request_action(gc, NULL, msg, NULL,
-+ gaim2_request_action(gc, NULL, msg, NULL,
- GAIM_DEFAULT_ACTION_NONE, pa, 2,
- _("Authorize"), G_CALLBACK(msn_accept_add_cb),
- _("Deny"), G_CALLBACK(msn_cancel_add_cb));
-@@ -165,7 +165,7 @@ get_store_name(MsnUser *user)
- store_name = msn_user_get_store_name(user);
-
- if (store_name != NULL)
-- store_name = gaim_url_encode(store_name);
-+ store_name = gaim2_url_encode(store_name);
- else
- store_name = msn_user_get_passport(user);
-
-@@ -200,7 +200,7 @@ msn_request_add_group(MsnUserList *userl
- data->old_group_name = g_strdup(old_group_name);
-
- trans = msn_transaction_new(cmdproc, "ADG", "%s %d",
-- gaim_url_encode(new_group_name),
-+ gaim2_url_encode(new_group_name),
- 0);
-
- msn_transaction_set_data(trans, data);
-@@ -231,7 +231,7 @@ void
- msn_got_add_user(MsnSession *session, MsnUser *user,
- MsnListId list_id, int group_id)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *passport;
- const char *friendly;
-
-@@ -242,9 +242,9 @@ msn_got_add_user(MsnSession *session, Ms
-
- if (list_id == MSN_LIST_FL)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- serv_got_alias(gc, passport, friendly);
-
-@@ -259,33 +259,33 @@ msn_got_add_user(MsnSession *session, Ms
- }
- else if (list_id == MSN_LIST_AL)
- {
-- gaim_privacy_permit_add(account, passport, TRUE);
-+ gaim2_privacy_permit_add(account, passport, TRUE);
- }
- else if (list_id == MSN_LIST_BL)
- {
-- gaim_privacy_deny_add(account, passport, TRUE);
-+ gaim2_privacy_deny_add(account, passport, TRUE);
- }
- else if (list_id == MSN_LIST_RL)
- {
-- GaimConnection *gc;
-- GaimConversation *convo;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *convo;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
-- gaim_debug_info("msn",
-+ gaim2_debug_info("msn",
- "%s has added you to his or her buddy list.\n",
- passport);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, passport, account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, passport, account);
- if (convo) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- char *msg;
-
-- buddy = gaim_find_buddy(account, passport);
-+ buddy = gaim2_find_buddy(account, passport);
- msg = g_strdup_printf(
- _("%s has added you to his or her buddy list."),
-- buddy ? gaim_buddy_get_contact_alias(buddy) : passport);
-- gaim_conv_im_write(GAIM_CONV_IM(convo), passport, msg,
-+ buddy ? gaim2_buddy_get_contact_alias(buddy) : passport);
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), passport, msg,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- }
-@@ -297,14 +297,14 @@ msn_got_add_user(MsnSession *session, Ms
- }
-
- user->list_op |= (1 << list_id);
-- /* gaim_user_add_list_id (user, list_id); */
-+ /* gaim2_user_add_list_id (user, list_id); */
- }
-
- void
- msn_got_rem_user(MsnSession *session, MsnUser *user,
- MsnListId list_id, int group_id)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *passport;
-
- account = session->account;
-@@ -326,41 +326,41 @@ msn_got_rem_user(MsnSession *session, Ms
- }
- else if (list_id == MSN_LIST_AL)
- {
-- gaim_privacy_permit_remove(account, passport, TRUE);
-+ gaim2_privacy_permit_remove(account, passport, TRUE);
- }
- else if (list_id == MSN_LIST_BL)
- {
-- gaim_privacy_deny_remove(account, passport, TRUE);
-+ gaim2_privacy_deny_remove(account, passport, TRUE);
- }
- else if (list_id == MSN_LIST_RL)
- {
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
-
-- gaim_debug_info("msn",
-+ gaim2_debug_info("msn",
- "%s has removed you from his or her buddy list.\n",
- passport);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, passport, account);
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, passport, account);
- if (convo) {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- char *msg;
-
-- buddy = gaim_find_buddy(account, passport);
-+ buddy = gaim2_find_buddy(account, passport);
- msg = g_strdup_printf(
- _("%s has removed you from his or her buddy list."),
-- buddy ? gaim_buddy_get_contact_alias(buddy) : passport);
-- gaim_conv_im_write(GAIM_CONV_IM(convo), passport, msg,
-+ buddy ? gaim2_buddy_get_contact_alias(buddy) : passport);
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), passport, msg,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- }
- }
-
- user->list_op &= ~(1 << list_id);
-- /* gaim_user_remove_list_id (user, list_id); */
-+ /* gaim2_user_remove_list_id (user, list_id); */
-
- if (user->list_op == 0)
- {
-- gaim_debug_info("msn", "Buddy '%s' shall be deleted?.\n",
-+ gaim2_debug_info("msn", "Buddy '%s' shall be deleted?.\n",
- passport);
-
- }
-@@ -370,13 +370,13 @@ void
- msn_got_lst_user(MsnSession *session, MsnUser *user,
- int list_op, GSList *group_ids)
- {
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- const char *passport;
- const char *store;
-
- account = session->account;
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- passport = msn_user_get_passport(user);
- store = msn_user_get_store_name(user);
-@@ -402,10 +402,10 @@ msn_got_lst_user(MsnSession *session, Ms
- if (g_slist_find_custom(account->deny, passport,
- (GCompareFunc)strcmp))
- {
-- gaim_privacy_deny_remove(gc->account, passport, TRUE);
-+ gaim2_privacy_deny_remove(gc->account, passport, TRUE);
- }
-
-- gaim_privacy_permit_add(account, passport, TRUE);
-+ gaim2_privacy_permit_add(account, passport, TRUE);
- }
-
- if (list_op & MSN_LIST_BL_OP)
-@@ -415,10 +415,10 @@ msn_got_lst_user(MsnSession *session, Ms
- if (g_slist_find_custom(account->permit, passport,
- (GCompareFunc)strcmp))
- {
-- gaim_privacy_permit_remove(gc->account, passport, TRUE);
-+ gaim2_privacy_permit_remove(gc->account, passport, TRUE);
- }
-
-- gaim_privacy_deny_add(account, passport, TRUE);
-+ gaim2_privacy_deny_add(account, passport, TRUE);
- }
-
- if (list_op & MSN_LIST_RL_OP)
-@@ -628,7 +628,7 @@ msn_userlist_rem_buddy(MsnUserList *user
- if (group_id < 0)
- {
- /* Whoa, there is no such group. */
-- gaim_debug_error("msn", "Group doesn't exist: %s\n", group_name);
-+ gaim2_debug_error("msn", "Group doesn't exist: %s\n", group_name);
- return;
- }
- }
-@@ -637,7 +637,7 @@ msn_userlist_rem_buddy(MsnUserList *user
- if (!(user_is_there(user, list_id, group_id)))
- {
- list = lists[list_id];
-- gaim_debug_error("msn", "User '%s' is not there: %s\n",
-+ gaim2_debug_error("msn", "User '%s' is not there: %s\n",
- who, list);
- return;
- }
-@@ -660,7 +660,7 @@ msn_userlist_add_buddy(MsnUserList *user
-
- group_id = -1;
-
-- if (!gaim_email_is_valid(who))
-+ if (!gaim2_email_is_valid(who))
- {
- /* only notify the user about problems adding to the friends list
- * maybe we should do something else for other lists, but it probably
-@@ -668,7 +668,7 @@ msn_userlist_add_buddy(MsnUserList *user
- if (list_id == MSN_LIST_FL)
- {
- char *str = g_strdup_printf(_("Unable to add \"%s\"."), who);
-- gaim_notify_error(NULL, NULL, str,
-+ gaim2_notify_error(NULL, NULL, str,
- _("The screen name specified is invalid."));
- g_free(str);
- }
-@@ -694,7 +694,7 @@ msn_userlist_add_buddy(MsnUserList *user
- if (user_is_there(user, list_id, group_id))
- {
- list = lists[list_id];
-- gaim_debug_error("msn", "User '%s' is already there: %s\n", who, list);
-+ gaim2_debug_error("msn", "User '%s' is already there: %s\n", who, list);
- return;
- }
-
-diff -prNu ./src/protocols/msn/userlist.h ./src/protocols/msn/userlist.h
---- ./src/protocols/msn/userlist.h 2004-08-25 03:43:54.000000000 +0200
-+++ ./src/protocols/msn/userlist.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file userlist.h MSN user list support
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/msn/utils.c ./src/protocols/msn/utils.c
---- ./src/protocols/msn/utils.c 2005-12-08 21:59:32.000000000 +0100
-+++ ./src/protocols/msn/utils.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file utils.c Utility functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -110,7 +110,7 @@ msn_parse_format(const char *mime, char
- }
- }
-
-- cur = g_strdup(gaim_url_decode(pre->str));
-+ cur = g_strdup(gaim2_url_decode(pre->str));
- g_string_free(pre, TRUE);
-
- if (pre_ret != NULL)
-@@ -118,7 +118,7 @@ msn_parse_format(const char *mime, char
- else
- g_free(cur);
-
-- cur = g_strdup(gaim_url_decode(post->str));
-+ cur = g_strdup(gaim2_url_decode(post->str));
- g_string_free(post, TRUE);
-
- if (post_ret != NULL)
-@@ -129,7 +129,7 @@ msn_parse_format(const char *mime, char
-
- /*
- * We need this because we're only supposed to encode spaces in the font
-- * names. gaim_url_encode() isn't acceptable.
-+ * names. gaim2_url_encode() isn't acceptable.
- */
- static const char *
- encode_spaces(const char *str)
-diff -prNu ./src/protocols/msn/utils.h ./src/protocols/msn/utils.h
---- ./src/protocols/msn/utils.h 2004-06-06 05:42:55.000000000 +0200
-+++ ./src/protocols/msn/utils.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file utils.h Utility functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -25,7 +25,7 @@
- #define _MSN_UTILS_H_
-
- /**
-- * Parses the MSN message formatting into a format compatible with Gaim.
-+ * Parses the MSN message formatting into a format compatible with Gaim2.
- *
- * @param mime The mime header with the formatting.
- * @param pre_ret The returned prefix string.
-@@ -36,7 +36,7 @@
- void msn_parse_format(const char *mime, char **pre_ret, char **post_ret);
-
- /**
-- * Parses the Gaim message formatting (html) into the MSN format.
-+ * Parses the Gaim2 message formatting (html) into the MSN format.
- *
- * @param html The html message to format.
- * @param attributes The returned attributes string.
-diff -prNu ./src/protocols/napster/Makefile.am ./src/protocols/napster/Makefile.am
---- ./src/protocols/napster/Makefile.am 2005-10-24 02:15:32.000000000 +0200
-+++ ./src/protocols/napster/Makefile.am 2006-01-05 13:04:10.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- NAPSTERSOURCES = napster.c
-
-diff -prNu ./src/protocols/napster/napster.c ./src/protocols/napster/napster.c
---- ./src/protocols/napster/napster.c 2005-12-25 20:09:23.000000000 +0100
-+++ ./src/protocols/napster/napster.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim - Napster Protocol Plugin
-+ * gaim2 - Napster Protocol Plugin
- *
- * Copyright (C) 2000-2001, Rob Flynn <rob@marko.net>
- *
-@@ -42,13 +42,13 @@ struct nap_data {
- gchar *email;
- };
-
--static GaimConversation *nap_find_chat(GaimConnection *gc, const char *name)
-+static Gaim2Conversation *nap_find_chat(Gaim2Connection *gc, const char *name)
- {
- GSList *bcs = gc->buddy_chats;
-
- while (bcs) {
-- GaimConversation *b = bcs->data;
-- if (!gaim_utf8_strcasecmp(b->name, name))
-+ Gaim2Conversation *b = bcs->data;
-+ if (!gaim2_utf8_strcasecmp(b->name, name))
- return b;
- bcs = bcs->next;
- }
-@@ -56,7 +56,7 @@ static GaimConversation *nap_find_chat(G
- return NULL;
- }
-
--static void nap_write_packet(GaimConnection *gc, unsigned short command, const char *format, ...)
-+static void nap_write_packet(Gaim2Connection *gc, unsigned short command, const char *format, ...)
- {
- struct nap_data *ndata = (struct nap_data *)gc->proto_data;
- va_list ap;
-@@ -68,7 +68,7 @@ static void nap_write_packet(GaimConnect
- va_end(ap);
-
- size = strlen(message);
-- gaim_debug(GAIM_DEBUG_MISC, "napster", "S %3hd: %s\n", command, message);
-+ gaim2_debug(GAIM_DEBUG_MISC, "napster", "S %3hd: %s\n", command, message);
-
- write(ndata->fd, &size, 2);
- write(ndata->fd, &command, 2);
-@@ -77,11 +77,11 @@ static void nap_write_packet(GaimConnect
- g_free(message);
- }
-
--static int nap_do_irc_style(GaimConnection *gc, const char *message, const char *name)
-+static int nap_do_irc_style(Gaim2Connection *gc, const char *message, const char *name)
- {
- gchar **res;
-
-- gaim_debug(GAIM_DEBUG_MISC, "napster", "C %s\n", message);
-+ gaim2_debug(GAIM_DEBUG_MISC, "napster", "C %s\n", message);
-
- res = g_strsplit(message, " ", 2);
-
-@@ -126,9 +126,9 @@ static int nap_do_irc_style(GaimConnecti
- }
-
- /* 205 - MSG_CLIENT_PRIVMSG */
--static int nap_send_im(GaimConnection *gc, const char *who, const char *message, GaimMessageFlags flags)
-+static int nap_send_im(Gaim2Connection *gc, const char *who, const char *message, Gaim2MessageFlags flags)
- {
-- char *tmp = gaim_unescape_html(message);
-+ char *tmp = gaim2_unescape_html(message);
-
- if ((strlen(tmp) < 2) || (tmp[0] != '/' ) || (tmp[1] == '/')) {
- /* Actually send a chat message */
-@@ -144,19 +144,19 @@ static int nap_send_im(GaimConnection *g
- }
-
- /* 207 - MSG_CLIENT_ADD_HOTLIST */
--static void nap_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void nap_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- nap_write_packet(gc, 207, "%s", buddy->name);
- }
-
- /* 208 - MSG_CLIENT_ADD_HOTLIST_SEQ */
--static void nap_send_buddylist(GaimConnection *gc)
-+static void nap_send_buddylist(Gaim2Connection *gc)
- {
-- GaimBuddyList *blist;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *buddy;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *buddy;
-
-- if ((blist = gaim_get_blist()) != NULL)
-+ if ((blist = gaim2_get_blist()) != NULL)
- {
- for (gnode = blist->root; gnode != NULL; gnode = gnode->next)
- {
-@@ -170,7 +170,7 @@ static void nap_send_buddylist(GaimConne
- {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- buddy = (GaimBuddy *)bnode;
-+ buddy = (Gaim2Buddy *)bnode;
- nap_write_packet(gc, 208, "%s", buddy->name);
- }
- }
-@@ -179,7 +179,7 @@ static void nap_send_buddylist(GaimConne
- }
-
- /* 303 - MSG_CLIENT_REMOVE_HOTLIST */
--static void nap_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void nap_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- nap_write_packet(gc, 303, "%s", buddy->name);
- }
-@@ -196,7 +196,7 @@ static char *nap_get_chat_name(GHashTabl
- }
-
- /* 400 - MSG_CLIENT_JOIN */
--static void nap_join_chat(GaimConnection *gc, GHashTable *data)
-+static void nap_join_chat(Gaim2Connection *gc, GHashTable *data)
- {
- char *name;
-
-@@ -212,9 +212,9 @@ static void nap_join_chat(GaimConnection
- }
-
- /* 401 - MSG_CLIENT_PART */
--static void nap_chat_leave(GaimConnection *gc, int id)
-+static void nap_chat_leave(Gaim2Connection *gc, int id)
- {
-- GaimConversation *c = gaim_find_chat(gc, id);
-+ Gaim2Conversation *c = gaim2_find_chat(gc, id);
-
- if (!c)
- return;
-@@ -223,10 +223,10 @@ static void nap_chat_leave(GaimConnectio
- }
-
- /* 402 - MSG_CLIENT_PUBLIC */
--static int nap_chat_send(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags)
-+static int nap_chat_send(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags)
- {
-- GaimConversation *c = gaim_find_chat(gc, id);
-- char *tmp = gaim_unescape_html(message);
-+ Gaim2Conversation *c = gaim2_find_chat(gc, id);
-+ char *tmp = gaim2_unescape_html(message);
-
- if (!c)
- return -EINVAL;
-@@ -245,17 +245,17 @@ static int nap_chat_send(GaimConnection
- }
-
- /* 603 - MSG_CLIENT_WHOIS */
--static void nap_get_info(GaimConnection *gc, const char *who)
-+static void nap_get_info(Gaim2Connection *gc, const char *who)
- {
- nap_write_packet(gc, 603, "%s", who);
- }
-
--static void nap_callback(gpointer data, gint source, GaimInputCondition condition)
-+static void nap_callback(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct nap_data *ndata = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimConversation *c;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2Conversation *c;
- gchar *buf, *buf2, *buf3, **res;
- unsigned short header[2];
- int len;
-@@ -263,7 +263,7 @@ static void nap_callback(gpointer data,
- int i;
-
- if (read(source, (void*)header, 4) != 4) {
-- gaim_connection_error(gc, _("Unable to read header from server"));
-+ gaim2_connection_error(gc, _("Unable to read header from server"));
- return;
- }
-
-@@ -278,30 +278,30 @@ static void nap_callback(gpointer data,
- if (tmp <= 0) {
- g_free(buf);
- buf = g_strdup_printf(_("Unable to read message from server: %s. Command is %hd, length is %hd."), strerror(errno), len, command);
-- gaim_connection_error(gc, buf);
-+ gaim2_connection_error(gc, buf);
- g_free(buf);
- return;
- }
- i += tmp;
- } while (i != len);
-
-- gaim_debug(GAIM_DEBUG_MISC, "napster", "R %3hd: %s\n", command, buf);
-+ gaim2_debug(GAIM_DEBUG_MISC, "napster", "R %3hd: %s\n", command, buf);
-
- switch (command) {
- case 000: /* MSG_SERVER_ERROR */
-- gaim_notify_error(gc, NULL, buf, NULL);
-- gaim_input_remove(gc->inpa);
-+ gaim2_notify_error(gc, NULL, buf, NULL);
-+ gaim2_input_remove(gc->inpa);
- gc->inpa = 0;
- close(source);
-- gaim_connection_error(gc, _("Unknown server error."));
-+ gaim2_connection_error(gc, _("Unknown server error."));
- break;
-
- case 003: /* MSG_SERVER_EMAIL */
-- gaim_debug(GAIM_DEBUG_MISC, "napster", "Registered with e-mail address: %s\n", buf);
-+ gaim2_debug(GAIM_DEBUG_MISC, "napster", "Registered with e-mail address: %s\n", buf);
- ndata->email = g_strdup(buf);
-
- /* Our signon is complete */
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- /* Send the server our buddy list */
- nap_send_buddylist(gc);
-@@ -310,12 +310,12 @@ static void nap_callback(gpointer data,
-
- case 201: /* MSG_SERVER_SEARCH_RESULT */
- res = g_strsplit(buf, " ", 0);
-- gaim_prpl_got_user_status(account, res[0], "available", NULL);
-+ gaim2_prpl_got_user_status(account, res[0], "available", NULL);
- g_strfreev(res);
- break;
-
- case 202: /* MSG_SERVER_SEARCH_END */
-- gaim_prpl_got_user_status(account, buf, "offline", NULL);
-+ gaim2_prpl_got_user_status(account, buf, "offline", NULL);
- break;
-
- case 205: /* MSG_CLIENT_PRIVMSG */
-@@ -329,14 +329,14 @@ static void nap_callback(gpointer data,
- case 209: /* MSG_SERVER_USER_SIGNON */
- /* USERNAME SPEED */
- res = g_strsplit(buf, " ", 2);
-- gaim_prpl_got_user_status(account, res[0], "available", NULL);
-+ gaim2_prpl_got_user_status(account, res[0], "available", NULL);
- g_strfreev(res);
- break;
-
- case 210: /* MSG_SERVER_USER_SIGNOFF */
- /* USERNAME SPEED */
- res = g_strsplit(buf, " ", 2);
-- gaim_prpl_got_user_status(account, res[0], "offline", NULL);
-+ gaim2_prpl_got_user_status(account, res[0], "offline", NULL);
- g_strfreev(res);
- break;
-
-@@ -354,26 +354,26 @@ static void nap_callback(gpointer data,
-
- case 302: /* MSG_SERVER_HOTLIST_ERROR */
- buf2 = g_strdup_printf(_("Unable to add \"%s\" to your Napster hotlist"), buf);
-- gaim_notify_error(gc, NULL, buf2, NULL);
-+ gaim2_notify_error(gc, NULL, buf2, NULL);
- g_free(buf2);
- break;
-
- case 316: /* MSG_SERVER_DISCONNECTING */
- /* we have been kicked off =^( */
-- gaim_connection_error(gc, _("You were disconnected from the server."));
-+ gaim2_connection_error(gc, _("You were disconnected from the server."));
- break;
-
- case 401: /* MSG_CLIENT_PART */
- c = nap_find_chat(gc, buf);
- if (c)
-- serv_got_chat_left(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(c)));
-+ serv_got_chat_left(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(c)));
- break;
-
- case 403: /* MSG_SERVER_PUBLIC */
- res = g_strsplit(buf, " ", 3);
- c = nap_find_chat(gc, res[0]);
- if (c)
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(c)), res[1], 0, res[2], time((time_t)NULL));
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(c)), res[1], 0, res[2], time((time_t)NULL));
- g_strfreev(res);
- break;
-
-@@ -387,13 +387,13 @@ static void nap_callback(gpointer data,
- case 405: /* MSG_SERVER_JOIN_ACK */
- c = nap_find_chat(gc, buf);
- if (!c)
-- serv_got_joined_chat(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(c)), buf);
-+ serv_got_joined_chat(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(c)), buf);
- break;
-
- case 407: /* MSG_SERVER_PART */
- res = g_strsplit(buf, " ", 0);
- c = nap_find_chat(gc, res[0]);
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(c), res[1], NULL);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(c), res[1], NULL);
- g_strfreev(res);
- break;
-
-@@ -401,7 +401,7 @@ static void nap_callback(gpointer data,
- case 408: /* MSG_SERVER_CHANNEL_USER_LIST */
- res = g_strsplit(buf, " ", 4);
- c = nap_find_chat(gc, res[0]);
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(c), res[1], NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(c), res[1], NULL, GAIM_CBFLAGS_NONE, TRUE);
- g_strfreev(res);
- break;
-
-@@ -412,7 +412,7 @@ static void nap_callback(gpointer data,
- /* display the topic in the channel */
- res = g_strsplit(buf, " ", 2);
- c = nap_find_chat(gc, res[0]);
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(c), res[0], res[1]);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(c), res[0], res[1]);
- g_strfreev(res);
- break;
-
-@@ -423,10 +423,10 @@ static void nap_callback(gpointer data,
- break;
-
- case 604: /* MSG_SERVER_WHOIS_RESPONSE */
-- /* XXX - Format is: "Elite" 37 " " "Active" 0 0 0 0 "gaim 0.63cvs" 0 0 192.168.1.41 32798 0 unknown flounder */
-+ /* XXX - Format is: "Elite" 37 " " "Active" 0 0 0 0 "gaim2 0.63cvs" 0 0 192.168.1.41 32798 0 unknown flounder */
- res = g_strsplit(buf, " ", 2);
- /* res[0] == username */
-- gaim_notify_userinfo(gc, res[0], res[1], NULL, NULL);
-+ gaim2_notify_userinfo(gc, res[0], res[1], NULL, NULL);
- g_strfreev(res);
- break;
-
-@@ -453,7 +453,7 @@ static void nap_callback(gpointer data,
-
- case 748: /* MSG_SERVER_GHOST */
- /* Looks like someone logged in as us! =-O */
-- gaim_connection_error(gc, _("You have signed on from another location."));
-+ gaim2_connection_error(gc, _("You have signed on from another location."));
- break;
-
- case 751: /* MSG_CLIENT_PING */
-@@ -467,7 +467,7 @@ static void nap_callback(gpointer data,
-
- case 752: /* MSG_CLIENT_PONG */
- buf2 = g_strdup_printf("Received pong from %s", buf);
-- gaim_notify_info(gc, NULL, buf2, NULL);
-+ gaim2_notify_info(gc, NULL, buf2, NULL);
- g_free(buf2);
- break;
-
-@@ -477,14 +477,14 @@ static void nap_callback(gpointer data,
- buf3 = g_strdup_printf("/me %s", buf2);
- g_free(buf2);
- if ((c = nap_find_chat(gc, res[0]))) {
-- gaim_conv_chat_write(GAIM_CONV_CHAT(c), res[1], buf3, GAIM_MESSAGE_NICK, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(c), res[1], buf3, GAIM_MESSAGE_NICK, time(NULL));
- }
- g_free(buf3);
- g_strfreev(res);
- break;
-
- default:
-- gaim_debug(GAIM_DEBUG_MISC, "napster", "Unknown packet %hd: %s\n", command, buf);
-+ gaim2_debug(GAIM_DEBUG_MISC, "napster", "Unknown packet %hd: %s\n", command, buf);
- break;
- }
-
-@@ -492,59 +492,59 @@ static void nap_callback(gpointer data,
- }
-
- /* 002 - MSG_CLIENT_LOGIN */
--static void nap_login_connect(gpointer data, gint source, GaimInputCondition cond)
-+static void nap_login_connect(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct nap_data *ndata = (struct nap_data *)gc->proto_data;
- gchar *buf;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Unable to connect."));
-+ gaim2_connection_error(gc, _("Unable to connect."));
- return;
- }
-
- ndata->fd = source;
-
- /* Update the login progress status display */
-- buf = g_strdup_printf("Logging in: %s", gaim_account_get_username(gc->account));
-- gaim_connection_update_progress(gc, buf, 1, NAPSTER_CONNECT_STEPS);
-+ buf = g_strdup_printf("Logging in: %s", gaim2_account_get_username(gc->account));
-+ gaim2_connection_update_progress(gc, buf, 1, NAPSTER_CONNECT_STEPS);
- g_free(buf);
-
- /* Write our signon data */
-- nap_write_packet(gc, 2, "%s %s 0 \"gaim %s\" 0",
-- gaim_account_get_username(gc->account),
-- gaim_connection_get_password(gc), VERSION);
-+ nap_write_packet(gc, 2, "%s %s 0 \"gaim2 %s\" 0",
-+ gaim2_account_get_username(gc->account),
-+ gaim2_connection_get_password(gc), VERSION);
-
- /* And set up the input watcher */
-- gc->inpa = gaim_input_add(ndata->fd, GAIM_INPUT_READ, nap_callback, gc);
-+ gc->inpa = gaim2_input_add(ndata->fd, GAIM_INPUT_READ, nap_callback, gc);
- }
-
--static void nap_login(GaimAccount *account)
-+static void nap_login(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-
-- gaim_connection_update_progress(gc, _("Connecting"), 0, NAPSTER_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 0, NAPSTER_CONNECT_STEPS);
-
- gc->proto_data = g_new0(struct nap_data, 1);
-- if (gaim_proxy_connect(account,
-- gaim_account_get_string(account, "server", NAP_SERVER),
-- gaim_account_get_int(account, "port", NAP_PORT),
-+ if (gaim2_proxy_connect(account,
-+ gaim2_account_get_string(account, "server", NAP_SERVER),
-+ gaim2_account_get_int(account, "port", NAP_PORT),
- nap_login_connect, gc) != 0) {
-- gaim_connection_error(gc, _("Unable to connect."));
-+ gaim2_connection_error(gc, _("Unable to connect."));
- }
- }
-
--static void nap_close(GaimConnection *gc)
-+static void nap_close(Gaim2Connection *gc)
- {
- struct nap_data *ndata = (struct nap_data *)gc->proto_data;
-
- if (gc->inpa)
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
-
- if (!ndata)
- return;
-@@ -555,37 +555,37 @@ static void nap_close(GaimConnection *gc
- g_free(ndata);
- }
-
--static const char* nap_list_icon(GaimAccount *a, GaimBuddy *b)
-+static const char* nap_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- return "napster";
- }
-
--static void nap_list_emblems(GaimBuddy *b, const char **se, const char **sw,
-+static void nap_list_emblems(Gaim2Buddy *b, const char **se, const char **sw,
- const char **nw, const char **ne)
- {
- if(!GAIM_BUDDY_IS_ONLINE(b))
- *se = "offline";
- }
-
--static GList *nap_status_types(GaimAccount *account)
-+static GList *nap_status_types(Gaim2Account *account)
- {
- GList *types = NULL;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_AVAILABLE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AVAILABLE,
- NULL, NULL, TRUE, TRUE, FALSE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_OFFLINE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_OFFLINE,
- NULL, NULL, TRUE, TRUE, FALSE);
- types = g_list_append(types, type);
-
- return types;
- }
-
--static GList *nap_chat_info(GaimConnection *gc)
-+static GList *nap_chat_info(Gaim2Connection *gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -598,7 +598,7 @@ static GList *nap_chat_info(GaimConnecti
- return m;
- }
-
--GHashTable *nap_chat_info_defaults(GaimConnection *gc, const char *chat_name)
-+GHashTable *nap_chat_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
-
-@@ -610,9 +610,9 @@ GHashTable *nap_chat_info_defaults(GaimC
- return defaults;
- }
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_CHAT_TOPIC,
- NULL, /* user_splits */
-@@ -677,7 +677,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -708,16 +708,16 @@ static GaimPluginInfo info =
- NULL
- };
-
--static void init_plugin(GaimPlugin *plugin)
-+static void init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_string_new(_("Server"), "server",
-+ option = gaim2_account_option_string_new(_("Server"), "server",
- NAP_SERVER);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_int_new(_("Port"), "port", 8888);
-+ option = gaim2_account_option_int_new(_("Port"), "port", 8888);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-diff -prNu ./src/protocols/novell/Makefile.am ./src/protocols/novell/Makefile.am
---- ./src/protocols/novell/Makefile.am 2005-04-29 19:04:27.000000000 +0200
-+++ ./src/protocols/novell/Makefile.am 2006-01-05 13:04:24.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- NOVELLSOURCES = \
- nmfield.h \
-diff -prNu ./src/protocols/novell/nmconference.c ./src/protocols/novell/nmconference.c
---- ./src/protocols/novell/nmconference.c 2004-05-15 16:00:30.000000000 +0200
-+++ ./src/protocols/novell/nmconference.c 2006-01-05 15:11:07.000000000 +0100
-@@ -60,7 +60,7 @@ nm_create_conference(const char *guid)
- }
- conf->ref_count = 1;
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Creating a conference %p, total=%d\n",
- conf, conf_count++);
-
-@@ -72,12 +72,12 @@ nm_release_conference(NMConference * con
- {
- GSList *node;
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "In release conference %p, refs=%d\n",
- conference, conference->ref_count);
- if (conference != NULL && (--conference->ref_count == 0)) {
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Releasing conference %p, total=%d\n",
- conference, --conf_count);
-
-diff -prNu ./src/protocols/novell/nmcontact.c ./src/protocols/novell/nmcontact.c
---- ./src/protocols/novell/nmcontact.c 2004-05-15 16:00:31.000000000 +0200
-+++ ./src/protocols/novell/nmcontact.c 2006-01-05 15:11:07.000000000 +0100
-@@ -64,7 +64,7 @@ nm_create_contact()
-
- contact->ref_count = 1;
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell", "Creating contact, total=%d\n",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell", "Creating contact, total=%d\n",
- count++);
-
- return contact;
-@@ -229,7 +229,7 @@ nm_release_contact(NMContact * contact)
-
- if (--(contact->ref_count) == 0) {
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Releasing contact, total=%d\n", --count);
-
- if (contact->display_name) {
-diff -prNu ./src/protocols/novell/nmevent.c ./src/protocols/novell/nmevent.c
---- ./src/protocols/novell/nmevent.c 2004-08-23 20:55:36.000000000 +0200
-+++ ./src/protocols/novell/nmevent.c 2006-01-05 15:11:07.000000000 +0100
-@@ -170,7 +170,7 @@ handle_receive_message(NMUser * user, NM
- msg = g_new0(char, size + 1);
- rc = nm_read_all(conn, msg, size);
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell", "Message is %s\n", msg);
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell", "Message is %s\n", msg);
-
- /* Auto replies are not in RTF format! */
- if (!autoreply) {
-@@ -180,7 +180,7 @@ handle_receive_message(NMUser * user, NM
- nortf = nm_rtf_strip_formatting(ctx, msg);
- nm_rtf_deinit(ctx);
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Message without RTF is %s\n", nortf);
-
- /* Store the event data */
-@@ -910,7 +910,7 @@ nm_process_event(NMUser * user, int type
- break;
-
- default:
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Unknown event %d received.\n", type);
- rc = NMERR_PROTOCOL;
- break;
-diff -prNu ./src/protocols/novell/nmrequest.c ./src/protocols/novell/nmrequest.c
---- ./src/protocols/novell/nmrequest.c 2004-06-23 19:27:56.000000000 +0200
-+++ ./src/protocols/novell/nmrequest.c 2006-01-05 15:11:07.000000000 +0100
-@@ -51,7 +51,7 @@ NMRequest *nm_create_request(const char
- req->user_define = user_define;
- req->ref_count = 1;
-
-- gaim_debug_info("novell", "Creating NMRequest instance, total=%d\n", ++count);
-+ gaim2_debug_info("novell", "Creating NMRequest instance, total=%d\n", ++count);
-
- return req;
- }
-@@ -64,7 +64,7 @@ nm_release_request(NMRequest * req)
- g_free(req->cmd);
- g_free(req);
-
-- gaim_debug_info("novell",
-+ gaim2_debug_info("novell",
- "Releasing NMRequest instance, total=%d\n", --count);
- }
-
-diff -prNu ./src/protocols/novell/nmrtf.c ./src/protocols/novell/nmrtf.c
---- ./src/protocols/novell/nmrtf.c 2004-08-21 22:11:42.000000000 +0200
-+++ ./src/protocols/novell/nmrtf.c 2006-01-05 15:11:07.000000000 +0100
-@@ -233,7 +233,7 @@ nm_rtf_strip_formatting(NMRtfContext *ct
- if (status == NMRTF_OK)
- return g_strdup(ctx->output->str);
-
-- gaim_debug_info("novell", "RTF parser failed with error code %d", status);
-+ gaim2_debug_info("novell", "RTF parser failed with error code %d", status);
- return NULL;
- }
-
-@@ -312,7 +312,7 @@ get_current_encoding(NMRtfContext *ctx)
- case 254:
- return "CP437";
- default:
-- gaim_debug_info("novell", "Unhandled font charset %d\n", font->charset);
-+ gaim2_debug_info("novell", "Unhandled font charset %d\n", font->charset);
- return "CP1252";
- }
- return "CP1252";
-@@ -331,7 +331,7 @@ rtf_add_font_entry(NMRtfContext *ctx, in
- font->name = g_strdup(name);
- font->charset = charset;
-
-- gaim_debug_info("novell", "Adding font to table: #%d\t%s\t%d\n",
-+ gaim2_debug_info("novell", "Adding font to table: #%d\t%s\t%d\n",
- font->number, font->name, font->charset);
-
- ctx->font_table = g_slist_append(ctx->font_table, font);
-@@ -629,7 +629,7 @@ rtf_print_unicode_char(NMRtfContext *ctx
- /* convert the unicode character to utf8 and add directly to the output buffer */
- num = g_unichar_to_utf8((gunichar) ch, buf);
- buf[num] = 0;
-- gaim_debug_info("novell", "converted unichar 0x%X to utf8 char %s\n", ch, buf);
-+ gaim2_debug_info("novell", "converted unichar 0x%X to utf8 char %s\n", ch, buf);
-
- ctx->output = g_string_append(ctx->output, buf);
- return NMRTF_OK;
-@@ -656,7 +656,7 @@ rtf_flush_data(NMRtfContext *ctx)
- ctx->ansi = g_string_truncate(ctx->ansi, 0);
- } else {
- status = NMRTF_CONVERT_ERROR;
-- gaim_debug_info("novell", "failed to convert data! error code = %d msg = %s\n",
-+ gaim2_debug_info("novell", "failed to convert data! error code = %d msg = %s\n",
- gerror->code, gerror->message);
- g_free(gerror);
- }
-@@ -783,7 +783,7 @@ rtf_dispatch_special(NMRtfContext *ctx,
- ctx->ris = NMRTF_STATE_HEX;
- break;
- case NMRTF_SPECIAL_UNICODE:
-- gaim_debug_info("novell", "parsing unichar\n");
-+ gaim2_debug_info("novell", "parsing unichar\n");
- status = rtf_dispatch_unicode_char(ctx, ctx->param);
- /* Skip next char */
- if (status == NMRTF_OK)
-diff -prNu ./src/protocols/novell/nmuser.c ./src/protocols/novell/nmuser.c
---- ./src/protocols/novell/nmuser.c 2005-12-08 22:00:35.000000000 +0100
-+++ ./src/protocols/novell/nmuser.c 2006-01-05 15:11:07.000000000 +0100
-@@ -477,8 +477,8 @@ nm_send_message(NMUser * user, NMMessage
-
- rtfized = nm_rtfize_text(text);
-
-- gaim_debug_info("novell", "message text is: %s\n", text);
-- gaim_debug_info("novell", "message rtf is: %s\n", rtfized);
-+ gaim2_debug_info("novell", "message text is: %s\n", text);
-+ gaim2_debug_info("novell", "message rtf is: %s\n", rtfized);
-
- tmp = nm_field_add_pointer(tmp, NM_A_SZ_MESSAGE_BODY, 0, NMFIELD_METHOD_VALID, 0,
- rtfized, NMFIELD_TYPE_UTF8);
-@@ -1739,7 +1739,7 @@ nm_call_handler(NMUser * user, NMRequest
- } else {
-
- /* Nothing to do, just print debug message */
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "nm_call_handler(): Unknown request command, %s\n", cmd);
-
- }
-@@ -2124,12 +2124,12 @@ nm_rtfize_text(char *text)
- bytes = 6;
- } else {
- /* should never happen ... bogus utf-8! */
-- gaim_debug_info("novell", "bogus utf-8 lead byte: 0x%X\n", pch[0]);
-+ gaim2_debug_info("novell", "bogus utf-8 lead byte: 0x%X\n", pch[0]);
- uc = 0x003F;
- bytes = 1;
- }
- uni_str = g_strdup_printf("\\u%d?", uc);
-- gaim_debug_info("novell", "unicode escaped char %s\n", uni_str);
-+ gaim2_debug_info("novell", "unicode escaped char %s\n", uni_str);
- gstr = g_string_append(gstr, uni_str);
- pch += bytes;
- g_free(uni_str);
-diff -prNu ./src/protocols/novell/nmuser.h ./src/protocols/novell/nmuser.h
---- ./src/protocols/novell/nmuser.h 2004-06-23 19:27:56.000000000 +0200
-+++ ./src/protocols/novell/nmuser.h 2006-01-05 15:11:21.000000000 +0100
-@@ -211,7 +211,7 @@ void nm_deinitialize_user(NMUser * user)
- * @param user The User to login -- must be initialized
- * @param pwd The password of the user
- * @param my_addr The address of the client machine
-- * @param user_agent String describing the client (eg. "Gaim/0.76 (Linux; 2.4.20)")
-+ * @param user_agent String describing the client (eg. "Gaim2/0.76 (Linux; 2.4.20)")
- * @param callback Function to call when we get the response from the server
- * @param data User defined data to be passed to the callback function
- *
-diff -prNu ./src/protocols/novell/nmuserrecord.c ./src/protocols/novell/nmuserrecord.c
---- ./src/protocols/novell/nmuserrecord.c 2004-05-15 16:00:31.000000000 +0200
-+++ ./src/protocols/novell/nmuserrecord.c 2006-01-05 15:11:07.000000000 +0100
-@@ -57,7 +57,7 @@ nm_create_user_record()
-
- user_record->ref_count = 1;
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell", "Creating user_record, total=%d\n",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell", "Creating user_record, total=%d\n",
- count++);
-
- return user_record;
-@@ -279,7 +279,7 @@ nm_release_user_record(NMUserRecord * us
- {
- if (--(user_record->ref_count) == 0) {
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Releasing user_record, total=%d\n", --count);
-
- if (user_record->dn) {
-diff -prNu ./src/protocols/novell/novell.c ./src/protocols/novell/novell.c
---- ./src/protocols/novell/novell.c 2006-01-04 06:07:51.000000000 +0100
-+++ ./src/protocols/novell/novell.c 2006-01-05 15:11:07.000000000 +0100
-@@ -44,7 +44,7 @@
- #define NOVELL_STATUS_TYPE_IDLE "idle"
- #define NOVELL_STATUS_TYPE_APPEAR_OFFLINE "appearoffline"
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
- static gboolean
- _is_disconnect_error(NMERR_T err);
-@@ -56,16 +56,16 @@ static void
- _send_message(NMUser * user, NMMessage * message);
-
- static void
--_update_buddy_status(NMUser *user, GaimBuddy * buddy, int status, int gmt);
-+_update_buddy_status(NMUser *user, Gaim2Buddy * buddy, int status, int gmt);
-
- static void
--_remove_gaim_buddies(NMUser * user);
-+_remove_gaim2_buddies(NMUser * user);
-
- static void
--_add_contacts_to_gaim_blist(NMUser * user, NMFolder * folder);
-+_add_contacts_to_gaim2_blist(NMUser * user, NMFolder * folder);
-
- static void
--_add_gaim_buddies(NMUser * user);
-+_add_gaim2_buddies(NMUser * user);
-
- static void
- _sync_contact_list(NMUser *user);
-@@ -74,7 +74,7 @@ static void
- _sync_privacy_lists(NMUser *user);
-
- static void
--_show_info(GaimConnection * gc, NMUserRecord * user_record);
-+_show_info(Gaim2Connection * gc, NMUserRecord * user_record);
-
- const char *
- _get_conference_name(int id);
-@@ -88,30 +88,30 @@ static void
- _login_resp_cb(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *alias;
- NMERR_T rc;
-
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- if (gc == NULL)
- return;
-
- if (ret_code == NM_OK) {
-
- /* Set alias for user if not set (use Full Name) */
-- alias = gaim_account_get_alias(user->client_data);
-+ alias = gaim2_account_get_alias(user->client_data);
- if (alias == NULL || *alias == '\0') {
- alias = nm_user_record_get_full_name(user->user_record);
-
- if (alias)
-- gaim_account_set_alias(user->client_data, alias);
-+ gaim2_account_set_alias(user->client_data, alias);
- }
-
-- /* Tell Gaim that we are connected */
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ /* Tell Gaim2 that we are connected */
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- _sync_contact_list(user);
-
-@@ -130,9 +130,9 @@ _login_resp_cb(NMUser * user, NMERR_T re
- if (ret_code == NMERR_AUTHENTICATION_FAILED ||
- ret_code == NMERR_CREDENTIALS_MISSING ||
- ret_code == NMERR_PASSWORD_INVALID) {
-- gaim_account_set_password((GaimAccount*)user->client_data, NULL);
-+ gaim2_account_set_password((Gaim2Account*)user->client_data, NULL);
- }
-- gaim_connection_error(gc, err);
-+ gaim2_connection_error(gc, err);
- g_free(err);
- }
- }
-@@ -142,7 +142,7 @@ static void
- _get_status_resp_cb(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- GSList *buddies;
- GSList *bnode;
- NMUserRecord *user_record = (NMUserRecord *) resp_data;
-@@ -153,13 +153,13 @@ _get_status_resp_cb(NMUser * user, NMERR
-
- if (ret_code == NM_OK) {
-
-- /* Find all Gaim buddies and update their statuses */
-+ /* Find all Gaim2 buddies and update their statuses */
- const char *name = nm_user_record_get_display_id(user_record);
-
- if (name) {
-- buddies = gaim_find_buddies((GaimAccount *) user->client_data, name);
-+ buddies = gaim2_find_buddies((Gaim2Account *) user->client_data, name);
- for (bnode = buddies; bnode; bnode = bnode->next) {
-- buddy = (GaimBuddy *) bnode->data;
-+ buddy = (Gaim2Buddy *) bnode->data;
- if (buddy) {
- status = nm_user_record_get_status(user_record);
- _update_buddy_status(user, buddy, status, time(0));
-@@ -170,7 +170,7 @@ _get_status_resp_cb(NMUser * user, NMERR
-
- } else {
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_get_status_resp_cb(): rc = 0x%X\n", ret_code);
-
- }
-@@ -182,7 +182,7 @@ _rename_contact_resp_cb(NMUser * user, N
- gpointer resp_data, gpointer user_data)
- {
- if (ret_code != NM_OK) {
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_rename_contact_resp_cb(): rc = 0x%X\n", ret_code);
- }
- }
-@@ -192,8 +192,8 @@ static void
- _get_details_resp_send_msg(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConversation *gconv;
-- GaimConnection *gc;
-+ Gaim2Conversation *gconv;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record = NULL;
- NMContact *cntct = NULL;
- NMConference *conf;
-@@ -210,9 +210,9 @@ _get_details_resp_send_msg(NMUser * user
-
- /* Set the title for the conversation */
- /* XXX - Should this be GAIM_CONV_TYPE_IM? */
-- gconv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
-+ gconv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
- nm_user_record_get_display_id(user_record),
-- (GaimAccount *) user->client_data);
-+ (Gaim2Account *) user->client_data);
- if (gconv) {
-
- dn = nm_user_record_get_dn(user_record);
-@@ -221,14 +221,14 @@ _get_details_resp_send_msg(NMUser * user
- }
-
- if (cntct) {
-- gaim_conversation_set_title(gconv,
-+ gaim2_conversation_set_title(gconv,
- nm_contact_get_display_name(cntct));
- } else {
-
- /* Not in the contact list, try to user full name */
- name = (char *) nm_user_record_get_full_name(user_record);
- if (name)
-- gaim_conversation_set_title(gconv, name);
-+ gaim2_conversation_set_title(gconv, name);
- }
- }
-
-@@ -242,13 +242,13 @@ _get_details_resp_send_msg(NMUser * user
-
- } else {
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- if (gc != NULL) {
- char *err = g_strdup_printf(_("Unable to send message."
- " Could not get details for user (%s)."),
- nm_error_to_string (ret_code));
-
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
-
-@@ -257,14 +257,14 @@ _get_details_resp_send_msg(NMUser * user
- }
- }
-
--/* Set up the new GaimBuddy based on the response from getdetails */
-+/* Set up the new Gaim2Buddy based on the response from getdetails */
- static void
- _get_details_resp_setup_buddy(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
- NMUserRecord *user_record;
- NMContact *contact;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- const char *alias;
- NMERR_T rc = NM_OK;
-
-@@ -281,12 +281,12 @@ _get_details_resp_setup_buddy(NMUser * u
- nm_contact_set_user_record(contact, user_record);
-
- /* Set the display id */
-- gaim_blist_rename_buddy(buddy,
-+ gaim2_blist_rename_buddy(buddy,
- nm_user_record_get_display_id(user_record));
-
-- alias = gaim_buddy_get_alias(buddy);
-+ alias = gaim2_buddy_get_alias(buddy);
- if (alias == NULL || *alias == '\0' || (strcmp(alias, buddy->name) == 0)) {
-- gaim_blist_alias_buddy(buddy,
-+ gaim2_blist_alias_buddy(buddy,
- nm_user_record_get_full_name(user_record));
-
- /* Tell the server about the new display name */
-@@ -310,7 +310,7 @@ _get_details_resp_setup_buddy(NMUser * u
- nm_release_contact(contact);
- }
-
--/* Add the new contact into the GaimBuddy list */
-+/* Add the new contact into the Gaim2Buddy list */
- static void
- _create_contact_resp_cb(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
-@@ -318,8 +318,8 @@ _create_contact_resp_cb(NMUser * user, N
- NMContact *tmp_contact = (NMContact *) user_data;
- NMContact *new_contact = NULL;
- NMFolder *folder = NULL;
-- GaimGroup *group;
-- GaimBuddy *buddy;
-+ Gaim2Group *group;
-+ Gaim2Buddy *buddy;
- const char *folder_name = NULL;
- NMERR_T rc = NM_OK;
-
-@@ -343,7 +343,7 @@ _create_contact_resp_cb(NMUser * user, N
- folder_name = NM_ROOT_FOLDER_NAME;
-
- /* Re-add the buddy now that we got the okay from the server */
-- if (folder_name && (group = gaim_find_group(folder_name))) {
-+ if (folder_name && (group = gaim2_find_group(folder_name))) {
-
- const char *alias = nm_contact_get_display_name(tmp_contact);
- const char *display_id = nm_contact_get_display_id(new_contact);
-@@ -364,18 +364,18 @@ _create_contact_resp_cb(NMUser * user, N
-
- }
-
-- /* Add it to the gaim buddy list if it is not there */
-- buddy = gaim_find_buddy_in_group(user->client_data, display_id, group);
-+ /* Add it to the gaim2 buddy list if it is not there */
-+ buddy = gaim2_find_buddy_in_group(user->client_data, display_id, group);
- if (buddy == NULL) {
-- buddy = gaim_buddy_new(user->client_data, display_id, alias);
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-+ buddy = gaim2_buddy_new(user->client_data, display_id, alias);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
- }
-
- /* Save the new buddy as part of the contact object */
- nm_contact_set_data(new_contact, (gpointer) buddy);
-
- /* We need details for the user before we can setup the
-- * new Gaim buddy. We always call this because the
-+ * new Gaim2 buddy. We always call this because the
- * 'createcontact' response fields do not always contain
- * everything that we need.
- */
-@@ -388,14 +388,14 @@ _create_contact_resp_cb(NMUser * user, N
- }
-
- } else {
-- GaimConnection *gc = gaim_account_get_connection(user->client_data);
-+ Gaim2Connection *gc = gaim2_account_get_connection(user->client_data);
- const char *name = nm_contact_get_dn(tmp_contact);
- char *err;
-
- err =
- g_strdup_printf(_("Unable to add %s to your buddy list (%s)."),
- name, nm_error_to_string (ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -409,19 +409,19 @@ static void
- _send_message_resp_cb(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *err = NULL;
-
- if (user == NULL)
- return;
-
- if (ret_code != NM_OK) {
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
-
- /* TODO: Improve this! message to who or for what conference? */
- err = g_strdup_printf(_("Unable to send message (%s)."),
- nm_error_to_string (ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
- }
-@@ -434,7 +434,7 @@ _remove_contact_resp_cb(NMUser * user, N
- if (ret_code != NM_OK) {
- /* TODO: Display an error? */
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_remove_contact_resp_cb(): rc = 0x%x\n", ret_code);
- }
- }
-@@ -447,7 +447,7 @@ _remove_folder_resp_cb(NMUser * user, NM
- if (ret_code != NM_OK) {
- /* TODO: Display an error? */
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_remove_folder_resp_cb(): rc = 0x%x\n", ret_code);
- }
- }
-@@ -460,7 +460,7 @@ _move_contact_resp_cb(NMUser * user, NME
- if (ret_code != NM_OK) {
- /* TODO: Display an error? */
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_move_contact_resp_cb(): rc = 0x%x\n", ret_code);
- }
- }
-@@ -473,7 +473,7 @@ _rename_folder_resp_cb(NMUser * user, NM
- if (ret_code != NM_OK) {
- /* TODO: Display an error? */
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_rename_folder_resp_cb(): rc = 0x%x\n", ret_code);
- }
- }
-@@ -483,18 +483,18 @@ _sendinvite_resp_cb(NMUser *user, NMERR_
- gpointer resp_data, gpointer user_data)
- {
- char *err;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- if (user == NULL)
- return;
-
- if (ret_code != NM_OK) {
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- err = g_strdup_printf(_("Unable to invite user (%s)."), nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_sendinvite_resp_cb(): rc = 0x%x\n", ret_code);
- }
-
-@@ -519,7 +519,7 @@ _createconf_resp_send_msg(NMUser * user,
-
- if ((conf = nm_message_get_conference(msg))) {
-
-- GaimConnection *gc = gaim_account_get_connection(user->client_data);
-+ Gaim2Connection *gc = gaim2_account_get_connection(user->client_data);
- const char *name = NULL;
- char *err;
- NMUserRecord *ur;
-@@ -538,7 +538,7 @@ _createconf_resp_send_msg(NMUser * user,
- " Could not create the conference (%s)."),
- nm_error_to_string (ret_code));
-
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
-
-@@ -580,7 +580,7 @@ _create_folder_resp_move_contact(NMUser
-
- }
- } else {
-- GaimConnection *gc = gaim_account_get_connection(user->client_data);
-+ Gaim2Connection *gc = gaim2_account_get_connection(user->client_data);
- char *err = g_strdup_printf(_("Unable to move user %s"
- " to folder %s in the server side list."
- " Error while creating folder (%s)."),
-@@ -588,7 +588,7 @@ _create_folder_resp_move_contact(NMUser
- folder_name,
- nm_error_to_string (ret_code));
-
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
-
-@@ -626,14 +626,14 @@ _create_folder_resp_add_contact(NMUser *
- _check_for_disconnect(user, rc);
- }
- } else {
-- GaimConnection *gc = gaim_account_get_connection(user->client_data);
-+ Gaim2Connection *gc = gaim2_account_get_connection(user->client_data);
- const char *name = nm_contact_get_dn(contact);
- char *err =
- g_strdup_printf(_("Unable to add %s to your buddy list."
- " Error creating folder in server side list (%s)."),
- name, nm_error_to_string (ret_code));
-
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
-
- nm_release_contact(contact);
- g_free(err);
-@@ -646,8 +646,8 @@ static void
- _join_conf_resp_cb(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConversation *chat;
-- GaimConnection *gc;
-+ Gaim2Conversation *chat;
-+ Gaim2Connection *gc;
- NMUserRecord *ur;
- NMConference *conference = user_data;
- const char *name, *conf_name;
-@@ -656,7 +656,7 @@ _join_conf_resp_cb(NMUser * user, NMERR_
- if (user == NULL || conference == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
-
- if (ret_code == NM_OK) {
- conf_name = _get_conference_name(++user->conference_count);
-@@ -670,7 +670,7 @@ _join_conf_resp_cb(NMUser * user, NMERR_
- ur = nm_conference_get_participant(conference, i);
- if (ur) {
- name = nm_user_record_get_display_id(ur);
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(chat), name, NULL,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(chat), name, NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- }
- }
-@@ -683,7 +683,7 @@ static void
- _get_details_resp_show_info(NMUser * user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record;
- char *name;
- char *err;
-@@ -696,15 +696,15 @@ _get_details_resp_show_info(NMUser * use
- if (ret_code == NM_OK) {
- user_record = (NMUserRecord *) resp_data;
- if (user_record) {
-- _show_info(gaim_account_get_connection(user->client_data),
-+ _show_info(gaim2_account_get_connection(user->client_data),
- user_record);
- }
- } else {
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- err =
- g_strdup_printf(_("Could not get details for user %s (%s)."),
- name, nm_error_to_string (ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
-
-@@ -717,7 +717,7 @@ static void
- _get_details_resp_add_privacy_item(NMUser *user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record = resp_data;
- char *err;
- gboolean allowed = GPOINTER_TO_INT(user_data);
-@@ -726,7 +726,7 @@ _get_details_resp_add_privacy_item(NMUse
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- display_id = nm_user_record_get_display_id(user_record);
-
- if (ret_code == NM_OK) {
-@@ -735,14 +735,14 @@ _get_details_resp_add_privacy_item(NMUse
-
- if (!g_slist_find_custom(gc->account->permit,
- display_id, (GCompareFunc)nm_utf8_strcasecmp)) {
-- gaim_privacy_permit_add(gc->account, display_id, TRUE);
-+ gaim2_privacy_permit_add(gc->account, display_id, TRUE);
- }
-
- } else {
-
- if (!g_slist_find_custom(gc->account->permit,
- display_id, (GCompareFunc)nm_utf8_strcasecmp)) {
-- gaim_privacy_deny_add(gc->account, display_id, TRUE);
-+ gaim2_privacy_deny_add(gc->account, display_id, TRUE);
- }
- }
-
-@@ -750,7 +750,7 @@ _get_details_resp_add_privacy_item(NMUse
-
- err = g_strdup_printf(_("Unable to add user to privacy list (%s)."),
- nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -761,7 +761,7 @@ static void
- _create_privacy_item_deny_resp_cb(NMUser *user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record;
- char *who = user_data;
- char *err;
-@@ -771,7 +771,7 @@ _create_privacy_item_deny_resp_cb(NMUser
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
-
- if (ret_code == NM_OK) {
-
-@@ -784,7 +784,7 @@ _create_privacy_item_deny_resp_cb(NMUser
- if (!g_slist_find_custom(gc->account->deny,
- display_id, (GCompareFunc)nm_utf8_strcasecmp)) {
-
-- gaim_privacy_deny_add(gc->account, display_id, TRUE);
-+ gaim2_privacy_deny_add(gc->account, display_id, TRUE);
- }
-
- } else {
-@@ -797,7 +797,7 @@ _create_privacy_item_deny_resp_cb(NMUser
-
- err = g_strdup_printf(_("Unable to add %s to deny list (%s)."),
- who, nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -812,7 +812,7 @@ static void
- _create_privacy_item_permit_resp_cb(NMUser *user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record;
- char *who = user_data;
- char *err;
-@@ -822,7 +822,7 @@ _create_privacy_item_permit_resp_cb(NMUs
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
-
- if (ret_code == NM_OK) {
-
-@@ -836,7 +836,7 @@ _create_privacy_item_permit_resp_cb(NMUs
- display_id,
- (GCompareFunc)nm_utf8_strcasecmp)) {
-
-- gaim_privacy_permit_add(gc->account, display_id, TRUE);
-+ gaim2_privacy_permit_add(gc->account, display_id, TRUE);
- }
-
- } else {
-@@ -850,7 +850,7 @@ _create_privacy_item_permit_resp_cb(NMUs
-
- err = g_strdup_printf(_("Unable to add %s to permit list (%s)."), who,
- nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -864,7 +864,7 @@ _get_details_send_privacy_create(NMUser
- gpointer resp_data, gpointer user_data)
- {
- NMERR_T rc = NM_OK;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record = resp_data;
- char *err;
- gboolean allowed = GPOINTER_TO_INT(user_data);
-@@ -873,7 +873,7 @@ _get_details_send_privacy_create(NMUser
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- dn = nm_user_record_get_dn(user_record);
- display_id = nm_user_record_get_display_id(user_record);
-
-@@ -896,7 +896,7 @@ _get_details_send_privacy_create(NMUser
-
- err = g_strdup_printf(_("Unable to add user to privacy list (%s)."),
- nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -906,7 +906,7 @@ static void
- _remove_privacy_item_resp_cb(NMUser *user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *who = user_data;
- char *err;
-
-@@ -915,10 +915,10 @@ _remove_privacy_item_resp_cb(NMUser *use
-
- if (ret_code != NM_OK) {
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- err = g_strdup_printf(_("Unable to remove %s from privacy list (%s)."), who,
- nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
-
-@@ -930,7 +930,7 @@ static void
- _set_privacy_default_resp_cb(NMUser *user, NMERR_T ret_code,
- gpointer resp_data, gpointer user_data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *err;
-
- if (user == NULL)
-@@ -938,10 +938,10 @@ _set_privacy_default_resp_cb(NMUser *use
-
- if (ret_code != NM_OK) {
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- err = g_strdup_printf(_("Unable to change server side privacy settings (%s)."),
- nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -953,7 +953,7 @@ _get_details_resp_send_invite(NMUser *us
- gpointer resp_data, gpointer user_data)
- {
- NMERR_T rc = NM_OK;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record = resp_data;
- char *err;
- const char *display_id;
-@@ -965,7 +965,7 @@ _get_details_resp_send_invite(NMUser *us
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- display_id = nm_user_record_get_display_id(user_record);
-
- if (ret_code == NM_OK) {
-@@ -973,7 +973,7 @@ _get_details_resp_send_invite(NMUser *us
- for (cnode = user->conferences; cnode != NULL; cnode = cnode->next) {
- conference = cnode->data;
- if (conference && (chat = nm_conference_get_data(conference))) {
-- if (gaim_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
-+ if (gaim2_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
- rc = nm_send_conference_invite(user, conference, user_record,
- NULL, _sendinvite_resp_cb, NULL);
- _check_for_disconnect(user, rc);
-@@ -985,7 +985,7 @@ _get_details_resp_send_invite(NMUser *us
- } else {
-
- err = g_strdup_printf(_("Unable to invite user (%s)."), nm_error_to_string(ret_code));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
-
- }
-@@ -998,7 +998,7 @@ _createconf_resp_send_invite(NMUser * us
- NMERR_T rc = NM_OK;
- NMConference *conference = resp_data;
- NMUserRecord *user_record = user_data;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *err;
-
- if (user == NULL)
-@@ -1012,8 +1012,8 @@ _createconf_resp_send_invite(NMUser * us
- _check_for_disconnect(user, rc);
- } else {
- err = g_strdup_printf(_("Unable to create conference (%s)."), nm_error_to_string(ret_code));
-- gc = gaim_account_get_connection(user->client_data);
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gc = gaim2_account_get_connection(user->client_data);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
- }
-@@ -1040,7 +1040,7 @@ _user_agent_string()
- release = "Unknown";
- }
-
-- return g_strdup_printf("Gaim/%s (%s; %s)", VERSION, sysname, release);
-+ return g_strdup_printf("Gaim2/%s (%s; %s)", VERSION, sysname, release);
-
- #else
-
-@@ -1098,7 +1098,7 @@ _user_agent_string()
- sysname = "Windows";
- }
-
-- return g_strdup_printf("Gaim/%s (%s; %ld.%ld)", VERSION, sysname,
-+ return g_strdup_printf("Gaim2/%s (%s; %ld.%ld)", VERSION, sysname,
- os_info.dwMajorVersion, os_info.dwMinorVersion);
-
- #endif
-@@ -1116,11 +1116,11 @@ _is_disconnect_error(NMERR_T err)
- static gboolean
- _check_for_disconnect(NMUser * user, NMERR_T err)
- {
-- GaimConnection *gc = gaim_account_get_connection(user->client_data);
-+ Gaim2Connection *gc = gaim2_account_get_connection(user->client_data);
-
- if (_is_disconnect_error(err)) {
-
-- gaim_connection_error(gc, _("Error communicating with server."
-+ gaim2_connection_error(gc, _("Error communicating with server."
- " Closing connection."));
- return TRUE;
-
-@@ -1159,12 +1159,12 @@ _send_message(NMUser * user, NMMessage *
- }
-
- /*
-- * Update the status of the given buddy in the Gaim buddy list
-+ * Update the status of the given buddy in the Gaim2 buddy list
- */
- static void
--_update_buddy_status(NMUser *user, GaimBuddy * buddy, int novellstatus, int gmt)
-+_update_buddy_status(NMUser *user, Gaim2Buddy * buddy, int novellstatus, int gmt)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- const char *status_id;
- const char *text = NULL;
- const char *dn;
-@@ -1206,41 +1206,41 @@ _update_buddy_status(NMUser *user, GaimB
- }
- }
-
-- gaim_prpl_got_user_status(account, buddy->name, status_id,
-+ gaim2_prpl_got_user_status(account, buddy->name, status_id,
- "message", text, NULL);
-- gaim_prpl_got_user_idle(account, buddy->name,
-+ gaim2_prpl_got_user_idle(account, buddy->name,
- (novellstatus == NM_STATUS_AWAY_IDLE), idle);
- }
-
--/* Iterate through the cached Gaim buddy list and remove buddies
-+/* Iterate through the cached Gaim2 buddy list and remove buddies
- * that are not in the server side list.
- */
- static void
--_remove_gaim_buddies(NMUser *user)
-+_remove_gaim2_buddies(NMUser *user)
- {
-- GaimBlistNode *gnode;
-- GaimBlistNode *cnode;
-- GaimBlistNode *bnode;
-- GaimGroup *group;
-- GaimBuddy *buddy;
-- GaimBuddyList *blist;
-+ Gaim2BlistNode *gnode;
-+ Gaim2BlistNode *cnode;
-+ Gaim2BlistNode *bnode;
-+ Gaim2Group *group;
-+ Gaim2Buddy *buddy;
-+ Gaim2BuddyList *blist;
- GSList *rem_list = NULL;
- GSList *l;
- NMFolder *folder = NULL;
- const char *gname = NULL;
-
-- if ((blist = gaim_get_blist())) {
-+ if ((blist = gaim2_get_blist())) {
- for (gnode = blist->root; gnode; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-- group = (GaimGroup *) gnode;
-+ group = (Gaim2Group *) gnode;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if (!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- buddy = (GaimBuddy *) bnode;
-+ buddy = (Gaim2Buddy *) bnode;
- if (buddy->account == user->client_data) {
- gname = group->name;
- if (strcmp(group->name, NM_ROOT_FOLDER_NAME) == 0)
-@@ -1257,28 +1257,28 @@ _remove_gaim_buddies(NMUser *user)
-
- if (rem_list) {
- for (l = rem_list; l; l = l->next) {
-- gaim_blist_remove_buddy(l->data);
-+ gaim2_blist_remove_buddy(l->data);
- }
- g_slist_free(rem_list);
- }
- }
- }
-
--/* Add all of the contacts in the given folder to the Gaim buddy list */
-+/* Add all of the contacts in the given folder to the Gaim2 buddy list */
- static void
--_add_contacts_to_gaim_blist(NMUser * user, NMFolder * folder)
-+_add_contacts_to_gaim2_blist(NMUser * user, NMFolder * folder)
- {
- NMUserRecord *user_record = NULL;
- NMContact *contact = NULL;
-- GaimBuddy *buddy = NULL;
-- GaimGroup *group;
-+ Gaim2Buddy *buddy = NULL;
-+ Gaim2Group *group;
- NMERR_T cnt = 0, i;
- const char *text = NULL;
- const char *name = NULL;
- const char *fname = NULL;
- int status = 0;
-
-- /* If this is the root folder give it a name. Gaim does not have the concept of
-+ /* If this is the root folder give it a name. Gaim2 does not have the concept of
- * a root folder.
- */
- fname = nm_folder_get_name(folder);
-@@ -1286,11 +1286,11 @@ _add_contacts_to_gaim_blist(NMUser * use
- fname = NM_ROOT_FOLDER_NAME;
- }
-
-- /* Does the Gaim group exist already? */
-- group = gaim_find_group(fname);
-+ /* Does the Gaim2 group exist already? */
-+ group = gaim2_find_group(fname);
- if (group == NULL) {
-- group = gaim_group_new(fname);
-- gaim_blist_add_group(group, NULL);
-+ group = gaim2_group_new(fname);
-+ gaim2_blist_add_group(group, NULL);
- }
-
- /* Get each contact for this folder */
-@@ -1302,14 +1302,14 @@ _add_contacts_to_gaim_blist(NMUser * use
- name = nm_contact_get_display_id(contact);
- if (name) {
-
-- buddy = gaim_find_buddy_in_group(user->client_data, name, group);
-+ buddy = gaim2_find_buddy_in_group(user->client_data, name, group);
- if (buddy == NULL) {
-- /* Add it to the gaim buddy list */
-- buddy = gaim_buddy_new(user->client_data,
-+ /* Add it to the gaim2 buddy list */
-+ buddy = gaim2_buddy_new(user->client_data,
- name,
- nm_contact_get_display_name(contact));
-
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
- }
-
- /* Set the initial status for the buddy */
-@@ -1333,9 +1333,9 @@ _add_contacts_to_gaim_blist(NMUser * use
- }
- }
-
--/* Add all of the server side contacts to the Gaim buddy list. */
-+/* Add all of the server side contacts to the Gaim2 buddy list. */
- static void
--_add_gaim_buddies(NMUser * user)
-+_add_gaim2_buddies(NMUser * user)
- {
- int cnt = 0, i;
- NMFolder *root_folder = NULL;
-@@ -1346,19 +1346,19 @@ _add_gaim_buddies(NMUser * user)
-
- /* Add sub-folders and contacts to sub-folders...
- * iterate throught the sub-folders in reverse order
-- * because Gaim adds the folders to the front -- so we
-+ * because Gaim2 adds the folders to the front -- so we
- * want to add the first folder last
- */
- cnt = nm_folder_get_subfolder_count(root_folder);
- for (i = cnt-1; i >= 0; i--) {
- folder = nm_folder_get_subfolder(root_folder, i);
- if (folder) {
-- _add_contacts_to_gaim_blist(user, folder);
-+ _add_contacts_to_gaim2_blist(user, folder);
- }
- }
-
- /* Add contacts for the root folder */
-- _add_contacts_to_gaim_blist(user, root_folder);
-+ _add_contacts_to_gaim2_blist(user, root_folder);
- }
- }
-
-@@ -1370,8 +1370,8 @@ _sync_contact_list(NMUser *user)
- * from the server side list that are not in
- * the local list
- */
-- _remove_gaim_buddies(user);
-- _add_gaim_buddies(user);
-+ _remove_gaim2_buddies(user);
-+ _add_gaim2_buddies(user);
- user->clist_synched = TRUE;
- }
-
-@@ -1379,18 +1379,18 @@ static void
- _sync_privacy_lists(NMUser *user)
- {
- GSList *node = NULL, *rem_list = NULL;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- const char *name, *dn;
- NMUserRecord *user_record;
-
- if (user == NULL)
- return;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- if (gc == NULL)
- return;
-
-- /* Set the Gaim privacy setting */
-+ /* Set the Gaim2 privacy setting */
- if (user->default_deny) {
- if (user->allow_list == NULL) {
- gc->account->perm_deny = GAIM_PRIVACY_DENY_ALL;
-@@ -1415,7 +1415,7 @@ _sync_privacy_lists(NMUser *user)
-
- if (!g_slist_find_custom(gc->account->permit,
- name, (GCompareFunc)nm_utf8_strcasecmp)) {
-- gaim_privacy_permit_add(gc->account, name , TRUE);
-+ gaim2_privacy_permit_add(gc->account, name , TRUE);
- }
- }
-
-@@ -1428,7 +1428,7 @@ _sync_privacy_lists(NMUser *user)
-
- if (!g_slist_find_custom(gc->account->deny,
- name, (GCompareFunc)nm_utf8_strcasecmp)) {
-- gaim_privacy_deny_add(gc->account, name, TRUE);
-+ gaim2_privacy_deny_add(gc->account, name, TRUE);
- }
- }
-
-@@ -1445,7 +1445,7 @@ _sync_privacy_lists(NMUser *user)
-
- if (rem_list) {
- for (node = rem_list; node; node = node->next) {
-- gaim_privacy_permit_remove(gc->account, (char *)node->data, TRUE);
-+ gaim2_privacy_permit_remove(gc->account, (char *)node->data, TRUE);
- }
- g_free(rem_list);
- rem_list = NULL;
-@@ -1462,7 +1462,7 @@ _sync_privacy_lists(NMUser *user)
-
- if (rem_list) {
- for (node = rem_list; node; node = node->next) {
-- gaim_privacy_deny_remove(gc->account, (char *)node->data, TRUE);
-+ gaim2_privacy_deny_remove(gc->account, (char *)node->data, TRUE);
- }
- g_slist_free(rem_list);
- }
-@@ -1494,7 +1494,7 @@ _map_property_tag(const char *tag)
-
- /* Display a dialog box showing the properties for the given user record */
- static void
--_show_info(GaimConnection * gc, NMUserRecord * user_record)
-+_show_info(Gaim2Connection * gc, NMUserRecord * user_record)
- {
- GString *info_text;
- int count, i;
-@@ -1537,7 +1537,7 @@ _show_info(GaimConnection * gc, NMUserRe
- }
- }
-
-- gaim_notify_userinfo(gc, nm_user_record_get_userid(user_record),
-+ gaim2_notify_userinfo(gc, nm_user_record_get_userid(user_record),
- info_text->str, NULL, NULL);
-
- g_string_free(info_text, TRUE);
-@@ -1545,7 +1545,7 @@ _show_info(GaimConnection * gc, NMUserRe
-
- /* Send a join conference, the first item in the parms list is the
- * NMUser object and the second item is the conference to join.
-- * This callback is passed to gaim_request_action when we ask the
-+ * This callback is passed to gaim2_request_action when we ask the
- * user if they want to join the conference.
- */
- static void
-@@ -1572,7 +1572,7 @@ _join_conference_cb(GSList * parms)
-
- /* Send a reject conference, the first item in the parms list is the
- * NMUser object and the second item is the conference to reject.
-- * This callback is passed to gaim_request_action when we ask the
-+ * This callback is passed to gaim2_request_action when we ask the
- * user if they want to joing the conference.
- */
- static void
-@@ -1597,21 +1597,21 @@ _reject_conference_cb(GSList * parms)
- }
-
- static void
--_initiate_conference_cb(GaimBlistNode *node, gpointer ignored)
-+_initiate_conference_cb(Gaim2BlistNode *node, gpointer ignored)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- NMUser *user;
- const char *conf_name;
-- GaimConversation *chat = NULL;
-+ Gaim2Conversation *chat = NULL;
- NMUserRecord *user_record;
- NMConference *conference;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- user = gc->proto_data;
- if (user == NULL)
-@@ -1647,13 +1647,13 @@ _get_conference_name(int id)
- }
-
- static void
--_show_privacy_locked_error(GaimConnection *gc, NMUser *user)
-+_show_privacy_locked_error(Gaim2Connection *gc, NMUser *user)
- {
- char *err;
-
- err = g_strdup_printf(_("Unable to change server side privacy settings (%s)."),
- nm_error_to_string(NMERR_ADMIN_LOCKED));
-- gaim_notify_error(gc, NULL, err, NULL);
-+ gaim2_notify_error(gc, NULL, err, NULL);
- g_free(err);
- }
-
-@@ -1662,18 +1662,18 @@ _show_privacy_locked_error(GaimConnectio
- ******************************************************************************/
-
- static void
--novell_ssl_connect_error(GaimSslConnection * gsc,
-- GaimSslErrorType error, gpointer data)
-+novell_ssl_connect_error(Gaim2SslConnection * gsc,
-+ Gaim2SslErrorType error, gpointer data)
- {
-- gaim_connection_error((GaimConnection *)data,
-+ gaim2_connection_error((Gaim2Connection *)data,
- _("Unable to make SSL connection to server."));
- }
-
- static void
--novell_ssl_recv_cb(gpointer data, GaimSslConnection * gsc,
-- GaimInputCondition condition)
-+novell_ssl_recv_cb(gpointer data, Gaim2SslConnection * gsc,
-+ Gaim2InputCondition condition)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- NMUser *user;
- NMERR_T rc;
-
-@@ -1689,21 +1689,21 @@ novell_ssl_recv_cb(gpointer data, GaimSs
-
- if (_is_disconnect_error(rc)) {
-
-- gaim_connection_error(gc,
-+ gaim2_connection_error(gc,
- _("Error communicating with server."
- " Closing connection."));
- } else {
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "Error processing event or response (%d).\n", rc);
- }
- }
- }
-
- static void
--novell_ssl_connected_cb(gpointer data, GaimSslConnection * gsc,
-- GaimInputCondition cond)
-+novell_ssl_connected_cb(gpointer data, Gaim2SslConnection * gsc,
-+ Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- NMUser *user;
- NMConn *conn;
- NMERR_T rc = 0;
-@@ -1720,25 +1720,25 @@ novell_ssl_connected_cb(gpointer data, G
-
- conn->ssl_conn = g_new0(NMSSLConn, 1);
- conn->ssl_conn->data = gsc;
-- conn->ssl_conn->read = (nm_ssl_read_cb) gaim_ssl_read;
-- conn->ssl_conn->write = (nm_ssl_write_cb) gaim_ssl_write;
-+ conn->ssl_conn->read = (nm_ssl_read_cb) gaim2_ssl_read;
-+ conn->ssl_conn->write = (nm_ssl_write_cb) gaim2_ssl_write;
-
-- gaim_connection_update_progress(gc, _("Authenticating..."),
-+ gaim2_connection_update_progress(gc, _("Authenticating..."),
- 2, NOVELL_CONNECT_STEPS);
-
-- my_addr = gaim_network_get_my_ip(gsc->fd);
-- pwd = gaim_connection_get_password(gc);
-+ my_addr = gaim2_network_get_my_ip(gsc->fd);
-+ pwd = gaim2_connection_get_password(gc);
- ua = _user_agent_string();
-
- rc = nm_send_login(user, pwd, my_addr, ua, _login_resp_cb, NULL);
- if (rc == NM_OK) {
- conn->connected = TRUE;
-- gaim_ssl_input_add(gsc, novell_ssl_recv_cb, gc);
-+ gaim2_ssl_input_add(gsc, novell_ssl_recv_cb, gc);
- } else {
-- gaim_connection_error(gc, _("Unable to connect to server."));
-+ gaim2_connection_error(gc, _("Unable to connect to server."));
- }
-
-- gaim_connection_update_progress(gc, _("Waiting for response..."),
-+ gaim2_connection_update_progress(gc, _("Waiting for response..."),
- 3, NOVELL_CONNECT_STEPS);
-
- g_free(ua);
-@@ -1753,9 +1753,9 @@ _evt_receive_message(NMUser * user, NMEv
- {
- NMUserRecord *user_record = NULL;
- NMContact *contact = NULL;
-- GaimConversation *gconv;
-+ Gaim2Conversation *gconv;
- NMConference *conference;
-- GaimMessageFlags flags;
-+ Gaim2MessageFlags flags;
- char *text = NULL;
-
- text = g_markup_escape_text(nm_event_get_text(event), -1);
-@@ -1763,7 +1763,7 @@ _evt_receive_message(NMUser * user, NMEv
- conference = nm_event_get_conference(event);
- if (conference) {
-
-- GaimConversation *chat = nm_conference_get_data(conference);
-+ Gaim2Conversation *chat = nm_conference_get_data(conference);
-
- /* Is this a single person 'conversation' or a conference? */
- if (chat == NULL && nm_conference_get_participant_count(conference) == 1) {
-@@ -1775,20 +1775,20 @@ _evt_receive_message(NMUser * user, NMEv
- if (nm_event_get_type(event) == NMEVT_RECEIVE_AUTOREPLY)
- flags |= GAIM_MESSAGE_AUTO_RESP;
-
-- serv_got_im(gaim_account_get_connection(user->client_data),
-+ serv_got_im(gaim2_account_get_connection(user->client_data),
- nm_user_record_get_display_id(user_record),
- text, flags,
- nm_event_get_gmt(event));
-
-- gconv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ gconv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- nm_user_record_get_display_id(user_record),
-- (GaimAccount *) user->client_data);
-+ (Gaim2Account *) user->client_data);
- if (gconv) {
-
- contact = nm_find_contact(user, nm_event_get_source(event));
- if (contact) {
-
-- gaim_conversation_set_title(
-+ gaim2_conversation_set_title(
- gconv, nm_contact_get_display_name(contact));
-
-
-@@ -1800,7 +1800,7 @@ _evt_receive_message(NMUser * user, NMEv
- if (name == NULL)
- name = nm_user_record_get_userid(user_record);
-
-- gaim_conversation_set_title(gconv, name);
-+ gaim2_conversation_set_title(gconv, name);
- }
-
- }
-@@ -1830,8 +1830,8 @@ _evt_receive_message(NMUser * user, NMEv
- name = nm_user_record_get_display_id(user_record);
- }
-
-- serv_got_chat_in(gaim_account_get_connection(user->client_data),
-- gaim_conv_chat_get_id(GAIM_CONV_CHAT(chat)),
-+ serv_got_chat_in(gaim2_account_get_connection(user->client_data),
-+ gaim2_conv_chat_get_id(GAIM_CONV_CHAT(chat)),
- name, 0, text, nm_event_get_gmt(event));
- }
- }
-@@ -1843,7 +1843,7 @@ _evt_receive_message(NMUser * user, NMEv
- static void
- _evt_conference_left(NMUser * user, NMEvent * event)
- {
-- GaimConversation *chat;
-+ Gaim2Conversation *chat;
- NMConference *conference;
-
- conference = nm_event_get_conference(event);
-@@ -1854,7 +1854,7 @@ _evt_conference_left(NMUser * user, NMEv
- nm_event_get_source(event));
-
- if (ur)
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(chat),
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(chat),
- nm_user_record_get_display_id(ur),
- NULL);
- }
-@@ -1864,7 +1864,7 @@ _evt_conference_left(NMUser * user, NMEv
- static void
- _evt_conference_invite_notify(NMUser * user, NMEvent * event)
- {
-- GaimConversation *gconv;
-+ Gaim2Conversation *gconv;
- NMConference *conference;
- NMUserRecord *user_record = NULL;
- char *str = NULL;
-@@ -1875,7 +1875,7 @@ _evt_conference_invite_notify(NMUser * u
- gconv = nm_conference_get_data(conference);
- str = g_strdup_printf(_("%s has been invited to this conversation."),
- nm_user_record_get_display_id(user_record));
-- gaim_conversation_write(gconv, NULL, str,
-+ gaim2_conversation_write(gconv, NULL, str,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(str);
- }
-@@ -1885,7 +1885,7 @@ static void
- _evt_conference_invite(NMUser * user, NMEvent * event)
- {
- NMUserRecord *ur;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GSList *parms = NULL;
- const char *title = NULL;
- const char *secondary = NULL;
-@@ -1915,8 +1915,8 @@ _evt_conference_invite(NMUser * user, NM
- parms = g_slist_append(parms, nm_event_get_conference(event));
-
- /* Prompt the user */
-- gc = gaim_account_get_connection(user->client_data);
-- gaim_request_action(gc, title, primary, secondary,
-+ gc = gaim2_account_get_connection(user->client_data);
-+ gaim2_request_action(gc, title, primary, secondary,
- GAIM_DEFAULT_ACTION_NONE, parms, 2,
- _("Yes"), G_CALLBACK(_join_conference_cb),
- _("No"), G_CALLBACK(_reject_conference_cb));
-@@ -1928,14 +1928,14 @@ _evt_conference_invite(NMUser * user, NM
- static void
- _evt_conference_joined(NMUser * user, NMEvent * event)
- {
-- GaimConversation *chat = NULL;
-- GaimConnection *gc;
-+ Gaim2Conversation *chat = NULL;
-+ Gaim2Connection *gc;
- NMConference *conference = NULL;
- NMUserRecord *ur = NULL;
- const char *name;
- const char *conf_name;
-
-- gc = gaim_account_get_connection(user->client_data);
-+ gc = gaim2_account_get_connection(user->client_data);
- if (gc == NULL)
- return;
-
-@@ -1953,7 +1953,7 @@ _evt_conference_joined(NMUser * user, NM
- nm_conference_set_data(conference, (gpointer) chat);
-
- name = nm_user_record_get_display_id(ur);
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(chat), name, NULL,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(chat), name, NULL,
- GAIM_CBFLAGS_NONE, TRUE);
-
- }
-@@ -1964,8 +1964,8 @@ _evt_conference_joined(NMUser * user, NM
- ur = nm_find_user_record(user, nm_event_get_source(event));
- if (ur) {
- name = nm_user_record_get_display_id(ur);
-- if (!gaim_conv_chat_find_user(GAIM_CONV_CHAT(chat), name)) {
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(chat), name, NULL,
-+ if (!gaim2_conv_chat_find_user(GAIM_CONV_CHAT(chat), name)) {
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(chat), name, NULL,
- GAIM_CBFLAGS_NONE, TRUE);
- }
- }
-@@ -1976,7 +1976,7 @@ _evt_conference_joined(NMUser * user, NM
- static void
- _evt_status_change(NMUser * user, NMEvent * event)
- {
-- GaimBuddy *buddy = NULL;
-+ Gaim2Buddy *buddy = NULL;
- GSList *buddies;
- GSList *bnode;
- NMUserRecord *user_record;
-@@ -1991,9 +1991,9 @@ _evt_status_change(NMUser * user, NMEven
-
- /* Update status for buddy in all folders */
- display_id = nm_user_record_get_display_id(user_record);
-- buddies = gaim_find_buddies(user->client_data, display_id);
-+ buddies = gaim2_find_buddies(user->client_data, display_id);
- for (bnode = buddies; bnode; bnode = bnode->next) {
-- buddy = (GaimBuddy *) bnode->data;
-+ buddy = (Gaim2Buddy *) bnode->data;
- if (buddy) {
- _update_buddy_status(user, buddy, status, nm_event_get_gmt(event));
- }
-@@ -2007,21 +2007,21 @@ _evt_status_change(NMUser * user, NMEven
- static void
- _evt_user_disconnect(NMUser * user, NMEvent * event)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = gaim_account_get_connection((GaimAccount *) user->client_data);
-+ gc = gaim2_account_get_connection((Gaim2Account *) user->client_data);
- if (gc)
-- gaim_connection_error(gc, _("You have been logged out because you"
-+ gaim2_connection_error(gc, _("You have been logged out because you"
- " logged in at another workstation."));
- }
-
- static void
- _evt_user_typing(NMUser * user, NMEvent * event)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record = NULL;
-
-- gc = gaim_account_get_connection((GaimAccount *) user->client_data);
-+ gc = gaim2_account_get_connection((Gaim2Account *) user->client_data);
- if (gc) {
- user_record = nm_find_user_record(user, nm_event_get_source(event));
- if (user_record) {
-@@ -2034,10 +2034,10 @@ _evt_user_typing(NMUser * user, NMEvent
- static void
- _evt_user_not_typing(NMUser * user, NMEvent * event)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUserRecord *user_record;
-
-- gc = gaim_account_get_connection((GaimAccount *) user->client_data);
-+ gc = gaim2_account_get_connection((Gaim2Account *) user->client_data);
- if (gc) {
- user_record = nm_find_user_record(user, nm_event_get_source(event));
- if (user_record) {
-@@ -2051,14 +2051,14 @@ static void
- _evt_undeliverable_status(NMUser * user, NMEvent * event)
- {
- NMUserRecord *ur;
-- GaimConversation *gconv;
-+ Gaim2Conversation *gconv;
- char *str;
-
- ur = nm_find_user_record(user, nm_event_get_source(event));
- if (ur) {
- /* XXX - Should this be GAIM_CONV_TYPE_IM? */
- gconv =
-- gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
-+ gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
- nm_user_record_get_display_id(ur),
- user->client_data);
- if (gconv) {
-@@ -2069,7 +2069,7 @@ _evt_undeliverable_status(NMUser * user,
- }
- str = g_strdup_printf(_("%s appears to be offline and did not receive"
- " the message that you just sent."), name);
-- gaim_conversation_write(gconv, NULL, str,
-+ gaim2_conversation_write(gconv, NULL, str,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(str);
- }
-@@ -2130,7 +2130,7 @@ _event_callback(NMUser * user, NMEvent *
- _evt_conference_left(user, event);
- break;
- default:
-- gaim_debug(GAIM_DEBUG_INFO, "novell",
-+ gaim2_debug(GAIM_DEBUG_INFO, "novell",
- "_event_callback(): unhandled event, %d\n",
- nm_event_get_type(event));
- break;
-@@ -2142,9 +2142,9 @@ _event_callback(NMUser * user, NMEvent *
- ******************************************************************************/
-
- static void
--novell_login(GaimAccount * account)
-+novell_login(Gaim2Account * account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUser *user = NULL;
- const char *server;
- const char *name;
-@@ -2153,26 +2153,26 @@ novell_login(GaimAccount * account)
- if (account == NULL)
- return;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- if (gc == NULL)
- return;
-
-- server = gaim_account_get_string(account, "server", NULL);
-+ server = gaim2_account_get_string(account, "server", NULL);
- if (server == NULL || *server == '\0') {
-
- /* TODO: Would be nice to prompt if not set!
-- * gaim_request_fields(gc, _("Server Address"),...);
-+ * gaim2_request_fields(gc, _("Server Address"),...);
- */
-
- /* ...but for now just error out with a nice message. */
-- gaim_connection_error(gc, _("Unable to connect to server."
-+ gaim2_connection_error(gc, _("Unable to connect to server."
- " Please enter the address of the server"
- " you wish to connect to."));
- return;
- }
-
-- port = gaim_account_get_int(account, "port", DEFAULT_PORT);
-- name = gaim_account_get_username(account);
-+ port = gaim2_account_get_int(account, "port", DEFAULT_PORT);
-+ name = gaim2_account_get_username(account);
-
- user = nm_initialize_user(name, server, port, account, _event_callback);
- if (user) {
-@@ -2180,21 +2180,21 @@ novell_login(GaimAccount * account)
- gc->proto_data = user;
-
- /* connect to the server */
-- gaim_connection_update_progress(gc, _("Connecting"),
-+ gaim2_connection_update_progress(gc, _("Connecting"),
- 1, NOVELL_CONNECT_STEPS);
-
- user->conn->use_ssl = TRUE;
-- if (gaim_ssl_connect(user->client_data, user->conn->addr,
-+ if (gaim2_ssl_connect(user->client_data, user->conn->addr,
- user->conn->port, novell_ssl_connected_cb,
- novell_ssl_connect_error, gc) == NULL) {
-- gaim_connection_error(gc, _("Error."
-+ gaim2_connection_error(gc, _("Error."
- " SSL support is not installed."));
- }
- }
- }
-
- static void
--novell_close(GaimConnection * gc)
-+novell_close(Gaim2Connection * gc)
- {
- NMUser *user;
- NMConn *conn;
-@@ -2206,7 +2206,7 @@ novell_close(GaimConnection * gc)
- if (user) {
- conn = user->conn;
- if (conn && conn->ssl_conn) {
-- gaim_ssl_close(user->conn->ssl_conn->data);
-+ gaim2_ssl_close(user->conn->ssl_conn->data);
- }
- nm_deinitialize_user(user);
- }
-@@ -2214,8 +2214,8 @@ novell_close(GaimConnection * gc)
- }
-
- static int
--novell_send_im(GaimConnection * gc, const char *name,
-- const char *message_body, GaimMessageFlags flags)
-+novell_send_im(Gaim2Connection * gc, const char *name,
-+ const char *message_body, Gaim2MessageFlags flags)
- {
- NMUserRecord *user_record = NULL;
- NMConference *conf = NULL;
-@@ -2235,7 +2235,7 @@ novell_send_im(GaimConnection * gc, cons
- return 0;
-
- /* Create a new message */
-- plain = gaim_unescape_html(message_body);
-+ plain = gaim2_unescape_html(message_body);
- message = nm_create_message(plain);
- g_free(plain);
-
-@@ -2306,7 +2306,7 @@ novell_send_im(GaimConnection * gc, cons
- }
-
- static int
--novell_send_typing(GaimConnection * gc, const char *name, int typing)
-+novell_send_typing(Gaim2Connection * gc, const char *name, int typing)
- {
- NMConference *conf = NULL;
- NMUser *user;
-@@ -2340,7 +2340,7 @@ novell_send_typing(GaimConnection * gc,
- }
-
- static void
--novell_convo_closed(GaimConnection * gc, const char *who)
-+novell_convo_closed(Gaim2Connection * gc, const char *who)
- {
- NMUser *user;
- NMConference *conf;
-@@ -2361,11 +2361,11 @@ novell_convo_closed(GaimConnection * gc,
- }
-
- static void
--novell_chat_leave(GaimConnection * gc, int id)
-+novell_chat_leave(Gaim2Connection * gc, int id)
- {
- NMConference *conference;
- NMUser *user;
-- GaimConversation *chat;
-+ Gaim2Conversation *chat;
- GSList *cnode;
- NMERR_T rc = NM_OK;
-
-@@ -2379,7 +2379,7 @@ novell_chat_leave(GaimConnection * gc, i
- for (cnode = user->conferences; cnode != NULL; cnode = cnode->next) {
- conference = cnode->data;
- if (conference && (chat = nm_conference_get_data(conference))) {
-- if (gaim_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
-+ if (gaim2_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
- rc = nm_send_leave_conference(user, conference, NULL, NULL);
- _check_for_disconnect(user, rc);
- break;
-@@ -2391,12 +2391,12 @@ novell_chat_leave(GaimConnection * gc, i
- }
-
- static void
--novell_chat_invite(GaimConnection *gc, int id,
-+novell_chat_invite(Gaim2Connection *gc, int id,
- const char *message, const char *who)
- {
- NMConference *conference;
- NMUser *user;
-- GaimConversation *chat;
-+ Gaim2Conversation *chat;
- GSList *cnode;
- NMERR_T rc = NM_OK;
- NMUserRecord *user_record = NULL;
-@@ -2418,7 +2418,7 @@ novell_chat_invite(GaimConnection *gc, i
- for (cnode = user->conferences; cnode != NULL; cnode = cnode->next) {
- conference = cnode->data;
- if (conference && (chat = nm_conference_get_data(conference))) {
-- if (gaim_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
-+ if (gaim2_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
- rc = nm_send_conference_invite(user, conference, user_record,
- message, _sendinvite_resp_cb, NULL);
- _check_for_disconnect(user, rc);
-@@ -2429,10 +2429,10 @@ novell_chat_invite(GaimConnection *gc, i
- }
-
- static int
--novell_chat_send(GaimConnection * gc, int id, const char *text, GaimMessageFlags flags)
-+novell_chat_send(Gaim2Connection * gc, int id, const char *text, Gaim2MessageFlags flags)
- {
- NMConference *conference;
-- GaimConversation *chat;
-+ Gaim2Conversation *chat;
- GSList *cnode;
- NMMessage *message;
- NMUser *user;
-@@ -2447,14 +2447,14 @@ novell_chat_send(GaimConnection * gc, in
- if (user == NULL)
- return -1;
-
-- plain = gaim_unescape_html(text);
-+ plain = gaim2_unescape_html(text);
- message = nm_create_message(plain);
- g_free(plain);
-
- for (cnode = user->conferences; cnode != NULL; cnode = cnode->next) {
- conference = cnode->data;
- if (conference && (chat = nm_conference_get_data(conference))) {
-- if (gaim_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
-+ if (gaim2_conv_chat_get_id(GAIM_CONV_CHAT(chat)) == id) {
-
- nm_message_set_conference(message, conference);
-
-@@ -2471,7 +2471,7 @@ novell_chat_send(GaimConnection * gc, in
- if (!_check_for_disconnect(user, rc)) {
-
- /* Use the account alias if it is set */
-- name = gaim_account_get_alias(user->client_data);
-+ name = gaim2_account_get_alias(user->client_data);
- if (name == NULL || *name == '\0') {
-
- /* If there is no account alias, try full name */
-@@ -2479,7 +2479,7 @@ novell_chat_send(GaimConnection * gc, in
- if (name == NULL || *name == '\0') {
-
- /* Fall back to the username that we are signed in with */
-- name = gaim_account_get_username(user->client_data);
-+ name = gaim2_account_get_username(user->client_data);
- }
- }
-
-@@ -2494,11 +2494,11 @@ novell_chat_send(GaimConnection * gc, in
-
-
- /* The conference was not found, must be closed */
-- chat = gaim_find_chat(gc, id);
-+ chat = gaim2_find_chat(gc, id);
- if (chat) {
- str = g_strdup_printf(_("This conference has been closed."
- " No more messages can be sent."));
-- gaim_conversation_write(chat, NULL, str, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(chat, NULL, str, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(str);
- }
-
-@@ -2509,7 +2509,7 @@ novell_chat_send(GaimConnection * gc, in
- }
-
- static void
--novell_add_buddy(GaimConnection * gc, GaimBuddy *buddy, GaimGroup * group)
-+novell_add_buddy(Gaim2Connection * gc, Gaim2Buddy *buddy, Gaim2Group * group)
- {
- NMFolder *folder = NULL;
- NMContact *contact;
-@@ -2533,14 +2533,14 @@ novell_add_buddy(GaimConnection * gc, Ga
- contact = nm_create_contact();
- nm_contact_set_dn(contact, buddy->name);
-
-- /* Remove the GaimBuddy (we will add it back after adding it
-+ /* Remove the Gaim2Buddy (we will add it back after adding it
- * to the server side list). Save the alias if there is one.
- */
-- alias = gaim_buddy_get_alias(buddy);
-+ alias = gaim2_buddy_get_alias(buddy);
- if (alias && strcmp(alias, buddy->name))
- nm_contact_set_display_name(contact, alias);
-
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- buddy = NULL;
-
- if (strcmp(group->name, NM_ROOT_FOLDER_NAME) == 0) {
-@@ -2568,7 +2568,7 @@ novell_add_buddy(GaimConnection * gc, Ga
- }
-
- static void
--novell_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+novell_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- NMContact *contact;
- NMFolder *folder;
-@@ -2604,7 +2604,7 @@ novell_remove_buddy(GaimConnection *gc,
- }
-
- static void
--novell_remove_group(GaimConnection * gc, GaimGroup *group)
-+novell_remove_group(Gaim2Connection * gc, Gaim2Group *group)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
-@@ -2625,7 +2625,7 @@ novell_remove_group(GaimConnection * gc,
- }
-
- static void
--novell_alias_buddy(GaimConnection * gc, const char *name, const char *alias)
-+novell_alias_buddy(Gaim2Connection * gc, const char *name, const char *alias)
- {
- NMContact *contact;
- NMUser *user;
-@@ -2645,11 +2645,11 @@ novell_alias_buddy(GaimConnection * gc,
- for (cnode = contacts; cnode != NULL; cnode = cnode->next) {
- contact = (NMContact *) cnode->data;
- if (contact) {
-- GaimGroup *group = NULL;
-- GaimBuddy *buddy;
-+ Gaim2Group *group = NULL;
-+ Gaim2Buddy *buddy;
- NMFolder *folder;
-
-- /* Alias the Gaim buddy? */
-+ /* Alias the Gaim2 buddy? */
- folder = nm_find_folder_by_id(user,
- nm_contact_get_parent_id(contact));
- if (folder) {
-@@ -2657,14 +2657,14 @@ novell_alias_buddy(GaimConnection * gc,
- if (*fname == '\0') {
- fname = NM_ROOT_FOLDER_NAME;
- }
-- group = gaim_find_group(fname);
-+ group = gaim2_find_group(fname);
- }
-
- if (group) {
-- buddy = gaim_find_buddy_in_group(user->client_data,
-+ buddy = gaim2_find_buddy_in_group(user->client_data,
- name, group);
- if (buddy && strcmp(buddy->alias, alias))
-- gaim_blist_alias_buddy(buddy, alias);
-+ gaim2_blist_alias_buddy(buddy, alias);
- }
-
- /* Tell the server to alias the contact */
-@@ -2679,7 +2679,7 @@ novell_alias_buddy(GaimConnection * gc,
- }
-
- static void
--novell_group_buddy(GaimConnection * gc,
-+novell_group_buddy(Gaim2Connection * gc,
- const char *name, const char *old_group_name,
- const char *new_group_name)
- {
-@@ -2741,8 +2741,8 @@ novell_group_buddy(GaimConnection * gc,
- }
-
- static void
--novell_rename_group(GaimConnection * gc, const char *old_name,
-- GaimGroup *group, GList *moved_buddies)
-+novell_rename_group(Gaim2Connection * gc, const char *old_name,
-+ Gaim2Group *group, GList *moved_buddies)
- {
- NMERR_T rc = NM_OK;
- NMFolder *folder;
-@@ -2756,7 +2756,7 @@ novell_rename_group(GaimConnection * gc,
- if (user) {
- /* Does new folder exist already? */
- if (nm_find_folder(user, group->name)) {
-- /* gaim_blist_rename_group() adds the buddies
-+ /* gaim2_blist_rename_group() adds the buddies
- * to the new group and removes the old group...
- * so there is nothing more to do here.
- */
-@@ -2778,14 +2778,14 @@ novell_rename_group(GaimConnection * gc,
- }
-
- static void
--novell_list_emblems(GaimBuddy * buddy, const char **se, const char **sw, const char **nw, const char **ne)
-+novell_list_emblems(Gaim2Buddy * buddy, const char **se, const char **sw, const char **nw, const char **ne)
- {
- NMUserRecord *user_record = NULL;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUser *user;
- int status = 0;
-
-- gc = gaim_account_get_connection(buddy->account);
-+ gc = gaim2_account_get_connection(buddy->account);
-
- if (gc == NULL || (user = gc->proto_data) == NULL)
- return;
-@@ -2812,16 +2812,16 @@ novell_list_emblems(GaimBuddy * buddy, c
- }
-
- static const char *
--novell_list_icon(GaimAccount * account, GaimBuddy * buddy)
-+novell_list_icon(Gaim2Account * account, Gaim2Buddy * buddy)
- {
- return "novell";
- }
-
- static char *
--novell_tooltip_text(GaimBuddy * buddy)
-+novell_tooltip_text(Gaim2Buddy * buddy)
- {
- NMUserRecord *user_record = NULL;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- NMUser *user;
- int status = 0;
- char *ret_text = NULL;
-@@ -2831,7 +2831,7 @@ novell_tooltip_text(GaimBuddy * buddy)
- if (buddy == NULL)
- return "";
-
-- gc = gaim_account_get_connection(buddy->account);
-+ gc = gaim2_account_get_connection(buddy->account);
- if (gc == NULL || (user = gc->proto_data) == NULL)
- return "";
-
-@@ -2877,12 +2877,12 @@ novell_tooltip_text(GaimBuddy * buddy)
- }
-
- static void
--novell_set_idle(GaimConnection * gc, int time)
-+novell_set_idle(Gaim2Connection * gc, int time)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
- const char *id = NULL;
-- GaimStatus *status = NULL;
-+ Gaim2Status *status = NULL;
-
- if (gc == NULL)
- return;
-@@ -2891,8 +2891,8 @@ novell_set_idle(GaimConnection * gc, int
- if (user == NULL)
- return;
-
-- status = gaim_account_get_active_status(gaim_connection_get_account(gc));
-- id = gaim_status_get_id(status);
-+ status = gaim2_account_get_active_status(gaim2_connection_get_account(gc));
-+ id = gaim2_status_get_id(status);
-
- /* Only go idle if active status is available */
- if (!strcmp(id, NOVELL_STATUS_TYPE_AVAILABLE)) {
-@@ -2907,7 +2907,7 @@ novell_set_idle(GaimConnection * gc, int
- }
-
- static void
--novell_get_info(GaimConnection * gc, const char *name)
-+novell_get_info(Gaim2Connection * gc, const char *name)
- {
- NMUserRecord *user_record;
- NMUser *user;
-@@ -2937,13 +2937,13 @@ novell_get_info(GaimConnection * gc, con
- }
-
- static char *
--novell_status_text(GaimBuddy * buddy)
-+novell_status_text(Gaim2Buddy * buddy)
- {
- const char *text = NULL;
- const char *dn = NULL;
-
- if (buddy && buddy->account) {
-- GaimConnection *gc = gaim_account_get_connection(buddy->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(buddy->account);
-
- if (gc && gc->proto_data) {
- NMUser *user = gc->proto_data;
-@@ -2965,72 +2965,72 @@ novell_status_text(GaimBuddy * buddy)
- }
-
- static GList *
--novell_status_types(GaimAccount *account)
-+novell_status_types(Gaim2Account *account)
- {
- GList *status_types = NULL;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE, NOVELL_STATUS_TYPE_AVAILABLE,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE, NOVELL_STATUS_TYPE_AVAILABLE,
- NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AWAY, NOVELL_STATUS_TYPE_AWAY,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AWAY, NOVELL_STATUS_TYPE_AWAY,
- NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_UNAVAILABLE, NOVELL_STATUS_TYPE_BUSY,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_UNAVAILABLE, NOVELL_STATUS_TYPE_BUSY,
- _("Busy"), TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_INVISIBLE, NOVELL_STATUS_TYPE_APPEAR_OFFLINE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_INVISIBLE, NOVELL_STATUS_TYPE_APPEAR_OFFLINE,
- NULL, TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_OFFLINE, NULL, NULL, FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_OFFLINE, NULL, NULL, FALSE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-
- return status_types;
- }
-
- static void
--novell_set_status(GaimAccount *account, GaimStatus *status)
-+novell_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- gboolean connected;
-- GaimPresence *presence;
-- GaimStatusType *type;
-- GaimStatusPrimitive primitive;
-+ Gaim2Presence *presence;
-+ Gaim2StatusType *type;
-+ Gaim2StatusPrimitive primitive;
- NMUser *user;
- NMSTATUS_T novellstatus = NM_STATUS_AVAILABLE;
- NMERR_T rc = NM_OK;
- const char *msg = NULL;
- char *text = NULL;
-
-- connected = gaim_account_is_connected(account);
-- presence = gaim_status_get_presence(status);
-- type = gaim_status_get_type(status);
-- primitive = gaim_status_type_get_primitive(type);
-+ connected = gaim2_account_is_connected(account);
-+ presence = gaim2_status_get_presence(status);
-+ type = gaim2_status_get_type(status);
-+ primitive = gaim2_status_type_get_primitive(type);
-
- /*
- * We don't have any independent statuses, so we don't need to
- * do anything when a status is deactivated (because another
- * status is about to be activated).
- */
-- if (!gaim_status_is_active(status))
-+ if (!gaim2_status_is_active(status))
- return;
-
- if (!connected)
- return;
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- user = gc->proto_data;
- if (user == NULL)
- return;
-@@ -3043,7 +3043,7 @@ novell_set_status(GaimAccount *account,
- novellstatus = NM_STATUS_BUSY;
- } else if (primitive == GAIM_STATUS_INVISIBLE) {
- novellstatus = NM_STATUS_OFFLINE;
-- } else if (gaim_presence_is_idle(presence)) {
-+ } else if (gaim2_presence_is_idle(presence)) {
- novellstatus = NM_STATUS_AWAY_IDLE;
- } else {
- novellstatus = NM_STATUS_AVAILABLE;
-@@ -3051,14 +3051,14 @@ novell_set_status(GaimAccount *account,
-
- if (primitive == GAIM_STATUS_AWAY || primitive == GAIM_STATUS_AVAILABLE ||
- primitive == GAIM_STATUS_UNAVAILABLE) {
-- msg = gaim_status_get_attr_string(status, "message");
-+ msg = gaim2_status_get_attr_string(status, "message");
- text = g_strdup(msg);
-
- if (primitive == GAIM_STATUS_AVAILABLE)
- msg = NULL; /* no auto replies for online status */
-
- /* Don't want newlines in status text */
-- gaim_util_chrreplace(text, '\n', ' ');
-+ gaim2_util_chrreplace(text, '\n', ' ');
- }
-
- rc = nm_send_set_status(user, novellstatus, text, msg, NULL, NULL);
-@@ -3069,7 +3069,7 @@ novell_set_status(GaimAccount *account,
- }
-
- static void
--novell_add_permit(GaimConnection *gc, const char *who)
-+novell_add_permit(Gaim2Connection *gc, const char *who)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
-@@ -3085,7 +3085,7 @@ novell_add_permit(GaimConnection *gc, co
- /* Remove first -- we will add it back in when we get
- * the okay from the server
- */
-- gaim_privacy_permit_remove(gc->account, who, TRUE);
-+ gaim2_privacy_permit_remove(gc->account, who, TRUE);
-
- if (nm_user_is_privacy_locked(user)) {
- _show_privacy_locked_error(gc, user);
-@@ -3113,7 +3113,7 @@ novell_add_permit(GaimConnection *gc, co
- }
-
- static void
--novell_add_deny(GaimConnection *gc, const char *who)
-+novell_add_deny(Gaim2Connection *gc, const char *who)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
-@@ -3129,7 +3129,7 @@ novell_add_deny(GaimConnection *gc, cons
- /* Remove first -- we will add it back in when we get
- * the okay from the server
- */
-- gaim_privacy_deny_remove(gc->account, who, TRUE);
-+ gaim2_privacy_deny_remove(gc->account, who, TRUE);
-
- if (nm_user_is_privacy_locked(user)) {
- _show_privacy_locked_error(gc, user);
-@@ -3157,7 +3157,7 @@ novell_add_deny(GaimConnection *gc, cons
- }
-
- static void
--novell_rem_permit(GaimConnection *gc, const char *who)
-+novell_rem_permit(Gaim2Connection *gc, const char *who)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
-@@ -3187,7 +3187,7 @@ novell_rem_permit(GaimConnection *gc, co
- }
-
- static void
--novell_rem_deny(GaimConnection *gc, const char *who)
-+novell_rem_deny(Gaim2Connection *gc, const char *who)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
-@@ -3217,7 +3217,7 @@ novell_rem_deny(GaimConnection *gc, cons
- }
-
- static void
--novell_set_permit_deny(GaimConnection *gc)
-+novell_set_permit_deny(Gaim2Connection *gc)
- {
- NMERR_T rc = NM_OK;
- const char *dn, *name = NULL;
-@@ -3305,7 +3305,7 @@ novell_set_permit_deny(GaimConnection *g
-
- if (!g_slist_find_custom(gc->account->permit,
- name, (GCompareFunc)nm_utf8_strcasecmp)) {
-- gaim_privacy_permit_add(gc->account, name , TRUE);
-+ gaim2_privacy_permit_add(gc->account, name , TRUE);
- }
- }
- }
-@@ -3324,7 +3324,7 @@ novell_set_permit_deny(GaimConnection *g
- g_strdup(dn));
- }
- } else {
-- gaim_privacy_permit_remove(gc->account, (char *)node->data, TRUE);
-+ gaim2_privacy_permit_remove(gc->account, (char *)node->data, TRUE);
- }
- }
- }
-@@ -3347,7 +3347,7 @@ novell_set_permit_deny(GaimConnection *g
-
- if (!g_slist_find_custom(gc->account->deny,
- name, (GCompareFunc)nm_utf8_strcasecmp)) {
-- gaim_privacy_deny_add(gc->account, name , TRUE);
-+ gaim2_privacy_deny_add(gc->account, name , TRUE);
- }
- }
- }
-@@ -3367,7 +3367,7 @@ novell_set_permit_deny(GaimConnection *g
- g_strdup(name));
- }
- } else {
-- gaim_privacy_deny_remove(gc->account, (char *)node->data, TRUE);
-+ gaim2_privacy_deny_remove(gc->account, (char *)node->data, TRUE);
- }
- }
-
-@@ -3435,13 +3435,13 @@ novell_set_permit_deny(GaimConnection *g
- }
-
- static GList *
--novell_blist_node_menu(GaimBlistNode *node)
-+novell_blist_node_menu(Gaim2BlistNode *node)
- {
- GList *list = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
- if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- act = gaim_blist_node_action_new(_("Initiate _Chat"),
-+ act = gaim2_blist_node_action_new(_("Initiate _Chat"),
- _initiate_conference_cb, NULL, NULL);
- list = g_list_append(list, act);
- }
-@@ -3450,7 +3450,7 @@ novell_blist_node_menu(GaimBlistNode *no
- }
-
- static void
--novell_keepalive(GaimConnection *gc)
-+novell_keepalive(Gaim2Connection *gc)
- {
- NMUser *user;
- NMERR_T rc = NM_OK;
-@@ -3466,7 +3466,7 @@ novell_keepalive(GaimConnection *gc)
- _check_for_disconnect(user, rc);
- }
-
--static GaimPluginProtocolInfo prpl_info = {
-+static Gaim2PluginProtocolInfo prpl_info = {
- 0,
- NULL, /* user_splits */
- NULL, /* protocol_options */
-@@ -3513,7 +3513,7 @@ static GaimPluginProtocolInfo prpl_info
- novell_rename_group, /* rename_group */
- NULL, /* buddy_free */
- novell_convo_closed, /* convo_closed */
-- gaim_normalize_nocase, /* normalize */
-+ gaim2_normalize_nocase, /* normalize */
- NULL, /* set_buddy_icon */
- novell_remove_group, /* remove_group */
- NULL, /* get_cb_real_name */
-@@ -3530,7 +3530,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info = {
-+static Gaim2PluginInfo info = {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
- GAIM_MINOR_VERSION,
-@@ -3560,15 +3560,15 @@ static GaimPluginInfo info = {
- };
-
- static void
--init_plugin(GaimPlugin * plugin)
-+init_plugin(Gaim2Plugin * plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_string_new(_("Server address"), "server", NULL);
-+ option = gaim2_account_option_string_new(_("Server address"), "server", NULL);
- prpl_info.protocol_options =
- g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_int_new(_("Server port"), "port", DEFAULT_PORT);
-+ option = gaim2_account_option_int_new(_("Server port"), "port", DEFAULT_PORT);
- prpl_info.protocol_options =
- g_list_append(prpl_info.protocol_options, option);
-
-diff -prNu ./src/protocols/oscar/aim.h ./src/protocols/oscar/aim.h
---- ./src/protocols/oscar/aim.h 2005-12-25 04:41:49.000000000 +0100
-+++ ./src/protocols/oscar/aim.h 2006-01-05 15:11:21.000000000 +0100
-@@ -278,7 +278,7 @@ struct client_info_s {
- }
-
- #define CLIENTINFO_GAIM { \
-- "Gaim/" VERSION, \
-+ "Gaim2/" VERSION, \
- 0x0109, \
- 0x0005, 0x0001, \
- 0x0000, 0x0bdc, \
-diff -prNu ./src/protocols/oscar/auth.c ./src/protocols/oscar/auth.c
---- ./src/protocols/oscar/auth.c 2005-12-09 05:05:04.000000000 +0100
-+++ ./src/protocols/oscar/auth.c 2006-01-05 15:11:06.000000000 +0100
-@@ -60,40 +60,40 @@ static int aim_encode_password(const cha
- #ifdef USE_OLD_MD5
- static int aim_encode_password_md5(const char *password, const char *key, fu8_t *digest)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
-
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
-
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, (const guchar *)key, strlen(key));
-- gaim_cipher_context_append(context, (const guchar *)password, strlen(password));
-- gaim_cipher_context_append(context, (const guchar *)AIM_MD5_STRING, strlen(AIM_MD5_STRING));
-- gaim_cipher_context_digest(context, 16, digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)key, strlen(key));
-+ gaim2_cipher_context_append(context, (const guchar *)password, strlen(password));
-+ gaim2_cipher_context_append(context, (const guchar *)AIM_MD5_STRING, strlen(AIM_MD5_STRING));
-+ gaim2_cipher_context_digest(context, 16, digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- return 0;
- }
- #else
- static int aim_encode_password_md5(const char *password, const char *key, fu8_t *digest)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar passdigest[16];
-
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
-
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, (const guchar *)password, strlen(password));
-- gaim_cipher_context_digest(context, 16, passdigest, NULL);
-- gaim_cipher_context_destroy(context);
--
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, (const guchar *)key, strlen(key));
-- gaim_cipher_context_append(context, passdigest, 16);
-- gaim_cipher_context_append(context, (const guchar *)AIM_MD5_STRING, strlen(AIM_MD5_STRING));
-- gaim_cipher_context_digest(context, 16, digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)password, strlen(password));
-+ gaim2_cipher_context_digest(context, 16, passdigest, NULL);
-+ gaim2_cipher_context_destroy(context);
-+
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)key, strlen(key));
-+ gaim2_cipher_context_append(context, passdigest, 16);
-+ gaim2_cipher_context_append(context, (const guchar *)AIM_MD5_STRING, strlen(AIM_MD5_STRING));
-+ gaim2_cipher_context_digest(context, 16, digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- return 0;
- }
-diff -prNu ./src/protocols/oscar/buddylist.c ./src/protocols/oscar/buddylist.c
---- ./src/protocols/oscar/buddylist.c 2005-08-13 08:43:45.000000000 +0200
-+++ ./src/protocols/oscar/buddylist.c 2006-01-05 15:11:06.000000000 +0100
-@@ -117,7 +117,7 @@ faim_export int aim_buddylist_set(aim_se
- return -EINVAL;
-
- for (tmpptr = strtok(localcpy, "&"); tmpptr; ) {
-- gaim_debug_misc("oscar", "---adding: %s (%d)\n", tmpptr, strlen(tmpptr));
-+ gaim2_debug_misc("oscar", "---adding: %s (%d)\n", tmpptr, strlen(tmpptr));
- len += 1 + strlen(tmpptr);
- tmpptr = strtok(NULL, "&");
- }
-@@ -132,7 +132,7 @@ faim_export int aim_buddylist_set(aim_se
-
- for (tmpptr = strtok(localcpy, "&"); tmpptr; ) {
-
-- gaim_debug_misc("oscar", "---adding: %s (%d)\n", tmpptr, strlen(tmpptr));
-+ gaim2_debug_misc("oscar", "---adding: %s (%d)\n", tmpptr, strlen(tmpptr));
-
- aimbs_put8(&fr->data, strlen(tmpptr));
- aimbs_putstr(&fr->data, tmpptr);
-diff -prNu ./src/protocols/oscar/chat.c ./src/protocols/oscar/chat.c
---- ./src/protocols/oscar/chat.c 2005-12-09 05:05:04.000000000 +0100
-+++ ./src/protocols/oscar/chat.c 2006-01-05 15:11:06.000000000 +0100
-@@ -52,7 +52,7 @@ faim_export aim_conn_t *aim_chat_getconn
- if (cur->type != AIM_CONN_TYPE_CHAT)
- continue;
- if (!cur->internal) {
-- gaim_debug_misc("oscar", "faim: chat: chat connection with no name! (fd = %d)\n", cur->fd);
-+ gaim2_debug_misc("oscar", "faim: chat: chat connection with no name! (fd = %d)\n", cur->fd);
- continue;
- }
-
-@@ -142,7 +142,7 @@ static int infoupdate(aim_session_t *ses
- detaillevel = aimbs_get8(bs);
-
- if (detaillevel != 0x02) {
-- gaim_debug_misc("oscar", "faim: chat_roomupdateinfo: detail level %d not supported\n", detaillevel);
-+ gaim2_debug_misc("oscar", "faim: chat_roomupdateinfo: detail level %d not supported\n", detaillevel);
- return 1;
- }
-
-@@ -477,7 +477,7 @@ static int incomingim_ch3(aim_session_t
- channel = aimbs_get16(bs);
-
- if (channel != 0x0003) {
-- gaim_debug_misc("oscar", "faim: chat_incoming: unknown channel! (0x%04x)\n", channel);
-+ gaim2_debug_misc("oscar", "faim: chat_incoming: unknown channel! (0x%04x)\n", channel);
- return 0;
- }
-
-diff -prNu ./src/protocols/oscar/chatnav.c ./src/protocols/oscar/chatnav.c
---- ./src/protocols/oscar/chatnav.c 2005-12-09 05:05:04.000000000 +0100
-+++ ./src/protocols/oscar/chatnav.c 2006-01-05 15:11:06.000000000 +0100
-@@ -154,7 +154,7 @@ static int parseinfo_perms(aim_session_t
-
- classperms = aim_tlv_get16(innerlist, 0x0002, 1);
-
-- gaim_debug_misc("oscar", "faim: class permissions %x\n", classperms);
-+ gaim2_debug_misc("oscar", "faim: class permissions %x\n", classperms);
- }
-
- /*
-@@ -309,7 +309,7 @@ static int parseinfo_create(aim_session_
- tlvlist = aim_tlvlist_read(bs);
-
- if (!(bigblock = aim_tlv_gettlv(tlvlist, 0x0004, 1))) {
-- gaim_debug_misc("oscar", "no bigblock in top tlv in create room response\n");
-+ gaim2_debug_misc("oscar", "no bigblock in top tlv in create room response\n");
- aim_tlvlist_free(&tlvlist);
- return 0;
- }
-@@ -323,7 +323,7 @@ static int parseinfo_create(aim_session_
- detaillevel = aimbs_get8(&bbbs);
-
- if (detaillevel != 0x02) {
-- gaim_debug_misc("oscar", "unknown detaillevel in create room response (0x%02x)\n", detaillevel);
-+ gaim2_debug_misc("oscar", "unknown detaillevel in create room response (0x%02x)\n", detaillevel);
- aim_tlvlist_free(&tlvlist);
- free(ck);
- return 0;
-@@ -391,12 +391,12 @@ static int parseinfo(aim_session_t *sess
- int ret = 0;
-
- if (!(snac2 = aim_remsnac(sess, snac->id))) {
-- gaim_debug_misc("oscar", "faim: chatnav_parse_info: received response to unknown request! (%08lx)\n", snac->id);
-+ gaim2_debug_misc("oscar", "faim: chatnav_parse_info: received response to unknown request! (%08lx)\n", snac->id);
- return 0;
- }
-
- if (snac2->family != 0x000d) {
-- gaim_debug_misc("oscar", "faim: chatnav_parse_info: recieved response that maps to corrupt request! (fam=%04x)\n", snac2->family);
-+ gaim2_debug_misc("oscar", "faim: chatnav_parse_info: recieved response that maps to corrupt request! (fam=%04x)\n", snac2->family);
- return 0;
- }
-
-@@ -406,19 +406,19 @@ static int parseinfo(aim_session_t *sess
- if (snac2->type == 0x0002) /* request chat rights */
- ret = parseinfo_perms(sess, mod, rx, snac, bs, snac2);
- else if (snac2->type == 0x0003) /* request exchange info */
-- gaim_debug_misc("oscar", "chatnav_parse_info: resposne to exchange info\n");
-+ gaim2_debug_misc("oscar", "chatnav_parse_info: resposne to exchange info\n");
- else if (snac2->type == 0x0004) /* request room info */
-- gaim_debug_misc("oscar", "chatnav_parse_info: response to room info\n");
-+ gaim2_debug_misc("oscar", "chatnav_parse_info: response to room info\n");
- else if (snac2->type == 0x0005) /* request more room info */
-- gaim_debug_misc("oscar", "chatnav_parse_info: response to more room info\n");
-+ gaim2_debug_misc("oscar", "chatnav_parse_info: response to more room info\n");
- else if (snac2->type == 0x0006) /* request occupant list */
-- gaim_debug_misc("oscar", "chatnav_parse_info: response to occupant info\n");
-+ gaim2_debug_misc("oscar", "chatnav_parse_info: response to occupant info\n");
- else if (snac2->type == 0x0007) /* search for a room */
-- gaim_debug_misc("oscar", "chatnav_parse_info: search results\n");
-+ gaim2_debug_misc("oscar", "chatnav_parse_info: search results\n");
- else if (snac2->type == 0x0008) /* create room */
- ret = parseinfo_create(sess, mod, rx, snac, bs, snac2);
- else
-- gaim_debug_misc("oscar", "chatnav_parse_info: unknown request subtype (%04x)\n", snac2->type);
-+ gaim2_debug_misc("oscar", "chatnav_parse_info: unknown request subtype (%04x)\n", snac2->type);
-
- if (snac2)
- free(snac2->data);
-diff -prNu ./src/protocols/oscar/conn.c ./src/protocols/oscar/conn.c
---- ./src/protocols/oscar/conn.c 2005-12-08 22:02:53.000000000 +0100
-+++ ./src/protocols/oscar/conn.c 2006-01-05 15:11:06.000000000 +0100
-@@ -86,7 +86,7 @@ faim_internal void aim_conn_addgroup(aim
- if (!(sg = malloc(sizeof(struct snacgroup))))
- return;
-
-- gaim_debug_misc("oscar", "adding group 0x%04x\n", group);
-+ gaim2_debug_misc("oscar", "adding group 0x%04x\n", group);
- sg->group = group;
-
- sg->next = ins->groups;
-diff -prNu ./src/protocols/oscar/ft.c ./src/protocols/oscar/ft.c
---- ./src/protocols/oscar/ft.c 2005-10-25 22:50:21.000000000 +0200
-+++ ./src/protocols/oscar/ft.c 2006-01-05 15:11:06.000000000 +0100
-@@ -231,7 +231,7 @@ faim_export int aim_handlerendconnect(ai
- ret = userfunc(sess, NULL, newconn, cur);
-
- } else {
-- gaim_debug_warning("oscar", "Got a connection on a listener that's not rendezvous. Closing connection.\n");
-+ gaim2_debug_warning("oscar", "Got a connection on a listener that's not rendezvous. Closing connection.\n");
- aim_conn_close(newconn);
- ret = -1;
- }
-@@ -603,7 +603,7 @@ static int handlehdr_odc(aim_session_t *
- /* XXX - create an aimbs_getnullstr function? */
- snptr = aimbs_getstr(bs, 32); /* Next 32 bytes contain the sn, padded with null chars */
-
-- gaim_debug_misc("oscar", "faim: OFT frame: handlehdr_odc: %04x / %04x / %s\n", payloadlength, flags, snptr);
-+ gaim2_debug_misc("oscar", "faim: OFT frame: handlehdr_odc: %04x / %04x / %s\n", payloadlength, flags, snptr);
-
- if (flags & 0x0008) {
- if ((userfunc = aim_callhandler(sess, conn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMTYPING)))
-@@ -1090,7 +1090,7 @@ faim_internal int aim_rxdispatch_rendezv
- if (fr->hdr.rend.type == 0x0001)
- ret = handlehdr_odc(sess, conn, fr, &fr->data);
- else
-- gaim_debug_info("oscar", "ODC directim frame unknown, type is %04x\n", fr->hdr.rend.type);
-+ gaim2_debug_info("oscar", "ODC directim frame unknown, type is %04x\n", fr->hdr.rend.type);
-
- } else {
- aim_rxcallback_t userfunc;
-@@ -1155,13 +1155,13 @@ faim_internal struct aim_rv_proxy_info *
- aim_bstream_rewind(&bs_body);
- proxy_info->err_code = aimbs_get16(&bs_body);
- } else {
-- gaim_debug_warning("oscar","error reading rv proxy error packet\n");
-+ gaim2_debug_warning("oscar","error reading rv proxy error packet\n");
- aim_conn_close(conn);
- free(proxy_info);
- proxy_info = NULL;
- }
- } else {
-- gaim_debug_warning("oscar","invalid length for proxy error packet\n");
-+ gaim2_debug_warning("oscar","invalid length for proxy error packet\n");
- free(proxy_info);
- proxy_info = NULL;
- }
-@@ -1181,21 +1181,21 @@ faim_internal struct aim_rv_proxy_info *
- ip_temp[2], ip_temp[3]);
- proxy_info->ip = strdup(str_ip);
- } else {
-- gaim_debug_warning("oscar","error reading rv proxy error packet\n");
-+ gaim2_debug_warning("oscar","error reading rv proxy error packet\n");
- aim_conn_close(conn);
- free(proxy_info);
- proxy_info = NULL;
- }
- } else {
-- gaim_debug_warning("oscar","invalid length for proxy error packet\n");
-+ gaim2_debug_warning("oscar","invalid length for proxy error packet\n");
- free(proxy_info);
- proxy_info = NULL;
- }
- } else {
-- gaim_debug_warning("oscar","unknown type for aim rendezvous proxy packet\n");
-+ gaim2_debug_warning("oscar","unknown type for aim rendezvous proxy packet\n");
- }
- } else {
-- gaim_debug_warning("oscar","error reading header of rv proxy packet\n");
-+ gaim2_debug_warning("oscar","error reading header of rv proxy packet\n");
- aim_conn_close(conn);
- free(proxy_info);
- proxy_info = NULL;
-diff -prNu ./src/protocols/oscar/icq.c ./src/protocols/oscar/icq.c
---- ./src/protocols/oscar/icq.c 2005-12-25 04:41:49.000000000 +0100
-+++ ./src/protocols/oscar/icq.c 2006-01-05 15:11:06.000000000 +0100
-@@ -473,7 +473,7 @@ static int icqresponse(aim_session_t *se
-
- if (!(tl = aim_tlvlist_read(bs)) || !(datatlv = aim_tlv_gettlv(tl, 0x0001, 1))) {
- aim_tlvlist_free(&tl);
-- gaim_debug_misc("oscar", "corrupt ICQ response\n");
-+ gaim2_debug_misc("oscar", "corrupt ICQ response\n");
- return 0;
- }
-
-@@ -484,7 +484,7 @@ static int icqresponse(aim_session_t *se
- cmd = aimbs_getle16(&qbs);
- reqid = aimbs_getle16(&qbs);
-
-- gaim_debug_misc("oscar", "icq response: %d bytes, %ld, 0x%04x, 0x%04x\n", cmdlen, ouruin, cmd, reqid);
-+ gaim2_debug_misc("oscar", "icq response: %d bytes, %ld, 0x%04x, 0x%04x\n", cmdlen, ouruin, cmd, reqid);
-
- if (cmd == 0x0041) { /* offline message */
- struct aim_icq_offlinemsg msg;
-diff -prNu ./src/protocols/oscar/im.c ./src/protocols/oscar/im.c
---- ./src/protocols/oscar/im.c 2005-12-25 20:09:24.000000000 +0100
-+++ ./src/protocols/oscar/im.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1159,7 +1159,7 @@ static int outgoingim(aim_session_t *ses
- channel = aimbs_get16(bs);
-
- if (channel != 0x01) {
-- gaim_debug_misc("oscar", "icbm: ICBM recieved on unsupported channel. Ignoring. (chan = %04x)\n", channel);
-+ gaim2_debug_misc("oscar", "icbm: ICBM recieved on unsupported channel. Ignoring. (chan = %04x)\n", channel);
- return 0;
- }
-
-@@ -1382,7 +1382,7 @@ static int incomingim_ch1_parsemsgs(aim_
- msglen = aimbs_get16(&mbs);
- if (msglen > aim_bstream_empty(&mbs))
- {
-- gaim_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.", userinfo->sn);
-+ gaim2_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.", userinfo->sn);
- break;
- }
-
-@@ -1490,7 +1490,7 @@ static int incomingim_ch1(aim_session_t
-
- if (length > aim_bstream_empty(bs))
- {
-- gaim_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.\n", userinfo->sn);
-+ gaim2_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.\n", userinfo->sn);
- break;
- }
-
-@@ -1513,7 +1513,7 @@ static int incomingim_ch1(aim_session_t
- args.featureslen = aimbs_get16(bs);
- if (args.featureslen > aim_bstream_empty(bs))
- {
-- gaim_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.\n", userinfo->sn);
-+ gaim2_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.\n", userinfo->sn);
- break;
- }
- if (args.featureslen == 0)
-@@ -1579,7 +1579,7 @@ static int incomingim_ch1(aim_session_t
- args.extdatalen = length;
- if (args.extdatalen > aim_bstream_empty(bs))
- {
-- gaim_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.\n", userinfo->sn);
-+ gaim2_debug_misc("oscar", "Received an IM containing an invalid message part from %s. They are probably trying to do something malicious.\n", userinfo->sn);
- break;
- }
- if (args.extdatalen == 0)
-@@ -1588,7 +1588,7 @@ static int incomingim_ch1(aim_session_t
- args.extdata = aimbs_getraw(bs, args.extdatalen);
-
- } else {
-- gaim_debug_misc("oscar", "incomingim_ch1: unknown TLV 0x%04x (len %d)\n", type, length);
-+ gaim2_debug_misc("oscar", "incomingim_ch1: unknown TLV 0x%04x (len %d)\n", type, length);
- }
-
- /*
-@@ -1651,7 +1651,7 @@ static void incomingim_ch2_buddylist(aim
- bnlen = aimbs_get16(servdata);
- bn = aimbs_getstr(servdata, bnlen);
-
-- gaim_debug_misc("oscar", "got a buddy list from %s: group %s, buddy %s\n", userinfo->sn, gn, bn);
-+ gaim2_debug_misc("oscar", "got a buddy list from %s: group %s, buddy %s\n", userinfo->sn, gn, bn);
-
- free(bn);
- }
-@@ -1833,7 +1833,7 @@ static int incomingim_ch2(aim_session_t
- */
- cookie2 = aimbs_getraw(&bbs, 8);
- if (memcmp(cookie, cookie2, 8) != 0)
-- gaim_debug_misc("oscar", "rend: warning cookies don't match!\n");
-+ gaim2_debug_misc("oscar", "rend: warning cookies don't match!\n");
- memcpy(args.cookie, cookie2, 8);
- free(cookie2);
-
-@@ -2139,7 +2139,7 @@ static int incomingim(aim_session_t *ses
- aim_tlvlist_free(&tlvlist);
-
- } else {
-- gaim_debug_misc("oscar", "icbm: ICBM received on an unsupported channel. Ignoring. (chan = %04x)\n", channel);
-+ gaim2_debug_misc("oscar", "icbm: ICBM received on an unsupported channel. Ignoring. (chan = %04x)\n", channel);
- }
-
- aim_info_free(&userinfo);
-@@ -2364,7 +2364,7 @@ static int msgack(aim_session_t *sess, a
- * Subtype 0x0014 - Send a mini typing notification (mtn) packet.
- *
- * This is supported by winaim5 and newer, MacAIM bleh and newer, iChat bleh and newer,
-- * and Gaim 0.60 and newer.
-+ * and Gaim2 0.60 and newer.
- *
- */
- faim_export int aim_im_sendmtn(aim_session_t *sess, fu16_t type1, const char *sn, fu16_t type2)
-@@ -2419,7 +2419,7 @@ faim_export int aim_im_sendmtn(aim_sessi
- * Subtype 0x0014 - Receive a mini typing notification (mtn) packet.
- *
- * This is supported by winaim5 and newer, MacAIM bleh and newer, iChat bleh and newer,
-- * and Gaim 0.60 and newer.
-+ * and Gaim2 0.60 and newer.
- *
- */
- static int mtn_receive(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_bstream_t *bs)
-diff -prNu ./src/protocols/oscar/locate.c ./src/protocols/oscar/locate.c
---- ./src/protocols/oscar/locate.c 2005-12-21 19:36:18.000000000 +0100
-+++ ./src/protocols/oscar/locate.c 2006-01-05 15:11:06.000000000 +0100
-@@ -402,7 +402,7 @@ faim_internal fu32_t aim_locate_getcaps(
- }
-
- if (!identified)
-- gaim_debug_misc("oscar", "unknown capability: {%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x}\n",
-+ gaim2_debug_misc("oscar", "unknown capability: {%02x%02x%02x%02x-%02x%02x-%02x%02x-%02x%02x-%02x%02x%02x%02x%02x%02x}\n",
- cap[0], cap[1], cap[2], cap[3],
- cap[4], cap[5],
- cap[6], cap[7],
-@@ -436,7 +436,7 @@ faim_internal fu32_t aim_locate_getcaps_
- }
-
- if (!identified)
-- gaim_debug_misc("oscar", "unknown short capability: {%02x%02x}\n", cap[0], cap[1]);
-+ gaim2_debug_misc("oscar", "unknown short capability: {%02x%02x}\n", cap[0], cap[1]);
-
- free(cap);
- }
-@@ -471,17 +471,17 @@ static void dumptlv(aim_session_t *sess,
- if (!sess || !bs || !len)
- return;
-
-- gaim_debug_misc("oscar", "userinfo: type =0x%04x\n", type);
-- gaim_debug_misc("oscar", "userinfo: length=0x%04x\n", len);
-- gaim_debug_misc("oscar", "userinfo: value:\n");
-+ gaim2_debug_misc("oscar", "userinfo: type =0x%04x\n", type);
-+ gaim2_debug_misc("oscar", "userinfo: length=0x%04x\n", len);
-+ gaim2_debug_misc("oscar", "userinfo: value:\n");
-
- for (i = 0; i < len; i++) {
- if ((i % 8) == 0)
-- gaim_debug_misc("oscar", "\nuserinfo: ");
-- gaim_debug_misc("oscar", "0x%2x ", aimbs_get8(bs));
-+ gaim2_debug_misc("oscar", "\nuserinfo: ");
-+ gaim2_debug_misc("oscar", "0x%2x ", aimbs_get8(bs));
- }
-
-- gaim_debug_misc("oscar", "\n");
-+ gaim2_debug_misc("oscar", "\n");
-
- return;
- }
-@@ -810,8 +810,8 @@ faim_internal int aim_info_extract(aim_s
- * recovery.
- *
- */
-- gaim_debug_misc("oscar", "userinfo: **warning: unexpected TLV:\n");
-- gaim_debug_misc("oscar", "userinfo: sn =%s\n", outinfo->sn);
-+ gaim2_debug_misc("oscar", "userinfo: **warning: unexpected TLV:\n");
-+ gaim2_debug_misc("oscar", "userinfo: sn =%s\n", outinfo->sn);
- dumptlv(sess, type, bs, length);
- }
-
-@@ -884,17 +884,17 @@ static int error(aim_session_t *sess, ai
- int was_explicit;
-
- if (!(snac2 = aim_remsnac(sess, snac->id))) {
-- gaim_debug_misc("oscar", "faim: locate.c, error(): received response from unknown request!\n");
-+ gaim2_debug_misc("oscar", "faim: locate.c, error(): received response from unknown request!\n");
- return 0;
- }
-
- if ((snac2->family != 0x0002) && (snac2->type != 0x0015)) {
-- gaim_debug_misc("oscar", "faim: locate.c, error(): received response from invalid request! %d\n", snac2->family);
-+ gaim2_debug_misc("oscar", "faim: locate.c, error(): received response from invalid request! %d\n", snac2->family);
- return 0;
- }
-
- if (!(sn = snac2->data)) {
-- gaim_debug_misc("oscar", "faim: locate.c, error(): received response from request without a screen name!\n");
-+ gaim2_debug_misc("oscar", "faim: locate.c, error(): received response from request without a screen name!\n");
- return 0;
- }
-
-diff -prNu ./src/protocols/oscar/Makefile.am ./src/protocols/oscar/Makefile.am
---- ./src/protocols/oscar/Makefile.am 2005-09-01 05:30:17.000000000 +0200
-+++ ./src/protocols/oscar/Makefile.am 2006-01-05 13:04:35.000000000 +0100
-@@ -3,7 +3,7 @@ EXTRA_DIST = \
- AUTHORS \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- OSCARSOURCES = \
- admin.c \
-diff -prNu ./src/protocols/oscar/oscar.c ./src/protocols/oscar/oscar.c
---- ./src/protocols/oscar/oscar.c 2006-01-05 06:04:06.000000000 +0100
-+++ ./src/protocols/oscar/oscar.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * Some code copyright (C) 1998-1999, Mark Spencer <markster@marko.net>
- * Some code copyright (C) 1999-2001, Eric Warmenhoven
-@@ -57,7 +57,7 @@
- #define OSCAR_STATUS_ID_FREE4CHAT "free4chat"
- #define OSCAR_STATUS_ID_CUSTOM "custom"
-
--#define AIMHASHDATA "http://gaim.sourceforge.net/aim_data.php3"
-+#define AIMHASHDATA "http://gaim2.sourceforge.net/aim_data.php3"
-
- #define OSCAR_CONNECT_STEPS 6
- #define OSCAR_DEFAULT_LOGIN_SERVER "login.oscar.aol.com"
-@@ -143,14 +143,14 @@ struct chat_connection {
- aim_conn_t *conn;
- int inpa;
- int id;
-- GaimConnection *gc; /* i hate this. */
-- GaimConversation *conv; /* bah. */
-+ Gaim2Connection *gc; /* i hate this. */
-+ Gaim2Conversation *conv; /* bah. */
- int maxlen;
- int maxvis;
- };
-
- struct oscar_direct_im {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char name[80];
- int watcher;
- aim_conn_t *conn;
-@@ -161,7 +161,7 @@ struct oscar_direct_im {
- };
-
- struct ask_direct {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *sn;
- char ip[64];
- fu8_t cookie[8];
-@@ -192,7 +192,7 @@ struct buddyinfo {
- };
-
- struct name_data {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- gchar *name;
- gchar *nick;
- };
-@@ -226,74 +226,74 @@ static char *msgerrreason[] = {
- };
- static int msgerrreasonlen = 25;
-
--/* All the libfaim->gaim callback functions */
--static int gaim_parse_auth_resp (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_login (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_auth_securid_request(aim_session_t *, aim_frame_t *, ...);
--static int gaim_handle_redirect (aim_session_t *, aim_frame_t *, ...);
--static int gaim_info_change (aim_session_t *, aim_frame_t *, ...);
--static int gaim_account_confirm (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_oncoming (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_offgoing (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_incoming_im(aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_misses (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_clientauto (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_userinfo (aim_session_t *, aim_frame_t *, ...);
--static int gaim_reqinfo_timeout (aim_session_t *, aim_frame_t *, ...);
--static int gaim_got_infoblock (aim_session_t *sess, aim_frame_t *fr, ...);
--static int gaim_parse_motd (aim_session_t *, aim_frame_t *, ...);
--static int gaim_chatnav_info (aim_session_t *, aim_frame_t *, ...);
--static int gaim_conv_chat_join (aim_session_t *, aim_frame_t *, ...);
--static int gaim_conv_chat_leave (aim_session_t *, aim_frame_t *, ...);
--static int gaim_conv_chat_info_update (aim_session_t *, aim_frame_t *, ...);
--static int gaim_conv_chat_incoming_msg(aim_session_t *, aim_frame_t *, ...);
--static int gaim_email_parseupdate(aim_session_t *, aim_frame_t *, ...);
--static int gaim_icon_error (aim_session_t *, aim_frame_t *, ...);
--static int gaim_icon_parseicon (aim_session_t *, aim_frame_t *, ...);
-+/* All the libfaim->gaim2 callback functions */
-+static int gaim2_parse_auth_resp (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_login (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_auth_securid_request(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_handle_redirect (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_info_change (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_account_confirm (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_oncoming (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_offgoing (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_incoming_im(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_misses (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_clientauto (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_userinfo (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_reqinfo_timeout (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_got_infoblock (aim_session_t *sess, aim_frame_t *fr, ...);
-+static int gaim2_parse_motd (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_chatnav_info (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_conv_chat_join (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_conv_chat_leave (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_conv_chat_info_update (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_conv_chat_incoming_msg(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_email_parseupdate(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_icon_error (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_icon_parseicon (aim_session_t *, aim_frame_t *, ...);
- static int oscar_icon_req (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_msgack (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_ratechange (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_evilnotify (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_searcherror(aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_searchreply(aim_session_t *, aim_frame_t *, ...);
--static int gaim_bosrights (aim_session_t *, aim_frame_t *, ...);
--static int gaim_connerr (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_msgack (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_ratechange (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_evilnotify (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_searcherror(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_searchreply(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_bosrights (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_connerr (aim_session_t *, aim_frame_t *, ...);
- static int conninitdone_admin (aim_session_t *, aim_frame_t *, ...);
- static int conninitdone_bos (aim_session_t *, aim_frame_t *, ...);
- static int conninitdone_chatnav (aim_session_t *, aim_frame_t *, ...);
- static int conninitdone_chat (aim_session_t *, aim_frame_t *, ...);
- static int conninitdone_email (aim_session_t *, aim_frame_t *, ...);
- static int conninitdone_icon (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_msgerr (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_mtn (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_locaterights(aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_buddyrights(aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_locerr (aim_session_t *, aim_frame_t *, ...);
--static int gaim_icbm_param_info (aim_session_t *, aim_frame_t *, ...);
--static int gaim_parse_genericerr (aim_session_t *, aim_frame_t *, ...);
--static int gaim_memrequest (aim_session_t *, aim_frame_t *, ...);
--static int gaim_selfinfo (aim_session_t *, aim_frame_t *, ...);
--static int gaim_offlinemsg (aim_session_t *, aim_frame_t *, ...);
--static int gaim_offlinemsgdone (aim_session_t *, aim_frame_t *, ...);
--static int gaim_icqalias (aim_session_t *, aim_frame_t *, ...);
--static int gaim_icqinfo (aim_session_t *, aim_frame_t *, ...);
--static int gaim_popup (aim_session_t *, aim_frame_t *, ...);
--
--static int gaim_ssi_parseerr (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_parserights (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_parselist (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_parseack (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_parseadd (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_authgiven (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_authrequest (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_authreply (aim_session_t *, aim_frame_t *, ...);
--static int gaim_ssi_gotadded (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_msgerr (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_mtn (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_locaterights(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_buddyrights(aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_locerr (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_icbm_param_info (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_parse_genericerr (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_memrequest (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_selfinfo (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_offlinemsg (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_offlinemsgdone (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_icqalias (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_icqinfo (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_popup (aim_session_t *, aim_frame_t *, ...);
-+
-+static int gaim2_ssi_parseerr (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_parserights (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_parselist (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_parseack (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_parseadd (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_authgiven (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_authrequest (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_authreply (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_ssi_gotadded (aim_session_t *, aim_frame_t *, ...);
-
- /* for DirectIM/image transfer */
--static int gaim_odc_initiate (aim_session_t *, aim_frame_t *, ...);
--static int gaim_odc_incoming (aim_session_t *, aim_frame_t *, ...);
--static int gaim_odc_typing (aim_session_t *, aim_frame_t *, ...);
--static int gaim_odc_update_ui (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_odc_initiate (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_odc_incoming (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_odc_typing (aim_session_t *, aim_frame_t *, ...);
-+static int gaim2_odc_update_ui (aim_session_t *, aim_frame_t *, ...);
-
- /* for file transfer */
- static int oscar_sendfile_estblsh(aim_session_t *, aim_frame_t *, ...);
-@@ -301,17 +301,17 @@ static int oscar_sendfile_prompt (aim_se
- static int oscar_sendfile_ack (aim_session_t *, aim_frame_t *, ...);
- static int oscar_sendfile_done (aim_session_t *, aim_frame_t *, ...);
-
--static gboolean gaim_icon_timerfunc(gpointer data);
--static void oscar_callback(gpointer data, gint source, GaimInputCondition condition);
--static void oscar_xfer_init_recv(GaimXfer *xfer);
--static void oscar_xfer_init_send(GaimXfer *xfer);
--
--static void oscar_direct_im_initiate(GaimConnection *gc, const char *who, const guchar *cookie);
--static void recent_buddies_cb(const char *name, GaimPrefType type, gpointer value, gpointer data);
--static void oscar_set_info(GaimConnection *gc, const char *info);
--static void oscar_set_info_and_status(GaimAccount *account, gboolean setinfo, const char *rawinfo, gboolean setstatus, GaimStatus *status);
--static void oscar_set_extendedstatus(GaimConnection *gc);
--static gboolean gaim_ssi_rerequestdata(gpointer data);
-+static gboolean gaim2_icon_timerfunc(gpointer data);
-+static void oscar_callback(gpointer data, gint source, Gaim2InputCondition condition);
-+static void oscar_xfer_init_recv(Gaim2Xfer *xfer);
-+static void oscar_xfer_init_send(Gaim2Xfer *xfer);
-+
-+static void oscar_direct_im_initiate(Gaim2Connection *gc, const char *who, const guchar *cookie);
-+static void recent_buddies_cb(const char *name, Gaim2PrefType type, gpointer value, gpointer data);
-+static void oscar_set_info(Gaim2Connection *gc, const char *info);
-+static void oscar_set_info_and_status(Gaim2Account *account, gboolean setinfo, const char *rawinfo, gboolean setstatus, Gaim2Status *status);
-+static void oscar_set_extendedstatus(Gaim2Connection *gc);
-+static gboolean gaim2_ssi_rerequestdata(gpointer data);
-
- static void oscar_free_name_data(struct name_data *data) {
- g_free(data->name);
-@@ -394,7 +394,7 @@ oscar_encoding_to_utf8(const char *encod
- gchar *utf8 = NULL;
-
- if ((encoding == NULL) || encoding[0] == '\0') {
-- gaim_debug_info("oscar", "Empty encoding, assuming UTF-8\n");
-+ gaim2_debug_info("oscar", "Empty encoding, assuming UTF-8\n");
- } else if (!strcasecmp(encoding, "iso-8859-1")) {
- utf8 = g_convert(text, textlen, "UTF-8", "iso-8859-1", NULL, NULL, NULL);
- } else if (!strcasecmp(encoding, "ISO-8859-1-Windows-3.1-Latin-1")) {
-@@ -402,7 +402,7 @@ oscar_encoding_to_utf8(const char *encod
- } else if (!strcasecmp(encoding, "unicode-2-0")) {
- utf8 = g_convert(text, textlen, "UTF-8", "UCS-2BE", NULL, NULL, NULL);
- } else if (strcasecmp(encoding, "us-ascii") && strcmp(encoding, "utf-8")) {
-- gaim_debug_warning("oscar", "Unrecognized character encoding \"%s\", "
-+ gaim2_debug_warning("oscar", "Unrecognized character encoding \"%s\", "
- "attempting to convert to UTF-8 anyway\n", encoding);
- utf8 = g_convert(text, textlen, "UTF-8", encoding, NULL, NULL, NULL);
- }
-@@ -424,25 +424,25 @@ oscar_encoding_to_utf8(const char *encod
- return utf8;
- }
-
--static gchar *oscar_utf8_try_convert(GaimAccount *account, const gchar *msg)
-+static gchar *oscar_utf8_try_convert(Gaim2Account *account, const gchar *msg)
- {
- const char *charset = NULL;
- char *ret = NULL;
-
-- if(aim_sn_is_icq(gaim_account_get_username(account)))
-- charset = gaim_account_get_string(account, "encoding", NULL);
-+ if(aim_sn_is_icq(gaim2_account_get_username(account)))
-+ charset = gaim2_account_get_string(account, "encoding", NULL);
-
- if(charset && *charset)
- ret = g_convert(msg, -1, "UTF-8", charset, NULL, NULL, NULL);
-
- if(!ret)
-- ret = gaim_utf8_try_convert(msg);
-+ ret = gaim2_utf8_try_convert(msg);
-
- return ret;
- }
-
- static gchar *
--gaim_plugin_oscar_convert_to_utf8(const gchar *data, gsize datalen, const char *charsetstr, gboolean fallback)
-+gaim2_plugin_oscar_convert_to_utf8(const gchar *data, gsize datalen, const char *charsetstr, gboolean fallback)
- {
- gchar *ret = NULL;
- GError *err = NULL;
-@@ -456,7 +456,7 @@ gaim_plugin_oscar_convert_to_utf8(const
- else
- ret = g_convert(data, datalen, "UTF-8", charsetstr, NULL, NULL, &err);
- if (err != NULL) {
-- gaim_debug_warning("oscar", "Conversation from %s failed: %s.\n",
-+ gaim2_debug_warning("oscar", "Conversation from %s failed: %s.\n",
- charsetstr, err->message);
- g_error_free(err);
- }
-@@ -464,7 +464,7 @@ gaim_plugin_oscar_convert_to_utf8(const
- if (g_utf8_validate(data, datalen, NULL))
- ret = g_strndup(data, datalen);
- else
-- gaim_debug_warning("oscar", "String is not valid UTF-8.\n");
-+ gaim2_debug_warning("oscar", "String is not valid UTF-8.\n");
- }
-
- return ret;
-@@ -476,17 +476,17 @@ gaim_plugin_oscar_convert_to_utf8(const
- * We try decoding using two different character sets. The charset
- * specified in the IM determines the order in which we attempt to
- * decode. We do this because there are lots of broken ICQ clients
-- * that don't correctly send non-ASCII messages. And if Gaim isn't
-+ * that don't correctly send non-ASCII messages. And if Gaim2 isn't
- * able to deal with that crap, then people complain like banshees.
- * charsetstr1 is always set to what the correct encoding should be.
- */
- static gchar *
--gaim_plugin_oscar_decode_im_part(GaimAccount *account, const char *sourcesn, fu16_t charset, fu16_t charsubset, const gchar *data, gsize datalen)
-+gaim2_plugin_oscar_decode_im_part(Gaim2Account *account, const char *sourcesn, fu16_t charset, fu16_t charsubset, const gchar *data, gsize datalen)
- {
- gchar *ret = NULL;
- const gchar *charsetstr1, *charsetstr2;
-
-- gaim_debug_info("oscar", "Parsing IM part, charset=0x%04hx, charsubset=0x%04hx, datalen=%hd\n", charset, charsubset, datalen);
-+ gaim2_debug_info("oscar", "Parsing IM part, charset=0x%04hx, charsubset=0x%04hx, datalen=%hd\n", charset, charsubset, datalen);
-
- if ((datalen == 0) || (data == NULL))
- return NULL;
-@@ -496,27 +496,27 @@ gaim_plugin_oscar_decode_im_part(GaimAcc
- charsetstr2 = "UTF-8";
- } else if (charset == AIM_CHARSET_CUSTOM) {
- if ((sourcesn != NULL) && isdigit(sourcesn[0]))
-- charsetstr1 = gaim_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-+ charsetstr1 = gaim2_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
- else
- charsetstr1 = "ISO-8859-1";
- charsetstr2 = "UTF-8";
- } else if (charset == AIM_CHARSET_ASCII) {
- /* Should just be "ASCII" */
- charsetstr1 = "ASCII";
-- charsetstr2 = gaim_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-+ charsetstr2 = gaim2_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
- } else if (charset == 0x000d) {
- /* Mobile AIM client on a Nokia 3100 and an LG VX6000 */
- charsetstr1 = "ISO-8859-1";
-- charsetstr2 = gaim_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-+ charsetstr2 = gaim2_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
- } else {
- /* Unknown, hope for valid UTF-8... */
- charsetstr1 = "UTF-8";
-- charsetstr2 = gaim_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-+ charsetstr2 = gaim2_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
- }
-
-- ret = gaim_plugin_oscar_convert_to_utf8(data, datalen, charsetstr1, FALSE);
-+ ret = gaim2_plugin_oscar_convert_to_utf8(data, datalen, charsetstr1, FALSE);
- if (ret == NULL)
-- ret = gaim_plugin_oscar_convert_to_utf8(data, datalen, charsetstr2, TRUE);
-+ ret = gaim2_plugin_oscar_convert_to_utf8(data, datalen, charsetstr2, TRUE);
- if (ret == NULL)
- ret = g_strdup(_("(There was an error receiving this message. The buddy you are speaking to most likely has a buggy client.)"));
-
-@@ -527,12 +527,12 @@ gaim_plugin_oscar_decode_im_part(GaimAcc
- * Figure out what encoding to use when sending a given outgoing message.
- */
- static void
--gaim_plugin_oscar_convert_to_best_encoding(GaimConnection *gc, const char *destsn, const gchar *from,
-+gaim2_plugin_oscar_convert_to_best_encoding(Gaim2Connection *gc, const char *destsn, const gchar *from,
- gchar **msg, int *msglen_int,
- fu16_t *charset, fu16_t *charsubset)
- {
- OscarData *od = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- GError *err = NULL;
- aim_userinfo_t *userinfo = NULL;
- const gchar *charsetstr;
-@@ -558,8 +558,8 @@ gaim_plugin_oscar_convert_to_best_encodi
-
- if ((userinfo != NULL) && (userinfo->capabilities & AIM_CAPS_ICQUTF8))
- {
-- GaimBuddy *b;
-- b = gaim_find_buddy(account, destsn);
-+ Gaim2Buddy *b;
-+ b = gaim2_find_buddy(account, destsn);
- if ((b != NULL) && (GAIM_BUDDY_IS_ONLINE(b)))
- {
- *msg = g_convert(from, strlen(from), "UCS-2BE", "UTF-8", NULL, &msglen, NULL);
-@@ -579,7 +579,7 @@ gaim_plugin_oscar_convert_to_best_encodi
- */
- charsetstr = "ISO-8859-1";
- if ((destsn != NULL) && aim_sn_is_icq(destsn))
-- charsetstr = gaim_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-+ charsetstr = gaim2_account_get_string(account, "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-
- /*
- * XXX - We need a way to only attempt to convert if we KNOW "from"
-@@ -604,10 +604,10 @@ gaim_plugin_oscar_convert_to_best_encodi
- return;
- }
-
-- gaim_debug_error("oscar", "Error converting a Unicode message: %s\n", err->message);
-+ gaim2_debug_error("oscar", "Error converting a Unicode message: %s\n", err->message);
- g_error_free(err);
-
-- gaim_debug_error("oscar", "This should NEVER happen! Sending UTF-8 text flagged as ASCII.\n");
-+ gaim2_debug_error("oscar", "This should NEVER happen! Sending UTF-8 text flagged as ASCII.\n");
- *msg = g_strdup(from);
- *msglen_int = strlen(*msg);
- *charset = AIM_CHARSET_ASCII;
-@@ -733,7 +733,7 @@ static char *oscar_icqstatus(int state)
- }
-
- static void
--oscar_string_append(GaimAccount *account, GString *str, const char *newline,
-+oscar_string_append(Gaim2Account *account, GString *str, const char *newline,
- const char *name, const char *value)
- {
- gchar *utf8;
-@@ -744,18 +744,18 @@ oscar_string_append(GaimAccount *account
- }
- }
-
--static void oscar_string_append_info(GaimConnection *gc, GString *str, const char *newline, GaimBuddy *b, aim_userinfo_t *userinfo)
-+static void oscar_string_append_info(Gaim2Connection *gc, GString *str, const char *newline, Gaim2Buddy *b, aim_userinfo_t *userinfo)
- {
- OscarData *od;
-- GaimAccount *account;
-- GaimPresence *presence = NULL;
-- GaimStatus *status = NULL;
-- GaimGroup *g = NULL;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence = NULL;
-+ Gaim2Status *status = NULL;
-+ Gaim2Group *g = NULL;
- struct buddyinfo *bi = NULL;
- char *tmp;
-
- od = gc->proto_data;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- if ((str == NULL) || (newline == NULL) || ((b == NULL) && (userinfo == NULL)))
- return;
-@@ -764,23 +764,23 @@ static void oscar_string_append_info(Gai
- userinfo = aim_locate_finduserinfo(od->sess, b->name);
-
- if (b == NULL)
-- b = gaim_find_buddy(account, userinfo->sn);
-+ b = gaim2_find_buddy(account, userinfo->sn);
-
- if (b != NULL) {
-- g = gaim_buddy_get_group(b);
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-+ g = gaim2_buddy_get_group(b);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
- }
-
- if (userinfo != NULL)
-- bi = g_hash_table_lookup(od->buddyinfo, gaim_normalize(account, userinfo->sn));
-+ bi = g_hash_table_lookup(od->buddyinfo, gaim2_normalize(account, userinfo->sn));
-
- if (b != NULL) {
-- if (gaim_presence_is_online(presence)) {
-+ if (gaim2_presence_is_online(presence)) {
- if (aim_sn_is_icq(b->name)) {
-- GaimStatus *status = gaim_presence_get_active_status(presence);
-+ Gaim2Status *status = gaim2_presence_get_active_status(presence);
- oscar_string_append(gc->account, str, newline, _("Status"),
-- gaim_status_get_name(status));
-+ gaim2_status_get_name(status));
- }
- } else {
- tmp = aim_ssi_itemlist_findparentname(od->sess->ssi.local, b->name);
-@@ -851,7 +851,7 @@ static char *extract_name(const char *na
- }
-
- static struct chat_connection *
--find_oscar_chat(GaimConnection *gc, int id)
-+find_oscar_chat(Gaim2Connection *gc, int id)
- {
- OscarData *od = (OscarData *)gc->proto_data;
- GSList *cur;
-@@ -868,7 +868,7 @@ find_oscar_chat(GaimConnection *gc, int
- }
-
- static struct chat_connection *
--find_oscar_chat_by_conn(GaimConnection *gc, aim_conn_t *conn)
-+find_oscar_chat_by_conn(Gaim2Connection *gc, aim_conn_t *conn)
- {
- OscarData *od = (OscarData *)gc->proto_data;
- GSList *cur;
-@@ -885,7 +885,7 @@ find_oscar_chat_by_conn(GaimConnection *
- }
-
- static struct chat_connection *
--find_oscar_chat_by_conv(GaimConnection *gc, GaimConversation *conv)
-+find_oscar_chat_by_conv(Gaim2Connection *gc, Gaim2Conversation *conv)
- {
- OscarData *od = (OscarData *)gc->proto_data;
- GSList *cur;
-@@ -902,17 +902,17 @@ find_oscar_chat_by_conv(GaimConnection *
- }
-
- static void
--oscar_chat_kill(GaimConnection *gc, struct chat_connection *cc)
-+oscar_chat_kill(Gaim2Connection *gc, struct chat_connection *cc)
- {
- OscarData *od = (OscarData *)gc->proto_data;
-
- /* Notify the conversation window that we've left the chat */
-- serv_got_chat_left(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(cc->conv)));
-+ serv_got_chat_left(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(cc->conv)));
-
- /* Destroy the chat_connection */
- od->oscar_chats = g_slist_remove(od->oscar_chats, cc);
- if (cc->inpa > 0)
-- gaim_input_remove(cc->inpa);
-+ gaim2_input_remove(cc->inpa);
- aim_conn_kill(od->sess, &cc->conn);
- g_free(cc->name);
- g_free(cc->show);
-@@ -939,7 +939,7 @@ static struct oscar_direct_im *oscar_dir
-
- static void oscar_direct_im_destroy(OscarData *od, struct oscar_direct_im *dim)
- {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "destroying Direct IM for %s.\n", dim->name);
-
- od->direct_ims = g_slist_remove(od->direct_ims, dim);
-@@ -948,7 +948,7 @@ static void oscar_direct_im_destroy(Osca
- return;
- }
- if (dim->watcher)
-- gaim_input_remove(dim->watcher);
-+ gaim2_input_remove(dim->watcher);
- if (dim->conn) {
- aim_conn_close(dim->conn);
- aim_conn_kill(od->sess, &dim->conn);
-@@ -959,10 +959,10 @@ static void oscar_direct_im_destroy(Osca
- /* the only difference between this and destroy is this writes a conv message */
- static void oscar_direct_im_disconnect(OscarData *od, struct oscar_direct_im *dim)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- char buf[256];
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "%s disconnected Direct IM.\n", dim->name);
-
- if (dim->connected)
-@@ -970,13 +970,13 @@ static void oscar_direct_im_disconnect(O
- else
- g_snprintf(buf, sizeof buf, _("Direct IM with %s failed"), dim->name);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, dim->name,
-- gaim_connection_get_account(dim->gc));
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, dim->name,
-+ gaim2_connection_get_account(dim->gc));
-
- if (conv) {
-- gaim_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
- } else {
-- gaim_notify_error(dim->gc, NULL, _("Direct Connect failed"), buf);
-+ gaim2_notify_error(dim->gc, NULL, _("Direct Connect failed"), buf);
- }
-
- oscar_direct_im_destroy(od, dim);
-@@ -985,9 +985,9 @@ static void oscar_direct_im_disconnect(O
- }
-
- /* oops i made two of these. this one just calls the other one. */
--static void gaim_odc_disconnect(aim_session_t *sess, aim_conn_t *conn)
-+static void gaim2_odc_disconnect(aim_session_t *sess, aim_conn_t *conn)
- {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
- struct oscar_direct_im *dim;
- char *sn;
-@@ -999,18 +999,18 @@ static void gaim_odc_disconnect(aim_sess
- }
-
- static void destroy_direct_im_request(struct ask_direct *d) {
-- gaim_debug_info("oscar", "Freeing DirectIM prompts.\n");
-+ gaim2_debug_info("oscar", "Freeing DirectIM prompts.\n");
-
- g_free(d->sn);
- g_free(d);
- }
-
--/* this is just a gaim_proxy_connect cb that sets up the rest of the cbs */
--static void oscar_odc_callback(gpointer data, gint source, GaimInputCondition condition) {
-+/* this is just a gaim2_proxy_connect cb that sets up the rest of the cbs */
-+static void oscar_odc_callback(gpointer data, gint source, Gaim2InputCondition condition) {
- struct oscar_direct_im *dim = data;
-- GaimConnection *gc = dim->gc;
-+ Gaim2Connection *gc = dim->gc;
- OscarData *od = gc->proto_data;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- char buf[256];
- struct sockaddr name;
- socklen_t name_len = 1;
-@@ -1023,7 +1023,7 @@ static void oscar_odc_callback(gpointer
- return;
- }
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- oscar_direct_im_destroy(od, dim);
- return;
- }
-@@ -1040,7 +1040,7 @@ static void oscar_odc_callback(gpointer
- memcpy(cookie, tmp, 8);
- oscar_direct_im_destroy(od, dim);
- oscar_direct_im_initiate(gc, who, cookie);
-- gaim_debug_info("oscar", "asking direct im initiator to connect to us\n");
-+ gaim2_debug_info("oscar", "asking direct im initiator to connect to us\n");
- g_free(who);
- return;
- }
-@@ -1048,15 +1048,15 @@ static void oscar_odc_callback(gpointer
-
- dim->conn->fd = source;
- aim_conn_completeconnect(od->sess, dim->conn);
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, dim->name);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, dim->name);
-
- /* This is the best way to see if we're connected or not */
- /* Is this really needed? */
- if (getpeername(source, &name, &name_len) == 0) {
- g_snprintf(buf, sizeof buf, _("Direct IM with %s established"), dim->name);
- dim->connected = TRUE;
-- gaim_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- dim->watcher = gaim_input_add(dim->conn->fd, GAIM_INPUT_READ, oscar_callback, dim->conn);
-+ gaim2_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ dim->watcher = gaim2_input_add(dim->conn->fd, GAIM_INPUT_READ, oscar_callback, dim->conn);
- } else {
- if (dim->donttryagain) {
- oscar_direct_im_disconnect(od, dim);
-@@ -1069,7 +1069,7 @@ static void oscar_odc_callback(gpointer
- memcpy(cookie, tmp, 8);
- oscar_direct_im_destroy(od, dim);
- oscar_direct_im_initiate(gc, who, cookie);
-- gaim_debug_info("oscar", "asking direct im initiator to connect to us\n");
-+ gaim2_debug_info("oscar", "asking direct im initiator to connect to us\n");
- g_free(who);
- return;
- }
-@@ -1079,26 +1079,26 @@ static void oscar_odc_callback(gpointer
- }
-
- static void accept_direct_im_request(struct ask_direct *d) {
-- GaimConnection *gc = d->gc;
-+ Gaim2Connection *gc = d->gc;
- OscarData *od;
- struct oscar_direct_im *dim;
- char *host; int port = 5190;
- int i, rc;
- char *tmp;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- destroy_direct_im_request(d);
- return;
- }
-
- od = (OscarData *)gc->proto_data;
-- gaim_debug_info("oscar", "Accepted DirectIM.\n");
-+ gaim2_debug_info("oscar", "Accepted DirectIM.\n");
-
- dim = oscar_direct_im_find(od, d->sn);
- if (dim && dim->connected) {
- destroy_direct_im_request(d); /* 40 */ /* what does that 40 mean? */
-- gaim_debug_info("oscar", "Wait, we're already connected, ignoring DirectIM.\n");
-+ gaim2_debug_info("oscar", "Wait, we're already connected, ignoring DirectIM.\n");
- return;
- }
- dim = g_new0(struct oscar_direct_im, 1);
-@@ -1115,13 +1115,13 @@ static void accept_direct_im_request(str
- }
-
- aim_conn_addhandler(od->sess, dim->conn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMINCOMING,
-- gaim_odc_incoming, 0);
-+ gaim2_odc_incoming, 0);
- aim_conn_addhandler(od->sess, dim->conn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMTYPING,
-- gaim_odc_typing, 0);
-+ gaim2_odc_typing, 0);
- aim_conn_addhandler(od->sess, dim->conn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_IMAGETRANSFER,
-- gaim_odc_update_ui, 0);
-+ gaim2_odc_update_ui, 0);
-
-- gaim_debug_info("oscar", "ip is %s.\n", d->ip);
-+ gaim2_debug_info("oscar", "ip is %s.\n", d->ip);
- for (i = 0; i < (int)strlen(d->ip); i++) {
- if (d->ip[i] == ':') {
- port = atoi(&(d->ip[i+1]));
-@@ -1131,12 +1131,12 @@ static void accept_direct_im_request(str
- host = g_strndup(d->ip, i);
- dim->conn->status |= AIM_CONN_STATUS_INPROGRESS;
- dim->gpc_pend = TRUE;
-- rc = gaim_proxy_connect(gc->account, host, port, oscar_odc_callback, dim);
-+ rc = gaim2_proxy_connect(gc->account, host, port, oscar_odc_callback, dim);
-
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, d->sn);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, d->sn);
- tmp = g_strdup_printf(_("Attempting to connect to %s at %s:%hu for Direct IM."), d->sn, host,
- port);
-- gaim_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(tmp);
-
- g_free(host);
-@@ -1155,10 +1155,10 @@ static void accept_direct_im_request(str
- /*
- * We have just established a socket with the other dude, so set up some handlers.
- */
--static int gaim_odc_initiate(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_odc_initiate(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- struct oscar_direct_im *dim;
- char buf[256];
- char *sn;
-@@ -1175,22 +1175,22 @@ static int gaim_odc_initiate(aim_session
-
- sn = g_strdup(aim_odc_getsn(newconn));
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "DirectIM: initiate success to %s\n", sn);
- dim = oscar_direct_im_find(od, sn);
-
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, sn);
-- gaim_input_remove(dim->watcher);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, sn);
-+ gaim2_input_remove(dim->watcher);
- dim->conn = newconn;
-- dim->watcher = gaim_input_add(dim->conn->fd, GAIM_INPUT_READ, oscar_callback, dim->conn);
-+ dim->watcher = gaim2_input_add(dim->conn->fd, GAIM_INPUT_READ, oscar_callback, dim->conn);
- dim->connected = TRUE;
- g_snprintf(buf, sizeof buf, _("Direct IM with %s established"), sn);
- g_free(sn);
-- gaim_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(conv, NULL, buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-
-- aim_conn_addhandler(sess, newconn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMINCOMING, gaim_odc_incoming, 0);
-- aim_conn_addhandler(sess, newconn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMTYPING, gaim_odc_typing, 0);
-- aim_conn_addhandler(sess, newconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_IMAGETRANSFER, gaim_odc_update_ui, 0);
-+ aim_conn_addhandler(sess, newconn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMINCOMING, gaim2_odc_incoming, 0);
-+ aim_conn_addhandler(sess, newconn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIMTYPING, gaim2_odc_typing, 0);
-+ aim_conn_addhandler(sess, newconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_IMAGETRANSFER, gaim2_odc_update_ui, 0);
-
- return 1;
- }
-@@ -1200,11 +1200,11 @@ static int gaim_odc_initiate(aim_session
- * update a progress bar, or to eat lots of dry cat food. Wet cat food is
- * nasty, you sicko.
- */
--static int gaim_odc_update_ui(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_odc_update_ui(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- char *sn;
- double percent;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
- struct oscar_direct_im *dim;
-
-@@ -1216,12 +1216,12 @@ static int gaim_odc_update_ui(aim_sessio
- if (!sn || !(dim = oscar_direct_im_find(od, sn)))
- return 1;
- if (dim->watcher) {
-- gaim_input_remove(dim->watcher); /* Otherwise, the callback will callback */
-+ gaim2_input_remove(dim->watcher); /* Otherwise, the callback will callback */
- /* The callback will callback? I don't get how that would happen here. */
- dim->watcher = 0;
- }
-
-- dim->watcher = gaim_input_add(dim->conn->fd, GAIM_INPUT_READ,
-+ dim->watcher = gaim2_input_add(dim->conn->fd, GAIM_INPUT_READ,
- oscar_callback, dim->conn);
-
- return 1;
-@@ -1235,7 +1235,7 @@ static int gaim_odc_update_ui(aim_sessio
- * This function rips out all the data chunks and creates an imgstore for
- * each one. In order to do this, it first goes through the IM and takes
- * out all the IMG tags. When doing so, it rewrites the original IMG tag
-- * with one compatible with the imgstore Gaim core code. For each one, we
-+ * with one compatible with the imgstore Gaim2 core code. For each one, we
- * then read in chunks of data from the end of the message and actually
- * create the img store using the given data.
- *
-@@ -1256,9 +1256,9 @@ static int gaim_odc_update_ui(aim_sessio
- * <DATA ID="2" SIZE="65978">datadatadatadata</DATA>
- * </BINARY>
- */
--static int gaim_odc_incoming(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-- GaimMessageFlags imflags = 0;
-+static int gaim2_odc_incoming(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2MessageFlags imflags = 0;
- gchar *utf8;
- GString *newmsg = g_string_new("");
- GSList *images = NULL;
-@@ -1276,21 +1276,21 @@ static int gaim_odc_incoming(aim_session
- va_end(ap);
- msgend = msg + len;
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Got DirectIM message from %s\n", sn);
-
- if (isawaymsg)
- imflags |= GAIM_MESSAGE_AUTO_RESP;
-
- /* message has a binary trailer */
-- if ((binary = gaim_strcasestr(msg, "<binary>"))) {
-+ if ((binary = gaim2_strcasestr(msg, "<binary>"))) {
- GData *attribs;
- const char *tmp, *start, *end, *last = NULL;
-
- tmp = msg;
-
- /* for each valid image tag... */
-- while (gaim_markup_find_tag("img", tmp, &start, &end, &attribs)) {
-+ while (gaim2_markup_find_tag("img", tmp, &start, &end, &attribs)) {
- const char *id, *src, *datasize;
- const char *data = NULL;
- char *tag = NULL;
-@@ -1310,14 +1310,14 @@ static int gaim_odc_incoming(aim_session
- tag = g_strdup_printf("<data id=\"%s\" size=\"%s\">", id, datasize);
-
- /* if we have a tag, find the start of the data */
-- if (tag && (data = gaim_strcasestr(binary, tag)))
-+ if (tag && (data = gaim2_strcasestr(binary, tag)))
- data += strlen(tag);
-
- g_free(tag);
-
- /* check the data is here and store it */
- if (data + (size = atoi(datasize)) <= msgend)
-- imgid = gaim_imgstore_add(data, size, src);
-+ imgid = gaim2_imgstore_add(data, size, src);
-
- /*
- * XXX - The code below contains some calls to oscar_encoding_to_utf8
-@@ -1366,7 +1366,7 @@ static int gaim_odc_incoming(aim_session
-
- /* Convert to UTF8 */
- /* (This hasn't been tested very much) */
-- utf8 = gaim_plugin_oscar_decode_im_part(gc->account, sn, encoding, 0x0000, newmsg->str, len);
-+ utf8 = gaim2_plugin_oscar_decode_im_part(gc->account, sn, encoding, 0x0000, newmsg->str, len);
- if (utf8 != NULL) {
- serv_got_im(gc, sn, utf8, imflags, time(NULL));
- g_free(utf8);
-@@ -1382,7 +1382,7 @@ static int gaim_odc_incoming(aim_session
-
- for (tmp = images; tmp != NULL; tmp = tmp->next) {
- id = GPOINTER_TO_INT(tmp->data);
-- gaim_imgstore_unref(id);
-+ gaim2_imgstore_unref(id);
- }
-
- g_slist_free(images);
-@@ -1391,11 +1391,11 @@ static int gaim_odc_incoming(aim_session
- return 1;
- }
-
--static int gaim_odc_typing(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_odc_typing(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- char *sn;
- int typing;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
-
- va_start(ap, fr);
- sn = va_arg(ap, char *);
-@@ -1404,7 +1404,7 @@ static int gaim_odc_typing(aim_session_t
-
- if (typing == 0x0002) {
- /* I had to leave this. It's just too funny. It reminds me of my sister. */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ohmigod! %s has started typing (DirectIM). He's going to send you a message! *squeal*\n", sn);
- serv_got_typing(gc, sn, 0, GAIM_TYPING);
- } else if (typing == 0x0001)
-@@ -1414,7 +1414,7 @@ static int gaim_odc_typing(aim_session_t
- return 1;
- }
-
--static int gaim_odc_send_im(aim_session_t *sess, aim_conn_t *conn, const char *message, GaimMessageFlags imflags) {
-+static int gaim2_odc_send_im(aim_session_t *sess, aim_conn_t *conn, const char *message, Gaim2MessageFlags imflags) {
- char *buf;
- size_t len;
- int ret;
-@@ -1427,8 +1427,8 @@ static int gaim_odc_send_im(aim_session_
- last = message;
-
- /* for each valid IMG tag... */
-- while (last && *last && gaim_markup_find_tag("img", last, &start, &end, &attribs)) {
-- GaimStoredImage *image = NULL;
-+ while (last && *last && gaim2_markup_find_tag("img", last, &start, &end, &attribs)) {
-+ Gaim2StoredImage *image = NULL;
- const char *id;
-
- if (start - last) {
-@@ -1437,12 +1437,12 @@ static int gaim_odc_send_im(aim_session_
-
- id = g_datalist_get_data(&attribs, "id");
-
-- /* ... if it refers to a valid gaim image ... */
-- if (id && (image = gaim_imgstore_get(atoi(id)))) {
-+ /* ... if it refers to a valid gaim2 image ... */
-+ if (id && (image = gaim2_imgstore_get(atoi(id)))) {
- /* ... append the message from start to the tag ... */
-- unsigned long size = gaim_imgstore_get_size(image);
-- const char *filename = gaim_imgstore_get_filename(image);
-- gpointer imgdata = gaim_imgstore_get_data(image);
-+ unsigned long size = gaim2_imgstore_get_size(image);
-+ const char *filename = gaim2_imgstore_get_filename(image);
-+ gpointer imgdata = gaim2_imgstore_get_data(image);
-
- oscar_id++;
-
-@@ -1499,7 +1499,7 @@ static int gaim_odc_send_im(aim_session_
-
- struct ask_do_dir_im {
- char *who;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- };
-
- static void oscar_cancel_direct_im(struct ask_do_dir_im *data) {
-@@ -1517,7 +1517,7 @@ static void oscar_cancel_direct_im(struc
- *
- * note that cookie is an 8 byte string that isn't NULL terminated
- */
--static void oscar_direct_im_initiate(GaimConnection *gc, const char *who, const guchar *cookie) {
-+static void oscar_direct_im_initiate(Gaim2Connection *gc, const char *who, const guchar *cookie) {
- OscarData *od;
- struct oscar_direct_im *dim;
- int listenfd;
-@@ -1529,10 +1529,10 @@ static void oscar_direct_im_initiate(Gai
- if (dim) {
- if (!(dim->connected)) { /* We'll free the old, unconnected dim, and start over */
- oscar_direct_im_disconnect(od, dim);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Gave up on old direct IM, trying again\n");
- } else {
-- gaim_notify_error(gc, NULL, "DirectIM already open.", NULL);
-+ gaim2_notify_error(gc, NULL, "DirectIM already open.", NULL);
- return;
- }
- }
-@@ -1540,35 +1540,35 @@ static void oscar_direct_im_initiate(Gai
- dim->gc = gc;
- g_snprintf(dim->name, sizeof dim->name, "%s", who);
-
-- listenfd = gaim_network_listen_range(5190, 5199, SOCK_STREAM);
-- ip = gaim_network_get_my_ip(od->conn ? od->conn->fd : -1);
-+ listenfd = gaim2_network_listen_range(5190, 5199, SOCK_STREAM);
-+ ip = gaim2_network_get_my_ip(od->conn ? od->conn->fd : -1);
- if (listenfd >= 0)
-- dim->conn = aim_odc_initiate(od->sess, who, listenfd, gaim_network_ip_atoi(ip), gaim_network_get_port_from_fd(listenfd), cookie);
-+ dim->conn = aim_odc_initiate(od->sess, who, listenfd, gaim2_network_ip_atoi(ip), gaim2_network_get_port_from_fd(listenfd), cookie);
- if (dim->conn != NULL) {
- char *tmp;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- od->direct_ims = g_slist_append(od->direct_ims, dim);
-- dim->watcher = gaim_input_add(dim->conn->fd, GAIM_INPUT_READ,
-+ dim->watcher = gaim2_input_add(dim->conn->fd, GAIM_INPUT_READ,
- oscar_callback, dim->conn);
- aim_conn_addhandler(od->sess, dim->conn, AIM_CB_FAM_OFT, AIM_CB_OFT_DIRECTIM_ESTABLISHED,
-- gaim_odc_initiate, 0);
-+ gaim2_odc_initiate, 0);
-
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, who);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, dim->gc->account, who);
- tmp = g_strdup_printf(_("Asking %s to connect to us at %s:%hu for Direct IM."), who, ip,
-- gaim_network_get_port_from_fd(listenfd));
-- gaim_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_network_get_port_from_fd(listenfd));
-+ gaim2_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(tmp);
- } else {
-- gaim_notify_error(gc, NULL, _("Unable to open Direct IM"), NULL);
-+ gaim2_notify_error(gc, NULL, _("Unable to open Direct IM"), NULL);
- oscar_direct_im_destroy(od, dim);
- }
- }
-
- static void oscar_direct_im(struct ask_do_dir_im *data) {
-- GaimConnection *gc = data->gc;
-+ Gaim2Connection *gc = data->gc;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- g_free(data->who);
- g_free(data);
- return;
-@@ -1580,17 +1580,17 @@ static void oscar_direct_im(struct ask_d
- }
-
- /* this is the right click menu cb thingy */
--static void oscar_ask_direct_im(GaimBlistNode *node, gpointer ignored) {
-+static void oscar_ask_direct_im(Gaim2BlistNode *node, gpointer ignored) {
-
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- gchar *buf;
- struct ask_do_dir_im *data;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- data = g_new0(struct ask_do_dir_im, 1);
- data->who = g_strdup(buddy->name);
-@@ -1598,7 +1598,7 @@ static void oscar_ask_direct_im(GaimBlis
- buf = g_strdup_printf(_("You have selected to open a Direct IM connection with %s."),
- buddy->name);
-
-- gaim_request_action(gc, NULL, buf,
-+ gaim2_request_action(gc, NULL, buf,
- _("Because this reveals your IP address, it "
- "may be considered a privacy risk. Do you "
- "wish to continue?"),
-@@ -1612,78 +1612,78 @@ static void oscar_ask_direct_im(GaimBlis
- * End scary direct im stuff
- *****************************************************************************/
-
--static void oscar_callback(gpointer data, gint source, GaimInputCondition condition) {
-+static void oscar_callback(gpointer data, gint source, Gaim2InputCondition condition) {
- aim_conn_t *conn = (aim_conn_t *)data;
- aim_session_t *sess = aim_conn_getsess(conn);
-- GaimConnection *gc = sess ? sess->aux_data : NULL;
-+ Gaim2Connection *gc = sess ? sess->aux_data : NULL;
- OscarData *od;
-
- if (!gc) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "oscar callback for closed connection (1).\n");
- return;
- }
-
- if( !(od = (OscarData *)gc->proto_data) ) {
-- gaim_debug_warning("oscar","NULL od in oscar_callback; conn closed?\n");
-+ gaim2_debug_warning("oscar","NULL od in oscar_callback; conn closed?\n");
- return;
- }
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- /* oh boy. this is probably bad. i guess the only thing we
- * can really do is return? */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "oscar callback for closed connection (2).\n");
-- gaim_debug_misc("oscar", "gc = %p\n", gc);
-+ gaim2_debug_misc("oscar", "gc = %p\n", gc);
- return;
- }
-
- if (condition & GAIM_INPUT_READ) {
- if (conn->type == AIM_CONN_TYPE_LISTENER) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "got information on rendezvous listener\n");
- if (aim_handlerendconnect(od->sess, conn) < 0) {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "connection error (rendezvous listener)\n");
- aim_conn_kill(od->sess, &conn);
-- /* AAA - Don't we need to gaim_xfer_cancel here? --marv */
-+ /* AAA - Don't we need to gaim2_xfer_cancel here? --marv */
- }
- } else {
- if (aim_get_command(od->sess, conn) >= 0) {
- aim_rxdispatch(od->sess);
- if (od->killme) {
-- gaim_debug_error("oscar", "Waiting to be destroyed\n");
-+ gaim2_debug_error("oscar", "Waiting to be destroyed\n");
- return;
- }
- } else {
- if ((conn->type == AIM_CONN_TYPE_BOS) ||
- !(aim_getconn_type(od->sess, AIM_CONN_TYPE_BOS)))
- {
-- gaim_debug_error("oscar", "Major connection error "
-+ gaim2_debug_error("oscar", "Major connection error "
- "(invalid data was received on the oscar TCP stream).\n");
-- gaim_connection_error(gc, _("Disconnected."));
-+ gaim2_connection_error(gc, _("Disconnected."));
- } else if (conn->type == AIM_CONN_TYPE_CHAT) {
- struct chat_connection *cc = find_oscar_chat_by_conn(gc, conn);
-- GaimConversation *conv = gaim_find_chat(gc, cc->id);
-+ Gaim2Conversation *conv = gaim2_find_chat(gc, cc->id);
- char *buf;
-- gaim_debug_info("oscar", "Lost connection "
-+ gaim2_debug_info("oscar", "Lost connection "
- "to chat room %s\n", cc->name);
-
- buf = g_strdup_printf(_("You have lost your connection "
- "to chat room %s."), cc->name);
- if (conv != NULL)
-- gaim_conversation_write(conv, NULL, buf, GAIM_MESSAGE_ERROR, time(NULL));
-+ gaim2_conversation_write(conv, NULL, buf, GAIM_MESSAGE_ERROR, time(NULL));
- else
-- gaim_notify_error(gc, NULL, buf, NULL);
-+ gaim2_notify_error(gc, NULL, buf, NULL);
- g_free(buf);
-
- oscar_chat_kill(gc, cc);
-
- } else if (conn->type == AIM_CONN_TYPE_CHATNAV) {
- if (od->cnpa > 0)
-- gaim_input_remove(od->cnpa);
-+ gaim2_input_remove(od->cnpa);
- od->cnpa = 0;
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "removing chatnav input watcher\n");
- while (od->create_rooms) {
- struct create_room *cr = od->create_rooms->data;
-@@ -1691,40 +1691,40 @@ static void oscar_callback(gpointer data
- od->create_rooms =
- g_slist_remove(od->create_rooms, cr);
- g_free(cr);
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Chat is currently unavailable"),
- NULL);
- }
-- gaim_debug_info("oscar","killing rendezvous connection\n");
-+ gaim2_debug_info("oscar","killing rendezvous connection\n");
- aim_conn_kill(od->sess, &conn);
- } else if (conn->type == AIM_CONN_TYPE_AUTH) {
- if (od->paspa > 0)
-- gaim_input_remove(od->paspa);
-+ gaim2_input_remove(od->paspa);
- od->paspa = 0;
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "removing authconn input watcher\n");
- aim_conn_kill(od->sess, &conn);
- } else if (conn->type == AIM_CONN_TYPE_EMAIL) {
- if (od->emlpa > 0)
-- gaim_input_remove(od->emlpa);
-+ gaim2_input_remove(od->emlpa);
- od->emlpa = 0;
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "removing email input watcher\n");
- aim_conn_kill(od->sess, &conn);
- } else if (conn->type == AIM_CONN_TYPE_ICON) {
- if (od->icopa > 0)
-- gaim_input_remove(od->icopa);
-+ gaim2_input_remove(od->icopa);
- od->icopa = 0;
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "removing icon input watcher\n");
- aim_conn_kill(od->sess, &conn);
- } else if (conn->type == AIM_CONN_TYPE_RENDEZVOUS) {
- if (conn->subtype == AIM_CONN_SUBTYPE_OFT_DIRECTIM)
-- gaim_odc_disconnect(od->sess, conn);
-- gaim_debug_info("oscar","killing rendezvous connection\n");
-+ gaim2_odc_disconnect(od->sess, conn);
-+ gaim2_debug_info("oscar","killing rendezvous connection\n");
- aim_conn_kill(od->sess, &conn);
- } else {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "holy crap! generic connection error! %hu\n",
- conn->type);
- aim_conn_kill(od->sess, &conn);
-@@ -1734,14 +1734,14 @@ static void oscar_callback(gpointer data
- }
- }
-
--static void oscar_login_connect(gpointer data, gint source, GaimInputCondition cond)
-+static void oscar_login_connect(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *conn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -1752,38 +1752,38 @@ static void oscar_login_connect(gpointer
- conn->fd = source;
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Couldn't connect to host"));
-+ gaim2_connection_error(gc, _("Couldn't connect to host"));
- return;
- }
-
- aim_conn_completeconnect(sess, conn);
-- gc->inpa = gaim_input_add(conn->fd, GAIM_INPUT_READ, oscar_callback, conn);
-- aim_request_login(sess, conn, gaim_account_get_username(gaim_connection_get_account(gc)));
-+ gc->inpa = gaim2_input_add(conn->fd, GAIM_INPUT_READ, oscar_callback, conn);
-+ aim_request_login(sess, conn, gaim2_account_get_username(gaim2_connection_get_account(gc)));
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Screen name sent, waiting for response\n");
-- gaim_connection_update_progress(gc, _("Screen name sent"), 1, OSCAR_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Screen name sent"), 1, OSCAR_CONNECT_STEPS);
- ck[1] = 0x65;
- }
-
- static void
--oscar_login(GaimAccount *account)
-+oscar_login(Gaim2Account *account)
- {
- aim_session_t *sess;
- aim_conn_t *conn;
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- OscarData *od = gc->proto_data = g_new0(OscarData, 1);
-
-- gaim_debug_misc("oscar", "oscar_login: gc = %p\n", gc);
-+ gaim2_debug_misc("oscar", "oscar_login: gc = %p\n", gc);
-
-- if (!aim_snvalid(gaim_account_get_username(account))) {
-+ if (!aim_snvalid(gaim2_account_get_username(account))) {
- gchar *buf;
-- buf = g_strdup_printf(_("Unable to login: Could not sign on as %s because the screen name is invalid. Screen names must either start with a letter and contain only letters, numbers and spaces, or contain only numbers."), gaim_account_get_username(account));
-- gaim_connection_error(gc, buf);
-+ buf = g_strdup_printf(_("Unable to login: Could not sign on as %s because the screen name is invalid. Screen names must either start with a letter and contain only letters, numbers and spaces, or contain only numbers."), gaim2_account_get_username(account));
-+ gaim2_connection_error(gc, buf);
- g_free(buf);
- }
-
-- if (aim_sn_is_icq((gaim_account_get_username(account)))) {
-+ if (aim_sn_is_icq((gaim2_account_get_username(account)))) {
- od->icq = TRUE;
- } else {
- gc->flags |= GAIM_CONNECTION_HTML;
-@@ -1801,40 +1801,40 @@ oscar_login(GaimAccount *account)
- od->sess = sess;
- sess->aux_data = gc;
-
-- /* Connect to core Gaim signals */
-- gaim_prefs_connect_callback(gc, "/plugins/prpl/oscar/recent_buddies", recent_buddies_cb, gc);
-+ /* Connect to core Gaim2 signals */
-+ gaim2_prefs_connect_callback(gc, "/plugins/prpl/oscar/recent_buddies", recent_buddies_cb, gc);
-
- conn = aim_newconn(sess, AIM_CONN_TYPE_AUTH);
- if (conn == NULL) {
-- gaim_debug_error("oscar", "internal connection error\n");
-- gaim_connection_error(gc, _("Unable to login to AIM"));
-+ gaim2_debug_error("oscar", "internal connection error\n");
-+ gaim2_connection_error(gc, _("Unable to login to AIM"));
- return;
- }
-
-- aim_conn_addhandler(sess, conn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-- aim_conn_addhandler(sess, conn, 0x0017, 0x0003, gaim_parse_auth_resp, 0);
-- aim_conn_addhandler(sess, conn, 0x0017, 0x0007, gaim_parse_login, 0);
-- aim_conn_addhandler(sess, conn, AIM_CB_FAM_ATH, AIM_CB_ATH_SECURID_REQUEST, gaim_parse_auth_securid_request, 0);
-+ aim_conn_addhandler(sess, conn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
-+ aim_conn_addhandler(sess, conn, 0x0017, 0x0003, gaim2_parse_auth_resp, 0);
-+ aim_conn_addhandler(sess, conn, 0x0017, 0x0007, gaim2_parse_login, 0);
-+ aim_conn_addhandler(sess, conn, AIM_CB_FAM_ATH, AIM_CB_ATH_SECURID_REQUEST, gaim2_parse_auth_securid_request, 0);
-
- conn->status |= AIM_CONN_STATUS_INPROGRESS;
-- if (gaim_proxy_connect(account, gaim_account_get_string(account, "server", OSCAR_DEFAULT_LOGIN_SERVER),
-- gaim_account_get_int(account, "port", OSCAR_DEFAULT_LOGIN_PORT),
-+ if (gaim2_proxy_connect(account, gaim2_account_get_string(account, "server", OSCAR_DEFAULT_LOGIN_SERVER),
-+ gaim2_account_get_int(account, "port", OSCAR_DEFAULT_LOGIN_PORT),
- oscar_login_connect, gc) < 0) {
-- gaim_connection_error(gc, _("Couldn't connect to host"));
-+ gaim2_connection_error(gc, _("Couldn't connect to host"));
- return;
- }
-
-- gaim_connection_update_progress(gc, _("Connecting"), 0, OSCAR_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 0, OSCAR_CONNECT_STEPS);
- ck[0] = 0x5a;
- }
-
--static void oscar_close(GaimConnection *gc) {
-+static void oscar_close(Gaim2Connection *gc) {
- OscarData *od = (OscarData *)gc->proto_data;
-
- while (od->oscar_chats) {
- struct chat_connection *n = od->oscar_chats->data;
- if (n->inpa > 0)
-- gaim_input_remove(n->inpa);
-+ gaim2_input_remove(n->inpa);
- g_free(n->name);
- g_free(n->show);
- od->oscar_chats = g_slist_remove(od->oscar_chats, n);
-@@ -1846,9 +1846,9 @@ static void oscar_close(GaimConnection *
- }
- /* BBB */
- while (od->file_transfers) {
-- GaimXfer *xfer;
-- xfer = (GaimXfer *)od->file_transfers->data;
-- gaim_xfer_cancel_local(xfer);
-+ Gaim2Xfer *xfer;
-+ xfer = (Gaim2Xfer *)od->file_transfers->data;
-+ gaim2_xfer_cancel_local(xfer);
- }
- while (od->requesticon) {
- char *sn = od->requesticon->data;
-@@ -1869,38 +1869,38 @@ static void oscar_close(GaimConnection *
- if (od->oldp)
- g_free(od->oldp);
- if (gc->inpa > 0)
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
- if (od->cnpa > 0)
-- gaim_input_remove(od->cnpa);
-+ gaim2_input_remove(od->cnpa);
- if (od->paspa > 0)
-- gaim_input_remove(od->paspa);
-+ gaim2_input_remove(od->paspa);
- if (od->emlpa > 0)
-- gaim_input_remove(od->emlpa);
-+ gaim2_input_remove(od->emlpa);
- if (od->icopa > 0)
-- gaim_input_remove(od->icopa);
-+ gaim2_input_remove(od->icopa);
- if (od->icontimer > 0)
-- gaim_timeout_remove(od->icontimer);
-+ gaim2_timeout_remove(od->icontimer);
- if (od->getblisttimer > 0)
-- gaim_timeout_remove(od->getblisttimer);
-+ gaim2_timeout_remove(od->getblisttimer);
- if (od->getinfotimer > 0)
-- gaim_timeout_remove(od->getinfotimer);
-- gaim_prefs_disconnect_by_handle(gc);
-+ gaim2_timeout_remove(od->getinfotimer);
-+ gaim2_prefs_disconnect_by_handle(gc);
-
- aim_session_kill(od->sess);
- g_free(od->sess);
- od->sess = NULL;
- g_free(gc->proto_data);
- gc->proto_data = NULL;
-- gaim_debug_info("oscar", "Signed off.\n");
-+ gaim2_debug_info("oscar", "Signed off.\n");
- }
-
--static void oscar_bos_connect(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void oscar_bos_connect(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *bosconn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -1911,14 +1911,14 @@ static void oscar_bos_connect(gpointer d
- bosconn->fd = source;
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Could Not Connect"));
-+ gaim2_connection_error(gc, _("Could Not Connect"));
- return;
- }
-
- aim_conn_completeconnect(sess, bosconn);
-- gc->inpa = gaim_input_add(bosconn->fd, GAIM_INPUT_READ, oscar_callback, bosconn);
-+ gc->inpa = gaim2_input_add(bosconn->fd, GAIM_INPUT_READ, oscar_callback, bosconn);
-
-- gaim_connection_update_progress(gc,
-+ gaim2_connection_update_progress(gc,
- _("Connection established, cookie sent"), 4, OSCAR_CONNECT_STEPS);
- ck[4] = 0x61;
- }
-@@ -1930,7 +1930,7 @@ static void oscar_bos_connect(gpointer d
- * ninja.
- *
- * The series of events for a file send is:
-- * -Create xfer and call gaim_xfer_request (this happens in oscar_ask_sendfile)
-+ * -Create xfer and call gaim2_xfer_request (this happens in oscar_ask_sendfile)
- * -User chooses a file and oscar_xfer_init is called. It establishes a
- * listening socket, then asks the remote user to connect to us (and
- * gives them the file name, port, IP, etc.)
-@@ -1942,8 +1942,8 @@ static void oscar_bos_connect(gpointer d
- * -We get drunk because file transfer kicks ass.
- *
- * The series of events for a file receive is:
-- * -Create xfer and call gaim_xfer request (this happens in incomingim_chan2)
-- * -Gaim user selects file to name and location to save file to and
-+ * -Create xfer and call gaim2_xfer request (this happens in incomingim_chan2)
-+ * -Gaim2 user selects file to name and location to save file to and
- * oscar_xfer_init is called
- * -It connects to the remote user using the IP they gave us earlier
- * -After connecting, they send us an AIM_CB_OFT_PROMPT. In reply, we send
-@@ -1959,16 +1959,16 @@ static void oscar_bos_connect(gpointer d
- * a better idea of what happens, take a look at the diagrams and documentation
- * from my Summer of Code project. -- Jonathan Clark
- */
--static void oscar_sendfile_connected(gpointer data, gint source, GaimInputCondition condition);
--static void oscar_xfer_proxylogin(gpointer data, gint source, GaimInputCondition condition);
--static void oscar_send_file_request(GaimXfer *xfer);
-+static void oscar_sendfile_connected(gpointer data, gint source, Gaim2InputCondition condition);
-+static void oscar_xfer_proxylogin(gpointer data, gint source, Gaim2InputCondition condition);
-+static void oscar_send_file_request(Gaim2Xfer *xfer);
-
- /*
- * Miscellaneous xfer functions
- */
--static GaimXfer *oscar_find_xfer_by_cookie(GSList *fts, const fu8_t *ck)
-+static Gaim2Xfer *oscar_find_xfer_by_cookie(GSList *fts, const fu8_t *ck)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
-
- while (fts) {
-@@ -1984,9 +1984,9 @@ static GaimXfer *oscar_find_xfer_by_cook
- return NULL;
- }
-
--static GaimXfer *oscar_find_xfer_by_conn(GSList *fts, aim_conn_t *conn)
-+static Gaim2Xfer *oscar_find_xfer_by_conn(GSList *fts, aim_conn_t *conn)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
-
- while (fts) {
-@@ -2007,16 +2007,16 @@ static GaimXfer *oscar_find_xfer_by_conn
- * If we're the receiver, send an OFT header with the bytes received
- * filled in to indicate this party's over.
- */
--static void oscar_xfer_end(GaimXfer *xfer)
-+static void oscar_xfer_end(Gaim2Xfer *xfer)
- {
- struct aim_oft_info *oft_info = xfer->data;
-- GaimConnection *gc = oft_info->sess->aux_data;
-+ Gaim2Connection *gc = oft_info->sess->aux_data;
- OscarData *od = gc->proto_data;
-
-- gaim_debug_info("oscar", "AAA - in oscar_xfer_end\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_xfer_end\n");
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-- oft_info->fh.nrecvd = gaim_xfer_get_bytes_sent(xfer);
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_RECEIVE) {
-+ oft_info->fh.nrecvd = gaim2_xfer_get_bytes_sent(xfer);
- aim_oft_sendheader(oft_info->sess, AIM_CB_OFT_DONE, oft_info);
- }
-
-@@ -2031,7 +2031,7 @@ static void oscar_xfer_end(GaimXfer *xfe
- */
-
- /*
-- * This is a gaim timeout callback called X milliseconds after a connection is attempted
-+ * This is a gaim2 timeout callback called X milliseconds after a connection is attempted
- * By this point, we've lost faith in the connection method we just tried and want to
- * try something new. Hopefully, that new connection method will be more successful,
- * otherwise, we'll end up here again and again until the connection is successful
-@@ -2039,13 +2039,13 @@ static void oscar_xfer_end(GaimXfer *xfe
- * and inform the user of his bad karma.
- */
- static gboolean oscar_xfer_ip_timeout(gpointer data) {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
- char *msg = NULL;
-
-- gaim_debug_info("oscar","AAA - in oscar_xfer_ip_timeout\n");
-+ gaim2_debug_info("oscar","AAA - in oscar_xfer_ip_timeout\n");
-
-- xfer = (GaimXfer*) data;
-+ xfer = (Gaim2Xfer*) data;
- if(xfer->data) {
- oft_info = (struct aim_oft_info*) xfer->data;
-
-@@ -2072,24 +2072,24 @@ static gboolean oscar_xfer_ip_timeout(gp
-
- /* Let the user not to lose hope quite yet*/
- msg = g_strdup_printf(_("Attempting connection redirect..."));
-- gaim_xfer_conversation_write(xfer, msg, FALSE);
-+ gaim2_xfer_conversation_write(xfer, msg, FALSE);
- g_free(msg);
-
-- gaim_timeout_add(FT_REDIR_TIMEOUT,
-+ gaim2_timeout_add(FT_REDIR_TIMEOUT,
- oscar_xfer_ip_timeout, xfer);
- oft_info->method = AIM_XFER_REDIR;
- g_free(oft_info->proxyip);
- oft_info->proxyip = NULL;
-- oft_info->clientip = g_strdup( gaim_network_get_my_ip(
-+ oft_info->clientip = g_strdup( gaim2_network_get_my_ip(
- oft_info->conn ? oft_info->conn->fd : -1));
- oscar_xfer_init_send(xfer);
- } else {
- /* clientip, verifiedip, and redirect all failed. */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "redirect timed out. requesting stg3 proxy\n");
-
- /* Kill our listener */
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- aim_conn_kill(oft_info->sess, &oft_info->conn);
-
- /* Instead of failing here, request a stage 3 proxy */
-@@ -2108,7 +2108,7 @@ static gboolean oscar_xfer_ip_timeout(gp
- /* clientip timed out, now try verifiedip */
- g_free(xfer->remote_ip);
- xfer->remote_ip = g_strdup(oft_info->verifiedip);
-- gaim_debug_info("oscar","attempting connection using verifiedip\n");
-+ gaim2_debug_info("oscar","attempting connection using verifiedip\n");
- oscar_xfer_init_recv(xfer);
- }
- } else if(oft_info->method == AIM_XFER_PROXY) {
-@@ -2117,26 +2117,26 @@ static gboolean oscar_xfer_ip_timeout(gp
- * when it's a proxied transfer that timed out. It is possible that a
- * stage 1/2 proxied transfer might work when a stage 3 will not. */
- msg = g_strdup_printf(_("Transfer of file %s timed out.\n Try enabling proxy servers for file transfers in Tools->Preferences->AIM/ICQ."),
-- gaim_xfer_get_filename(xfer));
-- gaim_xfer_conversation_write(xfer, msg, TRUE);
-+ gaim2_xfer_get_filename(xfer));
-+ gaim2_xfer_conversation_write(xfer, msg, TRUE);
- g_free(msg);
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- if(oft_info->xfer_reffed) {
- oft_info->xfer_reffed = FALSE;
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
- } else {
-- gaim_debug_warning("oscar","unknown xfer method encountered in timout\n");
-+ gaim2_debug_warning("oscar","unknown xfer method encountered in timout\n");
- }
- } else {
- if(oft_info->xfer_reffed) {
- oft_info->xfer_reffed = FALSE;
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- }
-- gaim_debug_info("oscar","connection successful; timeout off\n");
-+ gaim2_debug_info("oscar","connection successful; timeout off\n");
- }
- } else {
-- gaim_debug_info("oscar","transfer already done; nothing to do\n");
-+ gaim2_debug_info("oscar","transfer already done; nothing to do\n");
- }
- return FALSE;
- }
-@@ -2144,15 +2144,15 @@ static gboolean oscar_xfer_ip_timeout(gp
- /*
- * Connect to another client or a file transfer proxy server.
- * Though this function has traditionally only been used during file receives,
-- * it is now called to make any sort of file transfer connection via gaim_proxy_connect.
-+ * it is now called to make any sort of file transfer connection via gaim2_proxy_connect.
- */
--static void oscar_xfer_init_recv(GaimXfer *xfer)
-+static void oscar_xfer_init_recv(Gaim2Xfer *xfer)
- {
- struct aim_oft_info *oft_info;
- struct aim_rv_proxy_info *proxy_info;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- OscarData *od;
-- GaimInputFunction nextstop_cb;
-+ Gaim2InputFunction nextstop_cb;
- int rc;
-
- g_return_if_fail(xfer != NULL);
-@@ -2163,7 +2163,7 @@ static void oscar_xfer_init_recv(GaimXfe
- gc = oft_info->sess->aux_data;
- od = gc->proto_data;
-
-- gaim_debug_info("oscar", "AAA - in oscar_xfer_init_recv\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_xfer_init_recv\n");
-
- /* Start a timer for this ip address
- * If the clientip fails, try the verifiedip
-@@ -2171,7 +2171,7 @@ static void oscar_xfer_init_recv(GaimXfe
- * This xfer reference will be released in oscar_xfer_ip_timeout */
- if(!oft_info->xfer_reffed) {
- oft_info->xfer_reffed = TRUE;
-- gaim_xfer_ref(xfer);
-+ gaim2_xfer_ref(xfer);
- }
-
- if(oft_info->method != AIM_XFER_PROXY) {
-@@ -2180,25 +2180,25 @@ static void oscar_xfer_init_recv(GaimXfe
- if(xfer->remote_ip && oft_info->verifiedip
- && g_ascii_strcasecmp(xfer->remote_ip, oft_info->verifiedip) == 0
- && g_ascii_strcasecmp(oft_info->clientip, oft_info->verifiedip) != 0 ) {
-- gaim_timeout_add(FT_VERIFIEDIP_TIMEOUT, oscar_xfer_ip_timeout, xfer);
-+ gaim2_timeout_add(FT_VERIFIEDIP_TIMEOUT, oscar_xfer_ip_timeout, xfer);
- } else {
-- gaim_timeout_add(FT_CLIENTIP_TIMEOUT, oscar_xfer_ip_timeout, xfer);
-+ gaim2_timeout_add(FT_CLIENTIP_TIMEOUT, oscar_xfer_ip_timeout, xfer);
- }
- } else {
-- gaim_timeout_add(FT_PROXYIP_TIMEOUT, oscar_xfer_ip_timeout, xfer);
-+ gaim2_timeout_add(FT_PROXYIP_TIMEOUT, oscar_xfer_ip_timeout, xfer);
- }
- oft_info->conn = aim_newconn(od->sess, AIM_CONN_TYPE_RENDEZVOUS);
-
- /* If we're routing this transfer through a AOL proxy server, do the special login
- * before telling the other client we're ready for action.
-- * Note, firststop_cb is the first function called after gaim has made a connection
-+ * Note, firststop_cb is the first function called after gaim2 has made a connection
- * Also, the connection type is changed until the proxy login is complete */
- if(oft_info->method == AIM_XFER_PROXY) {
- if(proxy_info)
- proxy_info->conn = oft_info->conn;
- else {
-- gaim_debug_warning("oscar","NULL proxy_info\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL proxy_info\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
- nextstop_cb = oscar_xfer_proxylogin;
- oft_info->conn->type = AIM_CONN_TYPE_RENDEZVOUS_PROXY;
-@@ -2210,33 +2210,33 @@ static void oscar_xfer_init_recv(GaimXfe
- oft_info->conn->subtype = AIM_CONN_SUBTYPE_OFT_SENDFILE;
- aim_conn_addhandler(od->sess, oft_info->conn, AIM_CB_FAM_OFT, AIM_CB_OFT_PROMPT,
- oscar_sendfile_prompt, 0);
-- rc = gaim_proxy_connect(gaim_connection_get_account(gc),
-+ rc = gaim2_proxy_connect(gaim2_connection_get_account(gc),
- xfer->remote_ip, xfer->remote_port, nextstop_cb, xfer);
- if (rc == -1) {
-- gaim_xfer_error(GAIM_XFER_RECEIVE, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_RECEIVE, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to establish file descriptor."));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else {
-- gaim_xfer_error(GAIM_XFER_RECEIVE, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_RECEIVE, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to create new connection."));
-- gaim_xfer_cancel_local(xfer);
-- /* Try a different port? Ask them to connect to us? /join #gaim and whine? */
-+ gaim2_xfer_cancel_local(xfer);
-+ /* Try a different port? Ask them to connect to us? /join #gaim2 and whine? */
- }
- }
-
- /*
- * "Never mind. This transfer wasn't such a great idea after all."
- */
--static void oscar_xfer_cancel_recv(GaimXfer *xfer)
-+static void oscar_xfer_cancel_recv(Gaim2Xfer *xfer)
- {
- struct aim_oft_info *oft_info = xfer->data;
-- GaimConnection *gc = oft_info->sess->aux_data;
-+ Gaim2Connection *gc = oft_info->sess->aux_data;
- OscarData *od = gc->proto_data;
-
-- gaim_debug_info("oscar", "AAA - in oscar_xfer_cancel_recv\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_xfer_cancel_recv\n");
-
-- if (gaim_xfer_get_status(xfer) != GAIM_XFER_STATUS_CANCEL_REMOTE)
-+ if (gaim2_xfer_get_status(xfer) != GAIM_XFER_STATUS_CANCEL_REMOTE)
- aim_im_sendch2_sendfile_cancel(oft_info->sess, oft_info);
-
- aim_conn_kill(oft_info->sess, &oft_info->conn);
-@@ -2248,7 +2248,7 @@ static void oscar_xfer_cancel_recv(GaimX
- /*
- * Called after every data packet we receive
- */
--static void oscar_xfer_ack_recv(GaimXfer *xfer, const guchar *buffer, size_t size)
-+static void oscar_xfer_ack_recv(Gaim2Xfer *xfer, const guchar *buffer, size_t size)
- {
- struct aim_oft_info *oft_info = xfer->data;
-
-@@ -2264,24 +2264,24 @@ static void oscar_xfer_ack_recv(GaimXfer
- * Called by oscar_send_proxylogin_cb when we receive a ready packet
- * BBB
- */
--static void oscar_xfer_proxylogin_ready(GaimXfer *xfer, gint fd) {
-+static void oscar_xfer_proxylogin_ready(Gaim2Xfer *xfer, gint fd) {
- struct aim_oft_info *oft_info;
- struct aim_rv_proxy_info *proxy_info;
-
-- gaim_debug_info("oscar","AAA - in oscar_xfer_proxylogin_ready\n");
-+ gaim2_debug_info("oscar","AAA - in oscar_xfer_proxylogin_ready\n");
- if (!(oft_info = xfer->data)) {
-- gaim_debug_warning("oscar","NULL oft_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL oft_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
- if (!(proxy_info = oft_info->proxy_info)) {
-- gaim_debug_warning("oscar","NULL proxy_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL proxy_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-
- /* Remove the rv proxy watcher and put the connection type back the way we found it */
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- oft_info->conn->type = AIM_CONN_TYPE_RENDEZVOUS;
-
-@@ -2299,7 +2299,7 @@ static void oscar_xfer_proxylogin_ready(
- oscar_sendfile_ack, 0);
- aim_conn_addhandler(oft_info->sess, oft_info->conn, AIM_CB_FAM_OFT, AIM_CB_OFT_DONE,
- oscar_sendfile_done, 0);
-- xfer->watcher = gaim_input_add(oft_info->conn->fd, GAIM_INPUT_READ, oscar_callback,
-+ xfer->watcher = gaim2_input_add(oft_info->conn->fd, GAIM_INPUT_READ, oscar_callback,
- oft_info->conn);
-
- /* Inform the other user that we are connected and ready to transfer */
-@@ -2307,8 +2307,8 @@ static void oscar_xfer_proxylogin_ready(
- } else if(oft_info->send_or_recv == AIM_XFER_RECV) {
- oscar_sendfile_connected(xfer, fd, GAIM_INPUT_READ);
- } else {
-- gaim_debug_warning("oscar","no value for send_or_recv; aborting transfer\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","no value for send_or_recv; aborting transfer\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
- }
-
-@@ -2316,26 +2316,26 @@ static void oscar_xfer_proxylogin_ready(
- * Called by oscar_sendfile_proxylogin_cb when we receive an ack packet in reply to an init_send
- * BBB
- */
--static void oscar_xfer_proxylogin_ack(GaimXfer *xfer) {
-+static void oscar_xfer_proxylogin_ack(Gaim2Xfer *xfer) {
- struct aim_oft_info *oft_info;
- struct aim_rv_proxy_info *proxy_info;
-
-- gaim_debug_info("oscar","AAA - in oscar_xfer_proxylogin_ack\n");
-+ gaim2_debug_info("oscar","AAA - in oscar_xfer_proxylogin_ack\n");
- if (!(oft_info = xfer->data)) {
-- gaim_debug_warning("oscar","NULL oft_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL oft_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
- if (!(proxy_info = oft_info->proxy_info)) {
-- gaim_debug_warning("oscar","NULL proxy_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL proxy_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-
- /* Use the proxy "port" we just ACK-quired (hah) so that the proxy will love us */
- oft_info->port = proxy_info->port;
- oft_info->proxyip = g_strdup(proxy_info->ip);
-- gaim_debug_info("oscar","received client ip and port: %s:%d\n",
-+ gaim2_debug_info("oscar","received client ip and port: %s:%d\n",
- oft_info->proxyip, oft_info->port);
-
- if(oft_info->send_or_recv == AIM_XFER_SEND) {
-@@ -2343,18 +2343,18 @@ static void oscar_xfer_proxylogin_ack(Ga
- } else if(oft_info->send_or_recv == AIM_XFER_RECV) {
- strncpy(oft_info->fh.name, xfer->filename, 64);
- oft_info->fh.name[63] = '\0';
-- oft_info->fh.totsize = gaim_xfer_get_size(xfer);
-- oft_info->fh.size = gaim_xfer_get_size(xfer);
-+ oft_info->fh.totsize = gaim2_xfer_get_size(xfer);
-+ oft_info->fh.size = gaim2_xfer_get_size(xfer);
-
- /* Calculating the checksum can take a very long time for large files */
-- gaim_debug_info("oscar","calculating file checksum\n");
-+ gaim2_debug_info("oscar","calculating file checksum\n");
- oft_info->fh.checksum = aim_oft_checksum_file(xfer->local_filename);
-- gaim_debug_info("oscar","checksum calculated\n");
-+ gaim2_debug_info("oscar","checksum calculated\n");
-
- aim_im_sendch2_sendfile_ask(oft_info->sess, oft_info);
- } else {
-- gaim_debug_warning("oscar","no value for send_or_recv; aborting transfer\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","no value for send_or_recv; aborting transfer\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
- }
-
-@@ -2362,19 +2362,19 @@ static void oscar_xfer_proxylogin_ack(Ga
- * This is called whenever we receive data while negotiating a rendezvous proxy connection
- * BBB
- */
--static void oscar_xfer_proxylogin_cb(gpointer data, gint source, GaimInputCondition condition) {
-- GaimXfer *xfer;
-+static void oscar_xfer_proxylogin_cb(gpointer data, gint source, Gaim2InputCondition condition) {
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
-
-- gaim_debug_info("oscar","AAA - in oscar_xfer_proxylogin_cb\n");
-+ gaim2_debug_info("oscar","AAA - in oscar_xfer_proxylogin_cb\n");
- if (!(xfer = data)) {
-- gaim_debug_warning("oscar","NULL xfer; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL xfer; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
- if (!(oft_info = xfer->data)) {
-- gaim_debug_warning("oscar","NULL oft_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL oft_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-
-@@ -2392,20 +2392,20 @@ static void oscar_xfer_proxylogin_cb(gpo
- oft_info->proxy_info = NULL;
- break;
- case AIM_RV_PROXY_ERROR:
-- gaim_debug_info("oscar","error logging into rendezvous proxy; err code is %x\n",
-+ gaim2_debug_info("oscar","error logging into rendezvous proxy; err code is %x\n",
- oft_info->proxy_info->err_code);
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
- free(oft_info->proxy_info);
- oft_info->proxy_info = NULL;
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- break;
- /* We should never get here */
- default:
-- gaim_debug_info("oscar","proxylogin switch defaulted unexpectedly\n");
-+ gaim2_debug_info("oscar","proxylogin switch defaulted unexpectedly\n");
- }
- } else {
-- gaim_debug_info("oscar","could not read rv proxy packet\n");
-+ gaim2_debug_info("oscar","could not read rv proxy packet\n");
- }
- }
-
-@@ -2413,31 +2413,31 @@ static void oscar_xfer_proxylogin_cb(gpo
- * Called to send necessary login data to a rendezvous proxy server once we're connected
- * Takes xfer is data and fd as source
- */
--static void oscar_xfer_proxylogin(gpointer data, gint source, GaimInputCondition condition)
-+static void oscar_xfer_proxylogin(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
- struct aim_rv_proxy_info *proxy_info;
- int err;
-
-- gaim_debug_info("oscar","AAA - in oscar_xfer_proxylogin\n");
-+ gaim2_debug_info("oscar","AAA - in oscar_xfer_proxylogin\n");
- if (!(xfer = data)) {
-- gaim_debug_warning("oscar","NULL xfer; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL xfer; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
- if (!(oft_info = xfer->data)) {
-- gaim_debug_warning("oscar","NULL oft_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL oft_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
- if (!(proxy_info = oft_info->proxy_info)) {
-- gaim_debug_warning("oscar","NULL proxy_info; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","NULL proxy_info; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
- if(oft_info->success) {
-- gaim_debug_info("oscar","connection already successful, ignoring 2nd conn\n");
-+ gaim2_debug_info("oscar","connection already successful, ignoring 2nd conn\n");
- return;
- }
-
-@@ -2450,59 +2450,59 @@ static void oscar_xfer_proxylogin(gpoint
-
- if(oft_info->send_or_recv == AIM_XFER_SEND) {
- if(oft_info->stage == AIM_XFER_PROXY_STG1 || oft_info->stage == AIM_XFER_PROXY_STG3) {
-- gaim_debug_info("oscar","sending INIT SEND for stage 1/3 rv proxied send\n");
-+ gaim2_debug_info("oscar","sending INIT SEND for stage 1/3 rv proxied send\n");
- if( (err = aim_rv_proxy_init_send(proxy_info)) ) {
-- gaim_xfer_error(GAIM_XFER_SEND, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_SEND, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to log into file transfer proxy."));
-- gaim_debug_info("oscar", "error while sending INIT SEND rv proxy packet: %s\n",
-+ gaim2_debug_info("oscar", "error while sending INIT SEND rv proxy packet: %s\n",
- strerror(err));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else if(oft_info->stage == AIM_XFER_PROXY_STG2) {
-- gaim_debug_info("oscar","sending INIT RECV for stage 2 rv proxied send\n");
-+ gaim2_debug_info("oscar","sending INIT RECV for stage 2 rv proxied send\n");
- if( (err = aim_rv_proxy_init_recv(proxy_info)) ) {
-- gaim_xfer_error(GAIM_XFER_SEND, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_SEND, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to log into file transfer proxy."));
-- gaim_debug_info("oscar", "error while sending INIT RECV rv proxy packet: %s\n",
-+ gaim2_debug_info("oscar", "error while sending INIT RECV rv proxy packet: %s\n",
- strerror(err));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else {
-- gaim_debug_warning("oscar","no proxy type specified; aborting transfer\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","no proxy type specified; aborting transfer\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else if(oft_info->send_or_recv == AIM_XFER_RECV) {
- if(oft_info->stage == AIM_XFER_PROXY_STG2) {
-- gaim_debug_info("oscar","sending INIT SEND for stage 2 rv proxied receive\n");
-+ gaim2_debug_info("oscar","sending INIT SEND for stage 2 rv proxied receive\n");
- if( (err = aim_rv_proxy_init_send(proxy_info)) ) {
-- gaim_xfer_error(GAIM_XFER_SEND, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_SEND, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to log into file transfer proxy."));
-- gaim_debug_info("oscar", "error while sending INIT SEND rv proxy packet: %s\n",
-+ gaim2_debug_info("oscar", "error while sending INIT SEND rv proxy packet: %s\n",
- strerror(err));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else if(oft_info->stage == AIM_XFER_PROXY_STG1
- || oft_info->stage == AIM_XFER_PROXY_STG3) {
-- gaim_debug_info("oscar","sending INIT RECV for stage 1/3 rv proxied receive\n");
-+ gaim2_debug_info("oscar","sending INIT RECV for stage 1/3 rv proxied receive\n");
- if( (err = aim_rv_proxy_init_recv(proxy_info)) ) {
-- gaim_xfer_error(GAIM_XFER_SEND, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_SEND, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to log into file transfer proxy."));
-- gaim_debug_info("oscar", "error while sending INIT RECV rv proxy packet: %s\n",
-+ gaim2_debug_info("oscar", "error while sending INIT RECV rv proxy packet: %s\n",
- strerror(err));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else {
-- gaim_debug_warning("oscar","no proxy type specified; aborting transfer\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","no proxy type specified; aborting transfer\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
- } else {
-- gaim_debug_warning("oscar","no send_or_recv value specified; aborting\n");
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_debug_warning("oscar","no send_or_recv value specified; aborting\n");
-+ gaim2_xfer_cancel_local(xfer);
- }
- free(proxy_info);
- oft_info->proxy_info = NULL;
-
-- xfer->watcher = gaim_input_add(xfer->fd, GAIM_INPUT_READ, oscar_xfer_proxylogin_cb, xfer);
-+ xfer->watcher = gaim2_input_add(xfer->fd, GAIM_INPUT_READ, oscar_xfer_proxylogin_cb, xfer);
- }
-
-
-@@ -2513,25 +2513,25 @@ static void oscar_xfer_proxylogin(gpoint
- /*
- * Send a request to another client notifying them we want to sent a file
- */
--static void oscar_send_file_request(GaimXfer *xfer)
-+static void oscar_send_file_request(Gaim2Xfer *xfer)
- {
- struct aim_oft_info *oft_info = xfer->data;
-- GaimConnection *gc = oft_info->sess->aux_data;
-+ Gaim2Connection *gc = oft_info->sess->aux_data;
- OscarData *od = gc->proto_data;
-
-- gaim_debug_info("oscar", "AAA - in oscar_send_file_request\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_send_file_request\n");
-
- if (oft_info->conn) {
- xfer->filename = g_path_get_basename(xfer->local_filename);
- strncpy(oft_info->fh.name, xfer->filename, 64);
- oft_info->fh.name[63] = '\0';
-- oft_info->fh.totsize = gaim_xfer_get_size(xfer);
-- oft_info->fh.size = gaim_xfer_get_size(xfer);
-+ oft_info->fh.totsize = gaim2_xfer_get_size(xfer);
-+ oft_info->fh.size = gaim2_xfer_get_size(xfer);
-
- /* Calculating the checksum can take a very long time for large files */
-- gaim_debug_info("oscar","calculating file checksum\n");
-+ gaim2_debug_info("oscar","calculating file checksum\n");
- oft_info->fh.checksum = aim_oft_checksum_file(xfer->local_filename);
-- gaim_debug_info("oscar","checksum calculated\n");
-+ gaim2_debug_info("oscar","checksum calculated\n");
-
- memcpy(&oft_info->fh.bcookie, oft_info->cookie, 8);
-
-@@ -2539,9 +2539,9 @@ static void oscar_send_file_request(Gaim
- aim_conn_addhandler(od->sess, oft_info->conn, AIM_CB_FAM_OFT,
- AIM_CB_OFT_ESTABLISHED, oscar_sendfile_estblsh, 0);
- } else {
-- gaim_xfer_error(GAIM_XFER_SEND, gaim_xfer_get_account(xfer), xfer->who,
-+ gaim2_xfer_error(GAIM_XFER_SEND, gaim2_xfer_get_account(xfer), xfer->who,
- _("Unable to establish listener socket or no AOL proxy connection present."));
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- }
- }
-
-@@ -2550,35 +2550,35 @@ static void oscar_send_file_request(Gaim
- * Opens a listener socket in preparation for sending a file
- * This is not called if we are using a rendezvous proxy server
- */
--static void oscar_xfer_init_send(GaimXfer *xfer)
-+static void oscar_xfer_init_send(Gaim2Xfer *xfer)
- {
- struct aim_oft_info *oft_info = xfer->data;
-- GaimConnection *gc = oft_info->sess->aux_data;
-+ Gaim2Connection *gc = oft_info->sess->aux_data;
- OscarData *od = gc->proto_data;
- int listenfd;
-
-- gaim_debug_info("oscar", "AAA - in oscar_xfer_init_send\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_xfer_init_send\n");
-
- /* Create a listening socket and an associated libfaim conn */
-- if ((listenfd = gaim_network_listen_range(5190, 5199, SOCK_STREAM)) < 0) {
-- gaim_xfer_cancel_local(xfer);
-+ if ((listenfd = gaim2_network_listen_range(5190, 5199, SOCK_STREAM)) < 0) {
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-- xfer->local_port = gaim_network_get_port_from_fd(listenfd);
-+ xfer->local_port = gaim2_network_get_port_from_fd(listenfd);
- oft_info->port = xfer->local_port;
- if (aim_sendfile_listen(od->sess, oft_info, listenfd) != 0) {
-- gaim_xfer_cancel_local(xfer);
-+ gaim2_xfer_cancel_local(xfer);
- return;
- }
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "port is %hu, ip is %s\n",
- xfer->local_port, oft_info->clientip);
-
- if(oft_info->conn)
-- xfer->watcher = gaim_input_add(oft_info->conn->fd, GAIM_INPUT_READ, oscar_callback,
-+ xfer->watcher = gaim2_input_add(oft_info->conn->fd, GAIM_INPUT_READ, oscar_callback,
- oft_info->conn);
- else
-- gaim_debug_info("oscar","NULL oft_info->conn; not adding watcher\n");
-+ gaim2_debug_info("oscar","NULL oft_info->conn; not adding watcher\n");
-
- oscar_send_file_request(xfer);
- }
-@@ -2586,15 +2586,15 @@ static void oscar_xfer_init_send(GaimXfe
- /*
- * "On second thought, you don't deserve this file."
- */
--static void oscar_xfer_cancel_send(GaimXfer *xfer)
-+static void oscar_xfer_cancel_send(Gaim2Xfer *xfer)
- {
- struct aim_oft_info *oft_info = xfer->data;
-- GaimConnection *gc = oft_info->sess->aux_data;
-+ Gaim2Connection *gc = oft_info->sess->aux_data;
- OscarData *od = gc->proto_data;
-
-- gaim_debug_info("oscar", "AAA - in oscar_xfer_cancel_send\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_xfer_cancel_send\n");
-
-- if (gaim_xfer_get_status(xfer) != GAIM_XFER_STATUS_CANCEL_REMOTE)
-+ if (gaim2_xfer_get_status(xfer) != GAIM_XFER_STATUS_CANCEL_REMOTE)
- aim_im_sendch2_sendfile_cancel(oft_info->sess, oft_info);
-
- /* Added a few sanity checks to prevent segfaulting */
-@@ -2610,7 +2610,7 @@ static void oscar_xfer_cancel_send(GaimX
- /*
- * Called when we send some data to the other client
- */
--static void oscar_xfer_ack_send(GaimXfer *xfer, const guchar *buffer, size_t size)
-+static void oscar_xfer_ack_send(Gaim2Xfer *xfer, const guchar *buffer, size_t size)
- {
- struct aim_oft_info *oft_info = xfer->data;
-
-@@ -2619,7 +2619,7 @@ static void oscar_xfer_ack_send(GaimXfer
- * of as a transferring just a single file. The rendezvous
- * establishes a connection between two computers, and then
- * those computers can use the same connection for transferring
-- * multiple files. So we don't want the Gaim core up and closing
-+ * multiple files. So we don't want the Gaim2 core up and closing
- * the socket all willy-nilly. We want to do that in the oscar
- * prpl, whenever one side or the other says they're finished
- * using the connection. There might be a better way to intercept
-@@ -2630,19 +2630,19 @@ static void oscar_xfer_ack_send(GaimXfer
- * If we're done sending, intercept the socket from the core ft code
- * and wait for the other guy to send the "done" OFT packet.
- */
-- if (gaim_xfer_get_bytes_remaining(xfer) <= 0) {
-- gaim_input_remove(xfer->watcher);
-- xfer->watcher = gaim_input_add(xfer->fd, GAIM_INPUT_READ, oscar_callback, oft_info->conn);
-+ if (gaim2_xfer_get_bytes_remaining(xfer) <= 0) {
-+ gaim2_input_remove(xfer->watcher);
-+ xfer->watcher = gaim2_input_add(xfer->fd, GAIM_INPUT_READ, oscar_callback, oft_info->conn);
- xfer->fd = 0;
-- gaim_xfer_set_completed(xfer, TRUE);
-+ gaim2_xfer_set_completed(xfer, TRUE);
- }
- }
-
- /*
-- * Called by the Gaim core to determine whether or not we're allowed to send a file
-+ * Called by the Gaim2 core to determine whether or not we're allowed to send a file
- * to this user.
- */
--static gboolean oscar_can_receive_file(GaimConnection *gc, const char *who) {
-+static gboolean oscar_can_receive_file(Gaim2Connection *gc, const char *who) {
- OscarData *od = gc->proto_data;
-
- if (od != NULL) {
-@@ -2654,7 +2654,7 @@ static gboolean oscar_can_receive_file(G
- * file transfer, and don't allow sending to ourselves.
- */
- if (userinfo && (userinfo->capabilities & AIM_CAPS_SENDFILE) &&
-- aim_sncmp(who, gaim_account_get_username(gaim_connection_get_account(gc))))
-+ aim_sncmp(who, gaim2_account_get_username(gaim2_connection_get_account(gc))))
- {
- return TRUE;
- }
-@@ -2663,28 +2663,28 @@ static gboolean oscar_can_receive_file(G
- return FALSE;
- }
-
--static GaimXfer*
--oscar_new_xfer(GaimConnection *gc, const char *who) {
-+static Gaim2Xfer*
-+oscar_new_xfer(Gaim2Connection *gc, const char *who) {
- OscarData *od;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
- const char *ip;
- gboolean use_rv_proxy;
-
-- use_rv_proxy = gaim_prefs_get_bool("/plugins/prpl/oscar/use_rv_proxy");
-+ use_rv_proxy = gaim2_prefs_get_bool("/plugins/prpl/oscar/use_rv_proxy");
- if(use_rv_proxy)
-- gaim_debug_info("oscar","using stage 1 proxied transfer\n");
-+ gaim2_debug_info("oscar","using stage 1 proxied transfer\n");
-
- od = (OscarData *)gc->proto_data;
-
- /* You want to send a file to someone else, you're so generous */
-
- /* Build the file transfer handle */
-- xfer = gaim_xfer_new(gc->account, GAIM_XFER_SEND, who);
-+ xfer = gaim2_xfer_new(gc->account, GAIM_XFER_SEND, who);
-
- /* Create the oscar-specific data */
- if (use_rv_proxy) {
-- /* This hostname will be resolved by gaim_proxy_connect */
-+ /* This hostname will be resolved by gaim2_proxy_connect */
- xfer->remote_ip = g_strdup(AIM_RV_PROXY_SERVER_URL);
- xfer->remote_port = AIM_RV_PROXY_CONNECT_PORT;
- oft_info = aim_oft_createinfo(od->sess, NULL /*cookie*/, who, 0 /*ip*/, 0, 0, 0, NULL,
-@@ -2694,7 +2694,7 @@ oscar_new_xfer(GaimConnection *gc, const
- * so that it can be sent to the proxy */
- aim_icbm_makecookie(oft_info->cookie);
- } else {
-- ip = gaim_network_get_my_ip(od->conn ? od->conn->fd : -1);
-+ ip = gaim2_network_get_my_ip(od->conn ? od->conn->fd : -1);
- oft_info = aim_oft_createinfo(od->sess, NULL, who, ip, 0, 0, 0, NULL,
- AIM_XFER_SEND, AIM_XFER_DIRECT, AIM_XFER_PROXY_NONE);
- }
-@@ -2702,13 +2702,13 @@ oscar_new_xfer(GaimConnection *gc, const
-
- /* Setup our I/O op functions */
- if (use_rv_proxy)
-- gaim_xfer_set_init_fnc(xfer, oscar_xfer_init_recv);
-+ gaim2_xfer_set_init_fnc(xfer, oscar_xfer_init_recv);
- else
-- gaim_xfer_set_init_fnc(xfer, oscar_xfer_init_send);
-- gaim_xfer_set_end_fnc(xfer, oscar_xfer_end);
-- gaim_xfer_set_cancel_send_fnc(xfer, oscar_xfer_cancel_send);
-- gaim_xfer_set_request_denied_fnc(xfer, oscar_xfer_cancel_send);
-- gaim_xfer_set_ack_fnc(xfer, oscar_xfer_ack_send);
-+ gaim2_xfer_set_init_fnc(xfer, oscar_xfer_init_send);
-+ gaim2_xfer_set_end_fnc(xfer, oscar_xfer_end);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, oscar_xfer_cancel_send);
-+ gaim2_xfer_set_request_denied_fnc(xfer, oscar_xfer_cancel_send);
-+ gaim2_xfer_set_ack_fnc(xfer, oscar_xfer_ack_send);
-
- /* Keep track of this transfer for later */
- od->file_transfers = g_slist_append(od->file_transfers, xfer);
-@@ -2717,36 +2717,36 @@ oscar_new_xfer(GaimConnection *gc, const
- }
-
- /*
-- * Called by the Gaim core when the user indicates that a file is to be sent to
-+ * Called by the Gaim2 core when the user indicates that a file is to be sent to
- * a special someone.
- */
--static void oscar_send_file(GaimConnection *gc, const char *who, const char *file) {
-- GaimXfer *xfer = oscar_new_xfer(gc, who);
-+static void oscar_send_file(Gaim2Connection *gc, const char *who, const char *file) {
-+ Gaim2Xfer *xfer = oscar_new_xfer(gc, who);
-
- /* Now perform the request */
- if (file)
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
- else
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
--static int gaim_parse_auth_resp(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_parse_auth_resp(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-- GaimAccount *account = gc->account;
-+ Gaim2Account *account = gc->account;
- aim_conn_t *bosconn;
- char *host; int port;
- int i, rc;
- va_list ap;
- struct aim_authresp_info *info;
-
-- port = gaim_account_get_int(account, "port", OSCAR_DEFAULT_LOGIN_PORT);
-+ port = gaim2_account_get_int(account, "port", OSCAR_DEFAULT_LOGIN_PORT);
-
- va_start(ap, fr);
- info = va_arg(ap, struct aim_authresp_info *);
- va_end(ap);
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "inside auth_resp (Screen name: %s)\n", info->sn);
-
- if (info->errorcode || !info->bosip || !info->cookielen || !info->cookie) {
-@@ -2755,107 +2755,107 @@ static int gaim_parse_auth_resp(aim_sess
- case 0x05:
- /* Incorrect nick/password */
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, _("Incorrect nickname or password."));
-+ gaim2_connection_error(gc, _("Incorrect nickname or password."));
- break;
- case 0x11:
- /* Suspended account */
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, _("Your account is currently suspended."));
-+ gaim2_connection_error(gc, _("Your account is currently suspended."));
- break;
- case 0x14:
- /* service temporarily unavailable */
-- gaim_connection_error(gc, _("The AOL Instant Messenger service is temporarily unavailable."));
-+ gaim2_connection_error(gc, _("The AOL Instant Messenger service is temporarily unavailable."));
- break;
- case 0x18:
- /* connecting too frequently */
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, _("You have been connecting and disconnecting too frequently. Wait ten minutes and try again. If you continue to try, you will need to wait even longer."));
-+ gaim2_connection_error(gc, _("You have been connecting and disconnecting too frequently. Wait ten minutes and try again. If you continue to try, you will need to wait even longer."));
- break;
- case 0x1c:
- /* client too old */
- gc->wants_to_die = TRUE;
- g_snprintf(buf, sizeof(buf), _("The client version you are using is too old. Please upgrade at %s"), GAIM_WEBSITE);
-- gaim_connection_error(gc, buf);
-+ gaim2_connection_error(gc, buf);
- break;
- default:
-- gaim_connection_error(gc, _("Authentication failed"));
-+ gaim2_connection_error(gc, _("Authentication failed"));
- break;
- }
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Login Error Code 0x%04hx\n", info->errorcode);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Error URL: %s\n", info->errorurl);
- od->killme = TRUE;
- return 1;
- }
-
-
-- gaim_debug_misc("oscar", "Reg status: %hu\n", info->regstatus);
-+ gaim2_debug_misc("oscar", "Reg status: %hu\n", info->regstatus);
-
- if (info->email) {
-- gaim_debug_misc("oscar", "Email: %s\n", info->email);
-+ gaim2_debug_misc("oscar", "Email: %s\n", info->email);
- } else {
-- gaim_debug_misc("oscar", "Email is NULL\n");
-+ gaim2_debug_misc("oscar", "Email is NULL\n");
- }
-
-- gaim_debug_misc("oscar", "BOSIP: %s\n", info->bosip);
-- gaim_debug_info("oscar",
-+ gaim2_debug_misc("oscar", "BOSIP: %s\n", info->bosip);
-+ gaim2_debug_info("oscar",
- "Closing auth connection...\n");
- aim_conn_kill(sess, &fr->conn);
-
- bosconn = aim_newconn(sess, AIM_CONN_TYPE_BOS);
- if (bosconn == NULL) {
-- gaim_connection_error(gc, _("Internal Error"));
-+ gaim2_connection_error(gc, _("Internal Error"));
- od->killme = TRUE;
- return 0;
- }
-
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNINITDONE, conninitdone_bos, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0009, 0x0003, gaim_bosrights, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0009, 0x0003, gaim2_bosrights, 0);
- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ACK, AIM_CB_ACK_ACK, NULL, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_REDIRECT, gaim_handle_redirect, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_RIGHTSINFO, gaim_parse_locaterights, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_BUD, AIM_CB_BUD_RIGHTSINFO, gaim_parse_buddyrights, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_BUD, AIM_CB_BUD_ONCOMING, gaim_parse_oncoming, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_BUD, AIM_CB_BUD_OFFGOING, gaim_parse_offgoing, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_INCOMING, gaim_parse_incoming_im, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_ERROR, gaim_parse_locerr, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_MISSEDCALL, gaim_parse_misses, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_CLIENTAUTORESP, gaim_parse_clientauto, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_RATECHANGE, gaim_parse_ratechange, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_EVIL, gaim_parse_evilnotify, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOK, AIM_CB_LOK_ERROR, gaim_parse_searcherror, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOK, 0x0003, gaim_parse_searchreply, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_ERROR, gaim_parse_msgerr, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_MTN, gaim_parse_mtn, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_USERINFO, gaim_parse_userinfo, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_REQUESTINFOTIMEOUT, gaim_reqinfo_timeout, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_GOTINFOBLOCK, gaim_got_infoblock, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_ACK, gaim_parse_msgack, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_MOTD, gaim_parse_motd, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0004, 0x0005, gaim_icbm_param_info, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0001, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0003, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0009, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0001, 0x001f, gaim_memrequest, 0);
-- aim_conn_addhandler(sess, bosconn, 0x0001, 0x000f, gaim_selfinfo, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_REDIRECT, gaim2_handle_redirect, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_RIGHTSINFO, gaim2_parse_locaterights, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_BUD, AIM_CB_BUD_RIGHTSINFO, gaim2_parse_buddyrights, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_BUD, AIM_CB_BUD_ONCOMING, gaim2_parse_oncoming, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_BUD, AIM_CB_BUD_OFFGOING, gaim2_parse_offgoing, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_INCOMING, gaim2_parse_incoming_im, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_ERROR, gaim2_parse_locerr, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_MISSEDCALL, gaim2_parse_misses, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_CLIENTAUTORESP, gaim2_parse_clientauto, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_RATECHANGE, gaim2_parse_ratechange, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_EVIL, gaim2_parse_evilnotify, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOK, AIM_CB_LOK_ERROR, gaim2_parse_searcherror, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOK, 0x0003, gaim2_parse_searchreply, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_ERROR, gaim2_parse_msgerr, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_MTN, gaim2_parse_mtn, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_USERINFO, gaim2_parse_userinfo, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_REQUESTINFOTIMEOUT, gaim2_reqinfo_timeout, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_LOC, AIM_CB_LOC_GOTINFOBLOCK, gaim2_got_infoblock, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_MSG, AIM_CB_MSG_ACK, gaim2_parse_msgack, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_GEN, AIM_CB_GEN_MOTD, gaim2_parse_motd, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0004, 0x0005, gaim2_icbm_param_info, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0001, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0003, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0009, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0001, 0x001f, gaim2_memrequest, 0);
-+ aim_conn_addhandler(sess, bosconn, 0x0001, 0x000f, gaim2_selfinfo, 0);
- aim_conn_addhandler(sess, bosconn, 0x0001, 0x0021, oscar_icon_req,0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_OFFLINEMSG, gaim_offlinemsg, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_OFFLINEMSGCOMPLETE, gaim_offlinemsgdone, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_POP, 0x0002, gaim_popup, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_ALIAS, gaim_icqalias, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_INFO, gaim_icqinfo, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_ERROR, gaim_ssi_parseerr, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RIGHTSINFO, gaim_ssi_parserights, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_LIST, gaim_ssi_parselist, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_NOLIST, gaim_ssi_parselist, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_SRVACK, gaim_ssi_parseack, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_ADD, gaim_ssi_parseadd, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RECVAUTH, gaim_ssi_authgiven, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RECVAUTHREQ, gaim_ssi_authrequest, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RECVAUTHREP, gaim_ssi_authreply, 0);
-- aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_ADDED, gaim_ssi_gotadded, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_OFFLINEMSG, gaim2_offlinemsg, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_OFFLINEMSGCOMPLETE, gaim2_offlinemsgdone, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_POP, 0x0002, gaim2_popup, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_ALIAS, gaim2_icqalias, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_ICQ, AIM_CB_ICQ_INFO, gaim2_icqinfo, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_ERROR, gaim2_ssi_parseerr, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RIGHTSINFO, gaim2_ssi_parserights, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_LIST, gaim2_ssi_parselist, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_NOLIST, gaim2_ssi_parselist, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_SRVACK, gaim2_ssi_parseack, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_ADD, gaim2_ssi_parseadd, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RECVAUTH, gaim2_ssi_authgiven, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RECVAUTHREQ, gaim2_ssi_authrequest, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_RECVAUTHREP, gaim2_ssi_authreply, 0);
-+ aim_conn_addhandler(sess, bosconn, AIM_CB_FAM_SSI, AIM_CB_SSI_ADDED, gaim2_ssi_gotadded, 0);
-
- od->conn = bosconn;
- for (i = 0; i < (int)strlen(info->bosip); i++) {
-@@ -2866,26 +2866,26 @@ static int gaim_parse_auth_resp(aim_sess
- }
- host = g_strndup(info->bosip, i);
- bosconn->status |= AIM_CONN_STATUS_INPROGRESS;
-- rc = gaim_proxy_connect(gc->account, host, port, oscar_bos_connect, gc);
-+ rc = gaim2_proxy_connect(gc->account, host, port, oscar_bos_connect, gc);
- g_free(host);
- if (rc < 0) {
-- gaim_connection_error(gc, _("Could Not Connect"));
-+ gaim2_connection_error(gc, _("Could Not Connect"));
- od->killme = TRUE;
- return 0;
- }
- aim_sendcookie(sess, bosconn, info->cookielen, info->cookie);
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
-
-- gaim_connection_update_progress(gc, _("Received authorization"), 3, OSCAR_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Received authorization"), 3, OSCAR_CONNECT_STEPS);
- ck[3] = 0x64;
-
- return 1;
- }
-
- static void
--gaim_parse_auth_securid_request_yes_cb(gpointer user_data, const char *msg)
-+gaim2_parse_auth_securid_request_yes_cb(gpointer user_data, const char *msg)
- {
-- GaimConnection *gc = user_data;
-+ Gaim2Connection *gc = user_data;
- OscarData *od = gc->proto_data;
- aim_session_t *sess = od->sess;
-
-@@ -2893,41 +2893,41 @@ gaim_parse_auth_securid_request_yes_cb(g
- }
-
- static void
--gaim_parse_auth_securid_request_no_cb(gpointer user_data, const char *value)
-+gaim2_parse_auth_securid_request_no_cb(gpointer user_data, const char *value)
- {
-- GaimConnection *gc = user_data;
-+ Gaim2Connection *gc = user_data;
- OscarData *od = gc->proto_data;
-
- /* Disconnect */
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, _("The SecurID key entered is invalid."));
-+ gaim2_connection_error(gc, _("The SecurID key entered is invalid."));
- od->killme = TRUE;
- }
-
- static int
--gaim_parse_auth_securid_request(aim_session_t *sess, aim_frame_t *fr, ...)
-+gaim2_parse_auth_securid_request(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- gchar *primary;
-
-- gaim_debug_info("oscar", "Got SecurID request\n");
-+ gaim2_debug_info("oscar", "Got SecurID request\n");
-
-- primary = g_strdup_printf("Enter the SecurID key for %s.", gaim_account_get_username(account));
-- gaim_request_input(gc, NULL, _("Enter SecurID"), primary,
-+ primary = g_strdup_printf("Enter the SecurID key for %s.", gaim2_account_get_username(account));
-+ gaim2_request_input(gc, NULL, _("Enter SecurID"), primary,
- _("Enter the 6 digit number from the digital display."),
- FALSE, FALSE, NULL,
-- _("OK"), G_CALLBACK(gaim_parse_auth_securid_request_yes_cb),
-- _("Cancel"), G_CALLBACK(gaim_parse_auth_securid_request_no_cb),
-+ _("OK"), G_CALLBACK(gaim2_parse_auth_securid_request_yes_cb),
-+ _("Cancel"), G_CALLBACK(gaim2_parse_auth_securid_request_no_cb),
- gc);
- g_free(primary);
-
- return 1;
- }
-
--/* XXX - Should use gaim_url_fetch for the below stuff */
-+/* XXX - Should use gaim2_url_fetch for the below stuff */
- struct pieceofcrap {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- unsigned long offset;
- unsigned long len;
- char *modname;
-@@ -2936,7 +2936,7 @@ struct pieceofcrap {
- unsigned int inpa;
- };
-
--static void damn_you(gpointer data, gint source, GaimInputCondition c)
-+static void damn_you(gpointer data, gint source, Gaim2InputCondition c)
- {
- struct pieceofcrap *pos = data;
- OscarData *od = pos->gc->proto_data;
-@@ -2957,28 +2957,28 @@ static void damn_you(gpointer data, gint
- char buf[256];
- g_snprintf(buf, sizeof(buf), _("You may be disconnected shortly. You may want to use TOC until "
- "this is fixed. Check %s for updates."), GAIM_WEBSITE);
-- gaim_notify_warning(pos->gc, NULL,
-- _("Gaim was unable to get a valid AIM login hash."),
-+ gaim2_notify_warning(pos->gc, NULL,
-+ _("Gaim2 was unable to get a valid AIM login hash."),
- buf);
-- gaim_input_remove(pos->inpa);
-+ gaim2_input_remove(pos->inpa);
- close(pos->fd);
- g_free(pos);
- return;
- }
- read(pos->fd, m, 16);
- m[16] = '\0';
-- gaim_debug_misc("oscar", "Sending hash: ");
-+ gaim2_debug_misc("oscar", "Sending hash: ");
- for (x = 0; x < 16; x++)
-- gaim_debug_misc(NULL, "%02hhx ", (unsigned char)m[x]);
-+ gaim2_debug_misc(NULL, "%02hhx ", (unsigned char)m[x]);
-
-- gaim_debug_misc(NULL, "\n");
-- gaim_input_remove(pos->inpa);
-+ gaim2_debug_misc(NULL, "\n");
-+ gaim2_input_remove(pos->inpa);
- close(pos->fd);
- aim_sendmemblock(od->sess, pos->conn, 0, 16, m, AIM_SENDMEMBLOCK_FLAG_ISHASH);
- g_free(pos);
- }
-
--static void straight_to_hell(gpointer data, gint source, GaimInputCondition cond) {
-+static void straight_to_hell(gpointer data, gint source, Gaim2InputCondition cond) {
- struct pieceofcrap *pos = data;
- gchar *buf;
-
-@@ -2987,8 +2987,8 @@ static void straight_to_hell(gpointer da
- if (source < 0) {
- buf = g_strdup_printf(_("You may be disconnected shortly. You may want to use TOC until "
- "this is fixed. Check %s for updates."), GAIM_WEBSITE);
-- gaim_notify_warning(pos->gc, NULL,
-- _("Gaim was unable to get a valid AIM login hash."),
-+ gaim2_notify_warning(pos->gc, NULL,
-+ _("Gaim2 was unable to get a valid AIM login hash."),
- buf);
- g_free(buf);
- if (pos->modname)
-@@ -3003,14 +3003,14 @@ static void straight_to_hell(gpointer da
- g_free(buf);
- if (pos->modname)
- g_free(pos->modname);
-- pos->inpa = gaim_input_add(pos->fd, GAIM_INPUT_READ, damn_you, pos);
-+ pos->inpa = gaim2_input_add(pos->fd, GAIM_INPUT_READ, damn_you, pos);
- return;
- }
-
- /* size of icbmui.ocm, the largest module in AIM 3.5 */
- #define AIM_MAX_FILE_SIZE 98304
-
--int gaim_memrequest(aim_session_t *sess, aim_frame_t *fr, ...) {
-+int gaim2_memrequest(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- struct pieceofcrap *pos;
- fu32_t offset, len;
-@@ -3022,12 +3022,12 @@ int gaim_memrequest(aim_session_t *sess,
- modname = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "offset: %u, len: %u, file: %s\n",
- offset, len, (modname ? modname : "aim.exe"));
-
- if (len == 0) {
-- gaim_debug_misc("oscar", "len is 0, hashing NULL\n");
-+ gaim2_debug_misc("oscar", "len is 0, hashing NULL\n");
- aim_sendmemblock(sess, fr->conn, offset, len, NULL,
- AIM_SENDMEMBLOCK_FLAG_ISREQUEST);
- return 1;
-@@ -3053,7 +3053,7 @@ int gaim_memrequest(aim_session_t *sess,
- buf[i++] = (len >> 8) & 0xff;
- buf[i++] = (len >> 16) & 0xff;
- buf[i++] = (len >> 24) & 0xff;
-- gaim_debug_misc("oscar", "len + offset is invalid, "
-+ gaim2_debug_misc("oscar", "len + offset is invalid, "
- "hashing request\n");
- aim_sendmemblock(sess, command->conn, offset, i, buf, AIM_SENDMEMBLOCK_FLAG_ISREQUEST);
- g_free(buf);
-@@ -3069,24 +3069,24 @@ int gaim_memrequest(aim_session_t *sess,
- pos->len = len;
- pos->modname = modname ? g_strdup(modname) : NULL;
-
-- if (gaim_proxy_connect(pos->gc->account, "gaim.sourceforge.net", 80, straight_to_hell, pos) != 0) {
-+ if (gaim2_proxy_connect(pos->gc->account, "gaim2.sourceforge.net", 80, straight_to_hell, pos) != 0) {
- char buf[256];
- if (pos->modname)
- g_free(pos->modname);
- g_free(pos);
- g_snprintf(buf, sizeof(buf), _("You may be disconnected shortly. You may want to use TOC until "
- "this is fixed. Check %s for updates."), GAIM_WEBSITE);
-- gaim_notify_warning(pos->gc, NULL,
-- _("Gaim was unable to get a valid login hash."),
-+ gaim2_notify_warning(pos->gc, NULL,
-+ _("Gaim2 was unable to get a valid login hash."),
- buf);
- }
-
- return 1;
- }
-
--static int gaim_parse_login(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+static int gaim2_parse_login(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct client_info_s info = CLIENTINFO_GAIM;
- va_list ap;
- char *key;
-@@ -3095,25 +3095,25 @@ static int gaim_parse_login(aim_session_
- key = va_arg(ap, char *);
- va_end(ap);
-
-- aim_send_login(sess, fr->conn, gaim_account_get_username(account),
-- gaim_connection_get_password(gc), &info, key);
-+ aim_send_login(sess, fr->conn, gaim2_account_get_username(account),
-+ gaim2_connection_get_password(gc), &info, key);
-
-- gaim_connection_update_progress(gc, _("Password sent"), 2, OSCAR_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Password sent"), 2, OSCAR_CONNECT_STEPS);
- ck[2] = 0x6c;
-
- return 1;
- }
-
- static int conninitdone_chat(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- struct chat_connection *chatcon;
- static int id = 1;
-
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_USERJOIN, gaim_conv_chat_join, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_USERLEAVE, gaim_conv_chat_leave, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_ROOMINFOUPDATE, gaim_conv_chat_info_update, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_INCOMINGMSG, gaim_conv_chat_incoming_msg, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_USERJOIN, gaim2_conv_chat_join, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_USERLEAVE, gaim2_conv_chat_leave, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_ROOMINFOUPDATE, gaim2_conv_chat_info_update, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CHT, AIM_CB_CHT_INCOMINGMSG, gaim2_conv_chat_incoming_msg, 0);
-
- aim_clientready(sess, fr->conn);
-
-@@ -3126,8 +3126,8 @@ static int conninitdone_chat(aim_session
-
- static int conninitdone_chatnav(aim_session_t *sess, aim_frame_t *fr, ...) {
-
-- aim_conn_addhandler(sess, fr->conn, 0x000d, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CTN, AIM_CB_CTN_INFO, gaim_chatnav_info, 0);
-+ aim_conn_addhandler(sess, fr->conn, 0x000d, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_CTN, AIM_CB_CTN_INFO, gaim2_chatnav_info, 0);
-
- aim_clientready(sess, fr->conn);
-
-@@ -3138,8 +3138,8 @@ static int conninitdone_chatnav(aim_sess
-
- static int conninitdone_email(aim_session_t *sess, aim_frame_t *fr, ...) {
-
-- aim_conn_addhandler(sess, fr->conn, 0x0018, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_EML, AIM_CB_EML_MAILSTATUS, gaim_email_parseupdate, 0);
-+ aim_conn_addhandler(sess, fr->conn, 0x0018, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_EML, AIM_CB_EML_MAILSTATUS, gaim2_email_parseupdate, 0);
-
- aim_email_sendcookies(sess);
- aim_email_activate(sess);
-@@ -3149,31 +3149,31 @@ static int conninitdone_email(aim_sessio
- }
-
- static int conninitdone_icon(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-
-- aim_conn_addhandler(sess, fr->conn, 0x0018, 0x0001, gaim_parse_genericerr, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ICO, AIM_CB_ICO_ERROR, gaim_icon_error, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ICO, AIM_CB_ICO_RESPONSE, gaim_icon_parseicon, 0);
-+ aim_conn_addhandler(sess, fr->conn, 0x0018, 0x0001, gaim2_parse_genericerr, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ICO, AIM_CB_ICO_ERROR, gaim2_icon_error, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ICO, AIM_CB_ICO_RESPONSE, gaim2_icon_parseicon, 0);
-
- aim_clientready(sess, fr->conn);
-
- od->iconconnecting = FALSE;
-
- if (od->icontimer)
-- gaim_timeout_remove(od->icontimer);
-- od->icontimer = gaim_timeout_add(100, gaim_icon_timerfunc, gc);
-+ gaim2_timeout_remove(od->icontimer);
-+ od->icontimer = gaim2_timeout_add(100, gaim2_icon_timerfunc, gc);
-
- return 1;
- }
-
--static void oscar_chatnav_connect(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void oscar_chatnav_connect(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *tstconn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -3185,24 +3185,24 @@ static void oscar_chatnav_connect(gpoint
-
- if (source < 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to chatnav server\n");
- return;
- }
-
- aim_conn_completeconnect(sess, tstconn);
-- od->cnpa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-- gaim_debug_info("oscar", "chatnav: connected\n");
-+ od->cnpa = gaim2_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-+ gaim2_debug_info("oscar", "chatnav: connected\n");
- }
-
--static void oscar_auth_connect(gpointer data, gint source, GaimInputCondition cond)
-+static void oscar_auth_connect(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *tstconn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -3214,25 +3214,25 @@ static void oscar_auth_connect(gpointer
-
- if (source < 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to authorizer\n");
- return;
- }
-
- aim_conn_completeconnect(sess, tstconn);
-- od->paspa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-- gaim_debug_info("oscar", "admin: connected\n");
-+ od->paspa = gaim2_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-+ gaim2_debug_info("oscar", "admin: connected\n");
- }
-
--static void oscar_chat_connect(gpointer data, gint source, GaimInputCondition cond)
-+static void oscar_chat_connect(gpointer data, gint source, Gaim2InputCondition cond)
- {
- struct chat_connection *ccon = data;
-- GaimConnection *gc = ccon->gc;
-+ Gaim2Connection *gc = ccon->gc;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *tstconn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- g_free(ccon->show);
- g_free(ccon->name);
-@@ -3254,17 +3254,17 @@ static void oscar_chat_connect(gpointer
- }
-
- aim_conn_completeconnect(sess, ccon->conn);
-- ccon->inpa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-+ ccon->inpa = gaim2_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
- od->oscar_chats = g_slist_append(od->oscar_chats, ccon);
- }
-
--static void oscar_email_connect(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void oscar_email_connect(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *tstconn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -3276,24 +3276,24 @@ static void oscar_email_connect(gpointer
-
- if (source < 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to email server\n");
- return;
- }
-
- aim_conn_completeconnect(sess, tstconn);
-- od->emlpa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-- gaim_debug_info("oscar",
-+ od->emlpa = gaim2_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-+ gaim2_debug_info("oscar",
- "email: connected\n");
- }
-
--static void oscar_icon_connect(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void oscar_icon_connect(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- OscarData *od;
- aim_session_t *sess;
- aim_conn_t *tstconn;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-@@ -3305,20 +3305,20 @@ static void oscar_icon_connect(gpointer
-
- if (source < 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to icon server\n");
- return;
- }
-
- aim_conn_completeconnect(sess, tstconn);
-- od->icopa = gaim_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-- gaim_debug_info("oscar", "icon: connected\n");
-+ od->icopa = gaim2_input_add(tstconn->fd, GAIM_INPUT_READ, oscar_callback, tstconn);
-+ gaim2_debug_info("oscar", "icon: connected\n");
- }
-
- /* Hrmph. I don't know how to make this look better. --mid */
--static int gaim_handle_redirect(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+static int gaim2_handle_redirect(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- aim_conn_t *tstconn;
- int i;
- char *host;
-@@ -3326,7 +3326,7 @@ static int gaim_handle_redirect(aim_sess
- va_list ap;
- struct aim_redirect_data *redir;
-
-- port = gaim_account_get_int(account, "port", OSCAR_DEFAULT_LOGIN_PORT);
-+ port = gaim2_account_get_int(account, "port", OSCAR_DEFAULT_LOGIN_PORT);
-
- va_start(ap, fr);
- redir = va_arg(ap, struct aim_redirect_data *);
-@@ -3342,22 +3342,22 @@ static int gaim_handle_redirect(aim_sess
-
- switch(redir->group) {
- case 0x7: /* Authorizer */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Reconnecting with authorizor...\n");
- tstconn = aim_newconn(sess, AIM_CONN_TYPE_AUTH);
- if (tstconn == NULL) {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to reconnect with authorizer\n");
- g_free(host);
- return 1;
- }
-- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-+ aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNINITDONE, conninitdone_admin, 0);
-
- tstconn->status |= AIM_CONN_STATUS_INPROGRESS;
-- if (gaim_proxy_connect(account, host, port, oscar_auth_connect, gc) != 0) {
-+ if (gaim2_proxy_connect(account, host, port, oscar_auth_connect, gc) != 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to reconnect with authorizer\n");
- g_free(host);
- return 1;
-@@ -3368,18 +3368,18 @@ static int gaim_handle_redirect(aim_sess
- case 0xd: /* ChatNav */
- tstconn = aim_newconn(sess, AIM_CONN_TYPE_CHATNAV);
- if (tstconn == NULL) {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to chatnav server\n");
- g_free(host);
- return 1;
- }
-- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-+ aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNINITDONE, conninitdone_chatnav, 0);
-
- tstconn->status |= AIM_CONN_STATUS_INPROGRESS;
-- if (gaim_proxy_connect(account, host, port, oscar_chatnav_connect, gc) != 0) {
-+ if (gaim2_proxy_connect(account, host, port, oscar_chatnav_connect, gc) != 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to chatnav server\n");
- g_free(host);
- return 1;
-@@ -3392,13 +3392,13 @@ static int gaim_handle_redirect(aim_sess
-
- tstconn = aim_newconn(sess, AIM_CONN_TYPE_CHAT);
- if (tstconn == NULL) {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to chat server\n");
- g_free(host);
- return 1;
- }
-
-- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-+ aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNINITDONE, conninitdone_chat, 0);
-
- ccon = g_new0(struct chat_connection, 1);
-@@ -3410,9 +3410,9 @@ static int gaim_handle_redirect(aim_sess
- ccon->show = extract_name(redir->chat.room);
-
- ccon->conn->status |= AIM_CONN_STATUS_INPROGRESS;
-- if (gaim_proxy_connect(account, host, port, oscar_chat_connect, ccon) != 0) {
-+ if (gaim2_proxy_connect(account, host, port, oscar_chat_connect, ccon) != 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to chat server\n");
- g_free(host);
- g_free(ccon->show);
-@@ -3421,25 +3421,25 @@ static int gaim_handle_redirect(aim_sess
- return 1;
- }
- aim_sendcookie(sess, tstconn, redir->cookielen, redir->cookie);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Connected to chat room %s exchange %hu\n",
- ccon->name, ccon->exchange);
- } break;
-
- case 0x0010: { /* icon */
- if (!(tstconn = aim_newconn(sess, AIM_CONN_TYPE_ICON))) {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to icon server\n");
- g_free(host);
- return 1;
- }
-- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-+ aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNINITDONE, conninitdone_icon, 0);
-
- tstconn->status |= AIM_CONN_STATUS_INPROGRESS;
-- if (gaim_proxy_connect(account, host, port, oscar_icon_connect, gc) != 0) {
-+ if (gaim2_proxy_connect(account, host, port, oscar_icon_connect, gc) != 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to icon server\n");
- g_free(host);
- return 1;
-@@ -3449,18 +3449,18 @@ static int gaim_handle_redirect(aim_sess
-
- case 0x0018: { /* email */
- if (!(tstconn = aim_newconn(sess, AIM_CONN_TYPE_EMAIL))) {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to email server\n");
- g_free(host);
- return 1;
- }
-- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim_connerr, 0);
-+ aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNERR, gaim2_connerr, 0);
- aim_conn_addhandler(sess, tstconn, AIM_CB_FAM_SPECIAL, AIM_CB_SPECIAL_CONNINITDONE, conninitdone_email, 0);
-
- tstconn->status |= AIM_CONN_STATUS_INPROGRESS;
-- if (gaim_proxy_connect(account, host, port, oscar_email_connect, gc) != 0) {
-+ if (gaim2_proxy_connect(account, host, port, oscar_email_connect, gc) != 0) {
- aim_conn_kill(sess, &tstconn);
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unable to connect to email server\n");
- g_free(host);
- return 1;
-@@ -3469,7 +3469,7 @@ static int gaim_handle_redirect(aim_sess
- } break;
-
- default: /* huh? */
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "got redirect for unknown service 0x%04hx\n",
- redir->group);
- break;
-@@ -3479,11 +3479,11 @@ static int gaim_handle_redirect(aim_sess
- return 1;
- }
-
--static int gaim_parse_oncoming(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_parse_oncoming(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc;
-- GaimAccount *account;
-- GaimPresence *presence;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
- OscarData *od;
- struct buddyinfo *bi;
- time_t time_idle = 0, signon = 0;
-@@ -3496,8 +3496,8 @@ static int gaim_parse_oncoming(aim_sessi
- aim_userinfo_t *info;
-
- gc = sess->aux_data;
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
- od = gc->proto_data;
-
- va_start(ap, fr);
-@@ -3558,23 +3558,23 @@ static int gaim_parse_oncoming(aim_sessi
-
- if (have_status_message)
- {
-- gaim_prpl_got_user_status(account, info->sn, status_id,
-+ gaim2_prpl_got_user_status(account, info->sn, status_id,
- "message", message, NULL);
- g_free(message);
- }
- else
-- gaim_prpl_got_user_status(account, info->sn, status_id, NULL);
-+ gaim2_prpl_got_user_status(account, info->sn, status_id, NULL);
-
- /* Login time stuff */
- if (info->present & AIM_USERINFO_PRESENT_ONLINESINCE)
- signon = info->onlinesince;
- else if (info->present & AIM_USERINFO_PRESENT_SESSIONLEN)
- signon = time(NULL) - info->sessionlen;
-- if (!aim_sncmp(gaim_account_get_username(account), info->sn)) {
-- gaim_connection_set_display_name(gc, info->sn);
-- od->timeoffset = signon - gaim_presence_get_login_time(presence);
-+ if (!aim_sncmp(gaim2_account_get_username(account), info->sn)) {
-+ gaim2_connection_set_display_name(gc, info->sn);
-+ od->timeoffset = signon - gaim2_presence_get_login_time(presence);
- }
-- gaim_prpl_got_user_login_time(account, info->sn, signon - od->timeoffset);
-+ gaim2_prpl_got_user_login_time(account, info->sn, signon - od->timeoffset);
-
- /* Idle time stuff */
- /* info->idletime is the number of minutes that this user has been idle */
-@@ -3582,15 +3582,15 @@ static int gaim_parse_oncoming(aim_sessi
- time_idle = time(NULL) - info->idletime * 60;
-
- if (time_idle > 0)
-- gaim_prpl_got_user_idle(account, info->sn, TRUE, time_idle);
-+ gaim2_prpl_got_user_idle(account, info->sn, TRUE, time_idle);
- else
-- gaim_prpl_got_user_idle(account, info->sn, FALSE, 0);
-+ gaim2_prpl_got_user_idle(account, info->sn, FALSE, 0);
-
- /* Server stored icon stuff */
-- bi = g_hash_table_lookup(od->buddyinfo, gaim_normalize(account, info->sn));
-+ bi = g_hash_table_lookup(od->buddyinfo, gaim2_normalize(account, info->sn));
- if (!bi) {
- bi = g_new0(struct buddyinfo, 1);
-- g_hash_table_insert(od->buddyinfo, g_strdup(gaim_normalize(account, info->sn)), bi);
-+ g_hash_table_insert(od->buddyinfo, g_strdup(gaim2_normalize(account, info->sn)), bi);
- }
- bi->typingnot = FALSE;
- bi->ico_informed = FALSE;
-@@ -3599,24 +3599,24 @@ static int gaim_parse_oncoming(aim_sessi
- if (info->iconcsumlen) {
- const char *filename = NULL, *saved_b16 = NULL;
- char *b16 = NULL, *filepath = NULL;
-- GaimBuddy *b = NULL;
-+ Gaim2Buddy *b = NULL;
-
-- b16 = gaim_base16_encode(info->iconcsum, info->iconcsumlen);
-- b = gaim_find_buddy(account, info->sn);
-+ b16 = gaim2_base16_encode(info->iconcsum, info->iconcsumlen);
-+ b = gaim2_find_buddy(account, info->sn);
- /*
- * If for some reason the checksum is valid, but cached file is not..
- * we want to know.
- */
-- filename = gaim_blist_node_get_string((GaimBlistNode*)b, "buddy_icon");
-+ filename = gaim2_blist_node_get_string((Gaim2BlistNode*)b, "buddy_icon");
- if (filename != NULL) {
- if (g_file_test(filename, G_FILE_TEST_EXISTS))
-- saved_b16 = gaim_blist_node_get_string((GaimBlistNode*)b,
-+ saved_b16 = gaim2_blist_node_get_string((Gaim2BlistNode*)b,
- "icon_checksum");
- else {
-- filepath = g_build_filename(gaim_buddy_icons_get_cache_dir(),
-+ filepath = g_build_filename(gaim2_buddy_icons_get_cache_dir(),
- filename, NULL);
- if (g_file_test(filepath, G_FILE_TEST_EXISTS))
-- saved_b16 = gaim_blist_node_get_string((GaimBlistNode*)b,
-+ saved_b16 = gaim2_blist_node_get_string((Gaim2BlistNode*)b,
- "icon_checksum");
- g_free(filepath);
- }
-@@ -3628,10 +3628,10 @@ static int gaim_parse_oncoming(aim_sessi
- while (cur && aim_sncmp((char *)cur->data, info->sn))
- cur = cur->next;
- if (!cur) {
-- od->requesticon = g_slist_append(od->requesticon, g_strdup(gaim_normalize(account, info->sn)));
-+ od->requesticon = g_slist_append(od->requesticon, g_strdup(gaim2_normalize(account, info->sn)));
- if (od->icontimer)
-- gaim_timeout_remove(od->icontimer);
-- od->icontimer = gaim_timeout_add(500, gaim_icon_timerfunc, gc);
-+ gaim2_timeout_remove(od->icontimer);
-+ od->icontimer = gaim2_timeout_add(500, gaim2_icon_timerfunc, gc);
- }
- }
- g_free(b16);
-@@ -3640,17 +3640,17 @@ static int gaim_parse_oncoming(aim_sessi
- return 1;
- }
-
--static void gaim_check_comment(OscarData *od, const char *str) {
-+static void gaim2_check_comment(OscarData *od, const char *str) {
- if ((str == NULL) || strcmp(str, (const char *)ck))
- aim_locate_setcaps(od->sess, caps_aim);
- else
- aim_locate_setcaps(od->sess, caps_aim | AIM_CAPS_SECUREIM);
- }
-
--static int gaim_parse_offgoing(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_parse_offgoing(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- va_list ap;
- aim_userinfo_t *info;
-
-@@ -3658,9 +3658,9 @@ static int gaim_parse_offgoing(aim_sessi
- info = va_arg(ap, aim_userinfo_t *);
- va_end(ap);
-
-- gaim_prpl_got_user_status(account, info->sn, OSCAR_STATUS_ID_OFFLINE, NULL);
-+ gaim2_prpl_got_user_status(account, info->sn, OSCAR_STATUS_ID_OFFLINE, NULL);
-
-- g_hash_table_remove(od->buddyinfo, gaim_normalize(gc->account, info->sn));
-+ g_hash_table_remove(od->buddyinfo, gaim2_normalize(gc->account, info->sn));
-
- return 1;
- }
-@@ -3673,14 +3673,14 @@ static int gaim_parse_offgoing(aim_sessi
- * add a callback or two, and then send the AIM_CB_OFT_PROMPT.
- */
- static int oscar_sendfile_estblsh(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
- va_list ap;
- aim_conn_t *conn, *listenerconn;
-
-- gaim_debug_info("oscar", "AAA - in oscar_sendfile_estblsh\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_sendfile_estblsh\n");
-
- va_start(ap, fr);
- conn = va_arg(ap, aim_conn_t *);
-@@ -3691,12 +3691,12 @@ static int oscar_sendfile_estblsh(aim_se
- * Finding by listenerconn will work for direct connections only */
- if (!(xfer = oscar_find_xfer_by_conn(od->file_transfers, conn))) {
- if(!(xfer = oscar_find_xfer_by_conn(od->file_transfers, listenerconn))) {
-- gaim_debug_warning("oscar","xfer not found via connection\n");
-+ gaim2_debug_warning("oscar","xfer not found via connection\n");
- return 1;
- }
- }
- if (!(oft_info = xfer->data)) {
-- gaim_debug_warning("oscar","NULL data\n");
-+ gaim2_debug_warning("oscar","NULL data\n");
- return 1;
- }
-
-@@ -3706,7 +3706,7 @@ static int oscar_sendfile_estblsh(aim_se
-
- if(oft_info->method != AIM_XFER_PROXY) {
- /* Stop watching listener conn; watch transfer conn instead */
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
-
- aim_conn_kill(sess, &listenerconn);
-
-@@ -3714,7 +3714,7 @@ static int oscar_sendfile_estblsh(aim_se
- xfer->fd = oft_info->conn->fd;
- }
-
-- xfer->watcher = gaim_input_add(oft_info->conn->fd, GAIM_INPUT_READ, oscar_callback, oft_info->conn);
-+ xfer->watcher = gaim2_input_add(oft_info->conn->fd, GAIM_INPUT_READ, oscar_callback, oft_info->conn);
-
- if(oft_info->send_or_recv == AIM_XFER_SEND) {
- aim_conn_addhandler(oft_info->sess, oft_info->conn, AIM_CB_FAM_OFT, AIM_CB_OFT_ACK,
-@@ -3733,28 +3733,28 @@ static int oscar_sendfile_estblsh(aim_se
- }
-
- /*
-- * This is the gaim callback passed to gaim_proxy_connect when connecting to another AIM
-+ * This is the gaim2 callback passed to gaim2_proxy_connect when connecting to another AIM
- * user in order to transfer a file
- * Takes xfer as data and fd as source
- * BBB
- */
--static void oscar_sendfile_connected(gpointer data, gint source, GaimInputCondition condition) {
-- GaimXfer *xfer;
-+static void oscar_sendfile_connected(gpointer data, gint source, Gaim2InputCondition condition) {
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "AAA - in oscar_sendfile_connected\n");
- if (!(xfer = data))
- return;
- if (!(oft_info = xfer->data))
- return;
- if(oft_info->success) {
-- gaim_debug_info("oscar","connection already successful; ignoring 2nd conn\n");
-+ gaim2_debug_info("oscar","connection already successful; ignoring 2nd conn\n");
- return;
- }
- if (source < 0) {
-- gaim_debug_info("oscar","received fd of %d; aborting transfer\n", source);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_debug_info("oscar","received fd of %d; aborting transfer\n", source);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
- oft_info->success = TRUE; /* Mark this connection as successful before it times out */
-@@ -3766,7 +3766,7 @@ static void oscar_sendfile_connected(gpo
-
- aim_conn_completeconnect(oft_info->sess, oft_info->conn);
-
-- xfer->watcher = gaim_input_add(xfer->fd, GAIM_INPUT_READ, oscar_callback, oft_info->conn);
-+ xfer->watcher = gaim2_input_add(xfer->fd, GAIM_INPUT_READ, oscar_callback, oft_info->conn);
-
- /* Inform the other user that we are connected and accept the transfer
- * Except for a stage 2 receive, then we'll be the ones receiving this accept message */
-@@ -3793,16 +3793,16 @@ static void oscar_sendfile_connected(gpo
- * get like totally ready to like, receive the file, kay?
- */
- static int oscar_sendfile_prompt(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
- va_list ap;
- aim_conn_t *conn;
- fu8_t *cookie;
- struct aim_fileheader_t *fh;
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "AAA - in oscar_sendfile_prompt\n");
-
- va_start(ap, fr);
-@@ -3818,7 +3818,7 @@ static int oscar_sendfile_prompt(aim_ses
- return 1;
-
- /* We want to stop listening with a normal thingy */
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
-
- /* They sent us some information about the file they're sending */
-@@ -3829,7 +3829,7 @@ static int oscar_sendfile_prompt(aim_ses
-
- /* XXX - convert the name from UTF-8 to UCS-2 if necessary, and pass the encoding to the call below */
- aim_oft_sendheader(oft_info->sess, AIM_CB_OFT_ACK, oft_info);
-- gaim_xfer_start(xfer, xfer->fd, NULL, 0);
-+ gaim2_xfer_start(xfer, xfer->fd, NULL, 0);
-
- return 0;
- }
-@@ -3839,15 +3839,15 @@ static int oscar_sendfile_prompt(aim_ses
- * prompt, so we want to start sending data like there's no tomorrow.
- */
- static int oscar_sendfile_ack(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- va_list ap;
- aim_conn_t *conn;
- fu8_t *cookie;
- struct aim_fileheader_t *fh;
-
-- gaim_debug_info("oscar", "AAA - in oscar_sendfile_ack\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_sendfile_ack\n");
- va_start(ap, fr);
- conn = va_arg(ap, aim_conn_t *);
- cookie = va_arg(ap, fu8_t *);
-@@ -3858,10 +3858,10 @@ static int oscar_sendfile_ack(aim_sessio
- return 1;
-
- /* We want to stop listening with a normal thingy */
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- xfer->watcher = 0;
-
-- gaim_xfer_start(xfer, xfer->fd, NULL, 0);
-+ gaim2_xfer_start(xfer, xfer->fd, NULL, 0);
-
- return 0;
- }
-@@ -3871,16 +3871,16 @@ static int oscar_sendfile_ack(aim_sessio
- * so we can close our direct connection and what not.
- */
- static int oscar_sendfile_done(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- va_list ap;
- aim_conn_t *conn;
- fu8_t *cookie;
- struct aim_fileheader_t *fh;
- struct aim_oft_info *oft_info;
-
-- gaim_debug_info("oscar", "AAA - in oscar_sendfile_done\n");
-+ gaim2_debug_info("oscar", "AAA - in oscar_sendfile_done\n");
- va_start(ap, fr);
- conn = va_arg(ap, aim_conn_t *);
- cookie = va_arg(ap, fu8_t *);
-@@ -3888,27 +3888,27 @@ static int oscar_sendfile_done(aim_sessi
- va_end(ap);
-
- if (!(xfer = oscar_find_xfer_by_conn(od->file_transfers, conn))) {
-- gaim_debug_warning("oscar","xfer not found\n");
-+ gaim2_debug_warning("oscar","xfer not found\n");
- return 1;
- }
- if(!(oft_info = xfer->data)) {
-- gaim_debug_warning("oscar","NULL oft_info\n");
-+ gaim2_debug_warning("oscar","NULL oft_info\n");
- return 1;
- }
- if(fh->nrecvd == fh->size)
-- gaim_xfer_set_completed(xfer, TRUE);
-+ gaim2_xfer_set_completed(xfer, TRUE);
-
- xfer->fd = conn->fd;
-- gaim_xfer_end(xfer);
-+ gaim2_xfer_end(xfer);
-
- return 0;
- }
-
- static int incomingim_chan1(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch1_args *args) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimMessageFlags flags = 0;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2MessageFlags flags = 0;
- struct buddyinfo *bi;
- char *iconfile;
- GString *message;
-@@ -3918,16 +3918,16 @@ static int incomingim_chan1(aim_session_
- const char *end;
- GData *attribs;
-
-- gaim_debug_misc("oscar", "Received IM from %s with %d parts\n",
-+ gaim2_debug_misc("oscar", "Received IM from %s with %d parts\n",
- userinfo->sn, args->mpmsg.numparts);
-
- if (args->mpmsg.numparts == 0)
- return 1;
-
-- bi = g_hash_table_lookup(od->buddyinfo, gaim_normalize(account, userinfo->sn));
-+ bi = g_hash_table_lookup(od->buddyinfo, gaim2_normalize(account, userinfo->sn));
- if (!bi) {
- bi = g_new0(struct buddyinfo, 1);
-- g_hash_table_insert(od->buddyinfo, g_strdup(gaim_normalize(account, userinfo->sn)), bi);
-+ g_hash_table_insert(od->buddyinfo, g_strdup(gaim2_normalize(account, userinfo->sn)), bi);
- }
-
- if (args->icbmflags & AIM_IMFLAGS_AWAY)
-@@ -3939,7 +3939,7 @@ static int incomingim_chan1(aim_session_
- bi->typingnot = FALSE;
-
- if ((args->icbmflags & AIM_IMFLAGS_HASICON) && (args->iconlen) && (args->iconsum) && (args->iconstamp)) {
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "%s has an icon\n", userinfo->sn);
- if ((args->iconlen != bi->ico_len) || (args->iconsum != bi->ico_csum) || (args->iconstamp != bi->ico_time)) {
- bi->ico_need = TRUE;
-@@ -3949,7 +3949,7 @@ static int incomingim_chan1(aim_session_
- }
- }
-
-- iconfile = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(account));
-+ iconfile = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(account));
- if ((iconfile != NULL) &&
- (args->icbmflags & AIM_IMFLAGS_BUDDYREQ) && !bi->ico_sent && bi->ico_informed) {
- FILE *file;
-@@ -3961,7 +3961,7 @@ static int incomingim_chan1(aim_session_
- if (file) {
- /* XXX - Use g_file_get_contents() */
- int len = fread(buf, 1, st.st_size, file);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Sending buddy icon to %s (%d bytes, "
- "%lu reported)\n",
- userinfo->sn, len, st.st_size);
-@@ -3969,11 +3969,11 @@ static int incomingim_chan1(aim_session_
- st.st_mtime, aimutil_iconsum(buf, st.st_size));
- fclose(file);
- } else
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't open buddy icon file!\n");
- g_free(buf);
- } else
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't stat buddy icon file!\n");
- }
- g_free(iconfile);
-@@ -3981,7 +3981,7 @@ static int incomingim_chan1(aim_session_
- message = g_string_new("");
- curpart = args->mpmsg.parts;
- while (curpart != NULL) {
-- tmp = gaim_plugin_oscar_decode_im_part(account, userinfo->sn, curpart->charset,
-+ tmp = gaim2_plugin_oscar_decode_im_part(account, userinfo->sn, curpart->charset,
- curpart->charsubset, curpart->data, curpart->datalen);
- if (tmp != NULL) {
- g_string_append(message, tmp);
-@@ -4001,12 +4001,12 @@ static int incomingim_chan1(aim_session_
- * Note: There *may* be some clients which send messages as HTML formatted -
- * they need to be special-cased somehow.
- */
-- if (aim_sn_is_icq(gaim_account_get_username(account)) && aim_sn_is_icq(userinfo->sn)) {
-+ if (aim_sn_is_icq(gaim2_account_get_username(account)) && aim_sn_is_icq(userinfo->sn)) {
- /* being recevied by ICQ from ICQ - escape HTML so it is displayed as sent */
- gchar *tmp2 = g_markup_escape_text(tmp, -1);
- g_free(tmp);
- tmp = tmp2;
-- tmp2 = gaim_strreplace(tmp, "\r\n", "<br>");
-+ tmp2 = gaim2_strreplace(tmp, "\r\n", "<br>");
- g_free(tmp);
- tmp = tmp2;
- }
-@@ -4014,7 +4014,7 @@ static int incomingim_chan1(aim_session_
- /*
- * Convert iChat color tags to normal font tags.
- */
-- if (gaim_markup_find_tag("body", tmp, &start, &end, &attribs))
-+ if (gaim2_markup_find_tag("body", tmp, &start, &end, &attribs))
- {
- const char *ichattextcolor, *ichatballooncolor;
-
-@@ -4046,8 +4046,8 @@ static int incomingim_chan1(aim_session_
- }
-
- static int incomingim_chan2(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args) {
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- OscarData *od;
- const char *username = NULL;
- char *message = NULL;
-@@ -4056,14 +4056,14 @@ static int incomingim_chan2(aim_session_
- g_return_val_if_fail(sess->aux_data != NULL, 0);
-
- gc = sess->aux_data;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- od = gc->proto_data;
-- username = gaim_account_get_username(account);
-+ username = gaim2_account_get_username(account);
-
- if (args == NULL)
- return 0;
-
-- gaim_debug_misc("oscar", "rendezvous with %s, status is %hu\n",
-+ gaim2_debug_misc("oscar", "rendezvous with %s, status is %hu\n",
- userinfo->sn, args->status);
-
- if (args->msg != NULL)
-@@ -4107,7 +4107,7 @@ static int incomingim_chan2(aim_session_
- if (args->status == AIM_RENDEZVOUS_PROPOSE
- && (args->info.sendfile.reqnum == 0x0001)) {
- /* Someone wants to send a file (or files) to us */
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
- struct aim_rv_proxy_info *proxy_info = NULL;
- gboolean use_rv_proxy;
-@@ -4118,7 +4118,7 @@ static int incomingim_chan2(aim_session_
- if (!args->cookie || !args->port ||
- !args->info.sendfile.filename || !args->info.sendfile.totsize ||
- !args->info.sendfile.totfiles || !args->reqclass) {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "%s tried to send you a file with incomplete "
- "information.\n", userinfo->sn);
- g_free(message);
-@@ -4133,21 +4133,21 @@ static int incomingim_chan2(aim_session_
- if (tmp && (tmp[1] == '*')) {
- tmp[0] = '\0';
- }
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "We're receiving a whole directory! What fun! "
- "Especially since we don't support that!\n");
- }
-
- /* Build the file transfer handle */
-- xfer = gaim_xfer_new(gc->account, GAIM_XFER_RECEIVE, userinfo->sn);
-+ xfer = gaim2_xfer_new(gc->account, GAIM_XFER_RECEIVE, userinfo->sn);
-
-- use_rv_proxy = gaim_prefs_get_bool("/plugins/prpl/oscar/use_rv_proxy");
-+ use_rv_proxy = gaim2_prefs_get_bool("/plugins/prpl/oscar/use_rv_proxy");
-
- if(args->info.sendfile.use_proxy) {
- /* The sender requested (stage 1) that we use a rendezvous proxy */
- xfer_method = AIM_XFER_PROXY;
- proxy_stage = AIM_XFER_PROXY_STG1;
-- gaim_debug_info("oscar","using stage 1 proxy with ip: %s\n",
-+ gaim2_debug_info("oscar","using stage 1 proxy with ip: %s\n",
- args->proxyip, args->port);
- xfer->remote_ip = g_strdup(args->proxyip);
- xfer->remote_port = AIM_RV_PROXY_CONNECT_PORT;
-@@ -4155,10 +4155,10 @@ static int incomingim_chan2(aim_session_
- } else if(use_rv_proxy) {
- /* If the local user indicated that a rendezvous proxy is necessary
- * start a stage 2 proxied transfer */
-- gaim_debug_info("oscar","using stage 2 proxied transfer\n");
-+ gaim2_debug_info("oscar","using stage 2 proxied transfer\n");
- xfer_method = AIM_XFER_PROXY;
- proxy_stage = AIM_XFER_PROXY_STG2;
-- /* This hostname will be resolved by gaim_proxy_connect */
-+ /* This hostname will be resolved by gaim2_proxy_connect */
- xfer->remote_ip = g_strdup(AIM_RV_PROXY_SERVER_URL);
- xfer->remote_port = AIM_RV_PROXY_CONNECT_PORT;
- proxy_info = aim_rv_proxy_createinfo(od->sess, args->cookie, 0);
-@@ -4173,16 +4173,16 @@ static int incomingim_chan2(aim_session_
- /* Use UTF8 so that the world will be a happier place */
- if (g_utf8_validate(args->info.sendfile.filename, -1,
- NULL)) {
-- gaim_xfer_set_filename(xfer,
-+ gaim2_xfer_set_filename(xfer,
- args->info.sendfile.filename);
- } else {
-- gchar * utf8_filename = gaim_utf8_salvage(
-+ gchar * utf8_filename = gaim2_utf8_salvage(
- args->info.sendfile.filename);
-- gaim_xfer_set_filename(xfer, utf8_filename);
-+ gaim2_xfer_set_filename(xfer, utf8_filename);
- g_free(utf8_filename);
- }
-
-- gaim_xfer_set_size(xfer, args->info.sendfile.totsize);
-+ gaim2_xfer_set_size(xfer, args->info.sendfile.totsize);
-
- /* Ignore messages that start with <ICQ_COOL_FT> (XML that is sent along
- * with ICQ sendfile requests) & <HTML> message that is sent with AOL file
-@@ -4190,11 +4190,11 @@ static int incomingim_chan2(aim_session_
- * is <HTML>, but not if it starts with <HTML> */
- if(message && ( g_ascii_strncasecmp(message,"<ICQ_COOL_FT>",13) < 0
- || g_ascii_strcasecmp(message,"<HTML>") == 0) ) {
-- gaim_debug_info("oscar","Ignoring file transfer message: %s\n", message);
-+ gaim2_debug_info("oscar","Ignoring file transfer message: %s\n", message);
- g_free(message);
- message = NULL;
- }
-- gaim_xfer_set_message(xfer, message);
-+ gaim2_xfer_set_message(xfer, message);
-
- /* Create the oscar-specific data */
- oft_info = aim_oft_createinfo(od->sess, args->cookie, userinfo->sn, args->clientip,
-@@ -4211,33 +4211,33 @@ static int incomingim_chan2(aim_session_
- xfer->data = oft_info;
-
- /* Setup our I/O op functions */
-- gaim_xfer_set_init_fnc(xfer, oscar_xfer_init_recv);
-- gaim_xfer_set_end_fnc(xfer, oscar_xfer_end);
-- gaim_xfer_set_request_denied_fnc(xfer, oscar_xfer_cancel_recv);
-- gaim_xfer_set_cancel_recv_fnc(xfer, oscar_xfer_cancel_recv);
-- gaim_xfer_set_ack_fnc(xfer, oscar_xfer_ack_recv);
-+ gaim2_xfer_set_init_fnc(xfer, oscar_xfer_init_recv);
-+ gaim2_xfer_set_end_fnc(xfer, oscar_xfer_end);
-+ gaim2_xfer_set_request_denied_fnc(xfer, oscar_xfer_cancel_recv);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, oscar_xfer_cancel_recv);
-+ gaim2_xfer_set_ack_fnc(xfer, oscar_xfer_ack_recv);
-
- /* Keep track of this transfer for later */
- od->file_transfers = g_slist_append(od->file_transfers, xfer);
-
- /* Now perform the request */
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- /* A secondary request has been sent to negotiate the connection method */
- } else if (args->status == AIM_RENDEZVOUS_PROPOSE && args->info.sendfile.reqnum == 0x0002) {
- /* We have asked to send a file to someone else, but they sent us a reply request
- * asking us to use an alternative method of connecting */
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
-
- if ((xfer = oscar_find_xfer_by_cookie(od->file_transfers, args->cookie))) {
- oft_info = xfer->data;
-
- /* Stop the listener connection */
-- gaim_input_remove(xfer->watcher);
-+ gaim2_input_remove(xfer->watcher);
- aim_conn_kill(sess, &oft_info->conn); /* This is currently the listener */
-
- if(args->info.sendfile.use_proxy) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "received request for stage 2 rv proxy with ip: %s\n",
- args->proxyip);
- oft_info->method = AIM_XFER_PROXY;
-@@ -4252,13 +4252,13 @@ static int incomingim_chan2(aim_session_
- xfer->remote_port = AIM_RV_PROXY_CONNECT_PORT;
- oscar_xfer_init_recv(xfer);
- } else {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "stage 2 rv proxy file send: no proxy ip specified\n");
- }
- } else if(args->clientip
- && g_ascii_strcasecmp(args->clientip,"0.0.0.0") == 0)
- {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "other client wants us to send stage 3 proxy info\n");
- oft_info->method = AIM_XFER_PROXY;
- oft_info->stage = AIM_XFER_PROXY_STG3;
-@@ -4267,7 +4267,7 @@ static int incomingim_chan2(aim_session_
- oft_info->clientip = NULL;
- oft_info->verifiedip = NULL;
-
-- /* This hostname will be resolved in gaim_proxy_connect */
-+ /* This hostname will be resolved in gaim2_proxy_connect */
- xfer->remote_ip = g_strdup(AIM_RV_PROXY_SERVER_URL);
- xfer->remote_port = AIM_RV_PROXY_CONNECT_PORT;
-
-@@ -4275,7 +4275,7 @@ static int incomingim_chan2(aim_session_
- = aim_rv_proxy_createinfo(od->sess, args->cookie, 0);
- oscar_xfer_init_recv(xfer);
- } else {
-- gaim_debug_info("oscar","received request to redirect transfer; clientip/verifiedip: %s / %s\n",
-+ gaim2_debug_info("oscar","received request to redirect transfer; clientip/verifiedip: %s / %s\n",
- args->clientip, args->verifiedip);
- oft_info->method = AIM_XFER_REDIR;
- if (args->verifiedip)
-@@ -4290,7 +4290,7 @@ static int incomingim_chan2(aim_session_
- oscar_xfer_init_recv(xfer);
- }
- } else {
-- gaim_debug_warning("oscar","received file tranfer reply request: xfer not found\n");
-+ gaim2_debug_warning("oscar","received file tranfer reply request: xfer not found\n");
- }
- /* A THIRD request has been sent trying to figure out what connection method will be used
- * to transfer this file */
-@@ -4298,14 +4298,14 @@ static int incomingim_chan2(aim_session_
- /* We are receiving a file from someone. We sent a request to use a stage 3
- * proxy. They did the initial proxy login and have sent us the info in a
- * third file transfer request. */
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct aim_oft_info *oft_info;
-
- if ((xfer = oscar_find_xfer_by_cookie(od->file_transfers, args->cookie))) {
- oft_info = xfer->data;
-
- /* We are receiving a file */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "other client sent us stage 3 proxy info\n");
-
- /* The following pieces of information should already have
-@@ -4323,19 +4323,19 @@ static int incomingim_chan2(aim_session_
- xfer->remote_port = AIM_RV_PROXY_CONNECT_PORT;
- oscar_xfer_init_recv(xfer);
- } else {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "stage 3 rv proxy file receive: no proxy ip specified\n");
- }
- } else {
-- gaim_debug_warning("oscar","received file tranfer reply request: xfer not found\n");
-+ gaim2_debug_warning("oscar","received file tranfer reply request: xfer not found\n");
- }
- } else if (args->status == AIM_RENDEZVOUS_CANCEL) {
- /* The other user wants to cancel a file transfer */
-- GaimXfer *xfer;
-- gaim_debug_info("oscar",
-+ Gaim2Xfer *xfer;
-+ gaim2_debug_info("oscar",
- "AAA - File transfer canceled by remote user\n");
- if ((xfer = oscar_find_xfer_by_cookie(od->file_transfers, args->cookie)))
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- } else if (args->status == AIM_RENDEZVOUS_ACCEPT) {
- /*
- * This gets sent by the receiver of a file
-@@ -4343,16 +4343,16 @@ static int incomingim_chan2(aim_session_
- * get this, then maybe a third party connected
- * to us, and we shouldn't send them anything.
- */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "AAA - received chan 2 AIM_RENDEZVOUS_ACCEPT; ignoring\n");
- } else {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "unknown rendezvous status!\n");
- }
- } else if (args->reqclass & AIM_CAPS_GETFILE) {
- } else if (args->reqclass & AIM_CAPS_TALK) {
- } else if (args->reqclass & AIM_CAPS_BUDDYICON) {
-- gaim_buddy_icons_set_for_user(account, userinfo->sn,
-+ gaim2_buddy_icons_set_for_user(account, userinfo->sn,
- args->info.icon.icon,
- args->info.icon.length);
- } else if (args->reqclass & AIM_CAPS_DIRECTIM) {
-@@ -4363,13 +4363,13 @@ static int incomingim_chan2(aim_session_
-
- if (!args->verifiedip) {
- /* TODO: do something about this, after figuring out what it means */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "directim kill blocked (%s)\n", userinfo->sn);
- g_free(message);
- return 1;
- }
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "%s received direct im request from %s (%s)\n",
- username, userinfo->sn, args->verifiedip);
-
-@@ -4396,11 +4396,11 @@ static int incomingim_chan2(aim_session_
- accept_direct_im_request(d);
- } else {
- if (dim && !dim->connected)
-- gaim_debug_warning("oscar", "DirectIM: received direct im request while "
-+ gaim2_debug_warning("oscar", "DirectIM: received direct im request while "
- "already connected to that buddy!");
- g_snprintf(buf, sizeof buf, _("%s has just asked to directly connect to %s"), userinfo->sn, username);
-
-- gaim_request_action(gc, NULL, buf,
-+ gaim2_request_action(gc, NULL, buf,
- _("This requires a direct connection between "
- "the two computers and is necessary for IM "
- "Images. Because your IP address will be "
-@@ -4412,9 +4412,9 @@ static int incomingim_chan2(aim_session_
- /* FIXME: we should actually send a packet on cancel */
- }
- } else if (args->reqclass & AIM_CAPS_ICQSERVERRELAY) {
-- gaim_debug_error("oscar", "Got an ICQ Server Relay message of type %d\n", args->info.rtfmsg.msgtype);
-+ gaim2_debug_error("oscar", "Got an ICQ Server Relay message of type %d\n", args->info.rtfmsg.msgtype);
- } else {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Unknown reqclass %hu\n", args->reqclass);
- }
-
-@@ -4429,53 +4429,53 @@ static int incomingim_chan2(aim_session_
- * methods of authorization (SSI and old-school channel 4 ICBM)
- */
- /* When you ask other people for authorization */
--static void gaim_auth_request(struct name_data *data, char *msg) {
-- GaimConnection *gc = data->gc;
-+static void gaim2_auth_request(struct name_data *data, char *msg) {
-+ Gaim2Connection *gc = data->gc;
-
-- if (g_list_find(gaim_connections_get_all(), gc)) {
-+ if (g_list_find(gaim2_connections_get_all(), gc)) {
- OscarData *od = gc->proto_data;
-- GaimBuddy *buddy = gaim_find_buddy(gc->account, data->name);
-- GaimGroup *group = gaim_buddy_get_group(buddy);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(gc->account, data->name);
-+ Gaim2Group *group = gaim2_buddy_get_group(buddy);
- if (buddy && group) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: adding buddy %s to group %s\n",
- buddy->name, group->name);
- aim_ssi_sendauthrequest(od->sess, data->name, msg ? msg : _("Please authorize me so I can add you to my buddy list."));
- if (!aim_ssi_itemlist_finditem(od->sess->ssi.local, group->name, buddy->name, AIM_SSI_TYPE_BUDDY))
-- aim_ssi_addbuddy(od->sess, buddy->name, group->name, gaim_buddy_get_alias_only(buddy), NULL, NULL, 1);
-+ aim_ssi_addbuddy(od->sess, buddy->name, group->name, gaim2_buddy_get_alias_only(buddy), NULL, NULL, 1);
- }
- }
- }
-
--static void gaim_auth_request_msgprompt(struct name_data *data) {
-- gaim_request_input(data->gc, NULL, _("Authorization Request Message:"),
-+static void gaim2_auth_request_msgprompt(struct name_data *data) {
-+ gaim2_request_input(data->gc, NULL, _("Authorization Request Message:"),
- NULL, _("Please authorize me!"), TRUE, FALSE, NULL,
-- _("OK"), G_CALLBACK(gaim_auth_request),
-+ _("OK"), G_CALLBACK(gaim2_auth_request),
- _("Cancel"), G_CALLBACK(oscar_free_name_data),
- data);
- }
-
--static void gaim_auth_dontrequest(struct name_data *data) {
-- GaimConnection *gc = data->gc;
-+static void gaim2_auth_dontrequest(struct name_data *data) {
-+ Gaim2Connection *gc = data->gc;
-
-- if (g_list_find(gaim_connections_get_all(), gc)) {
-+ if (g_list_find(gaim2_connections_get_all(), gc)) {
- /* Remove from local list */
-- GaimBuddy *b = gaim_find_buddy(gaim_connection_get_account(gc), data->name);
-- gaim_blist_remove_buddy(b);
-+ Gaim2Buddy *b = gaim2_find_buddy(gaim2_connection_get_account(gc), data->name);
-+ gaim2_blist_remove_buddy(b);
- }
-
- oscar_free_name_data(data);
- }
-
-
--static void gaim_auth_sendrequest(GaimConnection *gc, char *name) {
-+static void gaim2_auth_sendrequest(Gaim2Connection *gc, char *name) {
- struct name_data *data = g_new(struct name_data, 1);
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- gchar *dialog_msg, *nombre;
-
-- buddy = gaim_find_buddy(gc->account, name);
-- if (buddy && (gaim_buddy_get_alias_only(buddy)))
-- nombre = g_strdup_printf("%s (%s)", name, gaim_buddy_get_alias_only(buddy));
-+ buddy = gaim2_find_buddy(gc->account, name);
-+ if (buddy && (gaim2_buddy_get_alias_only(buddy)))
-+ nombre = g_strdup_printf("%s (%s)", name, gaim2_buddy_get_alias_only(buddy));
- else
- nombre = NULL;
-
-@@ -4484,33 +4484,33 @@ static void gaim_auth_sendrequest(GaimCo
- data->name = g_strdup(name);
- data->nick = NULL;
-
-- gaim_request_action(gc, NULL, _("Request Authorization"), dialog_msg,
-+ gaim2_request_action(gc, NULL, _("Request Authorization"), dialog_msg,
- 0, data, 2,
- _("_Request Authorization"),
-- G_CALLBACK(gaim_auth_request_msgprompt),
-- _("Cancel"), G_CALLBACK(gaim_auth_dontrequest));
-+ G_CALLBACK(gaim2_auth_request_msgprompt),
-+ _("Cancel"), G_CALLBACK(gaim2_auth_dontrequest));
-
- g_free(dialog_msg);
- g_free(nombre);
- }
-
-
--static void gaim_auth_sendrequest_menu(GaimBlistNode *node, gpointer ignored) {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+static void gaim2_auth_sendrequest_menu(Gaim2BlistNode *node, gpointer ignored) {
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-- gaim_auth_sendrequest(gc, buddy->name);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-+ gaim2_auth_sendrequest(gc, buddy->name);
- }
-
- /* When other people ask you for authorization */
--static void gaim_auth_grant(struct name_data *data) {
-- GaimConnection *gc = data->gc;
-+static void gaim2_auth_grant(struct name_data *data) {
-+ Gaim2Connection *gc = data->gc;
-
-- if (g_list_find(gaim_connections_get_all(), gc)) {
-+ if (g_list_find(gaim2_connections_get_all(), gc)) {
- OscarData *od = gc->proto_data;
- aim_ssi_sendauthreply(od->sess, data->name, 0x01, NULL);
- }
-@@ -4519,44 +4519,44 @@ static void gaim_auth_grant(struct name_
- }
-
- /* When other people ask you for authorization */
--static void gaim_auth_dontgrant(struct name_data *data, char *msg) {
-- GaimConnection *gc = data->gc;
-+static void gaim2_auth_dontgrant(struct name_data *data, char *msg) {
-+ Gaim2Connection *gc = data->gc;
-
-- if (g_list_find(gaim_connections_get_all(), gc)) {
-+ if (g_list_find(gaim2_connections_get_all(), gc)) {
- OscarData *od = gc->proto_data;
- aim_ssi_sendauthreply(od->sess, data->name, 0x00, msg ? msg : _("No reason given."));
- }
- }
-
--static void gaim_auth_dontgrant_msgprompt(struct name_data *data) {
-- gaim_request_input(data->gc, NULL, _("Authorization Denied Message:"),
-+static void gaim2_auth_dontgrant_msgprompt(struct name_data *data) {
-+ gaim2_request_input(data->gc, NULL, _("Authorization Denied Message:"),
- NULL, _("No reason given."), TRUE, FALSE, NULL,
-- _("OK"), G_CALLBACK(gaim_auth_dontgrant),
-+ _("OK"), G_CALLBACK(gaim2_auth_dontgrant),
- _("Cancel"), G_CALLBACK(oscar_free_name_data),
- data);
- }
-
- /* When someone sends you buddies */
--static void gaim_icq_buddyadd(struct name_data *data) {
-- GaimConnection *gc = data->gc;
-+static void gaim2_icq_buddyadd(struct name_data *data) {
-+ Gaim2Connection *gc = data->gc;
-
-- if (g_list_find(gaim_connections_get_all(), gc)) {
-- gaim_blist_request_add_buddy(gaim_connection_get_account(gc), data->name, NULL, data->nick);
-+ if (g_list_find(gaim2_connections_get_all(), gc)) {
-+ gaim2_blist_request_add_buddy(gaim2_connection_get_account(gc), data->name, NULL, data->nick);
- }
-
- oscar_free_name_data(data);
- }
-
- static int incomingim_chan4(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch4_args *args, time_t t) {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- gchar **msg1, **msg2;
- int i, numtoks;
-
- if (!args->type || !args->msg || !args->uin)
- return 1;
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Received a channel 4 message of type 0x%02hhx.\n",
- args->type);
-
-@@ -4573,8 +4573,8 @@ static int incomingim_chan4(aim_session_
- for (numtoks=0; msg1[numtoks]; numtoks++);
- msg2 = (gchar **)g_malloc((numtoks+1)*sizeof(gchar *));
- for (i=0; msg1[i]; i++) {
-- gaim_str_strip_char(msg1[i], '\r');
-- msg2[i] = gaim_plugin_oscar_decode_im_part(account, "1", AIM_CHARSET_ASCII, 0x0000, msg1[i], strlen(msg1[i]));
-+ gaim2_str_strip_char(msg1[i], '\r');
-+ msg2[i] = gaim2_plugin_oscar_decode_im_part(account, "1", AIM_CHARSET_ASCII, 0x0000, msg1[i], strlen(msg1[i]));
- }
- msg2[i] = NULL;
-
-@@ -4632,26 +4632,26 @@ static int incomingim_chan4(aim_session_
- gchar *dialog_msg;
-
- if (msg2[5] != NULL)
-- reason = gaim_plugin_oscar_decode_im_part(account, sn, AIM_CHARSET_CUSTOM, 0x0000, msg2[5], strlen(msg2[5]));
-+ reason = gaim2_plugin_oscar_decode_im_part(account, sn, AIM_CHARSET_CUSTOM, 0x0000, msg2[5], strlen(msg2[5]));
- else
- reason = g_strdup(_("No reason given."));
-
- dialog_msg = g_strdup_printf(_("The user %u wants to add %s to their buddy list for the following reason:\n%s"),
-- args->uin, gaim_account_get_username(gc->account), reason);
-+ args->uin, gaim2_account_get_username(gc->account), reason);
- g_free(reason);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Received an authorization request from UIN %u\n",
- args->uin);
- data->gc = gc;
- data->name = sn;
- data->nick = NULL;
-
-- gaim_request_action(gc, NULL, _("Authorization Request"),
-+ gaim2_request_action(gc, NULL, _("Authorization Request"),
- dialog_msg, GAIM_DEFAULT_ACTION_NONE, data,
- 2, _("_Authorize"),
-- G_CALLBACK(gaim_auth_grant),
-+ G_CALLBACK(gaim2_auth_grant),
- _("_Deny"),
-- G_CALLBACK(gaim_auth_dontgrant_msgprompt));
-+ G_CALLBACK(gaim2_auth_dontgrant_msgprompt));
- g_free(dialog_msg);
- }
- } break;
-@@ -4659,7 +4659,7 @@ static int incomingim_chan4(aim_session_
- case 0x07: { /* Someone has denied you authorization */
- if (i >= 1) {
- gchar *dialog_msg = g_strdup_printf(_("The user %u has denied your request to add them to your buddy list for the following reason:\n%s"), args->uin, msg2[0] ? msg2[0] : _("No reason given."));
-- gaim_notify_info(gc, NULL, _("ICQ authorization denied."),
-+ gaim2_notify_info(gc, NULL, _("ICQ authorization denied."),
- dialog_msg);
- g_free(dialog_msg);
- }
-@@ -4667,7 +4667,7 @@ static int incomingim_chan4(aim_session_
-
- case 0x08: { /* Someone has granted you authorization */
- gchar *dialog_msg = g_strdup_printf(_("The user %u has granted your request to add them to your buddy list."), args->uin);
-- gaim_notify_info(gc, NULL, "ICQ authorization accepted.",
-+ gaim2_notify_info(gc, NULL, "ICQ authorization accepted.",
- dialog_msg);
- g_free(dialog_msg);
- } break;
-@@ -4675,7 +4675,7 @@ static int incomingim_chan4(aim_session_
- case 0x09: { /* Message from the Godly ICQ server itself, I think */
- if (i >= 5) {
- gchar *dialog_msg = g_strdup_printf(_("You have received a special message\n\nFrom: %s [%s]\n%s"), msg2[0], msg2[3], msg2[5]);
-- gaim_notify_info(gc, NULL, "ICQ Server Message", dialog_msg);
-+ gaim2_notify_info(gc, NULL, "ICQ Server Message", dialog_msg);
- g_free(dialog_msg);
- }
- } break;
-@@ -4683,7 +4683,7 @@ static int incomingim_chan4(aim_session_
- case 0x0d: { /* Someone has sent you a pager message from http://www.icq.com/your_uin */
- if (i >= 6) {
- gchar *dialog_msg = g_strdup_printf(_("You have received an ICQ page\n\nFrom: %s [%s]\n%s"), msg2[0], msg2[3], msg2[5]);
-- gaim_notify_info(gc, NULL, "ICQ Page", dialog_msg);
-+ gaim2_notify_info(gc, NULL, "ICQ Page", dialog_msg);
- g_free(dialog_msg);
- }
- } break;
-@@ -4691,7 +4691,7 @@ static int incomingim_chan4(aim_session_
- case 0x0e: { /* Someone has emailed you at your_uin@pager.icq.com */
- if (i >= 6) {
- gchar *dialog_msg = g_strdup_printf(_("You have received an ICQ email from %s [%s]\n\nMessage is:\n%s"), msg2[0], msg2[3], msg2[5]);
-- gaim_notify_info(gc, NULL, "ICQ Email", dialog_msg);
-+ gaim2_notify_info(gc, NULL, "ICQ Email", dialog_msg);
- g_free(dialog_msg);
- }
- } break;
-@@ -4716,11 +4716,11 @@ static int incomingim_chan4(aim_session_
- data->name = g_strdup(text[i*2+1]);
- data->nick = g_strdup(text[i*2+2]);
-
-- gaim_request_action(gc, NULL, message,
-+ gaim2_request_action(gc, NULL, message,
- _("Do you want to add this buddy "
- "to your buddy list?"),
- GAIM_DEFAULT_ACTION_NONE, data, 2,
-- _("Add"), G_CALLBACK(gaim_icq_buddyadd),
-+ _("Add"), G_CALLBACK(gaim2_icq_buddyadd),
- _("_Decline"), G_CALLBACK(oscar_free_name_data));
- g_free(message);
- }
-@@ -4733,7 +4733,7 @@ static int incomingim_chan4(aim_session_
- } break;
-
- default: {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Received a channel 4 message of unknown type "
- "(type 0x%02hhx).\n", args->type);
- } break;
-@@ -4745,7 +4745,7 @@ static int incomingim_chan4(aim_session_
- return 1;
- }
-
--static int gaim_parse_incoming_im(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_incoming_im(aim_session_t *sess, aim_frame_t *fr, ...) {
- fu16_t channel;
- int ret = 0;
- aim_userinfo_t *userinfo;
-@@ -4775,7 +4775,7 @@ static int gaim_parse_incoming_im(aim_se
- } break;
-
- default: {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "ICBM received on unsupported channel (channel "
- "0x%04hx).", channel);
- } break;
-@@ -4786,9 +4786,9 @@ static int gaim_parse_incoming_im(aim_se
- return ret;
- }
-
--static int gaim_parse_misses(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+static int gaim2_parse_misses(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- char *buf;
- va_list ap;
- fu16_t chan, nummissed, reason;
-@@ -4858,28 +4858,28 @@ static int gaim_parse_misses(aim_session
- break;
- }
-
-- if (!gaim_conv_present_error(userinfo->sn, account, buf))
-- gaim_notify_error(sess->aux_data, NULL, buf, NULL);
-+ if (!gaim2_conv_present_error(userinfo->sn, account, buf))
-+ gaim2_notify_error(sess->aux_data, NULL, buf, NULL);
- g_free(buf);
-
- return 1;
- }
-
--static int gaim_parse_clientauto_ch2(aim_session_t *sess, const char *who, fu16_t reason, const guchar *cookie) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_parse_clientauto_ch2(aim_session_t *sess, const char *who, fu16_t reason, const guchar *cookie) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-
- /* BBB */
- switch (reason) {
- case 3: { /* Decline sendfile. */
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct oscar_direct_im *dim;
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "AAA - Other user declined some sort of direct "
- "connect attempt (automaticly?)\n");
- if ((xfer = oscar_find_xfer_by_cookie(od->file_transfers, cookie)))
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- else if ((dim = oscar_direct_im_find(od, who))) {
- /* AAA should use find by cookie or something here */
- oscar_direct_im_disconnect(od, dim);
-@@ -4887,7 +4887,7 @@ static int gaim_parse_clientauto_ch2(aim
- } break;
-
- default: {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "Received an unknown rendezvous client auto-response "
- "from %s. Type 0x%04hx\n", who, reason);
- }
-@@ -4897,8 +4897,8 @@ static int gaim_parse_clientauto_ch2(aim
- return 0;
- }
-
--static int gaim_parse_clientauto_ch4(aim_session_t *sess, char *who, fu16_t reason, fu32_t state, char *msg) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_parse_clientauto_ch4(aim_session_t *sess, char *who, fu16_t reason, fu32_t state, char *msg) {
-+ Gaim2Connection *gc = sess->aux_data;
-
- switch(reason) {
- case 0x0003: { /* Reply from an ICQ status message request */
-@@ -4913,14 +4913,14 @@ static int gaim_parse_clientauto_ch4(aim
- g_free(statusmsg);
- g_strfreev(splitmsg);
-
-- gaim_notify_userinfo(gc, who, dialogmsg, NULL, NULL);
-+ gaim2_notify_userinfo(gc, who, dialogmsg, NULL, NULL);
-
- g_free(title);
- g_free(dialogmsg);
- } break;
-
- default: {
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "Received an unknown client auto-response from %s. "
- "Type 0x%04hx\n", who, reason);
- } break;
-@@ -4929,7 +4929,7 @@ static int gaim_parse_clientauto_ch4(aim
- return 0;
- }
-
--static int gaim_parse_clientauto(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_clientauto(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- fu16_t chan, reason;
- char *who;
-@@ -4941,7 +4941,7 @@ static int gaim_parse_clientauto(aim_ses
-
- if (chan == 0x0002) { /* File transfer declined */
- guchar *cookie = va_arg(ap, guchar *);
-- return gaim_parse_clientauto_ch2(sess, who, reason, cookie);
-+ return gaim2_parse_clientauto_ch2(sess, who, reason, cookie);
- } else if (chan == 0x0004) { /* ICQ message */
- fu32_t state = 0;
- char *msg = NULL;
-@@ -4949,7 +4949,7 @@ static int gaim_parse_clientauto(aim_ses
- state = va_arg(ap, fu32_t);
- msg = va_arg(ap, char *);
- }
-- return gaim_parse_clientauto_ch4(sess, who, reason, state, msg);
-+ return gaim2_parse_clientauto_ch4(sess, who, reason, state, msg);
- }
-
- va_end(ap);
-@@ -4957,7 +4957,7 @@ static int gaim_parse_clientauto(aim_ses
- return 1;
- }
-
--static int gaim_parse_genericerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_genericerr(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- fu16_t reason;
- char *m;
-@@ -4966,23 +4966,23 @@ static int gaim_parse_genericerr(aim_ses
- reason = (fu16_t) va_arg(ap, unsigned int);
- va_end(ap);
-
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "snac threw error (reason 0x%04hx: %s)\n", reason,
- (reason < msgerrreasonlen) ? msgerrreason[reason] : "unknown");
-
- m = g_strdup_printf(_("SNAC threw error: %s\n"),
- reason < msgerrreasonlen ? _(msgerrreason[reason]) : _("Unknown error"));
-- gaim_notify_error(sess->aux_data, NULL, m, NULL);
-+ gaim2_notify_error(sess->aux_data, NULL, m, NULL);
- g_free(m);
-
- return 1;
- }
-
--static int gaim_parse_msgerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_parse_msgerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- #if 0
- OscarData *od = gc->proto_data;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- #endif
- va_list ap;
- fu16_t reason;
-@@ -4993,7 +4993,7 @@ static int gaim_parse_msgerr(aim_session
- data = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Message error with data %s and reason %hu\n",
- (data != NULL ? data : ""), reason);
-
-@@ -5001,17 +5001,17 @@ static int gaim_parse_msgerr(aim_session
- #if 0
- /* If this was a file transfer request, data is a cookie */
- if ((xfer = oscar_find_xfer_by_cookie(od->file_transfers, data))) {
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return 1;
- }
- #endif
-
- /* Data is assumed to be the destination sn */
- buf = g_strdup_printf(_("Unable to send message: %s"), (reason < msgerrreasonlen) ? msgerrreason[reason] : _("Unknown reason."));
-- if (!gaim_conv_present_error(data, gaim_connection_get_account(gc), buf)) {
-+ if (!gaim2_conv_present_error(data, gaim2_connection_get_account(gc), buf)) {
- g_free(buf);
- buf = g_strdup_printf(_("Unable to send message to %s:"), data ? data : "(unknown)");
-- gaim_notify_error(sess->aux_data, NULL, buf,
-+ gaim2_notify_error(sess->aux_data, NULL, buf,
- (reason < msgerrreasonlen) ? _(msgerrreason[reason]) : _("Unknown reason."));
- }
- g_free(buf);
-@@ -5019,8 +5019,8 @@ static int gaim_parse_msgerr(aim_session
- return 1;
- }
-
--static int gaim_parse_mtn(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_parse_mtn(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- fu16_t type1, type2;
- char *sn;
-@@ -5045,7 +5045,7 @@ static int gaim_parse_mtn(aim_session_t
- } break;
-
- default: {
-- gaim_debug_error("oscar", "Received unknown typing notification message from %s. Type1 is 0x%04x and type2 is 0x%04hx.\n", sn, type1, type2);
-+ gaim2_debug_error("oscar", "Received unknown typing notification message from %s. Type1 is 0x%04x and type2 is 0x%04hx.\n", sn, type1, type2);
- } break;
- }
-
-@@ -5056,7 +5056,7 @@ static int gaim_parse_mtn(aim_session_t
- * We get this error when there was an error in the locate family. This
- * happens when you request info of someone who is offline.
- */
--static int gaim_parse_locerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_locerr(aim_session_t *sess, aim_frame_t *fr, ...) {
- gchar *buf;
- va_list ap;
- fu16_t reason;
-@@ -5071,19 +5071,19 @@ static int gaim_parse_locerr(aim_session
- return 1;
-
- buf = g_strdup_printf(_("User information not available: %s"), (reason < msgerrreasonlen) ? _(msgerrreason[reason]) : _("Unknown reason."));
-- if (!gaim_conv_present_error(destn, gaim_connection_get_account((GaimConnection*)sess->aux_data), buf)) {
-+ if (!gaim2_conv_present_error(destn, gaim2_connection_get_account((Gaim2Connection*)sess->aux_data), buf)) {
- g_free(buf);
- buf = g_strdup_printf(_("User information for %s unavailable:"), destn);
-- gaim_notify_error(sess->aux_data, NULL, buf, (reason < msgerrreasonlen) ? _(msgerrreason[reason]) : _("Unknown reason."));
-+ gaim2_notify_error(sess->aux_data, NULL, buf, (reason < msgerrreasonlen) ? _(msgerrreason[reason]) : _("Unknown reason."));
- }
- g_free(buf);
-
- return 1;
- }
-
--static int gaim_parse_userinfo(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+static int gaim2_parse_userinfo(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- OscarData *od = gc->proto_data;
- GString *str;
- gchar *tmp = NULL, *info_utf8 = NULL, *away_utf8 = NULL;
-@@ -5115,7 +5115,7 @@ static int gaim_parse_userinfo(aim_sessi
- }
-
- if (userinfo->present & AIM_USERINFO_PRESENT_IDLE) {
-- tmp = gaim_str_seconds_to_string(userinfo->idletime*60);
-+ tmp = gaim2_str_seconds_to_string(userinfo->idletime*60);
- oscar_string_append(gc->account, str, "\n<br>", _("Idle"), tmp);
- g_free(tmp);
- }
-@@ -5147,21 +5147,21 @@ static int gaim_parse_userinfo(aim_sessi
- }
- }
-
-- tmp = gaim_str_sub_away_formatters(str->str, gaim_account_get_username(account));
-+ tmp = gaim2_str_sub_away_formatters(str->str, gaim2_account_get_username(account));
- g_string_free(str, TRUE);
-- gaim_str_strip_char(tmp, '\r');
-- gaim_notify_userinfo(gc, userinfo->sn, tmp, NULL, NULL);
-+ gaim2_str_strip_char(tmp, '\r');
-+ gaim2_notify_userinfo(gc, userinfo->sn, tmp, NULL, NULL);
- g_free(tmp);
-
- return 1;
- }
-
--static int gaim_got_infoblock(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_got_infoblock(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-- GaimBuddy *b;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Buddy *b;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- gchar *message = NULL;
-
- va_list ap;
-@@ -5171,34 +5171,34 @@ static int gaim_got_infoblock(aim_sessio
- userinfo = va_arg(ap, aim_userinfo_t *);
- va_end(ap);
-
-- b = gaim_find_buddy(gaim_connection_get_account(gc), userinfo->sn);
-+ b = gaim2_find_buddy(gaim2_connection_get_account(gc), userinfo->sn);
- if (b == NULL)
- return 1;
-
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-
-- if (!gaim_status_is_available(status) && gaim_status_is_online(status))
-+ if (!gaim2_status_is_available(status) && gaim2_status_is_online(status))
- {
- if ((userinfo != NULL) && (userinfo->flags & AIM_FLAG_AWAY) &&
- (userinfo->away_len > 0) && (userinfo->away != NULL) && (userinfo->away_encoding != NULL)) {
- gchar *charset = oscar_encoding_extract(userinfo->away_encoding);
- message = oscar_encoding_to_utf8(charset, userinfo->away, userinfo->away_len);
- g_free(charset);
-- gaim_status_set_attr_string(status, "message", message);
-+ gaim2_status_set_attr_string(status, "message", message);
- g_free(message);
- }
-
-- gaim_blist_update_buddy_status(b, status);
-+ gaim2_blist_update_buddy_status(b, status);
- }
-
- return 1;
- }
-
--static gboolean gaim_reqinfo_timeout_cb(void *data)
-+static gboolean gaim2_reqinfo_timeout_cb(void *data)
- {
- aim_session_t *sess = data;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-
- aim_locate_dorequest(data);
-@@ -5207,9 +5207,9 @@ static gboolean gaim_reqinfo_timeout_cb(
- return FALSE;
- }
-
--static int gaim_reqinfo_timeout(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_reqinfo_timeout(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-
- /*
-@@ -5218,12 +5218,12 @@ static int gaim_reqinfo_timeout(aim_sess
- * too quickly.
- */
- if (od->getinfotimer == 0)
-- od->getinfotimer = gaim_timeout_add(10000, gaim_reqinfo_timeout_cb, sess);
-+ od->getinfotimer = gaim2_timeout_add(10000, gaim2_reqinfo_timeout_cb, sess);
-
- return 1;
- }
-
--static int gaim_parse_motd(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_parse_motd(aim_session_t *sess, aim_frame_t *fr, ...)
- {
- char *msg;
- fu16_t id;
-@@ -5234,19 +5234,19 @@ static int gaim_parse_motd(aim_session_t
- msg = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "MOTD: %s (%hu)\n", msg ? msg : "Unknown", id);
- if (id < 4)
-- gaim_notify_warning(sess->aux_data, NULL,
-+ gaim2_notify_warning(sess->aux_data, NULL,
- _("Your AIM connection may be lost."), NULL);
-
- return 1;
- }
-
--static int gaim_chatnav_info(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_chatnav_info(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- fu16_t type;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-
- va_start(ap, fr);
-@@ -5262,19 +5262,19 @@ static int gaim_chatnav_info(aim_session
- exchangecount = va_arg(ap, int);
- exchanges = va_arg(ap, struct aim_chat_exchangeinfo *);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "chat info: Chat Rights:\n");
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "chat info: \tMax Concurrent Rooms: %hhd\n", maxrooms);
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "chat info: \tExchange List: (%d total)\n", exchangecount);
- for (i = 0; i < exchangecount; i++)
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "chat info: \t\t%hu %s\n",
- exchanges[i].number, exchanges[i].name ? exchanges[i].name : "");
- while (od->create_rooms) {
- struct create_room *cr = od->create_rooms->data;
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "creating room %s\n", cr->name);
- aim_chatnav_createroom(sess, fr->conn, cr->name, cr->exchange);
- g_free(cr->name);
-@@ -5301,7 +5301,7 @@ static int gaim_chatnav_info(aim_session
- name = va_arg(ap, char *);
- ck = va_arg(ap, char *);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "created room: %s %hu %hu %hu %u %hu %hu %hhu %hu %s %s\n",
- fqcn,
- exchange, instance, flags,
-@@ -5312,7 +5312,7 @@ static int gaim_chatnav_info(aim_session
- }
- break;
- default:
-- gaim_debug_warning("oscar",
-+ gaim2_debug_warning("oscar",
- "chatnav info: unknown type (%04hx)\n", type);
- break;
- }
-@@ -5322,11 +5322,11 @@ static int gaim_chatnav_info(aim_session
- return 1;
- }
-
--static int gaim_conv_chat_join(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_conv_chat_join(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- int count, i;
- aim_userinfo_t *info;
-- GaimConnection *g = sess->aux_data;
-+ Gaim2Connection *g = sess->aux_data;
-
- struct chat_connection *c = NULL;
-
-@@ -5340,16 +5340,16 @@ static int gaim_conv_chat_join(aim_sessi
- return 1;
-
- for (i = 0; i < count; i++)
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(c->conv), info[i].sn, NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(c->conv), info[i].sn, NULL, GAIM_CBFLAGS_NONE, TRUE);
-
- return 1;
- }
-
--static int gaim_conv_chat_leave(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_conv_chat_leave(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- int count, i;
- aim_userinfo_t *info;
-- GaimConnection *g = sess->aux_data;
-+ Gaim2Connection *g = sess->aux_data;
-
- struct chat_connection *c = NULL;
-
-@@ -5363,12 +5363,12 @@ static int gaim_conv_chat_leave(aim_sess
- return 1;
-
- for (i = 0; i < count; i++)
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(c->conv), info[i].sn, NULL);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(c->conv), info[i].sn, NULL);
-
- return 1;
- }
-
--static int gaim_conv_chat_info_update(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_conv_chat_info_update(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- aim_userinfo_t *userinfo;
- struct aim_chat_roominfo *roominfo;
-@@ -5377,7 +5377,7 @@ static int gaim_conv_chat_info_update(ai
- char *roomdesc;
- fu16_t unknown_c9, unknown_d2, unknown_d5, maxmsglen, maxvisiblemsglen;
- fu32_t creationtime;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- struct chat_connection *ccon = find_oscar_chat_by_conn(gc, fr->conn);
-
- va_start(ap, fr);
-@@ -5394,7 +5394,7 @@ static int gaim_conv_chat_info_update(ai
- maxvisiblemsglen = (fu16_t)va_arg(ap, unsigned int);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "inside chat_info_update (maxmsglen = %hu, maxvislen = %hu)\n",
- maxmsglen, maxvisiblemsglen);
-
-@@ -5404,8 +5404,8 @@ static int gaim_conv_chat_info_update(ai
- return 1;
- }
-
--static int gaim_conv_chat_incoming_msg(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_conv_chat_incoming_msg(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- struct chat_connection *ccon = find_oscar_chat_by_conn(gc, fr->conn);
- gchar *utf8;
- va_list ap;
-@@ -5431,9 +5431,9 @@ static int gaim_conv_chat_incoming_msg(a
- return 1;
- }
-
--static int gaim_email_parseupdate(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_email_parseupdate(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- struct aim_emailinfo *emailinfo;
- int havenewmail;
- char *alertitle, *alerturl;
-@@ -5445,41 +5445,41 @@ static int gaim_email_parseupdate(aim_se
- alerturl = va_arg(ap, char *);
- va_end(ap);
-
-- if ((emailinfo != NULL) && gaim_account_get_check_mail(gc->account)) {
-- gchar *to = g_strdup_printf("%s%s%s", gaim_account_get_username(gaim_connection_get_account(gc)),
-+ if ((emailinfo != NULL) && gaim2_account_get_check_mail(gc->account)) {
-+ gchar *to = g_strdup_printf("%s%s%s", gaim2_account_get_username(gaim2_connection_get_account(gc)),
- emailinfo->domain ? "@" : "",
- emailinfo->domain ? emailinfo->domain : "");
- if (emailinfo->unread && havenewmail)
-- gaim_notify_emails(gc, emailinfo->nummsgs, FALSE, NULL, NULL, (const char **)&to, (const char **)&emailinfo->url, NULL, NULL);
-+ gaim2_notify_emails(gc, emailinfo->nummsgs, FALSE, NULL, NULL, (const char **)&to, (const char **)&emailinfo->url, NULL, NULL);
- g_free(to);
- }
-
- if (alertitle)
-- gaim_debug_misc("oscar", "Got an alert '%s' %s\n", alertitle, alerturl ? alerturl : "");
-+ gaim2_debug_misc("oscar", "Got an alert '%s' %s\n", alertitle, alerturl ? alerturl : "");
-
- return 1;
- }
-
--static int gaim_icon_error(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_icon_error(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
- char *sn;
-
- sn = od->requesticon->data;
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "removing %s from hash table\n", sn);
- od->requesticon = g_slist_remove(od->requesticon, sn);
- free(sn);
-
- if (od->icontimer)
-- gaim_timeout_remove(od->icontimer);
-- od->icontimer = gaim_timeout_add(500, gaim_icon_timerfunc, gc);
-+ gaim2_timeout_remove(od->icontimer);
-+ od->icontimer = gaim2_timeout_add(500, gaim2_icon_timerfunc, gc);
-
- return 1;
- }
-
--static int gaim_icon_parseicon(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_icon_parseicon(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
- GSList *cur;
- va_list ap;
-@@ -5502,12 +5502,12 @@ static int gaim_icon_parseicon(aim_sessi
- */
- if ((iconlen > 0) && (iconlen != 90)) {
- char *b16;
-- GaimBuddy *b = gaim_find_buddy(gc->account, sn);
-- gaim_buddy_icons_set_for_user(gaim_connection_get_account(gc),
-+ Gaim2Buddy *b = gaim2_find_buddy(gc->account, sn);
-+ gaim2_buddy_icons_set_for_user(gaim2_connection_get_account(gc),
- sn, icon, iconlen);
-- b16 = gaim_base16_encode(iconcsum, iconcsumlen);
-+ b16 = gaim2_base16_encode(iconcsum, iconcsumlen);
- if (b16) {
-- gaim_blist_node_set_string((GaimBlistNode*)b, "icon_checksum", b16);
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)b, "icon_checksum", b16);
- g_free(b16);
- }
- }
-@@ -5524,14 +5524,14 @@ static int gaim_icon_parseicon(aim_sessi
- }
-
- if (od->icontimer)
-- gaim_timeout_remove(od->icontimer);
-- od->icontimer = gaim_timeout_add(250, gaim_icon_timerfunc, gc);
-+ gaim2_timeout_remove(od->icontimer);
-+ od->icontimer = gaim2_timeout_add(250, gaim2_icon_timerfunc, gc);
-
- return 1;
- }
-
--static gboolean gaim_icon_timerfunc(gpointer data) {
-- GaimConnection *gc = data;
-+static gboolean gaim2_icon_timerfunc(gpointer data) {
-+ Gaim2Connection *gc = data;
- OscarData *od = gc->proto_data;
- aim_userinfo_t *userinfo;
- aim_conn_t *conn;
-@@ -5547,7 +5547,7 @@ static gboolean gaim_icon_timerfunc(gpoi
-
- if (od->set_icon) {
- struct stat st;
-- char *iconfile = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(gaim_connection_get_account(gc)));
-+ char *iconfile = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(gaim2_connection_get_account(gc)));
- if (iconfile == NULL) {
- aim_ssi_delicon(od->sess);
- } else if (!g_stat(iconfile, &st)) {
-@@ -5557,15 +5557,15 @@ static gboolean gaim_icon_timerfunc(gpoi
- /* XXX - Use g_file_get_contents()? */
- fread(buf, 1, st.st_size, file);
- fclose(file);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Uploading icon to icon server\n");
- aim_bart_upload(od->sess, buf, st.st_size);
- } else
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't open buddy icon file!\n");
- g_free(buf);
- } else {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't stat buddy icon file!\n");
- }
- g_free(iconfile);
-@@ -5573,7 +5573,7 @@ static gboolean gaim_icon_timerfunc(gpoi
- }
-
- if (!od->requesticon) {
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "no more icons to request\n");
- return FALSE;
- }
-@@ -5594,7 +5594,7 @@ static gboolean gaim_icon_timerfunc(gpoi
- /*
- * Recieved in response to an IM sent with the AIM_IMFLAGS_ACK option.
- */
--static int gaim_parse_msgack(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_msgack(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- fu16_t type;
- char *sn;
-@@ -5604,12 +5604,12 @@ static int gaim_parse_msgack(aim_session
- sn = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_info("oscar", "Sent message to %s.\n", sn);
-+ gaim2_debug_info("oscar", "Sent message to %s.\n", sn);
-
- return 1;
- }
-
--static int gaim_parse_ratechange(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_ratechange(aim_session_t *sess, aim_frame_t *fr, ...) {
- static const char *codes[5] = {
- "invalid",
- "change",
-@@ -5633,7 +5633,7 @@ static int gaim_parse_ratechange(aim_ses
- maxavg = va_arg(ap, fu32_t);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "rate %s (param ID 0x%04hx): curavg = %u, maxavg = %u, alert at %u, "
- "clear warning at %u, limit at %u, disconnect at %u (window size = %u)\n",
- (code < 5) ? codes[code] : codes[0],
-@@ -5650,7 +5650,7 @@ static int gaim_parse_ratechange(aim_ses
- } else if (code == AIM_RATE_CODE_WARNING) {
- aim_conn_setlatency(fr->conn, windowsize/4);
- } else if (code == AIM_RATE_CODE_LIMIT) {
-- gaim_notify_error(sess->aux_data, NULL, _("Rate limiting error."),
-+ gaim2_notify_error(sess->aux_data, NULL, _("Rate limiting error."),
- _("The last action you attempted could not be "
- "performed because you are over the rate limit. "
- "Please wait 10 seconds and try again."));
-@@ -5662,7 +5662,7 @@ static int gaim_parse_ratechange(aim_ses
- return 1;
- }
-
--static int gaim_parse_evilnotify(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_evilnotify(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- fu16_t newevil;
- aim_userinfo_t *userinfo;
-@@ -5673,13 +5673,13 @@ static int gaim_parse_evilnotify(aim_ses
- va_end(ap);
-
- #ifdef CRAZY_WARNING
-- gaim_prpl_got_account_warning_level(account, (userinfo && userinfo->sn) ? userinfo->sn : NULL, (newevil/10.0) + 0.5);
-+ gaim2_prpl_got_account_warning_level(account, (userinfo && userinfo->sn) ? userinfo->sn : NULL, (newevil/10.0) + 0.5);
- #endif
-
- return 1;
- }
-
--static int gaim_selfinfo(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_selfinfo(aim_session_t *sess, aim_frame_t *fr, ...) {
- int warning_level;
- va_list ap;
- aim_userinfo_t *info;
-@@ -5698,14 +5698,14 @@ static int gaim_selfinfo(aim_session_t *
- warning_level = info->warnlevel/10.0 + 0.5;
-
- #ifdef CRAZY_WARNING
-- gaim_presence_set_warning_level(presence, warning_level);
-+ gaim2_presence_set_warning_level(presence, warning_level);
- #endif
-
- return 1;
- }
-
--static int gaim_connerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_connerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
- va_list ap;
- fu16_t code;
-@@ -5716,7 +5716,7 @@ static int gaim_connerr(aim_session_t *s
- msg = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_info("oscar", "Disconnected. Code is 0x%04x and msg is %s\n",
-+ gaim2_debug_info("oscar", "Disconnected. Code is 0x%04x and msg is %s\n",
- code, (msg != NULL ? msg : ""));
-
- g_return_val_if_fail(fr != NULL, 1);
-@@ -5725,24 +5725,24 @@ static int gaim_connerr(aim_session_t *s
- if (fr->conn->type == AIM_CONN_TYPE_BOS) {
- if (code == 0x0001) {
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, _("You have signed on from another location."));
-+ gaim2_connection_error(gc, _("You have signed on from another location."));
- } else {
-- gaim_connection_error(gc, _("You have been signed off for an unknown reason."));
-+ gaim2_connection_error(gc, _("You have been signed off for an unknown reason."));
- }
- od->killme = TRUE;
- } else if (fr->conn->type == AIM_CONN_TYPE_CHAT) {
- struct chat_connection *cc;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
- cc = find_oscar_chat_by_conn(gc, fr->conn);
-- conv = gaim_find_chat(gc, cc->id);
-+ conv = gaim2_find_chat(gc, cc->id);
-
- if (conv != NULL)
- {
- gchar *buf;
- buf = g_strdup_printf(_("You have been disconnected from chat "
- "room %s."), cc->name);
-- gaim_conversation_write(conv, NULL, buf, GAIM_MESSAGE_ERROR, time(NULL));
-+ gaim2_conversation_write(conv, NULL, buf, GAIM_MESSAGE_ERROR, time(NULL));
- g_free(buf);
- }
- oscar_chat_kill(gc, cc);
-@@ -5752,41 +5752,41 @@ static int gaim_connerr(aim_session_t *s
- }
-
- static int conninitdone_bos(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-
- aim_reqpersonalinfo(sess, fr->conn);
-
-- gaim_debug_info("oscar", "ssi: requesting rights and list\n");
-+ gaim2_debug_info("oscar", "ssi: requesting rights and list\n");
- aim_ssi_reqrights(sess);
- aim_ssi_reqdata(sess);
- if (od->getblisttimer > 0)
-- gaim_timeout_remove(od->getblisttimer);
-- od->getblisttimer = gaim_timeout_add(30000, gaim_ssi_rerequestdata, od->sess);
-+ gaim2_timeout_remove(od->getblisttimer);
-+ od->getblisttimer = gaim2_timeout_add(30000, gaim2_ssi_rerequestdata, od->sess);
-
- aim_locate_reqrights(sess);
- aim_buddylist_reqrights(sess, fr->conn);
- aim_im_reqparams(sess);
- aim_bos_reqrights(sess, fr->conn); /* XXX - Don't call this with ssi */
-
-- gaim_connection_update_progress(gc, _("Finalizing connection"), 5, OSCAR_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Finalizing connection"), 5, OSCAR_CONNECT_STEPS);
-
- return 1;
- }
-
- static int conninitdone_admin(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ADM, 0x0003, gaim_info_change, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ADM, 0x0005, gaim_info_change, 0);
-- aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ADM, 0x0007, gaim_account_confirm, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ADM, 0x0003, gaim2_info_change, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ADM, 0x0005, gaim2_info_change, 0);
-+ aim_conn_addhandler(sess, fr->conn, AIM_CB_FAM_ADM, 0x0007, gaim2_account_confirm, 0);
-
- aim_clientready(sess, fr->conn);
-- gaim_debug_info("oscar", "connected to admin\n");
-+ gaim2_debug_info("oscar", "connected to admin\n");
-
- if (od->chpass) {
-- gaim_debug_info("oscar", "changing password\n");
-+ gaim2_debug_info("oscar", "changing password\n");
- aim_admin_changepasswd(sess, fr->conn, od->newp, od->oldp);
- g_free(od->oldp);
- od->oldp = NULL;
-@@ -5795,24 +5795,24 @@ static int conninitdone_admin(aim_sessio
- od->chpass = FALSE;
- }
- if (od->setnick) {
-- gaim_debug_info("oscar", "formatting screen name\n");
-+ gaim2_debug_info("oscar", "formatting screen name\n");
- aim_admin_setnick(sess, fr->conn, od->newsn);
- g_free(od->newsn);
- od->newsn = NULL;
- od->setnick = FALSE;
- }
- if (od->conf) {
-- gaim_debug_info("oscar", "confirming account\n");
-+ gaim2_debug_info("oscar", "confirming account\n");
- aim_admin_reqconfirm(sess, fr->conn);
- od->conf = FALSE;
- }
- if (od->reqemail) {
-- gaim_debug_info("oscar", "requesting email\n");
-+ gaim2_debug_info("oscar", "requesting email\n");
- aim_admin_getinfo(sess, fr->conn, 0x0011);
- od->reqemail = FALSE;
- }
- if (od->setemail) {
-- gaim_debug_info("oscar", "setting email\n");
-+ gaim2_debug_info("oscar", "setting email\n");
- aim_admin_setemail(sess, fr->conn, od->email);
- g_free(od->email);
- od->email = NULL;
-@@ -5822,7 +5822,7 @@ static int conninitdone_admin(aim_sessio
- return 1;
- }
-
--static int gaim_icbm_param_info(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_icbm_param_info(aim_session_t *sess, aim_frame_t *fr, ...) {
- struct aim_icbmparameters *params;
- va_list ap;
-
-@@ -5831,7 +5831,7 @@ static int gaim_icbm_param_info(aim_sess
- va_end(ap);
-
- /* XXX - evidently this crashes on solaris. i have no clue why
-- gaim_debug_misc("oscar", "ICBM Parameters: maxchannel = %hu, default flags = 0x%08lx, max msg len = %hu, "
-+ gaim2_debug_misc("oscar", "ICBM Parameters: maxchannel = %hu, default flags = 0x%08lx, max msg len = %hu, "
- "max sender evil = %f, max receiver evil = %f, min msg interval = %u\n",
- params->maxchan, params->flags, params->maxmsglen,
- ((float)params->maxsenderwarn)/10.0, ((float)params->maxrecverwarn)/10.0,
-@@ -5848,10 +5848,10 @@ static int gaim_icbm_param_info(aim_sess
- return 1;
- }
-
--static int gaim_parse_locaterights(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_parse_locaterights(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- OscarData *od = (OscarData *)gc->proto_data;
- va_list ap;
- fu16_t maxsiglen;
-@@ -5860,7 +5860,7 @@ static int gaim_parse_locaterights(aim_s
- maxsiglen = (fu16_t) va_arg(ap, int);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "locate rights: max sig len = %d\n", maxsiglen);
-
- od->rights.maxsiglen = od->rights.maxawaymsglen = (guint)maxsiglen;
-@@ -5870,15 +5870,15 @@ static int gaim_parse_locaterights(aim_s
- else
- aim_locate_setcaps(od->sess, caps_aim);
- oscar_set_info_and_status(account, TRUE, account->user_info, TRUE,
-- gaim_account_get_active_status(account));
-+ gaim2_account_get_active_status(account));
-
- return 1;
- }
-
--static int gaim_parse_buddyrights(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_buddyrights(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- fu16_t maxbuddies, maxwatchers;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-
- va_start(ap, fr);
-@@ -5886,7 +5886,7 @@ static int gaim_parse_buddyrights(aim_se
- maxwatchers = (fu16_t) va_arg(ap, unsigned int);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "buddy list rights: Max buddies = %hu / Max watchers = %hu\n", maxbuddies, maxwatchers);
-
- od->rights.maxbuddies = (guint)maxbuddies;
-@@ -5895,11 +5895,11 @@ static int gaim_parse_buddyrights(aim_se
- return 1;
- }
-
--static int gaim_bosrights(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc;
-+static int gaim2_bosrights(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc;
- OscarData *od;
-- GaimAccount *account;
-- GaimStatus *status;
-+ Gaim2Account *account;
-+ Gaim2Status *status;
- const char *message;
- char *tmp;
- va_list ap;
-@@ -5907,32 +5907,32 @@ static int gaim_bosrights(aim_session_t
-
- gc = sess->aux_data;
- od = (OscarData *)gc->proto_data;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- va_start(ap, fr);
- maxpermits = (fu16_t) va_arg(ap, unsigned int);
- maxdenies = (fu16_t) va_arg(ap, unsigned int);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "BOS rights: Max permit = %hu / Max deny = %hu\n", maxpermits, maxdenies);
-
- od->rights.maxpermits = (guint)maxpermits;
- od->rights.maxdenies = (guint)maxdenies;
-
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
-- gaim_debug_info("oscar", "buddy list loaded\n");
-+ gaim2_debug_info("oscar", "buddy list loaded\n");
-
- aim_clientready(sess, fr->conn);
-
- /* Set our available message based on the current status */
-- status = gaim_account_get_active_status(account);
-- if (gaim_status_is_available(status))
-- message = gaim_status_get_attr_string(status, "message");
-+ status = gaim2_account_get_active_status(account);
-+ if (gaim2_status_is_available(status))
-+ message = gaim2_status_get_attr_string(status, "message");
- else
- message = NULL;
-- tmp = gaim_markup_strip_html(message);
-+ tmp = gaim2_markup_strip_html(message);
- aim_srv_setstatusmsg(sess, tmp);
- free(tmp);
-
-@@ -5942,8 +5942,8 @@ static int gaim_bosrights(aim_session_t
- aim_icq_reqofflinemsgs(sess);
- oscar_set_extendedstatus(gc);
- aim_icq_setsecurity(sess,
-- gaim_account_get_bool(account, "authorization", OSCAR_DEFAULT_AUTHORIZATION),
-- gaim_account_get_bool(account, "web_aware", OSCAR_DEFAULT_WEB_AWARE));
-+ gaim2_account_get_bool(account, "authorization", OSCAR_DEFAULT_AUTHORIZATION),
-+ gaim2_account_get_bool(account, "web_aware", OSCAR_DEFAULT_WEB_AWARE));
- }
-
- aim_reqservice(sess, fr->conn, AIM_CONN_TYPE_CHATNAV);
-@@ -5953,7 +5953,7 @@ static int gaim_bosrights(aim_session_t
- return 1;
- }
-
--static int gaim_offlinemsg(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_offlinemsg(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- struct aim_icq_offlinemsg *msg;
- struct aim_incomingim_ch4_args args;
-@@ -5963,20 +5963,20 @@ static int gaim_offlinemsg(aim_session_t
- msg = va_arg(ap, struct aim_icq_offlinemsg *);
- va_end(ap);
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Received offline message. Converting to channel 4 ICBM...\n");
- args.uin = msg->sender;
- args.type = msg->type;
- args.flags = msg->flags;
- args.msglen = msg->msglen;
- args.msg = msg->msg;
-- t = gaim_time_build(msg->year, msg->month, msg->day, msg->hour, msg->minute, 0);
-+ t = gaim2_time_build(msg->year, msg->month, msg->day, msg->hour, msg->minute, 0);
- incomingim_chan4(sess, fr->conn, NULL, &args, t);
-
- return 1;
- }
-
--static int gaim_offlinemsgdone(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_offlinemsgdone(aim_session_t *sess, aim_frame_t *fr, ...)
- {
- aim_icq_ackofflinemsgs(sess);
- return 1;
-@@ -6024,16 +6024,16 @@ static size_t my_strftime(char *s, size_
- /*
- * Before even realizing this was here, I went and did the same thing in util.c.
- *
-- * Use gaim_strftime()
-+ * Use gaim2_strftime()
- */
-
- #endif
-
--static int gaim_icqinfo(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_icqinfo(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- struct buddyinfo *bi = NULL;
- gchar who[16];
- GString *str;
-@@ -6051,9 +6051,9 @@ static int gaim_icqinfo(aim_session_t *s
-
- str = g_string_sized_new(100);
- g_snprintf(who, sizeof(who), "%u", info->uin);
-- buddy = gaim_find_buddy(gaim_connection_get_account(gc), who);
-+ buddy = gaim2_find_buddy(gaim2_connection_get_account(gc), who);
- if (buddy != NULL)
-- bi = g_hash_table_lookup(od->buddyinfo, gaim_normalize(buddy->account, buddy->name));
-+ bi = g_hash_table_lookup(od->buddyinfo, gaim2_normalize(buddy->account, buddy->name));
-
- g_string_append_printf(str, "<b>%s:</b> %s", _("UIN"), who);
- oscar_string_append(gc->account, str, "\n<br>", _("Nick"), info->nick);
-@@ -6090,7 +6090,7 @@ static int gaim_icqinfo(aim_session_t *s
- tm.tm_mday = (int)info->birthday;
- tm.tm_mon = (int)info->birthmonth-1;
- tm.tm_year = (int)info->birthyear-1900;
-- gaim_strftime(date, sizeof(date), "%x", &tm);
-+ gaim2_strftime(date, sizeof(date), "%x", &tm);
- oscar_string_append(gc->account, str, "\n<br>", _("Birthday"), date);
- }
- if ((info->age > 0) && (info->age < 255)) {
-@@ -6136,21 +6136,21 @@ static int gaim_icqinfo(aim_session_t *s
- }
-
- if (buddy != NULL)
-- alias = gaim_buddy_get_alias(buddy);
-+ alias = gaim2_buddy_get_alias(buddy);
- else
- alias = who;
-- gaim_notify_userinfo(gc, who, str->str, NULL, NULL);
-+ gaim2_notify_userinfo(gc, who, str->str, NULL, NULL);
- g_string_free(str, TRUE);
-
- return 1;
- }
-
--static int gaim_icqalias(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_icqalias(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- gchar who[16], *utf8;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- va_list ap;
- struct aim_icq_info *info;
-
-@@ -6161,8 +6161,8 @@ static int gaim_icqalias(aim_session_t *
- if (info->uin && info->nick && info->nick[0] && (utf8 = oscar_utf8_try_convert(account, info->nick))) {
- g_snprintf(who, sizeof(who), "%u", info->uin);
- serv_got_alias(gc, who, utf8);
-- if ((b = gaim_find_buddy(gc->account, who))) {
-- gaim_blist_node_set_string((GaimBlistNode*)b, "servernick", utf8);
-+ if ((b = gaim2_find_buddy(gc->account, who))) {
-+ gaim2_blist_node_set_string((Gaim2BlistNode*)b, "servernick", utf8);
- }
- g_free(utf8);
- }
-@@ -6170,9 +6170,9 @@ static int gaim_icqalias(aim_session_t *
- return 1;
- }
-
--static int gaim_popup(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_popup(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- gchar *text;
- va_list ap;
- char *msg, *url;
-@@ -6187,23 +6187,23 @@ static int gaim_popup(aim_session_t *ses
- va_end(ap);
-
- text = g_strdup_printf("%s<br><a href=\"%s\">%s</a>", msg, url, url);
-- gaim_notify_formatted(gc, NULL, _("Pop-Up Message"), NULL, text, NULL, NULL);
-+ gaim2_notify_formatted(gc, NULL, _("Pop-Up Message"), NULL, text, NULL, NULL);
- g_free(text);
-
- return 1;
- }
-
--static void oscar_searchresults_add_buddy_cb(GaimConnection *gc, GList *row)
-+static void oscar_searchresults_add_buddy_cb(Gaim2Connection *gc, GList *row)
- {
-- gaim_blist_request_add_buddy(gaim_connection_get_account(gc),
-+ gaim2_blist_request_add_buddy(gaim2_connection_get_account(gc),
- g_list_nth_data(row, 0), NULL, NULL);
- }
-
--static int gaim_parse_searchreply(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_parse_searchreply(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc = sess->aux_data;
-- GaimNotifySearchResults *results;
-- GaimNotifySearchColumn *column;
-+ Gaim2Connection *gc = sess->aux_data;
-+ Gaim2NotifySearchResults *results;
-+ Gaim2NotifySearchColumn *column;
- gchar *secondary;
- int i, num;
- va_list ap;
-@@ -6215,12 +6215,12 @@ static int gaim_parse_searchreply(aim_se
- SNs = va_arg(ap, char *);
- va_end(ap);
-
-- results = gaim_notify_searchresults_new();
-+ results = gaim2_notify_searchresults_new();
-
- if (results == NULL) {
-- gaim_debug_error("oscar", "gaim_parse_searchreply: "
-+ gaim2_debug_error("oscar", "gaim2_parse_searchreply: "
- "Unable to display the search results.\n");
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Unable to display the search results."),
- NULL);
- return 1;
-@@ -6232,24 +6232,24 @@ static int gaim_parse_searchreply(aim_se
- num),
- email);
-
-- column = gaim_notify_searchresults_column_new("Screen name");
-- gaim_notify_searchresults_column_add(results, column);
-+ column = gaim2_notify_searchresults_column_new("Screen name");
-+ gaim2_notify_searchresults_column_add(results, column);
-
- for (i = 0; i < num; i++) {
- GList *row = NULL;
- row = g_list_append(row, g_strdup(&SNs[i * (MAXSNLEN + 1)]));
-- gaim_notify_searchresults_row_add(results, row);
-+ gaim2_notify_searchresults_row_add(results, row);
- }
-- gaim_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_ADD,
-+ gaim2_notify_searchresults_button_add(results, GAIM_NOTIFY_BUTTON_ADD,
- oscar_searchresults_add_buddy_cb);
-- gaim_notify_searchresults(gc, NULL, NULL, secondary, results, NULL, NULL);
-+ gaim2_notify_searchresults(gc, NULL, NULL, secondary, results, NULL, NULL);
-
- g_free(secondary);
-
- return 1;
- }
-
--static int gaim_parse_searcherror(aim_session_t *sess, aim_frame_t *fr, ...) {
-+static int gaim2_parse_searcherror(aim_session_t *sess, aim_frame_t *fr, ...) {
- va_list ap;
- char *email;
- char *buf;
-@@ -6259,14 +6259,14 @@ static int gaim_parse_searcherror(aim_se
- va_end(ap);
-
- buf = g_strdup_printf(_("No results found for email address %s"), email);
-- gaim_notify_error(sess->aux_data, NULL, buf, NULL);
-+ gaim2_notify_error(sess->aux_data, NULL, buf, NULL);
- g_free(buf);
-
- return 1;
- }
-
--static int gaim_account_confirm(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_account_confirm(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- fu16_t status;
- va_list ap;
- char msg[256];
-@@ -6275,20 +6275,20 @@ static int gaim_account_confirm(aim_sess
- status = (fu16_t) va_arg(ap, unsigned int); /* status code of confirmation request */
- va_end(ap);
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "account confirmation returned status 0x%04x (%s)\n", status,
- status ? "unknown" : "email sent");
- if (!status) {
- g_snprintf(msg, sizeof(msg), _("You should receive an email asking to confirm %s."),
-- gaim_account_get_username(gaim_connection_get_account(gc)));
-- gaim_notify_info(gc, NULL, _("Account Confirmation Requested"), msg);
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)));
-+ gaim2_notify_info(gc, NULL, _("Account Confirmation Requested"), msg);
- }
-
- return 1;
- }
-
--static int gaim_info_change(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_info_change(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- fu16_t perms, err;
- char *url, *sn, *email;
-@@ -6303,7 +6303,7 @@ static int gaim_info_change(aim_session_
- email = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "account info: because of %s, perms=0x%04x, err=0x%04x, url=%s, sn=%s, email=%s\n",
- change ? "change" : "request", perms, err,
- (url != NULL) ? url : "(null)",
-@@ -6336,7 +6336,7 @@ static int gaim_info_change(aim_session_
- dialog_msg = g_strdup_printf(_("Error 0x%04x: Unknown error."), err);
- } break;
- }
-- gaim_notify_error(gc, NULL, dialog_top, dialog_msg);
-+ gaim2_notify_error(gc, NULL, dialog_top, dialog_msg);
- g_free(dialog_top);
- g_free(dialog_msg);
- return 1;
-@@ -6344,26 +6344,26 @@ static int gaim_info_change(aim_session_
-
- if (sn != NULL) {
- char *dialog_msg = g_strdup_printf(_("Your screen name is currently formatted as follows:\n%s"), sn);
-- gaim_notify_info(gc, NULL, _("Account Info"), dialog_msg);
-+ gaim2_notify_info(gc, NULL, _("Account Info"), dialog_msg);
- g_free(dialog_msg);
- }
-
- if (email != NULL) {
- char *dialog_msg = g_strdup_printf(_("The email address for %s is %s"),
-- gaim_account_get_username(gaim_connection_get_account(gc)), email);
-- gaim_notify_info(gc, NULL, _("Account Info"), dialog_msg);
-+ gaim2_account_get_username(gaim2_connection_get_account(gc)), email);
-+ gaim2_notify_info(gc, NULL, _("Account Info"), dialog_msg);
- g_free(dialog_msg);
- }
-
- return 1;
- }
-
--static void oscar_keepalive(GaimConnection *gc) {
-+static void oscar_keepalive(Gaim2Connection *gc) {
- OscarData *od = (OscarData *)gc->proto_data;
- aim_flap_nop(od->sess, od->conn);
- }
-
--static int oscar_send_typing(GaimConnection *gc, const char *name, int typing) {
-+static int oscar_send_typing(Gaim2Connection *gc, const char *name, int typing) {
- OscarData *od = (OscarData *)gc->proto_data;
- struct oscar_direct_im *dim = oscar_direct_im_find(od, name);
- if (dim && dim->connected)
-@@ -6378,7 +6378,7 @@ static int oscar_send_typing(GaimConnect
- GSList *list;
- for (list=gc->account->deny; (list && aim_sncmp(name, list->data)); list=list->next);
- if (!list) {
-- struct buddyinfo *bi = g_hash_table_lookup(od->buddyinfo, gaim_normalize(gc->account, name));
-+ struct buddyinfo *bi = g_hash_table_lookup(od->buddyinfo, gaim2_normalize(gc->account, name));
- if (bi && bi->typingnot) {
- if (typing == GAIM_TYPING)
- aim_im_sendmtn(od->sess, 0x0001, name, 0x0002);
-@@ -6392,43 +6392,43 @@ static int oscar_send_typing(GaimConnect
- return 0;
- }
-
--static int gaim_odc_send_im(aim_session_t *, aim_conn_t *, const char *, GaimMessageFlags);
-+static int gaim2_odc_send_im(aim_session_t *, aim_conn_t *, const char *, Gaim2MessageFlags);
-
--static int oscar_send_im(GaimConnection *gc, const char *name, const char *message, GaimMessageFlags imflags) {
-+static int oscar_send_im(Gaim2Connection *gc, const char *name, const char *message, Gaim2MessageFlags imflags) {
- OscarData *od = (OscarData *)gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct oscar_direct_im *dim = oscar_direct_im_find(od, name);
- int ret = 0;
-- char *iconfile = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(account));
-+ char *iconfile = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(account));
- char *tmp1, *tmp2;
-
- if (imflags & GAIM_MESSAGE_AUTO_RESP)
-- tmp1 = gaim_str_sub_away_formatters(message, name);
-+ tmp1 = gaim2_str_sub_away_formatters(message, name);
- else
- tmp1 = g_strdup(message);
-
- if (dim && dim->connected) {
- /* If we're directly connected, send a direct IM */
-- ret = gaim_odc_send_im(od->sess, dim->conn, tmp1, imflags);
-+ ret = gaim2_odc_send_im(od->sess, dim->conn, tmp1, imflags);
- } else {
- struct buddyinfo *bi;
- struct aim_sendimext_args args;
- struct stat st;
- gsize len;
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
-
- if (strstr(tmp1, "<IMG "))
-- gaim_conversation_write(conv, "",
-+ gaim2_conversation_write(conv, "",
- _("Your IM Image was not sent. "
- "You must be Direct Connected to send IM Images."),
- GAIM_MESSAGE_ERROR, time(NULL));
-
-- bi = g_hash_table_lookup(od->buddyinfo, gaim_normalize(account, name));
-+ bi = g_hash_table_lookup(od->buddyinfo, gaim2_normalize(account, name));
- if (!bi) {
- bi = g_new0(struct buddyinfo, 1);
-- g_hash_table_insert(od->buddyinfo, g_strdup(gaim_normalize(account, name)), bi);
-+ g_hash_table_insert(od->buddyinfo, g_strdup(gaim2_normalize(account, name)), bi);
- }
-
- args.flags = AIM_IMFLAGS_ACK | AIM_IMFLAGS_CUSTOMFEATURES;
-@@ -6440,7 +6440,7 @@ static int oscar_send_im(GaimConnection
- encoded" (and instead, assumes them to be UTF-8).
- For more details, see SF issue 1179452.
- */
-- GaimBuddy *buddy = gaim_find_buddy(gc->account, name);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(gc->account, name);
- if (buddy && GAIM_BUDDY_IS_ONLINE(buddy)) {
- args.features = features_icq;
- args.featureslen = sizeof(features_icq);
-@@ -6458,7 +6458,7 @@ static int oscar_send_im(GaimConnection
- }
-
- if (bi->ico_need) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Sending buddy icon request with message\n");
- args.flags |= AIM_IMFLAGS_BUDDYREQ;
- bi->ico_need = FALSE;
-@@ -6482,7 +6482,7 @@ static int oscar_send_im(GaimConnection
- }
-
- if (!bi->ico_informed) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Claiming to have a buddy icon\n");
- args.flags |= AIM_IMFLAGS_HASICON;
- bi->ico_me_len = args.iconlen;
-@@ -6502,10 +6502,10 @@ static int oscar_send_im(GaimConnection
- * If we're IMing an ICQ user from an ICQ account, then strip HTML
- * and use \r\n as the newline character.
- */
-- if (aim_sn_is_icq(gaim_account_get_username(account))) {
-+ if (aim_sn_is_icq(gaim2_account_get_username(account))) {
- if (aim_sn_is_icq(name))
- /* From ICQ to ICQ */
-- tmp2 = gaim_unescape_html(tmp1);
-+ tmp2 = gaim2_unescape_html(tmp1);
- else
- /* From ICQ to AIM */
- tmp2 = g_strdup(tmp1);
-@@ -6517,8 +6517,8 @@ static int oscar_send_im(GaimConnection
- tmp1 = tmp2;
- len = strlen(tmp1);
-
-- gaim_plugin_oscar_convert_to_best_encoding(gc, name, tmp1, (char **)&args.msg, &args.msglen, &args.charset, &args.charsubset);
-- gaim_debug_info("oscar", "Sending IM, charset=0x%04hx, charsubset=0x%04hx, length=%d\n",
-+ gaim2_plugin_oscar_convert_to_best_encoding(gc, name, tmp1, (char **)&args.msg, &args.msglen, &args.charset, &args.charsubset);
-+ gaim2_debug_info("oscar", "Sending IM, charset=0x%04hx, charsubset=0x%04hx, length=%d\n",
- args.charset, args.charsubset, args.msglen);
- ret = aim_im_sendch1_ext(od->sess, &args);
- g_free((char *)args.msg);
-@@ -6532,7 +6532,7 @@ static int oscar_send_im(GaimConnection
- return ret;
- }
-
--static void oscar_get_info(GaimConnection *gc, const char *name) {
-+static void oscar_get_info(Gaim2Connection *gc, const char *name) {
- OscarData *od = (OscarData *)gc->proto_data;
-
- if (od->icq && aim_sn_is_icq(name))
-@@ -6542,7 +6542,7 @@ static void oscar_get_info(GaimConnectio
- }
-
- #if 0
--static void oscar_set_dir(GaimConnection *gc, const char *first, const char *middle, const char *last,
-+static void oscar_set_dir(Gaim2Connection *gc, const char *first, const char *middle, const char *last,
- const char *maiden, const char *city, const char *state, const char *country, int web) {
- /* XXX - some of these things are wrong, but i'm lazy */
- OscarData *od = (OscarData *)gc->proto_data;
-@@ -6551,13 +6551,13 @@ static void oscar_set_dir(GaimConnection
- }
- #endif
-
--static void oscar_set_idle(GaimConnection *gc, int time) {
-+static void oscar_set_idle(Gaim2Connection *gc, int time) {
- OscarData *od = (OscarData *)gc->proto_data;
- aim_srv_setidle(od->sess, time);
- }
-
- static
--gchar *gaim_prpl_oscar_convert_to_infotext(const gchar *str, gsize *ret_len, char **encoding)
-+gchar *gaim2_prpl_oscar_convert_to_infotext(const gchar *str, gsize *ret_len, char **encoding)
- {
- int charset = 0;
- char *encoded = NULL;
-@@ -6579,32 +6579,32 @@ gchar *gaim_prpl_oscar_convert_to_infote
- }
-
- static void
--oscar_set_info(GaimConnection *gc, const char *rawinfo)
-+oscar_set_info(Gaim2Connection *gc, const char *rawinfo)
- {
-- GaimAccount *account;
-- GaimStatus *status;
-+ Gaim2Account *account;
-+ Gaim2Status *status;
-
-- account = gaim_connection_get_account(gc);
-- status = gaim_account_get_active_status(account);
-+ account = gaim2_connection_get_account(gc);
-+ status = gaim2_account_get_active_status(account);
- oscar_set_info_and_status(account, TRUE, rawinfo, FALSE, status);
- }
-
- static void
--oscar_set_extendedstatus(GaimConnection *gc)
-+oscar_set_extendedstatus(Gaim2Connection *gc)
- {
- OscarData *od;
-- GaimAccount *account;
-- GaimStatus *status;
-+ Gaim2Account *account;
-+ Gaim2Status *status;
- const gchar *status_id;
- fu32_t data = 0x00000000;
-
- od = gc->proto_data;
-- account = gaim_connection_get_account(gc);
-- status = gaim_account_get_active_status(account);
-- status_id = gaim_status_get_id(status);
-+ account = gaim2_connection_get_account(gc);
-+ status = gaim2_account_get_active_status(account);
-+ status_id = gaim2_status_get_id(status);
-
- data |= AIM_ICQ_STATE_HIDEIP;
-- if (gaim_account_get_bool(account, "web_aware", OSCAR_DEFAULT_WEB_AWARE))
-+ if (gaim2_account_get_bool(account, "web_aware", OSCAR_DEFAULT_WEB_AWARE))
- data |= AIM_ICQ_STATE_WEBAWARE;
-
- if (!strcmp(status_id, OSCAR_STATUS_ID_AVAILABLE) || !strcmp(status_id, OSCAR_STATUS_ID_AVAILABLE))
-@@ -6628,14 +6628,14 @@ oscar_set_extendedstatus(GaimConnection
- }
-
- static void
--oscar_set_info_and_status(GaimAccount *account, gboolean setinfo, const char *rawinfo,
-- gboolean setstatus, GaimStatus *status)
-+oscar_set_info_and_status(Gaim2Account *account, gboolean setinfo, const char *rawinfo,
-+ gboolean setstatus, Gaim2Status *status)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- OscarData *od = gc->proto_data;
-- GaimPresence *presence;
-- GaimStatusType *status_type;
-- GaimStatusPrimitive primitive;
-+ Gaim2Presence *presence;
-+ Gaim2StatusType *status_type;
-+ Gaim2StatusPrimitive primitive;
- gboolean invisible;
-
- char *htmlinfo;
-@@ -6648,10 +6648,10 @@ oscar_set_info_and_status(GaimAccount *a
- char *away = NULL;
- gsize awaylen = 0;
-
-- status_type = gaim_status_get_type(status);
-- primitive = gaim_status_type_get_primitive(status_type);
-- presence = gaim_account_get_presence(account);
-- invisible = gaim_presence_is_status_primitive_active(presence, GAIM_STATUS_INVISIBLE);
-+ status_type = gaim2_status_get_type(status);
-+ primitive = gaim2_status_type_get_primitive(status_type);
-+ presence = gaim2_account_get_presence(account);
-+ invisible = gaim2_presence_is_status_primitive_active(presence, GAIM_STATUS_INVISIBLE);
-
- if (!setinfo)
- {
-@@ -6659,7 +6659,7 @@ oscar_set_info_and_status(GaimAccount *a
- }
- else if (od->rights.maxsiglen == 0)
- {
-- gaim_notify_warning(gc, NULL, _("Unable to set AIM profile."),
-+ gaim2_notify_warning(gc, NULL, _("Unable to set AIM profile."),
- _("You have probably requested to set your "
- "profile before the login procedure completed. "
- "Your profile remains unset; try setting it "
-@@ -6667,19 +6667,19 @@ oscar_set_info_and_status(GaimAccount *a
- }
- else if (rawinfo != NULL)
- {
-- htmlinfo = gaim_strdup_withhtml(rawinfo);
-- info = gaim_prpl_oscar_convert_to_infotext(htmlinfo, &infolen, &info_encoding);
-+ htmlinfo = gaim2_strdup_withhtml(rawinfo);
-+ info = gaim2_prpl_oscar_convert_to_infotext(htmlinfo, &infolen, &info_encoding);
- g_free(htmlinfo);
-
- if (infolen > od->rights.maxsiglen)
- {
- gchar *errstr;
- errstr = g_strdup_printf(ngettext("The maximum profile length of %d byte "
-- "has been exceeded. Gaim has truncated it for you.",
-+ "has been exceeded. Gaim2 has truncated it for you.",
- "The maximum profile length of %d bytes "
-- "has been exceeded. Gaim has truncated it for you.",
-+ "has been exceeded. Gaim2 has truncated it for you.",
- od->rights.maxsiglen), od->rights.maxsiglen);
-- gaim_notify_warning(gc, NULL, _("Profile too long."), errstr);
-+ gaim2_notify_warning(gc, NULL, _("Profile too long."), errstr);
- g_free(errstr);
- }
- }
-@@ -6693,10 +6693,10 @@ oscar_set_info_and_status(GaimAccount *a
- const char *status_html;
- char *status_text;
-
-- status_html = gaim_status_get_attr_string(status, "message");
-+ status_html = gaim2_status_get_attr_string(status, "message");
- if (status_html != NULL)
- {
-- status_text = gaim_markup_strip_html(status_html);
-+ status_text = gaim2_markup_strip_html(status_html);
- /* If the status_text is longer than 60 character then truncate it */
- if (strlen(status_text) > 60)
- {
-@@ -6712,21 +6712,21 @@ oscar_set_info_and_status(GaimAccount *a
- }
- else if (primitive == GAIM_STATUS_AWAY)
- {
-- htmlaway = gaim_status_get_attr_string(status, "message");
-+ htmlaway = gaim2_status_get_attr_string(status, "message");
- if ((htmlaway == NULL) || (*htmlaway == '\0'))
- htmlaway = _("Away");
-- away = gaim_prpl_oscar_convert_to_infotext(htmlaway, &awaylen, &away_encoding);
-+ away = gaim2_prpl_oscar_convert_to_infotext(htmlaway, &awaylen, &away_encoding);
-
- if (awaylen > od->rights.maxawaymsglen)
- {
- gchar *errstr;
-
- errstr = g_strdup_printf(ngettext("The maximum away message length of %d byte "
-- "has been exceeded. Gaim has truncated it for you.",
-+ "has been exceeded. Gaim2 has truncated it for you.",
- "The maximum away message length of %d bytes "
-- "has been exceeded. Gaim has truncated it for you.",
-+ "has been exceeded. Gaim2 has truncated it for you.",
- od->rights.maxawaymsglen), od->rights.maxawaymsglen);
-- gaim_notify_warning(gc, NULL, _("Away message too long."), errstr);
-+ gaim2_notify_warning(gc, NULL, _("Away message too long."), errstr);
- g_free(errstr);
- }
- }
-@@ -6741,9 +6741,9 @@ oscar_set_info_and_status(GaimAccount *a
- }
-
- static void
--oscar_set_status_icq(GaimAccount *account, GaimStatus *status)
-+oscar_set_status_icq(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- OscarData *od = NULL;
-
- if (gc)
-@@ -6751,7 +6751,7 @@ oscar_set_status_icq(GaimAccount *accoun
- if (!od)
- return;
-
-- if (gaim_status_type_get_primitive(gaim_status_get_type(status)) == GAIM_STATUS_INVISIBLE)
-+ if (gaim2_status_type_get_primitive(gaim2_status_get_type(status)) == GAIM_STATUS_INVISIBLE)
- account->perm_deny = GAIM_PRIVACY_ALLOW_USERS;
- else
- account->perm_deny = GAIM_PRIVACY_DENY_USERS;
-@@ -6763,54 +6763,54 @@ oscar_set_status_icq(GaimAccount *accoun
- }
-
- static void
--oscar_set_status(GaimAccount *account, GaimStatus *status)
-+oscar_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- gaim_debug_info("oscar", "Set status to %s\n", gaim_status_get_name(status));
-+ gaim2_debug_info("oscar", "Set status to %s\n", gaim2_status_get_name(status));
-
-- if (!gaim_status_is_active(status))
-+ if (!gaim2_status_is_active(status))
- return;
-
-- if (!gaim_account_is_connected(account))
-+ if (!gaim2_account_is_connected(account))
- return;
-
- /* Set the AIM-style away message for both AIM and ICQ accounts */
- oscar_set_info_and_status(account, FALSE, NULL, TRUE, status);
-
- /* Set the ICQ status for ICQ accounts only */
-- if (aim_sn_is_icq(gaim_account_get_username(account)))
-+ if (aim_sn_is_icq(gaim2_account_get_username(account)))
- oscar_set_status_icq(account, status);
- }
-
- #ifdef CRAZY_WARN
- static void
--oscar_warn(GaimConnection *gc, const char *name, gboolean anonymous) {
-+oscar_warn(Gaim2Connection *gc, const char *name, gboolean anonymous) {
- OscarData *od = (OscarData *)gc->proto_data;
- aim_im_warn(od->sess, od->conn, name, anonymous ? AIM_WARN_ANON : 0);
- }
- #endif
-
- static void
--oscar_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group) {
-+oscar_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group) {
- OscarData *od = (OscarData *)gc->proto_data;
-
- if (!aim_snvalid(buddy->name)) {
- gchar *buf;
- buf = g_strdup_printf(_("Could not add the buddy %s because the screen name is invalid. Screen names must either start with a letter and contain only letters, numbers and spaces, or contain only numbers."), buddy->name);
-- if (!gaim_conv_present_error(buddy->name, gaim_connection_get_account(gc), buf))
-- gaim_notify_error(gc, NULL, _("Unable To Add"), buf);
-+ if (!gaim2_conv_present_error(buddy->name, gaim2_connection_get_account(gc), buf))
-+ gaim2_notify_error(gc, NULL, _("Unable To Add"), buf);
- g_free(buf);
-
- /* Remove from local list */
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
-
- return;
- }
-
- if ((od->sess->ssi.received_data) && !(aim_ssi_itemlist_finditem(od->sess->ssi.local, group->name, buddy->name, AIM_SSI_TYPE_BUDDY))) {
- if (buddy && group) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: adding buddy %s to group %s\n", buddy->name, group->name);
-- aim_ssi_addbuddy(od->sess, buddy->name, group->name, gaim_buddy_get_alias_only(buddy), NULL, NULL, 0);
-+ aim_ssi_addbuddy(od->sess, buddy->name, group->name, gaim2_buddy_get_alias_only(buddy), NULL, NULL, 0);
- }
- }
-
-@@ -6819,31 +6819,31 @@ oscar_add_buddy(GaimConnection *gc, Gaim
- aim_icq_getalias(od->sess, buddy->name);
- }
-
--static void oscar_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group) {
-+static void oscar_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group) {
- OscarData *od = (OscarData *)gc->proto_data;
-
- if (od->sess->ssi.received_data) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: deleting buddy %s from group %s\n", buddy->name, group->name);
- aim_ssi_delbuddy(od->sess, buddy->name, group->name);
- }
- }
-
--static void oscar_move_buddy(GaimConnection *gc, const char *name, const char *old_group, const char *new_group) {
-+static void oscar_move_buddy(Gaim2Connection *gc, const char *name, const char *old_group, const char *new_group) {
- OscarData *od = (OscarData *)gc->proto_data;
- if (od->sess->ssi.received_data && strcmp(old_group, new_group)) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: moving buddy %s from group %s to group %s\n", name, old_group, new_group);
- aim_ssi_movebuddy(od->sess, old_group, new_group, name);
- }
- }
-
--static void oscar_alias_buddy(GaimConnection *gc, const char *name, const char *alias) {
-+static void oscar_alias_buddy(Gaim2Connection *gc, const char *name, const char *alias) {
- OscarData *od = (OscarData *)gc->proto_data;
- if (od->sess->ssi.received_data) {
- char *gname = aim_ssi_itemlist_findparentname(od->sess->ssi.local, name);
- if (gname) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: changing the alias for buddy %s to %s\n", name, alias ? alias : "(none)");
- aim_ssi_aliasbuddy(od->sess, gname, name, alias);
- }
-@@ -6853,39 +6853,39 @@ static void oscar_alias_buddy(GaimConnec
- /*
- * FYI, the OSCAR SSI code removes empty groups automatically.
- */
--static void oscar_rename_group(GaimConnection *gc, const char *old_name, GaimGroup *group, GList *moved_buddies) {
-+static void oscar_rename_group(Gaim2Connection *gc, const char *old_name, Gaim2Group *group, GList *moved_buddies) {
- OscarData *od = (OscarData *)gc->proto_data;
-
- if (od->sess->ssi.received_data) {
- if (aim_ssi_itemlist_finditem(od->sess->ssi.local, group->name, NULL, AIM_SSI_TYPE_GROUP)) {
- GList *cur, *groups = NULL;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-
- /* Make a list of what the groups each buddy is in */
- for (cur = moved_buddies; cur != NULL; cur = cur->next) {
-- GaimBlistNode *node = cur->data;
-- /* node is GaimBuddy, parent is a GaimContact.
-+ Gaim2BlistNode *node = cur->data;
-+ /* node is Gaim2Buddy, parent is a Gaim2Contact.
- * We must go two levels up to get the Group */
- groups = g_list_append(groups,
- node->parent->parent);
- }
-
-- gaim_account_remove_buddies(account, moved_buddies, groups);
-- gaim_account_add_buddies(account, moved_buddies);
-+ gaim2_account_remove_buddies(account, moved_buddies, groups);
-+ gaim2_account_add_buddies(account, moved_buddies);
- g_list_free(groups);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: moved all buddies from group %s to %s\n", old_name, group->name);
- } else {
- aim_ssi_rename_group(od->sess, old_name, group->name);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: renamed group %s to %s\n", old_name, group->name);
- }
- }
- }
-
--static gboolean gaim_ssi_rerequestdata(gpointer data) {
-+static gboolean gaim2_ssi_rerequestdata(gpointer data) {
- aim_session_t *sess = data;
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
-
- aim_ssi_reqdata(sess);
-@@ -6894,8 +6894,8 @@ static gboolean gaim_ssi_rerequestdata(g
- return FALSE;
- }
-
--static int gaim_ssi_parseerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_parseerr(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
- va_list ap;
- fu16_t reason;
-@@ -6904,14 +6904,14 @@ static int gaim_ssi_parseerr(aim_session
- reason = (fu16_t)va_arg(ap, unsigned int);
- va_end(ap);
-
-- gaim_debug_error("oscar", "ssi: SNAC error %hu\n", reason);
-+ gaim2_debug_error("oscar", "ssi: SNAC error %hu\n", reason);
-
- if (reason == 0x0005) {
-- gaim_notify_error(gc, NULL, _("Unable To Retrieve Buddy List"),
-- _("Gaim was temporarily unable to retrieve your buddy list from the AIM servers. Your buddy list is not lost, and will probably become available in a few hours."));
-+ gaim2_notify_error(gc, NULL, _("Unable To Retrieve Buddy List"),
-+ _("Gaim2 was temporarily unable to retrieve your buddy list from the AIM servers. Your buddy list is not lost, and will probably become available in a few hours."));
- if (od->getblisttimer > 0)
-- gaim_timeout_remove(od->getblisttimer);
-- od->getblisttimer = gaim_timeout_add(30000, gaim_ssi_rerequestdata, od->sess);
-+ gaim2_timeout_remove(od->getblisttimer);
-+ od->getblisttimer = gaim2_timeout_add(30000, gaim2_ssi_rerequestdata, od->sess);
- }
-
- oscar_set_extendedstatus(gc);
-@@ -6919,14 +6919,14 @@ static int gaim_ssi_parseerr(aim_session
- /* Activate SSI */
- /* Sending the enable causes other people to be able to see you, and you to see them */
- /* Make sure your privacy setting/invisibility is set how you want it before this! */
-- gaim_debug_info("oscar", "ssi: activating server-stored buddy list\n");
-+ gaim2_debug_info("oscar", "ssi: activating server-stored buddy list\n");
- aim_ssi_enable(od->sess);
-
- return 1;
- }
-
--static int gaim_ssi_parserights(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_parserights(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = (OscarData *)gc->proto_data;
- int i;
- va_list ap;
-@@ -6938,13 +6938,13 @@ static int gaim_ssi_parserights(aim_sess
- maxitems = va_arg(ap, fu16_t *);
- va_end(ap);
-
-- gaim_debug_misc("oscar", "ssi rights:");
-+ gaim2_debug_misc("oscar", "ssi rights:");
-
- for (i=0; i<numtypes; i++)
-- gaim_debug_misc(NULL, " max type 0x%04x=%hd,",
-+ gaim2_debug_misc(NULL, " max type 0x%04x=%hd,",
- i, maxitems[i]);
-
-- gaim_debug_misc(NULL, "\n");
-+ gaim2_debug_misc(NULL, "\n");
-
- if (numtypes >= 0)
- od->rights.maxbuddies = maxitems[0];
-@@ -6958,13 +6958,13 @@ static int gaim_ssi_parserights(aim_sess
- return 1;
- }
-
--static int gaim_ssi_parselist(aim_session_t *sess, aim_frame_t *fr, ...)
-+static int gaim2_ssi_parselist(aim_session_t *sess, aim_frame_t *fr, ...)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- OscarData *od;
-- GaimAccount *account;
-- GaimGroup *g;
-- GaimBuddy *b;
-+ Gaim2Account *account;
-+ Gaim2Group *g;
-+ Gaim2Buddy *b;
- struct aim_ssi_item *curitem;
- fu32_t tmp;
- va_list ap;
-@@ -6974,7 +6974,7 @@ static int gaim_ssi_parselist(aim_sessio
-
- gc = sess->aux_data;
- od = gc->proto_data;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- va_start(ap, fr);
- fmtver = (fu16_t)va_arg(ap, int);
-@@ -6985,14 +6985,14 @@ static int gaim_ssi_parselist(aim_sessio
-
- /* Don't attempt to re-request our buddy list later */
- if (od->getblisttimer != 0)
-- gaim_timeout_remove(od->getblisttimer);
-+ gaim2_timeout_remove(od->getblisttimer);
- od->getblisttimer = 0;
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: syncing local list and server list\n");
-
- if ((timestamp == 0) || (numitems == 0)) {
-- gaim_debug_info("oscar", "Got AIM SSI with a 0 timestamp or 0 numitems--not syncing. This probably means your buddy list is empty.", NULL);
-+ gaim2_debug_info("oscar", "Got AIM SSI with a 0 timestamp or 0 numitems--not syncing. This probably means your buddy list is empty.", NULL);
- return 1;
- }
-
-@@ -7000,28 +7000,28 @@ static int gaim_ssi_parselist(aim_sessio
- aim_ssi_cleanlist(sess);
-
- { /* If not in server list then prune from local list */
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2BuddyList *blist;
- GSList *cur, *next;
-
- /* Buddies */
- cur = NULL;
-- if ((blist = gaim_get_blist()) != NULL) {
-+ if ((blist = gaim2_get_blist()) != NULL) {
- for (gnode = blist->root; gnode; gnode = gnode->next) {
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-- g = (GaimGroup *)gnode;
-+ g = (Gaim2Group *)gnode;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if (b->account == gc->account) {
- if (aim_ssi_itemlist_exists(sess->ssi.local, b->name)) {
- /* If the buddy is an ICQ user then load his nickname */
-- const char *servernick = gaim_blist_node_get_string((GaimBlistNode*)b, "servernick");
-+ const char *servernick = gaim2_blist_node_get_string((Gaim2BlistNode*)b, "servernick");
- char *alias;
- if (servernick)
- serv_got_alias(gc, b->name, servernick);
-@@ -7032,7 +7032,7 @@ static int gaim_ssi_parselist(aim_sessio
- aim_ssi_aliasbuddy(sess, g->name, b->name, b->alias);
- free(alias);
- } else {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: removing buddy %s from local list\n", b->name);
- /* We can't actually remove now because it will screw up our looping */
- cur = g_slist_prepend(cur, b);
-@@ -7046,7 +7046,7 @@ static int gaim_ssi_parselist(aim_sessio
- while (cur != NULL) {
- b = cur->data;
- cur = g_slist_remove(cur, b);
-- gaim_blist_remove_buddy(b);
-+ gaim2_blist_remove_buddy(b);
- }
-
- /* Permit list */
-@@ -7056,9 +7056,9 @@ static int gaim_ssi_parselist(aim_sessio
- cur = next;
- next = next->next;
- if (!aim_ssi_itemlist_finditem(sess->ssi.local, NULL, cur->data, AIM_SSI_TYPE_PERMIT)) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: removing permit %s from local list\n", (const char *)cur->data);
-- gaim_privacy_permit_remove(account, cur->data, TRUE);
-+ gaim2_privacy_permit_remove(account, cur->data, TRUE);
- }
- }
- }
-@@ -7070,9 +7070,9 @@ static int gaim_ssi_parselist(aim_sessio
- cur = next;
- next = next->next;
- if (!aim_ssi_itemlist_finditem(sess->ssi.local, NULL, cur->data, AIM_SSI_TYPE_DENY)) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: removing deny %s from local list\n", (const char *)cur->data);
-- gaim_privacy_deny_remove(account, cur->data, TRUE);
-+ gaim2_privacy_deny_remove(account, cur->data, TRUE);
- }
- }
- }
-@@ -7092,7 +7092,7 @@ static int gaim_ssi_parselist(aim_sessio
- char *gname_utf8 = gname ? oscar_utf8_try_convert(gc->account, gname) : NULL;
- char *alias = aim_ssi_getalias(sess->ssi.local, gname, curitem->name);
- char *alias_utf8 = alias ? oscar_utf8_try_convert(gc->account, alias) : NULL;
-- b = gaim_find_buddy(gc->account, curitem->name);
-+ b = gaim2_find_buddy(gc->account, curitem->name);
- /* Should gname be freed here? -- elb */
- /* Not with the current code, but that might be cleaner -- med */
- free(alias);
-@@ -7103,20 +7103,20 @@ static int gaim_ssi_parselist(aim_sessio
- b->alias = g_strdup(alias_utf8);
- }
- } else {
-- b = gaim_buddy_new(gc->account, curitem->name, alias_utf8);
-+ b = gaim2_buddy_new(gc->account, curitem->name, alias_utf8);
-
-- if (!(g = gaim_find_group(gname_utf8 ? gname_utf8 : _("Orphans")))) {
-- g = gaim_group_new(gname_utf8 ? gname_utf8 : _("Orphans"));
-- gaim_blist_add_group(g, NULL);
-+ if (!(g = gaim2_find_group(gname_utf8 ? gname_utf8 : _("Orphans")))) {
-+ g = gaim2_group_new(gname_utf8 ? gname_utf8 : _("Orphans"));
-+ gaim2_blist_add_group(g, NULL);
- }
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: adding buddy %s to group %s to local list\n", curitem->name, gname_utf8 ? gname_utf8 : _("Orphans"));
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- }
- if (!aim_sncmp(curitem->name, account->username)) {
- char *comment = aim_ssi_getcomment(sess->ssi.local, gname, curitem->name);
-- gaim_check_comment(od, comment);
-+ gaim2_check_comment(od, comment);
- free(comment);
- }
- g_free(gname_utf8);
-@@ -7134,9 +7134,9 @@ static int gaim_ssi_parselist(aim_sessio
- GSList *list;
- for (list=account->permit; (list && aim_sncmp(curitem->name, list->data)); list=list->next);
- if (!list) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: adding permit buddy %s to local list\n", curitem->name);
-- gaim_privacy_permit_add(account, curitem->name, TRUE);
-+ gaim2_privacy_permit_add(account, curitem->name, TRUE);
- }
- }
- } break;
-@@ -7146,9 +7146,9 @@ static int gaim_ssi_parselist(aim_sessio
- GSList *list;
- for (list=account->deny; (list && aim_sncmp(curitem->name, list->data)); list=list->next);
- if (!list) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: adding deny buddy %s to local list\n", curitem->name);
-- gaim_privacy_deny_add(account, curitem->name, TRUE);
-+ gaim2_privacy_deny_add(account, curitem->name, TRUE);
- }
- }
- } break;
-@@ -7157,18 +7157,18 @@ static int gaim_ssi_parselist(aim_sessio
- if (curitem->data) {
- fu8_t permdeny;
- if ((permdeny = aim_ssi_getpermdeny(sess->ssi.local)) && (permdeny != account->perm_deny)) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: changing permdeny from %d to %hhu\n", account->perm_deny, permdeny);
- account->perm_deny = permdeny;
- if (od->icq && account->perm_deny == GAIM_PRIVACY_ALLOW_USERS) {
-- gaim_presence_set_status_active(account->presence, OSCAR_STATUS_ID_INVISIBLE, TRUE);
-+ gaim2_presence_set_status_active(account->presence, OSCAR_STATUS_ID_INVISIBLE, TRUE);
- }
- }
- }
- } break;
-
- case 0x0005: { /* Presence setting */
-- /* We don't want to change Gaim's setting because it applies to all accounts */
-+ /* We don't want to change Gaim2's setting because it applies to all accounts */
- } break;
- } /* End of switch on curitem->type */
- } /* End of for loop */
-@@ -7178,15 +7178,15 @@ static int gaim_ssi_parselist(aim_sessio
- /* Activate SSI */
- /* Sending the enable causes other people to be able to see you, and you to see them */
- /* Make sure your privacy setting/invisibility is set how you want it before this! */
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: activating server-stored buddy list\n");
- aim_ssi_enable(sess);
-
- return 1;
- }
-
--static int gaim_ssi_parseack(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_parseack(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- struct aim_ssi_tmp *retval;
-
-@@ -7195,7 +7195,7 @@ static int gaim_ssi_parseack(aim_session
- va_end(ap);
-
- while (retval) {
-- gaim_debug_misc("oscar",
-+ gaim2_debug_misc("oscar",
- "ssi: status is 0x%04hx for a 0x%04hx action with name %s\n", retval->ack, retval->action, retval->item ? (retval->item->name ? retval->item->name : "no name") : "no item");
-
- if (retval->ack != 0xffff)
-@@ -7206,22 +7206,22 @@ static int gaim_ssi_parseack(aim_session
- case 0x000c: { /* you are over the limit, the cheat is to the limit, come on fhqwhgads */
- gchar *buf;
- buf = g_strdup_printf(_("Could not add the buddy %s because you have too many buddies in your buddy list. Please remove one and try again."), (retval->name ? retval->name : _("(no name)")));
-- if ((retval->name != NULL) && !gaim_conv_present_error(retval->name, gaim_connection_get_account(gc), buf))
-- gaim_notify_error(gc, NULL, _("Unable To Add"), buf);
-+ if ((retval->name != NULL) && !gaim2_conv_present_error(retval->name, gaim2_connection_get_account(gc), buf))
-+ gaim2_notify_error(gc, NULL, _("Unable To Add"), buf);
- g_free(buf);
- }
-
- case 0x000e: { /* buddy requires authorization */
- if ((retval->action == AIM_CB_SSI_ADD) && (retval->name))
-- gaim_auth_sendrequest(gc, retval->name);
-+ gaim2_auth_sendrequest(gc, retval->name);
- } break;
-
- default: { /* La la la */
- gchar *buf;
-- gaim_debug_error("oscar", "ssi: Action 0x%04hx was unsuccessful with error 0x%04hx\n", retval->action, retval->ack);
-+ gaim2_debug_error("oscar", "ssi: Action 0x%04hx was unsuccessful with error 0x%04hx\n", retval->action, retval->ack);
- buf = g_strdup_printf(_("Could not add the buddy %s for an unknown reason. The most common reason for this is that you have the maximum number of allowed buddies in your buddy list."), (retval->name ? retval->name : _("(no name)")));
-- if ((retval->name != NULL) && !gaim_conv_present_error(retval->name, gaim_connection_get_account(gc), buf))
-- gaim_notify_error(gc, NULL, _("Unable To Add"), buf);
-+ if ((retval->name != NULL) && !gaim2_conv_present_error(retval->name, gaim2_connection_get_account(gc), buf))
-+ gaim2_notify_error(gc, NULL, _("Unable To Add"), buf);
- g_free(buf);
- } break;
- }
-@@ -7232,11 +7232,11 @@ static int gaim_ssi_parseack(aim_session
- return 1;
- }
-
--static int gaim_ssi_parseadd(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_parseadd(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- char *gname, *gname_utf8, *alias, *alias_utf8;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
- va_list ap;
- fu16_t type;
- const char *name;
-@@ -7253,7 +7253,7 @@ static int gaim_ssi_parseadd(aim_session
- gname_utf8 = gname ? oscar_utf8_try_convert(gc->account, gname) : NULL;
- alias = aim_ssi_getalias(sess->ssi.local, gname, name);
- alias_utf8 = alias ? oscar_utf8_try_convert(gc->account, alias) : NULL;
-- b = gaim_find_buddy(gc->account, name);
-+ b = gaim2_find_buddy(gc->account, name);
- free(alias);
-
- if (b) {
-@@ -7263,16 +7263,16 @@ static int gaim_ssi_parseadd(aim_session
- b->alias = g_strdup(alias_utf8);
- }
- } else {
-- b = gaim_buddy_new(gc->account, name, alias_utf8);
-+ b = gaim2_buddy_new(gc->account, name, alias_utf8);
-
-- if (!(g = gaim_find_group(gname_utf8 ? gname_utf8 : _("Orphans")))) {
-- g = gaim_group_new(gname_utf8 ? gname_utf8 : _("Orphans"));
-- gaim_blist_add_group(g, NULL);
-+ if (!(g = gaim2_find_group(gname_utf8 ? gname_utf8 : _("Orphans")))) {
-+ g = gaim2_group_new(gname_utf8 ? gname_utf8 : _("Orphans"));
-+ gaim2_blist_add_group(g, NULL);
- }
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: adding buddy %s to group %s to local list\n", name, gname_utf8 ? gname_utf8 : _("Orphans"));
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- }
- g_free(gname_utf8);
- g_free(alias_utf8);
-@@ -7280,25 +7280,25 @@ static int gaim_ssi_parseadd(aim_session
- return 1;
- }
-
--static int gaim_ssi_authgiven(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_authgiven(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- char *sn, *msg;
- gchar *dialog_msg, *nombre;
- struct name_data *data;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- va_start(ap, fr);
- sn = va_arg(ap, char *);
- msg = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: %s has given you permission to add him to your buddy list\n", sn);
-
-- buddy = gaim_find_buddy(gc->account, sn);
-- if (buddy && (gaim_buddy_get_alias_only(buddy)))
-- nombre = g_strdup_printf("%s (%s)", sn, gaim_buddy_get_alias_only(buddy));
-+ buddy = gaim2_find_buddy(gc->account, sn);
-+ if (buddy && (gaim2_buddy_get_alias_only(buddy)))
-+ nombre = g_strdup_printf("%s (%s)", sn, gaim2_buddy_get_alias_only(buddy));
- else
- nombre = g_strdup(sn);
-
-@@ -7308,9 +7308,9 @@ static int gaim_ssi_authgiven(aim_sessio
- data->name = g_strdup(sn);
- data->nick = NULL;
-
-- gaim_request_yes_no(gc, NULL, _("Authorization Given"), dialog_msg,
-+ gaim2_request_yes_no(gc, NULL, _("Authorization Given"), dialog_msg,
- GAIM_DEFAULT_ACTION_NONE, data,
-- G_CALLBACK(gaim_icq_buddyadd),
-+ G_CALLBACK(gaim2_icq_buddyadd),
- G_CALLBACK(oscar_free_name_data));
-
- g_free(dialog_msg);
-@@ -7319,41 +7319,41 @@ static int gaim_ssi_authgiven(aim_sessio
- return 1;
- }
-
--static int gaim_ssi_authrequest(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_authrequest(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- char *sn;
- char *msg;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- gchar *nombre;
- gchar *reason = NULL;
- gchar *dialog_msg;
- struct name_data *data;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- va_start(ap, fr);
- sn = va_arg(ap, char *);
- msg = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: received authorization request from %s\n", sn);
-
-- buddy = gaim_find_buddy(account, sn);
-- if (buddy && (gaim_buddy_get_alias_only(buddy)))
-- nombre = g_strdup_printf("%s (%s)", sn, gaim_buddy_get_alias_only(buddy));
-+ buddy = gaim2_find_buddy(account, sn);
-+ if (buddy && (gaim2_buddy_get_alias_only(buddy)))
-+ nombre = g_strdup_printf("%s (%s)", sn, gaim2_buddy_get_alias_only(buddy));
- else
- nombre = g_strdup(sn);
-
- if (msg != NULL)
-- reason = gaim_plugin_oscar_decode_im_part(account, sn, AIM_CHARSET_CUSTOM, 0x0000, msg, strlen(msg));
-+ reason = gaim2_plugin_oscar_decode_im_part(account, sn, AIM_CHARSET_CUSTOM, 0x0000, msg, strlen(msg));
-
- if (reason == NULL)
- reason = g_strdup(_("No reason given."));
-
- dialog_msg = g_strdup_printf(
- _("The user %s wants to add %s to their buddy list for the following reason:\n%s"),
-- nombre, gaim_account_get_username(account), reason);
-+ nombre, gaim2_account_get_username(account), reason);
- g_free(reason);
-
- data = g_new(struct name_data, 1);
-@@ -7361,10 +7361,10 @@ static int gaim_ssi_authrequest(aim_sess
- data->name = g_strdup(sn);
- data->nick = NULL;
-
-- gaim_request_action(gc, NULL, _("Authorization Request"), dialog_msg,
-+ gaim2_request_action(gc, NULL, _("Authorization Request"), dialog_msg,
- GAIM_DEFAULT_ACTION_NONE, data, 2,
-- _("_Authorize"), G_CALLBACK(gaim_auth_grant),
-- _("_Deny"), G_CALLBACK(gaim_auth_dontgrant_msgprompt));
-+ _("_Authorize"), G_CALLBACK(gaim2_auth_grant),
-+ _("_Deny"), G_CALLBACK(gaim2_auth_dontgrant_msgprompt));
-
- g_free(dialog_msg);
- g_free(nombre);
-@@ -7372,13 +7372,13 @@ static int gaim_ssi_authrequest(aim_sess
- return 1;
- }
-
--static int gaim_ssi_authreply(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_authreply(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- char *sn, *msg;
- gchar *dialog_msg, *nombre;
- fu8_t reply;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- va_start(ap, fr);
- sn = va_arg(ap, char *);
-@@ -7386,23 +7386,23 @@ static int gaim_ssi_authreply(aim_sessio
- msg = va_arg(ap, char *);
- va_end(ap);
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "ssi: received authorization reply from %s. Reply is 0x%04hhx\n", sn, reply);
-
-- buddy = gaim_find_buddy(gc->account, sn);
-- if (buddy && (gaim_buddy_get_alias_only(buddy)))
-- nombre = g_strdup_printf("%s (%s)", sn, gaim_buddy_get_alias_only(buddy));
-+ buddy = gaim2_find_buddy(gc->account, sn);
-+ if (buddy && (gaim2_buddy_get_alias_only(buddy)))
-+ nombre = g_strdup_printf("%s (%s)", sn, gaim2_buddy_get_alias_only(buddy));
- else
- nombre = g_strdup(sn);
-
- if (reply) {
- /* Granted */
- dialog_msg = g_strdup_printf(_("The user %s has granted your request to add them to your buddy list."), nombre);
-- gaim_notify_info(gc, NULL, _("Authorization Granted"), dialog_msg);
-+ gaim2_notify_info(gc, NULL, _("Authorization Granted"), dialog_msg);
- } else {
- /* Denied */
- dialog_msg = g_strdup_printf(_("The user %s has denied your request to add them to your buddy list for the following reason:\n%s"), nombre, msg ? msg : _("No reason given."));
-- gaim_notify_info(gc, NULL, _("Authorization Denied"), dialog_msg);
-+ gaim2_notify_info(gc, NULL, _("Authorization Denied"), dialog_msg);
- }
- g_free(dialog_msg);
- g_free(nombre);
-@@ -7410,25 +7410,25 @@ static int gaim_ssi_authreply(aim_sessio
- return 1;
- }
-
--static int gaim_ssi_gotadded(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+static int gaim2_ssi_gotadded(aim_session_t *sess, aim_frame_t *fr, ...) {
-+ Gaim2Connection *gc = sess->aux_data;
- va_list ap;
- char *sn;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- va_start(ap, fr);
- sn = va_arg(ap, char *);
- va_end(ap);
-
-- buddy = gaim_find_buddy(gc->account, sn);
-- gaim_debug_info("oscar",
-+ buddy = gaim2_find_buddy(gc->account, sn);
-+ gaim2_debug_info("oscar",
- "ssi: %s added you to their buddy list\n", sn);
-- gaim_account_notify_added(gc->account, NULL, sn, (buddy ? gaim_buddy_get_alias_only(buddy) : NULL), NULL);
-+ gaim2_account_notify_added(gc->account, NULL, sn, (buddy ? gaim2_buddy_get_alias_only(buddy) : NULL), NULL);
-
- return 1;
- }
-
--static GList *oscar_chat_info(GaimConnection *gc) {
-+static GList *oscar_chat_info(Gaim2Connection *gc) {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-
-@@ -7450,7 +7450,7 @@ static GList *oscar_chat_info(GaimConnec
- return m;
- }
-
--static GHashTable *oscar_chat_info_defaults(GaimConnection *gc, const char *chat_name)
-+static GHashTable *oscar_chat_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
-
-@@ -7466,7 +7466,7 @@ static char *oscar_get_chat_name(GHashTa
- return g_strdup(g_hash_table_lookup(data, "room"));
- }
-
--static void oscar_join_chat(GaimConnection *gc, GHashTable *data) {
-+static void oscar_join_chat(Gaim2Connection *gc, GHashTable *data) {
- OscarData *od = (OscarData *)gc->proto_data;
- aim_conn_t *cur;
- char *name, *exchange;
-@@ -7475,21 +7475,21 @@ static void oscar_join_chat(GaimConnecti
- exchange = g_hash_table_lookup(data, "exchange");
-
- if ((name == NULL) || (*name == '\0')) {
-- gaim_notify_error(gc, NULL, _("Invalid chat name specified."), NULL);
-+ gaim2_notify_error(gc, NULL, _("Invalid chat name specified."), NULL);
- return;
- }
-
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Attempting to join chat room %s.\n", name);
-
- if ((cur = aim_getconn_type(od->sess, AIM_CONN_TYPE_CHATNAV))) {
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "chatnav exists, creating room\n");
- aim_chatnav_createroom(od->sess, cur, name, atoi(exchange));
- } else {
- /* this gets tricky */
- struct create_room *cr = g_new0(struct create_room, 1);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "chatnav does not exist, opening chatnav\n");
- cr->exchange = atoi(exchange);
- cr->name = g_strdup(name);
-@@ -7498,7 +7498,7 @@ static void oscar_join_chat(GaimConnecti
- }
- }
-
--static void oscar_chat_invite(GaimConnection *gc, int id, const char *message, const char *name) {
-+static void oscar_chat_invite(Gaim2Connection *gc, int id, const char *message, const char *name) {
- OscarData *od = (OscarData *)gc->proto_data;
- struct chat_connection *ccon = find_oscar_chat(gc, id);
-
-@@ -7510,46 +7510,46 @@ static void oscar_chat_invite(GaimConnec
- }
-
- static void
--oscar_chat_leave(GaimConnection *gc, int id)
-+oscar_chat_leave(Gaim2Connection *gc, int id)
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- struct chat_connection *cc;
-
-- conv = gaim_find_chat(gc, id);
-+ conv = gaim2_find_chat(gc, id);
-
- g_return_if_fail(conv != NULL);
-
-- gaim_debug_info("oscar", "Leaving chat room %s\n", conv->name);
-+ gaim2_debug_info("oscar", "Leaving chat room %s\n", conv->name);
-
-- cc = find_oscar_chat(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv)));
-+ cc = find_oscar_chat(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv)));
- oscar_chat_kill(gc, cc);
- }
-
--static int oscar_send_chat(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags) {
-+static int oscar_send_chat(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags) {
- OscarData *od = (OscarData *)gc->proto_data;
-- GaimConversation *conv = NULL;
-+ Gaim2Conversation *conv = NULL;
- struct chat_connection *c = NULL;
- char *buf, *buf2;
- fu16_t charset, charsubset;
- char *charsetstr = NULL;
- int len;
-
-- if (!(conv = gaim_find_chat(gc, id)))
-+ if (!(conv = gaim2_find_chat(gc, id)))
- return -EINVAL;
-
- if (!(c = find_oscar_chat_by_conv(gc, conv)))
- return -EINVAL;
-
-- buf = gaim_strdup_withhtml(message);
-+ buf = gaim2_strdup_withhtml(message);
- len = strlen(buf);
-
- if (strstr(buf, "<IMG "))
-- gaim_conversation_write(conv, "",
-+ gaim2_conversation_write(conv, "",
- _("Your IM Image was not sent. "
- "You cannot send IM Images in AIM chats."),
- GAIM_MESSAGE_ERROR, time(NULL));
-
-- gaim_plugin_oscar_convert_to_best_encoding(gc, NULL, buf, &buf2, &len, &charset, &charsubset);
-+ gaim2_plugin_oscar_convert_to_best_encoding(gc, NULL, buf, &buf2, &len, &charset, &charsubset);
- if ((len > c->maxlen) || (len > c->maxvis)) {
- g_free(buf2);
- return -E2BIG;
-@@ -7567,10 +7567,10 @@ static int oscar_send_chat(GaimConnectio
- return 0;
- }
-
--static const char *oscar_list_icon(GaimAccount *a, GaimBuddy *b)
-+static const char *oscar_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- if (!b || (b && b->name && b->name[0] == '+')) {
-- if (a != NULL && aim_sn_is_icq(gaim_account_get_username(a)))
-+ if (a != NULL && aim_sn_is_icq(gaim2_account_get_username(a)))
- return "icq";
- else
- return "aim";
-@@ -7581,13 +7581,13 @@ static const char *oscar_list_icon(GaimA
- return "aim";
- }
-
--static void oscar_list_emblems(GaimBuddy *b, const char **se, const char **sw, const char **nw, const char **ne)
-+static void oscar_list_emblems(Gaim2Buddy *b, const char **se, const char **sw, const char **nw, const char **ne)
- {
-- GaimConnection *gc = NULL;
-+ Gaim2Connection *gc = NULL;
- OscarData *od = NULL;
-- GaimAccount *account = NULL;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Account *account = NULL;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- const char *status_id;
- char *emblems[4] = {NULL,NULL,NULL,NULL};
- int i = 0;
-@@ -7602,11 +7602,11 @@ static void oscar_list_emblems(GaimBuddy
- if (od != NULL)
- userinfo = aim_locate_finduserinfo(od->sess, b->name);
-
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-- status_id = gaim_status_get_id(status);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-+ status_id = gaim2_status_get_id(status);
-
-- if (gaim_presence_is_online(presence) == FALSE) {
-+ if (gaim2_presence_is_online(presence) == FALSE) {
- char *gname;
- if ((b->name) && (od) && (od->sess->ssi.received_data) &&
- (gname = aim_ssi_itemlist_findparentname(od->sess->ssi.local, b->name)) &&
-@@ -7659,24 +7659,24 @@ static void oscar_list_emblems(GaimBuddy
- *ne = emblems[3];
- }
-
--static char *oscar_tooltip_text(GaimBuddy *b) {
-- GaimConnection *gc = b->account->gc;
-+static char *oscar_tooltip_text(Gaim2Buddy *b) {
-+ Gaim2Connection *gc = b->account->gc;
- OscarData *od = gc->proto_data;
- aim_userinfo_t *userinfo = aim_locate_finduserinfo(od->sess, b->name);
- GString *str = g_string_new("");
-
- if (GAIM_BUDDY_IS_ONLINE(b)) {
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- const char *message;
-
- oscar_string_append_info(gc, str, "\n", b, userinfo);
-
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-- message = gaim_status_get_attr_string(status, "message");
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-+ message = gaim2_status_get_attr_string(status, "message");
-
-- if (gaim_status_is_available(status))
-+ if (gaim2_status_is_available(status))
- {
- if (message != NULL)
- {
-@@ -7690,10 +7690,10 @@ static char *oscar_tooltip_text(GaimBudd
- {
- /* Away messages are HTML */
- gchar *tmp1, *tmp2;
-- tmp2 = gaim_markup_strip_html(message);
-+ tmp2 = gaim2_markup_strip_html(message);
- tmp1 = g_markup_escape_text(tmp2, -1);
- g_free(tmp2);
-- tmp2 = gaim_str_sub_away_formatters(tmp1, gaim_account_get_username(gaim_connection_get_account(gc)));
-+ tmp2 = gaim2_str_sub_away_formatters(tmp1, gaim2_account_get_username(gaim2_connection_get_account(gc)));
- g_free(tmp1);
- g_string_append_printf(str, "\n<b>%s:</b> %s", _("Away Message"), tmp2);
- g_free(tmp2);
-@@ -7708,25 +7708,25 @@ static char *oscar_tooltip_text(GaimBudd
- return g_string_free(str, FALSE);
- }
-
--static char *oscar_status_text(GaimBuddy *b)
-+static char *oscar_status_text(Gaim2Buddy *b)
- {
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- OscarData *od;
-- const GaimPresence *presence;
-- const GaimStatus *status;
-+ const Gaim2Presence *presence;
-+ const Gaim2Status *status;
- const char *id;
- const char *message;
- gchar *ret = NULL;
-
-- gc = gaim_account_get_connection(gaim_buddy_get_account(b));
-- account = gaim_connection_get_account(gc);
-+ gc = gaim2_account_get_connection(gaim2_buddy_get_account(b));
-+ account = gaim2_connection_get_account(gc);
- od = gc->proto_data;
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-- id = gaim_status_get_id(status);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-+ id = gaim2_status_get_id(status);
-
-- if (!gaim_presence_is_online(presence))
-+ if (!gaim2_presence_is_online(presence))
- {
- char *gname = aim_ssi_itemlist_findparentname(od->sess->ssi.local, b->name);
- if (aim_ssi_waitingforauth(od->sess->ssi.local, gname, b->name))
-@@ -7734,27 +7734,27 @@ static char *oscar_status_text(GaimBuddy
- else
- ret = g_strdup(_("Offline"));
- }
-- else if (gaim_status_is_available(status) && !strcmp(id, OSCAR_STATUS_ID_AVAILABLE))
-+ else if (gaim2_status_is_available(status) && !strcmp(id, OSCAR_STATUS_ID_AVAILABLE))
- {
- /* Available */
-- message = gaim_status_get_attr_string(status, "message");
-+ message = gaim2_status_get_attr_string(status, "message");
- if (message != NULL)
- {
- ret = g_markup_escape_text(message, -1);
-- gaim_util_chrreplace(ret, '\n', ' ');
-+ gaim2_util_chrreplace(ret, '\n', ' ');
- }
- }
-- else if (!gaim_status_is_available(status) && !strcmp(id, OSCAR_STATUS_ID_AWAY))
-+ else if (!gaim2_status_is_available(status) && !strcmp(id, OSCAR_STATUS_ID_AWAY))
- {
- /* Away */
-- message = gaim_status_get_attr_string(status, "message");
-+ message = gaim2_status_get_attr_string(status, "message");
- if (message != NULL)
- {
- gchar *tmp1, *tmp2;
-- tmp1 = gaim_markup_strip_html(message);
-- gaim_util_chrreplace(tmp1, '\n', ' ');
-+ tmp1 = gaim2_markup_strip_html(message);
-+ gaim2_util_chrreplace(tmp1, '\n', ' ');
- tmp2 = g_markup_escape_text(tmp1, -1);
-- ret = gaim_str_sub_away_formatters(tmp2, gaim_account_get_username(account));
-+ ret = gaim2_str_sub_away_formatters(tmp2, gaim2_account_get_username(account));
- g_free(tmp1);
- g_free(tmp2);
- }
-@@ -7764,14 +7764,14 @@ static char *oscar_status_text(GaimBuddy
- }
- }
- else
-- ret = g_strdup(gaim_status_get_name(status));
-+ ret = g_strdup(gaim2_status_get_name(status));
-
- return ret;
- }
-
-
- static int oscar_icon_req(aim_session_t *sess, aim_frame_t *fr, ...) {
-- GaimConnection *gc = sess->aux_data;
-+ Gaim2Connection *gc = sess->aux_data;
- OscarData *od = gc->proto_data;
- va_list ap;
- fu16_t type;
-@@ -7795,7 +7795,7 @@ static int oscar_icon_req(aim_session_t
- aim_reqservice(od->sess, od->conn, AIM_CONN_TYPE_ICON);
- } else {
- struct stat st;
-- char *iconfile = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(gaim_connection_get_account(gc)));
-+ char *iconfile = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(gaim2_connection_get_account(gc)));
- if (iconfile == NULL) {
- aim_ssi_delicon(od->sess);
- } else if (!g_stat(iconfile, &st)) {
-@@ -7805,21 +7805,21 @@ static int oscar_icon_req(aim_session_t
- /* XXX - Use g_file_get_contents()? */
- fread(buf, 1, st.st_size, file);
- fclose(file);
-- gaim_debug_info("oscar",
-+ gaim2_debug_info("oscar",
- "Uploading icon to icon server\n");
- aim_bart_upload(od->sess, buf, st.st_size);
- } else
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't open buddy icon file!\n");
- g_free(buf);
- } else {
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't stat buddy icon file!\n");
- }
- g_free(iconfile);
- }
- } else if (flags == 0x81) {
-- char *iconfile = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(gaim_connection_get_account(gc)));
-+ char *iconfile = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(gaim2_connection_get_account(gc)));
- if (iconfile == NULL)
- aim_ssi_delicon(od->sess);
- else {
-@@ -7838,8 +7838,8 @@ static int oscar_icon_req(aim_session_t
- return 0;
- }
-
--static void oscar_set_permit_deny(GaimConnection *gc) {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+static void oscar_set_permit_deny(Gaim2Connection *gc) {
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- OscarData *od = (OscarData *)gc->proto_data;
-
- if (od->sess->ssi.received_data) {
-@@ -7866,77 +7866,77 @@ static void oscar_set_permit_deny(GaimCo
- }
- }
-
--static void oscar_add_permit(GaimConnection *gc, const char *who) {
-+static void oscar_add_permit(Gaim2Connection *gc, const char *who) {
- OscarData *od = (OscarData *)gc->proto_data;
-- gaim_debug_info("oscar", "ssi: About to add a permit\n");
-+ gaim2_debug_info("oscar", "ssi: About to add a permit\n");
- if (od->sess->ssi.received_data)
- aim_ssi_addpermit(od->sess, who);
- }
-
--static void oscar_add_deny(GaimConnection *gc, const char *who) {
-+static void oscar_add_deny(Gaim2Connection *gc, const char *who) {
- OscarData *od = (OscarData *)gc->proto_data;
-- gaim_debug_info("oscar", "ssi: About to add a deny\n");
-+ gaim2_debug_info("oscar", "ssi: About to add a deny\n");
- if (od->sess->ssi.received_data)
- aim_ssi_adddeny(od->sess, who);
- }
-
--static void oscar_rem_permit(GaimConnection *gc, const char *who) {
-+static void oscar_rem_permit(Gaim2Connection *gc, const char *who) {
- OscarData *od = (OscarData *)gc->proto_data;
-- gaim_debug_info("oscar", "ssi: About to delete a permit\n");
-+ gaim2_debug_info("oscar", "ssi: About to delete a permit\n");
- if (od->sess->ssi.received_data)
- aim_ssi_delpermit(od->sess, who);
- }
-
--static void oscar_rem_deny(GaimConnection *gc, const char *who) {
-+static void oscar_rem_deny(Gaim2Connection *gc, const char *who) {
- OscarData *od = (OscarData *)gc->proto_data;
-- gaim_debug_info("oscar", "ssi: About to delete a deny\n");
-+ gaim2_debug_info("oscar", "ssi: About to delete a deny\n");
- if (od->sess->ssi.received_data)
- aim_ssi_deldeny(od->sess, who);
- }
-
- static GList *
--oscar_status_types(GaimAccount *account)
-+oscar_status_types(Gaim2Account *account)
- {
- gboolean is_icq;
- GList *status_types = NULL;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- is_icq = aim_sn_is_icq(gaim_account_get_username(account));
-+ is_icq = aim_sn_is_icq(gaim2_account_get_username(account));
-
- /* Oscar-common status types */
- if (is_icq)
- {
-- type = gaim_status_type_new_full(GAIM_STATUS_AVAILABLE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AVAILABLE,
- OSCAR_STATUS_ID_AVAILABLE,
- NULL, TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_AVAILABLE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AVAILABLE,
- OSCAR_STATUS_ID_FREE4CHAT,
- _("Free For Chat"), TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
- }
- else
- {
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE,
- OSCAR_STATUS_ID_AVAILABLE,
- NULL, TRUE, TRUE, FALSE,
- "message", _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ gaim2_value_new(GAIM_TYPE_STRING), NULL);
- status_types = g_list_append(status_types, type);
- }
-
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AWAY,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AWAY,
- OSCAR_STATUS_ID_AWAY,
- NULL, TRUE, TRUE, FALSE,
- "message", _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ gaim2_value_new(GAIM_TYPE_STRING), NULL);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_INVISIBLE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_INVISIBLE,
- OSCAR_STATUS_ID_INVISIBLE,
- NULL, TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-@@ -7944,23 +7944,23 @@ oscar_status_types(GaimAccount *account)
- /* ICQ-specific status types */
- if (is_icq)
- {
-- type = gaim_status_type_new_full(GAIM_STATUS_UNAVAILABLE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_UNAVAILABLE,
- OSCAR_STATUS_ID_OCCUPIED,
- _("Occupied"), TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_EXTENDED_AWAY,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_EXTENDED_AWAY,
- OSCAR_STATUS_ID_DND,
- _("Do Not Disturb"), TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-
-- type = gaim_status_type_new_full(GAIM_STATUS_EXTENDED_AWAY,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_EXTENDED_AWAY,
- OSCAR_STATUS_ID_NA,
- _("Not Available"), TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
- }
-
-- type = gaim_status_type_new_full(GAIM_STATUS_OFFLINE,
-+ type = gaim2_status_type_new_full(GAIM_STATUS_OFFLINE,
- OSCAR_STATUS_ID_OFFLINE,
- NULL, TRUE, TRUE, FALSE);
- status_types = g_list_append(status_types, type);
-@@ -7969,17 +7969,17 @@ oscar_status_types(GaimAccount *account)
- }
-
- static void oscar_ssi_editcomment(struct name_data *data, const char *text) {
-- GaimConnection *gc = data->gc;
-+ Gaim2Connection *gc = data->gc;
- OscarData *od = gc->proto_data;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
-
-- if (!(b = gaim_find_buddy(gaim_connection_get_account(data->gc), data->name))) {
-+ if (!(b = gaim2_find_buddy(gaim2_connection_get_account(data->gc), data->name))) {
- oscar_free_name_data(data);
- return;
- }
-
-- if (!(g = gaim_buddy_get_group(b))) {
-+ if (!(g = gaim2_buddy_get_group(b))) {
- oscar_free_name_data(data);
- return;
- }
-@@ -7987,31 +7987,31 @@ static void oscar_ssi_editcomment(struct
- aim_ssi_editcomment(od->sess, g->name, data->name, text);
-
- if (!aim_sncmp(data->name, gc->account->username))
-- gaim_check_comment(od, text);
-+ gaim2_check_comment(od, text);
-
- oscar_free_name_data(data);
- }
-
--static void oscar_buddycb_edit_comment(GaimBlistNode *node, gpointer ignore) {
-+static void oscar_buddycb_edit_comment(Gaim2BlistNode *node, gpointer ignore) {
-
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- OscarData *od;
- struct name_data *data;
-- GaimGroup *g;
-+ Gaim2Group *g;
- char *comment;
- gchar *comment_utf8;
- gchar *title;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- od = gc->proto_data;
-
- data = g_new(struct name_data, 1);
-
-- if (!(g = gaim_buddy_get_group(buddy)))
-+ if (!(g = gaim2_buddy_get_group(buddy)))
- return;
- comment = aim_ssi_getcomment(od->sess->ssi.local, g->name, buddy->name);
- comment_utf8 = comment ? oscar_utf8_try_convert(gc->account, comment) : NULL;
-@@ -8021,7 +8021,7 @@ static void oscar_buddycb_edit_comment(G
- data->nick = NULL;
-
- title = g_strdup_printf(_("Buddy Comment for %s"), data->name);
-- gaim_request_input(gc, title, _("Buddy Comment:"), NULL,
-+ gaim2_request_input(gc, title, _("Buddy Comment:"), NULL,
- comment_utf8, TRUE, FALSE, NULL,
- _("OK"), G_CALLBACK(oscar_ssi_editcomment),
- _("Cancel"), G_CALLBACK(oscar_free_name_data),
-@@ -8032,21 +8032,21 @@ static void oscar_buddycb_edit_comment(G
- g_free(comment_utf8);
- }
-
--static GList *oscar_buddy_menu(GaimBuddy *buddy) {
-+static GList *oscar_buddy_menu(Gaim2Buddy *buddy) {
-
-- GaimConnection *gc = gaim_account_get_connection(buddy->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(buddy->account);
- OscarData *od = gc->proto_data;
-
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
-- act = gaim_blist_node_action_new(_("Edit Buddy Comment"),
-+ act = gaim2_blist_node_action_new(_("Edit Buddy Comment"),
- oscar_buddycb_edit_comment, NULL, NULL);
- m = g_list_append(m, act);
-
- if (od->icq) {
- #if 0
-- act = gaim_blist_node_action_new(_("Get Status Msg"),
-+ act = gaim2_blist_node_action_new(_("Get Status Msg"),
- oscar_get_icqstatusmsg, NULL, NULL);
- m = g_list_append(m, act);
- #endif
-@@ -8054,17 +8054,17 @@ static GList *oscar_buddy_menu(GaimBuddy
- aim_userinfo_t *userinfo;
- userinfo = aim_locate_finduserinfo(od->sess, buddy->name);
-
-- if (userinfo && aim_sncmp(gaim_account_get_username(buddy->account), buddy->name) &&
-+ if (userinfo && aim_sncmp(gaim2_account_get_username(buddy->account), buddy->name) &&
- GAIM_BUDDY_IS_ONLINE(buddy)) {
-
- if (userinfo->capabilities & AIM_CAPS_DIRECTIM) {
-- act = gaim_blist_node_action_new(_("Direct IM"),
-+ act = gaim2_blist_node_action_new(_("Direct IM"),
- oscar_ask_direct_im, NULL, NULL);
- m = g_list_append(m, act);
- }
- #if 0
- if (userinfo->capabilities & AIM_CAPS_GETFILE) {
-- act = gaim_blist_node_action_new(_("Get File"),
-+ act = gaim2_blist_node_action_new(_("Get File"),
- oscar_ask_getfile, NULL, NULL);
- m = g_list_append(m, act);
- }
-@@ -8075,8 +8075,8 @@ static GList *oscar_buddy_menu(GaimBuddy
- if (od->sess->ssi.received_data) {
- char *gname = aim_ssi_itemlist_findparentname(od->sess->ssi.local, buddy->name);
- if (gname && aim_ssi_waitingforauth(od->sess->ssi.local, gname, buddy->name)) {
-- act = gaim_blist_node_action_new(_("Re-request Authorization"),
-- gaim_auth_sendrequest_menu, NULL, NULL);
-+ act = gaim2_blist_node_action_new(_("Re-request Authorization"),
-+ gaim2_auth_sendrequest_menu, NULL, NULL);
- m = g_list_append(m, act);
- }
- }
-@@ -8085,69 +8085,69 @@ static GList *oscar_buddy_menu(GaimBuddy
- }
-
-
--static GList *oscar_blist_node_menu(GaimBlistNode *node) {
-+static GList *oscar_blist_node_menu(Gaim2BlistNode *node) {
- if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- return oscar_buddy_menu((GaimBuddy *) node);
-+ return oscar_buddy_menu((Gaim2Buddy *) node);
- } else {
- return NULL;
- }
- }
-
- static void
--oscar_icq_privacy_opts(GaimConnection *gc, GaimRequestFields *fields)
-+oscar_icq_privacy_opts(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
- OscarData *od = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimRequestField *f;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2RequestField *f;
- gboolean auth, web_aware;
-
-- f = gaim_request_fields_get_field(fields, "authorization");
-- auth = gaim_request_field_bool_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "authorization");
-+ auth = gaim2_request_field_bool_get_value(f);
-
-- f = gaim_request_fields_get_field(fields, "web_aware");
-- web_aware = gaim_request_field_bool_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "web_aware");
-+ web_aware = gaim2_request_field_bool_get_value(f);
-
-- gaim_account_set_bool(account, "authorization", auth);
-- gaim_account_set_bool(account, "web_aware", web_aware);
-+ gaim2_account_set_bool(account, "authorization", auth);
-+ gaim2_account_set_bool(account, "web_aware", web_aware);
-
- oscar_set_extendedstatus(gc);
- aim_icq_setsecurity(od->sess, auth, web_aware);
- }
-
- static void
--oscar_show_icq_privacy_opts(GaimPluginAction *action)
-+oscar_show_icq_privacy_opts(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
- gboolean auth, web_aware;
-
-- auth = gaim_account_get_bool(account, "authorization", OSCAR_DEFAULT_AUTHORIZATION);
-- web_aware = gaim_account_get_bool(account, "web_aware", OSCAR_DEFAULT_WEB_AWARE);
-+ auth = gaim2_account_get_bool(account, "authorization", OSCAR_DEFAULT_AUTHORIZATION);
-+ web_aware = gaim2_account_get_bool(account, "web_aware", OSCAR_DEFAULT_WEB_AWARE);
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-+ g = gaim2_request_field_group_new(NULL);
-
-- f = gaim_request_field_bool_new("authorization", _("Require authorization"), auth);
-- gaim_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("authorization", _("Require authorization"), auth);
-+ gaim2_request_field_group_add_field(g, f);
-
-- f = gaim_request_field_bool_new("web_aware", _("Web aware (enabling this will cause you to receive SPAM!)"), web_aware);
-- gaim_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("web_aware", _("Web aware (enabling this will cause you to receive SPAM!)"), web_aware);
-+ gaim2_request_field_group_add_field(g, f);
-
-- gaim_request_fields_add_group(fields, g);
-+ gaim2_request_fields_add_group(fields, g);
-
-- gaim_request_fields(gc, _("ICQ Privacy Options"), _("ICQ Privacy Options"),
-+ gaim2_request_fields(gc, _("ICQ Privacy Options"), _("ICQ Privacy Options"),
- NULL, fields,
- _("OK"), G_CALLBACK(oscar_icq_privacy_opts),
- _("Cancel"), NULL, gc);
- }
-
--static void oscar_format_screenname(GaimConnection *gc, const char *nick) {
-+static void oscar_format_screenname(Gaim2Connection *gc, const char *nick) {
- OscarData *od = gc->proto_data;
-- if (!aim_sncmp(gaim_account_get_username(gaim_connection_get_account(gc)), nick)) {
-+ if (!aim_sncmp(gaim2_account_get_username(gaim2_connection_get_account(gc)), nick)) {
- if (!aim_getconn_type(od->sess, AIM_CONN_TYPE_AUTH)) {
- od->setnick = TRUE;
- od->newsn = g_strdup(nick);
-@@ -8156,24 +8156,24 @@ static void oscar_format_screenname(Gaim
- aim_admin_setnick(od->sess, aim_getconn_type(od->sess, AIM_CONN_TYPE_AUTH), nick);
- }
- } else {
-- gaim_notify_error(gc, NULL, _("The new formatting is invalid."),
-+ gaim2_notify_error(gc, NULL, _("The new formatting is invalid."),
- _("Screen name formatting can change only capitalization and whitespace."));
- }
- }
-
--static void oscar_show_format_screenname(GaimPluginAction *action)
-+static void oscar_show_format_screenname(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_request_input(gc, NULL, _("New screen name formatting:"), NULL,
-- gaim_connection_get_display_name(gc), FALSE, FALSE, NULL,
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_request_input(gc, NULL, _("New screen name formatting:"), NULL,
-+ gaim2_connection_get_display_name(gc), FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(oscar_format_screenname),
- _("Cancel"), NULL,
- gc);
- }
-
--static void oscar_confirm_account(GaimPluginAction *action)
-+static void oscar_confirm_account(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- OscarData *od = gc->proto_data;
- aim_conn_t *conn = aim_getconn_type(od->sess, AIM_CONN_TYPE_AUTH);
-
-@@ -8185,9 +8185,9 @@ static void oscar_confirm_account(GaimPl
- }
- }
-
--static void oscar_show_email(GaimPluginAction *action)
-+static void oscar_show_email(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- OscarData *od = gc->proto_data;
- aim_conn_t *conn = aim_getconn_type(od->sess, AIM_CONN_TYPE_AUTH);
-
-@@ -8199,7 +8199,7 @@ static void oscar_show_email(GaimPluginA
- }
- }
-
--static void oscar_change_email(GaimConnection *gc, const char *email)
-+static void oscar_change_email(Gaim2Connection *gc, const char *email)
- {
- OscarData *od = gc->proto_data;
- aim_conn_t *conn = aim_getconn_type(od->sess, AIM_CONN_TYPE_AUTH);
-@@ -8213,40 +8213,40 @@ static void oscar_change_email(GaimConne
- }
- }
-
--static void oscar_show_change_email(GaimPluginAction *action)
-+static void oscar_show_change_email(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_request_input(gc, NULL, _("Change Address To:"), NULL, NULL,
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_request_input(gc, NULL, _("Change Address To:"), NULL, NULL,
- FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(oscar_change_email),
- _("Cancel"), NULL,
- gc);
- }
-
--static void oscar_show_awaitingauth(GaimPluginAction *action)
-+static void oscar_show_awaitingauth(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- OscarData *od = gc->proto_data;
- gchar *nombre, *text, *tmp;
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- int num=0;
-
- text = g_strdup("");
-
-- for (gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-- GaimGroup *group = (GaimGroup *)gnode;
-+ for (gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
-+ Gaim2Group *group = (Gaim2Group *)gnode;
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *buddy = (GaimBuddy *)bnode;
-+ Gaim2Buddy *buddy = (Gaim2Buddy *)bnode;
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
- if (buddy->account == gc->account && aim_ssi_waitingforauth(od->sess->ssi.local, group->name, buddy->name)) {
-- if (gaim_buddy_get_alias_only(buddy))
-- nombre = g_strdup_printf(" %s (%s)", buddy->name, gaim_buddy_get_alias_only(buddy));
-+ if (gaim2_buddy_get_alias_only(buddy))
-+ nombre = g_strdup_printf(" %s (%s)", buddy->name, gaim2_buddy_get_alias_only(buddy));
- else
- nombre = g_strdup_printf(" %s", buddy->name);
- tmp = g_strdup_printf("%s%s<br>", text, nombre);
-@@ -8264,7 +8264,7 @@ static void oscar_show_awaitingauth(Gaim
- text = g_strdup(_("<i>you are not waiting for authorization</i>"));
- }
-
-- gaim_notify_formatted(gc, NULL, _("You are awaiting authorization from "
-+ gaim2_notify_formatted(gc, NULL, _("You are awaiting authorization from "
- "the following buddies"), _("You can re-request "
- "authorization from these buddies by "
- "right-clicking on them and selecting "
-@@ -8272,17 +8272,17 @@ static void oscar_show_awaitingauth(Gaim
- g_free(text);
- }
-
--static void search_by_email_cb(GaimConnection *gc, const char *email)
-+static void search_by_email_cb(Gaim2Connection *gc, const char *email)
- {
- OscarData *od = (OscarData *)gc->proto_data;
-
- aim_search_address(od->sess, od->conn, email);
- }
-
--static void oscar_show_find_email(GaimPluginAction *action)
-+static void oscar_show_find_email(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_request_input(gc, _("Find Buddy by E-mail"),
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_request_input(gc, _("Find Buddy by E-mail"),
- _("Search for a buddy by e-mail address"),
- _("Type the e-mail address of the buddy you are "
- "searching for."),
-@@ -8291,40 +8291,40 @@ static void oscar_show_find_email(GaimPl
- _("Cancel"), NULL, gc);
- }
-
--static void oscar_show_set_info(GaimPluginAction *action)
-+static void oscar_show_set_info(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_account_request_change_user_info(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_account_request_change_user_info(gaim2_connection_get_account(gc));
- }
-
--static void oscar_show_set_info_icqurl(GaimPluginAction *action)
-+static void oscar_show_set_info_icqurl(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_notify_uri(gc, "http://www.icq.com/whitepages/user_details.php");
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_notify_uri(gc, "http://www.icq.com/whitepages/user_details.php");
- }
-
--static void oscar_change_pass(GaimPluginAction *action)
-+static void oscar_change_pass(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_account_request_change_password(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_account_request_change_password(gaim2_connection_get_account(gc));
- }
-
--static void oscar_show_chpassurl(GaimPluginAction *action)
-+static void oscar_show_chpassurl(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- OscarData *od = gc->proto_data;
-- gchar *substituted = gaim_strreplace(od->sess->authinfo->chpassurl, "%s", gaim_account_get_username(gaim_connection_get_account(gc)));
-- gaim_notify_uri(gc, substituted);
-+ gchar *substituted = gaim2_strreplace(od->sess->authinfo->chpassurl, "%s", gaim2_account_get_username(gaim2_connection_get_account(gc)));
-+ gaim2_notify_uri(gc, substituted);
- g_free(substituted);
- }
-
--static void oscar_show_imforwardingurl(GaimPluginAction *action)
-+static void oscar_show_imforwardingurl(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_notify_uri(gc, "http://mymobile.aol.com/dbreg/register?action=imf&clientID=1");
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_notify_uri(gc, "http://mymobile.aol.com/dbreg/register?action=imf&clientID=1");
- }
-
--static void oscar_set_icon(GaimConnection *gc, const char *iconfile)
-+static void oscar_set_icon(Gaim2Connection *gc, const char *iconfile)
- {
- OscarData *od = gc->proto_data;
- aim_session_t *sess = od->sess;
-@@ -8338,8 +8338,8 @@ static void oscar_set_icon(GaimConnectio
- file = g_fopen(iconfile, "rb");
- if (file)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar md5[16];
- int len;
-
-@@ -8347,52 +8347,52 @@ static void oscar_set_icon(GaimConnectio
- len = fread(buf, 1, st.st_size, file);
- fclose(file);
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, buf, len);
-- gaim_cipher_context_digest(context, 16, md5, NULL);
-- gaim_cipher_context_destroy(context);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, buf, len);
-+ gaim2_cipher_context_digest(context, 16, md5, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- aim_ssi_seticon(sess, md5, 16);
- } else
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't open buddy icon file!\n");
- g_free(buf);
- } else
-- gaim_debug_error("oscar",
-+ gaim2_debug_error("oscar",
- "Can't stat buddy icon file!\n");
- }
-
-
--static GList *oscar_actions(GaimPlugin *plugin, gpointer context)
-+static GList *oscar_actions(Gaim2Plugin *plugin, gpointer context)
- {
-- GaimConnection *gc = (GaimConnection *) context;
-+ Gaim2Connection *gc = (Gaim2Connection *) context;
- OscarData *od = gc->proto_data;
- GList *m = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- act = gaim_plugin_action_new(_("Set User Info..."),
-+ act = gaim2_plugin_action_new(_("Set User Info..."),
- oscar_show_set_info);
- m = g_list_append(m, act);
-
- if (od->icq)
- {
-- act = gaim_plugin_action_new(_("Set User Info (URL)..."),
-+ act = gaim2_plugin_action_new(_("Set User Info (URL)..."),
- oscar_show_set_info_icqurl);
- m = g_list_append(m, act);
- }
-
-- act = gaim_plugin_action_new(_("Change Password..."),
-+ act = gaim2_plugin_action_new(_("Change Password..."),
- oscar_change_pass);
- m = g_list_append(m, act);
-
- if (od->sess->authinfo->chpassurl != NULL)
- {
-- act = gaim_plugin_action_new(_("Change Password (URL)"),
-+ act = gaim2_plugin_action_new(_("Change Password (URL)"),
- oscar_show_chpassurl);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Configure IM Forwarding (URL)"),
-+ act = gaim2_plugin_action_new(_("Configure IM Forwarding (URL)"),
- oscar_show_imforwardingurl);
- m = g_list_append(m, act);
- }
-@@ -8402,44 +8402,44 @@ static GList *oscar_actions(GaimPlugin *
- if (od->icq)
- {
- /* ICQ actions */
-- act = gaim_plugin_action_new(_("Set Privacy Options..."),
-+ act = gaim2_plugin_action_new(_("Set Privacy Options..."),
- oscar_show_icq_privacy_opts);
- m = g_list_append(m, act);
- }
- else
- {
- /* AIM actions */
-- act = gaim_plugin_action_new(_("Format Screen Name..."),
-+ act = gaim2_plugin_action_new(_("Format Screen Name..."),
- oscar_show_format_screenname);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Confirm Account"),
-+ act = gaim2_plugin_action_new(_("Confirm Account"),
- oscar_confirm_account);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Display Currently Registered Address"),
-+ act = gaim2_plugin_action_new(_("Display Currently Registered Address"),
- oscar_show_email);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Change Currently Registered Address..."),
-+ act = gaim2_plugin_action_new(_("Change Currently Registered Address..."),
- oscar_show_change_email);
- m = g_list_append(m, act);
- }
-
- m = g_list_append(m, NULL);
-
-- act = gaim_plugin_action_new(_("Show Buddies Awaiting Authorization"),
-+ act = gaim2_plugin_action_new(_("Show Buddies Awaiting Authorization"),
- oscar_show_awaitingauth);
- m = g_list_append(m, act);
-
- m = g_list_append(m, NULL);
-
-- act = gaim_plugin_action_new(_("Search for Buddy by Email..."),
-+ act = gaim2_plugin_action_new(_("Search for Buddy by Email..."),
- oscar_show_find_email);
- m = g_list_append(m, act);
-
- #if 0
-- act = gaim_plugin_action_new(_("Search for Buddy by Information"),
-+ act = gaim2_plugin_action_new(_("Search for Buddy by Information"),
- show_find_info);
- m = g_list_append(m, act);
- #endif
-@@ -8447,7 +8447,7 @@ static GList *oscar_actions(GaimPlugin *
- return m;
- }
-
--static void oscar_change_passwd(GaimConnection *gc, const char *old, const char *new)
-+static void oscar_change_passwd(Gaim2Connection *gc, const char *old, const char *new)
- {
- OscarData *od = gc->proto_data;
-
-@@ -8466,7 +8466,7 @@ static void oscar_change_passwd(GaimConn
- }
- }
-
--static void oscar_convo_closed(GaimConnection *gc, const char *who)
-+static void oscar_convo_closed(Gaim2Connection *gc, const char *who)
- {
- OscarData *od = gc->proto_data;
- struct oscar_direct_im *dim = oscar_direct_im_find(od, who);
-@@ -8478,9 +8478,9 @@ static void oscar_convo_closed(GaimConne
- }
-
- static void
--recent_buddies_cb(const char *name, GaimPrefType type, gpointer value, gpointer data)
-+recent_buddies_cb(const char *name, Gaim2PrefType type, gpointer value, gpointer data)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- OscarData *od = gc->proto_data;
- aim_session_t *sess = od->sess;
- fu32_t presence;
-@@ -8496,35 +8496,35 @@ recent_buddies_cb(const char *name, Gaim
- }
- }
-
--static GaimPluginPrefFrame *
--get_plugin_pref_frame(GaimPlugin *plugin)
-+static Gaim2PluginPrefFrame *
-+get_plugin_pref_frame(Gaim2Plugin *plugin)
- {
-- GaimPluginPrefFrame *frame;
-- GaimPluginPref *ppref;
-+ Gaim2PluginPrefFrame *frame;
-+ Gaim2PluginPref *ppref;
-
-- frame = gaim_plugin_pref_frame_new();
-+ frame = gaim2_plugin_pref_frame_new();
-
- #ifdef USE_PRPL_PREFERENCES
-- ppref = gaim_plugin_pref_new_with_name_and_label("/plugins/prpl/oscar/recent_buddies", _("Use recent buddies group"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_name_and_label("/plugins/prpl/oscar/recent_buddies", _("Use recent buddies group"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label("/plugins/prpl/oscar/show_idle", _("Show how long you have been idle"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_name_and_label("/plugins/prpl/oscar/show_idle", _("Show how long you have been idle"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
- #endif
-
-- ppref = gaim_plugin_pref_new_with_label(_("File Transfers"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ ppref = gaim2_plugin_pref_new_with_label(_("File Transfers"));
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
-- ppref = gaim_plugin_pref_new_with_name_and_label(
-+ ppref = gaim2_plugin_pref_new_with_name_and_label(
- "/plugins/prpl/oscar/use_rv_proxy",
- _("Use AIM/ICQ proxy server (Slower/More Secure/Usually Works)"));
-- gaim_plugin_pref_frame_add(frame, ppref);
-+ gaim2_plugin_pref_frame_add(frame, ppref);
-
- return frame;
- }
-
- static const char *
--oscar_normalize(const GaimAccount *account, const char *str)
-+oscar_normalize(const Gaim2Account *account, const char *str)
- {
- static char buf[BUF_LEN];
- char *tmp1, *tmp2;
-@@ -8550,20 +8550,20 @@ oscar_normalize(const GaimAccount *accou
- return buf;
- }
-
--static gboolean oscar_offline_message(const GaimBuddy *buddy)
-+static gboolean oscar_offline_message(const Gaim2Buddy *buddy)
- {
- OscarData *od;
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-
-- account = gaim_buddy_get_account(buddy);
-- gc = gaim_account_get_connection(account);
-+ account = gaim2_buddy_get_account(buddy);
-+ gc = gaim2_account_get_connection(account);
- od = (OscarData *)gc->proto_data;
-
-- return (od->icq && aim_sn_is_icq(gaim_account_get_username(account)));
-+ return (od->icq && aim_sn_is_icq(gaim2_account_get_username(account)));
- }
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_MAIL_CHECK | OPT_PROTO_IM_IMAGE,
- NULL, /* user_splits */
-@@ -8629,13 +8629,13 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginUiInfo prefs_info = {
-+static Gaim2PluginUiInfo prefs_info = {
- get_plugin_pref_frame,
- 0, /* page_num (Reserved) */
- NULL /* frame (Reserved) */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -8667,24 +8667,24 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_string_new(_("Auth host"), "server", OSCAR_DEFAULT_LOGIN_SERVER);
-+ option = gaim2_account_option_string_new(_("Auth host"), "server", OSCAR_DEFAULT_LOGIN_SERVER);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_int_new(_("Auth port"), "port", OSCAR_DEFAULT_LOGIN_PORT);
-+ option = gaim2_account_option_int_new(_("Auth port"), "port", OSCAR_DEFAULT_LOGIN_PORT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Encoding"), "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
-+ option = gaim2_account_option_string_new(_("Encoding"), "encoding", OSCAR_DEFAULT_CUSTOM_ENCODING);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
- /* Preferences */
-- gaim_prefs_add_none("/plugins/prpl/oscar");
-- gaim_prefs_add_bool("/plugins/prpl/oscar/recent_buddies", FALSE);
-- gaim_prefs_add_bool("/plugins/prpl/oscar/show_idle", FALSE);
-- gaim_prefs_add_bool("/plugins/prpl/oscar/use_rv_proxy", FALSE);
-+ gaim2_prefs_add_none("/plugins/prpl/oscar");
-+ gaim2_prefs_add_bool("/plugins/prpl/oscar/recent_buddies", FALSE);
-+ gaim2_prefs_add_bool("/plugins/prpl/oscar/show_idle", FALSE);
-+ gaim2_prefs_add_bool("/plugins/prpl/oscar/use_rv_proxy", FALSE);
- }
-
- GAIM_INIT_PLUGIN(oscar, init_plugin, info);
-diff -prNu ./src/protocols/oscar/rxhandlers.c ./src/protocols/oscar/rxhandlers.c
---- ./src/protocols/oscar/rxhandlers.c 2005-12-08 22:00:36.000000000 +0100
-+++ ./src/protocols/oscar/rxhandlers.c 2006-01-05 15:11:06.000000000 +0100
-@@ -68,7 +68,7 @@ faim_internal int aim__registermodule(ai
- mod->next = (aim_module_t *)sess->modlistv;
- sess->modlistv = mod;
-
-- gaim_debug_misc("oscar", "registered module %s (family 0x%04x, version = 0x%04x, tool 0x%04x, tool version 0x%04x)\n", mod->name, mod->family, mod->version, mod->toolid, mod->toolversion);
-+ gaim2_debug_misc("oscar", "registered module %s (family 0x%04x, version = 0x%04x, tool 0x%04x, tool version 0x%04x)\n", mod->name, mod->family, mod->version, mod->toolid, mod->toolversion);
-
- return 0;
- }
-@@ -376,15 +376,15 @@ static int bleck(aim_session_t *sess, ai
- subtype = aimbs_get16(&frame->data);
-
- if ((family < maxf) && (subtype+1 < maxs) && (literals[family][subtype] != NULL))
-- gaim_debug_misc("oscar", "bleck: channel %s: null handler for %04x/%04x (%s)\n", channels[frame->hdr.flap.channel], family, subtype, literals[family][subtype+1]);
-+ gaim2_debug_misc("oscar", "bleck: channel %s: null handler for %04x/%04x (%s)\n", channels[frame->hdr.flap.channel], family, subtype, literals[family][subtype+1]);
- else
-- gaim_debug_misc("oscar", "bleck: channel %s: null handler for %04x/%04x (no literal)\n", channels[frame->hdr.flap.channel], family, subtype);
-+ gaim2_debug_misc("oscar", "bleck: channel %s: null handler for %04x/%04x (no literal)\n", channels[frame->hdr.flap.channel], family, subtype);
- } else {
-
- if (frame->hdr.flap.channel <= maxchannels)
-- gaim_debug_misc("oscar", "bleck: channel %s (0x%02x)\n", channels[frame->hdr.flap.channel], frame->hdr.flap.channel);
-+ gaim2_debug_misc("oscar", "bleck: channel %s (0x%02x)\n", channels[frame->hdr.flap.channel], frame->hdr.flap.channel);
- else
-- gaim_debug_misc("oscar", "bleck: unknown channel 0x%02x\n", frame->hdr.flap.channel);
-+ gaim2_debug_misc("oscar", "bleck: unknown channel 0x%02x\n", frame->hdr.flap.channel);
-
- }
-
-@@ -398,7 +398,7 @@ faim_export int aim_conn_addhandler(aim_
- if (!conn)
- return -1;
-
-- gaim_debug_misc("oscar", "aim_conn_addhandler: adding for %04x/%04x\n", family, type);
-+ gaim2_debug_misc("oscar", "aim_conn_addhandler: adding for %04x/%04x\n", family, type);
-
- if (!(newcb = (struct aim_rxcblist_s *)calloc(1, sizeof(struct aim_rxcblist_s))))
- return -1;
-@@ -448,7 +448,7 @@ faim_internal aim_rxcallback_t aim_callh
- if (!conn)
- return NULL;
-
-- /* gaim_debug_misc("oscar", "aim_callhandler: calling for %04x/%04x\n", family, type); */
-+ /* gaim2_debug_misc("oscar", "aim_callhandler: calling for %04x/%04x\n", family, type); */
-
- for (cur = (struct aim_rxcblist_s *)conn->handlerlist; cur; cur = cur->next) {
- if ((cur->family == family) && (cur->type == type))
-@@ -456,11 +456,11 @@ faim_internal aim_rxcallback_t aim_callh
- }
-
- if (type == AIM_CB_SPECIAL_DEFAULT) {
-- /* gaim_debug_misc("oscar", "aim_callhandler: no default handler for family 0x%04x\n", family); */
-+ /* gaim2_debug_misc("oscar", "aim_callhandler: no default handler for family 0x%04x\n", family); */
- return NULL; /* prevent infinite recursion */
- }
-
-- /* gaim_debug_misc("oscar", "aim_callhandler: no handler for 0x%04x/0x%04x\n", family, type); */
-+ /* gaim2_debug_misc("oscar", "aim_callhandler: no handler for 0x%04x/0x%04x\n", family, type); */
-
- return aim_callhandler(sess, conn, family, AIM_CB_SPECIAL_DEFAULT);
- }
-@@ -541,7 +541,7 @@ faim_export void aim_rxdispatch(aim_sess
-
- } else if (cur->conn->type == AIM_CONN_TYPE_LISTENER) {
- /* not possible */
-- gaim_debug_misc("oscar", "rxdispatch called on LISTENER connection!\n");
-+ gaim2_debug_misc("oscar", "rxdispatch called on LISTENER connection!\n");
- cur->handled = 1;
- continue;
- }
-@@ -568,16 +568,16 @@ faim_internal int aim_parse_unknown(aim_
- {
- int i;
-
-- gaim_debug_misc("oscar", "\nRecieved unknown packet:");
-+ gaim2_debug_misc("oscar", "\nRecieved unknown packet:");
-
- for (i = 0; aim_bstream_empty(&frame->data); i++) {
- if ((i % 8) == 0)
-- gaim_debug_misc("oscar", "\n\t");
-+ gaim2_debug_misc("oscar", "\n\t");
-
-- gaim_debug_misc("oscar", "0x%2x ", aimbs_get8(&frame->data));
-+ gaim2_debug_misc("oscar", "0x%2x ", aimbs_get8(&frame->data));
- }
-
-- gaim_debug_misc("oscar", "\n\n");
-+ gaim2_debug_misc("oscar", "\n\n");
-
- return 1;
- }
-diff -prNu ./src/protocols/oscar/rxqueue.c ./src/protocols/oscar/rxqueue.c
---- ./src/protocols/oscar/rxqueue.c 2005-12-09 04:37:24.000000000 +0100
-+++ ./src/protocols/oscar/rxqueue.c 2006-01-05 15:11:06.000000000 +0100
-@@ -113,7 +113,7 @@ static int aim_get_command_flap(aim_sess
- * or we break. We must handle it just in case.
- */
- if (aimbs_get8(&hdr) != 0x2a) {
-- gaim_debug_misc("oscar", "Invalid FLAP frame received on FLAP connection!");
-+ gaim2_debug_misc("oscar", "Invalid FLAP frame received on FLAP connection!");
- aim_conn_close(conn);
- return -1;
- }
-@@ -190,7 +190,7 @@ faim_export int aim_get_command(aim_sess
- if (conn->type == AIM_CONN_TYPE_RENDEZVOUS)
- payloadlen = aim_get_command_rendezvous(sess, conn, fr);
- else if (conn->type == AIM_CONN_TYPE_LISTENER) {
-- gaim_debug_misc("oscar", "AIM_CONN_TYPE_LISTENER on fd %d\n", conn->fd);
-+ gaim2_debug_misc("oscar", "AIM_CONN_TYPE_LISTENER on fd %d\n", conn->fd);
- free(fr);
- return -1;
- } else
-diff -prNu ./src/protocols/oscar/search.c ./src/protocols/oscar/search.c
---- ./src/protocols/oscar/search.c 2005-08-13 08:43:45.000000000 +0200
-+++ ./src/protocols/oscar/search.c 2006-01-05 15:11:06.000000000 +0100
-@@ -21,7 +21,7 @@ static int error(aim_session_t *sess, ai
-
- /* XXX the modules interface should have already retrieved this for us */
- if (!(snac2 = aim_remsnac(sess, snac->id))) {
-- gaim_debug_misc("oscar", "search error: couldn't get a snac for 0x%08lx\n", snac->id);
-+ gaim2_debug_misc("oscar", "search error: couldn't get a snac for 0x%08lx\n", snac->id);
- return 0;
- }
-
-diff -prNu ./src/protocols/oscar/service.c ./src/protocols/oscar/service.c
---- ./src/protocols/oscar/service.c 2005-12-22 03:20:39.000000000 +0100
-+++ ./src/protocols/oscar/service.c 2006-01-05 15:11:06.000000000 +0100
-@@ -39,7 +39,7 @@ faim_export int aim_clientready(aim_sess
- aimbs_put16(&fr->data, mod->toolid);
- aimbs_put16(&fr->data, mod->toolversion);
- } else
-- gaim_debug_misc("oscar", "aim_clientready: server supports group 0x%04x but we don't!\n", sg->group);
-+ gaim2_debug_misc("oscar", "aim_clientready: server supports group 0x%04x but we don't!\n", sg->group);
- }
-
- aim_tx_enqueue(sess, fr);
-@@ -335,7 +335,7 @@ static int rateresp(aim_session_t *sess,
- if (mod->version >= 3)
- aimbs_getrawbuf(bs, rc.unknown, sizeof(rc.unknown));
-
-- gaim_debug_misc("oscar", "--- Adding rate class %d to connection type %d: window size = %ld, clear = %ld, alert = %ld, limit = %ld, disconnect = %ld, current = %ld, max = %ld\n", rx->conn->type, rc.classid, rc.windowsize, rc.clear, rc.alert, rc.limit, rc.disconnect, rc.current, rc.max);
-+ gaim2_debug_misc("oscar", "--- Adding rate class %d to connection type %d: window size = %ld, clear = %ld, alert = %ld, limit = %ld, disconnect = %ld, current = %ld, max = %ld\n", rx->conn->type, rc.classid, rc.windowsize, rc.clear, rc.alert, rc.limit, rc.disconnect, rc.current, rc.max);
-
- rc_addclass(&ins->rates, &rc);
- }
-@@ -628,7 +628,7 @@ static int migrate(aim_session_t *sess,
-
- group = aimbs_get16(bs);
-
-- gaim_debug_misc("oscar", "bifurcated migration unsupported -- group 0x%04x\n", group);
-+ gaim2_debug_misc("oscar", "bifurcated migration unsupported -- group 0x%04x\n", group);
- }
-
- tl = aim_tlvlist_read(bs);
-@@ -754,7 +754,7 @@ faim_internal int aim_setversions(aim_se
- aimbs_put16(&fr->data, mod->family);
- aimbs_put16(&fr->data, mod->version);
- } else
-- gaim_debug_misc("oscar", "aim_setversions: server supports group 0x%04x but we don't!\n", sg->group);
-+ gaim2_debug_misc("oscar", "aim_setversions: server supports group 0x%04x but we don't!\n", sg->group);
- }
-
- aim_tx_enqueue(sess, fr);
-@@ -833,7 +833,7 @@ faim_export int aim_setextstatus(aim_ses
- * Subtype 0x001e - Extended Status.
- *
- * Sets your "available" message. This is currently only supported by iChat
-- * and Gaim.
-+ * and Gaim2.
- *
- * These are the same TLVs seen in user info. You can
- * also set 0x0008 and 0x000c.
-@@ -934,7 +934,7 @@ static int memrequest(aim_session_t *ses
-
- modname = aim_tlv_getstr(list, 0x0001, 1);
-
-- gaim_debug_info("oscar", "Got memory request for data at 0x%08lx (%d bytes) of requested %s\n", offset, len, modname ? modname : "aim.exe");
-+ gaim2_debug_info("oscar", "Got memory request for data at 0x%08lx (%d bytes) of requested %s\n", offset, len, modname ? modname : "aim.exe");
-
- if ((userfunc = aim_callhandler(sess, rx->conn, snac->family, snac->subtype)))
- ret = userfunc(sess, rx, offset, len, modname);
-@@ -967,22 +967,22 @@ faim_export int aim_sendmemblock(aim_ses
- aimbs_putraw(&fr->data, buf, 0x10);
-
- } else if (buf && (len > 0)) { /* use input buffer */
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar digest[16];
-
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
-
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, buf, len);
-- gaim_cipher_context_digest(context, 16, digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, buf, len);
-+ gaim2_cipher_context_digest(context, 16, digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- aimbs_putraw(&fr->data, digest, 0x10);
-
- } else if (len == 0) { /* no length, just hash NULL (buf is optional) */
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar digest[16];
- fu8_t nil = '\0';
-
-@@ -990,12 +990,12 @@ faim_export int aim_sendmemblock(aim_ses
- * I'm not sure if we really need the empty append with the
- * new MD5 functions, so I'll leave it in, just in case.
- */
-- cipher = gaim_ciphers_find_cipher("md5");
-+ cipher = gaim2_ciphers_find_cipher("md5");
-
-- context = gaim_cipher_context_new(cipher, NULL);
-- gaim_cipher_context_append(context, &nil, 0);
-- gaim_cipher_context_digest(context, 16, digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ context = gaim2_cipher_context_new(cipher, NULL);
-+ gaim2_cipher_context_append(context, &nil, 0);
-+ gaim2_cipher_context_digest(context, 16, digest, NULL);
-+ gaim2_cipher_context_destroy(context);
-
- aimbs_putraw(&fr->data, digest, 0x10);
-
-@@ -1030,7 +1030,7 @@ faim_export int aim_sendmemblock(aim_ses
- aimbs_put32(&fr->data, 0xecf8427e);
-
- } else
-- gaim_debug_warning("oscar", "sendmemblock: unknown hash request\n");
-+ gaim2_debug_warning("oscar", "sendmemblock: unknown hash request\n");
-
- }
-
-diff -prNu ./src/protocols/oscar/txqueue.c ./src/protocols/oscar/txqueue.c
---- ./src/protocols/oscar/txqueue.c 2005-12-09 04:42:47.000000000 +0100
-+++ ./src/protocols/oscar/txqueue.c 2006-01-05 15:11:06.000000000 +0100
-@@ -31,19 +31,19 @@ faim_internal aim_frame_t *aim_tx_new(ai
- aim_frame_t *fr;
-
- if (!sess || !conn) {
-- gaim_debug_misc("oscar", "aim_tx_new: No session or no connection specified!\n");
-+ gaim2_debug_misc("oscar", "aim_tx_new: No session or no connection specified!\n");
- return NULL;
- }
-
- /* For sanity... */
- if ((conn->type == AIM_CONN_TYPE_RENDEZVOUS) || (conn->type == AIM_CONN_TYPE_LISTENER)) {
- if (framing != AIM_FRAMETYPE_OFT) {
-- gaim_debug_misc("oscar", "aim_tx_new: attempted to allocate inappropriate frame type for rendezvous connection\n");
-+ gaim2_debug_misc("oscar", "aim_tx_new: attempted to allocate inappropriate frame type for rendezvous connection\n");
- return NULL;
- }
- } else {
- if (framing != AIM_FRAMETYPE_FLAP) {
-- gaim_debug_misc("oscar", "aim_tx_new: attempted to allocate inappropriate frame type for FLAP connection\n");
-+ gaim2_debug_misc("oscar", "aim_tx_new: attempted to allocate inappropriate frame type for FLAP connection\n");
- return NULL;
- }
- }
-@@ -58,7 +58,7 @@ faim_internal aim_frame_t *aim_tx_new(ai
- else if (fr->hdrtype == AIM_FRAMETYPE_OFT)
- fr->hdr.rend.type = chan;
- else
-- gaim_debug_misc("oscar", "tx_new: unknown framing\n");
-+ gaim2_debug_misc("oscar", "tx_new: unknown framing\n");
-
- if (datalen > 0) {
- fu8_t *data;
-@@ -105,7 +105,7 @@ static int aim_tx_enqueue__queuebased(ai
- {
-
- if (!fr->conn) {
-- gaim_debug_warning("oscar", "aim_tx_enqueue: enqueueing packet with no connecetion\n");
-+ gaim2_debug_warning("oscar", "aim_tx_enqueue: enqueueing packet with no connecetion\n");
- fr->conn = aim_getconn_type(sess, AIM_CONN_TYPE_BOS);
- }
-
-@@ -142,7 +142,7 @@ static int aim_tx_enqueue__immediate(aim
- int ret;
-
- if (!fr->conn) {
-- gaim_debug_error("oscar", "aim_tx_enqueue: packet has no connection\n");
-+ gaim2_debug_error("oscar", "aim_tx_enqueue: packet has no connection\n");
- aim_frame_destroy(fr);
- return 0;
- }
-@@ -227,7 +227,7 @@ faim_internal int aim_bstream_send(aim_b
- if (count) {
- /*
- * I need to rewrite this. "Updating the UI" doesn't make sense. The program is
-- * blocked and the UI can't redraw. We're blocking all of Gaim. We need to set
-+ * blocked and the UI can't redraw. We're blocking all of Gaim2. We need to set
- * up an actual txqueue and a GAIM_INPUT_WRITE callback and only write when we
- * can. Why is this file called txqueue anyway? Lets rename it to txblock.
- */
-diff -prNu ./src/protocols/sametime/Makefile.am ./src/protocols/sametime/Makefile.am
---- ./src/protocols/sametime/Makefile.am 2005-12-16 05:08:04.000000000 +0100
-+++ ./src/protocols/sametime/Makefile.am 2006-01-05 13:04:50.000000000 +0100
-@@ -2,7 +2,7 @@
- EXTRA_DIST = Makefile.mingw
-
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
-
- noinst_HEADERS = sametime.h
-diff -prNu ./src/protocols/sametime/meanwhile/channel.lo ./src/protocols/sametime/meanwhile/channel.lo
---- ./src/protocols/sametime/meanwhile/channel.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/channel.lo 2005-11-19 00:13:42.000000000 +0100
-@@ -0,0 +1,12 @@
-+# channel.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/channel.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/cipher.lo ./src/protocols/sametime/meanwhile/cipher.lo
---- ./src/protocols/sametime/meanwhile/cipher.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/cipher.lo 2005-11-19 00:13:42.000000000 +0100
-@@ -0,0 +1,12 @@
-+# cipher.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/cipher.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/common.lo ./src/protocols/sametime/meanwhile/common.lo
---- ./src/protocols/sametime/meanwhile/common.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/common.lo 2005-11-19 00:13:43.000000000 +0100
-@@ -0,0 +1,12 @@
-+# common.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/common.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/.cvsignore ./src/protocols/sametime/meanwhile/.cvsignore
---- ./src/protocols/sametime/meanwhile/.cvsignore 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/.cvsignore 2006-01-05 14:24:29.000000000 +0100
-@@ -0,0 +1,10 @@
-+*.a
-+.deps
-+.libs
-+*.la
-+*.lo
-+*.o
-+*.dll
-+*.lib
-+Makefile
-+Makefile.in
-diff -prNu ./src/protocols/sametime/meanwhile/error.lo ./src/protocols/sametime/meanwhile/error.lo
---- ./src/protocols/sametime/meanwhile/error.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/error.lo 2005-11-19 00:13:44.000000000 +0100
-@@ -0,0 +1,12 @@
-+# error.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/error.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/libmeanwhile.la ./src/protocols/sametime/meanwhile/libmeanwhile.la
---- ./src/protocols/sametime/meanwhile/libmeanwhile.la 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/libmeanwhile.la 2005-11-19 00:13:51.000000000 +0100
-@@ -0,0 +1,35 @@
-+# libmeanwhile.la - a libtool library file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# The name that we can dlopen(3).
-+dlname=''
-+
-+# Names of this library.
-+library_names=''
-+
-+# The name of the static archive.
-+old_library='libmeanwhile.a'
-+
-+# Libraries that this one depends upon.
-+dependency_libs=' /usr/lib/libglib-2.0.la /usr/lib/libgmp.la -lnsl -lresolv'
-+
-+# Version information for libmeanwhile.
-+current=6
-+age=3
-+revision=3
-+
-+# Is this an already installed library?
-+installed=no
-+
-+# Should we warn about portability when linking against -modules?
-+shouldnotlink=no
-+
-+# Files to dlopen/dlpreopen
-+dlopen=''
-+dlpreopen=''
-+
-+# Directory that this library needs to be installed in:
-+libdir=''
-diff -prNu ./src/protocols/sametime/meanwhile/message.lo ./src/protocols/sametime/meanwhile/message.lo
---- ./src/protocols/sametime/meanwhile/message.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/message.lo 2005-11-19 00:13:44.000000000 +0100
-@@ -0,0 +1,12 @@
-+# message.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/message.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/mw_debug.lo ./src/protocols/sametime/meanwhile/mw_debug.lo
---- ./src/protocols/sametime/meanwhile/mw_debug.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/mw_debug.lo 2005-11-19 00:13:44.000000000 +0100
-@@ -0,0 +1,12 @@
-+# mw_debug.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/mw_debug.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/mw_util.lo ./src/protocols/sametime/meanwhile/mw_util.lo
---- ./src/protocols/sametime/meanwhile/mw_util.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/mw_util.lo 2005-11-19 00:13:45.000000000 +0100
-@@ -0,0 +1,12 @@
-+# mw_util.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/mw_util.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/service.lo ./src/protocols/sametime/meanwhile/service.lo
---- ./src/protocols/sametime/meanwhile/service.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/service.lo 2005-11-19 00:13:45.000000000 +0100
-@@ -0,0 +1,12 @@
-+# service.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/service.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/session.lo ./src/protocols/sametime/meanwhile/session.lo
---- ./src/protocols/sametime/meanwhile/session.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/session.lo 2005-11-19 00:13:46.000000000 +0100
-@@ -0,0 +1,12 @@
-+# session.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/session.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_aware.lo ./src/protocols/sametime/meanwhile/srvc_aware.lo
---- ./src/protocols/sametime/meanwhile/srvc_aware.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_aware.lo 2005-11-19 00:13:47.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_aware.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_aware.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_conf.lo ./src/protocols/sametime/meanwhile/srvc_conf.lo
---- ./src/protocols/sametime/meanwhile/srvc_conf.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_conf.lo 2005-11-19 00:13:47.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_conf.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_conf.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_ft.lo ./src/protocols/sametime/meanwhile/srvc_ft.lo
---- ./src/protocols/sametime/meanwhile/srvc_ft.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_ft.lo 2005-11-19 00:13:48.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_ft.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_ft.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_im.lo ./src/protocols/sametime/meanwhile/srvc_im.lo
---- ./src/protocols/sametime/meanwhile/srvc_im.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_im.lo 2005-11-19 00:13:48.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_im.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_im.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_place.lo ./src/protocols/sametime/meanwhile/srvc_place.lo
---- ./src/protocols/sametime/meanwhile/srvc_place.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_place.lo 2005-11-19 00:13:49.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_place.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_place.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_resolve.lo ./src/protocols/sametime/meanwhile/srvc_resolve.lo
---- ./src/protocols/sametime/meanwhile/srvc_resolve.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_resolve.lo 2005-11-19 00:13:50.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_resolve.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_resolve.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/srvc_store.lo ./src/protocols/sametime/meanwhile/srvc_store.lo
---- ./src/protocols/sametime/meanwhile/srvc_store.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/srvc_store.lo 2005-11-19 00:13:49.000000000 +0100
-@@ -0,0 +1,12 @@
-+# srvc_store.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/srvc_store.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/meanwhile/st_list.lo ./src/protocols/sametime/meanwhile/st_list.lo
---- ./src/protocols/sametime/meanwhile/st_list.lo 1970-01-01 01:00:00.000000000 +0100
-+++ ./src/protocols/sametime/meanwhile/st_list.lo 2005-11-19 00:13:50.000000000 +0100
-@@ -0,0 +1,12 @@
-+# st_list.lo - a libtool object file
-+# Generated by ltmain.sh - GNU libtool 1.5.20 (1.1220.2.287 2005/08/31 18:54:15)
-+#
-+# Please DO NOT delete this file!
-+# It is necessary for linking the library.
-+
-+# Name of the PIC object.
-+pic_object='.libs/st_list.o'
-+
-+# Name of the non-PIC object.
-+non_pic_object=none
-+
-diff -prNu ./src/protocols/sametime/sametime.c ./src/protocols/sametime/sametime.c
---- ./src/protocols/sametime/sametime.c 2005-12-25 20:09:24.000000000 +0100
-+++ ./src/protocols/sametime/sametime.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
-
- /*
-- Meanwhile Protocol Plugin for Gaim
-- Adds Lotus Sametime support to Gaim using the Meanwhile library
-+ Meanwhile Protocol Plugin for Gaim2
-+ Adds Lotus Sametime support to Gaim2 using the Meanwhile library
-
- Copyright (C) 2004 Christopher (siege) O'Brien <siege@preoccupied.net>
-
-@@ -31,9 +31,9 @@
- #include <glib/ghash.h>
- #include <glib/glist.h>
-
--/* gaim includes */
-+/* gaim2 includes */
- #include <internal.h>
--#include <gaim.h>
-+#include <gaim2.h>
- #include <config.h>
-
- #include <account.h>
-@@ -138,7 +138,7 @@
- #define mwSession_NO_SECRET "meanwhile.no_secret"
-
-
--/* keys to get/set gaim plugin information */
-+/* keys to get/set gaim2 plugin information */
- #define MW_KEY_HOST "server"
- #define MW_KEY_PORT "port"
- #define MW_KEY_ACTIVE_MSG "active_msg"
-@@ -170,7 +170,7 @@ enum blist_choice {
-
-
- /* testing for the above */
--#define BLIST_PREF_IS(n) (gaim_prefs_get_int(MW_PRPL_OPT_BLIST_ACTION)==(n))
-+#define BLIST_PREF_IS(n) (gaim2_prefs_get_int(MW_PRPL_OPT_BLIST_ACTION)==(n))
- #define BLIST_PREF_IS_LOCAL() BLIST_PREF_IS(blist_choice_LOCAL)
- #define BLIST_PREF_IS_MERGE() BLIST_PREF_IS(blist_choice_MERGE)
- #define BLIST_PREF_IS_STORE() BLIST_PREF_IS(blist_choice_STORE)
-@@ -178,10 +178,10 @@ enum blist_choice {
-
-
- /* debugging output */
--#define DEBUG_ERROR(a...) gaim_debug_error(G_LOG_DOMAIN, a)
--#define DEBUG_INFO(a...) gaim_debug_info(G_LOG_DOMAIN, a)
--#define DEBUG_MISC(a...) gaim_debug_misc(G_LOG_DOMAIN, a)
--#define DEBUG_WARN(a...) gaim_debug_warning(G_LOG_DOMAIN, a)
-+#define DEBUG_ERROR(a...) gaim2_debug_error(G_LOG_DOMAIN, a)
-+#define DEBUG_INFO(a...) gaim2_debug_info(G_LOG_DOMAIN, a)
-+#define DEBUG_MISC(a...) gaim2_debug_misc(G_LOG_DOMAIN, a)
-+#define DEBUG_WARN(a...) gaim2_debug_warning(G_LOG_DOMAIN, a)
-
-
- /** ensure non-null strings */
-@@ -203,9 +203,9 @@ static const unsigned char no_secret[] =
- static guint log_handler[2] = { 0, 0 };
-
-
--/** the gaim plugin data.
-+/** the gaim2 plugin data.
- available as gc->proto_data and mwSession_getClientData */
--struct mwGaimPluginData {
-+struct mwGaim2PluginData {
- struct mwSession *session;
-
- struct mwServiceAware *srvc_aware;
-@@ -216,7 +216,7 @@ struct mwGaimPluginData {
- struct mwServiceResolve *srvc_resolve;
- struct mwServiceStorage *srvc_store;
-
-- /** map of GaimGroup:mwAwareList and mwAwareList:GaimGroup */
-+ /** map of Gaim2Group:mwAwareList and mwAwareList:Gaim2Group */
- GHashTable *group_list_map;
-
- /** event id for the buddy list save callback */
-@@ -225,51 +225,51 @@ struct mwGaimPluginData {
- /** socket fd */
- int socket;
-
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- };
-
-
- /* blist and aware functions */
-
--static void blist_export(GaimConnection *gc, struct mwSametimeList *stlist);
-+static void blist_export(Gaim2Connection *gc, struct mwSametimeList *stlist);
-
--static void blist_store(struct mwGaimPluginData *pd);
-+static void blist_store(struct mwGaim2PluginData *pd);
-
--static void blist_schedule(struct mwGaimPluginData *pd);
-+static void blist_schedule(struct mwGaim2PluginData *pd);
-
--static void blist_merge(GaimConnection *gc, struct mwSametimeList *stlist);
-+static void blist_merge(Gaim2Connection *gc, struct mwSametimeList *stlist);
-
--static void blist_sync(GaimConnection *gc, struct mwSametimeList *stlist);
-+static void blist_sync(Gaim2Connection *gc, struct mwSametimeList *stlist);
-
--static gboolean buddy_is_external(GaimBuddy *b);
-+static gboolean buddy_is_external(Gaim2Buddy *b);
-
--static void buddy_add(struct mwGaimPluginData *pd, GaimBuddy *buddy);
-+static void buddy_add(struct mwGaim2PluginData *pd, Gaim2Buddy *buddy);
-
--static GaimBuddy *
--buddy_ensure(GaimConnection *gc, GaimGroup *group,
-+static Gaim2Buddy *
-+buddy_ensure(Gaim2Connection *gc, Gaim2Group *group,
- struct mwSametimeUser *stuser);
-
--static void group_add(struct mwGaimPluginData *pd, GaimGroup *group);
-+static void group_add(struct mwGaim2PluginData *pd, Gaim2Group *group);
-
--static GaimGroup *
--group_ensure(GaimConnection *gc, struct mwSametimeGroup *stgroup);
-+static Gaim2Group *
-+group_ensure(Gaim2Connection *gc, struct mwSametimeGroup *stgroup);
-
- static struct mwAwareList *
--list_ensure(struct mwGaimPluginData *pd, GaimGroup *group);
-+list_ensure(struct mwGaim2PluginData *pd, Gaim2Group *group);
-
-
- /* session functions */
-
- static struct mwSession *
--gc_to_session(GaimConnection *gc);
-+gc_to_session(Gaim2Connection *gc);
-
--static GaimConnection *session_to_gc(struct mwSession *session);
-+static Gaim2Connection *session_to_gc(struct mwSession *session);
-
-
- /* conference functions */
-
- static struct mwConference *
--conf_find_by_id(struct mwGaimPluginData *pd, int id);
-+conf_find_by_id(struct mwGaim2PluginData *pd, int id);
-
-
- /* conversation functions */
-@@ -292,7 +292,7 @@ static void convo_data_free(struct convo
-
- static void convo_features(struct mwConversation *conv);
-
--static GaimConversation *convo_get_gconv(struct mwConversation *conv);
-+static Gaim2Conversation *convo_get_gconv(struct mwConversation *conv);
-
-
- /* name and id */
-@@ -305,15 +305,15 @@ struct named_id {
-
- /* connection functions */
-
--static void connect_cb(gpointer data, gint source, GaimInputCondition cond);
-+static void connect_cb(gpointer data, gint source, Gaim2InputCondition cond);
-
-
- /* ----- session ------ */
-
-
--/** resolves a mwSession from a GaimConnection */
--static struct mwSession *gc_to_session(GaimConnection *gc) {
-- struct mwGaimPluginData *pd;
-+/** resolves a mwSession from a Gaim2Connection */
-+static struct mwSession *gc_to_session(Gaim2Connection *gc) {
-+ struct mwGaim2PluginData *pd;
-
- g_return_val_if_fail(gc != NULL, NULL);
-
-@@ -324,9 +324,9 @@ static struct mwSession *gc_to_session(G
- }
-
-
--/** resolves a GaimConnection from a mwSession */
--static GaimConnection *session_to_gc(struct mwSession *session) {
-- struct mwGaimPluginData *pd;
-+/** resolves a Gaim2Connection from a mwSession */
-+static Gaim2Connection *session_to_gc(struct mwSession *session) {
-+ struct mwGaim2PluginData *pd;
-
- g_return_val_if_fail(session != NULL, NULL);
-
-@@ -339,7 +339,7 @@ static GaimConnection *session_to_gc(str
-
- static int mw_session_io_write(struct mwSession *session,
- const guchar *buf, gsize len) {
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- int ret = 0;
-
- pd = mwSession_getClientData(session);
-@@ -356,7 +356,7 @@ static int mw_session_io_write(struct mw
-
- if(len > 0) {
- DEBUG_ERROR("write returned %i, %i bytes left unwritten\n", ret, len);
-- gaim_connection_error(pd->gc, _("Connection closed (writing)"));
-+ gaim2_connection_error(pd->gc, _("Connection closed (writing)"));
-
- #if 0
- close(pd->socket);
-@@ -371,8 +371,8 @@ static int mw_session_io_write(struct mw
-
-
- static void mw_session_io_close(struct mwSession *session) {
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-
- pd = mwSession_getClientData(session);
- g_return_if_fail(pd != NULL);
-@@ -385,7 +385,7 @@ static void mw_session_io_close(struct m
- }
-
- if(gc->inpa) {
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
- gc->inpa = 0;
- }
- }
-@@ -414,25 +414,25 @@ static void blist_resolve_alias_cb(struc
- match = result->matches->data;
- g_return_if_fail(match != NULL);
-
-- gaim_blist_server_alias_buddy(data, match->name);
-- gaim_blist_node_set_string(data, BUDDY_KEY_NAME, match->name);
-+ gaim2_blist_server_alias_buddy(data, match->name);
-+ gaim2_blist_node_set_string(data, BUDDY_KEY_NAME, match->name);
- }
-
-
- static void mw_aware_list_on_aware(struct mwAwareList *list,
- struct mwAwareSnapshot *aware) {
-
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- time_t idle;
- guint stat;
- const char *id;
- const char *status = MW_STATE_ACTIVE;
-
- gc = mwAwareList_getClientData(list);
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- pd = gc->proto_data;
- idle = aware->status.time;
-@@ -470,22 +470,22 @@ static void mw_aware_list_on_aware(struc
-
- /* NAB group members */
- if(aware->group) {
-- GaimGroup *group;
-- GaimBuddy *buddy;
-- GaimBlistNode *bnode;
-+ Gaim2Group *group;
-+ Gaim2Buddy *buddy;
-+ Gaim2BlistNode *bnode;
-
- group = g_hash_table_lookup(pd->group_list_map, list);
-- buddy = gaim_find_buddy_in_group(acct, id, group);
-- bnode = (GaimBlistNode *) buddy;
-+ buddy = gaim2_find_buddy_in_group(acct, id, group);
-+ bnode = (Gaim2BlistNode *) buddy;
-
- if(! buddy) {
- struct mwServiceResolve *srvc;
- GList *query;
-
-- buddy = gaim_buddy_new(acct, id, NULL);
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-+ buddy = gaim2_buddy_new(acct, id, NULL);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
-
-- bnode = (GaimBlistNode *) buddy;
-+ bnode = (Gaim2BlistNode *) buddy;
-
- srvc = pd->srvc_resolve;
- query = g_list_append(NULL, (char *) id);
-@@ -495,15 +495,15 @@ static void mw_aware_list_on_aware(struc
- g_list_free(query);
- }
-
-- gaim_blist_node_set_int(bnode, BUDDY_KEY_TYPE, mwSametimeUser_NORMAL);
-+ gaim2_blist_node_set_int(bnode, BUDDY_KEY_TYPE, mwSametimeUser_NORMAL);
- }
-
- if(aware->online) {
-- gaim_prpl_got_user_status(acct, id, status, NULL);
-- gaim_prpl_got_user_idle(acct, id, !!idle, idle);
-+ gaim2_prpl_got_user_status(acct, id, status, NULL);
-+ gaim2_prpl_got_user_idle(acct, id, !!idle, idle);
-
- } else {
-- gaim_prpl_got_user_status(acct, id, MW_STATE_OFFLINE, NULL);
-+ gaim2_prpl_got_user_status(acct, id, MW_STATE_OFFLINE, NULL);
- }
- }
-
-@@ -531,7 +531,7 @@ static struct mwAwareListHandler mw_awar
- /** Ensures that an Aware List is associated with the given group, and
- returns that list. */
- static struct mwAwareList *
--list_ensure(struct mwGaimPluginData *pd, GaimGroup *group) {
-+list_ensure(struct mwGaim2PluginData *pd, Gaim2Group *group) {
-
- struct mwAwareList *list;
-
-@@ -559,25 +559,25 @@ list_ensure(struct mwGaimPluginData *pd,
- }
-
-
--static void blist_export(GaimConnection *gc, struct mwSametimeList *stlist) {
-+static void blist_export(Gaim2Connection *gc, struct mwSametimeList *stlist) {
- /* - find the account for this connection
- - iterate through the buddy list
- - add each buddy matching this account to the stlist
- */
-
-- GaimAccount *acct;
-- GaimBuddyList *blist;
-- GaimBlistNode *gn, *cn, *bn;
-- GaimGroup *grp;
-- GaimBuddy *bdy;
-+ Gaim2Account *acct;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gn, *cn, *bn;
-+ Gaim2Group *grp;
-+ Gaim2Buddy *bdy;
-
- struct mwSametimeGroup *stg = NULL;
- struct mwIdBlock idb = { NULL, NULL };
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_if_fail(acct != NULL);
-
-- blist = gaim_get_blist();
-+ blist = gaim2_get_blist();
- g_return_if_fail(blist != NULL);
-
- for(gn = blist->root; gn; gn = gn->next) {
-@@ -587,28 +587,28 @@ static void blist_export(GaimConnection
- gboolean gopen;
-
- if(! GAIM_BLIST_NODE_IS_GROUP(gn)) continue;
-- grp = (GaimGroup *) gn;
-+ grp = (Gaim2Group *) gn;
-
- /* the group's type (normal or dynamic) */
-- gtype = gaim_blist_node_get_int(gn, GROUP_KEY_TYPE);
-+ gtype = gaim2_blist_node_get_int(gn, GROUP_KEY_TYPE);
- if(! gtype) gtype = mwSametimeGroup_NORMAL;
-
- /* if it's a normal group with none of our people in it, skip it */
-- if(gtype == mwSametimeGroup_NORMAL && !gaim_group_on_account(grp, acct))
-+ if(gtype == mwSametimeGroup_NORMAL && !gaim2_group_on_account(grp, acct))
- continue;
-
- /* if the group has an owner and we're not it, skip it */
-- owner = gaim_blist_node_get_string(gn, GROUP_KEY_OWNER);
-- if(owner && strcmp(owner, gaim_account_get_username(acct)))
-+ owner = gaim2_blist_node_get_string(gn, GROUP_KEY_OWNER);
-+ if(owner && strcmp(owner, gaim2_account_get_username(acct)))
- continue;
-
-- /* the group's actual name may be different from the gaim group's
-+ /* the group's actual name may be different from the gaim2 group's
- name. Find whichever is there */
-- gname = gaim_blist_node_get_string(gn, GROUP_KEY_NAME);
-+ gname = gaim2_blist_node_get_string(gn, GROUP_KEY_NAME);
- if(! gname) gname = grp->name;
-
- /* we save this, but never actually honor it */
-- gopen = ! gaim_blist_node_get_bool(gn, GROUP_KEY_COLLAPSED);
-+ gopen = ! gaim2_blist_node_get_bool(gn, GROUP_KEY_COLLAPSED);
-
- stg = mwSametimeGroup_new(stlist, gtype, gname);
- mwSametimeGroup_setAlias(stg, grp->name);
-@@ -626,7 +626,7 @@ static void blist_export(GaimConnection
- if(! GAIM_BLIST_NODE_IS_BUDDY(bn)) continue;
- if(! GAIM_BLIST_NODE_SHOULD_SAVE(bn)) continue;
-
-- bdy = (GaimBuddy *) bn;
-+ bdy = (Gaim2Buddy *) bn;
-
- if(bdy->account == acct) {
- struct mwSametimeUser *stu;
-@@ -634,7 +634,7 @@ static void blist_export(GaimConnection
-
- idb.user = bdy->name;
-
-- utype = gaim_blist_node_get_int(bn, BUDDY_KEY_TYPE);
-+ utype = gaim2_blist_node_get_int(bn, BUDDY_KEY_TYPE);
- if(! utype) utype = mwSametimeUser_NORMAL;
-
- stu = mwSametimeUser_new(stg, utype, &idb);
-@@ -647,13 +647,13 @@ static void blist_export(GaimConnection
- }
-
-
--static void blist_store(struct mwGaimPluginData *pd) {
-+static void blist_store(struct mwGaim2PluginData *pd) {
-
- struct mwSametimeList *stlist;
- struct mwServiceStorage *srvc;
- struct mwStorageUnit *unit;
-
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- struct mwPutBuffer *b;
- struct mwOpaque *o;
-@@ -700,7 +700,7 @@ static void blist_store(struct mwGaimPlu
-
-
- static gboolean blist_save_cb(gpointer data) {
-- struct mwGaimPluginData *pd = data;
-+ struct mwGaim2PluginData *pd = data;
-
- blist_store(pd);
- pd->save_event = 0;
-@@ -709,38 +709,38 @@ static gboolean blist_save_cb(gpointer d
-
-
- /** schedules the buddy list to be saved to the server */
--static void blist_schedule(struct mwGaimPluginData *pd) {
-+static void blist_schedule(struct mwGaim2PluginData *pd) {
- if(pd->save_event) return;
-
-- pd->save_event = gaim_timeout_add(BLIST_SAVE_SECONDS * 1000,
-+ pd->save_event = gaim2_timeout_add(BLIST_SAVE_SECONDS * 1000,
- blist_save_cb, pd);
- }
-
-
--static gboolean buddy_is_external(GaimBuddy *b) {
-+static gboolean buddy_is_external(Gaim2Buddy *b) {
- g_return_val_if_fail(b != NULL, FALSE);
-- return gaim_str_has_prefix(b->name, "@E ");
-+ return gaim2_str_has_prefix(b->name, "@E ");
- }
-
-
- /** Actually add a buddy to the aware service, and schedule the buddy
- list to be saved to the server */
--static void buddy_add(struct mwGaimPluginData *pd,
-- GaimBuddy *buddy) {
-+static void buddy_add(struct mwGaim2PluginData *pd,
-+ Gaim2Buddy *buddy) {
-
- struct mwAwareIdBlock idb = { mwAware_USER, (char *) buddy->name, NULL };
- struct mwAwareList *list;
-
-- GaimGroup *group;
-+ Gaim2Group *group;
- GList *add;
-
- add = g_list_prepend(NULL, &idb);
-
-- group = gaim_buddy_get_group(buddy);
-+ group = gaim2_buddy_get_group(buddy);
- list = list_ensure(pd, group);
-
- if(mwAwareList_addAware(list, add)) {
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- }
-
- blist_schedule(pd);
-@@ -749,14 +749,14 @@ static void buddy_add(struct mwGaimPlugi
- }
-
-
--/** ensure that a GaimBuddy exists in the group with data
-+/** ensure that a Gaim2Buddy exists in the group with data
- appropriately matching the st user entry from the st list */
--static GaimBuddy *buddy_ensure(GaimConnection *gc, GaimGroup *group,
-+static Gaim2Buddy *buddy_ensure(Gaim2Connection *gc, Gaim2Group *group,
- struct mwSametimeUser *stuser) {
-
-- struct mwGaimPluginData *pd = gc->proto_data;
-- GaimBuddy *buddy;
-- GaimAccount *acct = gaim_connection_get_account(gc);
-+ struct mwGaim2PluginData *pd = gc->proto_data;
-+ Gaim2Buddy *buddy;
-+ Gaim2Account *acct = gaim2_connection_get_account(gc);
-
- const char *id = mwSametimeUser_getUser(stuser);
- const char *name = mwSametimeUser_getShortName(stuser);
-@@ -766,33 +766,33 @@ static GaimBuddy *buddy_ensure(GaimConne
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(strlen(id) > 0, NULL);
-
-- buddy = gaim_find_buddy_in_group(acct, id, group);
-+ buddy = gaim2_find_buddy_in_group(acct, id, group);
- if(! buddy) {
-- buddy = gaim_buddy_new(acct, id, alias);
-+ buddy = gaim2_buddy_new(acct, id, alias);
-
-- gaim_blist_add_buddy(buddy, NULL, group, NULL);
-+ gaim2_blist_add_buddy(buddy, NULL, group, NULL);
- buddy_add(pd, buddy);
- }
-
-- gaim_blist_alias_buddy(buddy, alias);
-- gaim_blist_server_alias_buddy(buddy, name);
-- gaim_blist_node_set_string((GaimBlistNode *) buddy, BUDDY_KEY_NAME, name);
-- gaim_blist_node_set_int((GaimBlistNode *) buddy, BUDDY_KEY_TYPE, type);
-+ gaim2_blist_alias_buddy(buddy, alias);
-+ gaim2_blist_server_alias_buddy(buddy, name);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *) buddy, BUDDY_KEY_NAME, name);
-+ gaim2_blist_node_set_int((Gaim2BlistNode *) buddy, BUDDY_KEY_TYPE, type);
-
- return buddy;
- }
-
-
- /** add aware watch for a dynamic group */
--static void group_add(struct mwGaimPluginData *pd,
-- GaimGroup *group) {
-+static void group_add(struct mwGaim2PluginData *pd,
-+ Gaim2Group *group) {
-
- struct mwAwareIdBlock idb = { mwAware_GROUP, NULL, NULL };
- struct mwAwareList *list;
- const char *n;
- GList *add;
-
-- n = gaim_blist_node_get_string((GaimBlistNode *) group, GROUP_KEY_NAME);
-+ n = gaim2_blist_node_get_string((Gaim2BlistNode *) group, GROUP_KEY_NAME);
- if(! n) n = group->name;
-
- idb.user = (char *) n;
-@@ -804,21 +804,21 @@ static void group_add(struct mwGaimPlugi
- }
-
-
--/** ensure that a GaimGroup exists in the blist with data
-+/** ensure that a Gaim2Group exists in the blist with data
- appropriately matching the st group entry from the st list */
--static GaimGroup *group_ensure(GaimConnection *gc,
-+static Gaim2Group *group_ensure(Gaim2Connection *gc,
- struct mwSametimeGroup *stgroup) {
-- GaimAccount *acct;
-- GaimGroup *group = NULL;
-- GaimBuddyList *blist;
-- GaimBlistNode *gn;
-+ Gaim2Account *acct;
-+ Gaim2Group *group = NULL;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gn;
- const char *name, *alias, *owner;
- enum mwSametimeGroupType type;
-
-- acct = gaim_connection_get_account(gc);
-- owner = gaim_account_get_username(acct);
-+ acct = gaim2_connection_get_account(gc);
-+ owner = gaim2_account_get_username(acct);
-
-- blist = gaim_get_blist();
-+ blist = gaim2_get_blist();
- g_return_val_if_fail(blist != NULL, NULL);
-
- name = mwSametimeGroup_getName(stgroup);
-@@ -832,15 +832,15 @@ static GaimGroup *group_ensure(GaimConne
- for(gn = blist->root; gn; gn = gn->next) {
- const char *n, *o;
- if(! GAIM_BLIST_NODE_IS_GROUP(gn)) continue;
-- n = gaim_blist_node_get_string(gn, GROUP_KEY_NAME);
-- o = gaim_blist_node_get_string(gn, GROUP_KEY_OWNER);
-+ n = gaim2_blist_node_get_string(gn, GROUP_KEY_NAME);
-+ o = gaim2_blist_node_get_string(gn, GROUP_KEY_OWNER);
-
- DEBUG_INFO("found group named %s, owned by %s\n", NSTR(n), NSTR(o));
-
- if(n && !strcmp(n, name)) {
- if(!o || !strcmp(o, owner)) {
- DEBUG_INFO("that'll work\n");
-- group = (GaimGroup *) gn;
-+ group = (Gaim2Group *) gn;
- break;
- }
- }
-@@ -849,22 +849,22 @@ static GaimGroup *group_ensure(GaimConne
- /* try again, by alias */
- if(! group) {
- DEBUG_INFO("searching for group by alias %s\n", NSTR(alias));
-- group = gaim_find_group(alias);
-+ group = gaim2_find_group(alias);
- }
-
- /* oh well, no such group. Let's create it! */
- if(! group) {
- DEBUG_INFO("creating group\n");
-- group = gaim_group_new(alias);
-- gaim_blist_add_group(group, NULL);
-+ group = gaim2_group_new(alias);
-+ gaim2_blist_add_group(group, NULL);
- }
-
-- gn = (GaimBlistNode *) group;
-- gaim_blist_node_set_string(gn, GROUP_KEY_NAME, name);
-- gaim_blist_node_set_int(gn, GROUP_KEY_TYPE, type);
-+ gn = (Gaim2BlistNode *) group;
-+ gaim2_blist_node_set_string(gn, GROUP_KEY_NAME, name);
-+ gaim2_blist_node_set_int(gn, GROUP_KEY_TYPE, type);
-
- if(type == mwSametimeGroup_DYNAMIC) {
-- gaim_blist_node_set_string(gn, GROUP_KEY_OWNER, owner);
-+ gaim2_blist_node_set_string(gn, GROUP_KEY_OWNER, owner);
- group_add(gc->proto_data, group);
- }
-
-@@ -872,13 +872,13 @@ static GaimGroup *group_ensure(GaimConne
- }
-
-
--/** merge the entries from a st list into the gaim blist */
--static void blist_merge(GaimConnection *gc, struct mwSametimeList *stlist) {
-+/** merge the entries from a st list into the gaim2 blist */
-+static void blist_merge(Gaim2Connection *gc, struct mwSametimeList *stlist) {
- struct mwSametimeGroup *stgroup;
- struct mwSametimeUser *stuser;
-
-- GaimGroup *group;
-- GaimBuddy *buddy;
-+ Gaim2Group *group;
-+ Gaim2Buddy *buddy;
-
- GList *gl, *gtl, *ul, *utl;
-
-@@ -902,25 +902,25 @@ static void blist_merge(GaimConnection *
-
- /** remove all buddies on account from group. If del is TRUE and group
- is left empty, remove group as well */
--static void group_clear(GaimGroup *group, GaimAccount *acct, gboolean del) {
-- GaimConnection *gc;
-+static void group_clear(Gaim2Group *group, Gaim2Account *acct, gboolean del) {
-+ Gaim2Connection *gc;
- GList *prune = NULL;
-- GaimBlistNode *gn, *cn, *bn;
-+ Gaim2BlistNode *gn, *cn, *bn;
-
- g_return_if_fail(group != NULL);
-
- DEBUG_INFO("clearing members from pruned group %s\n", NSTR(group->name));
-
-- gc = gaim_account_get_connection(acct);
-+ gc = gaim2_account_get_connection(acct);
- g_return_if_fail(gc != NULL);
-
-- gn = (GaimBlistNode *) group;
-+ gn = (Gaim2BlistNode *) group;
-
- for(cn = gn->child; cn; cn = cn->next) {
- if(! GAIM_BLIST_NODE_IS_CONTACT(cn)) continue;
-
- for(bn = cn->child; bn; bn = bn->next) {
-- GaimBuddy *gb = (GaimBuddy *) bn;
-+ Gaim2Buddy *gb = (Gaim2Buddy *) bn;
-
- if(! GAIM_BLIST_NODE_IS_BUDDY(bn)) continue;
-
-@@ -932,29 +932,29 @@ static void group_clear(GaimGroup *group
- }
-
- /* quickly unsubscribe from presence for the entire group */
-- gaim_account_remove_group(acct, group);
-+ gaim2_account_remove_group(acct, group);
-
- /* remove blist entries that need to go */
- while(prune) {
-- gaim_blist_remove_buddy(prune->data);
-+ gaim2_blist_remove_buddy(prune->data);
- prune = g_list_delete_link(prune, prune);
- }
- DEBUG_INFO("cleared buddies\n");
-
- /* optionally remove group from blist */
-- if(del && !gaim_blist_get_group_size(group, TRUE)) {
-+ if(del && !gaim2_blist_get_group_size(group, TRUE)) {
- DEBUG_INFO("removing empty group\n");
-- gaim_blist_remove_group(group);
-+ gaim2_blist_remove_group(group);
- }
- }
-
-
- /** prune out group members that shouldn't be there */
--static void group_prune(GaimConnection *gc, GaimGroup *group,
-+static void group_prune(Gaim2Connection *gc, Gaim2Group *group,
- struct mwSametimeGroup *stgroup) {
-
-- GaimAccount *acct;
-- GaimBlistNode *gn, *cn, *bn;
-+ Gaim2Account *acct;
-+ Gaim2BlistNode *gn, *cn, *bn;
-
- GHashTable *stusers;
- GList *prune = NULL;
-@@ -964,7 +964,7 @@ static void group_prune(GaimConnection *
-
- DEBUG_INFO("pruning membership of group %s\n", NSTR(group->name));
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_if_fail(acct != NULL);
-
- stusers = g_hash_table_new(g_str_hash, g_str_equal);
-@@ -979,13 +979,13 @@ static void group_prune(GaimConnection *
- }
- g_list_free(utl);
-
-- gn = (GaimBlistNode *) group;
-+ gn = (Gaim2BlistNode *) group;
-
- for(cn = gn->child; cn; cn = cn->next) {
- if(! GAIM_BLIST_NODE_IS_CONTACT(cn)) continue;
-
- for(bn = cn->child; bn; bn = bn->next) {
-- GaimBuddy *gb = (GaimBuddy *) bn;
-+ Gaim2Buddy *gb = (Gaim2Buddy *) bn;
-
- if(! GAIM_BLIST_NODE_IS_BUDDY(bn)) continue;
-
-@@ -1002,22 +1002,22 @@ static void group_prune(GaimConnection *
- g_hash_table_destroy(stusers);
-
- if(prune) {
-- gaim_account_remove_buddies(acct, prune, NULL);
-+ gaim2_account_remove_buddies(acct, prune, NULL);
- while(prune) {
-- gaim_blist_remove_buddy(prune->data);
-+ gaim2_blist_remove_buddy(prune->data);
- prune = g_list_delete_link(prune, prune);
- }
- }
- }
-
-
--/** synch the entries from a st list into the gaim blist, removing any
-+/** synch the entries from a st list into the gaim2 blist, removing any
- existing buddies that aren't in the st list */
--static void blist_sync(GaimConnection *gc, struct mwSametimeList *stlist) {
-+static void blist_sync(Gaim2Connection *gc, struct mwSametimeList *stlist) {
-
-- GaimAccount *acct;
-- GaimBuddyList *blist;
-- GaimBlistNode *gn;
-+ Gaim2Account *acct;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gn;
-
- GHashTable *stgroups;
- GList *g_prune = NULL;
-@@ -1028,12 +1028,12 @@ static void blist_sync(GaimConnection *g
-
- DEBUG_INFO("synchronizing local buddy list from server list\n");
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_if_fail(acct != NULL);
-
-- acct_n = gaim_account_get_username(acct);
-+ acct_n = gaim2_account_get_username(acct);
-
-- blist = gaim_get_blist();
-+ blist = gaim2_get_blist();
- g_return_if_fail(blist != NULL);
-
- /* build a hash table for quick lookup while pruning the local
-@@ -1049,24 +1049,24 @@ static void blist_sync(GaimConnection *g
-
- /* find all groups which should be pruned from the local list */
- for(gn = blist->root; gn; gn = gn->next) {
-- GaimGroup *grp = (GaimGroup *) gn;
-+ Gaim2Group *grp = (Gaim2Group *) gn;
- const char *gname, *owner;
- struct mwSametimeGroup *stgrp;
-
- if(! GAIM_BLIST_NODE_IS_GROUP(gn)) continue;
-
- /* group not belonging to this account */
-- if(! gaim_group_on_account(grp, acct))
-+ if(! gaim2_group_on_account(grp, acct))
- continue;
-
- /* dynamic group belonging to this account. don't prune contents */
-- owner = gaim_blist_node_get_string(gn, GROUP_KEY_OWNER);
-+ owner = gaim2_blist_node_get_string(gn, GROUP_KEY_OWNER);
- if(owner && !strcmp(owner, acct_n))
- continue;
-
- /* we actually are synching by this key as opposed to the group
- title, which can be different things in the st list */
-- gname = gaim_blist_node_get_string(gn, GROUP_KEY_NAME);
-+ gname = gaim2_blist_node_get_string(gn, GROUP_KEY_NAME);
- if(! gname) gname = grp->name;
-
- stgrp = g_hash_table_lookup(stgroups, gname);
-@@ -1087,12 +1087,12 @@ static void blist_sync(GaimConnection *g
-
- /* prune all marked groups */
- while(g_prune) {
-- GaimGroup *grp = g_prune->data;
-- GaimBlistNode *gn = (GaimBlistNode *) grp;
-+ Gaim2Group *grp = g_prune->data;
-+ Gaim2BlistNode *gn = (Gaim2BlistNode *) grp;
- const char *owner;
- gboolean del = TRUE;
-
-- owner = gaim_blist_node_get_string(gn, GROUP_KEY_OWNER);
-+ owner = gaim2_blist_node_get_string(gn, GROUP_KEY_OWNER);
- if(owner && strcmp(owner, acct_n)) {
- /* it's a specialty group belonging to another account with some
- of our members in it, so don't fully delete it */
-@@ -1114,7 +1114,7 @@ static void fetch_blist_cb(struct mwServ
- guint32 result, struct mwStorageUnit *item,
- gpointer data) {
-
-- struct mwGaimPluginData *pd = data;
-+ struct mwGaim2PluginData *pd = data;
- struct mwSametimeList *stlist;
- struct mwSession *s;
-
-@@ -1147,31 +1147,31 @@ static void fetch_blist_cb(struct mwServ
- }
-
-
--/** signal triggered when a conversation is opened in Gaim */
--static void conversation_created_cb(GaimConversation *g_conv,
-- struct mwGaimPluginData *pd) {
-+/** signal triggered when a conversation is opened in Gaim2 */
-+static void conversation_created_cb(Gaim2Conversation *g_conv,
-+ struct mwGaim2PluginData *pd) {
-
- /* we need to tell the IM service to negotiate features for the
- conversation right away, otherwise it'll wait until the first
- message is sent before offering NotesBuddy features. Therefore
-- whenever Gaim creates a conversation, we'll immediately open the
-+ whenever Gaim2 creates a conversation, we'll immediately open the
- channel to the other side and figure out what the target can
- handle. Unfortunately, this makes us vulnerable to Psychic Mode,
- whereas a more lazy negotiation based on the first message
- would not */
-
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- struct mwIdBlock who = { 0, 0 };
- struct mwConversation *conv;
-
-- gc = gaim_conversation_get_gc(g_conv);
-+ gc = gaim2_conversation_get_gc(g_conv);
- if(pd->gc != gc)
- return; /* not ours */
-
-- if(gaim_conversation_get_type(g_conv) != GAIM_CONV_TYPE_IM)
-+ if(gaim2_conversation_get_type(g_conv) != GAIM_CONV_TYPE_IM)
- return; /* wrong type */
-
-- who.user = (char *) gaim_conversation_get_name(g_conv);
-+ who.user = (char *) gaim2_conversation_get_name(g_conv);
- conv = mwServiceIm_getConversation(pd->srvc_im, &who);
-
- convo_features(conv);
-@@ -1181,11 +1181,11 @@ static void conversation_created_cb(Gaim
- }
-
-
--static void blist_menu_nab(GaimBlistNode *node, gpointer data) {
-- struct mwGaimPluginData *pd = data;
-- GaimConnection *gc;
-+static void blist_menu_nab(Gaim2BlistNode *node, gpointer data) {
-+ struct mwGaim2PluginData *pd = data;
-+ Gaim2Connection *gc;
-
-- GaimGroup *group = (GaimGroup *) node;
-+ Gaim2Group *group = (Gaim2Group *) node;
-
- GString *str;
- char *tmp;
-@@ -1199,14 +1199,14 @@ static void blist_menu_nab(GaimBlistNode
-
- str = g_string_new(NULL);
-
-- tmp = (char *) gaim_blist_node_get_string(node, GROUP_KEY_NAME);
-+ tmp = (char *) gaim2_blist_node_get_string(node, GROUP_KEY_NAME);
-
- g_string_append_printf(str, _("<b>Group Title:</b> %s<br>"), group->name);
- g_string_append_printf(str, _("<b>Notes Group ID:</b> %s<br>"), tmp);
-
- tmp = g_strdup_printf(_("Info for Group %s"), group->name);
-
-- gaim_notify_formatted(gc, tmp, _("Notes Address Book Information"),
-+ gaim2_notify_formatted(gc, tmp, _("Notes Address Book Information"),
- NULL, str->str, NULL, NULL);
-
- g_free(tmp);
-@@ -1217,37 +1217,37 @@ static void blist_menu_nab(GaimBlistNode
- /** The normal blist menu prpl function doesn't get called for groups,
- so we use the blist-node-extended-menu signal to trigger this
- handler */
--static void blist_node_menu_cb(GaimBlistNode *node,
-- GList **menu, struct mwGaimPluginData *pd) {
-+static void blist_node_menu_cb(Gaim2BlistNode *node,
-+ GList **menu, struct mwGaim2PluginData *pd) {
- const char *owner;
-- GaimGroup *group;
-- GaimAccount *acct;
-- GaimBlistNodeAction *act;
-+ Gaim2Group *group;
-+ Gaim2Account *acct;
-+ Gaim2BlistNodeAction *act;
-
- /* we only want groups */
- if(! GAIM_BLIST_NODE_IS_GROUP(node)) return;
-- group = (GaimGroup *) node;
-+ group = (Gaim2Group *) node;
-
-- acct = gaim_connection_get_account(pd->gc);
-+ acct = gaim2_connection_get_account(pd->gc);
- g_return_if_fail(acct != NULL);
-
- /* better make sure we're connected */
-- if(! gaim_account_is_connected(acct)) return;
-+ if(! gaim2_account_is_connected(acct)) return;
-
- #if 0
- /* if there's anyone in the group for this acct, offer to invite
- them all to a conference */
-- if(gaim_group_on_account(group, acct)) {
-- act = gaim_blist_node_action_new(_("Invite Group to Conference..."),
-+ if(gaim2_group_on_account(group, acct)) {
-+ act = gaim2_blist_node_action_new(_("Invite Group to Conference..."),
- blist_menu_group_invite, pd, NULL);
- *menu = g_list_append(*menu, NULL);
- }
- #endif
-
- /* check if it's a NAB group for this account */
-- owner = gaim_blist_node_get_string(node, GROUP_KEY_OWNER);
-- if(owner && !strcmp(owner, gaim_account_get_username(acct))) {
-- act = gaim_blist_node_action_new(_("Get Notes Address Book Info"),
-+ owner = gaim2_blist_node_get_string(node, GROUP_KEY_OWNER);
-+ if(owner && !strcmp(owner, gaim2_account_get_username(acct))) {
-+ act = gaim2_blist_node_action_new(_("Get Notes Address Book Info"),
- blist_menu_nab, pd, NULL);
- *menu = g_list_append(*menu, act);
- }
-@@ -1256,22 +1256,22 @@ static void blist_node_menu_cb(GaimBlist
-
- /* lifted this from oldstatus, since HEAD doesn't do this at login
- anymore. */
--static void blist_init(GaimAccount *acct) {
-- GaimBlistNode *gnode, *cnode, *bnode;
-+static void blist_init(Gaim2Account *acct) {
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- GList *add_buds = NULL;
-
-- for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for(gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if(! GAIM_BLIST_NODE_IS_GROUP(gnode)) continue;
-
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
- if(! GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for(bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if(b->account == acct) {
- add_buds = g_list_append(add_buds, b);
- }
-@@ -1280,42 +1280,42 @@ static void blist_init(GaimAccount *acct
- }
-
- if(add_buds) {
-- gaim_account_add_buddies(acct, add_buds);
-+ gaim2_account_add_buddies(acct, add_buds);
- g_list_free(add_buds);
- }
- }
-
-
- /** Last thing to happen from a started session */
--static void services_starting(struct mwGaimPluginData *pd) {
-+static void services_starting(struct mwGaim2PluginData *pd) {
-
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
- struct mwStorageUnit *unit;
-- GaimBuddyList *blist;
-- GaimBlistNode *l;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *l;
-
- gc = pd->gc;
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- /* grab the buddy list from the server */
- unit = mwStorageUnit_new(mwStore_AWARE_LIST);
- mwServiceStorage_load(pd->srvc_store, unit, fetch_blist_cb, pd, NULL);
-
- /* start watching for new conversations */
-- gaim_signal_connect(gaim_conversations_get_handle(),
-+ gaim2_signal_connect(gaim2_conversations_get_handle(),
- "conversation-created", gc,
- GAIM_CALLBACK(conversation_created_cb), pd);
-
- /* watch for group extended menu items */
-- gaim_signal_connect(gaim_blist_get_handle(),
-+ gaim2_signal_connect(gaim2_blist_get_handle(),
- "blist-node-extended-menu", gc,
- GAIM_CALLBACK(blist_node_menu_cb), pd);
-
- /* find all the NAB groups and subscribe to them */
-- blist = gaim_get_blist();
-+ blist = gaim2_get_blist();
- for(l = blist->root; l; l = l->next) {
-- GaimGroup *group = (GaimGroup *) l;
-+ Gaim2Group *group = (Gaim2Group *) l;
- enum mwSametimeGroupType gt;
- const char *owner;
-
-@@ -1323,11 +1323,11 @@ static void services_starting(struct mwG
-
- /* if the group is ownerless, or has an owner and we're not it,
- skip it */
-- owner = gaim_blist_node_get_string(l, GROUP_KEY_OWNER);
-- if(!owner || strcmp(owner, gaim_account_get_username(acct)))
-+ owner = gaim2_blist_node_get_string(l, GROUP_KEY_OWNER);
-+ if(!owner || strcmp(owner, gaim2_account_get_username(acct)))
- continue;
-
-- gt = gaim_blist_node_get_int(l, GROUP_KEY_TYPE);
-+ gt = gaim2_blist_node_get_int(l, GROUP_KEY_TYPE);
- if(gt == mwSametimeGroup_DYNAMIC)
- group_add(pd, group);
- }
-@@ -1350,36 +1350,36 @@ static void services_starting(struct mwG
-
- static void session_loginRedirect(struct mwSession *session,
- const char *host) {
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- guint port;
-
- pd = mwSession_getClientData(session);
- gc = pd->gc;
-- account = gaim_connection_get_account(gc);
-- port = gaim_account_get_int(account, MW_KEY_PORT, MW_PLUGIN_DEFAULT_PORT);
-+ account = gaim2_connection_get_account(gc);
-+ port = gaim2_account_get_int(account, MW_KEY_PORT, MW_PLUGIN_DEFAULT_PORT);
-
-- if(gaim_account_get_bool(account, MW_KEY_FORCE, FALSE) ||
-- gaim_proxy_connect(account, host, port, connect_cb, pd)) {
-+ if(gaim2_account_get_bool(account, MW_KEY_FORCE, FALSE) ||
-+ gaim2_proxy_connect(account, host, port, connect_cb, pd)) {
-
- mwSession_forceLogin(session);
- }
- }
-
-
--static void mw_prpl_set_status(GaimAccount *acct, GaimStatus *status);
-+static void mw_prpl_set_status(Gaim2Account *acct, Gaim2Status *status);
-
-
- /** called from mw_session_stateChange when the session's state is
- mwSession_STARTED. Any finalizing of start-up stuff should go
- here */
--static void session_started(struct mwGaimPluginData *pd) {
-- GaimStatus *status;
-- GaimAccount *acct;
-+static void session_started(struct mwGaim2PluginData *pd) {
-+ Gaim2Status *status;
-+ Gaim2Account *acct;
-
-- acct = gaim_connection_get_account(pd->gc);
-- status = gaim_account_get_active_status(acct);
-+ acct = gaim2_connection_get_account(pd->gc);
-+ status = gaim2_account_get_active_status(acct);
- mw_prpl_set_status(acct, status);
-
- /* use our services to do neat things */
-@@ -1390,8 +1390,8 @@ static void session_started(struct mwGai
- static void mw_session_stateChange(struct mwSession *session,
- enum mwSessionState state,
- gpointer info) {
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
- char *msg = NULL;
-
- pd = mwSession_getClientData(session);
-@@ -1400,43 +1400,43 @@ static void mw_session_stateChange(struc
- switch(state) {
- case mwSession_STARTING:
- msg = _("Sending Handshake");
-- gaim_connection_update_progress(gc, msg, 2, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 2, MW_CONNECT_STEPS);
- break;
-
- case mwSession_HANDSHAKE:
- msg = _("Waiting for Handshake Acknowledgement");
-- gaim_connection_update_progress(gc, msg, 3, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 3, MW_CONNECT_STEPS);
- break;
-
- case mwSession_HANDSHAKE_ACK:
- msg = _("Handshake Acknowledged, Sending Login");
-- gaim_connection_update_progress(gc, msg, 4, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 4, MW_CONNECT_STEPS);
- break;
-
- case mwSession_LOGIN:
- msg = _("Waiting for Login Acknowledgement");
-- gaim_connection_update_progress(gc, msg, 5, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 5, MW_CONNECT_STEPS);
- break;
-
- case mwSession_LOGIN_REDIR:
- msg = _("Login Redirected");
-- gaim_connection_update_progress(gc, msg, 6, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 6, MW_CONNECT_STEPS);
- session_loginRedirect(session, info);
- break;
-
- case mwSession_LOGIN_CONT:
- msg = _("Forcing Login");
-- gaim_connection_update_progress(gc, msg, 7, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 7, MW_CONNECT_STEPS);
-
- case mwSession_LOGIN_ACK:
- msg = _("Login Acknowledged");
-- gaim_connection_update_progress(gc, msg, 8, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, msg, 8, MW_CONNECT_STEPS);
- break;
-
- case mwSession_STARTED:
- msg = _("Connected to Sametime Community Server");
-- gaim_connection_update_progress(gc, msg, 9, MW_CONNECT_STEPS);
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_update_progress(gc, msg, 9, MW_CONNECT_STEPS);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- session_started(pd);
- break;
-@@ -1444,7 +1444,7 @@ static void mw_session_stateChange(struc
- case mwSession_STOPPING:
- if(GPOINTER_TO_UINT(info) & ERR_FAILURE) {
- msg = mwError(GPOINTER_TO_UINT(info));
-- gaim_connection_error(gc, msg);
-+ gaim2_connection_error(gc, msg);
- g_free(msg);
- }
- break;
-@@ -1460,9 +1460,9 @@ static void mw_session_stateChange(struc
-
-
- static void mw_session_setPrivacyInfo(struct mwSession *session) {
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
- struct mwPrivacyInfo *privacy;
- GSList *l, **ll;
- guint count;
-@@ -1477,7 +1477,7 @@ static void mw_session_setPrivacyInfo(st
- gc = pd->gc;
- g_return_if_fail(gc != NULL);
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_if_fail(acct != NULL);
-
- privacy = mwSession_getPrivacyInfo(session);
-@@ -1497,8 +1497,8 @@ static void mw_session_setPrivacyInfo(st
-
-
- static void mw_session_setUserStatus(struct mwSession *session) {
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
- struct mwAwareIdBlock idb = { mwAware_USER, NULL, NULL };
- struct mwUserStatus *stat;
-
-@@ -1521,14 +1521,14 @@ static void mw_session_setUserStatus(str
- static void mw_session_admin(struct mwSession *session,
- const char *text) {
-
-- GaimConnection *gc = session_to_gc(session);
-+ Gaim2Connection *gc = session_to_gc(session);
- g_return_if_fail(gc != NULL);
-
- /** @todo Admin alerts should probably be in a conversation window
-- rather than a gaim_notify_message. Or in some sort of updating
-+ rather than a gaim2_notify_message. Or in some sort of updating
- dialog, or something. */
-
-- gaim_notify_message(gc, GAIM_NOTIFY_MSG_INFO, _("Admin Alert"),
-+ gaim2_notify_message(gc, GAIM_NOTIFY_MSG_INFO, _("Admin Alert"),
- text, NULL, NULL, NULL);
- }
-
-@@ -1547,15 +1547,15 @@ static int read_recv(struct mwSession *s
- }
-
-
--/** callback triggered from gaim_input_add, watches the socked for
-+/** callback triggered from gaim2_input_add, watches the socked for
- available data to be processed by the session */
- static void read_cb(gpointer data, gint source,
-- GaimInputCondition cond) {
-+ Gaim2InputCondition cond) {
-
-- struct mwGaimPluginData *pd = data;
-+ struct mwGaim2PluginData *pd = data;
- int ret = 0, err = 0;
-
-- /* How the heck can this happen? Fix submitted to Gaim so that it
-+ /* How the heck can this happen? Fix submitted to Gaim2 so that it
- won't happen anymore. */
- if(! cond) return;
-
-@@ -1579,13 +1579,13 @@ static void read_cb(gpointer data, gint
- }
-
- if(pd->gc->inpa) {
-- gaim_input_remove(pd->gc->inpa);
-+ gaim2_input_remove(pd->gc->inpa);
- pd->gc->inpa = 0;
- }
-
- if(! ret) {
- DEBUG_INFO("connection reset\n");
-- gaim_connection_error(pd->gc, _("Connection reset"));
-+ gaim2_connection_error(pd->gc, _("Connection reset"));
-
- } else if(ret < 0) {
- char *msg = strerror(err);
-@@ -1593,21 +1593,21 @@ static void read_cb(gpointer data, gint
- DEBUG_INFO("error in read callback: %s\n", msg);
-
- msg = g_strdup_printf(_("Error reading from socket: %s"), msg);
-- gaim_connection_error(pd->gc, msg);
-+ gaim2_connection_error(pd->gc, msg);
- g_free(msg);
- }
- }
-
-
--/** Callback passed to gaim_proxy_connect when an account is logged
-+/** Callback passed to gaim2_proxy_connect when an account is logged
- in, and if the session logging in receives a redirect message */
- static void connect_cb(gpointer data, gint source,
-- GaimInputCondition cond) {
-+ Gaim2InputCondition cond) {
-
-- struct mwGaimPluginData *pd = data;
-- GaimConnection *gc = pd->gc;
-+ struct mwGaim2PluginData *pd = data;
-+ Gaim2Connection *gc = pd->gc;
-
-- if(! g_list_find(gaim_connections_get_all(), pd->gc)) {
-+ if(! g_list_find(gaim2_connections_get_all(), pd->gc)) {
- close(source);
- g_return_if_reached();
- }
-@@ -1621,7 +1621,7 @@ static void connect_cb(gpointer data, gi
-
- } else {
- /* this is a regular connect, error out */
-- gaim_connection_error(pd->gc, _("Unable to connect to host"));
-+ gaim2_connection_error(pd->gc, _("Unable to connect to host"));
- }
-
- return;
-@@ -1633,7 +1633,7 @@ static void connect_cb(gpointer data, gi
- }
-
- pd->socket = source;
-- gc->inpa = gaim_input_add(source, GAIM_INPUT_READ, read_cb, pd);
-+ gc->inpa = gaim2_input_add(source, GAIM_INPUT_READ, read_cb, pd);
-
- mwSession_start(pd->session);
- }
-@@ -1643,25 +1643,25 @@ static void mw_session_announce(struct m
- struct mwLoginInfo *from,
- gboolean may_reply,
- const char *text) {
-- struct mwGaimPluginData *pd;
-- GaimAccount *acct;
-- GaimConversation *conv;
-- GaimBuddy *buddy;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Account *acct;
-+ Gaim2Conversation *conv;
-+ Gaim2Buddy *buddy;
- char *who = from->user_id;
- char *msg;
-
- pd = mwSession_getClientData(s);
-- acct = gaim_connection_get_account(pd->gc);
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, acct);
-- if(! conv) conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, acct, who);
-+ acct = gaim2_connection_get_account(pd->gc);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, acct);
-+ if(! conv) conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, acct, who);
-
-- buddy = gaim_find_buddy(acct, who);
-- if(buddy) who = (char *) gaim_buddy_get_contact_alias(buddy);
-+ buddy = gaim2_find_buddy(acct, who);
-+ if(buddy) who = (char *) gaim2_buddy_get_contact_alias(buddy);
-
- who = g_strdup_printf(_("Announcement from %s"), who);
-- msg = gaim_markup_linkify(text);
-+ msg = gaim2_markup_linkify(text);
-
-- gaim_conversation_write(conv, who, msg, GAIM_MESSAGE_RECV, time(NULL));
-+ gaim2_conversation_write(conv, who, msg, GAIM_MESSAGE_RECV, time(NULL));
- g_free(who);
- g_free(msg);
- }
-@@ -1712,8 +1712,8 @@ static void mw_conf_invited(struct mwCon
-
- struct mwServiceConference *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-
- char *c_inviter, *c_name, *c_topic, *c_invitation;
- GHashTable *ht;
-@@ -1745,21 +1745,21 @@ static void mw_conf_invited(struct mwCon
- }
-
-
--/* The following mess helps us relate a mwConference to a GaimConvChat
-+/* The following mess helps us relate a mwConference to a Gaim2ConvChat
- in the various forms by which either may be indicated */
-
- #define CONF_TO_ID(conf) (GPOINTER_TO_INT(conf))
- #define ID_TO_CONF(pd, id) (conf_find_by_id((pd), (id)))
-
--#define CHAT_TO_ID(chat) (gaim_conv_chat_get_id(chat))
--#define ID_TO_CHAT(id) (gaim_find_chat(id))
-+#define CHAT_TO_ID(chat) (gaim2_conv_chat_get_id(chat))
-+#define ID_TO_CHAT(id) (gaim2_find_chat(id))
-
- #define CHAT_TO_CONF(pd, chat) (ID_TO_CONF((pd), CHAT_TO_ID(chat)))
- #define CONF_TO_CHAT(conf) (ID_TO_CHAT(CONF_TO_ID(conf)))
-
-
- static struct mwConference *
--conf_find_by_id(struct mwGaimPluginData *pd, int id) {
-+conf_find_by_id(struct mwGaim2PluginData *pd, int id) {
-
- struct mwServiceConference *srvc = pd->srvc_conf;
- struct mwConference *conf = NULL;
-@@ -1768,7 +1768,7 @@ conf_find_by_id(struct mwGaimPluginData
- ll = mwServiceConference_getConferences(srvc);
- for(l = ll; l; l = l->next) {
- struct mwConference *c = l->data;
-- GaimConvChat *h = mwConference_getClientData(c);
-+ Gaim2ConvChat *h = mwConference_getClientData(c);
-
- if(CHAT_TO_ID(h) == id) {
- conf = c;
-@@ -1784,9 +1784,9 @@ conf_find_by_id(struct mwGaimPluginData
- static void mw_conf_opened(struct mwConference *conf, GList *members) {
- struct mwServiceConference *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimConversation *g_conf;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *g_conf;
-
- const char *n = mwConference_getName(conf);
-
-@@ -1805,7 +1805,7 @@ static void mw_conf_opened(struct mwConf
-
- for(; members; members = members->next) {
- struct mwLoginInfo *peer = members->data;
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(g_conf), peer->user_id,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(g_conf), peer->user_id,
- NULL, GAIM_CBFLAGS_NONE, FALSE);
- }
- }
-@@ -1814,8 +1814,8 @@ static void mw_conf_opened(struct mwConf
- static void mw_conf_closed(struct mwConference *conf, guint32 reason) {
- struct mwServiceConference *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-
- const char *n = mwConference_getName(conf);
- char *msg = mwError(reason);
-@@ -1829,7 +1829,7 @@ static void mw_conf_closed(struct mwConf
-
- serv_got_chat_left(gc, CONF_TO_ID(conf));
-
-- gaim_notify_error(gc, _("Conference Closed"), NULL, msg);
-+ gaim2_notify_error(gc, _("Conference Closed"), NULL, msg);
- g_free(msg);
- }
-
-@@ -1839,9 +1839,9 @@ static void mw_conf_peer_joined(struct m
-
- struct mwServiceConference *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimConvChat *g_conf;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2ConvChat *g_conf;
-
- const char *n = mwConference_getName(conf);
-
-@@ -1855,7 +1855,7 @@ static void mw_conf_peer_joined(struct m
- g_conf = mwConference_getClientData(conf);
- g_return_if_fail(g_conf != NULL);
-
-- gaim_conv_chat_add_user(g_conf, peer->user_id,
-+ gaim2_conv_chat_add_user(g_conf, peer->user_id,
- NULL, GAIM_CBFLAGS_NONE, TRUE);
- }
-
-@@ -1865,9 +1865,9 @@ static void mw_conf_peer_parted(struct m
-
- struct mwServiceConference *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimConvChat *g_conf;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2ConvChat *g_conf;
-
- const char *n = mwConference_getName(conf);
-
-@@ -1881,7 +1881,7 @@ static void mw_conf_peer_parted(struct m
- g_conf = mwConference_getClientData(conf);
- g_return_if_fail(g_conf != NULL);
-
-- gaim_conv_chat_remove_user(g_conf, peer->user_id, NULL);
-+ gaim2_conv_chat_remove_user(g_conf, peer->user_id, NULL);
- }
-
-
-@@ -1890,8 +1890,8 @@ static void mw_conf_text(struct mwConfer
-
- struct mwServiceConference *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
- char *esc;
-
- srvc = mwConference_getService(conf);
-@@ -1908,7 +1908,7 @@ static void mw_conf_text(struct mwConfer
- static void mw_conf_typing(struct mwConference *conf,
- struct mwLoginInfo *who, gboolean typing) {
-
-- /* gaim really has no good way to expose this to the user. */
-+ /* gaim2 really has no good way to expose this to the user. */
-
- const char *n = mwConference_getName(conf);
- const char *w = who->user_id;
-@@ -1946,14 +1946,14 @@ static struct mwServiceConference *mw_sr
- }
-
-
--static void ft_incoming_cancel(GaimXfer *xfer) {
-+static void ft_incoming_cancel(Gaim2Xfer *xfer) {
- /* incoming transfer rejected or canceled in-progress */
- struct mwFileTransfer *ft = xfer->data;
- if(ft) mwFileTransfer_reject(ft);
- }
-
-
--static void ft_incoming_init(GaimXfer *xfer) {
-+static void ft_incoming_init(Gaim2Xfer *xfer) {
- /* incoming transfer accepted */
-
- /* - accept the mwFileTransfer
-@@ -1979,24 +1979,24 @@ static void ft_incoming_init(GaimXfer *x
-
- static void mw_ft_offered(struct mwFileTransfer *ft) {
- /*
-- - create a gaim ft object
-+ - create a gaim2 ft object
- - offer it
- */
-
- struct mwServiceFileTransfer *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
- const char *who;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- /* @todo add some safety checks */
- srvc = mwFileTransfer_getService(ft);
- session = mwService_getSession(MW_SERVICE(srvc));
- pd = mwSession_getClientData(session);
- gc = pd->gc;
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- who = mwFileTransfer_getUser(ft)->user;
-
-@@ -2006,21 +2006,21 @@ static void mw_ft_offered(struct mwFileT
- DEBUG_INFO(" size: %u\n", mwFileTransfer_getFileSize(ft));
- DEBUG_INFO(" text: %s\n", NSTR(mwFileTransfer_getMessage(ft)));
-
-- xfer = gaim_xfer_new(acct, GAIM_XFER_RECEIVE, who);
-+ xfer = gaim2_xfer_new(acct, GAIM_XFER_RECEIVE, who);
-
-- gaim_xfer_ref(xfer);
-- mwFileTransfer_setClientData(ft, xfer, (GDestroyNotify) gaim_xfer_unref);
-+ gaim2_xfer_ref(xfer);
-+ mwFileTransfer_setClientData(ft, xfer, (GDestroyNotify) gaim2_xfer_unref);
- xfer->data = ft;
-
-- gaim_xfer_set_init_fnc(xfer, ft_incoming_init);
-- gaim_xfer_set_cancel_recv_fnc(xfer, ft_incoming_cancel);
-- gaim_xfer_set_request_denied_fnc(xfer, ft_incoming_cancel);
--
-- gaim_xfer_set_filename(xfer, mwFileTransfer_getFileName(ft));
-- gaim_xfer_set_size(xfer, mwFileTransfer_getFileSize(ft));
-- gaim_xfer_set_message(xfer, mwFileTransfer_getMessage(ft));
-+ gaim2_xfer_set_init_fnc(xfer, ft_incoming_init);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, ft_incoming_cancel);
-+ gaim2_xfer_set_request_denied_fnc(xfer, ft_incoming_cancel);
-+
-+ gaim2_xfer_set_filename(xfer, mwFileTransfer_getFileName(ft));
-+ gaim2_xfer_set_size(xfer, mwFileTransfer_getFileSize(ft));
-+ gaim2_xfer_set_message(xfer, mwFileTransfer_getMessage(ft));
-
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
-
-@@ -2028,7 +2028,7 @@ static void ft_send(struct mwFileTransfe
- guchar buf[BUF_LONG];
- struct mwOpaque o = { .data = buf, .len = BUF_LONG };
- guint32 rem;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- xfer = mwFileTransfer_getClientData(ft);
-
-@@ -2055,7 +2055,7 @@ static void ft_send(struct mwFileTransfe
-
-
- static gboolean ft_idle_cb(struct mwFileTransfer *ft) {
-- GaimXfer *xfer = mwFileTransfer_getClientData(ft);
-+ Gaim2Xfer *xfer = mwFileTransfer_getClientData(ft);
- g_return_val_if_fail(xfer != NULL, FALSE);
-
- xfer->watcher = 0;
-@@ -2067,11 +2067,11 @@ static gboolean ft_idle_cb(struct mwFile
-
- static void mw_ft_opened(struct mwFileTransfer *ft) {
- /*
-- - get gaim ft from client data in ft
-+ - get gaim2 ft from client data in ft
- - set the state to active
- */
-
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- xfer = mwFileTransfer_getClientData(ft);
-
-@@ -2081,9 +2081,9 @@ static void mw_ft_opened(struct mwFileTr
- g_return_if_reached();
- }
-
-- gaim_xfer_update_progress(xfer);
-+ gaim2_xfer_update_progress(xfer);
-
-- if(gaim_xfer_get_type(xfer) == GAIM_XFER_SEND) {
-+ if(gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND) {
- xfer->watcher = g_idle_add((GSourceFunc)ft_idle_cb, ft);
- xfer->dest_fp = g_fopen(xfer->local_filename, "rb");
- }
-@@ -2092,33 +2092,33 @@ static void mw_ft_opened(struct mwFileTr
-
- static void mw_ft_closed(struct mwFileTransfer *ft, guint32 code) {
- /*
-- - get gaim ft from client data in ft
-+ - get gaim2 ft from client data in ft
- - indicate rejection/cancelation/completion
- - free the file transfer itself
- */
-
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- xfer = mwFileTransfer_getClientData(ft);
- if(xfer) {
- xfer->data = NULL;
-
- if(mwFileTransfer_isDone(ft)) {
-- gaim_xfer_set_completed(xfer, TRUE);
-- gaim_xfer_end(xfer);
-+ gaim2_xfer_set_completed(xfer, TRUE);
-+ gaim2_xfer_end(xfer);
-
- } else if(mwFileTransfer_isCancelLocal(ft)) {
-- /* calling gaim_xfer_cancel_local is redundant, since that's
-+ /* calling gaim2_xfer_cancel_local is redundant, since that's
- probably what triggered this function to be called */
- ;
-
- } else if(mwFileTransfer_isCancelRemote(ft)) {
- /* steal the reference for the xfer */
- mwFileTransfer_setClientData(ft, NULL, NULL);
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
-
- /* drop the stolen reference */
-- gaim_xfer_unref(xfer);
-+ gaim2_xfer_unref(xfer);
- return;
- }
- }
-@@ -2130,12 +2130,12 @@ static void mw_ft_closed(struct mwFileTr
- static void mw_ft_recv(struct mwFileTransfer *ft,
- struct mwOpaque *data) {
- /*
-- - get gaim ft from client data in ft
-+ - get gaim2 ft from client data in ft
- - update transfered percentage
-- - if done, destroy the ft, disassociate from gaim ft
-+ - if done, destroy the ft, disassociate from gaim2 ft
- */
-
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- FILE *fp;
-
- xfer = mwFileTransfer_getClientData(ft);
-@@ -2150,7 +2150,7 @@ static void mw_ft_recv(struct mwFileTran
- /* update the progress */
- xfer->bytes_sent += data->len;
- xfer->bytes_remaining -= data->len;
-- gaim_xfer_update_progress(xfer);
-+ gaim2_xfer_update_progress(xfer);
-
- /* let the other side know we got it, and to send some more */
- mwFileTransfer_ack(ft);
-@@ -2158,13 +2158,13 @@ static void mw_ft_recv(struct mwFileTran
-
-
- static void mw_ft_ack(struct mwFileTransfer *ft) {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- xfer = mwFileTransfer_getClientData(ft);
- g_return_if_fail(xfer != NULL);
- g_return_if_fail(xfer->watcher == 0);
-
-- gaim_xfer_update_progress(xfer);
-+ gaim2_xfer_update_progress(xfer);
-
- if(mwFileTransfer_isOpen(ft))
- xfer->watcher = g_idle_add((GSourceFunc)ft_idle_cb, ft);
-@@ -2231,12 +2231,12 @@ static void convo_data_new(struct mwConv
- }
-
-
--static GaimConversation *convo_get_gconv(struct mwConversation *conv) {
-+static Gaim2Conversation *convo_get_gconv(struct mwConversation *conv) {
- struct mwServiceIm *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
-
- struct mwIdBlock *idb;
-
-@@ -2244,11 +2244,11 @@ static GaimConversation *convo_get_gconv
- session = mwService_getSession(MW_SERVICE(srvc));
- pd = mwSession_getClientData(session);
- gc = pd->gc;
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- idb = mwConversation_getTarget(conv);
-
-- return gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ return gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- idb->user, acct);
- }
-
-@@ -2283,7 +2283,7 @@ static void convo_queue(struct mwConvers
-
- /* Does what it takes to get an error displayed for a conversation */
- static void convo_error(struct mwConversation *conv, guint32 err) {
-- GaimConversation *gconv;
-+ Gaim2Conversation *gconv;
- char *tmp, *text;
- struct mwIdBlock *idb;
-
-@@ -2293,12 +2293,12 @@ static void convo_error(struct mwConvers
- text = g_strconcat(_("Unable to send message: "), tmp, NULL);
-
- gconv = convo_get_gconv(conv);
-- if(gconv && !gaim_conv_present_error(idb->user, gconv->account, text)) {
-+ if(gconv && !gaim2_conv_present_error(idb->user, gconv->account, text)) {
-
- g_free(text);
- text = g_strdup_printf(_("Unable to send message to %s:"),
- (idb->user)? idb->user: "(unknown)");
-- gaim_notify_error(gaim_account_get_connection(gconv->account),
-+ gaim2_notify_error(gaim2_account_get_connection(gconv->account),
- NULL, text, tmp);
- }
-
-@@ -2326,34 +2326,34 @@ static void convo_queue_send(struct mwCo
- }
-
-
--/** called when a mw conversation leaves a gaim conversation to
-- inform the gaim conversation that it's unsafe to offer any *cool*
-+/** called when a mw conversation leaves a gaim2 conversation to
-+ inform the gaim2 conversation that it's unsafe to offer any *cool*
- features. */
- static void convo_nofeatures(struct mwConversation *conv) {
-- GaimConversation *gconv;
-- GaimConnection *gc;
-+ Gaim2Conversation *gconv;
-+ Gaim2Connection *gc;
-
- gconv = convo_get_gconv(conv);
- if(! gconv) return;
-
-- gc = gaim_conversation_get_gc(gconv);
-+ gc = gaim2_conversation_get_gc(gconv);
- if(! gc) return;
-
-- gaim_conversation_set_features(gconv, gc->flags);
-+ gaim2_conversation_set_features(gconv, gc->flags);
- }
-
-
--/** called when a mw conversation and gaim conversation come together,
-- to inform the gaim conversation of what features to offer the
-+/** called when a mw conversation and gaim2 conversation come together,
-+ to inform the gaim2 conversation of what features to offer the
- user */
- static void convo_features(struct mwConversation *conv) {
-- GaimConversation *gconv;
-- GaimConnectionFlags feat;
-+ Gaim2Conversation *gconv;
-+ Gaim2ConnectionFlags feat;
-
- gconv = convo_get_gconv(conv);
- if(! gconv) return;
-
-- feat = gaim_conversation_get_features(gconv);
-+ feat = gaim2_conversation_get_features(gconv);
-
- if(mwConversation_isOpen(conv)) {
- if(mwConversation_supports(conv, mwImSend_HTML)) {
-@@ -2369,7 +2369,7 @@ static void convo_features(struct mwConv
- }
-
- DEBUG_INFO("conversation features set to 0x%04x\n", feat);
-- gaim_conversation_set_features(gconv, feat);
-+ gaim2_conversation_set_features(gconv, feat);
-
- } else {
- convo_nofeatures(conv);
-@@ -2384,35 +2384,35 @@ static void convo_features(struct mwConv
- static void convo_do_psychic(struct mwConversation *conv) {
- struct mwServiceIm *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
-
- struct mwIdBlock *idb;
-
-- GaimConversation *gconv;
-- GaimConvWindow *win;
-+ Gaim2Conversation *gconv;
-+ Gaim2ConvWindow *win;
-
- srvc = mwConversation_getService(conv);
- session = mwService_getSession(MW_SERVICE(srvc));
- pd = mwSession_getClientData(session);
- gc = pd->gc;
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- idb = mwConversation_getTarget(conv);
-
-- gconv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ gconv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- idb->user, acct);
- if(! gconv) {
-- gconv = gaim_conversation_new(GAIM_CONV_TYPE_IM, acct, idb->user);
-+ gconv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, acct, idb->user);
- }
-
- g_return_if_fail(gconv != NULL);
-
-- win = gaim_conversation_get_window(gconv);
-+ win = gaim2_conversation_get_window(gconv);
- g_return_if_fail(win != NULL);
-
-- gaim_conv_window_show(win);
-+ gaim2_conv_window_show(win);
- }
- #endif
-
-@@ -2420,9 +2420,9 @@ static void convo_do_psychic(struct mwCo
- static void mw_conversation_opened(struct mwConversation *conv) {
- struct mwServiceIm *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimAccount *acct;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
-
- struct convo_dat *cd;
-
-@@ -2430,7 +2430,7 @@ static void mw_conversation_opened(struc
- session = mwService_getSession(MW_SERVICE(srvc));
- pd = mwSession_getClientData(session);
- gc = pd->gc;
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- /* set up the queue */
- cd = mwConversation_getClientData(conv);
-@@ -2447,13 +2447,13 @@ static void mw_conversation_opened(struc
- }
-
- { /* record the client key for the buddy */
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
- struct mwLoginInfo *info;
- info = mwConversation_getTargetInfo(conv);
-
-- buddy = gaim_find_buddy(acct, info->user_id);
-+ buddy = gaim2_find_buddy(acct, info->user_id);
- if(buddy) {
-- gaim_blist_node_set_int((GaimBlistNode *) buddy,
-+ gaim2_blist_node_set_int((Gaim2BlistNode *) buddy,
- BUDDY_KEY_CLIENT, info->type);
- }
- }
-@@ -2495,7 +2495,7 @@ static void mw_conversation_closed(struc
-
-
- static void im_recv_text(struct mwConversation *conv,
-- struct mwGaimPluginData *pd,
-+ struct mwGaim2PluginData *pd,
- const char *msg) {
-
- struct mwIdBlock *idb;
-@@ -2504,7 +2504,7 @@ static void im_recv_text(struct mwConver
-
- idb = mwConversation_getTarget(conv);
-
-- txt = gaim_utf8_try_convert(msg);
-+ txt = gaim2_utf8_try_convert(msg);
- t = txt? txt: msg;
-
- esc = g_markup_escape_text(t, -1);
-@@ -2516,7 +2516,7 @@ static void im_recv_text(struct mwConver
-
-
- static void im_recv_typing(struct mwConversation *conv,
-- struct mwGaimPluginData *pd,
-+ struct mwGaim2PluginData *pd,
- gboolean typing) {
-
- struct mwIdBlock *idb;
-@@ -2528,7 +2528,7 @@ static void im_recv_typing(struct mwConv
-
-
- static void im_recv_html(struct mwConversation *conv,
-- struct mwGaimPluginData *pd,
-+ struct mwGaim2PluginData *pd,
- const char *msg) {
- struct mwIdBlock *idb;
- char *t1, *t2;
-@@ -2537,11 +2537,11 @@ static void im_recv_html(struct mwConver
- idb = mwConversation_getTarget(conv);
-
- /* ensure we're receiving UTF8 */
-- t1 = gaim_utf8_try_convert(msg);
-+ t1 = gaim2_utf8_try_convert(msg);
- t = t1? t1: msg;
-
- /* convert entities to UTF8 so they'll log correctly */
-- t2 = gaim_utf8_ncr_decode(t);
-+ t2 = gaim2_utf8_ncr_decode(t);
- t = t2? t2: t;
-
- serv_got_im(pd->gc, idb->user, t, 0, time(NULL));
-@@ -2552,7 +2552,7 @@ static void im_recv_html(struct mwConver
-
-
- static void im_recv_subj(struct mwConversation *conv,
-- struct mwGaimPluginData *pd,
-+ struct mwGaim2PluginData *pd,
- const char *subj) {
-
- /** @todo somehow indicate receipt of a conversation subject. It
-@@ -2581,7 +2581,7 @@ static char *make_cid(const char *cid) {
-
-
- static void im_recv_mime(struct mwConversation *conv,
-- struct mwGaimPluginData *pd,
-+ struct mwGaim2PluginData *pd,
- const char *data) {
-
- struct mwIdBlock *idb;
-@@ -2591,7 +2591,7 @@ static void im_recv_mime(struct mwConver
-
- GString *str;
-
-- GaimMimeDocument *doc;
-+ Gaim2MimeDocument *doc;
- const GList *parts;
-
- idb = mwConversation_getTarget(conv);
-@@ -2602,21 +2602,21 @@ static void im_recv_mime(struct mwConver
- /* don't want the contained string to ever be NULL */
- str = g_string_new("");
-
-- doc = gaim_mime_document_parse(data);
-+ doc = gaim2_mime_document_parse(data);
-
- /* handle all the MIME parts */
-- parts = gaim_mime_document_get_parts(doc);
-+ parts = gaim2_mime_document_get_parts(doc);
- for(; parts; parts = parts->next) {
-- GaimMimePart *part = parts->data;
-+ Gaim2MimePart *part = parts->data;
- const char *type;
-
-- type = gaim_mime_part_get_field(part, "content-type");
-+ type = gaim2_mime_part_get_field(part, "content-type");
- DEBUG_INFO("MIME part Content-Type: %s\n", NSTR(type));
-
- if(! type) {
- ; /* feh */
-
-- } else if(gaim_str_has_prefix(type, "image")) {
-+ } else if(gaim2_str_has_prefix(type, "image")) {
- /* put images into the image store */
-
- guchar *d_dat;
-@@ -2625,14 +2625,14 @@ static void im_recv_mime(struct mwConver
- int img;
-
- /* obtain and unencode the data */
-- gaim_mime_part_get_data_decoded(part, &d_dat, &d_len);
-+ gaim2_mime_part_get_data_decoded(part, &d_dat, &d_len);
-
- /* look up the content id */
-- cid = (char *) gaim_mime_part_get_field(part, "Content-ID");
-+ cid = (char *) gaim2_mime_part_get_field(part, "Content-ID");
- cid = make_cid(cid);
-
-- /* add image to the gaim image store */
-- img = gaim_imgstore_add(d_dat, d_len, cid);
-+ /* add image to the gaim2 image store */
-+ img = gaim2_imgstore_add(d_dat, d_len, cid);
- g_free(d_dat);
-
- /* map the cid to the image store identifier */
-@@ -2641,19 +2641,19 @@ static void im_recv_mime(struct mwConver
- /* recall the image for dereferencing later */
- images = g_list_append(images, GINT_TO_POINTER(img));
-
-- } else if(gaim_str_has_prefix(type, "text")) {
-+ } else if(gaim2_str_has_prefix(type, "text")) {
-
- /* concatenate all the text parts together */
- guchar *data;
- gsize len;
-
-- gaim_mime_part_get_data_decoded(part, &data, &len);
-+ gaim2_mime_part_get_data_decoded(part, &data, &len);
- g_string_append(str, (const char *)data);
- g_free(data);
- }
- }
-
-- gaim_mime_document_free(doc);
-+ gaim2_mime_document_free(doc);
-
- /* @todo should put this in its own function */
- { /* replace each IMG tag's SRC attribute with an ID attribute. This
-@@ -2662,7 +2662,7 @@ static void im_recv_mime(struct mwConver
- char *start, *end;
- char *tmp = str->str;
-
-- while(*tmp && gaim_markup_find_tag("img", tmp, (const char **) &start,
-+ while(*tmp && gaim2_markup_find_tag("img", tmp, (const char **) &start,
- (const char **) &end, &attribs)) {
-
- char *alt, *align, *border, *src;
-@@ -2704,7 +2704,7 @@ static void im_recv_mime(struct mwConver
-
- /* dereference all the imgages */
- while(images) {
-- gaim_imgstore_unref(GPOINTER_TO_INT(images->data));
-+ gaim2_imgstore_unref(GPOINTER_TO_INT(images->data));
- images = g_list_delete_link(images, images);
- }
- }
-@@ -2715,7 +2715,7 @@ static void mw_conversation_recv(struct
- gconstpointer msg) {
- struct mwServiceIm *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
-
- srvc = mwConversation_getService(conv);
- session = mwService_getSession(MW_SERVICE(srvc));
-@@ -2754,7 +2754,7 @@ static void mw_place_invite(struct mwCon
- const char *title, const char *name) {
- struct mwServiceIm *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
-
- struct mwIdBlock *idb;
- GHashTable *ht;
-@@ -2801,7 +2801,7 @@ static struct mwServiceIm *mw_srvc_im_ne
- }
-
-
--/* The following helps us relate a mwPlace to a GaimConvChat in the
-+/* The following helps us relate a mwPlace to a Gaim2ConvChat in the
- various forms by which either may be indicated. Uses some of
- the similar macros from the conference service above */
-
-@@ -2813,7 +2813,7 @@ static struct mwServiceIm *mw_srvc_im_ne
-
-
- static struct mwPlace *
--place_find_by_id(struct mwGaimPluginData *pd, int id) {
-+place_find_by_id(struct mwGaim2PluginData *pd, int id) {
- struct mwServicePlace *srvc = pd->srvc_place;
- struct mwPlace *place = NULL;
- GList *l;
-@@ -2821,7 +2821,7 @@ place_find_by_id(struct mwGaimPluginData
- l = (GList *) mwServicePlace_getPlaces(srvc);
- for(; l; l = l->next) {
- struct mwPlace *p = l->data;
-- GaimConvChat *h = GAIM_CONV_CHAT(mwPlace_getClientData(p));
-+ Gaim2ConvChat *h = GAIM_CONV_CHAT(mwPlace_getClientData(p));
-
- if(CHAT_TO_ID(h) == id) {
- place = p;
-@@ -2836,9 +2836,9 @@ place_find_by_id(struct mwGaimPluginData
- static void mw_place_opened(struct mwPlace *place) {
- struct mwServicePlace *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimConversation *gconf;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *gconf;
-
- GList *members, *l;
-
-@@ -2861,7 +2861,7 @@ static void mw_place_opened(struct mwPla
-
- for(l = members; l; l = l->next) {
- struct mwIdBlock *idb = l->data;
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(gconf), idb->user,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(gconf), idb->user,
- NULL, GAIM_CBFLAGS_NONE, FALSE);
- }
- g_list_free(members);
-@@ -2871,8 +2871,8 @@ static void mw_place_opened(struct mwPla
- static void mw_place_closed(struct mwPlace *place, guint32 code) {
- struct mwServicePlace *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-
- const char *n = mwPlace_getName(place);
- char *msg = mwError(code);
-@@ -2886,7 +2886,7 @@ static void mw_place_closed(struct mwPla
-
- serv_got_chat_left(gc, PLACE_TO_ID(place));
-
-- gaim_notify_error(gc, _("Place Closed"), NULL, msg);
-+ gaim2_notify_error(gc, _("Place Closed"), NULL, msg);
- g_free(msg);
- }
-
-@@ -2895,9 +2895,9 @@ static void mw_place_peerJoined(struct m
- const struct mwIdBlock *peer) {
- struct mwServicePlace *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimConversation *gconf;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *gconf;
-
- const char *n = mwPlace_getName(place);
-
-@@ -2911,7 +2911,7 @@ static void mw_place_peerJoined(struct m
- gconf = mwPlace_getClientData(place);
- g_return_if_fail(gconf != NULL);
-
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(gconf), peer->user,
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(gconf), peer->user,
- NULL, GAIM_CBFLAGS_NONE, TRUE);
- }
-
-@@ -2920,9 +2920,9 @@ static void mw_place_peerParted(struct m
- const struct mwIdBlock *peer) {
- struct mwServicePlace *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-- GaimConversation *gconf;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *gconf;
-
- const char *n = mwPlace_getName(place);
-
-@@ -2936,7 +2936,7 @@ static void mw_place_peerParted(struct m
- gconf = mwPlace_getClientData(place);
- g_return_if_fail(gconf != NULL);
-
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(gconf), peer->user, NULL);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(gconf), peer->user, NULL);
- }
-
-
-@@ -2959,8 +2959,8 @@ static void mw_place_message(struct mwPl
- const char *msg) {
- struct mwServicePlace *srvc;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
- char *esc;
-
- srvc = mwPlace_getService(place);
-@@ -3012,13 +3012,13 @@ static struct mwServiceStorage *mw_srvc_
- }
-
-
--/** allocate and associate a mwGaimPluginData with a GaimConnection */
--static struct mwGaimPluginData *mwGaimPluginData_new(GaimConnection *gc) {
-- struct mwGaimPluginData *pd;
-+/** allocate and associate a mwGaim2PluginData with a Gaim2Connection */
-+static struct mwGaim2PluginData *mwGaim2PluginData_new(Gaim2Connection *gc) {
-+ struct mwGaim2PluginData *pd;
-
- g_return_val_if_fail(gc != NULL, NULL);
-
-- pd = g_new0(struct mwGaimPluginData, 1);
-+ pd = g_new0(struct mwGaim2PluginData, 1);
- pd->gc = gc;
- pd->session = mwSession_new(&mw_session_handler);
- pd->srvc_aware = mw_srvc_aware_new(pd->session);
-@@ -3048,7 +3048,7 @@ static struct mwGaimPluginData *mwGaimPl
- }
-
-
--static void mwGaimPluginData_free(struct mwGaimPluginData *pd) {
-+static void mwGaim2PluginData_free(struct mwGaim2PluginData *pd) {
- g_return_if_fail(pd != NULL);
-
- pd->gc->proto_data = NULL;
-@@ -3080,7 +3080,7 @@ static void mwGaimPluginData_free(struct
- }
-
-
--static const char *mw_prpl_list_icon(GaimAccount *a, GaimBuddy *b) {
-+static const char *mw_prpl_list_icon(Gaim2Account *a, Gaim2Buddy *b) {
- /* my little green dude is a chopped up version of the aim running
- guy. First, cut off the head and store someplace safe. Then,
- take the left-half side of the body and throw it away. Make a
-@@ -3096,20 +3096,20 @@ static const char *mw_prpl_list_icon(Gai
- }
-
-
--static void mw_prpl_list_emblems(GaimBuddy *b,
-+static void mw_prpl_list_emblems(Gaim2Buddy *b,
- const char **se, const char **sw,
- const char **nw, const char **ne) {
-
- /* speaking of custom icons, the external icon here is an ugly
- little example of what happens when I use Gimp */
-
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- const char *status_id;
-
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-- status_id = gaim_status_get_id(status);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-+ status_id = gaim2_status_get_id(status);
-
- if(! GAIM_BUDDY_IS_ONLINE(b)) {
- *se = "offline";
-@@ -3126,9 +3126,9 @@ static void mw_prpl_list_emblems(GaimBud
- }
-
-
--static char *mw_prpl_status_text(GaimBuddy *b) {
-- GaimConnection *gc;
-- struct mwGaimPluginData *pd;
-+static char *mw_prpl_status_text(Gaim2Buddy *b) {
-+ Gaim2Connection *gc;
-+ struct mwGaim2PluginData *pd;
- struct mwAwareIdBlock t = { mwAware_USER, b->name, NULL };
- const char *ret;
-
-@@ -3140,14 +3140,14 @@ static char *mw_prpl_status_text(GaimBud
- }
-
-
--static const char *status_text(GaimBuddy *b) {
-- GaimPresence *presence;
-- GaimStatus *status;
-+static const char *status_text(Gaim2Buddy *b) {
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-
-- return gaim_status_get_name(status);
-+ return gaim2_status_get_name(status);
- }
-
-
-@@ -3186,9 +3186,9 @@ static char *user_supports_text(struct m
- }
-
-
--static char *mw_prpl_tooltip_text(GaimBuddy *b) {
-- GaimConnection *gc;
-- struct mwGaimPluginData *pd;
-+static char *mw_prpl_tooltip_text(Gaim2Buddy *b) {
-+ Gaim2Connection *gc;
-+ struct mwGaim2PluginData *pd;
- struct mwAwareIdBlock idb = { mwAware_USER, b->name, NULL };
-
- GString *str;
-@@ -3225,29 +3225,29 @@ static char *mw_prpl_tooltip_text(GaimBu
- }
-
-
--static GList *mw_prpl_status_types(GaimAccount *acct) {
-+static GList *mw_prpl_status_types(Gaim2Account *acct) {
- GList *types = NULL;
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
-
-- type = gaim_status_type_new(GAIM_STATUS_AVAILABLE, MW_STATE_ACTIVE,
-+ type = gaim2_status_type_new(GAIM_STATUS_AVAILABLE, MW_STATE_ACTIVE,
- _("Active"), TRUE);
-- gaim_status_type_add_attr(type, MW_STATE_MESSAGE, _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_status_type_add_attr(type, MW_STATE_MESSAGE, _("Message"),
-+ gaim2_value_new(GAIM_TYPE_STRING));
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, MW_STATE_AWAY,
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, MW_STATE_AWAY,
- NULL, TRUE);
-- gaim_status_type_add_attr(type, MW_STATE_MESSAGE, _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_status_type_add_attr(type, MW_STATE_MESSAGE, _("Message"),
-+ gaim2_value_new(GAIM_TYPE_STRING));
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_UNAVAILABLE, MW_STATE_BUSY,
-+ type = gaim2_status_type_new(GAIM_STATUS_UNAVAILABLE, MW_STATE_BUSY,
- _("Do Not Disturb"), TRUE);
-- gaim_status_type_add_attr(type, MW_STATE_MESSAGE, _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING));
-+ gaim2_status_type_add_attr(type, MW_STATE_MESSAGE, _("Message"),
-+ gaim2_value_new(GAIM_TYPE_STRING));
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_OFFLINE, MW_STATE_OFFLINE,
-+ type = gaim2_status_type_new(GAIM_STATUS_OFFLINE, MW_STATE_OFFLINE,
- NULL, TRUE);
- types = g_list_append(types, type);
-
-@@ -3255,35 +3255,35 @@ static GList *mw_prpl_status_types(GaimA
- }
-
-
--static void conf_create_prompt_cancel(GaimBuddy *buddy,
-- GaimRequestFields *fields) {
-+static void conf_create_prompt_cancel(Gaim2Buddy *buddy,
-+ Gaim2RequestFields *fields) {
- ; /* nothing to do */
- }
-
-
--static void conf_create_prompt_join(GaimBuddy *buddy,
-- GaimRequestFields *fields) {
-- GaimAccount *acct;
-- GaimConnection *gc;
-- struct mwGaimPluginData *pd;
-+static void conf_create_prompt_join(Gaim2Buddy *buddy,
-+ Gaim2RequestFields *fields) {
-+ Gaim2Account *acct;
-+ Gaim2Connection *gc;
-+ struct mwGaim2PluginData *pd;
- struct mwServiceConference *srvc;
-
-- GaimRequestField *f;
-+ Gaim2RequestField *f;
-
- const char *topic, *invite;
- struct mwConference *conf;
- struct mwIdBlock idb = { NULL, NULL };
-
- acct = buddy->account;
-- gc = gaim_account_get_connection(acct);
-+ gc = gaim2_account_get_connection(acct);
- pd = gc->proto_data;
- srvc = pd->srvc_conf;
-
-- f = gaim_request_fields_get_field(fields, CHAT_KEY_TOPIC);
-- topic = gaim_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, CHAT_KEY_TOPIC);
-+ topic = gaim2_request_field_string_get_value(f);
-
-- f = gaim_request_fields_get_field(fields, CHAT_KEY_INVITE);
-- invite = gaim_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, CHAT_KEY_INVITE);
-+ invite = gaim2_request_field_string_get_value(f);
-
- conf = mwConference_new(srvc, topic);
- mwConference_open(conf);
-@@ -3293,14 +3293,14 @@ static void conf_create_prompt_join(Gaim
- }
-
-
--static void blist_menu_conf_create(GaimBuddy *buddy, const char *msg) {
-+static void blist_menu_conf_create(Gaim2Buddy *buddy, const char *msg) {
-
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
-
-- GaimAccount *acct;
-- GaimConnection *gc;
-+ Gaim2Account *acct;
-+ Gaim2Connection *gc;
-
- char *msgA, *msgB;
-
-@@ -3309,26 +3309,26 @@ static void blist_menu_conf_create(GaimB
- acct = buddy->account;
- g_return_if_fail(acct != NULL);
-
-- gc = gaim_account_get_connection(acct);
-+ gc = gaim2_account_get_connection(acct);
- g_return_if_fail(gc != NULL);
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, g);
-+ g = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, g);
-
-- f = gaim_request_field_string_new(CHAT_KEY_TOPIC, _("Topic"), NULL, FALSE);
-- gaim_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new(CHAT_KEY_TOPIC, _("Topic"), NULL, FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-
-- f = gaim_request_field_string_new(CHAT_KEY_INVITE, _("Message"), msg, FALSE);
-- gaim_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new(CHAT_KEY_INVITE, _("Message"), msg, FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-
- msgA = _("Create conference with user");
- msgB = _("Please enter a topic for the new conference, and an invitation"
- " message to be sent to %s");
- msgB = g_strdup_printf(msgB, buddy->name);
-
-- gaim_request_fields(gc, _("New Conference"),
-+ gaim2_request_fields(gc, _("New Conference"),
- msgA, msgB, fields,
- _("Create"), G_CALLBACK(conf_create_prompt_join),
- _("Cancel"), G_CALLBACK(conf_create_prompt_cancel),
-@@ -3337,26 +3337,26 @@ static void blist_menu_conf_create(GaimB
- }
-
-
--static void conf_select_prompt_cancel(GaimBuddy *buddy,
-- GaimRequestFields *fields) {
-+static void conf_select_prompt_cancel(Gaim2Buddy *buddy,
-+ Gaim2RequestFields *fields) {
- ;
- }
-
-
--static void conf_select_prompt_invite(GaimBuddy *buddy,
-- GaimRequestFields *fields) {
-- GaimRequestField *f;
-+static void conf_select_prompt_invite(Gaim2Buddy *buddy,
-+ Gaim2RequestFields *fields) {
-+ Gaim2RequestField *f;
- const GList *l;
- const char *msg;
-
-- f = gaim_request_fields_get_field(fields, CHAT_KEY_INVITE);
-- msg = gaim_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, CHAT_KEY_INVITE);
-+ msg = gaim2_request_field_string_get_value(f);
-
-- f = gaim_request_fields_get_field(fields, "conf");
-- l = gaim_request_field_list_get_selected(f);
-+ f = gaim2_request_fields_get_field(fields, "conf");
-+ l = gaim2_request_field_list_get_selected(f);
-
- if(l) {
-- gpointer d = gaim_request_field_list_get_data(f, l->data);
-+ gpointer d = gaim2_request_field_list_get_data(f, l->data);
-
- if(GPOINTER_TO_INT(d) == 0x01) {
- blist_menu_conf_create(buddy, msg);
-@@ -3369,41 +3369,41 @@ static void conf_select_prompt_invite(Ga
- }
-
-
--static void blist_menu_conf_list(GaimBuddy *buddy,
-+static void blist_menu_conf_list(Gaim2Buddy *buddy,
- GList *confs) {
-
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
-
-- GaimAccount *acct;
-- GaimConnection *gc;
-+ Gaim2Account *acct;
-+ Gaim2Connection *gc;
-
- char *msgA, *msgB;
-
- acct = buddy->account;
- g_return_if_fail(acct != NULL);
-
-- gc = gaim_account_get_connection(acct);
-+ gc = gaim2_account_get_connection(acct);
- g_return_if_fail(gc != NULL);
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, g);
-+ g = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, g);
-
-- f = gaim_request_field_list_new("conf", _("Available Conferences"));
-- gaim_request_field_list_set_multi_select(f, FALSE);
-+ f = gaim2_request_field_list_new("conf", _("Available Conferences"));
-+ gaim2_request_field_list_set_multi_select(f, FALSE);
- for(; confs; confs = confs->next) {
- struct mwConference *c = confs->data;
-- gaim_request_field_list_add(f, mwConference_getTitle(c), c);
-+ gaim2_request_field_list_add(f, mwConference_getTitle(c), c);
- }
-- gaim_request_field_list_add(f, _("Create New Conference..."),
-+ gaim2_request_field_list_add(f, _("Create New Conference..."),
- GINT_TO_POINTER(0x01));
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_group_add_field(g, f);
-
-- f = gaim_request_field_string_new(CHAT_KEY_INVITE, "Message", NULL, FALSE);
-- gaim_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new(CHAT_KEY_INVITE, "Message", NULL, FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-
- msgA = _("Invite user to a conference");
- msgB = _("Select a conference from the list below to send an invite to"
-@@ -3411,7 +3411,7 @@ static void blist_menu_conf_list(GaimBud
- " create a new conference to invite this user to.");
- msgB = g_strdup_printf(msgB, buddy->name);
-
-- gaim_request_fields(gc, _("Invite to Conference"),
-+ gaim2_request_fields(gc, _("Invite to Conference"),
- msgA, msgB, fields,
- _("Invite"), G_CALLBACK(conf_select_prompt_invite),
- _("Cancel"), G_CALLBACK(conf_select_prompt_cancel),
-@@ -3420,11 +3420,11 @@ static void blist_menu_conf_list(GaimBud
- }
-
-
--static void blist_menu_conf(GaimBlistNode *node, gpointer data) {
-- GaimBuddy *buddy = (GaimBuddy *) node;
-- GaimAccount *acct;
-- GaimConnection *gc;
-- struct mwGaimPluginData *pd;
-+static void blist_menu_conf(Gaim2BlistNode *node, gpointer data) {
-+ Gaim2Buddy *buddy = (Gaim2Buddy *) node;
-+ Gaim2Account *acct;
-+ Gaim2Connection *gc;
-+ struct mwGaim2PluginData *pd;
- GList *l;
-
- g_return_if_fail(node != NULL);
-@@ -3433,7 +3433,7 @@ static void blist_menu_conf(GaimBlistNod
- acct = buddy->account;
- g_return_if_fail(acct != NULL);
-
-- gc = gaim_account_get_connection(acct);
-+ gc = gaim2_account_get_connection(acct);
- g_return_if_fail(gc != NULL);
-
- pd = gc->proto_data;
-@@ -3456,20 +3456,20 @@ static void blist_menu_conf(GaimBlistNod
- }
-
-
--static GList *mw_prpl_blist_node_menu(GaimBlistNode *node) {
-+static GList *mw_prpl_blist_node_menu(Gaim2BlistNode *node) {
- GList *l = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
- if(! GAIM_BLIST_NODE_IS_BUDDY(node))
- return l;
-
- l = g_list_append(l, NULL);
-
-- act = gaim_blist_node_action_new(_("Invite to Conference..."),
-+ act = gaim2_blist_node_action_new(_("Invite to Conference..."),
- blist_menu_conf, NULL, NULL);
- l = g_list_append(l, act);
-
-- /** note: this never gets called for a GaimGroup, have to use the
-+ /** note: this never gets called for a Gaim2Group, have to use the
- blist-node-extended-menu signal for that. The function
- blist_node_menu_cb is assigned to this signal in the function
- services_starting */
-@@ -3478,7 +3478,7 @@ static GList *mw_prpl_blist_node_menu(Ga
- }
-
-
--static GList *mw_prpl_chat_info(GaimConnection *gc) {
-+static GList *mw_prpl_chat_info(Gaim2Connection *gc) {
- GList *l = NULL;
- struct proto_chat_entry *pce;
-
-@@ -3491,7 +3491,7 @@ static GList *mw_prpl_chat_info(GaimConn
- }
-
-
--static GHashTable *mw_prpl_chat_info_defaults(GaimConnection *gc,
-+static GHashTable *mw_prpl_chat_info_defaults(Gaim2Connection *gc,
- const char *name) {
- GHashTable *table;
-
-@@ -3507,18 +3507,18 @@ static GHashTable *mw_prpl_chat_info_def
- }
-
-
--static void mw_prpl_login(GaimAccount *acct);
-+static void mw_prpl_login(Gaim2Account *acct);
-
-
--static void prompt_host_cancel_cb(GaimConnection *gc) {
-- gaim_connection_error(gc, _("No Sametime Community Server specified"));
-+static void prompt_host_cancel_cb(Gaim2Connection *gc) {
-+ gaim2_connection_error(gc, _("No Sametime Community Server specified"));
- }
-
-
--static void prompt_host_ok_cb(GaimConnection *gc, const char *host) {
-+static void prompt_host_ok_cb(Gaim2Connection *gc, const char *host) {
- if(host && *host) {
-- GaimAccount *acct = gaim_connection_get_account(gc);
-- gaim_account_set_string(acct, MW_KEY_HOST, host);
-+ Gaim2Account *acct = gaim2_connection_get_account(gc);
-+ gaim2_account_set_string(acct, MW_KEY_HOST, host);
- mw_prpl_login(acct);
-
- } else {
-@@ -3527,17 +3527,17 @@ static void prompt_host_ok_cb(GaimConnec
- }
-
-
--static void prompt_host(GaimConnection *gc) {
-- GaimAccount *acct;
-+static void prompt_host(Gaim2Connection *gc) {
-+ Gaim2Account *acct;
- char *msg;
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- msg = _("No host or IP address has been configured for the"
- " Meanwhile account %s. Please enter one below to"
- " continue logging in.");
-- msg = g_strdup_printf(msg, NSTR(gaim_account_get_username(acct)));
-+ msg = g_strdup_printf(msg, NSTR(gaim2_account_get_username(acct)));
-
-- gaim_request_input(gc, _("Meanwhile Connection Setup"),
-+ gaim2_request_input(gc, _("Meanwhile Connection Setup"),
- _("No Sametime Community Server Specified"), msg,
- MW_PLUGIN_DEFAULT_HOST, FALSE, FALSE, NULL,
- _("Connect"), G_CALLBACK(prompt_host_ok_cb),
-@@ -3548,31 +3548,31 @@ static void prompt_host(GaimConnection *
- }
-
-
--static void mw_prpl_login(GaimAccount *account) {
-- GaimConnection *gc;
-- struct mwGaimPluginData *pd;
-+static void mw_prpl_login(Gaim2Account *account) {
-+ Gaim2Connection *gc;
-+ struct mwGaim2PluginData *pd;
-
- char *user, *pass, *host;
- guint port, client;
-
-- gc = gaim_account_get_connection(account);
-- pd = mwGaimPluginData_new(gc);
-+ gc = gaim2_account_get_connection(account);
-+ pd = mwGaim2PluginData_new(gc);
-
- /* while we do support images, the default is to not offer it */
- gc->flags |= GAIM_CONNECTION_NO_IMAGES;
-
-- user = g_strdup(gaim_account_get_username(account));
-- pass = g_strdup(gaim_account_get_password(account));
-+ user = g_strdup(gaim2_account_get_username(account));
-+ pass = g_strdup(gaim2_account_get_password(account));
-
- host = strrchr(user, ':');
- if(host) {
- /* annoying user split from 1.2.0, need to undo it */
- *host++ = '\0';
-- gaim_account_set_string(account, MW_KEY_HOST, host);
-- gaim_account_set_username(account, user);
-+ gaim2_account_set_string(account, MW_KEY_HOST, host);
-+ gaim2_account_set_username(account, user);
-
- } else {
-- host = (char *) gaim_account_get_string(account, MW_KEY_HOST,
-+ host = (char *) gaim2_account_get_string(account, MW_KEY_HOST,
- MW_PLUGIN_DEFAULT_HOST);
- }
-
-@@ -3583,7 +3583,7 @@ static void mw_prpl_login(GaimAccount *a
- return;
- }
-
-- port = gaim_account_get_int(account, MW_KEY_PORT, MW_PLUGIN_DEFAULT_PORT);
-+ port = gaim2_account_get_int(account, MW_KEY_PORT, MW_PLUGIN_DEFAULT_PORT);
-
- DEBUG_INFO("user: '%s'\n", user);
- DEBUG_INFO("host: '%s'\n", host);
-@@ -3595,7 +3595,7 @@ static void mw_prpl_login(GaimAccount *a
- mwSession_setProperty(pd->session, mwSession_AUTH_PASSWORD, pass, g_free);
-
- client = mwLogin_MEANWHILE;
-- if(gaim_account_get_bool(account, MW_KEY_FAKE_IT, FALSE))
-+ if(gaim2_account_get_bool(account, MW_KEY_FAKE_IT, FALSE))
- client = mwLogin_BINARY;
-
- DEBUG_INFO("client id: 0x%04x\n", client);
-@@ -3603,16 +3603,16 @@ static void mw_prpl_login(GaimAccount *a
- mwSession_setProperty(pd->session, mwSession_CLIENT_TYPE_ID,
- GUINT_TO_POINTER(client), NULL);
-
-- gaim_connection_update_progress(gc, _("Connecting"), 1, MW_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 1, MW_CONNECT_STEPS);
-
-- if(gaim_proxy_connect(account, host, port, connect_cb, pd)) {
-- gaim_connection_error(gc, _("Unable to connect to host"));
-+ if(gaim2_proxy_connect(account, host, port, connect_cb, pd)) {
-+ gaim2_connection_error(gc, _("Unable to connect to host"));
- }
- }
-
-
--static void mw_prpl_close(GaimConnection *gc) {
-- struct mwGaimPluginData *pd;
-+static void mw_prpl_close(Gaim2Connection *gc) {
-+ struct mwGaim2PluginData *pd;
-
- g_return_if_fail(gc != NULL);
-
-@@ -3621,7 +3621,7 @@ static void mw_prpl_close(GaimConnection
-
- /* get rid of the blist save timeout */
- if(pd->save_event) {
-- gaim_timeout_remove(pd->save_event);
-+ gaim2_timeout_remove(pd->save_event);
- pd->save_event = 0;
- blist_store(pd);
- }
-@@ -3634,12 +3634,12 @@ static void mw_prpl_close(GaimConnection
-
- /* stop watching the socket */
- if(gc->inpa) {
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
- gc->inpa = 0;
- }
-
- /* clean up the rest */
-- mwGaimPluginData_free(pd);
-+ mwGaim2PluginData_free(pd);
- }
-
-
-@@ -3662,8 +3662,8 @@ static char *im_mime_content_type() {
-
- /** determine content type from extension. Not so happy about this,
- but I don't want to actually write image type detection */
--static char *im_mime_img_content_type(GaimStoredImage *img) {
-- const char *fn = gaim_imgstore_get_filename(img);
-+static char *im_mime_img_content_type(Gaim2StoredImage *img) {
-+ const char *fn = gaim2_imgstore_get_filename(img);
- const char *ct = NULL;
-
- ct = strrchr(fn, '.');
-@@ -3690,22 +3690,22 @@ static char *im_mime_img_content_type(Ga
- }
-
-
--static char *im_mime_img_content_disp(GaimStoredImage *img) {
-- const char *fn = gaim_imgstore_get_filename(img);
-+static char *im_mime_img_content_disp(Gaim2StoredImage *img) {
-+ const char *fn = gaim2_imgstore_get_filename(img);
- return g_strdup_printf("attachment; filename=\"%s\"", fn);
- }
-
-
--static char *nb_im_encode(GaimConnection *gc, const char *message) {
-- GaimAccount *acct;
-+static char *nb_im_encode(Gaim2Connection *gc, const char *message) {
-+ Gaim2Account *acct;
- const char *enc;
- char *ret;
- GError *error = NULL;
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_val_if_fail(acct != NULL, NULL);
-
-- enc = gaim_account_get_string(acct, MW_KEY_ENCODING,
-+ enc = gaim2_account_get_string(acct, MW_KEY_ENCODING,
- MW_PLUGIN_DEFAULT_ENCODING);
- g_return_val_if_fail(enc != NULL, NULL);
-
-@@ -3743,32 +3743,32 @@ static gboolean is_nb(struct mwConversat
-
-
- /** turn an IM with embedded images into a multi-part mime document */
--static char *im_mime_convert(GaimConnection *gc,
-+static char *im_mime_convert(Gaim2Connection *gc,
- struct mwConversation *conv,
- const char *message) {
- GString *str;
-- GaimMimeDocument *doc;
-- GaimMimePart *part;
-+ Gaim2MimeDocument *doc;
-+ Gaim2MimePart *part;
-
- GData *attr;
- char *tmp, *start, *end;
-
- str = g_string_new(NULL);
-
-- doc = gaim_mime_document_new();
-+ doc = gaim2_mime_document_new();
-
-- gaim_mime_document_set_field(doc, "Mime-Version", "1.0");
-- gaim_mime_document_set_field(doc, "Content-Disposition", "inline");
-+ gaim2_mime_document_set_field(doc, "Mime-Version", "1.0");
-+ gaim2_mime_document_set_field(doc, "Content-Disposition", "inline");
-
- tmp = im_mime_content_type();
-- gaim_mime_document_set_field(doc, "Content-Type", tmp);
-+ gaim2_mime_document_set_field(doc, "Content-Type", tmp);
- g_free(tmp);
-
- tmp = (char *) message;
-- while(*tmp && gaim_markup_find_tag("img", tmp, (const char **) &start,
-+ while(*tmp && gaim2_markup_find_tag("img", tmp, (const char **) &start,
- (const char **) &end, &attr)) {
- char *id;
-- GaimStoredImage *img = NULL;
-+ Gaim2StoredImage *img = NULL;
-
- gsize len = (start - tmp);
-
-@@ -3778,36 +3778,36 @@ static char *im_mime_convert(GaimConnect
- /* find the imgstore data by the id tag */
- id = g_datalist_get_data(&attr, "id");
- if(id && *id)
-- img = gaim_imgstore_get(atoi(id));
-+ img = gaim2_imgstore_get(atoi(id));
-
- if(img) {
- char *cid;
- gpointer data;
- size_t size;
-
-- part = gaim_mime_part_new(doc);
-+ part = gaim2_mime_part_new(doc);
-
- data = im_mime_img_content_disp(img);
-- gaim_mime_part_set_field(part, "Content-Disposition", data);
-+ gaim2_mime_part_set_field(part, "Content-Disposition", data);
- g_free(data);
-
- data = im_mime_img_content_type(img);
-- gaim_mime_part_set_field(part, "Content-Type", data);
-+ gaim2_mime_part_set_field(part, "Content-Type", data);
- g_free(data);
-
- cid = im_mime_content_id();
- data = g_strdup_printf("<%s>", cid);
-- gaim_mime_part_set_field(part, "Content-ID", data);
-+ gaim2_mime_part_set_field(part, "Content-ID", data);
- g_free(data);
-
-- gaim_mime_part_set_field(part, "Content-transfer-encoding", "base64");
-+ gaim2_mime_part_set_field(part, "Content-transfer-encoding", "base64");
-
- /* obtain and base64 encode the image data, and put it in the
- mime part */
-- data = gaim_imgstore_get_data(img);
-- size = gaim_imgstore_get_size(img);
-- data = gaim_base64_encode(data, (gsize) size);
-- gaim_mime_part_set_data(part, data);
-+ data = gaim2_imgstore_get_data(img);
-+ size = gaim2_imgstore_get_size(img);
-+ data = gaim2_base64_encode(data, (gsize) size);
-+ gaim2_mime_part_set_data(part, data);
- g_free(data);
-
- /* append the modified tag */
-@@ -3829,34 +3829,34 @@ static char *im_mime_convert(GaimConnect
- g_string_append(str, tmp);
-
- /* add the text/html part */
-- part = gaim_mime_part_new(doc);
-- gaim_mime_part_set_field(part, "Content-Disposition", "inline");
-+ part = gaim2_mime_part_new(doc);
-+ gaim2_mime_part_set_field(part, "Content-Disposition", "inline");
-
- if(is_nb(conv)) {
-- GaimAccount *acct = gaim_connection_get_account(gc);
-+ Gaim2Account *acct = gaim2_connection_get_account(gc);
-
-- tmp = (char *) gaim_account_get_string(acct, MW_KEY_ENCODING,
-+ tmp = (char *) gaim2_account_get_string(acct, MW_KEY_ENCODING,
- MW_PLUGIN_DEFAULT_ENCODING);
- tmp = g_strdup_printf("text/html; charset=\"%s\"", tmp);
-- gaim_mime_part_set_field(part, "Content-Type", tmp);
-+ gaim2_mime_part_set_field(part, "Content-Type", tmp);
- g_free(tmp);
-
-- gaim_mime_part_set_field(part, "Content-Transfer-Encoding", "7bit");
-+ gaim2_mime_part_set_field(part, "Content-Transfer-Encoding", "7bit");
-
- tmp = nb_im_encode(gc, str->str);
-- gaim_mime_part_set_data(part, tmp);
-+ gaim2_mime_part_set_data(part, tmp);
- g_free(tmp);
-
- } else {
-- gaim_mime_part_set_field(part, "Content-Type", "text/html");
-- gaim_mime_part_set_field(part, "Content-Transfer-Encoding", "8bit");
-- gaim_mime_part_set_data(part, str->str);
-+ gaim2_mime_part_set_field(part, "Content-Type", "text/html");
-+ gaim2_mime_part_set_field(part, "Content-Transfer-Encoding", "8bit");
-+ gaim2_mime_part_set_data(part, str->str);
- }
-
- g_string_free(str, TRUE);
-
- str = g_string_new(NULL);
-- gaim_mime_document_write(doc, str);
-+ gaim2_mime_document_write(doc, str);
- tmp = str->str;
- g_string_free(str, FALSE);
-
-@@ -3864,12 +3864,12 @@ static char *im_mime_convert(GaimConnect
- }
-
-
--static int mw_prpl_send_im(GaimConnection *gc,
-+static int mw_prpl_send_im(Gaim2Connection *gc,
- const char *name,
- const char *message,
-- GaimMessageFlags flags) {
-+ Gaim2MessageFlags flags) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwIdBlock who = { (char *) name, NULL };
- struct mwConversation *conv;
-
-@@ -3910,12 +3910,12 @@ static int mw_prpl_send_im(GaimConnectio
-
- /* html messages need the notesbuddy hack */
- char *msg = nb_im_encode(gc, message);
-- tmp = gaim_strdup_withhtml(msg);
-+ tmp = gaim2_strdup_withhtml(msg);
- g_free(msg);
-
- } else {
- /* need to do this to get the \n to <br> conversion */
-- tmp = gaim_strdup_withhtml(message);
-+ tmp = gaim2_strdup_withhtml(message);
- }
-
- ret = mwConversation_send(conv, mwImSend_HTML, tmp);
-@@ -3923,7 +3923,7 @@ static int mw_prpl_send_im(GaimConnectio
-
- } else {
- /* default to text */
-- tmp = gaim_markup_strip_html(message);
-+ tmp = gaim2_markup_strip_html(message);
- ret = mwConversation_send(conv, mwImSend_PLAIN, tmp);
- g_free(tmp);
- }
-@@ -3933,7 +3933,7 @@ static int mw_prpl_send_im(GaimConnectio
- } else {
-
- /* queue up the message safely as plain text */
-- char *tmp = gaim_markup_strip_html(message);
-+ char *tmp = gaim2_markup_strip_html(message);
- convo_queue(conv, mwImSend_PLAIN, tmp);
- g_free(tmp);
-
-@@ -3945,10 +3945,10 @@ static int mw_prpl_send_im(GaimConnectio
- }
-
-
--static int mw_prpl_send_typing(GaimConnection *gc, const char *name,
-+static int mw_prpl_send_typing(Gaim2Connection *gc, const char *name,
- int typing) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwIdBlock who = { (char *) name, NULL };
- struct mwConversation *conv;
-
-@@ -4032,13 +4032,13 @@ static const char *mw_client_name(guint1
- }
-
-
--static void mw_prpl_get_info(GaimConnection *gc, const char *who) {
-+static void mw_prpl_get_info(Gaim2Connection *gc, const char *who) {
-
- struct mwAwareIdBlock idb = { mwAware_USER, (char *) who, NULL };
-
-- struct mwGaimPluginData *pd;
-- GaimAccount *acct;
-- GaimBuddy *b;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Account *acct;
-+ Gaim2Buddy *b;
-
- GString *str;
- const char *tmp;
-@@ -4048,12 +4048,12 @@ static void mw_prpl_get_info(GaimConnect
-
- pd = gc->proto_data;
-
-- acct = gaim_connection_get_account(gc);
-- b = gaim_find_buddy(acct, who);
-+ acct = gaim2_connection_get_account(gc);
-+ b = gaim2_find_buddy(acct, who);
-
- str = g_string_new(NULL);
-
-- if(gaim_str_has_prefix(who, "@E ")) {
-+ if(gaim2_str_has_prefix(who, "@E ")) {
- g_string_append(str, _("<b>External User</b><br>"));
- }
-
-@@ -4067,7 +4067,7 @@ static void mw_prpl_get_info(GaimConnect
- b->server_alias);
- }
-
-- type = gaim_blist_node_get_int((GaimBlistNode *) b, BUDDY_KEY_CLIENT);
-+ type = gaim2_blist_node_get_int((Gaim2BlistNode *) b, BUDDY_KEY_CLIENT);
- if(type) {
- g_string_append(str, _("<b>Last Known Client:</b> "));
-
-@@ -4105,25 +4105,25 @@ static void mw_prpl_get_info(GaimConnect
- /* @todo emit a signal to allow a plugin to override the display of
- this notification, so that it can create its own */
-
-- gaim_notify_userinfo(gc, who, str->str, NULL, NULL);
-+ gaim2_notify_userinfo(gc, who, str->str, NULL, NULL);
-
- g_string_free(str, TRUE);
- }
-
-
--static void mw_prpl_set_status(GaimAccount *acct, GaimStatus *status) {
-- GaimConnection *gc;
-+static void mw_prpl_set_status(Gaim2Account *acct, Gaim2Status *status) {
-+ Gaim2Connection *gc;
- const char *state;
- char *message = NULL;
- struct mwSession *session;
- struct mwUserStatus stat;
-
- g_return_if_fail(acct != NULL);
-- gc = gaim_account_get_connection(acct);
-+ gc = gaim2_account_get_connection(acct);
-
-- state = gaim_status_get_id(status);
-+ state = gaim2_status_get_id(status);
-
-- DEBUG_INFO("Set status to %s\n", gaim_status_get_name(status));
-+ DEBUG_INFO("Set status to %s\n", gaim2_status_get_name(status));
-
- g_return_if_fail(gc != NULL);
-
-@@ -4145,12 +4145,12 @@ static void mw_prpl_set_status(GaimAccou
- }
-
- /* determine the message */
-- message = (char *) gaim_status_get_attr_string(status, MW_STATE_MESSAGE);
-+ message = (char *) gaim2_status_get_attr_string(status, MW_STATE_MESSAGE);
-
- if(message) {
- /* all the possible non-NULL values of message up to this point
- are const, so we don't need to free them */
-- message = gaim_markup_strip_html(message);
-+ message = gaim2_markup_strip_html(message);
- }
-
- /* out with the old */
-@@ -4164,7 +4164,7 @@ static void mw_prpl_set_status(GaimAccou
- }
-
-
--static void mw_prpl_set_idle(GaimConnection *gc, int t) {
-+static void mw_prpl_set_idle(Gaim2Connection *gc, int t) {
- struct mwSession *session;
- struct mwUserStatus stat;
-
-@@ -4196,21 +4196,21 @@ static void mw_prpl_set_idle(GaimConnect
- }
-
-
--static void notify_im(GaimConnection *gc, GList *row) {
-- GaimAccount *acct;
-- GaimConversation *conv;
-+static void notify_im(Gaim2Connection *gc, GList *row) {
-+ Gaim2Account *acct;
-+ Gaim2Conversation *conv;
- char *id;
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- id = g_list_nth_data(row, 1);
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, id, acct);
-- if(! conv) conv = gaim_conversation_new(GAIM_CONV_TYPE_IM, acct, id);
-- gaim_conversation_present(conv);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, id, acct);
-+ if(! conv) conv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, acct, id);
-+ gaim2_conversation_present(conv);
- }
-
-
--static void notify_add(GaimConnection *gc, GList *row) {
-- gaim_blist_request_add_buddy(gaim_connection_get_account(gc),
-+static void notify_add(Gaim2Connection *gc, GList *row) {
-+ gaim2_blist_request_add_buddy(gaim2_connection_get_account(gc),
- g_list_nth_data(row, 1), NULL,
- g_list_nth_data(row, 0));
- }
-@@ -4222,25 +4222,25 @@ static void notify_close(gpointer data)
-
-
- static void multi_resolved_query(struct mwResolveResult *result,
-- GaimConnection *gc) {
-+ Gaim2Connection *gc) {
- GList *l;
- char *msgA, *msgB;
-
-- GaimNotifySearchResults *sres;
-- GaimNotifySearchColumn *scol;
-+ Gaim2NotifySearchResults *sres;
-+ Gaim2NotifySearchColumn *scol;
-
-- sres = gaim_notify_searchresults_new();
-+ sres = gaim2_notify_searchresults_new();
-
-- scol = gaim_notify_searchresults_column_new(_("User Name"));
-- gaim_notify_searchresults_column_add(sres, scol);
-+ scol = gaim2_notify_searchresults_column_new(_("User Name"));
-+ gaim2_notify_searchresults_column_add(sres, scol);
-
-- scol = gaim_notify_searchresults_column_new(_("Sametime ID"));
-- gaim_notify_searchresults_column_add(sres, scol);
-+ scol = gaim2_notify_searchresults_column_new(_("Sametime ID"));
-+ gaim2_notify_searchresults_column_add(sres, scol);
-
-- gaim_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_IM,
-+ gaim2_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_IM,
- notify_im);
-
-- gaim_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_ADD,
-+ gaim2_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_ADD,
- notify_add);
-
- for(l = result->matches; l; l = l->next) {
-@@ -4255,7 +4255,7 @@ static void multi_resolved_query(struct
-
- row = g_list_append(row, g_strdup(match->name));
- row = g_list_append(row, g_strdup(match->id));
-- gaim_notify_searchresults_row_add(sres, row);
-+ gaim2_notify_searchresults_row_add(sres, row);
- }
-
- msgA = _("An ambiguous user ID was entered");
-@@ -4264,7 +4264,7 @@ static void multi_resolved_query(struct
- " add them to your buddy list.");
- msgB = g_strdup_printf(msgB, result->name);
-
-- gaim_notify_searchresults(gc, _("Select User"),
-+ gaim2_notify_searchresults(gc, _("Select User"),
- msgA, msgB, sres, notify_close, NULL);
-
- g_free(msgB);
-@@ -4276,11 +4276,11 @@ static void add_buddy_resolved(struct mw
- gpointer b) {
-
- struct mwResolveResult *res = NULL;
-- GaimBuddy *buddy = b;
-- GaimConnection *gc;
-- struct mwGaimPluginData *pd;
-+ Gaim2Buddy *buddy = b;
-+ Gaim2Connection *gc;
-+ struct mwGaim2PluginData *pd;
-
-- gc = gaim_account_get_connection(buddy->account);
-+ gc = gaim2_account_get_connection(buddy->account);
- pd = gc->proto_data;
-
- if(results)
-@@ -4295,20 +4295,20 @@ static void add_buddy_resolved(struct mw
- /* uh oh, the single result isn't identical to the search
- term, better safe then sorry, so let's make sure it's who
- the user meant to add */
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- multi_resolved_query(res, gc);
-
- } else {
- /* same person, set the server alias */
-- gaim_blist_server_alias_buddy(buddy, match->name);
-- gaim_blist_node_set_string((GaimBlistNode *) buddy,
-+ gaim2_blist_server_alias_buddy(buddy, match->name);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *) buddy,
- BUDDY_KEY_NAME, match->name);
- blist_schedule(pd);
- }
-
- } else {
- /* prompt user if more than one match was returned */
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- multi_resolved_query(res, gc);
- }
-
-@@ -4320,7 +4320,7 @@ static void add_buddy_resolved(struct mw
- this buddy */
-
- DEBUG_INFO("no such buddy in community\n");
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- blist_schedule(pd);
-
- if(res && res->name) {
-@@ -4334,18 +4334,18 @@ static void add_buddy_resolved(struct mw
- " your buddy list.");
- msgB = g_strdup_printf(msgB, NSTR(res->name));
-
-- gaim_notify_error(gc, _("Unable to add user"), msgA, msgB);
-+ gaim2_notify_error(gc, _("Unable to add user"), msgA, msgB);
-
- g_free(msgB);
- }
- }
-
-
--static void mw_prpl_add_buddy(GaimConnection *gc,
-- GaimBuddy *buddy,
-- GaimGroup *group) {
-+static void mw_prpl_add_buddy(Gaim2Connection *gc,
-+ Gaim2Buddy *buddy,
-+ Gaim2Group *group) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwServiceResolve *srvc;
- GList *query;
- enum mwResolveFlag flags;
-@@ -4368,14 +4368,14 @@ static void mw_prpl_add_buddy(GaimConnec
- g_list_free(query);
-
- if(req == SEARCH_ERROR) {
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- blist_schedule(pd);
- }
- }
-
-
--static void foreach_add_buddies(GaimGroup *group, GList *buddies,
-- struct mwGaimPluginData *pd) {
-+static void foreach_add_buddies(Gaim2Group *group, GList *buddies,
-+ struct mwGaim2PluginData *pd) {
- struct mwAwareList *list;
-
- list = list_ensure(pd, group);
-@@ -4384,17 +4384,17 @@ static void foreach_add_buddies(GaimGrou
- }
-
-
--static void mw_prpl_add_buddies(GaimConnection *gc,
-+static void mw_prpl_add_buddies(Gaim2Connection *gc,
- GList *buddies,
- GList *groups) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- GHashTable *group_sets;
- struct mwAwareIdBlock *idbs, *idb;
-
- pd = gc->proto_data;
-
-- /* map GaimGroup:GList of mwAwareIdBlock */
-+ /* map Gaim2Group:GList of mwAwareIdBlock */
- group_sets = g_hash_table_new(g_direct_hash, g_direct_equal);
-
- /* bunch of mwAwareIdBlock allocated at once, free'd at once */
-@@ -4402,22 +4402,22 @@ static void mw_prpl_add_buddies(GaimConn
-
- /* first pass collects mwAwareIdBlock lists for each group */
- for(; buddies; buddies = buddies->next) {
-- GaimBuddy *b = buddies->data;
-- GaimGroup *g;
-+ Gaim2Buddy *b = buddies->data;
-+ Gaim2Group *g;
- const char *fn;
- GList *l;
-
- /* nab the saved server alias and stick it on the buddy */
-- fn = gaim_blist_node_get_string((GaimBlistNode *) b, BUDDY_KEY_NAME);
-- gaim_blist_server_alias_buddy(b, fn);
-+ fn = gaim2_blist_node_get_string((Gaim2BlistNode *) b, BUDDY_KEY_NAME);
-+ gaim2_blist_server_alias_buddy(b, fn);
-
-- /* convert GaimBuddy into a mwAwareIdBlock */
-+ /* convert Gaim2Buddy into a mwAwareIdBlock */
- idb->type = mwAware_USER;
- idb->user = (char *) b->name;
- idb->community = NULL;
-
- /* put idb into the list associated with the buddy's group */
-- g = gaim_buddy_get_group(b);
-+ g = gaim2_buddy_get_group(b);
- l = g_hash_table_lookup(group_sets, g);
- l = g_list_prepend(l, idb++);
- g_hash_table_insert(group_sets, g, l);
-@@ -4434,17 +4434,17 @@ static void mw_prpl_add_buddies(GaimConn
- }
-
-
--static void mw_prpl_remove_buddy(GaimConnection *gc,
-- GaimBuddy *buddy, GaimGroup *group) {
-+static void mw_prpl_remove_buddy(Gaim2Connection *gc,
-+ Gaim2Buddy *buddy, Gaim2Group *group) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwAwareIdBlock idb = { mwAware_USER, buddy->name, NULL };
- struct mwAwareList *list;
-
- GList *rem = g_list_prepend(NULL, &idb);
-
- pd = gc->proto_data;
-- group = gaim_buddy_get_group(buddy);
-+ group = gaim2_buddy_get_group(buddy);
- list = list_ensure(pd, group);
-
- mwAwareList_removeAware(list, rem);
-@@ -4474,9 +4474,9 @@ static void privacy_fill(struct mwPrivac
- }
-
-
--static void mw_prpl_set_permit_deny(GaimConnection *gc) {
-- GaimAccount *acct;
-- struct mwGaimPluginData *pd;
-+static void mw_prpl_set_permit_deny(Gaim2Connection *gc) {
-+ Gaim2Account *acct;
-+ struct mwGaim2PluginData *pd;
- struct mwSession *session;
-
- struct mwPrivacyInfo privacy = {
-@@ -4487,7 +4487,7 @@ static void mw_prpl_set_permit_deny(Gaim
-
- g_return_if_fail(gc != NULL);
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_if_fail(acct != NULL);
-
- pd = gc->proto_data;
-@@ -4529,22 +4529,22 @@ static void mw_prpl_set_permit_deny(Gaim
- }
-
-
--static void mw_prpl_add_permit(GaimConnection *gc, const char *name) {
-+static void mw_prpl_add_permit(Gaim2Connection *gc, const char *name) {
- mw_prpl_set_permit_deny(gc);
- }
-
-
--static void mw_prpl_add_deny(GaimConnection *gc, const char *name) {
-+static void mw_prpl_add_deny(Gaim2Connection *gc, const char *name) {
- mw_prpl_set_permit_deny(gc);
- }
-
-
--static void mw_prpl_rem_permit(GaimConnection *gc, const char *name) {
-+static void mw_prpl_rem_permit(Gaim2Connection *gc, const char *name) {
- mw_prpl_set_permit_deny(gc);
- }
-
-
--static void mw_prpl_rem_deny(GaimConnection *gc, const char *name) {
-+static void mw_prpl_rem_deny(Gaim2Connection *gc, const char *name) {
- mw_prpl_set_permit_deny(gc);
- }
-
-@@ -4568,10 +4568,10 @@ static struct mwConference *conf_find(st
- }
-
-
--static void mw_prpl_join_chat(GaimConnection *gc,
-+static void mw_prpl_join_chat(Gaim2Connection *gc,
- GHashTable *components) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- char *c, *t;
-
- pd = gc->proto_data;
-@@ -4609,10 +4609,10 @@ static void mw_prpl_join_chat(GaimConnec
- }
-
-
--static void mw_prpl_reject_chat(GaimConnection *gc,
-+static void mw_prpl_reject_chat(Gaim2Connection *gc,
- GHashTable *components) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwServiceConference *srvc;
- char *c;
-
-@@ -4638,12 +4638,12 @@ static char *mw_prpl_get_chat_name(GHash
- }
-
-
--static void mw_prpl_chat_invite(GaimConnection *gc,
-+static void mw_prpl_chat_invite(Gaim2Connection *gc,
- int id,
- const char *invitation,
- const char *who) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwConference *conf;
- struct mwPlace *place;
- struct mwIdBlock idb = { (char *) who, NULL };
-@@ -4666,10 +4666,10 @@ static void mw_prpl_chat_invite(GaimConn
- }
-
-
--static void mw_prpl_chat_leave(GaimConnection *gc,
-+static void mw_prpl_chat_leave(Gaim2Connection *gc,
- int id) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwConference *conf;
-
- pd = gc->proto_data;
-@@ -4689,7 +4689,7 @@ static void mw_prpl_chat_leave(GaimConne
- }
-
-
--static void mw_prpl_chat_whisper(GaimConnection *gc,
-+static void mw_prpl_chat_whisper(Gaim2Connection *gc,
- int id,
- const char *who,
- const char *message) {
-@@ -4698,12 +4698,12 @@ static void mw_prpl_chat_whisper(GaimCon
- }
-
-
--static int mw_prpl_chat_send(GaimConnection *gc,
-+static int mw_prpl_chat_send(Gaim2Connection *gc,
- int id,
- const char *message,
-- GaimMessageFlags flags) {
-+ Gaim2MessageFlags flags) {
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwConference *conf;
-
- pd = gc->proto_data;
-@@ -4723,7 +4723,7 @@ static int mw_prpl_chat_send(GaimConnect
- }
-
-
--static void mw_prpl_keepalive(GaimConnection *gc) {
-+static void mw_prpl_keepalive(Gaim2Connection *gc) {
- struct mwSession *session;
-
- g_return_if_fail(gc != NULL);
-@@ -4735,11 +4735,11 @@ static void mw_prpl_keepalive(GaimConnec
- }
-
-
--static void mw_prpl_alias_buddy(GaimConnection *gc,
-+static void mw_prpl_alias_buddy(Gaim2Connection *gc,
- const char *who,
- const char *alias) {
-
-- struct mwGaimPluginData *pd = gc->proto_data;
-+ struct mwGaim2PluginData *pd = gc->proto_data;
- g_return_if_fail(pd != NULL);
-
- /* it's a change to the buddy list, so we've gotta reflect that in
-@@ -4749,7 +4749,7 @@ static void mw_prpl_alias_buddy(GaimConn
- }
-
-
--static void mw_prpl_group_buddy(GaimConnection *gc,
-+static void mw_prpl_group_buddy(Gaim2Connection *gc,
- const char *who,
- const char *old_group,
- const char *new_group) {
-@@ -4757,17 +4757,17 @@ static void mw_prpl_group_buddy(GaimConn
- struct mwAwareIdBlock idb = { mwAware_USER, (char *) who, NULL };
- GList *gl = g_list_prepend(NULL, &idb);
-
-- struct mwGaimPluginData *pd = gc->proto_data;
-- GaimGroup *group;
-+ struct mwGaim2PluginData *pd = gc->proto_data;
-+ Gaim2Group *group;
- struct mwAwareList *list;
-
- /* add who to new_group's aware list */
-- group = gaim_find_group(new_group);
-+ group = gaim2_find_group(new_group);
- list = list_ensure(pd, group);
- mwAwareList_addAware(list, gl);
-
- /* remove who from old_group's aware list */
-- group = gaim_find_group(old_group);
-+ group = gaim2_find_group(old_group);
- list = list_ensure(pd, group);
- mwAwareList_removeAware(list, gl);
-
-@@ -4778,32 +4778,32 @@ static void mw_prpl_group_buddy(GaimConn
- }
-
-
--static void mw_prpl_rename_group(GaimConnection *gc,
-+static void mw_prpl_rename_group(Gaim2Connection *gc,
- const char *old,
-- GaimGroup *group,
-+ Gaim2Group *group,
- GList *buddies) {
-
-- struct mwGaimPluginData *pd = gc->proto_data;
-+ struct mwGaim2PluginData *pd = gc->proto_data;
- g_return_if_fail(pd != NULL);
-
- /* it's a change in the buddy list, so we've gotta reflect that in
- the server copy. Also, having this function should prevent all
- those buddies from being removed and re-added. We don't really
-- give a crap what the group is named in Gaim other than to record
-+ give a crap what the group is named in Gaim2 other than to record
- that as the group name/alias */
-
- blist_schedule(pd);
- }
-
-
--static void mw_prpl_buddy_free(GaimBuddy *buddy) {
-+static void mw_prpl_buddy_free(Gaim2Buddy *buddy) {
- /* I don't think we have any cleanup for buddies yet */
- ;
- }
-
-
--static void mw_prpl_convo_closed(GaimConnection *gc, const char *who) {
-- struct mwGaimPluginData *pd = gc->proto_data;
-+static void mw_prpl_convo_closed(Gaim2Connection *gc, const char *who) {
-+ struct mwGaim2PluginData *pd = gc->proto_data;
- struct mwServiceIm *srvc;
- struct mwConversation *conv;
- struct mwIdBlock idb = { (char *) who, NULL };
-@@ -4821,7 +4821,7 @@ static void mw_prpl_convo_closed(GaimCon
- }
-
-
--static const char *mw_prpl_normalize(const GaimAccount *account,
-+static const char *mw_prpl_normalize(const Gaim2Account *account,
- const char *id) {
-
- /* code elsewhere assumes that the return value points to different
-@@ -4834,8 +4834,8 @@ static const char *mw_prpl_normalize(con
- }
-
-
--static void mw_prpl_remove_group(GaimConnection *gc, GaimGroup *group) {
-- struct mwGaimPluginData *pd;
-+static void mw_prpl_remove_group(Gaim2Connection *gc, Gaim2Group *group) {
-+ struct mwGaim2PluginData *pd;
- struct mwAwareList *list;
-
- pd = gc->proto_data;
-@@ -4854,11 +4854,11 @@ static void mw_prpl_remove_group(GaimCon
- }
-
-
--static gboolean mw_prpl_can_receive_file(GaimConnection *gc,
-+static gboolean mw_prpl_can_receive_file(Gaim2Connection *gc,
- const char *who) {
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwServiceAware *srvc;
-- GaimAccount *acct;
-+ Gaim2Account *acct;
-
- g_return_val_if_fail(gc != NULL, FALSE);
-
-@@ -4868,19 +4868,19 @@ static gboolean mw_prpl_can_receive_file
- srvc = pd->srvc_aware;
- g_return_val_if_fail(srvc != NULL, FALSE);
-
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
- g_return_val_if_fail(acct != NULL, FALSE);
-
-- return gaim_find_buddy(acct, who) &&
-+ return gaim2_find_buddy(acct, who) &&
- user_supports(srvc, who, mwAttribute_FILE_TRANSFER);
- }
-
-
--static void ft_outgoing_init(GaimXfer *xfer) {
-- GaimAccount *acct;
-- GaimConnection *gc;
-+static void ft_outgoing_init(Gaim2Xfer *xfer) {
-+ Gaim2Account *acct;
-+ Gaim2Connection *gc;
-
-- struct mwGaimPluginData *pd;
-+ struct mwGaim2PluginData *pd;
- struct mwServiceFileTransfer *srvc;
- struct mwFileTransfer *ft;
-
-@@ -4892,13 +4892,13 @@ static void ft_outgoing_init(GaimXfer *x
-
- DEBUG_INFO("ft_outgoing_init\n");
-
-- acct = gaim_xfer_get_account(xfer);
-- gc = gaim_account_get_connection(acct);
-+ acct = gaim2_xfer_get_account(xfer);
-+ gc = gaim2_account_get_connection(acct);
- pd = gc->proto_data;
- srvc = pd->srvc_ft;
-
-- filename = gaim_xfer_get_local_filename(xfer);
-- filesize = gaim_xfer_get_size(xfer);
-+ filename = gaim2_xfer_get_local_filename(xfer);
-+ filesize = gaim2_xfer_get_size(xfer);
- idb.user = xfer->who;
-
- /* test that we can actually send the file */
-@@ -4906,7 +4906,7 @@ static void ft_outgoing_init(GaimXfer *x
- if(! fp) {
- char *msg = g_strdup_printf(_("Error reading file %s: \n%s\n"),
- filename, strerror(errno));
-- gaim_xfer_error(gaim_xfer_get_type(xfer), acct, xfer->who, msg);
-+ gaim2_xfer_error(gaim2_xfer_get_type(xfer), acct, xfer->who, msg);
- g_free(msg);
- return;
- }
-@@ -4919,50 +4919,50 @@ static void ft_outgoing_init(GaimXfer *x
-
- ft = mwFileTransfer_new(srvc, &idb, NULL, filename, filesize);
-
-- gaim_xfer_ref(xfer);
-- mwFileTransfer_setClientData(ft, xfer, (GDestroyNotify) gaim_xfer_unref);
-+ gaim2_xfer_ref(xfer);
-+ mwFileTransfer_setClientData(ft, xfer, (GDestroyNotify) gaim2_xfer_unref);
- xfer->data = ft;
-
- mwFileTransfer_offer(ft);
- }
-
-
--static void ft_outgoing_cancel(GaimXfer *xfer) {
-+static void ft_outgoing_cancel(Gaim2Xfer *xfer) {
- struct mwFileTransfer *ft = xfer->data;
- if(ft) mwFileTransfer_cancel(ft);
- }
-
-
--static GaimXfer *mw_prpl_new_xfer(GaimConnection *gc, const char *who) {
-- GaimAccount *acct;
-- GaimXfer *xfer;
--
-- acct = gaim_connection_get_account(gc);
--
-- xfer = gaim_xfer_new(acct, GAIM_XFER_SEND, who);
-- gaim_xfer_set_init_fnc(xfer, ft_outgoing_init);
-- gaim_xfer_set_cancel_send_fnc(xfer, ft_outgoing_cancel);
-+static Gaim2Xfer *mw_prpl_new_xfer(Gaim2Connection *gc, const char *who) {
-+ Gaim2Account *acct;
-+ Gaim2Xfer *xfer;
-+
-+ acct = gaim2_connection_get_account(gc);
-+
-+ xfer = gaim2_xfer_new(acct, GAIM_XFER_SEND, who);
-+ gaim2_xfer_set_init_fnc(xfer, ft_outgoing_init);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, ft_outgoing_cancel);
-
- return xfer;
- }
-
--static void mw_prpl_send_file(GaimConnection *gc,
-+static void mw_prpl_send_file(Gaim2Connection *gc,
- const char *who, const char *file) {
-
-- GaimXfer *xfer = mw_prpl_new_xfer(gc, who);
-+ Gaim2Xfer *xfer = mw_prpl_new_xfer(gc, who);
-
- if(file) {
- DEBUG_INFO("file != NULL\n");
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
-
- } else {
- DEBUG_INFO("file == NULL\n");
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
- }
-
-
--static GaimPluginProtocolInfo mw_prpl_info = {
-+static Gaim2PluginProtocolInfo mw_prpl_info = {
- .options = OPT_PROTO_IM_IMAGE,
- .user_splits = NULL, /*< set in mw_plugin_init */
- .protocol_options = NULL, /*< set in mw_plugin_init */
-@@ -5026,42 +5026,42 @@ static GaimPluginProtocolInfo mw_prpl_in
- };
-
-
--static GaimPluginPrefFrame *
--mw_plugin_get_plugin_pref_frame(GaimPlugin *plugin) {
-- GaimPluginPrefFrame *frame;
-- GaimPluginPref *pref;
-+static Gaim2PluginPrefFrame *
-+mw_plugin_get_plugin_pref_frame(Gaim2Plugin *plugin) {
-+ Gaim2PluginPrefFrame *frame;
-+ Gaim2PluginPref *pref;
-
-- frame = gaim_plugin_pref_frame_new();
-+ frame = gaim2_plugin_pref_frame_new();
-
-- pref = gaim_plugin_pref_new_with_label(_("Remotely Stored Buddy List"));
-- gaim_plugin_pref_frame_add(frame, pref);
-+ pref = gaim2_plugin_pref_new_with_label(_("Remotely Stored Buddy List"));
-+ gaim2_plugin_pref_frame_add(frame, pref);
-
-
-- pref = gaim_plugin_pref_new_with_name(MW_PRPL_OPT_BLIST_ACTION);
-- gaim_plugin_pref_set_label(pref, _("Buddy List Storage Mode"));
-+ pref = gaim2_plugin_pref_new_with_name(MW_PRPL_OPT_BLIST_ACTION);
-+ gaim2_plugin_pref_set_label(pref, _("Buddy List Storage Mode"));
-
-- gaim_plugin_pref_set_type(pref, GAIM_PLUGIN_PREF_CHOICE);
-- gaim_plugin_pref_add_choice(pref, _("Local Buddy List Only"),
-+ gaim2_plugin_pref_set_type(pref, GAIM_PLUGIN_PREF_CHOICE);
-+ gaim2_plugin_pref_add_choice(pref, _("Local Buddy List Only"),
- GINT_TO_POINTER(blist_choice_LOCAL));
-- gaim_plugin_pref_add_choice(pref, _("Merge List from Server"),
-+ gaim2_plugin_pref_add_choice(pref, _("Merge List from Server"),
- GINT_TO_POINTER(blist_choice_MERGE));
-- gaim_plugin_pref_add_choice(pref, _("Merge and Save List to Server"),
-+ gaim2_plugin_pref_add_choice(pref, _("Merge and Save List to Server"),
- GINT_TO_POINTER(blist_choice_STORE));
-- gaim_plugin_pref_add_choice(pref, _("Synchronize List with Server"),
-+ gaim2_plugin_pref_add_choice(pref, _("Synchronize List with Server"),
- GINT_TO_POINTER(blist_choice_SYNCH));
-
-- gaim_plugin_pref_frame_add(frame, pref);
-+ gaim2_plugin_pref_frame_add(frame, pref);
-
- return frame;
- }
-
-
--static GaimPluginUiInfo mw_plugin_ui_info = {
-+static Gaim2PluginUiInfo mw_plugin_ui_info = {
- .get_plugin_pref_frame = mw_plugin_get_plugin_pref_frame,
- };
-
-
--static void st_import_action_cb(GaimConnection *gc, char *filename) {
-+static void st_import_action_cb(Gaim2Connection *gc, char *filename) {
- struct mwSametimeList *l;
-
- FILE *file;
-@@ -5089,17 +5089,17 @@ static void st_import_action_cb(GaimConn
-
-
- /** prompts for a file to import blist from */
--static void st_import_action(GaimPluginAction *act) {
-- GaimConnection *gc;
-- GaimAccount *account;
-+static void st_import_action(Gaim2PluginAction *act) {
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- char *title;
-
- gc = act->context;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- title = g_strdup_printf(_("Import Sametime List for Account %s"),
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
-
-- gaim_request_file(gc, title, NULL, FALSE,
-+ gaim2_request_file(gc, title, NULL, FALSE,
- G_CALLBACK(st_import_action_cb), NULL,
- gc);
-
-@@ -5107,7 +5107,7 @@ static void st_import_action(GaimPluginA
- }
-
-
--static void st_export_action_cb(GaimConnection *gc, char *filename) {
-+static void st_export_action_cb(Gaim2Connection *gc, char *filename) {
- struct mwSametimeList *l;
- char *str;
- FILE *file;
-@@ -5128,17 +5128,17 @@ static void st_export_action_cb(GaimConn
-
-
- /** prompts for a file to export blist to */
--static void st_export_action(GaimPluginAction *act) {
-- GaimConnection *gc;
-- GaimAccount *account;
-+static void st_export_action(Gaim2PluginAction *act) {
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- char *title;
-
- gc = act->context;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- title = g_strdup_printf(_("Export Sametime List for Account %s"),
-- gaim_account_get_username(account));
-+ gaim2_account_get_username(account));
-
-- gaim_request_file(gc, title, NULL, TRUE,
-+ gaim2_request_file(gc, title, NULL, TRUE,
- G_CALLBACK(st_export_action_cb), NULL,
- gc);
-
-@@ -5147,19 +5147,19 @@ static void st_export_action(GaimPluginA
-
-
- static void remote_group_multi_cleanup(gpointer ignore,
-- GaimRequestFields *fields) {
-+ Gaim2RequestFields *fields) {
-
-- GaimRequestField *f;
-+ Gaim2RequestField *f;
- const GList *l;
-
-- f = gaim_request_fields_get_field(fields, "group");
-- l = gaim_request_field_list_get_items(f);
-+ f = gaim2_request_fields_get_field(fields, "group");
-+ l = gaim2_request_field_list_get_items(f);
-
- for(; l; l = l->next) {
- const char *i = l->data;
- struct named_id *res;
-
-- res = gaim_request_field_list_get_data(f, i);
-+ res = gaim2_request_field_list_get_data(f, i);
-
- g_free(res->id);
- g_free(res->name);
-@@ -5168,21 +5168,21 @@ static void remote_group_multi_cleanup(g
- }
-
-
--static void remote_group_done(struct mwGaimPluginData *pd,
-+static void remote_group_done(struct mwGaim2PluginData *pd,
- const char *id, const char *name) {
-- GaimConnection *gc;
-- GaimAccount *acct;
-- GaimGroup *group;
-- GaimBlistNode *gn;
-+ Gaim2Connection *gc;
-+ Gaim2Account *acct;
-+ Gaim2Group *group;
-+ Gaim2BlistNode *gn;
- const char *owner;
-
- g_return_if_fail(pd != NULL);
-
- gc = pd->gc;
-- acct = gaim_connection_get_account(gc);
-+ acct = gaim2_connection_get_account(gc);
-
- /* collision checking */
-- group = gaim_find_group(name);
-+ group = gaim2_find_group(name);
- if(group) {
- char *msgA, *msgB;
-
-@@ -5190,40 +5190,40 @@ static void remote_group_done(struct mwG
- msgB = _("A group named '%s' already exists in your buddy list.");
- msgB = g_strdup_printf(msgB, name);
-
-- gaim_notify_error(gc, _("Unable to add group"), msgA, msgB);
-+ gaim2_notify_error(gc, _("Unable to add group"), msgA, msgB);
-
- g_free(msgB);
- return;
- }
-
-- group = gaim_group_new(name);
-- gn = (GaimBlistNode *) group;
-+ group = gaim2_group_new(name);
-+ gn = (Gaim2BlistNode *) group;
-
-- owner = gaim_account_get_username(acct);
-+ owner = gaim2_account_get_username(acct);
-
-- gaim_blist_node_set_string(gn, GROUP_KEY_NAME, id);
-- gaim_blist_node_set_int(gn, GROUP_KEY_TYPE, mwSametimeGroup_DYNAMIC);
-- gaim_blist_node_set_string(gn, GROUP_KEY_OWNER, owner);
-- gaim_blist_add_group(group, NULL);
-+ gaim2_blist_node_set_string(gn, GROUP_KEY_NAME, id);
-+ gaim2_blist_node_set_int(gn, GROUP_KEY_TYPE, mwSametimeGroup_DYNAMIC);
-+ gaim2_blist_node_set_string(gn, GROUP_KEY_OWNER, owner);
-+ gaim2_blist_add_group(group, NULL);
-
- group_add(pd, group);
- blist_schedule(pd);
- }
-
-
--static void remote_group_multi_cb(struct mwGaimPluginData *pd,
-- GaimRequestFields *fields) {
-- GaimRequestField *f;
-+static void remote_group_multi_cb(struct mwGaim2PluginData *pd,
-+ Gaim2RequestFields *fields) {
-+ Gaim2RequestField *f;
- const GList *l;
-
-- f = gaim_request_fields_get_field(fields, "group");
-- l = gaim_request_field_list_get_selected(f);
-+ f = gaim2_request_fields_get_field(fields, "group");
-+ l = gaim2_request_field_list_get_selected(f);
-
- if(l) {
- const char *i = l->data;
- struct named_id *res;
-
-- res = gaim_request_field_list_get_data(f, i);
-+ res = gaim2_request_field_list_get_data(f, i);
- remote_group_done(pd, res->id, res->name);
- }
-
-@@ -5232,24 +5232,24 @@ static void remote_group_multi_cb(struct
-
-
- static void remote_group_multi(struct mwResolveResult *result,
-- struct mwGaimPluginData *pd) {
-+ struct mwGaim2PluginData *pd) {
-
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
- GList *l;
- char *msgA, *msgB;
-
-- GaimConnection *gc = pd->gc;
-+ Gaim2Connection *gc = pd->gc;
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-- gaim_request_fields_add_group(fields, g);
-+ g = gaim2_request_field_group_new(NULL);
-+ gaim2_request_fields_add_group(fields, g);
-
-- f = gaim_request_field_list_new("group", _("Possible Matches"));
-- gaim_request_field_list_set_multi_select(f, FALSE);
-- gaim_request_field_set_required(f, TRUE);
-+ f = gaim2_request_field_list_new("group", _("Possible Matches"));
-+ gaim2_request_field_list_set_multi_select(f, FALSE);
-+ gaim2_request_field_set_required(f, TRUE);
-
- for(l = result->matches; l; l = l->next) {
- struct mwResolveMatch *match = l->data;
-@@ -5258,10 +5258,10 @@ static void remote_group_multi(struct mw
- res->id = g_strdup(match->id);
- res->name = g_strdup(match->name);
-
-- gaim_request_field_list_add(f, res->name, res);
-+ gaim2_request_field_list_add(f, res->name, res);
- }
-
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_group_add_field(g, f);
-
- msgA = _("Notes Address Book group results");
- msgB = _("The identifier '%s' may possibly refer to any of the following"
-@@ -5269,7 +5269,7 @@ static void remote_group_multi(struct mw
- " the list below to add it to your buddy list.");
- msgB = g_strdup_printf(msgB, result->name);
-
-- gaim_request_fields(gc, _("Select Notes Address Book"),
-+ gaim2_request_fields(gc, _("Select Notes Address Book"),
- msgA, msgB, fields,
- _("Add Group"), G_CALLBACK(remote_group_multi_cb),
- _("Cancel"), G_CALLBACK(remote_group_multi_cleanup),
-@@ -5285,8 +5285,8 @@ static void remote_group_resolved(struct
-
- struct mwResolveResult *res = NULL;
- struct mwSession *session;
-- struct mwGaimPluginData *pd;
-- GaimConnection *gc;
-+ struct mwGaim2PluginData *pd;
-+ Gaim2Connection *gc;
-
- session = mwService_getSession(MW_SERVICE(srvc));
- g_return_if_fail(session != NULL);
-@@ -5315,15 +5315,15 @@ static void remote_group_resolved(struct
- " groups in your Sametime community.");
- msgB = g_strdup_printf(msgB, res->name);
-
-- gaim_notify_error(gc, _("Unable to add group"), msgA, msgB);
-+ gaim2_notify_error(gc, _("Unable to add group"), msgA, msgB);
-
- g_free(msgB);
- }
- }
-
-
--static void remote_group_action_cb(GaimConnection *gc, const char *name) {
-- struct mwGaimPluginData *pd;
-+static void remote_group_action_cb(Gaim2Connection *gc, const char *name) {
-+ struct mwGaim2PluginData *pd;
- struct mwServiceResolve *srvc;
- GList *query;
- enum mwResolveFlag flags;
-@@ -5345,8 +5345,8 @@ static void remote_group_action_cb(GaimC
- }
-
-
--static void remote_group_action(GaimPluginAction *act) {
-- GaimConnection *gc;
-+static void remote_group_action(Gaim2PluginAction *act) {
-+ Gaim2Connection *gc;
- const char *msgA, *msgB;
-
- gc = act->context;
-@@ -5355,7 +5355,7 @@ static void remote_group_action(GaimPlug
- msgB = _("Enter the name of a Notes Address Book group in the field below"
- " to add the group and its members to your buddy list.");
-
-- gaim_request_input(gc, _("Add Group"), msgA, msgB, NULL,
-+ gaim2_request_input(gc, _("Add Group"), msgA, msgB, NULL,
- FALSE, FALSE, NULL,
- _("Add"), G_CALLBACK(remote_group_action_cb),
- _("Cancel"), NULL,
-@@ -5364,25 +5364,25 @@ static void remote_group_action(GaimPlug
-
-
- static void search_notify(struct mwResolveResult *result,
-- GaimConnection *gc) {
-+ Gaim2Connection *gc) {
- GList *l;
- char *msgA, *msgB;
-
-- GaimNotifySearchResults *sres;
-- GaimNotifySearchColumn *scol;
-+ Gaim2NotifySearchResults *sres;
-+ Gaim2NotifySearchColumn *scol;
-
-- sres = gaim_notify_searchresults_new();
-+ sres = gaim2_notify_searchresults_new();
-
-- scol = gaim_notify_searchresults_column_new(_("User Name"));
-- gaim_notify_searchresults_column_add(sres, scol);
-+ scol = gaim2_notify_searchresults_column_new(_("User Name"));
-+ gaim2_notify_searchresults_column_add(sres, scol);
-
-- scol = gaim_notify_searchresults_column_new(_("Sametime ID"));
-- gaim_notify_searchresults_column_add(sres, scol);
-+ scol = gaim2_notify_searchresults_column_new(_("Sametime ID"));
-+ gaim2_notify_searchresults_column_add(sres, scol);
-
-- gaim_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_IM,
-+ gaim2_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_IM,
- notify_im);
-
-- gaim_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_ADD,
-+ gaim2_notify_searchresults_button_add(sres, GAIM_NOTIFY_BUTTON_ADD,
- notify_add);
-
- for(l = result->matches; l; l = l->next) {
-@@ -5394,7 +5394,7 @@ static void search_notify(struct mwResol
-
- row = g_list_append(row, g_strdup(match->name));
- row = g_list_append(row, g_strdup(match->id));
-- gaim_notify_searchresults_row_add(sres, row);
-+ gaim2_notify_searchresults_row_add(sres, row);
- }
-
- msgA = _("Search results for '%s'");
-@@ -5405,7 +5405,7 @@ static void search_notify(struct mwResol
- msgA = g_strdup_printf(msgA, result->name);
- msgB = g_strdup_printf(msgB, result->name);
-
-- gaim_notify_searchresults(gc, _("Search Results"),
-+ gaim2_notify_searchresults(gc, _("Search Results"),
- msgA, msgB, sres, notify_close, NULL);
-
- g_free(msgA);
-@@ -5417,7 +5417,7 @@ static void search_resolved(struct mwSer
- guint32 id, guint32 code, GList *results,
- gpointer b) {
-
-- GaimConnection *gc = b;
-+ Gaim2Connection *gc = b;
- struct mwResolveResult *res = NULL;
-
- if(results) res = results->data;
-@@ -5432,15 +5432,15 @@ static void search_resolved(struct mwSer
- " Sametime community.");
- msgB = g_strdup_printf(msgB, NSTR(res->name));
-
-- gaim_notify_error(gc, _("No Matches"), msgA, msgB);
-+ gaim2_notify_error(gc, _("No Matches"), msgA, msgB);
-
- g_free(msgB);
- }
- }
-
-
--static void search_action_cb(GaimConnection *gc, const char *name) {
-- struct mwGaimPluginData *pd;
-+static void search_action_cb(Gaim2Connection *gc, const char *name) {
-+ struct mwGaim2PluginData *pd;
- struct mwServiceResolve *srvc;
- GList *query;
- enum mwResolveFlag flags;
-@@ -5462,8 +5462,8 @@ static void search_action_cb(GaimConnect
- }
-
-
--static void search_action(GaimPluginAction *act) {
-- GaimConnection *gc;
-+static void search_action(Gaim2PluginAction *act) {
-+ Gaim2Connection *gc;
- const char *msgA, *msgB;
-
- gc = act->context;
-@@ -5472,7 +5472,7 @@ static void search_action(GaimPluginActi
- msgB = _("Enter a name or partial ID in the field below to search"
- " for matching users in your Sametime community.");
-
-- gaim_request_input(gc, _("User Search"), msgA, msgB, NULL,
-+ gaim2_request_input(gc, _("User Search"), msgA, msgB, NULL,
- FALSE, FALSE, NULL,
- _("Search"), G_CALLBACK(search_action_cb),
- _("Cancel"), NULL,
-@@ -5480,23 +5480,23 @@ static void search_action(GaimPluginActi
- }
-
-
--static GList *mw_plugin_actions(GaimPlugin *plugin, gpointer context) {
-- GaimPluginAction *act;
-+static GList *mw_plugin_actions(Gaim2Plugin *plugin, gpointer context) {
-+ Gaim2PluginAction *act;
- GList *l = NULL;
-
-- act = gaim_plugin_action_new(_("Import Sametime List..."),
-+ act = gaim2_plugin_action_new(_("Import Sametime List..."),
- st_import_action);
- l = g_list_append(l, act);
-
-- act = gaim_plugin_action_new(_("Export Sametime List..."),
-+ act = gaim2_plugin_action_new(_("Export Sametime List..."),
- st_export_action);
- l = g_list_append(l, act);
-
-- act = gaim_plugin_action_new(_("Add Notes Address Book Group..."),
-+ act = gaim2_plugin_action_new(_("Add Notes Address Book Group..."),
- remote_group_action);
- l = g_list_append(l, act);
-
-- act = gaim_plugin_action_new(_("User Search..."),
-+ act = gaim2_plugin_action_new(_("User Search..."),
- search_action);
- l = g_list_append(l, act);
-
-@@ -5504,23 +5504,23 @@ static GList *mw_plugin_actions(GaimPlug
- }
-
-
--static gboolean mw_plugin_load(GaimPlugin *plugin) {
-+static gboolean mw_plugin_load(Gaim2Plugin *plugin) {
- return TRUE;
- }
-
-
--static gboolean mw_plugin_unload(GaimPlugin *plugin) {
-+static gboolean mw_plugin_unload(Gaim2Plugin *plugin) {
- return TRUE;
- }
-
-
--static void mw_plugin_destroy(GaimPlugin *plugin) {
-+static void mw_plugin_destroy(Gaim2Plugin *plugin) {
- g_log_remove_handler(G_LOG_DOMAIN, log_handler[0]);
- g_log_remove_handler("meanwhile", log_handler[1]);
- }
-
-
--static GaimPluginInfo mw_plugin_info = {
-+static Gaim2PluginInfo mw_plugin_info = {
- .magic = GAIM_PLUGIN_MAGIC,
- .major_version = GAIM_MAJOR_VERSION,
- .minor_version = GAIM_MINOR_VERSION,
-@@ -5551,46 +5551,46 @@ static void mw_log_handler(const gchar *
-
- if(! (msg && *msg)) return;
-
-- /* handle g_log requests via gaim's built-in debug logging */
-+ /* handle g_log requests via gaim2's built-in debug logging */
- if(flags & G_LOG_LEVEL_ERROR) {
-- gaim_debug_error(domain, "%s\n", msg);
-+ gaim2_debug_error(domain, "%s\n", msg);
-
- } else if(flags & G_LOG_LEVEL_WARNING) {
-- gaim_debug_warning(domain, "%s\n", msg);
-+ gaim2_debug_warning(domain, "%s\n", msg);
-
- } else {
-- gaim_debug_info(domain, "%s\n", msg);
-+ gaim2_debug_info(domain, "%s\n", msg);
- }
- }
-
-
--static void mw_plugin_init(GaimPlugin *plugin) {
-- GaimAccountOption *opt;
-+static void mw_plugin_init(Gaim2Plugin *plugin) {
-+ Gaim2AccountOption *opt;
- GList *l = NULL;
-
- GLogLevelFlags logflags =
- G_LOG_LEVEL_MASK | G_LOG_FLAG_FATAL | G_LOG_FLAG_RECURSION;
-
- /* set up the preferences */
-- gaim_prefs_add_none(MW_PRPL_OPT_BASE);
-- gaim_prefs_add_int(MW_PRPL_OPT_BLIST_ACTION, BLIST_CHOICE_DEFAULT);
-+ gaim2_prefs_add_none(MW_PRPL_OPT_BASE);
-+ gaim2_prefs_add_int(MW_PRPL_OPT_BLIST_ACTION, BLIST_CHOICE_DEFAULT);
-
- /* remove dead preferences */
-- gaim_prefs_remove(MW_PRPL_OPT_PSYCHIC);
-- gaim_prefs_remove(MW_PRPL_OPT_SAVE_DYNAMIC);
-+ gaim2_prefs_remove(MW_PRPL_OPT_PSYCHIC);
-+ gaim2_prefs_remove(MW_PRPL_OPT_SAVE_DYNAMIC);
-
- /* host to connect to */
-- opt = gaim_account_option_string_new(_("Server"), MW_KEY_HOST,
-+ opt = gaim2_account_option_string_new(_("Server"), MW_KEY_HOST,
- MW_PLUGIN_DEFAULT_HOST);
- l = g_list_append(l, opt);
-
- /* port to connect to */
-- opt = gaim_account_option_int_new(_("Port"), MW_KEY_PORT,
-+ opt = gaim2_account_option_int_new(_("Port"), MW_KEY_PORT,
- MW_PLUGIN_DEFAULT_PORT);
- l = g_list_append(l, opt);
-
- /* notesbuddy hack encoding */
-- opt = gaim_account_option_string_new(_("NotesBuddy encoding"),
-+ opt = gaim2_account_option_string_new(_("NotesBuddy encoding"),
- MW_KEY_ENCODING,
- MW_PLUGIN_DEFAULT_ENCODING);
- l = g_list_append(l, opt);
-@@ -5601,28 +5601,28 @@ static void mw_plugin_init(GaimPlugin *p
- gboolean b = FALSE;
- const char *label = _("Force login (ignore server redirects)");
-
-- if(gaim_prefs_exists(MW_PRPL_OPT_FORCE_LOGIN))
-- b = gaim_prefs_get_bool(MW_PRPL_OPT_FORCE_LOGIN);
-+ if(gaim2_prefs_exists(MW_PRPL_OPT_FORCE_LOGIN))
-+ b = gaim2_prefs_get_bool(MW_PRPL_OPT_FORCE_LOGIN);
-
-- opt = gaim_account_option_bool_new(label, MW_KEY_FORCE, b);
-+ opt = gaim2_account_option_bool_new(label, MW_KEY_FORCE, b);
- l = g_list_append(l, opt);
- }
-
- /* pretend to be Sametime Connect */
-- opt = gaim_account_option_bool_new(_("Hide client identity"),
-+ opt = gaim2_account_option_bool_new(_("Hide client identity"),
- MW_KEY_FAKE_IT, FALSE);
- l = g_list_append(l, opt);
-
- mw_prpl_info.protocol_options = l;
- l = NULL;
-
-- /* forward all our g_log messages to gaim. Generally all the logging
-- calls are using gaim_log directly, but the g_return macros will
-+ /* forward all our g_log messages to gaim2. Generally all the logging
-+ calls are using gaim2_log directly, but the g_return macros will
- get caught here */
- log_handler[0] = g_log_set_handler(G_LOG_DOMAIN, logflags,
- mw_log_handler, NULL);
-
-- /* redirect meanwhile's logging to gaim's */
-+ /* redirect meanwhile's logging to gaim2's */
- log_handler[1] = g_log_set_handler("meanwhile", logflags,
- mw_log_handler, NULL);
- }
-diff -prNu ./src/protocols/sametime/sametime.h ./src/protocols/sametime/sametime.h
---- ./src/protocols/sametime/sametime.h 2005-12-17 16:40:06.000000000 +0100
-+++ ./src/protocols/sametime/sametime.h 2006-01-05 15:11:21.000000000 +0100
-@@ -3,7 +3,7 @@
- /* CFLAGS trumps configure values */
-
-
--/** default host for the gaim plugin. You can specialize a build to
-+/** default host for the gaim2 plugin. You can specialize a build to
- default to your server by supplying this at compile time */
- #ifndef MW_PLUGIN_DEFAULT_HOST
- #define MW_PLUGIN_DEFAULT_HOST ""
-@@ -11,7 +11,7 @@
- /* "" */
-
-
--/** default port for the gaim plugin. You can specialize a build to
-+/** default port for the gaim2 plugin. You can specialize a build to
- default to your server by supplying this at compile time */
- #ifndef MW_PLUGIN_DEFAULT_PORT
- #define MW_PLUGIN_DEFAULT_PORT 1533
-@@ -19,7 +19,7 @@
- /* 1533 */
-
-
--/** default encoding for the gaim plugin.*/
-+/** default encoding for the gaim2 plugin.*/
- #ifndef MW_PLUGIN_DEFAULT_ENCODING
- #define MW_PLUGIN_DEFAULT_ENCODING "ISO-8859-1"
- #endif
-diff -prNu ./src/protocols/silc/buddy.c ./src/protocols/silc/buddy.c
---- ./src/protocols/silc/buddy.c 2005-12-21 22:18:25.000000000 +0100
-+++ ./src/protocols/silc/buddy.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim_buddy.c
-+ silcgaim2_buddy.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,64 +19,64 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "wb.h"
-
- /***************************** Key Agreement *********************************/
-
- static void
--silcgaim_buddy_keyagr(GaimBlistNode *node, gpointer data);
-+silcgaim2_buddy_keyagr(Gaim2BlistNode *node, gpointer data);
-
- static void
--silcgaim_buddy_keyagr_do(GaimConnection *gc, const char *name,
-+silcgaim2_buddy_keyagr_do(Gaim2Connection *gc, const char *name,
- gboolean force_local);
-
- typedef struct {
- char *nick;
-- GaimConnection *gc;
--} *SilcGaimResolve;
-+ Gaim2Connection *gc;
-+} *SilcGaim2Resolve;
-
- static void
--silcgaim_buddy_keyagr_resolved(SilcClient client,
-+silcgaim2_buddy_keyagr_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context)
- {
-- GaimConnection *gc = client->application;
-- SilcGaimResolve r = context;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2Resolve r = context;
- char tmp[256];
-
- if (!clients) {
- g_snprintf(tmp, sizeof(tmp),
- _("User %s is not present in the network"), r->nick);
-- gaim_notify_error(gc, _("Key Agreement"),
-+ gaim2_notify_error(gc, _("Key Agreement"),
- _("Cannot perform the key agreement"), tmp);
- silc_free(r->nick);
- silc_free(r);
- return;
- }
-
-- silcgaim_buddy_keyagr_do(gc, r->nick, FALSE);
-+ silcgaim2_buddy_keyagr_do(gc, r->nick, FALSE);
- silc_free(r->nick);
- silc_free(r);
- }
-
- typedef struct {
- gboolean responder;
--} *SilcGaimKeyAgr;
-+} *SilcGaim2KeyAgr;
-
- static void
--silcgaim_buddy_keyagr_cb(SilcClient client,
-+silcgaim2_buddy_keyagr_cb(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry client_entry,
- SilcKeyAgreementStatus status,
- SilcSKEKeyMaterial *key,
- void *context)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- SilcGaimKeyAgr a = context;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ SilcGaim2KeyAgr a = context;
-
- if (!sg->conn)
- return;
-@@ -84,7 +84,7 @@ silcgaim_buddy_keyagr_cb(SilcClient clie
- switch (status) {
- case SILC_KEY_AGREEMENT_OK:
- {
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
- char tmp[128];
-
- /* Set the private key for this client */
-@@ -95,48 +95,48 @@ silcgaim_buddy_keyagr_cb(SilcClient clie
-
-
- /* Open IM window */
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
- client_entry->nickname, sg->account);
- if (convo) {
- /* we don't have windows in the core anymore...but we may want to
- * provide some method for asking the UI to show the window
-- gaim_conv_window_show(gaim_conversation_get_window(convo));
-+ gaim2_conv_window_show(gaim2_conversation_get_window(convo));
- */
- } else {
-- convo = gaim_conversation_new(GAIM_CONV_TYPE_IM, sg->account,
-+ convo = gaim2_conversation_new(GAIM_CONV_TYPE_IM, sg->account,
- client_entry->nickname);
- }
- g_snprintf(tmp, sizeof(tmp), "%s [private key]", client_entry->nickname);
-- gaim_conversation_set_title(convo, tmp);
-+ gaim2_conversation_set_title(convo, tmp);
- }
- break;
-
- case SILC_KEY_AGREEMENT_ERROR:
-- gaim_notify_error(gc, _("Key Agreement"),
-+ gaim2_notify_error(gc, _("Key Agreement"),
- _("Error occurred during key agreement"), NULL);
- break;
-
- case SILC_KEY_AGREEMENT_FAILURE:
-- gaim_notify_error(gc, _("Key Agreement"), _("Key Agreement failed"), NULL);
-+ gaim2_notify_error(gc, _("Key Agreement"), _("Key Agreement failed"), NULL);
- break;
-
- case SILC_KEY_AGREEMENT_TIMEOUT:
-- gaim_notify_error(gc, _("Key Agreement"),
-+ gaim2_notify_error(gc, _("Key Agreement"),
- _("Timeout during key agreement"), NULL);
- break;
-
- case SILC_KEY_AGREEMENT_ABORTED:
-- gaim_notify_error(gc, _("Key Agreement"),
-+ gaim2_notify_error(gc, _("Key Agreement"),
- _("Key agreement was aborted"), NULL);
- break;
-
- case SILC_KEY_AGREEMENT_ALREADY_STARTED:
-- gaim_notify_error(gc, _("Key Agreement"),
-+ gaim2_notify_error(gc, _("Key Agreement"),
- _("Key agreement is already started"), NULL);
- break;
-
- case SILC_KEY_AGREEMENT_SELF_DENIED:
-- gaim_notify_error(gc, _("Key Agreement"),
-+ gaim2_notify_error(gc, _("Key Agreement"),
- _("Key agreement cannot be started with yourself"),
- NULL);
- break;
-@@ -149,16 +149,16 @@ silcgaim_buddy_keyagr_cb(SilcClient clie
- }
-
- static void
--silcgaim_buddy_keyagr_do(GaimConnection *gc, const char *name,
-+silcgaim2_buddy_keyagr_do(Gaim2Connection *gc, const char *name,
- gboolean force_local)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClientEntry *clients;
- SilcUInt32 clients_count;
- char *local_ip = NULL, *remote_ip = NULL;
- gboolean local = TRUE;
- char *nickname;
-- SilcGaimKeyAgr a;
-+ SilcGaim2KeyAgr a;
-
- if (!sg->conn || !name)
- return;
-@@ -171,13 +171,13 @@ silcgaim_buddy_keyagr_do(GaimConnection
- &clients_count);
- if (!clients) {
- /* Resolve unknown user */
-- SilcGaimResolve r = silc_calloc(1, sizeof(*r));
-+ SilcGaim2Resolve r = silc_calloc(1, sizeof(*r));
- if (!r)
- return;
- r->nick = g_strdup(name);
- r->gc = gc;
- silc_client_get_clients(sg->client, sg->conn, nickname, NULL,
-- silcgaim_buddy_keyagr_resolved, r);
-+ silcgaim2_buddy_keyagr_resolved, r);
- silc_free(nickname);
- return;
- }
-@@ -198,14 +198,14 @@ silcgaim_buddy_keyagr_do(GaimConnection
-
- if (silc_net_check_local_by_sock(sg->conn->sock->sock, NULL, &local_ip)) {
- /* Check if the IP is private */
-- if (!force_local && silcgaim_ip_is_private(local_ip)) {
-+ if (!force_local && silcgaim2_ip_is_private(local_ip)) {
- local = FALSE;
-
- /* Local IP is private, resolve the remote server IP to see whether
- we are talking to Internet or just on LAN. */
- if (silc_net_check_host_by_sock(sg->conn->sock->sock, NULL,
- &remote_ip))
-- if (silcgaim_ip_is_private(remote_ip))
-+ if (silcgaim2_ip_is_private(remote_ip))
- /* We assume we are in LAN. Let's provide
- the connection point. */
- local = TRUE;
-@@ -226,7 +226,7 @@ silcgaim_buddy_keyagr_do(GaimConnection
- /* Send the key agreement request */
- silc_client_send_key_agreement(sg->client, sg->conn, clients[0],
- local ? local_ip : NULL, NULL, 0, 60,
-- silcgaim_buddy_keyagr_cb, a);
-+ silcgaim2_buddy_keyagr_cb, a);
-
- silc_free(local_ip);
- silc_free(remote_ip);
-@@ -239,12 +239,12 @@ typedef struct {
- SilcClientID client_id;
- char *hostname;
- SilcUInt16 port;
--} *SilcGaimKeyAgrAsk;
-+} *SilcGaim2KeyAgrAsk;
-
- static void
--silcgaim_buddy_keyagr_request_cb(SilcGaimKeyAgrAsk a, gint id)
-+silcgaim2_buddy_keyagr_request_cb(SilcGaim2KeyAgrAsk a, gint id)
- {
-- SilcGaimKeyAgr ai;
-+ SilcGaim2KeyAgr ai;
- SilcClientEntry client_entry;
-
- if (id != 1)
-@@ -254,7 +254,7 @@ silcgaim_buddy_keyagr_request_cb(SilcGai
- client_entry = silc_client_get_client_by_id(a->client, a->conn,
- &a->client_id);
- if (!client_entry) {
-- gaim_notify_error(a->client->application, _("Key Agreement"),
-+ gaim2_notify_error(a->client->application, _("Key Agreement"),
- _("The remote user is not present in the network any more"),
- NULL);
- goto out;
-@@ -269,11 +269,11 @@ silcgaim_buddy_keyagr_request_cb(SilcGai
- ai->responder = FALSE;
- silc_client_perform_key_agreement(a->client, a->conn, client_entry,
- a->hostname, a->port,
-- silcgaim_buddy_keyagr_cb, ai);
-+ silcgaim2_buddy_keyagr_cb, ai);
- } else {
- /* Send request. Force us as the point of connection since requestor
- did not provide the point of connection. */
-- silcgaim_buddy_keyagr_do(a->client->application,
-+ silcgaim2_buddy_keyagr_do(a->client->application,
- client_entry->nickname, TRUE);
- }
-
-@@ -282,13 +282,13 @@ silcgaim_buddy_keyagr_request_cb(SilcGai
- silc_free(a);
- }
-
--void silcgaim_buddy_keyagr_request(SilcClient client,
-+void silcgaim2_buddy_keyagr_request(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry client_entry,
- const char *hostname, SilcUInt16 port)
- {
- char tmp[128], tmp2[128];
-- SilcGaimKeyAgrAsk a;
-+ SilcGaim2KeyAgrAsk a;
-
- g_snprintf(tmp, sizeof(tmp),
- _("Key agreement request received from %s. Would you like to "
-@@ -308,38 +308,38 @@ void silcgaim_buddy_keyagr_request(SilcC
- a->hostname = strdup(hostname);
- a->port = port;
-
-- gaim_request_action(client->application, _("Key Agreement Request"), tmp,
-+ gaim2_request_action(client->application, _("Key Agreement Request"), tmp,
- hostname ? tmp2 : NULL, 1, a, 2,
-- _("Yes"), G_CALLBACK(silcgaim_buddy_keyagr_request_cb),
-- _("No"), G_CALLBACK(silcgaim_buddy_keyagr_request_cb));
-+ _("Yes"), G_CALLBACK(silcgaim2_buddy_keyagr_request_cb),
-+ _("No"), G_CALLBACK(silcgaim2_buddy_keyagr_request_cb));
- }
-
- static void
--silcgaim_buddy_keyagr(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_keyagr(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
-- buddy = (GaimBuddy *)node;
-- silcgaim_buddy_keyagr_do(buddy->account->gc, buddy->name, FALSE);
-+ buddy = (Gaim2Buddy *)node;
-+ silcgaim2_buddy_keyagr_do(buddy->account->gc, buddy->name, FALSE);
- }
-
-
- /**************************** Static IM Key **********************************/
-
- static void
--silcgaim_buddy_resetkey(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_resetkey(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *b;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Buddy *b;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
- char *nickname;
- SilcClientEntry *clients;
- SilcUInt32 clients_count;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- b = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(b->account);
-+ b = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(b->account);
- sg = gc->proto_data;
-
- if (!silc_parse_userfqdn(b->name, &nickname, NULL))
-@@ -365,13 +365,13 @@ typedef struct {
- SilcClient client;
- SilcClientConnection conn;
- SilcClientID client_id;
--} *SilcGaimPrivkey;
-+} *SilcGaim2Privkey;
-
- static void
--silcgaim_buddy_privkey(GaimConnection *gc, const char *name);
-+silcgaim2_buddy_privkey(Gaim2Connection *gc, const char *name);
-
- static void
--silcgaim_buddy_privkey_cb(SilcGaimPrivkey p, const char *passphrase)
-+silcgaim2_buddy_privkey_cb(SilcGaim2Privkey p, const char *passphrase)
- {
- SilcClientEntry client_entry;
-
-@@ -384,7 +384,7 @@ silcgaim_buddy_privkey_cb(SilcGaimPrivke
- client_entry = silc_client_get_client_by_id(p->client, p->conn,
- &p->client_id);
- if (!client_entry) {
-- gaim_notify_error(p->client->application, _("IM With Password"),
-+ gaim2_notify_error(p->client->application, _("IM With Password"),
- _("The remote user is not present in the network any more"),
- NULL);
- silc_free(p);
-@@ -407,7 +407,7 @@ silcgaim_buddy_privkey_cb(SilcGaimPrivke
- }
-
- static void
--silcgaim_buddy_privkey_resolved(SilcClient client,
-+silcgaim2_buddy_privkey_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
-@@ -419,22 +419,22 @@ silcgaim_buddy_privkey_resolved(SilcClie
- g_snprintf(tmp, sizeof(tmp),
- _("User %s is not present in the network"),
- (const char *)context);
-- gaim_notify_error(client->application, _("IM With Password"),
-+ gaim2_notify_error(client->application, _("IM With Password"),
- _("Cannot set IM key"), tmp);
- g_free(context);
- return;
- }
-
-- silcgaim_buddy_privkey(client->application, context);
-+ silcgaim2_buddy_privkey(client->application, context);
- silc_free(context);
- }
-
- static void
--silcgaim_buddy_privkey(GaimConnection *gc, const char *name)
-+silcgaim2_buddy_privkey(Gaim2Connection *gc, const char *name)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- char *nickname;
-- SilcGaimPrivkey p;
-+ SilcGaim2Privkey p;
- SilcClientEntry *clients;
- SilcUInt32 clients_count;
-
-@@ -449,7 +449,7 @@ silcgaim_buddy_privkey(GaimConnection *g
- &clients_count);
- if (!clients) {
- silc_client_get_clients(sg->client, sg->conn, nickname, NULL,
-- silcgaim_buddy_privkey_resolved,
-+ silcgaim2_buddy_privkey_resolved,
- g_strdup(name));
- silc_free(nickname);
- return;
-@@ -461,10 +461,10 @@ silcgaim_buddy_privkey(GaimConnection *g
- p->client = sg->client;
- p->conn = sg->conn;
- p->client_id = *clients[0]->id;
-- gaim_request_input(gc, _("IM With Password"), NULL,
-+ gaim2_request_input(gc, _("IM With Password"), NULL,
- _("Set IM Password"), NULL, FALSE, TRUE, NULL,
-- _("OK"), G_CALLBACK(silcgaim_buddy_privkey_cb),
-- _("Cancel"), G_CALLBACK(silcgaim_buddy_privkey_cb),
-+ _("OK"), G_CALLBACK(silcgaim2_buddy_privkey_cb),
-+ _("Cancel"), G_CALLBACK(silcgaim2_buddy_privkey_cb),
- p);
-
- silc_free(clients);
-@@ -472,17 +472,17 @@ silcgaim_buddy_privkey(GaimConnection *g
- }
-
- static void
--silcgaim_buddy_privkey_menu(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_privkey_menu(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
-- silcgaim_buddy_privkey(gc, buddy->name);
-+ silcgaim2_buddy_privkey(gc, buddy->name);
- }
-
-
-@@ -492,13 +492,13 @@ typedef struct {
- SilcClient client;
- SilcClientConnection conn;
- SilcClientID client_id;
--} *SilcGaimBuddyGetkey;
-+} *SilcGaim2BuddyGetkey;
-
- static void
--silcgaim_buddy_getkey(GaimConnection *gc, const char *name);
-+silcgaim2_buddy_getkey(Gaim2Connection *gc, const char *name);
-
- static void
--silcgaim_buddy_getkey_cb(SilcGaimBuddyGetkey g,
-+silcgaim2_buddy_getkey_cb(SilcGaim2BuddyGetkey g,
- SilcClientCommandReplyContext cmd)
- {
- SilcClientEntry client_entry;
-@@ -509,7 +509,7 @@ silcgaim_buddy_getkey_cb(SilcGaimBuddyGe
- client_entry = silc_client_get_client_by_id(g->client, g->conn,
- &g->client_id);
- if (!client_entry) {
-- gaim_notify_error(g->client->application, _("Get Public Key"),
-+ gaim2_notify_error(g->client->application, _("Get Public Key"),
- _("The remote user is not present in the network any more"),
- NULL);
- silc_free(g);
-@@ -523,7 +523,7 @@ silcgaim_buddy_getkey_cb(SilcGaimBuddyGe
-
- /* Now verify the public key */
- pk = silc_pkcs_public_key_encode(client_entry->public_key, &pk_len);
-- silcgaim_verify_public_key(g->client, g->conn, client_entry->nickname,
-+ silcgaim2_verify_public_key(g->client, g->conn, client_entry->nickname,
- SILC_SOCKET_TYPE_CLIENT,
- pk, pk_len, SILC_SKE_PK_TYPE_SILC,
- NULL, NULL);
-@@ -532,7 +532,7 @@ silcgaim_buddy_getkey_cb(SilcGaimBuddyGe
- }
-
- static void
--silcgaim_buddy_getkey_resolved(SilcClient client,
-+silcgaim2_buddy_getkey_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
-@@ -544,25 +544,25 @@ silcgaim_buddy_getkey_resolved(SilcClien
- g_snprintf(tmp, sizeof(tmp),
- _("User %s is not present in the network"),
- (const char *)context);
-- gaim_notify_error(client->application, _("Get Public Key"),
-+ gaim2_notify_error(client->application, _("Get Public Key"),
- _("Cannot fetch the public key"), tmp);
- g_free(context);
- return;
- }
-
-- silcgaim_buddy_getkey(client->application, context);
-+ silcgaim2_buddy_getkey(client->application, context);
- silc_free(context);
- }
-
- static void
--silcgaim_buddy_getkey(GaimConnection *gc, const char *name)
-+silcgaim2_buddy_getkey(Gaim2Connection *gc, const char *name)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcClientEntry *clients;
- SilcUInt32 clients_count;
-- SilcGaimBuddyGetkey g;
-+ SilcGaim2BuddyGetkey g;
- char *nickname;
-
- if (!name)
-@@ -576,7 +576,7 @@ silcgaim_buddy_getkey(GaimConnection *gc
- &clients_count);
- if (!clients) {
- silc_client_get_clients(client, conn, nickname, NULL,
-- silcgaim_buddy_getkey_resolved,
-+ silcgaim2_buddy_getkey_resolved,
- g_strdup(name));
- silc_free(nickname);
- return;
-@@ -593,51 +593,51 @@ silcgaim_buddy_getkey(GaimConnection *gc
- clients[0]->nickname, NULL);
- silc_client_command_pending(conn, SILC_COMMAND_GETKEY,
- conn->cmd_ident,
-- (SilcCommandCb)silcgaim_buddy_getkey_cb, g);
-+ (SilcCommandCb)silcgaim2_buddy_getkey_cb, g);
- silc_free(clients);
- silc_free(nickname);
- }
-
- static void
--silcgaim_buddy_getkey_menu(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_getkey_menu(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
-- silcgaim_buddy_privkey(gc, buddy->name);
-+ silcgaim2_buddy_privkey(gc, buddy->name);
-
- }
-
- static void
--silcgaim_buddy_showkey(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_showkey(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *b;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Buddy *b;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
- SilcPublicKey public_key;
- const char *pkfile;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- b = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(b->account);
-+ b = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(b->account);
- sg = gc->proto_data;
-
-- pkfile = gaim_blist_node_get_string(node, "public-key");
-+ pkfile = gaim2_blist_node_get_string(node, "public-key");
- if (!silc_pkcs_load_public_key(pkfile, &public_key, SILC_PKCS_FILE_PEM) &&
- !silc_pkcs_load_public_key(pkfile, &public_key, SILC_PKCS_FILE_BIN)) {
-- gaim_notify_error(gc,
-+ gaim2_notify_error(gc,
- _("Show Public Key"),
- _("Could not load public key"), NULL);
- return;
- }
-
-- silcgaim_show_public_key(sg, b->name, public_key, NULL, NULL);
-+ silcgaim2_show_public_key(sg, b->name, public_key, NULL, NULL);
- silc_pkcs_public_key_free(public_key);
- }
-
-@@ -650,7 +650,7 @@ silcgaim_buddy_showkey(GaimBlistNode *no
- associate public keys to buddies and use those to search and watch
- in the network.
-
-- The problem is that Gaim does not return GaimBuddy contexts to the
-+ The problem is that Gaim2 does not return Gaim2Buddy contexts to the
- callbacks but the buddy names. Naturally, this is not going to work
- with SILC. But, for now, we have to do what we can... */
-
-@@ -658,30 +658,30 @@ typedef struct {
- SilcClient client;
- SilcClientConnection conn;
- SilcClientID client_id;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- unsigned char *offline_pk;
- SilcUInt32 offline_pk_len;
- unsigned int offline : 1;
- unsigned int pubkey_search : 1;
- unsigned int init : 1;
--} *SilcGaimBuddyRes;
-+} *SilcGaim2BuddyRes;
-
- static void
--silcgaim_add_buddy_ask_pk_cb(SilcGaimBuddyRes r, gint id);
-+silcgaim2_add_buddy_ask_pk_cb(SilcGaim2BuddyRes r, gint id);
- static void
--silcgaim_add_buddy_resolved(SilcClient client,
-+silcgaim2_add_buddy_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context);
-
--void silcgaim_get_info(GaimConnection *gc, const char *who)
-+void silcgaim2_get_info(Gaim2Connection *gc, const char *who)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcClientEntry client_entry;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- const char *filename, *nick = who;
- char tmp[256];
-
-@@ -694,11 +694,11 @@ void silcgaim_get_info(GaimConnection *g
- if (strlen(who) > 2 && who[0] == '*' && who[1] == '@')
- nick = who + 2;
-
-- b = gaim_find_buddy(gc->account, nick);
-+ b = gaim2_find_buddy(gc->account, nick);
- if (b) {
- /* See if we have this buddy's public key. If we do use that
- to search the details. */
-- filename = gaim_blist_node_get_string((GaimBlistNode *)b, "public-key");
-+ filename = gaim2_blist_node_get_string((Gaim2BlistNode *)b, "public-key");
- if (filename) {
- /* Call WHOIS. The user info is displayed in the WHOIS
- command reply. */
-@@ -710,7 +710,7 @@ void silcgaim_get_info(GaimConnection *g
- if (!b->proto_data) {
- g_snprintf(tmp, sizeof(tmp),
- _("User %s is not present in the network"), b->name);
-- gaim_notify_error(gc, _("User Information"),
-+ gaim2_notify_error(gc, _("User Information"),
- _("Cannot get user information"), tmp);
- return;
- }
-@@ -729,23 +729,23 @@ void silcgaim_get_info(GaimConnection *g
- }
-
- static void
--silcgaim_add_buddy_pk_no(SilcGaimBuddyRes r)
-+silcgaim2_add_buddy_pk_no(SilcGaim2BuddyRes r)
- {
- char tmp[512];
- g_snprintf(tmp, sizeof(tmp), _("The %s buddy is not trusted"),
- r->b->name);
-- gaim_notify_error(r->client->application, _("Add Buddy"), tmp,
-+ gaim2_notify_error(r->client->application, _("Add Buddy"), tmp,
- _("You cannot receive buddy notifications until you "
- "import his/her public key. You can use the Get Public Key "
- "command to get the public key."));
-- gaim_prpl_got_user_status(gaim_buddy_get_account(r->b), gaim_buddy_get_name(r->b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(r->b), gaim2_buddy_get_name(r->b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
- }
-
- static void
--silcgaim_add_buddy_save(bool success, void *context)
-+silcgaim2_add_buddy_save(bool success, void *context)
- {
-- SilcGaimBuddyRes r = context;
-- GaimBuddy *b = r->b;
-+ SilcGaim2BuddyRes r = context;
-+ Gaim2Buddy *b = r->b;
- SilcClient client = r->client;
- SilcClientEntry client_entry;
- SilcAttributePayload attr;
-@@ -760,7 +760,7 @@ silcgaim_add_buddy_save(bool success, vo
-
- if (!success) {
- /* The user did not trust the public key. */
-- silcgaim_add_buddy_pk_no(r);
-+ silcgaim2_add_buddy_pk_no(r);
- silc_free(r);
- return;
- }
-@@ -775,9 +775,9 @@ silcgaim_add_buddy_save(bool success, vo
- fingerprint[i] = '_';
- g_snprintf(filename, sizeof(filename) - 1,
- "%s" G_DIR_SEPARATOR_S "clientkeys" G_DIR_SEPARATOR_S "clientkey_%s.pub",
-- silcgaim_silcdir(), fingerprint);
-- gaim_blist_node_set_string((GaimBlistNode *)b, "public-key", filename);
-- gaim_prpl_got_user_status(gaim_buddy_get_account(r->b), gaim_buddy_get_name(r->b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
-+ silcgaim2_silcdir(), fingerprint);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *)b, "public-key", filename);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(r->b), gaim2_buddy_get_name(r->b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
- silc_free(fingerprint);
- silc_free(r->offline_pk);
- silc_free(r);
-@@ -916,7 +916,7 @@ silcgaim_add_buddy_save(bool success, vo
- tmp = fingerprint + strlen(fingerprint) - 9;
- g_snprintf(filename, sizeof(filename) - 1,
- "%s" G_DIR_SEPARATOR_S "friends" G_DIR_SEPARATOR_S "%s",
-- silcgaim_silcdir(), tmp);
-+ silcgaim2_silcdir(), tmp);
-
- pw = getpwuid(getuid());
- if (!pw)
-@@ -965,11 +965,11 @@ silcgaim_add_buddy_save(bool success, vo
- memset(filename, 0, sizeof(filename));
- g_snprintf(filename, sizeof(filename) - 1,
- "%s" G_DIR_SEPARATOR_S "clientkeys" G_DIR_SEPARATOR_S "clientkey_%s.pub",
-- silcgaim_silcdir(), fingerprint);
-- gaim_blist_node_set_string((GaimBlistNode *)b, "public-key", filename);
-+ silcgaim2_silcdir(), fingerprint);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *)b, "public-key", filename);
-
- /* Update online status */
-- gaim_prpl_got_user_status(gaim_buddy_get_account(r->b), gaim_buddy_get_name(r->b), SILCGAIM_STATUS_ID_AVAILABLE, NULL);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(r->b), gaim2_buddy_get_name(r->b), SILCGAIM_STATUS_ID_AVAILABLE, NULL);
-
- /* Finally, start watching this user so we receive its status
- changes from the server */
-@@ -982,70 +982,70 @@ silcgaim_add_buddy_save(bool success, vo
- }
-
- static void
--silcgaim_add_buddy_ask_import(void *user_data, const char *name)
-+silcgaim2_add_buddy_ask_import(void *user_data, const char *name)
- {
-- SilcGaimBuddyRes r = (SilcGaimBuddyRes)user_data;
-+ SilcGaim2BuddyRes r = (SilcGaim2BuddyRes)user_data;
- SilcPublicKey public_key;
-
- /* Load the public key */
- if (!silc_pkcs_load_public_key(name, &public_key, SILC_PKCS_FILE_PEM) &&
- !silc_pkcs_load_public_key(name, &public_key, SILC_PKCS_FILE_BIN)) {
-- silcgaim_add_buddy_ask_pk_cb(r, 0);
-- gaim_notify_error(r->client->application,
-+ silcgaim2_add_buddy_ask_pk_cb(r, 0);
-+ gaim2_notify_error(r->client->application,
- _("Add Buddy"), _("Could not load public key"), NULL);
- return;
- }
-
- /* Now verify the public key */
- r->offline_pk = silc_pkcs_public_key_encode(public_key, &r->offline_pk_len);
-- silcgaim_verify_public_key(r->client, r->conn, r->b->name,
-+ silcgaim2_verify_public_key(r->client, r->conn, r->b->name,
- SILC_SOCKET_TYPE_CLIENT,
- r->offline_pk, r->offline_pk_len,
- SILC_SKE_PK_TYPE_SILC,
-- silcgaim_add_buddy_save, r);
-+ silcgaim2_add_buddy_save, r);
- }
-
- static void
--silcgaim_add_buddy_ask_pk_cancel(void *user_data, const char *name)
-+silcgaim2_add_buddy_ask_pk_cancel(void *user_data, const char *name)
- {
-- SilcGaimBuddyRes r = (SilcGaimBuddyRes)user_data;
-+ SilcGaim2BuddyRes r = (SilcGaim2BuddyRes)user_data;
-
- /* The user did not import public key. The buddy is unusable. */
-- silcgaim_add_buddy_pk_no(r);
-+ silcgaim2_add_buddy_pk_no(r);
- silc_free(r);
- }
-
- static void
--silcgaim_add_buddy_ask_pk_cb(SilcGaimBuddyRes r, gint id)
-+silcgaim2_add_buddy_ask_pk_cb(SilcGaim2BuddyRes r, gint id)
- {
- if (id != 0) {
- /* The user did not import public key. The buddy is unusable. */
-- silcgaim_add_buddy_pk_no(r);
-+ silcgaim2_add_buddy_pk_no(r);
- silc_free(r);
- return;
- }
-
- /* Open file selector to select the public key. */
-- gaim_request_file(r->client->application, _("Open..."), NULL, FALSE,
-- G_CALLBACK(silcgaim_add_buddy_ask_import),
-- G_CALLBACK(silcgaim_add_buddy_ask_pk_cancel), r);
-+ gaim2_request_file(r->client->application, _("Open..."), NULL, FALSE,
-+ G_CALLBACK(silcgaim2_add_buddy_ask_import),
-+ G_CALLBACK(silcgaim2_add_buddy_ask_pk_cancel), r);
- }
-
- static void
--silcgaim_add_buddy_ask_pk(SilcGaimBuddyRes r)
-+silcgaim2_add_buddy_ask_pk(SilcGaim2BuddyRes r)
- {
- char tmp[512];
- g_snprintf(tmp, sizeof(tmp), _("The %s buddy is not present in the network"),
- r->b->name);
-- gaim_request_action(r->client->application, _("Add Buddy"), tmp,
-+ gaim2_request_action(r->client->application, _("Add Buddy"), tmp,
- _("To add the buddy you must import his/her public key. "
- "Press Import to import a public key."), 0, r, 2,
-- _("Cancel"), G_CALLBACK(silcgaim_add_buddy_ask_pk_cb),
-- _("_Import..."), G_CALLBACK(silcgaim_add_buddy_ask_pk_cb));
-+ _("Cancel"), G_CALLBACK(silcgaim2_add_buddy_ask_pk_cb),
-+ _("_Import..."), G_CALLBACK(silcgaim2_add_buddy_ask_pk_cb));
- }
-
- static void
--silcgaim_add_buddy_getkey_cb(SilcGaimBuddyRes r,
-+silcgaim2_add_buddy_getkey_cb(SilcGaim2BuddyRes r,
- SilcClientCommandReplyContext cmd)
- {
- SilcClientEntry client_entry;
-@@ -1060,65 +1060,65 @@ silcgaim_add_buddy_getkey_cb(SilcGaimBud
- to associate a public key with the buddy or the buddy
- cannot be added. */
- r->offline = TRUE;
-- silcgaim_add_buddy_ask_pk(r);
-+ silcgaim2_add_buddy_ask_pk(r);
- return;
- }
-
- /* Now verify the public key */
- pk = silc_pkcs_public_key_encode(client_entry->public_key, &pk_len);
-- silcgaim_verify_public_key(r->client, r->conn, client_entry->nickname,
-+ silcgaim2_verify_public_key(r->client, r->conn, client_entry->nickname,
- SILC_SOCKET_TYPE_CLIENT,
- pk, pk_len, SILC_SKE_PK_TYPE_SILC,
-- silcgaim_add_buddy_save, r);
-+ silcgaim2_add_buddy_save, r);
- silc_free(pk);
- }
-
- static void
--silcgaim_add_buddy_select_cb(SilcGaimBuddyRes r, GaimRequestFields *fields)
-+silcgaim2_add_buddy_select_cb(SilcGaim2BuddyRes r, Gaim2RequestFields *fields)
- {
-- GaimRequestField *f;
-+ Gaim2RequestField *f;
- const GList *list;
- SilcClientEntry client_entry;
-
-- f = gaim_request_fields_get_field(fields, "list");
-- list = gaim_request_field_list_get_selected(f);
-+ f = gaim2_request_fields_get_field(fields, "list");
-+ list = gaim2_request_field_list_get_selected(f);
- if (!list) {
- /* The user did not select any user. */
-- silcgaim_add_buddy_pk_no(r);
-+ silcgaim2_add_buddy_pk_no(r);
- silc_free(r);
- return;
- }
-
-- client_entry = gaim_request_field_list_get_data(f, list->data);
-- silcgaim_add_buddy_resolved(r->client, r->conn, &client_entry, 1, r);
-+ client_entry = gaim2_request_field_list_get_data(f, list->data);
-+ silcgaim2_add_buddy_resolved(r->client, r->conn, &client_entry, 1, r);
- }
-
- static void
--silcgaim_add_buddy_select_cancel(SilcGaimBuddyRes r, GaimRequestFields *fields)
-+silcgaim2_add_buddy_select_cancel(SilcGaim2BuddyRes r, Gaim2RequestFields *fields)
- {
- /* The user did not select any user. */
-- silcgaim_add_buddy_pk_no(r);
-+ silcgaim2_add_buddy_pk_no(r);
- silc_free(r);
- }
-
- static void
--silcgaim_add_buddy_select(SilcGaimBuddyRes r,
-+silcgaim2_add_buddy_select(SilcGaim2BuddyRes r,
- SilcClientEntry *clients,
- SilcUInt32 clients_count)
- {
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
- char tmp[512], tmp2[128];
- int i;
- char *fingerprint;
-
-- fields = gaim_request_fields_new();
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_list_new("list", NULL);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_field_list_set_multi_select(f, FALSE);
-- gaim_request_fields_add_group(fields, g);
-+ fields = gaim2_request_fields_new();
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_list_new("list", NULL);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_field_list_set_multi_select(f, FALSE);
-+ gaim2_request_fields_add_group(fields, g);
-
- for (i = 0; i < clients_count; i++) {
- fingerprint = NULL;
-@@ -1132,11 +1132,11 @@ silcgaim_add_buddy_select(SilcGaimBuddyR
- clients[i]->username, clients[i]->hostname ?
- clients[i]->hostname : "",
- fingerprint ? tmp2 : "");
-- gaim_request_field_list_add(f, tmp, clients[i]);
-+ gaim2_request_field_list_add(f, tmp, clients[i]);
- silc_free(fingerprint);
- }
-
-- gaim_request_fields(r->client->application, _("Add Buddy"),
-+ gaim2_request_fields(r->client->application, _("Add Buddy"),
- _("Select correct user"),
- r->pubkey_search
- ? _("More than one user was found with the same public key. Select "
-@@ -1144,26 +1144,26 @@ silcgaim_add_buddy_select(SilcGaimBuddyR
- : _("More than one user was found with the same name. Select "
- "the correct user from the list to add to the buddy list."),
- fields,
-- _("OK"), G_CALLBACK(silcgaim_add_buddy_select_cb),
-- _("Cancel"), G_CALLBACK(silcgaim_add_buddy_select_cancel), r);
-+ _("OK"), G_CALLBACK(silcgaim2_add_buddy_select_cb),
-+ _("Cancel"), G_CALLBACK(silcgaim2_add_buddy_select_cancel), r);
- }
-
- static void
--silcgaim_add_buddy_resolved(SilcClient client,
-+silcgaim2_add_buddy_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context)
- {
-- SilcGaimBuddyRes r = context;
-- GaimBuddy *b = r->b;
-+ SilcGaim2BuddyRes r = context;
-+ Gaim2Buddy *b = r->b;
- SilcAttributePayload pub;
- SilcAttributeObjPk userpk;
- unsigned char *pk;
- SilcUInt32 pk_len;
- const char *filename;
-
-- filename = gaim_blist_node_get_string((GaimBlistNode *)b, "public-key");
-+ filename = gaim2_blist_node_get_string((Gaim2BlistNode *)b, "public-key");
-
- /* If the buddy is offline/nonexistent, we will require user
- to associate a public key with the buddy or the buddy
-@@ -1178,9 +1178,9 @@ silcgaim_add_buddy_resolved(SilcClient c
- /* If the user has already associated a public key, try loading it
- * before prompting the user to load it again */
- if (filename != NULL)
-- silcgaim_add_buddy_ask_import(r, filename);
-+ silcgaim2_add_buddy_ask_import(r, filename);
- else
-- silcgaim_add_buddy_ask_pk(r);
-+ silcgaim2_add_buddy_ask_pk(r);
- return;
- }
-
-@@ -1192,7 +1192,7 @@ silcgaim_add_buddy_resolved(SilcClient c
- return;
- }
-
-- silcgaim_add_buddy_select(r, clients, clients_count);
-+ silcgaim2_add_buddy_select(r, clients, clients_count);
- return;
- }
-
-@@ -1212,7 +1212,7 @@ silcgaim_add_buddy_resolved(SilcClient c
- }
- } else {
- /* Verify from user which one is correct */
-- silcgaim_add_buddy_select(r, clients, clients_count);
-+ silcgaim2_add_buddy_select(r, clients, clients_count);
- return;
- }
- }
-@@ -1226,7 +1226,7 @@ silcgaim_add_buddy_resolved(SilcClient c
- /* Get the public key from attributes, if not present then
- resolve it with GETKEY unless we have it cached already. */
- if (clients[0]->attrs && !clients[0]->public_key) {
-- pub = silcgaim_get_attr(clients[0]->attrs,
-+ pub = silcgaim2_get_attr(clients[0]->attrs,
- SILC_ATTRIBUTE_USER_PUBLIC_KEY);
- if (!pub || !silc_attribute_get_object(pub, (void *)&userpk,
- sizeof(userpk))) {
-@@ -1235,7 +1235,7 @@ silcgaim_add_buddy_resolved(SilcClient c
- "GETKEY", clients[0]->nickname, NULL);
- silc_client_command_pending(conn, SILC_COMMAND_GETKEY,
- conn->cmd_ident,
-- (SilcCommandCb)silcgaim_add_buddy_getkey_cb,
-+ (SilcCommandCb)silcgaim2_add_buddy_getkey_cb,
- r);
- return;
- }
-@@ -1253,7 +1253,7 @@ silcgaim_add_buddy_resolved(SilcClient c
- "GETKEY", clients[0]->nickname, NULL);
- silc_client_command_pending(conn, SILC_COMMAND_GETKEY,
- conn->cmd_ident,
-- (SilcCommandCb)silcgaim_add_buddy_getkey_cb,
-+ (SilcCommandCb)silcgaim2_add_buddy_getkey_cb,
- r);
- return;
- }
-@@ -1263,27 +1263,27 @@ silcgaim_add_buddy_resolved(SilcClient c
- "GETKEY", clients[0]->nickname, NULL);
- silc_client_command_pending(conn, SILC_COMMAND_GETKEY,
- conn->cmd_ident,
-- (SilcCommandCb)silcgaim_add_buddy_getkey_cb,
-+ (SilcCommandCb)silcgaim2_add_buddy_getkey_cb,
- r);
- return;
- }
-
- /* We have the public key, verify it. */
- pk = silc_pkcs_public_key_encode(clients[0]->public_key, &pk_len);
-- silcgaim_verify_public_key(client, conn, clients[0]->nickname,
-+ silcgaim2_verify_public_key(client, conn, clients[0]->nickname,
- SILC_SOCKET_TYPE_CLIENT,
- pk, pk_len, SILC_SKE_PK_TYPE_SILC,
-- silcgaim_add_buddy_save, r);
-+ silcgaim2_add_buddy_save, r);
- silc_free(pk);
- }
-
- static void
--silcgaim_add_buddy_i(GaimConnection *gc, GaimBuddy *b, gboolean init)
-+silcgaim2_add_buddy_i(Gaim2Connection *gc, Gaim2Buddy *b, gboolean init)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
-- SilcGaimBuddyRes r;
-+ SilcGaim2BuddyRes r;
- SilcBuffer attrs;
- const char *filename, *name = b->name;
-
-@@ -1297,7 +1297,7 @@ silcgaim_add_buddy_i(GaimConnection *gc,
-
- /* See if we have this buddy's public key. If we do use that
- to search the details. */
-- filename = gaim_blist_node_get_string((GaimBlistNode *)b, "public-key");
-+ filename = gaim2_blist_node_get_string((Gaim2BlistNode *)b, "public-key");
- if (filename) {
- SilcPublicKey public_key;
- SilcAttributeObjPk userpk;
-@@ -1336,25 +1336,25 @@ silcgaim_add_buddy_i(GaimConnection *gc,
-
- /* Resolve */
- silc_client_get_clients_whois(client, conn, name, NULL, attrs,
-- silcgaim_add_buddy_resolved, r);
-+ silcgaim2_add_buddy_resolved, r);
- silc_buffer_free(attrs);
- }
-
--void silcgaim_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+void silcgaim2_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
-- silcgaim_add_buddy_i(gc, buddy, FALSE);
-+ silcgaim2_add_buddy_i(gc, buddy, FALSE);
- }
-
--void silcgaim_send_buddylist(GaimConnection *gc)
-+void silcgaim2_send_buddylist(Gaim2Connection *gc)
- {
-- GaimBuddyList *blist;
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *buddy;
-- GaimAccount *account;
-+ Gaim2BuddyList *blist;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *buddy;
-+ Gaim2Account *account;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- if ((blist = gaim_get_blist()) != NULL)
-+ if ((blist = gaim2_get_blist()) != NULL)
- {
- for (gnode = blist->root; gnode != NULL; gnode = gnode->next)
- {
-@@ -1368,34 +1368,34 @@ void silcgaim_send_buddylist(GaimConnect
- {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- buddy = (GaimBuddy *)bnode;
-- if (gaim_buddy_get_account(buddy) == account)
-- silcgaim_add_buddy_i(gc, buddy, TRUE);
-+ buddy = (Gaim2Buddy *)bnode;
-+ if (gaim2_buddy_get_account(buddy) == account)
-+ silcgaim2_add_buddy_i(gc, buddy, TRUE);
- }
- }
- }
- }
- }
-
--void silcgaim_remove_buddy(GaimConnection *gc, GaimBuddy *buddy,
-- GaimGroup *group)
-+void silcgaim2_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy,
-+ Gaim2Group *group)
- {
- silc_free(buddy->proto_data);
- }
-
--void silcgaim_idle_set(GaimConnection *gc, int idle)
-+void silcgaim2_idle_set(Gaim2Connection *gc, int idle)
-
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcAttributeObjService service;
- const char *server;
- int port;
-
-- server = gaim_account_get_string(sg->account, "server",
-+ server = gaim2_account_get_string(sg->account, "server",
- "silc.silcnet.org");
-- port = gaim_account_get_int(sg->account, "port", 706),
-+ port = gaim2_account_get_int(sg->account, "port", 706),
-
- memset(&service, 0, sizeof(service));
- silc_client_attribute_del(client, conn,
-@@ -1407,9 +1407,9 @@ void silcgaim_idle_set(GaimConnection *g
- &service, sizeof(service));
- }
-
--char *silcgaim_status_text(GaimBuddy *b)
-+char *silcgaim2_status_text(Gaim2Buddy *b)
- {
-- SilcGaim sg = b->account->gc->proto_data;
-+ SilcGaim2 sg = b->account->gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcClientID *client_id = b->proto_data;
-@@ -1440,7 +1440,7 @@ char *silcgaim_status_text(GaimBuddy *b)
- if (client_entry->mode & SILC_UMODE_ROBOT)
- return g_strdup(_("Robot"));
-
-- attr = silcgaim_get_attr(client_entry->attrs, SILC_ATTRIBUTE_STATUS_MOOD);
-+ attr = silcgaim2_get_attr(client_entry->attrs, SILC_ATTRIBUTE_STATUS_MOOD);
- if (attr && silc_attribute_get_object(attr, &mood, sizeof(mood))) {
- /* The mood is a bit mask, so we could show multiple moods,
- but let's show only one for now. */
-@@ -1471,9 +1471,9 @@ char *silcgaim_status_text(GaimBuddy *b)
- return NULL;
- }
-
--char *silcgaim_tooltip_text(GaimBuddy *b)
-+char *silcgaim2_tooltip_text(Gaim2Buddy *b)
- {
-- SilcGaim sg = b->account->gc->proto_data;
-+ SilcGaim2 sg = b->account->gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcClientID *client_id = b->proto_data;
-@@ -1499,12 +1499,12 @@ char *silcgaim_tooltip_text(GaimBuddy *b
- if (client_entry->mode) {
- g_string_append_printf(s, "\n<b>%s:</b> ", _("User Modes"));
- memset(tmp, 0, sizeof(tmp));
-- silcgaim_get_umode_string(client_entry->mode,
-+ silcgaim2_get_umode_string(client_entry->mode,
- tmp, sizeof(tmp) - strlen(tmp));
- g_string_append_printf(s, "%s", tmp);
- }
-
-- silcgaim_parse_attrs(client_entry->attrs, &moodstr, &statusstr, &contactstr, &langstr, &devicestr, &tzstr, &geostr);
-+ silcgaim2_parse_attrs(client_entry->attrs, &moodstr, &statusstr, &contactstr, &langstr, &devicestr, &tzstr, &geostr);
- if (moodstr) {
- g_string_append_printf(s, "\n<b>%s:</b> %s", _("Mood"), moodstr);
- g_free(moodstr);
-@@ -1544,16 +1544,16 @@ char *silcgaim_tooltip_text(GaimBuddy *b
- }
-
- static void
--silcgaim_buddy_kill(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_kill(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *b;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Buddy *b;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- b = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(b->account);
-+ b = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(b->account);
- sg = gc->proto_data;
-
- /* Call KILL */
-@@ -1562,65 +1562,65 @@ silcgaim_buddy_kill(GaimBlistNode *node,
- }
-
- typedef struct {
-- SilcGaim sg;
-+ SilcGaim2 sg;
- SilcClientEntry client_entry;
--} *SilcGaimBuddyWb;
-+} *SilcGaim2BuddyWb;
-
- static void
--silcgaim_buddy_wb(GaimBlistNode *node, gpointer data)
-+silcgaim2_buddy_wb(Gaim2BlistNode *node, gpointer data)
- {
-- SilcGaimBuddyWb wb = data;
-- silcgaim_wb_init(wb->sg, wb->client_entry);
-+ SilcGaim2BuddyWb wb = data;
-+ silcgaim2_wb_init(wb->sg, wb->client_entry);
- silc_free(wb);
- }
-
--GList *silcgaim_buddy_menu(GaimBuddy *buddy)
-+GList *silcgaim2_buddy_menu(Gaim2Buddy *buddy)
- {
-- GaimConnection *gc = gaim_account_get_connection(buddy->account);
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = gaim2_account_get_connection(buddy->account);
-+ SilcGaim2 sg = gc->proto_data;
- SilcClientConnection conn = sg->conn;
- const char *pkfile = NULL;
- SilcClientEntry client_entry = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
- GList *m = NULL;
-- SilcGaimBuddyWb wb;
-+ SilcGaim2BuddyWb wb;
-
-- pkfile = gaim_blist_node_get_string((GaimBlistNode *) buddy, "public-key");
-+ pkfile = gaim2_blist_node_get_string((Gaim2BlistNode *) buddy, "public-key");
- client_entry = silc_client_get_client_by_id(sg->client,
- sg->conn,
- buddy->proto_data);
-
- if (client_entry && client_entry->send_key) {
-- act = gaim_blist_node_action_new(_("Reset IM Key"),
-- silcgaim_buddy_resetkey, NULL, NULL);
-+ act = gaim2_blist_node_action_new(_("Reset IM Key"),
-+ silcgaim2_buddy_resetkey, NULL, NULL);
- m = g_list_append(m, act);
-
- } else {
-- act = gaim_blist_node_action_new(_("IM with Key Exchange"),
-- silcgaim_buddy_keyagr, NULL, NULL);
-+ act = gaim2_blist_node_action_new(_("IM with Key Exchange"),
-+ silcgaim2_buddy_keyagr, NULL, NULL);
- m = g_list_append(m, act);
-
-- act = gaim_blist_node_action_new(_("IM with Password"),
-- silcgaim_buddy_privkey_menu,
-+ act = gaim2_blist_node_action_new(_("IM with Password"),
-+ silcgaim2_buddy_privkey_menu,
- NULL, NULL);
- m = g_list_append(m, act);
- }
-
- if (pkfile) {
-- act = gaim_blist_node_action_new(_("Show Public Key"),
-- silcgaim_buddy_showkey, NULL, NULL);
-+ act = gaim2_blist_node_action_new(_("Show Public Key"),
-+ silcgaim2_buddy_showkey, NULL, NULL);
- m = g_list_append(m, act);
-
- } else {
-- act = gaim_blist_node_action_new(_("Get Public Key..."),
-- silcgaim_buddy_getkey_menu,
-+ act = gaim2_blist_node_action_new(_("Get Public Key..."),
-+ silcgaim2_buddy_getkey_menu,
- NULL, NULL);
- m = g_list_append(m, act);
- }
-
- if (conn && conn->local_entry->mode & SILC_UMODE_ROUTER_OPERATOR) {
-- act = gaim_blist_node_action_new(_("Kill User"),
-- silcgaim_buddy_kill, NULL, NULL);
-+ act = gaim2_blist_node_action_new(_("Kill User"),
-+ silcgaim2_buddy_kill, NULL, NULL);
- m = g_list_append(m, act);
- }
-
-@@ -1628,8 +1628,8 @@ GList *silcgaim_buddy_menu(GaimBuddy *bu
- wb = silc_calloc(1, sizeof(*wb));
- wb->sg = sg;
- wb->client_entry = client_entry;
-- act = gaim_blist_node_action_new(_("Draw On Whiteboard"),
-- silcgaim_buddy_wb, (void *)wb, NULL);
-+ act = gaim2_blist_node_action_new(_("Draw On Whiteboard"),
-+ silcgaim2_buddy_wb, (void *)wb, NULL);
- m = g_list_append(m, act);
- }
- return m;
-diff -prNu ./src/protocols/silc/chat.c ./src/protocols/silc/chat.c
---- ./src/protocols/silc/chat.c 2005-12-04 18:47:05.000000000 +0100
-+++ ./src/protocols/silc/chat.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim_chat.c
-+ silcgaim2_chat.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,12 +19,12 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "wb.h"
-
- /***************************** Channel Routines ******************************/
-
--GList *silcgaim_chat_info(GaimConnection *gc)
-+GList *silcgaim2_chat_info(Gaim2Connection *gc)
- {
- GList *ci = NULL;
- struct proto_chat_entry *pce;
-@@ -44,7 +44,7 @@ GList *silcgaim_chat_info(GaimConnection
- return ci;
- }
-
--GHashTable *silcgaim_chat_info_defaults(GaimConnection *gc, const char *chat_name)
-+GHashTable *silcgaim2_chat_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
-
-@@ -57,17 +57,17 @@ GHashTable *silcgaim_chat_info_defaults(
- }
-
- static void
--silcgaim_chat_getinfo(GaimConnection *gc, GHashTable *components);
-+silcgaim2_chat_getinfo(Gaim2Connection *gc, GHashTable *components);
-
- static void
--silcgaim_chat_getinfo_res(SilcClient client,
-+silcgaim2_chat_getinfo_res(SilcClient client,
- SilcClientConnection conn,
- SilcChannelEntry *channels,
- SilcUInt32 channels_count,
- void *context)
- {
- GHashTable *components = context;
-- GaimConnection *gc = client->application;
-+ Gaim2Connection *gc = client->application;
- const char *chname;
- char tmp[256];
-
-@@ -78,19 +78,19 @@ silcgaim_chat_getinfo_res(SilcClient cli
- if (!channels) {
- g_snprintf(tmp, sizeof(tmp),
- _("Channel %s does not exist in the network"), chname);
-- gaim_notify_error(gc, _("Channel Information"),
-+ gaim2_notify_error(gc, _("Channel Information"),
- _("Cannot get channel information"), tmp);
- return;
- }
-
-- silcgaim_chat_getinfo(gc, components);
-+ silcgaim2_chat_getinfo(gc, components);
- }
-
-
- static void
--silcgaim_chat_getinfo(GaimConnection *gc, GHashTable *components)
-+silcgaim2_chat_getinfo(Gaim2Connection *gc, GHashTable *components)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- const char *chname;
- char *buf, tmp[256], *tmp2;
- GString *s;
-@@ -109,7 +109,7 @@ silcgaim_chat_getinfo(GaimConnection *gc
- if (!channel) {
- silc_client_get_channel_resolve(sg->client, sg->conn,
- (char *)chname,
-- silcgaim_chat_getinfo_res,
-+ silcgaim2_chat_getinfo_res,
- components);
- return;
- }
-@@ -149,7 +149,7 @@ silcgaim_chat_getinfo(GaimConnection *gc
-
- if (channel->mode) {
- g_string_append_printf(s, _("<br><b>Channel Modes:</b> "));
-- silcgaim_get_chmode_string(channel->mode, tmp, sizeof(tmp));
-+ silcgaim2_get_chmode_string(channel->mode, tmp, sizeof(tmp));
- g_string_append(s, tmp);
- }
-
-@@ -170,25 +170,25 @@ silcgaim_chat_getinfo(GaimConnection *gc
- }
-
- buf = g_string_free(s, FALSE);
-- gaim_notify_formatted(gc, NULL, _("Channel Information"), NULL, buf, NULL, NULL);
-+ gaim2_notify_formatted(gc, NULL, _("Channel Information"), NULL, buf, NULL, NULL);
- g_free(buf);
- }
-
-
- static void
--silcgaim_chat_getinfo_menu(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_getinfo_menu(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat = (GaimChat *)node;
-- silcgaim_chat_getinfo(chat->account->gc, chat->components);
-+ Gaim2Chat *chat = (Gaim2Chat *)node;
-+ silcgaim2_chat_getinfo(chat->account->gc, chat->components);
- }
-
-
- #if 0 /* XXX For now these are not implemented. We need better
-- listview dialog from Gaim for these. */
-+ listview dialog from Gaim2 for these. */
- /************************** Channel Invite List ******************************/
-
- static void
--silcgaim_chat_invitelist(GaimBlistNode *node, gpointer data);
-+silcgaim2_chat_invitelist(Gaim2BlistNode *node, gpointer data);
- {
-
- }
-@@ -197,7 +197,7 @@ silcgaim_chat_invitelist(GaimBlistNode *
- /**************************** Channel Ban List *******************************/
-
- static void
--silcgaim_chat_banlist(GaimBlistNode *node, gpointer data);
-+silcgaim2_chat_banlist(Gaim2BlistNode *node, gpointer data);
- {
-
- }
-@@ -207,17 +207,17 @@ silcgaim_chat_banlist(GaimBlistNode *nod
- /************************* Channel Authentication ****************************/
-
- typedef struct {
-- SilcGaim sg;
-+ SilcGaim2 sg;
- SilcChannelEntry channel;
-- GaimChat *c;
-+ Gaim2Chat *c;
- SilcBuffer pubkeys;
--} *SilcGaimChauth;
-+} *SilcGaim2Chauth;
-
- static void
--silcgaim_chat_chpk_add(void *user_data, const char *name)
-+silcgaim2_chat_chpk_add(void *user_data, const char *name)
- {
-- SilcGaimChauth sgc = (SilcGaimChauth)user_data;
-- SilcGaim sg = sgc->sg;
-+ SilcGaim2Chauth sgc = (SilcGaim2Chauth)user_data;
-+ SilcGaim2 sg = sgc->sg;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcPublicKey public_key;
-@@ -228,10 +228,10 @@ silcgaim_chat_chpk_add(void *user_data,
- /* Load the public key */
- if (!silc_pkcs_load_public_key(name, &public_key, SILC_PKCS_FILE_PEM) &&
- !silc_pkcs_load_public_key(name, &public_key, SILC_PKCS_FILE_BIN)) {
-- silcgaim_chat_chauth_show(sgc->sg, sgc->channel, sgc->pubkeys);
-+ silcgaim2_chat_chauth_show(sgc->sg, sgc->channel, sgc->pubkeys);
- silc_buffer_free(sgc->pubkeys);
- silc_free(sgc);
-- gaim_notify_error(client->application,
-+ gaim2_notify_error(client->application,
- _("Add Channel Public Key"),
- _("Could not load public key"), NULL);
- return;
-@@ -262,21 +262,21 @@ silcgaim_chat_chpk_add(void *user_data,
- }
-
- static void
--silcgaim_chat_chpk_cancel(void *user_data, const char *name)
-+silcgaim2_chat_chpk_cancel(void *user_data, const char *name)
- {
-- SilcGaimChauth sgc = (SilcGaimChauth)user_data;
-- silcgaim_chat_chauth_show(sgc->sg, sgc->channel, sgc->pubkeys);
-+ SilcGaim2Chauth sgc = (SilcGaim2Chauth)user_data;
-+ silcgaim2_chat_chauth_show(sgc->sg, sgc->channel, sgc->pubkeys);
- silc_buffer_free(sgc->pubkeys);
- silc_free(sgc);
- }
-
- static void
--silcgaim_chat_chpk_cb(SilcGaimChauth sgc, GaimRequestFields *fields)
-+silcgaim2_chat_chpk_cb(SilcGaim2Chauth sgc, Gaim2RequestFields *fields)
- {
-- SilcGaim sg = sgc->sg;
-+ SilcGaim2 sg = sgc->sg;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
-- GaimRequestField *f;
-+ Gaim2RequestField *f;
- const GList *list;
- SilcPublicKey public_key;
- SilcBuffer chpks, pk, chidp;
-@@ -284,21 +284,21 @@ silcgaim_chat_chpk_cb(SilcGaimChauth sgc
- unsigned char mode[4];
- SilcUInt32 m;
-
-- f = gaim_request_fields_get_field(fields, "list");
-- if (!gaim_request_field_list_get_selected(f)) {
-+ f = gaim2_request_fields_get_field(fields, "list");
-+ if (!gaim2_request_field_list_get_selected(f)) {
- /* Add new public key */
-- gaim_request_file(sg->gc, _("Open Public Key..."), NULL, FALSE,
-- G_CALLBACK(silcgaim_chat_chpk_add),
-- G_CALLBACK(silcgaim_chat_chpk_cancel), sgc);
-+ gaim2_request_file(sg->gc, _("Open Public Key..."), NULL, FALSE,
-+ G_CALLBACK(silcgaim2_chat_chpk_add),
-+ G_CALLBACK(silcgaim2_chat_chpk_cancel), sgc);
- return;
- }
-
-- list = gaim_request_field_list_get_items(f);
-+ list = gaim2_request_field_list_get_items(f);
- chpks = silc_buffer_alloc_size(2);
-
- for (ct = 0; list; list = list->next, ct++) {
-- public_key = gaim_request_field_list_get_data(f, list->data);
-- if (gaim_request_field_list_is_selected(f, list->data)) {
-+ public_key = gaim2_request_field_list_get_data(f, list->data);
-+ if (gaim2_request_field_list_is_selected(f, list->data)) {
- /* Delete this public key */
- pk = silc_pkcs_public_key_payload_encode(public_key);
- chpks = silc_argument_payload_encode_one(chpks, pk->data,
-@@ -333,16 +333,16 @@ silcgaim_chat_chpk_cb(SilcGaimChauth sgc
- }
-
- static void
--silcgaim_chat_chauth_ok(SilcGaimChauth sgc, GaimRequestFields *fields)
-+silcgaim2_chat_chauth_ok(SilcGaim2Chauth sgc, Gaim2RequestFields *fields)
- {
-- SilcGaim sg = sgc->sg;
-- GaimRequestField *f;
-+ SilcGaim2 sg = sgc->sg;
-+ Gaim2RequestField *f;
- const char *curpass, *val;
- int set;
-
-- f = gaim_request_fields_get_field(fields, "passphrase");
-- val = gaim_request_field_string_get_value(f);
-- curpass = gaim_blist_node_get_string((GaimBlistNode *)sgc->c, "passphrase");
-+ f = gaim2_request_fields_get_field(fields, "passphrase");
-+ val = gaim2_request_field_string_get_value(f);
-+ curpass = gaim2_blist_node_get_string((Gaim2BlistNode *)sgc->c, "passphrase");
-
- if (!val && curpass)
- set = 0;
-@@ -356,18 +356,18 @@ silcgaim_chat_chauth_ok(SilcGaimChauth s
- if (set == 1) {
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
- sgc->channel->channel_name, "+a", val, NULL);
-- gaim_blist_node_set_string((GaimBlistNode *)sgc->c, "passphrase", val);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *)sgc->c, "passphrase", val);
- } else if (set == 0) {
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
- sgc->channel->channel_name, "-a", NULL);
-- gaim_blist_node_remove_setting((GaimBlistNode *)sgc->c, "passphrase");
-+ gaim2_blist_node_remove_setting((Gaim2BlistNode *)sgc->c, "passphrase");
- }
-
- silc_buffer_free(sgc->pubkeys);
- silc_free(sgc);
- }
-
--void silcgaim_chat_chauth_show(SilcGaim sg, SilcChannelEntry channel,
-+void silcgaim2_chat_chauth_show(SilcGaim2 sg, SilcChannelEntry channel,
- SilcBuffer channel_pubkeys)
- {
- SilcUInt16 argc;
-@@ -378,10 +378,10 @@ void silcgaim_chat_chauth_show(SilcGaim
- SilcPublicKey pubkey;
- SilcPublicKeyIdentifier ident;
- char tmp2[1024], t[512];
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-- SilcGaimChauth sgc;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
-+ SilcGaim2Chauth sgc;
- const char *curpass = NULL;
-
- sgc = silc_calloc(1, sizeof(*sgc));
-@@ -390,22 +390,22 @@ void silcgaim_chat_chauth_show(SilcGaim
- sgc->sg = sg;
- sgc->channel = channel;
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
- if (sgc->c)
-- curpass = gaim_blist_node_get_string((GaimBlistNode *)sgc->c, "passphrase");
-+ curpass = gaim2_blist_node_get_string((Gaim2BlistNode *)sgc->c, "passphrase");
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("passphrase", _("Channel Passphrase"),
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("passphrase", _("Channel Passphrase"),
- curpass, FALSE);
-- gaim_request_field_string_set_masked(f, TRUE);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
--
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_label_new("l1", _("Channel Public Keys List"));
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ gaim2_request_field_string_set_masked(f, TRUE);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-+
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_label_new("l1", _("Channel Public Keys List"));
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
- g_snprintf(t, sizeof(t),
- _("Channel authentication is used to secure the channel from "
-@@ -415,20 +415,20 @@ void silcgaim_chat_chauth_show(SilcGaim
- "then only users whose public keys are listed are able to join."));
-
- if (!channel_pubkeys) {
-- f = gaim_request_field_list_new("list", NULL);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields(sg->gc, _("Channel Authentication"),
-+ f = gaim2_request_field_list_new("list", NULL);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields(sg->gc, _("Channel Authentication"),
- _("Channel Authentication"), t, fields,
-- _("Add / Remove"), G_CALLBACK(silcgaim_chat_chpk_cb),
-- _("OK"), G_CALLBACK(silcgaim_chat_chauth_ok), sgc);
-+ _("Add / Remove"), G_CALLBACK(silcgaim2_chat_chpk_cb),
-+ _("OK"), G_CALLBACK(silcgaim2_chat_chauth_ok), sgc);
- return;
- }
- sgc->pubkeys = silc_buffer_copy(channel_pubkeys);
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_list_new("list", NULL);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_list_new("list", NULL);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
- SILC_GET16_MSB(argc, channel_pubkeys->data);
- chpks = silc_argument_payload_parse(channel_pubkeys->data + 2,
-@@ -446,7 +446,7 @@ void silcgaim_chat_chauth_show(SilcGaim
- g_snprintf(tmp2, sizeof(tmp2), "%s\n %s\n %s",
- ident->realname ? ident->realname : ident->username ?
- ident->username : "", fingerprint, babbleprint);
-- gaim_request_field_list_add(f, tmp2, pubkey);
-+ gaim2_request_field_list_add(f, tmp2, pubkey);
-
- silc_free(fingerprint);
- silc_free(babbleprint);
-@@ -454,26 +454,26 @@ void silcgaim_chat_chauth_show(SilcGaim
- pk = silc_argument_get_next_arg(chpks, &type, &pk_len);
- }
-
-- gaim_request_field_list_set_multi_select(f, FALSE);
-- gaim_request_fields(sg->gc, _("Channel Authentication"),
-+ gaim2_request_field_list_set_multi_select(f, FALSE);
-+ gaim2_request_fields(sg->gc, _("Channel Authentication"),
- _("Channel Authentication"), t, fields,
-- _("Add / Remove"), G_CALLBACK(silcgaim_chat_chpk_cb),
-- _("OK"), G_CALLBACK(silcgaim_chat_chauth_ok), sgc);
-+ _("Add / Remove"), G_CALLBACK(silcgaim2_chat_chpk_cb),
-+ _("OK"), G_CALLBACK(silcgaim2_chat_chauth_ok), sgc);
-
- silc_argument_payload_free(chpks);
- }
-
- static void
--silcgaim_chat_chauth(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_chauth(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -492,32 +492,32 @@ silcgaim_chat_chauth(GaimBlistNode *node
- a channel - and thus having multiple private keys on the channel. */
-
- typedef struct {
-- SilcGaim sg;
-- GaimChat *c;
-+ SilcGaim2 sg;
-+ Gaim2Chat *c;
- const char *channel;
--} *SilcGaimCharPrv;
-+} *SilcGaim2CharPrv;
-
- static void
--silcgaim_chat_prv_add(SilcGaimCharPrv p, GaimRequestFields *fields)
-+silcgaim2_chat_prv_add(SilcGaim2CharPrv p, Gaim2RequestFields *fields)
- {
-- SilcGaim sg = p->sg;
-+ SilcGaim2 sg = p->sg;
- char tmp[512];
-- GaimRequestField *f;
-+ Gaim2RequestField *f;
- const char *name, *passphrase, *alias;
- GHashTable *comp;
-- GaimGroup *g;
-- GaimChat *cn;
-+ Gaim2Group *g;
-+ Gaim2Chat *cn;
-
-- f = gaim_request_fields_get_field(fields, "name");
-- name = gaim_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "name");
-+ name = gaim2_request_field_string_get_value(f);
- if (!name) {
- silc_free(p);
- return;
- }
-- f = gaim_request_fields_get_field(fields, "passphrase");
-- passphrase = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "alias");
-- alias = gaim_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "passphrase");
-+ passphrase = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "alias");
-+ alias = gaim2_request_field_string_get_value(f);
-
- /* Add private group to buddy list */
- g_snprintf(tmp, sizeof(tmp), "%s [Private Group]", name);
-@@ -525,42 +525,42 @@ silcgaim_chat_prv_add(SilcGaimCharPrv p,
- g_hash_table_replace(comp, g_strdup("channel"), g_strdup(tmp));
- g_hash_table_replace(comp, g_strdup("passphrase"), g_strdup(passphrase));
-
-- cn = gaim_chat_new(sg->account, alias, comp);
-- g = (GaimGroup *)p->c->node.parent;
-- gaim_blist_add_chat(cn, g, (GaimBlistNode *)p->c);
-+ cn = gaim2_chat_new(sg->account, alias, comp);
-+ g = (Gaim2Group *)p->c->node.parent;
-+ gaim2_blist_add_chat(cn, g, (Gaim2BlistNode *)p->c);
-
- /* Associate to a real channel */
-- gaim_blist_node_set_string((GaimBlistNode *)cn, "parentch", p->channel);
-+ gaim2_blist_node_set_string((Gaim2BlistNode *)cn, "parentch", p->channel);
-
- /* Join the group */
-- silcgaim_chat_join(sg->gc, comp);
-+ silcgaim2_chat_join(sg->gc, comp);
-
- silc_free(p);
- }
-
- static void
--silcgaim_chat_prv_cancel(SilcGaimCharPrv p, GaimRequestFields *fields)
-+silcgaim2_chat_prv_cancel(SilcGaim2CharPrv p, Gaim2RequestFields *fields)
- {
- silc_free(p);
- }
-
- static void
--silcgaim_chat_prv(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_prv(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
--
-- SilcGaimCharPrv p;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-+
-+ SilcGaim2CharPrv p;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
- char tmp[512];
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- p = silc_calloc(1, sizeof(*p));
-@@ -569,47 +569,47 @@ silcgaim_chat_prv(GaimBlistNode *node, g
- p->sg = sg;
-
- p->channel = g_hash_table_lookup(chat->components, "channel");
-- p->c = gaim_blist_find_chat(sg->account, p->channel);
-+ p->c = gaim2_blist_find_chat(sg->account, p->channel);
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("name", _("Group Name"),
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("name", _("Group Name"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_group_add_field(g, f);
-
-- f = gaim_request_field_string_new("passphrase", _("Passphrase"),
-+ f = gaim2_request_field_string_new("passphrase", _("Passphrase"),
- NULL, FALSE);
-- gaim_request_field_string_set_masked(f, TRUE);
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_string_set_masked(f, TRUE);
-+ gaim2_request_field_group_add_field(g, f);
-
-- f = gaim_request_field_string_new("alias", _("Alias"),
-+ f = gaim2_request_field_string_new("alias", _("Alias"),
- NULL, FALSE);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
- g_snprintf(tmp, sizeof(tmp),
- _("Please enter the %s channel private group name and passphrase."),
- p->channel);
-- gaim_request_fields(gc, _("Add Channel Private Group"), NULL, tmp, fields,
-- _("Add"), G_CALLBACK(silcgaim_chat_prv_add),
-- _("Cancel"), G_CALLBACK(silcgaim_chat_prv_cancel), p);
-+ gaim2_request_fields(gc, _("Add Channel Private Group"), NULL, tmp, fields,
-+ _("Add"), G_CALLBACK(silcgaim2_chat_prv_add),
-+ _("Cancel"), G_CALLBACK(silcgaim2_chat_prv_cancel), p);
- }
-
-
- /****************************** Channel Modes ********************************/
-
- static void
--silcgaim_chat_permanent_reset(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_permanent_reset(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -618,17 +618,17 @@ silcgaim_chat_permanent_reset(GaimBlistN
- }
-
- static void
--silcgaim_chat_permanent(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_permanent(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
- const char *channel;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- if (!sg->conn)
-@@ -645,12 +645,12 @@ silcgaim_chat_permanent(GaimBlistNode *n
- }
-
- typedef struct {
-- SilcGaim sg;
-+ SilcGaim2 sg;
- const char *channel;
--} *SilcGaimChatInput;
-+} *SilcGaim2ChatInput;
-
- static void
--silcgaim_chat_ulimit_cb(SilcGaimChatInput s, const char *limit)
-+silcgaim2_chat_ulimit_cb(SilcGaim2ChatInput s, const char *limit)
- {
- SilcChannelEntry channel;
- int ulimit = 0;
-@@ -687,21 +687,21 @@ silcgaim_chat_ulimit_cb(SilcGaimChatInpu
- }
-
- static void
--silcgaim_chat_ulimit(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_ulimit(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
-- SilcGaimChatInput s;
-+ SilcGaim2ChatInput s;
- SilcChannelEntry channel;
- const char *ch;
- char tmp[32];
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- if (!sg->conn)
-@@ -718,24 +718,24 @@ silcgaim_chat_ulimit(GaimBlistNode *node
- s->channel = ch;
- s->sg = sg;
- g_snprintf(tmp, sizeof(tmp), "%d", (int)channel->user_limit);
-- gaim_request_input(gc, _("User Limit"), NULL,
-+ gaim2_request_input(gc, _("User Limit"), NULL,
- _("Set user limit on channel. Set to zero to reset user limit."),
- tmp, FALSE, FALSE, NULL,
-- _("OK"), G_CALLBACK(silcgaim_chat_ulimit_cb),
-- _("Cancel"), G_CALLBACK(silcgaim_chat_ulimit_cb), s);
-+ _("OK"), G_CALLBACK(silcgaim2_chat_ulimit_cb),
-+ _("Cancel"), G_CALLBACK(silcgaim2_chat_ulimit_cb), s);
- }
-
- static void
--silcgaim_chat_resettopic(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_resettopic(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -744,16 +744,16 @@ silcgaim_chat_resettopic(GaimBlistNode *
- }
-
- static void
--silcgaim_chat_settopic(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_settopic(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -762,16 +762,16 @@ silcgaim_chat_settopic(GaimBlistNode *no
- }
-
- static void
--silcgaim_chat_resetprivate(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_resetprivate(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -780,16 +780,16 @@ silcgaim_chat_resetprivate(GaimBlistNode
- }
-
- static void
--silcgaim_chat_setprivate(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_setprivate(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -798,16 +798,16 @@ silcgaim_chat_setprivate(GaimBlistNode *
- }
-
- static void
--silcgaim_chat_resetsecret(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_resetsecret(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -816,16 +816,16 @@ silcgaim_chat_resetsecret(GaimBlistNode
- }
-
- static void
--silcgaim_chat_setsecret(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_setsecret(Gaim2BlistNode *node, gpointer data)
- {
-- GaimChat *chat;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Chat *chat;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_CHAT(node));
-
-- chat = (GaimChat *) node;
-- gc = gaim_account_get_connection(chat->account);
-+ chat = (Gaim2Chat *) node;
-+ gc = gaim2_account_get_connection(chat->account);
- sg = gc->proto_data;
-
- silc_client_command_call(sg->client, sg->conn, NULL, "CMODE",
-@@ -834,23 +834,23 @@ silcgaim_chat_setsecret(GaimBlistNode *n
- }
-
- typedef struct {
-- SilcGaim sg;
-+ SilcGaim2 sg;
- SilcChannelEntry channel;
--} *SilcGaimChatWb;
-+} *SilcGaim2ChatWb;
-
- static void
--silcgaim_chat_wb(GaimBlistNode *node, gpointer data)
-+silcgaim2_chat_wb(Gaim2BlistNode *node, gpointer data)
- {
-- SilcGaimChatWb wb = data;
-- silcgaim_wb_init_ch(wb->sg, wb->channel);
-+ SilcGaim2ChatWb wb = data;
-+ silcgaim2_wb_init_ch(wb->sg, wb->channel);
- silc_free(wb);
- }
-
--GList *silcgaim_chat_menu(GaimChat *chat)
-+GList *silcgaim2_chat_menu(Gaim2Chat *chat)
- {
- GHashTable *components = chat->components;
-- GaimConnection *gc = gaim_account_get_connection(chat->account);
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = gaim2_account_get_connection(chat->account);
-+ SilcGaim2 sg = gc->proto_data;
- SilcClientConnection conn = sg->conn;
- const char *chname = NULL;
- SilcChannelEntry channel = NULL;
-@@ -858,7 +858,7 @@ GList *silcgaim_chat_menu(GaimChat *chat
- SilcUInt32 mode = 0;
-
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
- if (components)
- chname = g_hash_table_lookup(components, "channel");
-@@ -874,102 +874,102 @@ GList *silcgaim_chat_menu(GaimChat *chat
- if (strstr(chname, "[Private Group]"))
- return NULL;
-
-- act = gaim_blist_node_action_new(_("Get Info"),
-- silcgaim_chat_getinfo_menu,
-+ act = gaim2_blist_node_action_new(_("Get Info"),
-+ silcgaim2_chat_getinfo_menu,
- NULL, NULL);
- m = g_list_append(m, act);
-
- #if 0 /* XXX For now these are not implemented. We need better
-- listview dialog from Gaim for these. */
-+ listview dialog from Gaim2 for these. */
- if (mode & SILC_CHANNEL_UMODE_CHANOP) {
-- act = gaim_blist_node_action_new(_("Invite List"),
-- silcgaim_chat_invitelist,
-+ act = gaim2_blist_node_action_new(_("Invite List"),
-+ silcgaim2_chat_invitelist,
- NULL, NULL);
- m = g_list_append(m, act);
-
-- act = gaim_blist_node_action_new(_("Ban List"),
-- silcgaim_chat_banlist,
-+ act = gaim2_blist_node_action_new(_("Ban List"),
-+ silcgaim2_chat_banlist,
- NULL, NULL);
- m = g_list_append(m, act);
- }
- #endif
-
- if (chu) {
-- act = gaim_blist_node_action_new(_("Add Private Group"),
-- silcgaim_chat_prv,
-+ act = gaim2_blist_node_action_new(_("Add Private Group"),
-+ silcgaim2_chat_prv,
- NULL, NULL);
- m = g_list_append(m, act);
- }
-
- if (mode & SILC_CHANNEL_UMODE_CHANFO) {
-- act = gaim_blist_node_action_new(_("Channel Authentication"),
-- silcgaim_chat_chauth,
-+ act = gaim2_blist_node_action_new(_("Channel Authentication"),
-+ silcgaim2_chat_chauth,
- NULL, NULL);
- m = g_list_append(m, act);
-
- if (channel->mode & SILC_CHANNEL_MODE_FOUNDER_AUTH) {
-- act = gaim_blist_node_action_new(_("Reset Permanent"),
-- silcgaim_chat_permanent_reset,
-+ act = gaim2_blist_node_action_new(_("Reset Permanent"),
-+ silcgaim2_chat_permanent_reset,
- NULL, NULL);
- m = g_list_append(m, act);
- } else {
-- act = gaim_blist_node_action_new(_("Set Permanent"),
-- silcgaim_chat_permanent,
-+ act = gaim2_blist_node_action_new(_("Set Permanent"),
-+ silcgaim2_chat_permanent,
- NULL, NULL);
- m = g_list_append(m, act);
- }
- }
-
- if (mode & SILC_CHANNEL_UMODE_CHANOP) {
-- act = gaim_blist_node_action_new(_("Set User Limit"),
-- silcgaim_chat_ulimit,
-+ act = gaim2_blist_node_action_new(_("Set User Limit"),
-+ silcgaim2_chat_ulimit,
- NULL, NULL);
- m = g_list_append(m, act);
-
- if (channel->mode & SILC_CHANNEL_MODE_TOPIC) {
-- act = gaim_blist_node_action_new(_("Reset Topic Restriction"),
-- silcgaim_chat_resettopic,
-+ act = gaim2_blist_node_action_new(_("Reset Topic Restriction"),
-+ silcgaim2_chat_resettopic,
- NULL, NULL);
- m = g_list_append(m, act);
- } else {
-- act = gaim_blist_node_action_new(_("Set Topic Restriction"),
-- silcgaim_chat_settopic,
-+ act = gaim2_blist_node_action_new(_("Set Topic Restriction"),
-+ silcgaim2_chat_settopic,
- NULL, NULL);
- m = g_list_append(m, act);
- }
-
- if (channel->mode & SILC_CHANNEL_MODE_PRIVATE) {
-- act = gaim_blist_node_action_new(_("Reset Private Channel"),
-- silcgaim_chat_resetprivate,
-+ act = gaim2_blist_node_action_new(_("Reset Private Channel"),
-+ silcgaim2_chat_resetprivate,
- NULL, NULL);
- m = g_list_append(m, act);
- } else {
-- act = gaim_blist_node_action_new(_("Set Private Channel"),
-- silcgaim_chat_setprivate,
-+ act = gaim2_blist_node_action_new(_("Set Private Channel"),
-+ silcgaim2_chat_setprivate,
- NULL, NULL);
- m = g_list_append(m, act);
- }
-
- if (channel->mode & SILC_CHANNEL_MODE_SECRET) {
-- act = gaim_blist_node_action_new(_("Reset Secret Channel"),
-- silcgaim_chat_resetsecret,
-+ act = gaim2_blist_node_action_new(_("Reset Secret Channel"),
-+ silcgaim2_chat_resetsecret,
- NULL, NULL);
- m = g_list_append(m, act);
- } else {
-- act = gaim_blist_node_action_new(_("Set Secret Channel"),
-- silcgaim_chat_setsecret,
-+ act = gaim2_blist_node_action_new(_("Set Secret Channel"),
-+ silcgaim2_chat_setsecret,
- NULL, NULL);
- m = g_list_append(m, act);
- }
- }
-
- if (channel) {
-- SilcGaimChatWb wb;
-+ SilcGaim2ChatWb wb;
- wb = silc_calloc(1, sizeof(*wb));
- wb->sg = sg;
- wb->channel = channel;
-- act = gaim_blist_node_action_new(_("Draw On Whiteboard"),
-- silcgaim_chat_wb, (void *)wb, NULL);
-+ act = gaim2_blist_node_action_new(_("Draw On Whiteboard"),
-+ silcgaim2_chat_wb, (void *)wb, NULL);
- m = g_list_append(m, act);
- }
-
-@@ -979,16 +979,16 @@ GList *silcgaim_chat_menu(GaimChat *chat
-
- /******************************* Joining Etc. ********************************/
-
--void silcgaim_chat_join_done(SilcClient client,
-+void silcgaim2_chat_join_done(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
- SilcChannelEntry channel = context;
-- GaimConversation *convo;
-+ Gaim2Conversation *convo;
- SilcUInt32 retry = SILC_PTR_TO_32(channel->context);
- SilcHashTableList htl;
- SilcChannelUser chu;
-@@ -999,14 +999,14 @@ void silcgaim_chat_join_done(SilcClient
- /* Resolving users failed, try again. */
- channel->context = SILC_32_TO_PTR(retry + 1);
- silc_client_get_clients_by_channel(client, conn, channel,
-- silcgaim_chat_join_done, channel);
-+ silcgaim2_chat_join_done, channel);
- return;
- }
-
-- /* Add channel to Gaim */
-+ /* Add channel to Gaim2 */
- channel->context = SILC_32_TO_PTR(++sg->channel_ids);
- serv_got_joined_chat(gc, sg->channel_ids, channel->channel_name);
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- return;
-@@ -1014,7 +1014,7 @@ void silcgaim_chat_join_done(SilcClient
- /* Add all users to channel */
- silc_hash_table_list(channel->user_list, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
-- GaimConvChatBuddyFlags f = GAIM_CBFLAGS_NONE;
-+ Gaim2ConvChatBuddyFlags f = GAIM_CBFLAGS_NONE;
- if (!chu->client->nickname)
- continue;
- chu->context = SILC_32_TO_PTR(sg->channel_ids);
-@@ -1036,33 +1036,33 @@ void silcgaim_chat_join_done(SilcClient
- _("Channel founder on <I>%s</I> is <I>%s</I>"),
- channel->channel_name, chu->client->nickname);
-
-- gaim_conversation_write(convo, NULL, tmp,
-+ gaim2_conversation_write(convo, NULL, tmp,
- GAIM_MESSAGE_SYSTEM, time(NULL));
-
- }
- }
- silc_hash_table_list_reset(&htl);
-
-- gaim_conv_chat_add_users(GAIM_CONV_CHAT(convo), users, NULL, flags, FALSE);
-+ gaim2_conv_chat_add_users(GAIM_CONV_CHAT(convo), users, NULL, flags, FALSE);
- g_list_free(users);
- g_list_free(flags);
-
- /* Set topic */
- if (channel->topic)
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, channel->topic);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, channel->topic);
-
- /* Set nick */
-- gaim_conv_chat_set_nick(GAIM_CONV_CHAT(convo), conn->local_entry->nickname);
-+ gaim2_conv_chat_set_nick(GAIM_CONV_CHAT(convo), conn->local_entry->nickname);
- }
-
--char *silcgaim_get_chat_name(GHashTable *data)
-+char *silcgaim2_get_chat_name(GHashTable *data)
- {
- return g_strdup(g_hash_table_lookup(data, "channel"));
- }
-
--void silcgaim_chat_join(GaimConnection *gc, GHashTable *data)
-+void silcgaim2_chat_join(Gaim2Connection *gc, GHashTable *data)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- const char *channel, *passphrase, *parentch;
-@@ -1078,11 +1078,11 @@ void silcgaim_chat_join(GaimConnection *
- if (strstr(channel, "[Private Group]")) {
- SilcChannelEntry channel_entry;
- SilcChannelPrivateKey key;
-- GaimChat *c;
-- SilcGaimPrvgrp grp;
-+ Gaim2Chat *c;
-+ SilcGaim2Prvgrp grp;
-
-- c = gaim_blist_find_chat(sg->account, channel);
-- parentch = gaim_blist_node_get_string((GaimBlistNode *)c, "parentch");
-+ c = gaim2_blist_find_chat(sg->account, channel);
-+ parentch = gaim2_blist_node_get_string((Gaim2BlistNode *)c, "parentch");
- if (!parentch)
- return;
-
-@@ -1094,7 +1094,7 @@ void silcgaim_chat_join(GaimConnection *
- g_snprintf(tmp, sizeof(tmp),
- _("You have to join the %s channel before you are "
- "able to join the private group"), parentch);
-- gaim_notify_error(gc, _("Join Private Group"),
-+ gaim2_notify_error(gc, _("Join Private Group"),
- _("Cannot join private group"), tmp);
- return;
- }
-@@ -1142,10 +1142,10 @@ void silcgaim_chat_join(GaimConnection *
- channel, "-auth", "-founder", NULL);
- }
-
--void silcgaim_chat_invite(GaimConnection *gc, int id, const char *msg,
-+void silcgaim2_chat_invite(Gaim2Connection *gc, int id, const char *msg,
- const char *name)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcHashTableList htl;
-@@ -1159,10 +1159,10 @@ void silcgaim_chat_invite(GaimConnection
- to the actual channel */
- if (id > SILCGAIM_PRVGRP) {
- GList *l;
-- SilcGaimPrvgrp prv;
-+ SilcGaim2Prvgrp prv;
-
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->id == id)
-+ if (((SilcGaim2Prvgrp)l->data)->id == id)
- break;
- if (!l)
- return;
-@@ -1188,16 +1188,16 @@ void silcgaim_chat_invite(GaimConnection
- name, NULL);
- }
-
--void silcgaim_chat_leave(GaimConnection *gc, int id)
-+void silcgaim2_chat_leave(Gaim2Connection *gc, int id)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcHashTableList htl;
- SilcChannelUser chu;
- gboolean found = FALSE;
- GList *l;
-- SilcGaimPrvgrp prv;
-+ SilcGaim2Prvgrp prv;
-
- if (!conn)
- return;
-@@ -1207,7 +1207,7 @@ void silcgaim_chat_leave(GaimConnection
- SilcChannelEntry channel;
-
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->id == id)
-+ if (((SilcGaim2Prvgrp)l->data)->id == id)
- break;
- if (!l)
- return;
-@@ -1244,7 +1244,7 @@ void silcgaim_chat_leave(GaimConnection
-
- /* Leave from private groups on this channel as well */
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->chid == id) {
-+ if (((SilcGaim2Prvgrp)l->data)->chid == id) {
- prv = l->data;
- silc_client_del_channel_private_key(client, conn,
- chu->channel,
-@@ -1257,9 +1257,9 @@ void silcgaim_chat_leave(GaimConnection
- }
- }
-
--int silcgaim_chat_send(GaimConnection *gc, int id, const char *msg, GaimMessageFlags msgflags)
-+int silcgaim2_chat_send(Gaim2Connection *gc, int id, const char *msg, Gaim2MessageFlags msgflags)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcHashTableList htl;
-@@ -1270,14 +1270,14 @@ int silcgaim_chat_send(GaimConnection *g
- int ret;
- char *msg2, *tmp;
- gboolean found = FALSE;
-- gboolean sign = gaim_account_get_bool(sg->account, "sign-verify", FALSE);
-+ gboolean sign = gaim2_account_get_bool(sg->account, "sign-verify", FALSE);
-
- if (!msg || !conn)
- return 0;
-
- flags = SILC_MESSAGE_FLAG_UTF8;
-
-- tmp = msg2 = gaim_unescape_html(msg);
-+ tmp = msg2 = gaim2_unescape_html(msg);
-
- if (!g_ascii_strncasecmp(msg2, "/me ", 4))
- {
-@@ -1289,7 +1289,7 @@ int silcgaim_chat_send(GaimConnection *g
- flags |= SILC_MESSAGE_FLAG_ACTION;
- } else if (strlen(msg) > 1 && msg[0] == '/') {
- if (!silc_client_command_call(client, conn, msg + 1))
-- gaim_notify_error(gc, ("Call Command"), _("Cannot call command"),
-+ gaim2_notify_error(gc, ("Call Command"), _("Cannot call command"),
- _("Unknown command"));
- g_free(tmp);
- return 0;
-@@ -1303,10 +1303,10 @@ int silcgaim_chat_send(GaimConnection *g
- private group */
- if (id > SILCGAIM_PRVGRP) {
- GList *l;
-- SilcGaimPrvgrp prv;
-+ SilcGaim2Prvgrp prv;
-
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->id == id)
-+ if (((SilcGaim2Prvgrp)l->data)->id == id)
- break;
- if (!l) {
- g_free(tmp);
-@@ -1344,7 +1344,7 @@ int silcgaim_chat_send(GaimConnection *g
- flags, (unsigned char *)msg2,
- strlen(msg2), TRUE);
- if (ret) {
-- serv_got_chat_in(gc, id, gaim_connection_get_display_name(gc), 0, msg,
-+ serv_got_chat_in(gc, id, gaim2_connection_get_display_name(gc), 0, msg,
- time(NULL));
- }
- g_free(tmp);
-@@ -1352,9 +1352,9 @@ int silcgaim_chat_send(GaimConnection *g
- return ret;
- }
-
--void silcgaim_chat_set_topic(GaimConnection *gc, int id, const char *topic)
-+void silcgaim2_chat_set_topic(Gaim2Connection *gc, int id, const char *topic)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcHashTableList htl;
-@@ -1368,10 +1368,10 @@ void silcgaim_chat_set_topic(GaimConnect
- on the actual channel */
- if (id > SILCGAIM_PRVGRP) {
- GList *l;
-- SilcGaimPrvgrp prv;
-+ SilcGaim2Prvgrp prv;
-
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->id == id)
-+ if (((SilcGaim2Prvgrp)l->data)->id == id)
- break;
- if (!l)
- return;
-@@ -1396,53 +1396,53 @@ void silcgaim_chat_set_topic(GaimConnect
- chu->channel->channel_name, topic, NULL);
- }
-
--GaimRoomlist *silcgaim_roomlist_get_list(GaimConnection *gc)
-+Gaim2Roomlist *silcgaim2_roomlist_get_list(Gaim2Connection *gc)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- GList *fields = NULL;
-- GaimRoomlistField *f;
-+ Gaim2RoomlistField *f;
-
- if (!conn)
- return NULL;
-
- if (sg->roomlist)
-- gaim_roomlist_unref(sg->roomlist);
-+ gaim2_roomlist_unref(sg->roomlist);
-
- sg->roomlist_canceled = FALSE;
-
-- sg->roomlist = gaim_roomlist_new(gaim_connection_get_account(gc));
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "channel", TRUE);
-+ sg->roomlist = gaim2_roomlist_new(gaim2_connection_get_account(gc));
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "channel", TRUE);
- fields = g_list_append(fields, f);
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT,
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT,
- _("Users"), "users", FALSE);
- fields = g_list_append(fields, f);
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING,
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING,
- _("Topic"), "topic", FALSE);
- fields = g_list_append(fields, f);
-- gaim_roomlist_set_fields(sg->roomlist, fields);
-+ gaim2_roomlist_set_fields(sg->roomlist, fields);
-
- /* Call LIST */
- silc_client_command_call(client, conn, "LIST");
-
-- gaim_roomlist_set_in_progress(sg->roomlist, TRUE);
-+ gaim2_roomlist_set_in_progress(sg->roomlist, TRUE);
-
- return sg->roomlist;
- }
-
--void silcgaim_roomlist_cancel(GaimRoomlist *list)
-+void silcgaim2_roomlist_cancel(Gaim2Roomlist *list)
- {
-- GaimConnection *gc = gaim_account_get_connection(list->account);
-- SilcGaim sg;
-+ Gaim2Connection *gc = gaim2_account_get_connection(list->account);
-+ SilcGaim2 sg;
-
- if (!gc)
- return;
- sg = gc->proto_data;
-
-- gaim_roomlist_set_in_progress(list, FALSE);
-+ gaim2_roomlist_set_in_progress(list, FALSE);
- if (sg->roomlist == list) {
-- gaim_roomlist_unref(sg->roomlist);
-+ gaim2_roomlist_unref(sg->roomlist);
- sg->roomlist = NULL;
- sg->roomlist_canceled = TRUE;
- }
-diff -prNu ./src/protocols/silc/ft.c ./src/protocols/silc/ft.c
---- ./src/protocols/silc/ft.c 2005-11-19 03:01:48.000000000 +0100
-+++ ./src/protocols/silc/ft.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim_ft.c
-+ silcgaim2_ft.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,7 +19,7 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
-
- /****************************** File Transfer ********************************/
-
-@@ -30,15 +30,15 @@
- be an overkill since we'd effectively re-implement the file transfer what
- the SILC Client's file transfer API already provides.
-
-- From Gaim we do NOT use the FT API to do the transfer as it is very limiting.
-+ From Gaim2 we do NOT use the FT API to do the transfer as it is very limiting.
- In fact it does not suite to file transfers like SFTP at all. For example,
- it assumes that read operations are synchronous what they are not in SFTP.
-- It also assumes that the file transfer socket is to be handled by the Gaim
-+ It also assumes that the file transfer socket is to be handled by the Gaim2
- eventloop, and this naturally is something we don't want to do in case of
- SILC Toolkit. The FT API suites well to purely stream based file transfers
- like HTTP GET and similar.
-
-- For this reason, we directly access the Gaim GKT FT API and hack the FT
-+ For this reason, we directly access the Gaim2 GKT FT API and hack the FT
- API to merely provide the user interface experience and all the magic
- is done in the SILC Toolkit. Ie. we update the statistics information in
- the FT API for user interface, and that's it. A bit dirty but until the
-@@ -46,19 +46,19 @@
- us to do this. */
-
- typedef struct {
-- SilcGaim sg;
-+ SilcGaim2 sg;
- SilcClientEntry client_entry;
- SilcUInt32 session_id;
- char *hostname;
- SilcUInt16 port;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
-
- SilcClientFileName completion;
- void *completion_context;
--} *SilcGaimXfer;
-+} *SilcGaim2Xfer;
-
- static void
--silcgaim_ftp_monitor(SilcClient client,
-+silcgaim2_ftp_monitor(SilcClient client,
- SilcClientConnection conn,
- SilcClientMonitorStatus status,
- SilcClientFileError error,
-@@ -69,12 +69,12 @@ silcgaim_ftp_monitor(SilcClient client,
- const char *filepath,
- void *context)
- {
-- SilcGaimXfer xfer = context;
-- GaimConnection *gc = xfer->sg->gc;
-+ SilcGaim2Xfer xfer = context;
-+ Gaim2Connection *gc = xfer->sg->gc;
- char tmp[256];
-
- if (status == SILC_CLIENT_FILE_MONITOR_CLOSED) {
-- gaim_xfer_unref(xfer->xfer);
-+ gaim2_xfer_unref(xfer->xfer);
- silc_free(xfer);
- return;
- }
-@@ -86,62 +86,62 @@ silcgaim_ftp_monitor(SilcClient client,
- if (error == SILC_CLIENT_FILE_NO_SUCH_FILE) {
- g_snprintf(tmp, sizeof(tmp), "No such file %s",
- filepath ? filepath : "[N/A]");
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Error during file transfer"), tmp);
- } else if (error == SILC_CLIENT_FILE_PERMISSION_DENIED) {
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Error during file transfer"),
- _("Permission denied"));
- } else if (error == SILC_CLIENT_FILE_KEY_AGREEMENT_FAILED) {
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Error during file transfer"),
- _("Key agreement failed"));
- } else if (error == SILC_CLIENT_FILE_UNKNOWN_SESSION) {
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Error during file transfer"),
- _("File transfer session does not exist"));
- } else {
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Error during file transfer"), NULL);
- }
- silc_client_file_close(client, conn, session_id);
-- gaim_xfer_unref(xfer->xfer);
-+ gaim2_xfer_unref(xfer->xfer);
- silc_free(xfer);
- return;
- }
-
- /* Update file transfer UI */
- if (!offset && filesize)
-- gaim_xfer_set_size(xfer->xfer, filesize);
-+ gaim2_xfer_set_size(xfer->xfer, filesize);
- if (offset && filesize) {
- xfer->xfer->bytes_sent = offset;
- xfer->xfer->bytes_remaining = filesize - offset;
- }
-- gaim_xfer_update_progress(xfer->xfer);
-+ gaim2_xfer_update_progress(xfer->xfer);
-
- if (status == SILC_CLIENT_FILE_MONITOR_SEND ||
- status == SILC_CLIENT_FILE_MONITOR_RECEIVE) {
- if (offset == filesize) {
- /* Download finished */
-- gaim_xfer_set_completed(xfer->xfer, TRUE);
-+ gaim2_xfer_set_completed(xfer->xfer, TRUE);
- silc_client_file_close(client, conn, session_id);
- }
- }
- }
-
- static void
--silcgaim_ftp_cancel(GaimXfer *x)
-+silcgaim2_ftp_cancel(Gaim2Xfer *x)
- {
-- SilcGaimXfer xfer = x->data;
-+ SilcGaim2Xfer xfer = x->data;
- xfer->xfer->status = GAIM_XFER_STATUS_CANCEL_LOCAL;
-- gaim_xfer_update_progress(xfer->xfer);
-+ gaim2_xfer_update_progress(xfer->xfer);
- silc_client_file_close(xfer->sg->client, xfer->sg->conn, xfer->session_id);
- }
-
- static void
--silcgaim_ftp_ask_name_cancel(GaimXfer *x)
-+silcgaim2_ftp_ask_name_cancel(Gaim2Xfer *x)
- {
-- SilcGaimXfer xfer = x->data;
-+ SilcGaim2Xfer xfer = x->data;
-
- /* Cancel the transmission */
- xfer->completion(NULL, xfer->completion_context);
-@@ -149,18 +149,18 @@ silcgaim_ftp_ask_name_cancel(GaimXfer *x
- }
-
- static void
--silcgaim_ftp_ask_name_ok(GaimXfer *x)
-+silcgaim2_ftp_ask_name_ok(Gaim2Xfer *x)
- {
-- SilcGaimXfer xfer = x->data;
-+ SilcGaim2Xfer xfer = x->data;
- const char *name;
-
-- name = gaim_xfer_get_local_filename(x);
-+ name = gaim2_xfer_get_local_filename(x);
- g_unlink(name);
- xfer->completion(name, xfer->completion_context);
- }
-
- static void
--silcgaim_ftp_ask_name(SilcClient client,
-+silcgaim2_ftp_ask_name(SilcClient client,
- SilcClientConnection conn,
- SilcUInt32 session_id,
- const char *remote_filename,
-@@ -168,80 +168,80 @@ silcgaim_ftp_ask_name(SilcClient client,
- void *completion_context,
- void *context)
- {
-- SilcGaimXfer xfer = context;
-+ SilcGaim2Xfer xfer = context;
-
- xfer->completion = completion;
- xfer->completion_context = completion_context;
-
-- gaim_xfer_set_init_fnc(xfer->xfer, silcgaim_ftp_ask_name_ok);
-- gaim_xfer_set_request_denied_fnc(xfer->xfer, silcgaim_ftp_ask_name_cancel);
-+ gaim2_xfer_set_init_fnc(xfer->xfer, silcgaim2_ftp_ask_name_ok);
-+ gaim2_xfer_set_request_denied_fnc(xfer->xfer, silcgaim2_ftp_ask_name_cancel);
-
- /* Request to save the file */
-- gaim_xfer_set_filename(xfer->xfer, remote_filename);
-- gaim_xfer_request(xfer->xfer);
-+ gaim2_xfer_set_filename(xfer->xfer, remote_filename);
-+ gaim2_xfer_request(xfer->xfer);
- }
-
- static void
--silcgaim_ftp_request_result(GaimXfer *x)
-+silcgaim2_ftp_request_result(Gaim2Xfer *x)
- {
-- SilcGaimXfer xfer = x->data;
-+ SilcGaim2Xfer xfer = x->data;
- SilcClientFileError status;
-- GaimConnection *gc = xfer->sg->gc;
-+ Gaim2Connection *gc = xfer->sg->gc;
-
-- if (gaim_xfer_get_status(x) != GAIM_XFER_STATUS_ACCEPTED)
-+ if (gaim2_xfer_get_status(x) != GAIM_XFER_STATUS_ACCEPTED)
- return;
-
- /* Start the file transfer */
- status = silc_client_file_receive(xfer->sg->client, xfer->sg->conn,
-- silcgaim_ftp_monitor, xfer,
-+ silcgaim2_ftp_monitor, xfer,
- NULL, xfer->session_id,
-- silcgaim_ftp_ask_name, xfer);
-+ silcgaim2_ftp_ask_name, xfer);
- switch (status) {
- case SILC_CLIENT_FILE_OK:
- return;
- break;
-
- case SILC_CLIENT_FILE_UNKNOWN_SESSION:
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("No file transfer session active"), NULL);
- break;
-
- case SILC_CLIENT_FILE_ALREADY_STARTED:
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("File transfer already started"), NULL);
- break;
-
- case SILC_CLIENT_FILE_KEY_AGREEMENT_FAILED:
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Could not perform key agreement for file transfer"),
- NULL);
- break;
-
- default:
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Could not start the file transfer"), NULL);
- break;
- }
-
- /* Error */
-- gaim_xfer_unref(xfer->xfer);
-+ gaim2_xfer_unref(xfer->xfer);
- g_free(xfer->hostname);
- silc_free(xfer);
- }
-
- static void
--silcgaim_ftp_request_denied(GaimXfer *x)
-+silcgaim2_ftp_request_denied(Gaim2Xfer *x)
- {
-
- }
-
--void silcgaim_ftp_request(SilcClient client, SilcClientConnection conn,
-+void silcgaim2_ftp_request(SilcClient client, SilcClientConnection conn,
- SilcClientEntry client_entry, SilcUInt32 session_id,
- const char *hostname, SilcUInt16 port)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- SilcGaimXfer xfer;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ SilcGaim2Xfer xfer;
-
- xfer = silc_calloc(1, sizeof(*xfer));
- if (!xfer) {
-@@ -254,7 +254,7 @@ void silcgaim_ftp_request(SilcClient cli
- xfer->session_id = session_id;
- xfer->hostname = g_strdup(hostname);
- xfer->port = port;
-- xfer->xfer = gaim_xfer_new(xfer->sg->account, GAIM_XFER_RECEIVE,
-+ xfer->xfer = gaim2_xfer_new(xfer->sg->account, GAIM_XFER_RECEIVE,
- xfer->client_entry->nickname);
- if (!xfer->xfer) {
- silc_client_file_close(xfer->sg->client, xfer->sg->conn, xfer->session_id);
-@@ -262,49 +262,49 @@ void silcgaim_ftp_request(SilcClient cli
- silc_free(xfer);
- return;
- }
-- gaim_xfer_set_init_fnc(xfer->xfer, silcgaim_ftp_request_result);
-- gaim_xfer_set_request_denied_fnc(xfer->xfer, silcgaim_ftp_request_denied);
-- gaim_xfer_set_cancel_recv_fnc(xfer->xfer, silcgaim_ftp_cancel);
-+ gaim2_xfer_set_init_fnc(xfer->xfer, silcgaim2_ftp_request_result);
-+ gaim2_xfer_set_request_denied_fnc(xfer->xfer, silcgaim2_ftp_request_denied);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer->xfer, silcgaim2_ftp_cancel);
- xfer->xfer->remote_ip = g_strdup(hostname);
- xfer->xfer->remote_port = port;
- xfer->xfer->data = xfer;
-
- /* File transfer request */
-- gaim_xfer_request(xfer->xfer);
-+ gaim2_xfer_request(xfer->xfer);
- }
-
- static void
--silcgaim_ftp_send_cancel(GaimXfer *x)
-+silcgaim2_ftp_send_cancel(Gaim2Xfer *x)
- {
-- SilcGaimXfer xfer = x->data;
-+ SilcGaim2Xfer xfer = x->data;
- silc_client_file_close(xfer->sg->client, xfer->sg->conn, xfer->session_id);
-- gaim_xfer_unref(xfer->xfer);
-+ gaim2_xfer_unref(xfer->xfer);
- g_free(xfer->hostname);
- silc_free(xfer);
- }
-
- static void
--silcgaim_ftp_send(GaimXfer *x)
-+silcgaim2_ftp_send(Gaim2Xfer *x)
- {
-- SilcGaimXfer xfer = x->data;
-+ SilcGaim2Xfer xfer = x->data;
- const char *name;
- char *local_ip = NULL, *remote_ip = NULL;
- gboolean local = TRUE;
-
-- name = gaim_xfer_get_local_filename(x);
-+ name = gaim2_xfer_get_local_filename(x);
-
-- /* Do the same magic what we do with key agreement (see silcgaim_buddy.c)
-+ /* Do the same magic what we do with key agreement (see silcgaim2_buddy.c)
- to see if we are behind NAT. */
- if (silc_net_check_local_by_sock(xfer->sg->conn->sock->sock,
- NULL, &local_ip)) {
- /* Check if the IP is private */
-- if (silcgaim_ip_is_private(local_ip)) {
-+ if (silcgaim2_ip_is_private(local_ip)) {
- local = FALSE;
- /* Local IP is private, resolve the remote server IP to see whether
- we are talking to Internet or just on LAN. */
- if (silc_net_check_host_by_sock(xfer->sg->conn->sock->sock, NULL,
- &remote_ip))
-- if (silcgaim_ip_is_private(remote_ip))
-+ if (silcgaim2_ip_is_private(remote_ip))
- /* We assume we are in LAN. Let's provide the connection point. */
- local = TRUE;
- }
-@@ -315,7 +315,7 @@ silcgaim_ftp_send(GaimXfer *x)
-
- /* Send the file */
- silc_client_file_send(xfer->sg->client, xfer->sg->conn,
-- silcgaim_ftp_monitor, xfer,
-+ silcgaim2_ftp_monitor, xfer,
- local_ip, 0, !local, xfer->client_entry,
- name, &xfer->session_id);
-
-@@ -324,37 +324,37 @@ silcgaim_ftp_send(GaimXfer *x)
- }
-
- static void
--silcgaim_ftp_send_file_resolved(SilcClient client,
-+silcgaim2_ftp_send_file_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context)
- {
-- GaimConnection *gc = client->application;
-+ Gaim2Connection *gc = client->application;
- char tmp[256];
-
- if (!clients) {
- g_snprintf(tmp, sizeof(tmp),
- _("User %s is not present in the network"),
- (const char *)context);
-- gaim_notify_error(gc, _("Secure File Transfer"),
-+ gaim2_notify_error(gc, _("Secure File Transfer"),
- _("Cannot send file"), tmp);
- silc_free(context);
- return;
- }
-
-- silcgaim_ftp_send_file(client->application, (const char *)context, NULL);
-+ silcgaim2_ftp_send_file(client->application, (const char *)context, NULL);
- silc_free(context);
- }
-
--GaimXfer *silcgaim_ftp_new_xfer(GaimConnection *gc, const char *name)
-+Gaim2Xfer *silcgaim2_ftp_new_xfer(Gaim2Connection *gc, const char *name)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcClientEntry *clients;
- SilcUInt32 clients_count;
-- SilcGaimXfer xfer;
-+ SilcGaim2Xfer xfer;
- char *nickname;
-
- g_return_val_if_fail(name != NULL, NULL);
-@@ -367,7 +367,7 @@ GaimXfer *silcgaim_ftp_new_xfer(GaimConn
- &clients_count);
- if (!clients) {
- silc_client_get_clients(client, conn, nickname, NULL,
-- silcgaim_ftp_send_file_resolved,
-+ silcgaim2_ftp_send_file_resolved,
- strdup(name));
- silc_free(nickname);
- return NULL;
-@@ -379,7 +379,7 @@ GaimXfer *silcgaim_ftp_new_xfer(GaimConn
-
- xfer->sg = sg;
- xfer->client_entry = clients[0];
-- xfer->xfer = gaim_xfer_new(xfer->sg->account, GAIM_XFER_SEND,
-+ xfer->xfer = gaim2_xfer_new(xfer->sg->account, GAIM_XFER_SEND,
- xfer->client_entry->nickname);
- if (!xfer->xfer) {
- silc_client_file_close(xfer->sg->client, xfer->sg->conn, xfer->session_id);
-@@ -387,9 +387,9 @@ GaimXfer *silcgaim_ftp_new_xfer(GaimConn
- silc_free(xfer);
- return NULL;
- }
-- gaim_xfer_set_init_fnc(xfer->xfer, silcgaim_ftp_send);
-- gaim_xfer_set_request_denied_fnc(xfer->xfer, silcgaim_ftp_request_denied);
-- gaim_xfer_set_cancel_send_fnc(xfer->xfer, silcgaim_ftp_send_cancel);
-+ gaim2_xfer_set_init_fnc(xfer->xfer, silcgaim2_ftp_send);
-+ gaim2_xfer_set_request_denied_fnc(xfer->xfer, silcgaim2_ftp_request_denied);
-+ gaim2_xfer_set_cancel_send_fnc(xfer->xfer, silcgaim2_ftp_send_cancel);
- xfer->xfer->data = xfer;
-
- silc_free(clients);
-@@ -398,15 +398,15 @@ GaimXfer *silcgaim_ftp_new_xfer(GaimConn
- return xfer->xfer;
- }
-
--void silcgaim_ftp_send_file(GaimConnection *gc, const char *name, const char *file)
-+void silcgaim2_ftp_send_file(Gaim2Connection *gc, const char *name, const char *file)
- {
-- GaimXfer *xfer = silcgaim_ftp_new_xfer(gc, name);
-+ Gaim2Xfer *xfer = silcgaim2_ftp_new_xfer(gc, name);
-
- g_return_if_fail(xfer != NULL);
-
- /* Choose file to send */
- if (file)
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
- else
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-diff -prNu ./src/protocols/silc/Makefile.am ./src/protocols/silc/Makefile.am
---- ./src/protocols/silc/Makefile.am 2005-11-13 00:11:23.000000000 +0100
-+++ ./src/protocols/silc/Makefile.am 2006-01-05 13:04:59.000000000 +0100
-@@ -1,6 +1,6 @@
- EXTRA_DIST = README TODO Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- SILCSOURCES = silc.c silcgaim.h buddy.c chat.c ft.c ops.c pk.c util.c wb.c wb.h
-
-diff -prNu ./src/protocols/silc/ops.c ./src/protocols/silc/ops.c
---- ./src/protocols/silc/ops.c 2005-12-21 22:18:25.000000000 +0100
-+++ ./src/protocols/silc/ops.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim_ops.c
-+ silcgaim2_ops.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,7 +19,7 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "imgstore.h"
- #include "wb.h"
-
-@@ -53,19 +53,19 @@ silc_say(SilcClient client, SilcClientCo
- message. */
-
- static void
--silcgaim_mime_message(SilcClient client, SilcClientConnection conn,
-+silcgaim2_mime_message(SilcClient client, SilcClientConnection conn,
- SilcClientEntry sender, SilcChannelEntry channel,
- SilcMessagePayload payload, SilcChannelPrivateKey key,
- SilcMessageFlags flags, SilcMime mime,
- gboolean recursive)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
- const char *type;
- const unsigned char *data;
- SilcUInt32 data_len;
-- GaimMessageFlags cflags = 0;
-- GaimConversation *convo = NULL;
-+ Gaim2MessageFlags cflags = 0;
-+ Gaim2Conversation *convo = NULL;
-
- if (!mime)
- return;
-@@ -82,7 +82,7 @@ silcgaim_mime_message(SilcClient client,
- return;
-
- /* Process the complete message */
-- silcgaim_mime_message(client, conn, sender, channel,
-+ silcgaim2_mime_message(client, conn, sender, channel,
- payload, key, flags, mime, FALSE);
- return;
- }
-@@ -100,7 +100,7 @@ silcgaim_mime_message(SilcClient client,
- silc_dlist_start(parts);
- while ((p = silc_dlist_get(parts)) != SILC_LIST_END) {
- /* Recursively process parts */
-- silcgaim_mime_message(client, conn, sender, channel,
-+ silcgaim2_mime_message(client, conn, sender, channel,
- payload, key, flags, p, TRUE);
- }
- goto out;
-@@ -145,29 +145,29 @@ silcgaim_mime_message(SilcClient client,
- /* Get channel convo (if message is for channel) */
- if (key && channel) {
- GList *l;
-- SilcGaimPrvgrp prv;
-+ SilcGaim2Prvgrp prv;
-
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->key == key) {
-+ if (((SilcGaim2Prvgrp)l->data)->key == key) {
- prv = l->data;
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- prv->channel, sg->account);
- break;
- }
- }
- if (channel && !convo)
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (channel && !convo)
- goto out;
-
-- imgid = gaim_imgstore_add(data, data_len, "");
-+ imgid = gaim2_imgstore_add(data, data_len, "");
- if (imgid) {
- cflags |= GAIM_MESSAGE_IMAGES | GAIM_MESSAGE_RECV;
- g_snprintf(tmp, sizeof(tmp), "<IMG ID=\"%d\">", imgid);
-
- if (channel)
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
- sender->nickname ?
- sender->nickname :
- "<unknown>", cflags,
-@@ -177,7 +177,7 @@ silcgaim_mime_message(SilcClient client,
- sender->nickname : "<unknown>",
- tmp, cflags, time(NULL));
-
-- gaim_imgstore_unref(imgid);
-+ gaim2_imgstore_unref(imgid);
- cflags = 0;
- }
- goto out;
-@@ -185,12 +185,12 @@ silcgaim_mime_message(SilcClient client,
-
- /* Whiteboard message */
- if (strstr(type, "application/x-wb") &&
-- !gaim_account_get_bool(sg->account, "block-wb", FALSE)) {
-+ !gaim2_account_get_bool(sg->account, "block-wb", FALSE)) {
- if (channel)
-- silcgaim_wb_receive_ch(client, conn, sender, channel,
-+ silcgaim2_wb_receive_ch(client, conn, sender, channel,
- payload, flags, data, data_len);
- else
-- silcgaim_wb_receive(client, conn, sender, payload,
-+ silcgaim2_wb_receive(client, conn, sender, payload,
- flags, data, data_len);
- goto out;
- }
-@@ -214,9 +214,9 @@ silc_channel_message(SilcClient client,
- SilcMessageFlags flags, const unsigned char *message,
- SilcUInt32 message_len)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- GaimConversation *convo = NULL;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ Gaim2Conversation *convo = NULL;
- char *msg, *tmp;
-
- if (!message)
-@@ -224,24 +224,24 @@ silc_channel_message(SilcClient client,
-
- if (key) {
- GList *l;
-- SilcGaimPrvgrp prv;
-+ SilcGaim2Prvgrp prv;
-
- for (l = sg->grps; l; l = l->next)
-- if (((SilcGaimPrvgrp)l->data)->key == key) {
-+ if (((SilcGaim2Prvgrp)l->data)->key == key) {
- prv = l->data;
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- prv->channel, sg->account);
- break;
- }
- }
- if (!convo)
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- return;
-
- if (flags & SILC_MESSAGE_FLAG_SIGNED &&
-- gaim_account_get_bool(sg->account, "sign-verify", FALSE)) {
-+ gaim2_account_get_bool(sg->account, "sign-verify", FALSE)) {
- /* XXX */
- }
-
-@@ -250,7 +250,7 @@ silc_channel_message(SilcClient client,
- #ifdef HAVE_SILCMIME_H
- SilcMime mime;
- mime = silc_mime_decode(message, message_len);
-- silcgaim_mime_message(client, conn, sender, channel, payload,
-+ silcgaim2_mime_message(client, conn, sender, channel, payload,
- key, flags, mime, FALSE);
- #else
- char type[128], enc[128];
-@@ -267,8 +267,8 @@ silc_channel_message(SilcClient client,
-
- if (!strcmp(type, "application/x-wb") &&
- !strcmp(enc, "binary") &&
-- !gaim_account_get_bool(sg->account, "block-wb", FALSE))
-- silcgaim_wb_receive_ch(client, conn, sender, channel,
-+ !gaim2_account_get_bool(sg->account, "block-wb", FALSE))
-+ silcgaim2_wb_receive_ch(client, conn, sender, channel,
- payload, flags, data, data_len);
- #endif
- return;
-@@ -281,8 +281,8 @@ silc_channel_message(SilcClient client,
- return;
-
- tmp = g_markup_escape_text(msg, -1);
-- /* Send to Gaim */
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
-+ /* Send to Gaim2 */
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
- sender->nickname ?
- sender->nickname : "<unknown>", 0,
- tmp, time(NULL));
-@@ -299,8 +299,8 @@ silc_channel_message(SilcClient client,
- if (!msg)
- return;
-
-- /* Send to Gaim */
-- gaim_conversation_write(convo, NULL, (const char *)msg,
-+ /* Send to Gaim2 */
-+ gaim2_conversation_write(convo, NULL, (const char *)msg,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- return;
-@@ -308,8 +308,8 @@ silc_channel_message(SilcClient client,
-
- if (flags & SILC_MESSAGE_FLAG_UTF8) {
- tmp = g_markup_escape_text((const char *)message, -1);
-- /* Send to Gaim */
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
-+ /* Send to Gaim2 */
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)),
- sender->nickname ?
- sender->nickname : "<unknown>", 0,
- tmp, time(NULL));
-@@ -330,9 +330,9 @@ silc_private_message(SilcClient client,
- SilcMessageFlags flags, const unsigned char *message,
- SilcUInt32 message_len)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- GaimConversation *convo = NULL;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ Gaim2Conversation *convo = NULL;
- char *msg, *tmp;
-
- if (!message)
-@@ -340,11 +340,11 @@ silc_private_message(SilcClient client,
-
- if (sender->nickname)
- /* XXX - Should this be GAIM_CONV_TYPE_IM? */
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_ANY,
- sender->nickname, sg->account);
-
- if (flags & SILC_MESSAGE_FLAG_SIGNED &&
-- gaim_account_get_bool(sg->account, "sign-verify", FALSE)) {
-+ gaim2_account_get_bool(sg->account, "sign-verify", FALSE)) {
- /* XXX */
- }
-
-@@ -353,7 +353,7 @@ silc_private_message(SilcClient client,
- /* Process MIME message */
- SilcMime mime;
- mime = silc_mime_decode(message, message_len);
-- silcgaim_mime_message(client, conn, sender, NULL, payload,
-+ silcgaim2_mime_message(client, conn, sender, NULL, payload,
- NULL, flags, mime, FALSE);
- #else
- char type[128], enc[128];
-@@ -370,8 +370,8 @@ silc_private_message(SilcClient client,
-
- if (!strcmp(type, "application/x-wb") &&
- !strcmp(enc, "binary") &&
-- !gaim_account_get_bool(sg->account, "block-wb", FALSE))
-- silcgaim_wb_receive(client, conn, sender, payload,
-+ !gaim2_account_get_bool(sg->account, "block-wb", FALSE))
-+ silcgaim2_wb_receive(client, conn, sender, payload,
- flags, data, data_len);
- #endif
- return;
-@@ -384,7 +384,7 @@ silc_private_message(SilcClient client,
- return;
-
- tmp = g_markup_escape_text(msg, -1);
-- /* Send to Gaim */
-+ /* Send to Gaim2 */
- serv_got_im(gc, sender->nickname ?
- sender->nickname : "<unknown>",
- tmp, 0, time(NULL));
-@@ -401,8 +401,8 @@ silc_private_message(SilcClient client,
- if (!msg)
- return;
-
-- /* Send to Gaim */
-- gaim_conversation_write(convo, NULL, (const char *)msg,
-+ /* Send to Gaim2 */
-+ gaim2_conversation_write(convo, NULL, (const char *)msg,
- GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(msg);
- return;
-@@ -410,7 +410,7 @@ silc_private_message(SilcClient client,
-
- if (flags & SILC_MESSAGE_FLAG_UTF8) {
- tmp = g_markup_escape_text((const char *)message, -1);
-- /* Send to Gaim */
-+ /* Send to Gaim2 */
- serv_got_im(gc, sender->nickname ?
- sender->nickname : "<unknown>",
- tmp, 0, time(NULL));
-@@ -433,9 +433,9 @@ silc_notify(SilcClient client, SilcClien
- SilcNotifyType type, ...)
- {
- va_list va;
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- GaimConversation *convo;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ Gaim2Conversation *convo;
- SilcClientEntry client_entry, client_entry2;
- SilcChannelEntry channel;
- SilcServerEntry server_entry;
-@@ -447,7 +447,7 @@ silc_notify(SilcClient client, SilcClien
- char buf[512], buf2[512], *tmp, *name;
- SilcBuffer buffer;
- SilcNotifyType notify;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- int i;
-
- va_start(va, type);
-@@ -479,7 +479,7 @@ silc_notify(SilcClient client, SilcClien
- if (client_entry == conn->local_entry)
- break;
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- break;
-@@ -487,7 +487,7 @@ silc_notify(SilcClient client, SilcClien
- /* Join user to channel */
- g_snprintf(buf, sizeof(buf), "%s@%s",
- client_entry->username, client_entry->hostname);
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(convo),
- g_strdup(client_entry->nickname), buf, GAIM_CBFLAGS_NONE, TRUE);
-
- break;
-@@ -496,13 +496,13 @@ silc_notify(SilcClient client, SilcClien
- client_entry = va_arg(va, SilcClientEntry);
- channel = va_arg(va, SilcChannelEntry);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- break;
-
- /* Remove user from channel */
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
- client_entry->nickname, NULL);
-
- break;
-@@ -517,11 +517,11 @@ silc_notify(SilcClient client, SilcClien
- /* Remove from all channels */
- silc_hash_table_list(client_entry->channels, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chu->channel->channel_name, sg->account);
- if (!convo)
- continue;
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
- client_entry->nickname,
- tmp);
- }
-@@ -537,7 +537,7 @@ silc_notify(SilcClient client, SilcClien
- tmp = va_arg(va, char *);
- channel = va_arg(va, SilcChannelEntry);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- break;
-@@ -546,7 +546,7 @@ silc_notify(SilcClient client, SilcClien
- break;
-
- esc = g_markup_escape_text(tmp, -1);
-- tmp2 = gaim_markup_linkify(esc);
-+ tmp2 = gaim2_markup_linkify(esc);
- g_free(esc);
-
- if (idtype == SILC_ID_CLIENT) {
-@@ -554,30 +554,30 @@ silc_notify(SilcClient client, SilcClien
- g_snprintf(buf, sizeof(buf),
- _("%s has changed the topic of <I>%s</I> to: %s"),
- client_entry->nickname, channel->channel_name, tmp2);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), client_entry->nickname,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), client_entry->nickname,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo),
- client_entry->nickname, tmp);
- } else if (idtype == SILC_ID_SERVER) {
- server_entry = (SilcServerEntry)entry;
- g_snprintf(buf, sizeof(buf),
- _("%s has changed the topic of <I>%s</I> to: %s"),
- server_entry->server_name, channel->channel_name, tmp2);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), server_entry->server_name,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), server_entry->server_name,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo),
- server_entry->server_name, tmp);
- } else if (idtype == SILC_ID_CHANNEL) {
- channel = (SilcChannelEntry)entry;
- g_snprintf(buf, sizeof(buf),
- _("%s has changed the topic of <I>%s</I> to: %s"),
- channel->channel_name, channel->channel_name, tmp2);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), channel->channel_name,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), channel->channel_name,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo),
- channel->channel_name, tmp);
- } else {
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, tmp);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, tmp);
- }
-
- g_free(tmp2);
-@@ -595,12 +595,12 @@ silc_notify(SilcClient client, SilcClien
- /* Change nick on all channels */
- silc_hash_table_list(client_entry2->channels, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chu->channel->channel_name, sg->account);
- if (!convo)
- continue;
-- if (gaim_conv_chat_find_user(GAIM_CONV_CHAT(convo), client_entry->nickname))
-- gaim_conv_chat_rename_user(GAIM_CONV_CHAT(convo),
-+ if (gaim2_conv_chat_find_user(GAIM_CONV_CHAT(convo), client_entry->nickname))
-+ gaim2_conv_chat_rename_user(GAIM_CONV_CHAT(convo),
- client_entry->nickname,
- client_entry2->nickname);
- }
-@@ -619,7 +619,7 @@ silc_notify(SilcClient client, SilcClien
- buffer = va_arg(va, SilcBuffer);
- channel = va_arg(va, SilcChannelEntry);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- break;
-@@ -634,7 +634,7 @@ silc_notify(SilcClient client, SilcClien
- break;
-
- if (mode) {
-- silcgaim_get_chmode_string(mode, buf2, sizeof(buf2));
-+ silcgaim2_get_chmode_string(mode, buf2, sizeof(buf2));
- g_snprintf(buf, sizeof(buf),
- _("<I>%s</I> set channel <I>%s</I> modes to: %s"), name,
- channel->channel_name, buf2);
-@@ -643,20 +643,20 @@ silc_notify(SilcClient client, SilcClien
- _("<I>%s</I> removed all channel <I>%s</I> modes"), name,
- channel->channel_name);
- }
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), channel->channel_name,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), channel->channel_name,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
- break;
-
- case SILC_NOTIFY_TYPE_CUMODE_CHANGE:
- {
-- GaimConvChatBuddyFlags flags = GAIM_CBFLAGS_NONE;
-+ Gaim2ConvChatBuddyFlags flags = GAIM_CBFLAGS_NONE;
- idtype = va_arg(va, int);
- entry = va_arg(va, void *);
- mode = va_arg(va, SilcUInt32);
- client_entry2 = va_arg(va, SilcClientEntry);
- channel = va_arg(va, SilcChannelEntry);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- break;
-@@ -671,7 +671,7 @@ silc_notify(SilcClient client, SilcClien
- break;
-
- if (mode) {
-- silcgaim_get_chumode_string(mode, buf2, sizeof(buf2));
-+ silcgaim2_get_chumode_string(mode, buf2, sizeof(buf2));
- g_snprintf(buf, sizeof(buf),
- _("<I>%s</I> set <I>%s's</I> modes to: %s"), name,
- client_entry2->nickname, buf2);
-@@ -684,9 +684,9 @@ silc_notify(SilcClient client, SilcClien
- _("<I>%s</I> removed all <I>%s's</I> modes"), name,
- client_entry2->nickname);
- }
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), channel->channel_name,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), channel->channel_name,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- gaim_conv_chat_user_set_flags(GAIM_CONV_CHAT(convo), client_entry2->nickname, flags);
-+ gaim2_conv_chat_user_set_flags(GAIM_CONV_CHAT(convo), client_entry2->nickname, flags);
- break;
- }
-
-@@ -702,7 +702,7 @@ silc_notify(SilcClient client, SilcClien
- client_entry2 = va_arg(va, SilcClientEntry);
- channel = va_arg(va, SilcChannelEntry);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo)
- break;
-@@ -713,14 +713,14 @@ silc_notify(SilcClient client, SilcClien
- _("You have been kicked off <I>%s</I> by <I>%s</I> (%s)"),
- channel->channel_name, client_entry2->nickname,
- tmp ? tmp : "");
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), client_entry->nickname,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), client_entry->nickname,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- serv_got_chat_left(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
-+ serv_got_chat_left(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
- } else {
- /* Remove user from channel */
- g_snprintf(buf, sizeof(buf), ("Kicked by %s (%s)"),
- client_entry2->nickname, tmp ? tmp : "");
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
- client_entry->nickname,
- buf);
- }
-@@ -757,13 +757,13 @@ silc_notify(SilcClient client, SilcClien
- /* Remove us from all channels */
- silc_hash_table_list(client_entry->channels, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chu->channel->channel_name, sg->account);
- if (!convo)
- continue;
-- gaim_conv_chat_write(GAIM_CONV_CHAT(convo), client_entry->nickname,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(convo), client_entry->nickname,
- buf, GAIM_MESSAGE_SYSTEM, time(NULL));
-- serv_got_chat_left(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
-+ serv_got_chat_left(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo)));
- }
- silc_hash_table_list_reset(&htl);
-
-@@ -788,11 +788,11 @@ silc_notify(SilcClient client, SilcClien
- /* Remove user from all channels */
- silc_hash_table_list(client_entry->channels, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chu->channel->channel_name, sg->account);
- if (!convo)
- continue;
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
- client_entry->nickname, tmp);
- }
- silc_hash_table_list_reset(&htl);
-@@ -821,11 +821,11 @@ silc_notify(SilcClient client, SilcClien
- silc_hash_table_list(clients[i]->channels, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
- convo =
-- gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chu->channel->channel_name, sg->account);
- if (!convo)
- continue;
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(convo),
- clients[i]->nickname,
- _("Server signoff"));
- }
-@@ -837,7 +837,7 @@ silc_notify(SilcClient client, SilcClien
- case SILC_NOTIFY_TYPE_ERROR:
- {
- SilcStatus error = va_arg(va, int);
-- gaim_notify_error(gc, "Error Notify",
-+ gaim2_notify_error(gc, "Error Notify",
- silc_get_status_message(error),
- NULL);
- }
-@@ -858,7 +858,7 @@ silc_notify(SilcClient client, SilcClien
-
- b = NULL;
- if (public_key) {
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- const char *f;
-
- pk = silc_pkcs_public_key_encode(public_key, &pk_len);
-@@ -871,12 +871,12 @@ silc_notify(SilcClient client, SilcClien
- g_snprintf(buf, sizeof(buf) - 1,
- "%s" G_DIR_SEPARATOR_S "clientkeys"
- G_DIR_SEPARATOR_S "clientkey_%s.pub",
-- silcgaim_silcdir(), fingerprint);
-+ silcgaim2_silcdir(), fingerprint);
- silc_free(fingerprint);
- silc_free(pk);
-
- /* Find buddy by associated public key */
-- for (gnode = gaim_get_blist()->root; gnode;
-+ for (gnode = gaim2_get_blist()->root; gnode;
- gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-@@ -887,10 +887,10 @@ silc_notify(SilcClient client, SilcClien
- bnode = bnode->next) {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if (b->account != gc->account)
- continue;
-- f = gaim_blist_node_get_string(bnode, "public-key");
-+ f = gaim2_blist_node_get_string(bnode, "public-key");
- if (!strcmp(f, buf))
- goto cont;
- }
-@@ -900,9 +900,9 @@ silc_notify(SilcClient client, SilcClien
- cont:
- if (!b) {
- /* Find buddy by nickname */
-- b = gaim_find_buddy(sg->account, client_entry->nickname);
-+ b = gaim2_find_buddy(sg->account, client_entry->nickname);
- if (!b) {
-- gaim_debug_warning("silc", "WATCH for %s, unknown buddy",
-+ gaim2_debug_warning("silc", "WATCH for %s, unknown buddy",
- client_entry->nickname);
- break;
- }
-@@ -924,7 +924,7 @@ silc_notify(SilcClient client, SilcClien
- client_entry->mode & SILC_UMODE_PAGE ||
- client_entry->mode & SILC_UMODE_DETACHED)) {
- client_entry->mode = mode;
-- gaim_prpl_got_user_status(gaim_buddy_get_account(b), gaim_buddy_get_name(b), SILCGAIM_STATUS_ID_AVAILABLE, NULL);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(b), gaim2_buddy_get_name(b), SILCGAIM_STATUS_ID_AVAILABLE, NULL);
- }
- else if ((mode & SILC_UMODE_GONE) ||
- (mode & SILC_UMODE_INDISPOSED) ||
-@@ -932,22 +932,22 @@ silc_notify(SilcClient client, SilcClien
- (mode & SILC_UMODE_PAGE) ||
- (mode & SILC_UMODE_DETACHED)) {
- client_entry->mode = mode;
-- gaim_prpl_got_user_status(gaim_buddy_get_account(b), gaim_buddy_get_name(b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(b), gaim2_buddy_get_name(b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
- }
- } else if (notify == SILC_NOTIFY_TYPE_SIGNOFF ||
- notify == SILC_NOTIFY_TYPE_SERVER_SIGNOFF ||
- notify == SILC_NOTIFY_TYPE_KILLED) {
- client_entry->mode = mode;
-- gaim_prpl_got_user_status(gaim_buddy_get_account(b), gaim_buddy_get_name(b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(b), gaim2_buddy_get_name(b), SILCGAIM_STATUS_ID_OFFLINE, NULL);
- } else if (notify == SILC_NOTIFY_TYPE_NONE) {
- client_entry->mode = mode;
-- gaim_prpl_got_user_status(gaim_buddy_get_account(b), gaim_buddy_get_name(b), SILCGAIM_STATUS_ID_AVAILABLE, NULL);
-+ gaim2_prpl_got_user_status(gaim2_buddy_get_account(b), gaim2_buddy_get_name(b), SILCGAIM_STATUS_ID_AVAILABLE, NULL);
- }
- }
- break;
-
- default:
-- gaim_debug_info("silc", "Unhandled notification: %d\n", type);
-+ gaim2_debug_info("silc", "Unhandled notification: %d\n", type);
- break;
- }
-
-@@ -969,8 +969,8 @@ silc_command(SilcClient client, SilcClie
- SilcClientCommandContext cmd_context, bool success,
- SilcCommand command, SilcStatus status)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-
- switch (command) {
-
-@@ -989,7 +989,7 @@ silc_command(SilcClient client, SilcClie
-
- #if 0
- static void
--silcgaim_whois_more(SilcClientEntry client_entry, gint id)
-+silcgaim2_whois_more(SilcClientEntry client_entry, gint id)
- {
- SilcAttributePayload attr;
- SilcAttribute attribute;
-@@ -1084,7 +1084,7 @@ silcgaim_whois_more(SilcClientEntry clie
- }
-
- buf = g_string_free(s, FALSE);
-- gaim_notify_info(NULL, _("User Information"), _("User Information"),
-+ gaim2_notify_info(NULL, _("User Information"), _("User Information"),
- buf);
- g_free(buf);
- }
-@@ -1112,9 +1112,9 @@ silc_command_reply(SilcClient client, Si
- SilcCommandPayload cmd_payload, bool success,
- SilcCommand command, SilcStatus status, ...)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- GaimConversation *convo;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ Gaim2Conversation *convo;
- va_list vp;
-
- va_start(vp, status);
-@@ -1125,7 +1125,7 @@ silc_command_reply(SilcClient client, Si
- SilcChannelEntry channel_entry;
-
- if (!success) {
-- gaim_notify_error(gc, _("Join Chat"), _("Cannot join channel"),
-+ gaim2_notify_error(gc, _("Join Chat"), _("Cannot join channel"),
- silc_get_status_message(status));
- return;
- }
-@@ -1135,7 +1135,7 @@ silc_command_reply(SilcClient client, Si
-
- /* Resolve users on channel */
- silc_client_get_clients_by_channel(client, conn, channel_entry,
-- silcgaim_chat_join_done,
-+ silcgaim2_chat_join_done,
- channel_entry);
- }
- break;
-@@ -1156,7 +1156,7 @@ silc_command_reply(SilcClient client, Si
- GString *s;
-
- if (!success) {
-- gaim_notify_error(gc, _("User Information"),
-+ gaim2_notify_error(gc, _("User Information"),
- _("Cannot get user information"),
- silc_get_status_message(status));
- break;
-@@ -1195,12 +1195,12 @@ silc_command_reply(SilcClient client, Si
- if (client_entry->mode) {
- g_string_append_printf(s, "<br><b>%s:</b> ", _("User Modes"));
- memset(tmp, 0, sizeof(tmp));
-- silcgaim_get_umode_string(client_entry->mode,
-+ silcgaim2_get_umode_string(client_entry->mode,
- tmp, sizeof(tmp) - strlen(tmp));
- g_string_append_printf(s, "%s", tmp);
- }
-
-- silcgaim_parse_attrs(client_entry->attrs, &moodstr, &statusstr, &contactstr, &langstr, &devicestr, &tzstr, &geostr);
-+ silcgaim2_parse_attrs(client_entry->attrs, &moodstr, &statusstr, &contactstr, &langstr, &devicestr, &tzstr, &geostr);
- if (moodstr) {
- g_string_append_printf(s, "<br><b>%s:</b> %s", _("Mood"), moodstr);
- g_free(moodstr);
-@@ -1291,14 +1291,14 @@ silc_command_reply(SilcClient client, Si
- buf = g_string_free(s, FALSE);
- #if 0 /* XXX for now, let's not show attrs here */
- if (client_entry->attrs)
-- gaim_request_action(gc, _("User Information"),
-+ gaim2_request_action(gc, _("User Information"),
- _("User Information"),
- buf, 1, client_entry, 2,
-- _("OK"), G_CALLBACK(silcgaim_whois_more),
-- _("_More..."), G_CALLBACK(silcgaim_whois_more));
-+ _("OK"), G_CALLBACK(silcgaim2_whois_more),
-+ _("_More..."), G_CALLBACK(silcgaim2_whois_more));
- else
- #endif
-- gaim_notify_userinfo(gc, client_entry->nickname, buf, NULL, NULL);
-+ gaim2_notify_userinfo(gc, client_entry->nickname, buf, NULL, NULL);
- g_free(buf);
- }
- break;
-@@ -1310,7 +1310,7 @@ silc_command_reply(SilcClient client, Si
- GString *s;
-
- if (!success) {
-- gaim_notify_error(gc, _("User Information"),
-+ gaim2_notify_error(gc, _("User Information"),
- _("Cannot get user information"),
- silc_get_status_message(status));
- break;
-@@ -1359,14 +1359,14 @@ silc_command_reply(SilcClient client, Si
- }
-
- buf = g_string_free(s, FALSE);
-- gaim_notify_userinfo(gc, client_entry->nickname, buf, NULL, NULL);
-+ gaim2_notify_userinfo(gc, client_entry->nickname, buf, NULL, NULL);
- g_free(buf);
- }
- break;
-
- case SILC_COMMAND_DETACH:
- if (!success) {
-- gaim_notify_error(gc, _("Detach From Server"), _("Cannot detach"),
-+ gaim2_notify_error(gc, _("Detach From Server"), _("Cannot detach"),
- silc_get_status_message(status));
- return;
- }
-@@ -1377,24 +1377,24 @@ silc_command_reply(SilcClient client, Si
- SilcChannelEntry channel;
-
- if (!success) {
-- gaim_notify_error(gc, _("Topic"), _("Cannot set topic"),
-+ gaim2_notify_error(gc, _("Topic"), _("Cannot set topic"),
- silc_get_status_message(status));
- return;
- }
-
- channel = va_arg(vp, SilcChannelEntry);
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- channel->channel_name, sg->account);
- if (!convo) {
-- gaim_debug_error("silc", "Got a topic for %s, which doesn't exist\n",
-+ gaim2_debug_error("silc", "Got a topic for %s, which doesn't exist\n",
- channel->channel_name);
- break;
- }
-
- /* Set topic */
- if (channel->topic)
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, channel->topic);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, channel->topic);
- }
- break;
-
-@@ -1409,7 +1409,7 @@ silc_command_reply(SilcClient client, Si
- const char *oldnick;
-
- if (!success) {
-- gaim_notify_error(gc, _("Nick"), _("Failed to change nickname"),
-+ gaim2_notify_error(gc, _("Nick"), _("Failed to change nickname"),
- silc_get_status_message(status));
- return;
- }
-@@ -1419,20 +1419,20 @@ silc_command_reply(SilcClient client, Si
- /* Change nick on all channels */
- silc_hash_table_list(local_entry->channels, &htl);
- while (silc_hash_table_get(&htl, NULL, (void *)&chu)) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- chu->channel->channel_name, sg->account);
- if (!convo)
- continue;
-- oldnick = gaim_conv_chat_get_nick(GAIM_CONV_CHAT(convo));
-- if (strcmp(oldnick, gaim_normalize(gaim_conversation_get_account(convo), local_entry->nickname))) {
-- gaim_conv_chat_rename_user(GAIM_CONV_CHAT(convo),
-+ oldnick = gaim2_conv_chat_get_nick(GAIM_CONV_CHAT(convo));
-+ if (strcmp(oldnick, gaim2_normalize(gaim2_conversation_get_account(convo), local_entry->nickname))) {
-+ gaim2_conv_chat_rename_user(GAIM_CONV_CHAT(convo),
- oldnick, local_entry->nickname);
-- gaim_conv_chat_set_nick(GAIM_CONV_CHAT(convo), local_entry->nickname);
-+ gaim2_conv_chat_set_nick(GAIM_CONV_CHAT(convo), local_entry->nickname);
- }
- }
- silc_hash_table_list_reset(&htl);
-
-- gaim_connection_set_display_name(gc, local_entry->nickname);
-+ gaim2_connection_set_display_name(gc, local_entry->nickname);
- }
- break;
-
-@@ -1440,16 +1440,16 @@ silc_command_reply(SilcClient client, Si
- {
- char *topic, *name;
- int usercount;
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
-
- if (sg->roomlist_canceled)
- break;
-
- if (!success) {
-- gaim_notify_error(gc, _("Error"), _("Error retrieving room list"),
-+ gaim2_notify_error(gc, _("Error"), _("Error retrieving room list"),
- silc_get_status_message(status));
-- gaim_roomlist_set_in_progress(sg->roomlist, FALSE);
-- gaim_roomlist_unref(sg->roomlist);
-+ gaim2_roomlist_set_in_progress(sg->roomlist, FALSE);
-+ gaim2_roomlist_unref(sg->roomlist);
- sg->roomlist = NULL;
- return;
- }
-@@ -1457,28 +1457,28 @@ silc_command_reply(SilcClient client, Si
- (void)va_arg(vp, SilcChannelEntry);
- name = va_arg(vp, char *);
- if (!name) {
-- gaim_notify_error(gc, _("Roomlist"), _("Cannot get room list"),
-+ gaim2_notify_error(gc, _("Roomlist"), _("Cannot get room list"),
- silc_get_status_message(status));
-- gaim_roomlist_set_in_progress(sg->roomlist, FALSE);
-- gaim_roomlist_unref(sg->roomlist);
-+ gaim2_roomlist_set_in_progress(sg->roomlist, FALSE);
-+ gaim2_roomlist_unref(sg->roomlist);
- sg->roomlist = NULL;
- return;
- }
- topic = va_arg(vp, char *);
- usercount = va_arg(vp, int);
-
-- room = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, name, NULL);
-- gaim_roomlist_room_add_field(sg->roomlist, room, name);
-- gaim_roomlist_room_add_field(sg->roomlist, room,
-+ room = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, name, NULL);
-+ gaim2_roomlist_room_add_field(sg->roomlist, room, name);
-+ gaim2_roomlist_room_add_field(sg->roomlist, room,
- SILC_32_TO_PTR(usercount));
-- gaim_roomlist_room_add_field(sg->roomlist, room,
-+ gaim2_roomlist_room_add_field(sg->roomlist, room,
- topic ? topic : "");
-- gaim_roomlist_room_add(sg->roomlist, room);
-+ gaim2_roomlist_room_add(sg->roomlist, room);
-
- if (status == SILC_STATUS_LIST_END ||
- status == SILC_STATUS_OK) {
-- gaim_roomlist_set_in_progress(sg->roomlist, FALSE);
-- gaim_roomlist_unref(sg->roomlist);
-+ gaim2_roomlist_set_in_progress(sg->roomlist, FALSE);
-+ gaim2_roomlist_unref(sg->roomlist);
- sg->roomlist = NULL;
- }
- }
-@@ -1489,7 +1489,7 @@ silc_command_reply(SilcClient client, Si
- SilcPublicKey public_key;
-
- if (!success) {
-- gaim_notify_error(gc, _("Get Public Key"),
-+ gaim2_notify_error(gc, _("Get Public Key"),
- _("Cannot fetch the public key"),
- silc_get_status_message(status));
- return;
-@@ -1500,7 +1500,7 @@ silc_command_reply(SilcClient client, Si
- public_key = va_arg(vp, SilcPublicKey);
-
- if (!public_key)
-- gaim_notify_error(gc, _("Get Public Key"),
-+ gaim2_notify_error(gc, _("Get Public Key"),
- _("Cannot fetch the public key"),
- _("No public key was received"));
- }
-@@ -1515,7 +1515,7 @@ silc_command_reply(SilcClient client, Si
- char tmp[256];
-
- if (!success) {
-- gaim_notify_error(gc, _("Server Information"),
-+ gaim2_notify_error(gc, _("Server Information"),
- _("Cannot get server information"),
- silc_get_status_message(status));
- return;
-@@ -1528,7 +1528,7 @@ silc_command_reply(SilcClient client, Si
- if (server_name && server_info) {
- g_snprintf(tmp, sizeof(tmp), "Server: %s\n%s",
- server_name, server_info);
-- gaim_notify_info(gc, NULL, _("Server Information"), tmp);
-+ gaim2_notify_info(gc, NULL, _("Server Information"), tmp);
- }
- }
- break;
-@@ -1545,7 +1545,7 @@ silc_command_reply(SilcClient client, Si
- char *msg;
-
- if (!success) {
-- gaim_notify_error(gc, _("Server Statistics"),
-+ gaim2_notify_error(gc, _("Server Statistics"),
- _("Cannot get server statistics"),
- silc_get_status_message(status));
- return;
-@@ -1554,7 +1554,7 @@ silc_command_reply(SilcClient client, Si
- server_stats = va_arg(vp, unsigned char *);
- buffer_length = va_arg(vp, SilcUInt32);
- if (!server_stats || !buffer_length) {
-- gaim_notify_error(gc, _("Server Statistics"),
-+ gaim2_notify_error(gc, _("Server Statistics"),
- _("No server statistics available"), NULL);
- break;
- }
-@@ -1593,13 +1593,13 @@ silc_command_reply(SilcClient client, Si
- "Total server operators: %d\n"
- "Total router operators: %d\n"),
- silc_get_time(starttime),
-- gaim_str_seconds_to_string((int)uptime),
-+ gaim2_str_seconds_to_string((int)uptime),
- (int)my_clients, (int)my_channels, (int)my_server_ops, (int)my_router_ops,
- (int)cell_clients, (int)cell_channels, (int)cell_servers,
- (int)clients, (int)channels, (int)servers, (int)routers,
- (int)server_ops, (int)router_ops);
-
-- gaim_notify_info(gc, NULL,
-+ gaim2_notify_info(gc, NULL,
- _("Network Statistics"), msg);
- g_free(msg);
- }
-@@ -1608,19 +1608,19 @@ silc_command_reply(SilcClient client, Si
- case SILC_COMMAND_PING:
- {
- if (!success) {
-- gaim_notify_error(gc, _("Ping"), _("Ping failed"),
-+ gaim2_notify_error(gc, _("Ping"), _("Ping failed"),
- silc_get_status_message(status));
- return;
- }
-
-- gaim_notify_info(gc, _("Ping"), _("Ping reply received from server"),
-+ gaim2_notify_info(gc, _("Ping"), _("Ping reply received from server"),
- NULL);
- }
- break;
-
- case SILC_COMMAND_KILL:
- if (!success) {
-- gaim_notify_error(gc, _("Kill User"),
-+ gaim2_notify_error(gc, _("Kill User"),
- _("Could not kill user"),
- silc_get_status_message(status));
- return;
-@@ -1641,15 +1641,15 @@ silc_command_reply(SilcClient client, Si
- channel_pubkeys = va_arg(vp, SilcBuffer);
-
- if (sg->chpk)
-- silcgaim_chat_chauth_show(sg, channel_entry, channel_pubkeys);
-+ silcgaim2_chat_chauth_show(sg, channel_entry, channel_pubkeys);
- }
- break;
-
- default:
- if (success)
-- gaim_debug_info("silc", "Unhandled command: %d (succeeded)\n", command);
-+ gaim2_debug_info("silc", "Unhandled command: %d (succeeded)\n", command);
- else
-- gaim_debug_info("silc", "Unhandled command: %d (failed: %s)\n", command,
-+ gaim2_debug_info("silc", "Unhandled command: %d (failed: %s)\n", command,
- silc_get_status_message(status));
- break;
- }
-@@ -1668,8 +1668,8 @@ static void
- silc_connected(SilcClient client, SilcClientConnection conn,
- SilcClientConnectionStatus status)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
- gboolean reject_watch, block_invites, block_ims;
-
- if (!gc) {
-@@ -1681,17 +1681,17 @@ silc_connected(SilcClient client, SilcCl
- switch (status) {
- case SILC_CLIENT_CONN_SUCCESS:
- case SILC_CLIENT_CONN_SUCCESS_RESUME:
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- /* Send the server our buddy list */
-- silcgaim_send_buddylist(gc);
-+ silcgaim2_send_buddylist(gc);
-
-- g_unlink(silcgaim_session_file(gaim_account_get_username(sg->account)));
-+ g_unlink(silcgaim2_session_file(gaim2_account_get_username(sg->account)));
-
- /* Send any UMODEs configured for account */
-- reject_watch = gaim_account_get_bool(sg->account, "reject-watch", FALSE);
-- block_invites = gaim_account_get_bool(sg->account, "block-invites", FALSE);
-- block_ims = gaim_account_get_bool(sg->account, "block-ims", FALSE);
-+ reject_watch = gaim2_account_get_bool(sg->account, "reject-watch", FALSE);
-+ block_invites = gaim2_account_get_bool(sg->account, "block-invites", FALSE);
-+ block_ims = gaim2_account_get_bool(sg->account, "block-ims", FALSE);
- if (reject_watch || block_invites || block_ims) {
- char m[5];
- g_snprintf(m, sizeof(m), "+%s%s%s",
-@@ -1705,27 +1705,27 @@ silc_connected(SilcClient client, SilcCl
- return;
- break;
- case SILC_CLIENT_CONN_ERROR:
-- gaim_connection_error(gc, _("Error during connecting to SILC Server"));
-- g_unlink(silcgaim_session_file(gaim_account_get_username(sg->account)));
-+ gaim2_connection_error(gc, _("Error during connecting to SILC Server"));
-+ g_unlink(silcgaim2_session_file(gaim2_account_get_username(sg->account)));
- break;
-
- case SILC_CLIENT_CONN_ERROR_KE:
-- gaim_connection_error(gc, _("Key Exchange failed"));
-+ gaim2_connection_error(gc, _("Key Exchange failed"));
- break;
-
- case SILC_CLIENT_CONN_ERROR_AUTH:
-- gaim_connection_error(gc, _("Authentication failed"));
-+ gaim2_connection_error(gc, _("Authentication failed"));
- break;
-
- case SILC_CLIENT_CONN_ERROR_RESUME:
-- gaim_connection_error(gc,
-+ gaim2_connection_error(gc,
- _("Resuming detached session failed. "
- "Press Reconnect to create new connection."));
-- g_unlink(silcgaim_session_file(gaim_account_get_username(sg->account)));
-+ g_unlink(silcgaim2_session_file(gaim2_account_get_username(sg->account)));
- break;
-
- case SILC_CLIENT_CONN_ERROR_TIMEOUT:
-- gaim_connection_error(gc, _("Connection Timeout"));
-+ gaim2_connection_error(gc, _("Connection Timeout"));
- break;
- }
-
-@@ -1744,27 +1744,27 @@ static void
- silc_disconnected(SilcClient client, SilcClientConnection conn,
- SilcStatus status, const char *message)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-
- if (sg->resuming && !sg->detaching)
-- g_unlink(silcgaim_session_file(gaim_account_get_username(sg->account)));
-+ g_unlink(silcgaim2_session_file(gaim2_account_get_username(sg->account)));
-
- sg->conn = NULL;
-
- /* Close the connection */
- if (!sg->detaching)
-- gaim_connection_error(gc, _("Disconnected by server"));
-+ gaim2_connection_error(gc, _("Disconnected by server"));
- else
- /* TODO: Does this work correctly? Maybe we need to set wants_to_die? */
-- gaim_account_disconnect(gaim_connection_get_account(gc));
-+ gaim2_account_disconnect(gaim2_connection_get_account(gc));
- }
-
-
- typedef struct {
- SilcGetAuthMeth completion;
- void *context;
--} *SilcGaimGetAuthMethod;
-+} *SilcGaim2GetAuthMethod;
-
- /* Callback called when we've received the authentication method information
- from the server after we've requested it. */
-@@ -1774,7 +1774,7 @@ static void silc_get_auth_method_callbac
- SilcAuthMethod auth_meth,
- void *context)
- {
-- SilcGaimGetAuthMethod internal = context;
-+ SilcGaim2GetAuthMethod internal = context;
-
- switch (auth_meth) {
- case SILC_AUTH_NONE:
-@@ -1809,24 +1809,24 @@ silc_get_auth_method(SilcClient client,
- char *hostname, SilcUInt16 port,
- SilcGetAuthMeth completion, void *context)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- SilcGaimGetAuthMethod internal;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ SilcGaim2GetAuthMethod internal;
- const char *password;
-
- /* Progress */
- if (sg->resuming)
-- gaim_connection_update_progress(gc, _("Resuming session"), 4, 5);
-+ gaim2_connection_update_progress(gc, _("Resuming session"), 4, 5);
- else
-- gaim_connection_update_progress(gc, _("Authenticating connection"), 4, 5);
-+ gaim2_connection_update_progress(gc, _("Authenticating connection"), 4, 5);
-
- /* Check configuration if we have this connection configured. If we
- have then return that data immediately, as it's faster way. */
-- if (gaim_account_get_bool(sg->account, "pubkey-auth", FALSE)) {
-+ if (gaim2_account_get_bool(sg->account, "pubkey-auth", FALSE)) {
- completion(TRUE, SILC_AUTH_PUBLIC_KEY, NULL, 0, context);
- return;
- }
-- password = gaim_connection_get_password(gc);
-+ password = gaim2_connection_get_password(gc);
- if (password && *password) {
- completion(TRUE, SILC_AUTH_PASSWORD, (unsigned char *)password, strlen(password), context);
- return;
-@@ -1856,31 +1856,31 @@ silc_verify_public_key(SilcClient client
- SilcUInt32 pk_len, SilcSKEPKType pk_type,
- SilcVerifyPublicKey completion, void *context)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-
- if (!sg->conn && (conn_type == SILC_SOCKET_TYPE_SERVER ||
- conn_type == SILC_SOCKET_TYPE_ROUTER)) {
- /* Progress */
- if (sg->resuming)
-- gaim_connection_update_progress(gc, _("Resuming session"), 3, 5);
-+ gaim2_connection_update_progress(gc, _("Resuming session"), 3, 5);
- else
-- gaim_connection_update_progress(gc, _("Verifying server public key"),
-+ gaim2_connection_update_progress(gc, _("Verifying server public key"),
- 3, 5);
- }
-
- /* Verify public key */
-- silcgaim_verify_public_key(client, conn, NULL, conn_type, pk,
-+ silcgaim2_verify_public_key(client, conn, NULL, conn_type, pk,
- pk_len, pk_type, completion, context);
- }
-
- typedef struct {
- SilcAskPassphrase completion;
- void *context;
--} *SilcGaimAskPassphrase;
-+} *SilcGaim2AskPassphrase;
-
- static void
--silc_ask_passphrase_cb(SilcGaimAskPassphrase internal, const char *passphrase)
-+silc_ask_passphrase_cb(SilcGaim2AskPassphrase internal, const char *passphrase)
- {
- if (!passphrase || !(*passphrase))
- internal->completion(NULL, 0, internal->context);
-@@ -1899,13 +1899,13 @@ static void
- silc_ask_passphrase(SilcClient client, SilcClientConnection conn,
- SilcAskPassphrase completion, void *context)
- {
-- SilcGaimAskPassphrase internal = silc_calloc(1, sizeof(*internal));
-+ SilcGaim2AskPassphrase internal = silc_calloc(1, sizeof(*internal));
-
- if (!internal)
- return;
- internal->completion = completion;
- internal->context = context;
-- gaim_request_input(client->application, _("Passphrase"), NULL,
-+ gaim2_request_input(client->application, _("Passphrase"), NULL,
- _("Passphrase required"), NULL, FALSE, TRUE, NULL,
- _("OK"), G_CALLBACK(silc_ask_passphrase_cb),
- _("Cancel"), G_CALLBACK(silc_ask_passphrase_cb),
-@@ -1925,7 +1925,7 @@ static void
- silc_failure(SilcClient client, SilcClientConnection conn,
- SilcProtocol protocol, void *failure)
- {
-- GaimConnection *gc = client->application;
-+ Gaim2Connection *gc = client->application;
- char buf[128];
-
- memset(buf, 0, sizeof(buf));
-@@ -1961,7 +1961,7 @@ silc_failure(SilcClient client, SilcClie
-
- /* Show the error on the progress bar. A more generic error message
- is going to be showed to user after this in the silc_connected. */
-- gaim_connection_update_progress(gc, buf, 2, 5);
-+ gaim2_connection_update_progress(gc, buf, 2, 5);
- }
-
- if (protocol->protocol->type == SILC_PROTOCOL_CLIENT_CONNECTION_AUTH) {
-@@ -1972,7 +1972,7 @@ silc_failure(SilcClient client, SilcClie
-
- /* Show the error on the progress bar. A more generic error message
- is going to be showed to user after this in the silc_connected. */
-- gaim_connection_update_progress(gc, buf, 4, 5);
-+ gaim2_connection_update_progress(gc, buf, 4, 5);
- }
- }
-
-@@ -1990,7 +1990,7 @@ silc_key_agreement(SilcClient client, Si
- SilcUInt16 port, SilcKeyAgreementCallback *completion,
- void **context)
- {
-- silcgaim_buddy_keyagr_request(client, conn, client_entry, hostname, port);
-+ silcgaim2_buddy_keyagr_request(client, conn, client_entry, hostname, port);
- *completion = NULL;
- *context = NULL;
- return FALSE;
-@@ -2009,7 +2009,7 @@ silc_ftp(SilcClient client, SilcClientCo
- SilcClientEntry client_entry, SilcUInt32 session_id,
- const char *hostname, SilcUInt16 port)
- {
-- silcgaim_ftp_request(client, conn, client_entry, session_id,
-+ silcgaim2_ftp_request(client, conn, client_entry, session_id,
- hostname, port);
- }
-
-@@ -2035,12 +2035,12 @@ static void
- silc_detach(SilcClient client, SilcClientConnection conn,
- const unsigned char *detach_data, SilcUInt32 detach_data_len)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
- const char *file;
-
- /* Save the detachment data to file. */
-- file = silcgaim_session_file(gaim_account_get_username(sg->account));
-+ file = silcgaim2_session_file(gaim2_account_get_username(sg->account));
- g_unlink(file);
- silc_file_writefile(file, (char *)detach_data, detach_data_len);
- }
-diff -prNu ./src/protocols/silc/pk.c ./src/protocols/silc/pk.c
---- ./src/protocols/silc/pk.c 2005-12-21 22:18:25.000000000 +0100
-+++ ./src/protocols/silc/pk.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim_pk.c
-+ silcgaim2_pk.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,7 +19,7 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
-
- /************************* Public Key Verification ***************************/
-
-@@ -39,12 +39,12 @@ typedef struct {
- gboolean changed;
- } *PublicKeyVerify;
-
--static void silcgaim_verify_ask(const char *entity,
-+static void silcgaim2_verify_ask(const char *entity,
- const char *fingerprint,
- const char *babbleprint,
- PublicKeyVerify verify);
-
--static void silcgaim_verify_cb(PublicKeyVerify verify, gint id)
-+static void silcgaim2_verify_cb(PublicKeyVerify verify, gint id)
- {
- if (id != 2) {
- if (verify->completion)
-@@ -67,31 +67,31 @@ static void silcgaim_verify_cb(PublicKey
- silc_free(verify);
- }
-
--static void silcgaim_verify_details_cb(PublicKeyVerify verify)
-+static void silcgaim2_verify_details_cb(PublicKeyVerify verify)
- {
- /* What a hack. We have to display the accept dialog _again_
-- because Gaim closes the dialog after you press the button. Gaim
-+ because Gaim2 closes the dialog after you press the button. Gaim2
- should have option for the dialogs whether the buttons close them
- or not. */
-- silcgaim_verify_ask(verify->entity, verify->fingerprint,
-+ silcgaim2_verify_ask(verify->entity, verify->fingerprint,
- verify->babbleprint, verify);
- }
-
--static void silcgaim_verify_details(PublicKeyVerify verify, gint id)
-+static void silcgaim2_verify_details(PublicKeyVerify verify, gint id)
- {
- SilcPublicKey public_key;
-- GaimConnection *gc = verify->client->application;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = verify->client->application;
-+ SilcGaim2 sg = gc->proto_data;
-
- silc_pkcs_public_key_decode(verify->pk, verify->pk_len,
- &public_key);
-- silcgaim_show_public_key(sg, verify->entity_name, public_key,
-- G_CALLBACK(silcgaim_verify_details_cb),
-+ silcgaim2_show_public_key(sg, verify->entity_name, public_key,
-+ G_CALLBACK(silcgaim2_verify_details_cb),
- verify);
- silc_pkcs_public_key_free(public_key);
- }
-
--static void silcgaim_verify_ask(const char *entity,
-+static void silcgaim2_verify_ask(const char *entity,
- const char *fingerprint,
- const char *babbleprint,
- PublicKeyVerify verify)
-@@ -112,20 +112,20 @@ static void silcgaim_verify_ask(const ch
- _("Fingerprint and babbleprint for the %s key are:\n\n"
- "%s\n%s\n"), entity, fingerprint, babbleprint);
-
-- gaim_request_action(verify->client->application, _("Verify Public Key"), tmp, tmp2,
-+ gaim2_request_action(verify->client->application, _("Verify Public Key"), tmp, tmp2,
- GAIM_DEFAULT_ACTION_NONE, verify, 3,
-- _("Yes"), G_CALLBACK(silcgaim_verify_cb),
-- _("No"), G_CALLBACK(silcgaim_verify_cb),
-- _("_View..."), G_CALLBACK(silcgaim_verify_details));
-+ _("Yes"), G_CALLBACK(silcgaim2_verify_cb),
-+ _("No"), G_CALLBACK(silcgaim2_verify_cb),
-+ _("_View..."), G_CALLBACK(silcgaim2_verify_details));
- }
-
--void silcgaim_verify_public_key(SilcClient client, SilcClientConnection conn,
-+void silcgaim2_verify_public_key(SilcClient client, SilcClientConnection conn,
- const char *name, SilcSocketType conn_type,
- unsigned char *pk, SilcUInt32 pk_len,
- SilcSKEPKType pk_type,
- SilcVerifyPublicKey completion, void *context)
- {
-- GaimConnection *gc = client->application;
-+ Gaim2Connection *gc = client->application;
- int i;
- char file[256], filename[256], filename2[256], *ipf, *hostf = NULL;
- char *fingerprint, *babbleprint;
-@@ -137,7 +137,7 @@ void silcgaim_verify_public_key(SilcClie
- PublicKeyVerify verify;
-
- if (pk_type != SILC_SKE_PK_TYPE_SILC) {
-- gaim_notify_error(gc, _("Verify Public Key"),
-+ gaim2_notify_error(gc, _("Verify Public Key"),
- _("Unsupported public key type"), NULL);
- if (completion)
- completion(FALSE, context);
-@@ -162,13 +162,13 @@ void silcgaim_verify_public_key(SilcClie
- conn->sock->ip, conn->sock->port);
- g_snprintf(filename, sizeof(filename) - 1,
- "%s" G_DIR_SEPARATOR_S "%skeys" G_DIR_SEPARATOR_S "%s",
-- silcgaim_silcdir(), entity, file);
-+ silcgaim2_silcdir(), entity, file);
-
- g_snprintf(file, sizeof(file) - 1, "%skey_%s_%d.pub", entity,
- conn->sock->hostname, conn->sock->port);
- g_snprintf(filename2, sizeof(filename2) - 1,
- "%s" G_DIR_SEPARATOR_S "%skeys" G_DIR_SEPARATOR_S "%s",
-- silcgaim_silcdir(), entity, file);
-+ silcgaim2_silcdir(), entity, file);
-
- ipf = filename;
- hostf = filename2;
-@@ -177,7 +177,7 @@ void silcgaim_verify_public_key(SilcClie
- name, conn->sock->port);
- g_snprintf(filename, sizeof(filename) - 1,
- "%s" G_DIR_SEPARATOR_S "%skeys" G_DIR_SEPARATOR_S "%s",
-- silcgaim_silcdir(), entity, file);
-+ silcgaim2_silcdir(), entity, file);
-
- ipf = filename;
- }
-@@ -191,7 +191,7 @@ void silcgaim_verify_public_key(SilcClie
- g_snprintf(file, sizeof(file) - 1, "%skey_%s.pub", entity, fingerprint);
- g_snprintf(filename, sizeof(filename) - 1,
- "%s" G_DIR_SEPARATOR_S "%skeys" G_DIR_SEPARATOR_S "%s",
-- silcgaim_silcdir(), entity, file);
-+ silcgaim2_silcdir(), entity, file);
- silc_free(fingerprint);
-
- ipf = filename;
-@@ -218,7 +218,7 @@ void silcgaim_verify_public_key(SilcClie
- /* Check whether this key already exists */
- if (g_stat(ipf, &st) < 0 && (!hostf || g_stat(hostf, &st) < 0)) {
- /* Key does not exist, ask user to verify the key and save it */
-- silcgaim_verify_ask(name ? name : entity,
-+ silcgaim2_verify_ask(name ? name : entity,
- fingerprint, babbleprint, verify);
- return;
- } else {
-@@ -236,7 +236,7 @@ void silcgaim_verify_public_key(SilcClie
- SILC_PKCS_FILE_PEM) &&
- !silc_pkcs_load_public_key(hostf, &public_key,
- SILC_PKCS_FILE_BIN)))) {
-- silcgaim_verify_ask(name ? name : entity,
-+ silcgaim2_verify_ask(name ? name : entity,
- fingerprint, babbleprint, verify);
- return;
- }
-@@ -244,7 +244,7 @@ void silcgaim_verify_public_key(SilcClie
- /* Encode the key data */
- encpk = silc_pkcs_public_key_encode(public_key, &encpk_len);
- if (!encpk) {
-- silcgaim_verify_ask(name ? name : entity,
-+ silcgaim2_verify_ask(name ? name : entity,
- fingerprint, babbleprint, verify);
- return;
- }
-@@ -253,7 +253,7 @@ void silcgaim_verify_public_key(SilcClie
- if (memcmp(encpk, pk, encpk_len)) {
- /* Ask user to verify the key and save it */
- verify->changed = TRUE;
-- silcgaim_verify_ask(name ? name : entity,
-+ silcgaim2_verify_ask(name ? name : entity,
- fingerprint, babbleprint, verify);
- return;
- }
-diff -prNu ./src/protocols/silc/silc.c ./src/protocols/silc/silc.c
---- ./src/protocols/silc/silc.c 2005-12-25 20:09:25.000000000 +0100
-+++ ./src/protocols/silc/silc.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim.c
-+ silcgaim2.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,54 +19,54 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "version.h"
- #include "wb.h"
-
- extern SilcClientOperations ops;
--static GaimPlugin *silc_plugin = NULL;
-+static Gaim2Plugin *silc_plugin = NULL;
-
- static const char *
--silcgaim_list_icon(GaimAccount *a, GaimBuddy *b)
-+silcgaim2_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- return (const char *)"silc";
- }
-
- static void
--silcgaim_list_emblems(GaimBuddy *b, const char **se, const char **sw,
-+silcgaim2_list_emblems(Gaim2Buddy *b, const char **se, const char **sw,
- const char **nw, const char **ne)
- {
- }
-
- static GList *
--silcgaim_away_states(GaimAccount *account)
-+silcgaim2_away_states(Gaim2Account *account)
- {
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- GList *types = NULL;
-
-- type = gaim_status_type_new_full(GAIM_STATUS_AVAILABLE, SILCGAIM_STATUS_ID_AVAILABLE, NULL, FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AVAILABLE, SILCGAIM_STATUS_ID_AVAILABLE, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-- type = gaim_status_type_new_full(GAIM_STATUS_AVAILABLE, SILCGAIM_STATUS_ID_HYPER, _("Hyper Active"), FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AVAILABLE, SILCGAIM_STATUS_ID_HYPER, _("Hyper Active"), FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-- type = gaim_status_type_new_full(GAIM_STATUS_AWAY, SILCGAIM_STATUS_ID_AWAY, NULL, FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AWAY, SILCGAIM_STATUS_ID_AWAY, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-- type = gaim_status_type_new_full(GAIM_STATUS_UNAVAILABLE, SILCGAIM_STATUS_ID_BUSY, _("Busy"), FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_UNAVAILABLE, SILCGAIM_STATUS_ID_BUSY, _("Busy"), FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-- type = gaim_status_type_new_full(GAIM_STATUS_AWAY, SILCGAIM_STATUS_ID_INDISPOSED, _("Indisposed"), FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AWAY, SILCGAIM_STATUS_ID_INDISPOSED, _("Indisposed"), FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-- type = gaim_status_type_new_full(GAIM_STATUS_AWAY, SILCGAIM_STATUS_ID_PAGE, _("Wake Me Up"), FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_AWAY, SILCGAIM_STATUS_ID_PAGE, _("Wake Me Up"), FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-- type = gaim_status_type_new_full(GAIM_STATUS_OFFLINE, SILCGAIM_STATUS_ID_OFFLINE, NULL, FALSE, TRUE, FALSE);
-+ type = gaim2_status_type_new_full(GAIM_STATUS_OFFLINE, SILCGAIM_STATUS_ID_OFFLINE, NULL, FALSE, TRUE, FALSE);
- types = g_list_append(types, type);
-
- return types;
- }
-
- static void
--silcgaim_set_status(GaimAccount *account, GaimStatus *status)
-+silcgaim2_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-- SilcGaim sg = NULL;
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
-+ SilcGaim2 sg = NULL;
- SilcUInt32 mode;
- SilcBuffer idp;
- unsigned char mb[4];
-@@ -78,7 +78,7 @@ silcgaim_set_status(GaimAccount *account
- if (status == NULL)
- return;
-
-- state = gaim_status_get_id(status);
-+ state = gaim2_status_get_id(status);
-
- if (state == NULL)
- return;
-@@ -118,41 +118,41 @@ silcgaim_set_status(GaimAccount *account
- /*************************** Connection Routines *****************************/
-
- static void
--silcgaim_keepalive(GaimConnection *gc)
-+silcgaim2_keepalive(Gaim2Connection *gc)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- silc_client_send_packet(sg->client, sg->conn, SILC_PACKET_HEARTBEAT,
- NULL, 0);
- }
-
- static int
--silcgaim_scheduler(gpointer *context)
-+silcgaim2_scheduler(gpointer *context)
- {
-- SilcGaim sg = (SilcGaim)context;
-+ SilcGaim2 sg = (SilcGaim2)context;
- silc_client_run_one(sg->client);
- return 1;
- }
-
- static void
--silcgaim_nickname_parse(const char *nickname,
-+silcgaim2_nickname_parse(const char *nickname,
- char **ret_nickname)
- {
- silc_parse_userfqdn(nickname, ret_nickname, NULL);
- }
-
- static void
--silcgaim_login_connected(gpointer data, gint source, GaimInputCondition cond)
-+silcgaim2_login_connected(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client;
- SilcClientConnection conn;
-- GaimAccount *account = sg->account;
-+ Gaim2Account *account = sg->account;
- SilcClientConnectionParams params;
- const char *dfile;
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Connection failed"));
-+ gaim2_connection_error(gc, _("Connection failed"));
- return;
- }
-
-@@ -161,7 +161,7 @@ silcgaim_login_connected(gpointer data,
-
- client = sg->client;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- g_source_remove(sg->scheduler);
- silc_client_stop(sg->client);
-@@ -172,7 +172,7 @@ silcgaim_login_connected(gpointer data,
-
- /* Get session detachment data, if available */
- memset(&params, 0, sizeof(params));
-- dfile = silcgaim_session_file(gaim_account_get_username(sg->account));
-+ dfile = silcgaim2_session_file(gaim2_account_get_username(sg->account));
- params.detach_data = (unsigned char *)silc_file_readfile(dfile, &params.detach_data_len);
- if (params.detach_data)
- params.detach_data[params.detach_data_len] = 0;
-@@ -180,11 +180,11 @@ silcgaim_login_connected(gpointer data,
- /* Add connection to SILC client library */
- conn = silc_client_add_connection(
- sg->client, &params,
-- (char *)gaim_account_get_string(account, "server",
-+ (char *)gaim2_account_get_string(account, "server",
- "silc.silcnet.org"),
-- gaim_account_get_int(account, "port", 706), sg);
-+ gaim2_account_get_int(account, "port", 706), sg);
- if (!conn) {
-- gaim_connection_error(gc, _("Cannot initialize SILC Client connection"));
-+ gaim2_connection_error(gc, _("Cannot initialize SILC Client connection"));
- gc->proto_data = NULL;
- return;
- }
-@@ -192,10 +192,10 @@ silcgaim_login_connected(gpointer data,
-
- /* Progress */
- if (params.detach_data) {
-- gaim_connection_update_progress(gc, _("Resuming session"), 2, 5);
-+ gaim2_connection_update_progress(gc, _("Resuming session"), 2, 5);
- sg->resuming = TRUE;
- } else {
-- gaim_connection_update_progress(gc, _("Performing key exchange"), 2, 5);
-+ gaim2_connection_update_progress(gc, _("Performing key exchange"), 2, 5);
- }
-
- /* Perform SILC Key Exchange. The "silc_connected" will be called
-@@ -203,7 +203,7 @@ silcgaim_login_connected(gpointer data,
- silc_client_start_key_exchange(sg->client, sg->conn, source);
-
- /* Set default attributes */
-- if (!gaim_account_get_bool(account, "reject-attrs", FALSE)) {
-+ if (!gaim2_account_get_bool(account, "reject-attrs", FALSE)) {
- SilcUInt32 mask;
- const char *tmp;
- #ifdef HAVE_SYS_UTSNAME_H
-@@ -246,12 +246,12 @@ silcgaim_login_connected(gpointer data,
- }
-
- static void
--silcgaim_login(GaimAccount *account)
-+silcgaim2_login(Gaim2Account *account)
- {
-- SilcGaim sg;
-+ SilcGaim2 sg;
- SilcClient client;
- SilcClientParams params;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char pkd[256], prd[256];
- const char *cipher, *hmac;
- int i;
-@@ -263,45 +263,45 @@ silcgaim_login(GaimAccount *account)
-
- memset(&params, 0, sizeof(params));
- strcat(params.nickname_format, "%n@%h%a");
-- params.nickname_parse = silcgaim_nickname_parse;
-+ params.nickname_parse = silcgaim2_nickname_parse;
- params.ignore_requested_attributes =
-- gaim_account_get_bool(account, "reject-attrs", FALSE);
-+ gaim2_account_get_bool(account, "reject-attrs", FALSE);
-
- /* Allocate SILC client */
- client = silc_client_alloc(&ops, &params, gc, NULL);
- if (!client) {
-- gaim_connection_error(gc, _("Out of memory"));
-+ gaim2_connection_error(gc, _("Out of memory"));
- return;
- }
-
- /* Get username, real name and local hostname for SILC library */
-- if (gaim_account_get_username(account)) {
-- const char *u = gaim_account_get_username(account);
-+ if (gaim2_account_get_username(account)) {
-+ const char *u = gaim2_account_get_username(account);
- char **up = g_strsplit(u, "@", 2);
- client->username = strdup(up[0]);
- g_strfreev(up);
- } else {
- client->username = silc_get_username();
-- gaim_account_set_username(account, client->username);
-+ gaim2_account_set_username(account, client->username);
- }
-- if (gaim_account_get_user_info(account)) {
-- client->realname = strdup(gaim_account_get_user_info(account));
-+ if (gaim2_account_get_user_info(account)) {
-+ client->realname = strdup(gaim2_account_get_user_info(account));
- } else {
- client->realname = silc_get_real_name();
-- gaim_account_set_user_info(account, client->realname);
-+ gaim2_account_set_user_info(account, client->realname);
- }
- client->hostname = silc_net_localhost();
-
-- gaim_connection_set_display_name(gc, client->username);
-+ gaim2_connection_set_display_name(gc, client->username);
-
- /* Register requested cipher and HMAC */
-- cipher = gaim_account_get_string(account, "cipher", SILC_DEFAULT_CIPHER);
-+ cipher = gaim2_account_get_string(account, "cipher", SILC_DEFAULT_CIPHER);
- for (i = 0; silc_default_ciphers[i].name; i++)
- if (!strcmp(silc_default_ciphers[i].name, cipher)) {
- silc_cipher_register(&(silc_default_ciphers[i]));
- break;
- }
-- hmac = gaim_account_get_string(account, "hmac", SILC_DEFAULT_HMAC);
-+ hmac = gaim2_account_get_string(account, "hmac", SILC_DEFAULT_HMAC);
- for (i = 0; silc_default_hmacs[i].name; i++)
- if (!strcmp(silc_default_hmacs[i].name, hmac)) {
- silc_hmac_register(&(silc_default_hmacs[i]));
-@@ -311,29 +311,29 @@ silcgaim_login(GaimAccount *account)
- /* Init SILC client */
- if (!silc_client_init(client)) {
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, ("Cannot initialize SILC protocol"));
-+ gaim2_connection_error(gc, ("Cannot initialize SILC protocol"));
- return;
- }
-
- /* Check the ~/.silc dir and create it, and new key pair if necessary. */
-- if (!silcgaim_check_silc_dir(gc)) {
-+ if (!silcgaim2_check_silc_dir(gc)) {
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, ("Cannot find/access ~/.silc directory"));
-+ gaim2_connection_error(gc, ("Cannot find/access ~/.silc directory"));
- return;
- }
-
- /* Progress */
-- gaim_connection_update_progress(gc, _("Connecting to SILC Server"), 1, 5);
-+ gaim2_connection_update_progress(gc, _("Connecting to SILC Server"), 1, 5);
-
- /* Load SILC key pair */
-- g_snprintf(pkd, sizeof(pkd), "%s" G_DIR_SEPARATOR_S "public_key.pub", silcgaim_silcdir());
-- g_snprintf(prd, sizeof(prd), "%s" G_DIR_SEPARATOR_S "private_key.prv", silcgaim_silcdir());
-- if (!silc_load_key_pair((char *)gaim_account_get_string(account, "public-key", pkd),
-- (char *)gaim_account_get_string(account, "private-key", prd),
-+ g_snprintf(pkd, sizeof(pkd), "%s" G_DIR_SEPARATOR_S "public_key.pub", silcgaim2_silcdir());
-+ g_snprintf(prd, sizeof(prd), "%s" G_DIR_SEPARATOR_S "private_key.prv", silcgaim2_silcdir());
-+ if (!silc_load_key_pair((char *)gaim2_account_get_string(account, "public-key", pkd),
-+ (char *)gaim2_account_get_string(account, "private-key", prd),
- (gc->password == NULL) ? "" : gc->password, &client->pkcs,
- &client->public_key, &client->private_key)) {
- g_snprintf(pkd, sizeof(pkd), ("Could not load SILC key pair: %s"), strerror(errno));
-- gaim_connection_error(gc, pkd);
-+ gaim2_connection_error(gc, pkd);
- return;
- }
-
-@@ -347,27 +347,27 @@ silcgaim_login(GaimAccount *account)
- gc->proto_data = sg;
-
- /* Connect to the SILC server */
-- if (gaim_proxy_connect(account,
-- gaim_account_get_string(account, "server",
-+ if (gaim2_proxy_connect(account,
-+ gaim2_account_get_string(account, "server",
- "silc.silcnet.org"),
-- gaim_account_get_int(account, "port", 706),
-- silcgaim_login_connected, gc)) {
-- gaim_connection_error(gc, ("Unable to create connection"));
-+ gaim2_account_get_int(account, "port", 706),
-+ silcgaim2_login_connected, gc)) {
-+ gaim2_connection_error(gc, ("Unable to create connection"));
- return;
- }
-
- /* Schedule SILC using Glib's event loop */
- #ifndef _WIN32
-- sg->scheduler = g_timeout_add(5, (GSourceFunc)silcgaim_scheduler, sg);
-+ sg->scheduler = g_timeout_add(5, (GSourceFunc)silcgaim2_scheduler, sg);
- #else
-- sg->scheduler = g_timeout_add(300, (GSourceFunc)silcgaim_scheduler, sg);
-+ sg->scheduler = g_timeout_add(300, (GSourceFunc)silcgaim2_scheduler, sg);
- #endif
- }
-
- static int
--silcgaim_close_final(gpointer *context)
-+silcgaim2_close_final(gpointer *context)
- {
-- SilcGaim sg = (SilcGaim)context;
-+ SilcGaim2 sg = (SilcGaim2)context;
- silc_client_stop(sg->client);
- silc_client_free(sg->client);
- #ifdef HAVE_SILCMIME_H
-@@ -379,39 +379,39 @@ silcgaim_close_final(gpointer *context)
- }
-
- static void
--silcgaim_close(GaimConnection *gc)
-+silcgaim2_close(Gaim2Connection *gc)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
-
- g_return_if_fail(sg != NULL);
-
- /* Send QUIT */
- silc_client_command_call(sg->client, sg->conn, NULL,
-- "QUIT", "Download Gaim: " GAIM_WEBSITE, NULL);
-+ "QUIT", "Download Gaim2: " GAIM_WEBSITE, NULL);
-
- if (sg->conn)
- silc_client_close_connection(sg->client, sg->conn);
-
- g_source_remove(sg->scheduler);
-- g_timeout_add(1, (GSourceFunc)silcgaim_close_final, sg);
-+ g_timeout_add(1, (GSourceFunc)silcgaim2_close_final, sg);
- }
-
-
- /****************************** Protocol Actions *****************************/
-
- static void
--silcgaim_attrs_cancel(GaimConnection *gc, GaimRequestFields *fields)
-+silcgaim2_attrs_cancel(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
- /* Nothing */
- }
-
- static void
--silcgaim_attrs_cb(GaimConnection *gc, GaimRequestFields *fields)
-+silcgaim2_attrs_cb(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
-- GaimRequestField *f;
-+ Gaim2RequestField *f;
- char *tmp;
- SilcUInt32 tmp_len, mask;
- SilcAttributeObjService service;
-@@ -450,41 +450,41 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
-
- /* Set mood */
- mask = 0;
-- f = gaim_request_fields_get_field(fields, "mood_normal");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_normal");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_NORMAL;
-- f = gaim_request_fields_get_field(fields, "mood_happy");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_happy");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_HAPPY;
-- f = gaim_request_fields_get_field(fields, "mood_sad");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_sad");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_SAD;
-- f = gaim_request_fields_get_field(fields, "mood_angry");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_angry");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_ANGRY;
-- f = gaim_request_fields_get_field(fields, "mood_jealous");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_jealous");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_JEALOUS;
-- f = gaim_request_fields_get_field(fields, "mood_ashamed");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_ashamed");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_ASHAMED;
-- f = gaim_request_fields_get_field(fields, "mood_invincible");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_invincible");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_INVINCIBLE;
-- f = gaim_request_fields_get_field(fields, "mood_inlove");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_inlove");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_INLOVE;
-- f = gaim_request_fields_get_field(fields, "mood_sleepy");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_sleepy");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_SLEEPY;
-- f = gaim_request_fields_get_field(fields, "mood_bored");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_bored");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_BORED;
-- f = gaim_request_fields_get_field(fields, "mood_excited");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_excited");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_EXCITED;
-- f = gaim_request_fields_get_field(fields, "mood_anxious");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "mood_anxious");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_MOOD_ANXIOUS;
- silc_client_attribute_add(client, conn,
- SILC_ATTRIBUTE_STATUS_MOOD,
-@@ -493,23 +493,23 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
-
- /* Set preferred contact */
- mask = 0;
-- f = gaim_request_fields_get_field(fields, "contact_chat");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "contact_chat");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_CONTACT_CHAT;
-- f = gaim_request_fields_get_field(fields, "contact_email");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "contact_email");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_CONTACT_EMAIL;
-- f = gaim_request_fields_get_field(fields, "contact_call");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "contact_call");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_CONTACT_CALL;
-- f = gaim_request_fields_get_field(fields, "contact_sms");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "contact_sms");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_CONTACT_SMS;
-- f = gaim_request_fields_get_field(fields, "contact_mms");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "contact_mms");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_CONTACT_MMS;
-- f = gaim_request_fields_get_field(fields, "contact_video");
-- if (f && gaim_request_field_bool_get_value(f))
-+ f = gaim2_request_fields_get_field(fields, "contact_video");
-+ if (f && gaim2_request_field_bool_get_value(f))
- mask |= SILC_ATTRIBUTE_CONTACT_VIDEO;
- if (mask)
- silc_client_attribute_add(client, conn,
-@@ -519,9 +519,9 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
-
- /* Set status text */
- val = NULL;
-- f = gaim_request_fields_get_field(fields, "status_text");
-+ f = gaim2_request_fields_get_field(fields, "status_text");
- if (f)
-- val = gaim_request_field_string_get_value(f);
-+ val = gaim2_request_field_string_get_value(f);
- if (val && *val)
- silc_client_attribute_add(client, conn,
- SILC_ATTRIBUTE_STATUS_FREETEXT,
-@@ -529,11 +529,11 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
-
- /* Set vcard */
- val = NULL;
-- f = gaim_request_fields_get_field(fields, "vcard");
-+ f = gaim2_request_fields_get_field(fields, "vcard");
- if (f)
-- val = gaim_request_field_string_get_value(f);
-+ val = gaim2_request_field_string_get_value(f);
- if (val && *val) {
-- gaim_account_set_string(sg->account, "vcard", val);
-+ gaim2_account_set_string(sg->account, "vcard", val);
- tmp = silc_file_readfile(val, &tmp_len);
- if (tmp) {
- tmp[tmp_len] = 0;
-@@ -546,13 +546,13 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
- silc_vcard_free(&vcard);
- silc_free(tmp);
- } else {
-- gaim_account_set_string(sg->account, "vcard", "");
-+ gaim2_account_set_string(sg->account, "vcard", "");
- }
-
- #ifdef HAVE_SYS_UTSNAME_H
- /* Set device info */
-- f = gaim_request_fields_get_field(fields, "device");
-- if (f && gaim_request_field_bool_get_value(f)) {
-+ f = gaim2_request_fields_get_field(fields, "device");
-+ if (f && gaim2_request_field_bool_get_value(f)) {
- struct utsname u;
- if (!uname(&u)) {
- dev.type = SILC_ATTRIBUTE_DEVICE_COMPUTER;
-@@ -567,9 +567,9 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
-
- /* Set timezone */
- val = NULL;
-- f = gaim_request_fields_get_field(fields, "timezone");
-+ f = gaim2_request_fields_get_field(fields, "timezone");
- if (f)
-- val = gaim_request_field_string_get_value(f);
-+ val = gaim2_request_field_string_get_value(f);
- if (val && *val)
- silc_client_attribute_add(client, conn,
- SILC_ATTRIBUTE_TIMEZONE,
-@@ -577,15 +577,15 @@ silcgaim_attrs_cb(GaimConnection *gc, Ga
- }
-
- static void
--silcgaim_attrs(GaimPluginAction *action)
-+silcgaim2_attrs(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- SilcGaim sg = gc->proto_data;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
- SilcHashTable attrs;
- SilcAttributePayload attr;
- gboolean mnormal = TRUE, mhappy = FALSE, msad = FALSE,
-@@ -648,103 +648,103 @@ silcgaim_attrs(GaimPluginAction *action)
- device = FALSE;
- }
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_label_new("l3", _("Your Current Mood"));
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_normal", _("Normal"), mnormal);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_happy", _("Happy"), mhappy);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_sad", _("Sad"), msad);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_angry", _("Angry"), mangry);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_jealous", _("Jealous"), mjealous);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_ashamed", _("Ashamed"), mashamed);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_invincible", _("Invincible"), minvincible);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_inlove", _("In Love"), minlove);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_sleepy", _("Sleepy"), msleepy);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_bored", _("Bored"), mbored);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_excited", _("Excited"), mexcited);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("mood_anxious", _("Anxious"), manxious);
-- gaim_request_field_group_add_field(g, f);
--
-- f = gaim_request_field_label_new("l4", _("\nYour Preferred Contact Methods"));
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("contact_chat", _("Chat"), cchat);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("contact_email", _("Email"), cemail);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("contact_call", _("Phone"), ccall);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("contact_sms", _("SMS"), csms);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("contact_mms", _("MMS"), cmms);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("contact_video", _("Video Conferencing"), cvideo);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_label_new("l3", _("Your Current Mood"));
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_normal", _("Normal"), mnormal);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_happy", _("Happy"), mhappy);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_sad", _("Sad"), msad);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_angry", _("Angry"), mangry);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_jealous", _("Jealous"), mjealous);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_ashamed", _("Ashamed"), mashamed);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_invincible", _("Invincible"), minvincible);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_inlove", _("In Love"), minlove);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_sleepy", _("Sleepy"), msleepy);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_bored", _("Bored"), mbored);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_excited", _("Excited"), mexcited);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("mood_anxious", _("Anxious"), manxious);
-+ gaim2_request_field_group_add_field(g, f);
-+
-+ f = gaim2_request_field_label_new("l4", _("\nYour Preferred Contact Methods"));
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("contact_chat", _("Chat"), cchat);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("contact_email", _("Email"), cemail);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("contact_call", _("Phone"), ccall);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("contact_sms", _("SMS"), csms);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("contact_mms", _("MMS"), cmms);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("contact_video", _("Video Conferencing"), cvideo);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("status_text", _("Your Current Status"),
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("status_text", _("Your Current Status"),
- status[0] ? status : NULL, TRUE);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
-- g = gaim_request_field_group_new(NULL);
-+ g = gaim2_request_field_group_new(NULL);
- #if 0
-- f = gaim_request_field_label_new("l2", _("Online Services"));
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_bool_new("services",
-+ f = gaim2_request_field_label_new("l2", _("Online Services"));
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_bool_new("services",
- _("Let others see what services you are using"),
- TRUE);
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_group_add_field(g, f);
- #endif
- #ifdef HAVE_SYS_UTSNAME_H
-- f = gaim_request_field_bool_new("device",
-+ f = gaim2_request_field_bool_new("device",
- _("Let others see what computer you are using"),
- device);
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_group_add_field(g, f);
- #endif
-- gaim_request_fields_add_group(fields, g);
-+ gaim2_request_fields_add_group(fields, g);
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("vcard", _("Your VCard File"),
-- gaim_account_get_string(sg->account, "vcard", ""),
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("vcard", _("Your VCard File"),
-+ gaim2_account_get_string(sg->account, "vcard", ""),
- FALSE);
-- gaim_request_field_group_add_field(g, f);
-+ gaim2_request_field_group_add_field(g, f);
- #ifdef _WIN32
-- f = gaim_request_field_string_new("timezone", _("Timezone"), _tzname[0], FALSE);
-+ f = gaim2_request_field_string_new("timezone", _("Timezone"), _tzname[0], FALSE);
- #else
-- f = gaim_request_field_string_new("timezone", _("Timezone"), tzname[0], FALSE);
-+ f = gaim2_request_field_string_new("timezone", _("Timezone"), tzname[0], FALSE);
- #endif
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
-- gaim_request_fields(gc, _("User Online Status Attributes"),
-+ gaim2_request_fields(gc, _("User Online Status Attributes"),
- _("User Online Status Attributes"),
- _("You can let other users see your online status information "
- "and your personal information. Please fill the information "
- "you would like other users to see about yourself."),
- fields,
-- _("OK"), G_CALLBACK(silcgaim_attrs_cb),
-- _("Cancel"), G_CALLBACK(silcgaim_attrs_cancel), gc);
-+ _("OK"), G_CALLBACK(silcgaim2_attrs_cb),
-+ _("Cancel"), G_CALLBACK(silcgaim2_attrs_cancel), gc);
- }
-
- static void
--silcgaim_detach(GaimPluginAction *action)
-+silcgaim2_detach(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- SilcGaim sg;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ SilcGaim2 sg;
-
- if (!gc)
- return;
-@@ -758,10 +758,10 @@ silcgaim_detach(GaimPluginAction *action
- }
-
- static void
--silcgaim_view_motd(GaimPluginAction *action)
-+silcgaim2_view_motd(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- SilcGaim sg;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ SilcGaim2 sg;
- char *tmp;
-
- if (!gc)
-@@ -771,29 +771,29 @@ silcgaim_view_motd(GaimPluginAction *act
- return;
-
- if (!sg->motd) {
-- gaim_notify_error(
-+ gaim2_notify_error(
- gc, _("Message of the Day"), _("No Message of the Day available"),
- _("There is no Message of the Day associated with this connection"));
- return;
- }
-
- tmp = g_markup_escape_text(sg->motd, -1);
-- gaim_notify_formatted(gc, NULL, _("Message of the Day"), NULL,
-+ gaim2_notify_formatted(gc, NULL, _("Message of the Day"), NULL,
- tmp, NULL, NULL);
- g_free(tmp);
- }
-
- static void
--silcgaim_create_keypair_cancel(GaimConnection *gc, GaimRequestFields *fields)
-+silcgaim2_create_keypair_cancel(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
- /* Nothing */
- }
-
- static void
--silcgaim_create_keypair_cb(GaimConnection *gc, GaimRequestFields *fields)
-+silcgaim2_create_keypair_cb(Gaim2Connection *gc, Gaim2RequestFields *fields)
- {
-- SilcGaim sg = gc->proto_data;
-- GaimRequestField *f;
-+ SilcGaim2 sg = gc->proto_data;
-+ Gaim2RequestField *f;
- const char *val, *pkfile = NULL, *prfile = NULL;
- const char *pass1 = NULL, *pass2 = NULL, *un = NULL, *hn = NULL;
- const char *rn = NULL, *e = NULL, *o = NULL, *c = NULL;
-@@ -806,59 +806,59 @@ silcgaim_create_keypair_cb(GaimConnectio
- return;
-
- val = NULL;
-- f = gaim_request_fields_get_field(fields, "pass1");
-+ f = gaim2_request_fields_get_field(fields, "pass1");
- if (f)
-- val = gaim_request_field_string_get_value(f);
-+ val = gaim2_request_field_string_get_value(f);
- if (val && *val)
- pass1 = val;
- else
- pass1 = "";
- val = NULL;
-- f = gaim_request_fields_get_field(fields, "pass2");
-+ f = gaim2_request_fields_get_field(fields, "pass2");
- if (f)
-- val = gaim_request_field_string_get_value(f);
-+ val = gaim2_request_field_string_get_value(f);
- if (val && *val)
- pass2 = val;
- else
- pass2 = "";
-
- if (strcmp(pass1, pass2)) {
-- gaim_notify_error(
-+ gaim2_notify_error(
- gc, _("Create New SILC Key Pair"), _("Passphrases do not match"), NULL);
- return;
- }
-
- val = NULL;
-- f = gaim_request_fields_get_field(fields, "key");
-+ f = gaim2_request_fields_get_field(fields, "key");
- if (f)
-- val = gaim_request_field_string_get_value(f);
-+ val = gaim2_request_field_string_get_value(f);
- if (val && *val)
- keylen = atoi(val);
-- f = gaim_request_fields_get_field(fields, "pkfile");
-+ f = gaim2_request_fields_get_field(fields, "pkfile");
- if (f)
-- pkfile = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "prfile");
-+ pkfile = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "prfile");
- if (f)
-- prfile = gaim_request_field_string_get_value(f);
-+ prfile = gaim2_request_field_string_get_value(f);
-
-- f = gaim_request_fields_get_field(fields, "un");
-+ f = gaim2_request_fields_get_field(fields, "un");
- if (f)
-- un = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "hn");
-+ un = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "hn");
- if (f)
-- hn = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "rn");
-+ hn = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "rn");
- if (f)
-- rn = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "e");
-+ rn = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "e");
- if (f)
-- e = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "o");
-+ e = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "o");
- if (f)
-- o = gaim_request_field_string_get_value(f);
-- f = gaim_request_fields_get_field(fields, "c");
-+ o = gaim2_request_field_string_get_value(f);
-+ f = gaim2_request_fields_get_field(fields, "c");
- if (f)
-- c = gaim_request_field_string_get_value(f);
-+ c = gaim2_request_field_string_get_value(f);
-
- identifier = silc_pkcs_encode_identifier((char *)un, (char *)hn,
- (char *)rn, (char *)e, (char *)o, (char *)c);
-@@ -867,147 +867,147 @@ silcgaim_create_keypair_cb(GaimConnectio
- if (!silc_create_key_pair(SILCGAIM_DEF_PKCS, keylen, pkfile, prfile,
- identifier, pass1, NULL, &public_key, NULL,
- FALSE)) {
-- gaim_notify_error(
-+ gaim2_notify_error(
- gc, _("Create New SILC Key Pair"), _("Key Pair Generation failed"), NULL);
- return;
- }
-
-- silcgaim_show_public_key(sg, NULL, public_key, NULL, NULL);
-+ silcgaim2_show_public_key(sg, NULL, public_key, NULL, NULL);
-
- silc_pkcs_public_key_free(public_key);
- silc_free(identifier);
- }
-
- static void
--silcgaim_create_keypair(GaimPluginAction *action)
-+silcgaim2_create_keypair(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- SilcGaim sg = gc->proto_data;
-- GaimRequestFields *fields;
-- GaimRequestFieldGroup *g;
-- GaimRequestField *f;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ SilcGaim2 sg = gc->proto_data;
-+ Gaim2RequestFields *fields;
-+ Gaim2RequestFieldGroup *g;
-+ Gaim2RequestField *f;
- const char *username, *realname;
- char *hostname, **u;
- char tmp[256], pkd[256], pkd2[256], prd[256], prd2[256];
-
-- username = gaim_account_get_username(sg->account);
-+ username = gaim2_account_get_username(sg->account);
- u = g_strsplit(username, "@", 2);
- username = u[0];
-- realname = gaim_account_get_user_info(sg->account);
-+ realname = gaim2_account_get_user_info(sg->account);
- hostname = silc_net_localhost();
- g_snprintf(tmp, sizeof(tmp), "%s@%s", username, hostname);
-
-- g_snprintf(pkd2, sizeof(pkd2), "%s" G_DIR_SEPARATOR_S"public_key.pub", silcgaim_silcdir());
-- g_snprintf(prd2, sizeof(prd2), "%s" G_DIR_SEPARATOR_S"private_key.prv", silcgaim_silcdir());
-+ g_snprintf(pkd2, sizeof(pkd2), "%s" G_DIR_SEPARATOR_S"public_key.pub", silcgaim2_silcdir());
-+ g_snprintf(prd2, sizeof(prd2), "%s" G_DIR_SEPARATOR_S"private_key.prv", silcgaim2_silcdir());
- g_snprintf(pkd, sizeof(pkd) - 1, "%s",
-- gaim_account_get_string(gc->account, "public-key", pkd2));
-+ gaim2_account_get_string(gc->account, "public-key", pkd2));
- g_snprintf(prd, sizeof(prd) - 1, "%s",
-- gaim_account_get_string(gc->account, "private-key", prd2));
-+ gaim2_account_get_string(gc->account, "private-key", prd2));
-
-- fields = gaim_request_fields_new();
-+ fields = gaim2_request_fields_new();
-
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("key", _("Key Length"), "2048", FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("pkfile", _("Public Key File"), pkd, FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("prfile", _("Private Key File"), prd, FALSE);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
--
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("un", _("Username"), username ? username : "", FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("hn", _("Hostname"), hostname ? hostname : "", FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("rn", _("Real Name"), realname ? realname : "", FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("e", _("Email"), tmp, FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("o", _("Organization"), "", FALSE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("c", _("Country"), "", FALSE);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
--
-- g = gaim_request_field_group_new(NULL);
-- f = gaim_request_field_string_new("pass1", _("Passphrase"), "", FALSE);
-- gaim_request_field_string_set_masked(f, TRUE);
-- gaim_request_field_group_add_field(g, f);
-- f = gaim_request_field_string_new("pass2", _("Re-type Passphrase"), "", FALSE);
-- gaim_request_field_string_set_masked(f, TRUE);
-- gaim_request_field_group_add_field(g, f);
-- gaim_request_fields_add_group(fields, g);
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("key", _("Key Length"), "2048", FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("pkfile", _("Public Key File"), pkd, FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("prfile", _("Private Key File"), prd, FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-+
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("un", _("Username"), username ? username : "", FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("hn", _("Hostname"), hostname ? hostname : "", FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("rn", _("Real Name"), realname ? realname : "", FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("e", _("Email"), tmp, FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("o", _("Organization"), "", FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("c", _("Country"), "", FALSE);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-+
-+ g = gaim2_request_field_group_new(NULL);
-+ f = gaim2_request_field_string_new("pass1", _("Passphrase"), "", FALSE);
-+ gaim2_request_field_string_set_masked(f, TRUE);
-+ gaim2_request_field_group_add_field(g, f);
-+ f = gaim2_request_field_string_new("pass2", _("Re-type Passphrase"), "", FALSE);
-+ gaim2_request_field_string_set_masked(f, TRUE);
-+ gaim2_request_field_group_add_field(g, f);
-+ gaim2_request_fields_add_group(fields, g);
-
-- gaim_request_fields(gc, _("Create New SILC Key Pair"),
-+ gaim2_request_fields(gc, _("Create New SILC Key Pair"),
- _("Create New SILC Key Pair"), NULL, fields,
-- _("Generate Key Pair"), G_CALLBACK(silcgaim_create_keypair_cb),
-- _("Cancel"), G_CALLBACK(silcgaim_create_keypair_cancel), gc);
-+ _("Generate Key Pair"), G_CALLBACK(silcgaim2_create_keypair_cb),
-+ _("Cancel"), G_CALLBACK(silcgaim2_create_keypair_cancel), gc);
-
- g_strfreev(u);
- silc_free(hostname);
- }
-
- static void
--silcgaim_change_pass(GaimPluginAction *action)
-+silcgaim2_change_pass(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_account_request_change_password(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_account_request_change_password(gaim2_connection_get_account(gc));
- }
-
- static void
--silcgaim_change_passwd(GaimConnection *gc, const char *old, const char *new)
-+silcgaim2_change_passwd(Gaim2Connection *gc, const char *old, const char *new)
- {
- char prd[256];
-- g_snprintf(prd, sizeof(prd), "%s" G_DIR_SEPARATOR_S "private_key.pub", silcgaim_silcdir());
-- silc_change_private_key_passphrase(gaim_account_get_string(gc->account,
-+ g_snprintf(prd, sizeof(prd), "%s" G_DIR_SEPARATOR_S "private_key.pub", silcgaim2_silcdir());
-+ silc_change_private_key_passphrase(gaim2_account_get_string(gc->account,
- "private-key",
- prd), old, new);
- }
-
- static void
--silcgaim_show_set_info(GaimPluginAction *action)
-+silcgaim2_show_set_info(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_account_request_change_user_info(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_account_request_change_user_info(gaim2_connection_get_account(gc));
- }
-
- static void
--silcgaim_set_info(GaimConnection *gc, const char *text)
-+silcgaim2_set_info(Gaim2Connection *gc, const char *text)
- {
- }
-
- static GList *
--silcgaim_actions(GaimPlugin *plugin, gpointer context)
-+silcgaim2_actions(Gaim2Plugin *plugin, gpointer context)
- {
-- GaimConnection *gc = context;
-+ Gaim2Connection *gc = context;
- GList *list = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- if (!gaim_account_get_bool(gc->account, "reject-attrs", FALSE)) {
-- act = gaim_plugin_action_new(_("Online Status"),
-- silcgaim_attrs);
-+ if (!gaim2_account_get_bool(gc->account, "reject-attrs", FALSE)) {
-+ act = gaim2_plugin_action_new(_("Online Status"),
-+ silcgaim2_attrs);
- list = g_list_append(list, act);
- }
-
-- act = gaim_plugin_action_new(_("Detach From Server"),
-- silcgaim_detach);
-+ act = gaim2_plugin_action_new(_("Detach From Server"),
-+ silcgaim2_detach);
- list = g_list_append(list, act);
-
-- act = gaim_plugin_action_new(_("View Message of the Day"),
-- silcgaim_view_motd);
-+ act = gaim2_plugin_action_new(_("View Message of the Day"),
-+ silcgaim2_view_motd);
- list = g_list_append(list, act);
-
-- act = gaim_plugin_action_new(_("Create SILC Key Pair..."),
-- silcgaim_create_keypair);
-+ act = gaim2_plugin_action_new(_("Create SILC Key Pair..."),
-+ silcgaim2_create_keypair);
- list = g_list_append(list, act);
-
-- act = gaim_plugin_action_new(_("Change Password..."),
-- silcgaim_change_pass);
-+ act = gaim2_plugin_action_new(_("Change Password..."),
-+ silcgaim2_change_pass);
- list = g_list_append(list, act);
-
-- act = gaim_plugin_action_new(_("Set User Info..."),
-- silcgaim_show_set_info);
-+ act = gaim2_plugin_action_new(_("Set User Info..."),
-+ silcgaim2_show_set_info);
- list = g_list_append(list, act);
-
- return list;
-@@ -1021,27 +1021,27 @@ typedef struct {
- char *message;
- SilcUInt32 message_len;
- SilcMessageFlags flags;
-- GaimMessageFlags gflags;
--} *SilcGaimIM;
-+ Gaim2MessageFlags gflags;
-+} *SilcGaim2IM;
-
- static void
--silcgaim_send_im_resolved(SilcClient client,
-+silcgaim2_send_im_resolved(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context)
- {
-- GaimConnection *gc = client->application;
-- SilcGaim sg = gc->proto_data;
-- SilcGaimIM im = context;
-- GaimConversation *convo;
-+ Gaim2Connection *gc = client->application;
-+ SilcGaim2 sg = gc->proto_data;
-+ SilcGaim2IM im = context;
-+ Gaim2Conversation *convo;
- char tmp[256], *nickname = NULL;
- SilcClientEntry client_entry;
- #ifdef HAVE_SILCMIME_H
- SilcDList list;
- #endif
-
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, im->nick,
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, im->nick,
- sg->account);
- if (!convo)
- return;
-@@ -1068,7 +1068,7 @@ silcgaim_send_im_resolved(SilcClient cli
- #ifdef HAVE_SILCMIME_H
- /* Check for images */
- if (im->gflags & GAIM_MESSAGE_IMAGES) {
-- list = silcgaim_image_message(im->message, (SilcUInt32 *)&im->flags);
-+ list = silcgaim2_image_message(im->message, (SilcUInt32 *)&im->flags);
- if (list) {
- /* Send one or more MIME message. If more than one, they
- are MIME fragments due to over large message */
-@@ -1081,7 +1081,7 @@ silcgaim_send_im_resolved(SilcClient cli
- buf->data, buf->len,
- TRUE);
- silc_mime_partial_free(list);
-- gaim_conv_im_write(GAIM_CONV_IM(convo), conn->local_entry->nickname,
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), conn->local_entry->nickname,
- im->message, 0, time(NULL));
- goto out;
- }
-@@ -1091,14 +1091,14 @@ silcgaim_send_im_resolved(SilcClient cli
- /* Send the message */
- silc_client_send_private_message(client, conn, client_entry, im->flags,
- (unsigned char *)im->message, im->message_len, TRUE);
-- gaim_conv_im_write(GAIM_CONV_IM(convo), conn->local_entry->nickname,
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), conn->local_entry->nickname,
- im->message, 0, time(NULL));
- goto out;
-
- err:
- g_snprintf(tmp, sizeof(tmp),
- _("User <I>%s</I> is not present in the network"), im->nick);
-- gaim_conversation_write(convo, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conversation_write(convo, NULL, tmp, GAIM_MESSAGE_SYSTEM, time(NULL));
-
- out:
- g_free(im->nick);
-@@ -1108,17 +1108,17 @@ silcgaim_send_im_resolved(SilcClient cli
- }
-
- static int
--silcgaim_send_im(GaimConnection *gc, const char *who, const char *message,
-- GaimMessageFlags flags)
-+silcgaim2_send_im(Gaim2Connection *gc, const char *who, const char *message,
-+ Gaim2MessageFlags flags)
- {
-- SilcGaim sg = gc->proto_data;
-+ SilcGaim2 sg = gc->proto_data;
- SilcClient client = sg->client;
- SilcClientConnection conn = sg->conn;
- SilcClientEntry *clients;
- SilcUInt32 clients_count, mflags;
- char *nickname, *msg, *tmp;
- int ret = 0;
-- gboolean sign = gaim_account_get_bool(sg->account, "sign-verify", FALSE);
-+ gboolean sign = gaim2_account_get_bool(sg->account, "sign-verify", FALSE);
- #ifdef HAVE_SILCMIME_H
- SilcDList list;
- #endif
-@@ -1128,7 +1128,7 @@ silcgaim_send_im(GaimConnection *gc, con
-
- mflags = SILC_MESSAGE_FLAG_UTF8;
-
-- tmp = msg = gaim_unescape_html(message);
-+ tmp = msg = gaim2_unescape_html(message);
-
- if (!g_ascii_strncasecmp(msg, "/me ", 4)) {
- msg += 4;
-@@ -1139,7 +1139,7 @@ silcgaim_send_im(GaimConnection *gc, con
- mflags |= SILC_MESSAGE_FLAG_ACTION;
- } else if (strlen(msg) > 1 && msg[0] == '/') {
- if (!silc_client_command_call(client, conn, msg + 1))
-- gaim_notify_error(gc, ("Call Command"), _("Cannot call command"),
-+ gaim2_notify_error(gc, ("Call Command"), _("Cannot call command"),
- _("Unknown command"));
- g_free(tmp);
- return 0;
-@@ -1159,7 +1159,7 @@ silcgaim_send_im(GaimConnection *gc, con
- &clients_count);
- if (!clients) {
- /* Resolve unknown user */
-- SilcGaimIM im = silc_calloc(1, sizeof(*im));
-+ SilcGaim2IM im = silc_calloc(1, sizeof(*im));
- if (!im) {
- g_free(tmp);
- return 0;
-@@ -1170,7 +1170,7 @@ silcgaim_send_im(GaimConnection *gc, con
- im->flags = mflags;
- im->gflags = flags;
- silc_client_get_clients(client, conn, nickname, NULL,
-- silcgaim_send_im_resolved, im);
-+ silcgaim2_send_im_resolved, im);
- silc_free(nickname);
- g_free(tmp);
- return 0;
-@@ -1179,7 +1179,7 @@ silcgaim_send_im(GaimConnection *gc, con
- #ifdef HAVE_SILCMIME_H
- /* Check for images */
- if (flags & GAIM_MESSAGE_IMAGES) {
-- list = silcgaim_image_message(message, &mflags);
-+ list = silcgaim2_image_message(message, &mflags);
- if (list) {
- /* Send one or more MIME message. If more than one, they
- are MIME fragments due to over large message */
-@@ -1214,14 +1214,14 @@ silcgaim_send_im(GaimConnection *gc, con
- }
-
-
--static GList *silcgaim_blist_node_menu(GaimBlistNode *node) {
-+static GList *silcgaim2_blist_node_menu(Gaim2BlistNode *node) {
- /* split this single menu building function back into the two
- original: one for buddies and one for chats */
-
- if(GAIM_BLIST_NODE_IS_CHAT(node)) {
-- return silcgaim_chat_menu((GaimChat *) node);
-+ return silcgaim2_chat_menu((Gaim2Chat *) node);
- } else if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- return silcgaim_buddy_menu((GaimBuddy *) node);
-+ return silcgaim2_buddy_menu((Gaim2Buddy *) node);
- } else {
- g_return_val_if_reached(NULL);
- }
-@@ -1229,60 +1229,60 @@ static GList *silcgaim_blist_node_menu(G
-
- /********************************* Commands **********************************/
-
--static GaimCmdRet silcgaim_cmd_chat_part(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_chat_part(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- GaimConversation *convo;
-+ Gaim2Connection *gc;
-+ Gaim2Conversation *convo;
- int id = 0;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-
- if(args && args[0]) {
-- convo = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0],
-+ convo = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, args[0],
- gc->account);
- } else
- convo = conv;
-
-- id = gaim_conv_chat_get_id(GAIM_CONV_CHAT(convo));
-+ id = gaim2_conv_chat_get_id(GAIM_CONV_CHAT(convo));
-
- if (id == 0)
- return GAIM_CMD_RET_FAILED;
-
-- silcgaim_chat_leave(gc, id);
-+ silcgaim2_chat_leave(gc, id);
-
- return GAIM_CMD_RET_OK;
-
- }
-
--static GaimCmdRet silcgaim_cmd_chat_topic(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_chat_topic(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- int id = 0;
- char *buf, *tmp, *tmp2;
- const char *topic;
-
-- gc = gaim_conversation_get_gc(conv);
-- id = gaim_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-+ gc = gaim2_conversation_get_gc(conv);
-+ id = gaim2_conv_chat_get_id(GAIM_CONV_CHAT(conv));
-
- if (gc == NULL || id == 0)
- return GAIM_CMD_RET_FAILED;
-
- if (!args || !args[0]) {
-- topic = gaim_conv_chat_get_topic (GAIM_CONV_CHAT(conv));
-+ topic = gaim2_conv_chat_get_topic (GAIM_CONV_CHAT(conv));
- if (topic) {
- tmp = g_markup_escape_text(topic, -1);
-- tmp2 = gaim_markup_linkify(tmp);
-+ tmp2 = gaim2_markup_linkify(tmp);
- buf = g_strdup_printf(_("current topic is: %s"), tmp2);
- g_free(tmp);
- g_free(tmp2);
- } else
- buf = g_strdup(_("No topic is set"));
-- gaim_conv_chat_write(GAIM_CONV_CHAT(conv), gc->account->username, buf,
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(conv), gc->account->username, buf,
- GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- g_free(buf);
-
-@@ -1293,12 +1293,12 @@ static GaimCmdRet silcgaim_cmd_chat_topi
- return GAIM_CMD_RET_FAILED;
- }
-
-- silcgaim_chat_set_topic(gc, id, args ? args[0] : NULL);
-+ silcgaim2_chat_set_topic(gc, id, args ? args[0] : NULL);
-
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_chat_join(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_chat_join(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- GHashTable *comp;
-@@ -1312,48 +1312,48 @@ static GaimCmdRet silcgaim_cmd_chat_join
- if(args[1])
- g_hash_table_replace(comp, "passphrase", args[1]);
-
-- silcgaim_chat_join(gaim_conversation_get_gc(conv), comp);
-+ silcgaim2_chat_join(gaim2_conversation_get_gc(conv), comp);
-
- g_hash_table_destroy(comp);
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_chat_list(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_chat_list(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- gc = gaim_conversation_get_gc(conv);
-- gaim_roomlist_show_with_account(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc;
-+ gc = gaim2_conversation_get_gc(conv);
-+ gaim2_roomlist_show_with_account(gaim2_connection_get_account(gc));
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_whois(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_whois(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-
-- silcgaim_get_info(gc, args[0]);
-+ silcgaim2_get_info(gc, args[0]);
-
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_msg(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_msg(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- int ret;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-
-- ret = silcgaim_send_im(gc, args[0], args[1], GAIM_MESSAGE_SEND);
-+ ret = silcgaim2_send_im(gc, args[0], args[1], GAIM_MESSAGE_SEND);
-
- if (ret)
- return GAIM_CMD_RET_OK;
-@@ -1361,31 +1361,31 @@ static GaimCmdRet silcgaim_cmd_msg(GaimC
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet silcgaim_cmd_query(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_query(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- int ret = 1;
-- GaimConversation *convo;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Conversation *convo;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
-
- if (!args || !args[0]) {
- *error = g_strdup(_("You must specify a nick"));
- return GAIM_CMD_RET_FAILED;
- }
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- convo = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, args[0]);
-+ convo = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, args[0]);
-
- if (args[1]) {
-- ret = silcgaim_send_im(gc, args[0], args[1], GAIM_MESSAGE_SEND);
-- gaim_conv_im_write(GAIM_CONV_IM(convo), gaim_connection_get_display_name(gc),
-+ ret = silcgaim2_send_im(gc, args[0], args[1], GAIM_MESSAGE_SEND);
-+ gaim2_conv_im_write(GAIM_CONV_IM(convo), gaim2_connection_get_display_name(gc),
- args[1], GAIM_MESSAGE_SEND, time(NULL));
- }
-
-@@ -1395,14 +1395,14 @@ static GaimCmdRet silcgaim_cmd_query(Gai
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet silcgaim_cmd_motd(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_motd(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
- char *tmp;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-@@ -1418,20 +1418,20 @@ static GaimCmdRet silcgaim_cmd_motd(Gaim
- }
-
- tmp = g_markup_escape_text(sg->motd, -1);
-- gaim_notify_formatted(gc, NULL, _("Message of the Day"), NULL,
-+ gaim2_notify_formatted(gc, NULL, _("Message of the Day"), NULL,
- tmp, NULL, NULL);
- g_free(tmp);
-
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_detach(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_detach(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-@@ -1447,16 +1447,16 @@ static GaimCmdRet silcgaim_cmd_detach(Ga
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_cmode(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_cmode(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
- SilcChannelEntry channel;
- char *silccmd, *silcargs, *msg, tmp[256];
- const char *chname;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL || !args || gc->proto_data == NULL)
- return GAIM_CMD_RET_FAILED;
-@@ -1466,7 +1466,7 @@ static GaimCmdRet silcgaim_cmd_cmode(Gai
- if (args[0])
- chname = args[0];
- else
-- chname = gaim_conversation_get_name(conv);
-+ chname = gaim2_conversation_get_name(conv);
-
- if (!args[1]) {
- channel = silc_client_get_channel(sg->client, sg->conn,
-@@ -1476,12 +1476,12 @@ static GaimCmdRet silcgaim_cmd_cmode(Gai
- return GAIM_CMD_RET_FAILED;
- }
- if (channel->mode) {
-- silcgaim_get_chmode_string(channel->mode, tmp, sizeof(tmp));
-+ silcgaim2_get_chmode_string(channel->mode, tmp, sizeof(tmp));
- msg = g_strdup_printf(_("channel modes for %s: %s"), chname, tmp);
- } else {
- msg = g_strdup_printf(_("no channel modes are set on %s"), chname);
- }
-- gaim_conv_chat_write(GAIM_CONV_CHAT(conv), "",
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(conv), "",
- msg, GAIM_MESSAGE_SYSTEM|GAIM_MESSAGE_NO_LOG, time(NULL));
- g_free(msg);
- return GAIM_CMD_RET_OK;
-@@ -1500,14 +1500,14 @@ static GaimCmdRet silcgaim_cmd_cmode(Gai
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_generic(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_generic(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
- char *silccmd, *silcargs;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-@@ -1522,7 +1522,7 @@ static GaimCmdRet silcgaim_cmd_generic(G
- g_free(silcargs);
- if (!silc_client_command_call(sg->client, sg->conn, silccmd)) {
- g_free(silccmd);
-- *error = g_strdup_printf(_("Unknown command: %s, (may be a Gaim bug)"), cmd);
-+ *error = g_strdup_printf(_("Unknown command: %s, (may be a Gaim2 bug)"), cmd);
- return GAIM_CMD_RET_FAILED;
- }
- g_free(silccmd);
-@@ -1530,13 +1530,13 @@ static GaimCmdRet silcgaim_cmd_generic(G
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_quit(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_quit(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-@@ -1547,18 +1547,18 @@ static GaimCmdRet silcgaim_cmd_quit(Gaim
- return GAIM_CMD_RET_FAILED;
-
- silc_client_command_call(sg->client, sg->conn, NULL,
-- "QUIT", (args && args[0]) ? args[0] : "Download Gaim: " GAIM_WEBSITE, NULL);
-+ "QUIT", (args && args[0]) ? args[0] : "Download Gaim2: " GAIM_WEBSITE, NULL);
-
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet silcgaim_cmd_call(GaimConversation *conv,
-+static Gaim2CmdRet silcgaim2_cmd_call(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
-
- if (gc == NULL)
- return GAIM_CMD_RET_FAILED;
-@@ -1580,140 +1580,140 @@ static GaimCmdRet silcgaim_cmd_call(Gaim
- /************************** Plugin Initialization ****************************/
-
- static void
--silcgaim_register_commands(void)
-+silcgaim2_register_commands(void)
- {
-- gaim_cmd_register("part", "w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("part", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT |
- GAIM_CMD_FLAG_PRPL_ONLY | GAIM_CMD_FLAG_ALLOW_WRONG_ARGS,
-- "prpl-silc", silcgaim_cmd_chat_part, _("part [channel]: Leave the chat"), NULL);
-- gaim_cmd_register("leave", "w", GAIM_CMD_P_PRPL,
-+ "prpl-silc", silcgaim2_cmd_chat_part, _("part [channel]: Leave the chat"), NULL);
-+ gaim2_cmd_register("leave", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT |
- GAIM_CMD_FLAG_PRPL_ONLY | GAIM_CMD_FLAG_ALLOW_WRONG_ARGS,
-- "prpl-silc", silcgaim_cmd_chat_part, _("leave [channel]: Leave the chat"), NULL);
-- gaim_cmd_register("topic", "s", GAIM_CMD_P_PRPL,
-+ "prpl-silc", silcgaim2_cmd_chat_part, _("leave [channel]: Leave the chat"), NULL);
-+ gaim2_cmd_register("topic", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc",
-- silcgaim_cmd_chat_topic, _("topic [&lt;new topic&gt;]: View or change the topic"), NULL);
-- gaim_cmd_register("join", "ws", GAIM_CMD_P_PRPL,
-+ silcgaim2_cmd_chat_topic, _("topic [&lt;new topic&gt;]: View or change the topic"), NULL);
-+ gaim2_cmd_register("join", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT |
- GAIM_CMD_FLAG_PRPL_ONLY | GAIM_CMD_FLAG_ALLOW_WRONG_ARGS,
-- "prpl-silc", silcgaim_cmd_chat_join,
-+ "prpl-silc", silcgaim2_cmd_chat_join,
- _("join &lt;channel&gt; [&lt;password&gt;]: Join a chat on this network"), NULL);
-- gaim_cmd_register("list", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("list", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc",
-- silcgaim_cmd_chat_list, _("list: List channels on this network"), NULL);
-- gaim_cmd_register("whois", "w", GAIM_CMD_P_PRPL,
-+ silcgaim2_cmd_chat_list, _("list: List channels on this network"), NULL);
-+ gaim2_cmd_register("whois", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-silc",
-- silcgaim_cmd_whois, _("whois &lt;nick&gt;: View nick's information"), NULL);
-- gaim_cmd_register("msg", "ws", GAIM_CMD_P_PRPL,
-+ silcgaim2_cmd_whois, _("whois &lt;nick&gt;: View nick's information"), NULL);
-+ gaim2_cmd_register("msg", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_msg,
-+ "prpl-silc", silcgaim2_cmd_msg,
- _("msg &lt;nick&gt; &lt;message&gt;: Send a private message to a user"), NULL);
-- gaim_cmd_register("query", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("query", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_query,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_query,
- _("query &lt;nick&gt; [&lt;message&gt;]: Send a private message to a user"), NULL);
-- gaim_cmd_register("motd", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("motd", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_motd,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_motd,
- _("motd: View the server's Message Of The Day"), NULL);
-- gaim_cmd_register("detach", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("detach", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_detach,
-+ "prpl-silc", silcgaim2_cmd_detach,
- _("detach: Detach this session"), NULL);
-- gaim_cmd_register("quit", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("quit", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_quit,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_quit,
- _("quit [message]: Disconnect from the server, with an optional message"), NULL);
-- gaim_cmd_register("call", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("call", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_call,
-+ "prpl-silc", silcgaim2_cmd_call,
- _("call &lt;command&gt;: Call any silc client command"), NULL);
- /* These below just get passed through for the silc client library to deal
- * with */
-- gaim_cmd_register("kill", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("kill", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("kill &lt;nick&gt; [-pubkey|&lt;reason&gt;]: Kill nick"), NULL);
-- gaim_cmd_register("nick", "w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("nick", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_generic,
-+ "prpl-silc", silcgaim2_cmd_generic,
- _("nick &lt;newnick&gt;: Change your nickname"), NULL);
-- gaim_cmd_register("whowas", "ww", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("whowas", "ww", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("whowas &lt;nick&gt;: View nick's information"), NULL);
-- gaim_cmd_register("cmode", "wws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("cmode", "wws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_cmode,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_cmode,
- _("cmode &lt;channel&gt; [+|-&lt;modes&gt;] [arguments]: Change or display channel modes"), NULL);
-- gaim_cmd_register("cumode", "wws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("cumode", "wws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("cumode &lt;channel&gt; +|-&lt;modes&gt; &lt;nick&gt;: Change nick's modes on channel"), NULL);
-- gaim_cmd_register("umode", "w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("umode", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_generic,
-+ "prpl-silc", silcgaim2_cmd_generic,
- _("umode &lt;usermodes&gt;: Set your modes in the network"), NULL);
-- gaim_cmd_register("oper", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("oper", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_generic,
-+ "prpl-silc", silcgaim2_cmd_generic,
- _("oper &lt;nick&gt; [-pubkey]: Get server operator privileges"), NULL);
-- gaim_cmd_register("invite", "ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("invite", "ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("invite &lt;channel&gt; [-|+]&lt;nick&gt;: invite nick or add/remove from channel invite list"), NULL);
-- gaim_cmd_register("kick", "wws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("kick", "wws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("kick &lt;channel&gt; &lt;nick&gt; [comment]: Kick client from channel"), NULL);
-- gaim_cmd_register("info", "w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("info", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("info [server]: View server administrative details"), NULL);
-- gaim_cmd_register("ban", "ww", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("ban", "ww", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_generic,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_generic,
- _("ban [&lt;channel&gt; +|-&lt;nick&gt;]: Ban client from channel"), NULL);
-- gaim_cmd_register("getkey", "w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("getkey", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_generic,
-+ "prpl-silc", silcgaim2_cmd_generic,
- _("getkey &lt;nick|server&gt;: Retrieve client's or server's public key"), NULL);
-- gaim_cmd_register("stats", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("stats", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_generic,
-+ "prpl-silc", silcgaim2_cmd_generic,
- _("stats: View server and network statistics"), NULL);
-- gaim_cmd_register("ping", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("ping", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_generic,
-+ "prpl-silc", silcgaim2_cmd_generic,
- _("ping: Send PING to the connected server"), NULL);
--#if 0 /* Gaim doesn't handle these yet */
-- gaim_cmd_register("users", "w", GAIM_CMD_P_PRPL,
-+#if 0 /* Gaim2 doesn't handle these yet */
-+ gaim2_cmd_register("users", "w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-silc", silcgaim_cmd_users,
-+ "prpl-silc", silcgaim2_cmd_users,
- _("users &lt;channel&gt;: List users in channel"));
-- gaim_cmd_register("names", "ww", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("names", "ww", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY |
-- GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim_cmd_names,
-+ GAIM_CMD_FLAG_ALLOW_WRONG_ARGS, "prpl-silc", silcgaim2_cmd_names,
- _("names [-count|-ops|-halfops|-voices|-normal] &lt;channel(s)&gt;: List specific users in channel(s)"));
- #endif
- }
-
--static GaimWhiteboardPrplOps silcgaim_wb_ops =
-+static Gaim2WhiteboardPrplOps silcgaim2_wb_ops =
- {
-- silcgaim_wb_start,
-- silcgaim_wb_end,
-- silcgaim_wb_get_dimensions,
-- silcgaim_wb_set_dimensions,
-- silcgaim_wb_get_brush,
-- silcgaim_wb_set_brush,
-- silcgaim_wb_send,
-- silcgaim_wb_clear,
-+ silcgaim2_wb_start,
-+ silcgaim2_wb_end,
-+ silcgaim2_wb_get_dimensions,
-+ silcgaim2_wb_set_dimensions,
-+ silcgaim2_wb_get_brush,
-+ silcgaim2_wb_set_brush,
-+ silcgaim2_wb_send,
-+ silcgaim2_wb_clear,
- };
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- #ifdef HAVE_SILCMIME_H
- OPT_PROTO_CHAT_TOPIC | OPT_PROTO_UNIQUE_CHATNAME |
-@@ -1725,40 +1725,40 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* user_splits */
- NULL, /* protocol_options */
- NO_BUDDY_ICONS, /* icon_spec */
-- silcgaim_list_icon, /* list_icon */
-- silcgaim_list_emblems, /* list_emblems */
-- silcgaim_status_text, /* status_text */
-- silcgaim_tooltip_text, /* tooltip_text */
-- silcgaim_away_states, /* away_states */
-- silcgaim_blist_node_menu, /* blist_node_menu */
-- silcgaim_chat_info, /* chat_info */
-- silcgaim_chat_info_defaults,/* chat_info_defaults */
-- silcgaim_login, /* login */
-- silcgaim_close, /* close */
-- silcgaim_send_im, /* send_im */
-- silcgaim_set_info, /* set_info */
-+ silcgaim2_list_icon, /* list_icon */
-+ silcgaim2_list_emblems, /* list_emblems */
-+ silcgaim2_status_text, /* status_text */
-+ silcgaim2_tooltip_text, /* tooltip_text */
-+ silcgaim2_away_states, /* away_states */
-+ silcgaim2_blist_node_menu, /* blist_node_menu */
-+ silcgaim2_chat_info, /* chat_info */
-+ silcgaim2_chat_info_defaults,/* chat_info_defaults */
-+ silcgaim2_login, /* login */
-+ silcgaim2_close, /* close */
-+ silcgaim2_send_im, /* send_im */
-+ silcgaim2_set_info, /* set_info */
- NULL, /* send_typing */
-- silcgaim_get_info, /* get_info */
-- silcgaim_set_status, /* set_status */
-- silcgaim_idle_set, /* set_idle */
-- silcgaim_change_passwd, /* change_passwd */
-- silcgaim_add_buddy, /* add_buddy */
-+ silcgaim2_get_info, /* get_info */
-+ silcgaim2_set_status, /* set_status */
-+ silcgaim2_idle_set, /* set_idle */
-+ silcgaim2_change_passwd, /* change_passwd */
-+ silcgaim2_add_buddy, /* add_buddy */
- NULL, /* add_buddies */
-- silcgaim_remove_buddy, /* remove_buddy */
-+ silcgaim2_remove_buddy, /* remove_buddy */
- NULL, /* remove_buddies */
- NULL, /* add_permit */
- NULL, /* add_deny */
- NULL, /* rem_permit */
- NULL, /* rem_deny */
- NULL, /* set_permit_deny */
-- silcgaim_chat_join, /* join_chat */
-+ silcgaim2_chat_join, /* join_chat */
- NULL, /* reject_chat */
-- silcgaim_get_chat_name, /* get_chat_name */
-- silcgaim_chat_invite, /* chat_invite */
-- silcgaim_chat_leave, /* chat_leave */
-+ silcgaim2_get_chat_name, /* get_chat_name */
-+ silcgaim2_chat_invite, /* chat_invite */
-+ silcgaim2_chat_leave, /* chat_leave */
- NULL, /* chat_whisper */
-- silcgaim_chat_send, /* chat_send */
-- silcgaim_keepalive, /* keepalive */
-+ silcgaim2_chat_send, /* chat_send */
-+ silcgaim2_keepalive, /* keepalive */
- NULL, /* register_user */
- NULL, /* get_cb_info */
- NULL, /* get_cb_away */
-@@ -1771,20 +1771,20 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* set_buddy_icon */
- NULL, /* remove_group */
- NULL, /* get_cb_real_name */
-- silcgaim_chat_set_topic, /* set_chat_topic */
-+ silcgaim2_chat_set_topic, /* set_chat_topic */
- NULL, /* find_blist_chat */
-- silcgaim_roomlist_get_list, /* roomlist_get_list */
-- silcgaim_roomlist_cancel, /* roomlist_cancel */
-+ silcgaim2_roomlist_get_list, /* roomlist_get_list */
-+ silcgaim2_roomlist_cancel, /* roomlist_cancel */
- NULL, /* roomlist_expand_category */
- NULL, /* can_receive_file */
-- silcgaim_ftp_send_file, /* send_file */
-- silcgaim_ftp_new_xfer, /* new_xfer */
-+ silcgaim2_ftp_send_file, /* send_file */
-+ silcgaim2_ftp_new_xfer, /* new_xfer */
- NULL, /* offline_message */
-- &silcgaim_wb_ops, /* whiteboard_prpl_ops */
-+ &silcgaim2_wb_ops, /* whiteboard_prpl_ops */
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -1812,37 +1812,37 @@ static GaimPluginInfo info =
- NULL, /**< ui_info */
- &prpl_info, /**< extra_info */
- NULL, /**< prefs_info */
-- silcgaim_actions
-+ silcgaim2_actions
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-- GaimAccountUserSplit *split;
-+ Gaim2AccountOption *option;
-+ Gaim2AccountUserSplit *split;
- char tmp[256];
- int i;
-- GaimKeyValuePair *kvp;
-+ Gaim2KeyValuePair *kvp;
- GList *list = NULL;
-
- silc_plugin = plugin;
-
-- split = gaim_account_user_split_new(_("Network"), "silcnet.org", '@');
-+ split = gaim2_account_user_split_new(_("Network"), "silcnet.org", '@');
- prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-
- /* Account options */
-- option = gaim_account_option_string_new(_("Connect server"),
-+ option = gaim2_account_option_string_new(_("Connect server"),
- "server",
- "silc.silcnet.org");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_int_new(_("Port"), "port", 706);
-+ option = gaim2_account_option_int_new(_("Port"), "port", 706);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- g_snprintf(tmp, sizeof(tmp), "%s" G_DIR_SEPARATOR_S "public_key.pub", silcgaim_silcdir());
-- option = gaim_account_option_string_new(_("Public Key file"),
-+ g_snprintf(tmp, sizeof(tmp), "%s" G_DIR_SEPARATOR_S "public_key.pub", silcgaim2_silcdir());
-+ option = gaim2_account_option_string_new(_("Public Key file"),
- "public-key", tmp);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- g_snprintf(tmp, sizeof(tmp), "%s" G_DIR_SEPARATOR_S "private_key.prv", silcgaim_silcdir());
-- option = gaim_account_option_string_new(_("Private Key file"),
-+ g_snprintf(tmp, sizeof(tmp), "%s" G_DIR_SEPARATOR_S "private_key.prv", silcgaim2_silcdir());
-+ option = gaim2_account_option_string_new(_("Private Key file"),
- "private-key", tmp);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-@@ -1852,7 +1852,7 @@ init_plugin(GaimPlugin *plugin)
- kvp->value = strdup(silc_default_ciphers[i].name);
- list = g_list_append(list, kvp);
- }
-- option = gaim_account_option_list_new(_("Cipher"), "cipher", list);
-+ option = gaim2_account_option_list_new(_("Cipher"), "cipher", list);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
- list = NULL;
-@@ -1862,37 +1862,37 @@ init_plugin(GaimPlugin *plugin)
- kvp->value = strdup(silc_default_hmacs[i].name);
- list = g_list_append(list, kvp);
- }
-- option = gaim_account_option_list_new(_("HMAC"), "hmac", list);
-+ option = gaim2_account_option_list_new(_("HMAC"), "hmac", list);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_bool_new(_("Public key authentication"),
-+ option = gaim2_account_option_bool_new(_("Public key authentication"),
- "pubkey-auth", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Reject watching by other users"),
-+ option = gaim2_account_option_bool_new(_("Reject watching by other users"),
- "reject-watch", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Block invites"),
-+ option = gaim2_account_option_bool_new(_("Block invites"),
- "block-invites", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Block IMs without Key Exchange"),
-+ option = gaim2_account_option_bool_new(_("Block IMs without Key Exchange"),
- "block-ims", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Reject online status attribute requests"),
-+ option = gaim2_account_option_bool_new(_("Reject online status attribute requests"),
- "reject-attrs", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Block messages to whiteboard"),
-+ option = gaim2_account_option_bool_new(_("Block messages to whiteboard"),
- "block-wb", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Automatically open whiteboard"),
-+ option = gaim2_account_option_bool_new(_("Automatically open whiteboard"),
- "open-wb", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Digitally sign and verify all messages"),
-+ option = gaim2_account_option_bool_new(_("Digitally sign and verify all messages"),
- "sign-verify", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- gaim_prefs_remove("/plugins/prpl/silc");
-+ gaim2_prefs_remove("/plugins/prpl/silc");
-
-- silcgaim_register_commands();
-+ silcgaim2_register_commands();
-
- #ifdef _WIN32
- silc_net_win32_init();
-diff -prNu ./src/protocols/silc/silcgaim.h ./src/protocols/silc/silcgaim.h
---- ./src/protocols/silc/silcgaim.h 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/silc/silcgaim.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim.h
-+ silcgaim2.h
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -20,7 +20,7 @@
- #ifndef SILCGAIM_H
- #define SILCGAIM_H
-
--/* Gaim includes */
-+/* Gaim2 includes */
- #include "internal.h"
- #include "account.h"
- #include "accountopt.h"
-@@ -60,21 +60,21 @@ typedef struct {
- unsigned long chid;
- const char *parentch;
- SilcChannelPrivateKey key;
--} *SilcGaimPrvgrp;
-+} *SilcGaim2Prvgrp;
-
--/* The SILC Gaim plugin context */
--typedef struct SilcGaimStruct {
-+/* The SILC Gaim2 plugin context */
-+typedef struct SilcGaim2Struct {
- SilcClient client;
- SilcClientConnection conn;
-
- guint scheduler;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- unsigned long channel_ids;
- GList *grps;
-
- char *motd;
-- GaimRoomlist *roomlist;
-+ Gaim2Roomlist *roomlist;
- #ifdef HAVE_SILCMIME_H
- SilcMimeAssembler mimeass;
- #endif
-@@ -82,71 +82,71 @@ typedef struct SilcGaimStruct {
- unsigned int resuming : 1;
- unsigned int roomlist_canceled : 1;
- unsigned int chpk : 1;
--} *SilcGaim;
-+} *SilcGaim2;
-
-
--gboolean silcgaim_check_silc_dir(GaimConnection *gc);
--void silcgaim_chat_join_done(SilcClient client,
-+gboolean silcgaim2_check_silc_dir(Gaim2Connection *gc);
-+void silcgaim2_chat_join_done(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry *clients,
- SilcUInt32 clients_count,
- void *context);
--const char *silcgaim_silcdir(void);
--const char *silcgaim_session_file(const char *account);
--void silcgaim_verify_public_key(SilcClient client, SilcClientConnection conn,
-+const char *silcgaim2_silcdir(void);
-+const char *silcgaim2_session_file(const char *account);
-+void silcgaim2_verify_public_key(SilcClient client, SilcClientConnection conn,
- const char *name, SilcSocketType conn_type,
- unsigned char *pk, SilcUInt32 pk_len,
- SilcSKEPKType pk_type,
- SilcVerifyPublicKey completion, void *context);
--GList *silcgaim_buddy_menu(GaimBuddy *buddy);
--void silcgaim_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group);
--void silcgaim_send_buddylist(GaimConnection *gc);
--void silcgaim_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group);
--void silcgaim_buddy_keyagr_request(SilcClient client,
-+GList *silcgaim2_buddy_menu(Gaim2Buddy *buddy);
-+void silcgaim2_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group);
-+void silcgaim2_send_buddylist(Gaim2Connection *gc);
-+void silcgaim2_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group);
-+void silcgaim2_buddy_keyagr_request(SilcClient client,
- SilcClientConnection conn,
- SilcClientEntry client_entry,
- const char *hostname, SilcUInt16 port);
--void silcgaim_idle_set(GaimConnection *gc, int idle);
--char *silcgaim_tooltip_text(GaimBuddy *b);
--char *silcgaim_status_text(GaimBuddy *b);
--gboolean silcgaim_ip_is_private(const char *ip);
--void silcgaim_ftp_send_file(GaimConnection *gc, const char *name, const char *file);
--GaimXfer *silcgaim_ftp_new_xfer(GaimConnection *gc, const char *name);
--void silcgaim_ftp_request(SilcClient client, SilcClientConnection conn,
-+void silcgaim2_idle_set(Gaim2Connection *gc, int idle);
-+char *silcgaim2_tooltip_text(Gaim2Buddy *b);
-+char *silcgaim2_status_text(Gaim2Buddy *b);
-+gboolean silcgaim2_ip_is_private(const char *ip);
-+void silcgaim2_ftp_send_file(Gaim2Connection *gc, const char *name, const char *file);
-+Gaim2Xfer *silcgaim2_ftp_new_xfer(Gaim2Connection *gc, const char *name);
-+void silcgaim2_ftp_request(SilcClient client, SilcClientConnection conn,
- SilcClientEntry client_entry, SilcUInt32 session_id,
- const char *hostname, SilcUInt16 port);
--void silcgaim_show_public_key(SilcGaim sg,
-+void silcgaim2_show_public_key(SilcGaim2 sg,
- const char *name, SilcPublicKey public_key,
- GCallback callback, void *context);
--void silcgaim_get_info(GaimConnection *gc, const char *who);
-+void silcgaim2_get_info(Gaim2Connection *gc, const char *who);
- SilcAttributePayload
--silcgaim_get_attr(SilcDList attrs, SilcAttribute attribute);
--void silcgaim_get_umode_string(SilcUInt32 mode, char *buf,
-+silcgaim2_get_attr(SilcDList attrs, SilcAttribute attribute);
-+void silcgaim2_get_umode_string(SilcUInt32 mode, char *buf,
- SilcUInt32 buf_size);
--void silcgaim_get_chmode_string(SilcUInt32 mode, char *buf,
-+void silcgaim2_get_chmode_string(SilcUInt32 mode, char *buf,
- SilcUInt32 buf_size);
--void silcgaim_get_chumode_string(SilcUInt32 mode, char *buf,
-+void silcgaim2_get_chumode_string(SilcUInt32 mode, char *buf,
- SilcUInt32 buf_size);
--GList *silcgaim_chat_info(GaimConnection *gc);
--GHashTable *silcgaim_chat_info_defaults(GaimConnection *gc, const char *chat_name);
--GList *silcgaim_chat_menu(GaimChat *);
--void silcgaim_chat_join(GaimConnection *gc, GHashTable *data);
--char *silcgaim_get_chat_name(GHashTable *data);
--void silcgaim_chat_invite(GaimConnection *gc, int id, const char *msg,
-+GList *silcgaim2_chat_info(Gaim2Connection *gc);
-+GHashTable *silcgaim2_chat_info_defaults(Gaim2Connection *gc, const char *chat_name);
-+GList *silcgaim2_chat_menu(Gaim2Chat *);
-+void silcgaim2_chat_join(Gaim2Connection *gc, GHashTable *data);
-+char *silcgaim2_get_chat_name(GHashTable *data);
-+void silcgaim2_chat_invite(Gaim2Connection *gc, int id, const char *msg,
- const char *name);
--void silcgaim_chat_leave(GaimConnection *gc, int id);
--int silcgaim_chat_send(GaimConnection *gc, int id, const char *msg, GaimMessageFlags flags);
--void silcgaim_chat_set_topic(GaimConnection *gc, int id, const char *topic);
--GaimRoomlist *silcgaim_roomlist_get_list(GaimConnection *gc);
--void silcgaim_roomlist_cancel(GaimRoomlist *list);
--void silcgaim_chat_chauth_show(SilcGaim sg, SilcChannelEntry channel,
-+void silcgaim2_chat_leave(Gaim2Connection *gc, int id);
-+int silcgaim2_chat_send(Gaim2Connection *gc, int id, const char *msg, Gaim2MessageFlags flags);
-+void silcgaim2_chat_set_topic(Gaim2Connection *gc, int id, const char *topic);
-+Gaim2Roomlist *silcgaim2_roomlist_get_list(Gaim2Connection *gc);
-+void silcgaim2_roomlist_cancel(Gaim2Roomlist *list);
-+void silcgaim2_chat_chauth_show(SilcGaim2 sg, SilcChannelEntry channel,
- SilcBuffer channel_pubkeys);
--void silcgaim_parse_attrs(SilcDList attrs, char **moodstr, char **statusstr,
-+void silcgaim2_parse_attrs(SilcDList attrs, char **moodstr, char **statusstr,
- char **contactstr, char **langstr, char **devicestr,
- char **tzstr, char **geostr);
- #ifdef HAVE_SILCMIME_H
--char *silcgaim_file2mime(const char *filename);
--SilcDList silcgaim_image_message(const char *msg, SilcUInt32 *mflags);
-+char *silcgaim2_file2mime(const char *filename);
-+SilcDList silcgaim2_image_message(const char *msg, SilcUInt32 *mflags);
- #endif
-
- #ifdef _WIN32
-diff -prNu ./src/protocols/silc/util.c ./src/protocols/silc/util.c
---- ./src/protocols/silc/util.c 2005-11-24 22:07:12.000000000 +0100
-+++ ./src/protocols/silc/util.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim_util.c
-+ silcgaim2_util.c
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -19,30 +19,30 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "imgstore.h"
-
- /**************************** Utility Routines *******************************/
-
- static char str[256], str2[256];
-
--const char *silcgaim_silcdir(void)
-+const char *silcgaim2_silcdir(void)
- {
-- const char *hd = gaim_home_dir();
-+ const char *hd = gaim2_home_dir();
- memset(str, 0, sizeof(str));
- g_snprintf(str, sizeof(str) - 1, "%s" G_DIR_SEPARATOR_S ".silc", hd ? hd : "/tmp");
- return (const char *)str;
- }
-
--const char *silcgaim_session_file(const char *account)
-+const char *silcgaim2_session_file(const char *account)
- {
- memset(str2, 0, sizeof(str2));
- g_snprintf(str2, sizeof(str2) - 1, "%s" G_DIR_SEPARATOR_S "%s_session",
-- silcgaim_silcdir(), account);
-+ silcgaim2_silcdir(), account);
- return (const char *)str2;
- }
-
--gboolean silcgaim_ip_is_private(const char *ip)
-+gboolean silcgaim2_ip_is_private(const char *ip)
- {
- if (silc_net_is_ip4(ip)) {
- if (!strncmp(ip, "10.", 3)) {
-@@ -68,7 +68,7 @@ gboolean silcgaim_ip_is_private(const ch
- it doesn't exist, it will create the directory. After that it checks if
- user's Public and Private key files exists and creates them if needed. */
-
--gboolean silcgaim_check_silc_dir(GaimConnection *gc)
-+gboolean silcgaim2_check_silc_dir(Gaim2Connection *gc)
- {
- char filename[256], file_public_key[256], file_private_key[256];
- char servfilename[256], clientfilename[256], friendsfilename[256];
-@@ -78,17 +78,17 @@ gboolean silcgaim_check_silc_dir(GaimCon
-
- pw = getpwuid(getuid());
- if (!pw) {
-- gaim_debug_error("silc", "silc: %s\n", strerror(errno));
-+ gaim2_debug_error("silc", "silc: %s\n", strerror(errno));
- return FALSE;
- }
-
-- g_snprintf(filename, sizeof(filename) - 1, "%s", silcgaim_silcdir());
-+ g_snprintf(filename, sizeof(filename) - 1, "%s", silcgaim2_silcdir());
- g_snprintf(servfilename, sizeof(servfilename) - 1, "%s" G_DIR_SEPARATOR_S "serverkeys",
-- silcgaim_silcdir());
-+ silcgaim2_silcdir());
- g_snprintf(clientfilename, sizeof(clientfilename) - 1, "%s" G_DIR_SEPARATOR_S "clientkeys",
-- silcgaim_silcdir());
-+ silcgaim2_silcdir());
- g_snprintf(friendsfilename, sizeof(friendsfilename) - 1, "%s" G_DIR_SEPARATOR_S "friends",
-- silcgaim_silcdir());
-+ silcgaim2_silcdir());
-
- /*
- * Check ~/.silc directory
-@@ -98,23 +98,23 @@ gboolean silcgaim_check_silc_dir(GaimCon
- if (errno == ENOENT) {
- if (pw->pw_uid == geteuid()) {
- if ((g_mkdir(filename, 0755)) == -1) {
-- gaim_debug_error("silc", "Couldn't create '%s' directory\n", filename);
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory\n", filename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
- filename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n", filename, strerror(errno));
-+ gaim2_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n", filename, strerror(errno));
- return FALSE;
- }
- } else {
- #ifndef _WIN32
- /* Check the owner of the dir */
- if (st.st_uid != 0 && st.st_uid != pw->pw_uid) {
-- gaim_debug_error("silc", "You don't seem to own '%s' directory\n",
-+ gaim2_debug_error("silc", "You don't seem to own '%s' directory\n",
- filename);
- return FALSE;
- }
-@@ -129,16 +129,16 @@ gboolean silcgaim_check_silc_dir(GaimCon
- if (errno == ENOENT) {
- if (pw->pw_uid == geteuid()) {
- if ((g_mkdir(servfilename, 0755)) == -1) {
-- gaim_debug_error("silc", "Couldn't create '%s' directory\n", servfilename);
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory\n", servfilename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
- servfilename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n",
-+ gaim2_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n",
- servfilename, strerror(errno));
- return FALSE;
- }
-@@ -152,16 +152,16 @@ gboolean silcgaim_check_silc_dir(GaimCon
- if (errno == ENOENT) {
- if (pw->pw_uid == geteuid()) {
- if ((g_mkdir(clientfilename, 0755)) == -1) {
-- gaim_debug_error("silc", "Couldn't create '%s' directory\n", clientfilename);
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory\n", clientfilename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
- clientfilename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n",
-+ gaim2_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n",
- clientfilename, strerror(errno));
- return FALSE;
- }
-@@ -175,16 +175,16 @@ gboolean silcgaim_check_silc_dir(GaimCon
- if (errno == ENOENT) {
- if (pw->pw_uid == geteuid()) {
- if ((g_mkdir(friendsfilename, 0755)) == -1) {
-- gaim_debug_error("silc", "Couldn't create '%s' directory\n", friendsfilename);
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory\n", friendsfilename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
-+ gaim2_debug_error("silc", "Couldn't create '%s' directory due to a wrong uid!\n",
- friendsfilename);
- return FALSE;
- }
- } else {
-- gaim_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n",
-+ gaim2_debug_error("silc", "Couldn't stat '%s' directory, error: %s\n",
- friendsfilename, strerror(errno));
- return FALSE;
- }
-@@ -193,17 +193,17 @@ gboolean silcgaim_check_silc_dir(GaimCon
- /*
- * Check Public and Private keys
- */
-- g_snprintf(pkd, sizeof(pkd), "%s" G_DIR_SEPARATOR_S "public_key.pub", silcgaim_silcdir());
-- g_snprintf(prd, sizeof(prd), "%s" G_DIR_SEPARATOR_S "private_key.prv", silcgaim_silcdir());
-+ g_snprintf(pkd, sizeof(pkd), "%s" G_DIR_SEPARATOR_S "public_key.pub", silcgaim2_silcdir());
-+ g_snprintf(prd, sizeof(prd), "%s" G_DIR_SEPARATOR_S "private_key.prv", silcgaim2_silcdir());
- g_snprintf(file_public_key, sizeof(file_public_key) - 1, "%s",
-- gaim_account_get_string(gc->account, "public-key", pkd));
-+ gaim2_account_get_string(gc->account, "public-key", pkd));
- g_snprintf(file_private_key, sizeof(file_public_key) - 1, "%s",
-- gaim_account_get_string(gc->account, "private-key", prd));
-+ gaim2_account_get_string(gc->account, "private-key", prd));
-
- if ((g_stat(file_public_key, &st)) == -1) {
- /* If file doesn't exist */
- if (errno == ENOENT) {
-- gaim_connection_update_progress(gc, _("Creating SILC key pair..."), 1, 5);
-+ gaim2_connection_update_progress(gc, _("Creating SILC key pair..."), 1, 5);
- silc_create_key_pair(SILCGAIM_DEF_PKCS,
- SILCGAIM_DEF_PKCS_LEN,
- file_public_key, file_private_key, NULL,
-@@ -211,7 +211,7 @@ gboolean silcgaim_check_silc_dir(GaimCon
- NULL, NULL, NULL, FALSE);
- g_stat(file_public_key, &st);
- } else {
-- gaim_debug_error("silc", "Couldn't stat '%s' public key, error: %s\n",
-+ gaim2_debug_error("silc", "Couldn't stat '%s' public key, error: %s\n",
- file_public_key, strerror(errno));
- return FALSE;
- }
-@@ -220,7 +220,7 @@ gboolean silcgaim_check_silc_dir(GaimCon
- #ifndef _WIN32
- /* Check the owner of the public key */
- if (st.st_uid != 0 && st.st_uid != pw->pw_uid) {
-- gaim_debug_error("silc", "You don't seem to own your public key!?\n");
-+ gaim2_debug_error("silc", "You don't seem to own your public key!?\n");
- return FALSE;
- }
- #endif
-@@ -228,7 +228,7 @@ gboolean silcgaim_check_silc_dir(GaimCon
- if ((g_stat(file_private_key, &st)) == -1) {
- /* If file doesn't exist */
- if (errno == ENOENT) {
-- gaim_connection_update_progress(gc, _("Creating SILC key pair..."), 1, 5);
-+ gaim2_connection_update_progress(gc, _("Creating SILC key pair..."), 1, 5);
- silc_create_key_pair(SILCGAIM_DEF_PKCS,
- SILCGAIM_DEF_PKCS_LEN,
- file_public_key, file_private_key, NULL,
-@@ -236,7 +236,7 @@ gboolean silcgaim_check_silc_dir(GaimCon
- NULL, NULL, NULL, FALSE);
- g_stat(file_private_key, &st);
- } else {
-- gaim_debug_error("silc", "Couldn't stat '%s' private key, error: %s\n",
-+ gaim2_debug_error("silc", "Couldn't stat '%s' private key, error: %s\n",
- file_private_key, strerror(errno));
- return FALSE;
- }
-@@ -245,21 +245,21 @@ gboolean silcgaim_check_silc_dir(GaimCon
- #ifndef _WIN32
- /* Check the owner of the private key */
- if (st.st_uid != 0 && st.st_uid != pw->pw_uid) {
-- gaim_debug_error("silc", "You don't seem to own your private key!?\n");
-+ gaim2_debug_error("silc", "You don't seem to own your private key!?\n");
- return FALSE;
- }
-
- /* Check the permissions for the private key */
- if ((st.st_mode & 0777) != 0600) {
-- gaim_debug_warning("silc", "Wrong permissions in your private key file `%s'!\n"
-+ gaim2_debug_warning("silc", "Wrong permissions in your private key file `%s'!\n"
- "Trying to change them ... ", file_private_key);
- if ((chmod(file_private_key, 0600)) == -1) {
-- gaim_debug_error("silc",
-+ gaim2_debug_error("silc",
- "Failed to change permissions for private key file!\n"
- "Permissions for your private key file must be 0600.\n");
- return FALSE;
- }
-- gaim_debug_warning("silc", "Done.\n\n");
-+ gaim2_debug_warning("silc", "Done.\n\n");
- }
- #endif
-
-@@ -281,7 +281,7 @@ uid_t geteuid() {
- }
- #endif
-
--void silcgaim_show_public_key(SilcGaim sg,
-+void silcgaim2_show_public_key(SilcGaim2 sg,
- const char *name, SilcPublicKey public_key,
- GCallback callback, void *context)
- {
-@@ -330,7 +330,7 @@ void silcgaim_show_public_key(SilcGaim s
-
- buf = g_string_free(s, FALSE);
-
-- gaim_request_action(sg->gc, _("Public Key Information"),
-+ gaim2_request_action(sg->gc, _("Public Key Information"),
- _("Public Key Information"),
- buf, 0, context, 1,
- _("Close"), callback);
-@@ -343,7 +343,7 @@ void silcgaim_show_public_key(SilcGaim s
- }
-
- SilcAttributePayload
--silcgaim_get_attr(SilcDList attrs, SilcAttribute attribute)
-+silcgaim2_get_attr(SilcDList attrs, SilcAttribute attribute)
- {
- SilcAttributePayload attr = NULL;
-
-@@ -358,7 +358,7 @@ silcgaim_get_attr(SilcDList attrs, SilcA
- return attr;
- }
-
--void silcgaim_get_umode_string(SilcUInt32 mode, char *buf,
-+void silcgaim2_get_umode_string(SilcUInt32 mode, char *buf,
- SilcUInt32 buf_size)
- {
- memset(buf, 0, buf_size);
-@@ -393,7 +393,7 @@ void silcgaim_get_umode_string(SilcUInt3
- strcat(buf, "[blocks invites] ");
- }
-
--void silcgaim_get_chmode_string(SilcUInt32 mode, char *buf,
-+void silcgaim2_get_chmode_string(SilcUInt32 mode, char *buf,
- SilcUInt32 buf_size)
- {
- memset(buf, 0, buf_size);
-@@ -423,7 +423,7 @@ void silcgaim_get_chmode_string(SilcUInt
- strcat(buf, "[operators silenced] ");
- }
-
--void silcgaim_get_chumode_string(SilcUInt32 mode, char *buf,
-+void silcgaim2_get_chumode_string(SilcUInt32 mode, char *buf,
- SilcUInt32 buf_size)
- {
- memset(buf, 0, buf_size);
-@@ -442,7 +442,7 @@ void silcgaim_get_chumode_string(SilcUIn
- }
-
- void
--silcgaim_parse_attrs(SilcDList attrs, char **moodstr, char **statusstr,
-+silcgaim2_parse_attrs(SilcDList attrs, char **moodstr, char **statusstr,
- char **contactstr, char **langstr, char **devicestr,
- char **tzstr, char **geostr)
- {
-@@ -467,7 +467,7 @@ silcgaim_parse_attrs(SilcDList attrs, ch
- return;
-
- s = g_string_new("");
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_STATUS_MOOD);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_STATUS_MOOD);
- if (attr && silc_attribute_get_object(attr, &mood, sizeof(mood))) {
- if (mood & SILC_ATTRIBUTE_MOOD_HAPPY)
- g_string_append_printf(s, "[%s] ", _("Happy"));
-@@ -498,13 +498,13 @@ silcgaim_parse_attrs(SilcDList attrs, ch
- } else
- g_string_free(s, TRUE);
-
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_STATUS_FREETEXT);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_STATUS_FREETEXT);
- memset(tmp, 0, sizeof(tmp));
- if (attr && silc_attribute_get_object(attr, tmp, sizeof(tmp)))
- *statusstr = g_strdup(tmp);
-
- s = g_string_new("");
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_PREFERRED_CONTACT);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_PREFERRED_CONTACT);
- if (attr && silc_attribute_get_object(attr, &contact, sizeof(contact))) {
- if (contact & SILC_ATTRIBUTE_CONTACT_CHAT)
- g_string_append_printf(s, "[%s] ", _("Chat"));
-@@ -527,13 +527,13 @@ silcgaim_parse_attrs(SilcDList attrs, ch
- } else
- g_string_free(s, TRUE);
-
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_PREFERRED_LANGUAGE);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_PREFERRED_LANGUAGE);
- memset(tmp, 0, sizeof(tmp));
- if (attr && silc_attribute_get_object(attr, tmp, sizeof(tmp)))
- *langstr = g_strdup(tmp);
-
- s = g_string_new("");
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_DEVICE_INFO);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_DEVICE_INFO);
- memset(&device, 0, sizeof(device));
- if (attr && silc_attribute_get_object(attr, &device, sizeof(device))) {
- if (device.type == SILC_ATTRIBUTE_DEVICE_COMPUTER)
-@@ -556,12 +556,12 @@ silcgaim_parse_attrs(SilcDList attrs, ch
- } else
- g_string_free(s, TRUE);
-
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_TIMEZONE);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_TIMEZONE);
- memset(tmp, 0, sizeof(tmp));
- if (attr && silc_attribute_get_object(attr, tmp, sizeof(tmp)))
- *tzstr = g_strdup(tmp);
-
-- attr = silcgaim_get_attr(attrs, SILC_ATTRIBUTE_GEOLOCATION);
-+ attr = silcgaim2_get_attr(attrs, SILC_ATTRIBUTE_GEOLOCATION);
- memset(&geo, 0, sizeof(geo));
- if (attr && silc_attribute_get_object(attr, &geo, sizeof(geo)))
- *geostr = g_strdup_printf("%s %s %s (%s)",
-@@ -574,7 +574,7 @@ silcgaim_parse_attrs(SilcDList attrs, ch
- #ifdef HAVE_SILCMIME_H
- /* Returns MIME type of filetype */
-
--char *silcgaim_file2mime(const char *filename)
-+char *silcgaim2_file2mime(const char *filename)
- {
- const char *ct;
-
-@@ -600,7 +600,7 @@ char *silcgaim_file2mime(const char *fil
- there are multiple images and/or text with images multipart MIME
- message is created. */
-
--SilcDList silcgaim_image_message(const char *msg, SilcUInt32 *mflags)
-+SilcDList silcgaim2_image_message(const char *msg, SilcUInt32 *mflags)
- {
- SilcMime mime = NULL, p;
- SilcDList list, parts = NULL;
-@@ -610,9 +610,9 @@ SilcDList silcgaim_image_message(const c
- gboolean images = FALSE;
-
- last = msg;
-- while (last && *last && gaim_markup_find_tag("img", last, &start,
-+ while (last && *last && gaim2_markup_find_tag("img", last, &start,
- &end, &attribs)) {
-- GaimStoredImage *image = NULL;
-+ Gaim2StoredImage *image = NULL;
- const char *id;
-
- /* Check if there is text before image */
-@@ -625,7 +625,7 @@ SilcDList silcgaim_image_message(const c
- "text/plain; charset=utf-8");
-
- tmp = g_strndup(last, start - last);
-- text = gaim_unescape_html(tmp);
-+ text = gaim2_unescape_html(tmp);
- g_free(tmp);
- /* Add text */
- silc_mime_add_data(p, text, strlen(text));
-@@ -637,14 +637,14 @@ SilcDList silcgaim_image_message(const c
- }
-
- id = g_datalist_get_data(&attribs, "id");
-- if (id && (image = gaim_imgstore_get(atoi(id)))) {
-- unsigned long imglen = gaim_imgstore_get_size(image);
-- gpointer img = gaim_imgstore_get_data(image);
-+ if (id && (image = gaim2_imgstore_get(atoi(id)))) {
-+ unsigned long imglen = gaim2_imgstore_get_size(image);
-+ gpointer img = gaim2_imgstore_get_data(image);
-
- p = silc_mime_alloc();
-
- /* Add content type */
-- type = silcgaim_file2mime(gaim_imgstore_get_filename(image));
-+ type = silcgaim2_file2mime(gaim2_imgstore_get_filename(image));
- if (!type) {
- g_datalist_clear(&attribs);
- last = end + 1;
-@@ -673,7 +673,7 @@ SilcDList silcgaim_image_message(const c
-
- /* Check for text after the image(s) */
- if (images && last && *last) {
-- char *tmp = gaim_unescape_html(last);
-+ char *tmp = gaim2_unescape_html(last);
- p = silc_mime_alloc();
-
- /* Add content type */
-diff -prNu ./src/protocols/silc/wb.c ./src/protocols/silc/wb.c
---- ./src/protocols/silc/wb.c 2005-11-20 01:59:36.000000000 +0100
-+++ ./src/protocols/silc/wb.c 2006-01-05 15:11:06.000000000 +0100
-@@ -19,7 +19,7 @@
-
- #include "silcincludes.h"
- #include "silcclient.h"
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "wb.h"
-
- /*
-@@ -62,16 +62,16 @@
- typedef enum {
- SILCGAIM_WB_DRAW = 0x01,
- SILCGAIM_WB_CLEAR = 0x02,
--} SilcGaimWbCommand;
-+} SilcGaim2WbCommand;
-
- /* Brush size */
- typedef enum {
- SILCGAIM_WB_BRUSH_SMALL = 2,
- SILCGAIM_WB_BRUSH_MEDIUM = 5,
- SILCGAIM_WB_BRUSH_LARGE = 10,
--} SilcGaimWbBrushSize;
-+} SilcGaim2WbBrushSize;
-
--/* Brush color (XXX Gaim should provide default colors) */
-+/* Brush color (XXX Gaim2 should provide default colors) */
- typedef enum {
- SILCGAIM_WB_COLOR_BLACK = 0,
- SILCGAIM_WB_COLOR_RED = 13369344,
-@@ -86,7 +86,7 @@ typedef enum {
- SILCGAIM_WB_COLOR_BROWN = 5256485,
- SILCGAIM_WB_COLOR_GREY = 11184810,
- SILCGAIM_WB_COLOR_WHITE = 16777215,
--} SilcGaimWbColor;
-+} SilcGaim2WbColor;
-
- typedef struct {
- int type; /* 0 = buddy, 1 = channel */
-@@ -98,20 +98,20 @@ typedef struct {
- int height;
- int brush_size;
- int brush_color;
--} *SilcGaimWb;
-+} *SilcGaim2Wb;
-
- /* Initialize whiteboard */
-
--GaimWhiteboard *silcgaim_wb_init(SilcGaim sg, SilcClientEntry client_entry)
-+Gaim2Whiteboard *silcgaim2_wb_init(SilcGaim2 sg, SilcClientEntry client_entry)
- {
- SilcClientConnection conn;
-- GaimWhiteboard *wb;
-- SilcGaimWb wbs;
-+ Gaim2Whiteboard *wb;
-+ SilcGaim2Wb wbs;
-
- conn = sg->conn;
-- wb = gaim_whiteboard_get_session(sg->account, client_entry->nickname);
-+ wb = gaim2_whiteboard_get_session(sg->account, client_entry->nickname);
- if (!wb)
-- wb = gaim_whiteboard_create(sg->account, client_entry->nickname, 0);
-+ wb = gaim2_whiteboard_create(sg->account, client_entry->nickname, 0);
- if (!wb)
- return NULL;
-
-@@ -128,21 +128,21 @@ GaimWhiteboard *silcgaim_wb_init(SilcGai
- wb->proto_data = wbs;
-
- /* Start the whiteboard */
-- gaim_whiteboard_start(wb);
-- gaim_whiteboard_clear(wb);
-+ gaim2_whiteboard_start(wb);
-+ gaim2_whiteboard_clear(wb);
- }
-
- return wb;
- }
-
--GaimWhiteboard *silcgaim_wb_init_ch(SilcGaim sg, SilcChannelEntry channel)
-+Gaim2Whiteboard *silcgaim2_wb_init_ch(SilcGaim2 sg, SilcChannelEntry channel)
- {
-- GaimWhiteboard *wb;
-- SilcGaimWb wbs;
-+ Gaim2Whiteboard *wb;
-+ SilcGaim2Wb wbs;
-
-- wb = gaim_whiteboard_get_session(sg->account, channel->channel_name);
-+ wb = gaim2_whiteboard_get_session(sg->account, channel->channel_name);
- if (!wb)
-- wb = gaim_whiteboard_create(sg->account, channel->channel_name, 0);
-+ wb = gaim2_whiteboard_create(sg->account, channel->channel_name, 0);
- if (!wb)
- return NULL;
-
-@@ -159,15 +159,15 @@ GaimWhiteboard *silcgaim_wb_init_ch(Silc
- wb->proto_data = wbs;
-
- /* Start the whiteboard */
-- gaim_whiteboard_start(wb);
-- gaim_whiteboard_clear(wb);
-+ gaim2_whiteboard_start(wb);
-+ gaim2_whiteboard_clear(wb);
- }
-
- return wb;
- }
-
- static void
--silcgaim_wb_parse(SilcGaimWb wbs, GaimWhiteboard *wb,
-+silcgaim2_wb_parse(SilcGaim2Wb wbs, Gaim2Whiteboard *wb,
- unsigned char *message, SilcUInt32 message_len)
- {
- SilcUInt8 command;
-@@ -191,7 +191,7 @@ silcgaim_wb_parse(SilcGaimWb wbs, GaimWh
-
- /* Update whiteboard if its dimensions changed */
- if (width != wbs->width || height != wbs->height)
-- silcgaim_wb_set_dimensions(wb, height, width);
-+ silcgaim2_wb_set_dimensions(wb, height, width);
-
- if (command == SILCGAIM_WB_DRAW) {
- /* Parse data and draw it */
-@@ -213,7 +213,7 @@ silcgaim_wb_parse(SilcGaimWb wbs, GaimWh
- return;
- silc_buffer_pull(&buf, 8);
-
-- gaim_whiteboard_draw_line(wb, x, y, x + dx, y + dy,
-+ gaim2_whiteboard_draw_line(wb, x, y, x + dx, y + dy,
- brush_color, brush_size);
- x += dx;
- y += dy;
-@@ -221,31 +221,31 @@ silcgaim_wb_parse(SilcGaimWb wbs, GaimWh
- }
-
- if (command == SILCGAIM_WB_CLEAR)
-- gaim_whiteboard_clear(wb);
-+ gaim2_whiteboard_clear(wb);
- }
-
- typedef struct {
- unsigned char *message;
- SilcUInt32 message_len;
-- SilcGaim sg;
-+ SilcGaim2 sg;
- SilcClientEntry sender;
- SilcChannelEntry channel;
--} *SilcGaimWbRequest;
-+} *SilcGaim2WbRequest;
-
- static void
--silcgaim_wb_request_cb(SilcGaimWbRequest req, gint id)
-+silcgaim2_wb_request_cb(SilcGaim2WbRequest req, gint id)
- {
-- GaimWhiteboard *wb;
-+ Gaim2Whiteboard *wb;
-
- if (id != 1)
- goto out;
-
- if (!req->channel)
-- wb = silcgaim_wb_init(req->sg, req->sender);
-+ wb = silcgaim2_wb_init(req->sg, req->sender);
- else
-- wb = silcgaim_wb_init_ch(req->sg, req->channel);
-+ wb = silcgaim2_wb_init_ch(req->sg, req->channel);
-
-- silcgaim_wb_parse(wb->proto_data, wb, req->message, req->message_len);
-+ silcgaim2_wb_parse(wb->proto_data, wb, req->message, req->message_len);
-
- out:
- silc_free(req->message);
-@@ -253,28 +253,28 @@ silcgaim_wb_request_cb(SilcGaimWbRequest
- }
-
- static void
--silcgaim_wb_request(SilcClient client, const unsigned char *message,
-+silcgaim2_wb_request(SilcClient client, const unsigned char *message,
- SilcUInt32 message_len, SilcClientEntry sender,
- SilcChannelEntry channel)
- {
- char tmp[128];
-- SilcGaimWbRequest req;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ SilcGaim2WbRequest req;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- gc = client->application;
- sg = gc->proto_data;
-
- /* Open whiteboard automatically if requested */
-- if (gaim_account_get_bool(sg->account, "open-wb", FALSE)) {
-- GaimWhiteboard *wb;
-+ if (gaim2_account_get_bool(sg->account, "open-wb", FALSE)) {
-+ Gaim2Whiteboard *wb;
-
- if (!channel)
-- wb = silcgaim_wb_init(sg, sender);
-+ wb = silcgaim2_wb_init(sg, sender);
- else
-- wb = silcgaim_wb_init_ch(sg, channel);
-+ wb = silcgaim2_wb_init_ch(sg, channel);
-
-- silcgaim_wb_parse(wb->proto_data, wb, (unsigned char *)message,
-+ silcgaim2_wb_parse(wb->proto_data, wb, (unsigned char *)message,
- message_len);
- return;
- }
-@@ -299,80 +299,80 @@ silcgaim_wb_request(SilcClient client, c
- req->channel = channel;
- req->sg = sg;
-
-- gaim_request_action(gc, _("Whiteboard"), tmp, NULL, 1, req, 2,
-- _("Yes"), G_CALLBACK(silcgaim_wb_request_cb),
-- _("No"), G_CALLBACK(silcgaim_wb_request_cb));
-+ gaim2_request_action(gc, _("Whiteboard"), tmp, NULL, 1, req, 2,
-+ _("Yes"), G_CALLBACK(silcgaim2_wb_request_cb),
-+ _("No"), G_CALLBACK(silcgaim2_wb_request_cb));
- }
-
- /* Process incoming whiteboard message */
-
--void silcgaim_wb_receive(SilcClient client, SilcClientConnection conn,
-+void silcgaim2_wb_receive(SilcClient client, SilcClientConnection conn,
- SilcClientEntry sender, SilcMessagePayload payload,
- SilcMessageFlags flags, const unsigned char *message,
- SilcUInt32 message_len)
- {
-- SilcGaim sg;
-- GaimConnection *gc;
-- GaimWhiteboard *wb;
-- SilcGaimWb wbs;
-+ SilcGaim2 sg;
-+ Gaim2Connection *gc;
-+ Gaim2Whiteboard *wb;
-+ SilcGaim2Wb wbs;
-
- gc = client->application;
- sg = gc->proto_data;
-
-- wb = gaim_whiteboard_get_session(sg->account, sender->nickname);
-+ wb = gaim2_whiteboard_get_session(sg->account, sender->nickname);
- if (!wb) {
- /* Ask user if they want to open the whiteboard */
-- silcgaim_wb_request(client, message, message_len,
-+ silcgaim2_wb_request(client, message, message_len,
- sender, NULL);
- return;
- }
-
- wbs = wb->proto_data;
-- silcgaim_wb_parse(wbs, wb, (unsigned char *)message, message_len);
-+ silcgaim2_wb_parse(wbs, wb, (unsigned char *)message, message_len);
- }
-
- /* Process incoming whiteboard message on channel */
-
--void silcgaim_wb_receive_ch(SilcClient client, SilcClientConnection conn,
-+void silcgaim2_wb_receive_ch(SilcClient client, SilcClientConnection conn,
- SilcClientEntry sender, SilcChannelEntry channel,
- SilcMessagePayload payload,
- SilcMessageFlags flags,
- const unsigned char *message,
- SilcUInt32 message_len)
- {
-- SilcGaim sg;
-- GaimConnection *gc;
-- GaimWhiteboard *wb;
-- SilcGaimWb wbs;
-+ SilcGaim2 sg;
-+ Gaim2Connection *gc;
-+ Gaim2Whiteboard *wb;
-+ SilcGaim2Wb wbs;
-
- gc = client->application;
- sg = gc->proto_data;
-
-- wb = gaim_whiteboard_get_session(sg->account, channel->channel_name);
-+ wb = gaim2_whiteboard_get_session(sg->account, channel->channel_name);
- if (!wb) {
- /* Ask user if they want to open the whiteboard */
-- silcgaim_wb_request(client, message, message_len,
-+ silcgaim2_wb_request(client, message, message_len,
- sender, channel);
- return;
- }
-
- wbs = wb->proto_data;
-- silcgaim_wb_parse(wbs, wb, (unsigned char *)message, message_len);
-+ silcgaim2_wb_parse(wbs, wb, (unsigned char *)message, message_len);
- }
-
- /* Send whiteboard message */
-
--void silcgaim_wb_send(GaimWhiteboard *wb, GList *draw_list)
-+void silcgaim2_wb_send(Gaim2Whiteboard *wb, GList *draw_list)
- {
-- SilcGaimWb wbs = wb->proto_data;
-+ SilcGaim2Wb wbs = wb->proto_data;
- SilcBuffer packet;
- GList *list;
- int len;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
- g_return_if_fail(draw_list);
-- gc = gaim_account_get_connection(wb->account);
-+ gc = gaim2_account_get_connection(wb->account);
- g_return_if_fail(gc);
- sg = gc->proto_data;
- g_return_if_fail(sg);
-@@ -420,64 +420,64 @@ void silcgaim_wb_send(GaimWhiteboard *wb
- silc_buffer_free(packet);
- }
-
--/* Gaim Whiteboard operations */
-+/* Gaim2 Whiteboard operations */
-
--void silcgaim_wb_start(GaimWhiteboard *wb)
-+void silcgaim2_wb_start(Gaim2Whiteboard *wb)
- {
- /* Nothing here. Everything is in initialization */
- }
-
--void silcgaim_wb_end(GaimWhiteboard *wb)
-+void silcgaim2_wb_end(Gaim2Whiteboard *wb)
- {
- silc_free(wb->proto_data);
- wb->proto_data = NULL;
- }
-
--void silcgaim_wb_get_dimensions(GaimWhiteboard *wb, int *width, int *height)
-+void silcgaim2_wb_get_dimensions(Gaim2Whiteboard *wb, int *width, int *height)
- {
-- SilcGaimWb wbs = wb->proto_data;
-+ SilcGaim2Wb wbs = wb->proto_data;
- *width = wbs->width;
- *height = wbs->height;
- }
-
--void silcgaim_wb_set_dimensions(GaimWhiteboard *wb, int width, int height)
-+void silcgaim2_wb_set_dimensions(Gaim2Whiteboard *wb, int width, int height)
- {
-- SilcGaimWb wbs = wb->proto_data;
-+ SilcGaim2Wb wbs = wb->proto_data;
- wbs->width = width > SILCGAIM_WB_WIDTH_MAX ? SILCGAIM_WB_WIDTH_MAX :
- width;
- wbs->height = height > SILCGAIM_WB_HEIGHT_MAX ? SILCGAIM_WB_HEIGHT_MAX :
- height;
-
- /* Update whiteboard */
-- gaim_whiteboard_set_dimensions(wb, wbs->width, wbs->height);
-+ gaim2_whiteboard_set_dimensions(wb, wbs->width, wbs->height);
- }
-
--void silcgaim_wb_get_brush(GaimWhiteboard *wb, int *size, int *color)
-+void silcgaim2_wb_get_brush(Gaim2Whiteboard *wb, int *size, int *color)
- {
-- SilcGaimWb wbs = wb->proto_data;
-+ SilcGaim2Wb wbs = wb->proto_data;
- *size = wbs->brush_size;
- *color = wbs->brush_color;
- }
-
--void silcgaim_wb_set_brush(GaimWhiteboard *wb, int size, int color)
-+void silcgaim2_wb_set_brush(Gaim2Whiteboard *wb, int size, int color)
- {
-- SilcGaimWb wbs = wb->proto_data;
-+ SilcGaim2Wb wbs = wb->proto_data;
- wbs->brush_size = size;
- wbs->brush_color = color;
-
- /* Update whiteboard */
-- gaim_whiteboard_set_brush(wb, size, color);
-+ gaim2_whiteboard_set_brush(wb, size, color);
- }
-
--void silcgaim_wb_clear(GaimWhiteboard *wb)
-+void silcgaim2_wb_clear(Gaim2Whiteboard *wb)
- {
-- SilcGaimWb wbs = wb->proto_data;
-+ SilcGaim2Wb wbs = wb->proto_data;
- SilcBuffer packet;
- int len;
-- GaimConnection *gc;
-- SilcGaim sg;
-+ Gaim2Connection *gc;
-+ SilcGaim2 sg;
-
-- gc = gaim_account_get_connection(wb->account);
-+ gc = gaim2_account_get_connection(wb->account);
- g_return_if_fail(gc);
- sg = gc->proto_data;
- g_return_if_fail(sg);
-diff -prNu ./src/protocols/silc/wb.h ./src/protocols/silc/wb.h
---- ./src/protocols/silc/wb.h 2005-11-13 00:04:44.000000000 +0100
-+++ ./src/protocols/silc/wb.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,6 +1,6 @@
- /*
-
-- silcgaim.h
-+ silcgaim2.h
-
- Author: Pekka Riikonen <priikone@silcnet.org>
-
-@@ -20,30 +20,30 @@
- #ifndef SILCGAIM_WB_H
- #define SILCGAIM_WB_H
-
--#include "silcgaim.h"
-+#include "silcgaim2.h"
- #include "whiteboard.h"
-
--GaimWhiteboard *
--silcgaim_wb_init(SilcGaim sg, SilcClientEntry client_entry);
--GaimWhiteboard *
--silcgaim_wb_init_ch(SilcGaim sg, SilcChannelEntry channel);
--void silcgaim_wb_receive(SilcClient client, SilcClientConnection conn,
-+Gaim2Whiteboard *
-+silcgaim2_wb_init(SilcGaim2 sg, SilcClientEntry client_entry);
-+Gaim2Whiteboard *
-+silcgaim2_wb_init_ch(SilcGaim2 sg, SilcChannelEntry channel);
-+void silcgaim2_wb_receive(SilcClient client, SilcClientConnection conn,
- SilcClientEntry sender, SilcMessagePayload payload,
- SilcMessageFlags flags, const unsigned char *message,
- SilcUInt32 message_len);
--void silcgaim_wb_receive_ch(SilcClient client, SilcClientConnection conn,
-+void silcgaim2_wb_receive_ch(SilcClient client, SilcClientConnection conn,
- SilcClientEntry sender, SilcChannelEntry channel,
- SilcMessagePayload payload,
- SilcMessageFlags flags,
- const unsigned char *message,
- SilcUInt32 message_len);
--void silcgaim_wb_start(GaimWhiteboard *wb);
--void silcgaim_wb_end(GaimWhiteboard *wb);
--void silcgaim_wb_get_dimensions(GaimWhiteboard *wb, int *width, int *height);
--void silcgaim_wb_set_dimensions(GaimWhiteboard *wb, int width, int height);
--void silcgaim_wb_get_brush(GaimWhiteboard *wb, int *size, int *color);
--void silcgaim_wb_set_brush(GaimWhiteboard *wb, int size, int color);
--void silcgaim_wb_send(GaimWhiteboard *wb, GList *draw_list);
--void silcgaim_wb_clear(GaimWhiteboard *wb);
-+void silcgaim2_wb_start(Gaim2Whiteboard *wb);
-+void silcgaim2_wb_end(Gaim2Whiteboard *wb);
-+void silcgaim2_wb_get_dimensions(Gaim2Whiteboard *wb, int *width, int *height);
-+void silcgaim2_wb_set_dimensions(Gaim2Whiteboard *wb, int width, int height);
-+void silcgaim2_wb_get_brush(Gaim2Whiteboard *wb, int *size, int *color);
-+void silcgaim2_wb_set_brush(Gaim2Whiteboard *wb, int size, int color);
-+void silcgaim2_wb_send(Gaim2Whiteboard *wb, GList *draw_list);
-+void silcgaim2_wb_clear(Gaim2Whiteboard *wb);
-
- #endif /* SILCGAIM_WB_H */
-diff -prNu ./src/protocols/simple/Makefile.am ./src/protocols/simple/Makefile.am
---- ./src/protocols/simple/Makefile.am 2005-12-17 23:25:36.000000000 +0100
-+++ ./src/protocols/simple/Makefile.am 2006-01-05 13:05:09.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- SIMPLESOURCES = \
- simple.c \
-diff -prNu ./src/protocols/simple/simple.c ./src/protocols/simple/simple.c
---- ./src/protocols/simple/simple.c 2006-01-05 06:04:07.000000000 +0100
-+++ ./src/protocols/simple/simple.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file simple.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -69,16 +69,16 @@ static char *gencallid() {
- rand() & 0xFFFF);
- }
-
--static const char *simple_list_icon(GaimAccount *a, GaimBuddy *b) {
-+static const char *simple_list_icon(Gaim2Account *a, Gaim2Buddy *b) {
- return "simple";
- }
-
--static void simple_keep_alive(GaimConnection *gc) {
-+static void simple_keep_alive(Gaim2Connection *gc) {
- struct simple_account_data *sip = gc->proto_data;
- if(sip->udp) { /* in case of UDP send a packet only with a 0 byte to
- remain in the NAT table */
- gchar buf[2]={0,0};
-- gaim_debug_info("simple", "sending keep alive\n");
-+ gaim2_debug_info("simple", "sending keep alive\n");
- sendto(sip->fd, buf, 1, 0, (struct sockaddr*)&sip->serveraddr, sizeof(struct sockaddr_in));
- }
- return;
-@@ -91,25 +91,25 @@ static void send_publish(struct simple_a
-
- static void do_notifies(struct simple_account_data *sip) {
- GSList *tmp = sip->watcher;
-- gaim_debug_info("simple", "do_notifies()\n");
-+ gaim2_debug_info("simple", "do_notifies()\n");
- if((sip->republish != -1) || sip->republish < time(NULL)) {
-- if(gaim_account_get_bool(sip->account, "dopublish", TRUE)) {
-+ if(gaim2_account_get_bool(sip->account, "dopublish", TRUE)) {
- send_publish(sip);
- }
- }
-
- while(tmp) {
-- gaim_debug_info("simple", "notifying %s\n", ((struct simple_watcher*)tmp->data)->name);
-+ gaim2_debug_info("simple", "notifying %s\n", ((struct simple_watcher*)tmp->data)->name);
- send_notify(sip, tmp->data);
- tmp = tmp->next;
- }
- }
-
--static void simple_set_status(GaimAccount *account, GaimStatus *status) {
-- GaimStatusPrimitive primitive = gaim_status_type_get_primitive(gaim_status_get_type(status));
-+static void simple_set_status(Gaim2Account *account, Gaim2Status *status) {
-+ Gaim2StatusPrimitive primitive = gaim2_status_type_get_primitive(gaim2_status_get_type(status));
- struct simple_account_data *sip = NULL;
-
-- if (!gaim_status_is_active(status))
-+ if (!gaim2_status_is_active(status))
- return;
-
- if (account->gc)
-@@ -179,7 +179,7 @@ static struct sip_connection *connection
- static void connection_remove(struct simple_account_data *sip, int fd) {
- struct sip_connection *conn = connection_find(sip, fd);
- sip->openconns = g_slist_remove(sip->openconns, conn);
-- if(conn->inputhandler) gaim_input_remove(conn->inputhandler);
-+ if(conn->inputhandler) gaim2_input_remove(conn->inputhandler);
- g_free(conn->inbuf);
- g_free(conn);
- }
-@@ -194,46 +194,46 @@ static void connection_free_all(struct s
- }
- }
-
--static void simple_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void simple_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- struct simple_account_data *sip = (struct simple_account_data *)gc->proto_data;
- struct simple_buddy *b;
- if(strncmp("sip:", buddy->name,4)) {
- gchar *buf = g_strdup_printf(_("Could not add the buddy %s because every simple user has to start with 'sip:'."), buddy->name);
-- gaim_notify_error(gc, NULL, _("Unable To Add"), buf);
-+ gaim2_notify_error(gc, NULL, _("Unable To Add"), buf);
- g_free(buf);
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_blist_remove_buddy(buddy);
- return;
- }
- if(!g_hash_table_lookup(sip->buddies, buddy->name)) {
- b = g_new0(struct simple_buddy, 1);
-- gaim_debug_info("simple","simple_add_buddy %s\n",buddy->name);
-+ gaim2_debug_info("simple","simple_add_buddy %s\n",buddy->name);
- b->name = g_strdup(buddy->name);
- g_hash_table_insert(sip->buddies, b->name, b);
- } else {
-- gaim_debug_info("simple","buddy %s already in internal list\n", buddy->name);
-+ gaim2_debug_info("simple","buddy %s already in internal list\n", buddy->name);
- }
- }
-
--static void simple_get_buddies(GaimConnection *gc) {
-- GaimBlistNode *gnode, *cnode, *bnode;
-+static void simple_get_buddies(Gaim2Connection *gc) {
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-
-- gaim_debug_info("simple","simple_get_buddies\n");
-+ gaim2_debug_info("simple","simple_get_buddies\n");
-
-- for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for(gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode)) continue;
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode)) continue;
- for(bnode = cnode->child; bnode; bnode = bnode->next) {
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode)) continue;
-- if(((GaimBuddy*)bnode)->account == gc->account)
-- simple_add_buddy(gc, (GaimBuddy*)bnode, (GaimGroup *)gnode);
-+ if(((Gaim2Buddy*)bnode)->account == gc->account)
-+ simple_add_buddy(gc, (Gaim2Buddy*)bnode, (Gaim2Group *)gnode);
- }
- }
- }
- }
-
--static void simple_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void simple_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- struct simple_account_data *sip = (struct simple_account_data *)gc->proto_data;
- struct simple_buddy *b = g_hash_table_lookup(sip->buddies, buddy->name);
-@@ -242,17 +242,17 @@ static void simple_remove_buddy(GaimConn
- g_free(b);
- }
-
--static GList *simple_status_types(GaimAccount *acc) {
-- GaimStatusType *type;
-+static GList *simple_status_types(Gaim2Account *acc) {
-+ Gaim2StatusType *type;
- GList *types = NULL;
-
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_AVAILABLE, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new_full(
-+ type = gaim2_status_type_new_full(
- GAIM_STATUS_OFFLINE, NULL, NULL, TRUE, TRUE, FALSE);
- types = g_list_append(types, type);
-
-@@ -267,32 +267,32 @@ static gchar *auth_header(struct simple_
-
- if(auth->type == 1) { /* Digest */
- sprintf(noncecount, "%08d", auth->nc++);
-- response = gaim_cipher_http_digest_calculate_response(
-+ response = gaim2_cipher_http_digest_calculate_response(
- "md5", method, target, NULL, NULL,
- auth->nonce, noncecount, NULL, auth->digest_session_key);
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "response %s\n", response);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "response %s\n", response);
-
- ret = g_strdup_printf("Digest username=\"%s\", realm=\"%s\", nonce=\"%s\", uri=\"%s\", nc=\"%s\", response=\"%s\"\r\n", sip->username, auth->realm, auth->nonce, target, noncecount, response);
- g_free(response);
- return ret;
- } else if(auth->type == 2) { /* NTLM */
- if(auth->nc == 3) {
-- ret = gaim_ntlm_gen_type3(sip->username, sip->password, "gaim", sip->servername, auth->nonce);
-+ ret = gaim2_ntlm_gen_type3(sip->username, sip->password, "gaim2", sip->servername, auth->nonce);
- tmp = g_strdup_printf("NTLM qop=\"auth\" realm=\"%s\" targetname=\"%s\" response=\"%s\"\r\n", auth->realm, auth->target, ret);
- g_free(ret);
- return tmp;
- }
-- ret = gaim_ntlm_gen_type1("gaim", sip->servername);
-+ ret = gaim2_ntlm_gen_type1("gaim2", sip->servername);
- tmp = g_strdup_printf("NTLM qop=\"auth\" realm=\"%s\" targetname=\"%s\" response=\"%s\"\r\n", auth->realm, auth->target, ret);
- g_free(ret);
- return tmp;
- }
-
- sprintf(noncecount, "%08d", auth->nc++);
-- response = gaim_cipher_http_digest_calculate_response(
-+ response = gaim2_cipher_http_digest_calculate_response(
- "md5", method, target, NULL, NULL,
- auth->nonce, noncecount, NULL, auth->digest_session_key);
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "response %s\n", response);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "response %s\n", response);
-
- ret = g_strdup_printf("Digest username=\"%s\", realm=\"%s\", nonce=\"%s\", uri=\"%s\", nc=\"%s\", response=\"%s\"\r\n", sip->username, auth->realm, auth->nonce, target, noncecount, response);
- g_free(response);
-@@ -305,12 +305,12 @@ static void fill_auth(struct simple_acco
- char *tmp2;
- gchar **parts;
- if(!hdr) {
-- gaim_debug_error("simple", "fill_auth: hdr==NULL\n");
-+ gaim2_debug_error("simple", "fill_auth: hdr==NULL\n");
- return;
- }
-
- if(!g_strncasecmp(hdr, "NTLM", 4)) {
-- gaim_debug_info("simple", "found NTLM\n");
-+ gaim2_debug_info("simple", "found NTLM\n");
- auth->type = 2;
- if(!auth->nonce && !auth->nc) {
- parts = g_strsplit(hdr, " ", 0);
-@@ -334,7 +334,7 @@ static void fill_auth(struct simple_acco
- }
- if(!auth->nonce && auth->nc==2) {
- auth->nc = 3;
-- auth->nonce = gaim_ntlm_parse_type2(hdr+5);
-+ auth->nonce = gaim2_ntlm_parse_type2(hdr+5);
- }
- return;
- }
-@@ -352,23 +352,23 @@ static void fill_auth(struct simple_acco
- }
- g_strfreev(parts);
-
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "nonce: %s realm: %s ", auth->nonce, auth->realm);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "nonce: %s realm: %s ", auth->nonce, auth->realm);
-
-- auth->digest_session_key = gaim_cipher_http_digest_calculate_session_key(
-+ auth->digest_session_key = gaim2_cipher_http_digest_calculate_session_key(
- "md5", sip->username, auth->realm, sip->password, auth->nonce, NULL);
-
- auth->nc=1;
- }
-
--static void simple_input_cb(gpointer data, gint source, GaimInputCondition cond);
-+static void simple_input_cb(gpointer data, gint source, Gaim2InputCondition cond);
-
--static void send_later_cb(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void send_later_cb(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- struct simple_account_data *sip = gc->proto_data;
- struct sip_connection *conn;
-
- if( source < 0 ) {
-- gaim_connection_error(gc,"Could not connect");
-+ gaim2_connection_error(gc,"Could not connect");
- return;
- }
-
-@@ -376,20 +376,20 @@ static void send_later_cb(gpointer data,
- sip->connecting = 0;
- write(sip->fd, sip->sendlater, strlen(sip->sendlater));
- conn = connection_create(sip, source);
-- conn->inputhandler = gaim_input_add(sip->fd, GAIM_INPUT_READ, simple_input_cb, gc);
-+ conn->inputhandler = gaim2_input_add(sip->fd, GAIM_INPUT_READ, simple_input_cb, gc);
- g_free(sip->sendlater);
- sip->sendlater = 0;
- }
-
-
--static void sendlater(GaimConnection *gc, const char *buf) {
-+static void sendlater(Gaim2Connection *gc, const char *buf) {
- struct simple_account_data *sip = gc->proto_data;
- int error = 0;
- if(!sip->connecting) {
-- gaim_debug_info("simple","connecting to %s port %d\n", sip->realhostname ? sip->realhostname : "{NULL}", sip->realport);
-- error = gaim_proxy_connect(sip->account, sip->realhostname, sip->realport, send_later_cb, gc);
-+ gaim2_debug_info("simple","connecting to %s port %d\n", sip->realhostname ? sip->realhostname : "{NULL}", sip->realport);
-+ error = gaim2_proxy_connect(sip->account, sip->realhostname, sip->realport, send_later_cb, gc);
- if(error) {
-- gaim_connection_error(gc, _("Couldn't create socket"));
-+ gaim2_connection_error(gc, _("Couldn't create socket"));
- }
- sip->connecting = 1;
- }
-@@ -401,15 +401,15 @@ static void sendlater(GaimConnection *gc
- }
- }
-
--static int sendout_pkt(GaimConnection *gc, const char *buf) {
-+static int sendout_pkt(Gaim2Connection *gc, const char *buf) {
- struct simple_account_data *sip = gc->proto_data;
- time_t currtime = time(NULL);
- int ret = 0;
-
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "\n\nsending - %s\n######\n%s\n######\n\n", ctime(&currtime), buf);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "\n\nsending - %s\n######\n%s\n######\n\n", ctime(&currtime), buf);
- if(sip->udp) {
- if(sendto(sip->fd, buf, strlen(buf), 0, (struct sockaddr*)&sip->serveraddr, sizeof(struct sockaddr_in)) < strlen(buf)) {
-- gaim_debug_info("simple", "could not send packet\n");
-+ gaim2_debug_info("simple", "could not send packet\n");
- }
- } else {
- if(sip->fd <0 ) {
-@@ -447,7 +447,7 @@ static void sendout_sipmsg(struct simple
- g_free(outstr);
- }
-
--static void send_sip_response(GaimConnection *gc, struct sipmsg *msg, int code, char *text, char *body) {
-+static void send_sip_response(Gaim2Connection *gc, struct sipmsg *msg, int code, char *text, char *body) {
- GSList *tmp = msg->headers;
- char *oldstr;
- char *name;
-@@ -500,7 +500,7 @@ static struct transaction *transactions_
- return (struct transaction *)NULL;
- }
-
--static void send_sip_request(GaimConnection *gc, gchar *method, gchar *url, gchar *to, gchar *addheaders, gchar *body, struct sip_dialog *dialog, TransCallback tc) {
-+static void send_sip_request(Gaim2Connection *gc, gchar *method, gchar *url, gchar *to, gchar *addheaders, gchar *body, struct sip_dialog *dialog, TransCallback tc) {
- struct simple_account_data *sip = gc->proto_data;
- char *callid= dialog ? g_strdup(dialog->callid) : gencallid();
- char *auth="";
-@@ -518,19 +518,19 @@ static void send_sip_request(GaimConnect
- buf = auth_header(sip, &sip->registrar, method, url);
- auth = g_strdup_printf("Authorization: %s", buf);
- g_free(buf);
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "header %s", auth);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "header %s", auth);
- }
-
- if(sip->proxy.type && strcmp(method,"REGISTER")) {
- buf = auth_header(sip, &sip->proxy, method, url);
- auth = g_strdup_printf("Proxy-Authorization: %s", buf);
- g_free(buf);
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "header %s", auth);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "header %s", auth);
- }
-
- if(!sip->ip || !strcmp(sip->ip,"0.0.0.0")) { /* if there was no known ip retry now */
- g_free(sip->ip);
-- sip->ip = g_strdup(gaim_network_get_public_ip());
-+ sip->ip = g_strdup(gaim2_network_get_public_ip());
- }
- buf = g_strdup_printf("%s %s SIP/2.0\r\n"
- "Via: SIP/2.0/%s %s:%d;branch=%s\r\n"
-@@ -538,7 +538,7 @@ static void send_sip_request(GaimConnect
- "To: <%s>%s%s\r\n"
- "Max-Forwards: 10\r\n"
- "CSeq: %d %s\r\n"
-- "User-Agent: Gaim SIP/SIMPLE Plugin\r\n"
-+ "User-Agent: Gaim2 SIP/SIMPLE Plugin\r\n"
- "Call-ID: %s\r\n"
- "%s%s"
- "Content-Length: %" G_GSIZE_FORMAT "\r\n\r\n%s",
-@@ -600,7 +600,7 @@ static gchar *parse_from(gchar *hdr) {
- gchar *tmp;
-
- if(!from) return NULL;
-- gaim_debug_info("simple", "parsing address out of %s\n",from);
-+ gaim2_debug_info("simple", "parsing address out of %s\n",from);
- tmp = strchr(from, '<');
-
- /* i hate the different SIP UA behaviours... */
-@@ -610,7 +610,7 @@ static gchar *parse_from(gchar *hdr) {
- if(tmp) {
- from = g_strndup(from,tmp-from);
- } else {
-- gaim_debug_info("simple", "found < without > in From\n");
-+ gaim2_debug_info("simple", "found < without > in From\n");
- return NULL;
- }
- } else {
-@@ -621,7 +621,7 @@ static gchar *parse_from(gchar *hdr) {
- from = g_strdup(from);
- }
- }
-- gaim_debug_info("simple", "got %s\n",from);
-+ gaim2_debug_info("simple", "got %s\n",from);
- return from;
- }
-
-@@ -634,7 +634,7 @@ static gboolean process_subscribe_respon
-
- /* we can not subscribe -> user is offline (TODO unknown status?) */
-
-- gaim_prpl_got_user_status(sip->account, to, "offline", NULL);
-+ gaim2_prpl_got_user_status(sip->account, to, "offline", NULL);
- g_free(to);
- return TRUE;
- }
-@@ -660,9 +660,9 @@ static void simple_subscribe(struct simp
-
- static void simple_buddy_resub(char *name, struct simple_buddy *buddy, struct simple_account_data *sip) {
- time_t curtime = time(NULL);
-- gaim_debug_info("simple","buddy resub\n");
-+ gaim2_debug_info("simple","buddy resub\n");
- if(buddy->resubscribe < curtime) {
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "simple_buddy_resub %s\n",name);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "simple_buddy_resub %s\n",name);
- simple_subscribe(sip, buddy);
- }
- }
-@@ -673,7 +673,7 @@ static gboolean resend_timeout(struct si
- while(tmp) {
- struct transaction *trans = tmp->data;
- tmp = tmp->next;
-- gaim_debug_info("simple", "have open transaction age: %d\n", currtime- trans->time);
-+ gaim2_debug_info("simple", "have open transaction age: %d\n", currtime- trans->time);
- if((currtime - trans->time > 5) && trans->retries >= 1) {
- /* TODO 408 */
- } else {
-@@ -693,7 +693,7 @@ static gboolean register_timeout(struct
- if(sip->reregister < curtime) {
- do_register(sip);
- }
-- gaim_debug_info("simple","in register timeout\n");
-+ gaim2_debug_info("simple","in register timeout\n");
- /* check for every subscription if we need to resubscribe */
- g_hash_table_foreach(sip->buddies, (GHFunc)simple_buddy_resub, (gpointer)sip);
-
-@@ -723,10 +723,10 @@ static void simple_send_message(struct s
- g_free(hdr);
- }
-
--static int simple_im_send(GaimConnection *gc, const char *who, const char *what, GaimMessageFlags flags) {
-+static int simple_im_send(Gaim2Connection *gc, const char *who, const char *what, Gaim2MessageFlags flags) {
- struct simple_account_data *sip = gc->proto_data;
- char *to = g_strdup(who);
-- char *text = gaim_unescape_html(what);
-+ char *text = gaim2_unescape_html(what);
- simple_send_message(sip, to, text, NULL);
- g_free(to);
- g_free(text);
-@@ -742,7 +742,7 @@ static void process_incoming_message(str
-
- if(!from) return;
-
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "got message from %s: %s\n", from, msg->body);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "got message from %s: %s\n", from, msg->body);
-
- contenttype = sipmsg_find_header(msg, "Content-Type");
- if(!contenttype || !strncmp(contenttype, "text/plain", 10) || !strncmp(contenttype, "text/html", 9)) {
-@@ -756,14 +756,14 @@ static void process_incoming_message(str
- gchar *statedata;
-
- if(!isc) {
-- gaim_debug_info("simple","process_incoming_message: can not parse iscomposing\n");
-+ gaim2_debug_info("simple","process_incoming_message: can not parse iscomposing\n");
- return;
- }
-
- state = xmlnode_get_child(isc, "state");
-
- if(!state) {
-- gaim_debug_info("simple","process_incoming_message: no state found\n");
-+ gaim2_debug_info("simple","process_incoming_message: no state found\n");
- return;
- }
-
-@@ -777,7 +777,7 @@ static void process_incoming_message(str
- found = TRUE;
- }
- if(!found) {
-- gaim_debug_info("simple", "got unknown mime-type");
-+ gaim2_debug_info("simple", "got unknown mime-type");
- send_sip_response(sip->gc, msg, 415, "Unsupported media type", NULL);
- }
- g_free(from);
-@@ -786,16 +786,16 @@ static void process_incoming_message(str
-
- gboolean process_register_response(struct simple_account_data *sip, struct sipmsg *msg, struct transaction *tc) {
- gchar *tmp;
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "in process register response response: %d\n", msg->response);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "in process register response response: %d\n", msg->response);
- switch (msg->response) {
- case 200:
- if(sip->registerstatus<3) { /* registered */
-- if(gaim_account_get_bool(sip->account, "dopublish", TRUE)) {
-+ if(gaim2_account_get_bool(sip->account, "dopublish", TRUE)) {
- send_publish(sip);
- }
- }
- sip->registerstatus=3;
-- gaim_connection_set_state(sip->gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(sip->gc, GAIM_CONNECTED);
-
- /* get buddies from blist */
- simple_get_buddies(sip->gc);
-@@ -804,9 +804,9 @@ gboolean process_register_response(struc
- break;
- case 401:
- if(sip->registerstatus!=2) {
-- gaim_debug_info("simple","REGISTER retries %d\n",sip->registrar.retries);
-+ gaim2_debug_info("simple","REGISTER retries %d\n",sip->registrar.retries);
- if(sip->registrar.retries>3) {
-- gaim_connection_error(sip->gc,"Wrong Password");
-+ gaim2_connection_error(sip->gc,"Wrong Password");
- return TRUE;
- }
- tmp = sipmsg_find_header(msg, "WWW-Authenticate");
-@@ -834,21 +834,21 @@ static void process_incoming_notify(stru
- pidf = xmlnode_from_str(msg->body, msg->bodylen);
-
- if(!pidf) {
-- gaim_debug_info("simple","process_incoming_notify: no parseable pidf\n");
-+ gaim2_debug_info("simple","process_incoming_notify: no parseable pidf\n");
- return;
- }
-
- basicstatus = xmlnode_get_child(xmlnode_get_child(xmlnode_get_child(pidf,"tuple"),"status"), "basic");
-
- if(!basicstatus) {
-- gaim_debug_info("simple","process_incoming_notify: no basic found\n");
-+ gaim2_debug_info("simple","process_incoming_notify: no basic found\n");
- return;
- }
-
- tmp2 = xmlnode_get_data(basicstatus);
-
- if(!tmp2) {
-- gaim_debug_info("simple","process_incoming_notify: no basic data found\n");
-+ gaim2_debug_info("simple","process_incoming_notify: no basic data found\n");
- return;
- }
-
-@@ -856,8 +856,8 @@ static void process_incoming_notify(stru
- isonline = TRUE;
- }
-
-- if(isonline) gaim_prpl_got_user_status(sip->account, from, "available", NULL);
-- else gaim_prpl_got_user_status(sip->account, from, "offline", NULL);
-+ if(isonline) gaim2_prpl_got_user_status(sip->account, from, "available", NULL);
-+ else gaim2_prpl_got_user_status(sip->account, from, "offline", NULL);
-
- xmlnode_free(pidf);
-
-@@ -865,7 +865,7 @@ static void process_incoming_notify(stru
- send_sip_response(sip->gc, msg, 200, "OK", NULL);
- }
-
--static int simple_typing(GaimConnection *gc, const char *name, int typing) {
-+static int simple_typing(Gaim2Connection *gc, const char *name, int typing) {
- struct simple_account_data *sip = gc->proto_data;
-
- gchar *xml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
-@@ -958,7 +958,7 @@ static void process_incoming_subscribe(s
- ourtag = gentag();
- }
- if(!watcher) { /* new subscription */
-- if(!gaim_privacy_check(sip->account, from)) {
-+ if(!gaim2_privacy_check(sip->account, from)) {
- send_sip_response(sip->gc, msg, 202, "Ok", NULL);
- goto privend;
- }
-@@ -976,7 +976,7 @@ static void process_incoming_subscribe(s
- sipmsg_remove_header(msg, "Contact");
- tmp = g_strdup_printf("<%s@%s>",sip->username, sip->servername);
- sipmsg_add_header(msg, "Contact", tmp);
-- gaim_debug_info("simple","got subscribe: name %s ourtag %s theirtag %s callid %s\n", watcher->name, watcher->dialog.ourtag, watcher->dialog.theirtag, watcher->dialog.callid);
-+ gaim2_debug_info("simple","got subscribe: name %s ourtag %s theirtag %s callid %s\n", watcher->name, watcher->dialog.ourtag, watcher->dialog.theirtag, watcher->dialog.callid);
- send_sip_response(sip->gc, msg, 200, "Ok", NULL);
- g_free(tmp);
- send_notify(sip, watcher);
-@@ -1030,7 +1030,7 @@ static void process_input_message(struct
- } else {
- if(msg->response == 100) {
- /* ignore provisional response */
-- gaim_debug_info("simple","got trying response\n");
-+ gaim2_debug_info("simple","got trying response\n");
- } else {
- sip->proxy.retries = 0;
- if(msg->response == 401) sip->registrar.retries++;
-@@ -1044,11 +1044,11 @@ static void process_input_message(struct
- }
- found = 1;
- } else {
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "received response to unknown transaction");
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "received response to unknown transaction");
- }
- }
- if(!found) {
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "received a unknown sip message with method %sand response %d\n",msg->method, msg->response);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "received a unknown sip message with method %sand response %d\n",msg->method, msg->response);
- }
- }
-
-@@ -1074,7 +1074,7 @@ static void process_input(struct simple_
- time_t currtime = time(NULL);
- cur += 2;
- cur[0] = '\0';
-- gaim_debug_info("simple","\n\nreceived - %s\n######\n%s\n#######\n\n",ctime(&currtime), conn->inbuf);
-+ gaim2_debug_info("simple","\n\nreceived - %s\n######\n%s\n#######\n\n",ctime(&currtime), conn->inbuf);
- msg = sipmsg_parse_header(conn->inbuf);
- cur[0] = '\r';
- cur += 2;
-@@ -1091,15 +1091,15 @@ static void process_input(struct simple_
- sipmsg_free(msg);
- return;
- }
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "in process response response: %d\n", msg->response);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "in process response response: %d\n", msg->response);
- process_input_message(sip,msg);
- } else {
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "received a incomplete sip msg: %s\n", conn->inbuf);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "received a incomplete sip msg: %s\n", conn->inbuf);
- }
- }
-
--static void simple_udp_process(gpointer data, gint source, GaimInputCondition con) {
-- GaimConnection *gc = data;
-+static void simple_udp_process(gpointer data, gint source, Gaim2InputCondition con) {
-+ Gaim2Connection *gc = data;
- struct simple_account_data *sip = gc->proto_data;
- struct sipmsg *msg;
- int len;
-@@ -1108,19 +1108,19 @@ static void simple_udp_process(gpointer
- static char buffer[65536];
- len = recv(source, buffer, 65536, 0);
- buffer[len] = 0;
-- gaim_debug_info("simple","\n\nreceived - %s\n######\n%s\n#######\n\n",ctime(&currtime), buffer);
-+ gaim2_debug_info("simple","\n\nreceived - %s\n######\n%s\n#######\n\n",ctime(&currtime), buffer);
- msg = sipmsg_parse_msg(buffer);
- if(msg) process_input_message(sip, msg);
- }
-
--static void simple_input_cb(gpointer data, gint source, GaimInputCondition cond)
-+static void simple_input_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct simple_account_data *sip = gc->proto_data;
- int len;
- struct sip_connection *conn = connection_find(sip, source);
- if(!conn) {
-- gaim_debug_error("simple", "Connection not found!\n");
-+ gaim2_debug_error("simple", "Connection not found!\n");
- return;
- }
-
-@@ -1130,7 +1130,7 @@ static void simple_input_cb(gpointer dat
- }
-
- if ((len = read(source, conn->inbuf + conn->inbufused, SIMPLE_BUF_INC - 1)) <= 0) {
-- gaim_debug_info("simple","simple_input_cb: read error\n");
-+ gaim2_debug_info("simple","simple_input_cb: read error\n");
- connection_remove(sip, source);
- if(sip->fd == source) sip->fd = -1;
- return;
-@@ -1148,8 +1148,8 @@ static void simple_input_cb(gpointer dat
- }
-
- /* Callback for new connections on incoming TCP port */
--static void simple_newconn_cb(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void simple_newconn_cb(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- struct simple_account_data *sip = gc->proto_data;
- struct sip_connection *conn;
-
-@@ -1157,16 +1157,16 @@ static void simple_newconn_cb(gpointer d
-
- conn = connection_create(sip, newfd);
-
-- conn->inputhandler = gaim_input_add(newfd, GAIM_INPUT_READ, simple_input_cb, gc);
-+ conn->inputhandler = gaim2_input_add(newfd, GAIM_INPUT_READ, simple_input_cb, gc);
- }
-
--static void login_cb(gpointer data, gint source, GaimInputCondition cond) {
-- GaimConnection *gc = data;
-+static void login_cb(gpointer data, gint source, Gaim2InputCondition cond) {
-+ Gaim2Connection *gc = data;
- struct simple_account_data *sip = gc->proto_data;
- struct sip_connection *conn;
-
- if( source < 0 ) {
-- gaim_connection_error(gc,"Could not connect");
-+ gaim2_connection_error(gc,"Could not connect");
- return;
- }
-
-@@ -1175,11 +1175,11 @@ static void login_cb(gpointer data, gint
- conn = connection_create(sip, source);
-
- /* get the local ip */
-- sip->ip = g_strdup(gaim_network_get_my_ip(source));
-+ sip->ip = g_strdup(gaim2_network_get_my_ip(source));
-
- do_register(sip);
-
-- conn->inputhandler = gaim_input_add(sip->fd, GAIM_INPUT_READ, simple_input_cb, gc);
-+ conn->inputhandler = gaim2_input_add(sip->fd, GAIM_INPUT_READ, simple_input_cb, gc);
- }
-
- static guint simple_ht_hash_nick(const char *nick) {
-@@ -1191,14 +1191,14 @@ static guint simple_ht_hash_nick(const c
- }
-
- static gboolean simple_ht_equals_nick(const char *nick1, const char *nick2) {
-- return (gaim_utf8_strcasecmp(nick1, nick2) == 0);
-+ return (gaim2_utf8_strcasecmp(nick1, nick2) == 0);
- }
-
--static void srvresolved(GaimSrvResponse *resp, int results, gpointer data) {
-+static void srvresolved(Gaim2SrvResponse *resp, int results, gpointer data) {
- struct simple_account_data *sip = (struct simple_account_data*) data;
-
- gchar *hostname;
-- int port = gaim_account_get_int(sip->account, "port", 0);
-+ int port = gaim2_account_get_int(sip->account, "port", 0);
-
- int error = 0;
- struct hostent *h;
-@@ -1211,10 +1211,10 @@ static void srvresolved(GaimSrvResponse
- port = resp->port;
- g_free(resp);
- } else {
-- if(!gaim_account_get_bool(sip->account, "useproxy", FALSE)) {
-+ if(!gaim2_account_get_bool(sip->account, "useproxy", FALSE)) {
- hostname = g_strdup(sip->servername);
- } else {
-- hostname = g_strdup(gaim_account_get_string(sip->account, "proxy", sip->servername));
-+ hostname = g_strdup(gaim2_account_get_string(sip->account, "proxy", sip->servername));
- }
- }
-
-@@ -1223,105 +1223,105 @@ static void srvresolved(GaimSrvResponse
- /* TCP case */
- if(! sip->udp) {
- /* create socket for incoming connections */
-- sip->listenfd = gaim_network_listen_range(5060, 5160, SOCK_STREAM);
-+ sip->listenfd = gaim2_network_listen_range(5060, 5160, SOCK_STREAM);
- if(sip->listenfd == -1) {
-- gaim_connection_error(sip->gc, _("Could not create listen socket"));
-+ gaim2_connection_error(sip->gc, _("Could not create listen socket"));
- return;
- }
-- gaim_debug_info("simple", "listenfd: %d\n", sip->listenfd);
-- sip->listenport = gaim_network_get_port_from_fd(sip->listenfd);
-- sip->listenpa = gaim_input_add(sip->listenfd, GAIM_INPUT_READ, simple_newconn_cb, sip->gc);
-- gaim_debug_info("simple","connecting to %s port %d\n", hostname, port);
-+ gaim2_debug_info("simple", "listenfd: %d\n", sip->listenfd);
-+ sip->listenport = gaim2_network_get_port_from_fd(sip->listenfd);
-+ sip->listenpa = gaim2_input_add(sip->listenfd, GAIM_INPUT_READ, simple_newconn_cb, sip->gc);
-+ gaim2_debug_info("simple","connecting to %s port %d\n", hostname, port);
- /* open tcp connection to the server */
-- error = gaim_proxy_connect(sip->account, hostname, port, login_cb, sip->gc);
-+ error = gaim2_proxy_connect(sip->account, hostname, port, login_cb, sip->gc);
- if(error) {
-- gaim_connection_error(sip->gc, _("Couldn't create socket"));
-+ gaim2_connection_error(sip->gc, _("Couldn't create socket"));
- }
-
- } else { /* UDP */
-- gaim_debug_info("simple", "using udp with server %s and port %d\n", hostname, port);
-+ gaim2_debug_info("simple", "using udp with server %s and port %d\n", hostname, port);
-
- /** TODO: this should probably be async, right? */
- if (!(h = gethostbyname(hostname))) {
-- gaim_connection_error(sip->gc, _("Couldn't resolve host"));
-+ gaim2_connection_error(sip->gc, _("Couldn't resolve host"));
- return;
- }
-
- /* create socket for incoming connections */
-- sip->fd = gaim_network_listen_range(5060, 5160, SOCK_DGRAM);
-+ sip->fd = gaim2_network_listen_range(5060, 5160, SOCK_DGRAM);
-
- if(sip->fd == -1) {
-- gaim_connection_error(sip->gc, _("Could not create listen socket"));
-+ gaim2_connection_error(sip->gc, _("Could not create listen socket"));
- return;
- }
-
- sip->listenfd = sip->fd;
-
-- sip->listenpa = gaim_input_add(sip->fd, GAIM_INPUT_READ, simple_udp_process, sip->gc);
-+ sip->listenpa = gaim2_input_add(sip->fd, GAIM_INPUT_READ, simple_udp_process, sip->gc);
- sip->serveraddr.sin_family = AF_INET;
- sip->serveraddr.sin_port = htons(port);
-
- sip->serveraddr.sin_addr.s_addr = ((struct in_addr*)h->h_addr)->s_addr;
-- sip->ip = g_strdup(gaim_network_get_my_ip(sip->listenfd));
-- sip->resendtimeout = gaim_timeout_add(2500, (GSourceFunc)resend_timeout, sip);
-+ sip->ip = g_strdup(gaim2_network_get_my_ip(sip->listenfd));
-+ sip->resendtimeout = gaim2_timeout_add(2500, (GSourceFunc)resend_timeout, sip);
- do_register(sip);
- }
- }
-
--static void simple_login(GaimAccount *account)
-+static void simple_login(Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- struct simple_account_data *sip;
- gchar **userserver;
- gchar *hosttoconnect;
-
-- const char *username = gaim_account_get_username(account);
-+ const char *username = gaim2_account_get_username(account);
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- gc->proto_data = sip = g_new0(struct simple_account_data,1);
- sip->gc=gc;
- sip->account = account;
- sip->registerexpire = 900;
-- sip->udp = gaim_account_get_bool(account, "udp", FALSE);
-+ sip->udp = gaim2_account_get_bool(account, "udp", FALSE);
- if (strpbrk(username, " \t\v\r\n") != NULL) {
-- gaim_connection_error(gc, _("SIP usernames may not contain whitespaces or @ symbols"));
-+ gaim2_connection_error(gc, _("SIP usernames may not contain whitespaces or @ symbols"));
- return;
- }
-
- userserver = g_strsplit(username, "@", 2);
-- gaim_connection_set_display_name(gc,userserver[0]);
-+ gaim2_connection_set_display_name(gc,userserver[0]);
- sip->username = g_strdup(userserver[0]);
- sip->servername = g_strdup(userserver[1]);
-- sip->password = g_strdup(gaim_connection_get_password(gc));
-+ sip->password = g_strdup(gaim2_connection_get_password(gc));
- g_strfreev(userserver);
-
- sip->buddies = g_hash_table_new((GHashFunc)simple_ht_hash_nick, (GEqualFunc)simple_ht_equals_nick);
-
-- gaim_connection_update_progress(gc, _("Connecting"), 1, 2);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 1, 2);
-
- /* TODO: Set the status correctly. */
- sip->status = g_strdup("available");
-
-- if(!gaim_account_get_bool(account, "useproxy", FALSE)) {
-+ if(!gaim2_account_get_bool(account, "useproxy", FALSE)) {
- hosttoconnect = g_strdup(sip->servername);
- } else {
-- hosttoconnect = g_strdup(gaim_account_get_string(account, "proxy", sip->servername));
-+ hosttoconnect = g_strdup(gaim2_account_get_string(account, "proxy", sip->servername));
- }
-
- /* TCP case */
- if(! sip->udp) {
-- gaim_srv_resolve("sip","tcp",hosttoconnect,srvresolved, sip);
-+ gaim2_srv_resolve("sip","tcp",hosttoconnect,srvresolved, sip);
- } else { /* UDP */
-- gaim_srv_resolve("sip","udp",hosttoconnect,srvresolved, sip);
-+ gaim2_srv_resolve("sip","udp",hosttoconnect,srvresolved, sip);
- }
- g_free(hosttoconnect);
-
- /* register timeout callback for register / subscribe renewal */
-- /* TODO: What if the timeout is called before gaim_srv_resolve() finishes?! */
-- sip->registertimeout = gaim_timeout_add((rand()%100)+10*1000, (GSourceFunc)register_timeout, sip);
-+ /* TODO: What if the timeout is called before gaim2_srv_resolve() finishes?! */
-+ sip->registertimeout = gaim2_timeout_add((rand()%100)+10*1000, (GSourceFunc)register_timeout, sip);
- }
-
--static void simple_close(GaimConnection *gc)
-+static void simple_close(Gaim2Connection *gc)
- {
- struct simple_account_data *sip = gc->proto_data;
-
-@@ -1339,9 +1339,9 @@ static void simple_close(GaimConnection
- g_free(sip->sendlater);
- g_free(sip->ip);
- g_free(sip->realhostname);
-- if(sip->listenpa) gaim_input_remove(sip->listenpa);
-- if(sip->resendtimeout) gaim_timeout_remove(sip->resendtimeout);
-- if(sip->registertimeout) gaim_timeout_remove(sip->registertimeout);
-+ if(sip->listenpa) gaim2_input_remove(sip->listenpa);
-+ if(sip->resendtimeout) gaim2_timeout_remove(sip->resendtimeout);
-+ if(sip->registertimeout) gaim2_timeout_remove(sip->registertimeout);
- sip->servername = sip->username = sip->password = sip->registrar.nonce = sip->registrar.realm = sip->proxy.nonce = sip->proxy.realm = sip->sendlater = sip->ip = sip->realhostname = NULL;
- }
- g_free(gc->proto_data);
-@@ -1349,13 +1349,13 @@ static void simple_close(GaimConnection
- }
-
- /* not needed since privacy is checked for every subscribe */
--static void dummy_add_deny(GaimConnection *gc, const char *name) {
-+static void dummy_add_deny(Gaim2Connection *gc, const char *name) {
- }
-
--static void dummy_permit_deny(GaimConnection *gc) {
-+static void dummy_permit_deny(Gaim2Connection *gc) {
- }
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- 0,
- NULL, /* user_splits */
-@@ -1421,7 +1421,7 @@ static GaimPluginProtocolInfo prpl_info
- };
-
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -1450,26 +1450,26 @@ static GaimPluginInfo info =
- NULL
- };
-
--static void _init_plugin(GaimPlugin *plugin)
-+static void _init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountUserSplit *split;
-- GaimAccountOption *option;
-+ Gaim2AccountUserSplit *split;
-+ Gaim2AccountOption *option;
-
-- split = gaim_account_user_split_new(_("Server"), "", '@');
-+ split = gaim2_account_user_split_new(_("Server"), "", '@');
- prpl_info.user_splits = g_list_append(prpl_info.user_splits, split);
-
-- option = gaim_account_option_bool_new(_("Publish status (note: everyone may watch you)"), "dopublish", TRUE);
-+ option = gaim2_account_option_bool_new(_("Publish status (note: everyone may watch you)"), "dopublish", TRUE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_int_new(_("Connect port"), "port", 5060);
-+ option = gaim2_account_option_int_new(_("Connect port"), "port", 5060);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-
-- option = gaim_account_option_bool_new(_("Use UDP"), "udp", FALSE);
-+ option = gaim2_account_option_bool_new(_("Use UDP"), "udp", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_bool_new(_("Use proxy"), "useproxy", FALSE);
-+ option = gaim2_account_option_bool_new(_("Use proxy"), "useproxy", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-- option = gaim_account_option_string_new(_("Proxy"), "proxy", "");
-+ option = gaim2_account_option_string_new(_("Proxy"), "proxy", "");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
- }
-
-diff -prNu ./src/protocols/simple/simple.h ./src/protocols/simple/simple.h
---- ./src/protocols/simple/simple.h 2005-12-07 05:50:36.000000000 +0100
-+++ ./src/protocols/simple/simple.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file simple.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005, Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -61,7 +61,7 @@ struct sip_auth {
- };
-
- struct simple_account_data {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- gchar *servername;
- gchar *username;
- gchar *password;
-@@ -81,7 +81,7 @@ struct simple_account_data {
- guint registertimeout;
- guint resendtimeout;
- int connecting;
-- GaimAccount *account;
-+ Gaim2Account *account;
- gchar *sendlater;
- gchar *regcallid;
- GSList *transactions;
-diff -prNu ./src/protocols/simple/sipmsg.c ./src/protocols/simple/sipmsg.c
---- ./src/protocols/simple/sipmsg.c 2005-10-25 22:50:21.000000000 +0200
-+++ ./src/protocols/simple/sipmsg.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file sipmsg.c
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005 Thomas Butter <butter@uni-mannheim.de>
- *
-@@ -113,13 +113,13 @@ struct sipmsg *sipmsg_parse_header(gchar
- void sipmsg_print(struct sipmsg *msg) {
- GSList *cur;
- struct siphdrelement *elem;
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "SIP MSG\n");
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "response: %d\nmethod: %s\nbodylen: %d\n",msg->response,msg->method,msg->bodylen);
-- if(msg->target) gaim_debug(GAIM_DEBUG_MISC, "simple", "target: %s\n",msg->target);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "SIP MSG\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "response: %d\nmethod: %s\nbodylen: %d\n",msg->response,msg->method,msg->bodylen);
-+ if(msg->target) gaim2_debug(GAIM_DEBUG_MISC, "simple", "target: %s\n",msg->target);
- cur = msg->headers;
- while(cur) {
- elem = cur->data;
-- gaim_debug(GAIM_DEBUG_MISC, "simple", "name: %s value: %s\n",elem->name, elem->value);
-+ gaim2_debug(GAIM_DEBUG_MISC, "simple", "name: %s value: %s\n",elem->name, elem->value);
- cur = g_slist_next(cur);
- }
- }
-diff -prNu ./src/protocols/simple/sipmsg.h ./src/protocols/simple/sipmsg.h
---- ./src/protocols/simple/sipmsg.h 2005-10-26 02:34:26.000000000 +0200
-+++ ./src/protocols/simple/sipmsg.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /**
- * @file sipmsg.h
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2005, Thomas Butter <butter@uni-mannheim.de>
- *
-diff -prNu ./src/protocols/toc/Makefile.am ./src/protocols/toc/Makefile.am
---- ./src/protocols/toc/Makefile.am 2004-01-12 06:47:57.000000000 +0100
-+++ ./src/protocols/toc/Makefile.am 2006-01-05 13:05:19.000000000 +0100
-@@ -2,7 +2,7 @@ EXTRA_DIST = \
- PROTOCOL \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- TOCSOURCES = toc.c
-
-diff -prNu ./src/protocols/toc/toc.c ./src/protocols/toc/toc.c
---- ./src/protocols/toc/toc.c 2005-12-24 21:10:25.000000000 +0100
-+++ ./src/protocols/toc/toc.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 1998-1999, Mark Spencer <markster@marko.net>
- *
-@@ -32,7 +32,7 @@
- #include "util.h"
- #include "version.h"
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
- #define REVISION "penguin"
-
-@@ -73,7 +73,7 @@ static GaimPlugin *my_protocol = NULL;
- #define UC_WIRELESS 0x20
-
- struct ft_request {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *user;
- char UID[2048];
- char *cookie;
-@@ -119,48 +119,48 @@ struct signon {
-
- #define TOC_CONNECT_STEPS 3
-
--static void toc_login_callback(gpointer, gint, GaimInputCondition);
--static void toc_callback(gpointer, gint, GaimInputCondition);
-+static void toc_login_callback(gpointer, gint, Gaim2InputCondition);
-+static void toc_callback(gpointer, gint, Gaim2InputCondition);
-
- /* ok. this function used to take username/password, and return 0 on success.
-- * now, it takes username/password, and returns NULL on error or a new gaim_connection
-+ * now, it takes username/password, and returns NULL on error or a new gaim2_connection
- * on success. */
--static void toc_login(GaimAccount *account)
-+static void toc_login(Gaim2Account *account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- struct toc_data *tdt;
- char buf[80];
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
- gc->proto_data = tdt = g_new0(struct toc_data, 1);
- gc->flags |= GAIM_CONNECTION_HTML;
- gc->flags |= GAIM_CONNECTION_AUTO_RESP;
-
- g_snprintf(buf, sizeof buf, _("Looking up %s"),
-- gaim_account_get_string(account, "server", TOC_HOST));
-- gaim_connection_update_progress(gc, buf, 0, TOC_CONNECT_STEPS);
-+ gaim2_account_get_string(account, "server", TOC_HOST));
-+ gaim2_connection_update_progress(gc, buf, 0, TOC_CONNECT_STEPS);
-
-- gaim_debug(GAIM_DEBUG_INFO, "toc", "Client connects to TOC\n");
-- if (gaim_proxy_connect(account,
-- gaim_account_get_string(account, "server", TOC_HOST),
-- gaim_account_get_int(account, "port", TOC_PORT),
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc", "Client connects to TOC\n");
-+ if (gaim2_proxy_connect(account,
-+ gaim2_account_get_string(account, "server", TOC_HOST),
-+ gaim2_account_get_int(account, "port", TOC_PORT),
- toc_login_callback, gc) != 0 || !account->gc) {
- g_snprintf(buf, sizeof(buf), _("Connect to %s failed"),
-- gaim_account_get_string(account, "server", TOC_HOST));
-- gaim_connection_error(gc, buf);
-+ gaim2_account_get_string(account, "server", TOC_HOST));
-+ gaim2_connection_error(gc, buf);
- return;
- }
- }
-
--static void toc_login_callback(gpointer data, gint source, GaimInputCondition cond)
-+static void toc_login_callback(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct toc_data *tdt;
- char buf[80];
- struct sockaddr_in name;
- socklen_t namelen;
-
-- if (!g_list_find(gaim_connections_get_all(), data)) {
-+ if (!g_list_find(gaim2_connections_get_all(), data)) {
- close(source);
- return;
- }
-@@ -169,7 +169,7 @@ static void toc_login_callback(gpointer
-
- if (source == -1) {
- /* we didn't successfully connect. tdt->toc_fd is valid here */
-- gaim_connection_error(gc, _("Unable to connect."));
-+ gaim2_connection_error(gc, _("Unable to connect."));
- return;
- }
- tdt->toc_fd = source;
-@@ -182,39 +182,39 @@ static void toc_login_callback(gpointer
- if (getpeername(tdt->toc_fd, (struct sockaddr *)&name, &namelen) == 0)
- strncpy(tdt->toc_ip, inet_ntoa(name.sin_addr), sizeof(tdt->toc_ip));
- else
-- strncpy(tdt->toc_ip, gaim_account_get_string(gc->account, "server", TOC_HOST), sizeof(tdt->toc_ip));
-+ strncpy(tdt->toc_ip, gaim2_account_get_string(gc->account, "server", TOC_HOST), sizeof(tdt->toc_ip));
-
-- gaim_debug(GAIM_DEBUG_INFO, "toc",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc",
- "Client sends \"FLAPON\\r\\n\\r\\n\"\n");
- if (write(tdt->toc_fd, FLAPON, strlen(FLAPON)) < 0) {
-- gaim_connection_error(gc, _("Disconnected."));
-+ gaim2_connection_error(gc, _("Disconnected."));
- return;
- }
- tdt->state = STATE_FLAPON;
-
-- /* i know a lot of people like to look at gaim to see how TOC works. so i'll comment
-+ /* i know a lot of people like to look at gaim2 to see how TOC works. so i'll comment
- * on what this does. it's really simple. when there's data ready to be read from the
- * toc_fd file descriptor, toc_callback is called, with gc passed as its data arg. */
-- gc->inpa = gaim_input_add(tdt->toc_fd, GAIM_INPUT_READ, toc_callback, gc);
-+ gc->inpa = gaim2_input_add(tdt->toc_fd, GAIM_INPUT_READ, toc_callback, gc);
-
-- g_snprintf(buf, sizeof(buf), _("Signon: %s"), gaim_account_get_username(gc->account));
-- gaim_connection_update_progress(gc, buf, 1, TOC_CONNECT_STEPS);
-+ g_snprintf(buf, sizeof(buf), _("Signon: %s"), gaim2_account_get_username(gc->account));
-+ gaim2_connection_update_progress(gc, buf, 1, TOC_CONNECT_STEPS);
- }
-
--static void toc_close(GaimConnection *gc)
-+static void toc_close(Gaim2Connection *gc)
- {
- if (gc->inpa > 0)
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
- gc->inpa = 0;
- close(((struct toc_data *)gc->proto_data)->toc_fd);
- g_free(gc->proto_data);
- }
-
--static void toc_build_config(GaimAccount *account, char *s, int len, gboolean show)
-+static void toc_build_config(Gaim2Account *account, char *s, int len, gboolean show)
- {
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimGroup *g;
-- GaimBuddy *b;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Group *g;
-+ Gaim2Buddy *b;
- GSList *plist = account->permit;
- GSList *dlist = account->deny;
-
-@@ -224,17 +224,17 @@ static void toc_build_config(GaimAccount
- account->perm_deny = 1;
-
- pos += g_snprintf(&s[pos], len - pos, "m %d\n", account->perm_deny);
-- for(gnode = gaim_get_blist()->root; gnode && len > pos; gnode = gnode->next) {
-- g = (GaimGroup *)gnode;
-+ for(gnode = gaim2_get_blist()->root; gnode && len > pos; gnode = gnode->next) {
-+ g = (Gaim2Group *)gnode;
- if(!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
-- if(gaim_group_on_account(g, account)) {
-+ if(gaim2_group_on_account(g, account)) {
- pos += g_snprintf(&s[pos], len - pos, "g %s\n", g->name);
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
- if(!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for(bnode = gnode->child; bnode && len > pos; bnode = bnode->next) {
-- b = (GaimBuddy *)bnode;
-+ b = (Gaim2Buddy *)bnode;
- if(!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
- if(b->account == account) {
-@@ -352,7 +352,7 @@ char *escape_text(const char *msg)
- return ret;
- }
-
--static int sflap_send(GaimConnection *gc, const char *buf, int olen, int type)
-+static int sflap_send(Gaim2Connection *gc, const char *buf, int olen, int type)
- {
- struct toc_data *tdt = (struct toc_data *)gc->proto_data;
- int len;
-@@ -381,13 +381,13 @@ static int sflap_send(GaimConnection *gc
- * but this'll stop a segfault.
- */
- if (len > MSG_LEN) {
-- gaim_debug(GAIM_DEBUG_WARNING, "toc", "message too long, truncating\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "toc", "message too long, truncating\n");
- escaped[MSG_LEN - 1] = '\0';
- len = MSG_LEN;
- }
-
- if (olen < 0)
-- gaim_debug(GAIM_DEBUG_INFO, "toc", "C: %s\n", escaped);
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc", "C: %s\n", escaped);
-
- hdr.ast = '*';
- hdr.type = type;
-@@ -413,14 +413,14 @@ static int sflap_send(GaimConnection *gc
- return ret;
- }
-
--static int wait_reply(GaimConnection *gc, char *buffer, size_t buflen)
-+static int wait_reply(Gaim2Connection *gc, char *buffer, size_t buflen)
- {
- struct toc_data *tdt = (struct toc_data *)gc->proto_data;
- struct sflap_hdr *hdr;
- int ret;
-
- if (read(tdt->toc_fd, buffer, sizeof(struct sflap_hdr)) < 0) {
-- gaim_debug(GAIM_DEBUG_ERROR, "toc", "Couldn't read flap header\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc", "Couldn't read flap header\n");
- return -1;
- }
-
-@@ -428,7 +428,7 @@ static int wait_reply(GaimConnection *gc
-
- if (buflen < ntohs(hdr->len)) {
- /* fake like there's a read error */
-- gaim_debug(GAIM_DEBUG_ERROR, "toc",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc",
- "buffer too small (have %d, need %d)\n",
- buflen, ntohs(hdr->len));
- return -1;
-@@ -467,7 +467,7 @@ static void toc_got_info(void *data, con
- if (!url_text)
- return;
-
-- gaim_notify_formatted(data, NULL, _("Buddy Information"), NULL,
-+ gaim2_notify_formatted(data, NULL, _("Buddy Information"), NULL,
- url_text, NULL, NULL);
- }
-
-@@ -561,7 +561,7 @@ static char *show_error_message()
- }
-
- static void
--parse_toc_buddy_list(GaimAccount *account, char *config)
-+parse_toc_buddy_list(Gaim2Account *account, char *config)
- {
- char *c;
- char current[256];
-@@ -579,18 +579,18 @@ parse_toc_buddy_list(GaimAccount *accoun
- break;
- if (*c == 'g') {
- char *utf8 = NULL;
-- utf8 = gaim_utf8_try_convert(c + 2);
-+ utf8 = gaim2_utf8_try_convert(c + 2);
- if (utf8 == NULL) {
- g_strlcpy(current, _("Invalid Groupname"), sizeof(current));
- } else {
- g_strlcpy(current, utf8, sizeof(current));
- g_free(utf8);
- }
-- if (!gaim_find_group(current)) {
-- GaimGroup *g = gaim_group_new(current);
-- gaim_blist_add_group(g, NULL);
-+ if (!gaim2_find_group(current)) {
-+ Gaim2Group *g = gaim2_group_new(current);
-+ gaim2_blist_add_group(g, NULL);
- }
-- } else if (*c == 'b') { /*&& !gaim_find_buddy(user, c + 2)) {*/
-+ } else if (*c == 'b') { /*&& !gaim2_find_buddy(user, c + 2)) {*/
- char nm[80], sw[388], *a, *utf8 = NULL;
-
- if ((a = strchr(c + 2, ':')) != NULL) {
-@@ -599,9 +599,9 @@ parse_toc_buddy_list(GaimAccount *accoun
-
- g_strlcpy(nm, c + 2, sizeof(nm));
- if (a) {
-- utf8 = gaim_utf8_try_convert(a);
-+ utf8 = gaim2_utf8_try_convert(a);
- if (utf8 == NULL) {
-- gaim_debug(GAIM_DEBUG_ERROR, "toc blist",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc blist",
- "Failed to convert alias for "
- "'%s' to UTF-8\n", nm);
- }
-@@ -615,25 +615,25 @@ parse_toc_buddy_list(GaimAccount *accoun
- g_free(utf8);
- }
-
-- if (!gaim_find_buddy(account, nm)) {
-- GaimBuddy *b = gaim_buddy_new(account, nm, sw);
-- GaimGroup *g = gaim_find_group(current);
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ if (!gaim2_find_buddy(account, nm)) {
-+ Gaim2Buddy *b = gaim2_buddy_new(account, nm, sw);
-+ Gaim2Group *g = gaim2_find_group(current);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- buddies = g_list_append(buddies, b);
- }
- } else if (*c == 'p') {
-- gaim_privacy_permit_add(account, c + 2, TRUE);
-+ gaim2_privacy_permit_add(account, c + 2, TRUE);
- } else if (*c == 'd') {
-- gaim_privacy_deny_add(account, c + 2, TRUE);
-+ gaim2_privacy_deny_add(account, c + 2, TRUE);
- } else if (!strncmp("toc", c, 3)) {
- sscanf(c + strlen(c) - 1, "%d", &account->perm_deny);
-- gaim_debug(GAIM_DEBUG_MISC, "toc blist",
-+ gaim2_debug(GAIM_DEBUG_MISC, "toc blist",
- "permdeny: %d\n", account->perm_deny);
- if (account->perm_deny == 0)
- account->perm_deny = GAIM_PRIVACY_ALLOW_ALL;
- } else if (*c == 'm') {
- sscanf(c + 2, "%d", &account->perm_deny);
-- gaim_debug(GAIM_DEBUG_MISC, "toc blist",
-+ gaim2_debug(GAIM_DEBUG_MISC, "toc blist",
- "permdeny: %d\n", account->perm_deny);
- if (account->perm_deny == 0)
- account->perm_deny = GAIM_PRIVACY_ALLOW_ALL;
-@@ -642,7 +642,7 @@ parse_toc_buddy_list(GaimAccount *accoun
-
- if (account->gc) {
- if (buddies != NULL) {
-- gaim_account_add_buddies(account, buddies);
-+ gaim2_account_add_buddies(account, buddies);
- g_list_free(buddies);
- }
- serv_set_permit_deny(account->gc);
-@@ -650,80 +650,80 @@ parse_toc_buddy_list(GaimAccount *accoun
- g_list_free(buddies);
- }
-
--static void toc_callback(gpointer data, gint source, GaimInputCondition condition)
-+static void toc_callback(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimConnection *gc = (GaimConnection *)data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = (Gaim2Connection *)data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct toc_data *tdt = (struct toc_data *)gc->proto_data;
- struct sflap_hdr *hdr;
- struct signon so;
- char buf[8 * 1024], *c;
- char snd[BUF_LEN * 2];
-- const char *username = gaim_account_get_username(account);
-+ const char *username = gaim2_account_get_username(account);
- char *password;
-- GaimBuddy *buddy;
-+ Gaim2Buddy *buddy;
-
- /* there's data waiting to be read, so read it. */
- if (wait_reply(gc, buf, 8 * 1024) <= 0) {
-- gaim_connection_error(gc, _("Connection Closed"));
-+ gaim2_connection_error(gc, _("Connection Closed"));
- return;
- }
-
- if (tdt->state == STATE_FLAPON) {
- hdr = (struct sflap_hdr *)buf;
- if (hdr->type != TYPE_SIGNON)
-- gaim_debug(GAIM_DEBUG_ERROR, "toc", "hdr->type != TYPE_SIGNON\n");
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc", "hdr->type != TYPE_SIGNON\n");
- else
-- gaim_debug(GAIM_DEBUG_INFO, "toc",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc",
- "TOC sends Client FLAP SIGNON\n");
- tdt->seqno = ntohs(hdr->seqno);
- tdt->state = STATE_SIGNON_REQUEST;
-
-- gaim_debug(GAIM_DEBUG_INFO, "toc", "Client sends TOC FLAP SIGNON\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc", "Client sends TOC FLAP SIGNON\n");
- g_snprintf(so.username, sizeof(so.username), "%s", username);
- so.ver = htonl(1);
- so.tag = htons(1);
- so.namelen = htons(strlen(so.username));
- if (sflap_send(gc, (char *)&so, ntohs(so.namelen) + 8, TYPE_SIGNON) < 0) {
-- gaim_connection_error(gc, _("Disconnected."));
-+ gaim2_connection_error(gc, _("Disconnected."));
- return;
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "toc",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc",
- "Client sends TOC \"toc_signon\" message\n");
- /* i hate icq. */
- if (username[0] >= '0' && username[0] <= '9')
-- password = g_strndup(gaim_connection_get_password(gc), 8);
-+ password = g_strndup(gaim2_connection_get_password(gc), 8);
- else
-- password = g_strdup(gaim_connection_get_password(gc));
-+ password = g_strdup(gaim2_connection_get_password(gc));
- g_snprintf(snd, sizeof snd, "toc_signon %s %d %s %s %s \"%s\"",
-- AUTH_HOST, AUTH_PORT, gaim_normalize(account, username),
-+ AUTH_HOST, AUTH_PORT, gaim2_normalize(account, username),
- roast_password(password), LANGUAGE, REVISION);
- g_free(password);
- if (sflap_send(gc, snd, -1, TYPE_DATA) < 0) {
-- gaim_connection_error(gc, _("Disconnected."));
-+ gaim2_connection_error(gc, _("Disconnected."));
- return;
- }
-
-- gaim_connection_update_progress(gc, _("Waiting for reply..."), 2, TOC_CONNECT_STEPS);
-+ gaim2_connection_update_progress(gc, _("Waiting for reply..."), 2, TOC_CONNECT_STEPS);
- return;
- }
-
- if (tdt->state == STATE_SIGNON_REQUEST) {
-- gaim_debug(GAIM_DEBUG_INFO, "toc", "TOC sends client SIGN_ON reply\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc", "TOC sends client SIGN_ON reply\n");
- if (g_ascii_strncasecmp(buf + sizeof(struct sflap_hdr), "SIGN_ON", strlen("SIGN_ON"))) {
-- gaim_debug(GAIM_DEBUG_ERROR, "toc",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc",
- "Didn't get SIGN_ON! buf was: %s\n",
- buf + sizeof(struct sflap_hdr));
- if (!g_ascii_strncasecmp(buf + sizeof(struct sflap_hdr), "ERROR", 5)) {
- strtok(buf + sizeof(struct sflap_hdr), ":");
-- gaim_connection_error(gc, show_error_message());
-+ gaim2_connection_error(gc, show_error_message());
- } else
-- gaim_connection_error(gc, _("Authentication failed"));
-+ gaim2_connection_error(gc, _("Authentication failed"));
- return;
- }
- /* we're supposed to check that it's really TOC v1 here but we know it is ;) */
-- gaim_debug(GAIM_DEBUG_INFO, "toc",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc",
- "TOC version: %s\n", buf + sizeof(struct sflap_hdr) + 8);
-
- /* we used to check for the CONFIG here, but we'll wait until we've sent our
-@@ -732,19 +732,19 @@ static void toc_callback(gpointer data,
-
- tdt->state = STATE_ONLINE;
-
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- /*
- * Add me to my buddy list so that we know the time when
- * the server thinks I signed on.
- */
-- buddy = gaim_buddy_new(account, username, NULL);
-+ buddy = gaim2_buddy_new(account, username, NULL);
- /* XXX - Pick a group to add to */
-- /* gaim_blist_add(buddy, NULL, g, NULL); */
-- gaim_account_add_buddy(gc, buddy);
-+ /* gaim2_blist_add(buddy, NULL, g, NULL); */
-+ gaim2_account_add_buddy(gc, buddy);
-
- /* Client sends TOC toc_init_done message */
-- gaim_debug(GAIM_DEBUG_INFO, "toc",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc",
- "Client sends TOC toc_init_done message\n");
- g_snprintf(snd, sizeof snd, "toc_init_done");
- sflap_send(gc, snd, -1, TYPE_DATA);
-@@ -759,7 +759,7 @@ static void toc_callback(gpointer data,
- return;
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "toc", "S: %s\n",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc", "S: %s\n",
- buf + sizeof(struct sflap_hdr));
-
- c = strtok(buf + sizeof(struct sflap_hdr), ":"); /* Ditch the first part */
-@@ -767,22 +767,22 @@ static void toc_callback(gpointer data,
- if (!g_ascii_strcasecmp(c, "SIGN_ON")) {
- /* we should only get here after a PAUSE */
- if (tdt->state != STATE_PAUSE)
-- gaim_debug(GAIM_DEBUG_ERROR, "toc",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc",
- "got SIGN_ON but not PAUSE!\n");
- else {
- tdt->state = STATE_ONLINE;
- g_snprintf(snd, sizeof snd, "toc_signon %s %d %s %s %s \"%s\"",
- AUTH_HOST, AUTH_PORT,
-- gaim_normalize(account, gaim_account_get_username(account)),
-- roast_password(gaim_connection_get_password(gc)),
-+ gaim2_normalize(account, gaim2_account_get_username(account)),
-+ roast_password(gaim2_connection_get_password(gc)),
- LANGUAGE, REVISION);
- if (sflap_send(gc, snd, -1, TYPE_DATA) < 0) {
-- gaim_connection_error(gc, _("Disconnected."));
-+ gaim2_connection_error(gc, _("Disconnected."));
- return;
- }
- g_snprintf(snd, sizeof snd, "toc_init_done");
- sflap_send(gc, snd, -1, TYPE_DATA);
-- gaim_notify_info(gc, NULL,
-+ gaim2_notify_info(gc, NULL,
- _("TOC has come back from its pause. You may "
- "now send messages again."), NULL);
- }
-@@ -855,23 +855,23 @@ static void toc_callback(gpointer data,
- * If we have info for ourselves then set our display name, warning
- * level and official time of login.
- */
-- tmp = g_strdup(gaim_normalize(account, gaim_account_get_username(gc->account)));
-- if (!strcmp(tmp, gaim_normalize(account, c))) {
-- gaim_connection_set_display_name(gc, c);
-+ tmp = g_strdup(gaim2_normalize(account, gaim2_account_get_username(gc->account)));
-+ if (!strcmp(tmp, gaim2_normalize(account, c))) {
-+ gaim2_connection_set_display_name(gc, c);
- /* XXX - What should the second parameter be here? */
-- /* gaim_prpl_got_account_warning_level(account, NULL, evil);*/
-- gaim_prpl_got_account_login_time(account, signon);
-+ /* gaim2_prpl_got_account_warning_level(account, NULL, evil);*/
-+ gaim2_prpl_got_account_login_time(account, signon);
- }
- g_free(tmp);
-
-- gaim_prpl_got_user_status(account, c, (logged_in ? "online" : "offline"), NULL);
-- gaim_prpl_got_user_login_time(account, c, signon);
-+ gaim2_prpl_got_user_status(account, c, (logged_in ? "online" : "offline"), NULL);
-+ gaim2_prpl_got_user_login_time(account, c, signon);
- if (time_idle > 0)
-- gaim_prpl_got_user_idle(account, c, TRUE, time_idle);
-+ gaim2_prpl_got_user_idle(account, c, TRUE, time_idle);
- else
-- gaim_prpl_got_user_idle(account, c, FALSE, 0);
-+ gaim2_prpl_got_user_idle(account, c, FALSE, 0);
- } else if (!g_ascii_strcasecmp(c, "ERROR")) {
-- gaim_notify_error(gc, NULL, show_error_message(), NULL);
-+ gaim2_notify_error(gc, NULL, show_error_message(), NULL);
- } else if (!g_ascii_strcasecmp(c, "EVILED")) {
- int lev;
- char *name;
-@@ -879,7 +879,7 @@ static void toc_callback(gpointer data,
- sscanf(strtok(NULL, ":"), "%d", &lev);
- name = strtok(NULL, ":");
-
-- /* gaim_prpl_got_account_warning_level(account, name, lev); */
-+ /* gaim2_prpl_got_account_warning_level(account, name, lev); */
- } else if (!g_ascii_strcasecmp(c, "CHAT_JOIN")) {
- char *name;
- int id;
-@@ -890,7 +890,7 @@ static void toc_callback(gpointer data,
- serv_got_joined_chat(gc, id, name);
- } else if (!g_ascii_strcasecmp(c, "CHAT_IN")) {
- int id;
-- GaimMessageFlags flags;
-+ Gaim2MessageFlags flags;
- char *m, *who, *whisper;
-
- sscanf(strtok(NULL, ":"), "%d", &id);
-@@ -908,8 +908,8 @@ static void toc_callback(gpointer data,
- int id;
- char *in, *buddy;
- GSList *bcs = gc->buddy_chats;
-- GaimConversation *b = NULL;
-- GaimConvChat *chat;
-+ Gaim2Conversation *b = NULL;
-+ Gaim2ConvChat *chat;
-
- sscanf(strtok(NULL, ":"), "%d", &id);
- in = strtok(NULL, ":");
-@@ -917,8 +917,8 @@ static void toc_callback(gpointer data,
- chat = GAIM_CONV_CHAT(b);
-
- while (bcs) {
-- b = (GaimConversation *)bcs->data;
-- if (id == gaim_conv_chat_get_id(chat))
-+ b = (Gaim2Conversation *)bcs->data;
-+ if (id == gaim2_conv_chat_get_id(chat))
- break;
- bcs = bcs->next;
- b = NULL;
-@@ -929,10 +929,10 @@ static void toc_callback(gpointer data,
-
- if (in && (*in == 'T'))
- while ((buddy = strtok(NULL, ":")) != NULL)
-- gaim_conv_chat_add_user(chat, buddy, NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(chat, buddy, NULL, GAIM_CBFLAGS_NONE, TRUE);
- else
- while ((buddy = strtok(NULL, ":")) != NULL)
-- gaim_conv_chat_remove_user(chat, buddy, NULL);
-+ gaim2_conv_chat_remove_user(chat, buddy, NULL);
- } else if (!g_ascii_strcasecmp(c, "CHAT_INVITE")) {
- char *name, *who, *message;
- int id;
-@@ -949,14 +949,14 @@ static void toc_callback(gpointer data,
- serv_got_chat_invite(gc, name, who, message, components);
- } else if (!g_ascii_strcasecmp(c, "CHAT_LEFT")) {
- GSList *bcs = gc->buddy_chats;
-- GaimConversation *b = NULL;
-+ Gaim2Conversation *b = NULL;
- int id;
-
- sscanf(strtok(NULL, ":"), "%d", &id);
-
- while (bcs) {
-- b = (GaimConversation *)bcs->data;
-- if (id == gaim_conv_chat_get_id(GAIM_CONV_CHAT(b)))
-+ b = (Gaim2Conversation *)bcs->data;
-+ if (id == gaim2_conv_chat_get_id(GAIM_CONV_CHAT(b)))
- break;
- b = NULL;
- bcs = bcs->next;
-@@ -967,10 +967,10 @@ static void toc_callback(gpointer data,
-
- if (b->window) {
- char error_buf[BUF_LONG];
-- gaim_conversation_set_account(b, NULL);
-+ gaim2_conversation_set_account(b, NULL);
- g_snprintf(error_buf, sizeof error_buf, _("You have been disconnected"
- " from chat room %s."), b->name);
-- gaim_notify_error(gc, NULL, error_buf, NULL);
-+ gaim2_notify_error(gc, NULL, error_buf, NULL);
- } else
- serv_got_chat_left(gc, id);
- } else if (!g_ascii_strcasecmp(c, "GOTO_URL")) {
-@@ -980,20 +980,20 @@ static void toc_callback(gpointer data,
- url = strtok(NULL, ":");
-
- g_snprintf(tmp, sizeof(tmp), "http://%s:%d/%s", tdt->toc_ip,
-- gaim_account_get_int(gc->account, "port", TOC_PORT),
-+ gaim2_account_get_int(gc->account, "port", TOC_PORT),
- url);
-- gaim_url_fetch(tmp, FALSE, NULL, FALSE, toc_got_info, gc);
-+ gaim2_url_fetch(tmp, FALSE, NULL, FALSE, toc_got_info, gc);
- } else if (!g_ascii_strcasecmp(c, "DIR_STATUS")) {
- } else if (!g_ascii_strcasecmp(c, "ADMIN_NICK_STATUS")) {
- } else if (!g_ascii_strcasecmp(c, "ADMIN_PASSWD_STATUS")) {
-- gaim_notify_info(gc, NULL, _("Password Change Successful"), NULL);
-+ gaim2_notify_info(gc, NULL, _("Password Change Successful"), NULL);
- } else if (!g_ascii_strcasecmp(c, "PAUSE")) {
- tdt->state = STATE_PAUSE;
-- gaim_notify_warning(gc, NULL,
-+ gaim2_notify_warning(gc, NULL,
- _("TOC has sent a PAUSE command."),
- _("When this happens, TOC ignores any messages "
- "sent to it, and may kick you off if you send a"
-- " message. Gaim will prevent anything from "
-+ " message. Gaim2 will prevent anything from "
- "going through. This is only temporary, please "
- "be patient."));
- } else if (!g_ascii_strcasecmp(c, "RVOUS_PROPOSE")) {
-@@ -1068,7 +1068,7 @@ static void toc_callback(gpointer data,
- for (i--; i >= 0; i--)
- g_free(messages[i]);
-
-- gaim_debug(GAIM_DEBUG_MISC, "toc",
-+ gaim2_debug(GAIM_DEBUG_MISC, "toc",
- "English translation of RVOUS_PROPOSE: %s requests "
- "Send File (i.e. send a file to you); %s:%d "
- "(verified_ip:port), %d files at total size of "
-@@ -1123,7 +1123,7 @@ static void toc_callback(gpointer data,
- }
- frombase64(strtok(NULL, ":"), (char **)&icon, NULL);
-
-- gaim_debug(GAIM_DEBUG_MISC, "toc",
-+ gaim2_debug(GAIM_DEBUG_MISC, "toc",
- "received icon of length %d\n", icon->len);
- g_free(icon);
- for (i--; i >= 0; i--)
-@@ -1131,18 +1131,18 @@ static void toc_callback(gpointer data,
- } else if (!strcmp(uuid, IMAGE_UID)) {
- /* aka Direct IM */
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "toc",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc",
- "Don't know what to do with RVOUS UUID %s\n", uuid);
- /* do we have to do anything here? i think it just times out */
- }
- #endif
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "toc",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "toc",
- "don't know what to do with %s\n", c);
- }
- }
-
--static int toc_send_im(GaimConnection *gc, const char *name, const char *message, GaimMessageFlags flags)
-+static int toc_send_im(Gaim2Connection *gc, const char *name, const char *message, Gaim2MessageFlags flags)
- {
- char *buf1, *buf2;
-
-@@ -1153,12 +1153,12 @@ static int toc_send_im(GaimConnection *g
- g_free(buf1);
- return -E2BIG;
- }
-- buf2 = g_strdup_printf("toc_send_im %s \"%s\"%s", gaim_normalize(gc->account, name), buf1,
-+ buf2 = g_strdup_printf("toc_send_im %s \"%s\"%s", gaim2_normalize(gc->account, name), buf1,
- ((flags & GAIM_MESSAGE_AUTO_RESP) ? " auto" : ""));
- g_free(buf1);
- #else
- /* This doesn't work yet. See the comments below for details */
-- buf1 = gaim_strreplace(message, "\"", "\\\"");
-+ buf1 = gaim2_strreplace(message, "\"", "\\\"");
-
- /*
- * We still need to determine what encoding should be used and send the
-@@ -1177,7 +1177,7 @@ static int toc_send_im(GaimConnection *g
- return -E2BIG;
- }
-
-- buf2 = g_strdup_printf("toc2_send_im_enc %s F U en \"%s\" %s", gaim_normalize(gc->account, name), buf1,
-+ buf2 = g_strdup_printf("toc2_send_im_enc %s F U en \"%s\" %s", gaim2_normalize(gc->account, name), buf1,
- ((flags & GAIM_MESSAGE_AUTO_RESP) ? "auto" : ""));
- g_free(buf1);
- #endif
-@@ -1188,7 +1188,7 @@ static int toc_send_im(GaimConnection *g
- return 1;
- }
-
--static void toc_set_config(GaimConnection *gc)
-+static void toc_set_config(Gaim2Connection *gc)
- {
- char *buf = g_malloc(MSG_LEN), snd[BUF_LEN * 2];
- toc_build_config(gc->account, buf, MSG_LEN - strlen("toc_set_config \\{\\}"), FALSE);
-@@ -1197,33 +1197,33 @@ static void toc_set_config(GaimConnectio
- g_free(buf);
- }
-
--static void toc_get_info(GaimConnection *gc, const char *name)
-+static void toc_get_info(Gaim2Connection *gc, const char *name)
- {
- char buf[BUF_LEN * 2];
-- g_snprintf(buf, MSG_LEN, "toc_get_info %s", gaim_normalize(gc->account, name));
-+ g_snprintf(buf, MSG_LEN, "toc_get_info %s", gaim2_normalize(gc->account, name));
- sflap_send(gc, buf, -1, TYPE_DATA);
- }
-
- /* Should be implemented as an Account Action? */
--static void toc_get_dir(GaimBlistNode *node, gpointer data)
-+static void toc_get_dir(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- char buf[BUF_LEN * 2];
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- g_snprintf(buf, MSG_LEN, "toc_get_dir %s",
-- gaim_normalize(buddy->account, buddy->name));
-+ gaim2_normalize(buddy->account, buddy->name));
- sflap_send(gc, buf, -1, TYPE_DATA);
- }
-
- #if 0
- /* Should be implemented as an Account Action */
--static void toc_set_dir(GaimConnection *g, const char *first, const char *middle, const char *last,
-+static void toc_set_dir(Gaim2Connection *g, const char *first, const char *middle, const char *last,
- const char *maiden, const char *city, const char *state, const char *country, int web)
- {
- char *buf3, buf2[BUF_LEN * 4], buf[BUF_LEN];
-@@ -1238,13 +1238,13 @@ static void toc_set_dir(GaimConnection *
-
- #if 0
- /* Should be implemented as an Account Action */
--static void toc_dir_search(GaimConnection *g, const char *first, const char *middle, const char *last,
-+static void toc_dir_search(Gaim2Connection *g, const char *first, const char *middle, const char *last,
- const char *maiden, const char *city, const char *state, const char *country, const char *email)
- {
- char buf[BUF_LONG];
- g_snprintf(buf, sizeof(buf) / 2, "toc_dir_search %s:%s:%s:%s:%s:%s:%s:%s", first, middle,
- last, maiden, city, state, country, email);
-- gaim_debug(GAIM_DEBUG_INFO, "toc",
-+ gaim2_debug(GAIM_DEBUG_INFO, "toc",
- "Searching for: %s,%s,%s,%s,%s,%s,%s\n",
- first, middle, last, maiden,
- city, state, country);
-@@ -1252,7 +1252,7 @@ static void toc_dir_search(GaimConnectio
- }
- #endif
-
--static void toc_set_status(GaimAccount *account, GaimStatus *status)
-+static void toc_set_status(Gaim2Account *account, Gaim2Status *status)
- {
- #if 0 /* do we care about TOC any more? */
- char buf[BUF_LEN * 2];
-@@ -1272,7 +1272,7 @@ static void toc_set_status(GaimAccount *
- #endif
- }
-
--static void toc_set_info(GaimConnection *g, const char *info)
-+static void toc_set_info(Gaim2Connection *g, const char *info)
- {
- char buf[BUF_LEN * 2], *buf2;
- buf2 = escape_text(info);
-@@ -1281,7 +1281,7 @@ static void toc_set_info(GaimConnection
- sflap_send(g, buf, -1, TYPE_DATA);
- }
-
--static void toc_change_passwd(GaimConnection *g, const char *orig, const char *new)
-+static void toc_change_passwd(Gaim2Connection *g, const char *orig, const char *new)
- {
- char buf[BUF_LEN * 2];
- g_snprintf(buf, BUF_LONG, "toc_change_passwd %s %s", orig, new);
-@@ -1289,15 +1289,15 @@ static void toc_change_passwd(GaimConnec
- }
-
- static void
--toc_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+toc_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- char buf[BUF_LEN * 2];
-- g_snprintf(buf, sizeof(buf), "toc_add_buddy %s", gaim_normalize(gc->account, buddy->name));
-+ g_snprintf(buf, sizeof(buf), "toc_add_buddy %s", gaim2_normalize(gc->account, buddy->name));
- sflap_send(gc, buf, -1, TYPE_DATA);
- toc_set_config(gc);
- }
-
--static void toc_add_buddies(GaimConnection *gc, GList *buddies, GList *groups)
-+static void toc_add_buddies(Gaim2Connection *gc, GList *buddies, GList *groups)
- {
- char buf[BUF_LEN * 2];
- int n;
-@@ -1305,26 +1305,26 @@ static void toc_add_buddies(GaimConnecti
-
- n = g_snprintf(buf, sizeof(buf), "toc_add_buddy");
- for (cur = buddies; cur != NULL; cur = cur->next) {
-- GaimBuddy *buddy = cur->data;
-+ Gaim2Buddy *buddy = cur->data;
-
-- if (strlen(gaim_normalize(gc->account, buddy->name)) + n + 32 > MSG_LEN) {
-+ if (strlen(gaim2_normalize(gc->account, buddy->name)) + n + 32 > MSG_LEN) {
- sflap_send(gc, buf, -1, TYPE_DATA);
- n = g_snprintf(buf, sizeof(buf), "toc_add_buddy");
- }
-- n += g_snprintf(buf + n, sizeof(buf) - n, " %s", gaim_normalize(gc->account, buddy->name));
-+ n += g_snprintf(buf + n, sizeof(buf) - n, " %s", gaim2_normalize(gc->account, buddy->name));
- }
- sflap_send(gc, buf, -1, TYPE_DATA);
- }
-
--static void toc_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void toc_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- char buf[BUF_LEN * 2];
-- g_snprintf(buf, sizeof(buf), "toc_remove_buddy %s", gaim_normalize(gc->account, buddy->name));
-+ g_snprintf(buf, sizeof(buf), "toc_remove_buddy %s", gaim2_normalize(gc->account, buddy->name));
- sflap_send(gc, buf, -1, TYPE_DATA);
- toc_set_config(gc);
- }
-
--static void toc_remove_buddies(GaimConnection *gc, GList *buddies, GList *groups)
-+static void toc_remove_buddies(Gaim2Connection *gc, GList *buddies, GList *groups)
- {
- char buf[BUF_LEN * 2];
- int n;
-@@ -1332,33 +1332,33 @@ static void toc_remove_buddies(GaimConne
-
- n = g_snprintf(buf, sizeof(buf), "toc_remove_buddy");
- for (cur = buddies; cur != NULL; cur = cur->next) {
-- GaimBuddy *buddy = cur->data;
-+ Gaim2Buddy *buddy = cur->data;
-
-- if (strlen(gaim_normalize(gc->account, buddy->name)) + n + 32 > MSG_LEN) {
-+ if (strlen(gaim2_normalize(gc->account, buddy->name)) + n + 32 > MSG_LEN) {
- sflap_send(gc, buf, -1, TYPE_DATA);
- n = g_snprintf(buf, sizeof(buf), "toc_remove_buddy");
- }
-- n += g_snprintf(buf + n, sizeof(buf) - n, " %s", gaim_normalize(gc->account, buddy->name));
-+ n += g_snprintf(buf + n, sizeof(buf) - n, " %s", gaim2_normalize(gc->account, buddy->name));
- }
- sflap_send(gc, buf, -1, TYPE_DATA);
- toc_set_config(gc);
- }
-
--static void toc_set_idle(GaimConnection *g, int time)
-+static void toc_set_idle(Gaim2Connection *g, int time)
- {
- char buf[BUF_LEN * 2];
- g_snprintf(buf, sizeof(buf), "toc_set_idle %d", time);
- sflap_send(g, buf, -1, TYPE_DATA);
- }
-
--static void toc_warn(GaimConnection *g, const char *name, int anon)
-+static void toc_warn(Gaim2Connection *g, const char *name, int anon)
- {
- char send[BUF_LEN * 2];
- g_snprintf(send, 255, "toc_evil %s %s", name, ((anon) ? "anon" : "norm"));
- sflap_send(g, send, -1, TYPE_DATA);
- }
-
--static GList *toc_chat_info(GaimConnection *gc)
-+static GList *toc_chat_info(Gaim2Connection *gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -1379,7 +1379,7 @@ static GList *toc_chat_info(GaimConnecti
- return m;
- }
-
--GHashTable *toc_chat_info_defaults(GaimConnection *gc, const char *chat_name)
-+GHashTable *toc_chat_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
-
-@@ -1391,7 +1391,7 @@ GHashTable *toc_chat_info_defaults(GaimC
- return defaults;
- }
-
--static void toc_join_chat(GaimConnection *g, GHashTable *data)
-+static void toc_join_chat(Gaim2Connection *g, GHashTable *data)
- {
- char buf[BUF_LONG];
- char *name, *exchange;
-@@ -1410,23 +1410,23 @@ static void toc_join_chat(GaimConnection
- sflap_send(g, buf, -1, TYPE_DATA);
- }
-
--static void toc_chat_invite(GaimConnection *gc, int id, const char *message, const char *name)
-+static void toc_chat_invite(Gaim2Connection *gc, int id, const char *message, const char *name)
- {
- char buf[BUF_LONG];
- g_snprintf(buf, sizeof(buf) / 2, "toc_chat_invite %d \"%s\" %s", id,
-- message ? message : "", gaim_normalize(gc->account, name));
-+ message ? message : "", gaim2_normalize(gc->account, name));
- sflap_send(gc, buf, -1, TYPE_DATA);
- }
-
--static void toc_chat_leave(GaimConnection *g, int id)
-+static void toc_chat_leave(Gaim2Connection *g, int id)
- {
- GSList *bcs = g->buddy_chats;
-- GaimConversation *b = NULL;
-+ Gaim2Conversation *b = NULL;
- char buf[BUF_LEN * 2];
-
- while (bcs) {
-- b = (GaimConversation *)bcs->data;
-- if (id == gaim_conv_chat_get_id(GAIM_CONV_CHAT(b)))
-+ b = (Gaim2Conversation *)bcs->data;
-+ if (id == gaim2_conv_chat_get_id(GAIM_CONV_CHAT(b)))
- break;
- b = NULL;
- bcs = bcs->next;
-@@ -1435,7 +1435,7 @@ static void toc_chat_leave(GaimConnectio
- if (!b)
- return; /* can this happen? */
-
-- if (gaim_conversation_get_account(b) == NULL) {
-+ if (gaim2_conversation_get_account(b) == NULL) {
- /* TOC already kicked us out of this room */
- serv_got_chat_left(g, id);
- }
-@@ -1445,17 +1445,17 @@ static void toc_chat_leave(GaimConnectio
- }
- }
-
--static void toc_chat_whisper(GaimConnection *gc, int id, const char *who, const char *message)
-+static void toc_chat_whisper(Gaim2Connection *gc, int id, const char *who, const char *message)
- {
- char *buf1, *buf2;
- buf1 = escape_text(message);
-- buf2 = g_strdup_printf("toc_chat_whisper %d %s \"%s\"", id, gaim_normalize(gc->account, who), buf1);
-+ buf2 = g_strdup_printf("toc_chat_whisper %d %s \"%s\"", id, gaim2_normalize(gc->account, who), buf1);
- g_free(buf1);
- sflap_send(gc, buf2, -1, TYPE_DATA);
- g_free(buf2);
- }
-
--static int toc_chat_send(GaimConnection *g, int id, const char *message, GaimMessageFlags flags)
-+static int toc_chat_send(Gaim2Connection *g, int id, const char *message, Gaim2MessageFlags flags)
- {
- char *buf1, *buf2;
- buf1 = escape_text(message);
-@@ -1470,13 +1470,13 @@ static int toc_chat_send(GaimConnection
- return 0;
- }
-
--static void toc_keepalive(GaimConnection *gc)
-+static void toc_keepalive(Gaim2Connection *gc)
- {
- sflap_send(gc, "", 0, TYPE_KEEPALIVE);
- }
-
- static const char *
--toc_normalize(const GaimAccount *account, const char *str)
-+toc_normalize(const Gaim2Account *account, const char *str)
- {
- static char buf[BUF_LEN];
- char *tmp1, *tmp2;
-@@ -1502,10 +1502,10 @@ toc_normalize(const GaimAccount *account
- return buf;
- }
-
--static const char *toc_list_icon(GaimAccount *a, GaimBuddy *b)
-+static const char *toc_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- if (!b || (b && b->name && b->name[0] == '+')) {
-- if (a != NULL && isdigit(*gaim_account_get_username(a)))
-+ if (a != NULL && isdigit(*gaim2_account_get_username(a)))
- return "icq";
- else
- return "aim";
-@@ -1516,7 +1516,7 @@ static const char *toc_list_icon(GaimAcc
- return "aim";
- }
-
--static void toc_list_emblems(GaimBuddy *b, const char **se, const char **sw, const char **nw, const char **ne)
-+static void toc_list_emblems(Gaim2Buddy *b, const char **se, const char **sw, const char **nw, const char **ne)
- {
- char *emblems[4] = {NULL,NULL,NULL,NULL};
- int i = 0;
-@@ -1540,13 +1540,13 @@ static void toc_list_emblems(GaimBuddy *
- *ne = emblems[3];
- }
-
--static GList *toc_blist_node_menu(GaimBlistNode *node)
-+static GList *toc_blist_node_menu(Gaim2BlistNode *node)
- {
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
- if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- act = gaim_blist_node_action_new(_("Get Dir Info"),
-+ act = gaim2_blist_node_action_new(_("Get Dir Info"),
- toc_get_dir, NULL, NULL);
- m = g_list_append(m, act);
- }
-@@ -1554,27 +1554,27 @@ static GList *toc_blist_node_menu(GaimBl
- return m;
- }
-
--static void toc_add_permit(GaimConnection *gc, const char *who)
-+static void toc_add_permit(Gaim2Connection *gc, const char *who)
- {
- char buf2[BUF_LEN * 2];
- if (gc->account->perm_deny != 3)
- return;
-- g_snprintf(buf2, sizeof(buf2), "toc_add_permit %s", gaim_normalize(gc->account, who));
-+ g_snprintf(buf2, sizeof(buf2), "toc_add_permit %s", gaim2_normalize(gc->account, who));
- sflap_send(gc, buf2, -1, TYPE_DATA);
- toc_set_config(gc);
- }
-
--static void toc_add_deny(GaimConnection *gc, const char *who)
-+static void toc_add_deny(Gaim2Connection *gc, const char *who)
- {
- char buf2[BUF_LEN * 2];
- if (gc->account->perm_deny != 4)
- return;
-- g_snprintf(buf2, sizeof(buf2), "toc_add_deny %s", gaim_normalize(gc->account, who));
-+ g_snprintf(buf2, sizeof(buf2), "toc_add_deny %s", gaim2_normalize(gc->account, who));
- sflap_send(gc, buf2, -1, TYPE_DATA);
- toc_set_config(gc);
- }
-
--static void toc_set_permit_deny(GaimConnection *gc)
-+static void toc_set_permit_deny(Gaim2Connection *gc)
- {
- char buf2[BUF_LEN * 2];
- GSList *list;
-@@ -1606,7 +1606,7 @@ static void toc_set_permit_deny(GaimConn
- at = g_snprintf(buf2, sizeof(buf2), "toc_add_permit ");
- list = gc->account->permit;
- while (list) {
-- at += g_snprintf(buf2 + at, sizeof(buf2) - at, "%s ", gaim_normalize(gc->account, list->data));
-+ at += g_snprintf(buf2 + at, sizeof(buf2) - at, "%s ", gaim2_normalize(gc->account, list->data));
- if (at > MSG_LEN + 32) { /* from out my ass comes greatness */
- sflap_send(gc, buf2, -1, TYPE_DATA);
- at = g_snprintf(buf2, sizeof(buf2), "toc_add_permit ");
-@@ -1624,7 +1624,7 @@ static void toc_set_permit_deny(GaimConn
- at = g_snprintf(buf2, sizeof(buf2), "toc_add_deny ");
- list = gc->account->deny;
- while (list) {
-- at += g_snprintf(buf2 + at, sizeof(buf2) - at, "%s ", gaim_normalize(gc->account, list->data));
-+ at += g_snprintf(buf2 + at, sizeof(buf2) - at, "%s ", gaim2_normalize(gc->account, list->data));
- if (at > MSG_LEN + 32) { /* from out my ass comes greatness */
- sflap_send(gc, buf2, -1, TYPE_DATA);
- at = g_snprintf(buf2, sizeof(buf2), "toc_add_deny ");
-@@ -1639,21 +1639,21 @@ static void toc_set_permit_deny(GaimConn
- toc_set_config(gc);
- }
-
--static void toc_rem_permit(GaimConnection *gc, const char *who)
-+static void toc_rem_permit(Gaim2Connection *gc, const char *who)
- {
- if (gc->account->perm_deny != 3)
- return;
- toc_set_permit_deny(gc);
- }
-
--static void toc_rem_deny(GaimConnection *gc, const char *who)
-+static void toc_rem_deny(Gaim2Connection *gc, const char *who)
- {
- if (gc->account->perm_deny != 4)
- return;
- toc_set_permit_deny(gc);
- }
-
--static GList *toc_away_states(GaimAccount *account)
-+static GList *toc_away_states(Gaim2Account *account)
- {
- #if 0 /* do we care about TOC any more? */
- return g_list_append(NULL, GAIM_AWAY_CUSTOM);
-@@ -1663,35 +1663,35 @@ static GList *toc_away_states(GaimAccoun
- }
-
- static void
--show_set_info(GaimPluginAction *action)
-+show_set_info(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_account_request_change_user_info(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_account_request_change_user_info(gaim2_connection_get_account(gc));
- }
-
- static void
--change_pass(GaimPluginAction *action)
-+change_pass(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_account_request_change_password(gaim_connection_get_account(gc));
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_account_request_change_password(gaim2_connection_get_account(gc));
- }
-
--static GList *toc_actions(GaimPlugin *plugin, gpointer context)
-+static GList *toc_actions(Gaim2Plugin *plugin, gpointer context)
- {
- GList *m = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- act = gaim_plugin_action_new(_("Set User Info"),
-+ act = gaim2_plugin_action_new(_("Set User Info"),
- show_set_info);
- m = g_list_append(m, act);
-
- #if 0
-- act = gaim_plugin_action_new(_("Set Dir Info"),
-+ act = gaim2_plugin_action_new(_("Set Dir Info"),
- show_set_dir);
- m = g_list_append(m, act);
- #endif
-
-- act = gaim_plugin_action_new(_("Change Password"),
-+ act = gaim2_plugin_action_new(_("Change Password"),
- change_pass);
- m = g_list_append(m, act);
-
-@@ -1739,7 +1739,7 @@ struct file_header {
- struct file_transfer {
- struct file_header hdr;
-
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- char *user;
- char *cookie;
-@@ -1759,7 +1759,7 @@ struct file_transfer {
-
- static void debug_header(struct file_transfer *ft) {
- struct file_header *f = (struct file_header *)ft;
-- gaim_debug(GAIM_DEBUG_MISC, "toc", "FT HEADER:\n"
-+ gaim2_debug(GAIM_DEBUG_MISC, "toc", "FT HEADER:\n"
- "\t%s %d 0x%04x\n"
- "\t%s %d %d\n"
- "\t%d %d %d %d %d %d\n"
-@@ -1783,7 +1783,7 @@ static void debug_header(struct file_tra
- f->name);
- }
-
--static void toc_send_file_callback(gpointer data, gint source, GaimInputCondition cond)
-+static void toc_send_file_callback(gpointer data, gint source, Gaim2InputCondition cond)
- {
- char buf[BUF_LONG];
- int rt, i;
-@@ -1809,9 +1809,9 @@ static void toc_send_file_callback(gpoin
- ft->file = g_fopen(ft->filename, "w");
- if (!ft->file) {
- buf = g_strdup_printf(_("Could not open %s for writing!"), ft->filename);
-- gaim_notify_error(ft->gc, NULL, buf, strerror(errno));
-+ gaim2_notify_error(ft->gc, NULL, buf, strerror(errno));
- g_free(buf);
-- gaim_input_remove(ft->inpa);
-+ gaim2_input_remove(ft->inpa);
- close(source);
- g_free(ft->filename);
- g_free(ft->user);
-@@ -1826,9 +1826,9 @@ static void toc_send_file_callback(gpoin
- if (!ft->file) {
- buf = g_strdup_printf("Could not open %s/%s for writing!", ft->filename,
- ft->hdr.name);
-- gaim_notify_error(ft->gc, NULL, buf, strerror(errno));
-+ gaim2_notify_error(ft->gc, NULL, buf, strerror(errno));
- g_free(buf);
-- gaim_input_remove(ft->inpa);
-+ gaim2_input_remove(ft->inpa);
- close(source);
- g_free(ft->filename);
- g_free(ft->user);
-@@ -1843,10 +1843,10 @@ static void toc_send_file_callback(gpoin
-
- rt = read(source, buf, MIN(ntohl(ft->hdr.size) - ft->recvsize, 1024));
- if (rt < 0) {
-- gaim_notify_error(ft->gc, NULL,
-+ gaim2_notify_error(ft->gc, NULL,
- _("File transfer failed; other side probably "
- "canceled."), NULL);
-- gaim_input_remove(ft->inpa);
-+ gaim2_input_remove(ft->inpa);
- close(source);
- g_free(ft->user);
- g_free(ft->ip);
-@@ -1872,7 +1872,7 @@ static void toc_send_file_callback(gpoin
- ft->recvsize = 0;
- fclose(ft->file);
- if (ft->hdr.filesleft == 0) {
-- gaim_input_remove(ft->inpa);
-+ gaim2_input_remove(ft->inpa);
- close(source);
- g_free(ft->filename);
- g_free(ft->user);
-@@ -1883,12 +1883,12 @@ static void toc_send_file_callback(gpoin
- }
- }
-
--static void toc_send_file_connect(gpointer data, gint src, GaimInputCondition cond)
-+static void toc_send_file_connect(gpointer data, gint src, Gaim2InputCondition cond)
- {
- struct file_transfer *ft = data;
-
- if (src == -1) {
-- gaim_notify_error(ft->gc, NULL,
-+ gaim2_notify_error(ft->gc, NULL,
- _("Could not connect for transfer."), NULL);
- g_free(ft->filename);
- g_free(ft->cookie);
-@@ -1898,17 +1898,17 @@ static void toc_send_file_connect(gpoint
- return;
- }
-
-- ft->inpa = gaim_input_add(src, GAIM_INPUT_READ, toc_send_file_callback, ft);
-+ ft->inpa = gaim2_input_add(src, GAIM_INPUT_READ, toc_send_file_callback, ft);
- }
-
- static void toc_send_file(gpointer a, struct file_transfer *old_ft)
- {
- struct file_transfer *ft;
- const char *dirname = gtk_file_selection_get_filename(GTK_FILE_SELECTION(old_ft->window));
-- GaimAccount *account;
-+ Gaim2Account *account;
- char buf[BUF_LEN * 2];
-
-- if (gaim_gtk_check_if_dir(dirname, GTK_FILE_SELECTION(old_ft->window)))
-+ if (gaim2_gtk_check_if_dir(dirname, GTK_FILE_SELECTION(old_ft->window)))
- return;
- ft = g_new0(struct file_transfer, 1);
- if (old_ft->files == 1)
-@@ -1927,8 +1927,8 @@ static void toc_send_file(gpointer a, st
- g_snprintf(buf, sizeof(buf), "toc_rvous_accept %s %s %s", ft->user, ft->cookie, FILE_SEND_UID);
- sflap_send(ft->gc, buf, -1, TYPE_DATA);
-
-- if (gaim_proxy_connect(account, ft->ip, ft->port, toc_send_file_connect, ft) != 0) {
-- gaim_notify_error(ft->gc, NULL,
-+ if (gaim2_proxy_connect(account, ft->ip, ft->port, toc_send_file_connect, ft) != 0) {
-+ gaim2_notify_error(ft->gc, NULL,
- _("Could not connect for transfer."), NULL);
- g_free(ft->filename);
- g_free(ft->cookie);
-@@ -1939,7 +1939,7 @@ static void toc_send_file(gpointer a, st
- }
- }
-
--static void toc_get_file_callback(gpointer data, gint source, GaimInputCondition cond)
-+static void toc_get_file_callback(gpointer data, gint source, Gaim2InputCondition cond)
- {
- char buf[BUF_LONG];
-
-@@ -1953,8 +1953,8 @@ static void toc_get_file_callback(gpoint
- write(source, buf, remain);
- ft->recvsize += remain;
- if (ft->recvsize == ntohl(ft->hdr.totsize)) {
-- gaim_input_remove(ft->inpa);
-- ft->inpa = gaim_input_add(source, GAIM_INPUT_READ,
-+ gaim2_input_remove(ft->inpa);
-+ ft->inpa = gaim2_input_add(source, GAIM_INPUT_READ,
- toc_get_file_callback, ft);
- }
- return;
-@@ -1995,8 +1995,8 @@ static void toc_get_file_callback(gpoint
-
- if (ft->hdr.hdrtype != htons(0x120c)) {
- g_snprintf(buf, sizeof(buf), "%s decided to cancel the transfer", ft->user);
-- gaim_notify_error(ft->gc, NULL, buf, NULL);
-- gaim_input_remove(ft->inpa);
-+ gaim2_notify_error(ft->gc, NULL, buf, NULL);
-+ gaim2_input_remove(ft->inpa);
- close(source);
- g_free(ft->filename);
- g_free(ft->user);
-@@ -2020,8 +2020,8 @@ static void toc_get_file_callback(gpoint
- read(source, &ft->hdr.bcookie, MIN(256 - 8, ntohs(ft->hdr.hdrlen) - 8));
- debug_header(ft);
-
-- gaim_input_remove(ft->inpa);
-- ft->inpa = gaim_input_add(source, GAIM_INPUT_WRITE,
-+ gaim2_input_remove(ft->inpa);
-+ ft->inpa = gaim2_input_add(source, GAIM_INPUT_WRITE,
- toc_get_file_callback, ft);
- return;
- }
-@@ -2031,7 +2031,7 @@ static void toc_get_file_callback(gpoint
- read(source, &ft->hdr.bcookie, MIN(256 - 8, ntohs(ft->hdr.hdrlen) - 8));
- debug_header(ft);
-
-- gaim_input_remove(ft->inpa);
-+ gaim2_input_remove(ft->inpa);
- close(source);
- g_free(ft->filename);
- g_free(ft->user);
-@@ -2044,7 +2044,7 @@ static void toc_get_file_callback(gpoint
- }
- }
-
--static void toc_get_file_connect(gpointer data, gint src, GaimInputCondition cond)
-+static void toc_get_file_connect(gpointer data, gint src, Gaim2InputCondition cond)
- {
- struct file_transfer *ft = data;
- struct file_header *hdr;
-@@ -2052,7 +2052,7 @@ static void toc_get_file_connect(gpointe
- char *basename;
-
- if (src == -1) {
-- gaim_notify_error(ft->gc, NULL,
-+ gaim2_notify_error(ft->gc, NULL,
- _("Could not connect for transfer."), NULL);
- fclose(ft->file);
- g_free(ft->filename);
-@@ -2085,7 +2085,7 @@ static void toc_get_file_connect(gpointe
- hdr->lsizeoffset = 0x10;
- g_snprintf(hdr->name, 64, "listing.txt");
- if (write(src, hdr, 256) < 0) {
-- gaim_notify_error(ft->gc, NULL,
-+ gaim2_notify_error(ft->gc, NULL,
- _("Could not write file header. The file will "
- "not be transferred."), NULL);
- fclose(ft->file);
-@@ -2097,24 +2097,24 @@ static void toc_get_file_connect(gpointe
- return;
- }
-
-- ft->inpa = gaim_input_add(src, GAIM_INPUT_READ, toc_get_file_callback, ft);
-+ ft->inpa = gaim2_input_add(src, GAIM_INPUT_READ, toc_get_file_callback, ft);
- }
-
- static void toc_get_file(gpointer a, struct file_transfer *old_ft)
- {
- struct file_transfer *ft;
- const char *dirname = gtk_file_selection_get_filename(GTK_FILE_SELECTION(old_ft->window));
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *buf, buf2[BUF_LEN * 2];
-
-- if (gaim_gtk_check_if_dir(dirname, GTK_FILE_SELECTION(old_ft->window)))
-+ if (gaim2_gtk_check_if_dir(dirname, GTK_FILE_SELECTION(old_ft->window)))
- return;
- ft = g_new0(struct file_transfer, 1);
- ft->filename = g_strdup(dirname);
- ft->file = g_fopen(ft->filename, "r");
- if (!ft->file) {
- buf = g_strdup_printf("Unable to open %s for transfer.", ft->filename);
-- gaim_notify_error(ft->gc, NULL, buf, NULL);
-+ gaim2_notify_error(ft->gc, NULL, buf, NULL);
- g_free(buf);
- g_free(ft->filename);
- g_free(ft);
-@@ -2122,7 +2122,7 @@ static void toc_get_file(gpointer a, str
- }
- if (g_stat(dirname, &ft->st)) {
- buf = g_strdup_printf("Unable to examine %s.", dirname);
-- gaim_notify_error(ft->gc, NULL, buf, NULL);
-+ gaim2_notify_error(ft->gc, NULL, buf, NULL);
- g_free(buf);
- g_free(ft->filename);
- g_free(ft);
-@@ -2139,8 +2139,8 @@ static void toc_get_file(gpointer a, str
- g_snprintf(buf2, sizeof(buf2), "toc_rvous_accept %s %s %s", ft->user, ft->cookie, FILE_GET_UID);
- sflap_send(ft->gc, buf2, -1, TYPE_DATA);
-
-- if (gaim_proxy_connect(account, ft->ip, ft->port, toc_get_file_connect, ft) < 0) {
-- gaim_notify_error(ft->gc, NULL,
-+ if (gaim2_proxy_connect(account, ft->ip, ft->port, toc_get_file_connect, ft) < 0) {
-+ gaim2_notify_error(ft->gc, NULL,
- _("Could not connect for transfer."), NULL);
- fclose(ft->file);
- g_free(ft->filename);
-@@ -2174,7 +2174,7 @@ static void toc_reject_ft(struct ft_requ
-
-
- static void toc_accept_ft(struct ft_request *fr) {
-- if(g_list_find(gaim_connections_get_all(), fr->gc)) {
-+ if(g_list_find(gaim2_connections_get_all(), fr->gc)) {
- GtkWidget *window;
- char buf[BUF_LEN];
-
-@@ -2186,8 +2186,8 @@ static void toc_accept_ft(struct ft_requ
- ft->port = fr->port;
- ft->files = fr->files;
-
-- ft->window = window = gtk_file_selection_new(_("Gaim - Save As..."));
-- g_snprintf(buf, sizeof(buf), "%s/%s", gaim_home_dir(), fr->filename ? fr->filename : "");
-+ ft->window = window = gtk_file_selection_new(_("Gaim2 - Save As..."));
-+ g_snprintf(buf, sizeof(buf), "%s/%s", gaim2_home_dir(), fr->filename ? fr->filename : "");
- gtk_file_selection_set_filename(GTK_FILE_SELECTION(window), buf);
- g_signal_connect(G_OBJECT(window), "destroy",
- G_CALLBACK(cancel_callback), ft);
-@@ -2223,21 +2223,21 @@ static void accept_file_dialog(struct ft
- "%s requests %s to accept %d file: %s (%.2f %s)%s%s",
- "%s requests %s to accept %d files: %s (%.2f %s)%s%s",
- ft->files),
-- ft->user, gaim_account_get_username(ft->gc->account), ft->files,
-+ ft->user, gaim2_account_get_username(ft->gc->account), ft->files,
- ft->filename, size, sizes[index], (ft->message) ? "\n" : "",
- (ft->message) ? ft->message : "");
- } else {
- g_snprintf(buf, sizeof(buf), _("%s requests you to send them a file"), ft->user);
- }
-
-- gaim_request_accept_cancel(ft->gc, NULL, buf, NULL,
-+ gaim2_request_accept_cancel(ft->gc, NULL, buf, NULL,
- GAIM_DEFAULT_ACTION_NONE, ft,
- G_CALLBACK(toc_accept_ft),
- G_CALLBACK(toc_reject_ft));
- }
- #endif
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- 0,
- NULL, /* user_splits */
-@@ -2302,7 +2302,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -2334,15 +2334,15 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_string_new(_("TOC host"), "server", TOC_HOST);
-+ option = gaim2_account_option_string_new(_("TOC host"), "server", TOC_HOST);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-- option = gaim_account_option_int_new(_("TOC port"), "port", TOC_PORT);
-+ option = gaim2_account_option_int_new(_("TOC port"), "port", TOC_PORT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
- option);
-
-diff -prNu ./src/protocols/yahoo/Makefile.am ./src/protocols/yahoo/Makefile.am
---- ./src/protocols/yahoo/Makefile.am 2005-12-09 05:59:04.000000000 +0100
-+++ ./src/protocols/yahoo/Makefile.am 2006-01-05 13:05:31.000000000 +0100
-@@ -1,7 +1,7 @@
- EXTRA_DIST = \
- Makefile.mingw
-
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- YAHOOSOURCES = \
- util.c \
-diff -prNu ./src/protocols/yahoo/util.c ./src/protocols/yahoo/util.c
---- ./src/protocols/yahoo/util.c 2005-10-12 06:02:46.000000000 +0200
-+++ ./src/protocols/yahoo/util.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * Some code copyright 2003 Tim Ringenbach <omarvo@hotmail.com>
- * (marv on irc.freenode.net)
-@@ -44,7 +44,7 @@
- * it is not dereferenced.
- * @return The g_malloced string in the appropriate encoding.
- */
--char *yahoo_string_encode(GaimConnection *gc, const char *str, gboolean *utf8)
-+char *yahoo_string_encode(Gaim2Connection *gc, const char *str, gboolean *utf8)
- {
- struct yahoo_data *yd = gc->proto_data;
- char *ret;
-@@ -76,7 +76,7 @@ char *yahoo_string_encode(GaimConnection
- * @param utf8 Did the server tell us it was supposed to be utf8?
- * @return The decoded, utf-8 string, which must be g_free()'d.
- */
--char *yahoo_string_decode(GaimConnection *gc, const char *str, gboolean utf8)
-+char *yahoo_string_decode(Gaim2Connection *gc, const char *str, gboolean utf8)
- {
- struct yahoo_data *yd = gc->proto_data;
- char *ret;
-@@ -147,7 +147,7 @@ void yahoo_init_colorht()
- g_hash_table_insert(ht, "x4", "</U>");
-
- /* these just tell us the text they surround is supposed
-- * to be a link. gaim figures that out on its own so we
-+ * to be a link. gaim2 figures that out on its own so we
- * just ignore it.
- */
- g_hash_table_insert(ht, "l", ""); /* link start */
-@@ -266,7 +266,7 @@ char *yahoo_codes_to_html(const char *x)
- else if ((match = (char *) g_hash_table_lookup(ht, tmp->str)))
- g_string_append(s, match);
- else {
-- gaim_debug(GAIM_DEBUG_ERROR, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "yahoo",
- "Unknown ansi code 'ESC[%sm'.\n", tmp->str);
- g_string_free(tmp, TRUE);
- break;
-@@ -335,7 +335,7 @@ char *yahoo_codes_to_html(const char *x)
-
- ret = s->str;
- g_string_free(s, FALSE);
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "yahoo_codes_to_html: Returning string: '%s'.\n", ret);
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "yahoo_codes_to_html: Returning string: '%s'.\n", ret);
- return ret;
- }
-
-@@ -717,7 +717,7 @@ char *yahoo_html_to_codes(const char *sr
- g_string_free(dest, FALSE);
-
- esc = g_strescape(ret, NULL);
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "yahoo_html_to_codes: Returning string: '%s'.\n", esc);
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "yahoo_html_to_codes: Returning string: '%s'.\n", esc);
- g_free(esc);
-
- yahoo_htc_queue_cleanup(colors);
-diff -prNu ./src/protocols/yahoo/yahoo.c ./src/protocols/yahoo/yahoo.c
---- ./src/protocols/yahoo/yahoo.c 2005-12-25 20:09:25.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -51,32 +51,32 @@
-
- /* #define YAHOO_DEBUG */
-
--static void yahoo_add_buddy(GaimConnection *gc, GaimBuddy *, GaimGroup *);
-+static void yahoo_add_buddy(Gaim2Connection *gc, Gaim2Buddy *, Gaim2Group *);
- static void yahoo_login_page_cb(void *user_data, const char *buf, size_t len);
--static void yahoo_set_status(GaimAccount *account, GaimStatus *status);
-+static void yahoo_set_status(Gaim2Account *account, Gaim2Status *status);
-
- static void
--yahoo_add_permit(GaimConnection *gc, const char *who)
-+yahoo_add_permit(Gaim2Connection *gc, const char *who)
- {
-- gaim_debug_info("yahoo",
-+ gaim2_debug_info("yahoo",
- "Permitting ID %s local contact rights for account %s\n", who, gc->account);
-- gaim_privacy_permit_add(gc->account,who,TRUE);
-+ gaim2_privacy_permit_add(gc->account,who,TRUE);
- }
-
- static void
--yahoo_rem_permit(GaimConnection *gc, const char *who)
-+yahoo_rem_permit(Gaim2Connection *gc, const char *who)
- {
-- gaim_debug_info("yahoo",
-+ gaim2_debug_info("yahoo",
- "Denying ID %s local contact rights for account %s\n", who, gc->account);
-- gaim_privacy_permit_remove(gc->account,who,TRUE);
-+ gaim2_privacy_permit_remove(gc->account,who,TRUE);
- }
-
--gboolean yahoo_privacy_check(GaimConnection *gc, const char *who)
-+gboolean yahoo_privacy_check(Gaim2Connection *gc, const char *who)
- {
- /* returns TRUE if allowed through, FALSE otherwise */
- gboolean permitted;
-
-- permitted = gaim_privacy_check(gc->account, who);
-+ permitted = gaim2_privacy_check(gc->account, who);
-
- /* print some debug info */
- if (!permitted) {
-@@ -94,11 +94,11 @@ gboolean yahoo_privacy_check(GaimConnect
- break;
- }
- if(deb)
-- gaim_debug_info("yahoo",
-+ gaim2_debug_info("yahoo",
- "%s blocked data received from %s (%s)\n",
- gc->account->username,who, deb);
- } else if (gc->account->perm_deny == GAIM_PRIVACY_ALLOW_USERS) {
-- gaim_debug_info("yahoo",
-+ gaim2_debug_info("yahoo",
- "%s allowed data received from %s (GAIM_PRIVACY_ALLOW_USERS)\n",
- gc->account->username,who);
- }
-@@ -106,11 +106,11 @@ gboolean yahoo_privacy_check(GaimConnect
- return permitted;
- }
-
--static void yahoo_update_status(GaimConnection *gc, const char *name, YahooFriend *f)
-+static void yahoo_update_status(Gaim2Connection *gc, const char *name, YahooFriend *f)
- {
- char *status = NULL;
-
-- if (!gc || !name || !f || !gaim_find_buddy(gaim_connection_get_account(gc), name))
-+ if (!gc || !name || !f || !gaim2_find_buddy(gaim2_connection_get_account(gc), name))
- return;
-
- if (f->status == YAHOO_STATUS_OFFLINE)
-@@ -162,27 +162,27 @@ static void yahoo_update_status(GaimConn
- status = YAHOO_STATUS_TYPE_AVAILABLE;
- break;
- default:
-- gaim_debug_warning("yahoo", "Warning, unknown status %d\n", f->status);
-+ gaim2_debug_warning("yahoo", "Warning, unknown status %d\n", f->status);
- break;
- }
-
- if (status) {
- if (f->status == YAHOO_STATUS_CUSTOM)
-- gaim_prpl_got_user_status(gaim_connection_get_account(gc), name, status, "message",
-+ gaim2_prpl_got_user_status(gaim2_connection_get_account(gc), name, status, "message",
- yahoo_friend_get_status_message(f), NULL);
- else
-- gaim_prpl_got_user_status(gaim_connection_get_account(gc), name, status, NULL);
-+ gaim2_prpl_got_user_status(gaim2_connection_get_account(gc), name, status, NULL);
- }
-
- if (f->idle != 0)
-- gaim_prpl_got_user_idle(gaim_connection_get_account(gc), name, TRUE, f->idle);
-+ gaim2_prpl_got_user_idle(gaim2_connection_get_account(gc), name, TRUE, f->idle);
- else
-- gaim_prpl_got_user_idle(gaim_connection_get_account(gc), name, FALSE, 0);
-+ gaim2_prpl_got_user_idle(gaim2_connection_get_account(gc), name, FALSE, 0);
- }
-
--static void yahoo_process_status(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_status(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
- GSList *l = pkt->hash;
- YahooFriend *f = NULL;
-@@ -190,7 +190,7 @@ static void yahoo_process_status(GaimCon
-
- if (pkt->service == YAHOO_SERVICE_LOGOFF && pkt->status == -1) {
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, _("You have signed on from another location."));
-+ gaim2_connection_error(gc, _("You have signed on from another location."));
- return;
- }
-
-@@ -202,14 +202,14 @@ static void yahoo_process_status(GaimCon
- break;
- case 1: /* we don't get the full buddy list here. */
- if (!yd->logged_in) {
-- gaim_connection_set_display_name(gc, pair->value);
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_display_name(gc, pair->value);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
- yd->logged_in = TRUE;
- if (yd->picture_upload_todo) {
- yahoo_buddy_icon_upload(gc, yd->picture_upload_todo);
- yd->picture_upload_todo = NULL;
- }
-- yahoo_set_status(account, gaim_account_get_active_status(account));
-+ yahoo_set_status(account, gaim2_account_get_active_status(account));
-
- /* this requests the list. i have a feeling that this is very evil
- *
-@@ -302,7 +302,7 @@ static void yahoo_process_status(GaimCon
- if (strtol(pair->value, NULL, 10) == 0) {
- if (f)
- f->status = YAHOO_STATUS_OFFLINE;
-- gaim_prpl_got_user_status(account, name, "offline", NULL);
-+ gaim2_prpl_got_user_status(account, name, "offline", NULL);
- break;
- }
- break;
-@@ -319,10 +319,10 @@ static void yahoo_process_status(GaimCon
- gsize len;
-
- if (pair->value) {
-- decoded = gaim_base64_decode(pair->value, &len);
-+ decoded = gaim2_base64_decode(pair->value, &len);
- if (len) {
-- tmp = gaim_str_binary_to_ascii(decoded, len);
-- gaim_debug_info("yahoo", "Got key 197, value = %s\n", tmp);
-+ tmp = gaim2_str_binary_to_ascii(decoded, len);
-+ gaim2_debug_info("yahoo", "Got key 197, value = %s\n", tmp);
- g_free(tmp);
- }
- g_free(decoded);
-@@ -332,19 +332,19 @@ static void yahoo_process_status(GaimCon
- case 192: /* Pictures, aka Buddy Icons, checksum */
- {
- int cksum = strtol(pair->value, NULL, 10);
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
-
- if (!name)
- break;
-
-- b = gaim_find_buddy(gc->account, name);
-+ b = gaim2_find_buddy(gc->account, name);
-
- if (!cksum || (cksum == -1)) {
- if (f)
- yahoo_friend_set_buddy_icon_need_request(f, TRUE);
-- gaim_buddy_icons_set_for_user(gc->account, name, NULL, 0);
-+ gaim2_buddy_icons_set_for_user(gc->account, name, NULL, 0);
- if (b)
-- gaim_blist_node_remove_setting((GaimBlistNode *)b, YAHOO_ICON_CHECKSUM_KEY);
-+ gaim2_blist_node_remove_setting((Gaim2BlistNode *)b, YAHOO_ICON_CHECKSUM_KEY);
- break;
- }
-
-@@ -352,7 +352,7 @@ static void yahoo_process_status(GaimCon
- break;
-
- yahoo_friend_set_buddy_icon_need_request(f, FALSE);
-- if (cksum != gaim_blist_node_get_int((GaimBlistNode*)b, YAHOO_ICON_CHECKSUM_KEY))
-+ if (cksum != gaim2_blist_node_get_int((Gaim2BlistNode*)b, YAHOO_ICON_CHECKSUM_KEY))
- yahoo_send_picture_request(gc, name);
-
- break;
-@@ -360,12 +360,12 @@ static void yahoo_process_status(GaimCon
- case 16: /* Custom error message */
- {
- char *tmp = yahoo_string_decode(gc, pair->value, TRUE);
-- gaim_notify_error(gc, NULL, tmp, NULL);
-+ gaim2_notify_error(gc, NULL, tmp, NULL);
- g_free(tmp);
- }
- break;
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "yahoo",
- "Unknown status key %d\n", pair->key);
- break;
- }
-@@ -377,26 +377,26 @@ static void yahoo_process_status(GaimCon
- yahoo_update_status(gc, name, f);
- }
-
--static void yahoo_do_group_check(GaimAccount *account, GHashTable *ht, const char *name, const char *group)
-+static void yahoo_do_group_check(Gaim2Account *account, GHashTable *ht, const char *name, const char *group)
- {
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
- GSList *list, *i;
- gboolean onlist = 0;
- char *oname = NULL;
- char **oname_p = &oname;
- GSList **list_p = &list;
-
-- if (!g_hash_table_lookup_extended(ht, gaim_normalize(account, name), (gpointer *) oname_p, (gpointer *) list_p))
-- list = gaim_find_buddies(account, name);
-+ if (!g_hash_table_lookup_extended(ht, gaim2_normalize(account, name), (gpointer *) oname_p, (gpointer *) list_p))
-+ list = gaim2_find_buddies(account, name);
- else
- g_hash_table_steal(ht, name);
-
- for (i = list; i; i = i->next) {
- b = i->data;
-- g = gaim_buddy_get_group(b);
-- if (!gaim_utf8_strcasecmp(group, g->name)) {
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ g = gaim2_buddy_get_group(b);
-+ if (!gaim2_utf8_strcasecmp(group, g->name)) {
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "Oh good, %s is in the right group (%s).\n", name, group);
- list = g_slist_delete_link(list, i);
- onlist = 1;
-@@ -405,19 +405,19 @@ static void yahoo_do_group_check(GaimAcc
- }
-
- if (!onlist) {
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "Uhoh, %s isn't on the list (or not in this group), adding him to group %s.\n", name, group);
-- if (!(g = gaim_find_group(group))) {
-- g = gaim_group_new(group);
-- gaim_blist_add_group(g, NULL);
-+ if (!(g = gaim2_find_group(group))) {
-+ g = gaim2_group_new(group);
-+ gaim2_blist_add_group(g, NULL);
- }
-- b = gaim_buddy_new(account, name, NULL);
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ b = gaim2_buddy_new(account, name, NULL);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- }
-
- if (list) {
- if (!oname)
-- oname = g_strdup(gaim_normalize(account, name));
-+ oname = g_strdup(gaim2_normalize(account, name));
- g_hash_table_insert(ht, oname, list);
- } else if (oname)
- g_free(oname);
-@@ -427,14 +427,14 @@ static void yahoo_do_group_cleanup(gpoin
- {
- char *name = key;
- GSList *list = value, *i;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
-
- for (i = list; i; i = i->next) {
- b = i->data;
-- g = gaim_buddy_get_group(b);
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "Deleting Buddy %s from group %s.\n", name, g->name);
-- gaim_blist_remove_buddy(b);
-+ g = gaim2_buddy_get_group(b);
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "Deleting Buddy %s from group %s.\n", name, g->name);
-+ gaim2_blist_remove_buddy(b);
- }
- }
-
-@@ -471,15 +471,15 @@ static void yahoo_process_cookie(struct
- }
- }
-
--static void yahoo_process_list(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_list(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- gboolean export = FALSE;
- gboolean got_serv_list = FALSE;
-- GaimBuddy *b;
-- GaimGroup *g;
-+ Gaim2Buddy *b;
-+ Gaim2Group *g;
- YahooFriend *f = NULL;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
- GHashTable *ht;
-
-@@ -539,16 +539,16 @@ static void yahoo_process_list(GaimConne
- grp = yahoo_string_decode(gc, split[0], FALSE);
- buddies = g_strsplit(split[1], ",", -1);
- for (bud = buddies; bud && *bud; bud++) {
-- norm_bud = g_strdup(gaim_normalize(account, *bud));
-+ norm_bud = g_strdup(gaim2_normalize(account, *bud));
- f = yahoo_friend_find_or_new(gc, norm_bud);
-
-- if (!(b = gaim_find_buddy(account, norm_bud))) {
-- if (!(g = gaim_find_group(grp))) {
-- g = gaim_group_new(grp);
-- gaim_blist_add_group(g, NULL);
-+ if (!(b = gaim2_find_buddy(account, norm_bud))) {
-+ if (!(g = gaim2_find_group(grp))) {
-+ g = gaim2_group_new(grp);
-+ gaim2_blist_add_group(g, NULL);
- }
-- b = gaim_buddy_new(account, norm_bud, NULL);
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ b = gaim2_buddy_new(account, norm_bud, NULL);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- export = TRUE;
- }
-
-@@ -572,7 +572,7 @@ static void yahoo_process_list(GaimConne
- for (bud = buddies; bud && *bud; bud++) {
- /* The server is already ignoring the user */
- got_serv_list = TRUE;
-- gaim_privacy_deny_add(gc->account, *bud, 1);
-+ gaim2_privacy_deny_add(gc->account, *bud, 1);
- }
- g_strfreev(buddies);
-
-@@ -586,7 +586,7 @@ static void yahoo_process_list(GaimConne
- (gc->account->perm_deny != GAIM_PRIVACY_ALLOW_USERS)))
- {
- gc->account->perm_deny = GAIM_PRIVACY_DENY_USERS;
-- gaim_debug_info("yahoo", "%s privacy defaulting to GAIM_PRIVACY_DENY_USERS.\n",
-+ gaim2_debug_info("yahoo", "%s privacy defaulting to GAIM_PRIVACY_DENY_USERS.\n",
- gc->account->username);
- }
-
-@@ -595,7 +595,7 @@ static void yahoo_process_list(GaimConne
- for (bud = buddies; bud && *bud; bud++) {
- f = yahoo_friend_find(gc, *bud);
- if (f) {
-- gaim_debug_info("yahoo", "%s setting presence for %s to PERM_OFFLINE\n",
-+ gaim2_debug_info("yahoo", "%s setting presence for %s to PERM_OFFLINE\n",
- gc->account->username, *bud);
- f->presence = YAHOO_PRESENCE_PERM_OFFLINE;
- }
-@@ -607,7 +607,7 @@ static void yahoo_process_list(GaimConne
- }
- }
-
--static void yahoo_process_notify(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_notify(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *msg = NULL;
- char *from = NULL;
-@@ -639,10 +639,10 @@ static void yahoo_process_notify(GaimCon
- else
- serv_got_typing_stopped(gc, from);
- } else if (!g_ascii_strncasecmp(msg, "GAME", strlen("GAME"))) {
-- GaimBuddy *bud = gaim_find_buddy(gc->account, from);
-+ Gaim2Buddy *bud = gaim2_find_buddy(gc->account, from);
-
- if (!bud) {
-- gaim_debug(GAIM_DEBUG_WARNING, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_WARNING, "yahoo",
- "%s is playing a game, and doesn't want "
- "you to know.\n", from);
- }
-@@ -670,7 +670,7 @@ struct _yahoo_im {
- char *msg;
- };
-
--static void yahoo_process_message(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_message(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- GSList *list = NULL;
-@@ -708,26 +708,26 @@ static void yahoo_process_message(GaimCo
- l = l->next;
- }
- } else if (pkt->status == 2) {
-- gaim_notify_error(gc, NULL,
-+ gaim2_notify_error(gc, NULL,
- _("Your Yahoo! message did not get sent."), NULL);
- }
-
- /* Check for the Doodle IMV */
- if(!strcmp(imv, "doodle;11"))
- {
-- GaimWhiteboard *wb;
-+ Gaim2Whiteboard *wb;
-
- if (!yahoo_privacy_check(gc, im->from)) {
-- gaim_debug_info("yahoo", "Doodle request from %s dropped.\n", im->from);
-+ gaim2_debug_info("yahoo", "Doodle request from %s dropped.\n", im->from);
- return;
- }
-
-- wb = gaim_whiteboard_get_session(gc->account, im->from);
-+ wb = gaim2_whiteboard_get_session(gc->account, im->from);
-
- /* If a Doodle session doesn't exist between this user */
- if(wb == NULL)
- {
-- wb = gaim_whiteboard_create(gc->account, im->from, DOODLE_STATE_REQUESTED);
-+ wb = gaim2_whiteboard_create(gc->account, im->from, DOODLE_STATE_REQUESTED);
-
- yahoo_doodle_command_send_request(gc, im->from);
- yahoo_doodle_command_send_ready(gc, im->from);
-@@ -745,17 +745,17 @@ static void yahoo_process_message(GaimCo
- }
-
- if (!yahoo_privacy_check(gc, im->from)) {
-- gaim_debug_info("yahoo", "Message from %s dropped.\n", im->from);
-+ gaim2_debug_info("yahoo", "Message from %s dropped.\n", im->from);
- return;
- }
-
- m = yahoo_string_decode(gc, im->msg, im->utf8);
-- gaim_str_strip_char(m, '\r');
-+ gaim2_str_strip_char(m, '\r');
-
- if (!strcmp(m, "<ding>")) {
-- GaimConversation *c = gaim_conversation_new(GAIM_CONV_TYPE_IM,
-- gaim_connection_get_account(gc), im->from);
-- gaim_conv_im_write(GAIM_CONV_IM(c), "", _("Buzz!!"), GAIM_MESSAGE_NICK|GAIM_MESSAGE_RECV,
-+ Gaim2Conversation *c = gaim2_conversation_new(GAIM_CONV_TYPE_IM,
-+ gaim2_connection_get_account(gc), im->from);
-+ gaim2_conv_im_write(GAIM_CONV_IM(c), "", _("Buzz!!"), GAIM_MESSAGE_NICK|GAIM_MESSAGE_RECV,
- im->time);
- g_free(m);
- g_free(im);
-@@ -779,7 +779,7 @@ static void yahoo_process_message(GaimCo
- g_slist_free(list);
- }
-
--static void yahoo_process_sysmessage(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_sysmessage(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- char *prim, *me = NULL, *msg = NULL, *escmsg = NULL;
-@@ -801,14 +801,14 @@ static void yahoo_process_sysmessage(Gai
- escmsg = g_markup_escape_text(msg, -1);
-
- prim = g_strdup_printf(_("Yahoo! system message for %s:"),
-- me?me:gaim_connection_get_display_name(gc));
-- gaim_notify_info(NULL, NULL, prim, escmsg);
-+ me?me:gaim2_connection_get_display_name(gc));
-+ gaim2_notify_info(NULL, NULL, prim, escmsg);
- g_free(prim);
- g_free(escmsg);
- }
-
- struct yahoo_add_request {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *id;
- char *who;
- char *msg;
-@@ -816,13 +816,13 @@ struct yahoo_add_request {
-
- static void
- yahoo_buddy_add_authorize_cb(struct yahoo_add_request *add_req, const char *msg) {
-- GaimBuddy *buddy = gaim_find_buddy(add_req->gc->account, add_req->who);
-+ Gaim2Buddy *buddy = gaim2_find_buddy(add_req->gc->account, add_req->who);
-
- if (buddy != NULL)
-- gaim_account_notify_added(add_req->gc->account, add_req->who,
-+ gaim2_account_notify_added(add_req->gc->account, add_req->who,
- add_req->id, NULL, add_req->msg);
- else
-- gaim_account_request_add(add_req->gc->account, add_req->who,
-+ gaim2_account_request_add(add_req->gc->account, add_req->who,
- add_req->id, NULL, add_req->msg);
-
- g_free(add_req->id);
-@@ -844,9 +844,9 @@ yahoo_buddy_add_deny_cb(struct yahoo_add
- YAHOO_STATUS_AVAILABLE, 0);
-
- yahoo_packet_hash(pkt, "sss",
-- 1, gaim_normalize(add_req->gc->account,
-- gaim_account_get_username(
-- gaim_connection_get_account(
-+ 1, gaim2_normalize(add_req->gc->account,
-+ gaim2_account_get_username(
-+ gaim2_connection_get_account(
- add_req->gc))),
- 7, add_req->who,
- 14, encoded_msg ? encoded_msg : "");
-@@ -861,7 +861,7 @@ yahoo_buddy_add_deny_cb(struct yahoo_add
- g_free(add_req);
- }
-
--static void yahoo_buddy_added_us(GaimConnection *gc, struct yahoo_packet *pkt) {
-+static void yahoo_buddy_added_us(Gaim2Connection *gc, struct yahoo_packet *pkt) {
- struct yahoo_add_request *add_req;
- char *msg = NULL;
- GSList *l = pkt->hash;
-@@ -901,7 +901,7 @@ static void yahoo_buddy_added_us(GaimCon
- add_req->who, add_req->id,
- add_req->msg ? ": " : "",
- add_req->msg ? add_req->msg : "");
-- gaim_request_input(gc, NULL, prompt_msg,
-+ gaim2_request_input(gc, NULL, prompt_msg,
- _("Message (optional) :"),
- NULL, TRUE, FALSE, NULL,
- _("Authorize"), G_CALLBACK(
-@@ -918,7 +918,7 @@ static void yahoo_buddy_added_us(GaimCon
- }
- }
-
--static void yahoo_buddy_denied_our_add(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_buddy_denied_our_add(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *who = NULL;
- char *msg = NULL;
-@@ -950,15 +950,15 @@ static void yahoo_buddy_denied_our_add(G
- g_string_printf(buf, _("%s has (retroactively) denied your request to add them to your list for the following reason: %s."), who, msg2);
- g_free(msg2);
- }
-- gaim_notify_info(gc, NULL, _("Add buddy rejected"), buf->str);
-+ gaim2_notify_info(gc, NULL, _("Add buddy rejected"), buf->str);
- g_string_free(buf, TRUE);
- g_hash_table_remove(yd->friends, who);
-- gaim_prpl_got_user_status(gaim_connection_get_account(gc), who, "offline", NULL); /* FIXME: make this set not on list status instead */
-+ gaim2_prpl_got_user_status(gaim2_connection_get_account(gc), who, "offline", NULL); /* FIXME: make this set not on list status instead */
- /* TODO: Shouldn't we remove the buddy from our local list? */
- }
- }
-
--static void yahoo_process_contact(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_contact(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- switch (pkt->status) {
- case 1:
-@@ -1028,9 +1028,9 @@ static char *yahoo_decode(const char *te
- return converted;
- }
-
--static void yahoo_process_mail(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_mail(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
- char *who = NULL;
- char *email = NULL;
-@@ -1039,7 +1039,7 @@ static void yahoo_process_mail(GaimConne
- int count = 0;
- GSList *l = pkt->hash;
-
-- if (!gaim_account_get_check_mail(account))
-+ if (!gaim2_account_get_check_mail(account))
- return;
-
- while (l) {
-@@ -1060,17 +1060,17 @@ static void yahoo_process_mail(GaimConne
- char *dec_subj = yahoo_decode(subj);
- char *from = g_strdup_printf("%s (%s)", dec_who, email);
-
-- gaim_notify_email(gc, dec_subj, from, gaim_account_get_username(account),
-+ gaim2_notify_email(gc, dec_subj, from, gaim2_account_get_username(account),
- yahoo_mail_url, NULL, NULL);
-
- g_free(dec_who);
- g_free(dec_subj);
- g_free(from);
- } else if (count > 0) {
-- const char *to = gaim_account_get_username(account);
-+ const char *to = gaim2_account_get_username(account);
- const char *url = yahoo_mail_url;
-
-- gaim_notify_emails(gc, count, FALSE, NULL, NULL, &to, &url,
-+ gaim2_notify_emails(gc, count, FALSE, NULL, NULL, &to, &url,
- NULL, NULL);
- }
- }
-@@ -1105,12 +1105,12 @@ static void to_y64(char *out, const unsi
- *out = '\0';
- }
-
--static void yahoo_process_auth_old(GaimConnection *gc, const char *seed)
-+static void yahoo_process_auth_old(Gaim2Connection *gc, const char *seed)
- {
- struct yahoo_packet *pack;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- const char *name = gaim_normalize(account, gaim_account_get_username(account));
-- const char *pass = gaim_connection_get_password(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ const char *name = gaim2_normalize(account, gaim2_account_get_username(account));
-+ const char *pass = gaim2_connection_get_password(gc);
- struct yahoo_data *yd = gc->proto_data;
-
- /* So, Yahoo has stopped supporting its older clients in India, and undoubtedly
-@@ -1124,8 +1124,8 @@ static void yahoo_process_auth_old(GaimC
- * Sorry, Yahoo.
- */
-
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar digest[16];
-
- char *crypt_result;
-@@ -1144,19 +1144,19 @@ static void yahoo_process_auth_old(GaimC
- sv = seed[15];
- sv = sv % 8;
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
-- gaim_cipher_context_append(context, (const guchar *)pass, strlen(pass));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)pass, strlen(pass));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
-
- to_y64(password_hash, digest, 16);
-
- crypt_result = yahoo_crypt(pass, "$1$_2S43d5f$");
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)crypt_result, strlen(crypt_result));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)crypt_result, strlen(crypt_result));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
- to_y64(crypt_hash, digest, 16);
-
- switch (sv) {
-@@ -1200,15 +1200,15 @@ static void yahoo_process_auth_old(GaimC
- break;
- }
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)hash_string_p, strlen(hash_string_p));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)hash_string_p, strlen(hash_string_p));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
- to_y64(result6, digest, 16);
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)hash_string_c, strlen(hash_string_c));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)hash_string_c, strlen(hash_string_c));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_destroy(context);
- to_y64(result96, digest, 16);
-
- pack = yahoo_packet_new(YAHOO_SERVICE_AUTHRESP, YAHOO_STATUS_AVAILABLE, 0);
-@@ -1222,21 +1222,21 @@ static void yahoo_process_auth_old(GaimC
- /* I'm dishing out some uber-mad props to Cerulean Studios for cracking this
- * and sending the fix! Thanks guys. */
-
--static void yahoo_process_auth_new(GaimConnection *gc, const char *seed)
-+static void yahoo_process_auth_new(Gaim2Connection *gc, const char *seed)
- {
- struct yahoo_packet *pack = NULL;
-- GaimAccount *account = gaim_connection_get_account(gc);
-- const char *name = gaim_normalize(account, gaim_account_get_username(account));
-- const char *pass = gaim_connection_get_password(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ const char *name = gaim2_normalize(account, gaim2_account_get_username(account));
-+ const char *pass = gaim2_connection_get_password(gc);
- struct yahoo_data *yd = gc->proto_data;
-
-- GaimCipher *md5_cipher;
-- GaimCipherContext *md5_ctx;
-+ Gaim2Cipher *md5_cipher;
-+ Gaim2CipherContext *md5_ctx;
- guchar md5_digest[16];
-
-- GaimCipher *sha1_cipher;
-- GaimCipherContext *sha1_ctx1;
-- GaimCipherContext *sha1_ctx2;
-+ Gaim2Cipher *sha1_cipher;
-+ Gaim2CipherContext *sha1_ctx1;
-+ Gaim2CipherContext *sha1_ctx2;
-
- char *alphabet1 = "FBZDWAGHrJTLMNOPpRSKUVEXYChImkwQ";
- char *alphabet2 = "F0E1D2C3B4A59687abcdefghijklmnop";
-@@ -1286,12 +1286,12 @@ static void yahoo_process_auth_new(GaimC
- memset(&magic_key_char, 0, 4);
- memset(&comparison_src, 0, 20);
-
-- md5_cipher = gaim_ciphers_find_cipher("md5");
-- md5_ctx = gaim_cipher_context_new(md5_cipher, NULL);
-+ md5_cipher = gaim2_ciphers_find_cipher("md5");
-+ md5_ctx = gaim2_cipher_context_new(md5_cipher, NULL);
-
-- sha1_cipher = gaim_ciphers_find_cipher("sha1");
-- sha1_ctx1 = gaim_cipher_context_new(sha1_cipher, NULL);
-- sha1_ctx2 = gaim_cipher_context_new(sha1_cipher, NULL);
-+ sha1_cipher = gaim2_ciphers_find_cipher("sha1");
-+ sha1_ctx1 = gaim2_cipher_context_new(sha1_cipher, NULL);
-+ sha1_ctx2 = gaim2_cipher_context_new(sha1_cipher, NULL);
-
- /*
- * Magic: Phase 1. Generate what seems to be a 30 byte value (could change if base64
-@@ -1427,10 +1427,10 @@ static void yahoo_process_auth_new(GaimC
- test[1] = x >> 8;
- test[2] = y;
-
-- gaim_cipher_context_reset(md5_ctx, NULL);
-- gaim_cipher_context_append(md5_ctx, magic_key_char, 4);
-- gaim_cipher_context_append(md5_ctx, test, 3);
-- gaim_cipher_context_digest(md5_ctx, sizeof(md5_digest),
-+ gaim2_cipher_context_reset(md5_ctx, NULL);
-+ gaim2_cipher_context_append(md5_ctx, magic_key_char, 4);
-+ gaim2_cipher_context_append(md5_ctx, test, 3);
-+ gaim2_cipher_context_digest(md5_ctx, sizeof(md5_digest),
- md5_digest, NULL);
-
- if (!memcmp(md5_digest, comparison_src+4, 16)) {
-@@ -1460,16 +1460,16 @@ static void yahoo_process_auth_new(GaimC
- }
-
- /* Get password and crypt hashes as per usual. */
-- gaim_cipher_context_reset(md5_ctx, NULL);
-- gaim_cipher_context_append(md5_ctx, (const guchar *)pass, strlen(pass));
-- gaim_cipher_context_digest(md5_ctx, sizeof(md5_digest),
-+ gaim2_cipher_context_reset(md5_ctx, NULL);
-+ gaim2_cipher_context_append(md5_ctx, (const guchar *)pass, strlen(pass));
-+ gaim2_cipher_context_digest(md5_ctx, sizeof(md5_digest),
- md5_digest, NULL);
- to_y64(password_hash, md5_digest, 16);
-
- crypt_result = yahoo_crypt(pass, "$1$_2S43d5f$");
-- gaim_cipher_context_reset(md5_ctx, NULL);
-- gaim_cipher_context_append(md5_ctx, (const guchar *)crypt_result, strlen(crypt_result));
-- gaim_cipher_context_digest(md5_ctx, sizeof(md5_digest),
-+ gaim2_cipher_context_reset(md5_ctx, NULL);
-+ gaim2_cipher_context_append(md5_ctx, (const guchar *)crypt_result, strlen(crypt_result));
-+ gaim2_cipher_context_digest(md5_ctx, sizeof(md5_digest),
- md5_digest, NULL);
- to_y64(crypt_hash, md5_digest, 16);
-
-@@ -1493,20 +1493,20 @@ static void yahoo_process_auth_new(GaimC
- * which we previously extrapolated from our challenge.
- */
-
-- gaim_cipher_context_append(sha1_ctx1, pass_hash_xor1, 64);
-+ gaim2_cipher_context_append(sha1_ctx1, pass_hash_xor1, 64);
- if (y >= 3)
-- gaim_cipher_context_set_option(sha1_ctx1, "sizeLo", GINT_TO_POINTER(0x1ff));
-- gaim_cipher_context_append(sha1_ctx1, magic_key_char, 4);
-- gaim_cipher_context_digest(sha1_ctx1, sizeof(digest1), digest1, NULL);
-+ gaim2_cipher_context_set_option(sha1_ctx1, "sizeLo", GINT_TO_POINTER(0x1ff));
-+ gaim2_cipher_context_append(sha1_ctx1, magic_key_char, 4);
-+ gaim2_cipher_context_digest(sha1_ctx1, sizeof(digest1), digest1, NULL);
-
- /*
- * The second context gets the password hash XORed with 0x5c plus the SHA-1 digest
- * of the first context.
- */
-
-- gaim_cipher_context_append(sha1_ctx2, pass_hash_xor2, 64);
-- gaim_cipher_context_append(sha1_ctx2, digest1, 20);
-- gaim_cipher_context_digest(sha1_ctx2, sizeof(digest2), digest2, NULL);
-+ gaim2_cipher_context_append(sha1_ctx2, pass_hash_xor2, 64);
-+ gaim2_cipher_context_append(sha1_ctx2, digest1, 20);
-+ gaim2_cipher_context_digest(sha1_ctx2, sizeof(digest2), digest2, NULL);
-
- /*
- * Now that we have digest2, use it to fetch characters from an alphabet to construct
-@@ -1576,30 +1576,30 @@ static void yahoo_process_auth_new(GaimC
- if (cnt < 64)
- memset(&(crypt_hash_xor2[cnt]), 0x5c, 64-cnt);
-
-- gaim_cipher_context_reset(sha1_ctx1, NULL);
-- gaim_cipher_context_reset(sha1_ctx2, NULL);
-+ gaim2_cipher_context_reset(sha1_ctx1, NULL);
-+ gaim2_cipher_context_reset(sha1_ctx2, NULL);
-
- /*
- * The first context gets the password hash XORed with 0x36 plus a magic value
- * which we previously extrapolated from our challenge.
- */
-
-- gaim_cipher_context_append(sha1_ctx1, crypt_hash_xor1, 64);
-+ gaim2_cipher_context_append(sha1_ctx1, crypt_hash_xor1, 64);
- if (y >= 3) {
-- gaim_cipher_context_set_option(sha1_ctx1, "sizeLo",
-+ gaim2_cipher_context_set_option(sha1_ctx1, "sizeLo",
- GINT_TO_POINTER(0x1ff));
- }
-- gaim_cipher_context_append(sha1_ctx1, magic_key_char, 4);
-- gaim_cipher_context_digest(sha1_ctx1, sizeof(digest1), digest1, NULL);
-+ gaim2_cipher_context_append(sha1_ctx1, magic_key_char, 4);
-+ gaim2_cipher_context_digest(sha1_ctx1, sizeof(digest1), digest1, NULL);
-
- /*
- * The second context gets the password hash XORed with 0x5c plus the SHA-1 digest
- * of the first context.
- */
-
-- gaim_cipher_context_append(sha1_ctx2, crypt_hash_xor2, 64);
-- gaim_cipher_context_append(sha1_ctx2, digest1, 20);
-- gaim_cipher_context_digest(sha1_ctx2, sizeof(digest2), digest2, NULL);
-+ gaim2_cipher_context_append(sha1_ctx2, crypt_hash_xor2, 64);
-+ gaim2_cipher_context_append(sha1_ctx2, digest1, 20);
-+ gaim2_cipher_context_digest(sha1_ctx2, sizeof(digest2), digest2, NULL);
-
- /*
- * Now that we have digest2, use it to fetch characters from an alphabet to construct
-@@ -1648,7 +1648,7 @@ static void yahoo_process_auth_new(GaimC
- sprintf(byte, "%c", delimit_lookup[lookup]);
- strcat(resp_96, byte);
- }
-- gaim_debug_info("yahoo", "yahoo status: %d\n", yd->current_status);
-+ gaim2_debug_info("yahoo", "yahoo status: %d\n", yd->current_status);
- pack = yahoo_packet_new(YAHOO_SERVICE_AUTHRESP, yd->current_status, 0);
- yahoo_packet_hash(pack, "sssss", 0, name, 6, resp_6, 96, resp_96, 1,
- name, 135, "6,0,0,1710");
-@@ -1657,15 +1657,15 @@ static void yahoo_process_auth_new(GaimC
-
- yahoo_packet_send_and_free(pack, yd);
-
-- gaim_cipher_context_destroy(md5_ctx);
-- gaim_cipher_context_destroy(sha1_ctx1);
-- gaim_cipher_context_destroy(sha1_ctx2);
-+ gaim2_cipher_context_destroy(md5_ctx);
-+ gaim2_cipher_context_destroy(sha1_ctx1);
-+ gaim2_cipher_context_destroy(sha1_ctx2);
-
- g_free(password_hash);
- g_free(crypt_hash);
- }
-
--static void yahoo_process_auth(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_auth(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *seed = NULL;
- char *sn = NULL;
-@@ -1694,9 +1694,9 @@ static void yahoo_process_auth(GaimConne
- break;
- default:
- buf = g_strdup_printf(_("The Yahoo server has requested the use of an unrecognized "
-- "authentication method. This version of Gaim will likely not be able "
-+ "authentication method. This version of Gaim2 will likely not be able "
- "to successfully sign on to Yahoo. Check %s for updates."), GAIM_WEBSITE);
-- gaim_notify_error(gc, "", _("Failed Yahoo! Authentication"),
-+ gaim2_notify_error(gc, "", _("Failed Yahoo! Authentication"),
- buf);
- g_free(buf);
- yahoo_process_auth_new(gc, seed); /* Can't hurt to try it anyway. */
-@@ -1704,41 +1704,41 @@ static void yahoo_process_auth(GaimConne
- }
- }
-
--static void ignore_buddy(GaimBuddy *buddy) {
-- GaimGroup *group;
-- GaimConversation *conv;
-- GaimAccount *account;
-+static void ignore_buddy(Gaim2Buddy *buddy) {
-+ Gaim2Group *group;
-+ Gaim2Conversation *conv;
-+ Gaim2Account *account;
- gchar *name;
-
- if (!buddy)
- return;
-
-- group = gaim_buddy_get_group(buddy);
-+ group = gaim2_buddy_get_group(buddy);
- name = g_strdup(buddy->name);
- account = buddy->account;
-
-- gaim_debug(GAIM_DEBUG_INFO, "blist",
-+ gaim2_debug(GAIM_DEBUG_INFO, "blist",
- "Removing '%s' from buddy list.\n", buddy->name);
-- gaim_account_remove_buddy(account, buddy, group);
-- gaim_blist_remove_buddy(buddy);
-+ gaim2_account_remove_buddy(account, buddy, group);
-+ gaim2_blist_remove_buddy(buddy);
-
- serv_add_deny(account->gc, name);
-
- /* The follow should really be done by the core... */
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, account);
-
- if (conv != NULL)
-- gaim_conversation_update(conv, GAIM_CONV_UPDATE_REMOVE);
-+ gaim2_conversation_update(conv, GAIM_CONV_UPDATE_REMOVE);
-
- g_free(name);
- }
-
--static void keep_buddy(GaimBuddy *b) {
-- gaim_privacy_deny_remove(b->account, b->name, 1);
-+static void keep_buddy(Gaim2Buddy *b) {
-+ gaim2_privacy_deny_remove(b->account, b->name, 1);
- }
-
--static void yahoo_process_ignore(GaimConnection *gc, struct yahoo_packet *pkt) {
-- GaimBuddy *b;
-+static void yahoo_process_ignore(Gaim2Connection *gc, struct yahoo_packet *pkt) {
-+ Gaim2Buddy *b;
- GSList *l;
- gchar *who = NULL;
- gchar *sn = NULL;
-@@ -1768,11 +1768,11 @@ static void yahoo_process_ignore(GaimCon
-
- switch (status) {
- case 12:
-- b = gaim_find_buddy(gc->account, who);
-+ b = gaim2_find_buddy(gc->account, who);
- g_snprintf(buf, sizeof(buf), _("You have tried to ignore %s, but the "
- "user is on your buddy list. Clicking \"Yes\" "
- "will remove and ignore the buddy."), who);
-- gaim_request_yes_no(gc, NULL, _("Ignore buddy?"), buf, 0, b,
-+ gaim2_request_yes_no(gc, NULL, _("Ignore buddy?"), buf, 0, b,
- G_CALLBACK(ignore_buddy),
- G_CALLBACK(keep_buddy));
- break;
-@@ -1784,7 +1784,7 @@ static void yahoo_process_ignore(GaimCon
- }
- }
-
--static void yahoo_process_authresp(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_authresp(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- struct yahoo_data *yd = gc->proto_data;
- GSList *l = pkt->hash;
-@@ -1814,14 +1814,14 @@ static void yahoo_process_authresp(GaimC
- if (yd->fd >= 0)
- close(yd->fd);
- if (gc->inpa)
-- gaim_input_remove(gc->inpa);
-- gaim_url_fetch(WEBMESSENGER_URL, TRUE, "Gaim/" VERSION, FALSE,
-+ gaim2_input_remove(gc->inpa);
-+ gaim2_url_fetch(WEBMESSENGER_URL, TRUE, "Gaim2/" VERSION, FALSE,
- yahoo_login_page_cb, gc);
-- gaim_notify_warning(gc, NULL, _("Normal authentication failed!"),
-+ gaim2_notify_warning(gc, NULL, _("Normal authentication failed!"),
- _("The normal authentication method has failed. "
- "This means either your password is incorrect, "
- "or Yahoo!'s authentication scheme has changed. "
-- "Gaim will now attempt to log in using Web "
-+ "Gaim2 will now attempt to log in using Web "
- "Messenger authentication, which will result "
- "in reduced functionality and features."));
- return;
-@@ -1841,12 +1841,12 @@ static void yahoo_process_authresp(GaimC
- fullmsg = g_strdup(msg);
-
- gc->wants_to_die = TRUE;
-- gaim_connection_error(gc, fullmsg);
-+ gaim2_connection_error(gc, fullmsg);
- g_free(msg);
- g_free(fullmsg);
- }
-
--static void yahoo_process_addbuddy(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_addbuddy(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- int err = 0;
- char *who = NULL;
-@@ -1887,14 +1887,14 @@ static void yahoo_process_addbuddy(GaimC
-
- decoded_group = yahoo_string_decode(gc, group, FALSE);
- buf = g_strdup_printf(_("Could not add buddy %s to group %s to the server list on account %s."),
-- who, decoded_group, gaim_connection_get_display_name(gc));
-- if (!gaim_conv_present_error(who, gaim_connection_get_account(gc), buf))
-- gaim_notify_error(gc, NULL, _("Could not add buddy to server list"), buf);
-+ who, decoded_group, gaim2_connection_get_display_name(gc));
-+ if (!gaim2_conv_present_error(who, gaim2_connection_get_account(gc), buf))
-+ gaim2_notify_error(gc, NULL, _("Could not add buddy to server list"), buf);
- g_free(buf);
- g_free(decoded_group);
- }
-
--static void yahoo_process_p2p(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_p2p(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- char *who = NULL;
-@@ -1940,10 +1940,10 @@ static void yahoo_process_p2p(GaimConnec
- char *tmp2;
- YahooFriend *f;
-
-- decoded = gaim_base64_decode(base64, &len);
-+ decoded = gaim2_base64_decode(base64, &len);
- if (len) {
-- char *tmp = gaim_str_binary_to_ascii(decoded, len);
-- gaim_debug_info("yahoo", "Got P2P service packet (from server): who = %s, ip = %s\n", who, tmp);
-+ char *tmp = gaim2_str_binary_to_ascii(decoded, len);
-+ gaim2_debug_info("yahoo", "Got P2P service packet (from server): who = %s, ip = %s\n", who, tmp);
- g_free(tmp);
- }
-
-@@ -1960,7 +1960,7 @@ static void yahoo_process_p2p(GaimConnec
- }
- }
-
--static void yahoo_process_audible(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_process_audible(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *who = NULL, *msg = NULL;
- GSList *l = pkt->hash;
-@@ -1993,18 +1993,18 @@ static void yahoo_process_audible(GaimCo
- if (!who || !msg)
- return;
- if (!g_utf8_validate(msg, -1, NULL)) {
-- gaim_debug_misc("yahoo", "Warning, nonutf8 audible, ignoring!\n");
-+ gaim2_debug_misc("yahoo", "Warning, nonutf8 audible, ignoring!\n");
- return;
- }
- if (!yahoo_privacy_check(gc, who)) {
-- gaim_debug_misc("yahoo", "Audible message from %s for %s dropped!\n",
-+ gaim2_debug_misc("yahoo", "Audible message from %s for %s dropped!\n",
- gc->account->username, who);
- return;
- }
- serv_got_im(gc, who, msg, 0, time(NULL));
- }
-
--static void yahoo_packet_process(GaimConnection *gc, struct yahoo_packet *pkt)
-+static void yahoo_packet_process(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- switch (pkt->service) {
- case YAHOO_SERVICE_LOGON:
-@@ -2117,15 +2117,15 @@ static void yahoo_packet_process(GaimCon
- case YAHOO_SERVICE_AUDIBLE:
- yahoo_process_audible(gc, pkt);
- default:
-- gaim_debug(GAIM_DEBUG_ERROR, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "yahoo",
- "Unhandled service 0x%02x\n", pkt->service);
- break;
- }
- }
-
--static void yahoo_pending(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_pending(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct yahoo_data *yd = gc->proto_data;
- char buf[1024];
- int len;
-@@ -2133,7 +2133,7 @@ static void yahoo_pending(gpointer data,
- len = read(yd->fd, buf, sizeof(buf));
-
- if (len <= 0) {
-- gaim_connection_error(gc, _("Unable to read"));
-+ gaim2_connection_error(gc, _("Unable to read"));
- return;
- }
-
-@@ -2154,7 +2154,7 @@ static void yahoo_pending(gpointer data,
- * are you trying to pull? */
- guchar *start;
-
-- gaim_debug_warning("yahoo", "Error in YMSG stream, got something not a YMSG packet!");
-+ gaim2_debug_warning("yahoo", "Error in YMSG stream, got something not a YMSG packet!");
-
- start = memchr(yd->rxqueue + 1, 'Y', yd->rxlen - 1);
- if (start) {
-@@ -2174,7 +2174,7 @@ static void yahoo_pending(gpointer data,
- pos += 2;
-
- pktlen = yahoo_get16(yd->rxqueue + pos); pos += 2;
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "%d bytes to read, rxlen is %d\n", pktlen, yd->rxlen);
-
- if (yd->rxlen < (YAHOO_PACKET_HDRLEN + pktlen))
-@@ -2186,7 +2186,7 @@ static void yahoo_pending(gpointer data,
-
- pkt->service = yahoo_get16(yd->rxqueue + pos); pos += 2;
- pkt->status = yahoo_get32(yd->rxqueue + pos); pos += 4;
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "Yahoo Service: 0x%02x Status: %d\n",
- pkt->service, pkt->status);
- pkt->id = yahoo_get32(yd->rxqueue + pos); pos += 4;
-@@ -2209,19 +2209,19 @@ static void yahoo_pending(gpointer data,
- }
- }
-
--static void yahoo_got_connected(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_got_connected(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct yahoo_data *yd;
- struct yahoo_packet *pkt;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Unable to connect."));
-+ gaim2_connection_error(gc, _("Unable to connect."));
- return;
- }
-
-@@ -2230,25 +2230,25 @@ static void yahoo_got_connected(gpointer
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_AUTH, yd->current_status, 0);
-
-- yahoo_packet_hash_str(pkt, 1, gaim_normalize(gc->account, gaim_account_get_username(gaim_connection_get_account(gc))));
-+ yahoo_packet_hash_str(pkt, 1, gaim2_normalize(gc->account, gaim2_account_get_username(gaim2_connection_get_account(gc))));
- yahoo_packet_send_and_free(pkt, yd);
-
-- gc->inpa = gaim_input_add(yd->fd, GAIM_INPUT_READ, yahoo_pending, gc);
-+ gc->inpa = gaim2_input_add(yd->fd, GAIM_INPUT_READ, yahoo_pending, gc);
- }
-
--static void yahoo_got_web_connected(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_got_web_connected(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct yahoo_data *yd;
- struct yahoo_packet *pkt;
-
-- if (!g_list_find(gaim_connections_get_all(), gc)) {
-+ if (!g_list_find(gaim2_connections_get_all(), gc)) {
- close(source);
- return;
- }
-
- if (source < 0) {
-- gaim_connection_error(gc, _("Unable to connect."));
-+ gaim2_connection_error(gc, _("Unable to connect."));
- return;
- }
-
-@@ -2258,19 +2258,19 @@ static void yahoo_got_web_connected(gpoi
- pkt = yahoo_packet_new(YAHOO_SERVICE_WEBLOGIN, YAHOO_STATUS_WEBLOGIN, 0);
-
- yahoo_packet_hash(pkt, "sss", 0,
-- gaim_normalize(gc->account, gaim_account_get_username(gaim_connection_get_account(gc))),
-- 1, gaim_normalize(gc->account, gaim_account_get_username(gaim_connection_get_account(gc))),
-+ gaim2_normalize(gc->account, gaim2_account_get_username(gaim2_connection_get_account(gc))),
-+ 1, gaim2_normalize(gc->account, gaim2_account_get_username(gaim2_connection_get_account(gc))),
- 6, yd->auth);
- yahoo_packet_send_and_free(pkt, yd);
-
- g_free(yd->auth);
-- gc->inpa = gaim_input_add(yd->fd, GAIM_INPUT_READ, yahoo_pending, gc);
-+ gc->inpa = gaim2_input_add(yd->fd, GAIM_INPUT_READ, yahoo_pending, gc);
- }
-
--static void yahoo_web_pending(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_web_pending(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
- char buf[2048], *i = buf;
- int len;
-@@ -2279,7 +2279,7 @@ static void yahoo_web_pending(gpointer d
- len = read(source, buf, sizeof(buf)-1);
- if (len <= 0 || (strncmp(buf, "HTTP/1.0 302", strlen("HTTP/1.0 302")) &&
- strncmp(buf, "HTTP/1.1 302", strlen("HTTP/1.1 302")))) {
-- gaim_connection_error(gc, _("Unable to read"));
-+ gaim2_connection_error(gc, _("Unable to read"));
- return;
- }
-
-@@ -2295,28 +2295,28 @@ static void yahoo_web_pending(gpointer d
- }
-
- yd->auth = g_string_free(s, FALSE);
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
- close(source);
- /* Now we have our cookies to login with. I'll go get the milk. */
-- if (gaim_proxy_connect(account, "wcs2.msg.dcn.yahoo.com",
-- gaim_account_get_int(account, "port", YAHOO_PAGER_PORT),
-+ if (gaim2_proxy_connect(account, "wcs2.msg.dcn.yahoo.com",
-+ gaim2_account_get_int(account, "port", YAHOO_PAGER_PORT),
- yahoo_got_web_connected, gc) != 0) {
-- gaim_connection_error(gc, _("Connection problem"));
-+ gaim2_connection_error(gc, _("Connection problem"));
- return;
- }
- }
-
--static void yahoo_got_cookies(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_got_cookies(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimConnection *gc = data;
-+ Gaim2Connection *gc = data;
- struct yahoo_data *yd = gc->proto_data;
- if (source < 0) {
-- gaim_connection_error(gc, _("Unable to connect."));
-+ gaim2_connection_error(gc, _("Unable to connect."));
- return;
- }
- write(source, yd->auth, strlen(yd->auth));
- g_free(yd->auth);
-- gc->inpa = gaim_input_add(source, GAIM_INPUT_READ, yahoo_web_pending, gc);
-+ gc->inpa = gaim2_input_add(source, GAIM_INPUT_READ, yahoo_web_pending, gc);
- }
-
- static void yahoo_login_page_hash_iter(const char *key, const char *val, GString *url)
-@@ -2331,7 +2331,7 @@ static void yahoo_login_page_hash_iter(c
- else if (!strcmp(key, ".challenge"))
- url = g_string_append(url, val);
- else
-- url = g_string_append(url, gaim_url_encode(val));
-+ url = g_string_append(url, gaim2_url_encode(val));
- }
-
- static GHashTable *yahoo_login_page_hash(const char *buf, size_t len)
-@@ -2371,36 +2371,36 @@ static GHashTable *yahoo_login_page_hash
-
- static void yahoo_login_page_cb(void *user_data, const char *buf, size_t len)
- {
-- GaimConnection *gc = (GaimConnection *)user_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Connection *gc = (Gaim2Connection *)user_data;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
-- const char *sn = gaim_account_get_username(account);
-- const char *pass = gaim_connection_get_password(gc);
-+ const char *sn = gaim2_account_get_username(account);
-+ const char *pass = gaim2_connection_get_password(gc);
- GHashTable *hash = yahoo_login_page_hash(buf, len);
- GString *url = g_string_new("GET http://login.yahoo.com/config/login?login=");
- char md5[33], *hashp = md5, *chal;
- int i;
-- GaimCipher *cipher;
-- GaimCipherContext *context;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context;
- guchar digest[16];
-
- url = g_string_append(url, sn);
- url = g_string_append(url, "&passwd=");
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context = gaim2_cipher_context_new(cipher, NULL);
-
-- gaim_cipher_context_append(context, (const guchar *)pass, strlen(pass));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)pass, strlen(pass));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
- for (i = 0; i < 16; ++i) {
- g_snprintf(hashp, 3, "%02x", digest[i]);
- hashp += 2;
- }
-
- chal = g_strconcat(md5, g_hash_table_lookup(hash, ".challenge"), NULL);
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, (const guchar *)chal, strlen(chal));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, (const guchar *)chal, strlen(chal));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
- hashp = md5;
- for (i = 0; i < 16; ++i) {
- g_snprintf(hashp, 3, "%02x", digest[i]);
-@@ -2410,9 +2410,9 @@ static void yahoo_login_page_cb(void *us
- * I dunno why this is here and commented out.. but in case it's needed
- * I updated it..
-
-- gaim_cipher_context_reset(context, NULL);
-- gaim_cipher_context_append(context, md5, strlen(md5));
-- gaim_cipher_context_digest(context, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_reset(context, NULL);
-+ gaim2_cipher_context_append(context, md5, strlen(md5));
-+ gaim2_cipher_context_digest(context, sizeof(digest), digest, NULL);
- hashp = md5;
- for (i = 0; i < 16; ++i) {
- g_snprintf(hashp, 3, "%02x", digest[i]);
-@@ -2428,43 +2428,43 @@ static void yahoo_login_page_cb(void *us
- "Host: login.yahoo.com\r\n\r\n");
- g_hash_table_destroy(hash);
- yd->auth = g_string_free(url, FALSE);
-- if (gaim_proxy_connect(account, "login.yahoo.com", 80, yahoo_got_cookies, gc) != 0) {
-- gaim_connection_error(gc, _("Connection problem"));
-+ if (gaim2_proxy_connect(account, "login.yahoo.com", 80, yahoo_got_cookies, gc) != 0) {
-+ gaim2_connection_error(gc, _("Connection problem"));
- return;
- }
-
-- gaim_cipher_context_destroy(context);
-+ gaim2_cipher_context_destroy(context);
- }
-
--static void yahoo_server_check(GaimAccount *account)
-+static void yahoo_server_check(Gaim2Account *account)
- {
- const char *server;
-
-- server = gaim_account_get_string(account, "server", YAHOO_PAGER_HOST);
-+ server = gaim2_account_get_string(account, "server", YAHOO_PAGER_HOST);
-
- if (strcmp(server, "scs.yahoo.com") == 0)
-- gaim_account_set_string(account, "server", YAHOO_PAGER_HOST);
-+ gaim2_account_set_string(account, "server", YAHOO_PAGER_HOST);
- }
-
--static void yahoo_picture_check(GaimAccount *account)
-+static void yahoo_picture_check(Gaim2Account *account)
- {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- char *buddyicon;
-
-- buddyicon = gaim_buddy_icons_get_full_path(gaim_account_get_buddy_icon(account));
-+ buddyicon = gaim2_buddy_icons_get_full_path(gaim2_account_get_buddy_icon(account));
- yahoo_set_buddy_icon(gc, buddyicon);
- g_free(buddyicon);
- }
-
--static int get_yahoo_status_from_gaim_status(GaimStatus *status)
-+static int get_yahoo_status_from_gaim2_status(Gaim2Status *status)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
- const char *status_id;
- const char *msg;
-
-- presence = gaim_status_get_presence(status);
-- status_id = gaim_status_get_id(status);
-- msg = gaim_status_get_attr_string(status, "message");
-+ presence = gaim2_status_get_presence(status);
-+ status_id = gaim2_status_get_id(status);
-+ msg = gaim2_status_get_attr_string(status, "message");
-
- if (!strcmp(status_id, YAHOO_STATUS_TYPE_AVAILABLE)) {
- if ((msg != NULL) && (*msg != '\0'))
-@@ -2493,70 +2493,70 @@ static int get_yahoo_status_from_gaim_st
- return YAHOO_STATUS_INVISIBLE;
- } else if (!strcmp(status_id, YAHOO_STATUS_TYPE_AWAY)) {
- return YAHOO_STATUS_CUSTOM;
-- } else if (gaim_presence_is_idle(presence)) {
-+ } else if (gaim2_presence_is_idle(presence)) {
- return YAHOO_STATUS_IDLE;
- } else {
-- gaim_debug_error("yahoo", "Unexpected GaimStatus!\n");
-+ gaim2_debug_error("yahoo", "Unexpected Gaim2Status!\n");
- return YAHOO_STATUS_AVAILABLE;
- }
- }
-
--static void yahoo_login(GaimAccount *account) {
-- GaimConnection *gc = gaim_account_get_connection(account);
-+static void yahoo_login(Gaim2Account *account) {
-+ Gaim2Connection *gc = gaim2_account_get_connection(account);
- struct yahoo_data *yd = gc->proto_data = g_new0(struct yahoo_data, 1);
-- GaimStatus *status = gaim_account_get_active_status(account);
-+ Gaim2Status *status = gaim2_account_get_active_status(account);
- gc->flags |= GAIM_CONNECTION_HTML | GAIM_CONNECTION_NO_BGCOLOR | GAIM_CONNECTION_NO_URLDESC;
-
-- gaim_connection_update_progress(gc, _("Connecting"), 1, 2);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 1, 2);
-
-- gaim_connection_set_display_name(gc, gaim_account_get_username(account));
-+ gaim2_connection_set_display_name(gc, gaim2_account_get_username(account));
-
- yd->fd = -1;
- yd->friends = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, yahoo_friend_free);
- yd->confs = NULL;
- yd->conf_id = 2;
-
-- yd->current_status = get_yahoo_status_from_gaim_status(status);
-+ yd->current_status = get_yahoo_status_from_gaim2_status(status);
-
- yahoo_server_check(account);
- yahoo_picture_check(account);
-
-- if (gaim_account_get_bool(account, "yahoojp", FALSE)) {
-+ if (gaim2_account_get_bool(account, "yahoojp", FALSE)) {
- yd->jp = TRUE;
-- if (gaim_proxy_connect(account,
-- gaim_account_get_string(account, "serverjp", YAHOOJP_PAGER_HOST),
-- gaim_account_get_int(account, "port", YAHOO_PAGER_PORT),
-+ if (gaim2_proxy_connect(account,
-+ gaim2_account_get_string(account, "serverjp", YAHOOJP_PAGER_HOST),
-+ gaim2_account_get_int(account, "port", YAHOO_PAGER_PORT),
- yahoo_got_connected, gc) != 0)
- {
-- gaim_connection_error(gc, _("Connection problem"));
-+ gaim2_connection_error(gc, _("Connection problem"));
- return;
- }
- } else {
- yd->jp = FALSE;
-- if (gaim_proxy_connect(account,
-- gaim_account_get_string(account, "server", YAHOO_PAGER_HOST),
-- gaim_account_get_int(account, "port", YAHOO_PAGER_PORT),
-+ if (gaim2_proxy_connect(account,
-+ gaim2_account_get_string(account, "server", YAHOO_PAGER_HOST),
-+ gaim2_account_get_int(account, "port", YAHOO_PAGER_PORT),
- yahoo_got_connected, gc) != 0)
- {
-- gaim_connection_error(gc, _("Connection problem"));
-+ gaim2_connection_error(gc, _("Connection problem"));
- return;
- }
- }
- }
-
--static void yahoo_close(GaimConnection *gc) {
-+static void yahoo_close(Gaim2Connection *gc) {
- struct yahoo_data *yd = (struct yahoo_data *)gc->proto_data;
- GSList *l;
-
- if (gc->inpa)
-- gaim_input_remove(gc->inpa);
-+ gaim2_input_remove(gc->inpa);
-
- for (l = yd->confs; l; l = l->next) {
-- GaimConversation *conv = l->data;
-+ Gaim2Conversation *conv = l->data;
-
-- yahoo_conf_leave(yd, gaim_conversation_get_name(conv),
-- gaim_connection_get_display_name(gc),
-- gaim_conv_chat_get_users(GAIM_CONV_CHAT(conv)));
-+ yahoo_conf_leave(yd, gaim2_conversation_get_name(conv),
-+ gaim2_connection_get_display_name(gc),
-+ gaim2_conv_chat_get_users(GAIM_CONV_CHAT(conv)));
- }
- g_slist_free(yd->confs);
-
-@@ -2585,24 +2585,24 @@ static void yahoo_close(GaimConnection *
- g_free(yd);
- }
-
--static const char *yahoo_list_icon(GaimAccount *a, GaimBuddy *b)
-+static const char *yahoo_list_icon(Gaim2Account *a, Gaim2Buddy *b)
- {
- return "yahoo";
- }
-
--static void yahoo_list_emblems(GaimBuddy *b, const char **se, const char **sw, const char **nw, const char **ne)
-+static void yahoo_list_emblems(Gaim2Buddy *b, const char **se, const char **sw, const char **nw, const char **ne)
- {
- int i = 0;
- char *emblems[4] = {NULL,NULL,NULL,NULL};
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- struct yahoo_data *yd;
- YahooFriend *f;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- const char *status_id;
-
-- if (!b || !(account = b->account) || !(gc = gaim_account_get_connection(account)) ||
-+ if (!b || !(account = b->account) || !(gc = gaim2_account_get_connection(account)) ||
- !(yd = gc->proto_data))
- return;
-
-@@ -2612,11 +2612,11 @@ static void yahoo_list_emblems(GaimBuddy
- return;
- }
-
-- presence = gaim_buddy_get_presence(b);
-- status = gaim_presence_get_active_status(presence);
-- status_id = gaim_status_get_id(status);
-+ presence = gaim2_buddy_get_presence(b);
-+ status = gaim2_presence_get_active_status(presence);
-+ status_id = gaim2_status_get_id(status);
-
-- if (gaim_presence_is_online(presence) == FALSE) {
-+ if (gaim2_presence_is_online(presence) == FALSE) {
- *se = "offline";
- return;
- } else {
-@@ -2665,10 +2665,10 @@ static char *yahoo_get_status_string(enu
- }
- }
-
--static void yahoo_initiate_conference(GaimBlistNode *node, gpointer data) {
-+static void yahoo_initiate_conference(Gaim2BlistNode *node, gpointer data) {
-
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- GHashTable *components;
- struct yahoo_data *yd;
-@@ -2676,14 +2676,14 @@ static void yahoo_initiate_conference(Ga
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- yd = gc->proto_data;
- id = yd->conf_id;
-
- components = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free);
- g_hash_table_replace(components, g_strdup("room"),
-- g_strdup_printf("%s-%d", gaim_connection_get_display_name(gc), id));
-+ g_strdup_printf("%s-%d", gaim2_connection_get_display_name(gc), id));
- g_hash_table_replace(components, g_strdup("topic"), g_strdup("Join my conference..."));
- g_hash_table_replace(components, g_strdup("type"), g_strdup("Conference"));
- yahoo_c_join(gc, components);
-@@ -2692,21 +2692,21 @@ static void yahoo_initiate_conference(Ga
- yahoo_c_invite(gc, id, "Join my conference...", buddy->name);
- }
-
--static void yahoo_presence_settings(GaimBlistNode *node, gpointer data) {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+static void yahoo_presence_settings(Gaim2BlistNode *node, gpointer data) {
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
- int presence_val = GPOINTER_TO_INT(data);
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- yahoo_friend_update_presence(gc, buddy->name, presence_val);
- }
-
--static void yahoo_game(GaimBlistNode *node, gpointer data) {
-+static void yahoo_game(Gaim2BlistNode *node, gpointer data) {
-
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- struct yahoo_data *yd;
- const char *game;
-@@ -2717,8 +2717,8 @@ static void yahoo_game(GaimBlistNode *no
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
- yd = (struct yahoo_data *) gc->proto_data;
-
- f = yahoo_friend_find(gc, buddy->name);
-@@ -2734,11 +2734,11 @@ static void yahoo_game(GaimBlistNode *no
- t++;
- *t = 0;
- g_snprintf(url, sizeof url, "http://games.yahoo.com/games/%s", game2);
-- gaim_notify_uri(gc, url);
-+ gaim2_notify_uri(gc, url);
- g_free(game2);
- }
-
--static char *yahoo_status_text(GaimBuddy *b)
-+static char *yahoo_status_text(Gaim2Buddy *b)
- {
- YahooFriend *f = NULL;
- const char *msg;
-@@ -2759,7 +2759,7 @@ static char *yahoo_status_text(GaimBuddy
- if (!(msg = yahoo_friend_get_status_message(f)))
- return NULL;
- msg2 = g_markup_escape_text(msg, strlen(msg));
-- gaim_util_chrreplace(msg2, '\n', ' ');
-+ gaim2_util_chrreplace(msg2, '\n', ' ');
- return msg2;
-
- default:
-@@ -2767,7 +2767,7 @@ static char *yahoo_status_text(GaimBuddy
- }
- }
-
--char *yahoo_tooltip_text(GaimBuddy *b)
-+char *yahoo_tooltip_text(Gaim2Buddy *b)
- {
- YahooFriend *f;
- char *escaped, *status = NULL, *presence = NULL;
-@@ -2818,47 +2818,47 @@ char *yahoo_tooltip_text(GaimBuddy *b)
- return g_string_free(s, FALSE);
- }
-
--static void yahoo_addbuddyfrommenu_cb(GaimBlistNode *node, gpointer data)
-+static void yahoo_addbuddyfrommenu_cb(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- yahoo_add_buddy(gc, buddy, NULL);
- }
-
-
--static void yahoo_chat_goto_menu(GaimBlistNode *node, gpointer data)
-+static void yahoo_chat_goto_menu(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *buddy;
-- GaimConnection *gc;
-+ Gaim2Buddy *buddy;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(GAIM_BLIST_NODE_IS_BUDDY(node));
-
-- buddy = (GaimBuddy *) node;
-- gc = gaim_account_get_connection(buddy->account);
-+ buddy = (Gaim2Buddy *) node;
-+ gc = gaim2_account_get_connection(buddy->account);
-
- yahoo_chat_goto(gc, buddy->name);
- }
-
--static GList *build_presence_submenu(YahooFriend *f, GaimConnection *gc) {
-+static GList *build_presence_submenu(YahooFriend *f, Gaim2Connection *gc) {
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
- struct yahoo_data *yd = (struct yahoo_data *) gc->proto_data;
-
- if (yd->current_status == YAHOO_STATUS_INVISIBLE) {
- if (f->presence != YAHOO_PRESENCE_ONLINE) {
-- act = gaim_blist_node_action_new(_("Appear Online"),
-+ act = gaim2_blist_node_action_new(_("Appear Online"),
- yahoo_presence_settings,
- GINT_TO_POINTER(YAHOO_PRESENCE_ONLINE),
- NULL);
- m = g_list_append(m, act);
- } else if (f->presence != YAHOO_PRESENCE_DEFAULT) {
-- act = gaim_blist_node_action_new(_("Appear Offline"),
-+ act = gaim2_blist_node_action_new(_("Appear Offline"),
- yahoo_presence_settings,
- GINT_TO_POINTER(YAHOO_PRESENCE_DEFAULT),
- NULL);
-@@ -2867,13 +2867,13 @@ static GList *build_presence_submenu(Yah
- }
-
- if (f->presence == YAHOO_PRESENCE_PERM_OFFLINE) {
-- act = gaim_blist_node_action_new(
-+ act = gaim2_blist_node_action_new(
- _("Don't Appear Permanently Offline"),
- yahoo_presence_settings,
- GINT_TO_POINTER(YAHOO_PRESENCE_DEFAULT), NULL);
- m = g_list_append(m, act);
- } else {
-- act = gaim_blist_node_action_new(
-+ act = gaim2_blist_node_action_new(
- _("Appear Permanently Offline"),
- yahoo_presence_settings,
- GINT_TO_POINTER(YAHOO_PRESENCE_PERM_OFFLINE),
-@@ -2884,20 +2884,20 @@ static GList *build_presence_submenu(Yah
- return m;
- }
-
--static void yahoo_doodle_blist_node(GaimBlistNode *node, gpointer data)
-+static void yahoo_doodle_blist_node(Gaim2BlistNode *node, gpointer data)
- {
-- GaimBuddy *b = (GaimBuddy *)node;
-- GaimConnection *gc = b->account->gc;
-+ Gaim2Buddy *b = (Gaim2Buddy *)node;
-+ Gaim2Connection *gc = b->account->gc;
-
- yahoo_doodle_initiate(gc, b->name);
- }
-
--static GList *yahoo_buddy_menu(GaimBuddy *buddy)
-+static GList *yahoo_buddy_menu(Gaim2Buddy *buddy)
- {
- GList *m = NULL;
-- GaimBlistNodeAction *act;
-+ Gaim2BlistNodeAction *act;
-
-- GaimConnection *gc = gaim_account_get_connection(buddy->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(buddy->account);
- struct yahoo_data *yd = gc->proto_data;
- static char buf2[1024];
- YahooFriend *f;
-@@ -2905,7 +2905,7 @@ static GList *yahoo_buddy_menu(GaimBuddy
- f = yahoo_friend_find(gc, buddy->name);
-
- if (!f && !yd->wm) {
-- act = gaim_blist_node_action_new(_("Add Buddy"),
-+ act = gaim2_blist_node_action_new(_("Add Buddy"),
- yahoo_addbuddyfrommenu_cb, NULL, NULL);
- m = g_list_append(m, act);
-
-@@ -2915,12 +2915,12 @@ static GList *yahoo_buddy_menu(GaimBuddy
-
- if (f && f->status != YAHOO_STATUS_OFFLINE) {
- if (!yd->wm) {
-- act = gaim_blist_node_action_new(_("Join in Chat"),
-+ act = gaim2_blist_node_action_new(_("Join in Chat"),
- yahoo_chat_goto_menu, NULL, NULL);
- m = g_list_append(m, act);
- }
-
-- act = gaim_blist_node_action_new(_("Initiate Conference"),
-+ act = gaim2_blist_node_action_new(_("Initiate Conference"),
- yahoo_initiate_conference, NULL, NULL);
- m = g_list_append(m, act);
-
-@@ -2938,20 +2938,20 @@ static GList *yahoo_buddy_menu(GaimBuddy
- *t = ' ';
- g_snprintf(buf2, sizeof buf2, "%s", room);
-
-- act = gaim_blist_node_action_new(buf2, yahoo_game, NULL, NULL);
-+ act = gaim2_blist_node_action_new(buf2, yahoo_game, NULL, NULL);
- m = g_list_append(m, act);
- }
- }
- }
-
- if (f) {
-- act = gaim_blist_node_action_new(_("Presence Settings"),
-+ act = gaim2_blist_node_action_new(_("Presence Settings"),
- NULL, NULL, build_presence_submenu(f, gc));
- m = g_list_append(m, act);
- }
-
- if (f) {
-- act = gaim_blist_node_action_new(_("Start Doodling"),
-+ act = gaim2_blist_node_action_new(_("Start Doodling"),
- yahoo_doodle_blist_node, NULL, NULL);
- m = g_list_append(m, act);
- }
-@@ -2959,16 +2959,16 @@ static GList *yahoo_buddy_menu(GaimBuddy
- return m;
- }
-
--static GList *yahoo_blist_node_menu(GaimBlistNode *node)
-+static GList *yahoo_blist_node_menu(Gaim2BlistNode *node)
- {
- if(GAIM_BLIST_NODE_IS_BUDDY(node)) {
-- return yahoo_buddy_menu((GaimBuddy *) node);
-+ return yahoo_buddy_menu((Gaim2Buddy *) node);
- } else {
- return NULL;
- }
- }
-
--static void yahoo_act_id(GaimConnection *gc, const char *entry)
-+static void yahoo_act_id(Gaim2Connection *gc, const char *entry)
- {
- struct yahoo_data *yd = gc->proto_data;
-
-@@ -2976,55 +2976,55 @@ static void yahoo_act_id(GaimConnection
- yahoo_packet_hash_str(pkt, 3, entry);
- yahoo_packet_send_and_free(pkt, yd);
-
-- gaim_connection_set_display_name(gc, entry);
-+ gaim2_connection_set_display_name(gc, entry);
- }
-
--static void yahoo_show_act_id(GaimPluginAction *action)
-+static void yahoo_show_act_id(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_request_input(gc, NULL, _("Active which ID?"), NULL,
-- gaim_connection_get_display_name(gc), FALSE, FALSE, NULL,
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_request_input(gc, NULL, _("Active which ID?"), NULL,
-+ gaim2_connection_get_display_name(gc), FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(yahoo_act_id),
- _("Cancel"), NULL, gc);
- }
-
--static void yahoo_show_chat_goto(GaimPluginAction *action)
-+static void yahoo_show_chat_goto(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-- gaim_request_input(gc, NULL, _("Join who in chat?"), NULL,
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
-+ gaim2_request_input(gc, NULL, _("Join who in chat?"), NULL,
- "", FALSE, FALSE, NULL,
- _("OK"), G_CALLBACK(yahoo_chat_goto),
- _("Cancel"), NULL, gc);
- }
-
--static GList *yahoo_actions(GaimPlugin *plugin, gpointer context) {
-+static GList *yahoo_actions(Gaim2Plugin *plugin, gpointer context) {
- GList *m = NULL;
-- GaimPluginAction *act;
-+ Gaim2PluginAction *act;
-
-- act = gaim_plugin_action_new(_("Activate ID..."),
-+ act = gaim2_plugin_action_new(_("Activate ID..."),
- yahoo_show_act_id);
- m = g_list_append(m, act);
-
-- act = gaim_plugin_action_new(_("Join User in Chat..."),
-+ act = gaim2_plugin_action_new(_("Join User in Chat..."),
- yahoo_show_chat_goto);
- m = g_list_append(m, act);
-
- return m;
- }
-
--static int yahoo_send_im(GaimConnection *gc, const char *who, const char *what, GaimMessageFlags flags)
-+static int yahoo_send_im(Gaim2Connection *gc, const char *who, const char *what, Gaim2MessageFlags flags)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt = yahoo_packet_new(YAHOO_SERVICE_MESSAGE, YAHOO_STATUS_OFFLINE, 0);
- char *msg = yahoo_html_to_codes(what);
- char *msg2;
- gboolean utf8 = TRUE;
-- GaimWhiteboard *wb;
-+ Gaim2Whiteboard *wb;
- int ret = 1;
-
- msg2 = yahoo_string_encode(gc, msg, &utf8);
-
-- yahoo_packet_hash(pkt, "ss", 1, gaim_connection_get_display_name(gc), 5, who);
-+ yahoo_packet_hash(pkt, "ss", 1, gaim2_connection_get_display_name(gc), 5, who);
- if (utf8)
- yahoo_packet_hash_str(pkt, 97, "1");
- yahoo_packet_hash_str(pkt, 14, msg2);
-@@ -3032,7 +3032,7 @@ static int yahoo_send_im(GaimConnection
- /* If this message is to a user who is also Doodling with the local user,
- * format the chat packet with the correct IMV information (thanks Yahoo!)
- */
-- wb = gaim_whiteboard_get_session(gc->account, (char*)who);
-+ wb = gaim2_whiteboard_get_session(gc->account, (char*)who);
- if (wb)
- yahoo_packet_hash_str(pkt, 63, "doodle;11");
- else
-@@ -3059,11 +3059,11 @@ static int yahoo_send_im(GaimConnection
- return ret;
- }
-
--static int yahoo_send_typing(GaimConnection *gc, const char *who, int typ)
-+static int yahoo_send_typing(Gaim2Connection *gc, const char *who, int typ)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt = yahoo_packet_new(YAHOO_SERVICE_NOTIFY, YAHOO_STATUS_TYPING, 0);
-- yahoo_packet_hash(pkt, "ssssss", 49, "TYPING", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "ssssss", 49, "TYPING", 1, gaim2_connection_get_display_name(gc),
- 14, " ", 13, typ == GAIM_TYPING ? "1" : "0",
- 5, who, 1002, "1");
-
-@@ -3079,10 +3079,10 @@ static void yahoo_session_presence_remov
- f->presence = YAHOO_PRESENCE_DEFAULT;
- }
-
--static void yahoo_set_status(GaimAccount *account, GaimStatus *status)
-+static void yahoo_set_status(Gaim2Account *account, Gaim2Status *status)
- {
-- GaimConnection *gc;
-- GaimPresence *presence;
-+ Gaim2Connection *gc;
-+ Gaim2Presence *presence;
- struct yahoo_data *yd;
- struct yahoo_packet *pkt;
- int old_status;
-@@ -3090,29 +3090,29 @@ static void yahoo_set_status(GaimAccount
- char *tmp = NULL;
- char *conv_msg = NULL;
-
-- if (!gaim_status_is_active(status))
-+ if (!gaim2_status_is_active(status))
- return;
-
-- gc = gaim_account_get_connection(account);
-- presence = gaim_status_get_presence(status);
-+ gc = gaim2_account_get_connection(account);
-+ presence = gaim2_status_get_presence(status);
- yd = (struct yahoo_data *)gc->proto_data;
- old_status = yd->current_status;
-
-- yd->current_status = get_yahoo_status_from_gaim_status(status);
-+ yd->current_status = get_yahoo_status_from_gaim2_status(status);
-
- if (yd->current_status == YAHOO_STATUS_CUSTOM)
- {
-- msg = gaim_status_get_attr_string(status, "message");
-+ msg = gaim2_status_get_attr_string(status, "message");
-
-- if (gaim_status_is_available(status)) {
-+ if (gaim2_status_is_available(status)) {
- tmp = yahoo_string_encode(gc, msg, NULL);
-- conv_msg = gaim_markup_strip_html(tmp);
-+ conv_msg = gaim2_markup_strip_html(tmp);
- g_free(tmp);
- } else {
- if ((msg == NULL) || (*msg == '\0'))
- msg = _("Away");
- tmp = yahoo_string_encode(gc, msg, NULL);
-- conv_msg = gaim_markup_strip_html(tmp);
-+ conv_msg = gaim2_markup_strip_html(tmp);
- g_free(tmp);
- }
- }
-@@ -3136,9 +3136,9 @@ static void yahoo_set_status(GaimAccount
-
- g_free(conv_msg);
-
-- if (gaim_presence_is_idle(presence))
-+ if (gaim2_presence_is_idle(presence))
- yahoo_packet_hash_str(pkt, 47, "2");
-- else if (!gaim_status_is_available(status))
-+ else if (!gaim2_status_is_available(status))
- yahoo_packet_hash_str(pkt, 47, "1");
-
- yahoo_packet_send_and_free(pkt, yd);
-@@ -3154,7 +3154,7 @@ static void yahoo_set_status(GaimAccount
- }
- }
-
--static void yahoo_set_idle(GaimConnection *gc, int idle)
-+static void yahoo_set_idle(Gaim2Connection *gc, int idle)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt = NULL;
-@@ -3170,11 +3170,11 @@ static void yahoo_set_idle(GaimConnectio
- yahoo_packet_hash_int(pkt, 10, yd->current_status);
- if (yd->current_status == YAHOO_STATUS_CUSTOM) {
- const char *tmp;
-- GaimStatus *status = gaim_presence_get_active_status(gaim_account_get_presence(gaim_connection_get_account(gc)));
-- tmp = gaim_status_get_attr_string(status, "message");
-+ Gaim2Status *status = gaim2_presence_get_active_status(gaim2_account_get_presence(gaim2_connection_get_account(gc)));
-+ tmp = gaim2_status_get_attr_string(status, "message");
- if (tmp != NULL) {
- msg = yahoo_string_encode(gc, tmp, NULL);
-- msg2 = gaim_markup_strip_html(msg);
-+ msg2 = gaim2_markup_strip_html(msg);
- yahoo_packet_hash_str(pkt, 19, msg2);
- } else {
- yahoo_packet_hash_str(pkt, 19, "");
-@@ -3185,7 +3185,7 @@ static void yahoo_set_idle(GaimConnectio
-
- if (idle)
- yahoo_packet_hash_str(pkt, 47, "2");
-- else if (!gaim_presence_is_available(gaim_account_get_presence(gaim_connection_get_account(gc))))
-+ else if (!gaim2_presence_is_available(gaim2_account_get_presence(gaim2_connection_get_account(gc))))
- yahoo_packet_hash_str(pkt, 47, "1");
-
- yahoo_packet_send_and_free(pkt, yd);
-@@ -3194,61 +3194,61 @@ static void yahoo_set_idle(GaimConnectio
- g_free(msg2);
- }
-
--static GList *yahoo_status_types(GaimAccount *account)
-+static GList *yahoo_status_types(Gaim2Account *account)
- {
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- GList *types = NULL;
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE, YAHOO_STATUS_TYPE_AVAILABLE,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AVAILABLE, YAHOO_STATUS_TYPE_AVAILABLE,
- NULL, TRUE, TRUE, FALSE,
- "message", _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ gaim2_value_new(GAIM_TYPE_STRING), NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new_with_attrs(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_AWAY,
-+ type = gaim2_status_type_new_with_attrs(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_AWAY,
- NULL, TRUE, TRUE, FALSE,
- "message", _("Message"),
-- gaim_value_new(GAIM_TYPE_STRING), NULL);
-+ gaim2_value_new(GAIM_TYPE_STRING), NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_BRB, _("Be Right Back"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_BRB, _("Be Right Back"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_UNAVAILABLE, YAHOO_STATUS_TYPE_BUSY, _("Busy"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_UNAVAILABLE, YAHOO_STATUS_TYPE_BUSY, _("Busy"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_NOTATHOME, _("Not at Home"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_NOTATHOME, _("Not at Home"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_NOTATDESK, _("Not at Desk"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_NOTATDESK, _("Not at Desk"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_NOTINOFFICE, _("Not in Office"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_NOTINOFFICE, _("Not in Office"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_UNAVAILABLE, YAHOO_STATUS_TYPE_ONPHONE, _("On the Phone"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_UNAVAILABLE, YAHOO_STATUS_TYPE_ONPHONE, _("On the Phone"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_EXTENDED_AWAY, YAHOO_STATUS_TYPE_ONVACATION, _("On Vacation"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_EXTENDED_AWAY, YAHOO_STATUS_TYPE_ONVACATION, _("On Vacation"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_OUTTOLUNCH, _("Out to Lunch"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_OUTTOLUNCH, _("Out to Lunch"), TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_STEPPEDOUT, _("Stepped Out"), TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AWAY, YAHOO_STATUS_TYPE_STEPPEDOUT, _("Stepped Out"), TRUE);
- types = g_list_append(types, type);
-
-
-- type = gaim_status_type_new(GAIM_STATUS_INVISIBLE, YAHOO_STATUS_TYPE_INVISIBLE, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_INVISIBLE, YAHOO_STATUS_TYPE_INVISIBLE, NULL, TRUE);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_OFFLINE, YAHOO_STATUS_TYPE_OFFLINE, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_OFFLINE, YAHOO_STATUS_TYPE_OFFLINE, NULL, TRUE);
- types = g_list_append(types, type);
-
- return types;
- }
-
--static void yahoo_keepalive(GaimConnection *gc)
-+static void yahoo_keepalive(Gaim2Connection *gc)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt = yahoo_packet_new(YAHOO_SERVICE_PING, YAHOO_STATUS_AVAILABLE, 0);
-@@ -3263,29 +3263,29 @@ static void yahoo_keepalive(GaimConnecti
- }
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_CHATPING, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash_str(pkt, 109, gaim_connection_get_display_name(gc));
-+ yahoo_packet_hash_str(pkt, 109, gaim2_connection_get_display_name(gc));
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--/* XXX - What's the deal with GaimGroup *foo? */
--static void yahoo_add_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *foo)
-+/* XXX - What's the deal with Gaim2Group *foo? */
-+static void yahoo_add_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *foo)
- {
- struct yahoo_data *yd = (struct yahoo_data *)gc->proto_data;
- struct yahoo_packet *pkt;
-- GaimGroup *g;
-+ Gaim2Group *g;
- char *group = NULL;
- char *group2 = NULL;
-
- if (!yd->logged_in)
- return;
-
-- if (!yahoo_privacy_check(gc, gaim_buddy_get_name(buddy)))
-+ if (!yahoo_privacy_check(gc, gaim2_buddy_get_name(buddy)))
- return;
-
- if (foo)
- group = foo->name;
- if (!group) {
-- g = gaim_buddy_get_group(gaim_find_buddy(gc->account, buddy->name));
-+ g = gaim2_buddy_get_group(gaim2_find_buddy(gc->account, buddy->name));
- if (g)
- group = g->name;
- else
-@@ -3294,29 +3294,29 @@ static void yahoo_add_buddy(GaimConnecti
-
- group2 = yahoo_string_encode(gc, group, NULL);
- pkt = yahoo_packet_new(YAHOO_SERVICE_ADDBUDDY, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "ssss", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "ssss", 1, gaim2_connection_get_display_name(gc),
- 7, buddy->name, 65, group2, 14, "");
- yahoo_packet_send_and_free(pkt, yd);
- g_free(group2);
- }
-
--static void yahoo_remove_buddy(GaimConnection *gc, GaimBuddy *buddy, GaimGroup *group)
-+static void yahoo_remove_buddy(Gaim2Connection *gc, Gaim2Buddy *buddy, Gaim2Group *group)
- {
- struct yahoo_data *yd = (struct yahoo_data *)gc->proto_data;
- YahooFriend *f;
- struct yahoo_packet *pkt;
- GSList *buddies, *l;
-- GaimGroup *g;
-+ Gaim2Group *g;
- gboolean remove = TRUE;
- char *cg;
-
- if (!(f = yahoo_friend_find(gc, buddy->name)))
- return;
-
-- buddies = gaim_find_buddies(gaim_connection_get_account(gc), buddy->name);
-+ buddies = gaim2_find_buddies(gaim2_connection_get_account(gc), buddy->name);
- for (l = buddies; l; l = l->next) {
-- g = gaim_buddy_get_group(l->data);
-- if (gaim_utf8_strcasecmp(group->name, g->name)) {
-+ g = gaim2_buddy_get_group(l->data);
-+ if (gaim2_utf8_strcasecmp(group->name, g->name)) {
- remove = FALSE;
- break;
- }
-@@ -3329,13 +3329,13 @@ static void yahoo_remove_buddy(GaimConne
-
- cg = yahoo_string_encode(gc, group->name, NULL);
- pkt = yahoo_packet_new(YAHOO_SERVICE_REMBUDDY, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sss", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "sss", 1, gaim2_connection_get_display_name(gc),
- 7, buddy->name, 65, cg);
- yahoo_packet_send_and_free(pkt, yd);
- g_free(cg);
- }
-
--static void yahoo_add_deny(GaimConnection *gc, const char *who) {
-+static void yahoo_add_deny(Gaim2Connection *gc, const char *who) {
- struct yahoo_data *yd = (struct yahoo_data *)gc->proto_data;
- struct yahoo_packet *pkt;
-
-@@ -3350,12 +3350,12 @@ static void yahoo_add_deny(GaimConnectio
- return;
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_IGNORECONTACT, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sss", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "sss", 1, gaim2_connection_get_display_name(gc),
- 7, who, 13, "1");
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--static void yahoo_rem_deny(GaimConnection *gc, const char *who) {
-+static void yahoo_rem_deny(Gaim2Connection *gc, const char *who) {
- struct yahoo_data *yd = (struct yahoo_data *)gc->proto_data;
- struct yahoo_packet *pkt;
-
-@@ -3366,12 +3366,12 @@ static void yahoo_rem_deny(GaimConnectio
- return;
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_IGNORECONTACT, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sss", 1, gaim_connection_get_display_name(gc), 7, who, 13, "2");
-+ yahoo_packet_hash(pkt, "sss", 1, gaim2_connection_get_display_name(gc), 7, who, 13, "2");
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--static void yahoo_set_permit_deny(GaimConnection *gc) {
-- GaimAccount *acct;
-+static void yahoo_set_permit_deny(Gaim2Connection *gc) {
-+ Gaim2Account *acct;
- GSList *deny;
-
- acct = gc->account;
-@@ -3401,14 +3401,14 @@ static void yahoo_set_permit_deny(GaimCo
- }
- }
-
--static gboolean yahoo_unload_plugin(GaimPlugin *plugin)
-+static gboolean yahoo_unload_plugin(Gaim2Plugin *plugin)
- {
- yahoo_dest_colorht();
-
- return TRUE;
- }
-
--static void yahoo_change_buddys_group(GaimConnection *gc, const char *who,
-+static void yahoo_change_buddys_group(Gaim2Connection *gc, const char *who,
- const char *old_group, const char *new_group)
- {
- struct yahoo_data *yd = gc->proto_data;
-@@ -3435,20 +3435,20 @@ static void yahoo_change_buddys_group(Ga
-
- /* Step 1: Add buddy to new group. */
- pkt = yahoo_packet_new(YAHOO_SERVICE_ADDBUDDY, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "ssss", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "ssss", 1, gaim2_connection_get_display_name(gc),
- 7, who, 65, gpn, 14, "");
- yahoo_packet_send_and_free(pkt, yd);
-
- /* Step 2: Remove buddy from old group */
- pkt = yahoo_packet_new(YAHOO_SERVICE_REMBUDDY, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sss", 1, gaim_connection_get_display_name(gc), 7, who, 65, gpo);
-+ yahoo_packet_hash(pkt, "sss", 1, gaim2_connection_get_display_name(gc), 7, who, 65, gpo);
- yahoo_packet_send_and_free(pkt, yd);
- g_free(gpn);
- g_free(gpo);
- }
-
--static void yahoo_rename_group(GaimConnection *gc, const char *old_name,
-- GaimGroup *group, GList *moved_buddies)
-+static void yahoo_rename_group(Gaim2Connection *gc, const char *old_name,
-+ Gaim2Group *group, GList *moved_buddies)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-@@ -3463,7 +3463,7 @@ static void yahoo_rename_group(GaimConne
- }
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_GROUPRENAME, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sss", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "sss", 1, gaim2_connection_get_display_name(gc),
- 65, gpo, 67, gpn);
- yahoo_packet_send_and_free(pkt, yd);
- g_free(gpn);
-@@ -3472,40 +3472,40 @@ static void yahoo_rename_group(GaimConne
-
- /********************************* Commands **********************************/
-
--static GaimCmdRet
--yahoogaim_cmd_buzz(GaimConversation *c, const gchar *cmd, gchar **args, gchar **error, void *data) {
-+static Gaim2CmdRet
-+yahoogaim2_cmd_buzz(Gaim2Conversation *c, const gchar *cmd, gchar **args, gchar **error, void *data) {
-
-- GaimAccount *account = gaim_conversation_get_account(c);
-- const char *username = gaim_account_get_username(account);
-+ Gaim2Account *account = gaim2_conversation_get_account(c);
-+ const char *username = gaim2_account_get_username(account);
-
- if (*args && args[0])
- return GAIM_CMD_RET_FAILED;
-
-- gaim_debug(GAIM_DEBUG_INFO, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_INFO, "yahoo",
- "Sending <ding> on account %s to buddy %s.\n", username, c->name);
-- gaim_conv_im_send(GAIM_CONV_IM(c), "<ding>");
-- gaim_conv_im_write(GAIM_CONV_IM(c), "", _("Buzz!!"), GAIM_MESSAGE_NICK|GAIM_MESSAGE_SEND, time(NULL));
-+ gaim2_conv_im_send(GAIM_CONV_IM(c), "<ding>");
-+ gaim2_conv_im_write(GAIM_CONV_IM(c), "", _("Buzz!!"), GAIM_MESSAGE_NICK|GAIM_MESSAGE_SEND, time(NULL));
- return GAIM_CMD_RET_OK;
- }
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
--static GaimCmdRet
--yahoogaim_cmd_chat_join(GaimConversation *conv, const char *cmd,
-+static Gaim2CmdRet
-+yahoogaim2_cmd_chat_join(Gaim2Conversation *conv, const char *cmd,
- char **args, char **error, void *data)
- {
- GHashTable *comp;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- struct yahoo_data *yd;
- int id;
-
- if (!args || !args[0])
- return GAIM_CMD_RET_FAILED;
-
-- gc = gaim_conversation_get_gc(conv);
-+ gc = gaim2_conversation_get_gc(conv);
- yd = gc->proto_data;
- id = yd->conf_id;
-- gaim_debug(GAIM_DEBUG_INFO, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_INFO, "yahoo",
- "Trying to join %s \n", args[0]);
-
- comp = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free);
-@@ -3519,32 +3519,32 @@ yahoogaim_cmd_chat_join(GaimConversation
- return GAIM_CMD_RET_OK;
- }
-
--static gboolean yahoo_offline_message(const GaimBuddy *buddy)
-+static gboolean yahoo_offline_message(const Gaim2Buddy *buddy)
- {
- return TRUE;
- }
-
- /************************** Plugin Initialization ****************************/
- static void
--yahoogaim_register_commands(void)
-+yahoogaim2_register_commands(void)
- {
-- gaim_cmd_register("join", "s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("join", "s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT |
- GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-yahoo", yahoogaim_cmd_chat_join,
-+ "prpl-yahoo", yahoogaim2_cmd_chat_join,
- _("join &lt;room&gt;: Join a chat room on the Yahoo network"), NULL);
-- gaim_cmd_register("buzz", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("buzz", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-yahoo", yahoogaim_cmd_buzz,
-+ "prpl-yahoo", yahoogaim2_cmd_buzz,
- _("buzz: Buzz a user to get their attention"), NULL);
-
-- gaim_cmd_register("doodle", "", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("doodle", "", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_PRPL_ONLY,
-- "prpl-yahoo", yahoo_doodle_gaim_cmd_start,
-+ "prpl-yahoo", yahoo_doodle_gaim2_cmd_start,
- _("doodle: Request user to start a Doodle session"), NULL);
- }
-
--static GaimWhiteboardPrplOps yahoo_whiteboard_prpl_ops =
-+static Gaim2WhiteboardPrplOps yahoo_whiteboard_prpl_ops =
- {
- yahoo_doodle_start,
- yahoo_doodle_end,
-@@ -3556,7 +3556,7 @@ static GaimWhiteboardPrplOps yahoo_white
- yahoo_doodle_clear
- };
-
--static GaimPluginProtocolInfo prpl_info =
-+static Gaim2PluginProtocolInfo prpl_info =
- {
- OPT_PROTO_MAIL_CHECK | OPT_PROTO_CHAT_TOPIC,
- NULL, /* user_splits */
-@@ -3604,10 +3604,10 @@ static GaimPluginProtocolInfo prpl_info
- yahoo_rename_group,
- NULL, /* buddy_free */
- NULL, /* convo_closed */
-- gaim_normalize_nocase, /* normalize */
-+ gaim2_normalize_nocase, /* normalize */
- yahoo_set_buddy_icon,
-- NULL, /* void (*remove_group)(GaimConnection *gc, const char *group);*/
-- NULL, /* char *(*get_cb_real_name)(GaimConnection *gc, int id, const char *who); */
-+ NULL, /* void (*remove_group)(Gaim2Connection *gc, const char *group);*/
-+ NULL, /* char *(*get_cb_real_name)(Gaim2Connection *gc, int id, const char *who); */
- NULL, /* set_chat_topic */
- NULL, /* find_blist_chat */
- yahoo_roomlist_get_list,
-@@ -3621,7 +3621,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info =
-+static Gaim2PluginInfo info =
- {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
-@@ -3650,46 +3650,46 @@ static GaimPluginInfo info =
- };
-
- static void
--init_plugin(GaimPlugin *plugin)
-+init_plugin(Gaim2Plugin *plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
-
-- option = gaim_account_option_bool_new(_("Yahoo Japan"), "yahoojp", FALSE);
-+ option = gaim2_account_option_bool_new(_("Yahoo Japan"), "yahoojp", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Pager host"), "server", YAHOO_PAGER_HOST);
-+ option = gaim2_account_option_string_new(_("Pager host"), "server", YAHOO_PAGER_HOST);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Japan Pager host"), "serverjp", YAHOOJP_PAGER_HOST);
-+ option = gaim2_account_option_string_new(_("Japan Pager host"), "serverjp", YAHOOJP_PAGER_HOST);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_int_new(_("Pager port"), "port", YAHOO_PAGER_PORT);
-+ option = gaim2_account_option_int_new(_("Pager port"), "port", YAHOO_PAGER_PORT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("File transfer host"), "xfer_host", YAHOO_XFER_HOST);
-+ option = gaim2_account_option_string_new(_("File transfer host"), "xfer_host", YAHOO_XFER_HOST);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Japan file transfer host"), "xferjp_host", YAHOOJP_XFER_HOST);
-+ option = gaim2_account_option_string_new(_("Japan file transfer host"), "xferjp_host", YAHOOJP_XFER_HOST);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_int_new(_("File transfer port"), "xfer_port", YAHOO_XFER_PORT);
-+ option = gaim2_account_option_int_new(_("File transfer port"), "xfer_port", YAHOO_XFER_PORT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Chat room locale"), "room_list_locale", YAHOO_ROOMLIST_LOCALE);
-+ option = gaim2_account_option_string_new(_("Chat room locale"), "room_list_locale", YAHOO_ROOMLIST_LOCALE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
- #if 0
-- option = gaim_account_option_string_new(_("Chat room list URL"), "room_list", YAHOO_ROOMLIST_URL);
-+ option = gaim2_account_option_string_new(_("Chat room list URL"), "room_list", YAHOO_ROOMLIST_URL);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("YCHT host"), "ycht-server", YAHOO_YCHT_HOST);
-+ option = gaim2_account_option_string_new(_("YCHT host"), "ycht-server", YAHOO_YCHT_HOST);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_int_new(_("YCHT port"), "ycht-port", YAHOO_YCHT_PORT);
-+ option = gaim2_account_option_int_new(_("YCHT port"), "ycht-port", YAHOO_YCHT_PORT);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
- #endif
-
- my_protocol = plugin;
-- yahoogaim_register_commands();
-+ yahoogaim2_register_commands();
- yahoo_init_colorht();
- }
-
-diff -prNu ./src/protocols/yahoo/yahoochat.c ./src/protocols/yahoo/yahoochat.c
---- ./src/protocols/yahoo/yahoochat.c 2005-11-24 21:47:46.000000000 +0100
-+++ ./src/protocols/yahoo/yahoochat.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -47,10 +47,10 @@
- #define YAHOO_CHAT_ID (1)
-
- /* prototype(s) */
--static void yahoo_chat_leave(GaimConnection *gc, const char *room, const char *dn, gboolean logout);
-+static void yahoo_chat_leave(Gaim2Connection *gc, const char *room, const char *dn, gboolean logout);
-
- /* special function to log us on to the yahoo chat service */
--static void yahoo_chat_online(GaimConnection *gc)
-+static void yahoo_chat_online(Gaim2Connection *gc)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-@@ -61,32 +61,32 @@ static void yahoo_chat_online(GaimConnec
- }
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_CHATONLINE, YAHOO_STATUS_AVAILABLE,0);
-- yahoo_packet_hash(pkt, "sss", 1, gaim_connection_get_display_name(gc),
-- 109, gaim_connection_get_display_name(gc), 6, "abcde");
-+ yahoo_packet_hash(pkt, "sss", 1, gaim2_connection_get_display_name(gc),
-+ 109, gaim2_connection_get_display_name(gc), 6, "abcde");
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--/* this is slow, and different from the gaim_* version in that it (hopefully) won't add a user twice */
--void yahoo_chat_add_users(GaimConvChat *chat, GList *newusers)
-+/* this is slow, and different from the gaim2_* version in that it (hopefully) won't add a user twice */
-+void yahoo_chat_add_users(Gaim2ConvChat *chat, GList *newusers)
- {
- GList *i;
-
- for (i = newusers; i; i = i->next) {
-- if (gaim_conv_chat_find_user(chat, i->data))
-+ if (gaim2_conv_chat_find_user(chat, i->data))
- continue;
-- gaim_conv_chat_add_user(chat, i->data, NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(chat, i->data, NULL, GAIM_CBFLAGS_NONE, TRUE);
- }
- }
-
--void yahoo_chat_add_user(GaimConvChat *chat, const char *user, const char *reason)
-+void yahoo_chat_add_user(Gaim2ConvChat *chat, const char *user, const char *reason)
- {
-- if (gaim_conv_chat_find_user(chat, user))
-+ if (gaim2_conv_chat_find_user(chat, user))
- return;
-
-- gaim_conv_chat_add_user(chat, user, reason, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(chat, user, reason, GAIM_CBFLAGS_NONE, TRUE);
- }
-
--static GaimConversation *yahoo_find_conference(GaimConnection *gc, const char *name)
-+static Gaim2Conversation *yahoo_find_conference(Gaim2Connection *gc, const char *name)
- {
- struct yahoo_data *yd;
- GSList *l;
-@@ -94,15 +94,15 @@ static GaimConversation *yahoo_find_conf
- yd = gc->proto_data;
-
- for (l = yd->confs; l; l = l->next) {
-- GaimConversation *c = l->data;
-- if (!gaim_utf8_strcasecmp(gaim_conversation_get_name(c), name))
-+ Gaim2Conversation *c = l->data;
-+ if (!gaim2_utf8_strcasecmp(gaim2_conversation_get_name(c), name))
- return c;
- }
- return NULL;
- }
-
-
--void yahoo_process_conference_invite(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_conference_invite(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l;
- char *room = NULL;
-@@ -155,7 +155,7 @@ void yahoo_process_conference_invite(Gai
- g_hash_table_replace(components, g_strdup("members"), g_strdup(members->str));
- }
- if (!yahoo_privacy_check(gc, who)) {
-- gaim_debug_info("yahoo",
-+ gaim2_debug_info("yahoo",
- "Invite to conference %s from %s has been dropped.\n", room, who);
- g_string_free(members, TRUE);
- return;
-@@ -165,7 +165,7 @@ void yahoo_process_conference_invite(Gai
- g_string_free(members, TRUE);
- }
-
--void yahoo_process_conference_decline(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_conference_decline(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l;
- char *room = NULL;
-@@ -201,7 +201,7 @@ void yahoo_process_conference_decline(Ga
-
- tmp = g_strdup_printf(_("%s declined your conference invitation to room \"%s\" because \"%s\"."),
- who, room, msg?msg:"");
-- gaim_notify_info(gc, NULL, _("Invitation Rejected"), tmp);
-+ gaim2_notify_info(gc, NULL, _("Invitation Rejected"), tmp);
- g_free(tmp);
- }
-
-@@ -211,12 +211,12 @@ void yahoo_process_conference_decline(Ga
- }
- }
-
--void yahoo_process_conference_logon(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_conference_logon(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l;
- char *room = NULL;
- char *who = NULL;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- for (l = pkt->hash; l; l = l->next) {
- struct yahoo_pair *pair = l->data;
-@@ -239,12 +239,12 @@ void yahoo_process_conference_logon(Gaim
- }
- }
-
--void yahoo_process_conference_logoff(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_conference_logoff(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l;
- char *room = NULL;
- char *who = NULL;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- for (l = pkt->hash; l; l = l->next) {
- struct yahoo_pair *pair = l->data;
-@@ -262,12 +262,12 @@ void yahoo_process_conference_logoff(Gai
- if (who && room) {
- c = yahoo_find_conference(gc, room);
- if (c)
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(c), who, NULL);
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(c), who, NULL);
- g_free(room);
- }
- }
-
--void yahoo_process_conference_message(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_conference_message(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l;
- char *room = NULL;
-@@ -275,7 +275,7 @@ void yahoo_process_conference_message(Ga
- char *msg = NULL;
- char *msg2;
- int utf8 = 0;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- for (l = pkt->hash; l; l = l->next) {
- struct yahoo_pair *pair = l->data;
-@@ -302,7 +302,7 @@ void yahoo_process_conference_message(Ga
- if (!c)
- return;
- msg = yahoo_codes_to_html(msg2);
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(c)), who, 0, msg, time(NULL));
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(c)), who, 0, msg, time(NULL));
- g_free(msg);
- g_free(msg2);
- }
-@@ -312,7 +312,7 @@ void yahoo_process_conference_message(Ga
-
-
- /* this is a confirmation of yahoo_chat_online(); */
--void yahoo_process_chat_online(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_online(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- struct yahoo_data *yd = (struct yahoo_data *) gc->proto_data;
-
-@@ -321,7 +321,7 @@ void yahoo_process_chat_online(GaimConne
- }
-
- /* this is basicly the opposite of chat_online */
--void yahoo_process_chat_logout(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_logout(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- struct yahoo_data *yd = (struct yahoo_data *) gc->proto_data;
- GSList *l;
-@@ -331,7 +331,7 @@ void yahoo_process_chat_logout(GaimConne
-
- if (pair->key == 1)
- if (g_ascii_strcasecmp(pair->value,
-- gaim_connection_get_display_name(gc)))
-+ gaim2_connection_get_display_name(gc)))
- return;
- }
-
-@@ -342,11 +342,11 @@ void yahoo_process_chat_logout(GaimConne
- }
- }
-
--void yahoo_process_chat_join(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_join(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = (struct yahoo_data *) gc->proto_data;
-- GaimConversation *c = NULL;
-+ Gaim2Conversation *c = NULL;
- GSList *l;
- GList *members = NULL;
- GList *roomies = NULL;
-@@ -355,7 +355,7 @@ void yahoo_process_chat_join(GaimConnect
- char *someid, *someotherid, *somebase64orhashosomething, *somenegativenumber;
-
- if (pkt->status == -1) {
-- gaim_notify_error(gc, NULL, _("Failed to join chat"), _("Maybe the room is full?"));
-+ gaim2_notify_error(gc, NULL, _("Failed to join chat"), _("Maybe the room is full?"));
- return;
- }
-
-@@ -406,54 +406,54 @@ void yahoo_process_chat_join(GaimConnect
- }
- }
-
-- if (room && yd->chat_name && gaim_utf8_strcasecmp(room, yd->chat_name))
-+ if (room && yd->chat_name && gaim2_utf8_strcasecmp(room, yd->chat_name))
- yahoo_chat_leave(gc, room,
-- gaim_connection_get_display_name(gc), FALSE);
-+ gaim2_connection_get_display_name(gc), FALSE);
-
-- c = gaim_find_chat(gc, YAHOO_CHAT_ID);
-+ c = gaim2_find_chat(gc, YAHOO_CHAT_ID);
-
-- if (room && (!c || gaim_conv_chat_has_left(GAIM_CONV_CHAT(c))) && members &&
-+ if (room && (!c || gaim2_conv_chat_has_left(GAIM_CONV_CHAT(c))) && members &&
- ((g_list_length(members) > 1) ||
-- !g_ascii_strcasecmp(members->data, gaim_connection_get_display_name(gc)))) {
-+ !g_ascii_strcasecmp(members->data, gaim2_connection_get_display_name(gc)))) {
- int i;
- GList *flags = NULL;
- for (i = 0; i < g_list_length(members); i++)
- flags = g_list_append(flags, GINT_TO_POINTER(GAIM_CBFLAGS_NONE));
-- if (c && gaim_conv_chat_has_left(GAIM_CONV_CHAT(c))) {
-+ if (c && gaim2_conv_chat_has_left(GAIM_CONV_CHAT(c))) {
- /* this might be a hack, but oh well, it should nicely */
- char *tmpmsg;
-
-- gaim_conversation_set_name(c, room);
-+ gaim2_conversation_set_name(c, room);
-
- c = serv_got_joined_chat(gc, YAHOO_CHAT_ID, room);
- if (topic)
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(c), NULL, topic);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(c), NULL, topic);
- yd->in_chat = 1;
- yd->chat_name = g_strdup(room);
-- gaim_conv_chat_add_users(GAIM_CONV_CHAT(c), members, NULL, flags, FALSE);
-+ gaim2_conv_chat_add_users(GAIM_CONV_CHAT(c), members, NULL, flags, FALSE);
-
- tmpmsg = g_strdup_printf(_("You are now chatting in %s."), room);
-- gaim_conv_chat_write(GAIM_CONV_CHAT(c), "", tmpmsg, GAIM_MESSAGE_SYSTEM, time(NULL));
-+ gaim2_conv_chat_write(GAIM_CONV_CHAT(c), "", tmpmsg, GAIM_MESSAGE_SYSTEM, time(NULL));
- g_free(tmpmsg);
- } else {
- c = serv_got_joined_chat(gc, YAHOO_CHAT_ID, room);
- if (topic)
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(c), NULL, topic);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(c), NULL, topic);
- yd->in_chat = 1;
- yd->chat_name = g_strdup(room);
-- gaim_conv_chat_add_users(GAIM_CONV_CHAT(c), members, NULL, flags, FALSE);
-+ gaim2_conv_chat_add_users(GAIM_CONV_CHAT(c), members, NULL, flags, FALSE);
- }
- } else if (c) {
- yahoo_chat_add_users(GAIM_CONV_CHAT(c), members);
- }
-
- if (account->deny && c) {
-- GaimConversationUiOps *ops = gaim_conversation_get_ui_ops(c);
-+ Gaim2ConversationUiOps *ops = gaim2_conversation_get_ui_ops(c);
- for (l = account->deny; l != NULL; l = l->next) {
- for (roomies = members; roomies; roomies = roomies->next) {
-- if (!gaim_utf8_strcasecmp((char *)l->data, roomies->data)) {
-- gaim_debug_info("yahoo", "Ignoring room member %s in room %s\n" , roomies->data, room ? room : "");
-- gaim_conv_chat_ignore(GAIM_CONV_CHAT(c),roomies->data);
-+ if (!gaim2_utf8_strcasecmp((char *)l->data, roomies->data)) {
-+ gaim2_debug_info("yahoo", "Ignoring room member %s in room %s\n" , roomies->data, room ? room : "");
-+ gaim2_conv_chat_ignore(GAIM_CONV_CHAT(c),roomies->data);
- ops->chat_update_user(c, roomies->data);
- }
- }
-@@ -465,7 +465,7 @@ void yahoo_process_chat_join(GaimConnect
- g_free(topic);
- }
-
--void yahoo_process_chat_exit(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_exit(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *who = NULL;
- char *room = NULL;
-@@ -484,20 +484,20 @@ void yahoo_process_chat_exit(GaimConnect
- }
-
- if (who && room) {
-- GaimConversation *c = gaim_find_chat(gc, YAHOO_CHAT_ID);
-- if (c && !gaim_utf8_strcasecmp(gaim_conversation_get_name(c), room))
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(c), who, NULL);
-+ Gaim2Conversation *c = gaim2_find_chat(gc, YAHOO_CHAT_ID);
-+ if (c && !gaim2_utf8_strcasecmp(gaim2_conversation_get_name(c), room))
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(c), who, NULL);
-
- }
- if (room)
- g_free(room);
- }
-
--void yahoo_process_chat_message(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_message(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *room = NULL, *who = NULL, *msg = NULL, *msg2;
- int msgtype = 1, utf8 = 1; /* default to utf8 */
-- GaimConversation *c = NULL;
-+ Gaim2Conversation *c = NULL;
- GSList *l;
-
- for (l = pkt->hash; l; l = l->next) {
-@@ -523,7 +523,7 @@ void yahoo_process_chat_message(GaimConn
- }
- }
-
-- c = gaim_find_chat(gc, YAHOO_CHAT_ID);
-+ c = gaim2_find_chat(gc, YAHOO_CHAT_ID);
- if (!who || !c) {
- if (room)
- g_free(room);
-@@ -532,7 +532,7 @@ void yahoo_process_chat_message(GaimConn
- }
-
- if (!msg) {
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "Got a message packet with no message.\nThis probably means something important, but we're ignoring it.\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "Got a message packet with no message.\nThis probably means something important, but we're ignoring it.\n");
- return;
- }
- msg2 = yahoo_string_decode(gc, msg, utf8);
-@@ -551,7 +551,7 @@ void yahoo_process_chat_message(GaimConn
- g_free(room);
- }
-
--void yahoo_process_chat_addinvite(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_addinvite(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l;
- char *room = NULL;
-@@ -586,7 +586,7 @@ void yahoo_process_chat_addinvite(GaimCo
- components = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free);
- g_hash_table_replace(components, g_strdup("room"), g_strdup(room));
- if (!yahoo_privacy_check(gc, who)) {
-- gaim_debug_info("yahoo",
-+ gaim2_debug_info("yahoo",
- "Invite to room %s from %s has been dropped.\n", room, who);
- if (room != NULL)
- g_free(room);
-@@ -602,10 +602,10 @@ void yahoo_process_chat_addinvite(GaimCo
- g_free(msg);
- }
-
--void yahoo_process_chat_goto(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_chat_goto(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- if (pkt->status == -1)
-- gaim_notify_error(gc, NULL, _("Failed to join buddy in chat"),
-+ gaim2_notify_error(gc, NULL, _("Failed to join buddy in chat"),
- _("Maybe they're not in a chat?"));
- }
-
-@@ -619,13 +619,13 @@ void yahoo_conf_leave(struct yahoo_data
- struct yahoo_packet *pkt;
- GList *w;
-
-- gaim_debug_misc("yahoo", "leaving conference %s\n", room);
-+ gaim2_debug_misc("yahoo", "leaving conference %s\n", room);
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_CONFLOGOFF, YAHOO_STATUS_AVAILABLE, 0);
-
- yahoo_packet_hash_str(pkt, 1, dn);
- for (w = who; w; w = w->next) {
-- const char *name = gaim_conv_chat_cb_get_name(w->data);
-+ const char *name = gaim2_conv_chat_cb_get_name(w->data);
- yahoo_packet_hash_str(pkt, 3, name);
- }
-
-@@ -633,7 +633,7 @@ void yahoo_conf_leave(struct yahoo_data
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--static int yahoo_conf_send(GaimConnection *gc, const char *dn, const char *room,
-+static int yahoo_conf_send(Gaim2Connection *gc, const char *dn, const char *room,
- GList *members, const char *what)
- {
- struct yahoo_data *yd = gc->proto_data;
-@@ -649,7 +649,7 @@ static int yahoo_conf_send(GaimConnectio
-
- yahoo_packet_hash_str(pkt, 1, dn);
- for (who = members; who; who = who->next) {
-- const char *name = gaim_conv_chat_cb_get_name(who->data);
-+ const char *name = gaim2_conv_chat_cb_get_name(who->data);
- yahoo_packet_hash_str(pkt, 53, name);
- }
- yahoo_packet_hash(pkt, "ss", 57, room, 14, msg2);
-@@ -663,7 +663,7 @@ static int yahoo_conf_send(GaimConnectio
- return 0;
- }
-
--static void yahoo_conf_join(struct yahoo_data *yd, GaimConversation *c, const char *dn, const char *room,
-+static void yahoo_conf_join(struct yahoo_data *yd, Gaim2Conversation *c, const char *dn, const char *room,
- const char *topic, const char *members)
- {
- struct yahoo_packet *pkt;
-@@ -681,7 +681,7 @@ static void yahoo_conf_join(struct yahoo
- if (!strcmp(memarr[i], "") || !strcmp(memarr[i], dn))
- continue;
- yahoo_packet_hash_str(pkt, 3, memarr[i]);
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(c), memarr[i], NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(c), memarr[i], NULL, GAIM_CBFLAGS_NONE, TRUE);
- }
- }
- yahoo_packet_send_and_free(pkt, yd);
-@@ -690,7 +690,7 @@ static void yahoo_conf_join(struct yahoo
- g_strfreev(memarr);
- }
-
--static void yahoo_conf_invite(GaimConnection *gc, GaimConversation *c,
-+static void yahoo_conf_invite(Gaim2Connection *gc, Gaim2Conversation *c,
- const char *dn, const char *buddy, const char *room, const char *msg)
- {
- struct yahoo_data *yd = gc->proto_data;
-@@ -701,13 +701,13 @@ static void yahoo_conf_invite(GaimConnec
- if (msg)
- msg2 = yahoo_string_encode(gc, msg, NULL);
-
-- members = gaim_conv_chat_get_users(GAIM_CONV_CHAT(c));
-+ members = gaim2_conv_chat_get_users(GAIM_CONV_CHAT(c));
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_CONFADDINVITE, YAHOO_STATUS_AVAILABLE, 0);
-
- yahoo_packet_hash(pkt, "sssss", 1, dn, 51, buddy, 57, room, 58, msg?msg2:"", 13, "0");
- for(; members; members = members->next) {
-- const char *name = gaim_conv_chat_cb_get_name(members->data);
-+ const char *name = gaim2_conv_chat_cb_get_name(members->data);
- if (!strcmp(name, dn))
- continue;
- yahoo_packet_hash(pkt, "ss", 52, name, 53, name);
-@@ -721,11 +721,11 @@ static void yahoo_conf_invite(GaimConnec
- * Functions dealing with chats
- */
-
--static void yahoo_chat_leave(GaimConnection *gc, const char *room, const char *dn, gboolean logout)
-+static void yahoo_chat_leave(Gaim2Connection *gc, const char *room, const char *dn, gboolean logout)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
- char *eroom;
- gboolean utf8 = 1;
-
-@@ -749,7 +749,7 @@ static void yahoo_chat_leave(GaimConnect
- yd->chat_name = NULL;
- }
-
-- if ((c = gaim_find_chat(gc, YAHOO_CHAT_ID)))
-+ if ((c = gaim2_find_chat(gc, YAHOO_CHAT_ID)))
- serv_got_chat_left(gc, YAHOO_CHAT_ID);
-
- if (!logout)
-@@ -802,7 +802,7 @@ meify(char *message, size_t len)
- return FALSE;
- }
-
--static int yahoo_chat_send(GaimConnection *gc, const char *dn, const char *room, const char *what, GaimMessageFlags flags)
-+static int yahoo_chat_send(Gaim2Connection *gc, const char *dn, const char *room, const char *what, Gaim2MessageFlags flags)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-@@ -845,7 +845,7 @@ static int yahoo_chat_send(GaimConnectio
- return 0;
- }
-
--static void yahoo_chat_join(GaimConnection *gc, const char *dn, const char *room, const char *topic)
-+static void yahoo_chat_join(Gaim2Connection *gc, const char *dn, const char *room, const char *topic)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-@@ -863,13 +863,13 @@ static void yahoo_chat_join(GaimConnecti
- room2 = yahoo_string_encode(gc, room, &utf8);
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_CHATJOIN, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "ssss", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "ssss", 1, gaim2_connection_get_display_name(gc),
- 62, "2", 104, room2, 129, "0");
- yahoo_packet_send_and_free(pkt, yd);
- g_free(room2);
- }
-
--static void yahoo_chat_invite(GaimConnection *gc, const char *dn, const char *buddy,
-+static void yahoo_chat_invite(Gaim2Connection *gc, const char *dn, const char *buddy,
- const char *room, const char *msg)
- {
- struct yahoo_data *yd = gc->proto_data;
-@@ -895,7 +895,7 @@ static void yahoo_chat_invite(GaimConnec
- g_free(msg2);
- }
-
--void yahoo_chat_goto(GaimConnection *gc, const char *name)
-+void yahoo_chat_goto(Gaim2Connection *gc, const char *name)
- {
- struct yahoo_data *yd;
- struct yahoo_packet *pkt;
-@@ -912,7 +912,7 @@ void yahoo_chat_goto(GaimConnection *gc,
- yahoo_chat_online(gc);
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_CHATGOTO, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sss", 109, name, 1, gaim_connection_get_display_name(gc), 62, "2");
-+ yahoo_packet_hash(pkt, "sss", 109, name, 1, gaim2_connection_get_display_name(gc), 62, "2");
- yahoo_packet_send_and_free(pkt, yd);
- }
- /*
-@@ -920,32 +920,32 @@ void yahoo_chat_goto(GaimConnection *gc,
- * which get called for both chats and conferences.
- */
-
--void yahoo_c_leave(GaimConnection *gc, int id)
-+void yahoo_c_leave(Gaim2Connection *gc, int id)
- {
- struct yahoo_data *yd = (struct yahoo_data *) gc->proto_data;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- if (!yd)
- return;
-
-- c = gaim_find_chat(gc, id);
-+ c = gaim2_find_chat(gc, id);
- if (!c)
- return;
-
- if (id != YAHOO_CHAT_ID) {
-- yahoo_conf_leave(yd, gaim_conversation_get_name(c),
-- gaim_connection_get_display_name(gc), gaim_conv_chat_get_users(GAIM_CONV_CHAT(c)));
-+ yahoo_conf_leave(yd, gaim2_conversation_get_name(c),
-+ gaim2_connection_get_display_name(gc), gaim2_conv_chat_get_users(GAIM_CONV_CHAT(c)));
- yd->confs = g_slist_remove(yd->confs, c);
- } else {
-- yahoo_chat_leave(gc, gaim_conversation_get_name(c), gaim_connection_get_display_name(gc), TRUE);
-+ yahoo_chat_leave(gc, gaim2_conversation_get_name(c), gaim2_connection_get_display_name(gc), TRUE);
- }
-
- serv_got_chat_left(gc, id);
- }
-
--int yahoo_c_send(GaimConnection *gc, int id, const char *what, GaimMessageFlags flags)
-+int yahoo_c_send(Gaim2Connection *gc, int id, const char *what, Gaim2MessageFlags flags)
- {
-- GaimConversation *c;
-+ Gaim2Conversation *c;
- int ret;
- struct yahoo_data *yd;
-
-@@ -953,24 +953,24 @@ int yahoo_c_send(GaimConnection *gc, int
- if (!yd)
- return -1;
-
-- c = gaim_find_chat(gc, id);
-+ c = gaim2_find_chat(gc, id);
- if (!c)
- return -1;
-
- if (id != YAHOO_CHAT_ID) {
-- ret = yahoo_conf_send(gc, gaim_connection_get_display_name(gc),
-- gaim_conversation_get_name(c), gaim_conv_chat_get_users(GAIM_CONV_CHAT(c)), what);
-+ ret = yahoo_conf_send(gc, gaim2_connection_get_display_name(gc),
-+ gaim2_conversation_get_name(c), gaim2_conv_chat_get_users(GAIM_CONV_CHAT(c)), what);
- } else {
-- ret = yahoo_chat_send(gc, gaim_connection_get_display_name(gc),
-- gaim_conversation_get_name(c), what, flags);
-+ ret = yahoo_chat_send(gc, gaim2_connection_get_display_name(gc),
-+ gaim2_conversation_get_name(c), what, flags);
- if (!ret)
-- serv_got_chat_in(gc, gaim_conv_chat_get_id(GAIM_CONV_CHAT(c)),
-- gaim_connection_get_display_name(gc), 0, what, time(NULL));
-+ serv_got_chat_in(gc, gaim2_conv_chat_get_id(GAIM_CONV_CHAT(c)),
-+ gaim2_connection_get_display_name(gc), 0, what, time(NULL));
- }
- return ret;
- }
-
--GList *yahoo_c_info(GaimConnection *gc)
-+GList *yahoo_c_info(Gaim2Connection *gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -984,7 +984,7 @@ GList *yahoo_c_info(GaimConnection *gc)
- return m;
- }
-
--GHashTable *yahoo_c_info_defaults(GaimConnection *gc, const char *chat_name)
-+GHashTable *yahoo_c_info_defaults(Gaim2Connection *gc, const char *chat_name)
- {
- GHashTable *defaults;
-
-@@ -1001,12 +1001,12 @@ char *yahoo_get_chat_name(GHashTable *da
- return g_strdup(g_hash_table_lookup(data, "room"));
- }
-
--void yahoo_c_join(GaimConnection *gc, GHashTable *data)
-+void yahoo_c_join(Gaim2Connection *gc, GHashTable *data)
- {
- struct yahoo_data *yd;
- char *room, *topic, *members, *type;
- int id;
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
- yd = (struct yahoo_data *) gc->proto_data;
- if (!yd)
-@@ -1026,35 +1026,35 @@ void yahoo_c_join(GaimConnection *gc, GH
- id = yd->conf_id++;
- c = serv_got_joined_chat(gc, id, room);
- yd->confs = g_slist_prepend(yd->confs, c);
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(c), gaim_connection_get_display_name(gc), topic);
-- yahoo_conf_join(yd, c, gaim_connection_get_display_name(gc), room, topic, members);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(c), gaim2_connection_get_display_name(gc), topic);
-+ yahoo_conf_join(yd, c, gaim2_connection_get_display_name(gc), room, topic, members);
- return;
- } else {
- if (yd->in_chat)
- yahoo_chat_leave(gc, room,
-- gaim_connection_get_display_name(gc),
-+ gaim2_connection_get_display_name(gc),
- FALSE);
- if (!yd->chat_online)
- yahoo_chat_online(gc);
-- yahoo_chat_join(gc, gaim_connection_get_display_name(gc), room, topic);
-+ yahoo_chat_join(gc, gaim2_connection_get_display_name(gc), room, topic);
- return;
- }
- }
-
--void yahoo_c_invite(GaimConnection *gc, int id, const char *msg, const char *name)
-+void yahoo_c_invite(Gaim2Connection *gc, int id, const char *msg, const char *name)
- {
-- GaimConversation *c;
-+ Gaim2Conversation *c;
-
-- c = gaim_find_chat(gc, id);
-+ c = gaim2_find_chat(gc, id);
- if (!c || !c->name)
- return;
-
- if (id != YAHOO_CHAT_ID) {
-- yahoo_conf_invite(gc, c, gaim_connection_get_display_name(gc), name,
-- gaim_conversation_get_name(c), msg);
-+ yahoo_conf_invite(gc, c, gaim2_connection_get_display_name(gc), name,
-+ gaim2_conversation_get_name(c), msg);
- } else {
-- yahoo_chat_invite(gc, gaim_connection_get_display_name(gc), name,
-- gaim_conversation_get_name(c), msg);
-+ yahoo_chat_invite(gc, gaim2_connection_get_display_name(gc), name,
-+ gaim2_conversation_get_name(c), msg);
- }
- }
-
-@@ -1066,16 +1066,16 @@ struct yahoo_roomlist {
- gboolean started;
- char *path;
- char *host;
-- GaimRoomlist *list;
-- GaimRoomlistRoom *cat;
-- GaimRoomlistRoom *ucat;
-+ Gaim2Roomlist *list;
-+ Gaim2RoomlistRoom *cat;
-+ Gaim2RoomlistRoom *ucat;
- GMarkupParseContext *parse;
- };
-
- static void yahoo_roomlist_destroy(struct yahoo_roomlist *yrl)
- {
- if (yrl->inpa)
-- gaim_input_remove(yrl->inpa);
-+ gaim2_input_remove(yrl->inpa);
- if (yrl->rxqueue)
- g_free(yrl->rxqueue);
- if (yrl->path)
-@@ -1093,7 +1093,7 @@ enum yahoo_room_type {
- };
-
- struct yahoo_chatxml_state {
-- GaimRoomlist *list;
-+ Gaim2Roomlist *list;
- struct yahoo_roomlist *yrl;
- GQueue *q;
- struct {
-@@ -1109,7 +1109,7 @@ struct yahoo_lobby {
- int count, users, voices, webcams;
- };
-
--static struct yahoo_chatxml_state *yahoo_chatxml_state_new(GaimRoomlist *list, struct yahoo_roomlist *yrl)
-+static struct yahoo_chatxml_state *yahoo_chatxml_state_new(Gaim2Roomlist *list, struct yahoo_roomlist *yrl)
- {
- struct yahoo_chatxml_state *s;
-
-@@ -1139,9 +1139,9 @@ static void yahoo_chatlist_start_element
- GError **error)
- {
- struct yahoo_chatxml_state *s = user_data;
-- GaimRoomlist *list = s->list;
-- GaimRoomlistRoom *r;
-- GaimRoomlistRoom *parent;
-+ Gaim2Roomlist *list = s->list;
-+ Gaim2RoomlistRoom *r;
-+ Gaim2RoomlistRoom *parent;
- int i;
-
- if (!strcmp(ename, "category")) {
-@@ -1157,10 +1157,10 @@ static void yahoo_chatlist_start_element
- return;
-
- parent = g_queue_peek_head(s->q);
-- r = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY, name, parent);
-- gaim_roomlist_room_add_field(list, r, (gpointer)name);
-- gaim_roomlist_room_add_field(list, r, (gpointer)id);
-- gaim_roomlist_room_add(list, r);
-+ r = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY, name, parent);
-+ gaim2_roomlist_room_add_field(list, r, (gpointer)name);
-+ gaim2_roomlist_room_add_field(list, r, (gpointer)id);
-+ gaim2_roomlist_room_add(list, r);
- g_queue_push_head(s->q, r);
- } else if (!strcmp(ename, "room")) {
- s->room.users = s->room.voices = s->room.webcams = 0;
-@@ -1213,34 +1213,34 @@ static void yahoo_chatlist_end_element(G
- g_queue_pop_head(s->q);
- } else if (!strcmp(ename, "room")) {
- struct yahoo_lobby *lob;
-- GaimRoomlistRoom *r, *l;
-+ Gaim2RoomlistRoom *r, *l;
-
- if (s->room.type == yrt_yahoo)
-- r = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY|GAIM_ROOMLIST_ROOMTYPE_ROOM,
-+ r = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY|GAIM_ROOMLIST_ROOMTYPE_ROOM,
- s->room.name, s->yrl->cat);
- else
-- r = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY|GAIM_ROOMLIST_ROOMTYPE_ROOM,
-+ r = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY|GAIM_ROOMLIST_ROOMTYPE_ROOM,
- s->room.name, s->yrl->ucat);
-
-- gaim_roomlist_room_add_field(s->list, r, s->room.name);
-- gaim_roomlist_room_add_field(s->list, r, s->room.id);
-- gaim_roomlist_room_add_field(s->list, r, GINT_TO_POINTER(s->room.users));
-- gaim_roomlist_room_add_field(s->list, r, GINT_TO_POINTER(s->room.voices));
-- gaim_roomlist_room_add_field(s->list, r, GINT_TO_POINTER(s->room.webcams));
-- gaim_roomlist_room_add_field(s->list, r, s->room.topic);
-- gaim_roomlist_room_add(s->list, r);
-+ gaim2_roomlist_room_add_field(s->list, r, s->room.name);
-+ gaim2_roomlist_room_add_field(s->list, r, s->room.id);
-+ gaim2_roomlist_room_add_field(s->list, r, GINT_TO_POINTER(s->room.users));
-+ gaim2_roomlist_room_add_field(s->list, r, GINT_TO_POINTER(s->room.voices));
-+ gaim2_roomlist_room_add_field(s->list, r, GINT_TO_POINTER(s->room.webcams));
-+ gaim2_roomlist_room_add_field(s->list, r, s->room.topic);
-+ gaim2_roomlist_room_add(s->list, r);
-
- while ((lob = g_queue_pop_head(s->q))) {
- char *name = g_strdup_printf("%s:%d", s->room.name, lob->count);
-- l = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, name, r);
-+ l = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_ROOM, name, r);
-
-- gaim_roomlist_room_add_field(s->list, l, name);
-- gaim_roomlist_room_add_field(s->list, l, s->room.id);
-- gaim_roomlist_room_add_field(s->list, l, GINT_TO_POINTER(lob->users));
-- gaim_roomlist_room_add_field(s->list, l, GINT_TO_POINTER(lob->voices));
-- gaim_roomlist_room_add_field(s->list, l, GINT_TO_POINTER(lob->webcams));
-- gaim_roomlist_room_add_field(s->list, l, s->room.topic);
-- gaim_roomlist_room_add(s->list, l);
-+ gaim2_roomlist_room_add_field(s->list, l, name);
-+ gaim2_roomlist_room_add_field(s->list, l, s->room.id);
-+ gaim2_roomlist_room_add_field(s->list, l, GINT_TO_POINTER(lob->users));
-+ gaim2_roomlist_room_add_field(s->list, l, GINT_TO_POINTER(lob->voices));
-+ gaim2_roomlist_room_add_field(s->list, l, GINT_TO_POINTER(lob->webcams));
-+ gaim2_roomlist_room_add_field(s->list, l, s->room.topic);
-+ gaim2_roomlist_room_add(s->list, l);
-
- g_free(name);
- g_free(lob);
-@@ -1256,22 +1256,22 @@ static GMarkupParser parser = {
- NULL
- };
-
--static void yahoo_roomlist_cleanup(GaimRoomlist *list, struct yahoo_roomlist *yrl)
-+static void yahoo_roomlist_cleanup(Gaim2Roomlist *list, struct yahoo_roomlist *yrl)
- {
-- gaim_roomlist_set_in_progress(list, FALSE);
-+ gaim2_roomlist_set_in_progress(list, FALSE);
-
- if (yrl) {
- list->proto_data = g_list_remove(list->proto_data, yrl);
- yahoo_roomlist_destroy(yrl);
- }
-
-- gaim_roomlist_unref(list);
-+ gaim2_roomlist_unref(list);
- }
-
--static void yahoo_roomlist_pending(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_roomlist_pending(gpointer data, gint source, Gaim2InputCondition cond)
- {
- struct yahoo_roomlist *yrl = data;
-- GaimRoomlist *list = yrl->list;
-+ Gaim2Roomlist *list = yrl->list;
- char buf[1024];
- int len;
- guchar *start;
-@@ -1315,15 +1315,15 @@ static void yahoo_roomlist_pending(gpoin
- yrl->rxlen = 0;
- }
-
--static void yahoo_roomlist_got_connected(gpointer data, gint source, GaimInputCondition cond)
-+static void yahoo_roomlist_got_connected(gpointer data, gint source, Gaim2InputCondition cond)
- {
- struct yahoo_roomlist *yrl = data;
-- GaimRoomlist *list = yrl->list;
-+ Gaim2Roomlist *list = yrl->list;
- char *buf, *cookie;
-- struct yahoo_data *yd = gaim_account_get_connection(list->account)->proto_data;
-+ struct yahoo_data *yd = gaim2_account_get_connection(list->account)->proto_data;
-
- if (source < 0) {
-- gaim_notify_error(gaim_account_get_connection(list->account), NULL, _("Unable to connect"), _("Fetching the room list failed."));
-+ gaim2_notify_error(gaim2_account_get_connection(list->account), NULL, _("Unable to connect"), _("Fetching the room list failed."));
- yahoo_roomlist_cleanup(list, yrl);
- return;
- }
-@@ -1336,90 +1336,90 @@ static void yahoo_roomlist_got_connected
- write(yrl->fd, buf, strlen(buf));
- g_free(cookie);
- g_free(buf);
-- yrl->inpa = gaim_input_add(yrl->fd, GAIM_INPUT_READ, yahoo_roomlist_pending, yrl);
-+ yrl->inpa = gaim2_input_add(yrl->fd, GAIM_INPUT_READ, yahoo_roomlist_pending, yrl);
-
- }
-
--GaimRoomlist *yahoo_roomlist_get_list(GaimConnection *gc)
-+Gaim2Roomlist *yahoo_roomlist_get_list(Gaim2Connection *gc)
- {
- struct yahoo_roomlist *yrl;
-- GaimRoomlist *rl;
-+ Gaim2Roomlist *rl;
- const char *rll;
- char *url;
- GList *fields = NULL;
-- GaimRoomlistField *f;
-+ Gaim2RoomlistField *f;
-
-- rll = gaim_account_get_string(gaim_connection_get_account(gc),
-+ rll = gaim2_account_get_string(gaim2_connection_get_account(gc),
- "room_list_locale", YAHOO_ROOMLIST_LOCALE);
-
- if (rll != NULL && *rll != '\0') {
- url = g_strdup_printf("%s?chatcat=0&intl=%s",
-- gaim_account_get_string(gaim_connection_get_account(gc),
-+ gaim2_account_get_string(gaim2_connection_get_account(gc),
- "room_list", YAHOO_ROOMLIST_URL), rll);
- } else {
- url = g_strdup_printf("%s?chatcat=0",
-- gaim_account_get_string(gaim_connection_get_account(gc),
-+ gaim2_account_get_string(gaim2_connection_get_account(gc),
- "room_list", YAHOO_ROOMLIST_URL));
- }
-
- yrl = g_new0(struct yahoo_roomlist, 1);
-- rl = gaim_roomlist_new(gaim_connection_get_account(gc));
-+ rl = gaim2_roomlist_new(gaim2_connection_get_account(gc));
- yrl->list = rl;
-
-- gaim_url_parse(url, &(yrl->host), NULL, &(yrl->path), NULL, NULL);
-+ gaim2_url_parse(url, &(yrl->host), NULL, &(yrl->path), NULL, NULL);
- g_free(url);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "room", TRUE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "room", TRUE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "id", TRUE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, "", "id", TRUE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Users"), "users", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Users"), "users", FALSE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Voices"), "voices", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Voices"), "voices", FALSE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Webcams"), "webcams", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_INT, _("Webcams"), "webcams", FALSE);
- fields = g_list_append(fields, f);
-
-- f = gaim_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, _("Topic"), "topic", FALSE);
-+ f = gaim2_roomlist_field_new(GAIM_ROOMLIST_FIELD_STRING, _("Topic"), "topic", FALSE);
- fields = g_list_append(fields, f);
-
-- gaim_roomlist_set_fields(rl, fields);
-+ gaim2_roomlist_set_fields(rl, fields);
-
-- if (gaim_proxy_connect(gaim_connection_get_account(gc),
-+ if (gaim2_proxy_connect(gaim2_connection_get_account(gc),
- yrl->host, 80, yahoo_roomlist_got_connected, yrl) != 0)
- {
-- gaim_notify_error(gc, NULL, _("Connection problem"), _("Unable to fetch room list."));
-+ gaim2_notify_error(gc, NULL, _("Connection problem"), _("Unable to fetch room list."));
- yahoo_roomlist_cleanup(rl, yrl);
- return NULL;
- }
-
- rl->proto_data = g_list_append(rl->proto_data, yrl);
-
-- gaim_roomlist_set_in_progress(rl, TRUE);
-+ gaim2_roomlist_set_in_progress(rl, TRUE);
- return rl;
- }
-
--void yahoo_roomlist_cancel(GaimRoomlist *list)
-+void yahoo_roomlist_cancel(Gaim2Roomlist *list)
- {
- GList *l, *k;
-
- k = l = list->proto_data;
- list->proto_data = NULL;
-
-- gaim_roomlist_set_in_progress(list, FALSE);
-+ gaim2_roomlist_set_in_progress(list, FALSE);
-
- for (; l; l = l->next) {
- yahoo_roomlist_destroy(l->data);
-- gaim_roomlist_unref(list);
-+ gaim2_roomlist_unref(list);
- }
- g_list_free(k);
- }
-
--void yahoo_roomlist_expand_category(GaimRoomlist *list, GaimRoomlistRoom *category)
-+void yahoo_roomlist_expand_category(Gaim2Roomlist *list, Gaim2RoomlistRoom *category)
- {
- struct yahoo_roomlist *yrl;
- char *url;
-@@ -1430,20 +1430,20 @@ void yahoo_roomlist_expand_category(Gaim
- return;
-
- if (!(id = g_list_nth_data(category->fields, 1))) {
-- gaim_roomlist_set_in_progress(list, FALSE);
-+ gaim2_roomlist_set_in_progress(list, FALSE);
- return;
- }
-
-- rll = gaim_account_get_string(list->account, "room_list_locale",
-+ rll = gaim2_account_get_string(list->account, "room_list_locale",
- YAHOO_ROOMLIST_LOCALE);
-
- if (rll != NULL && *rll != '\0') {
- url = g_strdup_printf("%s?chatroom_%s=0&intl=%s",
-- gaim_account_get_string(list->account,"room_list",
-+ gaim2_account_get_string(list->account,"room_list",
- YAHOO_ROOMLIST_URL), id, rll);
- } else {
- url = g_strdup_printf("%s?chatroom_%s=0",
-- gaim_account_get_string(list->account,"room_list",
-+ gaim2_account_get_string(list->account,"room_list",
- YAHOO_ROOMLIST_URL), id);
- }
-
-@@ -1452,22 +1452,22 @@ void yahoo_roomlist_expand_category(Gaim
- yrl->cat = category;
- list->proto_data = g_list_append(list->proto_data, yrl);
-
-- gaim_url_parse(url, &(yrl->host), NULL, &(yrl->path), NULL, NULL);
-+ gaim2_url_parse(url, &(yrl->host), NULL, &(yrl->path), NULL, NULL);
- g_free(url);
-
-- yrl->ucat = gaim_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY, _("User Rooms"), yrl->cat);
-- gaim_roomlist_room_add(list, yrl->ucat);
-+ yrl->ucat = gaim2_roomlist_room_new(GAIM_ROOMLIST_ROOMTYPE_CATEGORY, _("User Rooms"), yrl->cat);
-+ gaim2_roomlist_room_add(list, yrl->ucat);
-
-- if (gaim_proxy_connect(list->account,
-+ if (gaim2_proxy_connect(list->account,
- yrl->host, 80, yahoo_roomlist_got_connected, yrl) != 0)
- {
-- gaim_notify_error(gaim_account_get_connection(list->account),
-+ gaim2_notify_error(gaim2_account_get_connection(list->account),
- NULL, _("Connection problem"), _("Unable to fetch room list."));
-- gaim_roomlist_ref(list);
-+ gaim2_roomlist_ref(list);
- yahoo_roomlist_cleanup(list, yrl);
- return;
- }
-
-- gaim_roomlist_set_in_progress(list, TRUE);
-- gaim_roomlist_ref(list);
-+ gaim2_roomlist_set_in_progress(list, TRUE);
-+ gaim2_roomlist_ref(list);
- }
-diff -prNu ./src/protocols/yahoo/yahoochat.h ./src/protocols/yahoo/yahoochat.h
---- ./src/protocols/yahoo/yahoochat.h 2005-12-08 21:57:14.000000000 +0100
-+++ ./src/protocols/yahoo/yahoochat.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file yahoochat.h The Yahoo! protocol plugin, chat and conference stuff
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,39 +28,39 @@
- #include "roomlist.h"
- #include "yahoo_packet.h"
-
--void yahoo_process_conference_invite(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_conference_decline(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_conference_logon(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_conference_logoff(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_conference_message(GaimConnection *gc, struct yahoo_packet *pkt);
--
--void yahoo_process_chat_online(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_chat_logout(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_chat_join(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_chat_exit(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_chat_message(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_chat_addinvite(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_chat_goto(GaimConnection *gc, struct yahoo_packet *pkt);
--
--void yahoo_c_leave(GaimConnection *gc, int id);
--int yahoo_c_send(GaimConnection *gc, int id, const char *what, GaimMessageFlags flags);
--GList *yahoo_c_info(GaimConnection *gc);
--GHashTable *yahoo_c_info_defaults(GaimConnection *gc, const char *chat_name);
--void yahoo_c_join(GaimConnection *gc, GHashTable *data);
-+void yahoo_process_conference_invite(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_conference_decline(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_conference_logon(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_conference_logoff(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_conference_message(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+
-+void yahoo_process_chat_online(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_chat_logout(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_chat_join(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_chat_exit(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_chat_message(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_chat_addinvite(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_chat_goto(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+
-+void yahoo_c_leave(Gaim2Connection *gc, int id);
-+int yahoo_c_send(Gaim2Connection *gc, int id, const char *what, Gaim2MessageFlags flags);
-+GList *yahoo_c_info(Gaim2Connection *gc);
-+GHashTable *yahoo_c_info_defaults(Gaim2Connection *gc, const char *chat_name);
-+void yahoo_c_join(Gaim2Connection *gc, GHashTable *data);
- char *yahoo_get_chat_name(GHashTable *data);
--void yahoo_c_invite(GaimConnection *gc, int id, const char *msg, const char *name);
-+void yahoo_c_invite(Gaim2Connection *gc, int id, const char *msg, const char *name);
-
- void yahoo_conf_leave(struct yahoo_data *yd, const char *room, const char *dn, GList *who);
-
--void yahoo_chat_goto(GaimConnection *gc, const char *name);
-+void yahoo_chat_goto(Gaim2Connection *gc, const char *name);
-
- /* room listing functions */
--GaimRoomlist *yahoo_roomlist_get_list(GaimConnection *gc);
--void yahoo_roomlist_cancel(GaimRoomlist *list);
--void yahoo_roomlist_expand_category(GaimRoomlist *list, GaimRoomlistRoom *category);
-+Gaim2Roomlist *yahoo_roomlist_get_list(Gaim2Connection *gc);
-+void yahoo_roomlist_cancel(Gaim2Roomlist *list);
-+void yahoo_roomlist_expand_category(Gaim2Roomlist *list, Gaim2RoomlistRoom *category);
-
- /* util */
--void yahoo_chat_add_users(GaimConvChat *chat, GList *newusers);
--void yahoo_chat_add_user(GaimConvChat *chat, const char *user, const char *reason);
-+void yahoo_chat_add_users(Gaim2ConvChat *chat, GList *newusers);
-+void yahoo_chat_add_user(Gaim2ConvChat *chat, const char *user, const char *reason);
-
- #endif /* _YAHOO_CHAT_H_ */
-diff -prNu ./src/protocols/yahoo/yahoo_crypt.c ./src/protocols/yahoo/yahoo_crypt.c
---- ./src/protocols/yahoo/yahoo_crypt.c 2005-12-08 22:06:51.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_crypt.c 2006-01-05 15:11:07.000000000 +0100
-@@ -40,8 +40,8 @@ static const char b64t[64] =
-
- char *yahoo_crypt(const char *key, const char *salt)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *context1, *context2;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *context1, *context2;
- guchar digest[16];
- static char *buffer = NULL;
- static int buflen = 0;
-@@ -59,9 +59,9 @@ char *yahoo_crypt(const char *key, const
- return NULL;
- }
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- context1 = gaim_cipher_context_new(cipher, NULL);
-- context2 = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ context1 = gaim2_cipher_context_new(cipher, NULL);
-+ context2 = gaim2_cipher_context_new(cipher, NULL);
-
- /* Find beginning of salt string. The prefix should normally always
- * be present. Just in case it is not.
-@@ -74,40 +74,40 @@ char *yahoo_crypt(const char *key, const
- key_len = strlen (key);
-
- /* Add the key string. */
-- gaim_cipher_context_append(context1, (const guchar *)key, key_len);
-+ gaim2_cipher_context_append(context1, (const guchar *)key, key_len);
-
- /* Because the SALT argument need not always have the salt prefix we
- * add it separately.
- */
-- gaim_cipher_context_append(context1, (const guchar *)md5_salt_prefix,
-+ gaim2_cipher_context_append(context1, (const guchar *)md5_salt_prefix,
- sizeof(md5_salt_prefix) - 1);
-
- /* The last part is the salt string. This must be at most 8
- * characters and it ends at the first `$' character (for
- * compatibility which existing solutions).
- */
-- gaim_cipher_context_append(context1, (const guchar *)salt, salt_len);
-+ gaim2_cipher_context_append(context1, (const guchar *)salt, salt_len);
-
- /* Compute alternate MD5 sum with input KEY, SALT, and KEY. The
- * final result will be added to the first context.
- */
-
- /* Add key. */
-- gaim_cipher_context_append(context2, (const guchar *)key, key_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)key, key_len);
-
- /* Add salt. */
-- gaim_cipher_context_append(context2, (const guchar *)salt, salt_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)salt, salt_len);
-
- /* Add key again. */
-- gaim_cipher_context_append(context2, (const guchar *)key, key_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)key, key_len);
-
- /* Now get result of this (16 bytes) and add it to the other context. */
-- gaim_cipher_context_digest(context2, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_digest(context2, sizeof(digest), digest, NULL);
-
- /* Add for any character in the key one byte of the alternate sum. */
- for (cnt = key_len; cnt > 16; cnt -= 16)
-- gaim_cipher_context_append(context1, digest, 16);
-- gaim_cipher_context_append(context1, digest, cnt);
-+ gaim2_cipher_context_append(context1, digest, 16);
-+ gaim2_cipher_context_append(context1, digest, cnt);
-
- /* For the following code we need a NUL byte. */
- digest[0] = '\0';
-@@ -118,11 +118,11 @@ char *yahoo_crypt(const char *key, const
- * what was intended but we have to follow this to be compatible.
- */
- for (cnt = key_len; cnt > 0; cnt >>= 1)
-- gaim_cipher_context_append(context1,
-+ gaim2_cipher_context_append(context1,
- (cnt & 1) != 0 ? digest : (guchar *)key, 1);
-
- /* Create intermediate result. */
-- gaim_cipher_context_digest(context1, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_digest(context1, sizeof(digest), digest, NULL);
-
- /* Now comes another weirdness. In fear of password crackers here
- * comes a quite long loop which just processes the output of the
-@@ -130,30 +130,30 @@ char *yahoo_crypt(const char *key, const
- */
- for (cnt = 0; cnt < 1000; ++cnt) {
- /* New context. */
-- gaim_cipher_context_reset(context2, NULL);
-+ gaim2_cipher_context_reset(context2, NULL);
-
- /* Add key or last result. */
- if ((cnt & 1) != 0)
-- gaim_cipher_context_append(context2, (const guchar *)key, key_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)key, key_len);
- else
-- gaim_cipher_context_append(context2, digest, 16);
-+ gaim2_cipher_context_append(context2, digest, 16);
-
- /* Add salt for numbers not divisible by 3. */
- if (cnt % 3 != 0)
-- gaim_cipher_context_append(context2, (const guchar *)salt, salt_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)salt, salt_len);
-
- /* Add key for numbers not divisible by 7. */
- if (cnt % 7 != 0)
-- gaim_cipher_context_append(context2, (const guchar *)key, key_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)key, key_len);
-
- /* Add key or last result. */
- if ((cnt & 1) != 0)
-- gaim_cipher_context_append(context2, digest, 16);
-+ gaim2_cipher_context_append(context2, digest, 16);
- else
-- gaim_cipher_context_append(context2, (const guchar *)key, key_len);
-+ gaim2_cipher_context_append(context2, (const guchar *)key, key_len);
-
- /* Create intermediate result. */
-- gaim_cipher_context_digest(context2, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_digest(context2, sizeof(digest), digest, NULL);
- }
-
- /* Now we can construct the result string. It consists of three parts. */
-@@ -198,10 +198,10 @@ char *yahoo_crypt(const char *key, const
- * information. We do it in this way to clear correct_words[]
- * inside the MD5 implementation as well.
- */
-- gaim_cipher_context_reset(context1, NULL);
-- gaim_cipher_context_digest(context1, sizeof(digest), digest, NULL);
-- gaim_cipher_context_destroy(context1);
-- gaim_cipher_context_destroy(context2);
-+ gaim2_cipher_context_reset(context1, NULL);
-+ gaim2_cipher_context_digest(context1, sizeof(digest), digest, NULL);
-+ gaim2_cipher_context_destroy(context1);
-+ gaim2_cipher_context_destroy(context2);
-
- return buffer;
- }
-diff -prNu ./src/protocols/yahoo/yahoo_crypt.h ./src/protocols/yahoo/yahoo_crypt.h
---- ./src/protocols/yahoo/yahoo_crypt.h 2005-12-08 22:06:51.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_crypt.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/yahoo/yahoo_doodle.c ./src/protocols/yahoo/yahoo_doodle.c
---- ./src/protocols/yahoo/yahoo_doodle.c 2005-11-09 05:42:42.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_doodle.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -76,47 +76,47 @@ const int DefaultColorRGB24[] =
- /******************************************************************************
- * Functions
- *****************************************************************************/
--GaimCmdRet yahoo_doodle_gaim_cmd_start(GaimConversation *conv, const char *cmd, char **args, char **error, void *data)
-+Gaim2CmdRet yahoo_doodle_gaim2_cmd_start(Gaim2Conversation *conv, const char *cmd, char **args, char **error, void *data)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
- const gchar *name;
-
- if(*args && args[0])
- return GAIM_CMD_RET_FAILED;
-
-- account = gaim_conversation_get_account(conv);
-- gc = gaim_account_get_connection(account);
-- name = gaim_conversation_get_name(conv);
-+ account = gaim2_conversation_get_account(conv);
-+ gc = gaim2_account_get_connection(account);
-+ name = gaim2_conversation_get_name(conv);
- yahoo_doodle_initiate(gc, name);
-
- /* Write a local message to this conversation showing that a request for a
- * Doodle session has been made
- */
-- gaim_conv_im_write(GAIM_CONV_IM(conv), "", _("Sent Doodle request."),
-+ gaim2_conv_im_write(GAIM_CONV_IM(conv), "", _("Sent Doodle request."),
- GAIM_MESSAGE_NICK | GAIM_MESSAGE_RECV, time(NULL));
-
- return GAIM_CMD_RET_OK;
- }
-
--void yahoo_doodle_initiate(GaimConnection *gc, const char *name)
-+void yahoo_doodle_initiate(Gaim2Connection *gc, const char *name)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *to = (char*)name;
-- GaimWhiteboard *wb;
-+ Gaim2Whiteboard *wb;
-
- g_return_if_fail(gc);
- g_return_if_fail(name);
-
-- account = gaim_connection_get_account(gc);
-- wb = gaim_whiteboard_get_session(account, to);
-+ account = gaim2_connection_get_account(gc);
-+ wb = gaim2_whiteboard_get_session(account, to);
-
- if(wb == NULL)
- {
- /* Insert this 'session' in the list. At this point, it's only a
- * requested session.
- */
-- wb = gaim_whiteboard_create(account, to, DOODLE_STATE_REQUESTING);
-+ wb = gaim2_whiteboard_create(account, to, DOODLE_STATE_REQUESTING);
- }
-
- /* NOTE Perhaps some careful handling of remote assumed established
-@@ -128,7 +128,7 @@ void yahoo_doodle_initiate(GaimConnectio
-
- }
-
--void yahoo_doodle_process(GaimConnection *gc, const char *me, const char *from,
-+void yahoo_doodle_process(Gaim2Connection *gc, const char *me, const char *from,
- const char *command, const char *message)
- {
- if(!command)
-@@ -163,19 +163,19 @@ void yahoo_doodle_process(GaimConnection
- }
- }
-
--void yahoo_doodle_command_got_request(GaimConnection *gc, const char *from)
-+void yahoo_doodle_command_got_request(Gaim2Connection *gc, const char *from)
- {
-- GaimAccount *account;
-- GaimWhiteboard *wb;
-+ Gaim2Account *account;
-+ Gaim2Whiteboard *wb;
-
-- gaim_debug_info("yahoo", "doodle: Got Request (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Got Request (%s)\n", from);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- wb = gaim_whiteboard_get_session(account, from);
-+ wb = gaim2_whiteboard_get_session(account, from);
-
- /* If a session with the remote user doesn't exist */
- if(wb == NULL)
-@@ -189,11 +189,11 @@ void yahoo_doodle_command_got_request(Ga
- /* char dialog_message[64];
- g_sprintf(dialog_message, "%s is requesting to start a Doodle session with you.", from);
-
-- gaim_notify_message(NULL, GAIM_NOTIFY_MSG_INFO, "Doodle",
-+ gaim2_notify_message(NULL, GAIM_NOTIFY_MSG_INFO, "Doodle",
- dialog_message, NULL, NULL, NULL);
- */
-
-- wb = gaim_whiteboard_create(account, from, DOODLE_STATE_REQUESTED);
-+ wb = gaim2_whiteboard_create(account, from, DOODLE_STATE_REQUESTED);
-
- yahoo_doodle_command_send_request(gc, from);
- }
-@@ -203,26 +203,26 @@ void yahoo_doodle_command_got_request(Ga
- */
- }
-
--void yahoo_doodle_command_got_ready(GaimConnection *gc, const char *from)
-+void yahoo_doodle_command_got_ready(Gaim2Connection *gc, const char *from)
- {
-- GaimAccount *account;
-- GaimWhiteboard *wb;
-+ Gaim2Account *account;
-+ Gaim2Whiteboard *wb;
-
-- gaim_debug_info("yahoo", "doodle: Got Ready (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Got Ready (%s)\n", from);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- wb = gaim_whiteboard_get_session(account, from);
-+ wb = gaim2_whiteboard_get_session(account, from);
-
- if(wb == NULL)
- return;
-
- if(wb->state == DOODLE_STATE_REQUESTING)
- {
-- gaim_whiteboard_start(wb);
-+ gaim2_whiteboard_start(wb);
-
- wb->state = DOODLE_STATE_ESTABLISHED;
-
-@@ -232,7 +232,7 @@ void yahoo_doodle_command_got_ready(Gaim
- if(wb->state == DOODLE_STATE_ESTABLISHED)
- {
- /* TODO Ask whether to save picture too */
-- gaim_whiteboard_clear(wb);
-+ gaim2_whiteboard_clear(wb);
- }
-
- /* NOTE Not sure about this... I am trying to handle if the remote user
-@@ -241,28 +241,28 @@ void yahoo_doodle_command_got_ready(Gaim
- */
- if(wb->state == DOODLE_STATE_REQUESTED)
- {
-- /* gaim_whiteboard_start(wb); */
-+ /* gaim2_whiteboard_start(wb); */
- yahoo_doodle_command_send_request(gc, from);
- }
- }
-
--void yahoo_doodle_command_got_draw(GaimConnection *gc, const char *from, const char *message)
-+void yahoo_doodle_command_got_draw(Gaim2Connection *gc, const char *from, const char *message)
- {
-- GaimAccount *account;
-- GaimWhiteboard *wb;
-+ Gaim2Account *account;
-+ Gaim2Whiteboard *wb;
- char **tokens;
- int i;
- GList *d_list = NULL; /* a local list of drawing info */
-
-- gaim_debug_info("yahoo", "doodle: Got Draw (%s)\n", from);
-- gaim_debug_info("yahoo", "doodle: Draw message: %s\n", message);
-+ gaim2_debug_info("yahoo", "doodle: Got Draw (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Draw message: %s\n", message);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- wb = gaim_whiteboard_get_session(account, from);
-+ wb = gaim2_whiteboard_get_session(account, from);
-
- if(wb == NULL)
- return;
-@@ -300,19 +300,19 @@ void yahoo_doodle_command_got_draw(GaimC
- g_list_free(d_list);
- }
-
--void yahoo_doodle_command_got_clear(GaimConnection *gc, const char *from)
-+void yahoo_doodle_command_got_clear(Gaim2Connection *gc, const char *from)
- {
-- GaimAccount *account;
-- GaimWhiteboard *wb;
-+ Gaim2Account *account;
-+ Gaim2Whiteboard *wb;
-
-- gaim_debug_info("yahoo", "doodle: Got Clear (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Got Clear (%s)\n", from);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- wb = gaim_whiteboard_get_session(account, from);
-+ wb = gaim2_whiteboard_get_session(account, from);
-
- if(wb == NULL)
- return;
-@@ -321,14 +321,14 @@ void yahoo_doodle_command_got_clear(Gaim
- {
- /* TODO Ask user whether to save the image before clearing it */
-
-- gaim_whiteboard_clear(wb);
-+ gaim2_whiteboard_clear(wb);
- }
- }
-
- void
--yahoo_doodle_command_got_extra(GaimConnection *gc, const char *from, const char *message)
-+yahoo_doodle_command_got_extra(Gaim2Connection *gc, const char *from, const char *message)
- {
-- gaim_debug_info("yahoo", "doodle: Got Extra (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Got Extra (%s)\n", from);
-
- /* I do not like these 'extra' features, so I'll only handle them in one
- * way, which is returning them with the command/packet to turn them off
-@@ -336,20 +336,20 @@ yahoo_doodle_command_got_extra(GaimConne
- yahoo_doodle_command_send_extra(gc, from, DOODLE_EXTRA_NONE);
- }
-
--void yahoo_doodle_command_got_confirm(GaimConnection *gc, const char *from)
-+void yahoo_doodle_command_got_confirm(Gaim2Connection *gc, const char *from)
- {
-- GaimAccount *account;
-- GaimWhiteboard *wb;
-+ Gaim2Account *account;
-+ Gaim2Whiteboard *wb;
-
-- gaim_debug_info("yahoo", "doodle: Got Confirm (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Got Confirm (%s)\n", from);
-
- /* Get the doodle session */
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- wb = gaim_whiteboard_get_session(account, from);
-+ wb = gaim2_whiteboard_get_session(account, from);
-
- if(wb == NULL)
- return;
-@@ -361,7 +361,7 @@ void yahoo_doodle_command_got_confirm(Ga
- {
- wb->state = DOODLE_STATE_ESTABLISHED;
-
-- gaim_whiteboard_start(wb);
-+ gaim2_whiteboard_start(wb);
-
- yahoo_doodle_command_send_confirm(gc, from);
- }
-@@ -371,23 +371,23 @@ void yahoo_doodle_command_got_confirm(Ga
- {
- wb->state = DOODLE_STATE_ESTABLISHED;
-
-- gaim_whiteboard_start(wb);
-+ gaim2_whiteboard_start(wb);
- }
- }
-
--void yahoo_doodle_command_got_shutdown(GaimConnection *gc, const char *from)
-+void yahoo_doodle_command_got_shutdown(Gaim2Connection *gc, const char *from)
- {
-- GaimAccount *account;
-- GaimWhiteboard *wb;
-+ Gaim2Account *account;
-+ Gaim2Whiteboard *wb;
-
-- gaim_debug_info("yahoo", "doodle: Got Shutdown (%s)\n", from);
-+ gaim2_debug_info("yahoo", "doodle: Got Shutdown (%s)\n", from);
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
- /* Only handle this if local client requested Doodle session (else local
- * client would have sent one)
- */
-- wb = gaim_whiteboard_get_session(account, from);
-+ wb = gaim2_whiteboard_get_session(account, from);
-
- /* TODO Ask if user wants to save picture before the session is closed */
-
-@@ -396,14 +396,14 @@ void yahoo_doodle_command_got_shutdown(G
- return;
- else
- {
-- gaim_whiteboard_destroy(wb);
-+ gaim2_whiteboard_destroy(wb);
-
- /* yahoo_doodle_command_send_shutdown(gc, from); */
- }
- }
-
- static void yahoo_doodle_command_send_generic(const char *type,
-- GaimConnection *gc,
-+ Gaim2Connection *gc,
- const char *to,
- const char *message,
- const char *thirteen,
-@@ -413,14 +413,14 @@ static void yahoo_doodle_command_send_ge
- struct yahoo_data *yd;
- struct yahoo_packet *pkt;
-
-- gaim_debug_info("yahoo", "doodle: Sent %s (%s)\n", type, to);
-+ gaim2_debug_info("yahoo", "doodle: Sent %s (%s)\n", type, to);
-
- yd = gc->proto_data;
-
- /* Make and send an acknowledge (ready) Doodle packet */
- pkt = yahoo_packet_new(YAHOO_SERVICE_P2PFILEXFER, YAHOO_STATUS_AVAILABLE, 0);
- yahoo_packet_hash_str(pkt, 49, "IMVIRONMENT");
-- yahoo_packet_hash_str(pkt, 1, gaim_account_get_username(gc->account));
-+ yahoo_packet_hash_str(pkt, 1, gaim2_account_get_username(gc->account));
- yahoo_packet_hash_str(pkt, 14, message);
- yahoo_packet_hash_str(pkt, 13, thirteen);
- yahoo_packet_hash_str(pkt, 5, to);
-@@ -431,46 +431,46 @@ static void yahoo_doodle_command_send_ge
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--void yahoo_doodle_command_send_request(GaimConnection *gc, const char *to)
-+void yahoo_doodle_command_send_request(Gaim2Connection *gc, const char *to)
- {
- yahoo_doodle_command_send_generic("Request", gc, to, "1", "1", NULL, "1");
- }
-
--void yahoo_doodle_command_send_ready(GaimConnection *gc, const char *to)
-+void yahoo_doodle_command_send_ready(Gaim2Connection *gc, const char *to)
- {
- yahoo_doodle_command_send_generic("Ready", gc, to, "", "0", NULL, "0");
- }
-
--void yahoo_doodle_command_send_draw(GaimConnection *gc, const char *to, const char *message)
-+void yahoo_doodle_command_send_draw(Gaim2Connection *gc, const char *to, const char *message)
- {
- yahoo_doodle_command_send_generic("Draw", gc, to, message, "3", NULL, "1");
- }
-
--void yahoo_doodle_command_send_clear(GaimConnection *gc, const char *to)
-+void yahoo_doodle_command_send_clear(Gaim2Connection *gc, const char *to)
- {
- yahoo_doodle_command_send_generic("Clear", gc, to, " ", "2", NULL, "1");
- }
-
--void yahoo_doodle_command_send_extra(GaimConnection *gc, const char *to, const char *message)
-+void yahoo_doodle_command_send_extra(Gaim2Connection *gc, const char *to, const char *message)
- {
- yahoo_doodle_command_send_generic("Extra", gc, to, message, "4", NULL, "1");
- }
-
--void yahoo_doodle_command_send_confirm(GaimConnection *gc, const char *to)
-+void yahoo_doodle_command_send_confirm(Gaim2Connection *gc, const char *to)
- {
- yahoo_doodle_command_send_generic("Confirm", gc, to, "1", "5", NULL, "1");
- }
-
--void yahoo_doodle_command_send_shutdown(GaimConnection *gc, const char *to)
-+void yahoo_doodle_command_send_shutdown(Gaim2Connection *gc, const char *to)
- {
- yahoo_doodle_command_send_generic("Shutdown", gc, to, "", "0", ";0", "0");
- }
-
--void yahoo_doodle_start(GaimWhiteboard *wb)
-+void yahoo_doodle_start(Gaim2Whiteboard *wb)
- {
- doodle_session *ds = g_new0(doodle_session, 1);
-
-- /* gaim_debug_debug("yahoo", "doodle: yahoo_doodle_start()\n"); */
-+ /* gaim2_debug_debug("yahoo", "doodle: yahoo_doodle_start()\n"); */
-
- /* Set default brush size and color */
- ds->brush_size = DOODLE_BRUSH_SMALL;
-@@ -479,9 +479,9 @@ void yahoo_doodle_start(GaimWhiteboard *
- wb->proto_data = ds;
- }
-
--void yahoo_doodle_end(GaimWhiteboard *wb)
-+void yahoo_doodle_end(Gaim2Whiteboard *wb)
- {
-- GaimConnection *gc = gaim_account_get_connection(wb->account);
-+ Gaim2Connection *gc = gaim2_account_get_connection(wb->account);
-
- /* g_debug_debug("yahoo", "doodle: yahoo_doodle_end()\n"); */
-
-@@ -490,7 +490,7 @@ void yahoo_doodle_end(GaimWhiteboard *wb
- g_free(wb->proto_data);
- }
-
--void yahoo_doodle_get_dimensions(GaimWhiteboard *wb, int *width, int *height)
-+void yahoo_doodle_get_dimensions(Gaim2Whiteboard *wb, int *width, int *height)
- {
- /* standard Doodle canvases are of one size: 368x256 */
- *width = DOODLE_CANVAS_WIDTH;
-@@ -515,7 +515,7 @@ static char *yahoo_doodle_build_draw_str
- return g_string_free(message, FALSE);
- }
-
--void yahoo_doodle_send_draw_list(GaimWhiteboard *wb, GList *draw_list)
-+void yahoo_doodle_send_draw_list(Gaim2Whiteboard *wb, GList *draw_list)
- {
- doodle_session *ds = wb->proto_data;
- char *message;
-@@ -527,14 +527,14 @@ void yahoo_doodle_send_draw_list(GaimWhi
- g_free(message);
- }
-
--void yahoo_doodle_clear(GaimWhiteboard *wb)
-+void yahoo_doodle_clear(Gaim2Whiteboard *wb)
- {
- yahoo_doodle_command_send_clear(wb->account->gc, wb->who);
- }
-
-
- /* Traverse through the list and draw the points and lines */
--void yahoo_doodle_draw_stroke(GaimWhiteboard *wb, GList *draw_list)
-+void yahoo_doodle_draw_stroke(Gaim2Whiteboard *wb, GList *draw_list)
- {
- int brush_color;
- int brush_size;
-@@ -560,7 +560,7 @@ void yahoo_doodle_draw_stroke(GaimWhiteb
- g_return_if_fail(draw_list != NULL);
-
- /*
-- gaim_debug_debug("yahoo", "doodle: Drawing: color=%d, size=%d, (%d,%d)\n", brush_color, brush_size, x, y);
-+ gaim2_debug_debug("yahoo", "doodle: Drawing: color=%d, size=%d, (%d,%d)\n", brush_color, brush_size, x, y);
- */
-
- while(draw_list != NULL && draw_list->next != NULL)
-@@ -568,7 +568,7 @@ void yahoo_doodle_draw_stroke(GaimWhiteb
- int dx = GPOINTER_TO_INT(draw_list->data);
- int dy = GPOINTER_TO_INT(draw_list->next->data);
-
-- gaim_whiteboard_draw_line(wb,
-+ gaim2_whiteboard_draw_line(wb,
- x, y,
- x + dx, y + dy,
- brush_color, brush_size);
-@@ -580,20 +580,20 @@ void yahoo_doodle_draw_stroke(GaimWhiteb
- }
- }
-
--void yahoo_doodle_get_brush(GaimWhiteboard *wb, int *size, int *color)
-+void yahoo_doodle_get_brush(Gaim2Whiteboard *wb, int *size, int *color)
- {
- doodle_session *ds = (doodle_session *)wb->proto_data;
- *size = ds->brush_size;
- *color = ds->brush_color;
- }
-
--void yahoo_doodle_set_brush(GaimWhiteboard *wb, int size, int color)
-+void yahoo_doodle_set_brush(Gaim2Whiteboard *wb, int size, int color)
- {
- doodle_session *ds = (doodle_session *)wb->proto_data;
- ds->brush_size = size;
- ds->brush_color = color;
-
- /* Notify the core about the changes */
-- gaim_whiteboard_set_brush(wb, size, color);
-+ gaim2_whiteboard_set_brush(wb, size, color);
- }
-
-diff -prNu ./src/protocols/yahoo/yahoo_doodle.h ./src/protocols/yahoo/yahoo_doodle.h
---- ./src/protocols/yahoo/yahoo_doodle.h 2005-10-31 03:19:51.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_doodle.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file yahoo_doodle.h The Yahoo! protocol plugin Doodle IMVironment object
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -97,37 +97,37 @@ typedef struct _doodle_session
- * API
- *****************************************************************************/
-
--GaimCmdRet yahoo_doodle_gaim_cmd_start(GaimConversation *conv, const char *cmd, char **args,
-+Gaim2CmdRet yahoo_doodle_gaim2_cmd_start(Gaim2Conversation *conv, const char *cmd, char **args,
- char **error, void *data);
-
--void yahoo_doodle_process(GaimConnection *gc, const char *me, const char *from,
-+void yahoo_doodle_process(Gaim2Connection *gc, const char *me, const char *from,
- const char *command, const char *message);
--void yahoo_doodle_initiate(GaimConnection *gc, const char *to);
-+void yahoo_doodle_initiate(Gaim2Connection *gc, const char *to);
-
--void yahoo_doodle_command_got_request(GaimConnection *gc, const char *from);
--void yahoo_doodle_command_got_ready(GaimConnection *gc, const char *from);
--void yahoo_doodle_command_got_draw(GaimConnection *gc, const char *from, const char *message);
--void yahoo_doodle_command_got_clear(GaimConnection *gc, const char *from);
--void yahoo_doodle_command_got_extra(GaimConnection *gc, const char *from, const char *message);
--void yahoo_doodle_command_got_confirm(GaimConnection *gc, const char *from);
--void yahoo_doodle_command_got_shutdown(GaimConnection *gc, const char *from);
--
--void yahoo_doodle_command_send_request(GaimConnection *gc, const char *to);
--void yahoo_doodle_command_send_ready(GaimConnection *gc, const char *to);
--void yahoo_doodle_command_send_draw(GaimConnection *gc, const char *to, const char *message);
--void yahoo_doodle_command_send_clear(GaimConnection *gc, const char *to);
--void yahoo_doodle_command_send_extra(GaimConnection *gc, const char *to, const char *message);
--void yahoo_doodle_command_send_confirm(GaimConnection *gc, const char *to);
--void yahoo_doodle_command_send_shutdown(GaimConnection *gc, const char *to);
--
--void yahoo_doodle_start(GaimWhiteboard *wb);
--void yahoo_doodle_end(GaimWhiteboard *wb);
--void yahoo_doodle_get_dimensions(GaimWhiteboard *wb, int *width, int *height);
--void yahoo_doodle_send_draw_list(GaimWhiteboard *wb, GList *draw_list);
--void yahoo_doodle_clear(GaimWhiteboard *wb);
--
--void yahoo_doodle_draw_stroke(GaimWhiteboard *wb, GList *draw_list);
--void yahoo_doodle_get_brush(GaimWhiteboard *wb, int *size, int *color);
--void yahoo_doodle_set_brush(GaimWhiteboard *wb, int size, int color);
-+void yahoo_doodle_command_got_request(Gaim2Connection *gc, const char *from);
-+void yahoo_doodle_command_got_ready(Gaim2Connection *gc, const char *from);
-+void yahoo_doodle_command_got_draw(Gaim2Connection *gc, const char *from, const char *message);
-+void yahoo_doodle_command_got_clear(Gaim2Connection *gc, const char *from);
-+void yahoo_doodle_command_got_extra(Gaim2Connection *gc, const char *from, const char *message);
-+void yahoo_doodle_command_got_confirm(Gaim2Connection *gc, const char *from);
-+void yahoo_doodle_command_got_shutdown(Gaim2Connection *gc, const char *from);
-+
-+void yahoo_doodle_command_send_request(Gaim2Connection *gc, const char *to);
-+void yahoo_doodle_command_send_ready(Gaim2Connection *gc, const char *to);
-+void yahoo_doodle_command_send_draw(Gaim2Connection *gc, const char *to, const char *message);
-+void yahoo_doodle_command_send_clear(Gaim2Connection *gc, const char *to);
-+void yahoo_doodle_command_send_extra(Gaim2Connection *gc, const char *to, const char *message);
-+void yahoo_doodle_command_send_confirm(Gaim2Connection *gc, const char *to);
-+void yahoo_doodle_command_send_shutdown(Gaim2Connection *gc, const char *to);
-+
-+void yahoo_doodle_start(Gaim2Whiteboard *wb);
-+void yahoo_doodle_end(Gaim2Whiteboard *wb);
-+void yahoo_doodle_get_dimensions(Gaim2Whiteboard *wb, int *width, int *height);
-+void yahoo_doodle_send_draw_list(Gaim2Whiteboard *wb, GList *draw_list);
-+void yahoo_doodle_clear(Gaim2Whiteboard *wb);
-+
-+void yahoo_doodle_draw_stroke(Gaim2Whiteboard *wb, GList *draw_list);
-+void yahoo_doodle_get_brush(Gaim2Whiteboard *wb, int *size, int *color);
-+void yahoo_doodle_set_brush(Gaim2Whiteboard *wb, int size, int color);
-
- #endif /* _YAHOO_DOODLE_H_ */
-diff -prNu ./src/protocols/yahoo/yahoo_filexfer.c ./src/protocols/yahoo/yahoo_filexfer.c
---- ./src/protocols/yahoo/yahoo_filexfer.c 2005-12-08 22:00:39.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_filexfer.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
- * @file yahoo_filexfer.c Yahoo Filetransfer
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -36,7 +36,7 @@ struct yahoo_xfer_data {
- gchar *host;
- gchar *path;
- int port;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- long expires;
- gboolean started;
- gchar *rxqueue;
-@@ -52,27 +52,27 @@ static void yahoo_xfer_data_free(struct
- g_free(xd);
- }
-
--static void yahoo_receivefile_connected(gpointer data, gint source, GaimInputCondition condition)
-+static void yahoo_receivefile_connected(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct yahoo_xfer_data *xd;
- gchar *buf;
-
-- gaim_debug(GAIM_DEBUG_INFO, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_INFO, "yahoo",
- "AAA - in yahoo_receivefile_connected\n");
- if (!(xfer = data))
- return;
- if (!(xd = xfer->data))
- return;
- if (source < 0) {
-- gaim_xfer_error(GAIM_XFER_RECEIVE, gaim_xfer_get_account(xfer),
-+ gaim2_xfer_error(GAIM_XFER_RECEIVE, gaim2_xfer_get_account(xfer),
- xfer->who, _("Unable to connect."));
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
- xfer->fd = source;
-- gaim_xfer_start(xfer, source, NULL, 0);
-+ gaim2_xfer_start(xfer, source, NULL, 0);
-
- buf = g_strdup_printf("GET /%s HTTP/1.0\r\nHost: %s\r\n\r\n",
- xd->path, xd->host);
-@@ -82,20 +82,20 @@ static void yahoo_receivefile_connected(
- return;
- }
-
--static void yahoo_sendfile_connected(gpointer data, gint source, GaimInputCondition condition)
-+static void yahoo_sendfile_connected(gpointer data, gint source, Gaim2InputCondition condition)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct yahoo_xfer_data *xd;
- struct yahoo_packet *pkt;
- gchar *size, *post, *buf;
- const char *host;
- int content_length, port;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- struct yahoo_data *yd;
- char *filename, *encoded_filename;
-
-- gaim_debug(GAIM_DEBUG_INFO, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_INFO, "yahoo",
- "AAA - in yahoo_sendfile_connected\n");
- if (!(xfer = data))
- return;
-@@ -103,40 +103,40 @@ static void yahoo_sendfile_connected(gpo
- return;
-
- gc = xd->gc;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- yd = gc->proto_data;
-
- if (source < 0) {
-- gaim_xfer_error(GAIM_XFER_RECEIVE, gaim_xfer_get_account(xfer),
-+ gaim2_xfer_error(GAIM_XFER_RECEIVE, gaim2_xfer_get_account(xfer),
- xfer->who, _("Unable to connect."));
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- return;
- }
-
- xfer->fd = source;
-- gaim_xfer_start(xfer, source, NULL, 0);
-+ gaim2_xfer_start(xfer, source, NULL, 0);
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_FILETRANSFER, YAHOO_STATUS_AVAILABLE, yd->session_id);
-
-- size = g_strdup_printf("%" G_GSIZE_FORMAT, gaim_xfer_get_size(xfer));
-- filename = g_path_get_basename(gaim_xfer_get_local_filename(xfer));
-+ size = g_strdup_printf("%" G_GSIZE_FORMAT, gaim2_xfer_get_size(xfer));
-+ filename = g_path_get_basename(gaim2_xfer_get_local_filename(xfer));
- encoded_filename = yahoo_string_encode(gc, filename, NULL);
-
-- yahoo_packet_hash(pkt, "sssss", 0, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "sssss", 0, gaim2_connection_get_display_name(gc),
- 5, xfer->who, 14, "", 27, encoded_filename, 28, size);
-
- content_length = YAHOO_PACKET_HDRLEN + yahoo_packet_length(pkt);
-
- buf = g_strdup_printf("Y=%s; T=%s", yd->cookie_y, yd->cookie_t);
-
-- host = gaim_account_get_string(account, "xfer_host", YAHOO_XFER_HOST);
-- port = gaim_account_get_int(account, "xfer_port", YAHOO_XFER_PORT);
-+ host = gaim2_account_get_string(account, "xfer_host", YAHOO_XFER_HOST);
-+ port = gaim2_account_get_int(account, "xfer_port", YAHOO_XFER_PORT);
- post = g_strdup_printf("POST http://%s:%d/notifyft HTTP/1.0\r\n"
- "Content-length: %" G_GSIZE_FORMAT "\r\n"
- "Host: %s:%d\r\n"
- "Cookie: %s\r\n"
- "\r\n",
-- host, port, content_length + 4 + gaim_xfer_get_size(xfer),
-+ host, port, content_length + 4 + gaim2_xfer_get_size(xfer),
- host, port, buf);
- write(xfer->fd, post, strlen(post));
-
-@@ -152,60 +152,60 @@ static void yahoo_sendfile_connected(gpo
- g_free(filename);
- }
-
--static void yahoo_xfer_init(GaimXfer *xfer)
-+static void yahoo_xfer_init(Gaim2Xfer *xfer)
- {
- struct yahoo_xfer_data *xfer_data;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- struct yahoo_data *yd;
-
- xfer_data = xfer->data;
- gc = xfer_data->gc;
- yd = gc->proto_data;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- if (gaim_xfer_get_type(xfer) == GAIM_XFER_SEND) {
-+ if (gaim2_xfer_get_type(xfer) == GAIM_XFER_SEND) {
- if (yd->jp) {
-- if (gaim_proxy_connect(account, gaim_account_get_string(account, "xferjp_host", YAHOOJP_XFER_HOST),
-- gaim_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
-+ if (gaim2_proxy_connect(account, gaim2_account_get_string(account, "xferjp_host", YAHOOJP_XFER_HOST),
-+ gaim2_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
- yahoo_sendfile_connected, xfer) == -1)
- {
-- gaim_notify_error(gc, NULL, _("File Transfer Failed"),
-+ gaim2_notify_error(gc, NULL, _("File Transfer Failed"),
- _("Unable to establish file descriptor."));
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- }
- } else {
-- if (gaim_proxy_connect(account, gaim_account_get_string(account, "xfer_host", YAHOO_XFER_HOST),
-- gaim_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
-+ if (gaim2_proxy_connect(account, gaim2_account_get_string(account, "xfer_host", YAHOO_XFER_HOST),
-+ gaim2_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
- yahoo_sendfile_connected, xfer) == -1)
- {
-- gaim_notify_error(gc, NULL, _("File Transfer Failed"),
-+ gaim2_notify_error(gc, NULL, _("File Transfer Failed"),
- _("Unable to establish file descriptor."));
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- }
- }
- } else {
-- xfer->fd = gaim_proxy_connect(account, xfer_data->host, xfer_data->port,
-+ xfer->fd = gaim2_proxy_connect(account, xfer_data->host, xfer_data->port,
- yahoo_receivefile_connected, xfer);
- if (xfer->fd == -1) {
-- gaim_notify_error(gc, NULL, _("File Transfer Failed"),
-+ gaim2_notify_error(gc, NULL, _("File Transfer Failed"),
- _("Unable to establish file descriptor."));
-- gaim_xfer_cancel_remote(xfer);
-+ gaim2_xfer_cancel_remote(xfer);
- }
- }
- }
-
--static void yahoo_xfer_start(GaimXfer *xfer)
-+static void yahoo_xfer_start(Gaim2Xfer *xfer)
- {
- /* We don't need to do anything here, do we? */
- }
-
--static void yahoo_xfer_end(GaimXfer *xfer)
-+static void yahoo_xfer_end(Gaim2Xfer *xfer)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- struct yahoo_xfer_data *xfer_data;
-
-- account = gaim_xfer_get_account(xfer);
-+ account = gaim2_xfer_get_account(xfer);
- xfer_data = xfer->data;
-
- if (xfer_data)
-@@ -226,7 +226,7 @@ static guint calculate_length(const gcha
- return 0;
- }
-
--static gssize yahoo_xfer_read(guchar **buffer, GaimXfer *xfer)
-+static gssize yahoo_xfer_read(guchar **buffer, Gaim2Xfer *xfer)
- {
- gchar buf[4096];
- gssize len;
-@@ -236,16 +236,16 @@ static gssize yahoo_xfer_read(guchar **b
- int filelen;
- struct yahoo_xfer_data *xd = xfer->data;
-
-- if (gaim_xfer_get_type(xfer) != GAIM_XFER_RECEIVE) {
-+ if (gaim2_xfer_get_type(xfer) != GAIM_XFER_RECEIVE) {
- return 0;
- }
-
- len = read(xfer->fd, buf, sizeof(buf));
-
- if (len <= 0) {
-- if ((gaim_xfer_get_size(xfer) > 0) &&
-- (gaim_xfer_get_bytes_sent(xfer) >= gaim_xfer_get_size(xfer))) {
-- gaim_xfer_set_completed(xfer, TRUE);
-+ if ((gaim2_xfer_get_size(xfer) > 0) &&
-+ (gaim2_xfer_get_bytes_sent(xfer) >= gaim2_xfer_get_size(xfer))) {
-+ gaim2_xfer_set_completed(xfer, TRUE);
- return 0;
- } else
- return -1;
-@@ -267,7 +267,7 @@ static gssize yahoo_xfer_read(guchar **b
- if (!end)
- return 0;
- if ((filelen = calculate_length(length, len - (length - xd->rxqueue))))
-- gaim_xfer_set_size(xfer, filelen);
-+ gaim2_xfer_set_size(xfer, filelen);
- }
- start = g_strstr_len(xd->rxqueue, len, "\r\n\r\n");
- if (start)
-@@ -291,7 +291,7 @@ static gssize yahoo_xfer_read(guchar **b
- return len;
- }
-
--static gssize yahoo_xfer_write(const guchar *buffer, size_t size, GaimXfer *xfer)
-+static gssize yahoo_xfer_write(const guchar *buffer, size_t size, Gaim2Xfer *xfer)
- {
- gssize len;
- struct yahoo_xfer_data *xd = xfer->data;
-@@ -299,45 +299,45 @@ static gssize yahoo_xfer_write(const guc
- if (!xd)
- return -1;
-
-- if (gaim_xfer_get_type(xfer) != GAIM_XFER_SEND) {
-+ if (gaim2_xfer_get_type(xfer) != GAIM_XFER_SEND) {
- return -1;
- }
-
- len = write(xfer->fd, buffer, size);
-
- if (len == -1) {
-- if (gaim_xfer_get_bytes_sent(xfer) >= gaim_xfer_get_size(xfer))
-- gaim_xfer_set_completed(xfer, TRUE);
-+ if (gaim2_xfer_get_bytes_sent(xfer) >= gaim2_xfer_get_size(xfer))
-+ gaim2_xfer_set_completed(xfer, TRUE);
- if ((errno != EAGAIN) && (errno != EINTR))
- return -1;
- return 0;
- }
-
-- if ((gaim_xfer_get_bytes_sent(xfer) + len) >= gaim_xfer_get_size(xfer))
-- gaim_xfer_set_completed(xfer, TRUE);
-+ if ((gaim2_xfer_get_bytes_sent(xfer) + len) >= gaim2_xfer_get_size(xfer))
-+ gaim2_xfer_set_completed(xfer, TRUE);
-
- return len;
- }
-
--static void yahoo_xfer_cancel_send(GaimXfer *xfer)
-+static void yahoo_xfer_cancel_send(Gaim2Xfer *xfer)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- struct yahoo_xfer_data *xfer_data;
-
- xfer_data = xfer->data;
-- account = gaim_xfer_get_account(xfer);
-+ account = gaim2_xfer_get_account(xfer);
-
- if (xfer_data)
- yahoo_xfer_data_free(xfer_data);
- xfer->data = NULL;
- }
-
--static void yahoo_xfer_cancel_recv(GaimXfer *xfer)
-+static void yahoo_xfer_cancel_recv(Gaim2Xfer *xfer)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- struct yahoo_xfer_data *xfer_data;
-
-- account = gaim_xfer_get_account(xfer);
-+ account = gaim2_xfer_get_account(xfer);
- xfer_data = xfer->data;
-
- if (xfer_data)
-@@ -345,7 +345,7 @@ static void yahoo_xfer_cancel_recv(GaimX
- xfer->data = NULL;
- }
-
--void yahoo_process_p2pfilexfer(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_p2pfilexfer(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
-
-@@ -402,14 +402,14 @@ void yahoo_process_p2pfilexfer(GaimConne
- }
- }
-
--void yahoo_process_filetransfer(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_filetransfer(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- char *from = NULL;
- char *to = NULL;
- char *msg = NULL;
- char *url = NULL;
- long expires = 0;
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct yahoo_xfer_data *xfer_data;
- char *service = NULL;
- char *filename = NULL;
-@@ -439,7 +439,7 @@ void yahoo_process_filetransfer(GaimConn
-
- if (pkt->service == YAHOO_SERVICE_P2PFILEXFER) {
- if (service && (strcmp("FILEXFER", service) != 0)) {
-- gaim_debug_misc("yahoo", "unhandled service 0x%02x", pkt->service);
-+ gaim2_debug_misc("yahoo", "unhandled service 0x%02x", pkt->service);
- return;
- }
- }
-@@ -457,22 +457,22 @@ void yahoo_process_filetransfer(GaimConn
- /* Setup the Yahoo-specific file transfer data */
- xfer_data = g_new0(struct yahoo_xfer_data, 1);
- xfer_data->gc = gc;
-- if (!gaim_url_parse(url, &(xfer_data->host), &(xfer_data->port), &(xfer_data->path), NULL, NULL)) {
-+ if (!gaim2_url_parse(url, &(xfer_data->host), &(xfer_data->port), &(xfer_data->path), NULL, NULL)) {
- g_free(xfer_data);
- return;
- }
-
-- gaim_debug_misc("yahoo_filexfer", "Host is %s, port is %d, path is %s, and the full url was %s.\n",
-+ gaim2_debug_misc("yahoo_filexfer", "Host is %s, port is %d, path is %s, and the full url was %s.\n",
- xfer_data->host, xfer_data->port, xfer_data->path, url);
-
- /* Build the file transfer handle. */
-- xfer = gaim_xfer_new(gc->account, GAIM_XFER_RECEIVE, from);
-+ xfer = gaim2_xfer_new(gc->account, GAIM_XFER_RECEIVE, from);
- xfer->data = xfer_data;
-
- /* Set the info about the incoming file. */
- if (filename) {
- char *utf8_filename = yahoo_string_decode(gc, filename, TRUE);
-- gaim_xfer_set_filename(xfer, utf8_filename);
-+ gaim2_xfer_set_filename(xfer, utf8_filename);
- g_free(utf8_filename);
- } else {
- gchar *start, *end;
-@@ -485,30 +485,30 @@ void yahoo_process_filetransfer(GaimConn
- filename = g_strndup(start, end - start);
- utf8_filename = yahoo_string_decode(gc, filename, TRUE);
- g_free(filename);
-- gaim_xfer_set_filename(xfer, utf8_filename);
-+ gaim2_xfer_set_filename(xfer, utf8_filename);
- g_free(utf8_filename);
- filename = NULL;
- }
- }
-
-- gaim_xfer_set_size(xfer, filesize);
-+ gaim2_xfer_set_size(xfer, filesize);
-
- /* Setup our I/O op functions */
-- gaim_xfer_set_init_fnc(xfer, yahoo_xfer_init);
-- gaim_xfer_set_start_fnc(xfer, yahoo_xfer_start);
-- gaim_xfer_set_end_fnc(xfer, yahoo_xfer_end);
-- gaim_xfer_set_cancel_send_fnc(xfer, yahoo_xfer_cancel_send);
-- gaim_xfer_set_cancel_recv_fnc(xfer, yahoo_xfer_cancel_recv);
-- gaim_xfer_set_read_fnc(xfer, yahoo_xfer_read);
-- gaim_xfer_set_write_fnc(xfer, yahoo_xfer_write);
-+ gaim2_xfer_set_init_fnc(xfer, yahoo_xfer_init);
-+ gaim2_xfer_set_start_fnc(xfer, yahoo_xfer_start);
-+ gaim2_xfer_set_end_fnc(xfer, yahoo_xfer_end);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, yahoo_xfer_cancel_send);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, yahoo_xfer_cancel_recv);
-+ gaim2_xfer_set_read_fnc(xfer, yahoo_xfer_read);
-+ gaim2_xfer_set_write_fnc(xfer, yahoo_xfer_write);
-
- /* Now perform the request */
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-
--GaimXfer *yahoo_new_xfer(GaimConnection *gc, const char *who)
-+Gaim2Xfer *yahoo_new_xfer(Gaim2Connection *gc, const char *who)
- {
-- GaimXfer *xfer;
-+ Gaim2Xfer *xfer;
- struct yahoo_xfer_data *xfer_data;
-
- g_return_val_if_fail(who != NULL, NULL);
-@@ -517,30 +517,30 @@ GaimXfer *yahoo_new_xfer(GaimConnection
- xfer_data->gc = gc;
-
- /* Build the file transfer handle. */
-- xfer = gaim_xfer_new(gc->account, GAIM_XFER_SEND, who);
-+ xfer = gaim2_xfer_new(gc->account, GAIM_XFER_SEND, who);
- xfer->data = xfer_data;
-
- /* Setup our I/O op functions */
-- gaim_xfer_set_init_fnc(xfer, yahoo_xfer_init);
-- gaim_xfer_set_start_fnc(xfer, yahoo_xfer_start);
-- gaim_xfer_set_end_fnc(xfer, yahoo_xfer_end);
-- gaim_xfer_set_cancel_send_fnc(xfer, yahoo_xfer_cancel_send);
-- gaim_xfer_set_cancel_recv_fnc(xfer, yahoo_xfer_cancel_recv);
-- gaim_xfer_set_read_fnc(xfer, yahoo_xfer_read);
-- gaim_xfer_set_write_fnc(xfer, yahoo_xfer_write);
-+ gaim2_xfer_set_init_fnc(xfer, yahoo_xfer_init);
-+ gaim2_xfer_set_start_fnc(xfer, yahoo_xfer_start);
-+ gaim2_xfer_set_end_fnc(xfer, yahoo_xfer_end);
-+ gaim2_xfer_set_cancel_send_fnc(xfer, yahoo_xfer_cancel_send);
-+ gaim2_xfer_set_cancel_recv_fnc(xfer, yahoo_xfer_cancel_recv);
-+ gaim2_xfer_set_read_fnc(xfer, yahoo_xfer_read);
-+ gaim2_xfer_set_write_fnc(xfer, yahoo_xfer_write);
-
- return xfer;
- }
-
--void yahoo_send_file(GaimConnection *gc, const char *who, const char *file)
-+void yahoo_send_file(Gaim2Connection *gc, const char *who, const char *file)
- {
-- GaimXfer *xfer = yahoo_new_xfer(gc, who);
-+ Gaim2Xfer *xfer = yahoo_new_xfer(gc, who);
-
- g_return_if_fail(xfer != NULL);
-
- /* Now perform the request */
- if (file)
-- gaim_xfer_request_accepted(xfer, file);
-+ gaim2_xfer_request_accepted(xfer, file);
- else
-- gaim_xfer_request(xfer);
-+ gaim2_xfer_request(xfer);
- }
-diff -prNu ./src/protocols/yahoo/yahoo_filexfer.h ./src/protocols/yahoo/yahoo_filexfer.h
---- ./src/protocols/yahoo/yahoo_filexfer.h 2005-12-08 21:55:27.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_filexfer.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -27,28 +27,28 @@
- /**
- * Process ymsg events, particular IMViroments like Doodle
- */
--void yahoo_process_p2pfilexfer( GaimConnection *gc, struct yahoo_packet *pkt );
-+void yahoo_process_p2pfilexfer( Gaim2Connection *gc, struct yahoo_packet *pkt );
-
- /**
- * Process ymsg file receive invites.
- */
--void yahoo_process_filetransfer(GaimConnection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_filetransfer(Gaim2Connection *gc, struct yahoo_packet *pkt);
-
- /**
-- * Create a new GaimXfer
-+ * Create a new Gaim2Xfer
- *
-- * @param gc The GaimConnection handle.
-+ * @param gc The Gaim2Connection handle.
- * @param who Who will we be sending it to?
- */
--GaimXfer *yahoo_new_xfer(GaimConnection *gc, const char *who);
-+Gaim2Xfer *yahoo_new_xfer(Gaim2Connection *gc, const char *who);
-
- /**
- * Send a file.
- *
-- * @param gc The GaimConnection handle.
-+ * @param gc The Gaim2Connection handle.
- * @param who Who are we sending it to?
- * @param file What file? If NULL, user will choose after this call.
- */
--void yahoo_send_file(GaimConnection *gc, const char *who, const char *file);
-+void yahoo_send_file(Gaim2Connection *gc, const char *who, const char *file);
-
- #endif
-diff -prNu ./src/protocols/yahoo/yahoo_friend.c ./src/protocols/yahoo/yahoo_friend.c
---- ./src/protocols/yahoo/yahoo_friend.c 2005-11-09 00:50:06.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_friend.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -39,7 +39,7 @@ static YahooFriend *yahoo_friend_new(voi
- return ret;
- }
-
--YahooFriend *yahoo_friend_find(GaimConnection *gc, const char *name)
-+YahooFriend *yahoo_friend_find(Gaim2Connection *gc, const char *name)
- {
- struct yahoo_data *yd;
- const char *norm;
-@@ -48,12 +48,12 @@ YahooFriend *yahoo_friend_find(GaimConne
- g_return_val_if_fail(gc->proto_data != NULL, NULL);
-
- yd = gc->proto_data;
-- norm = gaim_normalize(gaim_connection_get_account(gc), name);
-+ norm = gaim2_normalize(gaim2_connection_get_account(gc), name);
-
- return g_hash_table_lookup(yd->friends, norm);
- }
-
--YahooFriend *yahoo_friend_find_or_new(GaimConnection *gc, const char *name)
-+YahooFriend *yahoo_friend_find_or_new(Gaim2Connection *gc, const char *name)
- {
- YahooFriend *f;
- struct yahoo_data *yd;
-@@ -63,7 +63,7 @@ YahooFriend *yahoo_friend_find_or_new(Ga
- g_return_val_if_fail(gc->proto_data != NULL, NULL);
-
- yd = gc->proto_data;
-- norm = gaim_normalize(gaim_connection_get_account(gc), name);
-+ norm = gaim2_normalize(gaim2_connection_get_account(gc), name);
-
- f = g_hash_table_lookup(yd->friends, norm);
- if (!f) {
-@@ -137,7 +137,7 @@ void yahoo_friend_free(gpointer p)
- g_free(f);
- }
-
--void yahoo_process_presence(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_presence(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- YahooFriend *f;
-@@ -160,7 +160,7 @@ void yahoo_process_presence(GaimConnecti
- }
-
- if (value != 1 && value != 2) {
-- gaim_debug_error("yahoo", "Received unknown value for presence key: %d\n", value);
-+ gaim2_debug_error("yahoo", "Received unknown value for presence key: %d\n", value);
- return;
- }
-
-@@ -171,7 +171,7 @@ void yahoo_process_presence(GaimConnecti
- return;
-
- if (pkt->service == YAHOO_SERVICE_PRESENCE_PERM) {
-- gaim_debug_info("yahoo", "Setting permanent presence for %s to %d.\n", who, (value == 1));
-+ gaim2_debug_info("yahoo", "Setting permanent presence for %s to %d.\n", who, (value == 1));
- /* If setting from perm offline to online when in invisible status,
- * this has already been taken care of (when the temp status changed) */
- if (value == 2 && f->presence == YAHOO_PRESENCE_ONLINE) {
-@@ -182,7 +182,7 @@ void yahoo_process_presence(GaimConnecti
- f->presence = YAHOO_PRESENCE_DEFAULT;
- }
- } else {
-- gaim_debug_info("yahoo", "Setting session presence for %s to %d.\n", who, (value == 1));
-+ gaim2_debug_info("yahoo", "Setting session presence for %s to %d.\n", who, (value == 1));
- if (value == 1)
- f->presence = YAHOO_PRESENCE_ONLINE;
- else
-@@ -190,7 +190,7 @@ void yahoo_process_presence(GaimConnecti
- }
- }
-
--void yahoo_friend_update_presence(GaimConnection *gc, const char *name,
-+void yahoo_friend_update_presence(Gaim2Connection *gc, const char *name,
- YahooPresenceVisibility presence)
- {
- struct yahoo_data *yd = gc->proto_data;
-@@ -206,7 +206,7 @@ void yahoo_friend_update_presence(GaimCo
-
- /* No need to change the value if it is already correct */
- if (f->presence == presence) {
-- gaim_debug_info("yahoo", "Not setting presence because there are no changes.\n");
-+ gaim2_debug_info("yahoo", "Not setting presence because there are no changes.\n");
- return;
- }
-
-@@ -215,7 +215,7 @@ void yahoo_friend_update_presence(GaimCo
- YAHOO_STATUS_AVAILABLE, yd->session_id);
-
- yahoo_packet_hash(pkt, "ssss",
-- 1, gaim_connection_get_display_name(gc),
-+ 1, gaim2_connection_get_display_name(gc),
- 31, "1", 13, "2", 7, name);
- } else if (presence == YAHOO_PRESENCE_DEFAULT) {
- if (f->presence == YAHOO_PRESENCE_PERM_OFFLINE) {
-@@ -223,13 +223,13 @@ void yahoo_friend_update_presence(GaimCo
- YAHOO_STATUS_AVAILABLE, yd->session_id);
-
- yahoo_packet_hash(pkt, "ssss",
-- 1, gaim_connection_get_display_name(gc),
-+ 1, gaim2_connection_get_display_name(gc),
- 31, "2", 13, "2", 7, name);
- } else if (yd->current_status == YAHOO_STATUS_INVISIBLE) {
- pkt = yahoo_packet_new(YAHOO_SERVICE_PRESENCE_SESSION,
- YAHOO_STATUS_AVAILABLE, yd->session_id);
- yahoo_packet_hash(pkt, "ssss",
-- 1, gaim_connection_get_display_name(gc),
-+ 1, gaim2_connection_get_display_name(gc),
- 31, "2", 13, "1", 7, name);
- }
- } else if (presence == YAHOO_PRESENCE_ONLINE) {
-@@ -237,7 +237,7 @@ void yahoo_friend_update_presence(GaimCo
- pkt = yahoo_packet_new(YAHOO_SERVICE_PRESENCE_PERM,
- YAHOO_STATUS_AVAILABLE, yd->session_id);
- yahoo_packet_hash(pkt, "ssss",
-- 1, gaim_connection_get_display_name(gc),
-+ 1, gaim2_connection_get_display_name(gc),
- 31, "2", 13, "2", 7, name);
- yahoo_packet_send_and_free(pkt, yd);
- }
-@@ -245,7 +245,7 @@ void yahoo_friend_update_presence(GaimCo
- pkt = yahoo_packet_new(YAHOO_SERVICE_PRESENCE_SESSION,
- YAHOO_STATUS_AVAILABLE, yd->session_id);
- yahoo_packet_hash(pkt, "ssss",
-- 1, gaim_connection_get_display_name(gc),
-+ 1, gaim2_connection_get_display_name(gc),
- 31, "1", 13, "1", 7, name);
- }
-
-diff -prNu ./src/protocols/yahoo/yahoo_friend.h ./src/protocols/yahoo/yahoo_friend.h
---- ./src/protocols/yahoo/yahoo_friend.h 2005-11-09 00:50:06.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_friend.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file yahoo_friend.h The Yahoo! protocol plugin YahooFriend object
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -49,8 +49,8 @@ typedef struct _YahooFriend {
- YahooPresenceVisibility presence;
- } YahooFriend;
-
--YahooFriend *yahoo_friend_find(GaimConnection *gc, const char *name);
--YahooFriend *yahoo_friend_find_or_new(GaimConnection *gc, const char *name);
-+YahooFriend *yahoo_friend_find(Gaim2Connection *gc, const char *name);
-+YahooFriend *yahoo_friend_find_or_new(Gaim2Connection *gc, const char *name);
-
- void yahoo_friend_set_ip(YahooFriend *f, const char *ip);
- const char *yahoo_friend_get_ip(YahooFriend *f);
-@@ -66,8 +66,8 @@ gboolean yahoo_friend_get_buddy_icon_nee
-
- void yahoo_friend_free(gpointer p);
-
--void yahoo_process_presence(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_friend_update_presence(GaimConnection *gc, const char *name,
-+void yahoo_process_presence(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_friend_update_presence(Gaim2Connection *gc, const char *name,
- YahooPresenceVisibility presence);
-
- #endif /* _YAHOO_FRIEND_H_ */
-diff -prNu ./src/protocols/yahoo/yahoo.h ./src/protocols/yahoo/yahoo.h
---- ./src/protocols/yahoo/yahoo.h 2005-12-04 19:19:55.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file yahoo.h The Yahoo! protocol plugin
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -84,7 +84,7 @@ enum yahoo_status {
- };
-
- struct yahoo_buddy_icon_upload_data {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GString *str;
- char *filename;
- int pos;
-@@ -162,7 +162,7 @@ char *yahoo_html_to_codes(const char *sr
- * it is not dereferenced.
- * @return The g_malloced string in the appropriate encoding.
- */
--char *yahoo_string_encode(GaimConnection *gc, const char *str, gboolean *utf8);
-+char *yahoo_string_encode(Gaim2Connection *gc, const char *str, gboolean *utf8);
-
- /**
- * Decode some text received from the server.
-@@ -172,13 +172,13 @@ char *yahoo_string_encode(GaimConnection
- * @param utf8 Did the server tell us it was supposed to be utf8?
- * @return The decoded, utf-8 string, which must be g_free()'d.
- */
--char *yahoo_string_decode(GaimConnection *gc, const char *str, gboolean utf8);
-+char *yahoo_string_decode(Gaim2Connection *gc, const char *str, gboolean utf8);
-
- /* previously-static functions, now needed for yahoo_profile.c */
--char *yahoo_tooltip_text(GaimBuddy *b);
-+char *yahoo_tooltip_text(Gaim2Buddy *b);
-
- /* yahoo_profile.c */
--void yahoo_get_info(GaimConnection *gc, const char *name);
-+void yahoo_get_info(Gaim2Connection *gc, const char *name);
-
- /**
- * Check to see whether the sender is permitted to send
-@@ -187,6 +187,6 @@ void yahoo_get_info(GaimConnection *gc,
- * @param who The sender of the packet to check
- */
- gboolean yahoo_privacy_check
-- (GaimConnection *gc, const char *who);
-+ (Gaim2Connection *gc, const char *who);
-
- #endif /* _YAHOO_H_ */
-diff -prNu ./src/protocols/yahoo/yahoo_packet.c ./src/protocols/yahoo/yahoo_packet.c
---- ./src/protocols/yahoo/yahoo_packet.c 2005-10-12 06:02:46.000000000 +0200
-+++ ./src/protocols/yahoo/yahoo_packet.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -75,7 +75,7 @@ void yahoo_packet_hash(struct yahoo_pack
- yahoo_packet_hash_str(pkt, key, strval);
- break;
- default:
-- gaim_debug_error("yahoo", "Invalid format character '%c'\n", *cur);
-+ gaim2_debug_error("yahoo", "Invalid format character '%c'\n", *cur);
- break;
- }
- }
-@@ -167,7 +167,7 @@ void yahoo_packet_read(struct yahoo_pack
- g_free(value);
- pkt->hash = g_slist_append(pkt->hash, pair);
- esc = g_strescape(pair->value, NULL);
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "Key: %d \tValue: %s\n", pair->key, esc);
- g_free(esc);
- } else {
-@@ -210,35 +210,35 @@ void yahoo_packet_dump(guchar *data, int
- #ifdef YAHOO_DEBUG
- int i;
-
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
-
- for (i = 0; i + 1 < len; i += 2) {
- if ((i % 16 == 0) && i) {
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
- }
-
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "%02x%02x ", data[i], data[i + 1]);
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "%02x%02x ", data[i], data[i + 1]);
- }
- if (i < len)
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "%02x", data[i]);
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "%02x", data[i]);
-
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
-
- for (i = 0; i < len; i++) {
- if ((i % 16 == 0) && i) {
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
- }
-
- if (g_ascii_isprint(data[i]))
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "%c ", data[i]);
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "%c ", data[i]);
- else
-- gaim_debug(GAIM_DEBUG_MISC, NULL, ". ");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, ". ");
- }
-
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
- #endif
- }
-
-@@ -274,7 +274,7 @@ int yahoo_packet_send(struct yahoo_packe
- yahoo_packet_dump(data, len);
- ret = write(yd->fd, data, len);
- if (ret != len)
-- gaim_debug_warning("yahoo", "Only wrote %d of %d bytes!", ret, len);
-+ gaim2_debug_warning("yahoo", "Only wrote %d of %d bytes!", ret, len);
- g_free(data);
-
- return ret;
-diff -prNu ./src/protocols/yahoo/yahoo_packet.h ./src/protocols/yahoo/yahoo_packet.h
---- ./src/protocols/yahoo/yahoo_packet.h 2005-11-09 00:50:06.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_packet.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file yahoo_packet.h The Yahoo! protocol plugin
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/protocols/yahoo/yahoo_picture.c ./src/protocols/yahoo/yahoo_picture.c
---- ./src/protocols/yahoo/yahoo_picture.c 2005-12-08 22:00:39.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_picture.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -38,7 +38,7 @@
-
-
- struct yahoo_fetch_picture_data {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *who;
- int checksum;
- };
-@@ -46,22 +46,22 @@ struct yahoo_fetch_picture_data {
- static void yahoo_fetch_picture_cb(void *user_data, const char *pic_data, size_t len)
- {
- struct yahoo_fetch_picture_data *d = user_data;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
-
- if (GAIM_CONNECTION_IS_VALID(d->gc) && len) {
-- gaim_buddy_icons_set_for_user(gaim_connection_get_account(d->gc), d->who, (void *)pic_data, len);
-- b = gaim_find_buddy(gaim_connection_get_account(d->gc), d->who);
-+ gaim2_buddy_icons_set_for_user(gaim2_connection_get_account(d->gc), d->who, (void *)pic_data, len);
-+ b = gaim2_find_buddy(gaim2_connection_get_account(d->gc), d->who);
- if (b)
-- gaim_blist_node_set_int((GaimBlistNode*)b, YAHOO_ICON_CHECKSUM_KEY, d->checksum);
-+ gaim2_blist_node_set_int((Gaim2BlistNode*)b, YAHOO_ICON_CHECKSUM_KEY, d->checksum);
- } else {
-- gaim_debug_error("yahoo", "Fetching buddy icon failed.\n");
-+ gaim2_debug_error("yahoo", "Fetching buddy icon failed.\n");
- }
-
- g_free(d->who);
- g_free(d);
- }
-
--void yahoo_process_picture(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_picture(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- char *who = NULL, *us = NULL;
-@@ -105,22 +105,22 @@ void yahoo_process_picture(GaimConnectio
- if (who && got_icon_info && url && !strncasecmp(url, "http://", 7)) {
- /* TODO: make this work p2p, try p2p before the url */
- struct yahoo_fetch_picture_data *data;
-- GaimBuddy *b = gaim_find_buddy(gc->account, who);
-- if (b && (checksum == gaim_blist_node_get_int((GaimBlistNode*)b, YAHOO_ICON_CHECKSUM_KEY)))
-+ Gaim2Buddy *b = gaim2_find_buddy(gc->account, who);
-+ if (b && (checksum == gaim2_blist_node_get_int((Gaim2BlistNode*)b, YAHOO_ICON_CHECKSUM_KEY)))
- return;
-
- data = g_new0(struct yahoo_fetch_picture_data, 1);
- data->gc = gc;
- data->who = g_strdup(who);
- data->checksum = checksum;
-- gaim_url_fetch(url, FALSE, "Mozilla/4.0 (compatible; MSIE 5.0)", FALSE,
-+ gaim2_url_fetch(url, FALSE, "Mozilla/4.0 (compatible; MSIE 5.0)", FALSE,
- yahoo_fetch_picture_cb, data);
- } else if (who && send_icon_info) {
- yahoo_send_picture_info(gc, who);
- }
- }
-
--void yahoo_process_picture_update(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_picture_update(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- char *who = NULL;
-@@ -147,19 +147,19 @@ void yahoo_process_picture_update(GaimCo
- if (icon == 2)
- yahoo_send_picture_request(gc, who);
- else if ((icon == 0) || (icon == 1)) {
-- GaimBuddy *b = gaim_find_buddy(gc->account, who);
-+ Gaim2Buddy *b = gaim2_find_buddy(gc->account, who);
- YahooFriend *f;
-- gaim_buddy_icons_set_for_user(gc->account, who, NULL, 0);
-+ gaim2_buddy_icons_set_for_user(gc->account, who, NULL, 0);
- if (b)
-- gaim_blist_node_remove_setting((GaimBlistNode *)b, YAHOO_ICON_CHECKSUM_KEY);
-+ gaim2_blist_node_remove_setting((Gaim2BlistNode *)b, YAHOO_ICON_CHECKSUM_KEY);
- if ((f = yahoo_friend_find(gc, who)))
- yahoo_friend_set_buddy_icon_need_request(f, TRUE);
-- gaim_debug_misc("yahoo", "Setting user %s's icon to NULL.\n", who);
-+ gaim2_debug_misc("yahoo", "Setting user %s's icon to NULL.\n", who);
- }
- }
- }
-
--void yahoo_process_picture_checksum(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_picture_checksum(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
- GSList *l = pkt->hash;
- char *who = NULL;
-@@ -183,15 +183,15 @@ void yahoo_process_picture_checksum(Gaim
- }
-
- if (who) {
-- GaimBuddy *b = gaim_find_buddy(gc->account, who);
-- if (b && (checksum != gaim_blist_node_get_int((GaimBlistNode*)b, YAHOO_ICON_CHECKSUM_KEY)))
-+ Gaim2Buddy *b = gaim2_find_buddy(gc->account, who);
-+ if (b && (checksum != gaim2_blist_node_get_int((Gaim2BlistNode*)b, YAHOO_ICON_CHECKSUM_KEY)))
- yahoo_send_picture_request(gc, who);
- }
- }
-
--void yahoo_process_picture_upload(GaimConnection *gc, struct yahoo_packet *pkt)
-+void yahoo_process_picture_upload(Gaim2Connection *gc, struct yahoo_packet *pkt)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
- GSList *l = pkt->hash;
- char *url = NULL;
-@@ -218,65 +218,65 @@ void yahoo_process_picture_upload(GaimCo
- if (yd->picture_url)
- g_free(yd->picture_url);
- yd->picture_url = g_strdup(url);
-- gaim_account_set_string(account, YAHOO_PICURL_SETTING, url);
-- gaim_account_set_int(account, YAHOO_PICCKSUM_SETTING, yd->picture_checksum);
-+ gaim2_account_set_string(account, YAHOO_PICURL_SETTING, url);
-+ gaim2_account_set_int(account, YAHOO_PICCKSUM_SETTING, yd->picture_checksum);
- yahoo_send_picture_update(gc, 2);
- yahoo_send_picture_checksum(gc);
- }
- }
-
--void yahoo_send_picture_info(GaimConnection *gc, const char *who)
-+void yahoo_send_picture_info(Gaim2Connection *gc, const char *who)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-
- if (!yd->picture_url) {
-- gaim_debug_warning("yahoo", "Attempted to send picture info without a picture\n");
-+ gaim2_debug_warning("yahoo", "Attempted to send picture info without a picture\n");
- return;
- }
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_PICTURE, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "sssssi", 1, gaim_connection_get_display_name(gc),
-- 4, gaim_connection_get_display_name(gc), 5, who,
-+ yahoo_packet_hash(pkt, "sssssi", 1, gaim2_connection_get_display_name(gc),
-+ 4, gaim2_connection_get_display_name(gc), 5, who,
- 13, "2", 20, yd->picture_url, 192, yd->picture_checksum);
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--void yahoo_send_picture_request(GaimConnection *gc, const char *who)
-+void yahoo_send_picture_request(Gaim2Connection *gc, const char *who)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_PICTURE, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash_str(pkt, 4, gaim_connection_get_display_name(gc)); /* me */
-+ yahoo_packet_hash_str(pkt, 4, gaim2_connection_get_display_name(gc)); /* me */
- yahoo_packet_hash_str(pkt, 5, who); /* the other guy */
- yahoo_packet_hash_str(pkt, 13, "1"); /* 1 = request, 2 = reply */
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--void yahoo_send_picture_checksum(GaimConnection *gc)
-+void yahoo_send_picture_checksum(Gaim2Connection *gc)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_PICTURE_CHECKSUM, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "ssi", 1, gaim_connection_get_display_name(gc),
-+ yahoo_packet_hash(pkt, "ssi", 1, gaim2_connection_get_display_name(gc),
- 212, "1", 192, yd->picture_checksum);
- yahoo_packet_send_and_free(pkt, yd);
- }
-
--void yahoo_send_picture_update_to_user(GaimConnection *gc, const char *who, int type)
-+void yahoo_send_picture_update_to_user(Gaim2Connection *gc, const char *who, int type)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yahoo_packet *pkt;
-
- pkt = yahoo_packet_new(YAHOO_SERVICE_PICTURE_UPDATE, YAHOO_STATUS_AVAILABLE, 0);
-- yahoo_packet_hash(pkt, "ssi", 1, gaim_connection_get_display_name(gc), 5, who, 206, type);
-+ yahoo_packet_hash(pkt, "ssi", 1, gaim2_connection_get_display_name(gc), 5, who, 206, type);
- yahoo_packet_send_and_free(pkt, yd);
- }
-
- struct yspufe {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- int type;
- };
-
-@@ -290,7 +290,7 @@ static void yahoo_send_picture_update_fo
- yahoo_send_picture_update_to_user(d->gc, who, d->type);
- }
-
--void yahoo_send_picture_update(GaimConnection *gc, int type)
-+void yahoo_send_picture_update(Gaim2Connection *gc, int type)
- {
- struct yahoo_data *yd = gc->proto_data;
- struct yspufe data;
-@@ -303,24 +303,24 @@ void yahoo_send_picture_update(GaimConne
-
- void yahoo_buddy_icon_upload_data_free(struct yahoo_buddy_icon_upload_data *d)
- {
-- gaim_debug_misc("yahoo", "In yahoo_buddy_icon_upload_data_free()\n");
-+ gaim2_debug_misc("yahoo", "In yahoo_buddy_icon_upload_data_free()\n");
-
- if (d->str)
- g_string_free(d->str, TRUE);
- if (d->filename)
- g_free(d->filename);
- if (d->watcher)
-- gaim_input_remove(d->watcher);
-+ gaim2_input_remove(d->watcher);
- if (d->fd != -1)
- close(d->fd);
- g_free(d);
- }
-
- /* we could care less about the server's responce, but yahoo gets grumpy if we close before it sends it */
--static void yahoo_buddy_icon_upload_reading(gpointer data, gint source, GaimInputCondition condition)
-+static void yahoo_buddy_icon_upload_reading(gpointer data, gint source, Gaim2InputCondition condition)
- {
- struct yahoo_buddy_icon_upload_data *d = data;
-- GaimConnection *gc = d->gc;
-+ Gaim2Connection *gc = d->gc;
- char buf[1024];
-
- if (!GAIM_CONNECTION_IS_VALID(gc)) {
-@@ -332,10 +332,10 @@ static void yahoo_buddy_icon_upload_read
- yahoo_buddy_icon_upload_data_free(d);
- }
-
--static void yahoo_buddy_icon_upload_pending(gpointer data, gint source, GaimInputCondition condition)
-+static void yahoo_buddy_icon_upload_pending(gpointer data, gint source, Gaim2InputCondition condition)
- {
- struct yahoo_buddy_icon_upload_data *d = data;
-- GaimConnection *gc = d->gc;
-+ Gaim2Connection *gc = d->gc;
- ssize_t wrote;
-
- if (!GAIM_CONNECTION_IS_VALID(gc)) {
-@@ -350,47 +350,47 @@ static void yahoo_buddy_icon_upload_pend
- }
- d->pos += wrote;
- if (d->pos >= d->str->len) {
-- gaim_debug_misc("yahoo", "Finished uploading buddy icon.\n");
-- gaim_input_remove(d->watcher);
-- d->watcher = gaim_input_add(d->fd, GAIM_INPUT_READ, yahoo_buddy_icon_upload_reading, d);
-+ gaim2_debug_misc("yahoo", "Finished uploading buddy icon.\n");
-+ gaim2_input_remove(d->watcher);
-+ d->watcher = gaim2_input_add(d->fd, GAIM_INPUT_READ, yahoo_buddy_icon_upload_reading, d);
- }
- }
-
--static void yahoo_buddy_icon_upload_connected(gpointer data, gint source, GaimInputCondition condition)
-+static void yahoo_buddy_icon_upload_connected(gpointer data, gint source, Gaim2InputCondition condition)
- {
- struct yahoo_buddy_icon_upload_data *d = data;
- struct yahoo_packet *pkt;
- gchar *size, *post, *buf;
- const char *host;
- int content_length, port;
-- GaimConnection *gc;
-- GaimAccount *account;
-+ Gaim2Connection *gc;
-+ Gaim2Account *account;
- struct yahoo_data *yd;
-
- if (!d)
- return;
-
- gc = d->gc;
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
- yd = gc->proto_data;
-
- if (source < 0) {
-- gaim_debug_error("yahoo", "Buddy icon upload failed, no file desc.\n");
-+ gaim2_debug_error("yahoo", "Buddy icon upload failed, no file desc.\n");
- yahoo_buddy_icon_upload_data_free(d);
- return;
- }
-
- d->fd = source;
-- d->watcher = gaim_input_add(d->fd, GAIM_INPUT_WRITE, yahoo_buddy_icon_upload_pending, d);
-+ d->watcher = gaim2_input_add(d->fd, GAIM_INPUT_WRITE, yahoo_buddy_icon_upload_pending, d);
-
- pkt = yahoo_packet_new(0xc2, YAHOO_STATUS_AVAILABLE, yd->session_id);
-
- size = g_strdup_printf("%" G_GSIZE_FORMAT, d->str->len);
- /* 1 = me, 38 = expire time(?), 0 = me, 28 = size, 27 = filename, 14 = NULL, 29 = data */
-- yahoo_packet_hash_str(pkt, 1, gaim_connection_get_display_name(gc));
-+ yahoo_packet_hash_str(pkt, 1, gaim2_connection_get_display_name(gc));
- yahoo_packet_hash_str(pkt, 38, "604800"); /* time til expire */
-- gaim_account_set_int(account, YAHOO_PICEXPIRE_SETTING, time(NULL) + 604800);
-- yahoo_packet_hash_str(pkt, 0, gaim_connection_get_display_name(gc));
-+ gaim2_account_set_int(account, YAHOO_PICEXPIRE_SETTING, time(NULL) + 604800);
-+ yahoo_packet_hash_str(pkt, 0, gaim2_connection_get_display_name(gc));
- yahoo_packet_hash_str(pkt, 28, size);
- yahoo_packet_hash_str(pkt, 27, d->filename);
- yahoo_packet_hash_str(pkt, 14, "");
-@@ -398,8 +398,8 @@ static void yahoo_buddy_icon_upload_conn
- content_length = YAHOO_PACKET_HDRLEN + yahoo_packet_length(pkt);
- buf = g_strdup_printf("Y=%s; T=%s", yd->cookie_y, yd->cookie_t);
-
-- host = gaim_account_get_string(account, "xfer_host", YAHOO_XFER_HOST);
-- port = gaim_account_get_int(account, "xfer_port", YAHOO_XFER_PORT);
-+ host = gaim2_account_get_string(account, "xfer_host", YAHOO_XFER_HOST);
-+ port = gaim2_account_get_int(account, "xfer_port", YAHOO_XFER_PORT);
- post = g_strdup_printf("POST http://%s:%d/notifyft HTTP/1.0\r\n"
- "Content-length: %" G_GSIZE_FORMAT "\r\n"
- "Host: %s:%d\r\n"
-@@ -418,34 +418,34 @@ static void yahoo_buddy_icon_upload_conn
- g_free(buf);
- }
-
--void yahoo_buddy_icon_upload(GaimConnection *gc, struct yahoo_buddy_icon_upload_data *d)
-+void yahoo_buddy_icon_upload(Gaim2Connection *gc, struct yahoo_buddy_icon_upload_data *d)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
- struct yahoo_data *yd = gc->proto_data;
-
- if (yd->jp) {
-- if (gaim_proxy_connect(account, gaim_account_get_string(account, "xferjp_host", YAHOOJP_XFER_HOST),
-- gaim_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
-+ if (gaim2_proxy_connect(account, gaim2_account_get_string(account, "xferjp_host", YAHOOJP_XFER_HOST),
-+ gaim2_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
- yahoo_buddy_icon_upload_connected, d) == -1)
- {
-- gaim_debug_error("yahoo", "Uploading our buddy icon failed to connect.\n");
-+ gaim2_debug_error("yahoo", "Uploading our buddy icon failed to connect.\n");
- yahoo_buddy_icon_upload_data_free(d);
- }
- } else {
-- if (gaim_proxy_connect(account, gaim_account_get_string(account, "xfer_host", YAHOO_XFER_HOST),
-- gaim_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
-+ if (gaim2_proxy_connect(account, gaim2_account_get_string(account, "xfer_host", YAHOO_XFER_HOST),
-+ gaim2_account_get_int(account, "xfer_port", YAHOO_XFER_PORT),
- yahoo_buddy_icon_upload_connected, d) == -1)
- {
-- gaim_debug_error("yahoo", "Uploading our buddy icon failed to connect.\n");
-+ gaim2_debug_error("yahoo", "Uploading our buddy icon failed to connect.\n");
- yahoo_buddy_icon_upload_data_free(d);
- }
- }
- }
-
--void yahoo_set_buddy_icon(GaimConnection *gc, const char *iconfile)
-+void yahoo_set_buddy_icon(Gaim2Connection *gc, const char *iconfile)
- {
- struct yahoo_data *yd = gc->proto_data;
-- GaimAccount *account = gc->account;
-+ Gaim2Account *account = gc->account;
- FILE *file;
- struct stat st;
-
-@@ -454,9 +454,9 @@ void yahoo_set_buddy_icon(GaimConnection
- g_free(yd->picture_url);
- yd->picture_url = NULL;
-
-- gaim_account_set_string(account, YAHOO_PICURL_SETTING, NULL);
-- gaim_account_set_int(account, YAHOO_PICCKSUM_SETTING, 0);
-- gaim_account_set_int(account, YAHOO_PICEXPIRE_SETTING, 0);
-+ gaim2_account_set_string(account, YAHOO_PICURL_SETTING, NULL);
-+ gaim2_account_set_int(account, YAHOO_PICCKSUM_SETTING, 0);
-+ gaim2_account_set_int(account, YAHOO_PICEXPIRE_SETTING, 0);
- if (yd->logged_in)
- yahoo_send_picture_update(gc, 0);
- /* TODO: check if we're connected and tell everyone we ain't not one no more */
-@@ -466,9 +466,9 @@ void yahoo_set_buddy_icon(GaimConnection
- GString *s = g_string_sized_new(st.st_size);
- size_t len;
- struct yahoo_buddy_icon_upload_data *d;
-- int oldcksum = gaim_account_get_int(account, YAHOO_PICCKSUM_SETTING, 0);
-- int expire = gaim_account_get_int(account, YAHOO_PICEXPIRE_SETTING, 0);
-- const char *oldurl = gaim_account_get_string(account, YAHOO_PICURL_SETTING, NULL);
-+ int oldcksum = gaim2_account_get_int(account, YAHOO_PICCKSUM_SETTING, 0);
-+ int expire = gaim2_account_get_int(account, YAHOO_PICEXPIRE_SETTING, 0);
-+ const char *oldurl = gaim2_account_get_string(account, YAHOO_PICURL_SETTING, NULL);
-
- g_string_set_size(s, st.st_size);
- len = fread(s->str, 1, st.st_size, file);
-@@ -478,7 +478,7 @@ void yahoo_set_buddy_icon(GaimConnection
-
- if ((yd->picture_checksum == oldcksum) && (expire > (time(NULL) + 60*60*24)) &&
- oldcksum && expire && oldurl) {
-- gaim_debug_misc("yahoo", "buddy icon is up to date. Not reuploading.\n");
-+ gaim2_debug_misc("yahoo", "buddy icon is up to date. Not reuploading.\n");
- g_string_free(s, TRUE);
- if (yd->picture_url)
- g_free(yd->picture_url);
-@@ -499,9 +499,9 @@ void yahoo_set_buddy_icon(GaimConnection
-
- yahoo_buddy_icon_upload(gc, d);
- } else
-- gaim_debug_error("yahoo",
-+ gaim2_debug_error("yahoo",
- "Can't open buddy icon file!\n");
- } else
-- gaim_debug_error("yahoo",
-+ gaim2_debug_error("yahoo",
- "Can't stat buddy icon file!\n");
- }
-diff -prNu ./src/protocols/yahoo/yahoo_picture.h ./src/protocols/yahoo/yahoo_picture.h
---- ./src/protocols/yahoo/yahoo_picture.h 2004-06-19 09:11:53.000000000 +0200
-+++ ./src/protocols/yahoo/yahoo_picture.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,19 +24,19 @@
- #ifndef _YAHOO_PICTURE_H_
- #define _YAHOO_PICTURE_H_
-
--void yahoo_send_picture_request(GaimConnection *gc, const char *who);
--void yahoo_send_picture_info(GaimConnection *gc, const char *who);
--void yahoo_send_picture_checksum(GaimConnection *gc);
--void yahoo_send_picture_update(GaimConnection *gc, int type);
--void yahoo_send_picture_update_to_user(GaimConnection *gc, const char *who, int type);
-+void yahoo_send_picture_request(Gaim2Connection *gc, const char *who);
-+void yahoo_send_picture_info(Gaim2Connection *gc, const char *who);
-+void yahoo_send_picture_checksum(Gaim2Connection *gc);
-+void yahoo_send_picture_update(Gaim2Connection *gc, int type);
-+void yahoo_send_picture_update_to_user(Gaim2Connection *gc, const char *who, int type);
-
--void yahoo_process_picture(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_picture_update(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_picture_checksum(GaimConnection *gc, struct yahoo_packet *pkt);
--void yahoo_process_picture_upload(GaimConnection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_picture(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_picture_update(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_picture_checksum(Gaim2Connection *gc, struct yahoo_packet *pkt);
-+void yahoo_process_picture_upload(Gaim2Connection *gc, struct yahoo_packet *pkt);
-
--void yahoo_set_buddy_icon(GaimConnection *gc, const char *iconfile);
--void yahoo_buddy_icon_upload(GaimConnection *gc, struct yahoo_buddy_icon_upload_data *d);
-+void yahoo_set_buddy_icon(Gaim2Connection *gc, const char *iconfile);
-+void yahoo_buddy_icon_upload(Gaim2Connection *gc, struct yahoo_buddy_icon_upload_data *d);
- void yahoo_buddy_icon_upload_data_free(struct yahoo_buddy_icon_upload_data *d);
-
- #endif /* _YAHOO_PICTURE_H_ */
-diff -prNu ./src/protocols/yahoo/yahoo_profile.c ./src/protocols/yahoo/yahoo_profile.c
---- ./src/protocols/yahoo/yahoo_profile.c 2005-12-23 02:22:29.000000000 +0100
-+++ ./src/protocols/yahoo/yahoo_profile.c 2006-01-05 15:11:06.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,7 +35,7 @@
- #include "yahoo_friend.h"
-
- typedef struct {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char *name;
- } YahooGetInfoData;
-
-@@ -661,10 +661,10 @@ static char *yahoo_remove_nonbreaking_sp
-
- static char *yahoo_tooltip_info_text(YahooGetInfoData *info_data) {
- GString *s = g_string_sized_new(80); /* wild guess */
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- YahooFriend *f;
-
-- b = gaim_find_buddy(gaim_connection_get_account(info_data->gc),
-+ b = gaim2_find_buddy(gaim2_connection_get_account(info_data->gc),
- info_data->name);
-
- if (b) {
-@@ -676,7 +676,7 @@ static char *yahoo_tooltip_info_text(Yah
- }
- #if 0
- if (b->idle > 0) {
-- char *idletime = gaim_str_seconds_to_string(time(NULL) - b->idle);
-+ char *idletime = gaim2_str_seconds_to_string(time(NULL) - b->idle);
- g_string_append_printf(s, _("<b>%s:</b> %s<br>"), _("Idle"),
- idletime);
- g_free(idletime);
-@@ -685,7 +685,7 @@ static char *yahoo_tooltip_info_text(Yah
- if (statustext) {
- char *tmp;
- g_strstrip(statustext);
-- tmp = gaim_strreplace(statustext, "\n", "<br>");
-+ tmp = gaim2_strreplace(statustext, "\n", "<br>");
- g_free(statustext);
- g_string_append_printf(s, "%s<br>", tmp);
- g_free(tmp);
-@@ -766,7 +766,7 @@ static void yahoo_got_info(void *data, c
- return;
- }
-
-- gaim_debug_info("yahoo", "In yahoo_got_info\n");
-+ gaim2_debug_info("yahoo", "In yahoo_got_info\n");
-
- yd = info_data->gc->proto_data;
- title = (yd->jp? _("Yahoo! Japan Profile") :
-@@ -783,7 +783,7 @@ static void yahoo_got_info(void *data, c
- g_snprintf(buf, 1024, "<html><body>%s<b>%s</b></body></html>",
- tooltip_text, _("Error retrieving profile"));
-
-- gaim_notify_userinfo(info_data->gc, info_data->name,
-+ gaim2_notify_userinfo(info_data->gc, info_data->name,
- buf, NULL, NULL);
-
- g_free(profile_url_text);
-@@ -820,7 +820,7 @@ static void yahoo_got_info(void *data, c
- "you will need to visit this link in your web browser"),
- profile_url_text, profile_url_text);
-
-- gaim_notify_userinfo(info_data->gc, info_data->name,
-+ gaim2_notify_userinfo(info_data->gc, info_data->name,
- buf, NULL, NULL);
-
- g_free(profile_url_text);
-@@ -845,7 +845,7 @@ static void yahoo_got_info(void *data, c
- if (profile_strings[strid].lang == profile_langs[lang].lang) break;
- }
- strings = profile_strings + strid;
-- gaim_debug_info("yahoo", "detected profile lang = %s (%d)\n", profile_strings[strid].lang_string, lang);
-+ gaim2_debug_info("yahoo", "detected profile lang = %s (%d)\n", profile_strings[strid].lang_string, lang);
- }
-
- /* Every user may choose his/her own profile language, and this language
-@@ -873,7 +873,7 @@ static void yahoo_got_info(void *data, c
- url_buffer = g_strdup(url_text);
-
- /*
-- * gaim_markup_strip_html() doesn't strip out character entities like &nbsp;
-+ * gaim2_markup_strip_html() doesn't strip out character entities like &nbsp;
- * and &#183;
- */
- yahoo_remove_nonbreaking_spaces(url_buffer);
-@@ -885,7 +885,7 @@ static void yahoo_got_info(void *data, c
- #endif
-
- /* nuke the nasty \r's */
-- gaim_str_strip_char(url_buffer, '\r');
-+ gaim2_str_strip_char(url_buffer, '\r');
-
- #if PHOTO_SUPPORT
- /* Marshall the existing state */
-@@ -905,9 +905,9 @@ static void yahoo_got_info(void *data, c
- if (photo_url_text) {
- /* User-uploaded photos use a different server that requires the Host
- * header, but Yahoo Japan will use the "chunked" content encoding if
-- * we specify HTTP 1.1. So we have to specify 1.0 & fix gaim_url_fetch
-+ * we specify HTTP 1.1. So we have to specify 1.0 & fix gaim2_url_fetch
- */
-- gaim_url_fetch(photo_url_text, FALSE, NULL, FALSE, yahoo_got_photo,
-+ gaim2_url_fetch(photo_url_text, FALSE, NULL, FALSE, yahoo_got_photo,
- info2_data);
- } else {
- /* Emulate a callback */
-@@ -943,15 +943,15 @@ static void yahoo_got_photo(void *data,
-
- /* Jun 29 05 Bleeter: Y! changed their profile pages. Terminators now seem to be */
- /* </dd> and not \n. The prpl's need to be audited before it can be moved */
-- /* in to gaim_markup_strip_html*/
-+ /* in to gaim2_markup_strip_html*/
- char *fudged_buffer;
-- fudged_buffer = gaim_strcasereplace(url_buffer, "</dd>", "</dd><br>");
-+ fudged_buffer = gaim2_strcasereplace(url_buffer, "</dd>", "</dd><br>");
- /* nuke the html, it's easier than trying to parse the horrid stuff */
-- stripped = gaim_markup_strip_html(fudged_buffer);
-+ stripped = gaim2_markup_strip_html(fudged_buffer);
- stripped_len = strlen(stripped);
-
-- gaim_debug_misc("yahoo", "stripped = %p\n", stripped);
-- gaim_debug_misc("yahoo", "url_buffer = %p\n", url_buffer);
-+ gaim2_debug_misc("yahoo", "stripped = %p\n", stripped);
-+ gaim2_debug_misc("yahoo", "url_buffer = %p\n", url_buffer);
-
- /* convert to utf8 */
- if (strings && strings->charset != XX) {
-@@ -966,7 +966,7 @@ static void yahoo_got_photo(void *data,
- }
- if (p) {
- g_free(stripped);
-- stripped = gaim_utf8_ncr_decode(p);
-+ stripped = gaim2_utf8_ncr_decode(p);
- stripped_len = strlen(stripped);
- g_free(p);
- }
-@@ -979,7 +979,7 @@ static void yahoo_got_photo(void *data,
- strings->charset, NULL, NULL, NULL);
- yahoo_remove_nonbreaking_spaces(last_updated_utf8_string);
-
-- gaim_debug_misc("yahoo", "after utf8 conversion: stripped = (%s)\n", stripped);
-+ gaim2_debug_misc("yahoo", "after utf8 conversion: stripped = (%s)\n", stripped);
- }
-
- /* gonna re-use the memory we've already got for url_buffer */
-@@ -990,7 +990,7 @@ static void yahoo_got_photo(void *data,
- #if 0
- /* extract their Yahoo! ID and put it in. Don't bother marking has_info as
- * true, since the Yahoo! ID will always be there */
-- if (!gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ if (!gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->yahoo_id_string, 10, "\n", 0,
- NULL, _("Yahoo! ID"), 0, NULL))
- ;
-@@ -1003,53 +1003,53 @@ static void yahoo_got_photo(void *data,
- || strstr(url_text, "403 Forbidden")
- || strstr(url_text, "404 Not Found")) {
-
-- gaim_debug_info("yahoo", "Error getting %s: %s\n",
-+ gaim2_debug_info("yahoo", "Error getting %s: %s\n",
- photo_url_text, url_text);
- } else {
-- gaim_debug_info("yahoo", "%s is %d bytes\n", photo_url_text, len);
-- id = gaim_imgstore_add(url_text, len, NULL);
-+ gaim2_debug_info("yahoo", "%s is %d bytes\n", photo_url_text, len);
-+ id = gaim2_imgstore_add(url_text, len, NULL);
- g_string_append_printf(s, "<img id=\"%d\"><br>", id);
- }
- }
- #endif /* PHOTO_SUPPORT */
-
- /* extract their Email address and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->my_email_string, 1, " ", 0,
- strings->private_string, _("Email"), 0, NULL);
-
- /* extract the Nickname if it exists */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "Nickname:", 1, "\n", '\n',
- NULL, _("Nickname"), 0, NULL);
-
- /* extract their RealName and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->realname_string, 1, "\n", '\n',
- NULL, _("Realname"), 0, NULL);
-
- /* extract their Location and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->location_string, 2, "\n", '\n',
- NULL, _("Location"), 0, NULL);
-
- /* extract their Age and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->age_string, 3, "\n", '\n',
- NULL, _("Age"), 0, NULL);
-
- /* extract their MaritalStatus and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->maritalstatus_string, 3, "\n", '\n',
- strings->no_answer_string, _("Marital Status"), 0, NULL);
-
- /* extract their Gender and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->gender_string, 3, "\n", '\n',
- strings->no_answer_string, _("Gender"), 0, NULL);
-
- /* extract their Occupation and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->occupation_string, 2, "\n", '\n',
- NULL, _("Occupation"), 0, NULL);
-
-@@ -1062,15 +1062,15 @@ static void yahoo_got_photo(void *data,
- * the "Description" ("Self PR") heading instead of "Links".)
- */
-
-- if (!gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ if (!gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->hobbies_string, 1, strings->latest_news_string,
- '\n', "\n", _("Hobbies"), 0, NULL))
- {
-- if (!gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ if (!gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->hobbies_string, 1, strings->favorite_quote_string,
- '\n', "\n", _("Hobbies"), 0, NULL))
- {
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->hobbies_string, 1, strings->links_string,
- '\n', "\n", _("Hobbies"), 0, NULL);
- }
-@@ -1080,18 +1080,18 @@ static void yahoo_got_photo(void *data,
- else
- found = TRUE;
-
-- if (!gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ if (!gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->latest_news_string, 1, strings->favorite_quote_string,
- '\n', "\n", _("Latest News"), 0, NULL))
- {
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->latest_news_string, 1, strings->links_string,
- '\n', "\n", _("Latest News"), 0, NULL);
- }
- else
- found = TRUE;
-
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->favorite_quote_string, 1, strings->links_string,
- '\n', "\n", _("Favorite Quote"), 0, NULL);
-
-@@ -1105,7 +1105,7 @@ static void yahoo_got_photo(void *data,
- strstr(stripped, strings->no_home_page_specified_string);
- if(!p)
- {
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->home_page_string, 1, "\n", 0, NULL,
- _("Home Page"), 1, NULL);
- }
-@@ -1120,16 +1120,16 @@ static void yahoo_got_photo(void *data,
- strstr(stripped,strings->no_cool_link_specified_string);
- if (!p)
- {
-- if (gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ if (gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->cool_link_1_string, 1, "\n", 0, NULL,
- _("Cool Link 1"), 1, NULL))
- {
- found = TRUE;
-- if (gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ if (gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->cool_link_2_string, 1, "\n", 0, NULL,
- _("Cool Link 2"), 1, NULL))
- {
-- gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ gaim2_markup_extract_info_field(stripped, stripped_len, s,
- strings->cool_link_3_string, 1, "\n", 0, NULL,
- _("Cool Link 3"), 1, NULL);
- }
-@@ -1137,12 +1137,12 @@ static void yahoo_got_photo(void *data,
- }
-
- /* see if Member Since is there, and if so, extract it. */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- "Member Since:", 1, last_updated_utf8_string,
- '\n', NULL, _("Member Since"), 0, NULL);
-
- /* extract the Last Updated date and put it in */
-- found |= gaim_markup_extract_info_field(stripped, stripped_len, s,
-+ found |= gaim2_markup_extract_info_field(stripped, stripped_len, s,
- last_updated_utf8_string, 1, " ", '\n', NULL,
- _("Last Update"), 0, NULL);
- } /* if (profile_state == PROFILE_STATE_DEFAULT) */
-@@ -1160,8 +1160,8 @@ static void yahoo_got_photo(void *data,
- "or format that is not supported at this time."));
-
- } else if (profile_state == PROFILE_STATE_NOT_FOUND) {
-- GaimBuddy *b = gaim_find_buddy
-- (gaim_connection_get_account(info_data->gc),
-+ Gaim2Buddy *b = gaim2_find_buddy
-+ (gaim2_connection_get_account(info_data->gc),
- info_data->name);
- YahooFriend *f = NULL;
- if (b) {
-@@ -1203,7 +1203,7 @@ static void yahoo_got_photo(void *data,
- g_string_prepend(s, "<html><body>\n");
-
- /* show it to the user */
-- gaim_notify_userinfo(info_data->gc, info_data->name,
-+ gaim2_notify_userinfo(info_data->gc, info_data->name,
- s->str, NULL, NULL);
-
- g_free(last_updated_utf8_string);
-@@ -1219,11 +1219,11 @@ static void yahoo_got_photo(void *data,
- g_free(photo_url_text);
- g_free(info2_data);
- if (id != -1)
-- gaim_imgstore_unref(id);
-+ gaim2_imgstore_unref(id);
- #endif
- }
-
--void yahoo_get_info(GaimConnection *gc, const char *name)
-+void yahoo_get_info(Gaim2Connection *gc, const char *name)
- {
- struct yahoo_data *yd = gc->proto_data;
- YahooGetInfoData *data;
-@@ -1236,7 +1236,7 @@ void yahoo_get_info(GaimConnection *gc,
- url = g_strdup_printf("%s%s",
- (yd->jp? YAHOOJP_PROFILE_URL: YAHOO_PROFILE_URL), name);
-
-- gaim_url_fetch(url, TRUE, NULL, FALSE, yahoo_got_info, data);
-+ gaim2_url_fetch(url, TRUE, NULL, FALSE, yahoo_got_info, data);
-
- g_free(url);
- }
-diff -prNu ./src/protocols/yahoo/ycht.c ./src/protocols/yahoo/ycht.c
---- ./src/protocols/yahoo/ycht.c 2005-10-12 06:02:46.000000000 +0200
-+++ ./src/protocols/yahoo/ycht.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,12 +1,12 @@
- /**
- * @file ycht.c The Yahoo! protocol plugin, YCHT protocol stuff.
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2004 Timothy Ringenbach <omarvo@hotmail.com>
- * Liberal amounts of code borrowed from the rest of the Yahoo! prpl.
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -54,7 +54,7 @@
- ************************************************************************************/
- static void ycht_process_login(YchtConn *ycht, YchtPkt *pkt)
- {
-- GaimConnection *gc = ycht->gc;
-+ Gaim2Connection *gc = ycht->gc;
- struct yahoo_data *yd = gc->proto_data;
-
- if (ycht->logged_in)
-@@ -69,7 +69,7 @@ static void ycht_process_login(YchtConn
-
- static void ycht_process_logout(YchtConn *ycht, YchtPkt *pkt)
- {
-- GaimConnection *gc = ycht->gc;
-+ Gaim2Connection *gc = ycht->gc;
- struct yahoo_data *yd = gc->proto_data;
-
- yd->chat_online = FALSE;
-@@ -79,8 +79,8 @@ static void ycht_process_logout(YchtConn
- static void ycht_process_chatjoin(YchtConn *ycht, YchtPkt *pkt)
- {
- char *room, *topic;
-- GaimConnection *gc = ycht->gc;
-- GaimConversation *c = NULL;
-+ Gaim2Connection *gc = ycht->gc;
-+ Gaim2Conversation *c = NULL;
- gboolean new_room = FALSE;
- char **members;
- int i;
-@@ -107,17 +107,17 @@ static void ycht_process_chatjoin(YchtCo
- ycht->changing_rooms = FALSE;
- c = serv_got_joined_chat(gc, YAHOO_CHAT_ID, room);
- } else {
-- c = gaim_find_chat(gc, YAHOO_CHAT_ID);
-+ c = gaim2_find_chat(gc, YAHOO_CHAT_ID);
- }
-
- if (topic)
-- gaim_conv_chat_set_topic(GAIM_CONV_CHAT(c), NULL, topic);
-+ gaim2_conv_chat_set_topic(GAIM_CONV_CHAT(c), NULL, topic);
-
- for (i = 0; members[i]; i++) {
- if (new_room) {
-- /*if (!strcmp(members[i], gaim_connection_get_display_name(ycht->gc)))
-+ /*if (!strcmp(members[i], gaim2_connection_get_display_name(ycht->gc)))
- continue;*/
-- gaim_conv_chat_add_user(GAIM_CONV_CHAT(c), members[i], NULL, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(GAIM_CONV_CHAT(c), members[i], NULL, GAIM_CBFLAGS_NONE, TRUE);
- } else {
- yahoo_chat_add_user(GAIM_CONV_CHAT(c), members[i], NULL);
- }
-@@ -134,9 +134,9 @@ static void ycht_process_chatpart(YchtCo
- who = g_list_nth_data(pkt->data, 1);
-
- if (who && room) {
-- GaimConversation *c = gaim_find_chat(ycht->gc, YAHOO_CHAT_ID);
-- if (c && !gaim_utf8_strcasecmp(gaim_conversation_get_name(c), room))
-- gaim_conv_chat_remove_user(GAIM_CONV_CHAT(c), who, NULL);
-+ Gaim2Conversation *c = gaim2_find_chat(ycht->gc, YAHOO_CHAT_ID);
-+ if (c && !gaim2_utf8_strcasecmp(gaim2_conversation_get_name(c), room))
-+ gaim2_conv_chat_remove_user(GAIM_CONV_CHAT(c), who, NULL);
-
- }
- }
-@@ -144,8 +144,8 @@ static void ycht_process_chatpart(YchtCo
- static void ycht_progress_chatmsg(YchtConn *ycht, YchtPkt *pkt)
- {
- char *who, *what, *msg;
-- GaimConversation *c;
-- GaimConnection *gc = ycht->gc;
-+ Gaim2Conversation *c;
-+ Gaim2Connection *gc = ycht->gc;
-
- who = g_list_nth_data(pkt->data, 1);
- what = g_list_nth_data(pkt->data, 2);
-@@ -153,7 +153,7 @@ static void ycht_progress_chatmsg(YchtCo
- if (!who || !what)
- return;
-
-- c = gaim_find_chat(gc, YAHOO_CHAT_ID);
-+ c = gaim2_find_chat(gc, YAHOO_CHAT_ID);
- if (!c)
- return;
-
-@@ -174,7 +174,7 @@ static void ycht_progress_chatmsg(YchtCo
- static void ycht_progress_online_friends(YchtConn *ycht, YchtPkt *pkt)
- {
- #if 0
-- GaimConnection *gc = ycht->gc;
-+ Gaim2Connection *gc = ycht->gc;
- struct yahoo_data *yd = gc->proto_data;
-
- if (ycht->logged_in)
-@@ -196,35 +196,35 @@ static void ycht_packet_dump(const gucha
- #ifdef YAHOO_YCHT_DEBUG
- int i;
-
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
-
- for (i = 0; i + 1 < len; i += 2) {
- if ((i % 16 == 0) && i) {
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
- }
-
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "%02hhx%02hhx ", data[i], data[i + 1]);
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "%02hhx%02hhx ", data[i], data[i + 1]);
- }
- if (i < len)
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "%02hhx", data[i]);
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "%02hhx", data[i]);
-
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
-
- for (i = 0; i < len; i++) {
- if ((i % 16 == 0) && i) {
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo", "");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo", "");
- }
-
- if (g_ascii_isprint(data[i]))
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "%c ", data[i]);
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "%c ", data[i]);
- else
-- gaim_debug(GAIM_DEBUG_MISC, NULL, ". ");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, ". ");
- }
-
-- gaim_debug(GAIM_DEBUG_MISC, NULL, "\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, NULL, "\n");
- #endif
- }
-
-@@ -312,7 +312,7 @@ static void ycht_packet_read(YchtPkt *pk
- len -= needle - pos + strlen(YCHT_SEP);
- pos = needle + strlen(YCHT_SEP);
- tmp2 = g_strescape(tmp, NULL);
-- gaim_debug_misc("yahoo", "Data[%d]:\t%s\n", i++, tmp2);
-+ gaim2_debug_misc("yahoo", "Data[%d]:\t%s\n", i++, tmp2);
- g_free(tmp2);
- }
-
-@@ -320,11 +320,11 @@ static void ycht_packet_read(YchtPkt *pk
- tmp = g_strndup(pos, len);
- pkt->data = g_list_append(pkt->data, tmp);
- tmp2 = g_strescape(tmp, NULL);
-- gaim_debug_misc("yahoo", "Data[%d]:\t%s\n", i, tmp2);
-+ gaim2_debug_misc("yahoo", "Data[%d]:\t%s\n", i, tmp2);
- g_free(tmp2);
- };
-
-- gaim_debug_misc("yahoo", "--==End of incoming YCHT packet==--\n");
-+ gaim2_debug_misc("yahoo", "--==End of incoming YCHT packet==--\n");
- }
-
- static void ycht_packet_process(YchtConn *ycht, YchtPkt *pkt)
-@@ -353,7 +353,7 @@ static void ycht_packet_process(YchtConn
- ycht_progress_online_friends(ycht, pkt);
- break;
- default:
-- gaim_debug_warning("yahoo", "YCHT: warning, unhandled service 0x%02x\n", pkt->service);
-+ gaim2_debug_warning("yahoo", "YCHT: warning, unhandled service 0x%02x\n", pkt->service);
- }
- }
-
-@@ -386,7 +386,7 @@ void ycht_connection_close(YchtConn *ych
- if (ycht->fd > 0)
- close(ycht->fd);
- if (ycht->inpa)
-- gaim_input_remove(ycht->inpa);
-+ gaim2_input_remove(ycht->inpa);
-
- if (ycht->rxqueue)
- g_free(ycht->rxqueue);
-@@ -397,11 +397,11 @@ void ycht_connection_close(YchtConn *ych
- static void ycht_connection_error(YchtConn *ycht, const gchar *error)
- {
-
-- gaim_notify_info(ycht->gc, NULL, _("Connection problem with the YCHT server."), error);
-+ gaim2_notify_info(ycht->gc, NULL, _("Connection problem with the YCHT server."), error);
- ycht_connection_close(ycht);
- }
-
--static void ycht_pending(gpointer data, gint source, GaimInputCondition cond)
-+static void ycht_pending(gpointer data, gint source, Gaim2InputCondition cond)
- {
- YchtConn *ycht = data;
- char buf[1024];
-@@ -430,7 +430,7 @@ static void ycht_pending(gpointer data,
- return;
-
- if (strncmp("YCHT", (char *)ycht->rxqueue, 4) != 0)
-- gaim_debug_error("yahoo", "YCHT: protocol error.\n");
-+ gaim2_debug_error("yahoo", "YCHT: protocol error.\n");
-
- pos += 4; /* YCHT */
-
-@@ -438,14 +438,14 @@ static void ycht_pending(gpointer data,
- service = yahoo_get32(ycht->rxqueue + pos); pos += 4;
- status = yahoo_get16(ycht->rxqueue + pos); pos += 2;
- pktlen = yahoo_get16(ycht->rxqueue + pos); pos += 2;
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "ycht: %d bytes to read, rxlen is %d\n", pktlen, ycht->rxlen);
-
- if (ycht->rxlen < (YCHT_HEADER_LEN + pktlen))
- return;
-
-- gaim_debug_misc("yahoo", "--==Incoming YCHT packet==--\n");
-- gaim_debug(GAIM_DEBUG_MISC, "yahoo",
-+ gaim2_debug_misc("yahoo", "--==Incoming YCHT packet==--\n");
-+ gaim2_debug(GAIM_DEBUG_MISC, "yahoo",
- "YCHT Service: 0x%02x Version: 0x%02x Status: 0x%02x\n",
- service, version, status);
- ycht_packet_dump(ycht->rxqueue, YCHT_HEADER_LEN + pktlen);
-@@ -469,10 +469,10 @@ static void ycht_pending(gpointer data,
- }
- }
-
--static void ycht_got_connected(gpointer data, gint source, GaimInputCondition cond)
-+static void ycht_got_connected(gpointer data, gint source, Gaim2InputCondition cond)
- {
- YchtConn *ycht = data;
-- GaimConnection *gc = ycht->gc;
-+ Gaim2Connection *gc = ycht->gc;
- struct yahoo_data *yd = gc->proto_data;
- YchtPkt *pkt;
- char *buf;
-@@ -486,7 +486,7 @@ static void ycht_got_connected(gpointer
-
- pkt = ycht_packet_new(YCHT_VERSION, YCHT_SERVICE_LOGIN, 0);
-
-- buf = g_strdup_printf("%s\001Y=%s; T=%s", gaim_connection_get_display_name(gc), yd->cookie_y, yd->cookie_t);
-+ buf = g_strdup_printf("%s\001Y=%s; T=%s", gaim2_connection_get_display_name(gc), yd->cookie_y, yd->cookie_t);
- ycht_packet_append(pkt, buf);
- g_free(buf);
-
-@@ -494,14 +494,14 @@ static void ycht_got_connected(gpointer
-
- ycht_packet_free(pkt);
-
-- ycht->inpa = gaim_input_add(ycht->fd, GAIM_INPUT_READ, ycht_pending, ycht);
-+ ycht->inpa = gaim2_input_add(ycht->fd, GAIM_INPUT_READ, ycht_pending, ycht);
- }
-
--void ycht_connection_open(GaimConnection *gc)
-+void ycht_connection_open(Gaim2Connection *gc)
- {
- YchtConn *ycht;
- struct yahoo_data *yd = gc->proto_data;
-- GaimAccount *account = gaim_connection_get_account(gc);
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-
- ycht = g_new0(YchtConn, 1);
- ycht->gc = gc;
-@@ -509,9 +509,9 @@ void ycht_connection_open(GaimConnection
-
- yd->ycht = ycht;
-
-- if (gaim_proxy_connect(account,
-- gaim_account_get_string(account, "ycht-server", YAHOO_YCHT_HOST),
-- gaim_account_get_int(account, "ycht-port", YAHOO_YCHT_PORT),
-+ if (gaim2_proxy_connect(account,
-+ gaim2_account_get_string(account, "ycht-server", YAHOO_YCHT_HOST),
-+ gaim2_account_get_int(account, "ycht-port", YAHOO_YCHT_PORT),
- ycht_got_connected, ycht) != 0)
- {
- ycht_connection_error(ycht, _("Connection problem"));
-@@ -549,7 +549,7 @@ int ycht_chat_send(YchtConn *ycht, const
- char *msg1, *msg2, *buf;
-
- if (strcmp(room, ycht->room))
-- gaim_debug_warning("yahoo", "uhoh, sending to the wrong room!\n");
-+ gaim2_debug_warning("yahoo", "uhoh, sending to the wrong room!\n");
-
- pkt = ycht_packet_new(YCHT_VERSION, YCHT_SERVICE_CHATMSG, 0);
-
-diff -prNu ./src/protocols/yahoo/ycht.h ./src/protocols/yahoo/ycht.h
---- ./src/protocols/yahoo/ycht.h 2005-10-12 06:02:46.000000000 +0200
-+++ ./src/protocols/yahoo/ycht.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,11 +1,11 @@
- /**
- * @file ycht.h The Yahoo! protocol plugin, YCHT protocol stuff.
- *
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 2004 Timothy Ringenbach <omarvo@hotmail.com>
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -64,7 +64,7 @@ yahoo: --==End of incoming YCHT packet==
- #define YCHT_SEP "\xc0\x80"
-
- typedef struct _YchtConn {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- gchar *room;
- int room_id;
- gint fd;
-@@ -82,7 +82,7 @@ typedef struct {
- GList *data;
- } YchtPkt;
-
--void ycht_connection_open(GaimConnection *gc);
-+void ycht_connection_open(Gaim2Connection *gc);
- void ycht_connection_close(YchtConn *ycht);
-
- void ycht_chat_join(YchtConn *ycht, const char *room);
-diff -prNu ./src/protocols/zephyr/Makefile.am ./src/protocols/zephyr/Makefile.am
---- ./src/protocols/zephyr/Makefile.am 2005-04-29 19:04:28.000000000 +0200
-+++ ./src/protocols/zephyr/Makefile.am 2006-01-05 13:05:47.000000000 +0100
-@@ -1,4 +1,4 @@
--pkgdir = $(libdir)/gaim
-+pkgdir = $(libdir)/gaim2
-
- ZEPHYRSOURCES = \
- ZAsyncLocate.c \
-diff -prNu ./src/protocols/zephyr/zephyr.c ./src/protocols/zephyr/zephyr.c
---- ./src/protocols/zephyr/zephyr.c 2005-12-25 20:09:25.000000000 +0100
-+++ ./src/protocols/zephyr/zephyr.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,6 +1,6 @@
- /* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- */
- /*
-- * gaim
-+ * gaim2
- *
- * Copyright (C) 1998-2001, Mark Spencer <markster@marko.net>
- * Some code borrowed from GtkZephyr, by
-@@ -70,7 +70,7 @@ typedef enum {
- } zephyr_connection_type;
-
- struct _zephyr_account {
-- GaimAccount* account;
-+ Gaim2Account* account;
- char *username;
- char *realm;
- char *encoding;
-@@ -139,7 +139,7 @@ struct _zephyr_triple {
- return TRUE;
-
- #define z_call_s(func, err) if (func != ZERR_NONE) {\
-- gaim_connection_error(gc, err);\
-+ gaim2_connection_error(gc, err);\
- return;\
- }
-
-@@ -172,7 +172,7 @@ static Code_t zephyr_subscribe_to(zephyr
- }
-
- char *local_zephyr_normalize(zephyr_account* zephyr,const char *);
--static void zephyr_chat_set_topic(GaimConnection * gc, int id, const char *topic);
-+static void zephyr_chat_set_topic(Gaim2Connection * gc, int id, const char *topic);
- char* zephyr_tzc_deescape_str(const char *message);
-
- static char *zephyr_strip_local_realm(zephyr_account* zephyr,const char* user){
-@@ -205,16 +205,16 @@ static char *zephyr_strip_local_realm(ze
- /* just for debugging */
- static void handle_unknown(ZNotice_t notice)
- {
-- gaim_debug_error("zephyr","z_packet: %s\n", notice.z_packet);
-- gaim_debug_error("zephyr","z_version: %s\n", notice.z_version);
-- gaim_debug_error("zephyr","z_kind: %d\n", (int)(notice.z_kind));
-- gaim_debug_error("zephyr","z_class: %s\n", notice.z_class);
-- gaim_debug_error("zephyr","z_class_inst: %s\n", notice.z_class_inst);
-- gaim_debug_error("zephyr","z_opcode: %s\n", notice.z_opcode);
-- gaim_debug_error("zephyr","z_sender: %s\n", notice.z_sender);
-- gaim_debug_error("zephyr","z_recipient: %s\n", notice.z_recipient);
-- gaim_debug_error("zephyr","z_message: %s\n", notice.z_message);
-- gaim_debug_error("zephyr","z_message_len: %d\n", notice.z_message_len);
-+ gaim2_debug_error("zephyr","z_packet: %s\n", notice.z_packet);
-+ gaim2_debug_error("zephyr","z_version: %s\n", notice.z_version);
-+ gaim2_debug_error("zephyr","z_kind: %d\n", (int)(notice.z_kind));
-+ gaim2_debug_error("zephyr","z_class: %s\n", notice.z_class);
-+ gaim2_debug_error("zephyr","z_class_inst: %s\n", notice.z_class_inst);
-+ gaim2_debug_error("zephyr","z_opcode: %s\n", notice.z_opcode);
-+ gaim2_debug_error("zephyr","z_sender: %s\n", notice.z_sender);
-+ gaim2_debug_error("zephyr","z_recipient: %s\n", notice.z_recipient);
-+ gaim2_debug_error("zephyr","z_message: %s\n", notice.z_message);
-+ gaim2_debug_error("zephyr","z_message_len: %d\n", notice.z_message_len);
- }
-
-
-@@ -255,21 +255,21 @@ static gboolean triple_subset(zephyr_tri
- {
-
- if (!zt2)
-- gaim_debug_error("zephyr","zt2 doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt2 doesn't exist\n");
- if (!zt1)
-- gaim_debug_error("zephyr","zt1 doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt1 doesn't exist\n");
- if (!(zt1->class))
-- gaim_debug_error("zephyr","zt1c doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt1c doesn't exist\n");
- if (!(zt1->instance))
-- gaim_debug_error("zephyr","zt1i doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt1i doesn't exist\n");
- if (!(zt1->recipient))
-- gaim_debug_error("zephyr","zt1r doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt1r doesn't exist\n");
- if (!(zt2->class))
-- gaim_debug_error("zephyr","zt2c doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt2c doesn't exist\n");
- if (!(zt2->recipient))
-- gaim_debug_error("zephyr","zt2r doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt2r doesn't exist\n");
- if (!(zt2->instance))
-- gaim_debug_error("zephyr","zt2i doesn't exist\n");
-+ gaim2_debug_error("zephyr","zt2i doesn't exist\n");
-
-
- if (g_ascii_strcasecmp(zt2->class, zt1->class)) {
-@@ -281,7 +281,7 @@ static gboolean triple_subset(zephyr_tri
- if (g_ascii_strcasecmp(zt2->recipient, zt1->recipient)) {
- return FALSE;
- }
-- gaim_debug_info("zephyr","<%s,%s,%s> is in <%s,%s,%s>\n",zt1->class,zt1->instance,zt1->recipient,zt2->class,zt2->instance,zt2->recipient);
-+ gaim2_debug_info("zephyr","<%s,%s,%s> is in <%s,%s,%s>\n",zt1->class,zt1->instance,zt1->recipient,zt2->class,zt2->instance,zt2->recipient);
- return TRUE;
- }
-
-@@ -317,7 +317,7 @@ static zephyr_triple *find_sub_by_id(zep
- Converts strings to utf-8 if necessary using user specified encoding
- */
-
--static gchar *zephyr_recv_convert(GaimConnection *gc,gchar *string, int len)
-+static gchar *zephyr_recv_convert(Gaim2Connection *gc,gchar *string, int len)
- {
- gchar *utf8;
- GError *err = NULL;
-@@ -327,7 +327,7 @@ static gchar *zephyr_recv_convert(GaimCo
- } else {
- utf8 = g_convert(string, len, "UTF-8", zephyr->encoding, NULL, NULL, &err);
- if (err) {
-- gaim_debug_error("zephyr", "recv conversion error: %s\n", err->message);
-+ gaim2_debug_error("zephyr", "recv conversion error: %s\n", err->message);
- utf8 = g_strdup(_("(There was an error converting this message. Check the 'Encoding' option in the Account Editor)"));
- g_error_free(err);
- }
-@@ -366,7 +366,7 @@ static char *html_to_zephyr(const char *
- bzero(ret, len * 3);
- retcount = 0;
- cnt = 0;
-- gaim_debug_info("zephyr","html received %s\n",message);
-+ gaim2_debug_info("zephyr","html received %s\n",message);
- while (cnt <= len) {
- if (message[cnt] == '<') {
- if (!g_ascii_strncasecmp(message + cnt + 1, "i>", 2)) {
-@@ -489,7 +489,7 @@ static char *html_to_zephyr(const char *
- cnt++;
- }
- }
-- gaim_debug_info("zephyr","zephyr outputted %s\n",ret);
-+ gaim2_debug_info("zephyr","zephyr outputted %s\n",ret);
- return ret;
- }
-
-@@ -680,18 +680,18 @@ static gboolean pending_zloc(zephyr_acco
-
- /* Called when the server notifies us a message couldn't get sent */
-
--static void message_failed(GaimConnection *gc, ZNotice_t notice, struct sockaddr_in from)
-+static void message_failed(Gaim2Connection *gc, ZNotice_t notice, struct sockaddr_in from)
- {
- if (g_ascii_strcasecmp(notice.z_class, "message")) {
- gchar* chat_failed = g_strdup_printf(_("Unable to send to chat %s,%s,%s"),notice.z_class,notice.z_class_inst,notice.z_recipient);
-- gaim_notify_error(gc,"",chat_failed,NULL);
-+ gaim2_notify_error(gc,"",chat_failed,NULL);
- g_free(chat_failed);
- } else {
-- gaim_notify_error(gc, notice.z_recipient, _("User is offline"), NULL);
-+ gaim2_notify_error(gc, notice.z_recipient, _("User is offline"), NULL);
- }
- }
-
--static void handle_message(GaimConnection *gc,ZNotice_t notice)
-+static void handle_message(Gaim2Connection *gc,ZNotice_t notice)
- {
- zephyr_account* zephyr = gc->proto_data;
-
-@@ -701,14 +701,14 @@ static void handle_message(GaimConnectio
- if (!g_ascii_strcasecmp(notice.z_opcode, LOCATE_LOCATE)) {
- int nlocs;
- char *user;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- /* XXX add real error reporting */
- if (ZParseLocations(&notice, NULL, &nlocs, &user) != ZERR_NONE)
- return;
-
-- if ((b = gaim_find_buddy(gc->account, user)) == NULL) {
-+ if ((b = gaim2_find_buddy(gc->account, user)) == NULL) {
- char* stripped_user = zephyr_strip_local_realm(zephyr,user);
-- b = gaim_find_buddy(gc->account,stripped_user);
-+ b = gaim2_find_buddy(gc->account,stripped_user);
- g_free(stripped_user);
- }
- if ((b && pending_zloc(zephyr,b->name)) || pending_zloc(zephyr,user)) {
-@@ -727,14 +727,14 @@ static void handle_message(GaimConnectio
- ZGetLocations(&locs, &one);
- g_string_append_printf(str, _("<br>At %s since %s"), locs.host, locs.time);
- }
-- gaim_notify_userinfo(gc, b ? b->name : user,
-+ gaim2_notify_userinfo(gc, b ? b->name : user,
- str->str, NULL, NULL);
- g_string_free(str, TRUE);
- } else {
- if (nlocs>0)
-- gaim_prpl_got_user_status(gc->account,b->name,"available",NULL);
-+ gaim2_prpl_got_user_status(gc->account,b->name,"available",NULL);
- else
-- gaim_prpl_got_user_status(gc->account,b->name,"offline",NULL);
-+ gaim2_prpl_got_user_status(gc->account,b->name,"offline",NULL);
- }
-
- g_free(user);
-@@ -742,27 +742,27 @@ static void handle_message(GaimConnectio
- } else {
- char *buf, *buf2, *buf3;
- char *send_inst;
-- GaimConversation *gconv1;
-- GaimConvChat *gcc;
-+ Gaim2Conversation *gconv1;
-+ Gaim2ConvChat *gcc;
- char *ptr = (char *) notice.z_message + (strlen(notice.z_message) + 1);
- int len;
- char *sendertmp = g_strdup_printf("%s", zephyr->username);
- int signature_length = strlen(notice.z_message);
- int message_has_no_body = 0;
-- GaimMessageFlags flags = 0;
-+ Gaim2MessageFlags flags = 0;
- gchar *tmpescape;
-
- /* Need to deal with 0 length messages to handle typing notification (OPCODE) ping messages */
-- /* One field zephyrs would have caused gaim to crash */
-+ /* One field zephyrs would have caused gaim2 to crash */
- if ( (notice.z_message_len == 0) || (signature_length >= notice.z_message_len - 1)) {
- message_has_no_body = 1;
- len = 0;
-- gaim_debug_info("zephyr","message_size %d %d %d\n",len,notice.z_message_len,signature_length);
-+ gaim2_debug_info("zephyr","message_size %d %d %d\n",len,notice.z_message_len,signature_length);
- buf3 = g_strdup("");
-
- } else {
- len = notice.z_message_len - ( signature_length +1);
-- gaim_debug_info("zephyr","message_size %d %d %d\n",len,notice.z_message_len,signature_length);
-+ gaim2_debug_info("zephyr","message_size %d %d %d\n",len,notice.z_message_len,signature_length);
- buf = g_malloc(len + 1);
- g_snprintf(buf, len + 1, "%s", ptr);
- g_strchomp(buf);
-@@ -800,7 +800,7 @@ static void handle_message(GaimConnectio
- case GAIM_PRIVACY_ALLOW_USERS: /* See if stripped_sender is in gc->account->permit and allow appropriately */
- in_deny = 1;
- for(l=gc->account->permit;l!=NULL;l=l->next) {
-- if (!gaim_utf8_strcasecmp(stripped_sender, gaim_normalize(gc->account, (char *)l->data))) {
-+ if (!gaim2_utf8_strcasecmp(stripped_sender, gaim2_normalize(gc->account, (char *)l->data))) {
- in_deny=0;
- break;
- }
-@@ -809,7 +809,7 @@ static void handle_message(GaimConnectio
- case GAIM_PRIVACY_DENY_USERS: /* See if stripped_sender is in gc->account->deny and deny if so */
- in_deny = 0;
- for(l=gc->account->deny;l!=NULL;l=l->next) {
-- if (!gaim_utf8_strcasecmp(stripped_sender, gaim_normalize(gc->account, (char *)l->data))) {
-+ if (!gaim2_utf8_strcasecmp(stripped_sender, gaim2_normalize(gc->account, (char *)l->data))) {
- in_deny=1;
- break;
- }
-@@ -817,7 +817,7 @@ static void handle_message(GaimConnectio
- break;
- case GAIM_PRIVACY_ALLOW_BUDDYLIST:
- in_deny = 1;
-- if (gaim_find_buddy(gc->account,stripped_sender)!=NULL) {
-+ if (gaim2_find_buddy(gc->account,stripped_sender)!=NULL) {
- in_deny = 0;
- }
- break;
-@@ -855,24 +855,24 @@ static void handle_message(GaimConnectio
- send_inst = g_strdup_printf("%s %s",sendertmp,notice.z_class_inst);
- send_inst_utf8 = zephyr_recv_convert(gc,send_inst, strlen(send_inst));
- if (!send_inst_utf8) {
-- gaim_debug_error("zephyr","send_inst %s became null\n", send_inst);
-+ gaim2_debug_error("zephyr","send_inst %s became null\n", send_inst);
- send_inst_utf8 = "malformed instance";
- }
-
- serv_got_chat_in(gc, zt2->id, send_inst_utf8, 0, buf3, time(NULL));
- g_free(send_inst);
-- gconv1 = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
-+ gconv1 = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT,
- zt2->name, gc->account);
-- gcc = gaim_conversation_get_chat_data(gconv1);
-+ gcc = gaim2_conversation_get_chat_data(gconv1);
-
-- if (!gaim_conv_chat_find_user(gcc, sendertmp)) {
-+ if (!gaim2_conv_chat_find_user(gcc, sendertmp)) {
- /* force interpretation in network byte order */
- unsigned char *addrs = (unsigned char *)&(notice.z_sender_addr.s_addr);
- gchar* ipaddr = g_strdup_printf("%hhd.%hhd.%hhd.%hhd", (unsigned char)addrs[0],
- (unsigned char)addrs[1], (unsigned char)addrs[2],
- (unsigned char) addrs[3]);
-
-- gaim_conv_chat_add_user(gcc, sendertmp, ipaddr, GAIM_CBFLAGS_NONE, TRUE);
-+ gaim2_conv_chat_add_user(gcc, sendertmp, ipaddr, GAIM_CBFLAGS_NONE, TRUE);
- g_free(ipaddr); /* fix memory leak? */
-
- }
-@@ -1014,7 +1014,7 @@ static parse_tree *parse_buffer(gchar* s
- /* In case we surpass maxchildren, ignore this */
- ptree->children[ptree->num_children++] = parse_buffer( newstr, do_parse);
- } else {
-- gaim_debug_error("zephyr","too many children in tzc output. skipping\n");
-+ gaim2_debug_error("zephyr","too many children in tzc output. skipping\n");
- }
- g_free(newstr);
- p = end + 1;
-@@ -1048,7 +1048,7 @@ static parse_tree *read_from_tzc(zephyr
- bufcur++;
- if ((bufcur - buf) > (bufsize - 1)) {
- if ((buf = realloc(buf, bufsize * 2)) == NULL) {
-- gaim_debug_error("zephyr","Ran out of memory");
-+ gaim2_debug_error("zephyr","Ran out of memory");
- exit(-1);
- } else {
- bufcur = buf + bufsize;
-@@ -1067,7 +1067,7 @@ static parse_tree *read_from_tzc(zephyr
-
- static gint check_notify_tzc(gpointer data)
- {
-- GaimConnection *gc = (GaimConnection *)data;
-+ Gaim2Connection *gc = (Gaim2Connection *)data;
- zephyr_account* zephyr = gc->proto_data;
- parse_tree *newparsetree = read_from_tzc(zephyr);
- if (newparsetree != NULL) {
-@@ -1077,7 +1077,7 @@ static gint check_notify_tzc(gpointer da
- ZNotice_t notice;
- parse_tree *msgnode = tree_child(find_node(newparsetree,"message"),2);
- parse_tree *bodynode = tree_child(msgnode,1);
-- /* char *zsig = g_strdup(" "); */ /* gaim doesn't care about zsigs */
-+ /* char *zsig = g_strdup(" "); */ /* gaim2 doesn't care about zsigs */
- char *msg = zephyr_tzc_deescape_str(bodynode->contents);
- size_t bufsize = strlen(msg) + 3;
- char *buf = g_new0(char,bufsize);
-@@ -1108,15 +1108,15 @@ static gint check_notify_tzc(gpointer da
- /* check_loc or zephyr_zloc respectively */
- /* XXX fix */
- char *user;
-- GaimBuddy *b;
-+ Gaim2Buddy *b;
- int nlocs = 0;
- parse_tree *locations;
- gchar *locval;
- user = tree_child(find_node(newparsetree,"user"),2)->contents;
-
-- if ((b = gaim_find_buddy(gc->account, user)) == NULL) {
-+ if ((b = gaim2_find_buddy(gc->account, user)) == NULL) {
- gchar *stripped_user = zephyr_strip_local_realm(zephyr,user);
-- b = gaim_find_buddy(gc->account, stripped_user);
-+ b = gaim2_find_buddy(gc->account, stripped_user);
- g_free(stripped_user);
- }
- locations = find_node(newparsetree,"locations");
-@@ -1143,14 +1143,14 @@ static gint check_notify_tzc(gpointer da
- tree_child(tree_child(tree_child(tree_child(locations,2),0),2),2)->contents);
- }
-
-- gaim_notify_userinfo(gc, b ? b->name : user,
-+ gaim2_notify_userinfo(gc, b ? b->name : user,
- str->str, NULL, NULL);
- g_string_free(str, TRUE);
- } else {
- if (nlocs>0)
-- gaim_prpl_got_user_status(gc->account,b->name,"available",NULL);
-+ gaim2_prpl_got_user_status(gc->account,b->name,"available",NULL);
- else
-- gaim_prpl_got_user_status(gc->account,b->name,"offline",NULL);
-+ gaim2_prpl_got_user_status(gc->account,b->name,"offline",NULL);
- }
- }
- else if (!g_ascii_strncasecmp(spewtype,"subscribed",10)) {
-@@ -1172,7 +1172,7 @@ static gint check_notify_tzc(gpointer da
- static gint check_notify_zeph02(gpointer data)
- {
- /* XXX add real error reporting */
-- GaimConnection *gc = (GaimConnection*) data;
-+ Gaim2Connection *gc = (Gaim2Connection*) data;
- while (ZPending()) {
- ZNotice_t notice;
- struct sockaddr_in from;
-@@ -1192,11 +1192,11 @@ static gint check_notify_zeph02(gpointer
- }
- break;
- case CLIENTACK:
-- gaim_debug_error("zephyr", "Client ack received\n");
-+ gaim2_debug_error("zephyr", "Client ack received\n");
- default:
- /* we'll just ignore things for now */
- handle_unknown(notice);
-- gaim_debug_error("zephyr", "Unhandled notice.\n");
-+ gaim2_debug_error("zephyr", "Unhandled notice.\n");
- break;
- }
- /* XXX add real error reporting */
-@@ -1210,19 +1210,19 @@ static gint check_notify_zeph02(gpointer
-
- static gint check_loc(gpointer_data)
- {
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- ZLocations_t locations;
- int numlocs;
- int one = 1;
-
-- for (gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for (gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if (!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *b = (GaimBuddy *) bnode;
-+ Gaim2Buddy *b = (Gaim2Buddy *) bnode;
-
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-@@ -1248,9 +1248,9 @@ static gint check_loc(gpointer_data)
-
- static gint check_loc(gpointer data)
- {
-- GaimBlistNode *gnode, *cnode, *bnode;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
- ZAsyncLocateData_t ald;
-- GaimConnection *gc = (GaimConnection *)data;
-+ Gaim2Connection *gc = (Gaim2Connection *)data;
- zephyr_account *zephyr = gc->proto_data;
-
- if (use_zeph02(zephyr)) {
-@@ -1259,14 +1259,14 @@ static gint check_loc(gpointer data)
- ald.version = NULL;
- }
-
-- for (gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for (gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
- if (!GAIM_BLIST_NODE_IS_CONTACT(cnode))
- continue;
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
-- GaimBuddy *b = (GaimBuddy *) bnode;
-+ Gaim2Buddy *b = (Gaim2Buddy *) bnode;
-
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-@@ -1274,7 +1274,7 @@ static gint check_loc(gpointer data)
- const char *chk;
-
- chk = local_zephyr_normalize(zephyr,b->name);
-- gaim_debug_info("zephyr","chk: %s b->name %s\n",chk,b->name);
-+ gaim2_debug_info("zephyr","chk: %s b->name %s\n",chk,b->name);
- /* XXX add real error reporting */
- /* doesn't matter if this fails or not; we'll just move on to the next one */
- if (use_zeph02(zephyr)) {
-@@ -1287,9 +1287,9 @@ static gint check_loc(gpointer data)
- for(i=0;i<numlocs;i++) {
- ZGetLocations(&locations,&one);
- if (nlocs>0)
-- gaim_prpl_got_user_status(gc->account,b->name,"available",NULL);
-+ gaim2_prpl_got_user_status(gc->account,b->name,"available",NULL);
- else
-- gaim_prpl_got_user_status(gc->account,b->name,"offline",NULL);
-+ gaim2_prpl_got_user_status(gc->account,b->name,"offline",NULL);
- }
- }
- #else
-@@ -1349,14 +1349,14 @@ static void zephyr_inithosts(zephyr_acco
- struct hostent *hent;
-
- if (gethostname(zephyr->ourhost, sizeof(zephyr->ourhost)) == -1) {
-- gaim_debug_error("zephyr", "unable to retrieve hostname, %%host%% and %%canon%% will be wrong in subscriptions and have been set to unknown\n");
-+ gaim2_debug_error("zephyr", "unable to retrieve hostname, %%host%% and %%canon%% will be wrong in subscriptions and have been set to unknown\n");
- g_strlcpy(zephyr->ourhost, "unknown", sizeof(zephyr->ourhost));
- g_strlcpy(zephyr->ourhostcanon, "unknown", sizeof(zephyr->ourhostcanon));
- return;
- }
-
- if (!(hent = gethostbyname(zephyr->ourhost))) {
-- gaim_debug_error("zephyr", "unable to resolve hostname, %%canon%% will be wrong in subscriptions.and has been set to the value of %%host%%, %s\n",zephyr->ourhost);
-+ gaim2_debug_error("zephyr", "unable to resolve hostname, %%canon%% will be wrong in subscriptions.and has been set to the value of %%host%%, %s\n",zephyr->ourhost);
- g_strlcpy(zephyr->ourhostcanon, zephyr->ourhost, sizeof(zephyr->ourhostcanon));
- return;
- }
-@@ -1378,7 +1378,7 @@ static void process_zsubs(zephyr_account
- gchar *fname;
- gchar buff[BUFSIZ];
-
-- fname = g_strdup_printf("%s/.zephyr.subs", gaim_home_dir());
-+ fname = g_strdup_printf("%s/.zephyr.subs", gaim2_home_dir());
- f = g_fopen(fname, "r");
- if (f) {
- char **triple;
-@@ -1447,7 +1447,7 @@ static void process_zsubs(zephyr_account
-
- if (zephyr_subscribe_to(zephyr,z_class, z_instance, recip,z_galaxy) != ZERR_NONE) {
-
-- gaim_debug_error("zephyr", "Couldn't subscribe to %s, %s, %s\n", z_class,z_instance,recip);
-+ gaim2_debug_error("zephyr", "Couldn't subscribe to %s, %s, %s\n", z_class,z_instance,recip);
- }
-
- zephyr->subscrips = g_slist_append(zephyr->subscrips, new_triple(zephyr,z_class,z_instance,recip));
-@@ -1462,29 +1462,29 @@ static void process_zsubs(zephyr_account
- }
- }
-
--static void process_anyone(GaimConnection *gc)
-+static void process_anyone(Gaim2Connection *gc)
- {
- FILE *fd;
- gchar buff[BUFSIZ], *filename;
-- GaimGroup *g;
-- GaimBuddy *b;
-+ Gaim2Group *g;
-+ Gaim2Buddy *b;
-
-- if (!(g = gaim_find_group(_("Anyone")))) {
-- g = gaim_group_new(_("Anyone"));
-- gaim_blist_add_group(g, NULL);
-+ if (!(g = gaim2_find_group(_("Anyone")))) {
-+ g = gaim2_group_new(_("Anyone"));
-+ gaim2_blist_add_group(g, NULL);
- }
-
-- filename = g_strconcat(gaim_home_dir(), "/.anyone", NULL);
-+ filename = g_strconcat(gaim2_home_dir(), "/.anyone", NULL);
- if ((fd = g_fopen(filename, "r")) != NULL) {
- while (fgets(buff, BUFSIZ, fd)) {
- strip_comments(buff);
- if (buff[0]) {
-- if (!(b = gaim_find_buddy(gc->account, buff))) {
-+ if (!(b = gaim2_find_buddy(gc->account, buff))) {
- char *stripped_user = zephyr_strip_local_realm(gc->proto_data,buff);
-- gaim_debug_info("zephyr","stripped_user %s\n",stripped_user);
-- if (!(b = gaim_find_buddy(gc->account,stripped_user))){
-- b = gaim_buddy_new(gc->account, stripped_user, NULL);
-- gaim_blist_add_buddy(b, NULL, g, NULL);
-+ gaim2_debug_info("zephyr","stripped_user %s\n",stripped_user);
-+ if (!(b = gaim2_find_buddy(gc->account,stripped_user))){
-+ b = gaim2_buddy_new(gc->account, stripped_user, NULL);
-+ gaim2_blist_add_buddy(b, NULL, g, NULL);
- }
- g_free(stripped_user);
- }
-@@ -1513,21 +1513,21 @@ static char* normalize_zephyr_exposure(c
- return EXPOSE_REALMVIS;
- }
-
--static void zephyr_login(GaimAccount * account)
-+static void zephyr_login(Gaim2Account * account)
- {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- zephyr_account *zephyr;
- gboolean read_anyone;
- gboolean read_zsubs;
- gchar *exposure;
-
-- gc = gaim_account_get_connection(account);
-- read_anyone = gaim_account_get_bool(gc->account,"read_anyone",TRUE);
-- read_zsubs = gaim_account_get_bool(gc->account,"read_zsubs",TRUE);
-- exposure = (gchar *)gaim_account_get_string(gc->account, "exposure_level", EXPOSE_REALMVIS);
-+ gc = gaim2_account_get_connection(account);
-+ read_anyone = gaim2_account_get_bool(gc->account,"read_anyone",TRUE);
-+ read_zsubs = gaim2_account_get_bool(gc->account,"read_zsubs",TRUE);
-+ exposure = (gchar *)gaim2_account_get_string(gc->account, "exposure_level", EXPOSE_REALMVIS);
-
- #ifdef WIN32
-- username = gaim_account_get_username(account);
-+ username = gaim2_account_get_username(account);
- #endif
- gc->flags |= GAIM_CONNECTION_HTML | GAIM_CONNECTION_NO_BGCOLOR | GAIM_CONNECTION_NO_URLDESC;
- gc->proto_data = zephyr=g_new0(zephyr_account,1);
-@@ -1537,56 +1537,56 @@ static void zephyr_login(GaimAccount * a
- /* Make sure that the exposure (visibility) is set to a sane value */
- zephyr->exposure=g_strdup(normalize_zephyr_exposure(exposure));
-
-- if (gaim_account_get_bool(gc->account,"use_tzc",0)) {
-+ if (gaim2_account_get_bool(gc->account,"use_tzc",0)) {
- zephyr->connection_type = GAIM_ZEPHYR_TZC;
- } else {
- zephyr->connection_type = GAIM_ZEPHYR_KRB4;
- }
-
-- zephyr->encoding = (char *)gaim_account_get_string(gc->account, "encoding", ZEPHYR_FALLBACK_CHARSET);
-- gaim_connection_update_progress(gc, _("Connecting"), 0, 8);
-+ zephyr->encoding = (char *)gaim2_account_get_string(gc->account, "encoding", ZEPHYR_FALLBACK_CHARSET);
-+ gaim2_connection_update_progress(gc, _("Connecting"), 0, 8);
-
- /* XXX z_call_s should actually try to report the com_err determined error */
- if (use_tzc(zephyr)) {
- pid_t pid;
-- /* gaim_connection_error(gc,"tzc not supported yet"); */
-+ /* gaim2_connection_error(gc,"tzc not supported yet"); */
- if ((pipe(zephyr->totzc) != 0) || (pipe(zephyr->fromtzc) != 0)) {
-- gaim_debug_error("zephyr", "pipe creation failed. killing\n");
-+ gaim2_debug_error("zephyr", "pipe creation failed. killing\n");
- exit(-1);
- }
-
- pid = fork();
-
- if (pid == -1) {
-- gaim_debug_error("zephyr", "forking failed\n");
-+ gaim2_debug_error("zephyr", "forking failed\n");
- exit(-1);
- }
- if (pid == 0) {
- unsigned int i=0;
- gboolean found_ps = FALSE;
-- gchar ** tzc_cmd_array = g_strsplit(gaim_account_get_string(gc->account,"tzc_command","/usr/bin/tzc -e %s")," ",0);
-+ gchar ** tzc_cmd_array = g_strsplit(gaim2_account_get_string(gc->account,"tzc_command","/usr/bin/tzc -e %s")," ",0);
- if (close(1) == -1) {
-- gaim_debug_error("zephyr", "stdout couldn't be closed. dying\n");
-+ gaim2_debug_error("zephyr", "stdout couldn't be closed. dying\n");
- exit(-1);
- }
- if (dup2(zephyr->fromtzc[1], 1) == -1) {
-- gaim_debug_error("zephyr", "dup2 of stdout failed \n");
-+ gaim2_debug_error("zephyr", "dup2 of stdout failed \n");
- exit(-1);
- }
- if (close(zephyr->fromtzc[1]) == -1) {
-- gaim_debug_error("zephyr", "closing of piped stdout failed\n");
-+ gaim2_debug_error("zephyr", "closing of piped stdout failed\n");
- exit(-1);
- }
- if (close(0) == -1) {
-- gaim_debug_error("zephyr", "stdin couldn't be closed. dying\n");
-+ gaim2_debug_error("zephyr", "stdin couldn't be closed. dying\n");
- exit(-1);
- }
- if (dup2(zephyr->totzc[0], 0) == -1) {
-- gaim_debug_error("zephyr", "dup2 of stdin failed \n");
-+ gaim2_debug_error("zephyr", "dup2 of stdin failed \n");
- exit(-1);
- }
- if (close(zephyr->totzc[0]) == -1) {
-- gaim_debug_error("zephyr", "closing of piped stdin failed\n");
-+ gaim2_debug_error("zephyr", "closing of piped stdin failed\n");
- exit(-1);
- }
- /* tzc_command should really be of the form
-@@ -1610,7 +1610,7 @@ static void zephyr_login(GaimAccount * a
- }
-
- if (!found_ps) {
-- gaim_connection_error(gc,"Tzc command needs %s to set the exposure\n");
-+ gaim2_connection_error(gc,"Tzc command needs %s to set the exposure\n");
- return;
- }
-
-@@ -1635,7 +1635,7 @@ static void zephyr_login(GaimAccount * a
- tv.tv_sec = 10;
- tv.tv_usec = 0;
-
-- gaim_debug_info("zephyr", "about to read from tzc\n");
-+ gaim2_debug_info("zephyr", "about to read from tzc\n");
-
- select(zephyr->fromtzc[ZEPHYR_FD_READ] + 1, &rfds, NULL, NULL, NULL);
-
-@@ -1667,7 +1667,7 @@ static void zephyr_login(GaimAccount * a
- ptr++;
- }
- if (ptr >=bufcur) {
-- gaim_connection_error(gc,"invalid output by tzc (or bad parsing code)");
-+ gaim2_connection_error(gc,"invalid output by tzc (or bad parsing code)");
- return;
- }
-
-@@ -1678,7 +1678,7 @@ static void zephyr_login(GaimAccount * a
- else if (*ptr == ')') {
- parenlevel--;
- }
-- gaim_debug_info("zephyr","tzc parenlevel is %d\n",parenlevel);
-+ gaim2_debug_info("zephyr","tzc parenlevel is %d\n",parenlevel);
- switch (parenlevel) {
- case 0:
- break;
-@@ -1688,7 +1688,7 @@ static void zephyr_login(GaimAccount * a
- while((*ptr != '(') && (*ptr != ')') && (ptr <bufcur))
- ptr++;
- if (ptr >= bufcur)
-- gaim_debug_error("zephyr","tzc parsing error\n");
-+ gaim2_debug_error("zephyr","tzc parsing error\n");
- break;
- case 2:
- /* You are probably at
-@@ -1709,7 +1709,7 @@ static void zephyr_login(GaimAccount * a
- ptr++;
- }
- }
-- gaim_debug_info("zephyr","tempstr parsed\n");
-+ gaim2_debug_info("zephyr","tempstr parsed\n");
- /* tempstr should now be a tempstridx length string containing all characters
- from that after the first ( to the one before the last paren ). */
- /* We should have the following possible lisp strings but we don't care
-@@ -1720,7 +1720,7 @@ static void zephyr_login(GaimAccount * a
- gchar* username = g_malloc0(100);
- int username_idx=0;
- char *realm;
-- gaim_debug_info("zephyr","zephyrid found\n");
-+ gaim2_debug_info("zephyr","zephyrid found\n");
- tempstridx+=8;
- while(tempstr[tempstridx] !='"' && tempstridx < 20000)
- tempstridx++;
-@@ -1732,7 +1732,7 @@ static void zephyr_login(GaimAccount * a
- if ((realm = strchr(username,'@')))
- zephyr->realm = g_strdup_printf("%s",realm+1);
- else {
-- realm = (gchar *)gaim_account_get_string(gc->account,"realm","");
-+ realm = (gchar *)gaim2_account_get_string(gc->account,"realm","");
- if (!*realm) {
- realm = "local-realm";
- }
-@@ -1745,21 +1745,21 @@ static void zephyr_login(GaimAccount * a
-
- g_free(username);
- } else {
-- gaim_debug_info("zephyr", "something that's not zephyr id found %s\n",tempstr);
-+ gaim2_debug_info("zephyr", "something that's not zephyr id found %s\n",tempstr);
- }
-
- /* We don't care about anything else yet */
- g_free(tempstr);
- break;
- default:
-- gaim_debug_info("zephyr","parenlevel is not 1 or 2\n");
-+ gaim2_debug_info("zephyr","parenlevel is not 1 or 2\n");
- /* This shouldn't be happening */
- break;
- }
- if (parenlevel==0)
- break;
- } /* while (ptr < bufcur) { */
-- gaim_debug_info("zephyr", "tzc startup done\n");
-+ gaim2_debug_info("zephyr", "tzc startup done\n");
- }
- }
- else if ( use_zeph02(zephyr)) {
-@@ -1768,7 +1768,7 @@ static void zephyr_login(GaimAccount * a
- z_call_s(ZOpenPort(&(zephyr->port)), "Couldn't open port");
- z_call_s(ZSetLocation((char *)zephyr->exposure), "Couldn't set location");
-
-- realm = (gchar *)gaim_account_get_string(gc->account,"realm","");
-+ realm = (gchar *)gaim2_account_get_string(gc->account,"realm","");
- if (!*realm) {
- realm = ZGetRealm();
- }
-@@ -1777,14 +1777,14 @@ static void zephyr_login(GaimAccount * a
- zephyr->username = g_strdup(ZGetSender());
-
- /* zephyr->realm = g_strdup(ZGetRealm()); */
-- gaim_debug_info("zephyr","realm: %s\n",zephyr->realm);
-+ gaim2_debug_info("zephyr","realm: %s\n",zephyr->realm);
- }
- else {
-- gaim_connection_error(gc,"Only ZEPH0.2 supported currently");
-+ gaim2_connection_error(gc,"Only ZEPH0.2 supported currently");
- return;
- }
-- gaim_debug_info("zephyr","does it get here\n");
-- gaim_debug_info("zephyr"," realm: %s username:%s\n", zephyr->realm, zephyr->username);
-+ gaim2_debug_info("zephyr","does it get here\n");
-+ gaim2_debug_info("zephyr"," realm: %s username:%s\n", zephyr->realm, zephyr->username);
-
- /* For now */
- zephyr->galaxy = NULL;
-@@ -1794,12 +1794,12 @@ static void zephyr_login(GaimAccount * a
- if (zephyr_subscribe_to(zephyr,"MESSAGE","PERSONAL",zephyr->username,NULL) != ZERR_NONE) {
- /* XXX don't translate this yet. It could be written better */
- /* XXX error messages could be handled with more detail */
-- gaim_notify_error(account->gc, NULL,
-+ gaim2_notify_error(account->gc, NULL,
- "Unable to subscribe to messages", "Unable to subscribe to initial messages");
- return;
- }
-
-- gaim_connection_set_state(gc, GAIM_CONNECTED);
-+ gaim2_connection_set_state(gc, GAIM_CONNECTED);
-
- if (read_anyone)
- process_anyone(gc);
-@@ -1807,11 +1807,11 @@ static void zephyr_login(GaimAccount * a
- process_zsubs(zephyr);
-
- if (use_zeph02(zephyr)) {
-- zephyr->nottimer = gaim_timeout_add(100, check_notify_zeph02, gc);
-+ zephyr->nottimer = gaim2_timeout_add(100, check_notify_zeph02, gc);
- } else if (use_tzc(zephyr)) {
-- zephyr->nottimer = gaim_timeout_add(100, check_notify_tzc, gc);
-+ zephyr->nottimer = gaim2_timeout_add(100, check_notify_tzc, gc);
- }
-- zephyr->loctimer = gaim_timeout_add(20000, check_loc, gc);
-+ zephyr->loctimer = gaim2_timeout_add(20000, check_loc, gc);
-
- }
-
-@@ -1829,7 +1829,7 @@ static void write_zsubs(zephyr_account *
-
- char **triple;
-
-- fname = g_strdup_printf("%s/.zephyr.subs", gaim_home_dir());
-+ fname = g_strdup_printf("%s/.zephyr.subs", gaim2_home_dir());
- fd = g_fopen(fname, "w");
-
- if (!fd) {
-@@ -1884,21 +1884,21 @@ static void write_zsubs(zephyr_account *
- fclose(fd);
- }
-
--static void write_anyone(GaimConnection *gc)
-+static void write_anyone(Gaim2Connection *gc)
- {
-- GaimBlistNode *gnode, *cnode, *bnode;
-- GaimBuddy *b;
-+ Gaim2BlistNode *gnode, *cnode, *bnode;
-+ Gaim2Buddy *b;
- char *fname;
- FILE *fd;
- zephyr_account* zephyr = gc->proto_data;
-- fname = g_strdup_printf("%s/.anyone", gaim_home_dir());
-+ fname = g_strdup_printf("%s/.anyone", gaim2_home_dir());
- fd = g_fopen(fname, "w");
- if (!fd) {
- g_free(fname);
- return;
- }
-
-- for (gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for (gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- if (!GAIM_BLIST_NODE_IS_GROUP(gnode))
- continue;
- for (cnode = gnode->child; cnode; cnode = cnode->next) {
-@@ -1907,7 +1907,7 @@ static void write_anyone(GaimConnection
- for (bnode = cnode->child; bnode; bnode = bnode->next) {
- if (!GAIM_BLIST_NODE_IS_BUDDY(bnode))
- continue;
-- b = (GaimBuddy *) bnode;
-+ b = (Gaim2Buddy *) bnode;
- if (b->account == gc->account) {
- gchar *stripped_user = zephyr_strip_local_realm(zephyr,b->name);
- fprintf(fd, "%s\n", stripped_user);
-@@ -1921,7 +1921,7 @@ static void write_anyone(GaimConnection
- g_free(fname);
- }
-
--static void zephyr_close(GaimConnection * gc)
-+static void zephyr_close(Gaim2Connection * gc)
- {
- GList *l;
- GSList *s;
-@@ -1935,10 +1935,10 @@ static void zephyr_close(GaimConnection
- }
- g_list_free(zephyr->pending_zloc_names);
-
-- if (gaim_account_get_bool(gc->account, "write_anyone", FALSE))
-+ if (gaim2_account_get_bool(gc->account, "write_anyone", FALSE))
- write_anyone(gc);
-
-- if (gaim_account_get_bool(gc->account, "write_zsubs", FALSE))
-+ if (gaim2_account_get_bool(gc->account, "write_zsubs", FALSE))
- write_zsubs(gc->proto_data);
-
- s = zephyr->subscrips;
-@@ -1949,10 +1949,10 @@ static void zephyr_close(GaimConnection
- g_slist_free(zephyr->subscrips);
-
- if (zephyr->nottimer)
-- gaim_timeout_remove(zephyr->nottimer);
-+ gaim2_timeout_remove(zephyr->nottimer);
- zephyr->nottimer = 0;
- if (zephyr->loctimer)
-- gaim_timeout_remove(zephyr->loctimer);
-+ gaim2_timeout_remove(zephyr->loctimer);
- zephyr->loctimer = 0;
- gc = NULL;
- if (use_zeph02(zephyr)) {
-@@ -1964,16 +1964,16 @@ static void zephyr_close(GaimConnection
- if (kill(tzc_pid,SIGTERM) == -1) {
- int err=errno;
- if (err==EINVAL) {
-- gaim_debug_error("zephyr","An invalid signal was specified when killing tzc\n");
-+ gaim2_debug_error("zephyr","An invalid signal was specified when killing tzc\n");
- }
- else if (err==ESRCH) {
-- gaim_debug_error("zephyr","Tzc's pid didn't exist while killing tzc\n");
-+ gaim2_debug_error("zephyr","Tzc's pid didn't exist while killing tzc\n");
- }
- else if (err==EPERM) {
-- gaim_debug_error("zephyr","gaim didn't have permission to kill tzc\n");
-+ gaim2_debug_error("zephyr","gaim2 didn't have permission to kill tzc\n");
- }
- else {
-- gaim_debug_error("zephyr","miscellaneous error while attempting to close tzc\n");
-+ gaim2_debug_error("zephyr","miscellaneous error while attempting to close tzc\n");
- }
- }
- }
-@@ -1992,12 +1992,12 @@ static const char * zephyr_get_signature
- return sig;
- }
-
--static int zephyr_chat_send(GaimConnection * gc, int id, const char *im, GaimMessageFlags flags)
-+static int zephyr_chat_send(Gaim2Connection * gc, int id, const char *im, Gaim2MessageFlags flags)
- {
- zephyr_triple *zt;
- const char *sig;
-- GaimConversation *gconv1;
-- GaimConvChat *gcc;
-+ Gaim2Conversation *gconv1;
-+ Gaim2ConvChat *gcc;
- char *inst;
- char *recipient;
- zephyr_account *zephyr = gc->proto_data;
-@@ -2009,11 +2009,11 @@ static int zephyr_chat_send(GaimConnecti
-
- sig = zephyr_get_signature();
-
-- gconv1 = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, zt->name,
-+ gconv1 = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, zt->name,
- gc->account);
-- gcc = gaim_conversation_get_chat_data(gconv1);
-+ gcc = gaim2_conversation_get_chat_data(gconv1);
-
-- if (!(inst = (char *)gaim_conv_chat_get_topic(gcc)))
-+ if (!(inst = (char *)gaim2_conv_chat_get_topic(gcc)))
- inst = g_strdup("PERSONAL");
-
- if (!g_ascii_strcasecmp(zt->recipient, "*"))
-@@ -2026,7 +2026,7 @@ static int zephyr_chat_send(GaimConnecti
- }
-
-
--static int zephyr_send_im(GaimConnection * gc, const char *who, const char *im, GaimMessageFlags flags)
-+static int zephyr_send_im(Gaim2Connection * gc, const char *who, const char *im, Gaim2MessageFlags flags)
- {
- const char *sig;
- zephyr_account *zephyr = gc->proto_data;
-@@ -2114,7 +2114,7 @@ static int zephyr_send_message(zephyr_ac
- char *html_buf;
- char *html_buf2;
- html_buf = html_to_zephyr(im);
-- html_buf2 = gaim_unescape_html(html_buf);
-+ html_buf2 = gaim2_unescape_html(html_buf);
-
- if(use_tzc(zephyr)) {
- char* zsendstr;
-@@ -2142,12 +2142,12 @@ static int zephyr_send_message(zephyr_ac
- notice.z_message_len = strlen(html_buf2) + strlen(sig) + 2;
- notice.z_message = buf;
- notice.z_opcode = g_strdup(opcode);
-- gaim_debug_info("zephyr","About to send notice");
-+ gaim2_debug_info("zephyr","About to send notice");
- if (! ZSendNotice(&notice, ZAUTH) == ZERR_NONE) {
- /* XXX handle errors here */
- return 0;
- }
-- gaim_debug_info("zephyr","notice sent");
-+ gaim2_debug_info("zephyr","notice sent");
- g_free(buf);
- }
-
-@@ -2176,7 +2176,7 @@ char *local_zephyr_normalize(zephyr_acco
- return buf;
- }
-
--static void zephyr_zloc(GaimConnection *gc, const char *who)
-+static void zephyr_zloc(Gaim2Connection *gc, const char *who)
- {
- ZAsyncLocateData_t ald;
- zephyr_account *zephyr = gc->proto_data;
-@@ -2197,9 +2197,9 @@ static void zephyr_zloc(GaimConnection *
- }
- }
-
--static void zephyr_set_status(GaimAccount *account, GaimStatus *status) {
-- zephyr_account *zephyr = gaim_account_get_connection(account)->proto_data;
-- GaimStatusPrimitive primitive = gaim_status_type_get_primitive(gaim_status_get_type(status));
-+static void zephyr_set_status(Gaim2Account *account, Gaim2Status *status) {
-+ zephyr_account *zephyr = gaim2_account_get_connection(account)->proto_data;
-+ Gaim2StatusPrimitive primitive = gaim2_status_type_get_primitive(gaim2_status_get_type(status));
-
- if (zephyr->away) {
- g_free(zephyr->away);
-@@ -2207,7 +2207,7 @@ static void zephyr_set_status(GaimAccoun
- }
-
- if (primitive == GAIM_STATUS_AWAY) {
-- zephyr->away = g_strdup(gaim_status_get_attr_string(status,"message"));
-+ zephyr->away = g_strdup(gaim2_status_get_attr_string(status,"message"));
- }
- else if (primitive == GAIM_STATUS_AVAILABLE) {
- if (use_zeph02(zephyr)) {
-@@ -2231,9 +2231,9 @@ static void zephyr_set_status(GaimAccoun
- }
- }
-
--static GList *zephyr_status_types(GaimAccount *account)
-+static GList *zephyr_status_types(Gaim2Account *account)
- {
-- GaimStatusType *type;
-+ Gaim2StatusType *type;
- GList *types = NULL;
-
- /* zephyr has several exposures
-@@ -2250,25 +2250,25 @@ static GList *zephyr_status_types(GaimAc
- Away won't change their exposure but will set an auto away message (for IMs only)
- */
-
-- type = gaim_status_type_new(GAIM_STATUS_AVAILABLE, NULL, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_AVAILABLE, NULL, NULL, TRUE);
- types = g_list_append(types,type);
-
-- type = gaim_status_type_new(GAIM_STATUS_INVISIBLE, NULL, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_INVISIBLE, NULL, NULL, TRUE);
- types = g_list_append(types,type);
-
-- type = gaim_status_type_new_with_attrs(
-+ type = gaim2_status_type_new_with_attrs(
- GAIM_STATUS_AWAY, NULL, NULL, TRUE, TRUE, FALSE,
-- "message", _("Message"), gaim_value_new(GAIM_TYPE_STRING),
-+ "message", _("Message"), gaim2_value_new(GAIM_TYPE_STRING),
- NULL);
- types = g_list_append(types, type);
-
-- type = gaim_status_type_new(GAIM_STATUS_OFFLINE, NULL, NULL, TRUE);
-+ type = gaim2_status_type_new(GAIM_STATUS_OFFLINE, NULL, NULL, TRUE);
- types = g_list_append(types,type);
-
- return types;
- }
-
--static GList *zephyr_chat_info(GaimConnection * gc)
-+static GList *zephyr_chat_info(Gaim2Connection * gc)
- {
- GList *m = NULL;
- struct proto_chat_entry *pce;
-@@ -2296,10 +2296,10 @@ static GList *zephyr_chat_info(GaimConne
-
- /* Called when the server notifies us a message couldn't get sent */
-
--static void zephyr_subscribe_failed(GaimConnection *gc,char * z_class, char *z_instance, char * z_recipient, char* z_galaxy)
-+static void zephyr_subscribe_failed(Gaim2Connection *gc,char * z_class, char *z_instance, char * z_recipient, char* z_galaxy)
- {
- gchar* subscribe_failed = g_strdup_printf(_("Attempt to subscribe to %s,%s,%s failed"), z_class, z_instance,z_recipient);
-- gaim_notify_error(gc,"", subscribe_failed, NULL);
-+ gaim2_notify_error(gc,"", subscribe_failed, NULL);
- g_free(subscribe_failed);
- }
-
-@@ -2317,7 +2317,7 @@ static char *zephyr_get_chat_name(GHashT
- }
-
-
--static void zephyr_join_chat(GaimConnection * gc, GHashTable * data)
-+static void zephyr_join_chat(Gaim2Connection * gc, GHashTable * data)
- {
- /* ZSubscription_t sub; */
- zephyr_triple *zt1, *zt2;
-@@ -2384,7 +2384,7 @@ static void zephyr_join_chat(GaimConnect
- zephyr_chat_set_topic(gc,zt1->id,instname);
- }
-
--static void zephyr_chat_leave(GaimConnection * gc, int id)
-+static void zephyr_chat_leave(Gaim2Connection * gc, int id)
- {
- zephyr_triple *zt;
- zephyr_account *zephyr = gc->proto_data;
-@@ -2396,14 +2396,14 @@ static void zephyr_chat_leave(GaimConnec
- }
- }
-
--static GaimChat *zephyr_find_blist_chat(GaimAccount *account, const char *name)
-+static Gaim2Chat *zephyr_find_blist_chat(Gaim2Account *account, const char *name)
- {
-- GaimBlistNode *gnode, *cnode;
-+ Gaim2BlistNode *gnode, *cnode;
-
- /* XXX needs to be %host%,%canon%, and %me% clean */
-- for(gnode = gaim_get_blist()->root; gnode; gnode = gnode->next) {
-+ for(gnode = gaim2_get_blist()->root; gnode; gnode = gnode->next) {
- for(cnode = gnode->child; cnode; cnode = cnode->next) {
-- GaimChat *chat = (GaimChat*)cnode;
-+ Gaim2Chat *chat = (Gaim2Chat*)cnode;
- char *zclass, *inst, *recip;
- char** triple;
- if(!GAIM_BLIST_NODE_IS_CHAT(cnode))
-@@ -2416,7 +2416,7 @@ static GaimChat *zephyr_find_blist_chat(
- inst = g_strdup("");
- if(!(recip = g_hash_table_lookup(chat->components, "recipient")))
- recip = g_strdup("");
-- /* gaim_debug_info("zephyr","in zephyr_find_blist_chat name: %s\n",name?name:""); */
-+ /* gaim2_debug_info("zephyr","in zephyr_find_blist_chat name: %s\n",name?name:""); */
- triple = g_strsplit(name,",",3);
- if (!g_ascii_strcasecmp(triple[0],zclass) && !g_ascii_strcasecmp(triple[1],inst) && !g_ascii_strcasecmp(triple[2],recip))
- return chat;
-@@ -2425,12 +2425,12 @@ static GaimChat *zephyr_find_blist_chat(
- }
- return NULL;
- }
--static const char *zephyr_list_icon(GaimAccount * a, GaimBuddy * b)
-+static const char *zephyr_list_icon(Gaim2Account * a, Gaim2Buddy * b)
- {
- return "zephyr";
- }
-
--static int zephyr_send_typing(GaimConnection *gc, const char *who, int typing) {
-+static int zephyr_send_typing(Gaim2Connection *gc, const char *who, int typing) {
- gchar *recipient;
- zephyr_account *zephyr = gc->proto_data;
- if (use_tzc(zephyr))
-@@ -2440,7 +2440,7 @@ static int zephyr_send_typing(GaimConnec
- return 0;
- /* XXX We probably should care if this fails. Or maybe we don't want to */
- if (!who) {
-- gaim_debug_info("zephyr", "who is null\n");
-+ gaim2_debug_info("zephyr", "who is null\n");
- recipient = local_zephyr_normalize(zephyr,"");
- } else {
- char *comma = strrchr(who, ',');
-@@ -2453,19 +2453,19 @@ static int zephyr_send_typing(GaimConnec
- recipient = local_zephyr_normalize(zephyr,who);
- }
-
-- gaim_debug_info("zephyr","about to send typing notification to %s\n",recipient);
-+ gaim2_debug_info("zephyr","about to send typing notification to %s\n",recipient);
- zephyr_send_message(zephyr,"MESSAGE","PERSONAL",recipient,"","","PING");
-- gaim_debug_info("zephyr","sent typing notification\n");
-+ gaim2_debug_info("zephyr","sent typing notification\n");
- return ZEPHYR_TYPING_SEND_TIMEOUT;
- }
-
-
-
--static void zephyr_chat_set_topic(GaimConnection * gc, int id, const char *topic)
-+static void zephyr_chat_set_topic(Gaim2Connection * gc, int id, const char *topic)
- {
- zephyr_triple *zt;
-- GaimConversation *gconv;
-- GaimConvChat *gcc;
-+ Gaim2Conversation *gconv;
-+ Gaim2ConvChat *gcc;
- gchar *topic_utf8;
- zephyr_account* zephyr = gc->proto_data;
- char *sender = (char *)zephyr->username;
-@@ -2474,23 +2474,23 @@ static void zephyr_chat_set_topic(GaimCo
- /* find_sub_by_id can return NULL */
- if (!zt)
- return;
-- gconv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, zt->name,
-+ gconv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_CHAT, zt->name,
- gc->account);
-- gcc = gaim_conversation_get_chat_data(gconv);
-+ gcc = gaim2_conversation_get_chat_data(gconv);
-
- topic_utf8 = zephyr_recv_convert(gc,(gchar *)topic,strlen(topic));
-- gaim_conv_chat_set_topic(gcc,sender,topic_utf8);
-+ gaim2_conv_chat_set_topic(gcc,sender,topic_utf8);
- g_free(topic_utf8);
- return;
- }
-
- /* commands */
-
--static GaimCmdRet zephyr_gaim_cmd_msg(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_msg(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- char *recipient;
-- zephyr_account *zephyr = gaim_conversation_get_gc(conv)->proto_data;
-+ zephyr_account *zephyr = gaim2_conversation_get_gc(conv)->proto_data;
- if (!g_ascii_strcasecmp(args[0],"*"))
- return GAIM_CMD_RET_FAILED; /* "*" is not a valid argument */
- else
-@@ -2505,28 +2505,28 @@ static GaimCmdRet zephyr_gaim_cmd_msg(Ga
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_zlocate(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_zlocate(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
-- zephyr_zloc(gaim_conversation_get_gc(conv),args[0]);
-+ zephyr_zloc(gaim2_conversation_get_gc(conv),args[0]);
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_instance(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_instance(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* Currently it sets the instance with leading spaces and
- * all. This might not be the best thing to do, though having
- * one word isn't ideal either. */
-
-- GaimConvChat *gcc = gaim_conversation_get_chat_data(conv);
-+ Gaim2ConvChat *gcc = gaim2_conversation_get_chat_data(conv);
- int id = gcc->id;
- const char* instance = args[0];
-- zephyr_chat_set_topic(gaim_conversation_get_gc(conv),id,instance);
-+ zephyr_chat_set_topic(gaim2_conversation_get_gc(conv),id,instance);
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_joinchat_cir(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_joinchat_cir(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* Join a new zephyr chat */
-@@ -2534,59 +2534,59 @@ static GaimCmdRet zephyr_gaim_cmd_joinch
- g_hash_table_insert(triple,"class",args[0]);
- g_hash_table_insert(triple,"instance",args[1]);
- g_hash_table_insert(triple,"recipient",args[2]);
-- zephyr_join_chat(gaim_conversation_get_gc(conv),triple);
-+ zephyr_join_chat(gaim2_conversation_get_gc(conv),triple);
- return GAIM_CMD_RET_OK;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_zi(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_zi(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* args = instance, message */
-- zephyr_account *zephyr = gaim_conversation_get_gc(conv)->proto_data;
-+ zephyr_account *zephyr = gaim2_conversation_get_gc(conv)->proto_data;
- if ( zephyr_send_message(zephyr,"message",args[0],"",args[1],zephyr_get_signature(),""))
- return GAIM_CMD_RET_OK;
- else
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_zci(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_zci(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* args = class, instance, message */
-- zephyr_account *zephyr = gaim_conversation_get_gc(conv)->proto_data;
-+ zephyr_account *zephyr = gaim2_conversation_get_gc(conv)->proto_data;
- if ( zephyr_send_message(zephyr,args[0],args[1],"",args[2],zephyr_get_signature(),""))
- return GAIM_CMD_RET_OK;
- else
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_zcir(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_zcir(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* args = class, instance, recipient, message */
-- zephyr_account *zephyr = gaim_conversation_get_gc(conv)->proto_data;
-+ zephyr_account *zephyr = gaim2_conversation_get_gc(conv)->proto_data;
- if ( zephyr_send_message(zephyr,args[0],args[1],args[2],args[3],zephyr_get_signature(),""))
- return GAIM_CMD_RET_OK;
- else
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_zir(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_zir(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* args = instance, recipient, message */
-- zephyr_account *zephyr = gaim_conversation_get_gc(conv)->proto_data;
-+ zephyr_account *zephyr = gaim2_conversation_get_gc(conv)->proto_data;
- if ( zephyr_send_message(zephyr,"message",args[0],args[1],args[2],zephyr_get_signature(),""))
- return GAIM_CMD_RET_OK;
- else
- return GAIM_CMD_RET_FAILED;
- }
-
--static GaimCmdRet zephyr_gaim_cmd_zc(GaimConversation *conv,
-+static Gaim2CmdRet zephyr_gaim2_cmd_zc(Gaim2Conversation *conv,
- const char *cmd, char **args, char **error, void *data)
- {
- /* args = class, message */
-- zephyr_account *zephyr = gaim_conversation_get_gc(conv)->proto_data;
-+ zephyr_account *zephyr = gaim2_conversation_get_gc(conv)->proto_data;
- if ( zephyr_send_message(zephyr,args[0],"PERSONAL","",args[1],zephyr_get_signature(),""))
- return GAIM_CMD_RET_OK;
- else
-@@ -2596,104 +2596,104 @@ static GaimCmdRet zephyr_gaim_cmd_zc(Gai
- static void zephyr_register_slash_commands()
- {
-
-- gaim_cmd_register("msg","ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("msg","ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_msg, _("msg &lt;nick&gt; &lt;message&gt;: Send a private message to a user"), NULL);
-+ zephyr_gaim2_cmd_msg, _("msg &lt;nick&gt; &lt;message&gt;: Send a private message to a user"), NULL);
-
-- gaim_cmd_register("zlocate","w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zlocate","w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zlocate, _("zlocate &lt;nick&gt;: Locate user"), NULL);
-+ zephyr_gaim2_cmd_zlocate, _("zlocate &lt;nick&gt;: Locate user"), NULL);
-
-- gaim_cmd_register("zl","w", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zl","w", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zlocate, _("zl &lt;nick&gt;: Locate user"), NULL);
-+ zephyr_gaim2_cmd_zlocate, _("zl &lt;nick&gt;: Locate user"), NULL);
-
-- gaim_cmd_register("instance","s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("instance","s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_instance, _("instance &lt;instance&gt;: Set the instance to be used on this class"), NULL);
-+ zephyr_gaim2_cmd_instance, _("instance &lt;instance&gt;: Set the instance to be used on this class"), NULL);
-
-- gaim_cmd_register("inst","s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("inst","s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_instance, _("inst &lt;instance&gt;: Set the instance to be used on this class"), NULL);
-+ zephyr_gaim2_cmd_instance, _("inst &lt;instance&gt;: Set the instance to be used on this class"), NULL);
-
-- gaim_cmd_register("topic","s", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("topic","s", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_instance, _("topic &lt;instance&gt;: Set the instance to be used on this class"), NULL);
-+ zephyr_gaim2_cmd_instance, _("topic &lt;instance&gt;: Set the instance to be used on this class"), NULL);
-
-- gaim_cmd_register("sub", "www", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("sub", "www", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_joinchat_cir,
-+ zephyr_gaim2_cmd_joinchat_cir,
- _("sub &lt;class&gt; &lt;instance&gt; &lt;recipient&gt;: Join a new chat"), NULL);
-
-- gaim_cmd_register("zi","ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zi","ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zi, _("zi &lt;instance&gt;: Send a message to &lt;message,<i>instance</i>,*&gt;"), NULL);
-+ zephyr_gaim2_cmd_zi, _("zi &lt;instance&gt;: Send a message to &lt;message,<i>instance</i>,*&gt;"), NULL);
-
-- gaim_cmd_register("zci","wws",GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zci","wws",GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zci,
-+ zephyr_gaim2_cmd_zci,
- _("zci &lt;class&gt; &lt;instance&gt;: Send a message to &lt;<i>class</i>,<i>instance</i>,*&gt;"), NULL);
-
-- gaim_cmd_register("zcir","wwws",GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zcir","wwws",GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zcir,
-+ zephyr_gaim2_cmd_zcir,
- _("zcir &lt;class&gt; &lt;instance&gt; &lt;recipient&gt;: Send a message to &lt;<i>class</i>,<i>instance</i>,<i>recipient</i>&gt;"), NULL);
-
-- gaim_cmd_register("zir","wws",GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zir","wws",GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zir,
-+ zephyr_gaim2_cmd_zir,
- _("zir &lt;instance&gt; &lt;recipient&gt;: Send a message to &lt;MESSAGE,<i>instance</i>,<i>recipient</i>&gt;"), NULL);
-
-- gaim_cmd_register("zc","ws", GAIM_CMD_P_PRPL,
-+ gaim2_cmd_register("zc","ws", GAIM_CMD_P_PRPL,
- GAIM_CMD_FLAG_IM | GAIM_CMD_FLAG_CHAT | GAIM_CMD_FLAG_PRPL_ONLY,
- "prpl-zephyr",
-- zephyr_gaim_cmd_zc, _("zc &lt;class&gt;: Send a message to &lt;<i>class</i>,PERSONAL,*&gt;"), NULL);
-+ zephyr_gaim2_cmd_zc, _("zc &lt;class&gt;: Send a message to &lt;<i>class</i>,PERSONAL,*&gt;"), NULL);
-
- }
-
-
- static void
--zephyr_add_deny(GaimConnection *gc, const char *who)
-+zephyr_add_deny(Gaim2Connection *gc, const char *who)
- {
-- gaim_privacy_deny_add(gc->account,who,1);
-+ gaim2_privacy_deny_add(gc->account,who,1);
- }
-
- static void
--zephyr_remove_deny(GaimConnection *gc, const char *who)
-+zephyr_remove_deny(Gaim2Connection *gc, const char *who)
- {
-- gaim_privacy_deny_remove(gc->account,who,1);
-+ gaim2_privacy_deny_remove(gc->account,who,1);
- }
-
- static void
--zephyr_add_permit(GaimConnection *gc, const char *who)
-+zephyr_add_permit(Gaim2Connection *gc, const char *who)
- {
-- gaim_privacy_permit_add(gc->account,who,1);
-+ gaim2_privacy_permit_add(gc->account,who,1);
- }
-
- static void
--zephyr_remove_permit(GaimConnection *gc, const char *who)
-+zephyr_remove_permit(Gaim2Connection *gc, const char *who)
- {
-- gaim_privacy_permit_remove(gc->account,who,1);
-+ gaim2_privacy_permit_remove(gc->account,who,1);
- }
-
- static void
--zephyr_set_permit_deny(GaimConnection *gc)
-+zephyr_set_permit_deny(Gaim2Connection *gc)
- {
- /* This doesn't have to do anything, since really, we can just check account->perm_deny when deciding whether to di */
- return;
- }
--static int zephyr_resubscribe(GaimConnection *gc)
-+static int zephyr_resubscribe(Gaim2Connection *gc)
- {
- /* Resubscribe to the in-memory list of subscriptions and also
- unsubscriptions*/
-@@ -2711,17 +2711,17 @@ static int zephyr_resubscribe(GaimConnec
- }
-
-
--static void zephyr_action_resubscribe(GaimPluginAction *action)
-+static void zephyr_action_resubscribe(Gaim2PluginAction *action)
- {
-
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- zephyr_resubscribe(gc);
- }
-
-
--static void zephyr_action_get_subs_from_server(GaimPluginAction *action)
-+static void zephyr_action_get_subs_from_server(Gaim2PluginAction *action)
- {
-- GaimConnection *gc = (GaimConnection *) action->context;
-+ Gaim2Connection *gc = (Gaim2Connection *) action->context;
- zephyr_account *zephyr = gc->proto_data;
- gchar *title;
- int retval, nsubs, one,i;
-@@ -2732,50 +2732,50 @@ static void zephyr_action_get_subs_from_
- title = g_strdup_printf("Server subscriptions for %s", zephyr->username);
-
- if (zephyr->port == 0) {
-- gaim_debug_error("zephyr", "error while retrieving port");
-+ gaim2_debug_error("zephyr", "error while retrieving port");
- return;
- }
- if ((retval = ZRetrieveSubscriptions(zephyr->port,&nsubs)) != ZERR_NONE) {
- /* XXX better error handling */
-- gaim_debug_error("zephyr", "error while retrieving subscriptions from server");
-+ gaim2_debug_error("zephyr", "error while retrieving subscriptions from server");
- return;
- }
- for(i=0;i<nsubs;i++) {
- one = 1;
- if ((retval = ZGetSubscriptions(&subs,&one)) != ZERR_NONE) {
- /* XXX better error handling */
-- gaim_debug_error("zephyr", "error while retrieving individual subscription");
-+ gaim2_debug_error("zephyr", "error while retrieving individual subscription");
- return;
- }
- g_string_append_printf(subout, "Class %s Instance %s Recipient %s<br>",
- subs.zsub_class, subs.zsub_classinst,
- subs.zsub_recipient);
- }
-- gaim_notify_formatted(gc, title, title, NULL, subout->str, NULL, NULL);
-+ gaim2_notify_formatted(gc, title, title, NULL, subout->str, NULL, NULL);
- } else {
- /* XXX fix */
-- gaim_notify_error(gc,"","tzc doesn't support this action",NULL);
-+ gaim2_notify_error(gc,"","tzc doesn't support this action",NULL);
- }
- }
-
-
--static GList *zephyr_actions(GaimPlugin *plugin, gpointer context)
-+static GList *zephyr_actions(Gaim2Plugin *plugin, gpointer context)
- {
- GList *list = NULL;
-- GaimPluginAction *act = NULL;
-+ Gaim2PluginAction *act = NULL;
-
-- act = gaim_plugin_action_new(_("Resubscribe"), zephyr_action_resubscribe);
-+ act = gaim2_plugin_action_new(_("Resubscribe"), zephyr_action_resubscribe);
- list = g_list_append(list, act);
-
-- act = gaim_plugin_action_new(_("Retrieve subscriptions from server"), zephyr_action_get_subs_from_server);
-+ act = gaim2_plugin_action_new(_("Retrieve subscriptions from server"), zephyr_action_get_subs_from_server);
- list = g_list_append(list,act);
-
- return list;
- }
-
--static GaimPlugin *my_protocol = NULL;
-+static Gaim2Plugin *my_protocol = NULL;
-
--static GaimPluginProtocolInfo prpl_info = {
-+static Gaim2PluginProtocolInfo prpl_info = {
- OPT_PROTO_CHAT_TOPIC | OPT_PROTO_NO_PASSWORD,
- NULL, /* ??? user_splits */
- NULL, /* ??? protocol_options */
-@@ -2839,7 +2839,7 @@ static GaimPluginProtocolInfo prpl_info
- NULL, /* media_prpl_ops */
- };
-
--static GaimPluginInfo info = {
-+static Gaim2PluginInfo info = {
- GAIM_PLUGIN_MAGIC,
- GAIM_MAJOR_VERSION,
- GAIM_MINOR_VERSION,
-@@ -2869,36 +2869,36 @@ static GaimPluginInfo info = {
- zephyr_actions
- };
-
--static void init_plugin(GaimPlugin * plugin)
-+static void init_plugin(Gaim2Plugin * plugin)
- {
-- GaimAccountOption *option;
-+ Gaim2AccountOption *option;
- char *tmp = get_exposure_level();
-
-- option = gaim_account_option_bool_new("Use tzc", "use_tzc", FALSE);
-+ option = gaim2_account_option_bool_new("Use tzc", "use_tzc", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new("tzc command", "tzc_command", "/usr/bin/tzc -e %s");
-+ option = gaim2_account_option_string_new("tzc command", "tzc_command", "/usr/bin/tzc -e %s");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_bool_new(_("Export to .anyone"), "write_anyone", FALSE);
-+ option = gaim2_account_option_bool_new(_("Export to .anyone"), "write_anyone", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_bool_new(_("Export to .zephyr.subs"), "write_zsubs", FALSE);
-+ option = gaim2_account_option_bool_new(_("Export to .zephyr.subs"), "write_zsubs", FALSE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_bool_new(_("Import from .anyone"), "read_anyone", TRUE);
-+ option = gaim2_account_option_bool_new(_("Import from .anyone"), "read_anyone", TRUE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_bool_new(_("Import from .zephyr.subs"), "read_zsubs", TRUE);
-+ option = gaim2_account_option_bool_new(_("Import from .zephyr.subs"), "read_zsubs", TRUE);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Realm"), "realm", "");
-+ option = gaim2_account_option_string_new(_("Realm"), "realm", "");
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Exposure"), "exposure_level", tmp?tmp: EXPOSE_REALMVIS);
-+ option = gaim2_account_option_string_new(_("Exposure"), "exposure_level", tmp?tmp: EXPOSE_REALMVIS);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
-- option = gaim_account_option_string_new(_("Encoding"), "encoding", ZEPHYR_FALLBACK_CHARSET);
-+ option = gaim2_account_option_string_new(_("Encoding"), "encoding", ZEPHYR_FALLBACK_CHARSET);
- prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option);
-
- my_protocol = plugin;
-diff -prNu ./src/protocols/zephyr/ZLocations.c ./src/protocols/zephyr/ZLocations.c
---- ./src/protocols/zephyr/ZLocations.c 2005-07-14 04:19:00.000000000 +0200
-+++ ./src/protocols/zephyr/ZLocations.c 2006-01-05 15:11:07.000000000 +0100
-@@ -91,7 +91,7 @@ Code_t Z_SendLocation(class, opcode, aut
- } else {
- #endif
- #ifdef WIN32
-- strncpy(mytty, "WinGaim", sizeof(mytty));
-+ strncpy(mytty, "WinGaim2", sizeof(mytty));
- #else
- ttyp = ttyname(0);
- if (ttyp && *ttyp) {
-diff -prNu ./src/protocols/zephyr/ZVariables.c ./src/protocols/zephyr/ZVariables.c
---- ./src/protocols/zephyr/ZVariables.c 2005-07-14 04:19:01.000000000 +0200
-+++ ./src/protocols/zephyr/ZVariables.c 2006-01-05 15:11:07.000000000 +0100
-@@ -116,7 +116,7 @@ static int get_localvarfile(bfr)
- const char *envptr;
- #ifndef WIN32
- struct passwd *pwd;
-- envptr = gaim_home_dir();
-+ envptr = gaim2_home_dir();
- #else
- envptr = getenv("HOME");
- if (!envptr)
-diff -prNu ./src/proxy.c ./src/proxy.c
---- ./src/proxy.c 2005-12-09 08:26:29.000000000 +0100
-+++ ./src/proxy.c 2006-01-05 15:11:07.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file proxy.c Proxy API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -38,16 +38,16 @@
- #include "proxy.h"
- #include "util.h"
-
--static GaimProxyInfo *global_proxy_info = NULL;
-+static Gaim2ProxyInfo *global_proxy_info = NULL;
-
- struct PHB {
-- GaimInputFunction func;
-+ Gaim2InputFunction func;
- gpointer data;
- char *host;
- int port;
- gint inpa;
-- GaimProxyInfo *gpi;
-- GaimAccount *account;
-+ Gaim2ProxyInfo *gpi;
-+ Gaim2Account *account;
- GSList *hosts;
- };
-
-@@ -68,14 +68,14 @@ static const char *socks5errors[] = {
- /**************************************************************************
- * Proxy structure API
- **************************************************************************/
--GaimProxyInfo *
--gaim_proxy_info_new(void)
-+Gaim2ProxyInfo *
-+gaim2_proxy_info_new(void)
- {
-- return g_new0(GaimProxyInfo, 1);
-+ return g_new0(Gaim2ProxyInfo, 1);
- }
-
- void
--gaim_proxy_info_destroy(GaimProxyInfo *info)
-+gaim2_proxy_info_destroy(Gaim2ProxyInfo *info)
- {
- g_return_if_fail(info != NULL);
-
-@@ -87,7 +87,7 @@ gaim_proxy_info_destroy(GaimProxyInfo *i
- }
-
- void
--gaim_proxy_info_set_type(GaimProxyInfo *info, GaimProxyType type)
-+gaim2_proxy_info_set_type(Gaim2ProxyInfo *info, Gaim2ProxyType type)
- {
- g_return_if_fail(info != NULL);
-
-@@ -95,7 +95,7 @@ gaim_proxy_info_set_type(GaimProxyInfo *
- }
-
- void
--gaim_proxy_info_set_host(GaimProxyInfo *info, const char *host)
-+gaim2_proxy_info_set_host(Gaim2ProxyInfo *info, const char *host)
- {
- g_return_if_fail(info != NULL);
-
-@@ -106,7 +106,7 @@ gaim_proxy_info_set_host(GaimProxyInfo *
- }
-
- void
--gaim_proxy_info_set_port(GaimProxyInfo *info, int port)
-+gaim2_proxy_info_set_port(Gaim2ProxyInfo *info, int port)
- {
- g_return_if_fail(info != NULL);
-
-@@ -114,7 +114,7 @@ gaim_proxy_info_set_port(GaimProxyInfo *
- }
-
- void
--gaim_proxy_info_set_username(GaimProxyInfo *info, const char *username)
-+gaim2_proxy_info_set_username(Gaim2ProxyInfo *info, const char *username)
- {
- g_return_if_fail(info != NULL);
-
-@@ -125,7 +125,7 @@ gaim_proxy_info_set_username(GaimProxyIn
- }
-
- void
--gaim_proxy_info_set_password(GaimProxyInfo *info, const char *password)
-+gaim2_proxy_info_set_password(Gaim2ProxyInfo *info, const char *password)
- {
- g_return_if_fail(info != NULL);
-
-@@ -135,8 +135,8 @@ gaim_proxy_info_set_password(GaimProxyIn
- info->password = (password == NULL ? NULL : g_strdup(password));
- }
-
--GaimProxyType
--gaim_proxy_info_get_type(const GaimProxyInfo *info)
-+Gaim2ProxyType
-+gaim2_proxy_info_get_type(const Gaim2ProxyInfo *info)
- {
- g_return_val_if_fail(info != NULL, GAIM_PROXY_NONE);
-
-@@ -144,7 +144,7 @@ gaim_proxy_info_get_type(const GaimProxy
- }
-
- const char *
--gaim_proxy_info_get_host(const GaimProxyInfo *info)
-+gaim2_proxy_info_get_host(const Gaim2ProxyInfo *info)
- {
- g_return_val_if_fail(info != NULL, NULL);
-
-@@ -152,7 +152,7 @@ gaim_proxy_info_get_host(const GaimProxy
- }
-
- int
--gaim_proxy_info_get_port(const GaimProxyInfo *info)
-+gaim2_proxy_info_get_port(const Gaim2ProxyInfo *info)
- {
- g_return_val_if_fail(info != NULL, 0);
-
-@@ -160,7 +160,7 @@ gaim_proxy_info_get_port(const GaimProxy
- }
-
- const char *
--gaim_proxy_info_get_username(const GaimProxyInfo *info)
-+gaim2_proxy_info_get_username(const Gaim2ProxyInfo *info)
- {
- g_return_val_if_fail(info != NULL, NULL);
-
-@@ -168,7 +168,7 @@ gaim_proxy_info_get_username(const GaimP
- }
-
- const char *
--gaim_proxy_info_get_password(const GaimProxyInfo *info)
-+gaim2_proxy_info_get_password(const Gaim2ProxyInfo *info)
- {
- g_return_val_if_fail(info != NULL, NULL);
-
-@@ -178,16 +178,16 @@ gaim_proxy_info_get_password(const GaimP
- /**************************************************************************
- * Global Proxy API
- **************************************************************************/
--GaimProxyInfo *
--gaim_global_proxy_get_info(void)
-+Gaim2ProxyInfo *
-+gaim2_global_proxy_get_info(void)
- {
- return global_proxy_info;
- }
-
--static GaimProxyInfo *
--gaim_gnome_proxy_get_info(void)
-+static Gaim2ProxyInfo *
-+gaim2_gnome_proxy_get_info(void)
- {
-- static GaimProxyInfo info = {0, NULL, 0, NULL, NULL};
-+ static Gaim2ProxyInfo info = {0, NULL, 0, NULL, NULL};
- gchar *path;
- if ((path = g_find_program_in_path("gconftool-2"))) {
- gchar *tmp;
-@@ -197,11 +197,11 @@ gaim_gnome_proxy_get_info(void)
- /* See whether to use a proxy. */
- if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/use_http_proxy", &tmp,
- NULL, NULL, NULL))
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- if (strcmp(tmp, "true\n")) {
- info.type = GAIM_PROXY_NONE;
- g_free(tmp);
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- }
-
- g_free(tmp);
-@@ -224,28 +224,28 @@ gaim_gnome_proxy_get_info(void)
- /* Get the new ones */
- if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/host", &info.host,
- NULL, NULL, NULL))
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- g_strchomp(info.host);
-
- if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/authentication_user", &info.username,
- NULL, NULL, NULL))
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- g_strchomp(info.username);
-
- if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/authentication_password", &info.password,
- NULL, NULL, NULL))
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- g_strchomp(info.password);
-
- if (!g_spawn_command_line_sync("gconftool-2 -g /system/http_proxy/port", &tmp,
- NULL, NULL, NULL))
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- info.port = atoi(tmp);
- g_free(tmp);
-
- return &info;
- }
-- return gaim_global_proxy_get_info();
-+ return gaim2_global_proxy_get_info();
- }
- /**************************************************************************
- * Proxy API
-@@ -293,9 +293,9 @@ static void
- trap_gdb_bug()
- {
- const char *message =
-- "Gaim's DNS child got a SIGTRAP signal. \n"
-- "This can be caused by trying to run gaim inside gdb.\n"
-- "There is a known gdb bug which prevents this. Supposedly gaim\n"
-+ "Gaim2's DNS child got a SIGTRAP signal. \n"
-+ "This can be caused by trying to run gaim2 inside gdb.\n"
-+ "There is a known gdb bug which prevents this. Supposedly gaim2\n"
- "should have detected you were using gdb and used an ugly hack,\n"
- "check cope_with_gdb_brokenness() in proxy.c.\n\n"
- "For more info about this bug, see http://sources.redhat.com/ml/gdb/2001-07/msg00349.html\n";
-@@ -328,7 +328,7 @@ cope_with_gdb_brokenness()
- e[MIN(n,sizeof(e)-1)] = '\0';
-
- if(strstr(e,"gdb")) {
-- gaim_debug_info("dns",
-+ gaim2_debug_info("dns",
- "Debugger detected, performing useless query...\n");
- gethostbyname("x.x.x.x.x");
- }
-@@ -336,7 +336,7 @@ cope_with_gdb_brokenness()
- }
-
- static void
--gaim_dns_resolverthread(int child_out, int child_in, gboolean show_debug)
-+gaim2_dns_resolverthread(int child_out, int child_in, gboolean show_debug)
- {
- dns_params_t dns_params;
- const size_t zero = 0;
-@@ -459,14 +459,14 @@ gaim_dns_resolverthread(int child_out, i
- }
-
- static pending_dns_request_t *
--gaim_dns_new_resolverthread(gboolean show_debug)
-+gaim2_dns_new_resolverthread(gboolean show_debug)
- {
- pending_dns_request_t *req;
- int child_out[2], child_in[2];
-
- /* Create pipes for communicating with the child process */
- if (pipe(child_out) || pipe(child_in)) {
-- gaim_debug_error("dns",
-+ gaim2_debug_error("dns",
- "Could not create pipes: %s\n", strerror(errno));
- return NULL;
- }
-@@ -484,7 +484,7 @@ gaim_dns_new_resolverthread(gboolean sho
- close(child_out[0]);
- close(child_in[1]);
-
-- gaim_dns_resolverthread(child_out[1], child_in[0], show_debug);
-+ gaim2_dns_resolverthread(child_out[1], child_in[0], show_debug);
- /* The thread calls _exit() rather than returning, so we never get here */
- }
-
-@@ -492,7 +492,7 @@ gaim_dns_new_resolverthread(gboolean sho
- close(child_out[1]);
- close(child_in[0]);
- if (req->dns_pid == -1) {
-- gaim_debug_error("dns",
-+ gaim2_debug_error("dns",
- "Could not create child process for DNS: %s\n",
- strerror(errno));
- g_free(req);
-@@ -502,7 +502,7 @@ gaim_dns_new_resolverthread(gboolean sho
- req->fd_out = child_out[0];
- req->fd_in = child_in[1];
- number_of_dns_children++;
-- gaim_debug_info("dns",
-+ gaim2_debug_info("dns",
- "Created new DNS child %d, there are now %d children.\n",
- req->dns_pid, number_of_dns_children);
-
-@@ -537,7 +537,7 @@ send_dns_request_to_child(pending_dns_re
-
- /* Are you alive? */
- if (kill(req->dns_pid, 0) != 0) {
-- gaim_debug_warning("dns",
-+ gaim2_debug_warning("dns",
- "DNS child %d no longer exists\n", req->dns_pid);
- return -1;
- }
-@@ -545,7 +545,7 @@ send_dns_request_to_child(pending_dns_re
- /* Let's contact this lost child! */
- rc = write(req->fd_in, dns_params, sizeof(*dns_params));
- if (rc < 0) {
-- gaim_debug_error("dns",
-+ gaim2_debug_error("dns",
- "Unable to write to DNS child %d: %d\n",
- req->dns_pid, strerror(errno));
- close(req->fd_in);
-@@ -558,21 +558,21 @@ send_dns_request_to_child(pending_dns_re
- rc = read(req->fd_out, &ch, sizeof(ch));
- if (rc != 1 || ch != 'Y')
- {
-- gaim_debug_warning("dns",
-+ gaim2_debug_warning("dns",
- "DNS child %d not responding. Killing it!\n",
- req->dns_pid);
- kill(req->dns_pid, SIGKILL);
- return -1;
- }
-
-- gaim_debug_info("dns",
-+ gaim2_debug_info("dns",
- "Successfully sent DNS request to child %d\n", req->dns_pid);
-
- return 0;
- }
-
- static void
--host_resolved(gpointer data, gint source, GaimInputCondition cond);
-+host_resolved(gpointer data, gint source, Gaim2InputCondition cond);
-
- static void
- release_dns_child(pending_dns_request_t *req)
-@@ -587,7 +587,7 @@ release_dns_child(pending_dns_request_t
- req->callback = r->callback;
- req->data = r->data;
-
-- gaim_debug_info("dns",
-+ gaim2_debug_info("dns",
- "Processing queued DNS query for '%s' with child %d\n",
- req->host, req->dns_pid);
-
-@@ -595,12 +595,12 @@ release_dns_child(pending_dns_request_t
- req_free(req);
- req = NULL;
-
-- gaim_debug_warning("dns",
-+ gaim2_debug_warning("dns",
- "Intent of process queued query of '%s' failed, "
- "requeueing...\n", r->params.hostname);
- g_queue_push_head(queued_requests, r);
- } else {
-- req->inpa = gaim_input_add(req->fd_out, GAIM_INPUT_READ, host_resolved, req);
-+ req->inpa = gaim2_input_add(req->fd_out, GAIM_INPUT_READ, host_resolved, req);
- g_free(r);
- }
-
-@@ -613,7 +613,7 @@ release_dns_child(pending_dns_request_t
- }
-
- static void
--host_resolved(gpointer data, gint source, GaimInputCondition cond)
-+host_resolved(gpointer data, gint source, Gaim2InputCondition cond)
- {
- pending_dns_request_t *req = (pending_dns_request_t*)data;
- int rc, err;
-@@ -621,8 +621,8 @@ host_resolved(gpointer data, gint source
- struct sockaddr *addr = NULL;
- size_t addrlen;
-
-- gaim_debug_info("dns", "Host '%s' resolved\n", req->host);
-- gaim_input_remove(req->inpa);
-+ gaim2_debug_info("dns", "Host '%s' resolved\n", req->host);
-+ gaim2_input_remove(req->inpa);
-
- rc = read(req->fd_out, &err, sizeof(err));
- if ((rc == 4) && (err != 0))
-@@ -635,7 +635,7 @@ host_resolved(gpointer data, gint source
- g_snprintf(message, sizeof(message), "DNS error: %d (pid=%d)",
- err, req->dns_pid);
- #endif
-- gaim_debug_error("dns", "%s\n", message);
-+ gaim2_debug_error("dns", "%s\n", message);
- req->callback(NULL, req->data, message);
- release_dns_child(req);
- return;
-@@ -656,7 +656,7 @@ host_resolved(gpointer data, gint source
- } else if (rc == -1) {
- char message[1024];
- g_snprintf(message, sizeof(message), "Error reading from DNS child: %s",strerror(errno));
-- gaim_debug_error("dns", "%s\n", message);
-+ gaim2_debug_error("dns", "%s\n", message);
- req->callback(NULL, req->data, message);
- req_free(req);
- return;
-@@ -664,7 +664,7 @@ host_resolved(gpointer data, gint source
- char message[1024];
- g_snprintf(message, sizeof(message), "EOF reading from DNS child");
- close(req->fd_out);
-- gaim_debug_error("dns", "%s\n", message);
-+ gaim2_debug_error("dns", "%s\n", message);
- req->callback(NULL, req->data, message);
- req_free(req);
- return;
-@@ -681,14 +681,14 @@ host_resolved(gpointer data, gint source
- */
-
- int
--gaim_gethostbyname_async(const char *hostname, int port, dns_callback_t callback, gpointer data)
-+gaim2_gethostbyname_async(const char *hostname, int port, dns_callback_t callback, gpointer data)
- {
- pending_dns_request_t *req = NULL;
- dns_params_t dns_params;
- gchar *host_temp;
- gboolean show_debug;
-
-- show_debug = gaim_debug_is_enabled();
-+ show_debug = gaim2_debug_is_enabled();
-
- host_temp = g_strstrip(g_strdup(hostname));
- strncpy(dns_params.hostname, host_temp, sizeof(dns_params.hostname) - 1);
-@@ -725,13 +725,13 @@ gaim_gethostbyname_async(const char *hos
- queued_requests = g_queue_new();
- g_queue_push_tail(queued_requests, r);
-
-- gaim_debug_info("dns",
-+ gaim2_debug_info("dns",
- "DNS query for '%s' queued\n", dns_params.hostname);
-
- return 0;
- }
-
-- req = gaim_dns_new_resolverthread(show_debug);
-+ req = gaim2_dns_new_resolverthread(show_debug);
- send_dns_request_to_child(req, &dns_params);
- }
-
-@@ -739,7 +739,7 @@ gaim_gethostbyname_async(const char *hos
- req->port = port;
- req->callback = callback;
- req->data = data;
-- req->inpa = gaim_input_add(req->fd_out, GAIM_INPUT_READ, host_resolved, req);
-+ req->inpa = gaim2_input_add(req->fd_out, GAIM_INPUT_READ, host_resolved, req);
-
- return 0;
- }
-@@ -758,7 +758,7 @@ typedef struct _dns_tdata {
- static gboolean dns_main_thread_cb(gpointer data) {
- dns_tdata *td = (dns_tdata*)data;
- if (td->errmsg != NULL) {
-- gaim_debug_info("dns", "%s\n", td->errmsg);
-+ gaim2_debug_info("dns", "%s\n", td->errmsg);
- }
- td->callback(td->hosts, td->data, td->errmsg);
- g_free(td->hostname);
-@@ -824,7 +824,7 @@ static gpointer dns_thread(gpointer data
- }
-
- int
--gaim_gethostbyname_async(const char *hostname, int port,
-+gaim2_gethostbyname_async(const char *hostname, int port,
- dns_callback_t callback, gpointer data)
- {
- dns_tdata *td;
-@@ -841,7 +841,7 @@ gaim_gethostbyname_async(const char *hos
- return 0;
- }
-
-- gaim_debug_info("dns", "DNS Lookup for: %s\n", hostname);
-+ gaim2_debug_info("dns", "DNS Lookup for: %s\n", hostname);
- td = g_new0(dns_tdata, 1);
- td->hostname = g_strdup(hostname);
- td->port = port;
-@@ -849,7 +849,7 @@ gaim_gethostbyname_async(const char *hos
- td->data = data;
-
- if(!g_thread_create(dns_thread, td, FALSE, &err)) {
-- gaim_debug_error("dns", "DNS thread create failure: %s\n", err?err->message:"");
-+ gaim2_debug_error("dns", "DNS thread create failure: %s\n", err?err->message:"");
- g_error_free(err);
- g_free(td->hostname);
- g_free(td);
-@@ -879,7 +879,7 @@ static gboolean host_resolved(gpointer d
- }
-
- int
--gaim_gethostbyname_async(const char *hostname, int port,
-+gaim2_gethostbyname_async(const char *hostname, int port,
- dns_callback_t callback, gpointer data)
- {
- struct sockaddr_in sin;
-@@ -888,8 +888,8 @@ gaim_gethostbyname_async(const char *hos
- if (!inet_aton(hostname, &sin.sin_addr)) {
- struct hostent *hp;
- if(!(hp = gethostbyname(hostname))) {
-- gaim_debug_error("dns",
-- "gaim_gethostbyname(\"%s\", %d) failed: %d\n",
-+ gaim2_debug_error("dns",
-+ "gaim2_gethostbyname(\"%s\", %d) failed: %d\n",
- hostname, port, h_errno);
- return -1;
- }
-@@ -905,20 +905,20 @@ gaim_gethostbyname_async(const char *hos
- req->addrlen = sizeof(sin);
- req->data = data;
- req->callback = callback;
-- gaim_timeout_add(10, host_resolved, req);
-+ gaim2_timeout_add(10, host_resolved, req);
- return 0;
- }
-
- #endif /* not __unix__ or _WIN32 */
-
- static void
--no_one_calls(gpointer data, gint source, GaimInputCondition cond)
-+no_one_calls(gpointer data, gint source, Gaim2InputCondition cond)
- {
- struct PHB *phb = data;
- unsigned int len;
- int error=0, ret;
-
-- gaim_debug_info("proxy", "Connected.\n");
-+ gaim2_debug_info("proxy", "Connected.\n");
-
- len = sizeof(error);
-
-@@ -939,9 +939,9 @@ no_one_calls(gpointer data, gint source,
- if (ret < 0 || error != 0) {
- if(ret!=0) error = errno;
- close(source);
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
-
-- gaim_debug_error("proxy",
-+ gaim2_debug_error("proxy",
- "getsockopt SO_ERROR check: %s\n", strerror(error));
-
- try_connect(phb);
-@@ -949,10 +949,10 @@ no_one_calls(gpointer data, gint source,
- }
-
- fcntl(source, F_SETFL, 0);
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
-
- if (phb->account == NULL ||
-- gaim_account_get_connection(phb->account) != NULL) {
-+ gaim2_account_get_connection(phb->account) != NULL) {
-
- phb->func(phb->data, source, GAIM_INPUT_READ);
- }
-@@ -966,7 +966,7 @@ static gboolean clean_connect(gpointer d
- struct PHB *phb = data;
-
- if (phb->account == NULL ||
-- gaim_account_get_connection(phb->account) != NULL) {
-+ gaim2_account_get_connection(phb->account) != NULL) {
-
- phb->func(phb->data, phb->port, GAIM_INPUT_READ);
- }
-@@ -983,11 +983,11 @@ proxy_connect_none(struct PHB *phb, stru
- {
- int fd = -1;
-
-- gaim_debug_info("proxy",
-+ gaim2_debug_info("proxy",
- "Connecting to %s:%d with no proxy\n", phb->host, phb->port);
-
- if ((fd = socket(addr->sa_family, SOCK_STREAM, 0)) < 0) {
-- gaim_debug_error("proxy",
-+ gaim2_debug_error("proxy",
- "Unable to create socket: %s\n", strerror(errno));
- return -1;
- }
-@@ -998,12 +998,12 @@ proxy_connect_none(struct PHB *phb, stru
-
- if (connect(fd, (struct sockaddr *)addr, addrlen) < 0) {
- if ((errno == EINPROGRESS) || (errno == EINTR)) {
-- gaim_debug_warning("proxy",
-+ gaim2_debug_warning("proxy",
- "Connect would have blocked.\n");
-- phb->inpa = gaim_input_add(fd, GAIM_INPUT_WRITE, no_one_calls, phb);
-+ phb->inpa = gaim2_input_add(fd, GAIM_INPUT_WRITE, no_one_calls, phb);
- }
- else {
-- gaim_debug_error("proxy",
-+ gaim2_debug_error("proxy",
- "Connect failed: %s\n", strerror(errno));
- close(fd);
- return -1;
-@@ -1012,16 +1012,16 @@ proxy_connect_none(struct PHB *phb, stru
- else {
- unsigned int len;
- int error = ETIMEDOUT;
-- gaim_debug_misc("proxy", "Connect didn't block.\n");
-+ gaim2_debug_misc("proxy", "Connect didn't block.\n");
- len = sizeof(error);
- if (getsockopt(fd, SOL_SOCKET, SO_ERROR, &error, &len) < 0) {
-- gaim_debug_error("proxy", "getsockopt failed.\n");
-+ gaim2_debug_error("proxy", "getsockopt failed.\n");
- close(fd);
- return -1;
- }
- fcntl(fd, F_SETFL, 0);
- phb->port = fd; /* bleh */
-- gaim_timeout_add(50, clean_connect, phb); /* we do this because we never
-+ gaim2_timeout_add(50, clean_connect, phb); /* we do this because we never
- want to call our callback
- before we return. */
- }
-@@ -1035,7 +1035,7 @@ proxy_connect_none(struct PHB *phb, stru
- static void
- http_complete(struct PHB *phb, gint source)
- {
-- gaim_debug_info("http proxy", "proxy connection established\n");
-+ gaim2_debug_info("http proxy", "proxy connection established\n");
- if(source < 0) {
- try_connect(phb);
- } else if(!phb->account || phb->account->gc) {
-@@ -1048,7 +1048,7 @@ http_complete(struct PHB *phb, gint sour
-
- /* read the response to the CONNECT request, if we are requesting a non-port-80 tunnel */
- static void
--http_canread(gpointer data, gint source, GaimInputCondition cond)
-+http_canread(gpointer data, gint source, Gaim2InputCondition cond)
- {
- int nlc = 0;
- int pos = 0;
-@@ -1096,21 +1096,21 @@ http_canread(gpointer data, gint source,
- while(len--) read(source, &tmpc, 1);
- }
- if(error) {
-- gaim_debug_error("proxy",
-+ gaim2_debug_error("proxy",
- "Unable to parse proxy's response: %s\n", inputline);
- close(source);
- source=-1;
- }
- else if(status!=200) {
-- gaim_debug_error("proxy",
-+ gaim2_debug_error("proxy",
- "Proxy server replied with:\n%s\n", inputline);
-
-- /* XXX: why in the hell are we calling gaim_connection_error() here? */
-+ /* XXX: why in the hell are we calling gaim2_connection_error() here? */
- if ( status == 407 /* Proxy Auth */ ) {
- gchar *ntlm;
- if( (ntlm = g_strrstr(inputline, "Proxy-Authenticate: NTLM "))) { /* Check for Type-2 */
- gchar *nonce = ntlm;
-- gchar *domain = (gchar*)gaim_proxy_info_get_username(phb->gpi);
-+ gchar *domain = (gchar*)gaim2_proxy_info_get_username(phb->gpi);
- gchar *username;
- gchar *request;
- gchar *response;
-@@ -1118,9 +1118,9 @@ http_canread(gpointer data, gint source,
- char *msg = g_strdup_printf(_("Proxy connection error %d"), status);
- close(source);
- source = -1;
-- gaim_connection_error(phb->account->gc, msg);
-+ gaim2_connection_error(phb->account->gc, msg);
- g_free(msg);
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
- return;
- }
- *username = 0;
-@@ -1128,8 +1128,8 @@ http_canread(gpointer data, gint source,
- ntlm += strlen("Proxy-Authenticate: NTLM ");
- while(*nonce != '\r' && *nonce != '\0') nonce ++;
- *nonce = 0;
-- nonce = gaim_ntlm_parse_type2(ntlm);
-- response = gaim_ntlm_gen_type3(username, (gchar*)gaim_proxy_info_get_password(phb->gpi), (gchar*)gaim_proxy_info_get_host(phb->gpi), domain, nonce);
-+ nonce = gaim2_ntlm_parse_type2(ntlm);
-+ response = gaim2_ntlm_gen_type3(username, (gchar*)gaim2_proxy_info_get_password(phb->gpi), (gchar*)gaim2_proxy_info_get_host(phb->gpi), domain, nonce);
- username--;
- *username = '\\';
- request = g_strdup_printf("CONNECT %s:%d HTTP/1.1\r\nHost: %s:%d\r\nProxy-Authorization: NTLM %s\r\nProxy-Connection: Keep-Alive\r\n\r\n",
-@@ -1141,16 +1141,16 @@ http_canread(gpointer data, gint source,
- return;
- } else if((ntlm = g_strrstr(inputline, "Proxy-Authenticate: NTLM"))) { /* Empty message */
- gchar request[2048];
-- gchar *domain = (gchar*)gaim_proxy_info_get_username(phb->gpi);
-+ gchar *domain = (gchar*)gaim2_proxy_info_get_username(phb->gpi);
- gchar *username;
- int request_len;
- if(!(username = strchr(domain, '\\'))) {
- char *msg = g_strdup_printf(_("Proxy connection error %d"), status);
- close(source);
- source = -1;
-- gaim_connection_error(phb->account->gc, msg);
-+ gaim2_connection_error(phb->account->gc, msg);
- g_free(msg);
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
- return;
- }
- *username = 0;
-@@ -1162,7 +1162,7 @@ http_canread(gpointer data, gint source,
- g_return_if_fail(request_len < sizeof(request));
- request_len += g_snprintf(request + request_len,
- sizeof(request) - request_len,
-- "Proxy-Authorization: NTLM %s\r\nProxy-Connection: Keep-Alive\r\n\r\n", gaim_ntlm_gen_type1((gchar*)gaim_proxy_info_get_host(phb->gpi),domain));
-+ "Proxy-Authorization: NTLM %s\r\nProxy-Connection: Keep-Alive\r\n\r\n", gaim2_ntlm_gen_type1((gchar*)gaim2_proxy_info_get_host(phb->gpi),domain));
- *username = '\\';
- write(source, request, request_len);
- return;
-@@ -1170,29 +1170,29 @@ http_canread(gpointer data, gint source,
- char *msg = g_strdup_printf(_("Proxy connection error %d"), status);
- close(source);
- source = -1;
-- gaim_connection_error(phb->account->gc, msg);
-+ gaim2_connection_error(phb->account->gc, msg);
- g_free(msg);
- }
- }
- if ( status == 403 /* Forbidden */ ) {
- gchar *msg = g_strdup_printf(_("Access denied: proxy server forbids port %d tunnelling."), phb->port);
-- gaim_connection_error(phb->account->gc, msg);
-+ gaim2_connection_error(phb->account->gc, msg);
- g_free(msg);
- } else {
- char *msg = g_strdup_printf(_("Proxy connection error %d"), status);
-- gaim_connection_error(phb->account->gc, msg);
-+ gaim2_connection_error(phb->account->gc, msg);
- g_free(msg);
- }
- } else {
- http_complete(phb, source);
- }
-
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
- return;
- }
-
- static void
--http_canwrite(gpointer data, gint source, GaimInputCondition cond)
-+http_canwrite(gpointer data, gint source, Gaim2InputCondition cond)
- {
- char request[8192];
- int request_len = 0;
-@@ -1200,10 +1200,10 @@ http_canwrite(gpointer data, gint source
- unsigned int len;
- int error = ETIMEDOUT;
-
-- gaim_debug_info("http proxy", "Connected.\n");
-+ gaim2_debug_info("http proxy", "Connected.\n");
-
- if (phb->inpa > 0)
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
-
- len = sizeof(error);
-
-@@ -1214,24 +1214,24 @@ http_canwrite(gpointer data, gint source
- return;
- }
-
-- gaim_debug_info("proxy", "using CONNECT tunnelling for %s:%d\n", phb->host, phb->port);
-+ gaim2_debug_info("proxy", "using CONNECT tunnelling for %s:%d\n", phb->host, phb->port);
- request_len = g_snprintf(request, sizeof(request),
- "CONNECT %s:%d HTTP/1.1\r\nHost: %s:%d\r\n",
- phb->host, phb->port, phb->host, phb->port);
-
-- if (gaim_proxy_info_get_username(phb->gpi) != NULL) {
-+ if (gaim2_proxy_info_get_username(phb->gpi) != NULL) {
- char *t1, *t2;
- t1 = g_strdup_printf("%s:%s",
-- gaim_proxy_info_get_username(phb->gpi),
-- gaim_proxy_info_get_password(phb->gpi) ?
-- gaim_proxy_info_get_password(phb->gpi) : "");
-- t2 = gaim_base64_encode((const guchar *)t1, strlen(t1));
-+ gaim2_proxy_info_get_username(phb->gpi),
-+ gaim2_proxy_info_get_password(phb->gpi) ?
-+ gaim2_proxy_info_get_password(phb->gpi) : "");
-+ t2 = gaim2_base64_encode((const guchar *)t1, strlen(t1));
- g_free(t1);
- g_return_if_fail(request_len < sizeof(request));
-
- request_len += g_snprintf(request + request_len,
- sizeof(request) - request_len,
-- "Proxy-Authorization: NTLM %s\r\nProxy-Authorization: Basic %s\r\nProxy-Connection: Keep-Alive\r\n", gaim_ntlm_gen_type1((gchar*)gaim_proxy_info_get_host(phb->gpi),""), t2);
-+ "Proxy-Authorization: NTLM %s\r\nProxy-Authorization: Basic %s\r\nProxy-Connection: Keep-Alive\r\n", gaim2_ntlm_gen_type1((gchar*)gaim2_proxy_info_get_host(phb->gpi),""), t2);
- g_free(t2);
- }
-
-@@ -1247,7 +1247,7 @@ http_canwrite(gpointer data, gint source
- }
-
- /* register the response handler for the CONNECT request */
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, http_canread, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, http_canread, phb);
- }
-
- static int
-@@ -1255,11 +1255,11 @@ proxy_connect_http(struct PHB *phb, stru
- {
- int fd = -1;
-
-- gaim_debug_info("http proxy",
-+ gaim2_debug_info("http proxy",
- "Connecting to %s:%d via %s:%d using HTTP\n",
- (phb->host ? phb->host : "(null)"), phb->port,
-- (gaim_proxy_info_get_host(phb->gpi) ? gaim_proxy_info_get_host(phb->gpi) : "(null)"),
-- gaim_proxy_info_get_port(phb->gpi));
-+ (gaim2_proxy_info_get_host(phb->gpi) ? gaim2_proxy_info_get_host(phb->gpi) : "(null)"),
-+ gaim2_proxy_info_get_port(phb->gpi));
-
- if ((fd = socket(addr->sa_family, SOCK_STREAM, 0)) < 0) {
- return -1;
-@@ -1272,12 +1272,12 @@ proxy_connect_http(struct PHB *phb, stru
-
- if (connect(fd, addr, addrlen) < 0) {
- if ((errno == EINPROGRESS) || (errno == EINTR)) {
-- gaim_debug_warning("http proxy",
-+ gaim2_debug_warning("http proxy",
- "Connect would have blocked.\n");
-
- if (phb->port != 80) {
- /* we need to do CONNECT first */
-- phb->inpa = gaim_input_add(fd, GAIM_INPUT_WRITE,
-+ phb->inpa = gaim2_input_add(fd, GAIM_INPUT_WRITE,
- http_canwrite, phb);
- } else {
- http_complete(phb, fd);
-@@ -1291,7 +1291,7 @@ proxy_connect_http(struct PHB *phb, stru
- unsigned int len;
- int error = ETIMEDOUT;
-
-- gaim_debug_misc("http proxy",
-+ gaim2_debug_misc("http proxy",
- "Connect didn't block.\n");
-
- len = sizeof(error);
-@@ -1307,18 +1307,18 @@ proxy_connect_http(struct PHB *phb, stru
- }
-
- static void
--s4_canread(gpointer data, gint source, GaimInputCondition cond)
-+s4_canread(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char packet[12];
- struct PHB *phb = data;
-
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
-
- memset(packet, 0, sizeof(packet));
-
- if (read(source, packet, 9) >= 4 && packet[1] == 90) {
- if (phb->account == NULL ||
-- gaim_account_get_connection(phb->account) != NULL) {
-+ gaim2_account_get_connection(phb->account) != NULL) {
-
- phb->func(phb->data, source, GAIM_INPUT_READ);
- }
-@@ -1334,7 +1334,7 @@ s4_canread(gpointer data, gint source, G
- }
-
- static void
--s4_canwrite(gpointer data, gint source, GaimInputCondition cond)
-+s4_canwrite(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char packet[12];
- struct hostent *hp;
-@@ -1342,10 +1342,10 @@ s4_canwrite(gpointer data, gint source,
- unsigned int len;
- int error = ETIMEDOUT;
-
-- gaim_debug_info("socks4 proxy", "Connected.\n");
-+ gaim2_debug_info("socks4 proxy", "Connected.\n");
-
- if (phb->inpa > 0)
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
-
- len = sizeof(error);
-
-@@ -1389,7 +1389,7 @@ s4_canwrite(gpointer data, gint source,
- return;
- }
-
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s4_canread, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, s4_canread, phb);
- }
-
- static int
-@@ -1397,11 +1397,11 @@ proxy_connect_socks4(struct PHB *phb, st
- {
- int fd = -1;
-
-- gaim_debug_info("socks4 proxy",
-+ gaim2_debug_info("socks4 proxy",
- "Connecting to %s:%d via %s:%d using SOCKS4\n",
- phb->host, phb->port,
-- gaim_proxy_info_get_host(phb->gpi),
-- gaim_proxy_info_get_port(phb->gpi));
-+ gaim2_proxy_info_get_host(phb->gpi),
-+ gaim2_proxy_info_get_port(phb->gpi));
-
- if ((fd = socket(addr->sa_family, SOCK_STREAM, 0)) < 0)
- return -1;
-@@ -1413,9 +1413,9 @@ proxy_connect_socks4(struct PHB *phb, st
-
- if (connect(fd, addr, addrlen) < 0) {
- if ((errno == EINPROGRESS) || (errno == EINTR)) {
-- gaim_debug_warning("socks4 proxy",
-+ gaim2_debug_warning("socks4 proxy",
- "Connect would have blocked.\n");
-- phb->inpa = gaim_input_add(fd, GAIM_INPUT_WRITE, s4_canwrite, phb);
-+ phb->inpa = gaim2_input_add(fd, GAIM_INPUT_WRITE, s4_canwrite, phb);
- }
- else {
- close(fd);
-@@ -1425,7 +1425,7 @@ proxy_connect_socks4(struct PHB *phb, st
- unsigned int len;
- int error = ETIMEDOUT;
-
-- gaim_debug_misc("socks4 proxy",
-+ gaim2_debug_misc("socks4 proxy",
- "Connect didn't block.\n");
-
- len = sizeof(error);
-@@ -1443,16 +1443,16 @@ proxy_connect_socks4(struct PHB *phb, st
- }
-
- static void
--s5_canread_again(gpointer data, gint source, GaimInputCondition cond)
-+s5_canread_again(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char buf[512];
- struct PHB *phb = data;
-
-- gaim_input_remove(phb->inpa);
-- gaim_debug_info("socks5 proxy", "Able to read again.\n");
-+ gaim2_input_remove(phb->inpa);
-+ gaim2_debug_info("socks5 proxy", "Able to read again.\n");
-
- if (read(source, buf, 4) < 4) {
-- gaim_debug_warning("socks5 proxy", "or not...\n");
-+ gaim2_debug_warning("socks5 proxy", "or not...\n");
- close(source);
-
- try_connect(phb);
-@@ -1460,9 +1460,9 @@ s5_canread_again(gpointer data, gint sou
- }
- if ((buf[0] != 0x05) || (buf[1] != 0x00)) {
- if ((buf[0] == 0x05) && (buf[1] < 0x09))
-- gaim_debug_error("socks5 proxy", socks5errors[buf[1]]);
-+ gaim2_debug_error("socks5 proxy", socks5errors[buf[1]]);
- else
-- gaim_debug_error("socks5 proxy", "Bad data.\n");
-+ gaim2_debug_error("socks5 proxy", "Bad data.\n");
- close(source);
-
- try_connect(phb);
-@@ -1489,7 +1489,7 @@ s5_canread_again(gpointer data, gint sou
- read(source, buf, 2);
-
- if (phb->account == NULL ||
-- gaim_account_get_connection(phb->account) != NULL) {
-+ gaim2_account_get_connection(phb->account) != NULL) {
-
- phb->func(phb->data, source, GAIM_INPUT_READ);
- }
-@@ -1521,17 +1521,17 @@ s5_sendconnect(gpointer data, gint sourc
- return;
- }
-
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_canread_again, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, s5_canread_again, phb);
- }
-
- static void
--s5_readauth(gpointer data, gint source, GaimInputCondition cond)
-+s5_readauth(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char buf[512];
- struct PHB *phb = data;
-
-- gaim_input_remove(phb->inpa);
-- gaim_debug_info("socks5 proxy", "Got auth response.\n");
-+ gaim2_input_remove(phb->inpa);
-+ gaim2_debug_info("socks5 proxy", "Got auth response.\n");
-
- if (read(source, buf, 2) < 2) {
- close(source);
-@@ -1552,8 +1552,8 @@ s5_readauth(gpointer data, gint source,
-
- static void hmacmd5_chap(const unsigned char * challenge, int challen, const char * passwd, unsigned char * response)
- {
-- GaimCipher *cipher;
-- GaimCipherContext *ctx;
-+ Gaim2Cipher *cipher;
-+ Gaim2CipherContext *ctx;
- int i;
- unsigned char Kxoripad[65];
- unsigned char Kxoropad[65];
-@@ -1561,14 +1561,14 @@ static void hmacmd5_chap(const unsigned
- char * pwinput;
- guchar md5buf[16];
-
-- cipher = gaim_ciphers_find_cipher("md5");
-- ctx = gaim_cipher_context_new(cipher, NULL);
-+ cipher = gaim2_ciphers_find_cipher("md5");
-+ ctx = gaim2_cipher_context_new(cipher, NULL);
-
- pwinput=(char *)passwd;
- pwlen=strlen(passwd);
- if (pwlen>64) {
-- gaim_cipher_context_append(ctx, (const guchar *)passwd, strlen(passwd));
-- gaim_cipher_context_digest(ctx, sizeof(md5buf), md5buf, NULL);
-+ gaim2_cipher_context_append(ctx, (const guchar *)passwd, strlen(passwd));
-+ gaim2_cipher_context_digest(ctx, sizeof(md5buf), md5buf, NULL);
- pwinput=(char *)md5buf;
- pwlen=16;
- }
-@@ -1582,21 +1582,21 @@ static void hmacmd5_chap(const unsigned
- Kxoropad[i]^=0x5c;
- }
-
-- gaim_cipher_context_reset(ctx, NULL);
-- gaim_cipher_context_append(ctx, Kxoripad, 64);
-- gaim_cipher_context_append(ctx, challenge, challen);
-- gaim_cipher_context_digest(ctx, sizeof(Kxoripad), Kxoripad, NULL);
-+ gaim2_cipher_context_reset(ctx, NULL);
-+ gaim2_cipher_context_append(ctx, Kxoripad, 64);
-+ gaim2_cipher_context_append(ctx, challenge, challen);
-+ gaim2_cipher_context_digest(ctx, sizeof(Kxoripad), Kxoripad, NULL);
-
-- gaim_cipher_context_reset(ctx, NULL);
-- gaim_cipher_context_append(ctx, Kxoropad, 64);
-- gaim_cipher_context_append(ctx, Kxoripad, 16);
-- gaim_cipher_context_digest(ctx, sizeof(response), response, NULL);
-+ gaim2_cipher_context_reset(ctx, NULL);
-+ gaim2_cipher_context_append(ctx, Kxoropad, 64);
-+ gaim2_cipher_context_append(ctx, Kxoripad, 16);
-+ gaim2_cipher_context_digest(ctx, sizeof(response), response, NULL);
-
-- gaim_cipher_context_destroy(ctx);
-+ gaim2_cipher_context_destroy(ctx);
- }
-
- static void
--s5_readchap(gpointer data, gint source, GaimInputCondition cond)
-+s5_readchap(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char buf[260];
- unsigned char cmdbuf[20];
-@@ -1604,8 +1604,8 @@ s5_readchap(gpointer data, gint source,
-
- int navas, currentav;
-
-- gaim_input_remove(phb->inpa);
-- gaim_debug(GAIM_DEBUG_INFO, "socks5 proxy", "Got CHAP response.\n");
-+ gaim2_input_remove(phb->inpa);
-+ gaim2_debug(GAIM_DEBUG_INFO, "socks5 proxy", "Got CHAP response.\n");
-
- if (read(source, cmdbuf, 2) < 2) {
- close(source);
-@@ -1645,7 +1645,7 @@ s5_readchap(gpointer data, gint source,
- return;
- } else {
- /* Failure */
-- gaim_debug_warning("proxy", "socks5 CHAP authentication "
-+ gaim2_debug_warning("proxy", "socks5 CHAP authentication "
- "failed. Disconnecting...");
- close(source);
-
-@@ -1656,7 +1656,7 @@ s5_readchap(gpointer data, gint source,
- case 0x03:
- /* Server wants our credentials */
- hmacmd5_chap(buf, cmdbuf[1],
-- gaim_proxy_info_get_password(phb->gpi),
-+ gaim2_proxy_info_get_password(phb->gpi),
- buf + 4);
- buf[0] = 0x01;
- buf[1] = 0x01;
-@@ -1673,7 +1673,7 @@ s5_readchap(gpointer data, gint source,
- /* Server wants to select an algorithm */
- if (buf[0] != 0x85) {
- /* Only currently support HMAC-MD5 */
-- gaim_debug_warning("proxy", "Server tried to select an "
-+ gaim2_debug_warning("proxy", "Server tried to select an "
- "algorithm that we did not advertise "
- "as supporting. This is a violation "
- "of the socks5 CHAP specification. "
-@@ -1689,17 +1689,17 @@ s5_readchap(gpointer data, gint source,
- /* Fell through. We ran out of CHAP events to process, but haven't
- * succeeded or failed authentication - there may be more to come.
- * If this is the case, come straight back here. */
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_readchap, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, s5_readchap, phb);
- }
-
- static void
--s5_canread(gpointer data, gint source, GaimInputCondition cond)
-+s5_canread(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char buf[512];
- struct PHB *phb = data;
-
-- gaim_input_remove(phb->inpa);
-- gaim_debug_info("socks5 proxy", "Able to read.\n");
-+ gaim2_input_remove(phb->inpa);
-+ gaim2_debug_info("socks5 proxy", "Able to read.\n");
-
- if (read(source, buf, 2) < 2) {
- close(source);
-@@ -1719,8 +1719,8 @@ s5_canread(gpointer data, gint source, G
- unsigned int i, j;
- const char *u, *p;
-
-- u = gaim_proxy_info_get_username(phb->gpi);
-- p = gaim_proxy_info_get_password(phb->gpi);
-+ u = gaim2_proxy_info_get_username(phb->gpi);
-+ p = gaim2_proxy_info_get_password(phb->gpi);
-
- i = (u == NULL) ? 0 : strlen(u);
- j = (p == NULL) ? 0 : strlen(p);
-@@ -1740,10 +1740,10 @@ s5_canread(gpointer data, gint source, G
- return;
- }
-
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_readauth, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, s5_readauth, phb);
- } else if (buf[1] == 0x03) {
- unsigned int userlen;
-- userlen = strlen(gaim_proxy_info_get_username(phb->gpi));
-+ userlen = strlen(gaim2_proxy_info_get_username(phb->gpi));
- buf[0] = 0x01;
- buf[1] = 0x02;
- buf[2] = 0x11;
-@@ -1751,7 +1751,7 @@ s5_canread(gpointer data, gint source, G
- buf[4] = 0x85;
- buf[5] = 0x02;
- buf[6] = userlen;
-- memcpy(buf + 7, gaim_proxy_info_get_username(phb->gpi), userlen);
-+ memcpy(buf + 7, gaim2_proxy_info_get_username(phb->gpi), userlen);
- if (write(source, buf, 7 + userlen) < 7 + userlen) {
- close(source);
-
-@@ -1759,7 +1759,7 @@ s5_canread(gpointer data, gint source, G
- return;
- }
-
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_readchap, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, s5_readchap, phb);
- }
- else {
- s5_sendconnect(phb, source);
-@@ -1767,7 +1767,7 @@ s5_canread(gpointer data, gint source, G
- }
-
- static void
--s5_canwrite(gpointer data, gint source, GaimInputCondition cond)
-+s5_canwrite(gpointer data, gint source, Gaim2InputCondition cond)
- {
- unsigned char buf[512];
- int i;
-@@ -1775,10 +1775,10 @@ s5_canwrite(gpointer data, gint source,
- unsigned int len;
- int error = ETIMEDOUT;
-
-- gaim_debug_info("socks5 proxy", "Connected.\n");
-+ gaim2_debug_info("socks5 proxy", "Connected.\n");
-
- if (phb->inpa > 0)
-- gaim_input_remove(phb->inpa);
-+ gaim2_input_remove(phb->inpa);
-
- len = sizeof(error);
- if (getsockopt(source, SOL_SOCKET, SO_ERROR, &error, &len) < 0) {
-@@ -1792,7 +1792,7 @@ s5_canwrite(gpointer data, gint source,
- i = 0;
- buf[0] = 0x05; /* SOCKS version 5 */
-
-- if (gaim_proxy_info_get_username(phb->gpi) != NULL) {
-+ if (gaim2_proxy_info_get_username(phb->gpi) != NULL) {
- buf[1] = 0x03; /* three methods */
- buf[2] = 0x00; /* no authentication */
- buf[3] = 0x03; /* CHAP authentication */
-@@ -1806,14 +1806,14 @@ s5_canwrite(gpointer data, gint source,
- }
-
- if (write(source, buf, i) < i) {
-- gaim_debug_error("socks5 proxy", "Unable to write\n");
-+ gaim2_debug_error("socks5 proxy", "Unable to write\n");
- close(source);
-
- try_connect(phb);
- return;
- }
-
-- phb->inpa = gaim_input_add(source, GAIM_INPUT_READ, s5_canread, phb);
-+ phb->inpa = gaim2_input_add(source, GAIM_INPUT_READ, s5_canread, phb);
- }
-
- static int
-@@ -1821,11 +1821,11 @@ proxy_connect_socks5(struct PHB *phb, st
- {
- int fd = -1;
-
-- gaim_debug_info("socks5 proxy",
-+ gaim2_debug_info("socks5 proxy",
- "Connecting to %s:%d via %s:%d using SOCKS5\n",
- phb->host, phb->port,
-- gaim_proxy_info_get_host(phb->gpi),
-- gaim_proxy_info_get_port(phb->gpi));
-+ gaim2_proxy_info_get_host(phb->gpi),
-+ gaim2_proxy_info_get_port(phb->gpi));
-
- if ((fd = socket(addr->sa_family, SOCK_STREAM, 0)) < 0)
- return -1;
-@@ -1837,10 +1837,10 @@ proxy_connect_socks5(struct PHB *phb, st
-
- if (connect(fd, addr, addrlen) < 0) {
- if ((errno == EINPROGRESS) || (errno == EINTR)) {
-- gaim_debug_warning("socks5 proxy",
-+ gaim2_debug_warning("socks5 proxy",
- "Connect would have blocked.\n");
-
-- phb->inpa = gaim_input_add(fd, GAIM_INPUT_WRITE, s5_canwrite, phb);
-+ phb->inpa = gaim2_input_add(fd, GAIM_INPUT_WRITE, s5_canwrite, phb);
- }
- else {
- close(fd);
-@@ -1851,7 +1851,7 @@ proxy_connect_socks5(struct PHB *phb, st
- unsigned int len;
- int error = ETIMEDOUT;
-
-- gaim_debug_misc("socks5 proxy",
-+ gaim2_debug_misc("socks5 proxy",
- "Connect didn't block.\n");
-
- len = sizeof(error);
-@@ -1880,7 +1880,7 @@ static void try_connect(struct PHB *phb)
- addr = phb->hosts->data;
- phb->hosts = g_slist_remove(phb->hosts, phb->hosts->data);
-
-- switch (gaim_proxy_info_get_type(phb->gpi)) {
-+ switch (gaim2_proxy_info_get_type(phb->gpi)) {
- case GAIM_PROXY_NONE:
- ret = proxy_connect_none(phb, addr, addrlen);
- break;
-@@ -1913,7 +1913,7 @@ static void try_connect(struct PHB *phb)
-
- if (ret < 0) {
- if (phb->account == NULL ||
-- gaim_account_get_connection(phb->account) != NULL) {
-+ gaim2_account_get_connection(phb->account) != NULL) {
-
- phb->func(phb->data, -1, GAIM_INPUT_READ);
- }
-@@ -1935,8 +1935,8 @@ connection_host_resolved(GSList *hosts,
- }
-
- int
--gaim_proxy_connect(GaimAccount *account, const char *host, int port,
-- GaimInputFunction func, gpointer data)
-+gaim2_proxy_connect(Gaim2Account *account, const char *host, int port,
-+ Gaim2InputFunction func, gpointer data)
- {
- const char *connecthost = host;
- int connectport = port;
-@@ -1949,12 +1949,12 @@ gaim_proxy_connect(GaimAccount *account,
-
- phb = g_new0(struct PHB, 1);
-
-- if (account && gaim_account_get_proxy_info(account) != NULL)
-- phb->gpi = gaim_account_get_proxy_info(account);
-- else if (gaim_running_gnome())
-- phb->gpi = gaim_gnome_proxy_get_info();
-+ if (account && gaim2_account_get_proxy_info(account) != NULL)
-+ phb->gpi = gaim2_account_get_proxy_info(account);
-+ else if (gaim2_running_gnome())
-+ phb->gpi = gaim2_gnome_proxy_get_info();
- else
-- phb->gpi = gaim_global_proxy_get_info();
-+ phb->gpi = gaim2_global_proxy_get_info();
-
- phb->func = func;
- phb->data = data;
-@@ -1962,7 +1962,7 @@ gaim_proxy_connect(GaimAccount *account,
- phb->port = port;
- phb->account = account;
-
-- if (gaim_proxy_info_get_type(phb->gpi) == GAIM_PROXY_USE_ENVVAR) {
-+ if (gaim2_proxy_info_get_type(phb->gpi) == GAIM_PROXY_USE_ENVVAR) {
- if ((tmp = g_getenv("HTTP_PROXY")) != NULL ||
- (tmp = g_getenv("http_proxy")) != NULL ||
- (tmp = g_getenv("HTTPPROXY")) != NULL) {
-@@ -1972,16 +1972,16 @@ gaim_proxy_connect(GaimAccount *account,
- /* http_proxy-format:
- * export http_proxy="http://user:passwd@your.proxy.server:port/"
- */
-- if(gaim_url_parse(tmp, &proxyhost, &proxyport, &proxypath, &proxyuser, &proxypasswd)) {
-- gaim_proxy_info_set_host(phb->gpi, proxyhost);
-+ if(gaim2_url_parse(tmp, &proxyhost, &proxyport, &proxypath, &proxyuser, &proxypasswd)) {
-+ gaim2_proxy_info_set_host(phb->gpi, proxyhost);
- g_free(proxyhost);
- g_free(proxypath);
- if (proxyuser != NULL) {
-- gaim_proxy_info_set_username(phb->gpi, proxyuser);
-+ gaim2_proxy_info_set_username(phb->gpi, proxyuser);
- g_free(proxyuser);
- }
- if (proxypasswd != NULL) {
-- gaim_proxy_info_set_password(phb->gpi, proxypasswd);
-+ gaim2_proxy_info_set_password(phb->gpi, proxypasswd);
- g_free(proxypasswd);
- }
-
-@@ -1992,37 +1992,37 @@ gaim_proxy_connect(GaimAccount *account,
- (tmp = g_getenv("HTTPPROXYPORT")) != NULL))
- proxyport = atoi(tmp);
-
-- gaim_proxy_info_set_port(phb->gpi, proxyport);
-+ gaim2_proxy_info_set_port(phb->gpi, proxyport);
- }
- } else {
- /* no proxy environment variable found, don't use a proxy */
-- gaim_debug_info("proxy", "No environment settings found, not using a proxy\n");
-- gaim_proxy_info_set_type(phb->gpi, GAIM_PROXY_NONE);
-+ gaim2_debug_info("proxy", "No environment settings found, not using a proxy\n");
-+ gaim2_proxy_info_set_type(phb->gpi, GAIM_PROXY_NONE);
- }
-
- /* XXX: Do we want to skip this step if user/password were part of url? */
- if ((tmp = g_getenv("HTTP_PROXY_USER")) != NULL ||
- (tmp = g_getenv("http_proxy_user")) != NULL ||
- (tmp = g_getenv("HTTPPROXYUSER")) != NULL)
-- gaim_proxy_info_set_username(phb->gpi, tmp);
-+ gaim2_proxy_info_set_username(phb->gpi, tmp);
-
- if ((tmp = g_getenv("HTTP_PROXY_PASS")) != NULL ||
- (tmp = g_getenv("http_proxy_pass")) != NULL ||
- (tmp = g_getenv("HTTPPROXYPASS")) != NULL)
-- gaim_proxy_info_set_password(phb->gpi, tmp);
-+ gaim2_proxy_info_set_password(phb->gpi, tmp);
- }
-
-- if ((gaim_proxy_info_get_type(phb->gpi) != GAIM_PROXY_NONE) &&
-- (gaim_proxy_info_get_host(phb->gpi) == NULL ||
-- gaim_proxy_info_get_port(phb->gpi) <= 0)) {
-+ if ((gaim2_proxy_info_get_type(phb->gpi) != GAIM_PROXY_NONE) &&
-+ (gaim2_proxy_info_get_host(phb->gpi) == NULL ||
-+ gaim2_proxy_info_get_port(phb->gpi) <= 0)) {
-
-- gaim_notify_error(NULL, NULL, _("Invalid proxy settings"), _("Either the host name or port number specified for your given proxy type is invalid."));
-+ gaim2_notify_error(NULL, NULL, _("Invalid proxy settings"), _("Either the host name or port number specified for your given proxy type is invalid."));
- g_free(phb->host);
- g_free(phb);
- return -1;
- }
-
-- switch (gaim_proxy_info_get_type(phb->gpi))
-+ switch (gaim2_proxy_info_get_type(phb->gpi))
- {
- case GAIM_PROXY_NONE:
- break;
-@@ -2031,8 +2031,8 @@ gaim_proxy_connect(GaimAccount *account,
- case GAIM_PROXY_SOCKS4:
- case GAIM_PROXY_SOCKS5:
- case GAIM_PROXY_USE_ENVVAR:
-- connecthost = gaim_proxy_info_get_host(phb->gpi);
-- connectport = gaim_proxy_info_get_port(phb->gpi);
-+ connecthost = gaim2_proxy_info_get_host(phb->gpi);
-+ connectport = gaim2_proxy_info_get_port(phb->gpi);
- break;
-
- default:
-@@ -2041,13 +2041,13 @@ gaim_proxy_connect(GaimAccount *account,
- return -1;
- }
-
-- return gaim_gethostbyname_async(connecthost, connectport,
-+ return gaim2_gethostbyname_async(connecthost, connectport,
- connection_host_resolved, phb);
- }
-
- int
--gaim_proxy_connect_socks5(GaimProxyInfo *gpi, const char *host, int port,
-- GaimInputFunction func, gpointer data)
-+gaim2_proxy_connect_socks5(Gaim2ProxyInfo *gpi, const char *host, int port,
-+ Gaim2InputFunction func, gpointer data)
- {
- struct PHB *phb;
-
-@@ -2058,16 +2058,16 @@ gaim_proxy_connect_socks5(GaimProxyInfo
- phb->host = g_strdup(host);
- phb->port = port;
-
-- return gaim_gethostbyname_async(gaim_proxy_info_get_host(gpi), gaim_proxy_info_get_port(gpi),
-+ return gaim2_gethostbyname_async(gaim2_proxy_info_get_host(gpi), gaim2_proxy_info_get_port(gpi),
- connection_host_resolved, phb);
- }
-
-
- static void
--proxy_pref_cb(const char *name, GaimPrefType type, gpointer value,
-+proxy_pref_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
-- GaimProxyInfo *info = gaim_global_proxy_get_info();
-+ Gaim2ProxyInfo *info = gaim2_global_proxy_get_info();
-
- if (!strcmp(name, "/core/proxy/type")) {
- int proxytype;
-@@ -2086,44 +2086,44 @@ proxy_pref_cb(const char *name, GaimPref
- else
- proxytype = -1;
-
-- gaim_proxy_info_set_type(info, proxytype);
-+ gaim2_proxy_info_set_type(info, proxytype);
- } else if (!strcmp(name, "/core/proxy/host"))
-- gaim_proxy_info_set_host(info, value);
-+ gaim2_proxy_info_set_host(info, value);
- else if (!strcmp(name, "/core/proxy/port"))
-- gaim_proxy_info_set_port(info, GPOINTER_TO_INT(value));
-+ gaim2_proxy_info_set_port(info, GPOINTER_TO_INT(value));
- else if (!strcmp(name, "/core/proxy/username"))
-- gaim_proxy_info_set_username(info, value);
-+ gaim2_proxy_info_set_username(info, value);
- else if (!strcmp(name, "/core/proxy/password"))
-- gaim_proxy_info_set_password(info, value);
-+ gaim2_proxy_info_set_password(info, value);
- }
-
- void
--gaim_proxy_init(void)
-+gaim2_proxy_init(void)
- {
- void *handle;
-
- /* Initialize a default proxy info struct. */
-- global_proxy_info = gaim_proxy_info_new();
-+ global_proxy_info = gaim2_proxy_info_new();
-
- /* Proxy */
-- gaim_prefs_add_none("/core/proxy");
-- gaim_prefs_add_string("/core/proxy/type", "none");
-- gaim_prefs_add_string("/core/proxy/host", "");
-- gaim_prefs_add_int("/core/proxy/port", 0);
-- gaim_prefs_add_string("/core/proxy/username", "");
-- gaim_prefs_add_string("/core/proxy/password", "");
-+ gaim2_prefs_add_none("/core/proxy");
-+ gaim2_prefs_add_string("/core/proxy/type", "none");
-+ gaim2_prefs_add_string("/core/proxy/host", "");
-+ gaim2_prefs_add_int("/core/proxy/port", 0);
-+ gaim2_prefs_add_string("/core/proxy/username", "");
-+ gaim2_prefs_add_string("/core/proxy/password", "");
-
- /* Setup callbacks for the preferences. */
-- handle = gaim_proxy_get_handle();
-- gaim_prefs_connect_callback(handle, "/core/proxy/type",
-+ handle = gaim2_proxy_get_handle();
-+ gaim2_prefs_connect_callback(handle, "/core/proxy/type",
- proxy_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/core/proxy/host",
-+ gaim2_prefs_connect_callback(handle, "/core/proxy/host",
- proxy_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/core/proxy/port",
-+ gaim2_prefs_connect_callback(handle, "/core/proxy/port",
- proxy_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/core/proxy/username",
-+ gaim2_prefs_connect_callback(handle, "/core/proxy/username",
- proxy_pref_cb, NULL);
-- gaim_prefs_connect_callback(handle, "/core/proxy/password",
-+ gaim2_prefs_connect_callback(handle, "/core/proxy/password",
- proxy_pref_cb, NULL);
- #ifdef _WIN32
- if(!g_thread_supported())
-@@ -2132,7 +2132,7 @@ gaim_proxy_init(void)
- }
-
- void *
--gaim_proxy_get_handle()
-+gaim2_proxy_get_handle()
- {
- static int handle;
-
-diff -prNu ./src/proxy.h ./src/proxy.h
---- ./src/proxy.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/proxy.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file proxy.h Proxy API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -40,21 +40,21 @@ typedef enum
- GAIM_PROXY_SOCKS5, /**< SOCKS 5 proxy. */
- GAIM_PROXY_USE_ENVVAR /**< Use environmental settings. */
-
--} GaimProxyType;
-+} Gaim2ProxyType;
-
- /**
- * Information on proxy settings.
- */
- typedef struct
- {
-- GaimProxyType type; /**< The proxy type. */
-+ Gaim2ProxyType type; /**< The proxy type. */
-
- char *host; /**< The host. */
- int port; /**< The port number. */
- char *username; /**< The username. */
- char *password; /**< The password. */
-
--} GaimProxyInfo;
-+} Gaim2ProxyInfo;
-
-
- #include "account.h"
-@@ -73,21 +73,21 @@ extern "C" {
- *
- * @return the handle to the proxy system
- */
--void *gaim_proxy_get_handle(void);
-+void *gaim2_proxy_get_handle(void);
-
- /**
- * Creates a proxy information structure.
- *
- * @return The proxy information structure.
- */
--GaimProxyInfo *gaim_proxy_info_new(void);
-+Gaim2ProxyInfo *gaim2_proxy_info_new(void);
-
- /**
- * Destroys a proxy information structure.
- *
- * @param info The proxy information structure to destroy.
- */
--void gaim_proxy_info_destroy(GaimProxyInfo *info);
-+void gaim2_proxy_info_destroy(Gaim2ProxyInfo *info);
-
- /**
- * Sets the type of proxy.
-@@ -95,7 +95,7 @@ void gaim_proxy_info_destroy(GaimProxyIn
- * @param info The proxy information.
- * @param type The proxy type.
- */
--void gaim_proxy_info_set_type(GaimProxyInfo *info, GaimProxyType type);
-+void gaim2_proxy_info_set_type(Gaim2ProxyInfo *info, Gaim2ProxyType type);
-
- /**
- * Sets the proxy host.
-@@ -103,7 +103,7 @@ void gaim_proxy_info_set_type(GaimProxyI
- * @param info The proxy information.
- * @param host The host.
- */
--void gaim_proxy_info_set_host(GaimProxyInfo *info, const char *host);
-+void gaim2_proxy_info_set_host(Gaim2ProxyInfo *info, const char *host);
-
- /**
- * Sets the proxy port.
-@@ -111,7 +111,7 @@ void gaim_proxy_info_set_host(GaimProxyI
- * @param info The proxy information.
- * @param port The port.
- */
--void gaim_proxy_info_set_port(GaimProxyInfo *info, int port);
-+void gaim2_proxy_info_set_port(Gaim2ProxyInfo *info, int port);
-
- /**
- * Sets the proxy username.
-@@ -119,7 +119,7 @@ void gaim_proxy_info_set_port(GaimProxyI
- * @param info The proxy information.
- * @param username The username.
- */
--void gaim_proxy_info_set_username(GaimProxyInfo *info, const char *username);
-+void gaim2_proxy_info_set_username(Gaim2ProxyInfo *info, const char *username);
-
- /**
- * Sets the proxy password.
-@@ -127,7 +127,7 @@ void gaim_proxy_info_set_username(GaimPr
- * @param info The proxy information.
- * @param password The password.
- */
--void gaim_proxy_info_set_password(GaimProxyInfo *info, const char *password);
-+void gaim2_proxy_info_set_password(Gaim2ProxyInfo *info, const char *password);
-
- /**
- * Returns the proxy's type.
-@@ -136,7 +136,7 @@ void gaim_proxy_info_set_password(GaimPr
- *
- * @return The type.
- */
--GaimProxyType gaim_proxy_info_get_type(const GaimProxyInfo *info);
-+Gaim2ProxyType gaim2_proxy_info_get_type(const Gaim2ProxyInfo *info);
-
- /**
- * Returns the proxy's host.
-@@ -145,7 +145,7 @@ GaimProxyType gaim_proxy_info_get_type(c
- *
- * @return The host.
- */
--const char *gaim_proxy_info_get_host(const GaimProxyInfo *info);
-+const char *gaim2_proxy_info_get_host(const Gaim2ProxyInfo *info);
-
- /**
- * Returns the proxy's port.
-@@ -154,7 +154,7 @@ const char *gaim_proxy_info_get_host(con
- *
- * @return The port.
- */
--int gaim_proxy_info_get_port(const GaimProxyInfo *info);
-+int gaim2_proxy_info_get_port(const Gaim2ProxyInfo *info);
-
- /**
- * Returns the proxy's username.
-@@ -163,7 +163,7 @@ int gaim_proxy_info_get_port(const GaimP
- *
- * @return The username.
- */
--const char *gaim_proxy_info_get_username(const GaimProxyInfo *info);
-+const char *gaim2_proxy_info_get_username(const Gaim2ProxyInfo *info);
-
- /**
- * Returns the proxy's password.
-@@ -172,7 +172,7 @@ const char *gaim_proxy_info_get_username
- *
- * @return The password.
- */
--const char *gaim_proxy_info_get_password(const GaimProxyInfo *info);
-+const char *gaim2_proxy_info_get_password(const Gaim2ProxyInfo *info);
-
- /*@}*/
-
-@@ -182,11 +182,11 @@ const char *gaim_proxy_info_get_password
- /*@{*/
-
- /**
-- * Returns gaim's global proxy information.
-+ * Returns gaim2's global proxy information.
- *
- * @return The global proxy information.
- */
--GaimProxyInfo *gaim_global_proxy_get_info(void);
-+Gaim2ProxyInfo *gaim2_global_proxy_get_info(void);
-
- /*@}*/
-
-@@ -198,7 +198,7 @@ GaimProxyInfo *gaim_global_proxy_get_inf
- /**
- * Initializes the proxy subsystem.
- */
--void gaim_proxy_init(void);
-+void gaim2_proxy_init(void);
-
- /**
- * Makes a connection to the specified host and port.
-@@ -211,13 +211,13 @@ void gaim_proxy_init(void);
- *
- * @return Zero indicates the connection is pending. Any other value indicates failure.
- */
--int gaim_proxy_connect(GaimAccount *account, const char *host, int port,
-- GaimInputFunction func, gpointer data);
-+int gaim2_proxy_connect(Gaim2Account *account, const char *host, int port,
-+ Gaim2InputFunction func, gpointer data);
-
- /**
- * Makes a connection through a SOCKS5 proxy.
- *
-- * @param gpi The GaimProxyInfo specifying the proxy settings
-+ * @param gpi The Gaim2ProxyInfo specifying the proxy settings
- * @param host The destination host.
- * @param port The destination port.
- * @param func The input handler function.
-@@ -225,8 +225,8 @@ int gaim_proxy_connect(GaimAccount *acco
- *
- * @return Zero indicates the connection is pending. Any other value indicates failure.
- */
--int gaim_proxy_connect_socks5(GaimProxyInfo *gpi, const char *host, int port,
-- GaimInputFunction func, gpointer data);
-+int gaim2_proxy_connect_socks5(Gaim2ProxyInfo *gpi, const char *host, int port,
-+ Gaim2InputFunction func, gpointer data);
-
- typedef void (*dns_callback_t)(GSList *hosts, gpointer data,
- const char *error_message);
-@@ -239,7 +239,7 @@ typedef void (*dns_callback_t)(GSList *h
- * @param data Extra data for the callback function
- * @return a GSList containing the size of followed by the struct sockaddr for any returned IP
- */
--int gaim_gethostbyname_async(const char *hostname, int port, dns_callback_t callback, gpointer data);
-+int gaim2_gethostbyname_async(const char *hostname, int port, dns_callback_t callback, gpointer data);
-
- /*@}*/
-
-diff -prNu ./src/prpl.c ./src/prpl.c
---- ./src/prpl.c 2005-12-25 06:34:43.000000000 +0100
-+++ ./src/prpl.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,114 +32,114 @@
- /** @name Protocol Plugin API */
- /**************************************************************************/
- void
--gaim_prpl_got_account_idle(GaimAccount *account, gboolean idle,
-+gaim2_prpl_got_account_idle(Gaim2Account *account, gboolean idle,
- time_t idle_time)
- {
- g_return_if_fail(account != NULL);
-- g_return_if_fail(gaim_account_is_connected(account));
-+ g_return_if_fail(gaim2_account_is_connected(account));
-
-- gaim_presence_set_idle(gaim_account_get_presence(account),
-+ gaim2_presence_set_idle(gaim2_account_get_presence(account),
- idle, idle_time);
- }
-
- void
--gaim_prpl_got_account_login_time(GaimAccount *account, time_t login_time)
-+gaim2_prpl_got_account_login_time(Gaim2Account *account, time_t login_time)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
-
- g_return_if_fail(account != NULL);
-- g_return_if_fail(gaim_account_is_connected(account));
-+ g_return_if_fail(gaim2_account_is_connected(account));
-
- if (login_time == 0)
- login_time = time(NULL);
-
-- presence = gaim_account_get_presence(account);
-+ presence = gaim2_account_get_presence(account);
-
-- gaim_presence_set_login_time(presence, login_time);
-+ gaim2_presence_set_login_time(presence, login_time);
- }
-
- static gboolean
--set_value_from_arg(GaimStatus *status, const char *id, va_list *args)
-+set_value_from_arg(Gaim2Status *status, const char *id, va_list *args)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
-- value = gaim_status_get_attr_value(status, id);
-+ value = gaim2_status_get_attr_value(status, id);
-
- if (value == NULL)
- {
-- gaim_debug_error("prpl",
-+ gaim2_debug_error("prpl",
- "Attempted to set an unknown attribute %s on "
- "status %s\n",
-- id, gaim_status_get_id(status));
-+ id, gaim2_status_get_id(status));
- return FALSE;
- }
-
-- switch (gaim_value_get_type(value))
-+ switch (gaim2_value_get_type(value))
- {
- case GAIM_TYPE_CHAR:
-- gaim_value_set_char(value, (char)va_arg(*args, int));
-+ gaim2_value_set_char(value, (char)va_arg(*args, int));
- break;
-
- case GAIM_TYPE_UCHAR:
-- gaim_value_set_uchar(value,
-+ gaim2_value_set_uchar(value,
- (unsigned char)va_arg(*args, unsigned int));
- break;
-
- case GAIM_TYPE_BOOLEAN:
-- gaim_value_set_boolean(value, va_arg(*args, gboolean));
-+ gaim2_value_set_boolean(value, va_arg(*args, gboolean));
- break;
-
- case GAIM_TYPE_SHORT:
-- gaim_value_set_short(value, (short)va_arg(*args, int));
-+ gaim2_value_set_short(value, (short)va_arg(*args, int));
- break;
-
- case GAIM_TYPE_USHORT:
-- gaim_value_set_ushort(value,
-+ gaim2_value_set_ushort(value,
- (unsigned short)va_arg(*args, unsigned int));
- break;
-
- case GAIM_TYPE_INT:
-- gaim_value_set_int(value, va_arg(*args, int));
-+ gaim2_value_set_int(value, va_arg(*args, int));
- break;
-
- case GAIM_TYPE_UINT:
-- gaim_value_set_uint(value, va_arg(*args, unsigned int));
-+ gaim2_value_set_uint(value, va_arg(*args, unsigned int));
- break;
-
- case GAIM_TYPE_LONG:
-- gaim_value_set_long(value, va_arg(*args, long));
-+ gaim2_value_set_long(value, va_arg(*args, long));
- break;
-
- case GAIM_TYPE_ULONG:
-- gaim_value_set_ulong(value, va_arg(*args, unsigned long));
-+ gaim2_value_set_ulong(value, va_arg(*args, unsigned long));
- break;
-
- case GAIM_TYPE_INT64:
-- gaim_value_set_int64(value, va_arg(*args, gint64));
-+ gaim2_value_set_int64(value, va_arg(*args, gint64));
- break;
-
- case GAIM_TYPE_UINT64:
-- gaim_value_set_uint64(value, va_arg(*args, guint64));
-+ gaim2_value_set_uint64(value, va_arg(*args, guint64));
- break;
-
- case GAIM_TYPE_STRING:
-- gaim_value_set_string(value, va_arg(*args, char *));
-+ gaim2_value_set_string(value, va_arg(*args, char *));
- break;
-
- case GAIM_TYPE_OBJECT:
-- gaim_value_set_object(value, va_arg(*args, void *));
-+ gaim2_value_set_object(value, va_arg(*args, void *));
- break;
-
- case GAIM_TYPE_POINTER:
-- gaim_value_set_pointer(value, va_arg(*args, void *));
-+ gaim2_value_set_pointer(value, va_arg(*args, void *));
- break;
-
- case GAIM_TYPE_ENUM:
-- gaim_value_set_enum(value, va_arg(*args, int));
-+ gaim2_value_set_enum(value, va_arg(*args, int));
- break;
-
- case GAIM_TYPE_BOXED:
-- gaim_value_set_boxed(value, va_arg(*args, void *));
-+ gaim2_value_set_boxed(value, va_arg(*args, void *));
- break;
-
- default:
-@@ -150,18 +150,18 @@ set_value_from_arg(GaimStatus *status, c
- }
-
- void
--gaim_prpl_got_account_status(GaimAccount *account, const char *status_id,
-+gaim2_prpl_got_account_status(Gaim2Account *account, const char *status_id,
- const char *attr_id, ...)
- {
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(status_id != NULL);
-- g_return_if_fail(gaim_account_is_connected(account));
-+ g_return_if_fail(gaim2_account_is_connected(account));
-
-- presence = gaim_account_get_presence(account);
-- status = gaim_presence_get_status(presence, status_id);
-+ presence = gaim2_account_get_presence(account);
-+ status = gaim2_presence_get_status(presence, status_id);
-
- g_return_if_fail(status != NULL);
-
-@@ -181,69 +181,69 @@ gaim_prpl_got_account_status(GaimAccount
- va_end(args);
- }
-
-- gaim_presence_set_status_active(presence, status_id, TRUE);
-+ gaim2_presence_set_status_active(presence, status_id, TRUE);
- }
-
- void
--gaim_prpl_got_user_idle(GaimAccount *account, const char *name,
-+gaim2_prpl_got_user_idle(Gaim2Account *account, const char *name,
- gboolean idle, time_t idle_time)
- {
-- GaimBuddy *buddy;
-- GaimPresence *presence;
-+ Gaim2Buddy *buddy;
-+ Gaim2Presence *presence;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(name != NULL);
-- g_return_if_fail(gaim_account_is_connected(account));
-+ g_return_if_fail(gaim2_account_is_connected(account));
-
-- if ((buddy = gaim_find_buddy(account, name)) == NULL)
-+ if ((buddy = gaim2_find_buddy(account, name)) == NULL)
- return;
-
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
-- gaim_presence_set_idle(presence, idle, idle_time);
-+ gaim2_presence_set_idle(presence, idle, idle_time);
- }
-
- void
--gaim_prpl_got_user_login_time(GaimAccount *account, const char *name,
-+gaim2_prpl_got_user_login_time(Gaim2Account *account, const char *name,
- time_t login_time)
- {
-- GaimBuddy *buddy;
-- GaimPresence *presence;
-+ Gaim2Buddy *buddy;
-+ Gaim2Presence *presence;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(name != NULL);
-
-- if ((buddy = gaim_find_buddy(account, name)) == NULL)
-+ if ((buddy = gaim2_find_buddy(account, name)) == NULL)
- return;
-
- if (login_time == 0)
- login_time = time(NULL);
-
-- presence = gaim_buddy_get_presence(buddy);
-+ presence = gaim2_buddy_get_presence(buddy);
-
-- gaim_presence_set_login_time(presence, login_time);
-+ gaim2_presence_set_login_time(presence, login_time);
- }
-
- void
--gaim_prpl_got_user_status(GaimAccount *account, const char *name,
-+gaim2_prpl_got_user_status(Gaim2Account *account, const char *name,
- const char *status_id, const char *attr_id, ...)
- {
- GSList *list, *iter;
-- GaimBuddy *buddy;
-- GaimPresence *presence;
-- GaimStatus *status;
-- GaimStatus *old_status;
-+ Gaim2Buddy *buddy;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
-+ Gaim2Status *old_status;
-
- g_return_if_fail(account != NULL);
- g_return_if_fail(name != NULL);
- g_return_if_fail(status_id != NULL);
-- g_return_if_fail(gaim_account_is_connected(account) || gaim_account_is_connecting(account));
-+ g_return_if_fail(gaim2_account_is_connected(account) || gaim2_account_is_connecting(account));
-
-- if ((buddy = gaim_find_buddy(account, name)) == NULL)
-+ if ((buddy = gaim2_find_buddy(account, name)) == NULL)
- return;
-
-- presence = gaim_buddy_get_presence(buddy);
-- status = gaim_presence_get_status(presence, status_id);
-+ presence = gaim2_buddy_get_presence(buddy);
-+ status = gaim2_presence_get_status(presence, status_id);
-
- g_return_if_fail(status != NULL);
-
-@@ -263,43 +263,43 @@ gaim_prpl_got_user_status(GaimAccount *a
- va_end(args);
- }
-
-- old_status = gaim_presence_get_active_status(presence);
-- gaim_presence_set_status_active(presence, status_id, TRUE);
-+ old_status = gaim2_presence_get_active_status(presence);
-+ gaim2_presence_set_status_active(presence, status_id, TRUE);
-
-- list = gaim_find_buddies(account, name);
-+ list = gaim2_find_buddies(account, name);
- for (iter = list; iter != NULL; iter = iter->next)
- {
-- buddy = (GaimBuddy *)iter->data;
-- gaim_blist_update_buddy_status(buddy, old_status);
-+ buddy = (Gaim2Buddy *)iter->data;
-+ gaim2_blist_update_buddy_status(buddy, old_status);
- }
- g_slist_free(list);
-
-- if (!gaim_status_is_online(status))
-- serv_got_typing_stopped(gaim_account_get_connection(account), name);
-+ if (!gaim2_status_is_online(status))
-+ serv_got_typing_stopped(gaim2_account_get_connection(account), name);
- }
-
- static void
--do_prpl_change_account_status(GaimAccount *account,
-- GaimStatus *old_status, GaimStatus *new_status)
-+do_prpl_change_account_status(Gaim2Account *account,
-+ Gaim2Status *old_status, Gaim2Status *new_status)
- {
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
-
-- if (gaim_status_is_online(new_status) &&
-- gaim_account_is_disconnected(account))
-+ if (gaim2_status_is_online(new_status) &&
-+ gaim2_account_is_disconnected(account))
- {
-- gaim_account_connect(account);
-+ gaim2_account_connect(account);
- return;
- }
-
-- if (!gaim_status_is_online(new_status))
-+ if (!gaim2_status_is_online(new_status))
- {
-- if (!gaim_account_is_disconnected(account))
-- gaim_account_disconnect(account);
-+ if (!gaim2_account_is_disconnected(account))
-+ gaim2_account_disconnect(account);
- return;
- }
-
-- if (gaim_account_is_connecting(account))
-+ if (gaim2_account_is_connecting(account))
- /*
- * We don't need to call the set_status PRPL function because
- * the PRPL will take care of setting its status during the
-@@ -307,7 +307,7 @@ do_prpl_change_account_status(GaimAccoun
- */
- return;
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- if (prpl == NULL)
- return;
-@@ -321,8 +321,8 @@ do_prpl_change_account_status(GaimAccoun
- }
-
- void
--gaim_prpl_change_account_status(GaimAccount *account,
-- GaimStatus *old_status, GaimStatus *new_status)
-+gaim2_prpl_change_account_status(Gaim2Account *account,
-+ Gaim2Status *old_status, Gaim2Status *new_status)
- {
- g_return_if_fail(account != NULL);
- g_return_if_fail(old_status != NULL);
-@@ -330,23 +330,23 @@ gaim_prpl_change_account_status(GaimAcco
-
- do_prpl_change_account_status(account, old_status, new_status);
-
-- gaim_signal_emit(gaim_accounts_get_handle(), "account-status-changed",
-+ gaim2_signal_emit(gaim2_accounts_get_handle(), "account-status-changed",
- account, old_status, new_status);
- }
-
- GList *
--gaim_prpl_get_statuses(GaimAccount *account, GaimPresence *presence)
-+gaim2_prpl_get_statuses(Gaim2Account *account, Gaim2Presence *presence)
- {
-- GaimPlugin *prpl;
-- GaimPluginProtocolInfo *prpl_info;
-+ Gaim2Plugin *prpl;
-+ Gaim2PluginProtocolInfo *prpl_info;
- GList *statuses = NULL;
- GList *l, *list;
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- g_return_val_if_fail(account != NULL, NULL);
- g_return_val_if_fail(presence != NULL, NULL);
-
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- if (prpl == NULL)
- return NULL;
-@@ -357,7 +357,7 @@ gaim_prpl_get_statuses(GaimAccount *acco
-
- for (l = list = prpl_info->status_types(account); l != NULL; l = l->next)
- {
-- status = gaim_status_new((GaimStatusType *)l->data, presence);
-+ status = gaim2_status_new((Gaim2StatusType *)l->data, presence);
- statuses = g_list_append(statuses, status);
- }
-
-@@ -371,16 +371,16 @@ gaim_prpl_get_statuses(GaimAccount *acco
- * Protocol Plugin Subsystem API
- **************************************************************************/
-
--GaimPlugin *
--gaim_find_prpl(const char *id)
-+Gaim2Plugin *
-+gaim2_find_prpl(const char *id)
- {
- GList *l;
-- GaimPlugin *plugin;
-+ Gaim2Plugin *plugin;
-
- g_return_val_if_fail(id != NULL, NULL);
-
-- for (l = gaim_plugins_get_protocols(); l != NULL; l = l->next) {
-- plugin = (GaimPlugin *)l->data;
-+ for (l = gaim2_plugins_get_protocols(); l != NULL; l = l->next) {
-+ plugin = (Gaim2Plugin *)l->data;
-
- if (!strcmp(plugin->info->id, id))
- return plugin;
-diff -prNu ./src/prpl.h ./src/prpl.h
---- ./src/prpl.h 2005-12-23 20:25:43.000000000 +0100
-+++ ./src/prpl.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file prpl.h Protocol Plugin functions
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -24,12 +24,12 @@
- */
-
- /* this file should be all that prpls need to include. therefore, by including
-- * this file, they should get glib, proxy, gaim_connection, prpl, etc. */
-+ * this file, they should get glib, proxy, gaim2_connection, prpl, etc. */
-
- #ifndef _GAIM_PRPL_H_
- #define _GAIM_PRPL_H_
-
--typedef struct _GaimPluginProtocolInfo GaimPluginProtocolInfo;
-+typedef struct _Gaim2PluginProtocolInfo Gaim2PluginProtocolInfo;
-
- /**************************************************************************/
- /** @name Basic Protocol Information */
-@@ -38,11 +38,11 @@ typedef struct _GaimPluginProtocolInfo G
- typedef enum {
- GAIM_ICON_SCALE_DISPLAY = 0x01, /**< We scale the icon when we display it */
- GAIM_ICON_SCALE_SEND = 0x02 /**< We scale the icon before we send it to the server */
--} GaimIconScaleRules;
-+} Gaim2IconScaleRules;
-
-
- /**
-- * A description of a Buddy Icon specification. This tells Gaim what kind of image file
-+ * A description of a Buddy Icon specification. This tells Gaim2 what kind of image file
- * it should give this prpl, and what kind of image file it should expect back.
- * Dimensions less than 1 should be ignored and the image not scaled.
- */
-@@ -54,8 +54,8 @@ typedef struct {
- int min_height; /**< The minimum height of this icon */
- int max_width; /**< The maximum width of this icon */
- int max_height; /**< The maximum height of this icon */
-- GaimIconScaleRules scale_rules; /**< How to stretch this icon */
--} GaimBuddyIconSpec;
-+ Gaim2IconScaleRules scale_rules; /**< How to stretch this icon */
-+} Gaim2BuddyIconSpec;
-
- /**
- * This \#define exists just to make it easier to fill out the buddy icon
-@@ -150,66 +150,66 @@ typedef enum
- */
- OPT_PROTO_REGISTER_NOSCREENNAME = 0x00000200,
-
--} GaimProtocolOptions;
-+} Gaim2ProtocolOptions;
-
- /**
- * A protocol plugin information structure.
- *
- * Every protocol plugin initializes this structure. It is the gateway
-- * between gaim and the protocol plugin. Many of this callbacks can be
-+ * between gaim2 and the protocol plugin. Many of this callbacks can be
- * NULL. If a callback must be implemented, it has a comment indicating so.
- */
--struct _GaimPluginProtocolInfo
-+struct _Gaim2PluginProtocolInfo
- {
-- GaimProtocolOptions options; /**< Protocol options. */
-+ Gaim2ProtocolOptions options; /**< Protocol options. */
-
-- GList *user_splits; /* A GList of GaimAccountUserSplit */
-- GList *protocol_options; /* A GList of GaimAccountOption */
-+ GList *user_splits; /* A GList of Gaim2AccountUserSplit */
-+ GList *protocol_options; /* A GList of Gaim2AccountOption */
-
-- GaimBuddyIconSpec icon_spec; /* The icon spec. */
-+ Gaim2BuddyIconSpec icon_spec; /* The icon spec. */
-
- /**
- * Returns the base icon name for the given buddy and account.
- * If buddy is NULL, it will return the name to use for the account's
- * icon. This must be implemented.
- */
-- const char *(*list_icon)(GaimAccount *account, GaimBuddy *buddy);
-+ const char *(*list_icon)(Gaim2Account *account, Gaim2Buddy *buddy);
-
- /**
- * Fills the four char**'s with string identifiers for "emblems"
- * that the UI will interpret and display as relevant
- */
-- void (*list_emblems)(GaimBuddy *buddy, const char **se, const char **sw,
-+ void (*list_emblems)(Gaim2Buddy *buddy, const char **se, const char **sw,
- const char **nw, const char **ne);
-
- /**
- * Gets a short string representing this buddy's status. This will
- * be shown on the buddy list.
- */
-- char *(*status_text)(GaimBuddy *buddy);
-+ char *(*status_text)(Gaim2Buddy *buddy);
-
- /**
- * Gets a string to put in the buddy list tooltip.
- */
-- char *(*tooltip_text)(GaimBuddy *buddy);
-+ char *(*tooltip_text)(Gaim2Buddy *buddy);
-
- /**
- * This must be implemented, and must add at least the offline
- * and online states.
- */
-- GList *(*status_types)(GaimAccount *account);
-+ GList *(*status_types)(Gaim2Account *account);
-
-- GList *(*blist_node_menu)(GaimBlistNode *node);
-- GList *(*chat_info)(GaimConnection *);
-- GHashTable *(*chat_info_defaults)(GaimConnection *, const char *chat_name);
-+ GList *(*blist_node_menu)(Gaim2BlistNode *node);
-+ GList *(*chat_info)(Gaim2Connection *);
-+ GHashTable *(*chat_info_defaults)(Gaim2Connection *, const char *chat_name);
-
- /* All the server-related functions */
-
- /** This must be implemented. */
-- void (*login)(GaimAccount *);
-+ void (*login)(Gaim2Account *);
-
- /** This must be implemented. */
-- void (*close)(GaimConnection *);
-+ void (*close)(Gaim2Connection *);
-
- /**
- * This PRPL function should return a positive value on success.
-@@ -220,93 +220,93 @@ struct _GaimPluginProtocolInfo
- * errno values, or just big something. If the message should
- * not be echoed to the conversation window, return 0.
- */
-- int (*send_im)(GaimConnection *, const char *who,
-+ int (*send_im)(Gaim2Connection *, const char *who,
- const char *message,
-- GaimMessageFlags flags);
-+ Gaim2MessageFlags flags);
-
-- void (*set_info)(GaimConnection *, const char *info);
-- int (*send_typing)(GaimConnection *, const char *name, int typing);
-- void (*get_info)(GaimConnection *, const char *who);
-- void (*set_status)(GaimAccount *account, GaimStatus *status);
-+ void (*set_info)(Gaim2Connection *, const char *info);
-+ int (*send_typing)(Gaim2Connection *, const char *name, int typing);
-+ void (*get_info)(Gaim2Connection *, const char *who);
-+ void (*set_status)(Gaim2Account *account, Gaim2Status *status);
-
-- void (*set_idle)(GaimConnection *, int idletime);
-- void (*change_passwd)(GaimConnection *, const char *old_pass,
-+ void (*set_idle)(Gaim2Connection *, int idletime);
-+ void (*change_passwd)(Gaim2Connection *, const char *old_pass,
- const char *new_pass);
-- void (*add_buddy)(GaimConnection *, GaimBuddy *buddy, GaimGroup *group);
-- void (*add_buddies)(GaimConnection *, GList *buddies, GList *groups);
-- void (*remove_buddy)(GaimConnection *, GaimBuddy *buddy, GaimGroup *group);
-- void (*remove_buddies)(GaimConnection *, GList *buddies, GList *groups);
-- void (*add_permit)(GaimConnection *, const char *name);
-- void (*add_deny)(GaimConnection *, const char *name);
-- void (*rem_permit)(GaimConnection *, const char *name);
-- void (*rem_deny)(GaimConnection *, const char *name);
-- void (*set_permit_deny)(GaimConnection *);
-- void (*join_chat)(GaimConnection *, GHashTable *components);
-- void (*reject_chat)(GaimConnection *, GHashTable *components);
-+ void (*add_buddy)(Gaim2Connection *, Gaim2Buddy *buddy, Gaim2Group *group);
-+ void (*add_buddies)(Gaim2Connection *, GList *buddies, GList *groups);
-+ void (*remove_buddy)(Gaim2Connection *, Gaim2Buddy *buddy, Gaim2Group *group);
-+ void (*remove_buddies)(Gaim2Connection *, GList *buddies, GList *groups);
-+ void (*add_permit)(Gaim2Connection *, const char *name);
-+ void (*add_deny)(Gaim2Connection *, const char *name);
-+ void (*rem_permit)(Gaim2Connection *, const char *name);
-+ void (*rem_deny)(Gaim2Connection *, const char *name);
-+ void (*set_permit_deny)(Gaim2Connection *);
-+ void (*join_chat)(Gaim2Connection *, GHashTable *components);
-+ void (*reject_chat)(Gaim2Connection *, GHashTable *components);
- char *(*get_chat_name)(GHashTable *components);
-- void (*chat_invite)(GaimConnection *, int id,
-+ void (*chat_invite)(Gaim2Connection *, int id,
- const char *who, const char *message);
-- void (*chat_leave)(GaimConnection *, int id);
-- void (*chat_whisper)(GaimConnection *, int id,
-+ void (*chat_leave)(Gaim2Connection *, int id);
-+ void (*chat_whisper)(Gaim2Connection *, int id,
- const char *who, const char *message);
-- int (*chat_send)(GaimConnection *, int id, const char *message, GaimMessageFlags flags);
-- void (*keepalive)(GaimConnection *);
-+ int (*chat_send)(Gaim2Connection *, int id, const char *message, Gaim2MessageFlags flags);
-+ void (*keepalive)(Gaim2Connection *);
-
- /* new user registration */
-- void (*register_user)(GaimAccount *);
-+ void (*register_user)(Gaim2Account *);
-
- /* get "chat buddy" info and away message */
-- void (*get_cb_info)(GaimConnection *, int, const char *who);
-- void (*get_cb_away)(GaimConnection *, int, const char *who);
-+ void (*get_cb_info)(Gaim2Connection *, int, const char *who);
-+ void (*get_cb_away)(Gaim2Connection *, int, const char *who);
-
- /* save/store buddy's alias on server list/roster */
-- void (*alias_buddy)(GaimConnection *, const char *who,
-+ void (*alias_buddy)(Gaim2Connection *, const char *who,
- const char *alias);
-
- /* change a buddy's group on a server list/roster */
-- void (*group_buddy)(GaimConnection *, const char *who,
-+ void (*group_buddy)(Gaim2Connection *, const char *who,
- const char *old_group, const char *new_group);
-
- /* rename a group on a server list/roster */
-- void (*rename_group)(GaimConnection *, const char *old_name,
-- GaimGroup *group, GList *moved_buddies);
-+ void (*rename_group)(Gaim2Connection *, const char *old_name,
-+ Gaim2Group *group, GList *moved_buddies);
-
-- void (*buddy_free)(GaimBuddy *);
-+ void (*buddy_free)(Gaim2Buddy *);
-
-- void (*convo_closed)(GaimConnection *, const char *who);
-+ void (*convo_closed)(Gaim2Connection *, const char *who);
-
-- const char *(*normalize)(const GaimAccount *, const char *);
-+ const char *(*normalize)(const Gaim2Account *, const char *);
-
-- void (*set_buddy_icon)(GaimConnection *, const char *filename);
-+ void (*set_buddy_icon)(Gaim2Connection *, const char *filename);
-
-- void (*remove_group)(GaimConnection *gc, GaimGroup *group);
-+ void (*remove_group)(Gaim2Connection *gc, Gaim2Group *group);
-
-- char *(*get_cb_real_name)(GaimConnection *gc, int id, const char *who);
-+ char *(*get_cb_real_name)(Gaim2Connection *gc, int id, const char *who);
-
-- void (*set_chat_topic)(GaimConnection *gc, int id, const char *topic);
-+ void (*set_chat_topic)(Gaim2Connection *gc, int id, const char *topic);
-
-- GaimChat *(*find_blist_chat)(GaimAccount *account, const char *name);
-+ Gaim2Chat *(*find_blist_chat)(Gaim2Account *account, const char *name);
-
- /* room listing prpl callbacks */
-- GaimRoomlist *(*roomlist_get_list)(GaimConnection *gc);
-- void (*roomlist_cancel)(GaimRoomlist *list);
-- void (*roomlist_expand_category)(GaimRoomlist *list, GaimRoomlistRoom *category);
-+ Gaim2Roomlist *(*roomlist_get_list)(Gaim2Connection *gc);
-+ void (*roomlist_cancel)(Gaim2Roomlist *list);
-+ void (*roomlist_expand_category)(Gaim2Roomlist *list, Gaim2RoomlistRoom *category);
-
- /* file transfer callbacks */
-- gboolean (*can_receive_file)(GaimConnection *, const char *who);
-- void (*send_file)(GaimConnection *, const char *who, const char *filename);
-- GaimXfer *(*new_xfer)(GaimConnection *, const char *who);
-- gboolean (*offline_message)(const GaimBuddy *buddy);
-+ gboolean (*can_receive_file)(Gaim2Connection *, const char *who);
-+ void (*send_file)(Gaim2Connection *, const char *who, const char *filename);
-+ Gaim2Xfer *(*new_xfer)(Gaim2Connection *, const char *who);
-+ gboolean (*offline_message)(const Gaim2Buddy *buddy);
-
-- GaimWhiteboardPrplOps *whiteboard_prpl_ops;
-- GaimMediaPrplOps *media_prpl_ops;
-+ Gaim2WhiteboardPrplOps *whiteboard_prpl_ops;
-+ Gaim2MediaPrplOps *media_prpl_ops;
- };
-
- #define GAIM_IS_PROTOCOL_PLUGIN(plugin) \
- ((plugin)->info->type == GAIM_PLUGIN_PROTOCOL)
-
- #define GAIM_PLUGIN_PROTOCOL_INFO(plugin) \
-- ((GaimPluginProtocolInfo *)(plugin)->info->extra_info)
-+ ((Gaim2PluginProtocolInfo *)(plugin)->info->extra_info)
-
- #ifdef __cplusplus
- extern "C" {
-@@ -318,7 +318,7 @@ extern "C" {
- /*@{*/
-
- /**
-- * Notifies Gaim that an account's idle state and time have changed.
-+ * Notifies Gaim2 that an account's idle state and time have changed.
- *
- * This is meant to be called from protocol plugins.
- *
-@@ -326,21 +326,21 @@ extern "C" {
- * @param idle The user's idle state.
- * @param idle_time The user's idle time.
- */
--void gaim_prpl_got_account_idle(GaimAccount *account, gboolean idle,
-+void gaim2_prpl_got_account_idle(Gaim2Account *account, gboolean idle,
- time_t idle_time);
-
- /**
-- * Notifies Gaim of an account's log-in time.
-+ * Notifies Gaim2 of an account's log-in time.
- *
- * This is meant to be called from protocol plugins.
- *
- * @param account The account the user is on.
- * @param login_time The user's log-in time.
- */
--void gaim_prpl_got_account_login_time(GaimAccount *account, time_t login_time);
-+void gaim2_prpl_got_account_login_time(Gaim2Account *account, time_t login_time);
-
- /**
-- * Notifies Gaim that an account's status has changed.
-+ * Notifies Gaim2 that an account's status has changed.
- *
- * This is meant to be called from protocol plugins.
- *
-@@ -350,11 +350,11 @@ void gaim_prpl_got_account_login_time(Ga
- * @param ... A NULL-terminated list of attribute IDs and values,
- * beginning with the value for @a attr_id.
- */
--void gaim_prpl_got_account_status(GaimAccount *account,
-+void gaim2_prpl_got_account_status(Gaim2Account *account,
- const char *status_id, const char *attr_id,
- ...);
- /**
-- * Notifies Gaim that a user's idle state and time have changed.
-+ * Notifies Gaim2 that a user's idle state and time have changed.
- *
- * This is meant to be called from protocol plugins.
- *
-@@ -365,11 +365,11 @@ void gaim_prpl_got_account_status(GaimAc
- * which the user became idle, in seconds since
- * the epoch.
- */
--void gaim_prpl_got_user_idle(GaimAccount *account, const char *name,
-+void gaim2_prpl_got_user_idle(Gaim2Account *account, const char *name,
- gboolean idle, time_t idle_time);
-
- /**
-- * Notifies Gaim of a user's log-in time.
-+ * Notifies Gaim2 of a user's log-in time.
- *
- * This is meant to be called from protocol plugins.
- *
-@@ -377,11 +377,11 @@ void gaim_prpl_got_user_idle(GaimAccount
- * @param name The screen name of the user.
- * @param login_time The user's log-in time.
- */
--void gaim_prpl_got_user_login_time(GaimAccount *account, const char *name,
-+void gaim2_prpl_got_user_login_time(Gaim2Account *account, const char *name,
- time_t login_time);
-
- /**
-- * Notifies Gaim that a user's status has changed.
-+ * Notifies Gaim2 that a user's status has changed.
- *
- * This is meant to be called from protocol plugins.
- *
-@@ -392,7 +392,7 @@ void gaim_prpl_got_user_login_time(GaimA
- * @param ... A NULL-terminated list of attribute IDs and values,
- * beginning with the value for @a attr_id.
- */
--void gaim_prpl_got_user_status(GaimAccount *account, const char *name,
-+void gaim2_prpl_got_user_status(Gaim2Account *account, const char *name,
- const char *status_id, const char *attr_id, ...);
- /**
- * Informs the server that an account's status changed.
-@@ -402,9 +402,9 @@ void gaim_prpl_got_user_status(GaimAccou
- * @param new_status The status that was activated, or deactivated
- * (in the case of independent statuses).
- */
--void gaim_prpl_change_account_status(GaimAccount *account,
-- GaimStatus *old_status,
-- GaimStatus *new_status);
-+void gaim2_prpl_change_account_status(Gaim2Account *account,
-+ Gaim2Status *old_status,
-+ Gaim2Status *new_status);
-
- /**
- * Retrieves the list of stock status types from a prpl.
-@@ -414,7 +414,7 @@ void gaim_prpl_change_account_status(Gai
- *
- * @return List of statuses
- */
--GList *gaim_prpl_get_statuses(GaimAccount *account, GaimPresence *presence);
-+GList *gaim2_prpl_get_statuses(Gaim2Account *account, Gaim2Presence *presence);
-
- /*@}*/
-
-@@ -428,7 +428,7 @@ GList *gaim_prpl_get_statuses(GaimAccoun
- *
- * @param id The protocol plugin;
- */
--GaimPlugin *gaim_find_prpl(const char *id);
-+Gaim2Plugin *gaim2_find_prpl(const char *id);
-
- /*@}*/
-
-diff -prNu ./src/request.c ./src/request.c
---- ./src/request.c 2005-08-29 00:16:17.000000000 +0200
-+++ ./src/request.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file request.c Request API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,24 +26,24 @@
- #include "request.h"
- #include "debug.h"
-
--static GaimRequestUiOps *request_ui_ops = NULL;
-+static Gaim2RequestUiOps *request_ui_ops = NULL;
- static GList *handles = NULL;
-
- typedef struct
- {
-- GaimRequestType type;
-+ Gaim2RequestType type;
- void *handle;
- void *ui_handle;
-
--} GaimRequestInfo;
-+} Gaim2RequestInfo;
-
-
--GaimRequestFields *
--gaim_request_fields_new(void)
-+Gaim2RequestFields *
-+gaim2_request_fields_new(void)
- {
-- GaimRequestFields *fields;
-+ Gaim2RequestFields *fields;
-
-- fields = g_new0(GaimRequestFields, 1);
-+ fields = g_new0(Gaim2RequestFields, 1);
-
- fields->fields = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, NULL);
-@@ -52,10 +52,10 @@ gaim_request_fields_new(void)
- }
-
- void
--gaim_request_fields_destroy(GaimRequestFields *fields)
-+gaim2_request_fields_destroy(Gaim2RequestFields *fields)
- {
- GList *l;
-- GaimRequestFieldGroup *group;
-+ Gaim2RequestFieldGroup *group;
-
- g_return_if_fail(fields != NULL);
-
-@@ -63,7 +63,7 @@ gaim_request_fields_destroy(GaimRequestF
- {
- group = l->data;
-
-- gaim_request_field_group_destroy(group);
-+ gaim2_request_field_group_destroy(group);
- }
-
- if (fields->groups != NULL)
-@@ -78,11 +78,11 @@ gaim_request_fields_destroy(GaimRequestF
- }
-
- void
--gaim_request_fields_add_group(GaimRequestFields *fields,
-- GaimRequestFieldGroup *group)
-+gaim2_request_fields_add_group(Gaim2RequestFields *fields,
-+ Gaim2RequestFieldGroup *group)
- {
- GList *l;
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_if_fail(fields != NULL);
- g_return_if_fail(group != NULL);
-@@ -91,19 +91,19 @@ gaim_request_fields_add_group(GaimReques
-
- group->fields_list = fields;
-
-- for (l = gaim_request_field_group_get_fields(group);
-+ for (l = gaim2_request_field_group_get_fields(group);
- l != NULL;
- l = l->next) {
-
- field = l->data;
-
- g_hash_table_insert(fields->fields,
-- g_strdup(gaim_request_field_get_id(field)), field);
-+ g_strdup(gaim2_request_field_get_id(field)), field);
- }
- }
-
- GList *
--gaim_request_fields_get_groups(const GaimRequestFields *fields)
-+gaim2_request_fields_get_groups(const Gaim2RequestFields *fields)
- {
- g_return_val_if_fail(fields != NULL, NULL);
-
-@@ -111,7 +111,7 @@ gaim_request_fields_get_groups(const Gai
- }
-
- gboolean
--gaim_request_fields_exists(const GaimRequestFields *fields, const char *id)
-+gaim2_request_fields_exists(const Gaim2RequestFields *fields, const char *id)
- {
- g_return_val_if_fail(fields != NULL, FALSE);
- g_return_val_if_fail(id != NULL, FALSE);
-@@ -120,7 +120,7 @@ gaim_request_fields_exists(const GaimReq
- }
-
- const GList *
--gaim_request_fields_get_required(const GaimRequestFields *fields)
-+gaim2_request_fields_get_required(const Gaim2RequestFields *fields)
- {
- g_return_val_if_fail(fields != NULL, NULL);
-
-@@ -128,22 +128,22 @@ gaim_request_fields_get_required(const G
- }
-
- gboolean
--gaim_request_fields_is_field_required(const GaimRequestFields *fields,
-+gaim2_request_fields_is_field_required(const Gaim2RequestFields *fields,
- const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, FALSE);
- g_return_val_if_fail(id != NULL, FALSE);
-
-- if ((field = gaim_request_fields_get_field(fields, id)) == NULL)
-+ if ((field = gaim2_request_fields_get_field(fields, id)) == NULL)
- return FALSE;
-
-- return gaim_request_field_is_required(field);
-+ return gaim2_request_field_is_required(field);
- }
-
- gboolean
--gaim_request_fields_all_required_filled(const GaimRequestFields *fields)
-+gaim2_request_fields_all_required_filled(const Gaim2RequestFields *fields)
- {
- GList *l;
-
-@@ -151,12 +151,12 @@ gaim_request_fields_all_required_filled(
-
- for (l = fields->required_fields; l != NULL; l = l->next)
- {
-- GaimRequestField *field = (GaimRequestField *)l->data;
-+ Gaim2RequestField *field = (Gaim2RequestField *)l->data;
-
-- switch (gaim_request_field_get_type(field))
-+ switch (gaim2_request_field_get_type(field))
- {
- case GAIM_REQUEST_FIELD_STRING:
-- if (gaim_request_field_string_get_value(field) == NULL)
-+ if (gaim2_request_field_string_get_value(field) == NULL)
- return FALSE;
-
- break;
-@@ -169,10 +169,10 @@ gaim_request_fields_all_required_filled(
- return TRUE;
- }
-
--GaimRequestField *
--gaim_request_fields_get_field(const GaimRequestFields *fields, const char *id)
-+Gaim2RequestField *
-+gaim2_request_fields_get_field(const Gaim2RequestFields *fields, const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, NULL);
- g_return_val_if_fail(id != NULL, NULL);
-@@ -185,83 +185,83 @@ gaim_request_fields_get_field(const Gaim
- }
-
- const char *
--gaim_request_fields_get_string(const GaimRequestFields *fields, const char *id)
-+gaim2_request_fields_get_string(const Gaim2RequestFields *fields, const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, NULL);
- g_return_val_if_fail(id != NULL, NULL);
-
-- if ((field = gaim_request_fields_get_field(fields, id)) == NULL)
-+ if ((field = gaim2_request_fields_get_field(fields, id)) == NULL)
- return NULL;
-
-- return gaim_request_field_string_get_value(field);
-+ return gaim2_request_field_string_get_value(field);
- }
-
- int
--gaim_request_fields_get_integer(const GaimRequestFields *fields,
-+gaim2_request_fields_get_integer(const Gaim2RequestFields *fields,
- const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, 0);
- g_return_val_if_fail(id != NULL, 0);
-
-- if ((field = gaim_request_fields_get_field(fields, id)) == NULL)
-+ if ((field = gaim2_request_fields_get_field(fields, id)) == NULL)
- return 0;
-
-- return gaim_request_field_int_get_value(field);
-+ return gaim2_request_field_int_get_value(field);
- }
-
- gboolean
--gaim_request_fields_get_bool(const GaimRequestFields *fields, const char *id)
-+gaim2_request_fields_get_bool(const Gaim2RequestFields *fields, const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, FALSE);
- g_return_val_if_fail(id != NULL, FALSE);
-
-- if ((field = gaim_request_fields_get_field(fields, id)) == NULL)
-+ if ((field = gaim2_request_fields_get_field(fields, id)) == NULL)
- return FALSE;
-
-- return gaim_request_field_bool_get_value(field);
-+ return gaim2_request_field_bool_get_value(field);
- }
-
- int
--gaim_request_fields_get_choice(const GaimRequestFields *fields, const char *id)
-+gaim2_request_fields_get_choice(const Gaim2RequestFields *fields, const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, -1);
- g_return_val_if_fail(id != NULL, -1);
-
-- if ((field = gaim_request_fields_get_field(fields, id)) == NULL)
-+ if ((field = gaim2_request_fields_get_field(fields, id)) == NULL)
- return -1;
-
-- return gaim_request_field_choice_get_value(field);
-+ return gaim2_request_field_choice_get_value(field);
- }
-
--GaimAccount *
--gaim_request_fields_get_account(const GaimRequestFields *fields,
-+Gaim2Account *
-+gaim2_request_fields_get_account(const Gaim2RequestFields *fields,
- const char *id)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(fields != NULL, NULL);
- g_return_val_if_fail(id != NULL, NULL);
-
-- if ((field = gaim_request_fields_get_field(fields, id)) == NULL)
-+ if ((field = gaim2_request_fields_get_field(fields, id)) == NULL)
- return NULL;
-
-- return gaim_request_field_account_get_value(field);
-+ return gaim2_request_field_account_get_value(field);
- }
-
--GaimRequestFieldGroup *
--gaim_request_field_group_new(const char *title)
-+Gaim2RequestFieldGroup *
-+gaim2_request_field_group_new(const char *title)
- {
-- GaimRequestFieldGroup *group;
-+ Gaim2RequestFieldGroup *group;
-
-- group = g_new0(GaimRequestFieldGroup, 1);
-+ group = g_new0(Gaim2RequestFieldGroup, 1);
-
- if (title != NULL)
- group->title = g_strdup(title);
-@@ -270,9 +270,9 @@ gaim_request_field_group_new(const char
- }
-
- void
--gaim_request_field_group_destroy(GaimRequestFieldGroup *group)
-+gaim2_request_field_group_destroy(Gaim2RequestFieldGroup *group)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
- GList *l;
-
- g_return_if_fail(group != NULL);
-@@ -283,7 +283,7 @@ gaim_request_field_group_destroy(GaimReq
- for (l = group->fields; l != NULL; l = l->next) {
- field = l->data;
-
-- gaim_request_field_destroy(field);
-+ gaim2_request_field_destroy(field);
- }
-
- g_list_free(group->fields);
-@@ -292,8 +292,8 @@ gaim_request_field_group_destroy(GaimReq
- }
-
- void
--gaim_request_field_group_add_field(GaimRequestFieldGroup *group,
-- GaimRequestField *field)
-+gaim2_request_field_group_add_field(Gaim2RequestFieldGroup *group,
-+ Gaim2RequestField *field)
- {
- g_return_if_fail(group != NULL);
- g_return_if_fail(field != NULL);
-@@ -303,12 +303,12 @@ gaim_request_field_group_add_field(GaimR
- if (group->fields_list != NULL)
- {
- g_hash_table_insert(group->fields_list->fields,
-- g_strdup(gaim_request_field_get_id(field)), field);
-+ g_strdup(gaim2_request_field_get_id(field)), field);
- }
-
- field->group = group;
-
-- if (gaim_request_field_is_required(field))
-+ if (gaim2_request_field_is_required(field))
- {
- group->fields_list->required_fields =
- g_list_append(group->fields_list->required_fields, field);
-@@ -316,7 +316,7 @@ gaim_request_field_group_add_field(GaimR
- }
-
- const char *
--gaim_request_field_group_get_title(const GaimRequestFieldGroup *group)
-+gaim2_request_field_group_get_title(const Gaim2RequestFieldGroup *group)
- {
- g_return_val_if_fail(group != NULL, NULL);
-
-@@ -324,35 +324,35 @@ gaim_request_field_group_get_title(const
- }
-
- GList *
--gaim_request_field_group_get_fields(const GaimRequestFieldGroup *group)
-+gaim2_request_field_group_get_fields(const Gaim2RequestFieldGroup *group)
- {
- g_return_val_if_fail(group != NULL, NULL);
-
- return group->fields;
- }
-
--GaimRequestField *
--gaim_request_field_new(const char *id, const char *text,
-- GaimRequestFieldType type)
-+Gaim2RequestField *
-+gaim2_request_field_new(const char *id, const char *text,
-+ Gaim2RequestFieldType type)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(type != GAIM_REQUEST_FIELD_NONE, NULL);
-
-- field = g_new0(GaimRequestField, 1);
-+ field = g_new0(Gaim2RequestField, 1);
-
- field->id = g_strdup(id);
- field->type = type;
-
-- gaim_request_field_set_label(field, text);
-- gaim_request_field_set_visible(field, TRUE);
-+ gaim2_request_field_set_label(field, text);
-+ gaim2_request_field_set_visible(field, TRUE);
-
- return field;
- }
-
- void
--gaim_request_field_destroy(GaimRequestField *field)
-+gaim2_request_field_destroy(Gaim2RequestField *field)
- {
- g_return_if_fail(field != NULL);
-
-@@ -403,7 +403,7 @@ gaim_request_field_destroy(GaimRequestFi
- }
-
- void
--gaim_request_field_set_label(GaimRequestField *field, const char *label)
-+gaim2_request_field_set_label(Gaim2RequestField *field, const char *label)
- {
- g_return_if_fail(field != NULL);
-
-@@ -414,7 +414,7 @@ gaim_request_field_set_label(GaimRequest
- }
-
- void
--gaim_request_field_set_visible(GaimRequestField *field, gboolean visible)
-+gaim2_request_field_set_visible(Gaim2RequestField *field, gboolean visible)
- {
- g_return_if_fail(field != NULL);
-
-@@ -422,7 +422,7 @@ gaim_request_field_set_visible(GaimReque
- }
-
- void
--gaim_request_field_set_type_hint(GaimRequestField *field,
-+gaim2_request_field_set_type_hint(Gaim2RequestField *field,
- const char *type_hint)
- {
- g_return_if_fail(field != NULL);
-@@ -434,7 +434,7 @@ gaim_request_field_set_type_hint(GaimReq
- }
-
- void
--gaim_request_field_set_required(GaimRequestField *field, gboolean required)
-+gaim2_request_field_set_required(Gaim2RequestField *field, gboolean required)
- {
- g_return_if_fail(field != NULL);
-
-@@ -460,8 +460,8 @@ gaim_request_field_set_required(GaimRequ
- }
- }
-
--GaimRequestFieldType
--gaim_request_field_get_type(const GaimRequestField *field)
-+Gaim2RequestFieldType
-+gaim2_request_field_get_type(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, GAIM_REQUEST_FIELD_NONE);
-
-@@ -469,7 +469,7 @@ gaim_request_field_get_type(const GaimRe
- }
-
- const char *
--gaim_request_field_get_id(const GaimRequestField *field)
-+gaim2_request_field_get_id(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
-
-@@ -477,7 +477,7 @@ gaim_request_field_get_id(const GaimRequ
- }
-
- const char *
--gaim_request_field_get_label(const GaimRequestField *field)
-+gaim2_request_field_get_label(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
-
-@@ -485,7 +485,7 @@ gaim_request_field_get_label(const GaimR
- }
-
- gboolean
--gaim_request_field_is_visible(const GaimRequestField *field)
-+gaim2_request_field_is_visible(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
-
-@@ -493,7 +493,7 @@ gaim_request_field_is_visible(const Gaim
- }
-
- const char *
--gaim_request_field_get_type_hint(const GaimRequestField *field)
-+gaim2_request_field_get_type_hint(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
-
-@@ -501,35 +501,35 @@ gaim_request_field_get_type_hint(const G
- }
-
- gboolean
--gaim_request_field_is_required(const GaimRequestField *field)
-+gaim2_request_field_is_required(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
-
- return field->required;
- }
-
--GaimRequestField *
--gaim_request_field_string_new(const char *id, const char *text,
-+Gaim2RequestField *
-+gaim2_request_field_string_new(const char *id, const char *text,
- const char *default_value, gboolean multiline)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_STRING);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_STRING);
-
- field->u.string.multiline = multiline;
- field->u.string.editable = TRUE;
-
-- gaim_request_field_string_set_default_value(field, default_value);
-- gaim_request_field_string_set_value(field, default_value);
-+ gaim2_request_field_string_set_default_value(field, default_value);
-+ gaim2_request_field_string_set_value(field, default_value);
-
- return field;
- }
-
- void
--gaim_request_field_string_set_default_value(GaimRequestField *field,
-+gaim2_request_field_string_set_default_value(Gaim2RequestField *field,
- const char *default_value)
- {
- g_return_if_fail(field != NULL);
-@@ -543,7 +543,7 @@ gaim_request_field_string_set_default_va
- }
-
- void
--gaim_request_field_string_set_value(GaimRequestField *field, const char *value)
-+gaim2_request_field_string_set_value(Gaim2RequestField *field, const char *value)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_STRING);
-@@ -555,7 +555,7 @@ gaim_request_field_string_set_value(Gaim
- }
-
- void
--gaim_request_field_string_set_masked(GaimRequestField *field, gboolean masked)
-+gaim2_request_field_string_set_masked(Gaim2RequestField *field, gboolean masked)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_STRING);
-@@ -564,7 +564,7 @@ gaim_request_field_string_set_masked(Gai
- }
-
- void
--gaim_request_field_string_set_editable(GaimRequestField *field,
-+gaim2_request_field_string_set_editable(Gaim2RequestField *field,
- gboolean editable)
- {
- g_return_if_fail(field != NULL);
-@@ -574,7 +574,7 @@ gaim_request_field_string_set_editable(G
- }
-
- const char *
--gaim_request_field_string_get_default_value(const GaimRequestField *field)
-+gaim2_request_field_string_get_default_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_STRING, NULL);
-@@ -583,7 +583,7 @@ gaim_request_field_string_get_default_va
- }
-
- const char *
--gaim_request_field_string_get_value(const GaimRequestField *field)
-+gaim2_request_field_string_get_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_STRING, NULL);
-@@ -592,7 +592,7 @@ gaim_request_field_string_get_value(cons
- }
-
- gboolean
--gaim_request_field_string_is_multiline(const GaimRequestField *field)
-+gaim2_request_field_string_is_multiline(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_STRING, FALSE);
-@@ -601,7 +601,7 @@ gaim_request_field_string_is_multiline(c
- }
-
- gboolean
--gaim_request_field_string_is_masked(const GaimRequestField *field)
-+gaim2_request_field_string_is_masked(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_STRING, FALSE);
-@@ -610,7 +610,7 @@ gaim_request_field_string_is_masked(cons
- }
-
- gboolean
--gaim_request_field_string_is_editable(const GaimRequestField *field)
-+gaim2_request_field_string_is_editable(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_STRING, FALSE);
-@@ -618,25 +618,25 @@ gaim_request_field_string_is_editable(co
- return field->u.string.editable;
- }
-
--GaimRequestField *
--gaim_request_field_int_new(const char *id, const char *text,
-+Gaim2RequestField *
-+gaim2_request_field_int_new(const char *id, const char *text,
- int default_value)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_INTEGER);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_INTEGER);
-
-- gaim_request_field_int_set_default_value(field, default_value);
-- gaim_request_field_int_set_value(field, default_value);
-+ gaim2_request_field_int_set_default_value(field, default_value);
-+ gaim2_request_field_int_set_value(field, default_value);
-
- return field;
- }
-
- void
--gaim_request_field_int_set_default_value(GaimRequestField *field,
-+gaim2_request_field_int_set_default_value(Gaim2RequestField *field,
- int default_value)
- {
- g_return_if_fail(field != NULL);
-@@ -646,7 +646,7 @@ gaim_request_field_int_set_default_value
- }
-
- void
--gaim_request_field_int_set_value(GaimRequestField *field, int value)
-+gaim2_request_field_int_set_value(Gaim2RequestField *field, int value)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_INTEGER);
-@@ -655,7 +655,7 @@ gaim_request_field_int_set_value(GaimReq
- }
-
- int
--gaim_request_field_int_get_default_value(const GaimRequestField *field)
-+gaim2_request_field_int_get_default_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, 0);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_INTEGER, 0);
-@@ -664,7 +664,7 @@ gaim_request_field_int_get_default_value
- }
-
- int
--gaim_request_field_int_get_value(const GaimRequestField *field)
-+gaim2_request_field_int_get_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, 0);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_INTEGER, 0);
-@@ -672,25 +672,25 @@ gaim_request_field_int_get_value(const G
- return field->u.integer.value;
- }
-
--GaimRequestField *
--gaim_request_field_bool_new(const char *id, const char *text,
-+Gaim2RequestField *
-+gaim2_request_field_bool_new(const char *id, const char *text,
- gboolean default_value)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_BOOLEAN);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_BOOLEAN);
-
-- gaim_request_field_bool_set_default_value(field, default_value);
-- gaim_request_field_bool_set_value(field, default_value);
-+ gaim2_request_field_bool_set_default_value(field, default_value);
-+ gaim2_request_field_bool_set_value(field, default_value);
-
- return field;
- }
-
- void
--gaim_request_field_bool_set_default_value(GaimRequestField *field,
-+gaim2_request_field_bool_set_default_value(Gaim2RequestField *field,
- gboolean default_value)
- {
- g_return_if_fail(field != NULL);
-@@ -700,7 +700,7 @@ gaim_request_field_bool_set_default_valu
- }
-
- void
--gaim_request_field_bool_set_value(GaimRequestField *field, gboolean value)
-+gaim2_request_field_bool_set_value(Gaim2RequestField *field, gboolean value)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_BOOLEAN);
-@@ -709,7 +709,7 @@ gaim_request_field_bool_set_value(GaimRe
- }
-
- gboolean
--gaim_request_field_bool_get_default_value(const GaimRequestField *field)
-+gaim2_request_field_bool_get_default_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_BOOLEAN, FALSE);
-@@ -718,7 +718,7 @@ gaim_request_field_bool_get_default_valu
- }
-
- gboolean
--gaim_request_field_bool_get_value(const GaimRequestField *field)
-+gaim2_request_field_bool_get_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_BOOLEAN, FALSE);
-@@ -726,25 +726,25 @@ gaim_request_field_bool_get_value(const
- return field->u.boolean.value;
- }
-
--GaimRequestField *
--gaim_request_field_choice_new(const char *id, const char *text,
-+Gaim2RequestField *
-+gaim2_request_field_choice_new(const char *id, const char *text,
- int default_value)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_CHOICE);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_CHOICE);
-
-- gaim_request_field_choice_set_default_value(field, default_value);
-- gaim_request_field_choice_set_value(field, default_value);
-+ gaim2_request_field_choice_set_default_value(field, default_value);
-+ gaim2_request_field_choice_set_value(field, default_value);
-
- return field;
- }
-
- void
--gaim_request_field_choice_add(GaimRequestField *field, const char *label)
-+gaim2_request_field_choice_add(Gaim2RequestField *field, const char *label)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(label != NULL);
-@@ -755,7 +755,7 @@ gaim_request_field_choice_add(GaimReques
- }
-
- void
--gaim_request_field_choice_set_default_value(GaimRequestField *field,
-+gaim2_request_field_choice_set_default_value(Gaim2RequestField *field,
- int default_value)
- {
- g_return_if_fail(field != NULL);
-@@ -765,7 +765,7 @@ gaim_request_field_choice_set_default_va
- }
-
- void
--gaim_request_field_choice_set_value(GaimRequestField *field,
-+gaim2_request_field_choice_set_value(Gaim2RequestField *field,
- int value)
- {
- g_return_if_fail(field != NULL);
-@@ -775,7 +775,7 @@ gaim_request_field_choice_set_value(Gaim
- }
-
- int
--gaim_request_field_choice_get_default_value(const GaimRequestField *field)
-+gaim2_request_field_choice_get_default_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, -1);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_CHOICE, -1);
-@@ -784,7 +784,7 @@ gaim_request_field_choice_get_default_va
- }
-
- int
--gaim_request_field_choice_get_value(const GaimRequestField *field)
-+gaim2_request_field_choice_get_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, -1);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_CHOICE, -1);
-@@ -793,7 +793,7 @@ gaim_request_field_choice_get_value(cons
- }
-
- GList *
--gaim_request_field_choice_get_labels(const GaimRequestField *field)
-+gaim2_request_field_choice_get_labels(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_CHOICE, NULL);
-@@ -801,14 +801,14 @@ gaim_request_field_choice_get_labels(con
- return field->u.choice.labels;
- }
-
--GaimRequestField *
--gaim_request_field_list_new(const char *id, const char *text)
-+Gaim2RequestField *
-+gaim2_request_field_list_new(const char *id, const char *text)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_LIST);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_LIST);
-
- field->u.list.item_data = g_hash_table_new_full(g_str_hash, g_str_equal,
- g_free, NULL);
-@@ -820,7 +820,7 @@ gaim_request_field_list_new(const char *
- }
-
- void
--gaim_request_field_list_set_multi_select(GaimRequestField *field,
-+gaim2_request_field_list_set_multi_select(Gaim2RequestField *field,
- gboolean multi_select)
- {
- g_return_if_fail(field != NULL);
-@@ -830,7 +830,7 @@ gaim_request_field_list_set_multi_select
- }
-
- gboolean
--gaim_request_field_list_get_multi_select(const GaimRequestField *field)
-+gaim2_request_field_list_get_multi_select(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_LIST, FALSE);
-@@ -839,7 +839,7 @@ gaim_request_field_list_get_multi_select
- }
-
- void *
--gaim_request_field_list_get_data(const GaimRequestField *field,
-+gaim2_request_field_list_get_data(const Gaim2RequestField *field,
- const char *text)
- {
- g_return_val_if_fail(field != NULL, NULL);
-@@ -850,7 +850,7 @@ gaim_request_field_list_get_data(const G
- }
-
- void
--gaim_request_field_list_add(GaimRequestField *field, const char *item,
-+gaim2_request_field_list_add(Gaim2RequestField *field, const char *item,
- void *data)
- {
- g_return_if_fail(field != NULL);
-@@ -864,19 +864,19 @@ gaim_request_field_list_add(GaimRequestF
- }
-
- void
--gaim_request_field_list_add_selected(GaimRequestField *field, const char *item)
-+gaim2_request_field_list_add_selected(Gaim2RequestField *field, const char *item)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(item != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_LIST);
-
-- if (!gaim_request_field_list_get_multi_select(field) &&
-+ if (!gaim2_request_field_list_get_multi_select(field) &&
- field->u.list.selected != NULL)
- {
-- gaim_debug_warning("request",
-+ gaim2_debug_warning("request",
- "More than one item added to non-multi-select "
- "field %s\n",
-- gaim_request_field_get_id(field));
-+ gaim2_request_field_get_id(field));
- return;
- }
-
-@@ -887,7 +887,7 @@ gaim_request_field_list_add_selected(Gai
- }
-
- void
--gaim_request_field_list_clear_selected(GaimRequestField *field)
-+gaim2_request_field_list_clear_selected(Gaim2RequestField *field)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_LIST);
-@@ -906,7 +906,7 @@ gaim_request_field_list_clear_selected(G
- }
-
- void
--gaim_request_field_list_set_selected(GaimRequestField *field, GList *items)
-+gaim2_request_field_list_set_selected(Gaim2RequestField *field, GList *items)
- {
- GList *l;
-
-@@ -914,15 +914,15 @@ gaim_request_field_list_set_selected(Gai
- g_return_if_fail(items != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_LIST);
-
-- gaim_request_field_list_clear_selected(field);
-+ gaim2_request_field_list_clear_selected(field);
-
-- if (!gaim_request_field_list_get_multi_select(field) &&
-+ if (!gaim2_request_field_list_get_multi_select(field) &&
- g_list_length(items) > 1)
- {
-- gaim_debug_warning("request",
-+ gaim2_debug_warning("request",
- "More than one item added to non-multi-select "
- "field %s\n",
-- gaim_request_field_get_id(field));
-+ gaim2_request_field_get_id(field));
- return;
- }
-
-@@ -936,7 +936,7 @@ gaim_request_field_list_set_selected(Gai
- }
-
- gboolean
--gaim_request_field_list_is_selected(const GaimRequestField *field,
-+gaim2_request_field_list_is_selected(const Gaim2RequestField *field,
- const char *item)
- {
- g_return_val_if_fail(field != NULL, FALSE);
-@@ -948,7 +948,7 @@ gaim_request_field_list_is_selected(cons
- }
-
- const GList *
--gaim_request_field_list_get_selected(const GaimRequestField *field)
-+gaim2_request_field_list_get_selected(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_LIST, NULL);
-@@ -957,7 +957,7 @@ gaim_request_field_list_get_selected(con
- }
-
- const GList *
--gaim_request_field_list_get_items(const GaimRequestField *field)
-+gaim2_request_field_list_get_items(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_LIST, NULL);
-@@ -965,30 +965,30 @@ gaim_request_field_list_get_items(const
- return field->u.list.items;
- }
-
--GaimRequestField *
--gaim_request_field_label_new(const char *id, const char *text)
-+Gaim2RequestField *
-+gaim2_request_field_label_new(const char *id, const char *text)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_LABEL);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_LABEL);
-
- return field;
- }
-
--GaimRequestField *
--gaim_request_field_image_new(const char *id, const char *text, const char *buf, gsize size)
-+Gaim2RequestField *
-+gaim2_request_field_image_new(const char *id, const char *text, const char *buf, gsize size)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
- g_return_val_if_fail(buf != NULL, NULL);
- g_return_val_if_fail(size > 0, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_IMAGE);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_IMAGE);
-
- field->u.image.buffer = g_memdup(buf, size);
- field->u.image.size = size;
-@@ -999,7 +999,7 @@ gaim_request_field_image_new(const char
- }
-
- void
--gaim_request_field_image_set_scale(GaimRequestField *field, unsigned int x, unsigned int y)
-+gaim2_request_field_image_set_scale(Gaim2RequestField *field, unsigned int x, unsigned int y)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_IMAGE);
-@@ -1009,7 +1009,7 @@ gaim_request_field_image_set_scale(GaimR
- }
-
- const char *
--gaim_request_field_image_get_buffer(GaimRequestField *field)
-+gaim2_request_field_image_get_buffer(Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_IMAGE, NULL);
-@@ -1018,7 +1018,7 @@ gaim_request_field_image_get_buffer(Gaim
- }
-
- gsize
--gaim_request_field_image_get_size(GaimRequestField *field)
-+gaim2_request_field_image_get_size(Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, 0);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_IMAGE, 0);
-@@ -1027,7 +1027,7 @@ gaim_request_field_image_get_size(GaimRe
- }
-
- unsigned int
--gaim_request_field_image_get_scale_x(GaimRequestField *field)
-+gaim2_request_field_image_get_scale_x(Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, 0);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_IMAGE, 0);
-@@ -1036,7 +1036,7 @@ gaim_request_field_image_get_scale_x(Gai
- }
-
- unsigned int
--gaim_request_field_image_get_scale_y(GaimRequestField *field)
-+gaim2_request_field_image_get_scale_y(Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, 0);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_IMAGE, 0);
-@@ -1044,32 +1044,32 @@ gaim_request_field_image_get_scale_y(Gai
- return field->u.image.scale_y;
- }
-
--GaimRequestField *
--gaim_request_field_account_new(const char *id, const char *text,
-- GaimAccount *account)
-+Gaim2RequestField *
-+gaim2_request_field_account_new(const char *id, const char *text,
-+ Gaim2Account *account)
- {
-- GaimRequestField *field;
-+ Gaim2RequestField *field;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(text != NULL, NULL);
-
-- field = gaim_request_field_new(id, text, GAIM_REQUEST_FIELD_ACCOUNT);
-+ field = gaim2_request_field_new(id, text, GAIM_REQUEST_FIELD_ACCOUNT);
-
-- if (account == NULL && gaim_connections_get_all() != NULL)
-+ if (account == NULL && gaim2_connections_get_all() != NULL)
- {
-- account = gaim_connection_get_account(
-- (GaimConnection *)gaim_connections_get_all()->data);
-+ account = gaim2_connection_get_account(
-+ (Gaim2Connection *)gaim2_connections_get_all()->data);
- }
-
-- gaim_request_field_account_set_default_value(field, account);
-- gaim_request_field_account_set_value(field, account);
-+ gaim2_request_field_account_set_default_value(field, account);
-+ gaim2_request_field_account_set_value(field, account);
-
- return field;
- }
-
- void
--gaim_request_field_account_set_default_value(GaimRequestField *field,
-- GaimAccount *default_value)
-+gaim2_request_field_account_set_default_value(Gaim2RequestField *field,
-+ Gaim2Account *default_value)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT);
-@@ -1078,8 +1078,8 @@ gaim_request_field_account_set_default_v
- }
-
- void
--gaim_request_field_account_set_value(GaimRequestField *field,
-- GaimAccount *value)
-+gaim2_request_field_account_set_value(Gaim2RequestField *field,
-+ Gaim2Account *value)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT);
-@@ -1088,7 +1088,7 @@ gaim_request_field_account_set_value(Gai
- }
-
- void
--gaim_request_field_account_set_show_all(GaimRequestField *field,
-+gaim2_request_field_account_set_show_all(Gaim2RequestField *field,
- gboolean show_all)
- {
- g_return_if_fail(field != NULL);
-@@ -1101,23 +1101,23 @@ gaim_request_field_account_set_show_all(
-
- if (!show_all)
- {
-- if (gaim_account_is_connected(field->u.account.default_account))
-+ if (gaim2_account_is_connected(field->u.account.default_account))
- {
-- gaim_request_field_account_set_default_value(field,
-- (GaimAccount *)gaim_connections_get_all()->data);
-+ gaim2_request_field_account_set_default_value(field,
-+ (Gaim2Account *)gaim2_connections_get_all()->data);
- }
-
-- if (gaim_account_is_connected(field->u.account.account))
-+ if (gaim2_account_is_connected(field->u.account.account))
- {
-- gaim_request_field_account_set_value(field,
-- (GaimAccount *)gaim_connections_get_all()->data);
-+ gaim2_request_field_account_set_value(field,
-+ (Gaim2Account *)gaim2_connections_get_all()->data);
- }
- }
- }
-
- void
--gaim_request_field_account_set_filter(GaimRequestField *field,
-- GaimFilterAccountFunc filter_func)
-+gaim2_request_field_account_set_filter(Gaim2RequestField *field,
-+ Gaim2FilterAccountFunc filter_func)
- {
- g_return_if_fail(field != NULL);
- g_return_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT);
-@@ -1125,8 +1125,8 @@ gaim_request_field_account_set_filter(Ga
- field->u.account.filter_func = filter_func;
- }
-
--GaimAccount *
--gaim_request_field_account_get_default_value(const GaimRequestField *field)
-+Gaim2Account *
-+gaim2_request_field_account_get_default_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT, NULL);
-@@ -1134,8 +1134,8 @@ gaim_request_field_account_get_default_v
- return field->u.account.default_account;
- }
-
--GaimAccount *
--gaim_request_field_account_get_value(const GaimRequestField *field)
-+Gaim2Account *
-+gaim2_request_field_account_get_value(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, NULL);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT, NULL);
-@@ -1144,7 +1144,7 @@ gaim_request_field_account_get_value(con
- }
-
- gboolean
--gaim_request_field_account_get_show_all(const GaimRequestField *field)
-+gaim2_request_field_account_get_show_all(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT, FALSE);
-@@ -1152,8 +1152,8 @@ gaim_request_field_account_get_show_all(
- return field->u.account.show_all;
- }
-
--GaimFilterAccountFunc
--gaim_request_field_account_get_filter(const GaimRequestField *field)
-+Gaim2FilterAccountFunc
-+gaim2_request_field_account_get_filter(const Gaim2RequestField *field)
- {
- g_return_val_if_fail(field != NULL, FALSE);
- g_return_val_if_fail(field->type == GAIM_REQUEST_FIELD_ACCOUNT, FALSE);
-@@ -1164,24 +1164,24 @@ gaim_request_field_account_get_filter(co
- /* -- */
-
- void *
--gaim_request_input(void *handle, const char *title, const char *primary,
-+gaim2_request_input(void *handle, const char *title, const char *primary,
- const char *secondary, const char *default_value,
- gboolean multiline, gboolean masked, gchar *hint,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data)
- {
-- GaimRequestUiOps *ops;
-+ Gaim2RequestUiOps *ops;
-
- g_return_val_if_fail(ok_text != NULL, NULL);
- g_return_val_if_fail(ok_cb != NULL, NULL);
-
-- ops = gaim_request_get_ui_ops();
-+ ops = gaim2_request_get_ui_ops();
-
- if (ops != NULL && ops->request_input != NULL) {
-- GaimRequestInfo *info;
-+ Gaim2RequestInfo *info;
-
-- info = g_new0(GaimRequestInfo, 1);
-+ info = g_new0(Gaim2RequestInfo, 1);
- info->type = GAIM_REQUEST_INPUT;
- info->handle = handle;
- info->ui_handle = ops->request_input(title, primary, secondary,
-@@ -1200,7 +1200,7 @@ gaim_request_input(void *handle, const c
- }
-
- void *
--gaim_request_choice(void *handle, const char *title, const char *primary,
-+gaim2_request_choice(void *handle, const char *title, const char *primary,
- const char *secondary, unsigned int default_value,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
-@@ -1213,7 +1213,7 @@ gaim_request_choice(void *handle, const
- g_return_val_if_fail(ok_cb != NULL, NULL);
-
- va_start(args, user_data);
-- ui_handle = gaim_request_choice_varg(handle, title, primary, secondary,
-+ ui_handle = gaim2_request_choice_varg(handle, title, primary, secondary,
- default_value, ok_text, ok_cb,
- cancel_text, cancel_cb, user_data, args);
- va_end(args);
-@@ -1222,24 +1222,24 @@ gaim_request_choice(void *handle, const
- }
-
- void *
--gaim_request_choice_varg(void *handle, const char *title,
-+gaim2_request_choice_varg(void *handle, const char *title,
- const char *primary, const char *secondary,
- unsigned int default_value,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data, va_list choices)
- {
-- GaimRequestUiOps *ops;
-+ Gaim2RequestUiOps *ops;
-
- g_return_val_if_fail(ok_text != NULL, NULL);
- g_return_val_if_fail(ok_cb != NULL, NULL);
-
-- ops = gaim_request_get_ui_ops();
-+ ops = gaim2_request_get_ui_ops();
-
- if (ops != NULL && ops->request_choice != NULL) {
-- GaimRequestInfo *info;
-+ Gaim2RequestInfo *info;
-
-- info = g_new0(GaimRequestInfo, 1);
-+ info = g_new0(Gaim2RequestInfo, 1);
- info->type = GAIM_REQUEST_CHOICE;
- info->handle = handle;
- info->ui_handle = ops->request_choice(title, primary, secondary,
-@@ -1257,7 +1257,7 @@ gaim_request_choice_varg(void *handle, c
- }
-
- void *
--gaim_request_action(void *handle, const char *title, const char *primary,
-+gaim2_request_action(void *handle, const char *title, const char *primary,
- const char *secondary, unsigned int default_action,
- void *user_data, size_t action_count, ...)
- {
-@@ -1267,7 +1267,7 @@ gaim_request_action(void *handle, const
- g_return_val_if_fail(action_count > 0, NULL);
-
- va_start(args, action_count);
-- ui_handle = gaim_request_action_varg(handle, title, primary, secondary,
-+ ui_handle = gaim2_request_action_varg(handle, title, primary, secondary,
- default_action, user_data,
- action_count, args);
- va_end(args);
-@@ -1276,21 +1276,21 @@ gaim_request_action(void *handle, const
- }
-
- void *
--gaim_request_action_varg(void *handle, const char *title,
-+gaim2_request_action_varg(void *handle, const char *title,
- const char *primary, const char *secondary,
- unsigned int default_action, void *user_data,
- size_t action_count, va_list actions)
- {
-- GaimRequestUiOps *ops;
-+ Gaim2RequestUiOps *ops;
-
- g_return_val_if_fail(action_count > 0, NULL);
-
-- ops = gaim_request_get_ui_ops();
-+ ops = gaim2_request_get_ui_ops();
-
- if (ops != NULL && ops->request_action != NULL) {
-- GaimRequestInfo *info;
-+ Gaim2RequestInfo *info;
-
-- info = g_new0(GaimRequestInfo, 1);
-+ info = g_new0(Gaim2RequestInfo, 1);
- info->type = GAIM_REQUEST_ACTION;
- info->handle = handle;
- info->ui_handle = ops->request_action(title, primary, secondary,
-@@ -1306,24 +1306,24 @@ gaim_request_action_varg(void *handle, c
- }
-
- void *
--gaim_request_fields(void *handle, const char *title, const char *primary,
-- const char *secondary, GaimRequestFields *fields,
-+gaim2_request_fields(void *handle, const char *title, const char *primary,
-+ const char *secondary, Gaim2RequestFields *fields,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data)
- {
-- GaimRequestUiOps *ops;
-+ Gaim2RequestUiOps *ops;
-
- g_return_val_if_fail(fields != NULL, NULL);
- g_return_val_if_fail(ok_text != NULL, NULL);
- g_return_val_if_fail(ok_cb != NULL, NULL);
-
-- ops = gaim_request_get_ui_ops();
-+ ops = gaim2_request_get_ui_ops();
-
- if (ops != NULL && ops->request_fields != NULL) {
-- GaimRequestInfo *info;
-+ Gaim2RequestInfo *info;
-
-- info = g_new0(GaimRequestInfo, 1);
-+ info = g_new0(Gaim2RequestInfo, 1);
- info->type = GAIM_REQUEST_FIELDS;
- info->handle = handle;
- info->ui_handle = ops->request_fields(title, primary, secondary,
-@@ -1340,18 +1340,18 @@ gaim_request_fields(void *handle, const
- }
-
- void *
--gaim_request_file(void *handle, const char *title, const char *filename,
-+gaim2_request_file(void *handle, const char *title, const char *filename,
- gboolean savedialog,
- GCallback ok_cb, GCallback cancel_cb, void *user_data)
- {
-- GaimRequestUiOps *ops;
-+ Gaim2RequestUiOps *ops;
-
-- ops = gaim_request_get_ui_ops();
-+ ops = gaim2_request_get_ui_ops();
-
- if (ops != NULL && ops->request_file != NULL) {
-- GaimRequestInfo *info;
-+ Gaim2RequestInfo *info;
-
-- info = g_new0(GaimRequestInfo, 1);
-+ info = g_new0(Gaim2RequestInfo, 1);
- info->type = GAIM_REQUEST_FILE;
- info->handle = handle;
- info->ui_handle = ops->request_file(title, filename, savedialog,
-@@ -1364,14 +1364,14 @@ gaim_request_file(void *handle, const ch
- }
-
- static void
--gaim_request_close_info(GaimRequestInfo *info)
-+gaim2_request_close_info(Gaim2RequestInfo *info)
- {
-- GaimRequestUiOps *ops;
-+ Gaim2RequestUiOps *ops;
-
-- ops = gaim_request_get_ui_ops();
-+ ops = gaim2_request_get_ui_ops();
-
-- gaim_notify_close_with_handle(info->ui_handle);
-- gaim_request_close_with_handle(info->ui_handle);
-+ gaim2_notify_close_with_handle(info->ui_handle);
-+ gaim2_request_close_with_handle(info->ui_handle);
-
- if (ops != NULL && ops->close_request != NULL)
- ops->close_request(info->type, info->ui_handle);
-@@ -1380,50 +1380,50 @@ gaim_request_close_info(GaimRequestInfo
- }
-
- void
--gaim_request_close(GaimRequestType type, void *ui_handle)
-+gaim2_request_close(Gaim2RequestType type, void *ui_handle)
- {
- GList *l;
-
- g_return_if_fail(ui_handle != NULL);
-
- for (l = handles; l != NULL; l = l->next) {
-- GaimRequestInfo *info = l->data;
-+ Gaim2RequestInfo *info = l->data;
-
- if (info->ui_handle == ui_handle) {
- handles = g_list_remove(handles, info);
-- gaim_request_close_info(info);
-+ gaim2_request_close_info(info);
- break;
- }
- }
- }
-
- void
--gaim_request_close_with_handle(void *handle)
-+gaim2_request_close_with_handle(void *handle)
- {
- GList *l, *l_next;
-
- g_return_if_fail(handle != NULL);
-
- for (l = handles; l != NULL; l = l_next) {
-- GaimRequestInfo *info = l->data;
-+ Gaim2RequestInfo *info = l->data;
-
- l_next = l->next;
-
- if (info->handle == handle) {
- handles = g_list_remove(handles, info);
-- gaim_request_close_info(info);
-+ gaim2_request_close_info(info);
- }
- }
- }
-
- void
--gaim_request_set_ui_ops(GaimRequestUiOps *ops)
-+gaim2_request_set_ui_ops(Gaim2RequestUiOps *ops)
- {
- request_ui_ops = ops;
- }
-
--GaimRequestUiOps *
--gaim_request_get_ui_ops(void)
-+Gaim2RequestUiOps *
-+gaim2_request_get_ui_ops(void)
- {
- return request_ui_ops;
- }
-diff -prNu ./src/request.h ./src/request.h
---- ./src/request.h 2006-01-04 18:36:42.000000000 +0100
-+++ ./src/request.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file request.h Request API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -44,7 +44,7 @@ typedef enum
- GAIM_REQUEST_FIELDS, /**< Multiple fields request. */
- GAIM_REQUEST_FILE /**< File open or save request. */
-
--} GaimRequestType;
-+} Gaim2RequestType;
-
- /**
- * A type of field.
-@@ -61,7 +61,7 @@ typedef enum
- GAIM_REQUEST_FIELD_IMAGE,
- GAIM_REQUEST_FIELD_ACCOUNT
-
--} GaimRequestFieldType;
-+} Gaim2RequestFieldType;
-
- /**
- * Multiple fields request data.
-@@ -76,28 +76,28 @@ typedef struct
-
- void *ui_data;
-
--} GaimRequestFields;
-+} Gaim2RequestFields;
-
- /**
- * A group of fields with a title.
- */
- typedef struct
- {
-- GaimRequestFields *fields_list;
-+ Gaim2RequestFields *fields_list;
-
- char *title;
-
- GList *fields;
-
--} GaimRequestFieldGroup;
-+} Gaim2RequestFieldGroup;
-
- /**
- * A request field.
- */
- typedef struct
- {
-- GaimRequestFieldType type;
-- GaimRequestFieldGroup *group;
-+ Gaim2RequestFieldType type;
-+ Gaim2RequestFieldGroup *group;
-
- char *id;
- char *label;
-@@ -154,11 +154,11 @@ typedef struct
-
- struct
- {
-- GaimAccount *default_account;
-- GaimAccount *account;
-+ Gaim2Account *default_account;
-+ Gaim2Account *account;
- gboolean show_all;
-
-- GaimFilterAccountFunc filter_func;
-+ Gaim2FilterAccountFunc filter_func;
-
- } account;
-
-@@ -174,7 +174,7 @@ typedef struct
-
- void *ui_data;
-
--} GaimRequestField;
-+} Gaim2RequestField;
-
- /**
- * Request UI operations.
-@@ -197,21 +197,21 @@ typedef struct
- void *user_data, size_t action_count,
- va_list actions);
- void *(*request_fields)(const char *title, const char *primary,
-- const char *secondary, GaimRequestFields *fields,
-+ const char *secondary, Gaim2RequestFields *fields,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data);
- void *(*request_file)(const char *title, const char *filename,
- gboolean savedialog, GCallback ok_cb,
- GCallback cancel_cb, void *user_data);
-- void (*close_request)(GaimRequestType type, void *ui_handle);
--} GaimRequestUiOps;
-+ void (*close_request)(Gaim2RequestType type, void *ui_handle);
-+} Gaim2RequestUiOps;
-
--typedef void (*GaimRequestInputCb)(void *, const char *);
--typedef void (*GaimRequestActionCb)(void *, int);
--typedef void (*GaimRequestChoiceCb)(void *, int);
--typedef void (*GaimRequestFieldsCb)(void *, GaimRequestFields *fields);
--typedef void (*GaimRequestFileCb)(void *, const char *filename);
-+typedef void (*Gaim2RequestInputCb)(void *, const char *);
-+typedef void (*Gaim2RequestActionCb)(void *, int);
-+typedef void (*Gaim2RequestChoiceCb)(void *, int);
-+typedef void (*Gaim2RequestFieldsCb)(void *, Gaim2RequestFields *fields);
-+typedef void (*Gaim2RequestFileCb)(void *, const char *filename);
-
- #ifdef __cplusplus
- extern "C" {
-@@ -223,18 +223,18 @@ extern "C" {
- /*@{*/
-
- /**
-- * Creates a list of fields to pass to gaim_request_fields().
-+ * Creates a list of fields to pass to gaim2_request_fields().
- *
-- * @return A GaimRequestFields structure.
-+ * @return A Gaim2RequestFields structure.
- */
--GaimRequestFields *gaim_request_fields_new(void);
-+Gaim2RequestFields *gaim2_request_fields_new(void);
-
- /**
- * Destroys a list of fields.
- *
- * @param fields The list of fields to destroy.
- */
--void gaim_request_fields_destroy(GaimRequestFields *fields);
-+void gaim2_request_fields_destroy(Gaim2RequestFields *fields);
-
- /**
- * Adds a group of fields to the list.
-@@ -242,8 +242,8 @@ void gaim_request_fields_destroy(GaimReq
- * @param fields The fields list.
- * @param group The group to add.
- */
--void gaim_request_fields_add_group(GaimRequestFields *fields,
-- GaimRequestFieldGroup *group);
-+void gaim2_request_fields_add_group(Gaim2RequestFields *fields,
-+ Gaim2RequestFieldGroup *group);
-
- /**
- * Returns a list of all groups in a field list.
-@@ -252,7 +252,7 @@ void gaim_request_fields_add_group(GaimR
- *
- * @return A list of groups.
- */
--GList *gaim_request_fields_get_groups(const GaimRequestFields *fields);
-+GList *gaim2_request_fields_get_groups(const Gaim2RequestFields *fields);
-
- /**
- * Returns whether or not the field with the specified ID exists.
-@@ -262,7 +262,7 @@ GList *gaim_request_fields_get_groups(co
- *
- * @return TRUE if the field exists, or FALSE.
- */
--gboolean gaim_request_fields_exists(const GaimRequestFields *fields,
-+gboolean gaim2_request_fields_exists(const Gaim2RequestFields *fields,
- const char *id);
-
- /**
-@@ -272,7 +272,7 @@ gboolean gaim_request_fields_exists(cons
- *
- * @return The list of required fields.
- */
--const GList *gaim_request_fields_get_required(const GaimRequestFields *fields);
-+const GList *gaim2_request_fields_get_required(const Gaim2RequestFields *fields);
-
- /**
- * Returns whether or not a field with the specified ID is required.
-@@ -282,7 +282,7 @@ const GList *gaim_request_fields_get_req
- *
- * @return TRUE if the specified field is required, or FALSE.
- */
--gboolean gaim_request_fields_is_field_required(const GaimRequestFields *fields,
-+gboolean gaim2_request_fields_is_field_required(const Gaim2RequestFields *fields,
- const char *id);
-
- /**
-@@ -292,8 +292,8 @@ gboolean gaim_request_fields_is_field_re
- *
- * @return TRUE if all required fields have values, or FALSE.
- */
--gboolean gaim_request_fields_all_required_filled(
-- const GaimRequestFields *fields);
-+gboolean gaim2_request_fields_all_required_filled(
-+ const Gaim2RequestFields *fields);
-
- /**
- * Return the field with the specified ID.
-@@ -303,8 +303,8 @@ gboolean gaim_request_fields_all_require
- *
- * @return The field, if found.
- */
--GaimRequestField *gaim_request_fields_get_field(
-- const GaimRequestFields *fields, const char *id);
-+Gaim2RequestField *gaim2_request_fields_get_field(
-+ const Gaim2RequestFields *fields, const char *id);
-
- /**
- * Returns the string value of a field with the specified ID.
-@@ -314,7 +314,7 @@ GaimRequestField *gaim_request_fields_ge
- *
- * @return The string value, if found, or @c NULL otherwise.
- */
--const char *gaim_request_fields_get_string(const GaimRequestFields *fields,
-+const char *gaim2_request_fields_get_string(const Gaim2RequestFields *fields,
- const char *id);
-
- /**
-@@ -325,7 +325,7 @@ const char *gaim_request_fields_get_stri
- *
- * @return The integer value, if found, or 0 otherwise.
- */
--int gaim_request_fields_get_integer(const GaimRequestFields *fields,
-+int gaim2_request_fields_get_integer(const Gaim2RequestFields *fields,
- const char *id);
-
- /**
-@@ -336,7 +336,7 @@ int gaim_request_fields_get_integer(cons
- *
- * @return The boolean value, if found, or @c FALSE otherwise.
- */
--gboolean gaim_request_fields_get_bool(const GaimRequestFields *fields,
-+gboolean gaim2_request_fields_get_bool(const Gaim2RequestFields *fields,
- const char *id);
-
- /**
-@@ -347,7 +347,7 @@ gboolean gaim_request_fields_get_bool(co
- *
- * @return The choice index, if found, or -1 otherwise.
- */
--int gaim_request_fields_get_choice(const GaimRequestFields *fields,
-+int gaim2_request_fields_get_choice(const Gaim2RequestFields *fields,
- const char *id);
-
- /**
-@@ -358,7 +358,7 @@ int gaim_request_fields_get_choice(const
- *
- * @return The account value, if found, or NULL otherwise.
- */
--GaimAccount *gaim_request_fields_get_account(const GaimRequestFields *fields,
-+Gaim2Account *gaim2_request_fields_get_account(const Gaim2RequestFields *fields,
- const char *id);
-
- /*@}*/
-@@ -375,14 +375,14 @@ GaimAccount *gaim_request_fields_get_acc
- *
- * @return A new fields group
- */
--GaimRequestFieldGroup *gaim_request_field_group_new(const char *title);
-+Gaim2RequestFieldGroup *gaim2_request_field_group_new(const char *title);
-
- /**
- * Destroys a fields group.
- *
- * @param group The group to destroy.
- */
--void gaim_request_field_group_destroy(GaimRequestFieldGroup *group);
-+void gaim2_request_field_group_destroy(Gaim2RequestFieldGroup *group);
-
- /**
- * Adds a field to the group.
-@@ -390,8 +390,8 @@ void gaim_request_field_group_destroy(Ga
- * @param group The group to add the field to.
- * @param field The field to add to the group.
- */
--void gaim_request_field_group_add_field(GaimRequestFieldGroup *group,
-- GaimRequestField *field);
-+void gaim2_request_field_group_add_field(Gaim2RequestFieldGroup *group,
-+ Gaim2RequestField *field);
-
- /**
- * Returns the title of a fields group.
-@@ -400,8 +400,8 @@ void gaim_request_field_group_add_field(
- *
- * @return The title, if set.
- */
--const char *gaim_request_field_group_get_title(
-- const GaimRequestFieldGroup *group);
-+const char *gaim2_request_field_group_get_title(
-+ const Gaim2RequestFieldGroup *group);
-
- /**
- * Returns a list of all fields in a group.
-@@ -410,8 +410,8 @@ const char *gaim_request_field_group_get
- *
- * @return The list of fields in the group.
- */
--GList *gaim_request_field_group_get_fields(
-- const GaimRequestFieldGroup *group);
-+GList *gaim2_request_field_group_get_fields(
-+ const Gaim2RequestFieldGroup *group);
-
- /*@}*/
-
-@@ -429,15 +429,15 @@ GList *gaim_request_field_group_get_fiel
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_new(const char *id, const char *text,
-- GaimRequestFieldType type);
-+Gaim2RequestField *gaim2_request_field_new(const char *id, const char *text,
-+ Gaim2RequestFieldType type);
-
- /**
- * Destroys a field.
- *
- * @param field The field to destroy.
- */
--void gaim_request_field_destroy(GaimRequestField *field);
-+void gaim2_request_field_destroy(Gaim2RequestField *field);
-
- /**
- * Sets the label text of a field.
-@@ -445,7 +445,7 @@ void gaim_request_field_destroy(GaimRequ
- * @param field The field.
- * @param label The text label.
- */
--void gaim_request_field_set_label(GaimRequestField *field, const char *label);
-+void gaim2_request_field_set_label(Gaim2RequestField *field, const char *label);
-
- /**
- * Sets whether or not a field is visible.
-@@ -453,7 +453,7 @@ void gaim_request_field_set_label(GaimRe
- * @param field The field.
- * @param visible TRUE if visible, or FALSE if not.
- */
--void gaim_request_field_set_visible(GaimRequestField *field, gboolean visible);
-+void gaim2_request_field_set_visible(Gaim2RequestField *field, gboolean visible);
-
- /**
- * Sets the type hint for the field.
-@@ -464,7 +464,7 @@ void gaim_request_field_set_visible(Gaim
- * @param field The field.
- * @param type_hint The type hint.
- */
--void gaim_request_field_set_type_hint(GaimRequestField *field,
-+void gaim2_request_field_set_type_hint(Gaim2RequestField *field,
- const char *type_hint);
-
- /**
-@@ -473,7 +473,7 @@ void gaim_request_field_set_type_hint(Ga
- * @param field The field.
- * @param required TRUE if required, or FALSE.
- */
--void gaim_request_field_set_required(GaimRequestField *field,
-+void gaim2_request_field_set_required(Gaim2RequestField *field,
- gboolean required);
-
- /**
-@@ -483,7 +483,7 @@ void gaim_request_field_set_required(Gai
- *
- * @return The field's type.
- */
--GaimRequestFieldType gaim_request_field_get_type(const GaimRequestField *field);
-+Gaim2RequestFieldType gaim2_request_field_get_type(const Gaim2RequestField *field);
-
- /**
- * Returns the ID of a field.
-@@ -492,7 +492,7 @@ GaimRequestFieldType gaim_request_field_
- *
- * @return The ID
- */
--const char *gaim_request_field_get_id(const GaimRequestField *field);
-+const char *gaim2_request_field_get_id(const Gaim2RequestField *field);
-
- /**
- * Returns the label text of a field.
-@@ -501,7 +501,7 @@ const char *gaim_request_field_get_id(co
- *
- * @return The label text.
- */
--const char *gaim_request_field_get_label(const GaimRequestField *field);
-+const char *gaim2_request_field_get_label(const Gaim2RequestField *field);
-
- /**
- * Returns whether or not a field is visible.
-@@ -510,7 +510,7 @@ const char *gaim_request_field_get_label
- *
- * @return TRUE if the field is visible. FALSE otherwise.
- */
--gboolean gaim_request_field_is_visible(const GaimRequestField *field);
-+gboolean gaim2_request_field_is_visible(const Gaim2RequestField *field);
-
- /**
- * Returns the field's type hint.
-@@ -519,7 +519,7 @@ gboolean gaim_request_field_is_visible(c
- *
- * @return The field's type hint.
- */
--const char *gaim_request_field_get_type_hint(const GaimRequestField *field);
-+const char *gaim2_request_field_get_type_hint(const Gaim2RequestField *field);
-
- /**
- * Returns whether or not a field is required.
-@@ -528,7 +528,7 @@ const char *gaim_request_field_get_type_
- *
- * @return TRUE if the field is required, or FALSE.
- */
--gboolean gaim_request_field_is_required(const GaimRequestField *field);
-+gboolean gaim2_request_field_is_required(const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -547,7 +547,7 @@ gboolean gaim_request_field_is_required(
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_string_new(const char *id,
-+Gaim2RequestField *gaim2_request_field_string_new(const char *id,
- const char *text,
- const char *default_value,
- gboolean multiline);
-@@ -558,7 +558,7 @@ GaimRequestField *gaim_request_field_str
- * @param field The field.
- * @param default_value The default value.
- */
--void gaim_request_field_string_set_default_value(GaimRequestField *field,
-+void gaim2_request_field_string_set_default_value(Gaim2RequestField *field,
- const char *default_value);
-
- /**
-@@ -567,7 +567,7 @@ void gaim_request_field_string_set_defau
- * @param field The field.
- * @param value The value.
- */
--void gaim_request_field_string_set_value(GaimRequestField *field,
-+void gaim2_request_field_string_set_value(Gaim2RequestField *field,
- const char *value);
-
- /**
-@@ -577,7 +577,7 @@ void gaim_request_field_string_set_value
- * @param field The field.
- * @param masked The masked value.
- */
--void gaim_request_field_string_set_masked(GaimRequestField *field,
-+void gaim2_request_field_string_set_masked(Gaim2RequestField *field,
- gboolean masked);
-
- /**
-@@ -586,7 +586,7 @@ void gaim_request_field_string_set_maske
- * @param field The field.
- * @param editable The editable value.
- */
--void gaim_request_field_string_set_editable(GaimRequestField *field,
-+void gaim2_request_field_string_set_editable(Gaim2RequestField *field,
- gboolean editable);
-
- /**
-@@ -596,8 +596,8 @@ void gaim_request_field_string_set_edita
- *
- * @return The default value.
- */
--const char *gaim_request_field_string_get_default_value(
-- const GaimRequestField *field);
-+const char *gaim2_request_field_string_get_default_value(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns the user-entered value in a string field.
-@@ -606,7 +606,7 @@ const char *gaim_request_field_string_ge
- *
- * @return The value.
- */
--const char *gaim_request_field_string_get_value(const GaimRequestField *field);
-+const char *gaim2_request_field_string_get_value(const Gaim2RequestField *field);
-
- /**
- * Returns whether or not a string field is multi-line.
-@@ -615,7 +615,7 @@ const char *gaim_request_field_string_ge
- *
- * @return @c TRUE if the field is mulit-line, or @c FALSE otherwise.
- */
--gboolean gaim_request_field_string_is_multiline(const GaimRequestField *field);
-+gboolean gaim2_request_field_string_is_multiline(const Gaim2RequestField *field);
-
- /**
- * Returns whether or not a string field is masked.
-@@ -624,7 +624,7 @@ gboolean gaim_request_field_string_is_mu
- *
- * @return @c TRUE if the field is masked, or @c FALSE otherwise.
- */
--gboolean gaim_request_field_string_is_masked(const GaimRequestField *field);
-+gboolean gaim2_request_field_string_is_masked(const Gaim2RequestField *field);
-
- /**
- * Returns whether or not a string field is editable.
-@@ -633,7 +633,7 @@ gboolean gaim_request_field_string_is_ma
- *
- * @return @c TRUE if the field is editable, or @c FALSE otherwise.
- */
--gboolean gaim_request_field_string_is_editable(const GaimRequestField *field);
-+gboolean gaim2_request_field_string_is_editable(const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -651,7 +651,7 @@ gboolean gaim_request_field_string_is_ed
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_int_new(const char *id,
-+Gaim2RequestField *gaim2_request_field_int_new(const char *id,
- const char *text,
- int default_value);
-
-@@ -661,7 +661,7 @@ GaimRequestField *gaim_request_field_int
- * @param field The field.
- * @param default_value The default value.
- */
--void gaim_request_field_int_set_default_value(GaimRequestField *field,
-+void gaim2_request_field_int_set_default_value(Gaim2RequestField *field,
- int default_value);
-
- /**
-@@ -670,7 +670,7 @@ void gaim_request_field_int_set_default_
- * @param field The field.
- * @param value The value.
- */
--void gaim_request_field_int_set_value(GaimRequestField *field, int value);
-+void gaim2_request_field_int_set_value(Gaim2RequestField *field, int value);
-
- /**
- * Returns the default value in an integer field.
-@@ -679,7 +679,7 @@ void gaim_request_field_int_set_value(Ga
- *
- * @return The default value.
- */
--int gaim_request_field_int_get_default_value(const GaimRequestField *field);
-+int gaim2_request_field_int_get_default_value(const Gaim2RequestField *field);
-
- /**
- * Returns the user-entered value in an integer field.
-@@ -688,7 +688,7 @@ int gaim_request_field_int_get_default_v
- *
- * @return The value.
- */
--int gaim_request_field_int_get_value(const GaimRequestField *field);
-+int gaim2_request_field_int_get_value(const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -708,7 +708,7 @@ int gaim_request_field_int_get_value(con
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_bool_new(const char *id,
-+Gaim2RequestField *gaim2_request_field_bool_new(const char *id,
- const char *text,
- gboolean default_value);
-
-@@ -718,7 +718,7 @@ GaimRequestField *gaim_request_field_boo
- * @param field The field.
- * @param default_value The default value.
- */
--void gaim_request_field_bool_set_default_value(GaimRequestField *field,
-+void gaim2_request_field_bool_set_default_value(Gaim2RequestField *field,
- gboolean default_value);
-
- /**
-@@ -727,7 +727,7 @@ void gaim_request_field_bool_set_default
- * @param field The field.
- * @param value The value.
- */
--void gaim_request_field_bool_set_value(GaimRequestField *field,
-+void gaim2_request_field_bool_set_value(Gaim2RequestField *field,
- gboolean value);
-
- /**
-@@ -737,8 +737,8 @@ void gaim_request_field_bool_set_value(G
- *
- * @return The default value.
- */
--gboolean gaim_request_field_bool_get_default_value(
-- const GaimRequestField *field);
-+gboolean gaim2_request_field_bool_get_default_value(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns the user-entered value in an boolean field.
-@@ -747,7 +747,7 @@ gboolean gaim_request_field_bool_get_def
- *
- * @return The value.
- */
--gboolean gaim_request_field_bool_get_value(const GaimRequestField *field);
-+gboolean gaim2_request_field_bool_get_value(const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -767,7 +767,7 @@ gboolean gaim_request_field_bool_get_val
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_choice_new(const char *id,
-+Gaim2RequestField *gaim2_request_field_choice_new(const char *id,
- const char *text,
- int default_value);
-
-@@ -777,7 +777,7 @@ GaimRequestField *gaim_request_field_cho
- * @param field The choice field.
- * @param label The choice label.
- */
--void gaim_request_field_choice_add(GaimRequestField *field,
-+void gaim2_request_field_choice_add(Gaim2RequestField *field,
- const char *label);
-
- /**
-@@ -786,7 +786,7 @@ void gaim_request_field_choice_add(GaimR
- * @param field The field.
- * @param default_value The default value.
- */
--void gaim_request_field_choice_set_default_value(GaimRequestField *field,
-+void gaim2_request_field_choice_set_default_value(Gaim2RequestField *field,
- int default_value);
-
- /**
-@@ -795,7 +795,7 @@ void gaim_request_field_choice_set_defau
- * @param field The field.
- * @param value The value.
- */
--void gaim_request_field_choice_set_value(GaimRequestField *field, int value);
-+void gaim2_request_field_choice_set_value(Gaim2RequestField *field, int value);
-
- /**
- * Returns the default value in an choice field.
-@@ -804,7 +804,7 @@ void gaim_request_field_choice_set_value
- *
- * @return The default value.
- */
--int gaim_request_field_choice_get_default_value(const GaimRequestField *field);
-+int gaim2_request_field_choice_get_default_value(const Gaim2RequestField *field);
-
- /**
- * Returns the user-entered value in an choice field.
-@@ -813,7 +813,7 @@ int gaim_request_field_choice_get_defaul
- *
- * @return The value.
- */
--int gaim_request_field_choice_get_value(const GaimRequestField *field);
-+int gaim2_request_field_choice_get_value(const Gaim2RequestField *field);
-
- /**
- * Returns a list of labels in a choice field.
-@@ -822,7 +822,7 @@ int gaim_request_field_choice_get_value(
- *
- * @return The list of labels.
- */
--GList *gaim_request_field_choice_get_labels(const GaimRequestField *field);
-+GList *gaim2_request_field_choice_get_labels(const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -839,7 +839,7 @@ GList *gaim_request_field_choice_get_lab
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_list_new(const char *id, const char *text);
-+Gaim2RequestField *gaim2_request_field_list_new(const char *id, const char *text);
-
- /**
- * Sets whether or not a list field allows multiple selection.
-@@ -848,7 +848,7 @@ GaimRequestField *gaim_request_field_lis
- * @param multi_select TRUE if multiple selection is enabled,
- * or FALSE otherwise.
- */
--void gaim_request_field_list_set_multi_select(GaimRequestField *field,
-+void gaim2_request_field_list_set_multi_select(Gaim2RequestField *field,
- gboolean multi_select);
-
- /**
-@@ -858,8 +858,8 @@ void gaim_request_field_list_set_multi_s
- *
- * @return TRUE if multiple selection is enabled, or FALSE otherwise.
- */
--gboolean gaim_request_field_list_get_multi_select(
-- const GaimRequestField *field);
-+gboolean gaim2_request_field_list_get_multi_select(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns the data for a particular item.
-@@ -869,7 +869,7 @@ gboolean gaim_request_field_list_get_mul
- *
- * @return The data associated with the item.
- */
--void *gaim_request_field_list_get_data(const GaimRequestField *field,
-+void *gaim2_request_field_list_get_data(const Gaim2RequestField *field,
- const char *text);
-
- /**
-@@ -879,7 +879,7 @@ void *gaim_request_field_list_get_data(c
- * @param item The list item.
- * @param data The associated data.
- */
--void gaim_request_field_list_add(GaimRequestField *field,
-+void gaim2_request_field_list_add(Gaim2RequestField *field,
- const char *item, void *data);
-
- /**
-@@ -888,7 +888,7 @@ void gaim_request_field_list_add(GaimReq
- * @param field The field.
- * @param item The item to add.
- */
--void gaim_request_field_list_add_selected(GaimRequestField *field,
-+void gaim2_request_field_list_add_selected(Gaim2RequestField *field,
- const char *item);
-
- /**
-@@ -896,7 +896,7 @@ void gaim_request_field_list_add_selecte
- *
- * @param field The field.
- */
--void gaim_request_field_list_clear_selected(GaimRequestField *field);
-+void gaim2_request_field_list_clear_selected(Gaim2RequestField *field);
-
- /**
- * Sets a list of selected items in a list field.
-@@ -904,7 +904,7 @@ void gaim_request_field_list_clear_selec
- * @param field The field.
- * @param items The list of selected items.
- */
--void gaim_request_field_list_set_selected(GaimRequestField *field,
-+void gaim2_request_field_list_set_selected(Gaim2RequestField *field,
- GList *items);
-
- /**
-@@ -915,21 +915,21 @@ void gaim_request_field_list_set_selecte
- *
- * @return TRUE if the item is selected. FALSE otherwise.
- */
--gboolean gaim_request_field_list_is_selected(const GaimRequestField *field,
-+gboolean gaim2_request_field_list_is_selected(const Gaim2RequestField *field,
- const char *item);
-
- /**
- * Returns a list of selected items in a list field.
- *
- * To retrieve the data for each item, use
-- * gaim_request_field_list_get_data().
-+ * gaim2_request_field_list_get_data().
- *
- * @param field The field.
- *
- * @return The list of selected items.
- */
--const GList *gaim_request_field_list_get_selected(
-- const GaimRequestField *field);
-+const GList *gaim2_request_field_list_get_selected(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns a list of items in a list field.
-@@ -938,7 +938,7 @@ const GList *gaim_request_field_list_get
- *
- * @return The list of items.
- */
--const GList *gaim_request_field_list_get_items(const GaimRequestField *field);
-+const GList *gaim2_request_field_list_get_items(const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -955,7 +955,7 @@ const GList *gaim_request_field_list_get
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_label_new(const char *id,
-+Gaim2RequestField *gaim2_request_field_label_new(const char *id,
- const char *text);
-
- /*@}*/
-@@ -975,7 +975,7 @@ GaimRequestField *gaim_request_field_lab
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_image_new(const char *id, const char *text,
-+Gaim2RequestField *gaim2_request_field_image_new(const char *id, const char *text,
- const char *buf, gsize size);
-
- /**
-@@ -985,7 +985,7 @@ GaimRequestField *gaim_request_field_ima
- * @param x The x scale factor.
- * @param y The y scale factor.
- */
--void gaim_request_field_image_set_scale(GaimRequestField *field, unsigned int x, unsigned int y);
-+void gaim2_request_field_image_set_scale(Gaim2RequestField *field, unsigned int x, unsigned int y);
-
- /**
- * Returns pointer to the image.
-@@ -994,7 +994,7 @@ void gaim_request_field_image_set_scale(
- *
- * @return Pointer to the image.
- */
--const char *gaim_request_field_image_get_buffer(GaimRequestField *field);
-+const char *gaim2_request_field_image_get_buffer(Gaim2RequestField *field);
-
- /**
- * Returns size (in bytes) of the image.
-@@ -1003,7 +1003,7 @@ const char *gaim_request_field_image_get
- *
- * @return Size of the image.
- */
--gsize gaim_request_field_image_get_size(GaimRequestField *field);
-+gsize gaim2_request_field_image_get_size(Gaim2RequestField *field);
-
- /**
- * Returns X scale coefficient of the image.
-@@ -1012,7 +1012,7 @@ gsize gaim_request_field_image_get_size(
- *
- * @return X scale coefficient of the image.
- */
--unsigned int gaim_request_field_image_get_scale_x(GaimRequestField *field);
-+unsigned int gaim2_request_field_image_get_scale_x(Gaim2RequestField *field);
-
- /**
- * Returns Y scale coefficient of the image.
-@@ -1021,7 +1021,7 @@ unsigned int gaim_request_field_image_ge
- *
- * @return Y scale coefficient of the image.
- */
--unsigned int gaim_request_field_image_get_scale_y(GaimRequestField *field);
-+unsigned int gaim2_request_field_image_get_scale_y(Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -1041,9 +1041,9 @@ unsigned int gaim_request_field_image_ge
- *
- * @return The new field.
- */
--GaimRequestField *gaim_request_field_account_new(const char *id,
-+Gaim2RequestField *gaim2_request_field_account_new(const char *id,
- const char *text,
-- GaimAccount *account);
-+ Gaim2Account *account);
-
- /**
- * Sets the default account on an account field.
-@@ -1051,8 +1051,8 @@ GaimRequestField *gaim_request_field_acc
- * @param field The account field.
- * @param default_value The default account.
- */
--void gaim_request_field_account_set_default_value(GaimRequestField *field,
-- GaimAccount *default_value);
-+void gaim2_request_field_account_set_default_value(Gaim2RequestField *field,
-+ Gaim2Account *default_value);
-
- /**
- * Sets the account in an account field.
-@@ -1060,8 +1060,8 @@ void gaim_request_field_account_set_defa
- * @param field The account field.
- * @param value The account.
- */
--void gaim_request_field_account_set_value(GaimRequestField *field,
-- GaimAccount *value);
-+void gaim2_request_field_account_set_value(Gaim2RequestField *field,
-+ Gaim2Account *value);
-
- /**
- * Sets whether or not to show all accounts in an account field.
-@@ -1072,7 +1072,7 @@ void gaim_request_field_account_set_valu
- * @param field The account field.
- * @param show_all Whether or not to show all accounts.
- */
--void gaim_request_field_account_set_show_all(GaimRequestField *field,
-+void gaim2_request_field_account_set_show_all(Gaim2RequestField *field,
- gboolean show_all);
-
- /**
-@@ -1084,8 +1084,8 @@ void gaim_request_field_account_set_show
- * @param field The account field.
- * @param filter_func The account filter function.
- */
--void gaim_request_field_account_set_filter(GaimRequestField *field,
-- GaimFilterAccountFunc filter_func);
-+void gaim2_request_field_account_set_filter(Gaim2RequestField *field,
-+ Gaim2FilterAccountFunc filter_func);
-
- /**
- * Returns the default account in an account field.
-@@ -1094,8 +1094,8 @@ void gaim_request_field_account_set_filt
- *
- * @return The default account.
- */
--GaimAccount *gaim_request_field_account_get_default_value(
-- const GaimRequestField *field);
-+Gaim2Account *gaim2_request_field_account_get_default_value(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns the user-entered account in an account field.
-@@ -1104,8 +1104,8 @@ GaimAccount *gaim_request_field_account_
- *
- * @return The user-entered account.
- */
--GaimAccount *gaim_request_field_account_get_value(
-- const GaimRequestField *field);
-+Gaim2Account *gaim2_request_field_account_get_value(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns whether or not to show all accounts in an account field.
-@@ -1116,8 +1116,8 @@ GaimAccount *gaim_request_field_account_
- * @param field The account field.
- * @return Whether or not to show all accounts.
- */
--gboolean gaim_request_field_account_get_show_all(
-- const GaimRequestField *field);
-+gboolean gaim2_request_field_account_get_show_all(
-+ const Gaim2RequestField *field);
-
- /**
- * Returns the account filter function in an account field.
-@@ -1129,8 +1129,8 @@ gboolean gaim_request_field_account_get_
- *
- * @return The account filter function.
- */
--GaimFilterAccountFunc gaim_request_field_account_get_filter(
-- const GaimRequestField *field);
-+Gaim2FilterAccountFunc gaim2_request_field_account_get_filter(
-+ const Gaim2RequestField *field);
-
- /*@}*/
-
-@@ -1147,7 +1147,7 @@ GaimFilterAccountFunc gaim_request_field
- * handle is used to programmatically close
- * the request dialog when it is no longer
- * needed. For PRPLs this is often a pointer
-- * to the GaimConnection instance. For plugins
-+ * to the Gaim2Connection instance. For plugins
- * this should be a similar, unique memory
- * location. This value is important because
- * it allows a request to be closed, say, when
-@@ -1172,7 +1172,7 @@ GaimFilterAccountFunc gaim_request_field
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_input(void *handle, const char *title,
-+void *gaim2_request_input(void *handle, const char *title,
- const char *primary, const char *secondary,
- const char *default_value,
- gboolean multiline, gboolean masked, gchar *hint,
-@@ -1185,7 +1185,7 @@ void *gaim_request_input(void *handle, c
- *
- * @param handle The plugin or connection handle. For some
- * things this is EXTREMELY important. See
-- * the comments on gaim_request_input.
-+ * the comments on gaim2_request_input.
- * @param title The title of the message.
- * @param primary The main point of the message.
- * @param secondary The secondary information.
-@@ -1200,7 +1200,7 @@ void *gaim_request_input(void *handle, c
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_choice(void *handle, const char *title,
-+void *gaim2_request_choice(void *handle, const char *title,
- const char *primary, const char *secondary,
- unsigned int default_value,
- const char *ok_text, GCallback ok_cb,
-@@ -1212,7 +1212,7 @@ void *gaim_request_choice(void *handle,
- *
- * @param handle The plugin or connection handle. For some
- * things this is EXTREMELY important. See
-- * the comments on gaim_request_input.
-+ * the comments on gaim2_request_input.
- * @param title The title of the message.
- * @param primary The main point of the message.
- * @param secondary The secondary information.
-@@ -1227,7 +1227,7 @@ void *gaim_request_choice(void *handle,
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_choice_varg(void *handle, const char *title,
-+void *gaim2_request_choice_varg(void *handle, const char *title,
- const char *primary, const char *secondary,
- unsigned int default_value,
- const char *ok_text, GCallback ok_cb,
-@@ -1241,7 +1241,7 @@ void *gaim_request_choice_varg(void *han
- *
- * @param handle The plugin or connection handle. For some
- * things this is EXTREMELY important. See
-- * the comments on gaim_request_input.
-+ * the comments on gaim2_request_input.
- * @param title The title of the message.
- * @param primary The main point of the message.
- * @param secondary The secondary information.
-@@ -1252,7 +1252,7 @@ void *gaim_request_choice_varg(void *han
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_action(void *handle, const char *title,
-+void *gaim2_request_action(void *handle, const char *title,
- const char *primary, const char *secondary,
- unsigned int default_action,
- void *user_data, size_t action_count, ...);
-@@ -1264,7 +1264,7 @@ void *gaim_request_action(void *handle,
- *
- * @param handle The plugin or connection handle. For some
- * things this is EXTREMELY important. See
-- * the comments on gaim_request_input.
-+ * the comments on gaim2_request_input.
- * @param title The title of the message.
- * @param primary The main point of the message.
- * @param secondary The secondary information.
-@@ -1275,7 +1275,7 @@ void *gaim_request_action(void *handle,
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_action_varg(void *handle, const char *title,
-+void *gaim2_request_action_varg(void *handle, const char *title,
- const char *primary, const char *secondary,
- unsigned int default_action,
- void *user_data, size_t action_count,
-@@ -1286,7 +1286,7 @@ void *gaim_request_action_varg(void *han
- *
- * @param handle The plugin or connection handle. For some
- * things this is EXTREMELY important. See
-- * the comments on gaim_request_input.
-+ * the comments on gaim2_request_input.
- * @param title The title of the message.
- * @param primary The main point of the message.
- * @param secondary The secondary information.
-@@ -1299,9 +1299,9 @@ void *gaim_request_action_varg(void *han
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_fields(void *handle, const char *title,
-+void *gaim2_request_fields(void *handle, const char *title,
- const char *primary, const char *secondary,
-- GaimRequestFields *fields,
-+ Gaim2RequestFields *fields,
- const char *ok_text, GCallback ok_cb,
- const char *cancel_text, GCallback cancel_cb,
- void *user_data);
-@@ -1312,40 +1312,40 @@ void *gaim_request_fields(void *handle,
- * @param type The request type.
- * @param uihandle The request UI handle.
- */
--void gaim_request_close(GaimRequestType type, void *uihandle);
-+void gaim2_request_close(Gaim2RequestType type, void *uihandle);
-
- /**
- * Closes all requests registered with the specified handle.
- *
- * @param handle The handle.
- */
--void gaim_request_close_with_handle(void *handle);
-+void gaim2_request_close_with_handle(void *handle);
-
- /**
-- * A wrapper for gaim_request_action() that uses Yes and No buttons.
-+ * A wrapper for gaim2_request_action() that uses Yes and No buttons.
- */
--#define gaim_request_yes_no(handle, title, primary, secondary, \
-+#define gaim2_request_yes_no(handle, title, primary, secondary, \
- default_action, user_data, yes_cb, no_cb) \
-- gaim_request_action((handle), (title), (primary), (secondary), \
-+ gaim2_request_action((handle), (title), (primary), (secondary), \
- (default_action), (user_data), 2, \
- _("Yes"), (yes_cb), _("No"), (no_cb))
-
- /**
-- * A wrapper for gaim_request_action() that uses OK and Cancel buttons.
-+ * A wrapper for gaim2_request_action() that uses OK and Cancel buttons.
- */
--#define gaim_request_ok_cancel(handle, title, primary, secondary, \
-+#define gaim2_request_ok_cancel(handle, title, primary, secondary, \
- default_action, user_data, ok_cb, cancel_cb) \
-- gaim_request_action((handle), (title), (primary), (secondary), \
-+ gaim2_request_action((handle), (title), (primary), (secondary), \
- (default_action), (user_data), 2, \
- _("OK"), (ok_cb), _("Cancel"), (cancel_cb))
-
- /**
-- * A wrapper for gaim_request_action() that uses Accept and Cancel buttons.
-+ * A wrapper for gaim2_request_action() that uses Accept and Cancel buttons.
- */
--#define gaim_request_accept_cancel(handle, title, primary, secondary, \
-+#define gaim2_request_accept_cancel(handle, title, primary, secondary, \
- default_action, user_data, accept_cb, \
- cancel_cb) \
-- gaim_request_action((handle), (title), (primary), (secondary), \
-+ gaim2_request_action((handle), (title), (primary), (secondary), \
- (default_action), (user_data), 2, \
- _("_Accept"), (accept_cb), _("Cancel"), (cancel_cb))
-
-@@ -1355,7 +1355,7 @@ void gaim_request_close_with_handle(void
- *
- * @param handle The plugin or connection handle. For some
- * things this is EXTREMELY important. See
-- * the comments on gaim_request_input.
-+ * the comments on gaim2_request_input.
- * @param title The title for the dialog (may be NULL)
- * @param filename The default filename (may be NULL)
- * @param savedialog True if this dialog is being used to save a file.
-@@ -1366,7 +1366,7 @@ void gaim_request_close_with_handle(void
- *
- * @return A UI-specific handle.
- */
--void *gaim_request_file(void *handle, const char *title, const char *filename,
-+void *gaim2_request_file(void *handle, const char *title, const char *filename,
- gboolean savedialog,
- GCallback ok_cb, GCallback cancel_cb,
- void *user_data);
-@@ -1384,7 +1384,7 @@ void *gaim_request_file(void *handle, co
- *
- * @param ops The UI operations structure.
- */
--void gaim_request_set_ui_ops(GaimRequestUiOps *ops);
-+void gaim2_request_set_ui_ops(Gaim2RequestUiOps *ops);
-
- /**
- * Returns the UI operations structure to be used when displaying a
-@@ -1392,7 +1392,7 @@ void gaim_request_set_ui_ops(GaimRequest
- *
- * @return The UI operations structure.
- */
--GaimRequestUiOps *gaim_request_get_ui_ops(void);
-+Gaim2RequestUiOps *gaim2_request_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/roomlist.c ./src/roomlist.c
---- ./src/roomlist.c 2005-11-28 12:47:50.000000000 +0100
-+++ ./src/roomlist.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file roomlist.c Room List API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -32,26 +32,26 @@
- #include "server.h"
-
-
--static GaimRoomlistUiOps *ops = NULL;
-+static Gaim2RoomlistUiOps *ops = NULL;
-
- /**************************************************************************/
- /** @name Room List API */
- /**************************************************************************/
- /*@{*/
-
--void gaim_roomlist_show_with_account(GaimAccount *account)
-+void gaim2_roomlist_show_with_account(Gaim2Account *account)
- {
- if (ops && ops->show_with_account)
- ops->show_with_account(account);
- }
-
--GaimRoomlist *gaim_roomlist_new(GaimAccount *account)
-+Gaim2Roomlist *gaim2_roomlist_new(Gaim2Account *account)
- {
-- GaimRoomlist *list;
-+ Gaim2Roomlist *list;
-
- g_return_val_if_fail(account != NULL, NULL);
-
-- list = g_new0(GaimRoomlist, 1);
-+ list = g_new0(Gaim2Roomlist, 1);
- list->account = account;
- list->rooms = NULL;
- list->fields = NULL;
-@@ -63,20 +63,20 @@ GaimRoomlist *gaim_roomlist_new(GaimAcco
- return list;
- }
-
--void gaim_roomlist_ref(GaimRoomlist *list)
-+void gaim2_roomlist_ref(Gaim2Roomlist *list)
- {
- g_return_if_fail(list != NULL);
-
- list->ref++;
-- gaim_debug_misc("roomlist", "reffing list, ref count now %d\n", list->ref);
-+ gaim2_debug_misc("roomlist", "reffing list, ref count now %d\n", list->ref);
- }
-
--static void gaim_roomlist_room_destroy(GaimRoomlist *list, GaimRoomlistRoom *r)
-+static void gaim2_roomlist_room_destroy(Gaim2Roomlist *list, Gaim2RoomlistRoom *r)
- {
- GList *l, *j;
-
- for (l = list->fields, j = r->fields; l && j; l = l->next, j = j->next) {
-- GaimRoomlistField *f = l->data;
-+ Gaim2RoomlistField *f = l->data;
- if (f->type == GAIM_ROOMLIST_FIELD_STRING)
- g_free(j->data);
- }
-@@ -86,34 +86,34 @@ static void gaim_roomlist_room_destroy(G
- g_free(r);
- }
-
--static void gaim_roomlist_field_destroy(GaimRoomlistField *f)
-+static void gaim2_roomlist_field_destroy(Gaim2RoomlistField *f)
- {
- g_free(f->label);
- g_free(f->name);
- g_free(f);
- }
-
--static void gaim_roomlist_destroy(GaimRoomlist *list)
-+static void gaim2_roomlist_destroy(Gaim2Roomlist *list)
- {
- GList *l;
-
-- gaim_debug_misc("roomlist", "destroying list %p\n", list);
-+ gaim2_debug_misc("roomlist", "destroying list %p\n", list);
-
- if (ops && ops->destroy)
- ops->destroy(list);
-
- if (list->rooms) {
- for (l = list->rooms; l; l = l->next) {
-- GaimRoomlistRoom *r = l->data;
-- gaim_roomlist_room_destroy(list, r);
-+ Gaim2RoomlistRoom *r = l->data;
-+ gaim2_roomlist_room_destroy(list, r);
- }
- g_list_free(list->rooms);
- }
-
- if (list->fields) {
- for (l = list->fields; l; l = l->next) {
-- GaimRoomlistField *f = l->data;
-- gaim_roomlist_field_destroy(f);
-+ Gaim2RoomlistField *f = l->data;
-+ gaim2_roomlist_field_destroy(f);
- }
- g_list_free(list->fields);
- }
-@@ -121,19 +121,19 @@ static void gaim_roomlist_destroy(GaimRo
- g_free(list);
- }
-
--void gaim_roomlist_unref(GaimRoomlist *list)
-+void gaim2_roomlist_unref(Gaim2Roomlist *list)
- {
- g_return_if_fail(list != NULL);
- g_return_if_fail(list->ref > 0);
-
- list->ref--;
-
-- gaim_debug_misc("roomlist", "unreffing list, ref count now %d\n", list->ref);
-+ gaim2_debug_misc("roomlist", "unreffing list, ref count now %d\n", list->ref);
- if (list->ref == 0)
-- gaim_roomlist_destroy(list);
-+ gaim2_roomlist_destroy(list);
- }
-
--void gaim_roomlist_set_fields(GaimRoomlist *list, GList *fields)
-+void gaim2_roomlist_set_fields(Gaim2Roomlist *list, GList *fields)
- {
- g_return_if_fail(list != NULL);
-
-@@ -143,7 +143,7 @@ void gaim_roomlist_set_fields(GaimRoomli
- ops->set_fields(list, fields);
- }
-
--void gaim_roomlist_set_in_progress(GaimRoomlist *list, gboolean in_progress)
-+void gaim2_roomlist_set_in_progress(Gaim2Roomlist *list, gboolean in_progress)
- {
- g_return_if_fail(list != NULL);
-
-@@ -153,14 +153,14 @@ void gaim_roomlist_set_in_progress(GaimR
- ops->in_progress(list, in_progress);
- }
-
--gboolean gaim_roomlist_get_in_progress(GaimRoomlist *list)
-+gboolean gaim2_roomlist_get_in_progress(Gaim2Roomlist *list)
- {
- g_return_val_if_fail(list != NULL, FALSE);
-
- return list->in_progress;
- }
-
--void gaim_roomlist_room_add(GaimRoomlist *list, GaimRoomlistRoom *room)
-+void gaim2_roomlist_room_add(Gaim2Roomlist *list, Gaim2RoomlistRoom *room)
- {
- g_return_if_fail(list != NULL);
- g_return_if_fail(room != NULL);
-@@ -171,9 +171,9 @@ void gaim_roomlist_room_add(GaimRoomlist
- ops->add_room(list, room);
- }
-
--GaimRoomlist *gaim_roomlist_get_list(GaimConnection *gc)
-+Gaim2Roomlist *gaim2_roomlist_get_list(Gaim2Connection *gc)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- g_return_val_if_fail(gc != NULL, NULL);
-
-@@ -185,14 +185,14 @@ GaimRoomlist *gaim_roomlist_get_list(Gai
- return NULL;
- }
-
--void gaim_roomlist_cancel_get_list(GaimRoomlist *list)
-+void gaim2_roomlist_cancel_get_list(Gaim2Roomlist *list)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(list != NULL);
-
-- gc = gaim_account_get_connection(list->account);
-+ gc = gaim2_account_get_connection(list->account);
-
- g_return_if_fail(gc != NULL);
-
-@@ -203,16 +203,16 @@ void gaim_roomlist_cancel_get_list(GaimR
- prpl_info->roomlist_cancel(list);
- }
-
--void gaim_roomlist_expand_category(GaimRoomlist *list, GaimRoomlistRoom *category)
-+void gaim2_roomlist_expand_category(Gaim2Roomlist *list, Gaim2RoomlistRoom *category)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConnection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(list != NULL);
- g_return_if_fail(category != NULL);
- g_return_if_fail(category->type & GAIM_ROOMLIST_ROOMTYPE_CATEGORY);
-
-- gc = gaim_account_get_connection(list->account);
-+ gc = gaim2_account_get_connection(list->account);
- g_return_if_fail(gc != NULL);
-
- if (gc->prpl != NULL)
-@@ -229,14 +229,14 @@ void gaim_roomlist_expand_category(GaimR
- /**************************************************************************/
- /*@{*/
-
--GaimRoomlistRoom *gaim_roomlist_room_new(GaimRoomlistRoomType type, const gchar *name,
-- GaimRoomlistRoom *parent)
-+Gaim2RoomlistRoom *gaim2_roomlist_room_new(Gaim2RoomlistRoomType type, const gchar *name,
-+ Gaim2RoomlistRoom *parent)
- {
-- GaimRoomlistRoom *room;
-+ Gaim2RoomlistRoom *room;
-
- g_return_val_if_fail(name != NULL, NULL);
-
-- room = g_new0(GaimRoomlistRoom, 1);
-+ room = g_new0(Gaim2RoomlistRoom, 1);
- room->type = type;
- room->name = g_strdup(name);
- room->parent = parent;
-@@ -244,9 +244,9 @@ GaimRoomlistRoom *gaim_roomlist_room_new
- return room;
- }
-
--void gaim_roomlist_room_add_field(GaimRoomlist *list, GaimRoomlistRoom *room, gconstpointer field)
-+void gaim2_roomlist_room_add_field(Gaim2Roomlist *list, Gaim2RoomlistRoom *room, gconstpointer field)
- {
-- GaimRoomlistField *f;
-+ Gaim2RoomlistField *f;
-
- g_return_if_fail(list != NULL);
- g_return_if_fail(room != NULL);
-@@ -270,16 +270,16 @@ void gaim_roomlist_room_add_field(GaimRo
- }
- }
-
--void gaim_roomlist_room_join(GaimRoomlist *list, GaimRoomlistRoom *room)
-+void gaim2_roomlist_room_join(Gaim2Roomlist *list, Gaim2RoomlistRoom *room)
- {
- GHashTable *components;
- GList *l, *j;
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
-
- g_return_if_fail(list != NULL);
- g_return_if_fail(room != NULL);
-
-- gc = gaim_account_get_connection(list->account);
-+ gc = gaim2_account_get_connection(list->account);
- if (!gc)
- return;
-
-@@ -287,7 +287,7 @@ void gaim_roomlist_room_join(GaimRoomlis
-
- g_hash_table_replace(components, "name", room->name);
- for (l = list->fields, j = room->fields; l && j; l = l->next, j = j->next) {
-- GaimRoomlistField *f = l->data;
-+ Gaim2RoomlistField *f = l->data;
-
- g_hash_table_replace(components, f->name, j->data);
- }
-@@ -304,16 +304,16 @@ void gaim_roomlist_room_join(GaimRoomlis
- /**************************************************************************/
- /*@{*/
-
--GaimRoomlistField *gaim_roomlist_field_new(GaimRoomlistFieldType type,
-+Gaim2RoomlistField *gaim2_roomlist_field_new(Gaim2RoomlistFieldType type,
- const gchar *label, const gchar *name,
- gboolean hidden)
- {
-- GaimRoomlistField *f;
-+ Gaim2RoomlistField *f;
-
- g_return_val_if_fail(label != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
-
-- f = g_new0(GaimRoomlistField, 1);
-+ f = g_new0(Gaim2RoomlistField, 1);
-
- f->type = type;
- f->label = g_strdup(label);
-@@ -331,12 +331,12 @@ GaimRoomlistField *gaim_roomlist_field_n
- /*@{*/
-
-
--void gaim_roomlist_set_ui_ops(GaimRoomlistUiOps *ui_ops)
-+void gaim2_roomlist_set_ui_ops(Gaim2RoomlistUiOps *ui_ops)
- {
- ops = ui_ops;
- }
-
--GaimRoomlistUiOps *gaim_roomlist_get_ui_ops(void)
-+Gaim2RoomlistUiOps *gaim2_roomlist_get_ui_ops(void)
- {
- return ops;
- }
-diff -prNu ./src/roomlist.h ./src/roomlist.h
---- ./src/roomlist.h 2004-09-15 15:11:44.000000000 +0200
-+++ ./src/roomlist.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file roomlist.h Room List API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,10 +26,10 @@
- #ifndef _GAIM_ROOMLIST_H_
- #define _GAIM_ROOMLIST_H_
-
--typedef struct _GaimRoomlist GaimRoomlist;
--typedef struct _GaimRoomlistRoom GaimRoomlistRoom;
--typedef struct _GaimRoomlistField GaimRoomlistField;
--typedef struct _GaimRoomlistUiOps GaimRoomlistUiOps;
-+typedef struct _Gaim2Roomlist Gaim2Roomlist;
-+typedef struct _Gaim2RoomlistRoom Gaim2RoomlistRoom;
-+typedef struct _Gaim2RoomlistField Gaim2RoomlistField;
-+typedef struct _Gaim2RoomlistUiOps Gaim2RoomlistUiOps;
-
- /**
- * The types of rooms.
-@@ -41,7 +41,7 @@ typedef enum
- GAIM_ROOMLIST_ROOMTYPE_CATEGORY = 0x01, /**< It's a category, but not a room you can join. */
- GAIM_ROOMLIST_ROOMTYPE_ROOM = 0x02 /**< It's a room, like the kind you can join. */
-
--} GaimRoomlistRoomType;
-+} Gaim2RoomlistRoomType;
-
- /**
- * The types of fields.
-@@ -52,7 +52,7 @@ typedef enum
- GAIM_ROOMLIST_FIELD_INT,
- GAIM_ROOMLIST_FIELD_STRING /**< We do a g_strdup on the passed value if it's this type. */
-
--} GaimRoomlistFieldType;
-+} Gaim2RoomlistFieldType;
-
- #include "account.h"
- #include "glib.h"
-@@ -64,8 +64,8 @@ typedef enum
- /**
- * Represents a list of rooms for a given connection on a given protocol.
- */
--struct _GaimRoomlist {
-- GaimAccount *account; /**< The account this list belongs to. */
-+struct _Gaim2Roomlist {
-+ Gaim2Account *account; /**< The account this list belongs to. */
- GList *fields; /**< The fields. */
- GList *rooms; /**< The list of rooms. */
- gboolean in_progress; /**< The listing is in progress. */
-@@ -77,19 +77,19 @@ struct _GaimRoomlist {
- /**
- * Represents a room.
- */
--struct _GaimRoomlistRoom {
-- GaimRoomlistRoomType type; /**< The type of room. */
-+struct _Gaim2RoomlistRoom {
-+ Gaim2RoomlistRoomType type; /**< The type of room. */
- gchar *name; /**< The name of the room. */
- GList *fields; /**< Other fields. */
-- GaimRoomlistRoom *parent; /**< The parent room, or NULL. */
-+ Gaim2RoomlistRoom *parent; /**< The parent room, or NULL. */
- gboolean expanded_once; /**< A flag the UI uses to avoid multiple expand prpl cbs. */
- };
-
- /**
- * A field a room might have.
- */
--struct _GaimRoomlistField {
-- GaimRoomlistFieldType type; /**< The type of field. */
-+struct _Gaim2RoomlistField {
-+ Gaim2RoomlistFieldType type; /**< The type of field. */
- gchar *label; /**< The i18n user displayed name of the field. */
- gchar *name; /**< The internal name of the field. */
- gboolean hidden; /**< Hidden? */
-@@ -98,13 +98,13 @@ struct _GaimRoomlistField {
- /**
- * The room list ops to be filled out by the UI.
- */
--struct _GaimRoomlistUiOps {
-- void (*show_with_account)(GaimAccount *account); /**< Force the ui to pop up a dialog and get the list */
-- void (*create)(GaimRoomlist *list); /**< A new list was created. */
-- void (*set_fields)(GaimRoomlist *list, GList *fields); /**< Sets the columns. */
-- void (*add_room)(GaimRoomlist *list, GaimRoomlistRoom *room); /**< Add a room to the list. */
-- void (*in_progress)(GaimRoomlist *list, gboolean flag); /**< Are we fetching stuff still? */
-- void (*destroy)(GaimRoomlist *list); /**< We're destroying list. */
-+struct _Gaim2RoomlistUiOps {
-+ void (*show_with_account)(Gaim2Account *account); /**< Force the ui to pop up a dialog and get the list */
-+ void (*create)(Gaim2Roomlist *list); /**< A new list was created. */
-+ void (*set_fields)(Gaim2Roomlist *list, GList *fields); /**< Sets the columns. */
-+ void (*add_room)(Gaim2Roomlist *list, Gaim2RoomlistRoom *room); /**< Add a room to the list. */
-+ void (*in_progress)(Gaim2Roomlist *list, gboolean flag); /**< Are we fetching stuff still? */
-+ void (*destroy)(Gaim2Roomlist *list); /**< We're destroying list. */
- };
-
-
-@@ -126,7 +126,7 @@ extern "C" {
- *
- * @param account The account to get the list on.
- */
--void gaim_roomlist_show_with_account(GaimAccount *account);
-+void gaim2_roomlist_show_with_account(Gaim2Account *account);
-
- /**
- * Returns a newly created room list object.
-@@ -136,14 +136,14 @@ void gaim_roomlist_show_with_account(Gai
- * @param account The account that's listing rooms.
- * @return The new room list handle.
- */
--GaimRoomlist *gaim_roomlist_new(GaimAccount *account);
-+Gaim2Roomlist *gaim2_roomlist_new(Gaim2Account *account);
-
- /**
- * Increases the reference count on the room list.
- *
- * @param list The object to ref.
- */
--void gaim_roomlist_ref(GaimRoomlist *list);
-+void gaim2_roomlist_ref(Gaim2Roomlist *list);
-
- /**
- * Decreases the reference count on the room list.
-@@ -153,18 +153,18 @@ void gaim_roomlist_ref(GaimRoomlist *lis
- * @param list The room list object to unref and possibly
- * destroy.
- */
--void gaim_roomlist_unref(GaimRoomlist *list);
-+void gaim2_roomlist_unref(Gaim2Roomlist *list);
-
- /**
- * Set the different field types and their names for this protocol.
- *
-- * This must be called before gaim_roomlist_room_add().
-+ * This must be called before gaim2_roomlist_room_add().
- *
- * @param list The room list.
-- * @param fields A GList of GaimRoomlistField's. UI's are encouraged
-+ * @param fields A GList of Gaim2RoomlistField's. UI's are encouraged
- * to default to displaying them in the order given.
- */
--void gaim_roomlist_set_fields(GaimRoomlist *list, GList *fields);
-+void gaim2_roomlist_set_fields(Gaim2Roomlist *list, GList *fields);
-
- /**
- * Set the "in progress" state of the room list.
-@@ -175,7 +175,7 @@ void gaim_roomlist_set_fields(GaimRoomli
- * @param list The room list.
- * @param in_progress We're downloading it, or we're not.
- */
--void gaim_roomlist_set_in_progress(GaimRoomlist *list, gboolean in_progress);
-+void gaim2_roomlist_set_in_progress(Gaim2Roomlist *list, gboolean in_progress);
-
- /**
- * Gets the "in progress" state of the room list.
-@@ -186,27 +186,27 @@ void gaim_roomlist_set_in_progress(GaimR
- * @param list The room list.
- * @return True if we're downloading it, or false if we're not.
- */
--gboolean gaim_roomlist_get_in_progress(GaimRoomlist *list);
-+gboolean gaim2_roomlist_get_in_progress(Gaim2Roomlist *list);
-
- /**
- * Adds a room to the list of them.
- *
- * @param list The room list.
- * @param room The room to add to the list. The GList of fields must be in the same
-- order as was given in gaim_roomlist_set_fields().
-+ order as was given in gaim2_roomlist_set_fields().
- */
--void gaim_roomlist_room_add(GaimRoomlist *list, GaimRoomlistRoom *room);
-+void gaim2_roomlist_room_add(Gaim2Roomlist *list, Gaim2RoomlistRoom *room);
-
- /**
-- * Returns a GaimRoomlist structure from the prpl, and
-+ * Returns a Gaim2Roomlist structure from the prpl, and
- * instructs the prpl to start fetching the list.
- *
-- * @param gc The GaimConnection to have get a list.
-+ * @param gc The Gaim2Connection to have get a list.
- *
-- * @return A GaimRoomlist* or @c NULL if the protocol
-+ * @return A Gaim2Roomlist* or @c NULL if the protocol
- * doesn't support that.
- */
--GaimRoomlist *gaim_roomlist_get_list(GaimConnection *gc);
-+Gaim2Roomlist *gaim2_roomlist_get_list(Gaim2Connection *gc);
-
- /**
- * Tells the prpl to stop fetching the list.
-@@ -216,7 +216,7 @@ GaimRoomlist *gaim_roomlist_get_list(Gai
- *
- * @param list The room list to cancel a get_list on.
- */
--void gaim_roomlist_cancel_get_list(GaimRoomlist *list);
-+void gaim2_roomlist_cancel_get_list(Gaim2Roomlist *list);
-
- /**
- * Tells the prpl that a category was expanded.
-@@ -229,7 +229,7 @@ void gaim_roomlist_cancel_get_list(GaimR
- * (category->type & GAIM_ROOMLIST_ROOMTYPE_CATEGORY)
- * must be true.
- */
--void gaim_roomlist_expand_category(GaimRoomlist *list, GaimRoomlistRoom *category);
-+void gaim2_roomlist_expand_category(Gaim2Roomlist *list, Gaim2RoomlistRoom *category);
-
- /*@}*/
-
-@@ -247,8 +247,8 @@ void gaim_roomlist_expand_category(GaimR
- *
- * @return A new room.
- */
--GaimRoomlistRoom *gaim_roomlist_room_new(GaimRoomlistRoomType type, const gchar *name,
-- GaimRoomlistRoom *parent);
-+Gaim2RoomlistRoom *gaim2_roomlist_room_new(Gaim2RoomlistRoomType type, const gchar *name,
-+ Gaim2RoomlistRoom *parent);
-
- /**
- * Adds a field to a room.
-@@ -257,15 +257,15 @@ GaimRoomlistRoom *gaim_roomlist_room_new
- * @param room The room.
- * @param field The field to append. Strings get g_strdup'd internally.
- */
--void gaim_roomlist_room_add_field(GaimRoomlist *list, GaimRoomlistRoom *room, gconstpointer field);
-+void gaim2_roomlist_room_add_field(Gaim2Roomlist *list, Gaim2RoomlistRoom *room, gconstpointer field);
-
- /**
-- * Join a room, given a GaimRoomlistRoom and it's associated GaimRoomlist.
-+ * Join a room, given a Gaim2RoomlistRoom and it's associated Gaim2Roomlist.
- *
- * @param list The room list the room belongs to.
- * @param room The room to join.
- */
--void gaim_roomlist_room_join(GaimRoomlist *list, GaimRoomlistRoom *room);
-+void gaim2_roomlist_room_join(Gaim2Roomlist *list, Gaim2RoomlistRoom *room);
-
- /*@}*/
-
-@@ -282,10 +282,10 @@ void gaim_roomlist_room_join(GaimRoomlis
- * @param name The internal name of the field.
- * @param hidden Hide the field.
- *
-- * @return A new GaimRoomlistField, ready to be added to a GList and passed to
-- * gaim_roomlist_set_fields().
-+ * @return A new Gaim2RoomlistField, ready to be added to a GList and passed to
-+ * gaim2_roomlist_set_fields().
- */
--GaimRoomlistField *gaim_roomlist_field_new(GaimRoomlistFieldType type,
-+Gaim2RoomlistField *gaim2_roomlist_field_new(Gaim2RoomlistFieldType type,
- const gchar *label, const gchar *name,
- gboolean hidden);
- /*@}*/
-@@ -296,19 +296,19 @@ GaimRoomlistField *gaim_roomlist_field_n
- /*@{*/
-
- /**
-- * Sets the UI operations structure to be used in all gaim room lists.
-+ * Sets the UI operations structure to be used in all gaim2 room lists.
- *
- * @param ops The UI operations structure.
- */
--void gaim_roomlist_set_ui_ops(GaimRoomlistUiOps *ops);
-+void gaim2_roomlist_set_ui_ops(Gaim2RoomlistUiOps *ops);
-
- /**
-- * Returns the gaim window UI operations structure to be used in
-+ * Returns the gaim2 window UI operations structure to be used in
- * new windows.
- *
-- * @return A filled-out GaimRoomlistUiOps structure.
-+ * @return A filled-out Gaim2RoomlistUiOps structure.
- */
--GaimRoomlistUiOps *gaim_roomlist_get_ui_ops(void);
-+Gaim2RoomlistUiOps *gaim2_roomlist_get_ui_ops(void);
-
- /*@}*/
-
-diff -prNu ./src/savedstatuses.c ./src/savedstatuses.c
---- ./src/savedstatuses.c 2006-01-05 05:32:25.000000000 +0100
-+++ ./src/savedstatuses.c 2006-01-05 15:11:07.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file savedstatus.c Saved Status API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -49,10 +49,10 @@
- * are fully backward compatible. The new status API just
- * adds the optional sub-statuses to the XML file.
- */
--struct _GaimSavedStatus
-+struct _Gaim2SavedStatus
- {
- char *title;
-- GaimStatusPrimitive type;
-+ Gaim2StatusPrimitive type;
- char *message;
-
- /** The timestamp when this saved status was created. This must be unique. */
-@@ -62,17 +62,17 @@ struct _GaimSavedStatus
-
- unsigned int usage_count;
-
-- GList *substatuses; /**< A list of GaimSavedStatusSub's. */
-+ GList *substatuses; /**< A list of Gaim2SavedStatusSub's. */
- };
-
- /*
-- * TODO: If a GaimStatusType is deleted, need to also delete any
-- * associated GaimSavedStatusSub's?
-+ * TODO: If a Gaim2StatusType is deleted, need to also delete any
-+ * associated Gaim2SavedStatusSub's?
- */
--struct _GaimSavedStatusSub
-+struct _Gaim2SavedStatusSub
- {
-- GaimAccount *account;
-- const GaimStatusType *type;
-+ Gaim2Account *account;
-+ const Gaim2StatusType *type;
- char *message;
- };
-
-@@ -87,7 +87,7 @@ static gboolean statuses_loaded = FAL
- * is used as a unique identifier.
- *
- * So the key in this hash table is the creation_time and
-- * the value is a pointer to the GaimSavedStatus.
-+ * the value is a pointer to the Gaim2SavedStatus.
- */
- static GHashTable *creation_times;
-
-@@ -98,7 +98,7 @@ static void schedule_save(void);
- *********************************************************************/
-
- static void
--free_saved_status_sub(GaimSavedStatusSub *substatus)
-+free_saved_status_sub(Gaim2SavedStatusSub *substatus)
- {
- g_return_if_fail(substatus != NULL);
-
-@@ -107,7 +107,7 @@ free_saved_status_sub(GaimSavedStatusSub
- }
-
- static void
--free_saved_status(GaimSavedStatus *status)
-+free_saved_status(Gaim2SavedStatus *status)
- {
- g_return_if_fail(status != NULL);
-
-@@ -116,7 +116,7 @@ free_saved_status(GaimSavedStatus *statu
-
- while (status->substatuses != NULL)
- {
-- GaimSavedStatusSub *substatus = status->substatuses->data;
-+ Gaim2SavedStatusSub *substatus = status->substatuses->data;
- status->substatuses = g_list_remove(status->substatuses, substatus);
- free_saved_status_sub(substatus);
- }
-@@ -129,7 +129,7 @@ free_saved_status(GaimSavedStatus *statu
- * make sure it is unique.
- */
- static void
--set_creation_time(GaimSavedStatus *status, time_t creation_time)
-+set_creation_time(Gaim2SavedStatus *status, time_t creation_time)
- {
- g_return_if_fail(status != NULL);
-
-@@ -158,8 +158,8 @@ set_creation_time(GaimSavedStatus *statu
- static gint
- saved_statuses_sort_func(gconstpointer a, gconstpointer b)
- {
-- const GaimSavedStatus *saved_status_a = a;
-- const GaimSavedStatus *saved_status_b = b;
-+ const Gaim2SavedStatus *saved_status_a = a;
-+ const Gaim2SavedStatus *saved_status_b = b;
- time_t time_a = saved_status_a->lastused +
- (MIN(saved_status_a->usage_count, 10) * 86400);
- time_t time_b = saved_status_b->lastused +
-@@ -173,7 +173,7 @@ saved_statuses_sort_func(gconstpointer a
-
- /**
- * Transient statuses are added and removed automatically by
-- * Gaim. If they're not used for a certain length of time then
-+ * Gaim2. If they're not used for a certain length of time then
- * they'll expire and be automatically removed. This function
- * does the expiration.
- */
-@@ -181,7 +181,7 @@ static void
- remove_old_transient_statuses()
- {
- GList *l, *next;
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
- int count;
- time_t creation_time;
-
-@@ -195,12 +195,12 @@ remove_old_transient_statuses()
- {
- next = l->next;
- saved_status = l->data;
-- if (gaim_savedstatus_is_transient(saved_status))
-+ if (gaim2_savedstatus_is_transient(saved_status))
- {
- if (count == MAX_TRANSIENTS)
- {
- saved_statuses = g_list_remove(saved_statuses, saved_status);
-- creation_time = gaim_savedstatus_get_creation_time(saved_status);
-+ creation_time = gaim2_savedstatus_get_creation_time(saved_status);
- g_hash_table_remove(creation_times, &creation_time);
- free_saved_status(saved_status);
- }
-@@ -218,18 +218,18 @@ remove_old_transient_statuses()
- *********************************************************************/
-
- static xmlnode *
--substatus_to_xmlnode(GaimSavedStatusSub *substatus)
-+substatus_to_xmlnode(Gaim2SavedStatusSub *substatus)
- {
- xmlnode *node, *child;
-
- node = xmlnode_new("substatus");
-
- child = xmlnode_new_child(node, "account");
-- xmlnode_set_attrib(child, "protocol", gaim_account_get_protocol_id(substatus->account));
-- xmlnode_insert_data(child, gaim_account_get_username(substatus->account), -1);
-+ xmlnode_set_attrib(child, "protocol", gaim2_account_get_protocol_id(substatus->account));
-+ xmlnode_insert_data(child, gaim2_account_get_username(substatus->account), -1);
-
- child = xmlnode_new_child(node, "state");
-- xmlnode_insert_data(child, gaim_status_type_get_id(substatus->type), -1);
-+ xmlnode_insert_data(child, gaim2_status_type_get_id(substatus->type), -1);
-
- if (substatus->message != NULL)
- {
-@@ -241,7 +241,7 @@ substatus_to_xmlnode(GaimSavedStatusSub
- }
-
- static xmlnode *
--status_to_xmlnode(GaimSavedStatus *status)
-+status_to_xmlnode(Gaim2SavedStatus *status)
- {
- xmlnode *node, *child;
- char buf[21];
-@@ -255,7 +255,7 @@ status_to_xmlnode(GaimSavedStatus *statu
- else
- {
- /*
-- * Gaim 1.5.0 and earlier require a name to be set, so we
-+ * Gaim2 1.5.0 and earlier require a name to be set, so we
- * do this little hack to maintain backward compatability
- * in the status.xml file. Eventually this should be removed
- * and we should determine if a status is transient by
-@@ -276,7 +276,7 @@ status_to_xmlnode(GaimSavedStatus *statu
- xmlnode_set_attrib(node, "usage_count", buf);
-
- child = xmlnode_new_child(node, "state");
-- xmlnode_insert_data(child, gaim_primitive_get_id_from_type(status->type), -1);
-+ xmlnode_insert_data(child, gaim2_primitive_get_id_from_type(status->type), -1);
-
- if (status->message != NULL)
- {
-@@ -319,14 +319,14 @@ sync_statuses(void)
-
- if (!statuses_loaded)
- {
-- gaim_debug_error("status", "Attempted to save statuses before they "
-+ gaim2_debug_error("status", "Attempted to save statuses before they "
- "were read!\n");
- return;
- }
-
- node = statuses_to_xmlnode();
- data = xmlnode_to_formatted_str(node, NULL);
-- gaim_util_write_data_to_file("status.xml", data, -1);
-+ gaim2_util_write_data_to_file("status.xml", data, -1);
- g_free(data);
- xmlnode_free(node);
- }
-@@ -343,7 +343,7 @@ static void
- schedule_save(void)
- {
- if (save_timer == 0)
-- save_timer = gaim_timeout_add(5000, save_cb, NULL);
-+ save_timer = gaim2_timeout_add(5000, save_cb, NULL);
- }
-
-
-@@ -351,14 +351,14 @@ schedule_save(void)
- * Reading from disk *
- *********************************************************************/
-
--static GaimSavedStatusSub *
-+static Gaim2SavedStatusSub *
- parse_substatus(xmlnode *substatus)
- {
-- GaimSavedStatusSub *ret;
-+ Gaim2SavedStatusSub *ret;
- xmlnode *node;
- char *data;
-
-- ret = g_new0(GaimSavedStatusSub, 1);
-+ ret = g_new0(Gaim2SavedStatusSub, 1);
-
- /* Read the account */
- node = xmlnode_get_child(substatus, "account");
-@@ -369,7 +369,7 @@ parse_substatus(xmlnode *substatus)
- acct_name = xmlnode_get_data(node);
- protocol = xmlnode_get_attrib(node, "protocol");
- if ((acct_name != NULL) && (protocol != NULL))
-- ret->account = gaim_accounts_find(acct_name, protocol);
-+ ret->account = gaim2_accounts_find(acct_name, protocol);
- g_free(acct_name);
- }
-
-@@ -383,7 +383,7 @@ parse_substatus(xmlnode *substatus)
- node = xmlnode_get_child(substatus, "state");
- if ((node != NULL) && ((data = xmlnode_get_data(node)) != NULL))
- {
-- ret->type = gaim_status_type_find_with_id(
-+ ret->type = gaim2_status_type_find_with_id(
- ret->account->status_types, data);
- g_free(data);
- }
-@@ -422,16 +422,16 @@ parse_substatus(xmlnode *substatus)
- *
- * I know. Moving, huh?
- */
--static GaimSavedStatus *
-+static Gaim2SavedStatus *
- parse_status(xmlnode *status)
- {
-- GaimSavedStatus *ret;
-+ Gaim2SavedStatus *ret;
- xmlnode *node;
- const char *attrib;
- char *data;
- int i;
-
-- ret = g_new0(GaimSavedStatus, 1);
-+ ret = g_new0(Gaim2SavedStatus, 1);
-
- attrib = xmlnode_get_attrib(status, "transient");
- if ((attrib == NULL) || (strcmp(attrib, "true")))
-@@ -445,7 +445,7 @@ parse_status(xmlnode *status)
- {
- /* Ensure the title is unique */
- i = 2;
-- while (gaim_savedstatus_find(ret->title) != NULL)
-+ while (gaim2_savedstatus_find(ret->title) != NULL)
- {
- g_free(ret->title);
- ret->title = g_strdup_printf("%s %d", attrib, i);
-@@ -469,7 +469,7 @@ parse_status(xmlnode *status)
- node = xmlnode_get_child(status, "state");
- if ((node != NULL) && ((data = xmlnode_get_data(node)) != NULL))
- {
-- ret->type = gaim_primitive_get_type_from_id(data);
-+ ret->type = gaim2_primitive_get_type_from_id(data);
- g_free(data);
- }
-
-@@ -484,7 +484,7 @@ parse_status(xmlnode *status)
- for (node = xmlnode_get_child(status, "substatus"); node != NULL;
- node = xmlnode_get_next_twin(node))
- {
-- GaimSavedStatusSub *new;
-+ Gaim2SavedStatusSub *new;
- new = parse_substatus(node);
- if (new != NULL)
- ret->substatuses = g_list_prepend(ret->substatuses, new);
-@@ -494,7 +494,7 @@ parse_status(xmlnode *status)
- }
-
- /**
-- * Read the saved statuses from a file in the Gaim user dir.
-+ * Read the saved statuses from a file in the Gaim2 user dir.
- *
- * @return TRUE on success, FALSE on failure (if the file can not
- * be opened, or if it contains invalid XML).
-@@ -506,7 +506,7 @@ load_statuses(void)
-
- statuses_loaded = TRUE;
-
-- statuses = gaim_util_read_xml_from_file("status.xml", _("saved statuses"));
-+ statuses = gaim2_util_read_xml_from_file("status.xml", _("saved statuses"));
-
- if (statuses == NULL)
- return;
-@@ -514,7 +514,7 @@ load_statuses(void)
- for (status = xmlnode_get_child(statuses, "status"); status != NULL;
- status = xmlnode_get_next_twin(status))
- {
-- GaimSavedStatus *new;
-+ Gaim2SavedStatus *new;
- new = parse_status(status);
- saved_statuses = g_list_prepend(saved_statuses, new);
- }
-@@ -527,16 +527,16 @@ load_statuses(void)
- /**************************************************************************
- * Saved status API
- **************************************************************************/
--GaimSavedStatus *
--gaim_savedstatus_new(const char *title, GaimStatusPrimitive type)
-+Gaim2SavedStatus *
-+gaim2_savedstatus_new(const char *title, Gaim2StatusPrimitive type)
- {
-- GaimSavedStatus *status;
-+ Gaim2SavedStatus *status;
-
- /* Make sure we don't already have a saved status with this title. */
- if (title != NULL)
-- g_return_val_if_fail(gaim_savedstatus_find(title) == NULL, NULL);
-+ g_return_val_if_fail(gaim2_savedstatus_find(title) == NULL, NULL);
-
-- status = g_new0(GaimSavedStatus, 1);
-+ status = g_new0(Gaim2SavedStatus, 1);
- status->title = g_strdup(title);
- status->type = type;
- set_creation_time(status, time(NULL));
-@@ -549,12 +549,12 @@ gaim_savedstatus_new(const char *title,
- }
-
- void
--gaim_savedstatus_set_title(GaimSavedStatus *status, const char *title)
-+gaim2_savedstatus_set_title(Gaim2SavedStatus *status, const char *title)
- {
- g_return_if_fail(status != NULL);
-
- /* Make sure we don't already have a saved status with this title. */
-- g_return_if_fail(gaim_savedstatus_find(title) == NULL);
-+ g_return_if_fail(gaim2_savedstatus_find(title) == NULL);
-
- g_free(status->title);
- status->title = g_strdup(title);
-@@ -563,7 +563,7 @@ gaim_savedstatus_set_title(GaimSavedStat
- }
-
- void
--gaim_savedstatus_set_type(GaimSavedStatus *status, GaimStatusPrimitive type)
-+gaim2_savedstatus_set_type(Gaim2SavedStatus *status, Gaim2StatusPrimitive type)
- {
- g_return_if_fail(status != NULL);
-
-@@ -573,7 +573,7 @@ gaim_savedstatus_set_type(GaimSavedStatu
- }
-
- void
--gaim_savedstatus_set_message(GaimSavedStatus *status, const char *message)
-+gaim2_savedstatus_set_message(Gaim2SavedStatus *status, const char *message)
- {
- g_return_if_fail(status != NULL);
-
-@@ -584,23 +584,23 @@ gaim_savedstatus_set_message(GaimSavedSt
- }
-
- void
--gaim_savedstatus_set_substatus(GaimSavedStatus *saved_status,
-- const GaimAccount *account,
-- const GaimStatusType *type,
-+gaim2_savedstatus_set_substatus(Gaim2SavedStatus *saved_status,
-+ const Gaim2Account *account,
-+ const Gaim2StatusType *type,
- const char *message)
- {
-- GaimSavedStatusSub *substatus;
-+ Gaim2SavedStatusSub *substatus;
-
- g_return_if_fail(saved_status != NULL);
- g_return_if_fail(account != NULL);
- g_return_if_fail(type != NULL);
-
- /* Find an existing substatus or create a new one */
-- substatus = gaim_savedstatus_get_substatus(saved_status, account);
-+ substatus = gaim2_savedstatus_get_substatus(saved_status, account);
- if (substatus == NULL)
- {
-- substatus = g_new0(GaimSavedStatusSub, 1);
-- substatus->account = (GaimAccount *)account;
-+ substatus = g_new0(Gaim2SavedStatusSub, 1);
-+ substatus->account = (Gaim2Account *)account;
- saved_status->substatuses = g_list_prepend(saved_status->substatuses, substatus);
- }
-
-@@ -612,11 +612,11 @@ gaim_savedstatus_set_substatus(GaimSaved
- }
-
- void
--gaim_savedstatus_unset_substatus(GaimSavedStatus *saved_status,
-- const GaimAccount *account)
-+gaim2_savedstatus_unset_substatus(Gaim2SavedStatus *saved_status,
-+ const Gaim2Account *account)
- {
- GList *iter;
-- GaimSavedStatusSub *substatus;
-+ Gaim2SavedStatusSub *substatus;
-
- g_return_if_fail(saved_status != NULL);
- g_return_if_fail(account != NULL);
-@@ -635,18 +635,18 @@ gaim_savedstatus_unset_substatus(GaimSav
- }
-
- gboolean
--gaim_savedstatus_delete(const char *title)
-+gaim2_savedstatus_delete(const char *title)
- {
-- GaimSavedStatus *status;
-+ Gaim2SavedStatus *status;
- time_t creation_time, current, idleaway;
-
-- status = gaim_savedstatus_find(title);
-+ status = gaim2_savedstatus_find(title);
-
- if (status == NULL)
- return FALSE;
-
- saved_statuses = g_list_remove(saved_statuses, status);
-- creation_time = gaim_savedstatus_get_creation_time(status);
-+ creation_time = gaim2_savedstatus_get_creation_time(status);
- g_hash_table_remove(creation_times, &creation_time);
- free_saved_status(status);
-
-@@ -656,25 +656,25 @@ gaim_savedstatus_delete(const char *titl
- * If we just deleted our current status or our idleaway status,
- * then set the appropriate pref back to 0.
- */
-- current = gaim_prefs_get_int("/core/savedstatus/current");
-+ current = gaim2_prefs_get_int("/core/savedstatus/current");
- if (current == creation_time)
-- gaim_prefs_set_int("/core/savedstatus/current", 0);
-+ gaim2_prefs_set_int("/core/savedstatus/current", 0);
-
-- idleaway = gaim_prefs_get_int("/core/savedstatus/idleaway");
-+ idleaway = gaim2_prefs_get_int("/core/savedstatus/idleaway");
- if (idleaway == creation_time)
-- gaim_prefs_set_int("/core/savedstatus/idleaway", 0);
-+ gaim2_prefs_set_int("/core/savedstatus/idleaway", 0);
-
- return TRUE;
- }
-
- const GList *
--gaim_savedstatuses_get_all(void)
-+gaim2_savedstatuses_get_all(void)
- {
- return saved_statuses;
- }
-
- GList *
--gaim_savedstatuses_get_popular(unsigned int how_many)
-+gaim2_savedstatuses_get_popular(unsigned int how_many)
- {
- GList *truncated = NULL;
- GList *cur;
-@@ -690,13 +690,13 @@ gaim_savedstatuses_get_popular(unsigned
- return truncated;
- }
-
--GaimSavedStatus *
--gaim_savedstatus_get_current()
-+Gaim2SavedStatus *
-+gaim2_savedstatus_get_current()
- {
- int creation_time;
-- GaimSavedStatus *saved_status = NULL;
-+ Gaim2SavedStatus *saved_status = NULL;
-
-- creation_time = gaim_prefs_get_int("/core/savedstatus/current");
-+ creation_time = gaim2_prefs_get_int("/core/savedstatus/current");
-
- if (creation_time != 0)
- saved_status = g_hash_table_lookup(creation_times, &creation_time);
-@@ -705,33 +705,33 @@ gaim_savedstatus_get_current()
- {
- /*
- * We don't have a current saved statuses! This is either a new
-- * Gaim user or someone upgrading from Gaim 1.5.0 or older, or
-+ * Gaim2 user or someone upgrading from Gaim2 1.5.0 or older, or
- * possibly someone who deleted the status they were currently
- * using? In any case, add a default status.
- */
-- saved_status = gaim_savedstatus_new(NULL, GAIM_STATUS_AVAILABLE);
-+ saved_status = gaim2_savedstatus_new(NULL, GAIM_STATUS_AVAILABLE);
- }
-
- return saved_status;
- }
-
--GaimSavedStatus *
--gaim_savedstatus_get_idleaway()
-+Gaim2SavedStatus *
-+gaim2_savedstatus_get_idleaway()
- {
- int creation_time;
-- GaimSavedStatus *saved_status;
-+ Gaim2SavedStatus *saved_status;
-
-- creation_time = gaim_prefs_get_int("/core/savedstatus/idleaway");
-+ creation_time = gaim2_prefs_get_int("/core/savedstatus/idleaway");
-
- if (creation_time == 0)
- {
- /*
- * We don't have a current saved statuses! This is either a new
-- * Gaim user or someone upgrading from Gaim 1.5.0 or older. Add
-+ * Gaim2 user or someone upgrading from Gaim2 1.5.0 or older. Add
- * a default status.
- */
-- saved_status = gaim_savedstatus_new(NULL, GAIM_STATUS_AWAY);
-- gaim_savedstatus_set_message(saved_status, _("I'm not here right now"));
-+ saved_status = gaim2_savedstatus_new(NULL, GAIM_STATUS_AWAY);
-+ gaim2_savedstatus_set_message(saved_status, _("I'm not here right now"));
- }
- else
- {
-@@ -741,17 +741,17 @@ gaim_savedstatus_get_idleaway()
- return saved_status;
- }
-
--GaimSavedStatus *
--gaim_savedstatus_find(const char *title)
-+Gaim2SavedStatus *
-+gaim2_savedstatus_find(const char *title)
- {
- GList *iter;
-- GaimSavedStatus *status;
-+ Gaim2SavedStatus *status;
-
- g_return_val_if_fail(title != NULL, NULL);
-
- for (iter = saved_statuses; iter != NULL; iter = iter->next)
- {
-- status = (GaimSavedStatus *)iter->data;
-+ status = (Gaim2SavedStatus *)iter->data;
- if ((status->title != NULL) && !strcmp(status->title, title))
- return status;
- }
-@@ -759,15 +759,15 @@ gaim_savedstatus_find(const char *title)
- return NULL;
- }
-
--GaimSavedStatus *
--gaim_savedstatus_find_by_creation_time(time_t creation_time)
-+Gaim2SavedStatus *
-+gaim2_savedstatus_find_by_creation_time(time_t creation_time)
- {
- GList *iter;
-- GaimSavedStatus *status;
-+ Gaim2SavedStatus *status;
-
- for (iter = saved_statuses; iter != NULL; iter = iter->next)
- {
-- status = (GaimSavedStatus *)iter->data;
-+ status = (Gaim2SavedStatus *)iter->data;
- if (status->creation_time == creation_time)
- return status;
- }
-@@ -776,7 +776,7 @@ gaim_savedstatus_find_by_creation_time(t
- }
-
- gboolean
--gaim_savedstatus_is_transient(const GaimSavedStatus *saved_status)
-+gaim2_savedstatus_is_transient(const Gaim2SavedStatus *saved_status)
- {
- g_return_val_if_fail(saved_status != NULL, TRUE);
-
-@@ -784,7 +784,7 @@ gaim_savedstatus_is_transient(const Gaim
- }
-
- const char *
--gaim_savedstatus_get_title(const GaimSavedStatus *saved_status)
-+gaim2_savedstatus_get_title(const Gaim2SavedStatus *saved_status)
- {
- const char *message;
-
-@@ -795,20 +795,20 @@ gaim_savedstatus_get_title(const GaimSav
- return saved_status->title;
-
- /* Otherwise, this is a transient status and we make up a title on the fly */
-- message = gaim_savedstatus_get_message(saved_status);
-+ message = gaim2_savedstatus_get_message(saved_status);
-
- if (message == NULL)
- {
-- GaimStatusPrimitive primitive;
-- primitive = gaim_savedstatus_get_type(saved_status);
-- return gaim_primitive_get_id_from_type(primitive);
-+ Gaim2StatusPrimitive primitive;
-+ primitive = gaim2_savedstatus_get_type(saved_status);
-+ return gaim2_primitive_get_id_from_type(primitive);
- }
- else
- {
- char *stripped;
- static char buf[64];
-- stripped = gaim_markup_strip_html(message);
-- gaim_util_chrreplace(stripped, '\n', ' ');
-+ stripped = gaim2_markup_strip_html(message);
-+ gaim2_util_chrreplace(stripped, '\n', ' ');
- strncpy(buf, stripped, sizeof(buf));
- buf[sizeof(buf) - 1] = '\0';
- if ((strlen(stripped) + 1) > sizeof(buf))
-@@ -822,8 +822,8 @@ gaim_savedstatus_get_title(const GaimSav
- }
- }
-
--GaimStatusPrimitive
--gaim_savedstatus_get_type(const GaimSavedStatus *saved_status)
-+Gaim2StatusPrimitive
-+gaim2_savedstatus_get_type(const Gaim2SavedStatus *saved_status)
- {
- g_return_val_if_fail(saved_status != NULL, GAIM_STATUS_OFFLINE);
-
-@@ -831,7 +831,7 @@ gaim_savedstatus_get_type(const GaimSave
- }
-
- const char *
--gaim_savedstatus_get_message(const GaimSavedStatus *saved_status)
-+gaim2_savedstatus_get_message(const Gaim2SavedStatus *saved_status)
- {
- g_return_val_if_fail(saved_status != NULL, NULL);
-
-@@ -839,7 +839,7 @@ gaim_savedstatus_get_message(const GaimS
- }
-
- time_t
--gaim_savedstatus_get_creation_time(const GaimSavedStatus *saved_status)
-+gaim2_savedstatus_get_creation_time(const Gaim2SavedStatus *saved_status)
- {
- g_return_val_if_fail(saved_status != NULL, 0);
-
-@@ -847,19 +847,19 @@ gaim_savedstatus_get_creation_time(const
- }
-
- gboolean
--gaim_savedstatus_has_substatuses(const GaimSavedStatus *saved_status)
-+gaim2_savedstatus_has_substatuses(const Gaim2SavedStatus *saved_status)
- {
- g_return_val_if_fail(saved_status != NULL, FALSE);
-
- return (saved_status->substatuses != NULL);
- }
-
--GaimSavedStatusSub *
--gaim_savedstatus_get_substatus(const GaimSavedStatus *saved_status,
-- const GaimAccount *account)
-+Gaim2SavedStatusSub *
-+gaim2_savedstatus_get_substatus(const Gaim2SavedStatus *saved_status,
-+ const Gaim2Account *account)
- {
- GList *iter;
-- GaimSavedStatusSub *substatus;
-+ Gaim2SavedStatusSub *substatus;
-
- g_return_val_if_fail(saved_status != NULL, NULL);
- g_return_val_if_fail(account != NULL, NULL);
-@@ -874,8 +874,8 @@ gaim_savedstatus_get_substatus(const Gai
- return NULL;
- }
-
--const GaimStatusType *
--gaim_savedstatus_substatus_get_type(const GaimSavedStatusSub *substatus)
-+const Gaim2StatusType *
-+gaim2_savedstatus_substatus_get_type(const Gaim2SavedStatusSub *substatus)
- {
- g_return_val_if_fail(substatus != NULL, NULL);
-
-@@ -883,7 +883,7 @@ gaim_savedstatus_substatus_get_type(cons
- }
-
- const char *
--gaim_savedstatus_substatus_get_message(const GaimSavedStatusSub *substatus)
-+gaim2_savedstatus_substatus_get_message(const Gaim2SavedStatusSub *substatus)
- {
- g_return_val_if_fail(substatus != NULL, NULL);
-
-@@ -891,7 +891,7 @@ gaim_savedstatus_substatus_get_message(c
- }
-
- void
--gaim_savedstatus_activate(GaimSavedStatus *saved_status)
-+gaim2_savedstatus_activate(Gaim2SavedStatus *saved_status)
- {
- GList *accounts, *node;
-
-@@ -903,33 +903,33 @@ gaim_savedstatus_activate(GaimSavedStatu
- saved_statuses = g_list_remove(saved_statuses, saved_status);
- saved_statuses = g_list_insert_sorted(saved_statuses, saved_status, saved_statuses_sort_func);
-
-- accounts = gaim_accounts_get_all_active();
-+ accounts = gaim2_accounts_get_all_active();
- for (node = accounts; node != NULL; node = node->next)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- account = node->data;
-- gaim_savedstatus_activate_for_account(saved_status, account);
-+ gaim2_savedstatus_activate_for_account(saved_status, account);
- }
-
- g_list_free(accounts);
-
-- gaim_prefs_set_int("/core/savedstatus/current",
-- gaim_savedstatus_get_creation_time(saved_status));
-+ gaim2_prefs_set_int("/core/savedstatus/current",
-+ gaim2_savedstatus_get_creation_time(saved_status));
- }
-
- void
--gaim_savedstatus_activate_for_account(const GaimSavedStatus *saved_status,
-- GaimAccount *account)
-+gaim2_savedstatus_activate_for_account(const Gaim2SavedStatus *saved_status,
-+ Gaim2Account *account)
- {
-- const GaimStatusType *status_type;
-- const GaimSavedStatusSub *substatus;
-+ const Gaim2StatusType *status_type;
-+ const Gaim2SavedStatusSub *substatus;
- const char *message = NULL;
-
- g_return_if_fail(saved_status != NULL);
- g_return_if_fail(account != NULL);
-
-- substatus = gaim_savedstatus_get_substatus(saved_status, account);
-+ substatus = gaim2_savedstatus_get_substatus(saved_status, account);
- if (substatus != NULL)
- {
- status_type = substatus->type;
-@@ -937,27 +937,27 @@ gaim_savedstatus_activate_for_account(co
- }
- else
- {
-- status_type = gaim_account_get_status_type_with_primitive(account, saved_status->type);
-+ status_type = gaim2_account_get_status_type_with_primitive(account, saved_status->type);
- if (status_type == NULL)
- return;
- message = saved_status->message;
- }
-
- if ((message != NULL) &&
-- (gaim_status_type_get_attr(status_type, "message")))
-+ (gaim2_status_type_get_attr(status_type, "message")))
- {
-- gaim_account_set_status(account, gaim_status_type_get_id(status_type),
-+ gaim2_account_set_status(account, gaim2_status_type_get_id(status_type),
- TRUE, "message", message, NULL);
- }
- else
- {
-- gaim_account_set_status(account, gaim_status_type_get_id(status_type),
-+ gaim2_account_set_status(account, gaim2_status_type_get_id(status_type),
- TRUE, NULL);
- }
- }
-
- void *
--gaim_savedstatuses_get_handle(void)
-+gaim2_savedstatuses_get_handle(void)
- {
- static int handle;
-
-@@ -965,38 +965,38 @@ gaim_savedstatuses_get_handle(void)
- }
-
- void
--gaim_savedstatuses_init(void)
-+gaim2_savedstatuses_init(void)
- {
- creation_times = g_hash_table_new(g_int_hash, g_int_equal);
-
- /*
- * Using 0 as the creation_time is a special case.
-- * If someone calls gaim_savedstatus_get_current() or
-- * gaim_savedstatus_get_idleaway() and either of those functions
-+ * If someone calls gaim2_savedstatus_get_current() or
-+ * gaim2_savedstatus_get_idleaway() and either of those functions
- * sees a creation_time of 0, then it will create a default
- * saved status and return that to the user.
- */
-- gaim_prefs_add_none("/core/savedstatus");
-- gaim_prefs_add_int("/core/savedstatus/current", 0);
-- gaim_prefs_add_int("/core/savedstatus/idleaway", 0);
-+ gaim2_prefs_add_none("/core/savedstatus");
-+ gaim2_prefs_add_int("/core/savedstatus/current", 0);
-+ gaim2_prefs_add_int("/core/savedstatus/idleaway", 0);
-
- load_statuses();
- }
-
- void
--gaim_savedstatuses_uninit(void)
-+gaim2_savedstatuses_uninit(void)
- {
- remove_old_transient_statuses();
-
- if (save_timer != 0)
- {
-- gaim_timeout_remove(save_timer);
-+ gaim2_timeout_remove(save_timer);
- save_timer = 0;
- sync_statuses();
- }
-
- while (saved_statuses != NULL) {
-- GaimSavedStatus *saved_status = saved_statuses->data;
-+ Gaim2SavedStatus *saved_status = saved_statuses->data;
- saved_statuses = g_list_remove(saved_statuses, saved_status);
- free_saved_status(saved_status);
- }
-diff -prNu ./src/savedstatuses.h ./src/savedstatuses.h
---- ./src/savedstatuses.h 2006-01-03 06:23:01.000000000 +0100
-+++ ./src/savedstatuses.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file savedstatuses.h Saved Status API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,14 +26,14 @@
- #define _GAIM_SAVEDSTATUSES_H_
-
- /**
-- * Saved statuses don't really interact much with the rest of Gaim. It
-+ * Saved statuses don't really interact much with the rest of Gaim2. It
- * could really be a plugin. It's just a list of away states. When
-- * a user chooses one of the saved states, their Gaim accounts are set
-+ * a user chooses one of the saved states, their Gaim2 accounts are set
- * to the settings of that state.
- *
- * In the savedstatus API, there is the concept of a 'transient'
- * saved status. A transient saved status is one that is not
-- * permanent. Gaim will removed it automatically if it isn't
-+ * permanent. Gaim2 will removed it automatically if it isn't
- * used for a period of time. Transient saved statuses don't
- * have titles and they don't show up in the list of saved
- * statuses. In fact, if a saved status does not have a title
-@@ -48,13 +48,13 @@
- */
-
- /*
-- * TODO: Hmm. We should probably just be saving GaimPresences. That's
-+ * TODO: Hmm. We should probably just be saving Gaim2Presences. That's
- * something we should look into once the status box gets fleshed
- * out more.
- */
-
--typedef struct _GaimSavedStatus GaimSavedStatus;
--typedef struct _GaimSavedStatusSub GaimSavedStatusSub;
-+typedef struct _Gaim2SavedStatus Gaim2SavedStatus;
-+typedef struct _Gaim2SavedStatusSub Gaim2SavedStatusSub;
-
- #include "status.h"
-
-@@ -75,8 +75,8 @@ typedef struct _GaimSavedStatusSub Gaim
- * @return The newly created saved status, or NULL if the title you
- * used was already taken.
- */
--GaimSavedStatus *gaim_savedstatus_new(const char *title,
-- GaimStatusPrimitive type);
-+Gaim2SavedStatus *gaim2_savedstatus_new(const char *title,
-+ Gaim2StatusPrimitive type);
-
- /**
- * Set the title for the given saved status.
-@@ -84,7 +84,7 @@ GaimSavedStatus *gaim_savedstatus_new(co
- * @param status The saved status.
- * @param title The title of the saved status.
- */
--void gaim_savedstatus_set_title(GaimSavedStatus *status,
-+void gaim2_savedstatus_set_title(Gaim2SavedStatus *status,
- const char *title);
-
- /**
-@@ -93,8 +93,8 @@ void gaim_savedstatus_set_title(GaimSave
- * @param status The saved status.
- * @param type The type of saved status.
- */
--void gaim_savedstatus_set_type(GaimSavedStatus *status,
-- GaimStatusPrimitive type);
-+void gaim2_savedstatus_set_type(Gaim2SavedStatus *status,
-+ Gaim2StatusPrimitive type);
-
- /**
- * Set the message for the given saved status.
-@@ -103,7 +103,7 @@ void gaim_savedstatus_set_type(GaimSaved
- * @param message The message, or NULL if you want to unset the
- * message for this status.
- */
--void gaim_savedstatus_set_message(GaimSavedStatus *status,
-+void gaim2_savedstatus_set_message(Gaim2SavedStatus *status,
- const char *message);
-
- /**
-@@ -115,22 +115,22 @@ void gaim_savedstatus_set_message(GaimSa
- * status.
- * @param message The message for the account in the substatus.
- */
--void gaim_savedstatus_set_substatus(GaimSavedStatus *status,
-- const GaimAccount *account,
-- const GaimStatusType *type,
-+void gaim2_savedstatus_set_substatus(Gaim2SavedStatus *status,
-+ const Gaim2Account *account,
-+ const Gaim2StatusType *type,
- const char *message);
-
- /**
- * Unset a substatus for an account in a saved status. This clears
-- * the previosly set substatus for the GaimSavedStatus. If this
-+ * the previosly set substatus for the Gaim2SavedStatus. If this
- * saved status is activated then this account will use the default
- * status type and message.
- *
- * @param saved_status The saved status.
- * @param account The account.
- */
--void gaim_savedstatus_unset_substatus(GaimSavedStatus *saved_status,
-- const GaimAccount *account);
-+void gaim2_savedstatus_unset_substatus(Gaim2SavedStatus *saved_status,
-+ const Gaim2Account *account);
-
- /**
- * Delete a saved status. This removes the saved status from the list
-@@ -142,14 +142,14 @@ void gaim_savedstatus_unset_substatus(Ga
- * status could not be deleted because no saved status exists
- * with the given title.
- */
--gboolean gaim_savedstatus_delete(const char *title);
-+gboolean gaim2_savedstatus_delete(const char *title);
-
- /**
- * Returns all saved statuses.
- *
- * @return A list of saved statuses.
- */
--const GList *gaim_savedstatuses_get_all(void);
-+const GList *gaim2_savedstatuses_get_all(void);
-
- /**
- * Returns the n most popular saved statuses. "Popularity" is
-@@ -160,26 +160,26 @@ const GList *gaim_savedstatuses_get_all(
- * to return, or '0' to get all saved
- * statuses sorted by popularity.
- * @return A linked list containing at most how_many
-- * GaimSavedStatuses. This list should be
-+ * Gaim2SavedStatuses. This list should be
- * g_list_free'd by the caller (but the
-- * GaimSavedStatuses must not be free'd).
-+ * Gaim2SavedStatuses must not be free'd).
- */
--GList *gaim_savedstatuses_get_popular(unsigned int how_many);
-+GList *gaim2_savedstatuses_get_popular(unsigned int how_many);
-
- /**
- * Returns the currently selected saved status.
- *
-- * @return A pointer to the in-use GaimSavedStatus.
-+ * @return A pointer to the in-use Gaim2SavedStatus.
- */
--GaimSavedStatus *gaim_savedstatus_get_current(void);
-+Gaim2SavedStatus *gaim2_savedstatus_get_current(void);
-
- /**
- * Returns the saved status that gets used when your
- * accounts become idle-away.
- *
-- * @return A pointer to the idle-away GaimSavedStatus.
-+ * @return A pointer to the idle-away Gaim2SavedStatus.
- */
--GaimSavedStatus *gaim_savedstatus_get_idleaway(void);
-+Gaim2SavedStatus *gaim2_savedstatus_get_idleaway(void);
-
- /**
- * Finds a saved status with the specified title.
-@@ -188,7 +188,7 @@ GaimSavedStatus *gaim_savedstatus_get_id
- *
- * @return The saved status if found, or NULL.
- */
--GaimSavedStatus *gaim_savedstatus_find(const char *title);
-+Gaim2SavedStatus *gaim2_savedstatus_find(const char *title);
-
- /**
- * Finds a saved status with the specified creation time.
-@@ -198,7 +198,7 @@ GaimSavedStatus *gaim_savedstatus_find(c
- *
- * @return The saved status if found, or NULL.
- */
--GaimSavedStatus *gaim_savedstatus_find_by_creation_time(time_t creation_time);
-+Gaim2SavedStatus *gaim2_savedstatus_find_by_creation_time(time_t creation_time);
-
- /**
- * Determines if a given saved status is "transient."
-@@ -211,13 +211,13 @@ GaimSavedStatus *gaim_savedstatus_find_b
- * created by the status box when the user sets himself
- * to one of the generic primitive statuses. The reason
- * we need to save this status information is so we can
-- * restore it when Gaim restarts.
-+ * restore it when Gaim2 restarts.
- *
- * @param saved_status The saved status.
- *
- * @return TRUE if the saved status is transient.
- */
--gboolean gaim_savedstatus_is_transient(const GaimSavedStatus *saved_status);
-+gboolean gaim2_savedstatus_is_transient(const Gaim2SavedStatus *saved_status);
-
- /**
- * Return the name of a given saved status.
-@@ -229,7 +229,7 @@ gboolean gaim_savedstatus_is_transient(c
- * you need a reference to the title for prolonged use then
- * you should make a copy of it.
- */
--const char *gaim_savedstatus_get_title(const GaimSavedStatus *saved_status);
-+const char *gaim2_savedstatus_get_title(const Gaim2SavedStatus *saved_status);
-
- /**
- * Return the type of a given saved status.
-@@ -238,7 +238,7 @@ const char *gaim_savedstatus_get_title(c
- *
- * @return The name.
- */
--GaimStatusPrimitive gaim_savedstatus_get_type(const GaimSavedStatus *saved_status);
-+Gaim2StatusPrimitive gaim2_savedstatus_get_type(const Gaim2SavedStatus *saved_status);
-
- /**
- * Return the default message of a given saved status.
-@@ -247,13 +247,13 @@ GaimStatusPrimitive gaim_savedstatus_get
- *
- * @return The name.
- */
--const char *gaim_savedstatus_get_message(const GaimSavedStatus *saved_status);
-+const char *gaim2_savedstatus_get_message(const Gaim2SavedStatus *saved_status);
-
- /**
- * Return the time in seconds-since-the-epoch when this
- * saved status was created. Note: For any status created
-- * by Gaim 1.5.0 or older this value will be invalid and
-- * very small (close to 0). This is because Gaim 1.5.0
-+ * by Gaim2 1.5.0 or older this value will be invalid and
-+ * very small (close to 0). This is because Gaim2 1.5.0
- * and older did not record the timestamp when the status
- * was created.
- *
-@@ -264,7 +264,7 @@ const char *gaim_savedstatus_get_message
- *
- * @return The timestamp when this saved status was created.
- */
--time_t gaim_savedstatus_get_creation_time(const GaimSavedStatus *saved_status);
-+time_t gaim2_savedstatus_get_creation_time(const Gaim2SavedStatus *saved_status);
-
- /**
- * Determine if a given saved status has "substatuses,"
-@@ -276,7 +276,7 @@ time_t gaim_savedstatus_get_creation_tim
- * @return TRUE if the saved_status has substatuses.
- * FALSE otherwise.
- */
--gboolean gaim_savedstatus_has_substatuses(const GaimSavedStatus *saved_status);
-+gboolean gaim2_savedstatus_has_substatuses(const Gaim2SavedStatus *saved_status);
-
- /**
- * Get the substatus for an account in a saved status.
-@@ -284,13 +284,13 @@ gboolean gaim_savedstatus_has_substatuse
- * @param saved_status The saved status.
- * @param account The account.
- *
-- * @return The GaimSavedStatusSub for the account, or NULL if
-+ * @return The Gaim2SavedStatusSub for the account, or NULL if
- * the given account does not have a substatus that
-- * differs from the default status of this GaimSavedStatus.
-+ * differs from the default status of this Gaim2SavedStatus.
- */
--GaimSavedStatusSub *gaim_savedstatus_get_substatus(
-- const GaimSavedStatus *saved_status,
-- const GaimAccount *account);
-+Gaim2SavedStatusSub *gaim2_savedstatus_get_substatus(
-+ const Gaim2SavedStatus *saved_status,
-+ const Gaim2Account *account);
-
- /**
- * Get the status type of a given substatus.
-@@ -299,7 +299,7 @@ GaimSavedStatusSub *gaim_savedstatus_get
- *
- * @return The status type.
- */
--const GaimStatusType *gaim_savedstatus_substatus_get_type(const GaimSavedStatusSub *substatus);
-+const Gaim2StatusType *gaim2_savedstatus_substatus_get_type(const Gaim2SavedStatusSub *substatus);
-
- /**
- * Get the message of a given substatus.
-@@ -309,16 +309,16 @@ const GaimStatusType *gaim_savedstatus_s
- * @return The message of the substatus, or NULL if this substatus does
- * not have a message.
- */
--const char *gaim_savedstatus_substatus_get_message(const GaimSavedStatusSub *substatus);
-+const char *gaim2_savedstatus_substatus_get_message(const Gaim2SavedStatusSub *substatus);
-
- /**
- * Sets the statuses for all your accounts to those specified
- * by the given saved_status. This function calls
-- * gaim_savedstatus_activate_for_account() for all your accounts.
-+ * gaim2_savedstatus_activate_for_account() for all your accounts.
- *
- * @param saved_status The status you want to set your accounts to.
- */
--void gaim_savedstatus_activate(GaimSavedStatus *saved_status);
-+void gaim2_savedstatus_activate(Gaim2SavedStatus *saved_status);
-
- /**
- * Sets the statuses for a given account to those specified
-@@ -327,24 +327,24 @@ void gaim_savedstatus_activate(GaimSaved
- * @param saved_status The status you want to set your accounts to.
- * @param account The account whose statuses you want to change.
- */
--void gaim_savedstatus_activate_for_account(const GaimSavedStatus *saved_status, GaimAccount *account);
-+void gaim2_savedstatus_activate_for_account(const Gaim2SavedStatus *saved_status, Gaim2Account *account);
-
- /**
- * Get the handle for the status subsystem.
- *
- * @return the handle to the status subsystem
- */
--void *gaim_savedstatuses_get_handle(void);
-+void *gaim2_savedstatuses_get_handle(void);
-
- /**
- * Initializes the status subsystem.
- */
--void gaim_savedstatuses_init(void);
-+void gaim2_savedstatuses_init(void);
-
- /**
- * Uninitializes the status subsystem.
- */
--void gaim_savedstatuses_uninit(void);
-+void gaim2_savedstatuses_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/server.c ./src/server.c
---- ./src/server.c 2005-12-29 20:36:58.000000000 +0100
-+++ ./src/server.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -37,12 +37,12 @@
- #define SECS_BEFORE_RESENDING_AUTORESPONSE 600
- #define SEX_BEFORE_RESENDING_AUTORESPONSE "Only after you're married"
-
--/* This should return the elapsed time in seconds in which Gaim will not send
-+/* This should return the elapsed time in seconds in which Gaim2 will not send
- * typing notifications.
- * if it returns zero, it will not send any more typing notifications
- * typing is a flag - TRUE for typing, FALSE for stopped typing */
--int serv_send_typing(GaimConnection *g, const char *name, int typing) {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+int serv_send_typing(Gaim2Connection *g, const char *name, int typing) {
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-@@ -55,7 +55,7 @@ int serv_send_typing(GaimConnection *g,
-
- static GSList *last_auto_responses = NULL;
- struct last_auto_response {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- char name[80];
- time_t sent;
- };
-@@ -83,14 +83,14 @@ expire_last_auto_responses(gpointer data
- }
-
- static struct last_auto_response *
--get_last_auto_response(GaimConnection *gc, const char *name)
-+get_last_auto_response(Gaim2Connection *gc, const char *name)
- {
- GSList *tmp;
- struct last_auto_response *lar;
-
- /* because we're modifying or creating a lar, schedule the
- * function to expire them as the pref dictates */
-- gaim_timeout_add((SECS_BEFORE_RESENDING_AUTORESPONSE + 1) * 1000, expire_last_auto_responses, NULL);
-+ gaim2_timeout_add((SECS_BEFORE_RESENDING_AUTORESPONSE + 1) * 1000, expire_last_auto_responses, NULL);
-
- tmp = last_auto_responses;
-
-@@ -112,23 +112,23 @@ get_last_auto_response(GaimConnection *g
- return lar;
- }
-
--int serv_send_im(GaimConnection *gc, const char *name, const char *message,
-- GaimMessageFlags flags)
-+int serv_send_im(Gaim2Connection *gc, const char *name, const char *message,
-+ Gaim2MessageFlags flags)
- {
-- GaimConversation *conv;
-- GaimAccount *account;
-- GaimPresence *presence;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Conversation *conv;
-+ Gaim2Account *account;
-+ Gaim2Presence *presence;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- int val = -EINVAL;
- const gchar *auto_reply_pref;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
-
- if (prpl_info && prpl_info->send_im)
- val = prpl_info->send_im(gc, name, message, flags);
-@@ -137,9 +137,9 @@ int serv_send_im(GaimConnection *gc, con
- * XXX - If "only auto-reply when away & idle" is set, then shouldn't
- * this only reset lar->sent if we're away AND idle?
- */
-- auto_reply_pref = gaim_prefs_get_string("/core/away/auto_reply");
-+ auto_reply_pref = gaim2_prefs_get_string("/core/away/auto_reply");
- if ((gc->flags & GAIM_CONNECTION_AUTO_RESP) &&
-- !gaim_presence_is_available(presence) &&
-+ !gaim2_presence_is_available(presence) &&
- strcmp(auto_reply_pref, "never")) {
-
- struct last_auto_response *lar;
-@@ -147,15 +147,15 @@ int serv_send_im(GaimConnection *gc, con
- lar->sent = time(NULL);
- }
-
-- if (conv && gaim_conv_im_get_type_again_timeout(GAIM_CONV_IM(conv)))
-- gaim_conv_im_stop_type_again_timeout(GAIM_CONV_IM(conv));
-+ if (conv && gaim2_conv_im_get_type_again_timeout(GAIM_CONV_IM(conv)))
-+ gaim2_conv_im_stop_type_again_timeout(GAIM_CONV_IM(conv));
-
- return val;
- }
-
--void serv_get_info(GaimConnection *gc, const char *name)
-+void serv_get_info(Gaim2Connection *gc, const char *name)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -164,26 +164,26 @@ void serv_get_info(GaimConnection *gc, c
- prpl_info->get_info(gc, name);
- }
-
--void serv_set_info(GaimConnection *gc, const char *info)
-+void serv_set_info(Gaim2Connection *gc, const char *info)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimAccount *account;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Account *account;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc) &&
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc) &&
- prpl_info->set_info) {
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- if (gaim_signal_emit_return_1(gaim_accounts_get_handle(),
-+ if (gaim2_signal_emit_return_1(gaim2_accounts_get_handle(),
- "account-setting-info", account, info))
- return;
-
- prpl_info->set_info(gc, info);
-
-- gaim_signal_emit(gaim_accounts_get_handle(),
-+ gaim2_signal_emit(gaim2_accounts_get_handle(),
- "account-set-info", account, info);
- }
- }
-@@ -191,9 +191,9 @@ void serv_set_info(GaimConnection *gc, c
- /*
- * Set buddy's alias on server roster/list
- */
--void serv_alias_buddy(GaimBuddy *b)
-+void serv_alias_buddy(Gaim2Buddy *b)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (b != NULL && b->account->gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(b->account->gc->prpl);
-@@ -204,19 +204,19 @@ void serv_alias_buddy(GaimBuddy *b)
- }
-
- void
--serv_got_alias(GaimConnection *gc, const char *who, const char *alias)
-+serv_got_alias(Gaim2Connection *gc, const char *who, const char *alias)
- {
-- GaimAccount *account = gaim_connection_get_account(gc);
-- GSList *buds, *buddies = gaim_find_buddies(account, who);
-- GaimBuddy *b;
-- GaimConversation *conv;
-+ Gaim2Account *account = gaim2_connection_get_account(gc);
-+ GSList *buds, *buddies = gaim2_find_buddies(account, who);
-+ Gaim2Buddy *b;
-+ Gaim2Conversation *conv;
-
- for (buds = buddies; buds; buds = buds->next)
- {
- b = buds->data;
-- gaim_blist_server_alias_buddy(b, alias);
-+ gaim2_blist_server_alias_buddy(b, alias);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, b->name, account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, b->name, account);
-
- if (conv != NULL && b->server_alias != NULL &&
- strcmp(b->server_alias, alias))
-@@ -224,7 +224,7 @@ serv_got_alias(GaimConnection *gc, const
- char *tmp = g_strdup_printf(_("%s is now known as %s.\n"),
- who, alias);
-
-- gaim_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM,
-+ gaim2_conversation_write(conv, NULL, tmp, GAIM_MESSAGE_SYSTEM,
- time(NULL));
-
- g_free(tmp);
-@@ -238,11 +238,11 @@ serv_got_alias(GaimConnection *gc, const
- *
- * Note: For now we'll not deal with changing gc's at the same time, but
- * it should be possible. Probably needs to be done, someday. Although,
-- * the UI for that would be difficult, because groups are Gaim-wide.
-+ * the UI for that would be difficult, because groups are Gaim2-wide.
- */
--void serv_move_buddy(GaimBuddy *b, GaimGroup *og, GaimGroup *ng)
-+void serv_move_buddy(Gaim2Buddy *b, Gaim2Group *og, Gaim2Group *ng)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (b->account->gc != NULL && b->account->gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(b->account->gc->prpl);
-@@ -254,53 +254,53 @@ void serv_move_buddy(GaimBuddy *b, GaimG
- }
- }
-
--void serv_add_permit(GaimConnection *g, const char *name)
-+void serv_add_permit(Gaim2Connection *g, const char *name)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->add_permit)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->add_permit)
- prpl_info->add_permit(g, name);
- }
-
--void serv_add_deny(GaimConnection *g, const char *name)
-+void serv_add_deny(Gaim2Connection *g, const char *name)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->add_deny)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->add_deny)
- prpl_info->add_deny(g, name);
- }
-
--void serv_rem_permit(GaimConnection *g, const char *name)
-+void serv_rem_permit(Gaim2Connection *g, const char *name)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->rem_permit)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->rem_permit)
- prpl_info->rem_permit(g, name);
- }
-
--void serv_rem_deny(GaimConnection *g, const char *name)
-+void serv_rem_deny(Gaim2Connection *g, const char *name)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->rem_deny)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->rem_deny)
- prpl_info->rem_deny(g, name);
- }
-
--void serv_set_permit_deny(GaimConnection *g)
-+void serv_set_permit_deny(Gaim2Connection *g)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-@@ -311,40 +311,40 @@ void serv_set_permit_deny(GaimConnection
- * in the prefs. In either case you should probably be resetting and
- * resending the permit/deny info when you get this.
- */
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->set_permit_deny)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->set_permit_deny)
- prpl_info->set_permit_deny(g);
- }
-
--void serv_join_chat(GaimConnection *g, GHashTable *data)
-+void serv_join_chat(Gaim2Connection *g, GHashTable *data)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->join_chat)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->join_chat)
- prpl_info->join_chat(g, data);
- }
-
-
--void serv_reject_chat(GaimConnection *g, GHashTable *data)
-+void serv_reject_chat(Gaim2Connection *g, GHashTable *data)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->reject_chat)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->reject_chat)
- prpl_info->reject_chat(g, data);
- }
-
--void serv_chat_invite(GaimConnection *g, int id, const char *message, const char *name)
-+void serv_chat_invite(Gaim2Connection *g, int id, const char *message, const char *name)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-- GaimConversation *conv;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Conversation *conv;
- char *buffy = message && *message ? g_strdup(message) : NULL;
-
-- conv = gaim_find_chat(g, id);
-+ conv = gaim2_find_chat(g, id);
-
- if (conv == NULL)
- return;
-@@ -352,30 +352,30 @@ void serv_chat_invite(GaimConnection *g,
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-inviting-user",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-inviting-user",
- conv, name, &buffy);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), g) && prpl_info->chat_invite)
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), g) && prpl_info->chat_invite)
- prpl_info->chat_invite(g, id, buffy, name);
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-invited-user",
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-invited-user",
- conv, name, buffy);
-
- if (buffy)
- g_free(buffy);
- }
-
--/* Ya know, nothing uses this except gaim_conversation_destroy(),
-+/* Ya know, nothing uses this except gaim2_conversation_destroy(),
- * I think I'll just merge it into that later...
- * Then again, something might want to use this, from outside prpl-land
- * to leave a chat without destroying the conversation.
- */
-
--void serv_chat_leave(GaimConnection *g, int id)
-+void serv_chat_leave(Gaim2Connection *g, int id)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
-- if (!g_list_find(gaim_connections_get_all(), g))
-+ if (!g_list_find(gaim2_connections_get_all(), g))
- return;
-
- if (g->prpl != NULL)
-@@ -385,9 +385,9 @@ void serv_chat_leave(GaimConnection *g,
- prpl_info->chat_leave(g, id);
- }
-
--void serv_chat_whisper(GaimConnection *g, int id, const char *who, const char *message)
-+void serv_chat_whisper(Gaim2Connection *g, int id, const char *who, const char *message)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (g != NULL && g->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(g->prpl);
-@@ -396,10 +396,10 @@ void serv_chat_whisper(GaimConnection *g
- prpl_info->chat_whisper(g, id, who, message);
- }
-
--int serv_chat_send(GaimConnection *gc, int id, const char *message, GaimMessageFlags flags)
-+int serv_chat_send(Gaim2Connection *gc, int id, const char *message, Gaim2MessageFlags flags)
- {
- int val = -EINVAL;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -410,9 +410,9 @@ int serv_chat_send(GaimConnection *gc, i
- return val;
- }
-
--void serv_set_buddyicon(GaimConnection *gc, const char *filename)
-+void serv_set_buddyicon(Gaim2Connection *gc, const char *filename)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -426,27 +426,27 @@ void serv_set_buddyicon(GaimConnection *
- * woo. i'm actually going to comment this function. isn't that fun. make
- * sure to follow along, kids
- */
--void serv_got_im(GaimConnection *gc, const char *who, const char *msg,
-- GaimMessageFlags flags, time_t mtime)
-+void serv_got_im(Gaim2Connection *gc, const char *who, const char *msg,
-+ Gaim2MessageFlags flags, time_t mtime)
- {
-- GaimAccount *account;
-- GaimConversation *cnv;
-- GaimPresence *presence;
-- GaimStatus *status;
-+ Gaim2Account *account;
-+ Gaim2Conversation *cnv;
-+ Gaim2Presence *presence;
-+ Gaim2Status *status;
- char *message, *name;
- char *angel, *buffy;
- int plugin_return;
-
- g_return_if_fail(msg != NULL);
-
-- account = gaim_connection_get_account(gc);
-- presence = gaim_account_get_presence(account);
-+ account = gaim2_connection_get_account(gc);
-+ presence = gaim2_account_get_presence(account);
-
- /*
- * We should update the conversation window buttons and menu,
- * if it exists.
- */
-- cnv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, gc->account);
-+ cnv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, who, gc->account);
-
- /*
- * Plugin stuff. we pass a char ** but we don't want to pass what's
-@@ -458,7 +458,7 @@ void serv_got_im(GaimConnection *gc, con
- angel = g_strdup(who);
-
- plugin_return = GPOINTER_TO_INT(
-- gaim_signal_emit_return_1(gaim_conversations_get_handle(),
-+ gaim2_signal_emit_return_1(gaim2_conversations_get_handle(),
- "receiving-im-msg", gc->account,
- &angel, &buffy, cnv, &flags));
-
-@@ -473,15 +473,15 @@ void serv_got_im(GaimConnection *gc, con
- name = angel;
- message = buffy;
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "received-im-msg", gc->account,
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "received-im-msg", gc->account,
- name, message, cnv, flags);
-
- /* search for conversation again in case it was created by received-im-msg handler */
- if (cnv == NULL)
-- cnv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
-+ cnv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
-
- /* Make sure URLs are clickable */
-- buffy = gaim_markup_linkify(message);
-+ buffy = gaim2_markup_linkify(message);
- g_free(message);
- message = buffy;
-
-@@ -496,7 +496,7 @@ void serv_got_im(GaimConnection *gc, con
- * are three or four different ways of handling it and different
- * things we have to do for each.
- */
-- if (!gaim_presence_is_available(presence))
-+ if (!gaim2_presence_is_available(presence))
- {
- time_t t = time(NULL);
- struct last_auto_response *lar;
-@@ -504,9 +504,9 @@ void serv_got_im(GaimConnection *gc, con
- const char *away_msg;
-
- if (cnv == NULL)
-- cnv = gaim_conversation_new(GAIM_CONV_TYPE_IM, account, name);
-+ cnv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, account, name);
-
-- gaim_conv_im_write(GAIM_CONV_IM(cnv), NULL, message, flags, mtime);
-+ gaim2_conv_im_write(GAIM_CONV_IM(cnv), NULL, message, flags, mtime);
-
- /*
- * Don't autorespond if:
-@@ -517,12 +517,12 @@ void serv_got_im(GaimConnection *gc, con
- * - or we're not idle and the 'only auto respond if idle' pref
- * is set
- */
-- auto_reply_pref = gaim_prefs_get_string("/core/away/auto_reply");
-+ auto_reply_pref = gaim2_prefs_get_string("/core/away/auto_reply");
-
- if (!(gc->flags & GAIM_CONNECTION_AUTO_RESP) ||
-- gaim_presence_is_available(presence) ||
-+ gaim2_presence_is_available(presence) ||
- !strcmp(auto_reply_pref, "never") ||
-- (!gaim_presence_is_idle(presence) &&
-+ (!gaim2_presence_is_idle(presence) &&
- !strcmp(auto_reply_pref, "awayidle"))) {
-
- g_free(name);
-@@ -547,19 +547,19 @@ void serv_got_im(GaimConnection *gc, con
- }
- lar->sent = t;
-
-- status = gaim_presence_get_active_status(presence);
-+ status = gaim2_presence_get_active_status(presence);
- if (status == NULL)
- return;
-
-- away_msg = gaim_value_get_string(
-- gaim_status_get_attr_value(status, "message"));
-+ away_msg = gaim2_value_get_string(
-+ gaim2_status_get_attr_value(status, "message"));
-
- if ((away_msg == NULL) || (*away_msg == '\0'))
- return;
-
- serv_send_im(gc, name, away_msg, GAIM_MESSAGE_AUTO_RESP);
-
-- gaim_conv_im_write(GAIM_CONV_IM(cnv), NULL, away_msg,
-+ gaim2_conv_im_write(GAIM_CONV_IM(cnv), NULL, away_msg,
- GAIM_MESSAGE_SEND | GAIM_MESSAGE_AUTO_RESP,
- mtime);
- }
-@@ -573,49 +573,49 @@ void serv_got_im(GaimConnection *gc, con
- */
-
- if (cnv == NULL)
-- cnv = gaim_conversation_new(GAIM_CONV_TYPE_IM, gc->account, name);
-+ cnv = gaim2_conversation_new(GAIM_CONV_TYPE_IM, gc->account, name);
-
-- gaim_conv_im_write(GAIM_CONV_IM(cnv), NULL, message, flags, mtime);
-+ gaim2_conv_im_write(GAIM_CONV_IM(cnv), NULL, message, flags, mtime);
- }
-
- g_free(name);
- g_free(message);
- }
-
--void serv_got_typing(GaimConnection *gc, const char *name, int timeout,
-- GaimTypingState state) {
-- GaimConversation *conv;
-- GaimConvIm *im = NULL;
-+void serv_got_typing(Gaim2Connection *gc, const char *name, int timeout,
-+ Gaim2TypingState state) {
-+ Gaim2Conversation *conv;
-+ Gaim2ConvIm *im = NULL;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
- if (conv != NULL) {
- im = GAIM_CONV_IM(conv);
-
-- gaim_conv_im_set_typing_state(im, state);
-- gaim_conv_im_update_typing(im);
-+ gaim2_conv_im_set_typing_state(im, state);
-+ gaim2_conv_im_update_typing(im);
- }
-
- if (state == GAIM_TYPING)
- {
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "buddy-typing", gc->account, name);
- }
- else
- {
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "buddy-typing-stopped", gc->account, name);
- }
-
- if (conv != NULL && timeout > 0)
-- gaim_conv_im_start_typing_timeout(im, timeout);
-+ gaim2_conv_im_start_typing_timeout(im, timeout);
- }
-
--void serv_got_typing_stopped(GaimConnection *gc, const char *name) {
-+void serv_got_typing_stopped(Gaim2Connection *gc, const char *name) {
-
-- GaimConversation *conv;
-- GaimConvIm *im;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvIm *im;
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM, name, gc->account);
- if (conv != NULL)
- {
- im = GAIM_CONV_IM(conv);
-@@ -623,17 +623,17 @@ void serv_got_typing_stopped(GaimConnect
- if (im->typing_state == GAIM_NOT_TYPING)
- return;
-
-- gaim_conv_im_stop_typing_timeout(im);
-- gaim_conv_im_set_typing_state(im, GAIM_NOT_TYPING);
-- gaim_conv_im_update_typing(im);
-+ gaim2_conv_im_stop_typing_timeout(im);
-+ gaim2_conv_im_set_typing_state(im, GAIM_NOT_TYPING);
-+ gaim2_conv_im_update_typing(im);
- }
-
-- gaim_signal_emit(gaim_conversations_get_handle(),
-+ gaim2_signal_emit(gaim2_conversations_get_handle(),
- "buddy-typing-stopped", gc->account, name);
- }
-
- struct chat_invite_data {
-- GaimConnection *gc;
-+ Gaim2Connection *gc;
- GHashTable *components;
- };
-
-@@ -660,18 +660,18 @@ static void chat_invite_accept(struct ch
-
-
-
--void serv_got_chat_invite(GaimConnection *gc, const char *name,
-+void serv_got_chat_invite(Gaim2Connection *gc, const char *name,
- const char *who, const char *message, GHashTable *data)
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char buf2[BUF_LONG];
- struct chat_invite_data *cid = g_new0(struct chat_invite_data, 1);
- int plugin_return;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- plugin_return = GPOINTER_TO_INT(gaim_signal_emit_return_1(
-- gaim_conversations_get_handle(),
-+ plugin_return = GPOINTER_TO_INT(gaim2_signal_emit_return_1(
-+ gaim2_conversations_get_handle(),
- "chat-invited", account, who, name, message, data));
-
- cid->gc = gc;
-@@ -683,15 +683,15 @@ void serv_got_chat_invite(GaimConnection
- {
- g_snprintf(buf2, sizeof(buf2),
- _("%s has invited %s to the chat room %s:\n%s"),
-- who, gaim_account_get_username(account), name, message);
-+ who, gaim2_account_get_username(account), name, message);
- }
- else
- g_snprintf(buf2, sizeof(buf2),
- _("%s has invited %s to the chat room %s\n"),
-- who, gaim_account_get_username(account), name);
-+ who, gaim2_account_get_username(account), name);
-
-
-- gaim_request_accept_cancel(gc, NULL, _("Accept chat invitation?"), buf2,
-+ gaim2_request_accept_cancel(gc, NULL, _("Accept chat invitation?"), buf2,
- GAIM_DEFAULT_ACTION_NONE, cid,
- G_CALLBACK(chat_invite_accept),
- G_CALLBACK(chat_invite_reject));
-@@ -702,44 +702,44 @@ void serv_got_chat_invite(GaimConnection
- chat_invite_reject(cid);
- }
-
--GaimConversation *serv_got_joined_chat(GaimConnection *gc,
-+Gaim2Conversation *serv_got_joined_chat(Gaim2Connection *gc,
- int id, const char *name)
- {
-- GaimConversation *conv;
-- GaimConvChat *chat;
-- GaimAccount *account;
-+ Gaim2Conversation *conv;
-+ Gaim2ConvChat *chat;
-+ Gaim2Account *account;
-
-- account = gaim_connection_get_account(gc);
-+ account = gaim2_connection_get_account(gc);
-
-- conv = gaim_conversation_new(GAIM_CONV_TYPE_CHAT, account, name);
-+ conv = gaim2_conversation_new(GAIM_CONV_TYPE_CHAT, account, name);
- chat = GAIM_CONV_CHAT(conv);
-
- if (!g_slist_find(gc->buddy_chats, conv))
- gc->buddy_chats = g_slist_append(gc->buddy_chats, conv);
-
-- gaim_conv_chat_set_id(chat, id);
-+ gaim2_conv_chat_set_id(chat, id);
-
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-joined", conv);
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-joined", conv);
-
- return conv;
- }
-
--void serv_got_chat_left(GaimConnection *g, int id)
-+void serv_got_chat_left(Gaim2Connection *g, int id)
- {
- GSList *bcs;
-- GaimConversation *conv = NULL;
-- GaimConvChat *chat = NULL;
-- GaimAccount *account;
-+ Gaim2Conversation *conv = NULL;
-+ Gaim2ConvChat *chat = NULL;
-+ Gaim2Account *account;
-
-- account = gaim_connection_get_account(g);
-+ account = gaim2_connection_get_account(g);
-
- for (bcs = g->buddy_chats; bcs != NULL; bcs = bcs->next) {
-- conv = (GaimConversation *)bcs->data;
-+ conv = (Gaim2Conversation *)bcs->data;
-
- chat = GAIM_CONV_CHAT(conv);
-
-- if (gaim_conv_chat_get_id(chat) == id)
-+ if (gaim2_conv_chat_get_id(chat) == id)
- break;
-
- conv = NULL;
-@@ -748,32 +748,32 @@ void serv_got_chat_left(GaimConnection *
- if (!conv)
- return;
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "chat-left", conv);
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "chat-left", conv);
-
-- gaim_debug(GAIM_DEBUG_INFO, "server", "Leaving room: %s\n",
-- gaim_conversation_get_name(conv));
-+ gaim2_debug(GAIM_DEBUG_INFO, "server", "Leaving room: %s\n",
-+ gaim2_conversation_get_name(conv));
-
- g->buddy_chats = g_slist_remove(g->buddy_chats, conv);
-
-- gaim_conv_chat_left(GAIM_CONV_CHAT(conv));
-+ gaim2_conv_chat_left(GAIM_CONV_CHAT(conv));
- }
-
--void serv_got_chat_in(GaimConnection *g, int id, const char *who,
-- GaimMessageFlags flags, const char *message, time_t mtime)
-+void serv_got_chat_in(Gaim2Connection *g, int id, const char *who,
-+ Gaim2MessageFlags flags, const char *message, time_t mtime)
- {
- GSList *bcs;
-- GaimConversation *conv = NULL;
-- GaimConvChat *chat = NULL;
-+ Gaim2Conversation *conv = NULL;
-+ Gaim2ConvChat *chat = NULL;
- char *buf;
- char *buffy, *angel;
- int plugin_return;
-
- for (bcs = g->buddy_chats; bcs != NULL; bcs = bcs->next) {
-- conv = (GaimConversation *)bcs->data;
-+ conv = (Gaim2Conversation *)bcs->data;
-
- chat = GAIM_CONV_CHAT(conv);
-
-- if (gaim_conv_chat_get_id(chat) == id)
-+ if (gaim2_conv_chat_get_id(chat) == id)
- break;
-
- conv = NULL;
-@@ -795,7 +795,7 @@ void serv_got_chat_in(GaimConnection *g,
- angel = g_strdup(who);
-
- plugin_return = GPOINTER_TO_INT(
-- gaim_signal_emit_return_1(gaim_conversations_get_handle(),
-+ gaim2_signal_emit_return_1(gaim2_conversations_get_handle(),
- "receiving-chat-msg", g->account,
- &angel, &buffy, conv, &flags));
-
-@@ -809,22 +809,22 @@ void serv_got_chat_in(GaimConnection *g,
- who = angel;
- message = buffy;
-
-- gaim_signal_emit(gaim_conversations_get_handle(), "received-chat-msg", g->account,
-+ gaim2_signal_emit(gaim2_conversations_get_handle(), "received-chat-msg", g->account,
- who, message, conv, flags);
-
- /* Make sure URLs are clickable */
-- buf = gaim_markup_linkify(message);
-+ buf = gaim2_markup_linkify(message);
-
-- gaim_conv_chat_write(chat, who, buf, flags, mtime);
-+ gaim2_conv_chat_write(chat, who, buf, flags, mtime);
-
- g_free(angel);
- g_free(buf);
- g_free(buffy);
- }
-
--void serv_send_file(GaimConnection *gc, const char *who, const char *file)
-+void serv_send_file(Gaim2Connection *gc, const char *who, const char *file)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-@@ -836,9 +836,9 @@ void serv_send_file(GaimConnection *gc,
- }
- }
-
--void serv_voice_chat(GaimConnection *gc, const char *who)
-+void serv_voice_chat(Gaim2Connection *gc, const char *who)
- {
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-diff -prNu ./src/server.h ./src/server.h
---- ./src/server.h 2005-11-24 21:47:45.000000000 +0100
-+++ ./src/server.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file server.h Server API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,40 +33,40 @@
- extern "C" {
- #endif
-
--int serv_send_im(GaimConnection *, const char *, const char *, GaimMessageFlags flags);
--void serv_get_info(GaimConnection *, const char *);
--void serv_set_info(GaimConnection *, const char *);
--int serv_send_typing(GaimConnection *, const char *, int);
--void serv_move_buddy(GaimBuddy *, GaimGroup *, GaimGroup *);
--void serv_add_permit(GaimConnection *, const char *);
--void serv_add_deny(GaimConnection *, const char *);
--void serv_rem_permit(GaimConnection *, const char *);
--void serv_rem_deny(GaimConnection *, const char *);
--void serv_set_permit_deny(GaimConnection *);
--void serv_join_chat(GaimConnection *, GHashTable *);
--void serv_reject_chat(GaimConnection *, GHashTable *);
--void serv_chat_invite(GaimConnection *, int, const char *, const char *);
--void serv_chat_leave(GaimConnection *, int);
--void serv_chat_whisper(GaimConnection *, int, const char *, const char *);
--int serv_chat_send(GaimConnection *, int, const char *, GaimMessageFlags flags);
--void serv_alias_buddy(GaimBuddy *);
--void serv_got_alias(GaimConnection *gc, const char *who, const char *alias);
--void serv_got_typing(GaimConnection *gc, const char *name, int timeout,
-- GaimTypingState state);
--void serv_set_buddyicon(GaimConnection *gc, const char *filename);
--void serv_got_typing_stopped(GaimConnection *gc, const char *name);
--void serv_got_im(GaimConnection *gc, const char *who, const char *msg,
-- GaimMessageFlags flags, time_t mtime);
--void serv_got_chat_invite(GaimConnection *gc, const char *name,
-+int serv_send_im(Gaim2Connection *, const char *, const char *, Gaim2MessageFlags flags);
-+void serv_get_info(Gaim2Connection *, const char *);
-+void serv_set_info(Gaim2Connection *, const char *);
-+int serv_send_typing(Gaim2Connection *, const char *, int);
-+void serv_move_buddy(Gaim2Buddy *, Gaim2Group *, Gaim2Group *);
-+void serv_add_permit(Gaim2Connection *, const char *);
-+void serv_add_deny(Gaim2Connection *, const char *);
-+void serv_rem_permit(Gaim2Connection *, const char *);
-+void serv_rem_deny(Gaim2Connection *, const char *);
-+void serv_set_permit_deny(Gaim2Connection *);
-+void serv_join_chat(Gaim2Connection *, GHashTable *);
-+void serv_reject_chat(Gaim2Connection *, GHashTable *);
-+void serv_chat_invite(Gaim2Connection *, int, const char *, const char *);
-+void serv_chat_leave(Gaim2Connection *, int);
-+void serv_chat_whisper(Gaim2Connection *, int, const char *, const char *);
-+int serv_chat_send(Gaim2Connection *, int, const char *, Gaim2MessageFlags flags);
-+void serv_alias_buddy(Gaim2Buddy *);
-+void serv_got_alias(Gaim2Connection *gc, const char *who, const char *alias);
-+void serv_got_typing(Gaim2Connection *gc, const char *name, int timeout,
-+ Gaim2TypingState state);
-+void serv_set_buddyicon(Gaim2Connection *gc, const char *filename);
-+void serv_got_typing_stopped(Gaim2Connection *gc, const char *name);
-+void serv_got_im(Gaim2Connection *gc, const char *who, const char *msg,
-+ Gaim2MessageFlags flags, time_t mtime);
-+void serv_got_chat_invite(Gaim2Connection *gc, const char *name,
- const char *who, const char *message,
- GHashTable *data);
--GaimConversation *serv_got_joined_chat(GaimConnection *gc,
-+Gaim2Conversation *serv_got_joined_chat(Gaim2Connection *gc,
- int id, const char *name);
--void serv_got_chat_left(GaimConnection *g, int id);
--void serv_got_chat_in(GaimConnection *g, int id, const char *who,
-- GaimMessageFlags flags, const char *message, time_t mtime);
--void serv_send_file(GaimConnection *gc, const char *who, const char *file);
--void serv_voice_chat(GaimConnection *gc, const char *who);
-+void serv_got_chat_left(Gaim2Connection *g, int id);
-+void serv_got_chat_in(Gaim2Connection *g, int id, const char *who,
-+ Gaim2MessageFlags flags, const char *message, time_t mtime);
-+void serv_send_file(Gaim2Connection *gc, const char *who, const char *file);
-+void serv_voice_chat(Gaim2Connection *gc, const char *who);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/signals.c ./src/signals.c
---- ./src/signals.c 2005-12-02 07:42:58.000000000 +0100
-+++ ./src/signals.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file signals.c Signal API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -41,39 +41,39 @@ typedef struct
-
- gulong next_signal_id;
-
--} GaimInstanceData;
-+} Gaim2InstanceData;
-
- typedef struct
- {
- gulong id;
-
-- GaimSignalMarshalFunc marshal;
-+ Gaim2SignalMarshalFunc marshal;
-
- int num_values;
-- GaimValue **values;
-- GaimValue *ret_value;
-+ Gaim2Value **values;
-+ Gaim2Value *ret_value;
-
- GList *handlers;
- size_t handler_count;
-
- gulong next_handler_id;
--} GaimSignalData;
-+} Gaim2SignalData;
-
- typedef struct
- {
- gulong id;
-- GaimCallback cb;
-+ Gaim2Callback cb;
- void *handle;
- void *data;
- gboolean use_vargs;
- int priority;
-
--} GaimSignalHandlerData;
-+} Gaim2SignalHandlerData;
-
- static GHashTable *instance_table = NULL;
-
- static void
--destroy_instance_data(GaimInstanceData *instance_data)
-+destroy_instance_data(Gaim2InstanceData *instance_data)
- {
- g_hash_table_destroy(instance_data->signals);
-
-@@ -81,14 +81,14 @@ destroy_instance_data(GaimInstanceData *
- }
-
- static void
--destroy_signal_data(GaimSignalData *signal_data)
-+destroy_signal_data(Gaim2SignalData *signal_data)
- {
-- GaimSignalHandlerData *handler_data;
-+ Gaim2SignalHandlerData *handler_data;
- GList *l;
-
- for (l = signal_data->handlers; l != NULL; l = l->next)
- {
-- handler_data = (GaimSignalHandlerData *)l->data;
-+ handler_data = (Gaim2SignalHandlerData *)l->data;
-
- g_free(l->data);
- }
-@@ -100,23 +100,23 @@ destroy_signal_data(GaimSignalData *sign
- int i;
-
- for (i = 0; i < signal_data->num_values; i++)
-- gaim_value_destroy((GaimValue *)signal_data->values[i]);
-+ gaim2_value_destroy((Gaim2Value *)signal_data->values[i]);
-
- g_free(signal_data->values);
- }
-
- if (signal_data->ret_value != NULL)
-- gaim_value_destroy(signal_data->ret_value);
-+ gaim2_value_destroy(signal_data->ret_value);
- g_free(signal_data);
- }
-
- gulong
--gaim_signal_register(void *instance, const char *signal,
-- GaimSignalMarshalFunc marshal,
-- GaimValue *ret_value, int num_values, ...)
-+gaim2_signal_register(void *instance, const char *signal,
-+ Gaim2SignalMarshalFunc marshal,
-+ Gaim2Value *ret_value, int num_values, ...)
- {
-- GaimInstanceData *instance_data;
-- GaimSignalData *signal_data;
-+ Gaim2InstanceData *instance_data;
-+ Gaim2SignalData *signal_data;
- va_list args;
-
- g_return_val_if_fail(instance != NULL, 0);
-@@ -124,11 +124,11 @@ gaim_signal_register(void *instance, con
- g_return_val_if_fail(marshal != NULL, 0);
-
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- if (instance_data == NULL)
- {
-- instance_data = g_new0(GaimInstanceData, 1);
-+ instance_data = g_new0(Gaim2InstanceData, 1);
-
- instance_data->instance = instance;
- instance_data->next_signal_id = 1;
-@@ -140,7 +140,7 @@ gaim_signal_register(void *instance, con
- g_hash_table_insert(instance_table, instance, instance_data);
- }
-
-- signal_data = g_new0(GaimSignalData, 1);
-+ signal_data = g_new0(Gaim2SignalData, 1);
- signal_data->id = instance_data->next_signal_id;
- signal_data->marshal = marshal;
- signal_data->next_handler_id = 1;
-@@ -151,12 +151,12 @@ gaim_signal_register(void *instance, con
- {
- int i;
-
-- signal_data->values = g_new0(GaimValue *, num_values);
-+ signal_data->values = g_new0(Gaim2Value *, num_values);
-
- va_start(args, num_values);
-
- for (i = 0; i < num_values; i++)
-- signal_data->values[i] = va_arg(args, GaimValue *);
-+ signal_data->values[i] = va_arg(args, Gaim2Value *);
-
- va_end(args);
- }
-@@ -171,15 +171,15 @@ gaim_signal_register(void *instance, con
- }
-
- void
--gaim_signal_unregister(void *instance, const char *signal)
-+gaim2_signal_unregister(void *instance, const char *signal)
- {
-- GaimInstanceData *instance_data;
-+ Gaim2InstanceData *instance_data;
-
- g_return_if_fail(instance != NULL);
- g_return_if_fail(signal != NULL);
-
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- g_return_if_fail(instance_data != NULL);
-
-@@ -195,7 +195,7 @@ gaim_signal_unregister(void *instance, c
- }
-
- void
--gaim_signals_unregister_by_instance(void *instance)
-+gaim2_signals_unregister_by_instance(void *instance)
- {
- gboolean found;
-
-@@ -211,12 +211,12 @@ gaim_signals_unregister_by_instance(void
- }
-
- void
--gaim_signal_get_values(void *instance, const char *signal,
-- GaimValue **ret_value,
-- int *num_values, GaimValue ***values)
-+gaim2_signal_get_values(void *instance, const char *signal,
-+ Gaim2Value **ret_value,
-+ int *num_values, Gaim2Value ***values)
- {
-- GaimInstanceData *instance_data;
-- GaimSignalData *signal_data;
-+ Gaim2InstanceData *instance_data;
-+ Gaim2SignalData *signal_data;
-
- g_return_if_fail(instance != NULL);
- g_return_if_fail(signal != NULL);
-@@ -225,13 +225,13 @@ gaim_signal_get_values(void *instance, c
-
- /* Get the instance data */
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- g_return_if_fail(instance_data != NULL);
-
- /* Get the signal data */
- signal_data =
-- (GaimSignalData *)g_hash_table_lookup(instance_data->signals, signal);
-+ (Gaim2SignalData *)g_hash_table_lookup(instance_data->signals, signal);
-
- g_return_if_fail(signal_data != NULL);
-
-@@ -243,8 +243,8 @@ gaim_signal_get_values(void *instance, c
- }
-
- static gint handler_priority(void * a, void * b) {
-- GaimSignalHandlerData *ah = (GaimSignalHandlerData*)a;
-- GaimSignalHandlerData *bh = (GaimSignalHandlerData*)b;
-+ Gaim2SignalHandlerData *ah = (Gaim2SignalHandlerData*)a;
-+ Gaim2SignalHandlerData *bh = (Gaim2SignalHandlerData*)b;
- if (ah->priority > bh->priority) return 1;
- if (ah->priority < bh->priority) return -1;
- return 0;
-@@ -252,11 +252,11 @@ static gint handler_priority(void * a, v
-
- static gulong
- signal_connect_common(void *instance, const char *signal, void *handle,
-- GaimCallback func, void *data, int priority, gboolean use_vargs)
-+ Gaim2Callback func, void *data, int priority, gboolean use_vargs)
- {
-- GaimInstanceData *instance_data;
-- GaimSignalData *signal_data;
-- GaimSignalHandlerData *handler_data;
-+ Gaim2InstanceData *instance_data;
-+ Gaim2SignalData *signal_data;
-+ Gaim2SignalHandlerData *handler_data;
-
- g_return_val_if_fail(instance != NULL, 0);
- g_return_val_if_fail(signal != NULL, 0);
-@@ -265,23 +265,23 @@ signal_connect_common(void *instance, co
-
- /* Get the instance data */
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- g_return_val_if_fail(instance_data != NULL, 0);
-
- /* Get the signal data */
- signal_data =
-- (GaimSignalData *)g_hash_table_lookup(instance_data->signals, signal);
-+ (Gaim2SignalData *)g_hash_table_lookup(instance_data->signals, signal);
-
- if (signal_data == NULL)
- {
-- gaim_debug(GAIM_DEBUG_ERROR, "signals",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "signals",
- "Signal data for %s not found!\n", signal);
- return 0;
- }
-
- /* Create the signal handler data */
-- handler_data = g_new0(GaimSignalHandlerData, 1);
-+ handler_data = g_new0(Gaim2SignalHandlerData, 1);
- handler_data->id = signal_data->next_handler_id;
- handler_data->cb = func;
- handler_data->handle = handle;
-@@ -297,40 +297,40 @@ signal_connect_common(void *instance, co
- }
-
- gulong
--gaim_signal_connect_priority(void *instance, const char *signal, void *handle,
-- GaimCallback func, void *data, int priority)
-+gaim2_signal_connect_priority(void *instance, const char *signal, void *handle,
-+ Gaim2Callback func, void *data, int priority)
- {
- return signal_connect_common(instance, signal, handle, func, data, priority, FALSE);
- }
-
- gulong
--gaim_signal_connect(void *instance, const char *signal, void *handle,
-- GaimCallback func, void *data)
-+gaim2_signal_connect(void *instance, const char *signal, void *handle,
-+ Gaim2Callback func, void *data)
- {
- return signal_connect_common(instance, signal, handle, func, data, GAIM_SIGNAL_PRIORITY_DEFAULT, FALSE);
- }
-
- gulong
--gaim_signal_connect_priority_vargs(void *instance, const char *signal, void *handle,
-- GaimCallback func, void *data, int priority)
-+gaim2_signal_connect_priority_vargs(void *instance, const char *signal, void *handle,
-+ Gaim2Callback func, void *data, int priority)
- {
- return signal_connect_common(instance, signal, handle, func, data, priority, TRUE);
- }
-
- gulong
--gaim_signal_connect_vargs(void *instance, const char *signal, void *handle,
-- GaimCallback func, void *data)
-+gaim2_signal_connect_vargs(void *instance, const char *signal, void *handle,
-+ Gaim2Callback func, void *data)
- {
- return signal_connect_common(instance, signal, handle, func, data, GAIM_SIGNAL_PRIORITY_DEFAULT, TRUE);
- }
-
- void
--gaim_signal_disconnect(void *instance, const char *signal,
-- void *handle, GaimCallback func)
-+gaim2_signal_disconnect(void *instance, const char *signal,
-+ void *handle, Gaim2Callback func)
- {
-- GaimInstanceData *instance_data;
-- GaimSignalData *signal_data;
-- GaimSignalHandlerData *handler_data;
-+ Gaim2InstanceData *instance_data;
-+ Gaim2SignalData *signal_data;
-+ Gaim2SignalHandlerData *handler_data;
- GList *l;
- gboolean found = FALSE;
-
-@@ -341,17 +341,17 @@ gaim_signal_disconnect(void *instance, c
-
- /* Get the instance data */
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- g_return_if_fail(instance_data != NULL);
-
- /* Get the signal data */
- signal_data =
-- (GaimSignalData *)g_hash_table_lookup(instance_data->signals, signal);
-+ (Gaim2SignalData *)g_hash_table_lookup(instance_data->signals, signal);
-
- if (signal_data == NULL)
- {
-- gaim_debug(GAIM_DEBUG_ERROR, "signals",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "signals",
- "Signal data for %s not found!\n", signal);
- return;
- }
-@@ -359,7 +359,7 @@ gaim_signal_disconnect(void *instance, c
- /* Find the handler data. */
- for (l = signal_data->handlers; l != NULL; l = l->next)
- {
-- handler_data = (GaimSignalHandlerData *)l->data;
-+ handler_data = (Gaim2SignalHandlerData *)l->data;
-
- if (handler_data->handle == handle && handler_data->cb == func)
- {
-@@ -385,14 +385,14 @@ gaim_signal_disconnect(void *instance, c
- */
- static void
- disconnect_handle_from_signals(const char *signal,
-- GaimSignalData *signal_data, void *handle)
-+ Gaim2SignalData *signal_data, void *handle)
- {
- GList *l, *l_next;
-- GaimSignalHandlerData *handler_data;
-+ Gaim2SignalHandlerData *handler_data;
-
- for (l = signal_data->handlers; l != NULL; l = l_next)
- {
-- handler_data = (GaimSignalHandlerData *)l->data;
-+ handler_data = (Gaim2SignalHandlerData *)l->data;
- l_next = l->next;
-
- if (handler_data->handle == handle)
-@@ -408,7 +408,7 @@ disconnect_handle_from_signals(const cha
-
- static void
- disconnect_handle_from_instance(void *instance,
-- GaimInstanceData *instance_data,
-+ Gaim2InstanceData *instance_data,
- void *handle)
- {
- g_hash_table_foreach(instance_data->signals,
-@@ -416,7 +416,7 @@ disconnect_handle_from_instance(void *in
- }
-
- void
--gaim_signals_disconnect_by_handle(void *handle)
-+gaim2_signals_disconnect_by_handle(void *handle)
- {
- g_return_if_fail(handle != NULL);
-
-@@ -425,7 +425,7 @@ gaim_signals_disconnect_by_handle(void *
- }
-
- void
--gaim_signal_emit(void *instance, const char *signal, ...)
-+gaim2_signal_emit(void *instance, const char *signal, ...)
- {
- va_list args;
-
-@@ -433,16 +433,16 @@ gaim_signal_emit(void *instance, const c
- g_return_if_fail(signal != NULL);
-
- va_start(args, signal);
-- gaim_signal_emit_vargs(instance, signal, args);
-+ gaim2_signal_emit_vargs(instance, signal, args);
- va_end(args);
- }
-
- void
--gaim_signal_emit_vargs(void *instance, const char *signal, va_list args)
-+gaim2_signal_emit_vargs(void *instance, const char *signal, va_list args)
- {
-- GaimInstanceData *instance_data;
-- GaimSignalData *signal_data;
-- GaimSignalHandlerData *handler_data;
-+ Gaim2InstanceData *instance_data;
-+ Gaim2SignalData *signal_data;
-+ Gaim2SignalHandlerData *handler_data;
- GList *l, *l_next;
- va_list tmp;
-
-@@ -450,16 +450,16 @@ gaim_signal_emit_vargs(void *instance, c
- g_return_if_fail(signal != NULL);
-
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- g_return_if_fail(instance_data != NULL);
-
- signal_data =
-- (GaimSignalData *)g_hash_table_lookup(instance_data->signals, signal);
-+ (Gaim2SignalData *)g_hash_table_lookup(instance_data->signals, signal);
-
- if (signal_data == NULL)
- {
-- gaim_debug(GAIM_DEBUG_ERROR, "signals",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "signals",
- "Signal data for %s not found!\n", signal);
- return;
- }
-@@ -468,7 +468,7 @@ gaim_signal_emit_vargs(void *instance, c
- {
- l_next = l->next;
-
-- handler_data = (GaimSignalHandlerData *)l->data;
-+ handler_data = (Gaim2SignalHandlerData *)l->data;
-
- /* This is necessary because a va_list may only be
- * evaluated once */
-@@ -489,14 +489,14 @@ gaim_signal_emit_vargs(void *instance, c
- }
-
- #ifdef HAVE_DBUS
-- gaim_dbus_signal_emit_gaim(signal, signal_data->num_values,
-+ gaim2_dbus_signal_emit_gaim2(signal, signal_data->num_values,
- signal_data->values, args);
- #endif /* HAVE_DBUS */
-
- }
-
- void *
--gaim_signal_emit_return_1(void *instance, const char *signal, ...)
-+gaim2_signal_emit_return_1(void *instance, const char *signal, ...)
- {
- void *ret_val;
- va_list args;
-@@ -505,19 +505,19 @@ gaim_signal_emit_return_1(void *instance
- g_return_val_if_fail(signal != NULL, NULL);
-
- va_start(args, signal);
-- ret_val = gaim_signal_emit_vargs_return_1(instance, signal, args);
-+ ret_val = gaim2_signal_emit_vargs_return_1(instance, signal, args);
- va_end(args);
-
- return ret_val;
- }
-
- void *
--gaim_signal_emit_vargs_return_1(void *instance, const char *signal,
-+gaim2_signal_emit_vargs_return_1(void *instance, const char *signal,
- va_list args)
- {
-- GaimInstanceData *instance_data;
-- GaimSignalData *signal_data;
-- GaimSignalHandlerData *handler_data;
-+ Gaim2InstanceData *instance_data;
-+ Gaim2SignalData *signal_data;
-+ Gaim2SignalHandlerData *handler_data;
- GList *l, *l_next;
- va_list tmp;
-
-@@ -525,22 +525,22 @@ gaim_signal_emit_vargs_return_1(void *in
- g_return_val_if_fail(signal != NULL, NULL);
-
- instance_data =
-- (GaimInstanceData *)g_hash_table_lookup(instance_table, instance);
-+ (Gaim2InstanceData *)g_hash_table_lookup(instance_table, instance);
-
- g_return_val_if_fail(instance_data != NULL, NULL);
-
- signal_data =
-- (GaimSignalData *)g_hash_table_lookup(instance_data->signals, signal);
-+ (Gaim2SignalData *)g_hash_table_lookup(instance_data->signals, signal);
-
- if (signal_data == NULL)
- {
-- gaim_debug(GAIM_DEBUG_ERROR, "signals",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "signals",
- "Signal data for %s not found!\n", signal);
- return 0;
- }
-
- #ifdef HAVE_DBUS
-- gaim_dbus_signal_emit_gaim(signal, signal_data->num_values,
-+ gaim2_dbus_signal_emit_gaim2(signal, signal_data->num_values,
- signal_data->values, args);
- #endif /* HAVE_DBUS */
-
-@@ -550,7 +550,7 @@ gaim_signal_emit_vargs_return_1(void *in
-
- l_next = l->next;
-
-- handler_data = (GaimSignalHandlerData *)l->data;
-+ handler_data = (Gaim2SignalHandlerData *)l->data;
-
- G_VA_COPY(tmp, args);
- if (handler_data->use_vargs)
-@@ -573,7 +573,7 @@ gaim_signal_emit_vargs_return_1(void *in
- }
-
- void
--gaim_signals_init()
-+gaim2_signals_init()
- {
- g_return_if_fail(instance_table == NULL);
-
-@@ -583,7 +583,7 @@ gaim_signals_init()
- }
-
- void
--gaim_signals_uninit()
-+gaim2_signals_uninit()
- {
- g_return_if_fail(instance_table != NULL);
-
-@@ -595,14 +595,14 @@ gaim_signals_uninit()
- * Marshallers
- **************************************************************************/
- void
--gaim_marshal_VOID(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_VOID(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- ((void (*)(void *))cb)(data);
- }
-
- void
--gaim_marshal_VOID__INT(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_VOID__INT(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- gint arg1 = va_arg(args, gint);
-@@ -611,7 +611,7 @@ gaim_marshal_VOID__INT(GaimCallback cb,
- }
-
- void
--gaim_marshal_VOID__INT_INT(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_VOID__INT_INT(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- gint arg1 = va_arg(args, gint);
-@@ -621,7 +621,7 @@ gaim_marshal_VOID__INT_INT(GaimCallback
- }
-
- void
--gaim_marshal_VOID__POINTER(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_VOID__POINTER(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -630,7 +630,7 @@ gaim_marshal_VOID__POINTER(GaimCallback
- }
-
- void
--gaim_marshal_VOID__POINTER_UINT(GaimCallback cb, va_list args,
-+gaim2_marshal_VOID__POINTER_UINT(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -639,7 +639,7 @@ gaim_marshal_VOID__POINTER_UINT(GaimCall
- ((void (*)(void *, guint, void *))cb)(arg1, arg2, data);
- }
-
--void gaim_marshal_VOID__POINTER_INT_INT(GaimCallback cb, va_list args,
-+void gaim2_marshal_VOID__POINTER_INT_INT(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -650,7 +650,7 @@ void gaim_marshal_VOID__POINTER_INT_INT(
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER(GaimCallback cb, va_list args,
-+gaim2_marshal_VOID__POINTER_POINTER(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -660,7 +660,7 @@ gaim_marshal_VOID__POINTER_POINTER(GaimC
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_UINT(GaimCallback cb, va_list args,
-+gaim2_marshal_VOID__POINTER_POINTER_UINT(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -671,7 +671,7 @@ gaim_marshal_VOID__POINTER_POINTER_UINT(
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_UINT_UINT(GaimCallback cb, va_list args,
-+gaim2_marshal_VOID__POINTER_POINTER_UINT_UINT(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -683,7 +683,7 @@ gaim_marshal_VOID__POINTER_POINTER_UINT_
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_POINTER(GaimCallback cb, va_list args,
-+gaim2_marshal_VOID__POINTER_POINTER_POINTER(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- void *arg1 = va_arg(args, void *);
-@@ -694,7 +694,7 @@ gaim_marshal_VOID__POINTER_POINTER_POINT
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER(GaimCallback cb,
-+gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -708,7 +708,7 @@ gaim_marshal_VOID__POINTER_POINTER_POINT
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER(GaimCallback cb,
-+gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -723,7 +723,7 @@ gaim_marshal_VOID__POINTER_POINTER_POINT
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT(GaimCallback cb,
-+gaim2_marshal_VOID__POINTER_POINTER_POINTER_UINT(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -737,7 +737,7 @@ gaim_marshal_VOID__POINTER_POINTER_POINT
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT(GaimCallback cb,
-+gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -752,7 +752,7 @@ gaim_marshal_VOID__POINTER_POINTER_POINT
- }
-
- void
--gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT(GaimCallback cb,
-+gaim2_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -768,7 +768,7 @@ gaim_marshal_VOID__POINTER_POINTER_POINT
- }
-
- void
--gaim_marshal_INT__INT(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_INT__INT(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- gint ret_val;
-@@ -781,7 +781,7 @@ gaim_marshal_INT__INT(GaimCallback cb, v
- }
-
- void
--gaim_marshal_INT__INT_INT(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_INT__INT_INT(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- gint ret_val;
-@@ -796,8 +796,8 @@ gaim_marshal_INT__INT_INT(GaimCallback c
-
-
- void
--gaim_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val)
-+gaim2_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val)
- {
- gint ret_val;
- void *arg1 = va_arg(args, void *);
-@@ -815,7 +815,7 @@ gaim_marshal_INT__POINTER_POINTER_POINTE
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_BOOLEAN__POINTER(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- gboolean ret_val;
-@@ -828,7 +828,7 @@ gaim_marshal_BOOLEAN__POINTER(GaimCallba
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER_POINTER(GaimCallback cb, va_list args,
-+gaim2_marshal_BOOLEAN__POINTER_POINTER(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- gboolean ret_val;
-@@ -842,7 +842,7 @@ gaim_marshal_BOOLEAN__POINTER_POINTER(Ga
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER(GaimCallback cb, va_list args,
-+gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER(Gaim2Callback cb, va_list args,
- void *data, void **return_val)
- {
- gboolean ret_val;
-@@ -858,7 +858,7 @@ gaim_marshal_BOOLEAN__POINTER_POINTER_PO
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER_POINTER_UINT(GaimCallback cb,
-+gaim2_marshal_BOOLEAN__POINTER_POINTER_UINT(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -876,7 +876,7 @@ gaim_marshal_BOOLEAN__POINTER_POINTER_UI
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT(GaimCallback cb,
-+gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -895,7 +895,7 @@ gaim_marshal_BOOLEAN__POINTER_POINTER_PO
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER(GaimCallback cb,
-+gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER(Gaim2Callback cb,
- va_list args,
- void *data,
- void **return_val)
-@@ -914,8 +914,8 @@ gaim_marshal_BOOLEAN__POINTER_POINTER_PO
- }
-
- void
--gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val)
-+gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val)
- {
- gboolean ret_val;
- void *arg1 = va_arg(args, void *);
-@@ -933,7 +933,7 @@ gaim_marshal_BOOLEAN__POINTER_POINTER_PO
- }
-
- void
--gaim_marshal_BOOLEAN__INT_POINTER(GaimCallback cb, va_list args, void *data,
-+gaim2_marshal_BOOLEAN__INT_POINTER(Gaim2Callback cb, va_list args, void *data,
- void **return_val)
- {
- gboolean ret_val;
-diff -prNu ./src/signals.h ./src/signals.h
---- ./src/signals.h 2005-12-04 19:19:52.000000000 +0100
-+++ ./src/signals.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file signals.h Signal API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,10 +28,10 @@
- #include <glib.h>
- #include "value.h"
-
--#define GAIM_CALLBACK(func) ((GaimCallback)func)
-+#define GAIM_CALLBACK(func) ((Gaim2Callback)func)
-
--typedef void (*GaimCallback)(void);
--typedef void (*GaimSignalMarshalFunc)(GaimCallback cb, va_list args,
-+typedef void (*Gaim2Callback)(void);
-+typedef void (*Gaim2SignalMarshalFunc)(Gaim2Callback cb, va_list args,
- void *data, void **return_val);
-
- #ifdef __cplusplus
-@@ -63,11 +63,11 @@ extern "C" {
- * @return The signal ID local to that instance, or 0 if the signal
- * couldn't be registered.
- *
-- * @see GaimValue
-+ * @see Gaim2Value
- */
--gulong gaim_signal_register(void *instance, const char *signal,
-- GaimSignalMarshalFunc marshal,
-- GaimValue *ret_value, int num_values, ...);
-+gulong gaim2_signal_register(void *instance, const char *signal,
-+ Gaim2SignalMarshalFunc marshal,
-+ Gaim2Value *ret_value, int num_values, ...);
-
- /**
- * Unregisters a signal in an instance.
-@@ -75,14 +75,14 @@ gulong gaim_signal_register(void *instan
- * @param instance The instance to unregister the signal for.
- * @param signal The signal name.
- */
--void gaim_signal_unregister(void *instance, const char *signal);
-+void gaim2_signal_unregister(void *instance, const char *signal);
-
- /**
- * Unregisters all signals in an instance.
- *
- * @param instance The instance to unregister the signal for.
- */
--void gaim_signals_unregister_by_instance(void *instance);
-+void gaim2_signals_unregister_by_instance(void *instance);
-
- /**
- * Returns a list of value types used for a signal.
-@@ -93,14 +93,14 @@ void gaim_signals_unregister_by_instance
- * @param num_values The returned number of values.
- * @param values The returned list of values.
- */
--void gaim_signal_get_values(void *instance, const char *signal,
-- GaimValue **ret_value,
-- int *num_values, GaimValue ***values);
-+void gaim2_signal_get_values(void *instance, const char *signal,
-+ Gaim2Value **ret_value,
-+ int *num_values, Gaim2Value ***values);
-
- /**
- * Connects a signal handler to a signal for a particular object.
- *
-- * Take care not to register a handler function twice. Gaim will
-+ * Take care not to register a handler function twice. Gaim2 will
- * not correct any mistakes for you in this area.
- *
- * @param instance The instance to connect to.
-@@ -113,16 +113,16 @@ void gaim_signal_get_values(void *instan
- *
- * @return The signal handler ID.
- *
-- * @see gaim_signal_disconnect()
-+ * @see gaim2_signal_disconnect()
- */
--gulong gaim_signal_connect_priority(void *instance, const char *signal,
-- void *handle, GaimCallback func, void *data, int priority);
-+gulong gaim2_signal_connect_priority(void *instance, const char *signal,
-+ void *handle, Gaim2Callback func, void *data, int priority);
-
- /**
- * Connects a signal handler to a signal for a particular object.
- * (priority defaults to 0)
- *
-- * Take care not to register a handler function twice. Gaim will
-+ * Take care not to register a handler function twice. Gaim2 will
- * not correct any mistakes for you in this area.
- *
- * @param instance The instance to connect to.
-@@ -133,10 +133,10 @@ gulong gaim_signal_connect_priority(void
- *
- * @return The signal handler ID.
- *
-- * @see gaim_signal_disconnect()
-+ * @see gaim2_signal_disconnect()
- */
--gulong gaim_signal_connect(void *instance, const char *signal,
-- void *handle, GaimCallback func, void *data);
-+gulong gaim2_signal_connect(void *instance, const char *signal,
-+ void *handle, Gaim2Callback func, void *data);
-
- /**
- * Connects a signal handler to a signal for a particular object.
-@@ -144,7 +144,7 @@ gulong gaim_signal_connect(void *instanc
- * The signal handler will take a va_args of arguments, instead of
- * individual arguments.
- *
-- * Take care not to register a handler function twice. Gaim will
-+ * Take care not to register a handler function twice. Gaim2 will
- * not correct any mistakes for you in this area.
- *
- * @param instance The instance to connect to.
-@@ -156,10 +156,10 @@ gulong gaim_signal_connect(void *instanc
- *
- * @return The signal handler ID.
- *
-- * @see gaim_signal_disconnect()
-+ * @see gaim2_signal_disconnect()
- */
--gulong gaim_signal_connect_priority_vargs(void *instance, const char *signal,
-- void *handle, GaimCallback func, void *data, int priority);
-+gulong gaim2_signal_connect_priority_vargs(void *instance, const char *signal,
-+ void *handle, Gaim2Callback func, void *data, int priority);
-
- /**
- * Connects a signal handler to a signal for a particular object.
-@@ -167,7 +167,7 @@ gulong gaim_signal_connect_priority_varg
- * The signal handler will take a va_args of arguments, instead of
- * individual arguments.
- *
-- * Take care not to register a handler function twice. Gaim will
-+ * Take care not to register a handler function twice. Gaim2 will
- * not correct any mistakes for you in this area.
- *
- * @param instance The instance to connect to.
-@@ -178,10 +178,10 @@ gulong gaim_signal_connect_priority_varg
- *
- * @return The signal handler ID.
- *
-- * @see gaim_signal_disconnect()
-+ * @see gaim2_signal_disconnect()
- */
--gulong gaim_signal_connect_vargs(void *instance, const char *signal,
-- void *handle, GaimCallback func, void *data);
-+gulong gaim2_signal_connect_vargs(void *instance, const char *signal,
-+ void *handle, Gaim2Callback func, void *data);
-
- /**
- * Disconnects a signal handler from a signal on an object.
-@@ -191,17 +191,17 @@ gulong gaim_signal_connect_vargs(void *i
- * @param handle The handle of the receiver.
- * @param func The registered function to disconnect.
- *
-- * @see gaim_signal_connect()
-+ * @see gaim2_signal_connect()
- */
--void gaim_signal_disconnect(void *instance, const char *signal,
-- void *handle, GaimCallback func);
-+void gaim2_signal_disconnect(void *instance, const char *signal,
-+ void *handle, Gaim2Callback func);
-
- /**
- * Removes all callbacks associated with a receiver handle.
- *
- * @param handle The receiver handle.
- */
--void gaim_signals_disconnect_by_handle(void *handle);
-+void gaim2_signals_disconnect_by_handle(void *handle);
-
- /**
- * Emits a signal.
-@@ -209,10 +209,10 @@ void gaim_signals_disconnect_by_handle(v
- * @param instance The instance emitting the signal.
- * @param signal The signal being emitted.
- *
-- * @see gaim_signal_connect()
-- * @see gaim_signal_disconnect()
-+ * @see gaim2_signal_connect()
-+ * @see gaim2_signal_disconnect()
- */
--void gaim_signal_emit(void *instance, const char *signal, ...);
-+void gaim2_signal_emit(void *instance, const char *signal, ...);
-
- /**
- * Emits a signal, using a va_list of arguments.
-@@ -221,10 +221,10 @@ void gaim_signal_emit(void *instance, co
- * @param signal The signal being emitted.
- * @param args The arguments list.
- *
-- * @see gaim_signal_connect()
-- * @see gaim_signal_disconnect()
-+ * @see gaim2_signal_connect()
-+ * @see gaim2_signal_disconnect()
- */
--void gaim_signal_emit_vargs(void *instance, const char *signal, va_list args);
-+void gaim2_signal_emit_vargs(void *instance, const char *signal, va_list args);
-
- /**
- * Emits a signal and returns the first non-NULL return value.
-@@ -237,7 +237,7 @@ void gaim_signal_emit_vargs(void *instan
- *
- * @return The first non-NULL return value
- */
--void *gaim_signal_emit_return_1(void *instance, const char *signal, ...);
-+void *gaim2_signal_emit_return_1(void *instance, const char *signal, ...);
-
- /**
- * Emits a signal and returns the first non-NULL return value.
-@@ -251,18 +251,18 @@ void *gaim_signal_emit_return_1(void *in
- *
- * @return The first non-NULL return value
- */
--void *gaim_signal_emit_vargs_return_1(void *instance, const char *signal,
-+void *gaim2_signal_emit_vargs_return_1(void *instance, const char *signal,
- va_list args);
-
- /**
- * Initializes the signals subsystem.
- */
--void gaim_signals_init(void);
-+void gaim2_signals_init(void);
-
- /**
- * Uninitializes the signals subsystem.
- */
--void gaim_signals_uninit(void);
-+void gaim2_signals_uninit(void);
-
- /*@}*/
-
-@@ -271,61 +271,61 @@ void gaim_signals_uninit(void);
- /**************************************************************************/
- /*@{*/
-
--void gaim_marshal_VOID(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__INT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__INT_INT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_INT_INT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_UINT_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--
--void gaim_marshal_INT__INT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_INT__INT_INT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--
--void gaim_marshal_BOOLEAN__POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_BOOLEAN__POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_BOOLEAN__POINTER_POINTER_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
--void gaim_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__INT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__INT_INT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_INT_INT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_UINT_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_POINTER_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_POINTER_POINTER_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_VOID__POINTER_POINTER_POINTER_UINT_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+
-+void gaim2_marshal_INT__INT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_INT__INT_INT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_INT__POINTER_POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+
-+void gaim2_marshal_BOOLEAN__POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__POINTER_POINTER_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_UINT(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__POINTER_POINTER_POINTER_POINTER_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-
--void gaim_marshal_BOOLEAN__INT_POINTER(
-- GaimCallback cb, va_list args, void *data, void **return_val);
-+void gaim2_marshal_BOOLEAN__INT_POINTER(
-+ Gaim2Callback cb, va_list args, void *data, void **return_val);
-
- /*@}*/
-
-diff -prNu ./src/socket.c ./src/socket.c
---- ./src/socket.c 2004-12-05 22:05:52.000000000 +0100
-+++ ./src/socket.c 2006-01-05 15:11:07.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim-remote
-+ * gaim2-remote
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,16 +23,16 @@
-
- /* Somewhat inspired by XMMS*/
-
--/* This provides code for connecting to a Gaim socket and communicating with
-+/* This provides code for connecting to a Gaim2 socket and communicating with
- * it. It will eventually be made a library once the core and ui are split. */
-
- #include <sys/types.h>
- #include <sys/socket.h>
- #include <sys/un.h>
- #include <unistd.h>
--#include "gaim-socket.h"
-+#include "gaim2-socket.h"
-
--void cui_send_packet (int fd, struct gaim_cui_packet *p) {
-+void cui_send_packet (int fd, struct gaim2_cui_packet *p) {
- int len = sizeof(p->type) + sizeof(p->subtype) + sizeof(p->length) + p->length;
- char *pack = g_malloc(len);
- char *a = pack;
-@@ -48,7 +48,7 @@ void cui_send_packet (int fd, struct gai
- }
-
-
--void cui_packet_append_string(struct gaim_cui_packet *p, char *str) {
-+void cui_packet_append_string(struct gaim2_cui_packet *p, char *str) {
- int len = p->length + strlen(str);
- char *k = g_malloc(len);
- memcpy(k, p->data, p->length);
-@@ -59,7 +59,7 @@ void cui_packet_append_string(struct gai
- p->length = len;
- }
-
--void cui_packet_append_char(struct gaim_cui_packet *p, char c) {
-+void cui_packet_append_char(struct gaim2_cui_packet *p, char c) {
- int len = p->length + sizeof(char);
- char *k = g_malloc(len);
- memcpy(k, p->data, p->length);
-@@ -70,7 +70,7 @@ void cui_packet_append_char(struct gaim_
- p->length = len;
- }
-
--void cui_packet_append_raw(struct gaim_cui_packet *p, char *str, int len) {
-+void cui_packet_append_raw(struct gaim2_cui_packet *p, char *str, int len) {
- int lent = p->length + len;
- char *k = g_malloc(lent);
- memcpy(k, p->data, p->length);
-@@ -81,8 +81,8 @@ void cui_packet_append_raw(struct gaim_c
- p->length = lent;
- }
-
--struct gaim_cui_packet *cui_packet_new(guchar type, guchar subtype) {
-- struct gaim_cui_packet *p = g_new0(struct gaim_cui_packet, 1);
-+struct gaim2_cui_packet *cui_packet_new(guchar type, guchar subtype) {
-+ struct gaim2_cui_packet *p = g_new0(struct gaim2_cui_packet, 1);
- p->type = type;
- p->subtype = subtype;
- p->length = 0;
-@@ -90,14 +90,14 @@ struct gaim_cui_packet *cui_packet_new(g
- return p;
- }
-
--void cui_packet_free(struct gaim_cui_packet *p) {
-+void cui_packet_free(struct gaim2_cui_packet *p) {
- if (p->data)
- g_free(p->data);
- g_free(p);
- }
-
--struct gaim_cui_packet *cui_read_packet(int fd) {
-- struct gaim_cui_packet *p = g_new0(struct gaim_cui_packet, 1);
-+struct gaim2_cui_packet *cui_read_packet(int fd) {
-+ struct gaim2_cui_packet *p = g_new0(struct gaim2_cui_packet, 1);
- char *data = NULL;
-
- if (!(read(fd, &p->type, sizeof(p->type)))) {
-@@ -129,7 +129,7 @@ struct gaim_cui_packet *cui_read_packet(
- }
-
- /* copied directly from xmms_connect_to_session */
--gint gaim_connect_to_session(gint session)
-+gint gaim2_connect_to_session(gint session)
- {
- gint fd;
- uid_t stored_uid, euid;
-@@ -141,7 +141,7 @@ gint gaim_connect_to_session(gint sessio
- stored_uid = getuid();
- euid = geteuid();
- setuid(euid);
-- sprintf(saddr.sun_path, "%s/gaim_%s.%d", g_get_tmp_dir(), g_get_user_name(), session);
-+ sprintf(saddr.sun_path, "%s/gaim2_%s.%d", g_get_tmp_dir(), g_get_user_name(), session);
- setreuid(stored_uid, euid);
- if (connect(fd, (struct sockaddr *) &saddr, sizeof (saddr)) != -1)
- return fd;
-@@ -150,11 +150,11 @@ gint gaim_connect_to_session(gint sessio
- return -1;
- }
-
--gboolean gaim_session_exists(int sess)
-+gboolean gaim2_session_exists(int sess)
- {
-- struct gaim_cui_packet *pack = NULL;
-+ struct gaim2_cui_packet *pack = NULL;
-
-- int fd = gaim_connect_to_session(sess);
-+ int fd = gaim2_connect_to_session(sess);
- if (fd > 0) {
- pack = cui_packet_new(CUI_TYPE_META, CUI_META_PING);
- cui_send_packet(fd, pack);
-diff -prNu ./src/sound.c ./src/sound.c
---- ./src/sound.c 2005-12-02 07:43:00.000000000 +0100
-+++ ./src/sound.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -26,17 +26,17 @@
- #include "prefs.h"
- #include "sound.h"
-
--static GaimSoundUiOps *sound_ui_ops = NULL;
-+static Gaim2SoundUiOps *sound_ui_ops = NULL;
-
- void
--gaim_sound_play_file(const char *filename, const GaimAccount *account)
-+gaim2_sound_play_file(const char *filename, const Gaim2Account *account)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
-- if ((account != NULL) && (!gaim_prefs_get_bool("/core/sound/while_away")))
-+ if ((account != NULL) && (!gaim2_prefs_get_bool("/core/sound/while_away")))
- {
-- status = gaim_account_get_active_status(account);
-- if (gaim_status_is_online(status) && !gaim_status_is_available(status))
-+ status = gaim2_account_get_active_status(account);
-+ if (gaim2_status_is_online(status) && !gaim2_status_is_available(status))
- return;
- }
-
-@@ -45,24 +45,24 @@ gaim_sound_play_file(const char *filenam
- }
-
- void
--gaim_sound_play_event(GaimSoundEventID event, const GaimAccount *account)
-+gaim2_sound_play_event(Gaim2SoundEventID event, const Gaim2Account *account)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- if ((account != NULL) &&
-- (!gaim_prefs_get_bool("/core/sound/while_away")))
-+ (!gaim2_prefs_get_bool("/core/sound/while_away")))
- {
-- status = gaim_account_get_active_status(account);
-- if (gaim_status_is_online(status) &&
-- !gaim_status_is_available(status))
-+ status = gaim2_account_get_active_status(account);
-+ if (gaim2_status_is_online(status) &&
-+ !gaim2_status_is_available(status))
- return;
- }
-
- if(sound_ui_ops && sound_ui_ops->play_event) {
- int plugin_return;
-
-- plugin_return = GPOINTER_TO_INT(gaim_signal_emit_return_1(
-- gaim_sounds_get_handle(), "playing-sound-event",
-+ plugin_return = GPOINTER_TO_INT(gaim2_signal_emit_return_1(
-+ gaim2_sounds_get_handle(), "playing-sound-event",
- event, account));
-
- if (plugin_return)
-@@ -73,7 +73,7 @@ gaim_sound_play_event(GaimSoundEventID e
- }
-
- void
--gaim_sound_set_ui_ops(GaimSoundUiOps *ops)
-+gaim2_sound_set_ui_ops(Gaim2SoundUiOps *ops)
- {
- if(sound_ui_ops && sound_ui_ops->uninit)
- sound_ui_ops->uninit();
-@@ -84,43 +84,43 @@ gaim_sound_set_ui_ops(GaimSoundUiOps *op
- sound_ui_ops->init();
- }
-
--GaimSoundUiOps *
--gaim_sound_get_ui_ops(void)
-+Gaim2SoundUiOps *
-+gaim2_sound_get_ui_ops(void)
- {
- return sound_ui_ops;
- }
-
- void
--gaim_sound_init()
-+gaim2_sound_init()
- {
-- void *handle = gaim_sounds_get_handle();
-+ void *handle = gaim2_sounds_get_handle();
-
- /**********************************************************************
- * Register signals
- **********************************************************************/
-
-- gaim_signal_register(handle, "playing-sound-event",
-- gaim_marshal_BOOLEAN__INT_POINTER,
-- gaim_value_new(GAIM_TYPE_BOOLEAN), 2,
-- gaim_value_new(GAIM_TYPE_INT),
-- gaim_value_new(GAIM_TYPE_POINTER));
-+ gaim2_signal_register(handle, "playing-sound-event",
-+ gaim2_marshal_BOOLEAN__INT_POINTER,
-+ gaim2_value_new(GAIM_TYPE_BOOLEAN), 2,
-+ gaim2_value_new(GAIM_TYPE_INT),
-+ gaim2_value_new(GAIM_TYPE_POINTER));
-
-- gaim_prefs_add_none("/core/sound");
-- gaim_prefs_add_bool("/core/sound/while_away", FALSE);
-+ gaim2_prefs_add_none("/core/sound");
-+ gaim2_prefs_add_bool("/core/sound/while_away", FALSE);
-
- }
-
- void
--gaim_sound_uninit()
-+gaim2_sound_uninit()
- {
- if(sound_ui_ops && sound_ui_ops->uninit)
- sound_ui_ops->uninit();
-
-- gaim_signals_unregister_by_instance(gaim_sounds_get_handle());
-+ gaim2_signals_unregister_by_instance(gaim2_sounds_get_handle());
- }
-
- void *
--gaim_sounds_get_handle()
-+gaim2_sounds_get_handle()
- {
- static int handle;
-
-diff -prNu ./src/sound.h ./src/sound.h
---- ./src/sound.h 2005-12-02 07:43:00.000000000 +0100
-+++ ./src/sound.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file sound.h Sound API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -36,7 +36,7 @@
- * A type of sound.
- */
-
--typedef enum _GaimSoundEventID
-+typedef enum _Gaim2SoundEventID
- {
- GAIM_SOUND_BUDDY_ARRIVE = 0, /**< Buddy signs on. */
- GAIM_SOUND_BUDDY_LEAVE, /**< Buddy signs off. */
-@@ -51,16 +51,16 @@ typedef enum _GaimSoundEventID
- GAIM_SOUND_CHAT_NICK, /**< Someone says your name in a chat. */
- GAIM_NUM_SOUNDS /**< Total number of sounds. */
-
--} GaimSoundEventID;
-+} Gaim2SoundEventID;
-
--typedef struct _GaimSoundUiOps
-+typedef struct _Gaim2SoundUiOps
- {
- void (*init)(void);
- void (*uninit)(void);
- void (*play_file)(const char *filename);
-- void (*play_event)(GaimSoundEventID event);
-+ void (*play_event)(Gaim2SoundEventID event);
-
--} GaimSoundUiOps;
-+} Gaim2SoundUiOps;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -80,7 +80,7 @@ extern "C" {
- * account. This is needed for the "sounds while away?"
- * preference to work correctly.
- */
--void gaim_sound_play_file(const char *filename, const GaimAccount *account);
-+void gaim2_sound_play_file(const char *filename, const Gaim2Account *account);
-
- /**
- * Plays the sound associated with the specified event.
-@@ -91,38 +91,38 @@ void gaim_sound_play_file(const char *fi
- * account. This is needed for the "sounds while away?"
- * preference to work correctly.
- */
--void gaim_sound_play_event(GaimSoundEventID event, const GaimAccount *account);
-+void gaim2_sound_play_event(Gaim2SoundEventID event, const Gaim2Account *account);
-
- /**
- * Sets the UI sound operations
- *
- * @param ops The UI sound operations structure.
- */
--void gaim_sound_set_ui_ops(GaimSoundUiOps *ops);
-+void gaim2_sound_set_ui_ops(Gaim2SoundUiOps *ops);
-
- /**
- * Gets the UI sound operations
- *
- * @return The UI sound operations structure.
- */
--GaimSoundUiOps *gaim_sound_get_ui_ops(void);
-+Gaim2SoundUiOps *gaim2_sound_get_ui_ops(void);
-
- /**
- * Initializes the sound subsystem
- */
--void gaim_sound_init(void);
-+void gaim2_sound_init(void);
-
- /**
- * Shuts down the sound subsystem
- */
--void gaim_sound_uninit(void);
-+void gaim2_sound_uninit(void);
-
- /**
- * Returns the sound subsystem handle.
- *
- * @return The sound subsystem handle.
- */
--void *gaim_sounds_get_handle(void);
-+void *gaim2_sounds_get_handle(void);
-
- /*@}*/
-
-diff -prNu ./src/sslconn.c ./src/sslconn.c
---- ./src/sslconn.c 2004-01-10 05:04:56.000000000 +0100
-+++ ./src/sslconn.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file sslconn.c SSL API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,23 +28,23 @@
- #include "sslconn.h"
-
- static gboolean _ssl_initialized = FALSE;
--static GaimSslOps *_ssl_ops = NULL;
-+static Gaim2SslOps *_ssl_ops = NULL;
-
- static gboolean
- ssl_init(void)
- {
-- GaimPlugin *plugin;
-- GaimSslOps *ops;
-+ Gaim2Plugin *plugin;
-+ Gaim2SslOps *ops;
-
- if (_ssl_initialized)
- return FALSE;
-
-- plugin = gaim_plugins_find_with_id("core-ssl");
-+ plugin = gaim2_plugins_find_with_id("core-ssl");
-
-- if (plugin != NULL && !gaim_plugin_is_loaded(plugin))
-- gaim_plugin_load(plugin);
-+ if (plugin != NULL && !gaim2_plugin_is_loaded(plugin))
-+ gaim2_plugin_load(plugin);
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
- if (ops != NULL && ops->init != NULL)
- return ops->init();
- else
-@@ -52,31 +52,31 @@ ssl_init(void)
- }
-
- gboolean
--gaim_ssl_is_supported(void)
-+gaim2_ssl_is_supported(void)
- {
- #ifdef HAVE_SSL
- ssl_init();
-- return (gaim_ssl_get_ops() != NULL);
-+ return (gaim2_ssl_get_ops() != NULL);
- #else
- return FALSE;
- #endif
- }
-
--GaimSslConnection *
--gaim_ssl_connect(GaimAccount *account, const char *host, int port,
-- GaimSslInputFunction func, GaimSslErrorFunction error_func,
-+Gaim2SslConnection *
-+gaim2_ssl_connect(Gaim2Account *account, const char *host, int port,
-+ Gaim2SslInputFunction func, Gaim2SslErrorFunction error_func,
- void *data)
- {
-- GaimSslConnection *gsc;
-- GaimSslOps *ops;
-+ Gaim2SslConnection *gsc;
-+ Gaim2SslOps *ops;
- int i;
-
- g_return_val_if_fail(host != NULL, NULL);
- g_return_val_if_fail(port != 0 && port != -1, NULL);
- g_return_val_if_fail(func != NULL, NULL);
-- g_return_val_if_fail(gaim_ssl_is_supported(), NULL);
-+ g_return_val_if_fail(gaim2_ssl_is_supported(), NULL);
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- g_return_val_if_fail(ops != NULL, NULL);
- g_return_val_if_fail(ops->connect_cb != NULL, NULL);
-@@ -87,7 +87,7 @@ gaim_ssl_connect(GaimAccount *account, c
- return NULL;
- }
-
-- gsc = g_new0(GaimSslConnection, 1);
-+ gsc = g_new0(Gaim2SslConnection, 1);
-
- gsc->host = g_strdup(host);
- gsc->port = port;
-@@ -95,7 +95,7 @@ gaim_ssl_connect(GaimAccount *account, c
- gsc->connect_cb = func;
- gsc->error_cb = error_func;
-
-- i = gaim_proxy_connect(account, host, port, ops->connect_cb, gsc);
-+ i = gaim2_proxy_connect(account, host, port, ops->connect_cb, gsc);
-
- if (i < 0)
- {
-@@ -105,47 +105,47 @@ gaim_ssl_connect(GaimAccount *account, c
- return NULL;
- }
-
-- return (GaimSslConnection *)gsc;
-+ return (Gaim2SslConnection *)gsc;
- }
-
- static void
--recv_cb(gpointer data, gint source, GaimInputCondition cond)
-+recv_cb(gpointer data, gint source, Gaim2InputCondition cond)
- {
-- GaimSslConnection *gsc = data;
-+ Gaim2SslConnection *gsc = data;
-
- gsc->recv_cb(gsc->recv_cb_data, gsc, cond);
- }
-
- void
--gaim_ssl_input_add(GaimSslConnection *gsc, GaimSslInputFunction func,
-+gaim2_ssl_input_add(Gaim2SslConnection *gsc, Gaim2SslInputFunction func,
- void *data)
- {
-- GaimSslOps *ops;
-+ Gaim2SslOps *ops;
-
- g_return_if_fail(func != NULL);
-- g_return_if_fail(gaim_ssl_is_supported());
-+ g_return_if_fail(gaim2_ssl_is_supported());
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- gsc->recv_cb_data = data;
- gsc->recv_cb = func;
-
-- gsc->inpa = gaim_input_add(gsc->fd, GAIM_INPUT_READ, recv_cb, gsc);
-+ gsc->inpa = gaim2_input_add(gsc->fd, GAIM_INPUT_READ, recv_cb, gsc);
- }
-
--GaimSslConnection *
--gaim_ssl_connect_fd(GaimAccount *account, int fd,
-- GaimSslInputFunction func,
-- GaimSslErrorFunction error_func, void *data)
-+Gaim2SslConnection *
-+gaim2_ssl_connect_fd(Gaim2Account *account, int fd,
-+ Gaim2SslInputFunction func,
-+ Gaim2SslErrorFunction error_func, void *data)
- {
-- GaimSslConnection *gsc;
-- GaimSslOps *ops;
-+ Gaim2SslConnection *gsc;
-+ Gaim2SslOps *ops;
-
- g_return_val_if_fail(fd > 0, NULL);
- g_return_val_if_fail(func != NULL, NULL);
-- g_return_val_if_fail(gaim_ssl_is_supported(), NULL);
-+ g_return_val_if_fail(gaim2_ssl_is_supported(), NULL);
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- g_return_val_if_fail(ops != NULL, NULL);
- g_return_val_if_fail(ops->connect_cb != NULL, NULL);
-@@ -156,7 +156,7 @@ gaim_ssl_connect_fd(GaimAccount *account
- return NULL;
- }
-
-- gsc = g_new0(GaimSslConnection, 1);
-+ gsc = g_new0(Gaim2SslConnection, 1);
-
- gsc->connect_cb_data = data;
- gsc->connect_cb = func;
-@@ -164,20 +164,20 @@ gaim_ssl_connect_fd(GaimAccount *account
-
- ops->connect_cb(gsc, fd, GAIM_INPUT_READ);
-
-- return (GaimSslConnection *)gsc;
-+ return (Gaim2SslConnection *)gsc;
- }
-
- void
--gaim_ssl_close(GaimSslConnection *gsc)
-+gaim2_ssl_close(Gaim2SslConnection *gsc)
- {
-- GaimSslOps *ops;
-+ Gaim2SslOps *ops;
-
- g_return_if_fail(gsc != NULL);
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- if (gsc->inpa)
-- gaim_input_remove(gsc->inpa);
-+ gaim2_input_remove(gsc->inpa);
-
- if (ops != NULL && ops->close != NULL)
- (ops->close)(gsc);
-@@ -192,15 +192,15 @@ gaim_ssl_close(GaimSslConnection *gsc)
- }
-
- size_t
--gaim_ssl_read(GaimSslConnection *gsc, void *data, size_t len)
-+gaim2_ssl_read(Gaim2SslConnection *gsc, void *data, size_t len)
- {
-- GaimSslOps *ops;
-+ Gaim2SslOps *ops;
-
- g_return_val_if_fail(gsc != NULL, 0);
- g_return_val_if_fail(data != NULL, 0);
- g_return_val_if_fail(len > 0, 0);
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- if (ops != NULL && (ops->read) != NULL)
- return (ops->read)(gsc, data, len);
-@@ -209,15 +209,15 @@ gaim_ssl_read(GaimSslConnection *gsc, vo
- }
-
- size_t
--gaim_ssl_write(GaimSslConnection *gsc, const void *data, size_t len)
-+gaim2_ssl_write(Gaim2SslConnection *gsc, const void *data, size_t len)
- {
-- GaimSslOps *ops;
-+ Gaim2SslOps *ops;
-
- g_return_val_if_fail(gsc != NULL, 0);
- g_return_val_if_fail(data != NULL, 0);
- g_return_val_if_fail(len > 0, 0);
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- if (ops != NULL && (ops->write) != NULL)
- return (ops->write)(gsc, data, len);
-@@ -226,31 +226,31 @@ gaim_ssl_write(GaimSslConnection *gsc, c
- }
-
- void
--gaim_ssl_set_ops(GaimSslOps *ops)
-+gaim2_ssl_set_ops(Gaim2SslOps *ops)
- {
- _ssl_ops = ops;
- }
-
--GaimSslOps *
--gaim_ssl_get_ops(void)
-+Gaim2SslOps *
-+gaim2_ssl_get_ops(void)
- {
- return _ssl_ops;
- }
-
- void
--gaim_ssl_init(void)
-+gaim2_ssl_init(void)
- {
- }
-
- void
--gaim_ssl_uninit(void)
-+gaim2_ssl_uninit(void)
- {
-- GaimSslOps *ops;
-+ Gaim2SslOps *ops;
-
- if (!_ssl_initialized)
- return;
-
-- ops = gaim_ssl_get_ops();
-+ ops = gaim2_ssl_get_ops();
-
- if (ops != NULL && ops->uninit != NULL)
- ops->uninit();
-diff -prNu ./src/sslconn.h ./src/sslconn.h
---- ./src/sslconn.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/sslconn.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file sslconn.h SSL API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,24 +33,24 @@ typedef enum
- {
- GAIM_SSL_HANDSHAKE_FAILED = 1,
- GAIM_SSL_CONNECT_FAILED = 2
--} GaimSslErrorType;
-+} Gaim2SslErrorType;
-
--typedef struct _GaimSslConnection GaimSslConnection;
-+typedef struct _Gaim2SslConnection Gaim2SslConnection;
-
--typedef void (*GaimSslInputFunction)(gpointer, GaimSslConnection *,
-- GaimInputCondition);
--typedef void (*GaimSslErrorFunction)(GaimSslConnection *, GaimSslErrorType,
-+typedef void (*Gaim2SslInputFunction)(gpointer, Gaim2SslConnection *,
-+ Gaim2InputCondition);
-+typedef void (*Gaim2SslErrorFunction)(Gaim2SslConnection *, Gaim2SslErrorType,
- gpointer);
-
--struct _GaimSslConnection
-+struct _Gaim2SslConnection
- {
- char *host;
- int port;
- void *connect_cb_data;
-- GaimSslInputFunction connect_cb;
-- GaimSslErrorFunction error_cb;
-+ Gaim2SslInputFunction connect_cb;
-+ Gaim2SslErrorFunction error_cb;
- void *recv_cb_data;
-- GaimSslInputFunction recv_cb;
-+ Gaim2SslInputFunction recv_cb;
-
- int fd;
- int inpa;
-@@ -67,12 +67,12 @@ typedef struct
- {
- gboolean (*init)(void);
- void (*uninit)(void);
-- GaimInputFunction connect_cb;
-- void (*close)(GaimSslConnection *gsc);
-- size_t (*read)(GaimSslConnection *gsc, void *data, size_t len);
-- size_t (*write)(GaimSslConnection *gsc, const void *data, size_t len);
-+ Gaim2InputFunction connect_cb;
-+ void (*close)(Gaim2SslConnection *gsc);
-+ size_t (*read)(Gaim2SslConnection *gsc, void *data, size_t len);
-+ size_t (*write)(Gaim2SslConnection *gsc, const void *data, size_t len);
-
--} GaimSslOps;
-+} Gaim2SslOps;
-
- #ifdef __cplusplus
- extern "C" {
-@@ -88,7 +88,7 @@ extern "C" {
- *
- * @return TRUE if SSL is supported, or FALSE otherwise.
- */
--gboolean gaim_ssl_is_supported(void);
-+gboolean gaim2_ssl_is_supported(void);
-
- /**
- * Makes a SSL connection to the specified host and port.
-@@ -102,9 +102,9 @@ gboolean gaim_ssl_is_supported(void);
- *
- * @return The SSL connection handle.
- */
--GaimSslConnection *gaim_ssl_connect(GaimAccount *account, const char *host,
-- int port, GaimSslInputFunction func,
-- GaimSslErrorFunction error_func,
-+Gaim2SslConnection *gaim2_ssl_connect(Gaim2Account *account, const char *host,
-+ int port, Gaim2SslInputFunction func,
-+ Gaim2SslErrorFunction error_func,
- void *data);
-
- /**
-@@ -118,9 +118,9 @@ GaimSslConnection *gaim_ssl_connect(Gaim
- *
- * @return The SSL connection handle.
- */
--GaimSslConnection *gaim_ssl_connect_fd(GaimAccount *account, int fd,
-- GaimSslInputFunction func,
-- GaimSslErrorFunction error_func,
-+Gaim2SslConnection *gaim2_ssl_connect_fd(Gaim2Account *account, int fd,
-+ Gaim2SslInputFunction func,
-+ Gaim2SslErrorFunction error_func,
- void *data);
-
- /**
-@@ -130,7 +130,7 @@ GaimSslConnection *gaim_ssl_connect_fd(G
- * @param func The callback function.
- * @param data User-defined data.
- */
--void gaim_ssl_input_add(GaimSslConnection *gsc, GaimSslInputFunction func,
-+void gaim2_ssl_input_add(Gaim2SslConnection *gsc, Gaim2SslInputFunction func,
- void *data);
-
- /**
-@@ -138,7 +138,7 @@ void gaim_ssl_input_add(GaimSslConnectio
- *
- * @param gsc The SSL connection to close.
- */
--void gaim_ssl_close(GaimSslConnection *gsc);
-+void gaim2_ssl_close(Gaim2SslConnection *gsc);
-
- /**
- * Reads data from an SSL connection.
-@@ -149,7 +149,7 @@ void gaim_ssl_close(GaimSslConnection *g
- *
- * @return The number of bytes read.
- */
--size_t gaim_ssl_read(GaimSslConnection *gsc, void *buffer, size_t len);
-+size_t gaim2_ssl_read(Gaim2SslConnection *gsc, void *buffer, size_t len);
-
- /**
- * Writes data to an SSL connection.
-@@ -160,7 +160,7 @@ size_t gaim_ssl_read(GaimSslConnection *
- *
- * @return The number of bytes written.
- */
--size_t gaim_ssl_write(GaimSslConnection *gsc, const void *buffer, size_t len);
-+size_t gaim2_ssl_write(Gaim2SslConnection *gsc, const void *buffer, size_t len);
-
- /*@}*/
-
-@@ -174,24 +174,24 @@ size_t gaim_ssl_write(GaimSslConnection
- *
- * @param ops The SSL operations structure to assign.
- */
--void gaim_ssl_set_ops(GaimSslOps *ops);
-+void gaim2_ssl_set_ops(Gaim2SslOps *ops);
-
- /**
- * Returns the current SSL operations structure.
- *
- * @return The SSL operations structure.
- */
--GaimSslOps *gaim_ssl_get_ops(void);
-+Gaim2SslOps *gaim2_ssl_get_ops(void);
-
- /**
- * Initializes the SSL subsystem.
- */
--void gaim_ssl_init(void);
-+void gaim2_ssl_init(void);
-
- /**
- * Uninitializes the SSL subsystem.
- */
--void gaim_ssl_uninit(void);
-+void gaim2_ssl_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/status.c ./src/status.c
---- ./src/status.c 2005-12-29 01:44:11.000000000 +0100
-+++ ./src/status.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file status.c Status API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -35,9 +35,9 @@
- /**
- * A type of status.
- */
--struct _GaimStatusType
-+struct _Gaim2StatusType
- {
-- GaimStatusPrimitive primitive;
-+ Gaim2StatusPrimitive primitive;
-
- char *id;
- char *name;
-@@ -53,19 +53,19 @@ struct _GaimStatusType
- /**
- * A status attribute.
- */
--struct _GaimStatusAttr
-+struct _Gaim2StatusAttr
- {
- char *id;
- char *name;
-- GaimValue *value_type;
-+ Gaim2Value *value_type;
- };
-
- /**
- * A list of statuses.
- */
--struct _GaimPresence
-+struct _Gaim2Presence
- {
-- GaimPresenceContext context;
-+ Gaim2PresenceContext context;
-
- gboolean idle;
- time_t idle_time;
-@@ -74,22 +74,22 @@ struct _GaimPresence
- GList *statuses;
- GHashTable *status_table;
-
-- GaimStatus *active_status;
-+ Gaim2Status *active_status;
-
- union
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
-
- struct
- {
-- GaimConversation *conv;
-+ Gaim2Conversation *conv;
- char *user;
-
- } chat;
-
- struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *name;
- size_t ref_count;
- GList *buddies;
-@@ -102,10 +102,10 @@ struct _GaimPresence
- /**
- * An active status.
- */
--struct _GaimStatus
-+struct _Gaim2Status
- {
-- GaimStatusType *type;
-- GaimPresence *presence;
-+ Gaim2StatusType *type;
-+ Gaim2Presence *presence;
-
- const char *title;
-
-@@ -116,9 +116,9 @@ struct _GaimStatus
-
- typedef struct
- {
-- GaimAccount *account;
-+ Gaim2Account *account;
- char *name;
--} GaimStatusBuddyKey;
-+} Gaim2StatusBuddyKey;
-
- static int primitive_scores[] =
- {
-@@ -140,11 +140,11 @@ static GHashTable *buddy_presences = NUL
- #define SCORE_IDLE_TIME 8
-
- /**************************************************************************
-- * GaimStatusPrimitive API
-+ * Gaim2StatusPrimitive API
- **************************************************************************/
--static struct GaimStatusPrimitiveMap
-+static struct Gaim2StatusPrimitiveMap
- {
-- GaimStatusPrimitive type;
-+ Gaim2StatusPrimitive type;
- const char *id;
- const char *name;
-
-@@ -161,7 +161,7 @@ static struct GaimStatusPrimitiveMap
- };
-
- const char *
--gaim_primitive_get_id_from_type(GaimStatusPrimitive type)
-+gaim2_primitive_get_id_from_type(Gaim2StatusPrimitive type)
- {
- int i;
-
-@@ -175,7 +175,7 @@ gaim_primitive_get_id_from_type(GaimStat
- }
-
- const char *
--gaim_primitive_get_name_from_type(GaimStatusPrimitive type)
-+gaim2_primitive_get_name_from_type(Gaim2StatusPrimitive type)
- {
- int i;
-
-@@ -188,8 +188,8 @@ gaim_primitive_get_name_from_type(GaimSt
- return status_primitive_map[0].name;
- }
-
--GaimStatusPrimitive
--gaim_primitive_get_type_from_id(const char *id)
-+Gaim2StatusPrimitive
-+gaim2_primitive_get_type_from_id(const char *id)
- {
- int i;
-
-@@ -206,19 +206,19 @@ gaim_primitive_get_type_from_id(const ch
-
-
- /**************************************************************************
-- * GaimStatusType API
-+ * Gaim2StatusType API
- **************************************************************************/
--GaimStatusType *
--gaim_status_type_new_full(GaimStatusPrimitive primitive, const char *id,
-+Gaim2StatusType *
-+gaim2_status_type_new_full(Gaim2StatusPrimitive primitive, const char *id,
- const char *name, gboolean saveable,
- gboolean user_settable, gboolean independent)
- {
-- GaimStatusType *status_type;
-+ Gaim2StatusType *status_type;
-
- g_return_val_if_fail(primitive != GAIM_STATUS_UNSET, NULL);
-
-- status_type = g_new0(GaimStatusType, 1);
-- GAIM_DBUS_REGISTER_POINTER(status_type, GaimStatusType);
-+ status_type = g_new0(Gaim2StatusType, 1);
-+ GAIM_DBUS_REGISTER_POINTER(status_type, Gaim2StatusType);
-
- status_type->primitive = primitive;
- status_type->saveable = saveable;
-@@ -228,35 +228,35 @@ gaim_status_type_new_full(GaimStatusPrim
- if (id != NULL)
- status_type->id = g_strdup(id);
- else
-- status_type->id = g_strdup(gaim_primitive_get_id_from_type(primitive));
-+ status_type->id = g_strdup(gaim2_primitive_get_id_from_type(primitive));
-
- if (name != NULL)
- status_type->name = g_strdup(name);
- else
-- status_type->name = g_strdup(_(gaim_primitive_get_name_from_type(primitive)));
-+ status_type->name = g_strdup(_(gaim2_primitive_get_name_from_type(primitive)));
-
- return status_type;
- }
-
--GaimStatusType *
--gaim_status_type_new(GaimStatusPrimitive primitive, const char *id,
-+Gaim2StatusType *
-+gaim2_status_type_new(Gaim2StatusPrimitive primitive, const char *id,
- const char *name, gboolean user_settable)
- {
- g_return_val_if_fail(primitive != GAIM_STATUS_UNSET, NULL);
-
-- return gaim_status_type_new_full(primitive, id, name, FALSE,
-+ return gaim2_status_type_new_full(primitive, id, name, FALSE,
- user_settable, FALSE);
- }
-
--GaimStatusType *
--gaim_status_type_new_with_attrs(GaimStatusPrimitive primitive,
-+Gaim2StatusType *
-+gaim2_status_type_new_with_attrs(Gaim2StatusPrimitive primitive,
- const char *id, const char *name,
- gboolean saveable, gboolean user_settable,
- gboolean independent, const char *attr_id,
-- const char *attr_name, GaimValue *attr_value,
-+ const char *attr_name, Gaim2Value *attr_value,
- ...)
- {
-- GaimStatusType *status_type;
-+ Gaim2StatusType *status_type;
- va_list args;
-
- g_return_val_if_fail(primitive != GAIM_STATUS_UNSET, NULL);
-@@ -264,21 +264,21 @@ gaim_status_type_new_with_attrs(GaimStat
- g_return_val_if_fail(attr_name != NULL, NULL);
- g_return_val_if_fail(attr_value != NULL, NULL);
-
-- status_type = gaim_status_type_new_full(primitive, id, name, saveable,
-+ status_type = gaim2_status_type_new_full(primitive, id, name, saveable,
- user_settable, independent);
-
- /* Add the first attribute */
-- gaim_status_type_add_attr(status_type, attr_id, attr_name, attr_value);
-+ gaim2_status_type_add_attr(status_type, attr_id, attr_name, attr_value);
-
- va_start(args, attr_value);
-- gaim_status_type_add_attrs_vargs(status_type, args);
-+ gaim2_status_type_add_attrs_vargs(status_type, args);
- va_end(args);
-
- return status_type;
- }
-
- void
--gaim_status_type_destroy(GaimStatusType *status_type)
-+gaim2_status_type_destroy(Gaim2StatusType *status_type)
- {
- GList *l;
-
-@@ -293,7 +293,7 @@ gaim_status_type_destroy(GaimStatusType
- if (status_type->attrs != NULL)
- {
- for (l = status_type->attrs; l != NULL; l = l->next)
-- gaim_status_attr_destroy((GaimStatusAttr *)l->data);
-+ gaim2_status_attr_destroy((Gaim2StatusAttr *)l->data);
-
- g_list_free(status_type->attrs);
- }
-@@ -303,7 +303,7 @@ gaim_status_type_destroy(GaimStatusType
- }
-
- void
--gaim_status_type_set_primary_attr(GaimStatusType *status_type, const char *id)
-+gaim2_status_type_set_primary_attr(Gaim2StatusType *status_type, const char *id)
- {
- g_return_if_fail(status_type != NULL);
-
-@@ -314,26 +314,26 @@ gaim_status_type_set_primary_attr(GaimSt
- }
-
- void
--gaim_status_type_add_attr(GaimStatusType *status_type, const char *id,
-- const char *name, GaimValue *value)
-+gaim2_status_type_add_attr(Gaim2StatusType *status_type, const char *id,
-+ const char *name, Gaim2Value *value)
- {
-- GaimStatusAttr *attr;
-+ Gaim2StatusAttr *attr;
-
- g_return_if_fail(status_type != NULL);
- g_return_if_fail(id != NULL);
- g_return_if_fail(name != NULL);
- g_return_if_fail(value != NULL);
-
-- attr = gaim_status_attr_new(id, name, value);
-+ attr = gaim2_status_attr_new(id, name, value);
-
- status_type->attrs = g_list_append(status_type->attrs, attr);
- }
-
- void
--gaim_status_type_add_attrs_vargs(GaimStatusType *status_type, va_list args)
-+gaim2_status_type_add_attrs_vargs(Gaim2StatusType *status_type, va_list args)
- {
- const char *id, *name;
-- GaimValue *value;
-+ Gaim2Value *value;
-
- g_return_if_fail(status_type != NULL);
-
-@@ -342,16 +342,16 @@ gaim_status_type_add_attrs_vargs(GaimSta
- name = va_arg(args, const char *);
- g_return_if_fail(name != NULL);
-
-- value = va_arg(args, GaimValue *);
-+ value = va_arg(args, Gaim2Value *);
- g_return_if_fail(value != NULL);
-
-- gaim_status_type_add_attr(status_type, id, name, value);
-+ gaim2_status_type_add_attr(status_type, id, name, value);
- }
- }
-
- void
--gaim_status_type_add_attrs(GaimStatusType *status_type, const char *id,
-- const char *name, GaimValue *value, ...)
-+gaim2_status_type_add_attrs(Gaim2StatusType *status_type, const char *id,
-+ const char *name, Gaim2Value *value, ...)
- {
- va_list args;
-
-@@ -361,15 +361,15 @@ gaim_status_type_add_attrs(GaimStatusTyp
- g_return_if_fail(value != NULL);
-
- /* Add the first attribute */
-- gaim_status_type_add_attr(status_type, id, name, value);
-+ gaim2_status_type_add_attr(status_type, id, name, value);
-
- va_start(args, value);
-- gaim_status_type_add_attrs_vargs(status_type, args);
-+ gaim2_status_type_add_attrs_vargs(status_type, args);
- va_end(args);
- }
-
--GaimStatusPrimitive
--gaim_status_type_get_primitive(const GaimStatusType *status_type)
-+Gaim2StatusPrimitive
-+gaim2_status_type_get_primitive(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, GAIM_STATUS_UNSET);
-
-@@ -377,7 +377,7 @@ gaim_status_type_get_primitive(const Gai
- }
-
- const char *
--gaim_status_type_get_id(const GaimStatusType *status_type)
-+gaim2_status_type_get_id(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, NULL);
-
-@@ -385,7 +385,7 @@ gaim_status_type_get_id(const GaimStatus
- }
-
- const char *
--gaim_status_type_get_name(const GaimStatusType *status_type)
-+gaim2_status_type_get_name(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, NULL);
-
-@@ -393,7 +393,7 @@ gaim_status_type_get_name(const GaimStat
- }
-
- gboolean
--gaim_status_type_is_saveable(const GaimStatusType *status_type)
-+gaim2_status_type_is_saveable(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, FALSE);
-
-@@ -401,7 +401,7 @@ gaim_status_type_is_saveable(const GaimS
- }
-
- gboolean
--gaim_status_type_is_user_settable(const GaimStatusType *status_type)
-+gaim2_status_type_is_user_settable(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, FALSE);
-
-@@ -409,7 +409,7 @@ gaim_status_type_is_user_settable(const
- }
-
- gboolean
--gaim_status_type_is_independent(const GaimStatusType *status_type)
-+gaim2_status_type_is_independent(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, FALSE);
-
-@@ -417,7 +417,7 @@ gaim_status_type_is_independent(const Ga
- }
-
- gboolean
--gaim_status_type_is_exclusive(const GaimStatusType *status_type)
-+gaim2_status_type_is_exclusive(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, FALSE);
-
-@@ -425,27 +425,27 @@ gaim_status_type_is_exclusive(const Gaim
- }
-
- gboolean
--gaim_status_type_is_available(const GaimStatusType *status_type)
-+gaim2_status_type_is_available(const Gaim2StatusType *status_type)
- {
-- GaimStatusPrimitive primitive;
-+ Gaim2StatusPrimitive primitive;
-
- g_return_val_if_fail(status_type != NULL, FALSE);
-
-- primitive = gaim_status_type_get_primitive(status_type);
-+ primitive = gaim2_status_type_get_primitive(status_type);
-
- return (primitive == GAIM_STATUS_AVAILABLE);
- }
-
- const char *
--gaim_status_type_get_primary_attr(const GaimStatusType *status_type)
-+gaim2_status_type_get_primary_attr(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, NULL);
-
- return status_type->primary_attr_id;
- }
-
--GaimStatusAttr *
--gaim_status_type_get_attr(const GaimStatusType *status_type, const char *id)
-+Gaim2StatusAttr *
-+gaim2_status_type_get_attr(const Gaim2StatusType *status_type, const char *id)
- {
- GList *l;
-
-@@ -454,9 +454,9 @@ gaim_status_type_get_attr(const GaimStat
-
- for (l = status_type->attrs; l != NULL; l = l->next)
- {
-- GaimStatusAttr *attr = (GaimStatusAttr *)l->data;
-+ Gaim2StatusAttr *attr = (Gaim2StatusAttr *)l->data;
-
-- if (!strcmp(gaim_status_attr_get_id(attr), id))
-+ if (!strcmp(gaim2_status_attr_get_id(attr), id))
- return attr;
- }
-
-@@ -464,17 +464,17 @@ gaim_status_type_get_attr(const GaimStat
- }
-
- const GList *
--gaim_status_type_get_attrs(const GaimStatusType *status_type)
-+gaim2_status_type_get_attrs(const Gaim2StatusType *status_type)
- {
- g_return_val_if_fail(status_type != NULL, NULL);
-
- return status_type->attrs;
- }
-
--const GaimStatusType *
--gaim_status_type_find_with_id(GList *status_types, const char *id)
-+const Gaim2StatusType *
-+gaim2_status_type_find_with_id(GList *status_types, const char *id)
- {
-- GaimStatusType *status_type;
-+ Gaim2StatusType *status_type;
-
- g_return_val_if_fail(id != NULL, NULL);
-
-@@ -493,19 +493,19 @@ gaim_status_type_find_with_id(GList *sta
-
-
- /**************************************************************************
--* GaimStatusAttr API
-+* Gaim2StatusAttr API
- **************************************************************************/
--GaimStatusAttr *
--gaim_status_attr_new(const char *id, const char *name, GaimValue *value_type)
-+Gaim2StatusAttr *
-+gaim2_status_attr_new(const char *id, const char *name, Gaim2Value *value_type)
- {
-- GaimStatusAttr *attr;
-+ Gaim2StatusAttr *attr;
-
- g_return_val_if_fail(id != NULL, NULL);
- g_return_val_if_fail(name != NULL, NULL);
- g_return_val_if_fail(value_type != NULL, NULL);
-
-- attr = g_new0(GaimStatusAttr, 1);
-- GAIM_DBUS_REGISTER_POINTER(attr, GaimStatusAttr);
-+ attr = g_new0(Gaim2StatusAttr, 1);
-+ GAIM_DBUS_REGISTER_POINTER(attr, Gaim2StatusAttr);
-
- attr->id = g_strdup(id);
- attr->name = g_strdup(name);
-@@ -515,21 +515,21 @@ gaim_status_attr_new(const char *id, con
- }
-
- void
--gaim_status_attr_destroy(GaimStatusAttr *attr)
-+gaim2_status_attr_destroy(Gaim2StatusAttr *attr)
- {
- g_return_if_fail(attr != NULL);
-
- g_free(attr->id);
- g_free(attr->name);
-
-- gaim_value_destroy(attr->value_type);
-+ gaim2_value_destroy(attr->value_type);
-
- GAIM_DBUS_UNREGISTER_POINTER(attr);
- g_free(attr);
- }
-
- const char *
--gaim_status_attr_get_id(const GaimStatusAttr *attr)
-+gaim2_status_attr_get_id(const Gaim2StatusAttr *attr)
- {
- g_return_val_if_fail(attr != NULL, NULL);
-
-@@ -537,15 +537,15 @@ gaim_status_attr_get_id(const GaimStatus
- }
-
- const char *
--gaim_status_attr_get_name(const GaimStatusAttr *attr)
-+gaim2_status_attr_get_name(const Gaim2StatusAttr *attr)
- {
- g_return_val_if_fail(attr != NULL, NULL);
-
- return attr->name;
- }
-
--GaimValue *
--gaim_status_attr_get_value(const GaimStatusAttr *attr)
-+Gaim2Value *
-+gaim2_status_attr_get_value(const Gaim2StatusAttr *attr)
- {
- g_return_val_if_fail(attr != NULL, NULL);
-
-@@ -554,35 +554,35 @@ gaim_status_attr_get_value(const GaimSta
-
-
- /**************************************************************************
--* GaimStatus API
-+* Gaim2Status API
- **************************************************************************/
--GaimStatus *
--gaim_status_new(GaimStatusType *status_type, GaimPresence *presence)
-+Gaim2Status *
-+gaim2_status_new(Gaim2StatusType *status_type, Gaim2Presence *presence)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
- const GList *l;
-
- g_return_val_if_fail(status_type != NULL, NULL);
- g_return_val_if_fail(presence != NULL, NULL);
-
-- status = g_new0(GaimStatus, 1);
-- GAIM_DBUS_REGISTER_POINTER(status, GaimStatus);
-+ status = g_new0(Gaim2Status, 1);
-+ GAIM_DBUS_REGISTER_POINTER(status, Gaim2Status);
-
- status->type = status_type;
- status->presence = presence;
-
- status->attr_values =
- g_hash_table_new_full(g_str_hash, g_str_equal, g_free,
-- (GDestroyNotify)gaim_value_destroy);
-+ (GDestroyNotify)gaim2_value_destroy);
-
-- for (l = gaim_status_type_get_attrs(status_type); l != NULL; l = l->next)
-+ for (l = gaim2_status_type_get_attrs(status_type); l != NULL; l = l->next)
- {
-- GaimStatusAttr *attr = (GaimStatusAttr *)l->data;
-- GaimValue *value = gaim_status_attr_get_value(attr);
-- GaimValue *new_value = gaim_value_dup(value);
-+ Gaim2StatusAttr *attr = (Gaim2StatusAttr *)l->data;
-+ Gaim2Value *value = gaim2_status_attr_get_value(attr);
-+ Gaim2Value *new_value = gaim2_value_dup(value);
-
- g_hash_table_insert(status->attr_values,
-- g_strdup(gaim_status_attr_get_id(attr)),
-+ g_strdup(gaim2_status_attr_get_id(attr)),
- new_value);
- }
-
-@@ -590,11 +590,11 @@ gaim_status_new(GaimStatusType *status_t
- }
-
- /*
-- * TODO: If the GaimStatus is in a GaimPresence, then
-- * remove it from the GaimPresence?
-+ * TODO: If the Gaim2Status is in a Gaim2Presence, then
-+ * remove it from the Gaim2Presence?
- */
- void
--gaim_status_destroy(GaimStatus *status)
-+gaim2_status_destroy(Gaim2Status *status)
- {
- g_return_if_fail(status != NULL);
-
-@@ -605,35 +605,35 @@ gaim_status_destroy(GaimStatus *status)
- }
-
- static void
--notify_buddy_status_update(GaimBuddy *buddy, GaimPresence *presence,
-- GaimStatus *old_status, GaimStatus *new_status)
-+notify_buddy_status_update(Gaim2Buddy *buddy, Gaim2Presence *presence,
-+ Gaim2Status *old_status, Gaim2Status *new_status)
- {
-- GaimBlistUiOps *ops = gaim_blist_get_ui_ops();
-+ Gaim2BlistUiOps *ops = gaim2_blist_get_ui_ops();
-
-- if (gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_system"))
- {
- time_t current_time = time(NULL);
-- const char *buddy_alias = gaim_buddy_get_alias(buddy);
-+ const char *buddy_alias = gaim2_buddy_get_alias(buddy);
- char *tmp = NULL;
-
-- if (gaim_status_is_available(new_status))
-+ if (gaim2_status_is_available(new_status))
- {
-- if (((old_status == NULL) || !gaim_status_is_online(old_status)))
-+ if (((old_status == NULL) || !gaim2_status_is_online(old_status)))
- {
- tmp = g_strdup_printf(_("%s signed on"), buddy_alias);
- }
-- else if (!gaim_status_is_available(old_status))
-+ else if (!gaim2_status_is_available(old_status))
- {
- tmp = g_strdup_printf(_("%s came back"), buddy_alias);
- }
- }
-- else if ((old_status != NULL) && gaim_status_is_available(old_status))
-+ else if ((old_status != NULL) && gaim2_status_is_available(old_status))
- {
-- if (!gaim_status_is_online(new_status))
-+ if (!gaim2_status_is_online(new_status))
- {
- tmp = g_strdup_printf(_("%s signed off"), buddy_alias);
- }
-- else if (!gaim_status_is_available(new_status))
-+ else if (!gaim2_status_is_available(new_status))
- {
- tmp = g_strdup_printf(_("%s went away"), buddy_alias);
- }
-@@ -641,31 +641,31 @@ notify_buddy_status_update(GaimBuddy *bu
-
- if (tmp != NULL)
- {
-- GaimLog *log = gaim_account_get_log(buddy->account);
-+ Gaim2Log *log = gaim2_account_get_log(buddy->account);
-
-- gaim_log_write(log, GAIM_MESSAGE_SYSTEM, buddy_alias,
-+ gaim2_log_write(log, GAIM_MESSAGE_SYSTEM, buddy_alias,
- current_time, tmp);
- g_free(tmp);
- }
- }
-
- if (ops != NULL && ops->update != NULL)
-- ops->update(gaim_get_blist(), (GaimBlistNode*)buddy);
-+ ops->update(gaim2_get_blist(), (Gaim2BlistNode*)buddy);
- }
-
- static void
--notify_status_update(GaimPresence *presence, GaimStatus *old_status,
-- GaimStatus *new_status)
-+notify_status_update(Gaim2Presence *presence, Gaim2Status *old_status,
-+ Gaim2Status *new_status)
- {
-- GaimPresenceContext context = gaim_presence_get_context(presence);
-+ Gaim2PresenceContext context = gaim2_presence_get_context(presence);
-
- if (context == GAIM_PRESENCE_CONTEXT_ACCOUNT)
- {
-- GaimAccount *account = gaim_presence_get_account(presence);
-- GaimAccountUiOps *ops = gaim_accounts_get_ui_ops();
-+ Gaim2Account *account = gaim2_presence_get_account(presence);
-+ Gaim2AccountUiOps *ops = gaim2_accounts_get_ui_ops();
-
-- if (gaim_account_get_enabled(account, gaim_core_get_ui()))
-- gaim_prpl_change_account_status(account, old_status, new_status);
-+ if (gaim2_account_get_enabled(account, gaim2_core_get_ui()))
-+ gaim2_prpl_change_account_status(account, old_status, new_status);
-
- if (ops != NULL && ops->status_changed != NULL)
- {
-@@ -676,30 +676,30 @@ notify_status_update(GaimPresence *prese
- {
- const GList *l;
-
-- for (l = gaim_presence_get_buddies(presence); l != NULL; l = l->next)
-+ for (l = gaim2_presence_get_buddies(presence); l != NULL; l = l->next)
- {
-- notify_buddy_status_update((GaimBuddy *)l->data, presence,
-+ notify_buddy_status_update((Gaim2Buddy *)l->data, presence,
- old_status, new_status);
- }
- }
- }
-
- static void
--status_has_changed(GaimStatus *status)
-+status_has_changed(Gaim2Status *status)
- {
-- GaimPresence *presence;
-- GaimStatus *old_status;
-+ Gaim2Presence *presence;
-+ Gaim2Status *old_status;
-
-- presence = gaim_status_get_presence(status);
-+ presence = gaim2_status_get_presence(status);
-
- /*
- * If this status is exclusive, then we must be setting it to "active."
- * Since we are setting it to active, we want to set the currently
- * active status to "inactive."
- */
-- if (gaim_status_is_exclusive(status))
-+ if (gaim2_status_is_exclusive(status))
- {
-- old_status = gaim_presence_get_active_status(presence);
-+ old_status = gaim2_presence_get_active_status(presence);
- if (old_status != NULL && (old_status != status))
- old_status->active = FALSE;
- presence->active_status = status;
-@@ -711,19 +711,19 @@ status_has_changed(GaimStatus *status)
- }
-
- void
--gaim_status_set_active(GaimStatus *status, gboolean active)
-+gaim2_status_set_active(Gaim2Status *status, gboolean active)
- {
-- gaim_status_set_active_with_attrs(status, active, NULL);
-+ gaim2_status_set_active_with_attrs(status, active, NULL);
- }
-
- /*
- * This used to parse the va_list directly, but now it creates a GList
-- * and passes it to gaim_status_set_active_with_attrs_list(). That
-+ * and passes it to gaim2_status_set_active_with_attrs_list(). That
- * function was created because accounts.c needs to pass a GList of
- * attributes to the status API.
- */
- void
--gaim_status_set_active_with_attrs(GaimStatus *status, gboolean active, va_list args)
-+gaim2_status_set_active_with_attrs(Gaim2Status *status, gboolean active, va_list args)
- {
- GList *attrs = NULL;
- const gchar *id;
-@@ -738,12 +738,12 @@ gaim_status_set_active_with_attrs(GaimSt
- attrs = g_list_append(attrs, data);
- }
- }
-- gaim_status_set_active_with_attrs_list(status, active, attrs);
-+ gaim2_status_set_active_with_attrs_list(status, active, attrs);
- g_list_free(attrs);
- }
-
- void
--gaim_status_set_active_with_attrs_list(GaimStatus *status, gboolean active,
-+gaim2_status_set_active_with_attrs_list(Gaim2Status *status, gboolean active,
- const GList *attrs)
- {
- gboolean changed = FALSE;
-@@ -751,11 +751,11 @@ gaim_status_set_active_with_attrs_list(G
-
- g_return_if_fail(status != NULL);
-
-- if (!active && gaim_status_is_exclusive(status))
-+ if (!active && gaim2_status_is_exclusive(status))
- {
-- gaim_debug_error("status",
-+ gaim2_debug_error("status",
- "Cannot deactivate an exclusive status (%s).\n",
-- gaim_status_get_id(status));
-+ gaim2_status_get_id(status));
- return;
- }
-
-@@ -769,14 +769,14 @@ gaim_status_set_active_with_attrs_list(G
- /* Set any attributes */
- while (attrs)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
-
- id = attrs->data;
- attrs = attrs->next;
-- value = gaim_status_get_attr_value(status, id);
-+ value = gaim2_status_get_attr_value(status, id);
- if (value == NULL)
- {
-- gaim_debug_warning("status", "The attribute \"%s\" on the status \"%s\" is "
-+ gaim2_debug_warning("status", "The attribute \"%s\" on the status \"%s\" is "
- "not supported.\n", id, status->type->name);
- /* Skip over the data and move on to the next attribute */
- attrs = attrs->next;
-@@ -793,7 +793,7 @@ gaim_status_set_active_with_attrs_list(G
- {
- continue;
- }
-- gaim_status_set_attr_string(status, id, string_data);
-+ gaim2_status_set_attr_string(status, id, string_data);
- changed = TRUE;
- }
- else if (value->type == GAIM_TYPE_INT)
-@@ -802,7 +802,7 @@ gaim_status_set_active_with_attrs_list(G
- attrs = attrs->next;
- if (int_data == value->data.int_data)
- continue;
-- gaim_status_set_attr_int(status, id, int_data);
-+ gaim2_status_set_attr_int(status, id, int_data);
- changed = TRUE;
- }
- else if (value->type == GAIM_TYPE_BOOLEAN)
-@@ -811,7 +811,7 @@ gaim_status_set_active_with_attrs_list(G
- attrs = attrs->next;
- if (boolean_data == value->data.boolean_data)
- continue;
-- gaim_status_set_attr_int(status, id, boolean_data);
-+ gaim2_status_set_attr_int(status, id, boolean_data);
- changed = TRUE;
- }
- else
-@@ -827,85 +827,85 @@ gaim_status_set_active_with_attrs_list(G
- }
-
- void
--gaim_status_set_attr_boolean(GaimStatus *status, const char *id,
-+gaim2_status_set_attr_boolean(Gaim2Status *status, const char *id,
- gboolean value)
- {
-- GaimStatusType *status_type;
-- GaimValue *attr_value;
-+ Gaim2StatusType *status_type;
-+ Gaim2Value *attr_value;
-
- g_return_if_fail(status != NULL);
- g_return_if_fail(id != NULL);
-
-- status_type = gaim_status_get_type(status);
-+ status_type = gaim2_status_get_type(status);
-
- /* Make sure this attribute exists and is the correct type. */
-- attr_value = gaim_status_get_attr_value(status, id);
-+ attr_value = gaim2_status_get_attr_value(status, id);
- g_return_if_fail(attr_value != NULL);
-- g_return_if_fail(gaim_value_get_type(attr_value) == GAIM_TYPE_BOOLEAN);
-+ g_return_if_fail(gaim2_value_get_type(attr_value) == GAIM_TYPE_BOOLEAN);
-
-- gaim_value_set_boolean(attr_value, value);
-+ gaim2_value_set_boolean(attr_value, value);
- }
-
- void
--gaim_status_set_attr_int(GaimStatus *status, const char *id, int value)
-+gaim2_status_set_attr_int(Gaim2Status *status, const char *id, int value)
- {
-- GaimStatusType *status_type;
-- GaimValue *attr_value;
-+ Gaim2StatusType *status_type;
-+ Gaim2Value *attr_value;
-
- g_return_if_fail(status != NULL);
- g_return_if_fail(id != NULL);
-
-- status_type = gaim_status_get_type(status);
-+ status_type = gaim2_status_get_type(status);
-
- /* Make sure this attribute exists and is the correct type. */
-- attr_value = gaim_status_get_attr_value(status, id);
-+ attr_value = gaim2_status_get_attr_value(status, id);
- g_return_if_fail(attr_value != NULL);
-- g_return_if_fail(gaim_value_get_type(attr_value) == GAIM_TYPE_INT);
-+ g_return_if_fail(gaim2_value_get_type(attr_value) == GAIM_TYPE_INT);
-
-- gaim_value_set_int(attr_value, value);
-+ gaim2_value_set_int(attr_value, value);
- }
-
- void
--gaim_status_set_attr_string(GaimStatus *status, const char *id,
-+gaim2_status_set_attr_string(Gaim2Status *status, const char *id,
- const char *value)
- {
-- GaimStatusType *status_type;
-- GaimValue *attr_value;
-+ Gaim2StatusType *status_type;
-+ Gaim2Value *attr_value;
-
- g_return_if_fail(status != NULL);
- g_return_if_fail(id != NULL);
-
-- status_type = gaim_status_get_type(status);
-+ status_type = gaim2_status_get_type(status);
-
- /* Make sure this attribute exists and is the correct type. */
-- attr_value = gaim_status_get_attr_value(status, id);
-+ attr_value = gaim2_status_get_attr_value(status, id);
- /* This used to be g_return_if_fail, but it's failing a LOT, so
- * let's generate a log error for now. */
- /* g_return_if_fail(attr_value != NULL); */
- if (attr_value == NULL) {
-- gaim_debug_error("status",
-+ gaim2_debug_error("status",
- "Attempted to set status attribute '%s' for "
- "status '%s', which is not legal. Fix "
- "this!\n", id,
-- gaim_status_type_get_name(gaim_status_get_type(status)));
-+ gaim2_status_type_get_name(gaim2_status_get_type(status)));
- return;
-
- }
-- g_return_if_fail(gaim_value_get_type(attr_value) == GAIM_TYPE_STRING);
-+ g_return_if_fail(gaim2_value_get_type(attr_value) == GAIM_TYPE_STRING);
-
-- gaim_value_set_string(attr_value, value);
-+ gaim2_value_set_string(attr_value, value);
- }
-
--GaimStatusType *
--gaim_status_get_type(const GaimStatus *status)
-+Gaim2StatusType *
-+gaim2_status_get_type(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, NULL);
-
- return status->type;
- }
-
--GaimPresence *
--gaim_status_get_presence(const GaimStatus *status)
-+Gaim2Presence *
-+gaim2_status_get_presence(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, NULL);
-
-@@ -913,47 +913,47 @@ gaim_status_get_presence(const GaimStatu
- }
-
- const char *
--gaim_status_get_id(const GaimStatus *status)
-+gaim2_status_get_id(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, NULL);
-
-- return gaim_status_type_get_id(gaim_status_get_type(status));
-+ return gaim2_status_type_get_id(gaim2_status_get_type(status));
- }
-
- const char *
--gaim_status_get_name(const GaimStatus *status)
-+gaim2_status_get_name(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, NULL);
-
-- return gaim_status_type_get_name(gaim_status_get_type(status));
-+ return gaim2_status_type_get_name(gaim2_status_get_type(status));
- }
-
- gboolean
--gaim_status_is_independent(const GaimStatus *status)
-+gaim2_status_is_independent(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, FALSE);
-
-- return gaim_status_type_is_independent(gaim_status_get_type(status));
-+ return gaim2_status_type_is_independent(gaim2_status_get_type(status));
- }
-
- gboolean
--gaim_status_is_exclusive(const GaimStatus *status)
-+gaim2_status_is_exclusive(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, FALSE);
-
-- return gaim_status_type_is_exclusive(gaim_status_get_type(status));
-+ return gaim2_status_type_is_exclusive(gaim2_status_get_type(status));
- }
-
- gboolean
--gaim_status_is_available(const GaimStatus *status)
-+gaim2_status_is_available(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, FALSE);
-
-- return gaim_status_type_is_available(gaim_status_get_type(status));
-+ return gaim2_status_type_is_available(gaim2_status_get_type(status));
- }
-
- gboolean
--gaim_status_is_active(const GaimStatus *status)
-+gaim2_status_is_active(const Gaim2Status *status)
- {
- g_return_val_if_fail(status != NULL, FALSE);
-
-@@ -961,79 +961,79 @@ gaim_status_is_active(const GaimStatus *
- }
-
- gboolean
--gaim_status_is_online(const GaimStatus *status)
-+gaim2_status_is_online(const Gaim2Status *status)
- {
-- GaimStatusPrimitive primitive;
-+ Gaim2StatusPrimitive primitive;
-
- g_return_val_if_fail( status != NULL, FALSE);
-
-- primitive = gaim_status_type_get_primitive(gaim_status_get_type(status));
-+ primitive = gaim2_status_type_get_primitive(gaim2_status_get_type(status));
-
- return (primitive != GAIM_STATUS_UNSET &&
- primitive != GAIM_STATUS_OFFLINE);
- }
-
--GaimValue *
--gaim_status_get_attr_value(const GaimStatus *status, const char *id)
-+Gaim2Value *
-+gaim2_status_get_attr_value(const Gaim2Status *status, const char *id)
- {
- g_return_val_if_fail(status != NULL, NULL);
- g_return_val_if_fail(id != NULL, NULL);
-
-- return (GaimValue *)g_hash_table_lookup(status->attr_values, id);
-+ return (Gaim2Value *)g_hash_table_lookup(status->attr_values, id);
- }
-
- gboolean
--gaim_status_get_attr_boolean(const GaimStatus *status, const char *id)
-+gaim2_status_get_attr_boolean(const Gaim2Status *status, const char *id)
- {
-- const GaimValue *value;
-+ const Gaim2Value *value;
-
- g_return_val_if_fail(status != NULL, FALSE);
- g_return_val_if_fail(id != NULL, FALSE);
-
-- if ((value = gaim_status_get_attr_value(status, id)) == NULL)
-+ if ((value = gaim2_status_get_attr_value(status, id)) == NULL)
- return FALSE;
-
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_BOOLEAN, FALSE);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_BOOLEAN, FALSE);
-
-- return gaim_value_get_boolean(value);
-+ return gaim2_value_get_boolean(value);
- }
-
- int
--gaim_status_get_attr_int(const GaimStatus *status, const char *id)
-+gaim2_status_get_attr_int(const Gaim2Status *status, const char *id)
- {
-- const GaimValue *value;
-+ const Gaim2Value *value;
-
- g_return_val_if_fail(status != NULL, 0);
- g_return_val_if_fail(id != NULL, 0);
-
-- if ((value = gaim_status_get_attr_value(status, id)) == NULL)
-+ if ((value = gaim2_status_get_attr_value(status, id)) == NULL)
- return 0;
-
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_INT, 0);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_INT, 0);
-
-- return gaim_value_get_int(value);
-+ return gaim2_value_get_int(value);
- }
-
- const char *
--gaim_status_get_attr_string(const GaimStatus *status, const char *id)
-+gaim2_status_get_attr_string(const Gaim2Status *status, const char *id)
- {
-- const GaimValue *value;
-+ const Gaim2Value *value;
-
- g_return_val_if_fail(status != NULL, NULL);
- g_return_val_if_fail(id != NULL, NULL);
-
-- if ((value = gaim_status_get_attr_value(status, id)) == NULL)
-+ if ((value = gaim2_status_get_attr_value(status, id)) == NULL)
- return NULL;
-
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_STRING, NULL);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_STRING, NULL);
-
-- return gaim_value_get_string(value);
-+ return gaim2_value_get_string(value);
- }
-
- gint
--gaim_status_compare(const GaimStatus *status1, const GaimStatus *status2)
-+gaim2_status_compare(const Gaim2Status *status1, const Gaim2Status *status2)
- {
-- GaimStatusType *type1, *type2;
-+ Gaim2StatusType *type1, *type2;
- int score1 = 0, score2 = 0;
-
- if ((status1 == NULL && status2 == NULL) ||
-@@ -1046,14 +1046,14 @@ gaim_status_compare(const GaimStatus *st
- else if (status2 == NULL)
- return -1;
-
-- type1 = gaim_status_get_type(status1);
-- type2 = gaim_status_get_type(status2);
-+ type1 = gaim2_status_get_type(status1);
-+ type2 = gaim2_status_get_type(status2);
-
-- if (gaim_status_is_active(status1))
-- score1 = primitive_scores[gaim_status_type_get_primitive(type1)];
-+ if (gaim2_status_is_active(status1))
-+ score1 = primitive_scores[gaim2_status_type_get_primitive(type1)];
-
-- if (gaim_status_is_active(status2))
-- score2 = primitive_scores[gaim_status_type_get_primitive(type2)];
-+ if (gaim2_status_is_active(status2))
-+ score2 = primitive_scores[gaim2_status_type_get_primitive(type2)];
-
- if (score1 > score2)
- return -1;
-@@ -1065,17 +1065,17 @@ gaim_status_compare(const GaimStatus *st
-
-
- /**************************************************************************
--* GaimPresence API
-+* Gaim2Presence API
- **************************************************************************/
--GaimPresence *
--gaim_presence_new(GaimPresenceContext context)
-+Gaim2Presence *
-+gaim2_presence_new(Gaim2PresenceContext context)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
-
- g_return_val_if_fail(context != GAIM_PRESENCE_CONTEXT_UNSET, NULL);
-
-- presence = g_new0(GaimPresence, 1);
-- GAIM_DBUS_REGISTER_POINTER(presence, GaimPresence);
-+ presence = g_new0(Gaim2Presence, 1);
-+ GAIM_DBUS_REGISTER_POINTER(presence, Gaim2Presence);
-
- presence->context = context;
-
-@@ -1086,55 +1086,55 @@ gaim_presence_new(GaimPresenceContext co
- return presence;
- }
-
--GaimPresence *
--gaim_presence_new_for_account(GaimAccount *account)
-+Gaim2Presence *
-+gaim2_presence_new_for_account(Gaim2Account *account)
- {
-- GaimPresence *presence = NULL;
-+ Gaim2Presence *presence = NULL;
- g_return_val_if_fail(account != NULL, NULL);
-
-- presence = gaim_presence_new(GAIM_PRESENCE_CONTEXT_ACCOUNT);
-+ presence = gaim2_presence_new(GAIM_PRESENCE_CONTEXT_ACCOUNT);
- presence->u.account = account;
-- presence->statuses = gaim_prpl_get_statuses(account, presence);
-+ presence->statuses = gaim2_prpl_get_statuses(account, presence);
-
- return presence;
- }
-
--GaimPresence *
--gaim_presence_new_for_conv(GaimConversation *conv)
-+Gaim2Presence *
-+gaim2_presence_new_for_conv(Gaim2Conversation *conv)
- {
-- GaimPresence *presence;
-+ Gaim2Presence *presence;
-
- g_return_val_if_fail(conv != NULL, NULL);
-
-- presence = gaim_presence_new(GAIM_PRESENCE_CONTEXT_CONV);
-+ presence = gaim2_presence_new(GAIM_PRESENCE_CONTEXT_CONV);
- presence->u.chat.conv = conv;
-- /* presence->statuses = gaim_prpl_get_statuses(conv->account, presence); ? */
-+ /* presence->statuses = gaim2_prpl_get_statuses(conv->account, presence); ? */
-
- return presence;
- }
-
--GaimPresence *
--gaim_presence_new_for_buddy(GaimBuddy *buddy)
-+Gaim2Presence *
-+gaim2_presence_new_for_buddy(Gaim2Buddy *buddy)
- {
-- GaimPresence *presence;
-- GaimStatusBuddyKey *key;
-- GaimAccount *account;
-+ Gaim2Presence *presence;
-+ Gaim2StatusBuddyKey *key;
-+ Gaim2Account *account;
-
- g_return_val_if_fail(buddy != NULL, NULL);
- account = buddy->account;
-
-- key = g_new0(GaimStatusBuddyKey, 1);
-+ key = g_new0(Gaim2StatusBuddyKey, 1);
- key->account = buddy->account;
- key->name = g_strdup(buddy->name);
-
- presence = g_hash_table_lookup(buddy_presences, key);
- if (presence == NULL)
- {
-- presence = gaim_presence_new(GAIM_PRESENCE_CONTEXT_BUDDY);
-+ presence = gaim2_presence_new(GAIM_PRESENCE_CONTEXT_BUDDY);
-
- presence->u.buddy.name = g_strdup(buddy->name);
- presence->u.buddy.account = buddy->account;
-- presence->statuses = gaim_prpl_get_statuses(buddy->account, presence);
-+ presence->statuses = gaim2_prpl_get_statuses(buddy->account, presence);
-
- g_hash_table_insert(buddy_presences, key, presence);
- }
-@@ -1152,13 +1152,13 @@ gaim_presence_new_for_buddy(GaimBuddy *b
- }
-
- void
--gaim_presence_destroy(GaimPresence *presence)
-+gaim2_presence_destroy(Gaim2Presence *presence)
- {
- g_return_if_fail(presence != NULL);
-
-- if (gaim_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_BUDDY)
-+ if (gaim2_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_BUDDY)
- {
-- GaimStatusBuddyKey key;
-+ Gaim2StatusBuddyKey key;
-
- if(presence->u.buddy.ref_count != 0)
- return;
-@@ -1171,14 +1171,14 @@ gaim_presence_destroy(GaimPresence *pres
- if (presence->u.buddy.name != NULL)
- g_free(presence->u.buddy.name);
- }
-- else if (gaim_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_CONV)
-+ else if (gaim2_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_CONV)
- {
- if (presence->u.chat.user != NULL)
- g_free(presence->u.chat.user);
- }
-
- if (presence->statuses != NULL) {
-- g_list_foreach(presence->statuses, (GFunc)gaim_status_destroy, NULL);
-+ g_list_foreach(presence->statuses, (GFunc)gaim2_status_destroy, NULL);
- g_list_free(presence->statuses);
- }
-
-@@ -1189,16 +1189,16 @@ gaim_presence_destroy(GaimPresence *pres
- }
-
- /*
-- * TODO: Maybe we should cal gaim_presence_destroy() after we
-+ * TODO: Maybe we should cal gaim2_presence_destroy() after we
- * decrement the ref count? I don't see why we should
- * make other places do it manually when we can do it here.
- */
- void
--gaim_presence_remove_buddy(GaimPresence *presence, GaimBuddy *buddy)
-+gaim2_presence_remove_buddy(Gaim2Presence *presence, Gaim2Buddy *buddy)
- {
- g_return_if_fail(presence != NULL);
- g_return_if_fail(buddy != NULL);
-- g_return_if_fail(gaim_presence_get_context(presence) ==
-+ g_return_if_fail(gaim2_presence_get_context(presence) ==
- GAIM_PRESENCE_CONTEXT_BUDDY);
-
- if (g_list_find(presence->u.buddy.buddies, buddy) != NULL)
-@@ -1210,7 +1210,7 @@ gaim_presence_remove_buddy(GaimPresence
- }
-
- void
--gaim_presence_add_status(GaimPresence *presence, GaimStatus *status)
-+gaim2_presence_add_status(Gaim2Presence *presence, Gaim2Status *status)
- {
- g_return_if_fail(presence != NULL);
- g_return_if_fail(status != NULL);
-@@ -1218,11 +1218,11 @@ gaim_presence_add_status(GaimPresence *p
- presence->statuses = g_list_append(presence->statuses, status);
-
- g_hash_table_insert(presence->status_table,
-- g_strdup(gaim_status_get_id(status)), status);
-+ g_strdup(gaim2_status_get_id(status)), status);
- }
-
- void
--gaim_presence_add_list(GaimPresence *presence, const GList *source_list)
-+gaim2_presence_add_list(Gaim2Presence *presence, const GList *source_list)
- {
- const GList *l;
-
-@@ -1230,29 +1230,29 @@ gaim_presence_add_list(GaimPresence *pre
- g_return_if_fail(source_list != NULL);
-
- for (l = source_list; l != NULL; l = l->next)
-- gaim_presence_add_status(presence, (GaimStatus *)l->data);
-+ gaim2_presence_add_status(presence, (Gaim2Status *)l->data);
- }
-
- void
--gaim_presence_set_status_active(GaimPresence *presence, const char *status_id,
-+gaim2_presence_set_status_active(Gaim2Presence *presence, const char *status_id,
- gboolean active)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- g_return_if_fail(presence != NULL);
- g_return_if_fail(status_id != NULL);
-
-- status = gaim_presence_get_status(presence, status_id);
-+ status = gaim2_presence_get_status(presence, status_id);
-
- g_return_if_fail(status != NULL);
- /* TODO: Should we do the following? */
- /* g_return_if_fail(active == status->active); */
-
-- if (gaim_status_is_exclusive(status))
-+ if (gaim2_status_is_exclusive(status))
- {
- if (!active)
- {
-- gaim_debug_warning("status",
-+ gaim2_debug_warning("status",
- "Attempted to set a non-independent status "
- "(%s) inactive. Only independent statuses "
- "can be specifically marked inactive.",
-@@ -1261,76 +1261,76 @@ gaim_presence_set_status_active(GaimPres
- }
- }
-
-- gaim_status_set_active(status, active);
-+ gaim2_status_set_active(status, active);
- }
-
- void
--gaim_presence_switch_status(GaimPresence *presence, const char *status_id)
-+gaim2_presence_switch_status(Gaim2Presence *presence, const char *status_id)
- {
-- gaim_presence_set_status_active(presence, status_id, TRUE);
-+ gaim2_presence_set_status_active(presence, status_id, TRUE);
- }
-
- static void
--update_buddy_idle(GaimBuddy *buddy, GaimPresence *presence,
-+update_buddy_idle(Gaim2Buddy *buddy, Gaim2Presence *presence,
- time_t current_time, gboolean old_idle, gboolean idle)
- {
-- GaimBlistUiOps *ops = gaim_get_blist()->ui_ops;
-- GaimConversation *conv;
-+ Gaim2BlistUiOps *ops = gaim2_get_blist()->ui_ops;
-+ Gaim2Conversation *conv;
-
- if (!old_idle && idle)
- {
-- if (gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_system"))
- {
-- GaimLog *log = gaim_account_get_log(buddy->account);
-+ Gaim2Log *log = gaim2_account_get_log(buddy->account);
- char *tmp = g_strdup_printf(_("%s became idle"),
-- gaim_buddy_get_alias(buddy));
-+ gaim2_buddy_get_alias(buddy));
-
-- gaim_log_write(log, GAIM_MESSAGE_SYSTEM,
-- gaim_buddy_get_alias(buddy), current_time, tmp);
-+ gaim2_log_write(log, GAIM_MESSAGE_SYSTEM,
-+ gaim2_buddy_get_alias(buddy), current_time, tmp);
- g_free(tmp);
- }
- }
- else if (old_idle && !idle)
- {
-- if (gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_system"))
- {
-- GaimLog *log = gaim_account_get_log(buddy->account);
-+ Gaim2Log *log = gaim2_account_get_log(buddy->account);
- char *tmp = g_strdup_printf(_("%s became unidle"),
-- gaim_buddy_get_alias(buddy));
-+ gaim2_buddy_get_alias(buddy));
-
-- gaim_log_write(log, GAIM_MESSAGE_SYSTEM,
-- gaim_buddy_get_alias(buddy), current_time, tmp);
-+ gaim2_log_write(log, GAIM_MESSAGE_SYSTEM,
-+ gaim2_buddy_get_alias(buddy), current_time, tmp);
- g_free(tmp);
- }
- }
-
- if (old_idle != idle)
-- gaim_signal_emit(gaim_blist_get_handle(), "buddy-idle-changed", buddy,
-+ gaim2_signal_emit(gaim2_blist_get_handle(), "buddy-idle-changed", buddy,
- old_idle, idle);
-
-- gaim_contact_invalidate_priority_buddy(gaim_buddy_get_contact(buddy));
-+ gaim2_contact_invalidate_priority_buddy(gaim2_buddy_get_contact(buddy));
-
- /* Should this be done here? It'd perhaps make more sense to
- * connect to buddy-[un]idle signals and update from there
- */
-
- if (ops != NULL && ops->update != NULL)
-- ops->update(gaim_get_blist(), (GaimBlistNode *)buddy);
-+ ops->update(gaim2_get_blist(), (Gaim2BlistNode *)buddy);
-
-- conv = gaim_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-- gaim_buddy_get_name(buddy),
-- gaim_buddy_get_account(buddy));
-+ conv = gaim2_find_conversation_with_account(GAIM_CONV_TYPE_IM,
-+ gaim2_buddy_get_name(buddy),
-+ gaim2_buddy_get_account(buddy));
- if (conv)
- {
-- GaimConversationUiOps *conv_ops;
-- conv_ops = gaim_conversation_get_ui_ops(conv);
-+ Gaim2ConversationUiOps *conv_ops;
-+ conv_ops = gaim2_conversation_get_ui_ops(conv);
- if (conv_ops && conv_ops->updated)
- conv_ops->updated(conv, GAIM_CONV_UPDATE_AWAY);
- }
- }
-
- void
--gaim_presence_set_idle(GaimPresence *presence, gboolean idle, time_t idle_time)
-+gaim2_presence_set_idle(Gaim2Presence *presence, gboolean idle, time_t idle_time)
- {
- gboolean old_idle;
-
-@@ -1343,53 +1343,53 @@ gaim_presence_set_idle(GaimPresence *pre
- presence->idle = idle;
- presence->idle_time = (idle ? idle_time : 0);
-
-- if (gaim_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_BUDDY)
-+ if (gaim2_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_BUDDY)
- {
- const GList *l;
- time_t current_time = time(NULL);
-
-- for (l = gaim_presence_get_buddies(presence); l != NULL; l = l->next)
-+ for (l = gaim2_presence_get_buddies(presence); l != NULL; l = l->next)
- {
-- update_buddy_idle((GaimBuddy *)l->data, presence, current_time,
-+ update_buddy_idle((Gaim2Buddy *)l->data, presence, current_time,
- old_idle, idle);
- }
- }
-- else if(gaim_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_ACCOUNT)
-+ else if(gaim2_presence_get_context(presence) == GAIM_PRESENCE_CONTEXT_ACCOUNT)
- {
-- GaimAccount *account;
-- GaimConnection *gc;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Account *account;
-+ Gaim2Connection *gc;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
-
-- account = gaim_presence_get_account(presence);
-+ account = gaim2_presence_get_account(presence);
-
-- if (gaim_prefs_get_bool("/core/logging/log_system"))
-+ if (gaim2_prefs_get_bool("/core/logging/log_system"))
- {
-- GaimLog *log = gaim_account_get_log(account);
-+ Gaim2Log *log = gaim2_account_get_log(account);
- char *msg;
-
- if (idle)
-- msg = g_strdup_printf(_("+++ %s became idle"), gaim_account_get_username(account));
-+ msg = g_strdup_printf(_("+++ %s became idle"), gaim2_account_get_username(account));
- else
-- msg = g_strdup_printf(_("+++ %s became unidle"), gaim_account_get_username(account));
-- gaim_log_write(log, GAIM_MESSAGE_SYSTEM,
-- gaim_account_get_username(account),
-+ msg = g_strdup_printf(_("+++ %s became unidle"), gaim2_account_get_username(account));
-+ gaim2_log_write(log, GAIM_MESSAGE_SYSTEM,
-+ gaim2_account_get_username(account),
- idle_time, msg);
- g_free(msg);
- }
-
-- gc = gaim_account_get_connection(account);
-+ gc = gaim2_account_get_connection(account);
-
- if (gc != NULL && gc->prpl != NULL)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(gc->prpl);
-
-- if (prpl_info && g_list_find(gaim_connections_get_all(), gc) &&
-+ if (prpl_info && g_list_find(gaim2_connections_get_all(), gc) &&
- prpl_info->set_idle)
- prpl_info->set_idle(gc, time(NULL) - idle_time);
- }
- }
-
- void
--gaim_presence_set_login_time(GaimPresence *presence, time_t login_time)
-+gaim2_presence_set_login_time(Gaim2Presence *presence, time_t login_time)
- {
- g_return_if_fail(presence != NULL);
-
-@@ -1399,22 +1399,22 @@ gaim_presence_set_login_time(GaimPresenc
- presence->login_time = login_time;
- }
-
--GaimPresenceContext
--gaim_presence_get_context(const GaimPresence *presence)
-+Gaim2PresenceContext
-+gaim2_presence_get_context(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, GAIM_PRESENCE_CONTEXT_UNSET);
-
- return presence->context;
- }
-
--GaimAccount *
--gaim_presence_get_account(const GaimPresence *presence)
-+Gaim2Account *
-+gaim2_presence_get_account(const Gaim2Presence *presence)
- {
-- GaimPresenceContext context;
-+ Gaim2PresenceContext context;
-
- g_return_val_if_fail(presence != NULL, NULL);
-
-- context = gaim_presence_get_context(presence);
-+ context = gaim2_presence_get_context(presence);
-
- g_return_val_if_fail(context == GAIM_PRESENCE_CONTEXT_ACCOUNT ||
- context == GAIM_PRESENCE_CONTEXT_BUDDY, NULL);
-@@ -1422,77 +1422,77 @@ gaim_presence_get_account(const GaimPres
- return presence->u.account;
- }
-
--GaimConversation *
--gaim_presence_get_conversation(const GaimPresence *presence)
-+Gaim2Conversation *
-+gaim2_presence_get_conversation(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, NULL);
-- g_return_val_if_fail(gaim_presence_get_context(presence) ==
-+ g_return_val_if_fail(gaim2_presence_get_context(presence) ==
- GAIM_PRESENCE_CONTEXT_CONV, NULL);
-
- return presence->u.chat.conv;
- }
-
- const char *
--gaim_presence_get_chat_user(const GaimPresence *presence)
-+gaim2_presence_get_chat_user(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, NULL);
-- g_return_val_if_fail(gaim_presence_get_context(presence) ==
-+ g_return_val_if_fail(gaim2_presence_get_context(presence) ==
- GAIM_PRESENCE_CONTEXT_CONV, NULL);
-
- return presence->u.chat.user;
- }
-
- const GList *
--gaim_presence_get_buddies(const GaimPresence *presence)
-+gaim2_presence_get_buddies(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, NULL);
-- g_return_val_if_fail(gaim_presence_get_context(presence) ==
-+ g_return_val_if_fail(gaim2_presence_get_context(presence) ==
- GAIM_PRESENCE_CONTEXT_BUDDY, NULL);
-
- return presence->u.buddy.buddies;
- }
-
- const GList *
--gaim_presence_get_statuses(const GaimPresence *presence)
-+gaim2_presence_get_statuses(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, NULL);
-
- return presence->statuses;
- }
-
--GaimStatus *
--gaim_presence_get_status(const GaimPresence *presence, const char *status_id)
-+Gaim2Status *
-+gaim2_presence_get_status(const Gaim2Presence *presence, const char *status_id)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
- const GList *l = NULL;
-
- g_return_val_if_fail(presence != NULL, NULL);
- g_return_val_if_fail(status_id != NULL, NULL);
-
- /* What's the purpose of this hash table? */
-- status = (GaimStatus *)g_hash_table_lookup(presence->status_table,
-+ status = (Gaim2Status *)g_hash_table_lookup(presence->status_table,
- status_id);
-
- if (status == NULL) {
-- for (l = gaim_presence_get_statuses(presence);
-+ for (l = gaim2_presence_get_statuses(presence);
- l != NULL && status == NULL; l = l->next)
- {
-- GaimStatus *temp_status = l->data;
-+ Gaim2Status *temp_status = l->data;
-
-- if (!strcmp(status_id, gaim_status_get_id(temp_status)))
-+ if (!strcmp(status_id, gaim2_status_get_id(temp_status)))
- status = temp_status;
- }
-
- if (status != NULL)
- g_hash_table_insert(presence->status_table,
-- g_strdup(gaim_status_get_id(status)), status);
-+ g_strdup(gaim2_status_get_id(status)), status);
- }
-
- return status;
- }
-
--GaimStatus *
--gaim_presence_get_active_status(const GaimPresence *presence)
-+Gaim2Status *
-+gaim2_presence_get_active_status(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, NULL);
-
-@@ -1500,74 +1500,74 @@ gaim_presence_get_active_status(const Ga
- }
-
- gboolean
--gaim_presence_is_available(const GaimPresence *presence)
-+gaim2_presence_is_available(const Gaim2Presence *presence)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- g_return_val_if_fail(presence != NULL, FALSE);
-
-- status = gaim_presence_get_active_status(presence);
-+ status = gaim2_presence_get_active_status(presence);
-
-- return ((status != NULL && gaim_status_is_available(status)) &&
-- !gaim_presence_is_idle(presence));
-+ return ((status != NULL && gaim2_status_is_available(status)) &&
-+ !gaim2_presence_is_idle(presence));
- }
-
- gboolean
--gaim_presence_is_online(const GaimPresence *presence)
-+gaim2_presence_is_online(const Gaim2Presence *presence)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- g_return_val_if_fail(presence != NULL, FALSE);
-
-- if ((status = gaim_presence_get_active_status(presence)) == NULL)
-+ if ((status = gaim2_presence_get_active_status(presence)) == NULL)
- return FALSE;
-
-- return gaim_status_is_online(status);
-+ return gaim2_status_is_online(status);
- }
-
- gboolean
--gaim_presence_is_status_active(const GaimPresence *presence,
-+gaim2_presence_is_status_active(const Gaim2Presence *presence,
- const char *status_id)
- {
-- GaimStatus *status;
-+ Gaim2Status *status;
-
- g_return_val_if_fail(presence != NULL, FALSE);
- g_return_val_if_fail(status_id != NULL, FALSE);
-
-- status = gaim_presence_get_status(presence, status_id);
-+ status = gaim2_presence_get_status(presence, status_id);
-
-- return (status != NULL && gaim_status_is_active(status));
-+ return (status != NULL && gaim2_status_is_active(status));
- }
-
- gboolean
--gaim_presence_is_status_primitive_active(const GaimPresence *presence,
-- GaimStatusPrimitive primitive)
-+gaim2_presence_is_status_primitive_active(const Gaim2Presence *presence,
-+ Gaim2StatusPrimitive primitive)
- {
-- GaimStatus *status;
-- GaimStatusType *status_type;
-+ Gaim2Status *status;
-+ Gaim2StatusType *status_type;
-
- g_return_val_if_fail(presence != NULL, FALSE);
- g_return_val_if_fail(primitive != GAIM_STATUS_UNSET, FALSE);
-
-- status = gaim_presence_get_active_status(presence);
-- status_type = gaim_status_get_type(status);
-+ status = gaim2_presence_get_active_status(presence);
-+ status_type = gaim2_status_get_type(status);
-
-- if (gaim_status_type_get_primitive(status_type) == primitive)
-+ if (gaim2_status_type_get_primitive(status_type) == primitive)
- return TRUE;
-
- return FALSE;
- }
-
- gboolean
--gaim_presence_is_idle(const GaimPresence *presence)
-+gaim2_presence_is_idle(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, FALSE);
-
-- return gaim_presence_is_online(presence) && presence->idle;
-+ return gaim2_presence_is_online(presence) && presence->idle;
- }
-
- time_t
--gaim_presence_get_idle_time(const GaimPresence *presence)
-+gaim2_presence_get_idle_time(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, 0);
-
-@@ -1575,16 +1575,16 @@ gaim_presence_get_idle_time(const GaimPr
- }
-
- time_t
--gaim_presence_get_login_time(const GaimPresence *presence)
-+gaim2_presence_get_login_time(const Gaim2Presence *presence)
- {
- g_return_val_if_fail(presence != NULL, 0);
-
-- return gaim_presence_is_online(presence) ? presence->login_time : 0;
-+ return gaim2_presence_is_online(presence) ? presence->login_time : 0;
- }
-
- gint
--gaim_presence_compare(const GaimPresence *presence1,
-- const GaimPresence *presence2)
-+gaim2_presence_compare(const Gaim2Presence *presence1,
-+ const Gaim2Presence *presence2)
- {
- gboolean idle1, idle2;
- time_t idle_time_1, idle_time_2;
-@@ -1599,29 +1599,29 @@ gaim_presence_compare(const GaimPresence
- return -1;
-
- /* Compute the score of the first set of statuses. */
-- for (l = gaim_presence_get_statuses(presence1); l != NULL; l = l->next)
-+ for (l = gaim2_presence_get_statuses(presence1); l != NULL; l = l->next)
- {
-- GaimStatus *status = (GaimStatus *)l->data;
-- GaimStatusType *type = gaim_status_get_type(status);
-+ Gaim2Status *status = (Gaim2Status *)l->data;
-+ Gaim2StatusType *type = gaim2_status_get_type(status);
-
-- if (gaim_status_is_active(status))
-- score1 += primitive_scores[gaim_status_type_get_primitive(type)];
-+ if (gaim2_status_is_active(status))
-+ score1 += primitive_scores[gaim2_status_type_get_primitive(type)];
- }
-- score1 += gaim_account_get_int(gaim_presence_get_account(presence1), "score", 0);
-+ score1 += gaim2_account_get_int(gaim2_presence_get_account(presence1), "score", 0);
-
- /* Compute the score of the second set of statuses. */
-- for (l = gaim_presence_get_statuses(presence2); l != NULL; l = l->next)
-+ for (l = gaim2_presence_get_statuses(presence2); l != NULL; l = l->next)
- {
-- GaimStatus *status = (GaimStatus *)l->data;
-- GaimStatusType *type = gaim_status_get_type(status);
-+ Gaim2Status *status = (Gaim2Status *)l->data;
-+ Gaim2StatusType *type = gaim2_status_get_type(status);
-
-- if (gaim_status_is_active(status))
-- score2 += primitive_scores[gaim_status_type_get_primitive(type)];
-+ if (gaim2_status_is_active(status))
-+ score2 += primitive_scores[gaim2_status_type_get_primitive(type)];
- }
-- score2 += gaim_account_get_int(gaim_presence_get_account(presence2), "score", 0);
-+ score2 += gaim2_account_get_int(gaim2_presence_get_account(presence2), "score", 0);
-
-- idle1 = gaim_presence_is_idle(presence1);
-- idle2 = gaim_presence_is_idle(presence2);
-+ idle1 = gaim2_presence_is_idle(presence1);
-+ idle2 = gaim2_presence_is_idle(presence2);
-
- if (idle1)
- score1 += primitive_scores[SCORE_IDLE];
-@@ -1629,8 +1629,8 @@ gaim_presence_compare(const GaimPresence
- if (idle2)
- score2 += primitive_scores[SCORE_IDLE];
-
-- idle_time_1 = time(NULL) - gaim_presence_get_idle_time(presence1);
-- idle_time_2 = time(NULL) - gaim_presence_get_idle_time(presence2);
-+ idle_time_1 = time(NULL) - gaim2_presence_get_idle_time(presence1);
-+ idle_time_2 = time(NULL) - gaim2_presence_get_idle_time(presence2);
-
- if (idle_time_1 > idle_time_2)
- score1 += primitive_scores[SCORE_IDLE_TIME];
-@@ -1650,7 +1650,7 @@ gaim_presence_compare(const GaimPresence
- * Status subsystem
- **************************************************************************/
- static void
--score_pref_changed_cb(const char *name, GaimPrefType type, gpointer value,
-+score_pref_changed_cb(const char *name, Gaim2PrefType type, gpointer value,
- gpointer data)
- {
- int index = GPOINTER_TO_INT(data);
-@@ -1659,9 +1659,9 @@ score_pref_changed_cb(const char *name,
- }
-
- static guint
--gaim_buddy_presences_hash(gconstpointer key)
-+gaim2_buddy_presences_hash(gconstpointer key)
- {
-- const GaimStatusBuddyKey *me = key;
-+ const Gaim2StatusBuddyKey *me = key;
- guint ret;
- char *str;
-
-@@ -1673,10 +1673,10 @@ gaim_buddy_presences_hash(gconstpointer
- }
-
- static gboolean
--gaim_buddy_presences_equal(gconstpointer a, gconstpointer b)
-+gaim2_buddy_presences_equal(gconstpointer a, gconstpointer b)
- {
-- GaimStatusBuddyKey *key_a = (GaimStatusBuddyKey *)a;
-- GaimStatusBuddyKey *key_b = (GaimStatusBuddyKey *)b;
-+ Gaim2StatusBuddyKey *key_a = (Gaim2StatusBuddyKey *)a;
-+ Gaim2StatusBuddyKey *key_b = (Gaim2StatusBuddyKey *)b;
-
- if(key_a->account == key_b->account &&
- !strcmp(key_a->name, key_b->name))
-@@ -1686,67 +1686,67 @@ gaim_buddy_presences_equal(gconstpointer
- }
-
- static void
--gaim_buddy_presences_key_free(gpointer a)
-+gaim2_buddy_presences_key_free(gpointer a)
- {
-- GaimStatusBuddyKey *key = (GaimStatusBuddyKey *)a;
-+ Gaim2StatusBuddyKey *key = (Gaim2StatusBuddyKey *)a;
- g_free(key->name);
- g_free(key);
- }
-
- void *
--gaim_status_get_handle(void) {
-+gaim2_status_get_handle(void) {
- static int handle;
-
- return &handle;
- }
-
- void
--gaim_status_init(void)
-+gaim2_status_init(void)
- {
-- void *handle = gaim_status_get_handle;
-+ void *handle = gaim2_status_get_handle;
-
-- gaim_prefs_add_none("/core/status");
-- gaim_prefs_add_none("/core/status/scores");
-+ gaim2_prefs_add_none("/core/status");
-+ gaim2_prefs_add_none("/core/status/scores");
-
-- gaim_prefs_add_int("/core/status/scores/offline",
-+ gaim2_prefs_add_int("/core/status/scores/offline",
- primitive_scores[GAIM_STATUS_OFFLINE]);
-- gaim_prefs_add_int("/core/status/scores/available",
-+ gaim2_prefs_add_int("/core/status/scores/available",
- primitive_scores[GAIM_STATUS_AVAILABLE]);
-- gaim_prefs_add_int("/core/status/scores/invisible",
-+ gaim2_prefs_add_int("/core/status/scores/invisible",
- primitive_scores[GAIM_STATUS_INVISIBLE]);
-- gaim_prefs_add_int("/core/status/scores/away",
-+ gaim2_prefs_add_int("/core/status/scores/away",
- primitive_scores[GAIM_STATUS_AWAY]);
-- gaim_prefs_add_int("/core/status/scores/extended_away",
-+ gaim2_prefs_add_int("/core/status/scores/extended_away",
- primitive_scores[GAIM_STATUS_EXTENDED_AWAY]);
-- gaim_prefs_add_int("/core/status/scores/idle",
-+ gaim2_prefs_add_int("/core/status/scores/idle",
- primitive_scores[SCORE_IDLE]);
-
-- gaim_prefs_connect_callback(handle, "/core/status/scores/offline",
-+ gaim2_prefs_connect_callback(handle, "/core/status/scores/offline",
- score_pref_changed_cb,
- GINT_TO_POINTER(GAIM_STATUS_OFFLINE));
-- gaim_prefs_connect_callback(handle, "/core/status/scores/available",
-+ gaim2_prefs_connect_callback(handle, "/core/status/scores/available",
- score_pref_changed_cb,
- GINT_TO_POINTER(GAIM_STATUS_AVAILABLE));
-- gaim_prefs_connect_callback(handle, "/core/status/scores/invisible",
-+ gaim2_prefs_connect_callback(handle, "/core/status/scores/invisible",
- score_pref_changed_cb,
- GINT_TO_POINTER(GAIM_STATUS_INVISIBLE));
-- gaim_prefs_connect_callback(handle, "/core/status/scores/away",
-+ gaim2_prefs_connect_callback(handle, "/core/status/scores/away",
- score_pref_changed_cb,
- GINT_TO_POINTER(GAIM_STATUS_AWAY));
-- gaim_prefs_connect_callback(handle, "/core/status/scores/extended_away",
-+ gaim2_prefs_connect_callback(handle, "/core/status/scores/extended_away",
- score_pref_changed_cb,
- GINT_TO_POINTER(GAIM_STATUS_EXTENDED_AWAY));
-- gaim_prefs_connect_callback(handle, "/core/status/scores/idle",
-+ gaim2_prefs_connect_callback(handle, "/core/status/scores/idle",
- score_pref_changed_cb,
- GINT_TO_POINTER(SCORE_IDLE));
-
-- buddy_presences = g_hash_table_new_full(gaim_buddy_presences_hash,
-- gaim_buddy_presences_equal,
-- gaim_buddy_presences_key_free, NULL);
-+ buddy_presences = g_hash_table_new_full(gaim2_buddy_presences_hash,
-+ gaim2_buddy_presences_equal,
-+ gaim2_buddy_presences_key_free, NULL);
- }
-
- void
--gaim_status_uninit(void)
-+gaim2_status_uninit(void)
- {
- if (buddy_presences != NULL)
- {
-diff -prNu ./src/status.h ./src/status.h
---- ./src/status.h 2005-12-21 09:24:15.000000000 +0100
-+++ ./src/status.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,54 +28,54 @@
- *
- * A brief explanation of the status API:
- *
-- * GaimStatusType's are created by each PRPL. They outline the
-+ * Gaim2StatusType's are created by each PRPL. They outline the
- * available statuses of the protocol. AIM, for example, supports
- * an available state with an optional available message, an away
- * state with a mandatory message, and an invisible state (which is
- * technically "independent" of the other two, but we'll get into
-- * that later). GaimStatusTypes are very permanent. They are
-+ * that later). Gaim2StatusTypes are very permanent. They are
- * hardcoded in each PRPL and will not change often. And because
- * they are hardcoded, they do not need to be saved to any XML file.
- *
-- * A GaimStatus can be thought of as an "instance" of a GaimStatusType.
-+ * A Gaim2Status can be thought of as an "instance" of a Gaim2StatusType.
- * If you've familiar with object-oriented programming languages
- * then this should be immediately clear. Say, for example, that
- * one of your AIM buddies has set himself as "away." You have a
-- * GaimBuddy node for this person in your buddy list. Gaim wants
-- * to mark this buddy as "away," so it creates a new GaimStatus.
-- * The GaimStatus has its GaimStatusType set to the "away" state
-- * for the oscar PRPL. The GaimStatus also contains the buddy's
-- * away message. GaimStatuses are sometimes saved, depending on
-- * the context. The current GaimStatuses associated with each of
-- * your accounts are saved so that the next time you start Gaim,
-+ * Gaim2Buddy node for this person in your buddy list. Gaim2 wants
-+ * to mark this buddy as "away," so it creates a new Gaim2Status.
-+ * The Gaim2Status has its Gaim2StatusType set to the "away" state
-+ * for the oscar PRPL. The Gaim2Status also contains the buddy's
-+ * away message. Gaim2Statuses are sometimes saved, depending on
-+ * the context. The current Gaim2Statuses associated with each of
-+ * your accounts are saved so that the next time you start Gaim2,
- * your accounts will be set to their last known statuses. There
- * is also a list of saved statuses that are written to the
-- * status.xml file. Also, each GaimStatus has a "savable" boolean.
-+ * status.xml file. Also, each Gaim2Status has a "savable" boolean.
- * If "savable" is set to FALSE then the status is NEVER saved.
-- * All GaimStatuses should be inside a GaimPresence.
-+ * All Gaim2Statuses should be inside a Gaim2Presence.
- *
- *
-- * A GaimStatus is either "indepedent" or "exclusive."
-+ * A Gaim2Status is either "indepedent" or "exclusive."
- * Independent statuses can be active or inactive and it doesn't
- * affect anything else. However, you can only have one exclusive
-- * status per GaimPresence. If you activate one exlusive status,
-+ * status per Gaim2Presence. If you activate one exlusive status,
- * then the previous exclusive status is automatically deactivated.
- *
-- * A GaimPresence is like a collection of GaimStatuses (plus some
-+ * A Gaim2Presence is like a collection of Gaim2Statuses (plus some
- * other random info). For any buddy, or for any one of your accounts,
- * or for any person you're chatting with, you may know various
- * amounts of information. This information is all contained in
-- * one GaimPresence. If one of your buddies is away and idle,
-- * then the presence contains the GaimStatus for their awayness,
-- * and it contains their current idle time. GaimPresences are
-+ * one Gaim2Presence. If one of your buddies is away and idle,
-+ * then the presence contains the Gaim2Status for their awayness,
-+ * and it contains their current idle time. Gaim2Presences are
- * never saved to disk. The information they contain is only relevent
-- * for the current GaimSession.
-+ * for the current Gaim2Session.
- */
-
--typedef struct _GaimStatusType GaimStatusType;
--typedef struct _GaimStatusAttr GaimStatusAttr;
--typedef struct _GaimPresence GaimPresence;
--typedef struct _GaimStatus GaimStatus;
-+typedef struct _Gaim2StatusType Gaim2StatusType;
-+typedef struct _Gaim2StatusAttr Gaim2StatusAttr;
-+typedef struct _Gaim2Presence Gaim2Presence;
-+typedef struct _Gaim2Status Gaim2Status;
-
- /**
- * A context for a presence.
-@@ -89,7 +89,7 @@ typedef enum
- GAIM_PRESENCE_CONTEXT_CONV,
- GAIM_PRESENCE_CONTEXT_BUDDY
-
--} GaimPresenceContext;
-+} Gaim2PresenceContext;
-
- /**
- * A primitive defining the basic structure of a status type.
-@@ -106,7 +106,7 @@ typedef enum
- GAIM_STATUS_MOBILE,
- GAIM_STATUS_NUM_PRIMITIVES
-
--} GaimStatusPrimitive;
-+} Gaim2StatusPrimitive;
-
- #include "account.h"
- #include "blist.h"
-@@ -114,7 +114,7 @@ typedef enum
- #include "value.h"
-
- /**************************************************************************/
--/** @name GaimStatusPrimitive API */
-+/** @name Gaim2StatusPrimitive API */
- /**************************************************************************/
- /*@{*/
-
-@@ -126,7 +126,7 @@ typedef enum
- *
- * @return The unique ID for this type.
- */
--const char *gaim_primitive_get_id_from_type(GaimStatusPrimitive type);
-+const char *gaim2_primitive_get_id_from_type(Gaim2StatusPrimitive type);
-
- /**
- * Lookup the name of a primitive status type based on the type. This
-@@ -137,7 +137,7 @@ const char *gaim_primitive_get_id_from_t
- *
- * @return The name of this type, suitable for users to see.
- */
--const char *gaim_primitive_get_name_from_type(GaimStatusPrimitive type);
-+const char *gaim2_primitive_get_name_from_type(Gaim2StatusPrimitive type);
-
- /**
- * Lookup the value of a primitive status type based on the id. The
-@@ -145,14 +145,14 @@ const char *gaim_primitive_get_name_from
- *
- * @param id The unique ID of a primitive status type.
- *
-- * @return The GaimStatusPrimitive value.
-+ * @return The Gaim2StatusPrimitive value.
- */
--GaimStatusPrimitive gaim_primitive_get_type_from_id(const char *id);
-+Gaim2StatusPrimitive gaim2_primitive_get_type_from_id(const char *id);
-
- /*@}*/
-
- /**************************************************************************/
--/** @name GaimStatusType API */
-+/** @name Gaim2StatusType API */
- /**************************************************************************/
- /*@{*/
-
-@@ -172,7 +172,7 @@ GaimStatusPrimitive gaim_primitive_get_t
- *
- * @return A new status type.
- */
--GaimStatusType *gaim_status_type_new_full(GaimStatusPrimitive primitive,
-+Gaim2StatusType *gaim2_status_type_new_full(Gaim2StatusPrimitive primitive,
- const char *id, const char *name,
- gboolean saveable,
- gboolean user_settable,
-@@ -191,7 +191,7 @@ GaimStatusType *gaim_status_type_new_ful
- *
- * @return A new status type.
- */
--GaimStatusType *gaim_status_type_new(GaimStatusPrimitive primitive,
-+Gaim2StatusType *gaim2_status_type_new(Gaim2StatusPrimitive primitive,
- const char *id, const char *name,
- gboolean user_settable);
-
-@@ -215,7 +215,7 @@ GaimStatusType *gaim_status_type_new(Gai
- *
- * @return A new status type.
- */
--GaimStatusType *gaim_status_type_new_with_attrs(GaimStatusPrimitive primitive,
-+Gaim2StatusType *gaim2_status_type_new_with_attrs(Gaim2StatusPrimitive primitive,
- const char *id,
- const char *name,
- gboolean saveable,
-@@ -223,14 +223,14 @@ GaimStatusType *gaim_status_type_new_wit
- gboolean independent,
- const char *attr_id,
- const char *attr_name,
-- GaimValue *attr_value, ...);
-+ Gaim2Value *attr_value, ...);
-
- /**
- * Destroys a status type.
- *
- * @param status_type The status type to destroy.
- */
--void gaim_status_type_destroy(GaimStatusType *status_type);
-+void gaim2_status_type_destroy(Gaim2StatusType *status_type);
-
- /**
- * Sets a status type's primary attribute.
-@@ -242,7 +242,7 @@ void gaim_status_type_destroy(GaimStatus
- * @param status_type The status type.
- * @param attr_id The ID of the primary attribute.
- */
--void gaim_status_type_set_primary_attr(GaimStatusType *status_type,
-+void gaim2_status_type_set_primary_attr(Gaim2StatusType *status_type,
- const char *attr_id);
-
- /**
-@@ -253,8 +253,8 @@ void gaim_status_type_set_primary_attr(G
- * @param name The name presented to the user.
- * @param value The value type of this attribute.
- */
--void gaim_status_type_add_attr(GaimStatusType *status_type, const char *id,
-- const char *name, GaimValue *value);
-+void gaim2_status_type_add_attr(Gaim2StatusType *status_type, const char *id,
-+ const char *name, Gaim2Value *value);
-
- /**
- * Adds multiple attributes to a status type.
-@@ -265,8 +265,8 @@ void gaim_status_type_add_attr(GaimStatu
- * @param value The value type of the first attribute attribute.
- * @param ... Additional attribute information.
- */
--void gaim_status_type_add_attrs(GaimStatusType *status_type, const char *id,
-- const char *name, GaimValue *value, ...);
-+void gaim2_status_type_add_attrs(Gaim2StatusType *status_type, const char *id,
-+ const char *name, Gaim2Value *value, ...);
-
- /**
- * Adds multiple attributes to a status type using a va_list.
-@@ -274,7 +274,7 @@ void gaim_status_type_add_attrs(GaimStat
- * @param status_type The status type to add the attribute to.
- * @param args The va_list of attributes.
- */
--void gaim_status_type_add_attrs_vargs(GaimStatusType *status_type,
-+void gaim2_status_type_add_attrs_vargs(Gaim2StatusType *status_type,
- va_list args);
-
- /**
-@@ -284,8 +284,8 @@ void gaim_status_type_add_attrs_vargs(Ga
- *
- * @return The primitive type of the status type.
- */
--GaimStatusPrimitive gaim_status_type_get_primitive(
-- const GaimStatusType *status_type);
-+Gaim2StatusPrimitive gaim2_status_type_get_primitive(
-+ const Gaim2StatusType *status_type);
-
- /**
- * Returns the ID of a status type.
-@@ -294,7 +294,7 @@ GaimStatusPrimitive gaim_status_type_get
- *
- * @return The ID of the status type.
- */
--const char *gaim_status_type_get_id(const GaimStatusType *status_type);
-+const char *gaim2_status_type_get_id(const Gaim2StatusType *status_type);
-
- /**
- * Returns the name of a status type.
-@@ -303,7 +303,7 @@ const char *gaim_status_type_get_id(cons
- *
- * @return The name of the status type.
- */
--const char *gaim_status_type_get_name(const GaimStatusType *status_type);
-+const char *gaim2_status_type_get_name(const Gaim2StatusType *status_type);
-
- /**
- * Returns whether or not the status type is saveable.
-@@ -313,7 +313,7 @@ const char *gaim_status_type_get_name(co
- * @return TRUE if user-defined statuses based off this type are saveable.
- * FALSE otherwise.
- */
--gboolean gaim_status_type_is_saveable(const GaimStatusType *status_type);
-+gboolean gaim2_status_type_is_saveable(const Gaim2StatusType *status_type);
-
- /**
- * Returns whether or not the status type can be set or modified by the
-@@ -324,7 +324,7 @@ gboolean gaim_status_type_is_saveable(co
- * @return TRUE if the status type can be set or modified by the user.
- * FALSE if it's a protocol-set setting.
- */
--gboolean gaim_status_type_is_user_settable(const GaimStatusType *status_type);
-+gboolean gaim2_status_type_is_user_settable(const Gaim2StatusType *status_type);
-
- /**
- * Returns whether or not the status type is independent.
-@@ -336,7 +336,7 @@ gboolean gaim_status_type_is_user_settab
- *
- * @return TRUE if the status type is independent, or FALSE otherwise.
- */
--gboolean gaim_status_type_is_independent(const GaimStatusType *status_type);
-+gboolean gaim2_status_type_is_independent(const Gaim2StatusType *status_type);
-
- /**
- * Returns whether the status type is exclusive.
-@@ -345,7 +345,7 @@ gboolean gaim_status_type_is_independent
- *
- * @return TRUE if the status type is exclusive, FALSE otherwise.
- */
--gboolean gaim_status_type_is_exclusive(const GaimStatusType *status_type);
-+gboolean gaim2_status_type_is_exclusive(const Gaim2StatusType *status_type);
-
- /**
- * Returns whether or not a status type is available.
-@@ -356,7 +356,7 @@ gboolean gaim_status_type_is_exclusive(c
- *
- * @return TRUE if the status is available, or FALSE otherwise.
- */
--gboolean gaim_status_type_is_available(const GaimStatusType *status_type);
-+gboolean gaim2_status_type_is_available(const Gaim2StatusType *status_type);
-
- /**
- * Returns a status type's primary attribute ID.
-@@ -365,7 +365,7 @@ gboolean gaim_status_type_is_available(c
- *
- * @return The primary attribute's ID.
- */
--const char *gaim_status_type_get_primary_attr(const GaimStatusType *type);
-+const char *gaim2_status_type_get_primary_attr(const Gaim2StatusType *type);
-
- /**
- * Returns the attribute with the specified ID.
-@@ -375,7 +375,7 @@ const char *gaim_status_type_get_primary
- *
- * @return The attribute, if found. NULL otherwise.
- */
--GaimStatusAttr *gaim_status_type_get_attr(const GaimStatusType *status_type,
-+Gaim2StatusAttr *gaim2_status_type_get_attr(const Gaim2StatusType *status_type,
- const char *id);
-
- /**
-@@ -385,10 +385,10 @@ GaimStatusAttr *gaim_status_type_get_att
- *
- * @return The list of attributes.
- */
--const GList *gaim_status_type_get_attrs(const GaimStatusType *status_type);
-+const GList *gaim2_status_type_get_attrs(const Gaim2StatusType *status_type);
-
- /**
-- * Find the GaimStatusType with the given id.
-+ * Find the Gaim2StatusType with the given id.
- *
- * @param status_types A list of status types. Often account->status_types.
- * @param id The unique ID of the status type you wish to find.
-@@ -396,13 +396,13 @@ const GList *gaim_status_type_get_attrs(
- * @return The status type with the given ID, or NULL if one could
- * not be found.
- */
--const GaimStatusType *gaim_status_type_find_with_id(GList *status_types,
-+const Gaim2StatusType *gaim2_status_type_find_with_id(GList *status_types,
- const char *id);
-
- /*@}*/
-
- /**************************************************************************/
--/** @name GaimStatusAttr API */
-+/** @name Gaim2StatusAttr API */
- /**************************************************************************/
- /*@{*/
-
-@@ -415,15 +415,15 @@ const GaimStatusType *gaim_status_type_f
- *
- * @return A new status attribute.
- */
--GaimStatusAttr *gaim_status_attr_new(const char *id, const char *name,
-- GaimValue *value_type);
-+Gaim2StatusAttr *gaim2_status_attr_new(const char *id, const char *name,
-+ Gaim2Value *value_type);
-
- /**
- * Destroys a status attribute.
- *
- * @param attr The status attribute to destroy.
- */
--void gaim_status_attr_destroy(GaimStatusAttr *attr);
-+void gaim2_status_attr_destroy(Gaim2StatusAttr *attr);
-
- /**
- * Returns the ID of a status attribute.
-@@ -432,7 +432,7 @@ void gaim_status_attr_destroy(GaimStatus
- *
- * @return The status attribute's ID.
- */
--const char *gaim_status_attr_get_id(const GaimStatusAttr *attr);
-+const char *gaim2_status_attr_get_id(const Gaim2StatusAttr *attr);
-
- /**
- * Returns the name of a status attribute.
-@@ -441,7 +441,7 @@ const char *gaim_status_attr_get_id(cons
- *
- * @return The status attribute's name.
- */
--const char *gaim_status_attr_get_name(const GaimStatusAttr *attr);
-+const char *gaim2_status_attr_get_name(const Gaim2StatusAttr *attr);
-
- /**
- * Returns the value of a status attribute.
-@@ -450,12 +450,12 @@ const char *gaim_status_attr_get_name(co
- *
- * @return The status attribute's value.
- */
--GaimValue *gaim_status_attr_get_value(const GaimStatusAttr *attr);
-+Gaim2Value *gaim2_status_attr_get_value(const Gaim2StatusAttr *attr);
-
- /*@}*/
-
- /**************************************************************************/
--/** @name GaimStatus API */
-+/** @name Gaim2Status API */
- /**************************************************************************/
- /*@{*/
-
-@@ -467,15 +467,15 @@ GaimValue *gaim_status_attr_get_value(co
- *
- * @return The new status.
- */
--GaimStatus *gaim_status_new(GaimStatusType *status_type,
-- GaimPresence *presence);
-+Gaim2Status *gaim2_status_new(Gaim2StatusType *status_type,
-+ Gaim2Presence *presence);
-
- /**
- * Destroys a status.
- *
- * @param status The status to destroy.
- */
--void gaim_status_destroy(GaimStatus *status);
-+void gaim2_status_destroy(Gaim2Status *status);
-
- /**
- * Sets whether or not a status is active.
-@@ -485,7 +485,7 @@ void gaim_status_destroy(GaimStatus *sta
- * @param status The status.
- * @param active The active state.
- */
--void gaim_status_set_active(GaimStatus *status, gboolean active);
-+void gaim2_status_set_active(Gaim2Status *status, gboolean active);
-
- /**
- * Sets whether or not a status is active.
-@@ -496,10 +496,10 @@ void gaim_status_set_active(GaimStatus *
- * @param active The active state.
- * @param args A list of attributes to set on the status. This list is
- * composed of key/value pairs, where each key is a valid
-- * attribute name for this GaimStatusType. The list should
-+ * attribute name for this Gaim2StatusType. The list should
- * be NULL terminated.
- */
--void gaim_status_set_active_with_attrs(GaimStatus *status, gboolean active,
-+void gaim2_status_set_active_with_attrs(Gaim2Status *status, gboolean active,
- va_list args);
-
- /**
-@@ -511,9 +511,9 @@ void gaim_status_set_active_with_attrs(G
- * @param active The active state.
- * @param attrs A list of attributes to set on the status. This list is
- * composed of key/value pairs, where each key is a valid
-- * attribute name for this GaimStatusType.
-+ * attribute name for this Gaim2StatusType.
- */
--void gaim_status_set_active_with_attrs_list(GaimStatus *status, gboolean active,
-+void gaim2_status_set_active_with_attrs_list(Gaim2Status *status, gboolean active,
- const GList *attrs);
-
- /**
-@@ -523,7 +523,7 @@ void gaim_status_set_active_with_attrs_l
- * @param id The attribute ID.
- * @param value The boolean value.
- */
--void gaim_status_set_attr_boolean(GaimStatus *status, const char *id,
-+void gaim2_status_set_attr_boolean(Gaim2Status *status, const char *id,
- gboolean value);
-
- /**
-@@ -533,7 +533,7 @@ void gaim_status_set_attr_boolean(GaimSt
- * @param id The attribute ID.
- * @param value The integer value.
- */
--void gaim_status_set_attr_int(GaimStatus *status, const char *id,
-+void gaim2_status_set_attr_int(Gaim2Status *status, const char *id,
- int value);
-
- /**
-@@ -543,7 +543,7 @@ void gaim_status_set_attr_int(GaimStatus
- * @param id The attribute ID.
- * @param value The string value.
- */
--void gaim_status_set_attr_string(GaimStatus *status, const char *id,
-+void gaim2_status_set_attr_string(Gaim2Status *status, const char *id,
- const char *value);
-
- /**
-@@ -553,7 +553,7 @@ void gaim_status_set_attr_string(GaimSta
- *
- * @return The status's type.
- */
--GaimStatusType *gaim_status_get_type(const GaimStatus *status);
-+Gaim2StatusType *gaim2_status_get_type(const Gaim2Status *status);
-
- /**
- * Returns the status's presence.
-@@ -562,55 +562,55 @@ GaimStatusType *gaim_status_get_type(con
- *
- * @return The status's presence.
- */
--GaimPresence *gaim_status_get_presence(const GaimStatus *status);
-+Gaim2Presence *gaim2_status_get_presence(const Gaim2Status *status);
-
- /**
- * Returns the status's type ID.
- *
- * This is a convenience method for
-- * gaim_status_type_get_id(gaim_status_get_type(status)).
-+ * gaim2_status_type_get_id(gaim2_status_get_type(status)).
- *
- * @param status The status.
- *
- * @return The status's ID.
- */
--const char *gaim_status_get_id(const GaimStatus *status);
-+const char *gaim2_status_get_id(const Gaim2Status *status);
-
- /**
- * Returns the status's name.
- *
- * This is a convenience method for
-- * gaim_status_type_get_name(gaim_status_get_type(status)).
-+ * gaim2_status_type_get_name(gaim2_status_get_type(status)).
- *
- * @param status The status.
- *
- * @return The status's name.
- */
--const char *gaim_status_get_name(const GaimStatus *status);
-+const char *gaim2_status_get_name(const Gaim2Status *status);
-
- /**
- * Returns whether or not a status is independent.
- *
- * This is a convenience method for
-- * gaim_status_type_is_independent(gaim_status_get_type(status)).
-+ * gaim2_status_type_is_independent(gaim2_status_get_type(status)).
- *
- * @param status The status.
- *
- * @return TRUE if the status is independent, or FALSE otherwise.
- */
--gboolean gaim_status_is_independent(const GaimStatus *status);
-+gboolean gaim2_status_is_independent(const Gaim2Status *status);
-
- /**
- * Returns whether or not a status is exclusive.
- *
- * This is a convenience method for
-- * gaim_status_type_is_exclusive(gaim_status_get_type(status)).
-+ * gaim2_status_type_is_exclusive(gaim2_status_get_type(status)).
- *
- * @param status The status.
- *
- * @return TRUE if the status is exclusive, FALSE otherwise.
- */
--gboolean gaim_status_is_exclusive(const GaimStatus *status);
-+gboolean gaim2_status_is_exclusive(const Gaim2Status *status);
-
- /**
- * Returns whether or not a status is available.
-@@ -618,13 +618,13 @@ gboolean gaim_status_is_exclusive(const
- * Available statuses are online and possibly invisible, but not away or idle.
- *
- * This is a convenience method for
-- * gaim_status_type_is_available(gaim_status_get_type(status)).
-+ * gaim2_status_type_is_available(gaim2_status_get_type(status)).
- *
- * @param status The status.
- *
- * @return TRUE if the status is available, or FALSE otherwise.
- */
--gboolean gaim_status_is_available(const GaimStatus *status);
-+gboolean gaim2_status_is_available(const Gaim2Status *status);
-
- /**
- * Returns the active state of a status.
-@@ -633,7 +633,7 @@ gboolean gaim_status_is_available(const
- *
- * @return The active state of the status.
- */
--gboolean gaim_status_is_active(const GaimStatus *status);
-+gboolean gaim2_status_is_active(const Gaim2Status *status);
-
- /**
- * Returns whether or not a status is considered 'online'
-@@ -642,7 +642,7 @@ gboolean gaim_status_is_active(const Gai
- *
- * @return TRUE if the status is considered online, FALSE otherwise
- */
--gboolean gaim_status_is_online(const GaimStatus *status);
-+gboolean gaim2_status_is_online(const Gaim2Status *status);
-
- /**
- * Returns the value of an attribute in a status with the specified ID.
-@@ -652,7 +652,7 @@ gboolean gaim_status_is_online(const Gai
- *
- * @return The value of the attribute.
- */
--GaimValue *gaim_status_get_attr_value(const GaimStatus *status,
-+Gaim2Value *gaim2_status_get_attr_value(const Gaim2Status *status,
- const char *id);
-
- /**
-@@ -663,7 +663,7 @@ GaimValue *gaim_status_get_attr_value(co
- *
- * @return The boolean value of the attribute.
- */
--gboolean gaim_status_get_attr_boolean(const GaimStatus *status,
-+gboolean gaim2_status_get_attr_boolean(const Gaim2Status *status,
- const char *id);
-
- /**
-@@ -674,7 +674,7 @@ gboolean gaim_status_get_attr_boolean(co
- *
- * @return The integer value of the attribute.
- */
--int gaim_status_get_attr_int(const GaimStatus *status, const char *id);
-+int gaim2_status_get_attr_int(const Gaim2Status *status, const char *id);
-
- /**
- * Returns the string value of an attribute in a status with the specified ID.
-@@ -684,7 +684,7 @@ int gaim_status_get_attr_int(const GaimS
- *
- * @return The string value of the attribute.
- */
--const char *gaim_status_get_attr_string(const GaimStatus *status,
-+const char *gaim2_status_get_attr_string(const Gaim2Status *status,
- const char *id);
-
- /**
-@@ -697,12 +697,12 @@ const char *gaim_status_get_attr_string(
- * 0 if @a status1 is equal to @a status2.
- * 1 if @a status2 is more available than @a status1.
- */
--gint gaim_status_compare(const GaimStatus *status1, const GaimStatus *status2);
-+gint gaim2_status_compare(const Gaim2Status *status1, const Gaim2Status *status2);
-
- /*@}*/
-
- /**************************************************************************/
--/** @name GaimPresence API */
-+/** @name Gaim2Presence API */
- /**************************************************************************/
- /*@{*/
-
-@@ -713,7 +713,7 @@ gint gaim_status_compare(const GaimStatu
- *
- * @return A new presence.
- */
--GaimPresence *gaim_presence_new(GaimPresenceContext context);
-+Gaim2Presence *gaim2_presence_new(Gaim2PresenceContext context);
-
- /**
- * Creates a presence for an account.
-@@ -722,7 +722,7 @@ GaimPresence *gaim_presence_new(GaimPres
- *
- * @return The new presence.
- */
--GaimPresence *gaim_presence_new_for_account(GaimAccount *account);
-+Gaim2Presence *gaim2_presence_new_for_account(Gaim2Account *account);
-
- /**
- * Creates a presence for a conversation.
-@@ -731,7 +731,7 @@ GaimPresence *gaim_presence_new_for_acco
- *
- * @return The new presence.
- */
--GaimPresence *gaim_presence_new_for_conv(GaimConversation *conv);
-+Gaim2Presence *gaim2_presence_new_for_conv(Gaim2Conversation *conv);
-
- /**
- * Creates a presence for a buddy.
-@@ -740,7 +740,7 @@ GaimPresence *gaim_presence_new_for_conv
- *
- * @return The new presence.
- */
--GaimPresence *gaim_presence_new_for_buddy(GaimBuddy *buddy);
-+Gaim2Presence *gaim2_presence_new_for_buddy(Gaim2Buddy *buddy);
-
- /**
- * Destroys a presence.
-@@ -749,11 +749,11 @@ GaimPresence *gaim_presence_new_for_budd
- * the presence.
- *
- * If this presence belongs to a buddy, you must call
-- * gaim_presence_remove_buddy() first.
-+ * gaim2_presence_remove_buddy() first.
- *
- * @param presence The presence to destroy.
- */
--void gaim_presence_destroy(GaimPresence *presence);
-+void gaim2_presence_destroy(Gaim2Presence *presence);
-
- /**
- * Removes a buddy from a presence.
-@@ -763,7 +763,7 @@ void gaim_presence_destroy(GaimPresence
- * @param presence The presence.
- * @param buddy The buddy.
- */
--void gaim_presence_remove_buddy(GaimPresence *presence, GaimBuddy *buddy);
-+void gaim2_presence_remove_buddy(Gaim2Presence *presence, Gaim2Buddy *buddy);
-
- /**
- * Adds a status to a presence.
-@@ -771,7 +771,7 @@ void gaim_presence_remove_buddy(GaimPres
- * @param presence The presence.
- * @param status The status to add.
- */
--void gaim_presence_add_status(GaimPresence *presence, GaimStatus *status);
-+void gaim2_presence_add_status(Gaim2Presence *presence, Gaim2Status *status);
-
- /**
- * Adds a list of statuses to the presence.
-@@ -779,32 +779,32 @@ void gaim_presence_add_status(GaimPresen
- * @param presence The presence.
- * @param source_list The source list of statuses to add.
- */
--void gaim_presence_add_list(GaimPresence *presence, const GList *source_list);
-+void gaim2_presence_add_list(Gaim2Presence *presence, const GList *source_list);
-
- /**
- * Sets the active state of a status in a presence.
- *
- * Only independent statuses can be set unactive. Normal statuses can only
- * be set active, so if you wish to disable a status, set another
-- * non-independent status to active, or use gaim_presence_switch_status().
-+ * non-independent status to active, or use gaim2_presence_switch_status().
- *
- * @param presence The presence.
- * @param status_id The ID of the status.
- * @param active The active state.
- */
--void gaim_presence_set_status_active(GaimPresence *presence,
-+void gaim2_presence_set_status_active(Gaim2Presence *presence,
- const char *status_id, gboolean active);
-
- /**
- * Switches the active status in a presence.
- *
-- * This is similar to gaim_presence_set_status_active(), except it won't
-+ * This is similar to gaim2_presence_set_status_active(), except it won't
- * activate independent statuses.
- *
- * @param presence The presence.
- * @param status_id The status ID to switch to.
- */
--void gaim_presence_switch_status(GaimPresence *presence,
-+void gaim2_presence_switch_status(Gaim2Presence *presence,
- const char *status_id);
-
- /**
-@@ -816,7 +816,7 @@ void gaim_presence_switch_status(GaimPre
- * is the time at which the user became idle,
- * in seconds since the epoch.
- */
--void gaim_presence_set_idle(GaimPresence *presence, gboolean idle,
-+void gaim2_presence_set_idle(Gaim2Presence *presence, gboolean idle,
- time_t idle_time);
-
- /**
-@@ -825,7 +825,7 @@ void gaim_presence_set_idle(GaimPresence
- * @param presence The presence.
- * @param login_time The login time.
- */
--void gaim_presence_set_login_time(GaimPresence *presence, time_t login_time);
-+void gaim2_presence_set_login_time(Gaim2Presence *presence, time_t login_time);
-
-
- /**
-@@ -835,7 +835,7 @@ void gaim_presence_set_login_time(GaimPr
- *
- * @return The presence's context.
- */
--GaimPresenceContext gaim_presence_get_context(const GaimPresence *presence);
-+Gaim2PresenceContext gaim2_presence_get_context(const Gaim2Presence *presence);
-
- /**
- * Returns a presence's account.
-@@ -844,7 +844,7 @@ GaimPresenceContext gaim_presence_get_co
- *
- * @return The presence's account.
- */
--GaimAccount *gaim_presence_get_account(const GaimPresence *presence);
-+Gaim2Account *gaim2_presence_get_account(const Gaim2Presence *presence);
-
- /**
- * Returns a presence's conversation.
-@@ -853,7 +853,7 @@ GaimAccount *gaim_presence_get_account(c
- *
- * @return The presence's conversation.
- */
--GaimConversation *gaim_presence_get_conversation(const GaimPresence *presence);
-+Gaim2Conversation *gaim2_presence_get_conversation(const Gaim2Presence *presence);
-
- /**
- * Returns a presence's chat user.
-@@ -862,7 +862,7 @@ GaimConversation *gaim_presence_get_conv
- *
- * @return The chat's user.
- */
--const char *gaim_presence_get_chat_user(const GaimPresence *presence);
-+const char *gaim2_presence_get_chat_user(const Gaim2Presence *presence);
-
- /**
- * Returns a presence's list of buddies.
-@@ -871,7 +871,7 @@ const char *gaim_presence_get_chat_user(
- *
- * @return The presence's list of buddies.
- */
--const GList *gaim_presence_get_buddies(const GaimPresence *presence);
-+const GList *gaim2_presence_get_buddies(const Gaim2Presence *presence);
-
- /**
- * Returns all the statuses in a presence.
-@@ -880,7 +880,7 @@ const GList *gaim_presence_get_buddies(c
- *
- * @return The statuses.
- */
--const GList *gaim_presence_get_statuses(const GaimPresence *presence);
-+const GList *gaim2_presence_get_statuses(const Gaim2Presence *presence);
-
- /**
- * Returns the status with the specified ID from a presence.
-@@ -890,7 +890,7 @@ const GList *gaim_presence_get_statuses(
- *
- * @return The status if found, or NULL.
- */
--GaimStatus *gaim_presence_get_status(const GaimPresence *presence,
-+Gaim2Status *gaim2_presence_get_status(const Gaim2Presence *presence,
- const char *status_id);
-
- /**
-@@ -900,7 +900,7 @@ GaimStatus *gaim_presence_get_status(con
- *
- * @return The active exclusive status.
- */
--GaimStatus *gaim_presence_get_active_status(const GaimPresence *presence);
-+Gaim2Status *gaim2_presence_get_active_status(const Gaim2Presence *presence);
-
- /**
- * Returns whether or not a presence is available.
-@@ -911,7 +911,7 @@ GaimStatus *gaim_presence_get_active_sta
- *
- * @return TRUE if the presence is available, or FALSE otherwise.
- */
--gboolean gaim_presence_is_available(const GaimPresence *presence);
-+gboolean gaim2_presence_is_available(const Gaim2Presence *presence);
-
- /**
- * Returns whether or not a presence is online.
-@@ -920,7 +920,7 @@ gboolean gaim_presence_is_available(cons
- *
- * @return TRUE if the presence is online, or FALSE otherwise.
- */
--gboolean gaim_presence_is_online(const GaimPresence *presence);
-+gboolean gaim2_presence_is_online(const Gaim2Presence *presence);
-
- /**
- * Returns whether or not a status in a presence is active.
-@@ -932,7 +932,7 @@ gboolean gaim_presence_is_online(const G
- *
- * @return TRUE if the status is active, or FALSE.
- */
--gboolean gaim_presence_is_status_active(const GaimPresence *presence,
-+gboolean gaim2_presence_is_status_active(const Gaim2Presence *presence,
- const char *status_id);
-
- /**
-@@ -946,8 +946,8 @@ gboolean gaim_presence_is_status_active(
- *
- * @return TRUE if the status is active, or FALSE.
- */
--gboolean gaim_presence_is_status_primitive_active(
-- const GaimPresence *presence, GaimStatusPrimitive primitive);
-+gboolean gaim2_presence_is_status_primitive_active(
-+ const Gaim2Presence *presence, Gaim2StatusPrimitive primitive);
-
- /**
- * Returns whether or not a presence is idle.
-@@ -955,10 +955,10 @@ gboolean gaim_presence_is_status_primiti
- * @param presence The presence.
- *
- * @return TRUE if the presence is idle, or FALSE otherwise.
-- * If the presence is offline (gaim_presence_is_online()
-+ * If the presence is offline (gaim2_presence_is_online()
- * returns FALSE) then FALSE is returned.
- */
--gboolean gaim_presence_is_idle(const GaimPresence *presence);
-+gboolean gaim2_presence_is_idle(const Gaim2Presence *presence);
-
- /**
- * Returns the presence's idle time.
-@@ -967,7 +967,7 @@ gboolean gaim_presence_is_idle(const Gai
- *
- * @return The presence's idle time.
- */
--time_t gaim_presence_get_idle_time(const GaimPresence *presence);
-+time_t gaim2_presence_get_idle_time(const Gaim2Presence *presence);
-
- /**
- * Returns the presence's login time.
-@@ -976,7 +976,7 @@ time_t gaim_presence_get_idle_time(const
- *
- * @return The presence's login time.
- */
--time_t gaim_presence_get_login_time(const GaimPresence *presence);
-+time_t gaim2_presence_get_login_time(const Gaim2Presence *presence);
-
- /**
- * Compares two presences for availability.
-@@ -988,8 +988,8 @@ time_t gaim_presence_get_login_time(cons
- * 0 if @a presence1 is equal to @a presence2.
- * 1 if @a presence1 is less available than @a presence2.
- */
--gint gaim_presence_compare(const GaimPresence *presence1,
-- const GaimPresence *presence2);
-+gint gaim2_presence_compare(const Gaim2Presence *presence1,
-+ const Gaim2Presence *presence2);
-
- /*@}*/
-
-@@ -1003,17 +1003,17 @@ gint gaim_presence_compare(const GaimPre
- *
- * @return the handle to the status subsystem
- */
--void *gaim_status_get_handle(void);
-+void *gaim2_status_get_handle(void);
-
- /**
- * Initializes the status subsystem.
- */
--void gaim_status_init(void);
-+void gaim2_status_init(void);
-
- /**
- * Uninitializes the status subsystem.
- */
--void gaim_status_uninit(void);
-+void gaim2_status_uninit(void);
-
- /*@}*/
-
-diff -prNu ./src/stringref.c ./src/stringref.c
---- ./src/stringref.c 2004-01-11 07:10:22.000000000 +0100
-+++ ./src/stringref.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file stringref.c Reference-counted immutable strings
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -36,31 +36,31 @@
-
- static GList *gclist = NULL;
-
--static void stringref_free(GaimStringref *stringref);
-+static void stringref_free(Gaim2Stringref *stringref);
- static gboolean gs_idle_cb(gpointer data);
-
--GaimStringref *gaim_stringref_new(const char *value)
-+Gaim2Stringref *gaim2_stringref_new(const char *value)
- {
-- GaimStringref *newref;
-+ Gaim2Stringref *newref;
-
- if (value == NULL)
- return NULL;
-
-- newref = g_malloc(sizeof(GaimStringref) + strlen(value));
-+ newref = g_malloc(sizeof(Gaim2Stringref) + strlen(value));
- strcpy(newref->value, value);
- newref->ref = 1;
-
- return newref;
- }
-
--GaimStringref *gaim_stringref_new_noref(const char *value)
-+Gaim2Stringref *gaim2_stringref_new_noref(const char *value)
- {
-- GaimStringref *newref;
-+ Gaim2Stringref *newref;
-
- if (value == NULL)
- return NULL;
-
-- newref = g_malloc(sizeof(GaimStringref) + strlen(value));
-+ newref = g_malloc(sizeof(Gaim2Stringref) + strlen(value));
- strcpy(newref->value, value);
- newref->ref = 0x80000000;
-
-@@ -71,16 +71,16 @@ GaimStringref *gaim_stringref_new_noref(
- return newref;
- }
-
--GaimStringref *gaim_stringref_printf(const char *format, ...)
-+Gaim2Stringref *gaim2_stringref_printf(const char *format, ...)
- {
-- GaimStringref *newref;
-+ Gaim2Stringref *newref;
- va_list ap;
-
- if (format == NULL)
- return NULL;
-
- va_start(ap, format);
-- newref = g_malloc(sizeof(GaimStringref) + g_printf_string_upper_bound(format, ap));
-+ newref = g_malloc(sizeof(Gaim2Stringref) + g_printf_string_upper_bound(format, ap));
- vsprintf(newref->value, format, ap);
- va_end(ap);
- newref->ref = 1;
-@@ -88,7 +88,7 @@ GaimStringref *gaim_stringref_printf(con
- return newref;
- }
-
--GaimStringref *gaim_stringref_ref(GaimStringref *stringref)
-+Gaim2Stringref *gaim2_stringref_ref(Gaim2Stringref *stringref)
- {
- if (stringref == NULL)
- return NULL;
-@@ -96,7 +96,7 @@ GaimStringref *gaim_stringref_ref(GaimSt
- return stringref;
- }
-
--void gaim_stringref_unref(GaimStringref *stringref)
-+void gaim2_stringref_unref(Gaim2Stringref *stringref)
- {
- if (stringref == NULL)
- return;
-@@ -107,26 +107,26 @@ void gaim_stringref_unref(GaimStringref
- }
- }
-
--const char *gaim_stringref_value(const GaimStringref *stringref)
-+const char *gaim2_stringref_value(const Gaim2Stringref *stringref)
- {
- return (stringref == NULL ? NULL : stringref->value);
- }
-
--int gaim_stringref_cmp(const GaimStringref *s1, const GaimStringref *s2)
-+int gaim2_stringref_cmp(const Gaim2Stringref *s1, const Gaim2Stringref *s2)
- {
-- return (s1 == s2 ? 0 : strcmp(gaim_stringref_value(s1), gaim_stringref_value(s2)));
-+ return (s1 == s2 ? 0 : strcmp(gaim2_stringref_value(s1), gaim2_stringref_value(s2)));
- }
-
--size_t gaim_stringref_len(const GaimStringref *stringref)
-+size_t gaim2_stringref_len(const Gaim2Stringref *stringref)
- {
-- return strlen(gaim_stringref_value(stringref));
-+ return strlen(gaim2_stringref_value(stringref));
- }
-
--static void stringref_free(GaimStringref *stringref)
-+static void stringref_free(Gaim2Stringref *stringref)
- {
- #ifdef DEBUG
- if (REFCOUNT(stringref->ref) != 0) {
-- gaim_debug(GAIM_DEBUG_ERROR, "stringref", "Free of nonzero (%d) ref stringref!\n", REFCOUNT(stringref->ref));
-+ gaim2_debug(GAIM_DEBUG_ERROR, "stringref", "Free of nonzero (%d) ref stringref!\n", REFCOUNT(stringref->ref));
- return;
- }
- #endif /* DEBUG */
-@@ -135,7 +135,7 @@ static void stringref_free(GaimStringref
-
- static gboolean gs_idle_cb(gpointer data)
- {
-- GaimStringref *ref;
-+ Gaim2Stringref *ref;
- GList *del;
-
- while (gclist != NULL) {
-diff -prNu ./src/stringref.h ./src/stringref.h
---- ./src/stringref.h 2004-08-08 07:37:58.000000000 +0200
-+++ ./src/stringref.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file stringref.h Reference-counted immutable strings
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -33,7 +33,7 @@
- * it must be immutable -- for this reason, do _not_ access it
- * directly!
- */
--typedef struct _GaimStringref {
-+typedef struct _Gaim2Stringref {
- guint32 ref; /**< The reference count of this string.
- * Note that reference counts are only
- * 31 bits, and the high-order bit
-@@ -45,7 +45,7 @@ typedef struct _GaimStringref {
- * Notice that it is simply "hanging
- * off the end" of the ref ... this
- * is to save an allocation. */
--} GaimStringref;
-+} Gaim2Stringref;
-
- /**
- * Creates an immutable reference-counted string object. The newly
-@@ -57,7 +57,7 @@ typedef struct _GaimStringref {
- * @return A newly allocated string reference object with a refcount
- * of 1.
- */
--GaimStringref *gaim_stringref_new(const char *value);
-+Gaim2Stringref *gaim2_stringref_new(const char *value);
-
- /**
- * Creates an immutable reference-counted string object. The newly
-@@ -71,7 +71,7 @@ GaimStringref *gaim_stringref_new(const
- * @return A newly allocated string reference object with a refcount
- * of zero.
- */
--GaimStringref *gaim_stringref_new_noref(const char *value);
-+Gaim2Stringref *gaim2_stringref_new_noref(const char *value);
-
- /**
- * Creates an immutable reference-counted string object from a printf
-@@ -83,7 +83,7 @@ GaimStringref *gaim_stringref_new_noref(
- * @return A newly allocated string reference object with a refcount
- * of 1.
- */
--GaimStringref *gaim_stringref_printf(const char *format, ...);
-+Gaim2Stringref *gaim2_stringref_printf(const char *format, ...);
-
- /**
- * Increase the reference count of the given stringref.
-@@ -92,7 +92,7 @@ GaimStringref *gaim_stringref_printf(con
- *
- * @return A pointer to the referenced string.
- */
--GaimStringref *gaim_stringref_ref(GaimStringref *stringref);
-+Gaim2Stringref *gaim2_stringref_ref(Gaim2Stringref *stringref);
-
- /**
- * Decrease the reference count of the given stringref. If this
-@@ -101,7 +101,7 @@ GaimStringref *gaim_stringref_ref(GaimSt
- *
- * @param stringref String to be dereferenced.
- */
--void gaim_stringref_unref(GaimStringref *stringref);
-+void gaim2_stringref_unref(Gaim2Stringref *stringref);
-
- /**
- * Retrieve the value of a stringref.
-@@ -119,7 +119,7 @@ void gaim_stringref_unref(GaimStringref
- *
- * @return The contents of the string reference.
- */
--const char *gaim_stringref_value(const GaimStringref *stringref);
-+const char *gaim2_stringref_value(const Gaim2Stringref *stringref);
-
- /**
- * Compare two stringrefs for string equality. This returns the same
-@@ -132,7 +132,7 @@ const char *gaim_stringref_value(const G
- *
- * @return An ordering indication on s1 and s2.
- */
--int gaim_stringref_cmp(const GaimStringref *s1, const GaimStringref *s2);
-+int gaim2_stringref_cmp(const Gaim2Stringref *s1, const Gaim2Stringref *s2);
-
- /**
- * Find the length of the string inside a stringref.
-@@ -141,6 +141,6 @@ int gaim_stringref_cmp(const GaimStringr
- *
- * @return The length of the string in stringref
- */
--size_t gaim_stringref_len(const GaimStringref *stringref);
-+size_t gaim2_stringref_len(const Gaim2Stringref *stringref);
-
- #endif /* _GAIM_STRINGREF_H_ */
-diff -prNu ./src/stun.c ./src/stun.c
---- ./src/stun.c 2006-01-03 19:16:04.000000000 +0100
-+++ ./src/stun.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,11 +2,11 @@
- * @file stun.c STUN (RFC3489) Implementation
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
- * STUN implementation inspired by jstun [http://jstun.javawi.de/]
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -62,7 +62,7 @@ struct stun_change {
- char value[4];
- };
-
--static GaimStunNatDiscovery nattype = {-1, 0, "\0"};
-+static Gaim2StunNatDiscovery nattype = {-1, 0, "\0"};
-
- static GSList *callbacks = 0;
- static int fd = -1;
-@@ -89,7 +89,7 @@ static gboolean timeoutfunc(void *blah)
- nattype.type = GAIM_STUN_NAT_TYPE_SYMMETRIC;
-
- /* remove input */
-- gaim_input_remove(incb);
-+ gaim2_input_remove(incb);
-
- /* set unknown */
- nattype.status = GAIM_STUN_STATUS_UNKNOWN;
-@@ -121,11 +121,11 @@ static void do_test2() {
- retry = 0;
- test = 2;
- sendto(fd, packet, packetsize, 0, (struct sockaddr *)&addr, sizeof(struct sockaddr_in));
-- timeout = gaim_timeout_add(500, (GSourceFunc)timeoutfunc, NULL);
-+ timeout = gaim2_timeout_add(500, (GSourceFunc)timeoutfunc, NULL);
- }
- #endif
-
--static void reply_cb(gpointer data, gint source, GaimInputCondition cond) {
-+static void reply_cb(gpointer data, gint source, Gaim2InputCondition cond) {
- char buffer[1024];
- char *tmp;
- int len;
-@@ -140,7 +140,7 @@ static void reply_cb(gpointer data, gint
-
- hdr = (struct stun_header*)buffer;
- if(hdr->transid[0]!=packet->transid[0] || hdr->transid[1]!=packet->transid[1] || hdr->transid[2]!=packet->transid[2] || hdr->transid[3]!=packet->transid[3]) { /* wrong transaction */
-- gaim_debug_info("stun", "got wrong transid\n");
-+ gaim2_debug_info("stun", "got wrong transid\n");
- return;
- }
- if(test==1) {
-@@ -154,7 +154,7 @@ static void reply_cb(gpointer data, gint
- }
- tmp += sizeof(struct stun_attrib) + attrib->len;
- }
-- gaim_debug_info("stun", "got public ip %s\n", nattype.publicip);
-+ gaim2_debug_info("stun", "got public ip %s\n", nattype.publicip);
- nattype.status = GAIM_STUN_STATUS_DISCOVERED;
- nattype.type = GAIM_STUN_NAT_TYPE_UNKNOWN_NAT;
-
-@@ -175,12 +175,12 @@ static void reply_cb(gpointer data, gint
- sinptr = (struct sockaddr_in *) &ifr->ifr_addr;
- if(sinptr->sin_addr.s_addr == in.s_addr) {
- /* no NAT */
-- gaim_debug_info("stun", "no nat");
-+ gaim2_debug_info("stun", "no nat");
- nattype.type = GAIM_STUN_NAT_TYPE_PUBLIC_IP;
- }
- }
- }
-- gaim_timeout_remove(timeout);
-+ gaim2_timeout_remove(timeout);
-
- #ifdef NOTYET
- do_test2();
-@@ -188,8 +188,8 @@ static void reply_cb(gpointer data, gint
- return;
- } else if(test == 2) {
- do_callbacks();
-- gaim_input_remove(incb);
-- gaim_timeout_remove(timeout);
-+ gaim2_input_remove(incb);
-+ gaim2_timeout_remove(timeout);
- nattype.type = GAIM_STUN_NAT_TYPE_FULL_CONE;
- }
- }
-@@ -218,7 +218,7 @@ static void hbn_cb(GSList *hosts, gpoint
- do_callbacks();
- return;
- }
-- incb = gaim_input_add(fd, GAIM_INPUT_READ, reply_cb, NULL);
-+ incb = gaim2_input_add(fd, GAIM_INPUT_READ, reply_cb, NULL);
-
- ret = GPOINTER_TO_INT(hosts->data);
- hosts = g_slist_remove(hosts, hosts->data);
-@@ -246,10 +246,10 @@ static void hbn_cb(GSList *hosts, gpoint
- test = 1;
- packet = &data;
- packetsize = sizeof(struct stun_header);
-- timeout = gaim_timeout_add(500, (GSourceFunc)timeoutfunc, NULL);
-+ timeout = gaim2_timeout_add(500, (GSourceFunc)timeoutfunc, NULL);
- }
-
--static void do_test1(GaimSrvResponse *resp, int results, gpointer sdata) {
-+static void do_test1(Gaim2SrvResponse *resp, int results, gpointer sdata) {
- const char *servername = sdata;
- int port = 3478;
-
-@@ -257,16 +257,16 @@ static void do_test1(GaimSrvResponse *re
- servername = resp[0].hostname;
- port = resp[0].port;
- }
-- gaim_debug_info("stun", "got %d SRV responses, server: %s, port: %d\n", results, servername, port);
-+ gaim2_debug_info("stun", "got %d SRV responses, server: %s, port: %d\n", results, servername, port);
-
-- gaim_gethostbyname_async(servername, port, hbn_cb, NULL);
-+ gaim2_gethostbyname_async(servername, port, hbn_cb, NULL);
- g_free(resp);
- }
-
--GaimStunNatDiscovery *gaim_stun_discover(StunCallback cb) {
-- const char *servername = gaim_prefs_get_string("/core/network/stun_server");
-+Gaim2StunNatDiscovery *gaim2_stun_discover(StunCallback cb) {
-+ const char *servername = gaim2_prefs_get_string("/core/network/stun_server");
-
-- gaim_debug_info("stun", "using server %s\n", servername);
-+ gaim2_debug_info("stun", "using server %s\n", servername);
-
- if(nattype.status == GAIM_STUN_STATUS_DISCOVERING) {
- if(cb)
-@@ -287,11 +287,11 @@ GaimStunNatDiscovery *gaim_stun_discover
- return &nattype;
- }
- callbacks = g_slist_append(callbacks, cb);
-- gaim_srv_resolve("stun", "udp", servername, do_test1,
-+ gaim2_srv_resolve("stun", "udp", servername, do_test1,
- (gpointer) servername);
- return &nattype;
- }
-
--void gaim_stun_init() {
-- gaim_prefs_add_string("/core/network/stun_server", "");
-+void gaim2_stun_init() {
-+ gaim2_prefs_add_string("/core/network/stun_server", "");
- }
-diff -prNu ./src/stun.h ./src/stun.h
---- ./src/stun.h 2006-01-03 01:23:24.000000000 +0100
-+++ ./src/stun.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file stun.h STUN API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -30,14 +30,14 @@
- /**************************************************************************/
- /*@{*/
-
--typedef struct _GaimStunNatDiscovery GaimStunNatDiscovery;
-+typedef struct _Gaim2StunNatDiscovery Gaim2StunNatDiscovery;
-
- typedef enum {
- GAIM_STUN_STATUS_UNDISCOVERED = -1,
- GAIM_STUN_STATUS_UNKNOWN, /* no STUN server reachable */
- GAIM_STUN_STATUS_DISCOVERING,
- GAIM_STUN_STATUS_DISCOVERED
--} GaimStunStatus;
-+} Gaim2StunStatus;
-
- typedef enum {
- GAIM_STUN_NAT_TYPE_PUBLIC_IP,
-@@ -46,18 +46,18 @@ typedef enum {
- GAIM_STUN_NAT_TYPE_RESTRICTED_CONE,
- GAIM_STUN_NAT_TYPE_PORT_RESTRICTED_CONE,
- GAIM_STUN_NAT_TYPE_SYMMETRIC
--} GaimStunNatType;
-+} Gaim2StunNatType;
-
--struct _GaimStunNatDiscovery {
-- GaimStunStatus status;
-- GaimStunNatType type;
-+struct _Gaim2StunNatDiscovery {
-+ Gaim2StunStatus status;
-+ Gaim2StunNatType type;
- char publicip[16];
- };
-
--typedef void (*StunCallback) (GaimStunNatDiscovery *);
-+typedef void (*StunCallback) (Gaim2StunNatDiscovery *);
-
- /**
-- * Starts a NAT discovery. It returns a GaimStunNatDiscovery if the discovery
-+ * Starts a NAT discovery. It returns a Gaim2StunNatDiscovery if the discovery
- * is already done. Otherwise the callback is called when the discovery is over
- * and NULL is returned.
- *
-@@ -65,12 +65,12 @@ typedef void (*StunCallback) (GaimStunNa
- * discovery would block. If the discovery is done, this is NOT
- * called.
- *
-- * @return a GaimStunNatDiscovery which includes the public IP and the type
-+ * @return a Gaim2StunNatDiscovery which includes the public IP and the type
- * of NAT or NULL is discovery would block
- */
--GaimStunNatDiscovery *gaim_stun_discover(StunCallback cb);
-+Gaim2StunNatDiscovery *gaim2_stun_discover(StunCallback cb);
-
--void gaim_stun_init(void);
-+void gaim2_stun_init(void);
-
- /*@}*/
-
-diff -prNu ./src/upnp.c ./src/upnp.c
---- ./src/upnp.c 2006-01-05 06:56:13.000000000 +0100
-+++ ./src/upnp.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file upnp.c UPnP Implementation
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -23,7 +23,7 @@
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
- #include "internal.h"
--#include "gaim.h"
-+#include "gaim2.h"
-
- #include "debug.h"
- #include "util.h"
-@@ -39,8 +39,8 @@
- */
- typedef struct
- {
-- guint inpa; /* gaim_input_add handle */
-- guint tima; /* gaim_timout_add handle */
-+ guint inpa; /* gaim2_input_add handle */
-+ guint tima; /* gaim2_timout_add handle */
- gchar* sendBuffer; /* send data */
- gchar* recvBuffer; /* response data */
- guint totalSizeRecv;
-@@ -133,12 +133,12 @@ typedef struct
-
-
- static void
--gaim_upnp_timeout(gpointer data, gint source, GaimInputCondition cond)
-+gaim2_upnp_timeout(gpointer data, gint source, Gaim2InputCondition cond)
- {
- NetResponseData* nrd = data;
-
-- gaim_input_remove(nrd->inpa);
-- gaim_timeout_remove(nrd->tima);
-+ gaim2_input_remove(nrd->inpa);
-+ gaim2_timeout_remove(nrd->tima);
-
- if(nrd->totalSizeRecv == 0 && nrd->recvBuffer != NULL) {
- g_free(nrd->recvBuffer);
-@@ -152,7 +152,7 @@ gaim_upnp_timeout(gpointer data, gint so
-
-
- static void
--gaim_upnp_http_read(gpointer data, gint sock, GaimInputCondition cond)
-+gaim2_upnp_http_read(gpointer data, gint sock, Gaim2InputCondition cond)
- {
- int sizeRecv;
- NetResponseData* nrd = data;
-@@ -160,12 +160,12 @@ gaim_upnp_http_read(gpointer data, gint
- sizeRecv = recv(sock, &(nrd->recvBuffer[nrd->totalSizeRecv]),
- MAX_DESCRIPTION_RECEIVE_SIZE-nrd->totalSizeRecv, 0);
- if(sizeRecv < 0 && errno != EINTR) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_http_read(): recv < 0: %i!\n\n", errno);
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_http_read(): recv < 0: %i!\n\n", errno);
- g_free(nrd->recvBuffer);
- nrd->recvBuffer = NULL;
-- gaim_timeout_remove(nrd->tima);
-- gaim_input_remove(nrd->inpa);
-+ gaim2_timeout_remove(nrd->tima);
-+ gaim2_input_remove(nrd->inpa);
- nrd->done = TRUE;
- return;
- }else if(errno == EINTR) {
-@@ -174,11 +174,11 @@ gaim_upnp_http_read(gpointer data, gint
- nrd->totalSizeRecv += sizeRecv;
-
- if(sizeRecv == 0) {
-- gaim_timeout_remove(nrd->tima);
-- gaim_input_remove(nrd->inpa);
-+ gaim2_timeout_remove(nrd->tima);
-+ gaim2_input_remove(nrd->inpa);
- if(nrd->totalSizeRecv == 0) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_http_read(): totalSizeRecv == 0\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_http_read(): totalSizeRecv == 0\n\n");
- g_free(nrd->recvBuffer);
- nrd->recvBuffer = NULL;
- } else {
-@@ -186,29 +186,29 @@ gaim_upnp_http_read(gpointer data, gint
- }
- nrd->done = TRUE;
- } else {
-- gaim_timeout_remove(nrd->tima);
-- gaim_input_remove(nrd->inpa);
-- nrd->tima = gaim_timeout_add(CONSECUTIVE_RECEIVE_TIMEOUT,
-- (GSourceFunc)gaim_upnp_timeout, nrd);
-- nrd->inpa = gaim_input_add(sock, GAIM_INPUT_READ,
-- gaim_upnp_http_read, nrd);
-+ gaim2_timeout_remove(nrd->tima);
-+ gaim2_input_remove(nrd->inpa);
-+ nrd->tima = gaim2_timeout_add(CONSECUTIVE_RECEIVE_TIMEOUT,
-+ (GSourceFunc)gaim2_upnp_timeout, nrd);
-+ nrd->inpa = gaim2_input_add(sock, GAIM_INPUT_READ,
-+ gaim2_upnp_http_read, nrd);
- }
- }
-
-
- static void
--gaim_upnp_http_send(gpointer data, gint sock, GaimInputCondition cond)
-+gaim2_upnp_http_send(gpointer data, gint sock, Gaim2InputCondition cond)
- {
- gsize sizeSent, totalSizeSent = 0;
- NetResponseData* nrd = data;
-
-- gaim_timeout_remove(nrd->tima);
-+ gaim2_timeout_remove(nrd->tima);
- while(totalSizeSent < strlen(nrd->sendBuffer)) {
- sizeSent = send(sock,(gchar*)(nrd->sendBuffer+totalSizeSent),
- strlen(nrd->sendBuffer)-totalSizeSent,0);
- if(sizeSent <= 0 && errno != EINTR) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_http_request(): Failed In send\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_http_request(): Failed In send\n\n");
- nrd->done = TRUE;
- g_free(nrd->recvBuffer);
- nrd->recvBuffer = NULL;
-@@ -220,10 +220,10 @@ gaim_upnp_http_send(gpointer data, gint
- totalSizeSent += sizeSent;
- }
-
-- nrd->tima = gaim_timeout_add(RECEIVE_TIMEOUT,
-- (GSourceFunc)gaim_upnp_timeout, nrd);
-- nrd->inpa = gaim_input_add(sock, GAIM_INPUT_READ,
-- gaim_upnp_http_read, nrd);
-+ nrd->tima = gaim2_timeout_add(RECEIVE_TIMEOUT,
-+ (GSourceFunc)gaim2_upnp_timeout, nrd);
-+ nrd->inpa = gaim2_input_add(sock, GAIM_INPUT_READ,
-+ gaim2_upnp_http_read, nrd);
- while (!nrd->done) {
- g_main_context_iteration(NULL, TRUE);
- }
-@@ -232,22 +232,22 @@ gaim_upnp_http_send(gpointer data, gint
-
-
- static gchar*
--gaim_upnp_http_request(const gchar* address, int port, gchar* httpRequest)
-+gaim2_upnp_http_request(const gchar* address, int port, gchar* httpRequest)
- {
- gchar* recvBuffer;
- NetResponseData* nrd = (NetResponseData*)g_malloc0(sizeof(NetResponseData));
- nrd->sendBuffer = httpRequest;
- nrd->recvBuffer = (gchar*)g_malloc(MAX_DESCRIPTION_RECEIVE_SIZE);
-
-- nrd->tima = gaim_timeout_add(RECEIVE_TIMEOUT,
-- (GSourceFunc)gaim_upnp_timeout, nrd);
-+ nrd->tima = gaim2_timeout_add(RECEIVE_TIMEOUT,
-+ (GSourceFunc)gaim2_upnp_timeout, nrd);
-
-- if(gaim_proxy_connect(NULL, address, port, gaim_upnp_http_send, nrd)) {
-+ if(gaim2_proxy_connect(NULL, address, port, gaim2_upnp_http_send, nrd)) {
-
-- gaim_debug_error("upnp", "Connect Failed: Address: %s @@@ Port %d @@@ Request %s\n\n",
-+ gaim2_debug_error("upnp", "Connect Failed: Address: %s @@@ Port %d @@@ Request %s\n\n",
- address, port, nrd->sendBuffer);
-
-- gaim_timeout_remove(nrd->tima);
-+ gaim2_timeout_remove(nrd->tima);
- g_free(nrd->recvBuffer);
- nrd->recvBuffer = NULL;
- } else {
-@@ -264,7 +264,7 @@ gaim_upnp_http_request(const gchar* addr
-
-
- static gboolean
--gaim_upnp_compare_device(const xmlnode* device, const gchar* deviceType)
-+gaim2_upnp_compare_device(const xmlnode* device, const gchar* deviceType)
- {
- xmlnode* deviceTypeNode = xmlnode_get_child(device, "deviceType");
- if(deviceTypeNode == NULL) {
-@@ -275,7 +275,7 @@ gaim_upnp_compare_device(const xmlnode*
-
-
- static gboolean
--gaim_upnp_compare_service(const xmlnode* service, const gchar* serviceType)
-+gaim2_upnp_compare_service(const xmlnode* service, const gchar* serviceType)
- {
- xmlnode* serviceTypeNode = xmlnode_get_child(service, "serviceType");
- if(serviceTypeNode == NULL) {
-@@ -287,7 +287,7 @@ gaim_upnp_compare_service(const xmlnode*
-
-
- static gchar*
--gaim_upnp_parse_description_response(const gchar* httpResponse,
-+gaim2_upnp_parse_description_response(const gchar* httpResponse,
- const gchar* httpURL, const gchar* serviceType)
- {
- gchar* xmlRoot;
-@@ -301,7 +301,7 @@ gaim_upnp_parse_description_response(con
-
- /* make sure we have a valid http response */
- if(g_strstr_len(httpResponse, strlen(httpResponse), HTTP_OK) == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): Failed In HTTP_OK\n\n");
- return NULL;
- }
-@@ -309,14 +309,14 @@ gaim_upnp_parse_description_response(con
- /* find the root of the xml document */
- if((xmlRoot = g_strstr_len(httpResponse, strlen(httpResponse),
- "<root")) == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): Failed finding root\n\n");
- return NULL;
- }
-
- /* create the xml root node */
- if((xmlRootNode = xmlnode_from_str(xmlRoot, -1)) == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): Could not parse xml root node\n\n");
- return NULL;
- }
-@@ -332,13 +332,13 @@ gaim_upnp_parse_description_response(con
-
- /* get urn:schemas-upnp-org:device:InternetGatewayDevice:1 and its devicelist */
- serviceTypeNode = xmlnode_get_child(xmlRootNode, "device");
-- while(!gaim_upnp_compare_device(serviceTypeNode,
-+ while(!gaim2_upnp_compare_device(serviceTypeNode,
- "urn:schemas-upnp-org:device:InternetGatewayDevice:1") &&
- serviceTypeNode != NULL) {
- serviceTypeNode = xmlnode_get_next_twin(serviceTypeNode);
- }
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 1\n\n");
- return NULL;
- g_free(baseURL);
-@@ -346,7 +346,7 @@ gaim_upnp_parse_description_response(con
- }
- serviceTypeNode = xmlnode_get_child(serviceTypeNode, "deviceList");
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 2\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -355,13 +355,13 @@ gaim_upnp_parse_description_response(con
-
- /* get urn:schemas-upnp-org:device:WANDevice:1 and its devicelist */
- serviceTypeNode = xmlnode_get_child(serviceTypeNode, "device");
-- while(!gaim_upnp_compare_device(serviceTypeNode,
-+ while(!gaim2_upnp_compare_device(serviceTypeNode,
- "urn:schemas-upnp-org:device:WANDevice:1") &&
- serviceTypeNode != NULL) {
- serviceTypeNode = xmlnode_get_next_twin(serviceTypeNode);
- }
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 3\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -369,7 +369,7 @@ gaim_upnp_parse_description_response(con
- }
- serviceTypeNode = xmlnode_get_child(serviceTypeNode, "deviceList");
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 4\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -378,13 +378,13 @@ gaim_upnp_parse_description_response(con
-
- /* get urn:schemas-upnp-org:device:WANConnectionDevice:1 and its servicelist */
- serviceTypeNode = xmlnode_get_child(serviceTypeNode, "device");
-- while(!gaim_upnp_compare_device(serviceTypeNode,
-+ while(!gaim2_upnp_compare_device(serviceTypeNode,
- "urn:schemas-upnp-org:device:WANConnectionDevice:1") &&
- serviceTypeNode != NULL) {
- serviceTypeNode = xmlnode_get_next_twin(serviceTypeNode);
- }
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 5\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -392,7 +392,7 @@ gaim_upnp_parse_description_response(con
- }
- serviceTypeNode = xmlnode_get_child(serviceTypeNode, "serviceList");
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 6\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -402,14 +402,14 @@ gaim_upnp_parse_description_response(con
- /* get the serviceType variable passed to this function */
- service = g_strdup_printf(SEARCH_REQUEST_DEVICE, serviceType);
- serviceTypeNode = xmlnode_get_child(serviceTypeNode, "service");
-- while(!gaim_upnp_compare_service(serviceTypeNode, service) &&
-+ while(!gaim2_upnp_compare_service(serviceTypeNode, service) &&
- serviceTypeNode != NULL) {
- serviceTypeNode = xmlnode_get_next_twin(serviceTypeNode);
- }
-
- g_free(service);
- if(serviceTypeNode == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): could not get serviceTypeNode 7\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -419,7 +419,7 @@ gaim_upnp_parse_description_response(con
- /* get the controlURL of the service */
- if((controlURLNode = xmlnode_get_child(serviceTypeNode,
- "controlURL")) == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_description_response(): Could not find controlURL\n\n");
- g_free(baseURL);
- xmlnode_free(xmlRootNode);
-@@ -443,7 +443,7 @@ gaim_upnp_parse_description_response(con
-
-
- static gchar*
--gaim_upnp_parse_description(const gchar* descriptionURL, const gchar* serviceType)
-+gaim2_upnp_parse_description(const gchar* descriptionURL, const gchar* serviceType)
- {
- gchar* fullURL;
- gchar* controlURL;
-@@ -460,7 +460,7 @@ gaim_upnp_parse_description(const gchar*
- example description URL: http://192.168.1.1:5678/rootDesc.xml */
-
- /* parse the url into address, port, path variables */
-- if(!gaim_url_parse(descriptionURL, &descriptionAddress,
-+ if(!gaim2_url_parse(descriptionURL, &descriptionAddress,
- &port, &descriptionXMLAddress, NULL, NULL)) {
- return NULL;
- }
-@@ -478,11 +478,11 @@ gaim_upnp_parse_description(const gchar*
- httpRequest = g_strdup_printf("GET /%s HTTP/1.1\r\nHost: %s\r\n\r\n",
- descriptionXMLAddress, descriptionAddressPort);
-
-- httpResponse = gaim_upnp_http_request(descriptionAddress,
-+ httpResponse = gaim2_upnp_http_request(descriptionAddress,
- port, httpRequest);
- if(httpResponse == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_parse_description(): httpResponse is NULL\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_parse_description(): httpResponse is NULL\n\n");
- g_free(descriptionXMLAddress);
- g_free(descriptionAddress);
- g_free(descriptionAddressPort);
-@@ -491,7 +491,7 @@ gaim_upnp_parse_description(const gchar*
- return NULL;
- }
-
-- controlURL = gaim_upnp_parse_description_response(httpResponse,
-+ controlURL = gaim2_upnp_parse_description_response(httpResponse,
- fullURL, serviceType);
-
- g_free(descriptionXMLAddress);
-@@ -502,8 +502,8 @@ gaim_upnp_parse_description(const gchar*
- g_free(httpResponse);
-
- if(controlURL == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_parse_description(): controlURL is NULL\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_parse_description(): controlURL is NULL\n\n");
- }
-
- return controlURL;
-@@ -511,7 +511,7 @@ gaim_upnp_parse_description(const gchar*
-
-
- static gchar*
--gaim_upnp_parse_discover_response(const gchar* buf, unsigned int bufSize,
-+gaim2_upnp_parse_discover_response(const gchar* buf, unsigned int bufSize,
- const gchar* serviceType)
- {
- gchar* startDescURL;
-@@ -520,13 +520,13 @@ gaim_upnp_parse_discover_response(const
- gchar* retVal;
-
- if(g_strstr_len(buf, strlen(buf), HTTP_OK) == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_discover_response(): Failed In HTTP_OK\n\n");
- return NULL;
- }
-
- if((startDescURL = g_strstr_len(buf, strlen(buf), "http://")) == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_discover_response(): Failed In finding http://\n\n");
- return NULL;
- }
-@@ -535,36 +535,36 @@ gaim_upnp_parse_discover_response(const
- if(endDescURL == NULL) {
- endDescURL = g_strstr_len(startDescURL, strlen(startDescURL), "\n");
- if(endDescURL == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_discover_response(): Failed In endDescURL\n\n");
- return NULL;
- }else if(endDescURL == startDescURL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_discover_response(): endDescURL == startDescURL\n\n");
- return NULL;
- }
- }else if(endDescURL == startDescURL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "parse_discover_response(): 2nd endDescURL == startDescURL\n\n");
- return NULL;
- }
- descURL = g_strndup(startDescURL, endDescURL-startDescURL);
-
-- retVal = gaim_upnp_parse_description(descURL, serviceType);
-+ retVal = gaim2_upnp_parse_description(descURL, serviceType);
- g_free(descURL);
- return retVal;
- }
-
-
- static void
--gaim_upnp_discover_udp_read(gpointer data, gint sock, GaimInputCondition cond)
-+gaim2_upnp_discover_udp_read(gpointer data, gint sock, Gaim2InputCondition cond)
- {
- unsigned int length;
- struct sockaddr_in from;
- int sizeRecv;
- NetResponseData* nrd = data;
-
-- gaim_timeout_remove(nrd->tima);
-+ gaim2_timeout_remove(nrd->tima);
- length = sizeof(struct sockaddr_in);
-
- do {
-@@ -580,14 +580,14 @@ gaim_upnp_discover_udp_read(gpointer dat
- }
- }while(errno == EINTR);
-
-- gaim_input_remove(nrd->inpa);
-+ gaim2_input_remove(nrd->inpa);
- nrd->done = TRUE;
- return;
- }
-
-
--GaimUPnPControlInfo*
--gaim_upnp_discover(void)
-+Gaim2UPnPControlInfo*
-+gaim2_upnp_discover(void)
- {
- /* Socket Setup Variables */
- int sock, i;
-@@ -604,14 +604,14 @@ gaim_upnp_discover(void)
- gchar* sendMessage = NULL;
-
- /* UDP RECEIVE VARIABLES */
-- GaimUPnPControlInfo* controlInfo = g_malloc(sizeof(GaimUPnPControlInfo));
-+ Gaim2UPnPControlInfo* controlInfo = g_malloc(sizeof(Gaim2UPnPControlInfo));
- NetResponseData* nrd = g_malloc(sizeof(NetResponseData));
-
- /* Set up the sockets */
- sock = socket(AF_INET, SOCK_DGRAM, 0);
- if (sock == -1) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_discover(): Failed In sock creation\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_discover(): Failed In sock creation\n\n");
- g_free(nrd);
- g_free(controlInfo);
- return NULL;
-@@ -620,8 +620,8 @@ gaim_upnp_discover(void)
- server.sin_family = AF_INET;
- if((hp = gethostbyname(HTTPMU_HOST_ADDRESS)) == NULL) {
- close(sock);
-- gaim_debug_error("upnp",
-- "gaim_upnp_discover(): Failed In gethostbyname\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_discover(): Failed In gethostbyname\n\n");
- g_free(nrd);
- g_free(controlInfo);
- return NULL;
-@@ -671,10 +671,10 @@ gaim_upnp_discover(void)
- }
-
- if(sentSuccess) {
-- nrd->tima = gaim_timeout_add(DISCOVERY_TIMEOUT,
-- (GSourceFunc)gaim_upnp_timeout, nrd);
-- nrd->inpa = gaim_input_add(sock, GAIM_INPUT_READ,
-- gaim_upnp_discover_udp_read, nrd);
-+ nrd->tima = gaim2_timeout_add(DISCOVERY_TIMEOUT,
-+ (GSourceFunc)gaim2_upnp_timeout, nrd);
-+ nrd->inpa = gaim2_input_add(sock, GAIM_INPUT_READ,
-+ gaim2_upnp_discover_udp_read, nrd);
- while (!nrd->done) {
- g_main_context_iteration(NULL, TRUE);
- }
-@@ -684,11 +684,11 @@ gaim_upnp_discover(void)
- /* parse the response, and see if it was a success */
- close(sock);
- if((controlInfo->controlURL=
-- gaim_upnp_parse_discover_response(nrd->recvBuffer,
-+ gaim2_upnp_parse_discover_response(nrd->recvBuffer,
- strlen(nrd->recvBuffer),
- serviceToUse))==NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_discover(): Failed In parse response\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_discover(): Failed In parse response\n\n");
- g_free(nrd->recvBuffer);
- g_free(nrd);
- g_free(controlInfo);
-@@ -711,8 +711,8 @@ gaim_upnp_discover(void)
-
- if(!sentSuccess || !recvSuccess) {
- close(sock);
-- gaim_debug_error("upnp",
-- "gaim_upnp_discover(): Failed In sent/recv success\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_discover(): Failed In sent/recv success\n\n");
- g_free(controlInfo);
- return NULL;
- }
-@@ -722,7 +722,7 @@ gaim_upnp_discover(void)
-
-
- static char*
--gaim_upnp_generate_action_message_and_send(const GaimUPnPControlInfo* controlInfo,
-+gaim2_upnp_generate_action_message_and_send(const Gaim2UPnPControlInfo* controlInfo,
- const gchar* actionName, const gchar* actionParams)
- {
- gchar* actionMessage;
-@@ -741,9 +741,9 @@ gaim_upnp_generate_action_message_and_se
- controlInfo->serviceType, actionParams, actionName);
-
- /* parse the url into address, port, path variables */
-- if(!gaim_url_parse(controlInfo->controlURL, &addressOfControl,
-+ if(!gaim2_url_parse(controlInfo->controlURL, &addressOfControl,
- &port, &pathOfControl, NULL, NULL)) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "generate_action_message_and_send(): Failed In Parse URL\n\n");
- g_free(soapMessage);
- return NULL;
-@@ -768,10 +768,10 @@ gaim_upnp_generate_action_message_and_se
- totalSendMessage = g_strdup_printf("%s%s", actionMessage, soapMessage);
-
- /* get the return of the http response */
-- httpResponse = gaim_upnp_http_request(addressOfControl,
-+ httpResponse = gaim2_upnp_http_request(addressOfControl,
- port, totalSendMessage);
- if(httpResponse == NULL) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "generate_action_message_and_send(): Failed In httpResponse\n\n");
- }
-
-@@ -787,7 +787,7 @@ gaim_upnp_generate_action_message_and_se
-
-
- gchar*
--gaim_upnp_get_public_ip(const GaimUPnPControlInfo* controlInfo)
-+gaim2_upnp_get_public_ip(const Gaim2UPnPControlInfo* controlInfo)
- {
- gchar* extIPAddress;
- gchar* httpResponse;
-@@ -795,31 +795,31 @@ gaim_upnp_get_public_ip(const GaimUPnPCo
- gchar actionParams[] = "";
- gchar* temp, *temp2;
-
-- httpResponse = gaim_upnp_generate_action_message_and_send(controlInfo,
-+ httpResponse = gaim2_upnp_generate_action_message_and_send(controlInfo,
- actionName, actionParams);
- if(httpResponse == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_get_public_ip(): Failed In httpResponse\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_get_public_ip(): Failed In httpResponse\n\n");
- return NULL;
- }
-
- /* extract the ip, or see if there is an error */
- if((temp = g_strstr_len(httpResponse, strlen(httpResponse),
- "<NewExternalIPAddress")) == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_get_public_ip(): Failed Finding <NewExternalIPAddress\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_get_public_ip(): Failed Finding <NewExternalIPAddress\n\n");
- g_free(httpResponse);
- return NULL;
- }
- if((temp = g_strstr_len(temp, strlen(temp), ">")) == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_get_public_ip(): Failed In Finding >\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_get_public_ip(): Failed In Finding >\n\n");
- g_free(httpResponse);
- return NULL;
- }
- if((temp2 = g_strstr_len(temp, strlen(temp), "<")) == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_get_public_ip(): Failed In Finding <\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_get_public_ip(): Failed In Finding <\n\n");
- g_free(httpResponse);
- return NULL;
- }
-@@ -828,18 +828,18 @@ gaim_upnp_get_public_ip(const GaimUPnPCo
-
- g_free(httpResponse);
-
-- gaim_debug_info("upnp", "NAT Returned IP: %s\n", extIPAddress);
-+ gaim2_debug_info("upnp", "NAT Returned IP: %s\n", extIPAddress);
- return extIPAddress;
- }
-
-
- static void
--gaim_upnp_get_local_system_ip(gpointer data, gint sock, GaimInputCondition cond)
-+gaim2_upnp_get_local_system_ip(gpointer data, gint sock, Gaim2InputCondition cond)
- {
- NetResponseData* nrd = data;
-- nrd->recvBuffer = g_strdup(gaim_network_get_local_system_ip(sock));
-+ nrd->recvBuffer = g_strdup(gaim2_network_get_local_system_ip(sock));
-
-- gaim_timeout_remove(nrd->tima);
-+ gaim2_timeout_remove(nrd->tima);
- nrd->done = TRUE;
-
- close(sock);
-@@ -847,7 +847,7 @@ gaim_upnp_get_local_system_ip(gpointer d
-
-
- static gchar*
--gaim_upnp_get_local_ip_address(const gchar* address)
-+gaim2_upnp_get_local_ip_address(const gchar* address)
- {
- gchar* ip;
- gchar* pathOfControl;
-@@ -855,9 +855,9 @@ gaim_upnp_get_local_ip_address(const gch
- int port = 0;
- NetResponseData* nrd = (NetResponseData*)g_malloc0(sizeof(NetResponseData));
-
-- if(!gaim_url_parse(address, &addressOfControl, &port, &pathOfControl,
-+ if(!gaim2_url_parse(address, &addressOfControl, &port, &pathOfControl,
- NULL, NULL)) {
-- gaim_debug_error("upnp",
-+ gaim2_debug_error("upnp",
- "get_local_ip_address(): Failed In Parse URL\n\n");
- return NULL;
- }
-@@ -865,16 +865,16 @@ gaim_upnp_get_local_ip_address(const gch
- port = DEFAULT_HTTP_PORT;
- }
-
-- nrd->tima = gaim_timeout_add(RECEIVE_TIMEOUT,
-- (GSourceFunc)gaim_upnp_timeout, nrd);
-+ nrd->tima = gaim2_timeout_add(RECEIVE_TIMEOUT,
-+ (GSourceFunc)gaim2_upnp_timeout, nrd);
-
-- if(gaim_proxy_connect(NULL, addressOfControl, port,
-- gaim_upnp_get_local_system_ip, nrd)) {
-+ if(gaim2_proxy_connect(NULL, addressOfControl, port,
-+ gaim2_upnp_get_local_system_ip, nrd)) {
-
-- gaim_debug_error("upnp", "Get Local IP Connect Failed: Address: %s @@@ Port %d @@@ Request %s\n\n",
-+ gaim2_debug_error("upnp", "Get Local IP Connect Failed: Address: %s @@@ Port %d @@@ Request %s\n\n",
- address, port, nrd->sendBuffer);
-
-- gaim_timeout_remove(nrd->tima);
-+ gaim2_timeout_remove(nrd->tima);
- } else {
- while (!nrd->done) {
- g_main_context_iteration(NULL, TRUE);
-@@ -884,14 +884,14 @@ gaim_upnp_get_local_ip_address(const gch
- ip = nrd->recvBuffer;
- g_free(nrd);
-
-- gaim_debug_info("upnp", "local ip: %s\n", ip);
-+ gaim2_debug_info("upnp", "local ip: %s\n", ip);
-
- return ip;
- }
-
-
- gboolean
--gaim_upnp_set_port_mapping(const GaimUPnPControlInfo* controlInfo,
-+gaim2_upnp_set_port_mapping(const Gaim2UPnPControlInfo* controlInfo,
- unsigned short portMap, const gchar* protocol)
- {
- gchar* httpResponse;
-@@ -900,9 +900,9 @@ gaim_upnp_set_port_mapping(const GaimUPn
- gchar* internalIP;
-
- /* get the internal IP */
-- if((internalIP = gaim_upnp_get_local_ip_address(controlInfo->controlURL)) == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_set_port_mapping(): couldn't get local ip\n\n");
-+ if((internalIP = gaim2_upnp_get_local_ip_address(controlInfo->controlURL)) == NULL) {
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_set_port_mapping(): couldn't get local ip\n\n");
- return FALSE;
- }
-
-@@ -910,11 +910,11 @@ gaim_upnp_set_port_mapping(const GaimUPn
- actionParams = g_strdup_printf(ADD_PORT_MAPPING_PARAMS, portMap,
- protocol, portMap, internalIP);
-
-- httpResponse = gaim_upnp_generate_action_message_and_send(controlInfo,
-+ httpResponse = gaim2_upnp_generate_action_message_and_send(controlInfo,
- actionName, actionParams);
- if(httpResponse == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_set_port_mapping(): Failed In httpResponse\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_set_port_mapping(): Failed In httpResponse\n\n");
- g_free(actionParams);
- g_free(internalIP);
- return FALSE;
-@@ -922,8 +922,8 @@ gaim_upnp_set_port_mapping(const GaimUPn
-
- /* determine if port mapping was a success */
- if(strstr(httpResponse, HTTP_OK) == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_set_port_mapping(): Failed HTTP_OK\n\n%s\n\n", httpResponse);
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_set_port_mapping(): Failed HTTP_OK\n\n%s\n\n", httpResponse);
- g_free(actionParams);
- g_free(httpResponse);
- g_free(internalIP);
-@@ -933,7 +933,7 @@ gaim_upnp_set_port_mapping(const GaimUPn
- g_free(actionParams);
- g_free(httpResponse);
-
-- gaim_debug_info("upnp", "NAT Added Port Forward On Port: %d: To IP: %s\n",
-+ gaim2_debug_info("upnp", "NAT Added Port Forward On Port: %d: To IP: %s\n",
- portMap, internalIP);
- g_free(internalIP);
- return TRUE;
-@@ -941,7 +941,7 @@ gaim_upnp_set_port_mapping(const GaimUPn
-
-
- gboolean
--gaim_upnp_remove_port_mapping(const GaimUPnPControlInfo* controlInfo,
-+gaim2_upnp_remove_port_mapping(const Gaim2UPnPControlInfo* controlInfo,
- unsigned short portMap, const char* protocol)
- {
- gchar* httpResponse;
-@@ -952,20 +952,20 @@ gaim_upnp_remove_port_mapping(const Gaim
- actionParams = g_strdup_printf(DELETE_PORT_MAPPING_PARAMS, portMap,
- protocol);
-
-- httpResponse = gaim_upnp_generate_action_message_and_send(controlInfo,
-+ httpResponse = gaim2_upnp_generate_action_message_and_send(controlInfo,
- actionName, actionParams);
-
- if(httpResponse == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_remove_port_mapping(): Failed In httpResponse\n\n");
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_remove_port_mapping(): Failed In httpResponse\n\n");
- g_free(actionParams);
- return FALSE;
- }
-
- /* determine if port mapping was a success */
- if(strstr(httpResponse, HTTP_OK) == NULL) {
-- gaim_debug_error("upnp",
-- "gaim_upnp_set_port_mapping(): Failed HTTP_OK\n\n%s\n\n",
-+ gaim2_debug_error("upnp",
-+ "gaim2_upnp_set_port_mapping(): Failed HTTP_OK\n\n%s\n\n",
- httpResponse);
- g_free(actionParams);
- g_free(httpResponse);
-@@ -975,6 +975,6 @@ gaim_upnp_remove_port_mapping(const Gaim
- g_free(actionParams);
- g_free(httpResponse);
-
-- gaim_debug_info("upnp", "NAT Removed Port Forward On Port: %d\n", portMap);
-+ gaim2_debug_info("upnp", "NAT Removed Port Forward On Port: %d\n", portMap);
- return TRUE;
- }
-diff -prNu ./src/upnp.h ./src/upnp.h
---- ./src/upnp.h 2005-09-11 05:58:13.000000000 +0200
-+++ ./src/upnp.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file upnp.h Universal Plug N Play API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -31,7 +31,7 @@ typedef struct
- {
- gchar* controlURL;
- gchar* serviceType;
--} GaimUPnPControlInfo;
-+} Gaim2UPnPControlInfo;
-
-
- #ifdef __cplusplus
-@@ -50,7 +50,7 @@ extern "C" {
- *
- * @return The control URL for the IGD we'll use to use the IGD services
- */
--GaimUPnPControlInfo* gaim_upnp_discover(void);
-+Gaim2UPnPControlInfo* gaim2_upnp_discover(void);
-
-
-
-@@ -59,42 +59,42 @@ GaimUPnPControlInfo* gaim_upnp_discover(
- * network, so when getting the network IP, instead of returning the
- * local network IP, the public IP is retrieved.
- *
-- * @param controlInfo The control URL retrieved from gaim_upnp_discover.
-+ * @param controlInfo The control URL retrieved from gaim2_upnp_discover.
- *
- * @return The IP address of the network, or NULL if something went wrong
- */
--gchar* gaim_upnp_get_public_ip(const GaimUPnPControlInfo* controlInfo);
-+gchar* gaim2_upnp_get_public_ip(const Gaim2UPnPControlInfo* controlInfo);
-
-
- /**
- * Maps Ports in a UPnP enabled IGD that sits on the local network to
-- * this gaim client. Essentially, this function takes care of the port
-+ * this gaim2 client. Essentially, this function takes care of the port
- * forwarding so things like file transfers can work behind NAT firewalls
- *
-- * @param controlInfo The control URL retrieved from gaim_upnp_discover.
-+ * @param controlInfo The control URL retrieved from gaim2_upnp_discover.
- * @param portMap The port to map to this client
- * @param protocol The protocol to map, either "TCP" or "UDP"
- *
- * @return TRUE if success, FALSE if something went wrong.
- */
--gboolean gaim_upnp_set_port_mapping(const GaimUPnPControlInfo* controlInfo,
-+gboolean gaim2_upnp_set_port_mapping(const Gaim2UPnPControlInfo* controlInfo,
- unsigned short portMap,
- const gchar* protocol);
-
- /**
- * Deletes a port mapping in a UPnP enabled IGD that sits on the local network
-- * to this gaim client. Essentially, this function takes care of deleting the
-+ * to this gaim2 client. Essentially, this function takes care of deleting the
- * port forwarding after they have completed a connection so another client on
- * the local network can take advantage of the port forwarding
- *
-- * @param controlInfo The control URL retrieved from gaim_upnp_discover.
-+ * @param controlInfo The control URL retrieved from gaim2_upnp_discover.
- * @param portMap The port to delete the mapping for
- * @param protocol The protocol to map to. Either "TCP" or "UDP"
- *
- * @return TRUE if success, FALSE if something went wrong.
- */
- gboolean
--gaim_upnp_remove_port_mapping(const GaimUPnPControlInfo* controlInfo,
-+gaim2_upnp_remove_port_mapping(const Gaim2UPnPControlInfo* controlInfo,
- unsigned short portMap,
- const gchar* protocol);
- /*@}*/
-diff -prNu ./src/util.c ./src/util.c
---- ./src/util.c 2005-12-23 07:48:27.000000000 +0100
-+++ ./src/util.c 2006-01-05 15:11:05.000000000 +0100
-@@ -2,7 +2,7 @@
- * @file util.h Utility Functions
- * @ingroup core
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -58,7 +58,7 @@ typedef struct
- unsigned long len;
- unsigned long data_len;
-
--} GaimFetchUrlData;
-+} Gaim2FetchUrlData;
-
- static char custom_home_dir[MAXPATHLEN];
- static char home_dir[MAXPATHLEN];
-@@ -67,7 +67,7 @@ static char home_dir[MAXPATHLEN];
- * Base16 Functions
- **************************************************************************/
- gchar *
--gaim_base16_encode(const guchar *data, gsize len)
-+gaim2_base16_encode(const guchar *data, gsize len)
- {
- int i;
- gchar *ascii = NULL;
-@@ -84,7 +84,7 @@ gaim_base16_encode(const guchar *data, g
- }
-
- guchar *
--gaim_base16_decode(const char *str, gsize *ret_len)
-+gaim2_base16_decode(const char *str, gsize *ret_len)
- {
- int len, i, accumulator = 0;
- guchar *data;
-@@ -141,7 +141,7 @@ static const char xdigits[] =
- "0123456789abcdef";
-
- gchar *
--gaim_base64_encode(const guchar *data, gsize len)
-+gaim2_base64_encode(const guchar *data, gsize len)
- {
- char *out, *rv;
-
-@@ -180,7 +180,7 @@ gaim_base64_encode(const guchar *data, g
- }
-
- guchar *
--gaim_base64_decode(const char *str, gsize *ret_len)
-+gaim2_base64_decode(const char *str, gsize *ret_len)
- {
- guchar *out = NULL;
- char tmp = 0;
-@@ -249,7 +249,7 @@ gaim_base64_decode(const char *str, gsiz
- * Quoted Printable Functions (see RFC 2045).
- **************************************************************************/
- guchar *
--gaim_quotedp_decode(const char *str, gsize *ret_len)
-+gaim2_quotedp_decode(const char *str, gsize *ret_len)
- {
- char *n, *new;
- const char *end, *p;
-@@ -299,7 +299,7 @@ gaim_quotedp_decode(const char *str, gsi
- * MIME Functions
- **************************************************************************/
- char *
--gaim_mime_decode_field(const char *str)
-+gaim2_mime_decode_field(const char *str)
- {
- /*
- * This is wing's version, partially based on revo/shx's version
-@@ -412,9 +412,9 @@ gaim_mime_decode_field(const char *str)
- guchar *decoded = NULL;
- gsize dec_len;
- if (g_ascii_strcasecmp(encoding, "Q") == 0)
-- decoded = gaim_quotedp_decode(encoded_text, &dec_len);
-+ decoded = gaim2_quotedp_decode(encoded_text, &dec_len);
- else if (g_ascii_strcasecmp(encoding, "B") == 0)
-- decoded = gaim_base64_decode(encoded_text, &dec_len);
-+ decoded = gaim2_base64_decode(encoded_text, &dec_len);
- else
- decoded = NULL;
- if (decoded) {
-@@ -462,7 +462,7 @@ gaim_mime_decode_field(const char *str)
- * Date/Time Functions
- **************************************************************************/
- const char *
--gaim_date(void)
-+gaim2_date(void)
- {
- static char date[80];
- time_t tme;
-@@ -474,7 +474,7 @@ gaim_date(void)
- }
-
- const char *
--gaim_date_full(void)
-+gaim2_date_full(void)
- {
- char *date;
- time_t tme;
-@@ -487,7 +487,7 @@ gaim_date_full(void)
- }
-
- time_t
--gaim_time_build(int year, int month, int day, int hour, int min, int sec)
-+gaim2_time_build(int year, int month, int day, int hour, int min, int sec)
- {
- struct tm tm;
-
-@@ -502,7 +502,7 @@ gaim_time_build(int year, int month, int
- }
-
- time_t
--gaim_str_to_time(const char *timestamp, gboolean utc)
-+gaim2_str_to_time(const char *timestamp, gboolean utc)
- {
- time_t retval = 0;
- struct tm *t;
-@@ -586,7 +586,7 @@ gaim_str_to_time(const char *timestamp,
- return retval;
- }
-
--size_t gaim_strftime(char *s, size_t max, const char *format, const struct tm *tm)
-+size_t gaim2_strftime(char *s, size_t max, const char *format, const struct tm *tm)
- {
- return strftime(s, max, format, tm);
- }
-@@ -595,7 +595,7 @@ size_t gaim_strftime(char *s, size_t max
- * Markup Functions
- **************************************************************************/
- gboolean
--gaim_markup_find_tag(const char *needle, const char *haystack,
-+gaim2_markup_find_tag(const char *needle, const char *haystack,
- const char **start, const char **end, GData **attributes)
- {
- GData *attribs;
-@@ -749,7 +749,7 @@ gaim_markup_find_tag(const char *needle,
- }
-
- gboolean
--gaim_markup_extract_info_field(const char *str, int len, GString *dest,
-+gaim2_markup_extract_info_field(const char *str, int len, GString *dest,
- const char *start_token, int skip,
- const char *end_token, char check_value,
- const char *no_value_token,
-@@ -828,7 +828,7 @@ gaim_markup_extract_info_field(const cha
- return FALSE;
- }
-
--struct gaim_parse_tag {
-+struct gaim2_parse_tag {
- char *src_tag;
- char *dest_tag;
- gboolean ignore;
-@@ -864,7 +864,7 @@ struct gaim_parse_tag {
- } \
- if(p && !r) { \
- if(*(p-1) != '/') { \
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1); \
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1); \
- pt->src_tag = x; \
- pt->dest_tag = y; \
- tags = g_list_prepend(tags, pt); \
-@@ -888,7 +888,7 @@ struct gaim_parse_tag {
- xhtml = g_string_append(xhtml, "<" y); \
- c += strlen("<" x); \
- if(*c != '/') { \
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1); \
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1); \
- pt->src_tag = x; \
- pt->dest_tag = y; \
- tags = g_list_prepend(tags, pt); \
-@@ -901,7 +901,7 @@ struct gaim_parse_tag {
- }
- #define ALLOW_TAG(x) ALLOW_TAG_ALT(x, x)
- void
--gaim_markup_html_to_xhtml(const char *html, char **xhtml_out,
-+gaim2_markup_html_to_xhtml(const char *html, char **xhtml_out,
- char **plain_out)
- {
- GString *xhtml = g_string_new("");
-@@ -914,7 +914,7 @@ gaim_markup_html_to_xhtml(const char *ht
- if(*(c+1) == '/') { /* closing tag */
- tag = tags;
- while(tag) {
-- struct gaim_parse_tag *pt = tag->data;
-+ struct gaim2_parse_tag *pt = tag->data;
- if(!g_ascii_strncasecmp((c+2), pt->src_tag, strlen(pt->src_tag)) && *(c+strlen(pt->src_tag)+2) == '>') {
- c += strlen(pt->src_tag) + 3;
- break;
-@@ -923,7 +923,7 @@ gaim_markup_html_to_xhtml(const char *ht
- }
- if(tag) {
- while(tags) {
-- struct gaim_parse_tag *pt = tags->data;
-+ struct gaim2_parse_tag *pt = tags->data;
- g_string_append_printf(xhtml, "</%s>", pt->dest_tag);
- if(tags == tag)
- break;
-@@ -991,7 +991,7 @@ gaim_markup_html_to_xhtml(const char *ht
- continue;
- }
- if(!g_ascii_strncasecmp(c, "<u>", 3) || !g_ascii_strncasecmp(c, "<underline>", strlen("<underline>"))) {
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1);
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1);
- pt->src_tag = *(c+2) == '>' ? "u" : "underline";
- pt->dest_tag = "span";
- tags = g_list_prepend(tags, pt);
-@@ -1000,7 +1000,7 @@ gaim_markup_html_to_xhtml(const char *ht
- continue;
- }
- if(!g_ascii_strncasecmp(c, "<s>", 3) || !g_ascii_strncasecmp(c, "<strike>", strlen("<strike>"))) {
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1);
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1);
- pt->src_tag = *(c+2) == '>' ? "s" : "strike";
- pt->dest_tag = "span";
- tags = g_list_prepend(tags, pt);
-@@ -1009,7 +1009,7 @@ gaim_markup_html_to_xhtml(const char *ht
- continue;
- }
- if(!g_ascii_strncasecmp(c, "<sub>", 5)) {
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1);
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1);
- pt->src_tag = "sub";
- pt->dest_tag = "span";
- tags = g_list_prepend(tags, pt);
-@@ -1018,7 +1018,7 @@ gaim_markup_html_to_xhtml(const char *ht
- continue;
- }
- if(!g_ascii_strncasecmp(c, "<sup>", 5)) {
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1);
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1);
- pt->src_tag = "sup";
- pt->dest_tag = "span";
- tags = g_list_prepend(tags, pt);
-@@ -1029,7 +1029,7 @@ gaim_markup_html_to_xhtml(const char *ht
- if(!g_ascii_strncasecmp(c, "<font", 5) && (*(c+5) == '>' || *(c+5) == ' ')) {
- const char *p = c;
- GString *style = g_string_new("");
-- struct gaim_parse_tag *pt;
-+ struct gaim2_parse_tag *pt;
- while(*p && *p != '>') {
- if(!g_ascii_strncasecmp(p, "back=", strlen("back="))) {
- const char *q = p + strlen("back=");
-@@ -1112,7 +1112,7 @@ gaim_markup_html_to_xhtml(const char *ht
- c++;
- else
- c = p;
-- pt = g_new0(struct gaim_parse_tag, 1);
-+ pt = g_new0(struct gaim2_parse_tag, 1);
- pt->src_tag = "font";
- pt->dest_tag = "span";
- tags = g_list_prepend(tags, pt);
-@@ -1129,7 +1129,7 @@ gaim_markup_html_to_xhtml(const char *ht
- while(*p && *p != '>') {
- if(!g_ascii_strncasecmp(p, "bgcolor=", strlen("bgcolor="))) {
- const char *q = p + strlen("bgcolor=");
-- struct gaim_parse_tag *pt = g_new0(struct gaim_parse_tag, 1);
-+ struct gaim2_parse_tag *pt = g_new0(struct gaim2_parse_tag, 1);
- GString *color = g_string_new("");
- if(*q == '\'' || *q == '\"')
- q++;
-@@ -1223,7 +1223,7 @@ gaim_markup_html_to_xhtml(const char *ht
- }
- tag = tags;
- while(tag) {
-- struct gaim_parse_tag *pt = tag->data;
-+ struct gaim2_parse_tag *pt = tag->data;
- if(!pt->ignore)
- g_string_append_printf(xhtml, "</%s>", pt->dest_tag);
- tag = tag->next;
-@@ -1247,7 +1247,7 @@ gaim_markup_html_to_xhtml(const char *ht
- */
-
- char *
--gaim_markup_strip_html(const char *str)
-+gaim2_markup_strip_html(const char *str)
- {
- int i, j, k;
- gboolean visible = TRUE;
-@@ -1343,7 +1343,7 @@ gaim_markup_strip_html(const char *str)
- char *tmp;
- g_free(href);
- tmp = g_strndup(str2 + st, end - st);
-- href = gaim_unescape_html(tmp);
-+ href = gaim2_unescape_html(tmp);
- g_free(tmp);
- href_st = j;
- }
-@@ -1491,7 +1491,7 @@ badentity(const char *c)
- }
-
- char *
--gaim_markup_linkify(const char *text)
-+gaim2_markup_linkify(const char *text)
- {
- const char *c, *t, *q = NULL;
- char *tmp, *tmpurlbuf, *url_buf;
-@@ -1551,7 +1551,7 @@ gaim_markup_linkify(const char *text)
- }
-
- url_buf = g_strndup(c, t - c);
-- tmpurlbuf = gaim_unescape_html(url_buf);
-+ tmpurlbuf = gaim2_unescape_html(url_buf);
- g_string_append_printf(ret, "<A HREF=\"%s\">%s</A>",
- tmpurlbuf, url_buf);
- g_free(url_buf);
-@@ -1584,7 +1584,7 @@ gaim_markup_linkify(const char *text)
- t--;
- }
- url_buf = g_strndup(c, t - c);
-- tmpurlbuf = gaim_unescape_html(url_buf);
-+ tmpurlbuf = gaim2_unescape_html(url_buf);
- g_string_append_printf(ret,
- "<A HREF=\"http://%s\">%s</A>", tmpurlbuf,
- url_buf);
-@@ -1608,7 +1608,7 @@ gaim_markup_linkify(const char *text)
- t--;
- }
- url_buf = g_strndup(c, t - c);
-- tmpurlbuf = gaim_unescape_html(url_buf);
-+ tmpurlbuf = gaim2_unescape_html(url_buf);
- g_string_append_printf(ret, "<A HREF=\"%s\">%s</A>",
- tmpurlbuf, url_buf);
- g_free(url_buf);
-@@ -1635,7 +1635,7 @@ gaim_markup_linkify(const char *text)
- t--;
- }
- url_buf = g_strndup(c, t - c);
-- tmpurlbuf = gaim_unescape_html(url_buf);
-+ tmpurlbuf = gaim2_unescape_html(url_buf);
- g_string_append_printf(ret,
- "<A HREF=\"ftp://%s\">%s</A>", tmpurlbuf,
- url_buf);
-@@ -1656,7 +1656,7 @@ gaim_markup_linkify(const char *text)
- if (*(t - 1) == '.')
- t--;
- url_buf = g_strndup(c, t - c);
-- tmpurlbuf = gaim_unescape_html(url_buf);
-+ tmpurlbuf = gaim2_unescape_html(url_buf);
- g_string_append_printf(ret, "<A HREF=\"%s\">%s</A>",
- tmpurlbuf, url_buf);
- g_free(url_buf);
-@@ -1719,8 +1719,8 @@ gaim_markup_linkify(const char *text)
- *d = '\0';
- }
-
-- tmpurlbuf = gaim_unescape_html(url_buf);
-- if (gaim_email_is_valid(tmpurlbuf)) {
-+ tmpurlbuf = gaim2_unescape_html(url_buf);
-+ if (gaim2_email_is_valid(tmpurlbuf)) {
- g_string_append_printf(ret, "<A HREF=\"mailto:%s\">%s</A>",
- tmpurlbuf, url_buf);
- } else {
-@@ -1757,7 +1757,7 @@ gaim_markup_linkify(const char *text)
- }
-
- char *
--gaim_unescape_html(const char *html) {
-+gaim2_unescape_html(const char *html) {
- char *unescaped = NULL;
-
- if (html != NULL) {
-@@ -1796,7 +1796,7 @@ gaim_unescape_html(const char *html) {
- }
-
- char *
--gaim_markup_slice(const char *str, guint x, guint y)
-+gaim2_markup_slice(const char *str, guint x, guint y)
- {
- GString *ret;
- GQueue *q;
-@@ -1892,7 +1892,7 @@ gaim_markup_slice(const char *str, guint
- while ((tag = g_queue_pop_head(q))) {
- char *name;
-
-- name = gaim_markup_get_tag_name(tag);
-+ name = gaim2_markup_get_tag_name(tag);
- g_string_append_printf(ret, "</%s>", name);
- g_free(name);
- g_free(tag);
-@@ -1903,7 +1903,7 @@ gaim_markup_slice(const char *str, guint
- }
-
- char *
--gaim_markup_get_tag_name(const char *tag)
-+gaim2_markup_get_tag_name(const char *tag)
- {
- int i;
- g_return_val_if_fail(tag != NULL, NULL);
-@@ -1920,28 +1920,28 @@ gaim_markup_get_tag_name(const char *tag
- * Path/Filename Functions
- **************************************************************************/
- const char *
--gaim_home_dir(void)
-+gaim2_home_dir(void)
- {
- #ifndef _WIN32
- return g_get_home_dir();
- #else
-- return wgaim_data_dir();
-+ return wgaim2_data_dir();
- #endif
- }
-
--/* returns a string of the form ~/.gaim, where ~ is replaced by the user's home
-- * dir. Note that there is no trailing slash after .gaim. */
-+/* returns a string of the form ~/.gaim2, where ~ is replaced by the user's home
-+ * dir. Note that there is no trailing slash after .gaim2. */
- const char *
--gaim_user_dir(void)
-+gaim2_user_dir(void)
- {
- if (custom_home_dir != NULL && strlen(custom_home_dir) > 0) {
- strcpy ((char*) &home_dir, (char*) &custom_home_dir);
- } else {
-- const gchar *hd = gaim_home_dir();
-+ const gchar *hd = gaim2_home_dir();
-
- if (hd) {
- g_strlcpy((char*) &home_dir, hd, sizeof(home_dir));
-- g_strlcat((char*) &home_dir, G_DIR_SEPARATOR_S ".gaim",
-+ g_strlcat((char*) &home_dir, G_DIR_SEPARATOR_S ".gaim2",
- sizeof(home_dir));
- }
- }
-@@ -1949,7 +1949,7 @@ gaim_user_dir(void)
- return home_dir;
- }
-
--void gaim_util_set_user_dir(const char *dir)
-+void gaim2_util_set_user_dir(const char *dir)
- {
- if (dir != NULL && strlen(dir) > 0) {
- g_strlcpy((char*) &custom_home_dir, dir,
-@@ -1957,7 +1957,7 @@ void gaim_util_set_user_dir(const char *
- }
- }
-
--int gaim_build_dir (const char *path, int mode)
-+int gaim2_build_dir (const char *path, int mode)
- {
- #if GLIB_CHECK_VERSION(2,8,0)
- return g_mkdir_with_parents(path, mode);
-@@ -1991,14 +1991,14 @@ int gaim_build_dir (const char *path, in
- continue;
- #endif
- } else if(g_file_test(dir, G_FILE_TEST_EXISTS)) {
-- gaim_debug_warning("build_dir", "bad path: %s\n", path);
-+ gaim2_debug_warning("build_dir", "bad path: %s\n", path);
- g_strfreev(components);
- g_free(dir);
- return -1;
- }
-
- if (g_mkdir(dir, mode) < 0) {
-- gaim_debug_warning("build_dir", "mkdir: %s\n", strerror(errno));
-+ gaim2_debug_warning("build_dir", "mkdir: %s\n", strerror(errno));
- g_strfreev(components);
- g_free(dir);
- return -1;
-@@ -2017,9 +2017,9 @@ int gaim_build_dir (const char *path, in
- * people's settings if there is a problem writing the new values.
- */
- gboolean
--gaim_util_write_data_to_file(const char *filename, const char *data, size_t size)
-+gaim2_util_write_data_to_file(const char *filename, const char *data, size_t size)
- {
-- const char *user_dir = gaim_user_dir();
-+ const char *user_dir = gaim2_user_dir();
- gchar *filename_temp, *filename_full;
- FILE *file;
- size_t real_size, byteswritten;
-@@ -2027,7 +2027,7 @@ gaim_util_write_data_to_file(const char
-
- g_return_val_if_fail(user_dir != NULL, FALSE);
-
-- gaim_debug_info("util", "Writing file %s to directory %s\n",
-+ gaim2_debug_info("util", "Writing file %s to directory %s\n",
- filename, user_dir);
-
- /* Ensure the user directory exists */
-@@ -2035,7 +2035,7 @@ gaim_util_write_data_to_file(const char
- {
- if (g_mkdir(user_dir, S_IRUSR | S_IWUSR | S_IXUSR) == -1)
- {
-- gaim_debug_error("util", "Error creating directory %s: %s\n",
-+ gaim2_debug_error("util", "Error creating directory %s: %s\n",
- user_dir, strerror(errno));
- return FALSE;
- }
-@@ -2049,7 +2049,7 @@ gaim_util_write_data_to_file(const char
- {
- if (g_unlink(filename_temp) == -1)
- {
-- gaim_debug_error("util", "Error removing old file %s: %s\n",
-+ gaim2_debug_error("util", "Error removing old file %s: %s\n",
- filename_temp, strerror(errno));
- }
- }
-@@ -2058,7 +2058,7 @@ gaim_util_write_data_to_file(const char
- file = g_fopen(filename_temp, "wb");
- if (file == NULL)
- {
-- gaim_debug_error("util", "Error opening file %s for writing: %s\n",
-+ gaim2_debug_error("util", "Error opening file %s for writing: %s\n",
- filename_temp, strerror(errno));
- g_free(filename_full);
- g_free(filename_temp);
-@@ -2072,7 +2072,7 @@ gaim_util_write_data_to_file(const char
- /* Close file */
- if (fclose(file) != 0)
- {
-- gaim_debug_error("util", "Error closing file %s: %s\n",
-+ gaim2_debug_error("util", "Error closing file %s: %s\n",
- filename_temp, strerror(errno));
- g_free(filename_full);
- g_free(filename_temp);
-@@ -2082,7 +2082,7 @@ gaim_util_write_data_to_file(const char
- /* Ensure the file is the correct size */
- if (byteswritten != real_size)
- {
-- gaim_debug_error("util", "Error writing to file %s: Wrote %" G_GSIZE_FORMAT " bytes "
-+ gaim2_debug_error("util", "Error writing to file %s: Wrote %" G_GSIZE_FORMAT " bytes "
- "but should have written %" G_GSIZE_FORMAT "; is your disk full?\n",
- filename_temp, byteswritten, real_size);
- g_free(filename_full);
-@@ -2092,7 +2092,7 @@ gaim_util_write_data_to_file(const char
- /* Use stat to be absolutely sure. */
- if ((g_stat(filename_temp, &st) == -1) || (st.st_size != real_size))
- {
-- gaim_debug_error("util", "Error writing data to file %s: "
-+ gaim2_debug_error("util", "Error writing data to file %s: "
- "Incomplete file written; is your disk full?\n",
- filename_temp);
- g_free(filename_full);
-@@ -2104,7 +2104,7 @@ gaim_util_write_data_to_file(const char
- /* Set file permissions */
- if (chmod(filename_temp, S_IRUSR | S_IWUSR) == -1)
- {
-- gaim_debug_error("util", "Error setting permissions of file %s: %s\n",
-+ gaim2_debug_error("util", "Error setting permissions of file %s: %s\n",
- filename_temp, strerror(errno));
- }
- #endif
-@@ -2114,7 +2114,7 @@ gaim_util_write_data_to_file(const char
- {
- if (g_unlink(filename_full) == -1)
- {
-- gaim_debug_error("util", "Error removing old file %s: %s\n",
-+ gaim2_debug_error("util", "Error removing old file %s: %s\n",
- filename_full, strerror(errno));
- }
- }
-@@ -2122,7 +2122,7 @@ gaim_util_write_data_to_file(const char
- /* Rename to the REAL name */
- if (g_rename(filename_temp, filename_full) == -1)
- {
-- gaim_debug_error("util", "Error renaming %s to %s: %s\n",
-+ gaim2_debug_error("util", "Error renaming %s to %s: %s\n",
- filename_temp, filename_full, strerror(errno));
- }
-
-@@ -2133,9 +2133,9 @@ gaim_util_write_data_to_file(const char
- }
-
- xmlnode *
--gaim_util_read_xml_from_file(const char *filename, const char *description)
-+gaim2_util_read_xml_from_file(const char *filename, const char *description)
- {
-- const char *user_dir = gaim_user_dir();
-+ const char *user_dir = gaim2_user_dir();
- gchar *filename_full;
- GError *error;
- gchar *contents = NULL;
-@@ -2144,14 +2144,14 @@ gaim_util_read_xml_from_file(const char
-
- g_return_val_if_fail(user_dir != NULL, NULL);
-
-- gaim_debug_info("util", "Reading file %s from directory %s\n",
-+ gaim2_debug_info("util", "Reading file %s from directory %s\n",
- filename, user_dir);
-
- filename_full = g_build_filename(user_dir, filename, NULL);
-
- if (!g_file_test(filename_full, G_FILE_TEST_EXISTS))
- {
-- gaim_debug_info("util", "File %s does not exist (this is not "
-+ gaim2_debug_info("util", "File %s does not exist (this is not "
- "necessarily an error)\n", filename_full);
- g_free(filename_full);
- return NULL;
-@@ -2159,7 +2159,7 @@ gaim_util_read_xml_from_file(const char
-
- if (!g_file_get_contents(filename_full, &contents, &length, &error))
- {
-- gaim_debug_error("util", "Error reading file %s: %s\n",
-+ gaim2_debug_error("util", "Error reading file %s: %s\n",
- filename_full, error->message);
- g_error_free(error);
- }
-@@ -2174,9 +2174,9 @@ gaim_util_read_xml_from_file(const char
- gchar *filename_temp;
-
- filename_temp = g_strdup_printf("%s~", filename);
-- gaim_debug_error("util", "Error parsing file %s. Rrenaming old "
-+ gaim2_debug_error("util", "Error parsing file %s. Rrenaming old "
- "file to %s\n", filename_full, filename_temp);
-- gaim_util_write_data_to_file(filename_temp, contents, length);
-+ gaim2_util_write_data_to_file(filename_temp, contents, length);
- g_free(filename_temp);
- }
-
-@@ -2191,7 +2191,7 @@ gaim_util_read_xml_from_file(const char
- msg = g_strdup_printf(_("An error was encountered reading your "
- "%s. They have not been loaded, and the old file "
- "has been renamed to %s~."), description, filename_full);
-- gaim_notify_error(NULL, NULL, title, msg);
-+ gaim2_notify_error(NULL, NULL, title, msg);
- g_free(title);
- g_free(msg);
- }
-@@ -2211,10 +2211,10 @@ gaim_util_read_xml_from_file(const char
- *
- * Returns NULL on failure and cleans up after itself if so.
- */
--static const char *gaim_mkstemp_templ = {"gaimXXXXXX"};
-+static const char *gaim2_mkstemp_templ = {"gaim2XXXXXX"};
-
- FILE *
--gaim_mkstemp(char **fpath, gboolean binary)
-+gaim2_mkstemp(char **fpath, gboolean binary)
- {
- const gchar *tmpdir;
- #ifndef _WIN32
-@@ -2225,28 +2225,28 @@ gaim_mkstemp(char **fpath, gboolean bina
- g_return_val_if_fail(fpath != NULL, NULL);
-
- if((tmpdir = (gchar*)g_get_tmp_dir()) != NULL) {
-- if((*fpath = g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", tmpdir, gaim_mkstemp_templ)) != NULL) {
-+ if((*fpath = g_strdup_printf("%s" G_DIR_SEPARATOR_S "%s", tmpdir, gaim2_mkstemp_templ)) != NULL) {
- #ifdef _WIN32
- char* result = _mktemp( *fpath );
- if( result == NULL )
-- gaim_debug(GAIM_DEBUG_ERROR, "gaim_mkstemp",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gaim2_mkstemp",
- "Problem creating the template\n");
- else
- {
- if( (fp = g_fopen( result, binary?"wb+":"w+")) == NULL ) {
-- gaim_debug(GAIM_DEBUG_ERROR, "gaim_mkstemp",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gaim2_mkstemp",
- "Couldn't fopen() %s\n", result);
- }
- }
- #else
- if((fd = mkstemp(*fpath)) == -1) {
-- gaim_debug(GAIM_DEBUG_ERROR, "gaim_mkstemp",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gaim2_mkstemp",
- "Couldn't make \"%s\", error: %d\n",
- *fpath, errno);
- } else {
- if((fp = fdopen(fd, "r+")) == NULL) {
- close(fd);
-- gaim_debug(GAIM_DEBUG_ERROR, "gaim_mkstemp",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gaim2_mkstemp",
- "Couldn't fdopen(), error: %d\n", errno);
- }
- }
-@@ -2257,7 +2257,7 @@ gaim_mkstemp(char **fpath, gboolean bina
- }
- }
- } else {
-- gaim_debug(GAIM_DEBUG_ERROR, "gaim_mkstemp",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "gaim2_mkstemp",
- "g_get_tmp_dir() failed!");
- }
-
-@@ -2265,7 +2265,7 @@ gaim_mkstemp(char **fpath, gboolean bina
- }
-
- gboolean
--gaim_program_is_valid(const char *program)
-+gaim2_program_is_valid(const char *program)
- {
- GError *error = NULL;
- char **argv;
-@@ -2276,7 +2276,7 @@ gaim_program_is_valid(const char *progra
- g_return_val_if_fail(*program != '\0', FALSE);
-
- if (!g_shell_parse_argv(program, NULL, &argv, &error)) {
-- gaim_debug(GAIM_DEBUG_ERROR, "program_is_valid",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "program_is_valid",
- "Could not parse program '%s': %s\n",
- program, error->message);
- g_error_free(error);
-@@ -2298,7 +2298,7 @@ gaim_program_is_valid(const char *progra
-
-
- gboolean
--gaim_running_gnome(void)
-+gaim2_running_gnome(void)
- {
- gchar *tmp = g_find_program_in_path("gnome-open");
-
-@@ -2310,7 +2310,7 @@ gaim_running_gnome(void)
- }
-
- gboolean
--gaim_running_kde(void)
-+gaim2_running_kde(void)
- {
- gchar *tmp = g_find_program_in_path("kfmclient");
- const char *session;
-@@ -2323,15 +2323,15 @@ gaim_running_kde(void)
- if (session != NULL && !strcmp(session, "true"))
- return TRUE;
-
-- /* If you run Gaim from Konsole under !KDE, this will provide a
-+ /* If you run Gaim2 from Konsole under !KDE, this will provide a
- * a false positive. Since we do the GNOME checks first, this is
- * only a problem if you're running something !(KDE || GNOME) and
-- * you run Gaim from Konsole. This really shouldn't be a problem. */
-+ * you run Gaim2 from Konsole. This really shouldn't be a problem. */
- return ((g_getenv("KDEDIR") != NULL) || g_getenv("KDEDIRS") != NULL);
- }
-
- char *
--gaim_fd_get_ip(int fd)
-+gaim2_fd_get_ip(int fd)
- {
- struct sockaddr addr;
- socklen_t namelen = sizeof(addr);
-@@ -2349,14 +2349,14 @@ gaim_fd_get_ip(int fd)
- * String Functions
- **************************************************************************/
- const char *
--gaim_normalize(const GaimAccount *account, const char *str)
-+gaim2_normalize(const Gaim2Account *account, const char *str)
- {
-- GaimPlugin *prpl = NULL;
-- GaimPluginProtocolInfo *prpl_info = NULL;
-+ Gaim2Plugin *prpl = NULL;
-+ Gaim2PluginProtocolInfo *prpl_info = NULL;
- const char *ret = NULL;
-
- if(account)
-- prpl = gaim_find_prpl(gaim_account_get_protocol_id(account));
-+ prpl = gaim2_find_prpl(gaim2_account_get_protocol_id(account));
-
- if(prpl)
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(prpl);
-@@ -2385,7 +2385,7 @@ gaim_normalize(const GaimAccount *accoun
- * comments in util.h.
- */
- const char *
--gaim_normalize_nocase(const GaimAccount *account, const char *str)
-+gaim2_normalize_nocase(const Gaim2Account *account, const char *str)
- {
- static char buf[BUF_LEN];
- char *tmp1, *tmp2;
-@@ -2402,7 +2402,7 @@ gaim_normalize_nocase(const GaimAccount
- }
-
- gchar *
--gaim_str_sub_away_formatters(const char *str, const char *name)
-+gaim2_str_sub_away_formatters(const char *str, const char *name)
- {
- char *c;
- GString *cpy;
-@@ -2459,7 +2459,7 @@ gaim_str_sub_away_formatters(const char
- }
-
- gchar *
--gaim_strdup_withhtml(const gchar *src)
-+gaim2_strdup_withhtml(const gchar *src)
- {
- gulong destsize, i, j;
- gchar *dest;
-@@ -2489,7 +2489,7 @@ gaim_strdup_withhtml(const gchar *src)
- }
-
- gboolean
--gaim_str_has_prefix(const char *s, const char *p)
-+gaim2_str_has_prefix(const char *s, const char *p)
- {
- #if GLIB_CHECK_VERSION(2,2,0)
- return g_str_has_prefix(s, p);
-@@ -2502,7 +2502,7 @@ gaim_str_has_prefix(const char *s, const
- }
-
- gboolean
--gaim_str_has_suffix(const char *s, const char *x)
-+gaim2_str_has_suffix(const char *s, const char *x)
- {
- #if GLIB_CHECK_VERSION(2,2,0)
- return g_str_has_suffix(s, x);
-@@ -2517,7 +2517,7 @@ gaim_str_has_suffix(const char *s, const
- }
-
- char *
--gaim_str_add_cr(const char *text)
-+gaim2_str_add_cr(const char *text)
- {
- char *ret = NULL;
- int count = 0, j;
-@@ -2546,14 +2546,14 @@ gaim_str_add_cr(const char *text)
- ret[j++] = text[i];
- }
-
-- gaim_debug_misc("gaim_str_add_cr", "got: %s, leaving with %s\n",
-+ gaim2_debug_misc("gaim2_str_add_cr", "got: %s, leaving with %s\n",
- text, ret);
-
- return ret;
- }
-
- void
--gaim_str_strip_char(char *text, char thechar)
-+gaim2_str_strip_char(char *text, char thechar)
- {
- int i, j;
-
-@@ -2567,7 +2567,7 @@ gaim_str_strip_char(char *text, char the
- }
-
- void
--gaim_util_chrreplace(char *string, char delimiter,
-+gaim2_util_chrreplace(char *string, char delimiter,
- char replacement)
- {
- int i = 0;
-@@ -2583,7 +2583,7 @@ gaim_util_chrreplace(char *string, char
- }
-
- gchar *
--gaim_strreplace(const char *string, const char *delimiter,
-+gaim2_strreplace(const char *string, const char *delimiter,
- const char *replacement)
- {
- gchar **split;
-@@ -2601,7 +2601,7 @@ gaim_strreplace(const char *string, cons
- }
-
- gchar *
--gaim_strcasereplace(const char *string, const char *delimiter,
-+gaim2_strcasereplace(const char *string, const char *delimiter,
- const char *replacement)
- {
- gchar *ret;
-@@ -2649,7 +2649,7 @@ gaim_strcasereplace(const char *string,
- }
-
- const char *
--gaim_strcasestr(const char *haystack, const char *needle)
-+gaim2_strcasestr(const char *haystack, const char *needle)
- {
- size_t hlen, nlen;
- const char *tmp, *ret;
-@@ -2676,7 +2676,7 @@ gaim_strcasestr(const char *haystack, co
- }
-
- char *
--gaim_str_size_to_units(size_t size)
-+gaim2_str_size_to_units(size_t size)
- {
- static const char *size_str[4] = { "bytes", "KB", "MB", "GB" };
- float size_mag;
-@@ -2705,7 +2705,7 @@ gaim_str_size_to_units(size_t size)
- }
-
- char *
--gaim_str_seconds_to_string(guint secs)
-+gaim2_str_seconds_to_string(guint secs)
- {
- GString *gstr;
- const char *prefix = "";
-@@ -2754,7 +2754,7 @@ gaim_str_seconds_to_string(guint secs)
-
-
- char *
--gaim_str_binary_to_ascii(const unsigned char *binary, guint len)
-+gaim2_str_binary_to_ascii(const unsigned char *binary, guint len)
- {
- GString *ret;
- guint i;
-@@ -2778,7 +2778,7 @@ gaim_str_binary_to_ascii(const unsigned
- * URI/URL Functions
- **************************************************************************/
- gboolean
--gaim_url_parse(const char *url, char **ret_host, int *ret_port,
-+gaim2_url_parse(const char *url, char **ret_host, int *ret_port,
- char **ret_path, char **ret_user, char **ret_passwd)
- {
- char scan_info[255];
-@@ -2858,7 +2858,7 @@ gaim_url_parse(const char *url, char **r
- }
-
- static void
--destroy_fetch_url_data(GaimFetchUrlData *gfud)
-+destroy_fetch_url_data(Gaim2FetchUrlData *gfud)
- {
- if (gfud->webdata != NULL) g_free(gfud->webdata);
- if (gfud->url != NULL) g_free(gfud->url);
-@@ -2873,7 +2873,7 @@ destroy_fetch_url_data(GaimFetchUrlData
-
- static gboolean
- parse_redirect(const char *data, size_t data_len, gint sock,
-- GaimFetchUrlData *gfud)
-+ Gaim2FetchUrlData *gfud)
- {
- gchar *s;
-
-@@ -2914,13 +2914,13 @@ parse_redirect(const char *data, size_t
- }
-
- /* Close the existing stuff. */
-- gaim_input_remove(gfud->inpa);
-+ gaim2_input_remove(gfud->inpa);
- close(sock);
-
-- gaim_debug_info("gaim_url_fetch", "Redirecting to %s\n", new_url);
-+ gaim2_debug_info("gaim2_url_fetch", "Redirecting to %s\n", new_url);
-
- /* Try again, with this new location. */
-- gaim_url_fetch(new_url, full, gfud->user_agent, gfud->http11,
-+ gaim2_url_fetch(new_url, full, gfud->user_agent, gfud->http11,
- gfud->callback, gfud->user_data);
-
- /* Free up. */
-@@ -2958,16 +2958,16 @@ parse_content_len(const char *data, size
- */
- if (p && g_strstr_len(p, data_len - (p - data), "\n")) {
- sscanf(p, "Content-Length: %" G_GSIZE_FORMAT, &content_len);
-- gaim_debug_misc("parse_content_len", "parsed %u\n", content_len);
-+ gaim2_debug_misc("parse_content_len", "parsed %u\n", content_len);
- }
-
- return content_len;
- }
-
- static void
--url_fetched_cb(gpointer url_data, gint sock, GaimInputCondition cond)
-+url_fetched_cb(gpointer url_data, gint sock, Gaim2InputCondition cond)
- {
-- GaimFetchUrlData *gfud = url_data;
-+ Gaim2FetchUrlData *gfud = url_data;
- int len;
- char buf[4096];
- char *data_cursor;
-@@ -2990,7 +2990,7 @@ url_fetched_cb(gpointer url_data, gint s
- {
- /* Host header is not forbidden in HTTP/1.0 requests, and HTTP/1.1
- * clients must know how to handle the "chunked" transfer encoding.
-- * Gaim doesn't know how to handle "chunked", so should always send
-+ * Gaim2 doesn't know how to handle "chunked", so should always send
- * the Host header regardless, to get around some observed problems
- */
- g_snprintf(buf, sizeof(buf),
-@@ -3015,12 +3015,12 @@ url_fetched_cb(gpointer url_data, gint s
- gfud->website.address);
- }
-
-- gaim_debug_misc("gaim_url_fetch", "Request: %s\n", buf);
-+ gaim2_debug_misc("gaim2_url_fetch", "Request: %s\n", buf);
-
- write(sock, buf, strlen(buf));
- fcntl(sock, F_SETFL, O_NONBLOCK);
- gfud->sentreq = TRUE;
-- gfud->inpa = gaim_input_add(sock, GAIM_INPUT_READ,
-+ gfud->inpa = gaim2_input_add(sock, GAIM_INPUT_READ,
- url_fetched_cb, url_data);
- gfud->data_len = 4096;
- gfud->webdata = g_malloc(gfud->data_len);
-@@ -3056,7 +3056,7 @@ url_fetched_cb(gpointer url_data, gint s
- guint header_len = (tmp + 4 - gfud->webdata);
- size_t content_len, body_len = 0;
-
-- gaim_debug_misc("gaim_url_fetch", "Response headers: '%.*s'\n",
-+ gaim2_debug_misc("gaim2_url_fetch", "Response headers: '%.*s'\n",
- header_len, gfud->webdata);
-
- /* See if we can find a redirect. */
-@@ -3085,9 +3085,9 @@ url_fetched_cb(gpointer url_data, gint s
-
- new_data = g_try_malloc(content_len);
- if (new_data == NULL) {
-- gaim_debug_error("gaim_url_fetch", "Failed to allocate %u bytes: %s\n",
-+ gaim2_debug_error("gaim2_url_fetch", "Failed to allocate %u bytes: %s\n",
- content_len, strerror(errno));
-- gaim_input_remove(gfud->inpa);
-+ gaim2_input_remove(gfud->inpa);
- close(sock);
- gfud->callback(gfud->user_data, NULL, 0);
- destroy_fetch_url_data(gfud);
-@@ -3126,7 +3126,7 @@ url_fetched_cb(gpointer url_data, gint s
- } else if (errno != ETIMEDOUT) {
- got_eof = TRUE;
- } else {
-- gaim_input_remove(gfud->inpa);
-+ gaim2_input_remove(gfud->inpa);
- close(sock);
-
- gfud->callback(gfud->user_data, NULL, 0);
-@@ -3140,9 +3140,9 @@ url_fetched_cb(gpointer url_data, gint s
- gfud->webdata = g_realloc(gfud->webdata, gfud->len + 1);
- gfud->webdata[gfud->len] = '\0';
-
-- /* gaim_debug_misc("gaim_url_fetch", "Received: '%s'\n", gfud->webdata); */
-+ /* gaim2_debug_misc("gaim2_url_fetch", "Received: '%s'\n", gfud->webdata); */
-
-- gaim_input_remove(gfud->inpa);
-+ gaim2_input_remove(gfud->inpa);
- close(sock);
- gfud->callback(gfud->user_data, gfud->webdata, gfud->len);
-
-@@ -3151,22 +3151,22 @@ url_fetched_cb(gpointer url_data, gint s
- }
-
- void
--gaim_url_fetch(const char *url, gboolean full,
-+gaim2_url_fetch(const char *url, gboolean full,
- const char *user_agent, gboolean http11,
- void (*cb)(gpointer, const char *, size_t),
- void *user_data)
- {
- int sock;
-- GaimFetchUrlData *gfud;
-+ Gaim2FetchUrlData *gfud;
-
- g_return_if_fail(url != NULL);
- g_return_if_fail(cb != NULL);
-
-- gaim_debug_info("gaim_url_fetch",
-+ gaim2_debug_info("gaim2_url_fetch",
- "requested to fetch (%s), full=%d, user_agent=(%s), http11=%d\n",
- url, full, user_agent?user_agent:"(null)", http11);
-
-- gfud = g_new0(GaimFetchUrlData, 1);
-+ gfud = g_new0(Gaim2FetchUrlData, 1);
-
- gfud->callback = cb;
- gfud->user_data = user_data;
-@@ -3175,10 +3175,10 @@ gaim_url_fetch(const char *url, gboolean
- gfud->http11 = http11;
- gfud->full = full;
-
-- gaim_url_parse(url, &gfud->website.address, &gfud->website.port,
-+ gaim2_url_parse(url, &gfud->website.address, &gfud->website.port,
- &gfud->website.page, &gfud->website.user, &gfud->website.passwd);
-
-- if ((sock = gaim_proxy_connect(NULL, gfud->website.address,
-+ if ((sock = gaim2_proxy_connect(NULL, gfud->website.address,
- gfud->website.port, url_fetched_cb,
- gfud)) < 0)
- {
-@@ -3189,7 +3189,7 @@ gaim_url_fetch(const char *url, gboolean
- }
-
- const char *
--gaim_url_decode(const char *str)
-+gaim2_url_decode(const char *str)
- {
- static char buf[BUF_LEN];
- guint i, j = 0;
-@@ -3233,7 +3233,7 @@ gaim_url_decode(const char *str)
- }
-
- const char *
--gaim_url_encode(const char *str)
-+gaim2_url_encode(const char *str)
- {
- const char *iter;
- static char buf[BUF_LEN];
-@@ -3274,7 +3274,7 @@ gaim_url_encode(const char *str)
- * but not completely checking to avoid conflicts with IP addresses
- */
- gboolean
--gaim_email_is_valid(const char *address)
-+gaim2_email_is_valid(const char *address)
- {
- const char *c, *domain;
- static char *rfc822_specials = "()<>@,;:\\\"[]";
-@@ -3320,7 +3320,7 @@ gaim_email_is_valid(const char *address)
-
- /* Stolen from gnome_uri_list_extract_uris */
- GList *
--gaim_uri_list_extract_uris(const gchar *uri_list)
-+gaim2_uri_list_extract_uris(const gchar *uri_list)
- {
- const gchar *p, *q;
- gchar *retval;
-@@ -3367,13 +3367,13 @@ gaim_uri_list_extract_uris(const gchar *
-
- /* Stolen from gnome_uri_list_extract_filenames */
- GList *
--gaim_uri_list_extract_filenames(const gchar *uri_list)
-+gaim2_uri_list_extract_filenames(const gchar *uri_list)
- {
- GList *tmp_list, *node, *result;
-
- g_return_val_if_fail (uri_list != NULL, NULL);
-
-- result = gaim_uri_list_extract_uris(uri_list);
-+ result = gaim2_uri_list_extract_uris(uri_list);
-
- tmp_list = result;
- while (tmp_list) {
-@@ -3399,7 +3399,7 @@ gaim_uri_list_extract_filenames(const gc
- * UTF8 String Functions
- **************************************************************************/
- gchar *
--gaim_utf8_try_convert(const char *str)
-+gaim2_utf8_try_convert(const char *str)
- {
- gsize converted;
- gchar *utf8;
-@@ -3427,7 +3427,7 @@ gaim_utf8_try_convert(const char *str)
- #define utf8_first(x) ((x & 0x80) == 0 || (x & 0xe0) == 0xc0 \
- || (x & 0xf0) == 0xe0 || (x & 0xf8) == 0xf)
- gchar *
--gaim_utf8_salvage(const char *str)
-+gaim2_utf8_salvage(const char *str)
- {
- GString *workstr;
- const char *end;
-@@ -3452,7 +3452,7 @@ gaim_utf8_salvage(const char *str)
- }
-
- char *
--gaim_utf8_ncr_decode(const char *in)
-+gaim2_utf8_ncr_decode(const char *in)
- {
- GString *out = g_string_new("");
- int i;
-@@ -3483,7 +3483,7 @@ gaim_utf8_ncr_decode(const char *in)
- }
-
- int
--gaim_utf8_strcasecmp(const char *a, const char *b)
-+gaim2_utf8_strcasecmp(const char *a, const char *b)
- {
- char *a_norm = NULL;
- char *b_norm = NULL;
-@@ -3498,7 +3498,7 @@ gaim_utf8_strcasecmp(const char *a, cons
-
- if(!g_utf8_validate(a, -1, NULL) || !g_utf8_validate(b, -1, NULL))
- {
-- gaim_debug_error("gaim_utf8_strcasecmp",
-+ gaim2_debug_error("gaim2_utf8_strcasecmp",
- "One or both parameters are invalid UTF8\n");
- return ret;
- }
-@@ -3514,7 +3514,7 @@ gaim_utf8_strcasecmp(const char *a, cons
-
- /* previously conversation::find_nick() */
- gboolean
--gaim_utf8_has_word(const char *haystack, const char *needle)
-+gaim2_utf8_has_word(const char *haystack, const char *needle)
- {
- char *hay, *pin, *p;
- int n;
-@@ -3537,7 +3537,7 @@ gaim_utf8_has_word(const char *haystack,
- return ret;
- }
-
--gboolean gaim_message_meify(char *message, size_t len)
-+gboolean gaim2_message_meify(char *message, size_t len)
- {
- char *c;
- gboolean inside_html = FALSE;
-@@ -3567,7 +3567,7 @@ gboolean gaim_message_meify(char *messag
- return FALSE;
- }
-
--char *gaim_text_strip_mnemonic(const char *in)
-+char *gaim2_text_strip_mnemonic(const char *in)
- {
- char *out;
- char *a;
-@@ -3628,16 +3628,16 @@ char *gaim_text_strip_mnemonic(const cha
- return out;
- }
-
--const char* gaim_unescape_filename(const char *escaped) {
-- return gaim_url_decode(escaped);
-+const char* gaim2_unescape_filename(const char *escaped) {
-+ return gaim2_url_decode(escaped);
- }
-
-
--/* this is almost identical to gaim_url_encode (hence gaim_url_decode
-+/* this is almost identical to gaim2_url_encode (hence gaim2_url_decode
- * being used above), but we want to keep certain characters unescaped
- * for compat reasons */
- const char *
--gaim_escape_filename(const char *str)
-+gaim2_escape_filename(const char *str)
- {
- const char *iter;
- static char buf[BUF_LEN];
-diff -prNu ./src/util.h ./src/util.h
---- ./src/util.h 2005-12-14 20:06:27.000000000 +0100
-+++ ./src/util.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file util.h Utility Functions
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -22,7 +22,7 @@
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- *
-- * @todo Rename the functions so that they live somewhere in the gaim
-+ * @todo Rename the functions so that they live somewhere in the gaim2
- * namespace.
- */
- #ifndef _GAIM_UTIL_H_
-@@ -41,15 +41,15 @@ extern "C" {
- /**
- * A key-value pair.
- *
-- * This is used by, among other things, gaim_gtk_combo* functions to pass in a
-+ * This is used by, among other things, gaim2_gtk_combo* functions to pass in a
- * list of key-value pairs so it can display a user-friendly value.
- */
--typedef struct _GaimKeyValuePair
-+typedef struct _Gaim2KeyValuePair
- {
- gchar *key;
- void *value;
-
--} GaimKeyValuePair;
-+} Gaim2KeyValuePair;
-
-
-
-@@ -67,9 +67,9 @@ typedef struct _GaimKeyValuePair
- * @return The base-16 string in the ASCII encoding. Must be
- * g_free'd when no longer needed.
- *
-- * @see gaim_base16_decode()
-+ * @see gaim2_base16_decode()
- */
--gchar *gaim_base16_encode(const guchar *data, gsize len);
-+gchar *gaim2_base16_encode(const guchar *data, gsize len);
-
- /**
- * Converts an ASCII string of base-16 encoded data to
-@@ -84,9 +84,9 @@ gchar *gaim_base16_encode(const guchar *
- *
- * @return The raw data. Must be g_free'd when no longer needed.
- *
-- * @see gaim_base16_encode()
-+ * @see gaim2_base16_encode()
- */
--guchar *gaim_base16_decode(const char *str, gsize *ret_len);
-+guchar *gaim2_base16_decode(const char *str, gsize *ret_len);
-
- /*@}*/
-
-@@ -105,9 +105,9 @@ guchar *gaim_base16_decode(const char *s
- * @return The base-64 string in the ASCII encoding. Must be
- * g_free'd when no longer needed.
- *
-- * @see gaim_base64_decode()
-+ * @see gaim2_base64_decode()
- */
--gchar *gaim_base64_encode(const guchar *data, gsize len);
-+gchar *gaim2_base64_encode(const guchar *data, gsize len);
-
- /**
- * Converts an ASCII string of base-64 encoded data to
-@@ -122,9 +122,9 @@ gchar *gaim_base64_encode(const guchar *
- *
- * @return The raw data. Must be g_free'd when no longer needed.
- *
-- * @see gaim_base64_encode()
-+ * @see gaim2_base64_encode()
- */
--guchar *gaim_base64_decode(const char *str, gsize *ret_len);
-+guchar *gaim2_base64_decode(const char *str, gsize *ret_len);
-
- /*@}*/
-
-@@ -145,7 +145,7 @@ guchar *gaim_base64_decode(const char *s
- *
- * @return The readable string. Must be g_free'd when no longer needed.
- */
--guchar *gaim_quotedp_decode(const char *str, gsize *ret_len);
-+guchar *gaim2_quotedp_decode(const char *str, gsize *ret_len);
-
- /*@}*/
-
-@@ -173,7 +173,7 @@ guchar *gaim_quotedp_decode(const char *
- * converted to UTF-8. Must be g_free'd when no longer
- * needed.
- */
--char *gaim_mime_decode_field(const char *str);
-+char *gaim2_mime_decode_field(const char *str);
-
- /*@}*/
-
-@@ -191,9 +191,9 @@ char *gaim_mime_decode_field(const char
- *
- * @return The current local time.
- *
-- * @see gaim_date_full()
-+ * @see gaim2_date_full()
- */
--const char *gaim_date(void);
-+const char *gaim2_date(void);
-
- /**
- * Returns the date and time in human-readable form.
-@@ -203,9 +203,9 @@ const char *gaim_date(void);
- *
- * @return The date and time in human-readable form.
- *
-- * @see gaim_date()
-+ * @see gaim2_date()
- */
--const char *gaim_date_full(void);
-+const char *gaim2_date_full(void);
-
- /**
- * Builds a time_t from the supplied information.
-@@ -219,7 +219,7 @@ const char *gaim_date_full(void);
- *
- * @return A time_t.
- */
--time_t gaim_time_build(int year, int month, int day, int hour,
-+time_t gaim2_time_build(int year, int month, int day, int hour,
- int min, int sec);
-
- /**
-@@ -230,7 +230,7 @@ time_t gaim_time_build(int year, int mon
- *
- * @return A time_t.
- */
--time_t gaim_str_to_time(const char *timestamp, gboolean utc);
-+time_t gaim2_str_to_time(const char *timestamp, gboolean utc);
-
- /**
- * Creates a string according to a time and format string
-@@ -241,7 +241,7 @@ time_t gaim_str_to_time(const char *time
- * TODO: The warning is gone in gcc4, and this function can
- * eventually be removed.
- */
--size_t gaim_strftime(char *s, size_t max, const char *format, const struct tm *tm);
-+size_t gaim2_strftime(char *s, size_t max, const char *format, const struct tm *tm);
-
- /*@}*/
-
-@@ -265,7 +265,7 @@ size_t gaim_strftime(char *s, size_t max
- * @param attributes the attributes, if the tag was found
- * @return TRUE if the tag was found
- */
--gboolean gaim_markup_find_tag(const char *needle, const char *haystack,
-+gboolean gaim2_markup_find_tag(const char *needle, const char *haystack,
- const char **start, const char **end,
- GData **attributes);
-
-@@ -291,7 +291,7 @@ gboolean gaim_markup_find_tag(const char
- *
- * @return TRUE if successful, or FALSE otherwise.
- */
--gboolean gaim_markup_extract_info_field(const char *str, int len, GString *dest,
-+gboolean gaim2_markup_extract_info_field(const char *str, int len, GString *dest,
- const char *start_token, int skip,
- const char *end_token, char check_value,
- const char *no_value_token,
-@@ -305,7 +305,7 @@ gboolean gaim_markup_extract_info_field(
- * @param dest_xhtml The destination XHTML output.
- * @param dest_plain The destination plain-text output.
- */
--void gaim_markup_html_to_xhtml(const char *html, char **dest_xhtml,
-+void gaim2_markup_html_to_xhtml(const char *html, char **dest_xhtml,
- char **dest_plain);
-
- /**
-@@ -315,7 +315,7 @@ void gaim_markup_html_to_xhtml(const cha
- *
- * @return The new string without HTML. This must be freed.
- */
--char *gaim_markup_strip_html(const char *str);
-+char *gaim2_markup_strip_html(const char *str);
-
- /**
- * Adds the necessary HTML code to turn URIs into HTML links in a string.
-@@ -324,7 +324,7 @@ char *gaim_markup_strip_html(const char
- *
- * @return The linkified text.
- */
--char *gaim_markup_linkify(const char *str);
-+char *gaim2_markup_linkify(const char *str);
-
- /**
- * Unescapes HTML entities to their literal characters.
-@@ -336,7 +336,7 @@ char *gaim_markup_linkify(const char *st
- *
- * @return the text with HTML entities literalized
- */
--char *gaim_unescape_html(const char *html);
-+char *gaim2_unescape_html(const char *html);
-
- /**
- * Returns a newly allocated substring of the HTML UTF-8 string "str".
-@@ -348,7 +348,7 @@ char *gaim_unescape_html(const char *htm
- * Note that x and y are in character offsets, not byte offsets, and
- * are offsets into an unformatted version of str. Because of this,
- * this function may be sensitive to changes in GtkIMHtml and may break
-- * when used with other UI's. libgaim users are encouraged to report and
-+ * when used with other UI's. libgaim2 users are encouraged to report and
- * work out any problems encountered.
- *
- * @param str The input NUL terminated, HTML, UTF-8 (or ASCII) string.
-@@ -359,7 +359,7 @@ char *gaim_unescape_html(const char *htm
- *
- * @return The HTML slice of string, with all formatting retained.
- */
--char *gaim_markup_slice(const char *str, guint x, guint y);
-+char *gaim2_markup_slice(const char *str, guint x, guint y);
-
- /**
- * Returns a newly allocated string containing the name of the tag
-@@ -370,7 +370,7 @@ char *gaim_markup_slice(const char *str,
- * @param tag The string starting a HTML tag.
- * @return A string containing the name of the tag.
- */
--char *gaim_markup_get_tag_name(const char *tag);
-+char *gaim2_markup_get_tag_name(const char *tag);
-
- /*@}*/
-
-@@ -385,25 +385,25 @@ char *gaim_markup_get_tag_name(const cha
- *
- * @return The user's home directory.
- *
-- * @see gaim_user_dir()
-+ * @see gaim2_user_dir()
- */
--const gchar *gaim_home_dir(void);
-+const gchar *gaim2_home_dir(void);
-
- /**
-- * Returns the gaim settings directory in the user's home directory.
-- * This is usually ~/.gaim
-+ * Returns the gaim2 settings directory in the user's home directory.
-+ * This is usually ~/.gaim2
- *
-- * @return The gaim settings directory.
-+ * @return The gaim2 settings directory.
- *
-- * @see gaim_home_dir()
-+ * @see gaim2_home_dir()
- */
--const char *gaim_user_dir(void);
-+const char *gaim2_user_dir(void);
-
- /**
-- * Define a custom gaim settings directory, overriding the default (user's home directory/.gaim)
-+ * Define a custom gaim2 settings directory, overriding the default (user's home directory/.gaim2)
- * @param dir The custom settings directory
- */
--void gaim_util_set_user_dir(const char *dir);
-+void gaim2_util_set_user_dir(const char *dir);
-
- /**
- * Builds a complete path from the root, making any directories along
-@@ -415,32 +415,32 @@ void gaim_util_set_user_dir(const char *
- *
- * @return 0 for success, nonzero on any error.
- */
--int gaim_build_dir(const char *path, int mode);
-+int gaim2_build_dir(const char *path, int mode);
-
- /**
-- * Write a string of data to a file of the given name in the Gaim
-- * user directory ($HOME/.gaim by default). The data is typically
-- * a serialized version of one of Gaim's config files, such as
-+ * Write a string of data to a file of the given name in the Gaim2
-+ * user directory ($HOME/.gaim2 by default). The data is typically
-+ * a serialized version of one of Gaim2's config files, such as
- * prefs.xml, accounts.xml, etc. And the string is typically
- * obtained using xmlnode_to_formatted_str. However, this function
- * should work fine for saving binary files as well.
- *
-- * @param filename The basename of the file to write in the gaim_user_dir.
-+ * @param filename The basename of the file to write in the gaim2_user_dir.
- * @param data A null-terminated string of data to write.
- * @param size The size of the data to save. If data is
- * null-terminated you can pass in -1.
- *
- * @return TRUE if the file was written successfully. FALSE otherwise.
- */
--gboolean gaim_util_write_data_to_file(const char *filename, const char *data,
-+gboolean gaim2_util_write_data_to_file(const char *filename, const char *data,
- size_t size);
-
- /**
- * Read the contents of a given file and parse the results into an
- * xmlnode tree structure. This is intended to be used to read
-- * Gaim's configuration xml files (prefs.xml, pounces.xml, etc.)
-+ * Gaim2's configuration xml files (prefs.xml, pounces.xml, etc.)
- *
-- * @param filename The basename of the file to open in the gaim_user_dir.
-+ * @param filename The basename of the file to open in the gaim2_user_dir.
- * @param description A very short description of the contents of this
- * file. This is used in error messages shown to the
- * user when the file can not be opened. For example,
-@@ -449,7 +449,7 @@ gboolean gaim_util_write_data_to_file(co
- * @return An xmlnode tree of the contents of the given file. Or NULL, if
- * the file does not exist or there was an error reading the file.
- */
--xmlnode *gaim_util_read_xml_from_file(const char *filename,
-+xmlnode *gaim2_util_read_xml_from_file(const char *filename,
- const char *description);
-
- /**
-@@ -468,7 +468,7 @@ xmlnode *gaim_util_read_xml_from_file(co
- *
- * @return A file pointer to the temporary file, or @c NULL on failure.
- */
--FILE *gaim_mkstemp(char **path, gboolean binary);
-+FILE *gaim2_mkstemp(char **path, gboolean binary);
-
- /**
- * Checks if the given program name is valid and executable.
-@@ -477,21 +477,21 @@ FILE *gaim_mkstemp(char **path, gboolean
- *
- * @return TRUE if the program is runable.
- */
--gboolean gaim_program_is_valid(const char *program);
-+gboolean gaim2_program_is_valid(const char *program);
-
- /**
- * Check if running GNOME.
- *
- * @return TRUE if running GNOME, FALSE otherwise.
- */
--gboolean gaim_running_gnome(void);
-+gboolean gaim2_running_gnome(void);
-
- /**
- * Check if running KDE.
- *
- * @return TRUE if running KDE, FALSE otherwise.
- */
--gboolean gaim_running_kde(void);
-+gboolean gaim2_running_kde(void);
-
- /**
- * Returns the IP address from a socket file descriptor.
-@@ -500,7 +500,7 @@ gboolean gaim_running_kde(void);
- *
- * @return The IP address, or @c NULL on error.
- */
--char *gaim_fd_get_ip(int fd);
-+char *gaim2_fd_get_ip(int fd);
-
- /*@}*/
-
-@@ -527,7 +527,7 @@ char *gaim_fd_get_ip(int fd);
- *
- * @return A pointer to the normalized version stored in a static buffer.
- */
--const char *gaim_normalize(const GaimAccount *account, const char *str);
-+const char *gaim2_normalize(const Gaim2Account *account, const char *str);
-
- /**
- * Normalizes a string, so that it is suitable for comparison.
-@@ -541,7 +541,7 @@ const char *gaim_normalize(const GaimAcc
- *
- * @return A pointer to the normalized version stored in a static buffer.
- */
--const char *gaim_normalize_nocase(const GaimAccount *account, const char *str);
-+const char *gaim2_normalize_nocase(const Gaim2Account *account, const char *str);
-
- /**
- * Compares two strings to see if the first contains the second as
-@@ -552,7 +552,7 @@ const char *gaim_normalize_nocase(const
- *
- * @return TRUE if p is a prefix of s, otherwise FALSE.
- */
--gboolean gaim_str_has_prefix(const char *s, const char *p);
-+gboolean gaim2_str_has_prefix(const char *s, const char *p);
-
- /**
- * Compares two strings to see if the second is a proper suffix
-@@ -563,7 +563,7 @@ gboolean gaim_str_has_prefix(const char
- *
- * @return TRUE if x is a a suffix of s, otherwise FALSE.
- */
--gboolean gaim_str_has_suffix(const char *s, const char *x);
-+gboolean gaim2_str_has_suffix(const char *s, const char *x);
-
- /**
- * Looks for %n, %d, or %t in a string, and replaces them with the
-@@ -575,7 +575,7 @@ gboolean gaim_str_has_suffix(const char
- * @return A newly allocated string where the special variables are
- * expanded. This should be g_free'd by the caller.
- */
--gchar *gaim_str_sub_away_formatters(const char *str, const char *name);
-+gchar *gaim2_str_sub_away_formatters(const char *str, const char *name);
-
- /**
- * Duplicates a string and replaces all newline characters from the
-@@ -585,7 +585,7 @@ gchar *gaim_str_sub_away_formatters(cons
- *
- * @return The new string. Must be g_free'd by the caller.
- */
--gchar *gaim_strdup_withhtml(const gchar *src);
-+gchar *gaim2_strdup_withhtml(const gchar *src);
-
- /**
- * Ensures that all linefeeds have a matching carriage return.
-@@ -594,7 +594,7 @@ gchar *gaim_strdup_withhtml(const gchar
- *
- * @return The string with carriage returns.
- */
--char *gaim_str_add_cr(const char *str);
-+char *gaim2_str_add_cr(const char *str);
-
- /**
- * Strips all instances of the given character from the
-@@ -602,12 +602,12 @@ char *gaim_str_add_cr(const char *str);
- * is useful for stripping new line characters, for example.
- *
- * Example usage:
-- * gaim_str_strip_char(my_dumb_string, '\n');
-+ * gaim2_str_strip_char(my_dumb_string, '\n');
- *
- * @param str The string to strip characters from.
- * @param thechar The character to strip from the given string.
- */
--void gaim_str_strip_char(char *str, char thechar);
-+void gaim2_str_strip_char(char *str, char thechar);
-
- /**
- * Given a string, this replaces all instances of one character
-@@ -619,7 +619,7 @@ void gaim_str_strip_char(char *str, char
- * @param replacement The character you want inserted in place
- * of the delimiting character.
- */
--void gaim_util_chrreplace(char *string, char delimiter,
-+void gaim2_util_chrreplace(char *string, char delimiter,
- char replacement);
-
- /**
-@@ -634,7 +634,7 @@ void gaim_util_chrreplace(char *string,
- * @return A new string, after performing the substitution.
- * free this with g_free().
- */
--gchar *gaim_strreplace(const char *string, const char *delimiter,
-+gchar *gaim2_strreplace(const char *string, const char *delimiter,
- const char *replacement);
-
- /**
-@@ -647,7 +647,7 @@ gchar *gaim_strreplace(const char *strin
- * @return A new string, with numerical character references
- * replaced with actual utf-8, free this with g_free().
- */
--char *gaim_utf8_ncr_decode(const char *in);
-+char *gaim2_utf8_ncr_decode(const char *in);
-
- /**
- * Given a string, this replaces one substring with another
-@@ -661,7 +661,7 @@ char *gaim_utf8_ncr_decode(const char *i
- * @return A new string, after performing the substitution.
- * free this with g_free().
- */
--gchar *gaim_strcasereplace(const char *string, const char *delimiter,
-+gchar *gaim2_strcasereplace(const char *string, const char *delimiter,
- const char *replacement);
-
- /**
-@@ -673,7 +673,7 @@ gchar *gaim_strcasereplace(const char *s
- *
- * @return the location of the substring if found, or NULL if not
- */
--const char *gaim_strcasestr(const char *haystack, const char *needle);
-+const char *gaim2_strcasestr(const char *haystack, const char *needle);
-
- /**
- * Returns a string representing a filesize in the appropriate
-@@ -683,7 +683,7 @@ const char *gaim_strcasestr(const char *
- *
- * @return The string in units form. This must be freed.
- */
--char *gaim_str_size_to_units(size_t size);
-+char *gaim2_str_size_to_units(size_t size);
-
- /**
- * Converts seconds into a human-readable form.
-@@ -693,7 +693,7 @@ char *gaim_str_size_to_units(size_t size
- * @return A human-readable form, containing days, hours, minutes, and
- * seconds.
- */
--char *gaim_str_seconds_to_string(guint sec);
-+char *gaim2_str_seconds_to_string(guint sec);
-
- /**
- * Converts a binary string into a NUL terminated ascii string,
-@@ -708,7 +708,7 @@ char *gaim_str_seconds_to_string(guint s
- *
- * @return A newly allocated ASCIIZ string.
- */
--char *gaim_str_binary_to_ascii(const unsigned char *binary, guint len);
-+char *gaim2_str_binary_to_ascii(const unsigned char *binary, guint len);
- /*@}*/
-
-
-@@ -729,7 +729,7 @@ char *gaim_str_binary_to_ascii(const uns
- * @param ret_user The returned username.
- * @param ret_passwd The returned password.
- */
--gboolean gaim_url_parse(const char *url, char **ret_host, int *ret_port,
-+gboolean gaim2_url_parse(const char *url, char **ret_host, int *ret_port,
- char **ret_path, char **ret_user, char **ret_passwd);
-
- /**
-@@ -743,7 +743,7 @@ gboolean gaim_url_parse(const char *url,
- * @param cb The callback function.
- * @param data The user data to pass to the callback function.
- */
--void gaim_url_fetch(const char *url, gboolean full,
-+void gaim2_url_fetch(const char *url, gboolean full,
- const char *user_agent, gboolean http11,
- void (*cb)(void *, const char *, size_t),
- void *data);
-@@ -756,7 +756,7 @@ void gaim_url_fetch(const char *url, gbo
- *
- * @return The resulting string.
- */
--const char *gaim_url_decode(const char *str);
-+const char *gaim2_url_decode(const char *str);
-
- /**
- * Encodes a URL into an escaped string.
-@@ -767,7 +767,7 @@ const char *gaim_url_decode(const char *
- *
- * @return The resulting string.
- */
--const char *gaim_url_encode(const char *str);
-+const char *gaim2_url_encode(const char *str);
-
- /**
- * Checks if the given email address is syntactically valid.
-@@ -776,7 +776,7 @@ const char *gaim_url_encode(const char *
- *
- * @return True if the email address is syntactically correct.
- */
--gboolean gaim_email_is_valid(const char *address);
-+gboolean gaim2_email_is_valid(const char *address);
-
- /**
- * This function extracts a list of URIs from the a "text/uri-list"
-@@ -787,7 +787,7 @@ gboolean gaim_email_is_valid(const char
- * @return A GList containing strings allocated with g_malloc
- * that have been splitted from uri-list.
- */
--GList *gaim_uri_list_extract_uris(const gchar *uri_list);
-+GList *gaim2_uri_list_extract_uris(const gchar *uri_list);
-
- /**
- * This function extracts a list of filenames from a
-@@ -798,10 +798,10 @@ GList *gaim_uri_list_extract_uris(const
- *
- * @return A GList containing strings allocated with g_malloc that
- * contain the filenames in the uri-list. Note that unlike
-- * gaim_uri_list_extract_uris() function, this will discard
-+ * gaim2_uri_list_extract_uris() function, this will discard
- * any non-file uri from the result value.
- */
--GList *gaim_uri_list_extract_filenames(const gchar *uri_list);
-+GList *gaim2_uri_list_extract_filenames(const gchar *uri_list);
-
- /*@}*/
-
-@@ -819,7 +819,7 @@ GList *gaim_uri_list_extract_filenames(c
- *
- * @return The UTF-8 string, or @c NULL if it could not be converted.
- */
--gchar *gaim_utf8_try_convert(const char *str);
-+gchar *gaim2_utf8_try_convert(const char *str);
-
- /**
- * Salvages the valid UTF-8 characters from a string, replacing any
-@@ -830,7 +830,7 @@ gchar *gaim_utf8_try_convert(const char
- *
- * @return A valid UTF-8 string.
- */
--gchar *gaim_utf8_salvage(const char *str);
-+gchar *gaim2_utf8_salvage(const char *str);
-
- /**
- * Compares two UTF-8 strings.
-@@ -842,7 +842,7 @@ gchar *gaim_utf8_salvage(const char *str
- * 0 if @a is equal to @a b.
- * 1 if @a is greater than @a b.
- */
--int gaim_utf8_strcasecmp(const char *a, const char *b);
-+int gaim2_utf8_strcasecmp(const char *a, const char *b);
-
- /**
- * Case insensitive search for a word in a string. The needle string
-@@ -854,7 +854,7 @@ int gaim_utf8_strcasecmp(const char *a,
- *
- * @return TRUE if haystack has the word, otherwise FALSE
- */
--gboolean gaim_utf8_has_word(const char *haystack, const char *needle);
-+gboolean gaim2_utf8_has_word(const char *haystack, const char *needle);
-
- /**
- * Checks for messages starting with "/me "
-@@ -864,7 +864,7 @@ gboolean gaim_utf8_has_word(const char *
- *
- * @return TRUE if it starts with /me, and it has been removed, otherwise FALSE
- */
--gboolean gaim_message_meify(char *message, size_t len);
-+gboolean gaim2_message_meify(char *message, size_t len);
-
- /**
- * Removes the underscore characters from a string used identify the mnemonic
-@@ -874,7 +874,7 @@ gboolean gaim_message_meify(char *messag
- *
- * @return The stripped string
- */
--char *gaim_text_strip_mnemonic(const char *in);
-+char *gaim2_text_strip_mnemonic(const char *in);
-
- /*@}*/
-
-@@ -887,10 +887,10 @@ char *gaim_text_strip_mnemonic(const cha
- *
- * @return x + 8
- */
--#define gaim_add_eight(x) ((x)+8)
-+#define gaim2_add_eight(x) ((x)+8)
-
- /**
-- * Does the reverse of gaim_escape_filename
-+ * Does the reverse of gaim2_escape_filename
- *
- * This will change hex codes and such to their ascii equivalents.
- *
-@@ -898,7 +898,7 @@ char *gaim_text_strip_mnemonic(const cha
- *
- * @return The resulting string.
- */
--const char *gaim_unescape_filename(const char *str);
-+const char *gaim2_unescape_filename(const char *str);
-
- /**
- * Escapes filesystem-unfriendly characters from a filename
-@@ -907,7 +907,7 @@ const char *gaim_unescape_filename(const
- *
- * @return The resulting string.
- */
--const char *gaim_escape_filename(const char *str);
-+const char *gaim2_escape_filename(const char *str);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/value.c ./src/value.c
---- ./src/value.c 2004-04-26 00:31:48.000000000 +0200
-+++ ./src/value.c 2006-01-05 15:11:04.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file value.c Value wrapper API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,15 +28,15 @@
-
- #define OUTGOING_FLAG 0x01
-
--GaimValue *
--gaim_value_new(GaimType type, ...)
-+Gaim2Value *
-+gaim2_value_new(Gaim2Type type, ...)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
- va_list args;
-
- g_return_val_if_fail(type != GAIM_TYPE_UNKNOWN, NULL);
-
-- value = g_new0(GaimValue, 1);
-+ value = g_new0(Gaim2Value, 1);
-
- value->type = type;
-
-@@ -52,15 +52,15 @@ gaim_value_new(GaimType type, ...)
- return value;
- }
-
--GaimValue *
--gaim_value_new_outgoing(GaimType type, ...)
-+Gaim2Value *
-+gaim2_value_new_outgoing(Gaim2Type type, ...)
- {
-- GaimValue *value;
-+ Gaim2Value *value;
- va_list args;
-
- g_return_val_if_fail(type != GAIM_TYPE_UNKNOWN, NULL);
-
-- value = g_new0(GaimValue, 1);
-+ value = g_new0(Gaim2Value, 1);
-
- value->type = type;
-
-@@ -79,16 +79,16 @@ gaim_value_new_outgoing(GaimType type, .
- }
-
- void
--gaim_value_destroy(GaimValue *value)
-+gaim2_value_destroy(Gaim2Value *value)
- {
- g_return_if_fail(value != NULL);
-
-- if (gaim_value_get_type(value) == GAIM_TYPE_BOXED)
-+ if (gaim2_value_get_type(value) == GAIM_TYPE_BOXED)
- {
- if (value->u.specific_type != NULL)
- g_free(value->u.specific_type);
- }
-- else if (gaim_value_get_type(value) == GAIM_TYPE_STRING)
-+ else if (gaim2_value_get_type(value) == GAIM_TYPE_STRING)
- {
- if (value->data.string_data != NULL)
- g_free(value->data.string_data);
-@@ -97,95 +97,95 @@ gaim_value_destroy(GaimValue *value)
- g_free(value);
- }
-
--GaimValue *
--gaim_value_dup(const GaimValue *value)
-+Gaim2Value *
-+gaim2_value_dup(const Gaim2Value *value)
- {
-- GaimValue *new_value;
-- GaimType type;
-+ Gaim2Value *new_value;
-+ Gaim2Type type;
-
- g_return_val_if_fail(value != NULL, NULL);
-
-- type = gaim_value_get_type(value);
-+ type = gaim2_value_get_type(value);
-
- if (type == GAIM_TYPE_SUBTYPE)
- {
-- new_value = gaim_value_new(GAIM_TYPE_SUBTYPE,
-- gaim_value_get_subtype(value));
-+ new_value = gaim2_value_new(GAIM_TYPE_SUBTYPE,
-+ gaim2_value_get_subtype(value));
- }
- else if (type == GAIM_TYPE_BOXED)
- {
-- new_value = gaim_value_new(GAIM_TYPE_BOXED,
-- gaim_value_get_specific_type(value));
-+ new_value = gaim2_value_new(GAIM_TYPE_BOXED,
-+ gaim2_value_get_specific_type(value));
- }
- else
-- new_value = gaim_value_new(type);
-+ new_value = gaim2_value_new(type);
-
- new_value->flags = value->flags;
-
- switch (type)
- {
- case GAIM_TYPE_CHAR:
-- gaim_value_set_char(new_value, gaim_value_get_char(value));
-+ gaim2_value_set_char(new_value, gaim2_value_get_char(value));
- break;
-
- case GAIM_TYPE_UCHAR:
-- gaim_value_set_uchar(new_value, gaim_value_get_uchar(value));
-+ gaim2_value_set_uchar(new_value, gaim2_value_get_uchar(value));
- break;
-
- case GAIM_TYPE_BOOLEAN:
-- gaim_value_set_boolean(new_value, gaim_value_get_boolean(value));
-+ gaim2_value_set_boolean(new_value, gaim2_value_get_boolean(value));
- break;
-
- case GAIM_TYPE_SHORT:
-- gaim_value_set_short(new_value, gaim_value_get_short(value));
-+ gaim2_value_set_short(new_value, gaim2_value_get_short(value));
- break;
-
- case GAIM_TYPE_USHORT:
-- gaim_value_set_ushort(new_value, gaim_value_get_ushort(value));
-+ gaim2_value_set_ushort(new_value, gaim2_value_get_ushort(value));
- break;
-
- case GAIM_TYPE_INT:
-- gaim_value_set_int(new_value, gaim_value_get_int(value));
-+ gaim2_value_set_int(new_value, gaim2_value_get_int(value));
- break;
-
- case GAIM_TYPE_UINT:
-- gaim_value_set_uint(new_value, gaim_value_get_uint(value));
-+ gaim2_value_set_uint(new_value, gaim2_value_get_uint(value));
- break;
-
- case GAIM_TYPE_LONG:
-- gaim_value_set_long(new_value, gaim_value_get_long(value));
-+ gaim2_value_set_long(new_value, gaim2_value_get_long(value));
- break;
-
- case GAIM_TYPE_ULONG:
-- gaim_value_set_ulong(new_value, gaim_value_get_ulong(value));
-+ gaim2_value_set_ulong(new_value, gaim2_value_get_ulong(value));
- break;
-
- case GAIM_TYPE_INT64:
-- gaim_value_set_int64(new_value, gaim_value_get_int64(value));
-+ gaim2_value_set_int64(new_value, gaim2_value_get_int64(value));
- break;
-
- case GAIM_TYPE_UINT64:
-- gaim_value_set_uint64(new_value, gaim_value_get_uint64(value));
-+ gaim2_value_set_uint64(new_value, gaim2_value_get_uint64(value));
- break;
-
- case GAIM_TYPE_STRING:
-- gaim_value_set_string(new_value, gaim_value_get_string(value));
-+ gaim2_value_set_string(new_value, gaim2_value_get_string(value));
- break;
-
- case GAIM_TYPE_OBJECT:
-- gaim_value_set_object(new_value, gaim_value_get_object(value));
-+ gaim2_value_set_object(new_value, gaim2_value_get_object(value));
- break;
-
- case GAIM_TYPE_POINTER:
-- gaim_value_set_pointer(new_value, gaim_value_get_pointer(value));
-+ gaim2_value_set_pointer(new_value, gaim2_value_get_pointer(value));
- break;
-
- case GAIM_TYPE_ENUM:
-- gaim_value_set_enum(new_value, gaim_value_get_enum(value));
-+ gaim2_value_set_enum(new_value, gaim2_value_get_enum(value));
- break;
-
- case GAIM_TYPE_BOXED:
-- gaim_value_set_boxed(new_value, gaim_value_get_boxed(value));
-+ gaim2_value_set_boxed(new_value, gaim2_value_get_boxed(value));
- break;
-
- default:
-@@ -195,8 +195,8 @@ gaim_value_dup(const GaimValue *value)
- return new_value;
- }
-
--GaimType
--gaim_value_get_type(const GaimValue *value)
-+Gaim2Type
-+gaim2_value_get_type(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, GAIM_TYPE_UNKNOWN);
-
-@@ -204,25 +204,25 @@ gaim_value_get_type(const GaimValue *val
- }
-
- unsigned int
--gaim_value_get_subtype(const GaimValue *value)
-+gaim2_value_get_subtype(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_SUBTYPE, 0);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_SUBTYPE, 0);
-
- return value->u.subtype;
- }
-
- const char *
--gaim_value_get_specific_type(const GaimValue *value)
-+gaim2_value_get_specific_type(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, NULL);
-- g_return_val_if_fail(gaim_value_get_type(value) == GAIM_TYPE_BOXED, NULL);
-+ g_return_val_if_fail(gaim2_value_get_type(value) == GAIM_TYPE_BOXED, NULL);
-
- return value->u.specific_type;
- }
-
- gboolean
--gaim_value_is_outgoing(const GaimValue *value)
-+gaim2_value_is_outgoing(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, FALSE);
-
-@@ -230,7 +230,7 @@ gaim_value_is_outgoing(const GaimValue *
- }
-
- void
--gaim_value_set_char(GaimValue *value, char data)
-+gaim2_value_set_char(Gaim2Value *value, char data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -238,7 +238,7 @@ gaim_value_set_char(GaimValue *value, ch
- }
-
- void
--gaim_value_set_uchar(GaimValue *value, unsigned char data)
-+gaim2_value_set_uchar(Gaim2Value *value, unsigned char data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -246,7 +246,7 @@ gaim_value_set_uchar(GaimValue *value, u
- }
-
- void
--gaim_value_set_boolean(GaimValue *value, gboolean data)
-+gaim2_value_set_boolean(Gaim2Value *value, gboolean data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -254,7 +254,7 @@ gaim_value_set_boolean(GaimValue *value,
- }
-
- void
--gaim_value_set_short(GaimValue *value, short data)
-+gaim2_value_set_short(Gaim2Value *value, short data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -262,7 +262,7 @@ gaim_value_set_short(GaimValue *value, s
- }
-
- void
--gaim_value_set_ushort(GaimValue *value, unsigned short data)
-+gaim2_value_set_ushort(Gaim2Value *value, unsigned short data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -270,7 +270,7 @@ gaim_value_set_ushort(GaimValue *value,
- }
-
- void
--gaim_value_set_int(GaimValue *value, int data)
-+gaim2_value_set_int(Gaim2Value *value, int data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -278,7 +278,7 @@ gaim_value_set_int(GaimValue *value, int
- }
-
- void
--gaim_value_set_uint(GaimValue *value, unsigned int data)
-+gaim2_value_set_uint(Gaim2Value *value, unsigned int data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -286,7 +286,7 @@ gaim_value_set_uint(GaimValue *value, un
- }
-
- void
--gaim_value_set_long(GaimValue *value, long data)
-+gaim2_value_set_long(Gaim2Value *value, long data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -294,7 +294,7 @@ gaim_value_set_long(GaimValue *value, lo
- }
-
- void
--gaim_value_set_ulong(GaimValue *value, unsigned long data)
-+gaim2_value_set_ulong(Gaim2Value *value, unsigned long data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -302,7 +302,7 @@ gaim_value_set_ulong(GaimValue *value, u
- }
-
- void
--gaim_value_set_int64(GaimValue *value, gint64 data)
-+gaim2_value_set_int64(Gaim2Value *value, gint64 data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -310,7 +310,7 @@ gaim_value_set_int64(GaimValue *value, g
- }
-
- void
--gaim_value_set_uint64(GaimValue *value, guint64 data)
-+gaim2_value_set_uint64(Gaim2Value *value, guint64 data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -318,7 +318,7 @@ gaim_value_set_uint64(GaimValue *value,
- }
-
- void
--gaim_value_set_string(GaimValue *value, const char *data)
-+gaim2_value_set_string(Gaim2Value *value, const char *data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -329,7 +329,7 @@ gaim_value_set_string(GaimValue *value,
- }
-
- void
--gaim_value_set_object(GaimValue *value, void *data)
-+gaim2_value_set_object(Gaim2Value *value, void *data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -337,7 +337,7 @@ gaim_value_set_object(GaimValue *value,
- }
-
- void
--gaim_value_set_pointer(GaimValue *value, void *data)
-+gaim2_value_set_pointer(Gaim2Value *value, void *data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -345,7 +345,7 @@ gaim_value_set_pointer(GaimValue *value,
- }
-
- void
--gaim_value_set_enum(GaimValue *value, int data)
-+gaim2_value_set_enum(Gaim2Value *value, int data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -353,7 +353,7 @@ gaim_value_set_enum(GaimValue *value, in
- }
-
- void
--gaim_value_set_boxed(GaimValue *value, void *data)
-+gaim2_value_set_boxed(Gaim2Value *value, void *data)
- {
- g_return_if_fail(value != NULL);
-
-@@ -361,7 +361,7 @@ gaim_value_set_boxed(GaimValue *value, v
- }
-
- char
--gaim_value_get_char(const GaimValue *value)
-+gaim2_value_get_char(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -369,7 +369,7 @@ gaim_value_get_char(const GaimValue *val
- }
-
- unsigned char
--gaim_value_get_uchar(const GaimValue *value)
-+gaim2_value_get_uchar(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -377,7 +377,7 @@ gaim_value_get_uchar(const GaimValue *va
- }
-
- gboolean
--gaim_value_get_boolean(const GaimValue *value)
-+gaim2_value_get_boolean(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, FALSE);
-
-@@ -385,7 +385,7 @@ gaim_value_get_boolean(const GaimValue *
- }
-
- short
--gaim_value_get_short(const GaimValue *value)
-+gaim2_value_get_short(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -393,7 +393,7 @@ gaim_value_get_short(const GaimValue *va
- }
-
- unsigned short
--gaim_value_get_ushort(const GaimValue *value)
-+gaim2_value_get_ushort(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -401,7 +401,7 @@ gaim_value_get_ushort(const GaimValue *v
- }
-
- int
--gaim_value_get_int(const GaimValue *value)
-+gaim2_value_get_int(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -409,7 +409,7 @@ gaim_value_get_int(const GaimValue *valu
- }
-
- unsigned int
--gaim_value_get_uint(const GaimValue *value)
-+gaim2_value_get_uint(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -417,7 +417,7 @@ gaim_value_get_uint(const GaimValue *val
- }
-
- long
--gaim_value_get_long(const GaimValue *value)
-+gaim2_value_get_long(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -425,7 +425,7 @@ gaim_value_get_long(const GaimValue *val
- }
-
- unsigned long
--gaim_value_get_ulong(const GaimValue *value)
-+gaim2_value_get_ulong(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -433,7 +433,7 @@ gaim_value_get_ulong(const GaimValue *va
- }
-
- gint64
--gaim_value_get_int64(const GaimValue *value)
-+gaim2_value_get_int64(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -441,7 +441,7 @@ gaim_value_get_int64(const GaimValue *va
- }
-
- guint64
--gaim_value_get_uint64(const GaimValue *value)
-+gaim2_value_get_uint64(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, 0);
-
-@@ -449,7 +449,7 @@ gaim_value_get_uint64(const GaimValue *v
- }
-
- const char *
--gaim_value_get_string(const GaimValue *value)
-+gaim2_value_get_string(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, NULL);
-
-@@ -457,7 +457,7 @@ gaim_value_get_string(const GaimValue *v
- }
-
- void *
--gaim_value_get_object(const GaimValue *value)
-+gaim2_value_get_object(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, NULL);
-
-@@ -465,7 +465,7 @@ gaim_value_get_object(const GaimValue *v
- }
-
- void *
--gaim_value_get_pointer(const GaimValue *value)
-+gaim2_value_get_pointer(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, NULL);
-
-@@ -473,7 +473,7 @@ gaim_value_get_pointer(const GaimValue *
- }
-
- int
--gaim_value_get_enum(const GaimValue *value)
-+gaim2_value_get_enum(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, -1);
-
-@@ -481,7 +481,7 @@ gaim_value_get_enum(const GaimValue *val
- }
-
- void *
--gaim_value_get_boxed(const GaimValue *value)
-+gaim2_value_get_boxed(const Gaim2Value *value)
- {
- g_return_val_if_fail(value != NULL, NULL);
-
-diff -prNu ./src/value.h ./src/value.h
---- ./src/value.h 2005-11-05 02:57:00.000000000 +0100
-+++ ./src/value.h 2006-01-05 15:11:20.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file value.h Value wrapper API
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -51,10 +51,10 @@ typedef enum
- GAIM_TYPE_ENUM, /**< Enum. */
- GAIM_TYPE_BOXED /**< Boxed pointer with specific type. */
-
--} GaimType;
-+} Gaim2Type;
-
- /**
-- * Gaim-specific subtype values.
-+ * Gaim2-specific subtype values.
- */
- typedef enum
- {
-@@ -73,14 +73,14 @@ typedef enum
- GAIM_SUBTYPE_CIPHER,
- GAIM_SUBTYPE_STATUS
-
--} GaimSubType;
-+} Gaim2SubType;
-
- /**
- * A wrapper for a type, subtype, and specific type of value.
- */
- typedef struct
- {
-- GaimType type;
-+ Gaim2Type type;
- unsigned short flags;
-
- union
-@@ -111,14 +111,14 @@ typedef struct
-
- } u;
-
--} GaimValue;
-+} Gaim2Value;
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- /**
-- * Creates a new GaimValue.
-+ * Creates a new Gaim2Value.
- *
- * This function takes a type and, depending on that type, a sub-type
- * or specific type.
-@@ -136,10 +136,10 @@ extern "C" {
- *
- * @return The new value.
- */
--GaimValue *gaim_value_new(GaimType type, ...);
-+Gaim2Value *gaim2_value_new(Gaim2Type type, ...);
-
- /**
-- * Creates a new outgoing GaimValue. If a value is an "outgoing" value
-+ * Creates a new outgoing Gaim2Value. If a value is an "outgoing" value
- * it means the value can be modified by plugins and scripts.
- *
- * This function takes a type and, depending on that type, a sub-type
-@@ -158,23 +158,23 @@ GaimValue *gaim_value_new(GaimType type,
- *
- * @return The new value.
- */
--GaimValue *gaim_value_new_outgoing(GaimType type, ...);
-+Gaim2Value *gaim2_value_new_outgoing(Gaim2Type type, ...);
-
- /**
-- * Destroys a GaimValue.
-+ * Destroys a Gaim2Value.
- *
- * @param value The value to destroy.
- */
--void gaim_value_destroy(GaimValue *value);
-+void gaim2_value_destroy(Gaim2Value *value);
-
- /**
-- * Duplicated a GaimValue.
-+ * Duplicated a Gaim2Value.
- *
- * @param value The value to duplicate.
- *
- * @return The duplicate value.
- */
--GaimValue *gaim_value_dup(const GaimValue *value);
-+Gaim2Value *gaim2_value_dup(const Gaim2Value *value);
-
- /**
- * Returns a value's type.
-@@ -183,7 +183,7 @@ GaimValue *gaim_value_dup(const GaimValu
- *
- * @return The value's type.
- */
--GaimType gaim_value_get_type(const GaimValue *value);
-+Gaim2Type gaim2_value_get_type(const Gaim2Value *value);
-
- /**
- * Returns a value's subtype.
-@@ -195,7 +195,7 @@ GaimType gaim_value_get_type(const GaimV
- *
- * @return The value's subtype, or 0 if @a type is not GAIM_TYPE_SUBTYPE.
- */
--unsigned int gaim_value_get_subtype(const GaimValue *value);
-+unsigned int gaim2_value_get_subtype(const Gaim2Value *value);
-
- /**
- * Returns a value's specific type.
-@@ -206,7 +206,7 @@ unsigned int gaim_value_get_subtype(cons
- *
- * @return The value's specific type, or @a NULL if not GAIM_TYPE_BOXED.
- */
--const char *gaim_value_get_specific_type(const GaimValue *value);
-+const char *gaim2_value_get_specific_type(const Gaim2Value *value);
-
- /**
- * Returns whether or not the value is an outgoing value.
-@@ -215,7 +215,7 @@ const char *gaim_value_get_specific_type
- *
- * @return TRUE if the value is outgoing, or FALSE otherwise.
- */
--gboolean gaim_value_is_outgoing(const GaimValue *value);
-+gboolean gaim2_value_is_outgoing(const Gaim2Value *value);
-
- /**
- * Sets the value's character data.
-@@ -223,7 +223,7 @@ gboolean gaim_value_is_outgoing(const Ga
- * @param value The value.
- * @param data The character data.
- */
--void gaim_value_set_char(GaimValue *value, char data);
-+void gaim2_value_set_char(Gaim2Value *value, char data);
-
- /**
- * Sets the value's unsigned character data.
-@@ -231,7 +231,7 @@ void gaim_value_set_char(GaimValue *valu
- * @param value The value.
- * @param data The unsigned character data.
- */
--void gaim_value_set_uchar(GaimValue *value, unsigned char data);
-+void gaim2_value_set_uchar(Gaim2Value *value, unsigned char data);
-
- /**
- * Sets the value's boolean data.
-@@ -239,7 +239,7 @@ void gaim_value_set_uchar(GaimValue *val
- * @param value The value.
- * @param data The boolean data.
- */
--void gaim_value_set_boolean(GaimValue *value, gboolean data);
-+void gaim2_value_set_boolean(Gaim2Value *value, gboolean data);
-
- /**
- * Sets the value's short integer data.
-@@ -247,7 +247,7 @@ void gaim_value_set_boolean(GaimValue *v
- * @param value The value.
- * @param data The short integer data.
- */
--void gaim_value_set_short(GaimValue *value, short data);
-+void gaim2_value_set_short(Gaim2Value *value, short data);
-
- /**
- * Sets the value's unsigned short integer data.
-@@ -255,7 +255,7 @@ void gaim_value_set_short(GaimValue *val
- * @param value The value.
- * @param data The unsigned short integer data.
- */
--void gaim_value_set_ushort(GaimValue *value, unsigned short data);
-+void gaim2_value_set_ushort(Gaim2Value *value, unsigned short data);
-
- /**
- * Sets the value's integer data.
-@@ -263,7 +263,7 @@ void gaim_value_set_ushort(GaimValue *va
- * @param value The value.
- * @param data The integer data.
- */
--void gaim_value_set_int(GaimValue *value, int data);
-+void gaim2_value_set_int(Gaim2Value *value, int data);
-
- /**
- * Sets the value's unsigned integer data.
-@@ -271,7 +271,7 @@ void gaim_value_set_int(GaimValue *value
- * @param value The value.
- * @param data The unsigned integer data.
- */
--void gaim_value_set_uint(GaimValue *value, unsigned int data);
-+void gaim2_value_set_uint(Gaim2Value *value, unsigned int data);
-
- /**
- * Sets the value's long integer data.
-@@ -279,7 +279,7 @@ void gaim_value_set_uint(GaimValue *valu
- * @param value The value.
- * @param data The long integer data.
- */
--void gaim_value_set_long(GaimValue *value, long data);
-+void gaim2_value_set_long(Gaim2Value *value, long data);
-
- /**
- * Sets the value's unsigned long integer data.
-@@ -287,7 +287,7 @@ void gaim_value_set_long(GaimValue *valu
- * @param value The value.
- * @param data The unsigned long integer data.
- */
--void gaim_value_set_ulong(GaimValue *value, unsigned long data);
-+void gaim2_value_set_ulong(Gaim2Value *value, unsigned long data);
-
- /**
- * Sets the value's 64-bit integer data.
-@@ -295,7 +295,7 @@ void gaim_value_set_ulong(GaimValue *val
- * @param value The value.
- * @param data The 64-bit integer data.
- */
--void gaim_value_set_int64(GaimValue *value, gint64 data);
-+void gaim2_value_set_int64(Gaim2Value *value, gint64 data);
-
- /**
- * Sets the value's unsigned 64-bit integer data.
-@@ -303,7 +303,7 @@ void gaim_value_set_int64(GaimValue *val
- * @param value The value.
- * @param data The unsigned 64-bit integer data.
- */
--void gaim_value_set_uint64(GaimValue *value, guint64 data);
-+void gaim2_value_set_uint64(Gaim2Value *value, guint64 data);
-
- /**
- * Sets the value's string data.
-@@ -311,7 +311,7 @@ void gaim_value_set_uint64(GaimValue *va
- * @param value The value.
- * @param data The string data.
- */
--void gaim_value_set_string(GaimValue *value, const char *data);
-+void gaim2_value_set_string(Gaim2Value *value, const char *data);
-
- /**
- * Sets the value's object data.
-@@ -319,7 +319,7 @@ void gaim_value_set_string(GaimValue *va
- * @param value The value.
- * @param data The object data.
- */
--void gaim_value_set_object(GaimValue *value, void *data);
-+void gaim2_value_set_object(Gaim2Value *value, void *data);
-
- /**
- * Sets the value's pointer data.
-@@ -327,7 +327,7 @@ void gaim_value_set_object(GaimValue *va
- * @param value The value.
- * @param data The pointer data.
- */
--void gaim_value_set_pointer(GaimValue *value, void *data);
-+void gaim2_value_set_pointer(Gaim2Value *value, void *data);
-
- /**
- * Sets the value's enum data.
-@@ -335,7 +335,7 @@ void gaim_value_set_pointer(GaimValue *v
- * @param value The value.
- * @param data The enum data.
- */
--void gaim_value_set_enum(GaimValue *value, int data);
-+void gaim2_value_set_enum(Gaim2Value *value, int data);
-
- /**
- * Sets the value's boxed data.
-@@ -343,7 +343,7 @@ void gaim_value_set_enum(GaimValue *valu
- * @param value The value.
- * @param data The boxed data.
- */
--void gaim_value_set_boxed(GaimValue *value, void *data);
-+void gaim2_value_set_boxed(Gaim2Value *value, void *data);
-
- /**
- * Returns the value's character data.
-@@ -352,7 +352,7 @@ void gaim_value_set_boxed(GaimValue *val
- *
- * @return The character data.
- */
--char gaim_value_get_char(const GaimValue *value);
-+char gaim2_value_get_char(const Gaim2Value *value);
-
- /**
- * Returns the value's unsigned character data.
-@@ -361,7 +361,7 @@ char gaim_value_get_char(const GaimValue
- *
- * @return The unsigned character data.
- */
--unsigned char gaim_value_get_uchar(const GaimValue *value);
-+unsigned char gaim2_value_get_uchar(const Gaim2Value *value);
-
- /**
- * Returns the value's boolean data.
-@@ -370,7 +370,7 @@ unsigned char gaim_value_get_uchar(const
- *
- * @return The boolean data.
- */
--gboolean gaim_value_get_boolean(const GaimValue *value);
-+gboolean gaim2_value_get_boolean(const Gaim2Value *value);
-
- /**
- * Returns the value's short integer data.
-@@ -379,7 +379,7 @@ gboolean gaim_value_get_boolean(const Ga
- *
- * @return The short integer data.
- */
--short gaim_value_get_short(const GaimValue *value);
-+short gaim2_value_get_short(const Gaim2Value *value);
-
- /**
- * Returns the value's unsigned short integer data.
-@@ -388,7 +388,7 @@ short gaim_value_get_short(const GaimVal
- *
- * @return The unsigned short integer data.
- */
--unsigned short gaim_value_get_ushort(const GaimValue *value);
-+unsigned short gaim2_value_get_ushort(const Gaim2Value *value);
-
- /**
- * Returns the value's integer data.
-@@ -397,7 +397,7 @@ unsigned short gaim_value_get_ushort(con
- *
- * @return The integer data.
- */
--int gaim_value_get_int(const GaimValue *value);
-+int gaim2_value_get_int(const Gaim2Value *value);
-
- /**
- * Returns the value's unsigned integer data.
-@@ -406,7 +406,7 @@ int gaim_value_get_int(const GaimValue *
- *
- * @return The unsigned integer data.
- */
--unsigned int gaim_value_get_uint(const GaimValue *value);
-+unsigned int gaim2_value_get_uint(const Gaim2Value *value);
-
- /**
- * Returns the value's long integer data.
-@@ -415,7 +415,7 @@ unsigned int gaim_value_get_uint(const G
- *
- * @return The long integer data.
- */
--long gaim_value_get_long(const GaimValue *value);
-+long gaim2_value_get_long(const Gaim2Value *value);
-
- /**
- * Returns the value's unsigned long integer data.
-@@ -424,7 +424,7 @@ long gaim_value_get_long(const GaimValue
- *
- * @return The unsigned long integer data.
- */
--unsigned long gaim_value_get_ulong(const GaimValue *value);
-+unsigned long gaim2_value_get_ulong(const Gaim2Value *value);
-
- /**
- * Returns the value's 64-bit integer data.
-@@ -433,7 +433,7 @@ unsigned long gaim_value_get_ulong(const
- *
- * @return The 64-bit integer data.
- */
--gint64 gaim_value_get_int64(const GaimValue *value);
-+gint64 gaim2_value_get_int64(const Gaim2Value *value);
-
- /**
- * Returns the value's unsigned 64-bit integer data.
-@@ -442,7 +442,7 @@ gint64 gaim_value_get_int64(const GaimVa
- *
- * @return The unsigned 64-bit integer data.
- */
--guint64 gaim_value_get_uint64(const GaimValue *value);
-+guint64 gaim2_value_get_uint64(const Gaim2Value *value);
-
- /**
- * Returns the value's string data.
-@@ -451,7 +451,7 @@ guint64 gaim_value_get_uint64(const Gaim
- *
- * @return The string data.
- */
--const char *gaim_value_get_string(const GaimValue *value);
-+const char *gaim2_value_get_string(const Gaim2Value *value);
-
- /**
- * Returns the value's object data.
-@@ -460,7 +460,7 @@ const char *gaim_value_get_string(const
- *
- * @return The object data.
- */
--void *gaim_value_get_object(const GaimValue *value);
-+void *gaim2_value_get_object(const Gaim2Value *value);
-
- /**
- * Returns the value's pointer data.
-@@ -469,7 +469,7 @@ void *gaim_value_get_object(const GaimVa
- *
- * @return The pointer data.
- */
--void *gaim_value_get_pointer(const GaimValue *value);
-+void *gaim2_value_get_pointer(const Gaim2Value *value);
-
- /**
- * Returns the value's enum data.
-@@ -478,7 +478,7 @@ void *gaim_value_get_pointer(const GaimV
- *
- * @return The enum data.
- */
--int gaim_value_get_enum(const GaimValue *value);
-+int gaim2_value_get_enum(const Gaim2Value *value);
-
- /**
- * Returns the value's boxed data.
-@@ -487,7 +487,7 @@ int gaim_value_get_enum(const GaimValue
- *
- * @return The boxed data.
- */
--void *gaim_value_get_boxed(const GaimValue *value);
-+void *gaim2_value_get_boxed(const Gaim2Value *value);
-
- #ifdef __cplusplus
- }
-diff -prNu ./src/version.h ./src/version.h
---- ./src/version.h 2005-03-09 01:01:38.000000000 +0100
-+++ ./src/version.h 2006-01-05 15:11:21.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
-- * @file version.h Gaim Versioning
-+ * @file version.h Gaim2 Versioning
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/whiteboard.c ./src/whiteboard.c
---- ./src/whiteboard.c 2005-11-09 05:42:42.000000000 +0100
-+++ ./src/whiteboard.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -29,8 +29,8 @@
- /******************************************************************************
- * Globals
- *****************************************************************************/
--static GaimWhiteboardUiOps *whiteboard_ui_ops = NULL;
--/* static GaimWhiteboardPrplOps *whiteboard_prpl_ops = NULL; */
-+static Gaim2WhiteboardUiOps *whiteboard_ui_ops = NULL;
-+/* static Gaim2WhiteboardPrplOps *whiteboard_prpl_ops = NULL; */
-
- static GList *wbList = NULL;
-
-@@ -39,27 +39,27 @@ static GList *wbList = NULL;
- /******************************************************************************
- * API
- *****************************************************************************/
--void gaim_whiteboard_set_ui_ops(GaimWhiteboardUiOps *ops)
-+void gaim2_whiteboard_set_ui_ops(Gaim2WhiteboardUiOps *ops)
- {
- whiteboard_ui_ops = ops;
- }
-
--void gaim_whiteboard_set_prpl_ops(GaimWhiteboard *wb, GaimWhiteboardPrplOps *ops)
-+void gaim2_whiteboard_set_prpl_ops(Gaim2Whiteboard *wb, Gaim2WhiteboardPrplOps *ops)
- {
- wb->prpl_ops = ops;
- }
-
--GaimWhiteboard *gaim_whiteboard_create(GaimAccount *account, const char *who, int state)
-+Gaim2Whiteboard *gaim2_whiteboard_create(Gaim2Account *account, const char *who, int state)
- {
-- GaimPluginProtocolInfo *prpl_info;
-- GaimWhiteboard *wb = g_new0(GaimWhiteboard, 1);
-+ Gaim2PluginProtocolInfo *prpl_info;
-+ Gaim2Whiteboard *wb = g_new0(Gaim2Whiteboard, 1);
-
- wb->account = account;
- wb->state = state;
- wb->who = g_strdup(who);
-
- prpl_info = GAIM_PLUGIN_PROTOCOL_INFO(account->gc->prpl);
-- gaim_whiteboard_set_prpl_ops(wb, prpl_info->whiteboard_prpl_ops);
-+ gaim2_whiteboard_set_prpl_ops(wb, prpl_info->whiteboard_prpl_ops);
-
- /* Start up protocol specifics */
- if(wb->prpl_ops && wb->prpl_ops->start)
-@@ -70,7 +70,7 @@ GaimWhiteboard *gaim_whiteboard_create(G
- return wb;
- }
-
--void gaim_whiteboard_destroy(GaimWhiteboard *wb)
-+void gaim2_whiteboard_destroy(Gaim2Whiteboard *wb)
- {
- if(wb->ui_data)
- {
-@@ -94,7 +94,7 @@ void gaim_whiteboard_destroy(GaimWhitebo
- }
- }
-
--void gaim_whiteboard_start(GaimWhiteboard *wb)
-+void gaim2_whiteboard_start(Gaim2Whiteboard *wb)
- {
- /* Create frontend for whiteboard */
- if(whiteboard_ui_ops && whiteboard_ui_ops->create)
-@@ -105,9 +105,9 @@ void gaim_whiteboard_start(GaimWhiteboar
- * usernames 'me' and 'who'. Returns a pointer to a matching whiteboard
- * session; if none match, it returns NULL.
- */
--GaimWhiteboard *gaim_whiteboard_get_session(GaimAccount *account, const char *who)
-+Gaim2Whiteboard *gaim2_whiteboard_get_session(Gaim2Account *account, const char *who)
- {
-- GaimWhiteboard *wb = NULL;
-+ Gaim2Whiteboard *wb = NULL;
-
- GList *l = wbList;
-
-@@ -126,15 +126,15 @@ GaimWhiteboard *gaim_whiteboard_get_sess
- return NULL;
- }
-
--void gaim_whiteboard_draw_list_destroy(GList *draw_list)
-+void gaim2_whiteboard_draw_list_destroy(GList *draw_list)
- {
- if (draw_list)
- g_list_free(draw_list);
- }
-
--gboolean gaim_whiteboard_get_dimensions(GaimWhiteboard *wb, int *width, int *height)
-+gboolean gaim2_whiteboard_get_dimensions(Gaim2Whiteboard *wb, int *width, int *height)
- {
-- GaimWhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-+ Gaim2WhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-
- if (prpl_ops && prpl_ops->get_dimensions)
- {
-@@ -145,57 +145,57 @@ gboolean gaim_whiteboard_get_dimensions(
- return FALSE;
- }
-
--void gaim_whiteboard_set_dimensions(GaimWhiteboard *wb, int width, int height)
-+void gaim2_whiteboard_set_dimensions(Gaim2Whiteboard *wb, int width, int height)
- {
- if(whiteboard_ui_ops && whiteboard_ui_ops->set_dimensions)
- whiteboard_ui_ops->set_dimensions(wb, width, height);
- }
-
--void gaim_whiteboard_send_draw_list(GaimWhiteboard *wb, GList *list)
-+void gaim2_whiteboard_send_draw_list(Gaim2Whiteboard *wb, GList *list)
- {
-- GaimWhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-+ Gaim2WhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-
- if (prpl_ops && prpl_ops->send_draw_list)
- prpl_ops->send_draw_list(wb, list);
- }
-
--void gaim_whiteboard_draw_point(GaimWhiteboard *wb, int x, int y, int color, int size)
-+void gaim2_whiteboard_draw_point(Gaim2Whiteboard *wb, int x, int y, int color, int size)
- {
- if(whiteboard_ui_ops && whiteboard_ui_ops->draw_point)
- whiteboard_ui_ops->draw_point(wb, x, y, color, size);
- }
-
--void gaim_whiteboard_draw_line(GaimWhiteboard *wb, int x1, int y1, int x2, int y2, int color, int size)
-+void gaim2_whiteboard_draw_line(Gaim2Whiteboard *wb, int x1, int y1, int x2, int y2, int color, int size)
- {
- if(whiteboard_ui_ops && whiteboard_ui_ops->draw_line)
- whiteboard_ui_ops->draw_line(wb, x1, y1, x2, y2, color, size);
- }
-
--void gaim_whiteboard_clear(GaimWhiteboard *wb)
-+void gaim2_whiteboard_clear(Gaim2Whiteboard *wb)
- {
- if(whiteboard_ui_ops && whiteboard_ui_ops->clear)
- whiteboard_ui_ops->clear(wb);
- }
-
--void gaim_whiteboard_send_clear(GaimWhiteboard *wb)
-+void gaim2_whiteboard_send_clear(Gaim2Whiteboard *wb)
- {
-- GaimWhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-+ Gaim2WhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-
- if (prpl_ops && prpl_ops->clear)
- prpl_ops->clear(wb);
- }
-
--void gaim_whiteboard_send_brush(GaimWhiteboard *wb, int size, int color)
-+void gaim2_whiteboard_send_brush(Gaim2Whiteboard *wb, int size, int color)
- {
-- GaimWhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-+ Gaim2WhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-
- if (prpl_ops && prpl_ops->set_brush)
- prpl_ops->set_brush(wb, size, color);
- }
-
--gboolean gaim_whiteboard_get_brush(GaimWhiteboard *wb, int *size, int *color)
-+gboolean gaim2_whiteboard_get_brush(Gaim2Whiteboard *wb, int *size, int *color)
- {
-- GaimWhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-+ Gaim2WhiteboardPrplOps *prpl_ops = wb->prpl_ops;
-
- if (prpl_ops && prpl_ops->get_brush)
- {
-@@ -205,7 +205,7 @@ gboolean gaim_whiteboard_get_brush(GaimW
- return FALSE;
- }
-
--void gaim_whiteboard_set_brush(GaimWhiteboard *wb, int size, int color)
-+void gaim2_whiteboard_set_brush(Gaim2Whiteboard *wb, int size, int color)
- {
- if (whiteboard_ui_ops && whiteboard_ui_ops->set_brush)
- whiteboard_ui_ops->set_brush(wb, size, color);
-diff -prNu ./src/whiteboard.h ./src/whiteboard.h
---- ./src/whiteboard.h 2005-12-08 21:56:44.000000000 +0100
-+++ ./src/whiteboard.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
-- * @file whiteboard.h The GaimWhiteboard core object
-+ * @file whiteboard.h The Gaim2Whiteboard core object
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -28,57 +28,57 @@
- /**
- * Whiteboard PRPL Operations
- */
--typedef struct _GaimWhiteboardPrplOps GaimWhiteboardPrplOps;
-+typedef struct _Gaim2WhiteboardPrplOps Gaim2WhiteboardPrplOps;
-
- #include "account.h"
-
- /**
-- * A GaimWhiteboard
-+ * A Gaim2Whiteboard
- */
--typedef struct _GaimWhiteboard
-+typedef struct _Gaim2Whiteboard
- {
- int state; /**< State of whiteboard session */
-
-- GaimAccount *account; /**< Account associated with this session */
-+ Gaim2Account *account; /**< Account associated with this session */
- char *who; /**< Name of the remote user */
-
- void *ui_data; /**< Graphical user-interface data */
- void *proto_data; /**< Protocol specific data */
-- GaimWhiteboardPrplOps *prpl_ops; /**< Protocol-plugin operations */
-+ Gaim2WhiteboardPrplOps *prpl_ops; /**< Protocol-plugin operations */
-
- GList *draw_list; /**< List of drawing elements/deltas to send */
--} GaimWhiteboard;
-+} Gaim2Whiteboard;
-
- /**
-- * The GaimWhiteboard UI Operations
-+ * The Gaim2Whiteboard UI Operations
- */
--typedef struct _GaimWhiteboardUiOps
-+typedef struct _Gaim2WhiteboardUiOps
- {
-- void (*create)(GaimWhiteboard *wb); /**< create function */
-- void (*destroy)(GaimWhiteboard *wb); /**< destory function */
-- void (*set_dimensions)(GaimWhiteboard *wb, int width, int height); /**< set_dimensions function */
-- void (*set_brush) (GaimWhiteboard *wb, int size, int color); /**< set the size and color of the brush */
-- void (*draw_point)(GaimWhiteboard *wb, int x, int y,
-+ void (*create)(Gaim2Whiteboard *wb); /**< create function */
-+ void (*destroy)(Gaim2Whiteboard *wb); /**< destory function */
-+ void (*set_dimensions)(Gaim2Whiteboard *wb, int width, int height); /**< set_dimensions function */
-+ void (*set_brush) (Gaim2Whiteboard *wb, int size, int color); /**< set the size and color of the brush */
-+ void (*draw_point)(Gaim2Whiteboard *wb, int x, int y,
- int color, int size); /**< draw_point function */
-- void (*draw_line)(GaimWhiteboard *wb, int x1, int y1,
-+ void (*draw_line)(Gaim2Whiteboard *wb, int x1, int y1,
- int x2, int y2,
- int color, int size); /**< draw_line function */
-- void (*clear)(GaimWhiteboard *wb); /**< clear function */
--} GaimWhiteboardUiOps;
-+ void (*clear)(Gaim2Whiteboard *wb); /**< clear function */
-+} Gaim2WhiteboardUiOps;
-
- /**
-- * GaimWhiteboard PRPL Operations
-+ * Gaim2Whiteboard PRPL Operations
- */
--struct _GaimWhiteboardPrplOps
-+struct _Gaim2WhiteboardPrplOps
- {
-- void (*start)(GaimWhiteboard *wb); /**< start function */
-- void (*end)(GaimWhiteboard *wb); /**< end function */
-- void (*get_dimensions)(GaimWhiteboard *wb, int *width, int *height); /**< get_dimensions function */
-- void (*set_dimensions)(GaimWhiteboard *wb, int width, int height); /**< set_dimensions function */
-- void (*get_brush) (GaimWhiteboard *wb, int *size, int *color); /**< get the brush size and color */
-- void (*set_brush) (GaimWhiteboard *wb, int size, int color); /**< set the brush size and color */
-- void (*send_draw_list)(GaimWhiteboard *wb, GList *draw_list); /**< send_draw_list function */
-- void (*clear)(GaimWhiteboard *wb); /**< clear function */
-+ void (*start)(Gaim2Whiteboard *wb); /**< start function */
-+ void (*end)(Gaim2Whiteboard *wb); /**< end function */
-+ void (*get_dimensions)(Gaim2Whiteboard *wb, int *width, int *height); /**< get_dimensions function */
-+ void (*set_dimensions)(Gaim2Whiteboard *wb, int width, int height); /**< set_dimensions function */
-+ void (*get_brush) (Gaim2Whiteboard *wb, int *size, int *color); /**< get the brush size and color */
-+ void (*set_brush) (Gaim2Whiteboard *wb, int size, int color); /**< set the brush size and color */
-+ void (*send_draw_list)(Gaim2Whiteboard *wb, GList *draw_list); /**< send_draw_list function */
-+ void (*clear)(Gaim2Whiteboard *wb); /**< clear function */
- };
-
- #ifdef __cplusplus
-@@ -86,7 +86,7 @@ extern "C" {
- #endif /* __cplusplus */
-
- /******************************************************************************/
--/** @name GaimWhiteboard API */
-+/** @name Gaim2Whiteboard API */
- /******************************************************************************/
- /*@{*/
-
-@@ -95,7 +95,7 @@ extern "C" {
- *
- * @param ops The UI operations to set
- */
--void gaim_whiteboard_set_ui_ops(GaimWhiteboardUiOps *ops);
-+void gaim2_whiteboard_set_ui_ops(Gaim2WhiteboardUiOps *ops);
-
- /**
- * Sets the prpl operations for a whiteboard
-@@ -103,7 +103,7 @@ void gaim_whiteboard_set_ui_ops(GaimWhit
- * @param wb The whiteboard for which to set the prpl operations
- * @param ops The prpl operations to set
- */
--void gaim_whiteboard_set_prpl_ops(GaimWhiteboard *wb, GaimWhiteboardPrplOps *ops);
-+void gaim2_whiteboard_set_prpl_ops(Gaim2Whiteboard *wb, Gaim2WhiteboardPrplOps *ops);
-
- /**
- * Creates a whiteboard
-@@ -114,21 +114,21 @@ void gaim_whiteboard_set_prpl_ops(GaimWh
- *
- * @return The new whiteboard
- */
--GaimWhiteboard *gaim_whiteboard_create(GaimAccount *account, const char *who, int state);
-+Gaim2Whiteboard *gaim2_whiteboard_create(Gaim2Account *account, const char *who, int state);
-
- /**
- * Destroys a whiteboard
- *
- * @param wb The whiteboard.
- */
--void gaim_whiteboard_destroy(GaimWhiteboard *wb);
-+void gaim2_whiteboard_destroy(Gaim2Whiteboard *wb);
-
- /**
- * Starts a whiteboard
- *
- * @param wb The whiteboard.
- */
--void gaim_whiteboard_start(GaimWhiteboard *wb);
-+void gaim2_whiteboard_start(Gaim2Whiteboard *wb);
-
- /**
- * Finds a whiteboard from an account and user.
-@@ -138,14 +138,14 @@ void gaim_whiteboard_start(GaimWhiteboar
- *
- * @return The whiteboard if found, otherwise @c NULL.
- */
--GaimWhiteboard *gaim_whiteboard_get_session(GaimAccount *account, const char *who);
-+Gaim2Whiteboard *gaim2_whiteboard_get_session(Gaim2Account *account, const char *who);
-
- /**
- * Destorys a drawing list for a whiteboard
- *
- * @param draw_list The drawing list.
- */
--void gaim_whiteboard_draw_list_destroy(GList *draw_list);
-+void gaim2_whiteboard_draw_list_destroy(GList *draw_list);
-
- /**
- * Gets the dimension of a whiteboard.
-@@ -156,7 +156,7 @@ void gaim_whiteboard_draw_list_destroy(G
- *
- * @return TRUE if the values of width and height were set.
- */
--gboolean gaim_whiteboard_get_dimensions(GaimWhiteboard *wb, int *width, int *height);
-+gboolean gaim2_whiteboard_get_dimensions(Gaim2Whiteboard *wb, int *width, int *height);
-
- /**
- * Sets the dimensions for a whiteboard.
-@@ -165,7 +165,7 @@ gboolean gaim_whiteboard_get_dimensions(
- * @param width The width.
- * @param height The height.
- */
--void gaim_whiteboard_set_dimensions(GaimWhiteboard *wb, int width, int height);
-+void gaim2_whiteboard_set_dimensions(Gaim2Whiteboard *wb, int width, int height);
-
- /**
- * Draws a point on a whiteboard.
-@@ -176,7 +176,7 @@ void gaim_whiteboard_set_dimensions(Gaim
- * @param color The color to use.
- * @param size The brush size.
- */
--void gaim_whiteboard_draw_point(GaimWhiteboard *wb, int x, int y, int color, int size);
-+void gaim2_whiteboard_draw_point(Gaim2Whiteboard *wb, int x, int y, int color, int size);
-
- /**
- * Send a list of points to draw to the buddy.
-@@ -184,7 +184,7 @@ void gaim_whiteboard_draw_point(GaimWhit
- * @param wb The whiteboard
- * @param list A GList of points
- */
--void gaim_whiteboard_send_draw_list(GaimWhiteboard *wb, GList *list);
-+void gaim2_whiteboard_send_draw_list(Gaim2Whiteboard *wb, GList *list);
-
- /**
- * Draws a line on a whiteboard
-@@ -197,21 +197,21 @@ void gaim_whiteboard_send_draw_list(Gaim
- * @param color The color to use.
- * @param size The brush size.
- */
--void gaim_whiteboard_draw_line(GaimWhiteboard *wb, int x1, int y1, int x2, int y2, int color, int size);
-+void gaim2_whiteboard_draw_line(Gaim2Whiteboard *wb, int x1, int y1, int x2, int y2, int color, int size);
-
- /**
- * Clears a whiteboard
- *
- * @param wb The whiteboard.
- */
--void gaim_whiteboard_clear(GaimWhiteboard *wb);
-+void gaim2_whiteboard_clear(Gaim2Whiteboard *wb);
-
- /**
- * Sends a request to the buddy to clear the whiteboard.
- *
- * @param wb The whiteboard
- */
--void gaim_whiteboard_send_clear(GaimWhiteboard *wb);
-+void gaim2_whiteboard_send_clear(Gaim2Whiteboard *wb);
-
- /**
- * Sends a request to change the size and color of the brush.
-@@ -220,7 +220,7 @@ void gaim_whiteboard_send_clear(GaimWhit
- * @param size The size of the brush
- * @param color The color of the brush
- */
--void gaim_whiteboard_send_brush(GaimWhiteboard *wb, int size, int color);
-+void gaim2_whiteboard_send_brush(Gaim2Whiteboard *wb, int size, int color);
-
- /**
- * Gets the size and color of the brush.
-@@ -231,7 +231,7 @@ void gaim_whiteboard_send_brush(GaimWhit
- *
- * @return TRUE if the size and color were set.
- */
--gboolean gaim_whiteboard_get_brush(GaimWhiteboard *wb, int *size, int *color);
-+gboolean gaim2_whiteboard_get_brush(Gaim2Whiteboard *wb, int *size, int *color);
-
- /**
- * Sets the size and color of the brush.
-@@ -240,7 +240,7 @@ gboolean gaim_whiteboard_get_brush(GaimW
- * @param size The size of the brush
- * @param color The color of the brush
- */
--void gaim_whiteboard_set_brush(GaimWhiteboard *wb, int size, int color);
-+void gaim2_whiteboard_set_brush(Gaim2Whiteboard *wb, int size, int color);
-
- /*@}*/
-
-diff -prNu ./src/win32/IdleTracker/idletrack.c ./src/win32/IdleTracker/idletrack.c
---- ./src/win32/IdleTracker/idletrack.c 2005-10-26 02:33:21.000000000 +0200
-+++ ./src/win32/IdleTracker/idletrack.c 2006-01-05 15:11:04.000000000 +0100
-@@ -13,7 +13,7 @@
- * using hooks doesn't put the willys up programs that keep an eye out for
- * loggers.
- *
-- * Windows 9x doesn't have GetLastInputInfo - when Gaim runs on these machines
-+ * Windows 9x doesn't have GetLastInputInfo - when Gaim2 runs on these machines
- * the code silently falls back onto the old hooking scheme.
- */
- #define _WIN32_WINNT 0x0500
-@@ -99,7 +99,7 @@ LRESULT CALLBACK MouseProc(int code, WPA
- }
-
-
--EXPORT DWORD wgaim_get_lastactive() {
-+EXPORT DWORD wgaim2_get_lastactive() {
- DWORD result = 0;
-
- /* If we have GetLastInputInfo then use it, otherwise use the hooks*/
-@@ -122,7 +122,7 @@ EXPORT DWORD wgaim_get_lastactive() {
- }
-
-
--EXPORT BOOL wgaim_set_idlehooks() {
-+EXPORT BOOL wgaim2_set_idlehooks() {
- /* Is GetLastInputInfo available?*/
- g_user32 = LoadLibrary("user32.dll");
- if (g_user32) {
-@@ -159,7 +159,7 @@ EXPORT BOOL wgaim_set_idlehooks() {
- }
-
-
--EXPORT void wgaim_remove_idlehooks() {
-+EXPORT void wgaim2_remove_idlehooks() {
- if (g_user32 != NULL)
- FreeLibrary(g_user32);
- if (keyHook)
-diff -prNu ./src/win32/IdleTracker/idletrack.h ./src/win32/IdleTracker/idletrack.h
---- ./src/win32/IdleTracker/idletrack.h 2005-12-16 10:02:17.000000000 +0100
-+++ ./src/win32/IdleTracker/idletrack.h 2006-01-05 15:11:20.000000000 +0100
-@@ -3,6 +3,6 @@
- */
- #include <windows.h>
-
--DWORD wgaim_get_lastactive(void);
--BOOL wgaim_set_idlehooks(void);
--void wgaim_remove_idlehooks(void);
-+DWORD wgaim2_get_lastactive(void);
-+BOOL wgaim2_set_idlehooks(void);
-+void wgaim2_remove_idlehooks(void);
-diff -prNu ./src/win32/libc_interface.c ./src/win32/libc_interface.c
---- ./src/win32/libc_interface.c 2005-12-15 17:13:56.000000000 +0100
-+++ ./src/win32/libc_interface.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: libc_interface.c
- * Date: October 14, 2002
-@@ -56,7 +56,7 @@ static char errbuf[1024];
- */
-
- /* helpers */
--static int wgaim_is_socket( int fd ) {
-+static int wgaim2_is_socket( int fd ) {
- int optval;
- unsigned int optlen = sizeof(int);
-
-@@ -65,7 +65,7 @@ static int wgaim_is_socket( int fd ) {
- if( error == WSAENOTSOCK )
- return FALSE;
- else {
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "wgaim_is_socket: getsockopt returned error: %d\n", error);
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "wgaim2_is_socket: getsockopt returned error: %d\n", error);
- return FALSE;
- }
- }
-@@ -73,7 +73,7 @@ static int wgaim_is_socket( int fd ) {
- }
-
- /* socket.h */
--int wgaim_socket (int namespace, int style, int protocol) {
-+int wgaim2_socket (int namespace, int style, int protocol) {
- int ret;
-
- ret = socket( namespace, style, protocol );
-@@ -85,7 +85,7 @@ int wgaim_socket (int namespace, int sty
- return ret;
- }
-
--int wgaim_connect(int socket, struct sockaddr *addr, u_long length) {
-+int wgaim2_connect(int socket, struct sockaddr *addr, u_long length) {
- int ret;
-
- ret = connect( socket, addr, length );
-@@ -99,7 +99,7 @@ int wgaim_connect(int socket, struct soc
- return 0;
- }
-
--int wgaim_getsockopt(int socket, int level, int optname, void *optval, socklen_t *optlenptr) {
-+int wgaim2_getsockopt(int socket, int level, int optname, void *optval, socklen_t *optlenptr) {
- if(getsockopt(socket, level, optname, optval, optlenptr) == SOCKET_ERROR ) {
- errno = WSAGetLastError();
- return -1;
-@@ -107,7 +107,7 @@ int wgaim_getsockopt(int socket, int lev
- return 0;
- }
-
--int wgaim_setsockopt(int socket, int level, int optname, const void *optval, socklen_t optlen) {
-+int wgaim2_setsockopt(int socket, int level, int optname, const void *optval, socklen_t optlen) {
- if(setsockopt(socket, level, optname, optval, optlen) == SOCKET_ERROR ) {
- errno = WSAGetLastError();
- return -1;
-@@ -115,7 +115,7 @@ int wgaim_setsockopt(int socket, int lev
- return 0;
- }
-
--int wgaim_getsockname(int socket, struct sockaddr *addr, socklen_t *lenptr) {
-+int wgaim2_getsockname(int socket, struct sockaddr *addr, socklen_t *lenptr) {
- if(getsockname(socket, addr, lenptr) == SOCKET_ERROR) {
- errno = WSAGetLastError();
- return -1;
-@@ -123,7 +123,7 @@ int wgaim_getsockname(int socket, struct
- return 0;
- }
-
--int wgaim_bind(int socket, struct sockaddr *addr, socklen_t length) {
-+int wgaim2_bind(int socket, struct sockaddr *addr, socklen_t length) {
- if(bind(socket, addr, length) == SOCKET_ERROR) {
- errno = WSAGetLastError();
- return -1;
-@@ -131,7 +131,7 @@ int wgaim_bind(int socket, struct sockad
- return 0;
- }
-
--int wgaim_listen(int socket, unsigned int n) {
-+int wgaim2_listen(int socket, unsigned int n) {
- if(listen(socket, n) == SOCKET_ERROR) {
- errno = WSAGetLastError();
- return -1;
-@@ -139,7 +139,7 @@ int wgaim_listen(int socket, unsigned in
- return 0;
- }
-
--int wgaim_sendto(int socket, const void *buf, size_t len, int flags, const struct sockaddr *to, socklen_t tolen) {
-+int wgaim2_sendto(int socket, const void *buf, size_t len, int flags, const struct sockaddr *to, socklen_t tolen) {
- int ret;
- if ((ret = sendto(socket, buf, len, flags, to, tolen)
- ) == SOCKET_ERROR) {
-@@ -151,7 +151,7 @@ int wgaim_sendto(int socket, const void
-
- /* fcntl.h */
- /* This is not a full implementation of fcntl. Update as needed.. */
--int wgaim_fcntl(int socket, int command, int val) {
-+int wgaim2_fcntl(int socket, int command, int val) {
- switch( command ) {
- case F_SETFL:
- {
-@@ -181,13 +181,13 @@ int wgaim_fcntl(int socket, int command,
- return 0;
- }
- default:
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "wgaim_fcntl: Unsupported command\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "wgaim2_fcntl: Unsupported command\n");
- return -1;
- }/*end switch*/
- }
-
- /* sys/ioctl.h */
--int wgaim_ioctl(int fd, int command, void* val) {
-+int wgaim2_ioctl(int fd, int command, void* val) {
- switch( command ) {
- case FIONBIO:
- {
-@@ -240,7 +240,7 @@ int wgaim_ioctl(int fd, int command, voi
- }
-
- /* arpa/inet.h */
--int wgaim_inet_aton(const char *name, struct in_addr *addr) {
-+int wgaim2_inet_aton(const char *name, struct in_addr *addr) {
- if((addr->s_addr = inet_addr(name)) == INADDR_NONE)
- return 0;
- else
-@@ -248,7 +248,7 @@ int wgaim_inet_aton(const char *name, st
- }
-
- /* netdb.h */
--struct hostent* wgaim_gethostbyname(const char *name) {
-+struct hostent* wgaim2_gethostbyname(const char *name) {
- struct hostent *hp;
-
- if((hp = gethostbyname(name)) == NULL) {
-@@ -259,7 +259,7 @@ struct hostent* wgaim_gethostbyname(cons
- }
-
- /* string.h */
--char* wgaim_strerror( int errornum ) {
-+char* wgaim2_strerror( int errornum ) {
- if( errornum > WSABASEERR ) {
- sprintf( errbuf, "Windows socket error #%d", errornum );
- return errbuf;
-@@ -273,10 +273,10 @@ char* wgaim_strerror( int errornum ) {
- /*
- * We need to figure out whether fd is a file or socket handle.
- */
--int wgaim_read(int fd, void *buf, unsigned int size) {
-+int wgaim2_read(int fd, void *buf, unsigned int size) {
- int ret;
-
-- if( wgaim_is_socket(fd) ) {
-+ if( wgaim2_is_socket(fd) ) {
- if( (ret = recv(fd, buf, size, 0)) == SOCKET_ERROR ) {
- errno = WSAGetLastError();
- return -1;
-@@ -299,10 +299,10 @@ int wgaim_read(int fd, void *buf, unsign
- }
- }
-
--int wgaim_write(int fd, const void *buf, unsigned int size) {
-+int wgaim2_write(int fd, const void *buf, unsigned int size) {
- int ret;
-
-- if( wgaim_is_socket(fd) ) {
-+ if( wgaim2_is_socket(fd) ) {
- if( (ret = send(fd, buf, size, 0)) == SOCKET_ERROR ) {
- errno = WSAGetLastError();
- return -1;
-@@ -317,10 +317,10 @@ int wgaim_write(int fd, const void *buf,
- return write(fd, buf, size);
- }
-
--int wgaim_close(int fd) {
-+int wgaim2_close(int fd) {
- int ret;
-
-- if( wgaim_is_socket(fd) ) {
-+ if( wgaim2_is_socket(fd) ) {
- if( (ret = closesocket(fd)) == SOCKET_ERROR ) {
- errno = WSAGetLastError();
- return -1;
-@@ -332,7 +332,7 @@ int wgaim_close(int fd) {
- return close(fd);
- }
-
--int wgaim_gethostname(char *name, size_t size) {
-+int wgaim2_gethostname(char *name, size_t size) {
- if(gethostname(name, size) == SOCKET_ERROR) {
- errno = WSAGetLastError();
- return -1;
-@@ -342,7 +342,7 @@ int wgaim_gethostname(char *name, size_t
-
- /* sys/time.h */
-
--int wgaim_gettimeofday(struct timeval *p, struct timezone *z) {
-+int wgaim2_gettimeofday(struct timeval *p, struct timezone *z) {
- int res = 0;
- struct _timeb timebuffer;
-
-@@ -363,7 +363,7 @@ int wgaim_gettimeofday(struct timeval *p
-
- /* stdio.h */
-
--int wgaim_rename (const char *oldname, const char *newname) {
-+int wgaim2_rename (const char *oldname, const char *newname) {
- struct stat oldstat, newstat;
-
- if(g_stat(oldname, &oldstat) == 0) {
-@@ -380,7 +380,7 @@ int wgaim_rename (const char *oldname, c
- is not a sub dir of oldname, newname should be
- deleted and oldname should be renamed.
- */
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "wgaim_rename does not behave here as it should\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "wgaim2_rename does not behave here as it should\n");
- return g_rename(oldname, newname);
- }
- }
-@@ -412,7 +412,7 @@ int wgaim_rename (const char *oldname, c
-
- /* time.h */
-
--struct tm * wgaim_localtime_r (const time_t *time, struct tm *resultp) {
-+struct tm * wgaim2_localtime_r (const time_t *time, struct tm *resultp) {
- struct tm* tmptm;
-
- if(!time)
-diff -prNu ./src/win32/libc_interface.h ./src/win32/libc_interface.h
---- ./src/win32/libc_interface.h 2005-12-16 10:02:17.000000000 +0100
-+++ ./src/win32/libc_interface.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: libc_interface.h
- *
-@@ -30,108 +30,108 @@
- #include <glib.h>
-
- /* sys/socket.h */
--int wgaim_socket(int namespace, int style, int protocol);
-+int wgaim2_socket(int namespace, int style, int protocol);
- #define socket( namespace, style, protocol ) \
--wgaim_socket( namespace, style, protocol )
-+wgaim2_socket( namespace, style, protocol )
-
--int wgaim_connect(int socket, struct sockaddr *addr, u_long length);
-+int wgaim2_connect(int socket, struct sockaddr *addr, u_long length);
- #define connect( socket, addr, length ) \
--wgaim_connect( socket, addr, length )
-+wgaim2_connect( socket, addr, length )
-
--int wgaim_getsockopt(int socket, int level, int optname, void *optval, socklen_t *optlenptr);
-+int wgaim2_getsockopt(int socket, int level, int optname, void *optval, socklen_t *optlenptr);
- #define getsockopt( args... ) \
--wgaim_getsockopt( args )
-+wgaim2_getsockopt( args )
-
--int wgaim_setsockopt(int socket, int level, int optname, const void *optval, socklen_t optlen);
-+int wgaim2_setsockopt(int socket, int level, int optname, const void *optval, socklen_t optlen);
- #define setsockopt( args... ) \
--wgaim_setsockopt( args )
-+wgaim2_setsockopt( args )
-
--int wgaim_getsockname (int socket, struct sockaddr *addr, socklen_t *lenptr);
-+int wgaim2_getsockname (int socket, struct sockaddr *addr, socklen_t *lenptr);
- #define getsockname( socket, addr, lenptr ) \
--wgaim_getsockname( socket, addr, lenptr )
-+wgaim2_getsockname( socket, addr, lenptr )
-
--int wgaim_bind(int socket, struct sockaddr *addr, socklen_t length);
-+int wgaim2_bind(int socket, struct sockaddr *addr, socklen_t length);
- #define bind( socket, addr, length ) \
--wgaim_bind( socket, addr, length )
-+wgaim2_bind( socket, addr, length )
-
--int wgaim_listen(int socket, unsigned int n);
-+int wgaim2_listen(int socket, unsigned int n);
- #define listen( socket, n ) \
--wgaim_listen( socket, n )
-+wgaim2_listen( socket, n )
-
--int wgaim_sendto(int socket, const void *buf, size_t len, int flags, const struct sockaddr *to, socklen_t tolen);
-+int wgaim2_sendto(int socket, const void *buf, size_t len, int flags, const struct sockaddr *to, socklen_t tolen);
- #define sendto(socket, buf, len, flags, to, tolen) \
--wgaim_sendto(socket, buf, len, flags, to, tolen)
-+wgaim2_sendto(socket, buf, len, flags, to, tolen)
-
- /* sys/ioctl.h */
--int wgaim_ioctl(int fd, int command, void* opt);
-+int wgaim2_ioctl(int fd, int command, void* opt);
- #define ioctl( fd, command, val ) \
--wgaim_ioctl( fd, command, val )
-+wgaim2_ioctl( fd, command, val )
-
- /* fcntl.h */
--int wgaim_fcntl(int socket, int command, int val);
-+int wgaim2_fcntl(int socket, int command, int val);
- #define fcntl( fd, command, val ) \
--wgaim_fcntl( fd, command, val )
-+wgaim2_fcntl( fd, command, val )
-
- #if !GLIB_CHECK_VERSION(2,6,0)
- # define open( args... ) _open( args )
- #endif
-
- /* arpa/inet.h */
--int wgaim_inet_aton(const char *name, struct in_addr *addr);
-+int wgaim2_inet_aton(const char *name, struct in_addr *addr);
- #define inet_aton( name, addr ) \
--wgaim_inet_aton( name, addr )
-+wgaim2_inet_aton( name, addr )
-
- /* netdb.h */
--struct hostent* wgaim_gethostbyname(const char *name);
-+struct hostent* wgaim2_gethostbyname(const char *name);
- #define gethostbyname( name ) \
--wgaim_gethostbyname( name )
-+wgaim2_gethostbyname( name )
-
- /* netinet/in.h */
- #define ntohl( netlong ) \
- (unsigned int)ntohl( netlong )
-
- /* string.h */
--char* wgaim_strerror( int errornum );
-+char* wgaim2_strerror( int errornum );
- #define hstrerror( herror ) \
--wgaim_strerror( errno )
-+wgaim2_strerror( errno )
- #define strerror( errornum ) \
--wgaim_strerror( errornum )
-+wgaim2_strerror( errornum )
-
- #define bzero( dest, size ) memset( dest, 0, size )
-
- /* unistd.h */
--int wgaim_read(int fd, void *buf, unsigned int size);
-+int wgaim2_read(int fd, void *buf, unsigned int size);
- #define read( fd, buf, buflen ) \
--wgaim_read( fd, buf, buflen )
-+wgaim2_read( fd, buf, buflen )
-
--int wgaim_write(int fd, const void *buf, unsigned int size);
-+int wgaim2_write(int fd, const void *buf, unsigned int size);
- #define write( socket, buf, buflen ) \
--wgaim_write( socket, buf, buflen )
-+wgaim2_write( socket, buf, buflen )
-
--int wgaim_close(int fd);
-+int wgaim2_close(int fd);
- #define close( fd ) \
--wgaim_close( fd )
-+wgaim2_close( fd )
-
- #ifndef sleep
- #define sleep(x) Sleep((x)*1000)
- #endif
-
--int wgaim_gethostname(char *name, size_t size);
-+int wgaim2_gethostname(char *name, size_t size);
- #define gethostname( name, size ) \
--wgaim_gethostname( name, size )
-+wgaim2_gethostname( name, size )
-
- /* sys/time.h */
--int wgaim_gettimeofday(struct timeval *p, struct timezone *z);
-+int wgaim2_gettimeofday(struct timeval *p, struct timezone *z);
- #define gettimeofday( timeval, timezone ) \
--wgaim_gettimeofday( timeval, timezone )
-+wgaim2_gettimeofday( timeval, timezone )
-
- /* stdio.h */
- #define snprintf _snprintf
- #define vsnprintf _vsnprintf
-
--int wgaim_rename(const char *oldname, const char *newname);
-+int wgaim2_rename(const char *oldname, const char *newname);
- #define rename( oldname, newname ) \
--wgaim_rename( oldname, newname )
-+wgaim2_rename( oldname, newname )
-
- #if GLIB_CHECK_VERSION(2,6,0)
- #ifdef g_rename
-@@ -139,7 +139,7 @@ wgaim_rename( oldname, newname )
- #endif
- /* This is necessary because we want rename on win32 to be able to overwrite an existing file, it is done in internal.h if GLib < 2.6*/
- #define g_rename(oldname, newname) \
--wgaim_rename(oldname, newname)
-+wgaim2_rename(oldname, newname)
- #endif
-
-
-@@ -151,8 +151,8 @@ wgaim_rename(oldname, newname)
- #define fchmod(a,b)
-
- /* time.h */
--struct tm *wgaim_localtime_r(const time_t *time, struct tm *resultp);
-+struct tm *wgaim2_localtime_r(const time_t *time, struct tm *resultp);
- #define localtime_r( time, resultp ) \
--wgaim_localtime_r( time, resultp )
-+wgaim2_localtime_r( time, resultp )
-
- #endif /* _LIBC_INTERFACE_H_ */
-diff -prNu ./src/win32/libc_internal.h ./src/win32/libc_internal.h
---- ./src/win32/libc_internal.h 2005-08-30 02:32:32.000000000 +0200
-+++ ./src/win32/libc_internal.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: libc_internal.h
- *
-diff -prNu ./src/win32/untar.c ./src/win32/untar.c
---- ./src/win32/untar.c 2005-02-11 06:10:40.000000000 +0100
-+++ ./src/win32/untar.c 2006-01-05 15:11:04.000000000 +0100
-@@ -89,9 +89,9 @@
- #define g_unlink unlink
- #endif
-
--#define untar_error( error, args... ) gaim_debug(GAIM_DEBUG_ERROR, "untar", error, ## args )
--#define untar_warning( warning, args... ) gaim_debug(GAIM_DEBUG_WARNING, "untar", warning, ## args )
--#define untar_verbose( args... ) gaim_debug(GAIM_DEBUG_INFO, "untar", ## args )
-+#define untar_error( error, args... ) gaim2_debug(GAIM_DEBUG_ERROR, "untar", error, ## args )
-+#define untar_warning( warning, args... ) gaim2_debug(GAIM_DEBUG_WARNING, "untar", warning, ## args )
-+#define untar_verbose( args... ) gaim2_debug(GAIM_DEBUG_INFO, "untar", ## args )
-
- #define WSIZE 32768 /* size of decompression buffer */
- #define TSIZE 512 /* size of a "tape" block */
-diff -prNu ./src/win32/wgaimerror.h ./src/win32/wgaimerror.h
---- ./src/win32/wgaimerror.h 2003-08-19 18:07:08.000000000 +0200
-+++ ./src/win32/wgaimerror.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,7 +1,7 @@
- /*
-- * gaim
-+ * gaim2
- *
-- * File: wgaimerror.h
-+ * File: wgaim2error.h
- * Date: October 14, 2002
- * Description: Convert Winsock errors to Unix errors
- *
-diff -prNu ./src/win32/win32dep.c ./src/win32/win32dep.c
---- ./src/win32/win32dep.c 2005-12-20 03:39:30.000000000 +0100
-+++ ./src/win32/win32dep.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,9 +1,9 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: win32dep.c
- * Date: June, 2002
-- * Description: Windows dependant code for Gaim
-+ * Description: Windows dependant code for Gaim2
- *
- * Copyright (C) 2002-2003, Herman Bloggs <hermanator12002@yahoo.com>
- *
-@@ -31,7 +31,7 @@
- #include <glib.h>
- #include <glib/gstdio.h>
-
--#include "gaim.h"
-+#include "gaim2.h"
- #include "debug.h"
- #include "notify.h"
-
-@@ -70,22 +70,22 @@ static char *app_data_dir, *install_dir,
- /*
- * GLOBALS
- */
--HINSTANCE gaimexe_hInstance = 0;
--HINSTANCE gaimdll_hInstance = 0;
-+HINSTANCE gaim2exe_hInstance = 0;
-+HINSTANCE gaim2dll_hInstance = 0;
-
- /*
- * PROTOS
- */
-
--FARPROC wgaim_find_and_loadproc(char*, char*);
--extern void wgaim_gtkspell_init();
--char* wgaim_data_dir(void);
-+FARPROC wgaim2_find_and_loadproc(char*, char*);
-+extern void wgaim2_gtkspell_init();
-+char* wgaim2_data_dir(void);
-
- /*
- * STATIC CODE
- */
-
--static void wgaim_debug_print(GaimDebugLevel level, const char *category, const char *format, va_list args) {
-+static void wgaim2_debug_print(Gaim2DebugLevel level, const char *category, const char *format, va_list args) {
- char *str = NULL;
- if (args != NULL) {
- str = g_strdup_vprintf(format, args);
-@@ -96,23 +96,23 @@ static void wgaim_debug_print(GaimDebugL
- g_free(str);
- }
-
--static GaimDebugUiOps ops = {
-- wgaim_debug_print
-+static Gaim2DebugUiOps ops = {
-+ wgaim2_debug_print
- };
-
- /*
- * PUBLIC CODE
- */
-
--HINSTANCE wgaim_hinstance(void) {
-- return gaimexe_hInstance;
-+HINSTANCE wgaim2_hinstance(void) {
-+ return gaim2exe_hInstance;
- }
-
- /* Escape windows dir separators. This is needed when paths are saved,
- and on being read back have their '\' chars used as an escape char.
- Returns an allocated string which needs to be freed.
- */
--char* wgaim_escape_dirsep( char* filename ) {
-+char* wgaim2_escape_dirsep( char* filename ) {
- int sepcount=0;
- char* ret=NULL;
- int cnt=0;
-@@ -137,15 +137,15 @@ char* wgaim_escape_dirsep( char* filenam
-
- /* Determine whether the specified dll contains the specified procedure.
- If so, load it (if not already loaded). */
--FARPROC wgaim_find_and_loadproc( char* dllname, char* procedure ) {
-+FARPROC wgaim2_find_and_loadproc( char* dllname, char* procedure ) {
- HMODULE hmod;
- int did_load=0;
- FARPROC proc = 0;
-
- if(!(hmod=GetModuleHandle(dllname))) {
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "%s not found. Loading it..\n", dllname);
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "%s not found. Loading it..\n", dllname);
- if(!(hmod = LoadLibrary(dllname))) {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim", "Could not load: %s\n", dllname);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2", "Could not load: %s\n", dllname);
- return NULL;
- }
- else
-@@ -153,12 +153,12 @@ FARPROC wgaim_find_and_loadproc( char* d
- }
-
- if((proc=GetProcAddress(hmod, procedure))) {
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "This version of %s contains %s\n",
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "This version of %s contains %s\n",
- dllname, procedure);
- return proc;
- }
- else {
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "Function %s not found in dll %s\n",
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "Function %s not found in dll %s\n",
- procedure, dllname);
- if(did_load) {
- /* unload dll */
-@@ -168,10 +168,10 @@ FARPROC wgaim_find_and_loadproc( char* d
- }
- }
-
--/* Determine Gaim Paths during Runtime */
-+/* Determine Gaim2 Paths during Runtime */
-
- /* Get paths to special Windows folders. */
--char *wgaim_get_special_folder(int folder_type) {
-+char *wgaim2_get_special_folder(int folder_type) {
- static LPFNSHGETFOLDERPATHA MySHGetFolderPathA = NULL;
- char *retval = NULL;
- #if GLIB_CHECK_VERSION(2,6,0)
-@@ -179,7 +179,7 @@ char *wgaim_get_special_folder(int folde
-
- if (!MySHGetFolderPathW) {
- MySHGetFolderPathW = (LPFNSHGETFOLDERPATHW)
-- wgaim_find_and_loadproc("shfolder.dll", "SHGetFolderPathW");
-+ wgaim2_find_and_loadproc("shfolder.dll", "SHGetFolderPathW");
- }
-
- if (MySHGetFolderPathW) {
-@@ -195,7 +195,7 @@ char *wgaim_get_special_folder(int folde
- if (!retval) {
- if (!MySHGetFolderPathA) {
- MySHGetFolderPathA = (LPFNSHGETFOLDERPATHA)
-- wgaim_find_and_loadproc("shfolder.dll", "SHGetFolderPathA");
-+ wgaim2_find_and_loadproc("shfolder.dll", "SHGetFolderPathA");
- }
- if (MySHGetFolderPathA) {
- char locale_dir[MAX_PATH + 1];
-@@ -214,7 +214,7 @@ char *wgaim_get_special_folder(int folde
- return retval;
- }
-
--char* wgaim_install_dir(void) {
-+char* wgaim2_install_dir(void) {
- static gboolean initialized = FALSE;
-
- if (!initialized) {
-@@ -237,7 +237,7 @@ char* wgaim_install_dir(void) {
-
- if (tmp == NULL) {
- tmp = g_win32_error_message(GetLastError());
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim",
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2",
- "GetModuleFileName error: %s\n", tmp);
- g_free(tmp);
- return NULL;
-@@ -251,11 +251,11 @@ char* wgaim_install_dir(void) {
- return install_dir;
- }
-
--char* wgaim_lib_dir(void) {
-+char* wgaim2_lib_dir(void) {
- static gboolean initialized = FALSE;
-
- if (!initialized) {
-- char *inst_dir = wgaim_install_dir();
-+ char *inst_dir = wgaim2_install_dir();
- if (inst_dir != NULL) {
- lib_dir = g_strdup_printf("%s" G_DIR_SEPARATOR_S "plugins", inst_dir);
- initialized = TRUE;
-@@ -267,11 +267,11 @@ char* wgaim_lib_dir(void) {
- return lib_dir;
- }
-
--char* wgaim_locale_dir(void) {
-+char* wgaim2_locale_dir(void) {
- static gboolean initialized = FALSE;
-
- if (!initialized) {
-- char *inst_dir = wgaim_install_dir();
-+ char *inst_dir = wgaim2_install_dir();
- if (inst_dir != NULL) {
- locale_dir = g_strdup_printf("%s" G_DIR_SEPARATOR_S "locale", inst_dir);
- initialized = TRUE;
-@@ -283,13 +283,13 @@ char* wgaim_locale_dir(void) {
- return locale_dir;
- }
-
--char* wgaim_data_dir(void) {
-+char* wgaim2_data_dir(void) {
- return app_data_dir;
- }
-
- /* Miscellaneous */
-
--gboolean wgaim_read_reg_string(HKEY key, char* sub_key, char* val_name, LPBYTE data, LPDWORD data_len) {
-+gboolean wgaim2_read_reg_string(HKEY key, char* sub_key, char* val_name, LPBYTE data, LPDWORD data_len) {
- HKEY hkey;
- gboolean ret = FALSE;
-
-@@ -303,7 +303,7 @@ gboolean wgaim_read_reg_string(HKEY key,
- return ret;
- }
-
--int wgaim_gz_decompress(const char* in, const char* out) {
-+int wgaim2_gz_decompress(const char* in, const char* out) {
- gzFile fin;
- FILE *fout;
- char buf[1024];
-@@ -311,19 +311,19 @@ int wgaim_gz_decompress(const char* in,
-
- if((fin = gzopen(in, "rb"))) {
- if(!(fout = g_fopen(out, "wb"))) {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim_gz_decompress", "Error opening file: %s\n", out);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2_gz_decompress", "Error opening file: %s\n", out);
- gzclose(fin);
- return 0;
- }
- }
- else {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim_gz_decompress", "gzopen failed to open: %s\n", in);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2_gz_decompress", "gzopen failed to open: %s\n", in);
- return 0;
- }
-
- while((ret=gzread(fin, buf, 1024))) {
- if(fwrite(buf, 1, ret, fout) < ret) {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim_gz_decompress", "Error writing %d bytes to file\n", ret);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2_gz_decompress", "Error writing %d bytes to file\n", ret);
- gzclose(fin);
- fclose(fout);
- return 0;
-@@ -333,36 +333,36 @@ int wgaim_gz_decompress(const char* in,
- gzclose(fin);
-
- if(ret < 0) {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim_gz_decompress", "gzread failed while reading: %s\n", in);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2_gz_decompress", "gzread failed while reading: %s\n", in);
- return 0;
- }
-
- return 1;
- }
-
--int wgaim_gz_untar(const char* filename, const char* destdir) {
-+int wgaim2_gz_untar(const char* filename, const char* destdir) {
- char tmpfile[_MAX_PATH];
-- char template[]="wgaimXXXXXX";
-+ char template[]="wgaim2XXXXXX";
-
- sprintf(tmpfile, "%s%s%s", g_get_tmp_dir(), G_DIR_SEPARATOR_S, _mktemp(template));
-- if(wgaim_gz_decompress(filename, tmpfile)) {
-+ if(wgaim2_gz_decompress(filename, tmpfile)) {
- int ret;
- if(untar(tmpfile, destdir, UNTAR_FORCE | UNTAR_QUIET))
- ret=1;
- else {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim_gz_untar", "Failure untaring %s\n", tmpfile);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2_gz_untar", "Failure untaring %s\n", tmpfile);
- ret=0;
- }
- g_unlink(tmpfile);
- return ret;
- }
- else {
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim_gz_untar", "Failed to gz decompress %s\n", filename);
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2_gz_untar", "Failed to gz decompress %s\n", filename);
- return 0;
- }
- }
-
--void wgaim_notify_uri(const char *uri) {
-+void wgaim2_notify_uri(const char *uri) {
- SHELLEXECUTEINFO sinfo;
-
- memset(&sinfo, 0, sizeof(sinfo));
-@@ -377,19 +377,19 @@ void wgaim_notify_uri(const char *uri) {
- default http browser.
- */
- if(!ShellExecuteEx(&sinfo))
-- gaim_debug_error("wgaim", "Error opening URI: %s error: %d\n", uri, (int)sinfo.hInstApp);
-+ gaim2_debug_error("wgaim2", "Error opening URI: %s error: %d\n", uri, (int)sinfo.hInstApp);
- }
-
--void wgaim_init(HINSTANCE hint) {
-+void wgaim2_init(HINSTANCE hint) {
- WORD wVersionRequested;
- WSADATA wsaData;
- char *perlenv;
- char *newenv;
-
-- gaim_debug_set_ui_ops(&ops);
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "wgaim_init start\n");
-+ gaim2_debug_set_ui_ops(&ops);
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "wgaim2_init start\n");
-
-- gaimexe_hInstance = hint;
-+ gaim2exe_hInstance = hint;
-
- /* Winsock init */
- wVersionRequested = MAKEWORD( 2, 2 );
-@@ -401,58 +401,58 @@ void wgaim_init(HINSTANCE hint) {
- wVersion since that is the version we requested. */
- if ( LOBYTE( wsaData.wVersion ) != 2 ||
- HIBYTE( wsaData.wVersion ) != 2 ) {
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "Could not find a usable WinSock DLL. Oh well.\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "Could not find a usable WinSock DLL. Oh well.\n");
- WSACleanup();
- }
-
- /* Set Environmental Variables */
-- /* Tell perl where to find Gaim's perl modules */
-+ /* Tell perl where to find Gaim2's perl modules */
- perlenv = (char*) g_getenv("PERL5LIB");
- newenv = g_strdup_printf("PERL5LIB=%s%s%s%s",
- perlenv ? perlenv : "",
- perlenv ? ";" : "",
-- wgaim_install_dir(),
-+ wgaim2_install_dir(),
- "\\perlmod;");
- if (putenv(newenv) < 0)
-- gaim_debug(GAIM_DEBUG_WARNING, "wgaim", "putenv failed\n");
-+ gaim2_debug(GAIM_DEBUG_WARNING, "wgaim2", "putenv failed\n");
- g_free(newenv);
-
-- /* Set app data dir, used by gaim_home_dir */
-+ /* Set app data dir, used by gaim2_home_dir */
- newenv = (char*) g_getenv("GAIMHOME");
- if (newenv) {
- app_data_dir = g_strdup(newenv);
- } else {
-- app_data_dir = wgaim_get_special_folder(CSIDL_APPDATA);
-+ app_data_dir = wgaim2_get_special_folder(CSIDL_APPDATA);
- if (!app_data_dir) {
- app_data_dir = g_strdup("C:");
- }
- }
-
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "Gaim settings dir: %s\n", app_data_dir);
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "Gaim2 settings dir: %s\n", app_data_dir);
-
- /* IdleTracker Initialization */
-- if(!wgaim_set_idlehooks())
-- gaim_debug(GAIM_DEBUG_ERROR, "wgaim", "Failed to initialize idle tracker\n");
-+ if(!wgaim2_set_idlehooks())
-+ gaim2_debug(GAIM_DEBUG_ERROR, "wgaim2", "Failed to initialize idle tracker\n");
-
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "wgaim_init end\n");
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "wgaim2_init end\n");
- }
-
- /* Windows Cleanup */
-
--void wgaim_cleanup(void) {
-- gaim_debug(GAIM_DEBUG_INFO, "wgaim", "wgaim_cleanup\n");
-+void wgaim2_cleanup(void) {
-+ gaim2_debug(GAIM_DEBUG_INFO, "wgaim2", "wgaim2_cleanup\n");
-
- /* winsock cleanup */
- WSACleanup();
-
- /* Idle tracker cleanup */
-- wgaim_remove_idlehooks();
-+ wgaim2_remove_idlehooks();
-
- g_free(app_data_dir);
- }
-
- /* DLL initializer */
- BOOL WINAPI DllMain( HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved ) {
-- gaimdll_hInstance = hinstDLL;
-+ gaim2dll_hInstance = hinstDLL;
- return TRUE;
- }
-diff -prNu ./src/win32/win32dep.h ./src/win32/win32dep.h
---- ./src/win32/win32dep.h 2005-12-16 10:02:17.000000000 +0100
-+++ ./src/win32/win32dep.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: win32dep.h
- *
-@@ -25,7 +25,7 @@
- #include <shlobj.h>
- #include <winsock2.h>
- #include <process.h>
--#include "wgaimerror.h"
-+#include "wgaim2error.h"
- #include "libc_interface.h"
-
- /*
-@@ -36,28 +36,28 @@
- ** win32dep.c
- **/
- /* Windows helper functions */
--HINSTANCE wgaim_hinstance(void);
--FARPROC wgaim_find_and_loadproc(char*, char*);
--gboolean wgaim_read_reg_string(HKEY key, char* sub_key, char* val_name, LPBYTE data, LPDWORD data_len);
--char* wgaim_escape_dirsep(char*);
--
--/* Determine Gaim paths */
--char* wgaim_get_special_folder(int folder_type); /* needs to be g_free'd */
--char* wgaim_install_dir(void);
--char* wgaim_lib_dir(void);
--char* wgaim_locale_dir(void);
--char* wgaim_data_dir(void);
-+HINSTANCE wgaim2_hinstance(void);
-+FARPROC wgaim2_find_and_loadproc(char*, char*);
-+gboolean wgaim2_read_reg_string(HKEY key, char* sub_key, char* val_name, LPBYTE data, LPDWORD data_len);
-+char* wgaim2_escape_dirsep(char*);
-+
-+/* Determine Gaim2 paths */
-+char* wgaim2_get_special_folder(int folder_type); /* needs to be g_free'd */
-+char* wgaim2_install_dir(void);
-+char* wgaim2_lib_dir(void);
-+char* wgaim2_locale_dir(void);
-+char* wgaim2_data_dir(void);
-
- /* Utility */
--int wgaim_gz_decompress(const char* in, const char* out);
--int wgaim_gz_untar(const char* filename, const char* destdir);
-+int wgaim2_gz_decompress(const char* in, const char* out);
-+int wgaim2_gz_untar(const char* filename, const char* destdir);
-
- /* Misc */
--void wgaim_notify_uri(const char *uri);
-+void wgaim2_notify_uri(const char *uri);
-
- /* init / cleanup */
--void wgaim_init(HINSTANCE);
--void wgaim_cleanup(void);
-+void wgaim2_init(HINSTANCE);
-+void wgaim2_cleanup(void);
-
-
- /*
-@@ -65,11 +65,11 @@ void wgaim_cleanup(void);
- */
-
- /*
-- * Gaim specific
-+ * Gaim2 specific
- */
--#define DATADIR wgaim_install_dir()
--#define LIBDIR wgaim_lib_dir()
--#define LOCALEDIR wgaim_locale_dir()
-+#define DATADIR wgaim2_install_dir()
-+#define LIBDIR wgaim2_lib_dir()
-+#define LOCALEDIR wgaim2_locale_dir()
-
- #endif /* _WIN32DEP_H_ */
-
-diff -prNu ./src/win32/wspell.c ./src/win32/wspell.c
---- ./src/win32/wspell.c 2005-09-21 04:05:08.000000000 +0200
-+++ ./src/win32/wspell.c 2006-01-05 15:11:04.000000000 +0100
-@@ -1,9 +1,9 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: wspell.c
- * Date: March, 2003
-- * Description: Windows Gaim gtkspell interface.
-+ * Description: Windows Gaim2 gtkspell interface.
- *
- * Copyright (C) 2002-2003, Herman Bloggs <hermanator12002@yahoo.com>
- *
-@@ -43,26 +43,26 @@ gboolean wgtkspell_set_language(GtkSpel
- void wgtkspell_recheck_all(GtkSpell *spell) {}
-
- /* GTKSPELL PROTOS */
--GtkSpell* (*wgaim_gtkspell_new_attach) (GtkTextView *,
-+GtkSpell* (*wgaim2_gtkspell_new_attach) (GtkTextView *,
- const gchar *,
- GError **) = wgtkspell_new_attach;
-
--GtkSpell* (*wgaim_gtkspell_get_from_text_view) (GtkTextView*) = wgtkspell_get_from_text_view;
-+GtkSpell* (*wgaim2_gtkspell_get_from_text_view) (GtkTextView*) = wgtkspell_get_from_text_view;
-
--void (*wgaim_gtkspell_detach) (GtkSpell*) = wgtkspell_detach;
-+void (*wgaim2_gtkspell_detach) (GtkSpell*) = wgtkspell_detach;
-
--gboolean (*wgaim_gtkspell_set_language) (GtkSpell*,
-+gboolean (*wgaim2_gtkspell_set_language) (GtkSpell*,
- const gchar*,
- GError**) = wgtkspell_set_language;
-
--void (*wgaim_gtkspell_recheck_all) (GtkSpell*) = wgtkspell_recheck_all;
-+void (*wgaim2_gtkspell_recheck_all) (GtkSpell*) = wgtkspell_recheck_all;
-
- static void load_gtkspell() {
-- wgaim_gtkspell_new_attach = (void*)wgaim_find_and_loadproc("libgtkspell.dll", "gtkspell_new_attach" );
-- wgaim_gtkspell_get_from_text_view = (void*)wgaim_find_and_loadproc("libgtkspell.dll", "gtkspell_get_from_text_view");
-- wgaim_gtkspell_detach = (void*)wgaim_find_and_loadproc("libgtkspell.dll", "gtkspell_detach");
-- wgaim_gtkspell_set_language = (void*)wgaim_find_and_loadproc("libgtkspell.dll", "gtkspell_set_language");
-- wgaim_gtkspell_recheck_all = (void*)wgaim_find_and_loadproc("libgtkspell.dll", "gtkspell_recheck_all");
-+ wgaim2_gtkspell_new_attach = (void*)wgaim2_find_and_loadproc("libgtkspell.dll", "gtkspell_new_attach" );
-+ wgaim2_gtkspell_get_from_text_view = (void*)wgaim2_find_and_loadproc("libgtkspell.dll", "gtkspell_get_from_text_view");
-+ wgaim2_gtkspell_detach = (void*)wgaim2_find_and_loadproc("libgtkspell.dll", "gtkspell_detach");
-+ wgaim2_gtkspell_set_language = (void*)wgaim2_find_and_loadproc("libgtkspell.dll", "gtkspell_set_language");
-+ wgaim2_gtkspell_recheck_all = (void*)wgaim2_find_and_loadproc("libgtkspell.dll", "gtkspell_recheck_all");
- }
-
- static char* lookup_aspell_path() {
-@@ -137,14 +137,14 @@ static char* lookup_aspell_path() {
- return path;
- }
-
--void wgaim_gtkspell_init() {
-+void wgaim2_gtkspell_init() {
- char *aspell_path = lookup_aspell_path();
-
- if (aspell_path != NULL) {
- char *tmp = g_strconcat(aspell_path, "\\aspell-15.dll", NULL);
- if (g_file_test(tmp, G_FILE_TEST_EXISTS)) {
- const char *path = g_getenv("PATH");
-- gaim_debug_info("wspell", "Found Aspell in %s\n", aspell_path);
-+ gaim2_debug_info("wspell", "Found Aspell in %s\n", aspell_path);
-
- g_free(tmp);
-
-@@ -156,12 +156,12 @@ void wgaim_gtkspell_init() {
-
- load_gtkspell();
- } else {
-- gaim_debug_warning("wspell", "Couldn't find aspell-15.dll\n");
-+ gaim2_debug_warning("wspell", "Couldn't find aspell-15.dll\n");
- }
-
- g_free(tmp);
- g_free(aspell_path);
- } else {
-- gaim_debug_warning("wspell", "Couldn't find path for Aspell\n");
-+ gaim2_debug_warning("wspell", "Couldn't find path for Aspell\n");
- }
- }
-diff -prNu ./src/win32/wspell.h ./src/win32/wspell.h
---- ./src/win32/wspell.h 2005-12-16 10:02:17.000000000 +0100
-+++ ./src/win32/wspell.h 2006-01-05 15:11:20.000000000 +0100
-@@ -1,5 +1,5 @@
- /*
-- * gaim
-+ * gaim2
- *
- * File: wspell.h
- *
-@@ -24,26 +24,26 @@
- #define _WSPELL_H_
- #include <gtkspell/gtkspell.h>
-
--void wgaim_gtkspell_init(void);
-+void wgaim2_gtkspell_init(void);
-
--extern GtkSpell* (*wgaim_gtkspell_new_attach)(GtkTextView*, const gchar*, GError**);
-+extern GtkSpell* (*wgaim2_gtkspell_new_attach)(GtkTextView*, const gchar*, GError**);
- #define gtkspell_new_attach( view, lang, error ) \
--wgaim_gtkspell_new_attach( view, lang, error )
-+wgaim2_gtkspell_new_attach( view, lang, error )
-
--extern GtkSpell* (*wgaim_gtkspell_get_from_text_view)(GtkTextView*);
-+extern GtkSpell* (*wgaim2_gtkspell_get_from_text_view)(GtkTextView*);
- #define gtkspell_get_from_text_view( view ) \
--wgaim_gtkspell_get_from_text_view( view )
-+wgaim2_gtkspell_get_from_text_view( view )
-
--extern void (*wgaim_gtkspell_detach)(GtkSpell*);
-+extern void (*wgaim2_gtkspell_detach)(GtkSpell*);
- #define gtkspell_detach( spell ) \
--wgaim_gtkspell_detach( spell )
-+wgaim2_gtkspell_detach( spell )
-
--extern gboolean (*wgaim_gtkspell_set_language)(GtkSpell*, const gchar*, GError**);
-+extern gboolean (*wgaim2_gtkspell_set_language)(GtkSpell*, const gchar*, GError**);
- #define gtkspell_set_language( spell, lang, error ) \
--wgaim_gtkspell_set_language( spell, lang, error )
-+wgaim2_gtkspell_set_language( spell, lang, error )
-
--extern void (*wgaim_gtkspell_recheck_all)(GtkSpell*);
-+extern void (*wgaim2_gtkspell_recheck_all)(GtkSpell*);
- #define gtkspell_recheck_all( spell ) \
--wgaim_gtkspell_recheck_all( spell )
-+wgaim2_gtkspell_recheck_all( spell )
-
- #endif /* _WSPELL_H_ */
-diff -prNu ./src/win_gaim.c ./src/win_gaim.c
---- ./src/win_gaim.c 2005-12-07 00:35:10.000000000 +0100
-+++ ./src/win_gaim.c 2006-01-05 15:11:03.000000000 +0100
-@@ -1,11 +1,11 @@
- /*
-- * win_gaim.c
-+ * win_gaim2.c
- *
- * Date: June, 2002
-- * Description: Entry point for win32 gaim, and various win32 dependant
-+ * Description: Entry point for win32 gaim2, and various win32 dependant
- * routines.
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-@@ -44,7 +44,7 @@ typedef BOOL (CALLBACK* LPFNATTACHCONSOL
- /*
- * PROTOTYPES
- */
--static LPFNGAIMMAIN gaim_main = NULL;
-+static LPFNGAIMMAIN gaim2_main = NULL;
- static LPFNSETDLLDIRECTORY MySetDllDirectory = NULL;
-
-
-@@ -90,7 +90,7 @@ static void dll_prep() {
- HMODULE hmod;
- HKEY hkey;
- #ifdef PORTABLE
-- /* We assume that GTK+ is installed under \\path\to\Gaim\..\GTK
-+ /* We assume that GTK+ is installed under \\path\to\Gaim2\..\GTK
- * First we find \\path\to
- */
- if (GetModuleFileName(NULL, path, MAX_PATH) != 0) {
-@@ -115,7 +115,7 @@ static void dll_prep() {
-
- if (path) {
- /* Set up the settings dir base to be \\path\to
-- * The actual settings dir will be \\path\to\.gaim */
-+ * The actual settings dir will be \\path\to\.gaim2 */
- char settingsdir[strlen(path) + strlen("GAIMHOME=") + 1];
- char aspelldir[strlen(path) + strlen("GAIM_ASPELL_DIR=\\Aspell\\bin") + 1];
-
-@@ -227,7 +227,7 @@ static void dll_prep() {
- }
- }
-
--static char* wgaim_lcid_to_posix(LCID lcid) {
-+static char* wgaim2_lcid_to_posix(LCID lcid) {
- char *posix = NULL;
- int lang_id = PRIMARYLANGID(lcid);
- int sub_id = SUBLANGID(lcid);
-@@ -364,12 +364,12 @@ static char* wgaim_lcid_to_posix(LCID lc
- return posix;
- }
-
--/* Determine and set Gaim locale as follows (in order of priority):
-+/* Determine and set Gaim2 locale as follows (in order of priority):
- - Check GAIMLANG env var
- - Check NSIS Installer Language reg value
- - Use default user locale
- */
--static const char *wgaim_get_locale() {
-+static const char *wgaim2_get_locale() {
- const char *locale = NULL;
- LCID lcid;
- #ifndef PORTABLE
-@@ -382,38 +382,38 @@ static const char *wgaim_get_locale() {
- return locale;
-
- #ifndef PORTABLE
-- if (read_reg_string(HKEY_CURRENT_USER, "SOFTWARE\\gaim",
-+ if (read_reg_string(HKEY_CURRENT_USER, "SOFTWARE\\gaim2",
- "Installer Language", (LPBYTE) &data, &datalen)) {
-- if ((locale = wgaim_lcid_to_posix(atoi(data))))
-+ if ((locale = wgaim2_lcid_to_posix(atoi(data))))
- return locale;
- }
- #endif
-
- lcid = GetUserDefaultLCID();
-- if ((locale = wgaim_lcid_to_posix(lcid)))
-+ if ((locale = wgaim2_lcid_to_posix(lcid)))
- return locale;
-
- return "en";
- }
-
--static void wgaim_set_locale() {
-+static void wgaim2_set_locale() {
- const char *locale = NULL;
- char envstr[25];
-
-- locale = wgaim_get_locale();
-+ locale = wgaim2_get_locale();
-
- snprintf(envstr, 25, "LANG=%s", locale);
- printf("Setting locale: %s\n", envstr);
- putenv(envstr);
- }
-
--static BOOL wgaim_set_running() {
-+static BOOL wgaim2_set_running() {
- HANDLE h;
-
-- if ((h = CreateMutex(NULL, FALSE, "gaim_is_running"))) {
-+ if ((h = CreateMutex(NULL, FALSE, "gaim2_is_running"))) {
- if (GetLastError() == ERROR_ALREADY_EXISTS) {
- MessageBox(NULL,
-- "An instance of Gaim is already running",
-+ "An instance of Gaim2 is already running",
- NULL, MB_OK | MB_TOPMOST);
- return FALSE;
- }
-@@ -421,7 +421,7 @@ static BOOL wgaim_set_running() {
- return TRUE;
- }
-
--static void wgaim_set_proxy() {
-+static void wgaim2_set_proxy() {
- DWORD regval = 1;
- DWORD reglen = sizeof(DWORD);
-
-@@ -474,7 +474,7 @@ int _stdcall
- WinMain (struct HINSTANCE__ *hInstance, struct HINSTANCE__ *hPrevInstance,
- char *lpszCmdLine, int nCmdShow) {
- char errbuf[512];
-- char gaimdir[MAX_PATH];
-+ char gaim2dir[MAX_PATH];
- HMODULE hmod;
-
- /* If debug or help or version flag used, create console for output */
-@@ -491,8 +491,8 @@ WinMain (struct HINSTANCE__ *hInstance,
- }
-
- /* Load exception handler if we have it */
-- if (GetModuleFileName(NULL, gaimdir, MAX_PATH) != 0) {
-- char *tmp = gaimdir;
-+ if (GetModuleFileName(NULL, gaim2dir, MAX_PATH) != 0) {
-+ char *tmp = gaim2dir;
- char *prev = NULL;
-
- while ((tmp = strchr(tmp, '\\'))) {
-@@ -502,8 +502,8 @@ WinMain (struct HINSTANCE__ *hInstance,
-
- if (prev) {
- prev[0] = '\0';
-- strcat(gaimdir, "\\exchndl.dll");
-- if (LoadLibrary(gaimdir))
-+ strcat(gaim2dir, "\\exchndl.dll");
-+ if (LoadLibrary(gaim2dir))
- printf("Loaded exchndl.dll\n");
- }
- } else {
-@@ -518,25 +518,25 @@ WinMain (struct HINSTANCE__ *hInstance,
- #endif
- dll_prep();
-
-- wgaim_set_locale();
-+ wgaim2_set_locale();
- /* If help or version flag used, do not check Mutex */
- if (!strstr(lpszCmdLine, "-h") && !strstr(lpszCmdLine, "-v"))
-- if (!getenv("GAIM_MULTI_INST") && !wgaim_set_running())
-+ if (!getenv("GAIM_MULTI_INST") && !wgaim2_set_running())
- return 0;
-
-- wgaim_set_proxy();
-+ wgaim2_set_proxy();
-
-- /* Now we are ready for Gaim .. */
-- if ((hmod = LoadLibrary("gaim.dll"))) {
-- gaim_main = (LPFNGAIMMAIN) GetProcAddress(hmod, "gaim_main");
-+ /* Now we are ready for Gaim2 .. */
-+ if ((hmod = LoadLibrary("gaim2.dll"))) {
-+ gaim2_main = (LPFNGAIMMAIN) GetProcAddress(hmod, "gaim2_main");
- }
-
-- if (!gaim_main) {
-- snprintf(errbuf, 512, "Error loading gaim.dll. Error: %u",
-+ if (!gaim2_main) {
-+ snprintf(errbuf, 512, "Error loading gaim2.dll. Error: %u",
- (UINT) GetLastError());
- MessageBox(NULL, errbuf, NULL, MB_OK | MB_TOPMOST);
- return 0;
- }
-
-- return gaim_main (hInstance, __argc, __argv);
-+ return gaim2_main (hInstance, __argc, __argv);
- }
-diff -prNu ./src/xmlnode.c ./src/xmlnode.c
---- ./src/xmlnode.c 2005-11-27 04:42:39.000000000 +0100
-+++ ./src/xmlnode.c 2006-01-05 15:11:05.000000000 +0100
-@@ -1,9 +1,9 @@
- /**
- * @file xmlnode.c XML DOM functions
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
-diff -prNu ./src/xmlnode.h ./src/xmlnode.h
---- ./src/xmlnode.h 2005-11-27 04:42:39.000000000 +0100
-+++ ./src/xmlnode.h 2006-01-05 15:11:21.000000000 +0100
-@@ -2,9 +2,9 @@
- * @file xmlnode.h XML DOM functions
- * @ingroup core
- *
-- * gaim
-+ * gaim2
- *
-- * Gaim is the legal property of its developers, whose names are too numerous
-+ * Gaim2 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.
- *
diff --git a/net-im/gaim/gaim-9999.ebuild b/net-im/gaim/gaim-9999.ebuild
deleted file mode 100644
index 7f2de41e..00000000
--- a/net-im/gaim/gaim-9999.ebuild
+++ /dev/null
@@ -1,202 +0,0 @@
-# Copyright 1999-2005 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-im/gaim/gaim-2.0.0_beta1-r3.ebuild,v 1.1 2005/12/29 13:48:45 gothgirl Exp $
-
-inherit cvs flag-o-matic eutils toolchain-funcs debug multilib mono
-
-ECVS_SERVER="cvs.sourceforge.net:/cvsroot/gaim"
-ECVS_MODULE="gaim"
-
-MY_PV=${PV/_beta/beta}
-MY_P="${PN}-${MY_PV}"
-
-DESCRIPTION="GTK Instant Messenger client"
-HOMEPAGE="http://gaim.sourceforge.net/"
-#SRC_URI="mirror://sourceforge/gaim/${MY_P}.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="2"
-KEYWORDS="~x86 ~amd64"
-IUSE="bonjour dbus nls perl spell nas cjk gnutls silc eds krb4 tcltk debug mono xscreensaver truespeech ao startup-notification audiofile vv"
-
-RDEPEND="media-libs/libao
- media-libs/audiofile
- bonjour? (net-misc/howl)
- dbus? ( >=sys-apps/dbus-0.35
- >=dev-lang/python-2.4 )
- >=x11-libs/gtk+-2.0
- >=dev-libs/glib-2.0
- nas? ( >=media-libs/nas-1.4.1-r1 )
- perl? ( >=dev-lang/perl-5.8.2-r1
- !<perl-core/ExtUtils-MakeMaker-6.17 )
- spell? ( >=app-text/gtkspell-2.0.2 )
- gnutls? ( net-libs/gnutls )
- !gnutls? ( >=dev-libs/nss-3.9.2-r2 )
- silc? ( >=net-im/silc-toolkit-0.9.12-r3 )
- eds? ( gnome-extra/evolution-data-server )
- krb4? ( >=app-crypt/mit-krb5-1.3.6-r1 )
- tcltk? ( dev-lang/tcl
- dev-lang/tk )
- startup-notification? ( >=x11-libs/startup-notification-0.5 )
- mono? ( dev-lang/mono )
- xscreensaver? (x11-misc/xscreensaver)"
-
-DEPEND="$RDEPEND
- dev-util/pkgconfig
- x11-libs/startup-notification
- nls? ( sys-devel/gettext )"
-
-S="${WORKDIR}/${PN}"
-
-# List of plugins
-# app-accessibility/festival-gaim
-# net-im/gaim-blogger
-# net-im/gaim-bnet
-# net-im/gaim-meanwhile
-# net-im/gaim-snpp
-# x11-plugins/autoprofile
-# x11-plugins/gaim-assistant
-# x11-plugins/gaim-encryption
-# x11-plugins/gaim-extprefs
-# x11-plugins/gaim-latex
-# x11-plugins/gaim-otr
-# x11-plugins/gaim-rhythmbox
-# x11-plugins/gaim-xmms-remote
-# x11-plugins/gaimosd
-# x11-plugins/guifications
-
-
-print_gaim_warning() {
- ewarn
- ewarn "This is a beta release! Please back up everything in your .gaim"
- ewarn "directory. We're looking for lots of feedback on this release"
- ewarn "especially what you love about it and what you hate about it."
- ewarn
- ewarn "Again, this is a beta release and should not be used by those"
- ewarn "with a heart condition, if you are pregnant, or if you are under"
- ewarn "the age of 8. Side-effects include awesomeness, dumbfoundedness,"
- ewarn "dry mouth and lava. Consult your doctor to find out if"
- ewarn "${MY_P} is right for you."
- ewarn
- ewarn "If you are merging ${MY_P} from an earlier version, you may need"
- ewarn "to re-merge any plugins like gaim-encryption or gaim-snpp."
- ewarn
- ewarn "If you experience problems with gaim, file them as bugs with"
- ewarn "Gentoo's bugzilla, http://bugs.gentoo.org. DO NOT report them"
- ewarn "as bugs with gaim's sourceforge tracker, and by all means DO NOT"
- ewarn "seek help in #gaim."
- ewarn
- ewarn "Be sure to USE=\"debug\" and include a backtrace for any seg"
- ewarn "faults, see http://gaim.sourceforge.net/gdb.php for details on"
- ewarn "backtraces."
- ewarn
- ewarn "Please read the gaim FAQ at http://gaim.sourceforge.net/faq.php"
- ewarn
- einfo
- einfo "Note that we are now filtering all unstable flags in C[XX]FLAGS."
- einfo
- #ebeep 5
- #epause 3
-}
-
-pkg_setup() {
- print_gaim_warning
- if use krb4 && ! built_with_use app-crypt/mit-krb5 krb4 ; then
- eerror
- eerror You need to rebuild app-crypt/mit-krb5 with USE=krb4 in order to
- eerror enable krb4 support for the zephyr protocol in gaim.
- eerror
- die "Configure failed"
- fi
-}
-
-src_unpack() {
- #unpack ${A}
- #cvs_src_unpack
- rsync -av /mnt/soft/cvs/gaim/gaim ${WORKDIR}
- cd "${S}"
-}
-
-src_compile() {
- einfo "Convert Gaim to Gaim2"
- #epatch ${FILESDIR}/gaim-to-gaim2.patch
- find . -type f -exec sed -i -e 's/gaim/gaim2/g' {} \;
- find . -type f -exec sed -i -e 's/Gaim/Gaim2/g' {} \;
- find . -type f -exec sed -i -e 's/GAIM/GAIM2/g' {} \;
-
- # Stabilize things, for your own good
- strip-flags
- replace-flags -O? -O2
-
- # -msse2 doesn't play nice on gcc 3.2
- [ "`gcc-version`" == "3.2" ] && filter-flags -msse2
-
- local myconf
- use truespeech && myconf="${myconf} --enable-truespeech"
- use ao || use audiofile || myconf="${myconf} --disable-audio"
- use dbus && myconf="${myconf} --enable-dbus"
- use debug && myconf="${myconf} --enable-debug"
- use perl || myconf="${myconf} --disable-perl"
- use spell || myconf="${myconf} --disable-gtkspell"
- use nls || myconf="${myconf} --disable-nls"
- use nas && myconf="${myconf} --enable-nas" || myconf="${myconf} --disable-nas"
- use eds || myconf="${myconf} --disable-gevolution"
- use krb4 && myconf="${myconf} --with-krb4"
- use tcltk || myconf="${myconf} --disable-tcl --disable-tk"
- use xscreensaver || myconf="${myconf} --disable-screensaver"
- use startup-notification || myconf="${myconf} --disable-startup-notification"
- use mono && myconf="${myconf} --enable-mono"
- use vv && myconf="${myconf} --enable-vv"
-
-
- if use gnutls ; then
- einfo "Disabling NSS, using GnuTLS"
- myconf="${myconf} --enable-nss=no"
- myconf="${myconf} --with-gnutls-includes=/usr/include/gnutls"
- myconf="${myconf} --with-gnutls-libs=/usr/$(get_libdir)"
- else
- einfo "Disabling GnuTLS, using NSS"
- myconf="${myconf} --enable-gnutls=no"
- myconf="${myconf} --with-nspr-includes=/usr/include/nspr"
- myconf="${myconf} --with-nss-includes=/usr/include/nss"
- myconf="${myconf} --with-nspr-libs=/usr/$(get_libdir)/nspr"
- myconf="${myconf} --with-nss-libs=/usr/$(get_libdir)/nss"
- fi
-
- einfo "Move some files to be correct with new namespace"
- mv gaim{,2}.desktop
- mv gaim{,2}.apspec.in
- mv gaim{,2}.pc.in
- mv gaim{,2}.spec.in
- mv doc/gaim{,2}.1.in
- mv m4macros/gaim{,2}.m4
- mv pixmaps/gaim{,2}.png
- mv pixmaps/gaim{,2}_error.png
- mv pixmaps/gaim{,2}_auth.png
- mv pixmaps/gaim{,2}_cool.png
- mv pixmaps/gaim{,2}_info.png
- mv pixmaps/gaim{,2}_question.png
- mv pixmaps/gaim{,2}_warning.png
- mv plugins/gaim{,2}rc.c
- mv plugins/mono/api/Gaim{,2}Plugin.cs
- mv plugins/perl/libgaim{,2}perl.c
- mv plugins/perl/common/Gaim{,2}.pm
- mv plugins/perl/common/Gaim{,2}.xs
- mv plugins/tcl/tcl_gaim{,2}.h
- mv src/gtkgaim{,2}.h
- mv src/gaim{,2}.h
-
- ./autogen.sh
- econf ${myconf} || die "Configuration failed"
-
- emake -j1 || die "Make failed"
-}
-
-src_install() {
- make install DESTDIR=${D} || die "Install failed"
- dodoc ABOUT-NLS AUTHORS COPYING HACKING INSTALL NEWS PROGRAMMING_NOTES README ChangeLog VERSION
-}
-
-pkg_postinst() {
- print_gaim_warning
-}