was.wm.js – Diff between revs 4 and 7
?pathlinks?
Rev 4 | Rev 7 | |||
---|---|---|---|---|
Line 1... | Line 1... | |||
1 | /*! was.wm.js - v1.0.1 - 2018-01-24 |
1 | /*! was.wm.js - v1.0.3 - 2018-01-25 |
|
2 | * http://grimore.org |
2 | * http://grimore.org |
|
3 | * Copyright (c) 2018 Wizardry and Steamworks <office@grimore.org>; Licensed GPL-3.0 */ |
3 | * Copyright (c) 2018 Wizardry and Steamworks <office@grimore.org>; Licensed GPL-3.0 */ |
|
4 | // Load the window manager desktop icons. |
4 | // Load the window manager desktop icons. |
|
5 | function loadWindowManagerIcons(path) { |
5 | function loadWindowManagerIcons(path) { |
|
6 | // Search and load all nucleons. |
6 | // Search and load all nucleons. |
|
Line 10... | Line 10... | |||
10 | var cookie = Cookies.get('window-manager-icons'); |
10 | var cookie = Cookies.get('window-manager-icons'); |
|
11 | if(cookie) { |
11 | if(cookie) { |
|
12 | states = JSON.parse(cookie); |
12 | states = JSON.parse(cookie); |
|
13 | } |
13 | } |
|
14 | $.each(nucleons, function(index, file) { |
14 | $.each(nucleons, function(index, file) { |
|
15 | // Skip files starting with full stop (POSIX). |
15 | // Only consider HTML files. |
|
16 | if (/^\./.test(file)) { |
16 | if (!/\.html$/.test(file)) { |
|
17 | return; |
17 | return; |
|
18 | } |
18 | } |
|
19 | $.get(path + '/' + file, function(data) { |
19 | $.get(path + '/' + file, function(data) { |
|
20 | data = $(data).get(0); |
20 | data = $(data).get(0); |
|
21 | var nucleon = data.getAttribute('data-target'); |
21 | var nucleon = data.getAttribute('data-target'); |