Skip to content

Commit 417b1d5

Browse files
committed
renaming
1 parent c33167a commit 417b1d5

File tree

1 file changed

+7
-11
lines changed

1 file changed

+7
-11
lines changed

services/static-webserver/client/source/class/osparc/dashboard/SortedByMenuButton.js

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ qx.Class.define("osparc.dashboard.SortedByMenuButton", {
4444
});
4545
// Sort by last modified date
4646
if (idx === options.length -1) {
47-
this.__menuButton = btn;
47+
this.__selectedMenuButton = btn;
4848
btn.setIcon("@FontAwesome5Solid/arrow-down/14");
4949
}
5050
sortedByMenu.add(btn);
@@ -61,11 +61,6 @@ qx.Class.define("osparc.dashboard.SortedByMenuButton", {
6161
},
6262

6363
statics: {
64-
DefaultSorting: {
65-
field: "last_change_date",
66-
direction: "desc"
67-
},
68-
6964
getSortByOptions: function() {
7065
return [{
7166
id: "name",
@@ -101,12 +96,13 @@ qx.Class.define("osparc.dashboard.SortedByMenuButton", {
10196
},
10297

10398
members: {
104-
__menuButton: null,
99+
__selectedMenuButton: null,
100+
105101
__buttonExecuted: function(btn) {
106-
if (this.__menuButton) {
107-
this.__menuButton.setIcon(null);
102+
if (this.__selectedMenuButton) {
103+
this.__selectedMenuButton.setIcon(null);
108104
}
109-
this.__menuButton = btn;
105+
this.__selectedMenuButton = btn;
110106
this.set({
111107
label: btn.getLabel(),
112108
icon: "@FontAwesome5Solid/chevron-down/10"
@@ -134,7 +130,7 @@ qx.Class.define("osparc.dashboard.SortedByMenuButton", {
134130
},
135131

136132
__handelSortEvent: function({field, direction}) {
137-
this.__menuButton.setIcon(direction ? "@FontAwesome5Solid/arrow-down/14" : "@FontAwesome5Solid/arrow-up/14")
133+
this.__selectedMenuButton.setIcon(direction ? "@FontAwesome5Solid/arrow-down/14" : "@FontAwesome5Solid/arrow-up/14")
138134
this.setIcon(direction ? "@FontAwesome5Solid/arrow-down/14" : "@FontAwesome5Solid/arrow-up/14")
139135
const sort = {
140136
field: field,

0 commit comments

Comments
 (0)