Skip to content

Commit

Permalink
1.7
Browse files Browse the repository at this point in the history
RELEASE
repalced mainworker with the unobfuscated line from 1.6 tag release

removed console.*

set cache key to v1.7
  • Loading branch information
Noitidart committed Apr 11, 2016
1 parent bebf882 commit d2f73dd
Show file tree
Hide file tree
Showing 12 changed files with 444 additions and 444 deletions.
26 changes: 13 additions & 13 deletions app/js/app_main.js
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ function templatedDataCaption(aTypeInt, aTitle, aSubtitle, aGettime, aImgSrc, aS
}

function nsOnFocus() {
console.log('focused');

readHistoryLog(function() {
updateCountsToSkillBars();
matchIsotopeContentsToFileJson(true);
Expand Down Expand Up @@ -286,7 +286,7 @@ function nsInitPage(aPostNonSkelInit_CB) {

}

console.log('servicesInfosReact:', servicesInfosReact);

servicesInfosReact.sort(function(a, b) {
return compareAlphaNumeric(a.serviceTitle, b.serviceTitle); // sort asc
});
Expand Down Expand Up @@ -429,7 +429,7 @@ var ServicesFilterRow = React.createClass({
cFilterBtns.push(React.createElement(ServiceFilterBtn, {pServiceName:'all', pServiceTitle:core.addon.l10n.app_main.title_all, sActiveFilter:this.props.sActiveFilter}));

var cServicesInfos = this.props.pServicesInfos;
console.log('cServicesInfos:', cServicesInfos);

for (var i=0; i<cServicesInfos.length; i++) {
var cServiceInfoEntry = cServicesInfos[i];
if (cServiceInfoEntry.hasAssociatedImgs) {
Expand Down Expand Up @@ -480,8 +480,8 @@ var ServicesSummaryCol = React.createClass({
// sServicesLogEntryCnts
// sActiveFilter

// console.log('pServicesInfosGroup:', this.props.pServicesInfosGroup);
// console.log('sServicesLogEntryCnts:', this.props.sServicesLogEntryCnts);



var cChildren = [];

Expand Down Expand Up @@ -1032,7 +1032,7 @@ function doOnBeforeUnload() {
}

function doOnContentLoad() {
console.log('in doOnContentLoad');

initPage();
}

Expand Down Expand Up @@ -1101,7 +1101,7 @@ var bootstrapMsgListener = {
funcScope: bootstrapCallbacks,
receiveMessage: function(aMsgEvent) {
var aMsgEventData = aMsgEvent.data;
console.log('framescript getting aMsgEvent, unevaled:', uneval(aMsgEventData));

// aMsgEvent.data should be an array, with first item being the unfction name in this.funcScope

var callbackPendingId;
Expand All @@ -1122,12 +1122,12 @@ var bootstrapMsgListener = {
contentMMFromContentWindow_Method2(content).sendAsyncMessage(core.addon.id, [callbackPendingId, aVal]);
},
function(aReason) {
console.error('aReject:', aReason);

contentMMFromContentWindow_Method2(content).sendAsyncMessage(core.addon.id, [callbackPendingId, ['promise_rejected', aReason]]);
}
).catch(
function(aCatch) {
console.error('aCatch:', aCatch);

contentMMFromContentWindow_Method2(content).sendAsyncMessage(core.addon.id, [callbackPendingId, ['promise_rejected', aCatch]]);
}
);
Expand All @@ -1137,7 +1137,7 @@ var bootstrapMsgListener = {
}
}
}
else { console.warn('funcName', funcName, 'not in scope of this.funcScope') } // else is intentionally on same line with console. so on finde replace all console. lines on release it will take this out


}
};
Expand Down Expand Up @@ -1196,7 +1196,7 @@ function genericReject(aPromiseName, aPromiseToReject, aReason) {
name: aPromiseName,
aReason: aReason
};
console.error('Rejected - ' + aPromiseName + ' - ', rejObj);

if (aPromiseToReject) {
aPromiseToReject.reject(rejObj);
}
Expand All @@ -1206,7 +1206,7 @@ function genericCatch(aPromiseName, aPromiseToReject, aCaught) {
name: aPromiseName,
aCaught: aCaught
};
console.error('Caught - ' + aPromiseName + ' - ', rejObj);

if (aPromiseToReject) {
aPromiseToReject.reject(rejObj);
}
Expand All @@ -1217,7 +1217,7 @@ function validateOptionsObj(aOptions, aOptionsDefaults) {
// ensures no invalid keys are found in aOptions, any key found in aOptions not having a key in aOptionsDefaults causes throw new Error as invalid option
for (var aOptKey in aOptions) {
if (!(aOptKey in aOptionsDefaults)) {
console.error('aOptKey of ' + aOptKey + ' is an invalid key, as it has no default value, aOptionsDefaults:', aOptionsDefaults, 'aOptions:', aOptions);

throw new Error('aOptKey of ' + aOptKey + ' is an invalid key, as it has no default value');
}
}
Expand Down
48 changes: 24 additions & 24 deletions app/js/app_options.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ function nsInitPage(aPostNonSkelInit_CB) {
var do_step2 = function() {
// refresh prefs in bootstrap core object - as source of truth for prefs is in bootstrap
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['refreshCoreForPrefs']], bootstrapMsgListener.funcScope, function(aCoreAddonPrefs) {
console.log('aCoreAddonPrefs:', aCoreAddonPrefs);

core.addon.prefs = aCoreAddonPrefs;
do_step3();
});
Expand All @@ -39,7 +39,7 @@ function nsInitPage(aPostNonSkelInit_CB) {
function nsOnFocus() {
// refresh prefs in bootstrap core object
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['refreshCoreForPrefs']], bootstrapMsgListener.funcScope, function(aCoreAddonPrefs) {
console.log('aCoreAddonPrefs:', aCoreAddonPrefs);

core.addon.prefs = aCoreAddonPrefs;
refreshGDOMState();
MyStore.setState({
Expand Down Expand Up @@ -171,12 +171,12 @@ var gDOMStructureCallbacks = {
return (!aBlockState.value ? core.addon.l10n.app_options.on : core.addon.l10n.app_options.off);
},
'callback:quickdir-reset-hidden': function(aBlockState) {
console.error('aBlockState.value:', aBlockState.value, 'core.addon.prefs.quick_save_dir.defaultValue:', core.addon.prefs.quick_save_dir.defaultValue);

if (aBlockState.value == core.addon.prefs.quick_save_dir.defaultValue) {
console.log('euqla so hide');

return true;
} else {
console.log('mismatch so show');

return false;
}
},
Expand All @@ -195,7 +195,7 @@ var gDOMStructureCallbacks = {
},
'callback:printprev-toggle-click': function() {
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['prefSet', 'print_preview', !core.addon.prefs.print_preview.value]], bootstrapMsgListener.funcScope, function(aCorePrefNameObj) {
console.log('pref set:', aCorePrefNameObj); // on fail bootstrap funciton throws so it will never get here

core.addon.prefs.print_preview = aCorePrefNameObj;
refreshGDOMState();
MyStore.setState({
Expand All @@ -206,7 +206,7 @@ var gDOMStructureCallbacks = {
'callback:systemhotkey-toggle-click': function() {
var newPrefValue = !core.addon.prefs.system_hotkey.value;
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['prefSet', 'system_hotkey', !core.addon.prefs.system_hotkey.value]], bootstrapMsgListener.funcScope, function(aCorePrefNameObj) {
console.log('pref set:', aCorePrefNameObj); // on fail bootstrap funciton throws so it will never get here

core.addon.prefs.system_hotkey = aCorePrefNameObj;
refreshGDOMState();
MyStore.setState({
Expand All @@ -221,7 +221,7 @@ var gDOMStructureCallbacks = {
},
'callback:autoup-toggle-click': function() {
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['prefSet', 'autoupdate', !core.addon.prefs.autoupdate.value]], bootstrapMsgListener.funcScope, function(aCorePrefNameObj) {
console.log('pref set:', aCorePrefNameObj); // on fail bootstrap funciton throws so it will never get here

core.addon.prefs.autoupdate = aCorePrefNameObj;
refreshGDOMState();
MyStore.setState({
Expand All @@ -233,7 +233,7 @@ var gDOMStructureCallbacks = {

var do_setPref = function(aDirPlatPath) {
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['prefSet', 'quick_save_dir', aDirPlatPath]], bootstrapMsgListener.funcScope, function(aCorePrefNameObj) {
console.log('pref set:', aCorePrefNameObj); // on fail bootstrap funciton throws so it will never get here

core.addon.prefs.quick_save_dir = aCorePrefNameObj;
refreshGDOMState();
MyStore.setState({
Expand All @@ -243,15 +243,15 @@ var gDOMStructureCallbacks = {
};

sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['browseFile', core.addon.l10n.app_options.change_dir_dialog_title, {mode:'modeGetFolder', async:true}]], bootstrapMsgListener.funcScope, function(aDirPlatPath) {
console.log('aDirPlatPath:', aDirPlatPath);

if (aDirPlatPath && aDirPlatPath != core.addon.prefs.quick_save_dir.value) {
do_setPref(aDirPlatPath);
}
});
},
'callback:quickdir-reset-click': function() {
sendAsyncMessageWithCallback(contentMMFromContentWindow_Method2(window), core.addon.id, ['callInBootstrap', ['prefSet', 'quick_save_dir', core.addon.prefs.quick_save_dir.defaultValue]], bootstrapMsgListener.funcScope, function(aCorePrefNameObj) {
console.log('pref set:', aCorePrefNameObj); // on fail bootstrap funciton throws so it will never get here

core.addon.prefs.quick_save_dir = aCorePrefNameObj;
refreshGDOMState();
MyStore.setState({
Expand All @@ -263,7 +263,7 @@ var gDOMStructureCallbacks = {

function getObjKeyVal(aObj, aKey, aState) { // react components uses this only for non-click callbacks
if (aKey == 'hidden') {
console.error('doing getObjKeyVal on aObj:', aObj, 'aKey:', aKey, 'aState:', aState);

}
if (aKey in aObj) {
var cVal = aObj[aKey];
Expand Down Expand Up @@ -390,7 +390,7 @@ var Block = React.createClass({

var cBlockDescs = [];
var cDescs = this.props.pBlock.descs;
console.error('cDescs:', cDescs);

for (var i=0; i<cDescs.length; i++) {
cBlockDescs.push(React.createElement('li', {},
cDescs[i]
Expand All @@ -399,15 +399,15 @@ var Block = React.createClass({

var cBlockBtns = [];
var cBtns = this.props.pBlock.btns;
// console.log('cBtns:', cBtns);

for (var i=0; i<cBtns.length; i++) {
var cBtnHidden = getObjKeyVal(cBtns[i], 'hidden', this.props.sBlockValue);
console.error('cBtnHidden:', cBtnHidden);

if (!cBtnHidden) {
cBlockBtns.push(React.createElement(Button, {sBlockValue:this.props.sBlockValue, pBtn:cBtns[i]}));
}
}
console.log('cBlockBtns:', cBlockBtns);


// add space between the cBtns if there is more than 1
// so [1, 2] becomes Array [ 1, " ", 2 ]
Expand Down Expand Up @@ -524,7 +524,7 @@ function doOnBeforeUnload() {
}

function doOnContentLoad() {
console.log('in doOnContentLoad');

initPage();
}

Expand Down Expand Up @@ -593,7 +593,7 @@ var bootstrapMsgListener = {
funcScope: bootstrapCallbacks,
receiveMessage: function(aMsgEvent) {
var aMsgEventData = aMsgEvent.data;
console.log('framescript getting aMsgEvent, unevaled:', uneval(aMsgEventData));

// aMsgEvent.data should be an array, with first item being the unfction name in this.funcScope

var callbackPendingId;
Expand All @@ -614,12 +614,12 @@ var bootstrapMsgListener = {
contentMMFromContentWindow_Method2(content).sendAsyncMessage(core.addon.id, [callbackPendingId, aVal]);
},
function(aReason) {
console.error('aReject:', aReason);

contentMMFromContentWindow_Method2(content).sendAsyncMessage(core.addon.id, [callbackPendingId, ['promise_rejected', aReason]]);
}
).catch(
function(aCatch) {
console.error('aCatch:', aCatch);

contentMMFromContentWindow_Method2(content).sendAsyncMessage(core.addon.id, [callbackPendingId, ['promise_rejected', aCatch]]);
}
);
Expand All @@ -629,7 +629,7 @@ var bootstrapMsgListener = {
}
}
}
else { console.warn('funcName', funcName, 'not in scope of this.funcScope') } // else is intentionally on same line with console. so on finde replace all console. lines on release it will take this out


}
};
Expand Down Expand Up @@ -688,7 +688,7 @@ function genericReject(aPromiseName, aPromiseToReject, aReason) {
name: aPromiseName,
aReason: aReason
};
console.error('Rejected - ' + aPromiseName + ' - ', rejObj);

if (aPromiseToReject) {
aPromiseToReject.reject(rejObj);
}
Expand All @@ -698,7 +698,7 @@ function genericCatch(aPromiseName, aPromiseToReject, aCaught) {
name: aPromiseName,
aCaught: aCaught
};
console.error('Caught - ' + aPromiseName + ' - ', rejObj);

if (aPromiseToReject) {
aPromiseToReject.reject(rejObj);
}
Expand All @@ -709,7 +709,7 @@ function validateOptionsObj(aOptions, aOptionsDefaults) {
// ensures no invalid keys are found in aOptions, any key found in aOptions not having a key in aOptionsDefaults causes throw new Error as invalid option
for (var aOptKey in aOptions) {
if (!(aOptKey in aOptionsDefaults)) {
console.error('aOptKey of ' + aOptKey + ' is an invalid key, as it has no default value, aOptionsDefaults:', aOptionsDefaults, 'aOptions:', aOptions);

throw new Error('aOptKey of ' + aOptKey + ' is an invalid key, as it has no default value');
}
}
Expand Down
Loading

0 comments on commit d2f73dd

Please sign in to comment.