mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-03 19:45:44 -05:00
Use a version of Bootstrap that always produces beans and remove all beans: true instructions.
This commit is contained in:
parent
7bd571de17
commit
3226147e00
28 changed files with 6 additions and 66 deletions
4
lib/bootstrap.js
vendored
4
lib/bootstrap.js
vendored
|
@ -14,7 +14,7 @@
|
|||
var Base = new function() { // Bootstrap scope
|
||||
// Fix __proto__ for browsers where it is not implemented (IE and Opera).
|
||||
var fix = !this.__proto__,
|
||||
hidden = /^(statics|generics|preserve|enumerable|beans|prototype|__proto__|toString|valueOf)$/,
|
||||
hidden = /^(statics|generics|preserve|enumerable|prototype|__proto__|toString|valueOf)$/,
|
||||
proto = Object.prototype,
|
||||
/**
|
||||
* Private function that checks if an object contains a given property.
|
||||
|
@ -182,7 +182,7 @@ var Base = new function() { // Bootstrap scope
|
|||
}
|
||||
// Iterate through all definitions in src now and call field() for each.
|
||||
if (src) {
|
||||
beans = src.beans && [];
|
||||
beans = [];
|
||||
for (var name in src)
|
||||
if (has.call(src, name) && !hidden.test(name))
|
||||
field(name, null, true, generics);
|
||||
|
|
|
@ -22,8 +22,6 @@
|
|||
var Matrix = this.Matrix = Base.extend({
|
||||
/** @lends Matrix# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a 2D affine transform.
|
||||
*
|
||||
|
@ -609,5 +607,5 @@ var Matrix = this.Matrix = Base.extend({
|
|||
this['set' + name] = function(value) {
|
||||
this[prop] = value;
|
||||
};
|
||||
}, { beans: true });
|
||||
}, {});
|
||||
});
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Point = this.Point = Base.extend({
|
||||
/** @lends Point# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a Point object with the given x and y coordinates.
|
||||
*
|
||||
|
@ -919,8 +917,6 @@ var Point = this.Point = Base.extend({
|
|||
* @ignore
|
||||
*/
|
||||
var LinkedPoint = Point.extend({
|
||||
beans: true,
|
||||
|
||||
set: function(x, y, dontNotify) {
|
||||
this._x = x;
|
||||
this._y = y;
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Rectangle = this.Rectangle = Base.extend({
|
||||
/** @lends Rectangle# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a Rectangle object.
|
||||
*
|
||||
|
@ -649,7 +647,7 @@ var Rectangle = this.Rectangle = Base.extend({
|
|||
// Note: call chaining happens here.
|
||||
return this[setX](point.x)[setY](point.y);
|
||||
};
|
||||
}, { beans: true });
|
||||
}, {});
|
||||
});
|
||||
|
||||
/**
|
||||
|
@ -661,8 +659,6 @@ var Rectangle = this.Rectangle = Base.extend({
|
|||
* @ignore
|
||||
*/
|
||||
var LinkedRectangle = Rectangle.extend({
|
||||
beans: true,
|
||||
|
||||
set: function(x, y, width, height, dontNotify) {
|
||||
this._x = x;
|
||||
this._y = y;
|
||||
|
@ -722,6 +718,6 @@ var LinkedRectangle = Rectangle.extend({
|
|||
this._owner[this._setter](this);
|
||||
return this;
|
||||
};
|
||||
}, { beans: true })
|
||||
}, {})
|
||||
);
|
||||
});
|
||||
|
|
|
@ -502,8 +502,6 @@ var Size = this.Size = Base.extend({
|
|||
* @ignore
|
||||
*/
|
||||
var LinkedSize = Size.extend({
|
||||
beans: true,
|
||||
|
||||
set: function(width, height, dontNotify) {
|
||||
this._width = width;
|
||||
this._height = height;
|
||||
|
|
|
@ -307,8 +307,6 @@ var Color = this.Color = Base.extend(new function() {
|
|||
}, {
|
||||
/** @lends Color# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Returns the type of the color as a string.
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Gradient = this.Gradient = Base.extend({
|
||||
/** @lends Gradient# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// TODO: Should type here be called 'radial' and have it receive a
|
||||
// boolean value?
|
||||
/**
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var GradientColor = this.GradientColor = Color.extend({
|
||||
/** @lends GradientColor# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a gradient color object.
|
||||
*
|
||||
|
|
|
@ -18,8 +18,6 @@
|
|||
var GradientStop = this.GradientStop = Base.extend({
|
||||
/** @lends GradientStop# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a GradientStop object.
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Group = this.Group = Item.extend({
|
||||
/** @lends Group# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// DOCS: document new Group(item, item...);
|
||||
/**
|
||||
* Creates a new Group item and places it at the top of the active layer.
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Item = this.Item = Base.extend({
|
||||
/** @lends Item# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* @name Item
|
||||
* @class The Item type allows you to access and modify the items in
|
||||
|
|
|
@ -33,8 +33,6 @@ var PathStyle = this.PathStyle = Base.extend(new function() {
|
|||
};
|
||||
|
||||
var fields = {
|
||||
beans: true,
|
||||
|
||||
// DOCS: why isn't the example code showing up?
|
||||
/**
|
||||
* PathStyle objects don't need to be created directly. Just pass an
|
||||
|
@ -151,7 +149,7 @@ var PathStyle = this.PathStyle = Base.extend(new function() {
|
|||
this[get] = function() {
|
||||
return this._style[get]();
|
||||
};
|
||||
}, { beans: true }));
|
||||
}, {}));
|
||||
|
||||
return fields;
|
||||
});
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var PlacedSymbol = this.PlacedSymbol = Item.extend({
|
||||
/** @lends PlacedSymbol# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a new PlacedSymbol Item.
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Raster = this.Raster = Item.extend({
|
||||
/** @lends Raster# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// TODO: Implement url / type, width, height.
|
||||
// TODO: Have PlacedSymbol & Raster inherit from a shared class?
|
||||
// DOCS: Document Raster constructor.
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Curve = this.Curve = Base.extend({
|
||||
/** @lends Curve# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a new curve object.
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
CurveLocation = Base.extend({
|
||||
/** @lends CurveLocation# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// DOCS: CurveLocation class description: add this comment back when the
|
||||
// mentioned functioned have been added:
|
||||
// The class is in use in many places, such as {@link Path#getLocationAt(offset)},
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Path = this.Path = PathItem.extend({
|
||||
/** @lends Path# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a new Path item and places it at the top of the active layer.
|
||||
*
|
||||
|
@ -1760,8 +1758,6 @@ var Path = this.Path = PathItem.extend({
|
|||
}
|
||||
|
||||
return {
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* The bounding rectangle of the item excluding stroke width.
|
||||
* @param matrix optional
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Segment = this.Segment = Base.extend({
|
||||
/** @lends Segment# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a new Segment object.
|
||||
*
|
||||
|
|
|
@ -21,8 +21,6 @@
|
|||
* @ignore
|
||||
*/
|
||||
var SegmentPoint = Point.extend({
|
||||
beans: true,
|
||||
|
||||
set: function(x, y) {
|
||||
this._x = x;
|
||||
this._y = y;
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Project = this.Project = Base.extend({
|
||||
/** @lends Project# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// TODO: Add arguments to define pages
|
||||
// DOCS: Document Project constructor and class
|
||||
/**
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Symbol = this.Symbol = Base.extend({
|
||||
/** @lends Symbol# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a Symbol item.
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var PointText = this.PointText = TextItem.extend({
|
||||
/** @lends PointText# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* Creates a point text item
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var TextItem = this.TextItem = Item.extend({
|
||||
/** @lends TextItem# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* @constructs TextItem
|
||||
*
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var Tool = this.Tool = Base.extend({
|
||||
/** @lends Tool# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// DOCS: rewrite Tool constructor explanation
|
||||
/**
|
||||
* Initializes the tool's settings, so a new tool can be assigned to it
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var ToolEvent = this.ToolEvent = Event.extend({
|
||||
/** @lends ToolEvent# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* @name ToolEvent
|
||||
* @constructor
|
||||
|
|
|
@ -15,8 +15,6 @@
|
|||
*/
|
||||
|
||||
var Event = this.Event = Base.extend({
|
||||
beans: true,
|
||||
|
||||
initialize: function(event) {
|
||||
this.event = event;
|
||||
},
|
||||
|
|
|
@ -18,8 +18,6 @@ var KeyEvent = this.KeyEvent = Event.extend(new function() {
|
|||
return {
|
||||
/** @lends KeyEvent# */
|
||||
|
||||
beans: true,
|
||||
|
||||
/**
|
||||
* @name KeyEvent
|
||||
* @constructor
|
||||
|
|
|
@ -17,8 +17,6 @@
|
|||
var View = this.View = Base.extend({
|
||||
/** @lends View# */
|
||||
|
||||
beans: true,
|
||||
|
||||
// DOCS: View: there is alot left to document
|
||||
// TODO: Add bounds parameter that defines position within canvas?
|
||||
// Find a good name for these bounds, since #bounds is already the artboard
|
||||
|
|
Loading…
Reference in a new issue