Skip to content
This repository was archived by the owner on Dec 30, 2018. It is now read-only.

Commit 65a98af

Browse files
committed
v0.3.1
1 parent 0fad655 commit 65a98af

File tree

5 files changed

+19
-10
lines changed

5 files changed

+19
-10
lines changed

CHANGELOG.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
<a name="v0.3.1"></a>
2+
### v0.3.1 (2013-08-04)
3+
4+
5+
#### Features
6+
7+
* **app:** expose scheduleMasonry(Once) methods ([0fad6552](http://github.com/passy/angular-masonry/commit/0fad65527af6f1dd11ebc2b3bb2deb03ebaef34c))
8+
19
<a name="v0.3.0"></a>
210
## v0.3.0 (2013-08-04)
311

angular-masonry.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* angular-masonry 0.3.0
2+
* angular-masonry 0.3.1
33
* Pascal Hartig, weluse GmbH, http://weluse.de/
44
* License: MIT
55
*/
@@ -11,22 +11,23 @@
1111
var bricks = {};
1212
var schedule = [];
1313
var destroyed = false;
14+
var self = this;
1415
var timeout = null;
1516

16-
function scheduleMasonryOnce() {
17+
this.scheduleMasonryOnce = function scheduleMasonryOnce() {
1718
var args = arguments;
1819
var found = schedule.filter(function (item) {
1920
return item[0] === args[0];
2021
}).length > 0;
2122

2223
if (!found) {
23-
scheduleMasonry.apply(null, arguments);
24+
this.scheduleMasonry.apply(null, arguments);
2425
}
2526
}
2627

2728
// Make sure it's only executed once within a reasonable time-frame in
2829
// case multiple elements are removed or added at once.
29-
function scheduleMasonry() {
30+
this.scheduleMasonry = function scheduleMasonry() {
3031
if (timeout) {
3132
$timeout.cancel(timeout);
3233
}
@@ -68,7 +69,7 @@
6869
// Keep track of added elements.
6970
bricks[id] = true;
7071
$element.masonry('appended', element, true);
71-
scheduleMasonryOnce('layout');
72+
self.scheduleMasonryOnce('layout');
7273
}
7374
}
7475

@@ -82,7 +83,7 @@
8283

8384
delete bricks[id];
8485
$element.masonry('remove', element);
85-
scheduleMasonryOnce('layout');
86+
this.scheduleMasonryOnce('layout');
8687
};
8788

8889
this.destroy = function destroy() {

angular-masonry.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bower.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "angular-masonry",
33
"description": "An AngularJS directive for Masonry.",
4-
"version": "0.3.0",
4+
"version": "0.3.1",
55
"main": "./angular-masonry.js",
66
"ignore": [
77
"**/.*",

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "angular-masonry",
3-
"version": "0.3.0",
3+
"version": "0.3.1",
44
"devDependencies": {
55
"grunt-contrib-uglify": "~0.2.2",
66
"grunt": "~0.4.1",

0 commit comments

Comments
 (0)