Commit Graph

38 Commits

Author SHA1 Message Date
Daniel E. Moctezuma 3f8578ef73 Replaced lowercase letters by uppercase ones on application name 2012-10-04 19:15:18 +02:00
Sebastian Kaspari 21032950b7 Update copright line (2009-2012). 2012-01-21 23:12:55 +01:00
Steven Luo d80f4133f1 Ack new mentions on part or kick from a channel
If we don't do this, the user is left with a new message notification
she can't clear, and we leak the Channel object.
2011-07-03 14:03:41 +02:00
Darren Salt 2759b00084 Add an informational message for when the MOTD is ignored. 2011-07-02 19:51:32 +02:00
Darren Salt 23ca120f0e Only ignore the MOTD once. 2011-07-02 19:49:19 +02:00
Steven Luo e7651315df Make reconnections actually work
At the moment, the reconnect feature is somewhat glitchy, popping up
multiple reconnect prompts even if a reconnection succeeds, and
occasionally causing crashes.  A successful reconnection results in the
conversation history being cleared, which is an annoying outcome when
connected over an unreliable network.

This patch does the following:

* Keep track of whether a reconnect dialog is active, to prevent
  multiple dialogs from opening.
* Introduce a new field to the Server object, mayReconnect, which is
  used to keep track of whether a reconnection should be attempted in
  the event of a disconnection.  It's set to "true" when we connect to a
  server, and "false" if the user asks for a disconnection.
* Prevent the clearing of active conversations and conversation history
  on disconnect, unless the user specifically asked for the disconnect.
* Keep the IRCService running even when no servers are connected, unless
  the user has disconnected from all servers herself.  This is needed
  for reliable auto-reconnects (see next patch), but has the side effect
  of keeping conversation history around even if the activity isn't open
  when a disconnect happens.
2011-06-29 20:34:52 +02:00
Sebastian Kaspari 6e48a29b34 Display message at the beginning and end of the server login 2011-06-10 22:29:17 +02:00
Sebastian Kaspari d9d1c4aba8 (Authentication) Implementation of authentication via NickServ on connect 2011-06-10 21:36:14 +02:00
Steven Luo aaf3f3e332 Prevent race between IRCConnection dispose() and onDisconnect() when quitting
When the user asks for a disconnect from the ConversationActivity, there
is a race between the IRCConnection, which is waiting for the server to
acknowledge the QUIT before calling onDisconnect(), and the IRCService,
which will invoke dispose() on the IRCConnection when
checkServiceStatus() is called during the activity shutdown.  If the
dispose() wins, the thread running the onDisconnect() is terminated,
leading to the cleanup being unfinished.  This causes the disconnect
notification to be unreliable, and can result in the list of servers in
the ongoing notification to be out of sync with reality.

To fix this, introduce a new field isQuitting to the IRCConnection,
which is set to true when quitServer() is called and cleared once
onDisconnect() has finished.  If dispose() is called while isQuitting is
set, it sets disposeRequested instead of doing the dispose itself, and
onDisconnect() will call through to super.dispose() once it's finished.

Note that this requires a change to PircBot to allow the overriding of
quitServer(String message), which is declared final upstream.
2011-06-08 23:11:29 +02:00
Steven Luo dc95472aaf Fix broadcast on topic change 2011-06-08 23:11:28 +02:00
Steven Luo 06e0849c17 Bugfix notification system
* If there's a new message notification, keep showing the "New messages
   in" content text, even after a disconnect notification.
 * Handle the case of a channel/query name duplicated between two or more
   connections more gracefully in new message notifications
 * Fix a race in updating notifications
2011-06-08 23:11:28 +02:00
Steven Luo 91d211c51d Make the conversation history size a configurable preference 2011-06-08 23:11:28 +02:00
Steven Luo 61960c9add Overhaul notifications system
Features:
* Now displays the number of mentions that the user has not seen in the
  notification.
* When no mentions are outstanding, display which servers the user is
  connected to, not the last message.
* When more than one mention is outstanding, display the names of the
  conversations with new mentions, not just the last message received.
* Notifications of mentions are suppressed if you're in the conversation
  at the time of the mention.
* Notifications of mentions automatically clear when you bring up the
  conversation.
* Vibrate notifications now generate the user's chosen default vibrate
  pattern, not a hard-coded one.
* Add ticker text to the notification that's displayed when the IRCService
  goes into the foreground, instead of displaying a blank ticker.

To allow for all of this, the implementation moves most of the details
of generating the notification text into the IRCService, which now
exposes addNewMention() and notifyConnected()/notifyDisconnected()
methods instead of the lower-level updateNotification().
2011-06-08 23:11:28 +02:00
Steven Luo 09fedc6975 Include channel topic in the displayed conversation title 2011-06-08 23:11:28 +02:00
Steven Luo 9a8bf44d63 Do something sane for private messages where the sender is our nick
As of now, private messages where the sender is our nick end up in
a query window targeted at us.  Show these messages in the query window
of the target instead, which is probably what we want.

This is useful for use with irssi proxy, which will send messages sent
by another client attached to the proxy to us in this way.

(Note that this patch makes a change to PircBot to pass the target of a
private message to the onPrivateMessage handler.)
2011-06-08 23:11:28 +02:00
Steven Luo c9ed28767d Actually deliver actions to existing private message windows 2011-06-08 23:11:28 +02:00
Steven Luo c4504be725 Notify the user on receipt of all private messages, not just ones with nick mentions
You'd rarely use someone's nick in a privmsg with them, and this matches
the behavior of other clients.
2011-06-08 23:11:28 +02:00
Steven Luo caf3272f71 Ensure privmsg with mention of user's nick opens new query when appropriate
If a private message that should open a new query window contains a
mention of the user's nick, the expected new window fails to open
because the isMentioned() path tries to use
server.getConversation().setStatus(), and server.getConversation() is
null in this case.  Fix this by moving the attempt to highlight the
window to a point where a conversation is guaranteed to exist.
2011-06-08 23:11:27 +02:00
Sebastian Kaspari 50a6047edd On own nick change: Display message in server info window (Your are now known as ...). Fixes #51. 2011-04-15 20:30:46 +02:00
Sebastian Kaspari dd07bd358a Bugfix: Only automatically change nickname on server code 433 if not already registered with server 2011-04-12 22:23:51 +02:00
liato 624f8c5014 Add support for mIRC colors. 2011-03-27 19:40:26 +02:00
Sebastian Kaspari 7563437343 Server: Fix typo in addConversation() 2011-03-15 23:59:49 +01:00
Sebastian Kaspari 4262cbcd15 New Setting: Show notices in server window. Closes #47. 2011-03-15 20:53:47 +01:00
Sebastian Kaspari b855b7ea92 Hide join/part setting now hides quit messages too 2011-03-15 20:42:35 +01:00
Sebastian Kaspari 49f067cd67 IRCConnection: Formatting 2011-03-15 20:12:12 +01:00
Sebastian Kaspari 95f3c4b255 Some more simple refactorings 2011-03-14 22:15:13 +01:00
liato a3ebf8d5d0 Handle auto joins after the user has registered with the server. 2011-03-09 08:54:28 +01:00
Thomas Martitz f4637ac582 Use a different color for join/part/quit for the circles in the ConversationSwitcher view.
This makes it easier to ignore unintersting messages wihout turning off the setting to show joins/parts/quits.
Once circle is colored for a new message, the join/part/quit cannot override it anymore.
2011-03-06 11:11:17 +01:00
Sebastian Kaspari 669113610a New user action view and new actions: reply, query 2011-02-05 16:04:36 +01:00
Sebastian Kaspari d8b1a0218f Added 2011 to licence header 2011-02-05 13:00:12 +01:00
Sebastian Kaspari e014165a17 New setting: Play (notification) sound on highlight 2010-12-17 22:29:33 +01:00
Sebastian Kaspari 82e62db96c New setting: Hide join and part messages 2010-11-18 19:25:26 +01:00
Sebastian Kaspari 6c3597ff80 IRCConnection: Just a bracket fix 2010-11-18 18:55:19 +01:00
Sebastian Kaspari 02b7ec1741 Replace all tabs with four spaces! 2010-11-18 18:52:19 +01:00
liato 3708a9c60c Small modification to the nick matching regular expression. 2010-11-17 02:53:08 +01:00
liato f5b5b99adb Improve detection for nickname in messages. This will prevent notifications from poping up when a word contains the nickname. 2010-11-17 02:36:52 +01:00
liato 81f2c94b87 Added setting to vibrate on highlight. 2010-11-17 01:32:09 +01:00
Sebastian Kaspari 1250c10d9c Merged application and test project into one repository 2010-11-07 08:35:45 +01:00