Don't set empty values for the default EmpathyHandler
This implies the following:
- have an empty default handler when the Dispatcher is used directly
with the singleton
- autogenerate the name for the default handler
- set priv->filters in the handler to an empty GPtrArray in this case,
as that can't be NULL.
[empathy_builder_get_file] NULL out passed GObj ptrs if GtkBuilder file broken
If the GtkBuilder file passed to empathy_builder_get_file is broken, it
returns NULL, but doesn't touch the contents of any pointers passed to retrieve
GObjects. In several places we start using these pointers without checking
whether the file was actually setup, which causes Empathy to crash.
Ideally callers of empathy_builder_get_file() should check whether or not
the function returned correctly before using any of the passed pointers, but
in case they don't, make sure we're not passing pointers to random memory.
Jonathan Tellier [Fri, 28 Aug 2009 17:26:15 +0000 (13:26 -0400)]
Fixed some of the EmpathyAccountWidget's control button behaviour.
- When creating an IRC account, we are now making sure that the control
buttons have the correct state.
- When creating an account, the "Cancel" button is always sensitive.
- Fixed a style error in EmpathyAccountsDialog.
Will Thompson [Mon, 31 Aug 2009 00:15:41 +0000 (01:15 +0100)]
Ack received messages from ourself.
Sumana Harihareswara reported that she had started a conversation with
herself, sent a message, and then tried to close the window, but
whenever she did so it reappeared.
This was because Empathy did not acknowledge "incoming" messages from
the user themself; hence, when it Close()d the channel, Gabble respawned
it, because it still had pending messages.
Will Thompson [Mon, 31 Aug 2009 00:13:00 +0000 (01:13 +0100)]
Use char* not EmpathyMessage in TpChat:send-error
The only consumer of this signal just extracts the body from the
EmpathyMessage. It will be easier to handle the SendError D-Bus signal
if we don't have to construct an EmpathyMessage from it.
Sjoerd Simons [Sat, 29 Aug 2009 16:33:46 +0000 (17:33 +0100)]
Add basic media-signalling capabilities
Add basic capabilities for media-signalling so future CM's will still advertise
support for them. Currently we announce:
org.freedesktop.Telepathy.Channel.Interface.MediaSignalling/ice-udp
org.freedesktop.Telepathy.Channel.Interface.MediaSignalling/gtalk-p2p
Sjoerd Simons [Sat, 29 Aug 2009 16:13:04 +0000 (17:13 +0100)]
Add the filters not in the Client file to a second Handler
A Dispatcher isn't guaranteed to ask the Handlers D-Bus interface for the
filter after launching it. So have our main handler match what is defined in
the client file and add an extra head which contains the complete list
Jonathan Tellier [Fri, 28 Aug 2009 18:19:47 +0000 (14:19 -0400)]
Fixed bug which would occur when deleting account with pending changes
- When the selected account was NULL,
accounts_dialog_has_pending_change() would not check its state
correctly. That function is working with a pointer on a pointer to the
account and was not dereferencing properly.
- The pointer to the account we pass to
accounts_dialog_has_pending_change() is now properly initialized to
NULL.
- When deleting an account, the COL_ACCOUNT_POINTER column is now
properly set to NULL.
Jonathan Tellier [Fri, 28 Aug 2009 15:23:44 +0000 (11:23 -0400)]
Using GtkTreeRowReference instead of a string path.
- When the user selects another account and has pending changes to the
currently selected account, we need to keed track of the destination
row. Instead of saving that information as the string representation
of a GtkTreePath, we now use a GtkTreeRowReference.
Jonathan Tellier [Fri, 28 Aug 2009 14:45:54 +0000 (10:45 -0400)]
Improved confirmation dialog shown to the user before discarding changes
- Split the confirmation dialog's text into a primary and secondary
section.
- Changed the button label to "Cancel" and "Discard" instead of "Yes"
and "No".
- Added a accounts_dialog_show_question_dialog() function to show
question dialogs related to the accounts dialog and connect to its
"response" signal.
- Removed the empathy_show_yes_no_question_dialog() function since it
was added for this specific patch but is no longer used.
Jonathan Tellier [Thu, 27 Aug 2009 15:57:18 +0000 (11:57 -0400)]
Minor changes to EmpathyAccountWidget and EmpathyAccountsDialog
- account_widget_entry_changed_common is not called when an entry loses
focus. Since this function is called on every keystroke, it was
unnecessary to call it again on focus-out-event.
- The EmpathyAccountWidget's control buttons' sensitivity (and
contains_pending_changes member) is not altered when the state of the
"Enabled" checkbox is changed due to an event which was not initiated
by the user.
- Fixed capitalization error in a comment in empathy-accounts-dialog.c
Jonathan Tellier [Wed, 26 Aug 2009 16:52:45 +0000 (12:52 -0400)]
Asking for confirmation before losing pending accounts changes.
If an account has pending changes, we now ask for a confirmation before:
- Adding a new account
- Closing the accounts dialog
- Selecting a new account.
Those are all options which discard pending changes.