1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-07-03 01:28:30 +00:00

3.5.182. I forgot to commit a bit again. D: Removed FFZ from two-factor auth dialogs / pages. Added option to always expand the player volume slider. Revamped ban notices to be nicer. Status indicator for emoteonly-mode. Fixed /ffz reload command. Update to the latest FileSaver.js. Make high contrast compatible with BTTV. Conversations fixes. Better BTTV dark theme detection.

This commit is contained in:
SirStendec 2016-05-20 17:30:34 -04:00
parent 6cf5ddc734
commit 4af0c3480c
19 changed files with 378 additions and 262 deletions

View file

@ -37,7 +37,7 @@ FFZ.msg_commands = {};
// Version
var VER = FFZ.version_info = {
major: 3, minor: 5, revision: 176,
major: 3, minor: 5, revision: 182,
toString: function() {
return [VER.major, VER.minor, VER.revision].join(".") + (VER.extra || "");
}
@ -172,6 +172,7 @@ require('./ext/emote_menu');
require('./featurefriday');
//require('./ui/chatpane');
require('./ui/popups');
require('./ui/styles');
require('./ui/dark');
@ -201,32 +202,24 @@ FFZ.prototype.initialize = function(increment, delay) {
// Make sure that FrankerFaceZ doesn't start setting itself up until the
// Twitch ember application is ready.
// Pages we don't want to interact with at all.
if ( location.hostname === 'passport.twitch.tv' || /^\/user\/two_factor/.test(location.pathname) ) {
this.log("Found authentication sub-page. Not initializing.");
return;
}
// Check for the player
if ( location.hostname === 'player.twitch.tv' ) {
this.init_player(delay);
return;
}
// Check for the transfer page.
if ( location.pathname === "/crossdomain/transfer" ) {
if ( location.hash.indexOf("ffz-settings-transfer") !== -1 )
this.init_settings_transfer();
return;
}
// Check for special non-ember pages.
if ( /^\/(?:$|search$|user\/|p\/|settings|m\/|messages?\/)/.test(location.pathname) ) {
this.init_normal(delay);
return;
}
if ( location.hostname === 'passport' && /^\/(?:authorize)/.test(location.pathname) ) {
this.log("Running on passport!");
this.init_normal(delay, true);
return;
}
// Check for the dashboard.
if ( /\/[^\/]+\/dashboard/.test(location.pathname) && !/bookmarks$/.test(location.pathname) ) {
this.init_dashboard(delay);
@ -248,16 +241,6 @@ FFZ.prototype.initialize = function(increment, delay) {
}
FFZ.prototype.init_settings_transfer = function() {
this.log("This is the HTTP Transfer URL. Building a settings backup and posting it to our parent.");
this.load_settings();
try { this.setup_line(); } catch(err) { }
var msg = {from_ffz: true, command: "http_settings", data: this._get_settings_object()};
window.opener.postMessage(msg, "https://www.twitch.tv");
window.close();
}
FFZ.prototype.init_player = function(delay) {
var start = (window.performance && performance.now) ? performance.now() : Date.now();
this.log("Found Twitch Player after " + (delay||0) + " ms at: " + location);