WebSockets: minor update in JS code style
Use anonymous blocks { } instead of anonymous functions as the outermost scope in some files. Also fix incorrect wording for a comment
This commit is contained in:
parent
f1d7e1759a
commit
cef81b8c23
@ -22,8 +22,8 @@ import { createRootContainer, Container, Dialog, Label, Button, Toggle,
|
|||||||
AudioStripGainFader, MidiStripGainFader,
|
AudioStripGainFader, MidiStripGainFader,
|
||||||
AudioStripMeter, MidiStripMeter } from './tkwidget.js';
|
AudioStripMeter, MidiStripMeter } from './tkwidget.js';
|
||||||
|
|
||||||
(() => {
|
{
|
||||||
|
|
||||||
const ardour = new ArdourClient();
|
const ardour = new ArdourClient();
|
||||||
|
|
||||||
async function main () {
|
async function main () {
|
||||||
@ -223,4 +223,4 @@ import { createRootContainer, Container, Dialog, Label, Button, Toggle,
|
|||||||
|
|
||||||
main();
|
main();
|
||||||
|
|
||||||
})();
|
}
|
||||||
|
@ -167,7 +167,7 @@ export class Dialog extends BaseDialog {
|
|||||||
|
|
||||||
show () {
|
show () {
|
||||||
// opening a TK.Dialog with auto_close=true from a TK.Button callback
|
// opening a TK.Dialog with auto_close=true from a TK.Button callback
|
||||||
// fails otherwise ev.stopPropagation() is called in the button event
|
// fails unless ev.stopPropagation() is called in the button event
|
||||||
// handler or setTimeout() is used here
|
// handler or setTimeout() is used here
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.tk.set('display_state', 'show');
|
this.tk.set('display_state', 'show');
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
|
|
||||||
import ArdourClient from '/shared/ardour.js';
|
import ArdourClient from '/shared/ardour.js';
|
||||||
|
|
||||||
(() => {
|
{
|
||||||
|
|
||||||
const MAX_LOG_LINES = 1000;
|
const MAX_LOG_LINES = 1000;
|
||||||
|
|
||||||
@ -65,4 +65,4 @@ import ArdourClient from '/shared/ardour.js';
|
|||||||
|
|
||||||
main();
|
main();
|
||||||
|
|
||||||
})();
|
}
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
|
|
||||||
import ArdourClient from '/shared/ardour.js';
|
import ArdourClient from '/shared/ardour.js';
|
||||||
|
|
||||||
(() => {
|
{
|
||||||
|
|
||||||
const dom = {
|
const dom = {
|
||||||
main : document.getElementById('main'),
|
main : document.getElementById('main'),
|
||||||
@ -126,4 +126,4 @@ import ArdourClient from '/shared/ardour.js';
|
|||||||
|
|
||||||
main();
|
main();
|
||||||
|
|
||||||
})();
|
}
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
|
|
||||||
import ArdourClient from '/shared/ardour.js';
|
import ArdourClient from '/shared/ardour.js';
|
||||||
|
|
||||||
(() => {
|
{
|
||||||
|
|
||||||
async function main () {
|
async function main () {
|
||||||
try {
|
try {
|
||||||
@ -81,4 +81,4 @@ import ArdourClient from '/shared/ardour.js';
|
|||||||
|
|
||||||
main();
|
main();
|
||||||
|
|
||||||
})();
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user