1
0
mirror of https://github.com/moparisthebest/Yaaic synced 2024-11-13 12:35:06 -05:00
Commit Graph

814 Commits

Author SHA1 Message Date
Steven Luo
ffe73b7c9f Hold MessageListAdapters and MessageListViews in DeckAdapter to avoid leaks
There are at least two significant memory leaks in Yaaic, which cause
the client to force close after a few hours with an
OutOfMemoryException:

(1) The IRCService holds Conversation objects, which contain a
MessageListAdapter, which have references to the ConversationActivity
context.  This causes Activity contexts to outlast the Activity, causing
a significant memory leak over time.

Fix this by holding the MessageListAdapter in the ConversationActivity's
DeckAdapter instead of in the Conversation objects.  The DeckAdapter's
lifecycle matches that of the Activity, so this prevents the leak.

(2) Every call to DeckAdapter.getView()/renderConversation() creates a
new MessageListView and adds it to the deck.  But adding the view to
the deck causes the deck to take a reference to the view, leaking the
MessageListView until the Activity is finished.  (This has the effect of
exacerbating the first leak, since the Activity context holds a
reference to the deck.)

Fix this leak by caching MessageListViews in the DeckAdapter, and
returning an existing MessageListView for a Conversation in getView() if
one already exists.
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
464430ee74 Add FLAG_ACTIVITY_NEW_TASK to notification intents
According to
http://developer.android.com/reference/android/app/Notification.html#contentIntent
we should do this.  Suppresses a log message when tapping on our status
bar notification.
2011-06-08 23:11:27 +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
Steven Luo
f1b57c9e25 Don't scroll to a conversation in onCreate() unless it was previously selected
This has two advantages:
(1) The activity remembers which conversation was last selected if it's
    destroyed (e.g. via the Back button) and then recreated with the connection
    still running.
(2) It prevents onCreate() from clearing all the mentioned notifications for
    the conversations in that activity.
2011-06-08 23:11:27 +02:00
remram44
3102340762 Corrected CONTRIBUTORS list 2011-06-08 23:11:17 +02:00
Sebastian Kaspari
1201931de1 Updated CONTRIBUTORS list 2011-05-06 17:21:35 +02:00
Sebastian Kaspari
b4493b81a4 Add danish translation (By rasher) 2011-05-06 17:18:20 +02:00
Matt Mastracci
ac4fa4a104 Add _ to ident chars, update comment 2011-04-24 20:53:40 -06:00
remram44
322c4e0ac8 French translation updated 2011-04-17 05:36:37 +08:00
Sebastian Kaspari
daf07014f8 Update CHANGELOG 2011-04-15 22:05:27 +02:00
Sebastian Kaspari
c20cd695e6 Updated version number: Yaaic 0.8 2011-04-15 22:00:55 +02:00
Sebastian Kaspari
1e5f016012 DeckAdapter: getView(): If no conversation is available (anymore) for the requested position, return an empty TextView. Fixes #56. 2011-04-15 20:39:33 +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
c6dbe8cc18 Remove color codes if the mirc colors option is off. Fixes #57 2011-04-14 22:53:38 +02:00
Sebastian Kaspari
86e0812741 Ooops, fix @author javadoc tag in classes: MircColors, Smilies 2011-04-13 00:14:40 +02:00
Sebastian Kaspari
4e266e1bb7 ConversationActivity: onCreate(): Check if server is returned by getServerById() - Fixes #55 2011-04-12 23:44:39 +02:00
Sebastian Kaspari
9387a02068 ConversationActivity: onStatusUpdate(): Check if service is already connected and initialized - Fixes #54 2011-04-12 23:37:11 +02:00
Sebastian Kaspari
ded6485f6b Database: isTitleUsed(): Escape server title (SQLiteException) - Fixes #53 2011-04-12 23:30:00 +02:00
Sebastian Kaspari
b3fd4157dc JoinActivity: Set cursor position 2011-04-12 23:05:09 +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
Sebastian Kaspari
aa5a081c02 Bugfix: Remember new nickname on auto nickname change (433: Nickname is already in use) 2011-04-12 22:07:09 +02:00
José Antonio Pérez Sánchez
2b3ce5132a fixed missing angle in closing tag 2011-03-30 16:07:37 +02:00
Sebastian Kaspari
dbf7983eec Updated turkish translation 2011-03-27 22:23:39 +02:00
Sebastian Kaspari
b798d4dacb Setting mIRC colors off by default 2011-03-27 20:02:42 +02:00
Sebastian Kaspari
591dc8f763 MircColors/Smilies: Code formatting and documentation 2011-03-27 20:02:06 +02:00
Sebastian Kaspari
673598ad31 Added licence header to new files 2011-03-27 19:53:05 +02:00
liato
ac1a07894f Add support for graphical smilies in chat. 2011-03-27 19:51:47 +02:00
liato
92a1e93bc1 Use TextUtils.concat to concatenate 2011-03-27 19:43:51 +02:00
liato
7490cdb38c Change settings text for mirc colors. 2011-03-27 19:43:34 +02:00
liato
eea82e506f Rename Colors class and methods. 2011-03-27 19:42:47 +02:00
liato
2189d2c05f Remove tagsoup dependency. Improve mIRC color code parsing speed. 2011-03-27 19:42:05 +02:00
liato
7c4abe0c9c Render colors correctly in topics and other foreground colored places. 2011-03-27 19:41:13 +02:00
liato
59c70a750d Fix mirc color bug by changing the tagsoup schema and making the font tag restartable. 2011-03-27 19:40:47 +02:00
liato
624f8c5014 Add support for mIRC colors. 2011-03-27 19:40:26 +02:00
liato
e612d3b09c Render html in messages to spannables. 2011-03-27 19:37:35 +02:00
Sebastian Kaspari
bd19398d65 Added turkish translation (Thanks to Hasan Kiran) 2011-03-27 18:21:22 +02:00
Sebastian Kaspari
9b776aef15 Update CHANGELOG 2011-03-27 17:41:28 +02:00
Sebastian Kaspari
ba9f6c6544 Increment version number (0.7) 2011-03-27 17:28:22 +02:00
liato
1f9c8efcca Fix nullpointerexception. 2011-03-27 17:16:38 +02:00
liato
1ebea8f7d6 Use integer division to calculate gallert item width. 2011-03-27 17:13:09 +02:00
liato
b49ead73ad Fix width issues in gallery. 2011-03-27 17:10:54 +02:00
Sebastian Kaspari
7563437343 Server: Fix typo in addConversation() 2011-03-15 23:59:49 +01:00
Sebastian Kaspari
78a47ca17b dp/sp: More adjustments 2011-03-15 22:11:55 +01:00
Sebastian Kaspari
214a786175 useritem.xml: Use dp for padding and sp for fonts 2011-03-15 21:31:53 +01:00
Sebastian Kaspari
f44aea0d5e channelitem.xml: Use dp for padding and sp for fonts 2011-03-15 21:31:53 +01:00
Sebastian Kaspari
23ed9c3343 aliasitem.xml: Use dp for padding and sp for fonts 2011-03-15 21:31:53 +01:00
Sebastian Kaspari
4713c22655 useritem.xml: Replace px by sp/dp 2011-03-15 21:31:53 +01:00
Sebastian Kaspari
7e559f288e user.xml: Replace px by sp/dp 2011-03-15 21:31:53 +01:00
Sebastian Kaspari
f71e89e1ee serveritem.xml: Replace px by sp/dp 2011-03-15 21:31:53 +01:00