Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
6afb091d
Commit
6afb091d
authored
Mar 01, 2013
by
ichim-david
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cached available-chatrooms calls to avoid dom calls on updateRoomList
parent
18f877b5
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
converse.js
converse.js
+6
-5
No files found.
converse.js
View file @
6afb091d
...
...
@@ -732,17 +732,18 @@
xmppchat
.
connection
.
muc
.
listRooms
(
xmppchat
.
connection
.
muc_domain
,
$
.
proxy
(
function
(
iq
)
{
var
name
,
jid
,
i
,
rooms
=
$
(
iq
).
find
(
'
query
'
).
find
(
'
item
'
),
rooms_length
=
rooms
.
length
;
this
.
$el
.
find
(
'
#available-chatrooms
'
).
find
(
'
dd.available-chatroom
'
).
remove
();
rooms_length
=
rooms
.
length
,
$available_chatrooms
=
this
.
$el
.
find
(
'
#available-chatrooms
'
);
$available_chatrooms
.
find
(
'
dd.available-chatroom
'
).
remove
();
if
(
rooms
.
length
)
{
this
.
$el
.
find
(
'
#available-chatrooms
dt
'
).
show
();
$available_chatrooms
.
find
(
'
dt
'
).
show
();
}
else
{
this
.
$el
.
find
(
'
#available-chatrooms
dt
'
).
hide
();
$available_chatrooms
.
find
(
'
dt
'
).
hide
();
}
for
(
i
=
0
;
i
<
rooms_length
;
i
++
)
{
name
=
Strophe
.
unescapeNode
(
$
(
rooms
[
i
]).
attr
(
'
name
'
));
jid
=
$
(
rooms
[
i
]).
attr
(
'
jid
'
);
this
.
$el
.
find
(
'
#available-chatrooms
'
)
.
append
(
this
.
room_template
({
'
name
'
:
name
,
'
jid
'
:
jid
}));
$available_chatrooms
.
append
(
this
.
room_template
({
'
name
'
:
name
,
'
jid
'
:
jid
}));
}
return
true
;
},
this
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment