kopia lustrzana https://github.com/backface/turtlestitch
adjust block to no longer use strings, and remove unneeded code
rodzic
ede60eec56
commit
ccce2c9ac7
44
lang-de.js
44
lang-de.js
|
@ -1248,45 +1248,7 @@ SnapTranslator.dict.de = {
|
||||||
'beliebiges',
|
'beliebiges',
|
||||||
|
|
||||||
// Date reporter dropdowns
|
// Date reporter dropdowns
|
||||||
'Month':
|
'month':
|
||||||
'Monat',
|
'monat',
|
||||||
// Months of the Year
|
|
||||||
'January':
|
|
||||||
'Januar',
|
|
||||||
'February':
|
|
||||||
'Februar',
|
|
||||||
'March':
|
|
||||||
'März',
|
|
||||||
'April':
|
|
||||||
'April',
|
|
||||||
'May':
|
|
||||||
'Mai',
|
|
||||||
'June':
|
|
||||||
'Juni',
|
|
||||||
'July':
|
|
||||||
'Juli',
|
|
||||||
'August':
|
|
||||||
'August',
|
|
||||||
'September':
|
|
||||||
'September',
|
|
||||||
'October':
|
|
||||||
'Oktober',
|
|
||||||
'November':
|
|
||||||
'November',
|
|
||||||
'December':
|
|
||||||
'Dezember',
|
|
||||||
'Sunday':
|
|
||||||
'Sonntag',
|
|
||||||
'Monday':
|
|
||||||
'Montag',
|
|
||||||
'Tuesday':
|
|
||||||
'Dienstag',
|
|
||||||
'Wednesday':
|
|
||||||
'Mittwoch',
|
|
||||||
'Thursday':
|
|
||||||
'Donnerstag',
|
|
||||||
'Friday':
|
|
||||||
'Freitag',
|
|
||||||
'Saturday':
|
|
||||||
'Samstag',
|
|
||||||
};
|
};
|
||||||
|
|
43
lang-fr.js
43
lang-fr.js
|
@ -1163,46 +1163,7 @@ SnapTranslator.dict.fr = {
|
||||||
'n\u0027importe quel',
|
'n\u0027importe quel',
|
||||||
|
|
||||||
// Date reporter dropdowns
|
// Date reporter dropdowns
|
||||||
'Month':
|
'month':
|
||||||
'mois',
|
'mois'
|
||||||
// Months of the Year
|
|
||||||
'January':
|
|
||||||
'janvier',
|
|
||||||
'February':
|
|
||||||
'février',
|
|
||||||
'March':
|
|
||||||
'mars',
|
|
||||||
'April':
|
|
||||||
'avril',
|
|
||||||
'May':
|
|
||||||
'mai',
|
|
||||||
'June':
|
|
||||||
'juin',
|
|
||||||
'July':
|
|
||||||
'juillet',
|
|
||||||
'August':
|
|
||||||
'août',
|
|
||||||
'September':
|
|
||||||
'septembre',
|
|
||||||
'October':
|
|
||||||
'octobre',
|
|
||||||
'November':
|
|
||||||
'novembre',
|
|
||||||
'December':
|
|
||||||
'decembre',
|
|
||||||
'Sunday':
|
|
||||||
'dimanche',
|
|
||||||
'Monday':
|
|
||||||
'lundi',
|
|
||||||
'Tuesday':
|
|
||||||
'mardi',
|
|
||||||
'Wednesday':
|
|
||||||
'mercredi',
|
|
||||||
'Thursday':
|
|
||||||
'jedui',
|
|
||||||
'Friday':
|
|
||||||
'vendredi',
|
|
||||||
'Saturday':
|
|
||||||
'samedi',
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
50
threads.js
50
threads.js
|
@ -83,7 +83,7 @@ ArgLabelMorph, localize, XML_Element, hex_sha512*/
|
||||||
|
|
||||||
// Global stuff ////////////////////////////////////////////////////////
|
// Global stuff ////////////////////////////////////////////////////////
|
||||||
|
|
||||||
modules.threads = '2013-December-28';
|
modules.threads = '2014-January-26';
|
||||||
|
|
||||||
var ThreadManager;
|
var ThreadManager;
|
||||||
var Process;
|
var Process;
|
||||||
|
@ -111,7 +111,7 @@ function snapEquals(a, b) {
|
||||||
y = b;
|
y = b;
|
||||||
}
|
}
|
||||||
|
|
||||||
// handle text comparision text-insensitive.
|
// handle text comparision case-insensitive.
|
||||||
if (isString(x) && isString(y)) {
|
if (isString(x) && isString(y)) {
|
||||||
return x.toLowerCase() === y.toLowerCase();
|
return x.toLowerCase() === y.toLowerCase();
|
||||||
}
|
}
|
||||||
|
@ -2477,12 +2477,10 @@ Process.prototype.reportTimer = function () {
|
||||||
// Process Dates and times in Snap
|
// Process Dates and times in Snap
|
||||||
// Map block options to built-in functions
|
// Map block options to built-in functions
|
||||||
var dateMap = {
|
var dateMap = {
|
||||||
'date' : 'toLocaleDateString',
|
|
||||||
'time' : 'toLocaleTimeString',
|
|
||||||
'year' : 'getFullYear',
|
'year' : 'getFullYear',
|
||||||
'month' : 'getMonthName', // return a name, not a number
|
'month' : 'getMonth',
|
||||||
'date': 'getDate',
|
'date': 'getDate',
|
||||||
'day of week' : 'getDayName', // return a name, not a number
|
'day of week' : 'getDay',
|
||||||
'hour' : 'getHours',
|
'hour' : 'getHours',
|
||||||
'minute' : 'getMinutes',
|
'minute' : 'getMinutes',
|
||||||
'second' : 'getSeconds',
|
'second' : 'getSeconds',
|
||||||
|
@ -2493,8 +2491,14 @@ Process.prototype.reportDate = function (datefn) {
|
||||||
|
|
||||||
currDate = new Date();
|
currDate = new Date();
|
||||||
func = dateMap[datefn];
|
func = dateMap[datefn];
|
||||||
|
result = currDate[func]();
|
||||||
return currDate[func]();
|
|
||||||
|
// Show months as 1-12 and days as 1-7
|
||||||
|
if (datefn === 'month' || datefn === 'day of week') {
|
||||||
|
result += 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Process code mapping
|
// Process code mapping
|
||||||
|
@ -3091,33 +3095,3 @@ UpvarReference.prototype.toString = function () {
|
||||||
UpvarReference.prototype.names = VariableFrame.prototype.names;
|
UpvarReference.prototype.names = VariableFrame.prototype.names;
|
||||||
UpvarReference.prototype.allNames = VariableFrame.prototype.allNames;
|
UpvarReference.prototype.allNames = VariableFrame.prototype.allNames;
|
||||||
UpvarReference.prototype.allNamesDict = VariableFrame.prototype.allNamesDict;
|
UpvarReference.prototype.allNamesDict = VariableFrame.prototype.allNamesDict;
|
||||||
|
|
||||||
// Date Utilities (for the 'reportDate' block)
|
|
||||||
|
|
||||||
Date.prototype.getMonthName = function () {
|
|
||||||
mons = ['January',
|
|
||||||
'February',
|
|
||||||
'March',
|
|
||||||
'April',
|
|
||||||
'May',
|
|
||||||
'June',
|
|
||||||
'July',
|
|
||||||
'August',
|
|
||||||
'September',
|
|
||||||
'October',
|
|
||||||
'November',
|
|
||||||
'December'];
|
|
||||||
return localize(mons[this.getMonth()]);
|
|
||||||
}
|
|
||||||
|
|
||||||
Date.prototype.getDayName = function () {
|
|
||||||
days = ['Sunday',
|
|
||||||
'Monday',
|
|
||||||
'Tuesday',
|
|
||||||
'Wednesday',
|
|
||||||
'Thursday',
|
|
||||||
'Friday',
|
|
||||||
'Saturday'];
|
|
||||||
return localize(days[this.getDay()]);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue