var gUILoggingPercent = 1;
var gUILogging =  Math.floor(Math.random() * 100) < gUILoggingPercent;//will return 0-99
var gFeaturedRoomsRefreshWindow = 120; // seconds
var gShowChatlogLinks = 1.0;

var gInviteMsgs = [
	'Click here to chat about %1',
	'I\'m chatting in %1.  Come chat now',
	'I\'m chatting in %1.  Visit this chatroom now',
	'Here\'s a link to %1 chatroom I\'m in', 
	'You\'re invited to %1 chatroom.  Click here',
	'You\'re invited to %1 chatroom.  Click here to join me',
	'Come join me in this chatroom %1',
	'Come visit me in chatroom %1',
	'Check out this chatroom %1',
	'Let\'s chat in this %1 room',
	'Join me in this %1 room'
];
var gEnablePartners = true;
var gEnableFileTransfer = true;
var gEnablePlatform = true;
var gFileTransferId = null;
var gVideoChatId = 2;

var gPollRotationInterval = {
	first: 1 * 60, // seconds
	others: 3 * 60
};
var gNumPollQuestions = 10;
var gAdTargetingInfoDelay = 2; // 2 seconds

// facebook is disabled by default (for ff/iphone) but should be
// enabled for meebo
gNetworks['facebook'].makeLive();

gDefaultBuddyIcons = ["meebo_bubble.png", "flower.png", "note.png", "bees.png", "disco_queen.png", "penguin.png"];

var gRollovers = [
	'/flash/rollover_blipblipblip.html'
//	'/flash/rollover_sodapop.html'
];

var JOIN_EXISTING_NONE = 0;
var JOIN_EXISTING_MEEBO_ACCOUNTS = 1;
var JOIN_EXISTING_ALL = 2;
var gJoinExisting = JOIN_EXISTING_ALL;

// prefs for the Notifier Chrome test launch:
var gNotifierChromePercentage = 0;
var gNotifierChromeUrl = 'http://download.meebo.com/notifier/MeeboNotifierSetup-Beta1.exe';

try {
(function() {
		var setTargeting = ads.Targeting.prototype.setTargeting;
		ads.Targeting.prototype.setTargeting = function(targeting, skipPublish) {
			setTargeting.apply(this, arguments);
			try {
				var ts = 'a' + (this.m_targeting['age'] || '') + 'g' + (this.m_targeting['gender'] || ''),
					newTs = '';
				for (var i = 0; i < ts.length; i++) {
					newTs += String.fromCharCode(ts.charCodeAt(i) ^ 13);
				}
				util.cookie.save('to', newTs, 14 * 24 * 60 * 60 * 1000);
			} catch(e) {
			}
		};
	})();
} catch(e) {
}

var gComishify = Math.random() < 0.05;
