Commit Graph

27 Commits

Author SHA1 Message Date
JC Brand
946e9fed5d Add new MUC option auto_join_rooms.
Fixes #156
2016-03-22 08:15:52 +00:00
JC Brand
fc7f50887a Refactored MUC plugin to not have to override ChatBoxes collection.
Instead we use event handlers.
2016-03-22 07:49:25 +00:00
JC Brand
2d846961c2 Use 'type' = 'chatroom' instead of 'chatroom' boolean. 2016-03-21 10:00:15 +00:00
JC Brand
82aa9fec2c Support for showing headline messages. 2016-03-21 10:00:10 +00:00
JC Brand
8e18d736b4 fixed indentation of comments 2016-03-19 22:16:00 +00:00
JC Brand
a2b8d04d84 Move config settings to the relevant plugins 2016-03-18 08:12:23 +00:00
JC Brand
6618d694b1 No need to override ChatBoxView with MUC-specific method 2016-03-16 09:03:00 +00:00
JC Brand
2fa39f2150 Move dependencies to the plugins that actually use them 2016-03-16 09:02:12 +00:00
JC Brand
9d9f64b2c3 declare namespace in relevant plugin 2016-03-14 16:46:04 +00:00
JC Brand
7039dbe01b Move chat minimization to a separate plugin 2016-03-14 16:38:43 +00:00
JC Brand
fc251db59e Let MUC plugin override the chatbox wrapper. 2016-03-14 16:02:43 +00:00
JC Brand
1676258c38 Move the MAM features to a separate plugin. 2016-03-14 14:04:36 +00:00
JC Brand
fe47773c7f Move ChatView into separate plugin. 2016-03-14 14:04:36 +00:00
JC Brand
8b459c68b1 Call trimChats in the show method of the box view
Not in the onAdded handler.
2016-03-09 11:03:06 +00:00
JC Brand
0aa0c02124 Add tests for src/converse-notification.js. updates #443
In the process refactored the code being tested.

- Move notifications code in MUC to src/converse-notification.js
- Trigger the 'contactStatusChanged' event in RosterContact and not in
  ChatBoxView (which might not exist).
2016-03-08 10:44:27 +00:00
JC Brand
23a1dc4f2b Some fixes concerning event emitting.
Don't make the event "this" context the protected converse object.
Can't trigger multiple data parameters, need to pass an object if there are
multiple values to be sent.
2016-03-01 22:39:45 +00:00
JC Brand
9cce0ff6ae Add plugin settings to default settings.
So that they are retrievable via the API.
2016-03-01 08:57:57 +00:00
JC Brand
cd731ed699 Some refactoring to make plugins easier.
- Refactored sound notification to make it a bit more generic
- Split up onMessage
2016-02-29 20:54:34 +00:00
JC Brand
dcd090ff31 Rip out the controlbox code and put it in src/converse-controlbox.js
Also fixed an issue w.r.t the plugin architecture. Previously infinite
recursion would happen when more than one plugin was overriding a method.

Resolved now by using a wrapper function that lazily sets the correct super
method.
2016-02-29 16:40:51 +00:00
JC Brand
9ae2f71747 Found more chatroom specific code in converse-core.js 2016-02-29 16:40:51 +00:00
JC Brand
9f9b38f852 Some i18n fixes
The __ translate method should only be run *after* converse.js has been
initialized and we know what the actual desired language is

Also fix bug in src/locales.js where wrong langs were assigned to wrong keys.
2016-02-28 08:45:36 +00:00
JC Brand
e79c204241 Refactor the API out into a separate module, src/convers-api.js
Plugins are now also updated so that they can get the closured converse object
directly and don't need to rely on _super.
2016-02-20 15:06:12 +00:00
JC Brand
cb241dd594 Moved all the registration code into a plugin 2016-02-19 10:43:46 +00:00
JC Brand
147a3c9e3e Found more MUC stuff in core.
Move the Occupants views and models to converse-muc.js as well as some
MUC-specific config variables.
2016-02-19 09:45:24 +00:00
rlanvin
00caccd1a3 Fix non_amd.html
- converse-muc.js was overriding the global "converse" variable
  with undefind (the factory function didn't return anything)
- locales was not defined in utils.js in non AMD (not passed in
  the factory function)
2016-02-17 10:04:46 +02:00
JC Brand
9eba9989dc OTR stuff has been moved to a component/plugin in src/converse-otr.js
Also fixed errors with converse obj not being defined in the MUC plugin.
2016-02-16 07:47:16 +00:00
JC Brand
576efc4815 Initial work on breaking converse.js up into components
First component to remove is MUC which was moved to src/converse-muc.js
The components are written as plugins and use converse.js's plugin machinery.

Update the plugin docs somewhat with new insites found while working on the muc
plugin.
2016-02-16 07:47:08 +00:00