Skip to content

Commit

Permalink
Dispatch even only from selected changed function
Browse files Browse the repository at this point in the history
  • Loading branch information
Hector Romero committed Aug 25, 2016
1 parent b01cf57 commit 8892056
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 30 deletions.
7 changes: 1 addition & 6 deletions dist/amd/au-table-select.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,11 +115,6 @@ define(["exports", "aurelia-framework", "./au-table"], function (exports, _aurel
}

this.row.$isSelected = this.row.$isSelected ? false : true;
this.setClass();

if (this.row.$isSelected) {
this.dispatchSelectedEvent();
}
};

AutSelectCustomAttribute.prototype.dispatchSelectedEvent = function dispatchSelectedEvent() {
Expand All @@ -142,7 +137,7 @@ define(["exports", "aurelia-framework", "./au-table"], function (exports, _aurel
this.setClass();

if (this.row.$isSelected) {
dispatchSelectedEvent();
this.dispatchSelectedEvent();
}
};

Expand Down
7 changes: 1 addition & 6 deletions dist/commonjs/au-table-select.js
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,6 @@ var AutSelectCustomAttribute = exports.AutSelectCustomAttribute = (_dec = (0, _a
}

this.row.$isSelected = this.row.$isSelected ? false : true;
this.setClass();

if (this.row.$isSelected) {
this.dispatchSelectedEvent();
}
};

AutSelectCustomAttribute.prototype.dispatchSelectedEvent = function dispatchSelectedEvent() {
Expand All @@ -141,7 +136,7 @@ var AutSelectCustomAttribute = exports.AutSelectCustomAttribute = (_dec = (0, _a
this.setClass();

if (this.row.$isSelected) {
dispatchSelectedEvent();
this.dispatchSelectedEvent();
}
};

Expand Down
7 changes: 1 addition & 6 deletions dist/es2015/au-table-select.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,11 +97,6 @@ export let AutSelectCustomAttribute = (_dec = inject(AureliaTableCustomAttribute
}

this.row.$isSelected = this.row.$isSelected ? false : true;
this.setClass();

if (this.row.$isSelected) {
this.dispatchSelectedEvent();
}
}

dispatchSelectedEvent() {
Expand All @@ -124,7 +119,7 @@ export let AutSelectCustomAttribute = (_dec = inject(AureliaTableCustomAttribute
this.setClass();

if (this.row.$isSelected) {
dispatchSelectedEvent();
this.dispatchSelectedEvent();
}
}

Expand Down
7 changes: 1 addition & 6 deletions dist/system/au-table-select.js
Original file line number Diff line number Diff line change
Expand Up @@ -122,11 +122,6 @@ System.register(["aurelia-framework", "./au-table"], function (_export, _context
}

this.row.$isSelected = this.row.$isSelected ? false : true;
this.setClass();

if (this.row.$isSelected) {
this.dispatchSelectedEvent();
}
};

AutSelectCustomAttribute.prototype.dispatchSelectedEvent = function dispatchSelectedEvent() {
Expand All @@ -149,7 +144,7 @@ System.register(["aurelia-framework", "./au-table"], function (_export, _context
this.setClass();

if (this.row.$isSelected) {
dispatchSelectedEvent();
this.dispatchSelectedEvent();
}
};

Expand Down
7 changes: 1 addition & 6 deletions src/au-table-select.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,11 +53,6 @@ export class AutSelectCustomAttribute {
}

this.row.$isSelected = this.row.$isSelected ? false : true;
this.setClass();

if (this.row.$isSelected) {
this.dispatchSelectedEvent();
}
}

dispatchSelectedEvent() {
Expand All @@ -80,7 +75,7 @@ export class AutSelectCustomAttribute {
this.setClass();

if (this.row.$isSelected) {
dispatchSelectedEvent();
this.dispatchSelectedEvent();
}
}

Expand Down

0 comments on commit 8892056

Please sign in to comment.