+ Trying -moz-crisp-edges… doesn't seem to improve speed much on 3.6, and looks worse

+ Created Utils.copy to make duplicating objects cleaner
+ Fixed a number of issues with pulling tabs out of a tray. Temporarily disabled the delay on drag as well.
+ Improved the threshold for switching from grid to stack; only happens when the grid fills up.
+ No longer announcing "bad storage data" when there is in fact no storage data (fresh start)
+ A couple more asserts
This commit is contained in:
Ian Gilman 2010-05-11 17:22:06 -07:00
parent ffba354eb3
commit 207855a456

View File

@ -309,6 +309,8 @@ window.Subscribable.prototype = {
};
// ##########
// Class: Utils
// Singelton with common utility functions.
var Utils = {
// ___ Windows and Tabs
get activeWindow(){
@ -527,8 +529,21 @@ var Utils = {
},
// ----------
// Function: isNumber
// Returns true if the argument is a valid number.
isNumber: function(n) {
return (typeof(n) == 'number' && !isNaN(n));
},
// ----------
// Function: copy
// Returns a copy of the argument. Note that this is a shallow copy; if the argument
// has properties that are themselves objects, those properties will be copied by reference.
copy: function(value) {
if(value && typeof(value) == 'object')
return $.extend({}, value);
return value;
}
};