tmp = nick.val().split(' ');
gateway.nick = tmp[0];
+
+ init_data.channel = $('#channel').val();
+
front.doLayout();
try {
front.run('/connect ' + netsel.val());
//$('#kiwi').bind("resize", front.doLayoutSize, false);
front.doLayout();
- //front.windowAdd('server');
front.tabviewAdd('server');
// Any pre-defined nick?
- if (typeof init_data.nick === "string") {
+ if (typeof window.init_data.nick === "string") {
$('#kiwi .formconnectwindow .nick').val(init_data.nick);
}
+
+ // Any pre-defined channels?
+ if (typeof window.init_data.channel === 'string') {
+ $('#channel').val(init_data.channel);
+ }
- //gateway.session_id = 'testses';
$('#kiwi .cur_topic').keydown(function (e) {
if (e.which === 13) {
switch (e.target.className) {
case 'link_ext':
+ case 'link_img_a':
return true;
break;
case 'link_ext_browser':
onNotice: function (e, data) {
var nick = (data.nick === undefined) ? '' : data.nick;
var enick = '[' + nick + ']';
-
+
if (front.tabviewExists(data.target)) {
front.tabviews[data.target.toLowerCase()].addMsg(null, enick, data.msg, 'notice');
} else if (front.tabviewExists(nick)) {
// Don't let any future plugins change it (ie. html_safe plugins)
event.event_bubbles = false;
- var img = '<img src="'+url+'" height="100%" width="100%" />';
+ var img = '<img class="link_img_a" src="'+url+'" height="100%" width="100%" />';
return '<a class="link_ext link_img" target="_blank" rel="nofollow" href="'+ url +'" style="height:50px;width:50px;display:block">'+ img +'<div class="tt box"></div></a>';
});
var chans = document.location.hash.match(/[#&]+[^ ,\\007]+/g);
if(chans != null && chans.length > 0) {
init_data.channel = chans.join(',');
- $('#channel').val(init_data.channel);
}
front.init();
function addEvents(){
$('.more_link').click(function(){ $('.content.bottom').slideDown('fast'); $('.network').focus(); return false; });
- $('.formconnectwindow').submit(function(){
- init_data.channel = $('#channel').val();
- return false;
- });
$('a.connect').click(function(){ $('.formconnectwindow').submit(); return false; });
}