本文整理汇总了TypeScript中bobril.invalidate函数的典型用法代码示例。如果您正苦于以下问题:TypeScript invalidate函数的具体用法?TypeScript invalidate怎么用?TypeScript invalidate使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了invalidate函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的TypeScript代码示例。
示例1: switch
c.onMessage = (c: longPollingClient.Connection, message: string, data: any) => {
if (!connected) {
connected = true;
reconnectDelay = 0;
b.invalidate();
}
switch (message) {
case "wait": {
wait = true;
b.invalidate();
break;
}
case "test": {
testing = true;
testUrl = data.url;
b.invalidate();
if (iframe != null) document.body.removeChild(iframe);
iframe = document.createElement("iframe");
document.body.appendChild(iframe);
iframe.src = testUrl;
break;
}
default: {
console.log("Unknown message: " + message, data);
break;
}
}
};
开发者ID:Bobris,项目名称:bobril-build,代码行数:28,代码来源:app.ts
示例2: initRobotoFonts
export function initRobotoFonts(subsets = 'latin') {
WebFont.load({ google: { families: ['Roboto:400,500:' + subsets] },
active() { b.invalidate(); },
inactive() { b.invalidate(); },
classes: false
});
}
开发者ID:JakubJecminek,项目名称:bobril-m,代码行数:7,代码来源:fonts.ts
示例3: switch
c.onMessage = (c: longPollingClient.Connection, message: string, data: any) => {
if (!connected) {
connected = true;
b.invalidate();
}
switch (message) {
case "testUpdated": {
testSvrState = data;
b.invalidate();
break;
}
default: {
console.log("Unknown message: " + message, data);
break;
}
}
};
开发者ID:tejnora,项目名称:bobril-build,代码行数:17,代码来源:index.ts
示例4: setInterval
const interval = setInterval(() => {
ctx.counter--;
if (ctx.counter <= 0) {
clearInterval(interval);
ctx.disabled = true;
}
b.invalidate();
}, 1000);
开发者ID:mathieugauthier,项目名称:Bobril-example,代码行数:8,代码来源:clicker.ts
示例5: reconnect
function reconnect() {
disconnected = false;
c.connect();
c.send("newClient", {
userAgent: navigator.userAgent
});
b.invalidate();
}
开发者ID:Bobris,项目名称:bobril-build,代码行数:8,代码来源:app.ts
示例6: updateColorModels
function updateColorModels(ctx: IColorPickerCtx, red: number, green: number, blue: number) {
ctx.hsv = graphics.rgbToHsv({ r: red, g: green, b: blue });
ctx.rgb.r = red;
ctx.rgb.g = green;
ctx.rgb.b = blue;
ctx.newPreviewColor = graphics.hsvToHex(ctx.hsv);
b.invalidate(ctx);
}
开发者ID:jirgl,项目名称:color-picker,代码行数:8,代码来源:colorPicker.ts
示例7: setTimeout
c.onClose = () => {
s.connected = false;
s.disconnected = true;
b.invalidate();
if (s.reconnectDelay < 30000) s.reconnectDelay += 1000;
setTimeout(() => {
reconnect();
}, s.reconnectDelay);
};
开发者ID:Bobris,项目名称:bobril-build,代码行数:9,代码来源:communication.ts
示例8: setTimeout
c.onClose = () => {
connected = false;
disconnected = true;
b.invalidate();
if (reconnectDelay < 30000) reconnectDelay += 1000;
setTimeout(() => {
reconnect();
}, reconnectDelay);
};
开发者ID:Bobris,项目名称:bobril-build,代码行数:9,代码来源:app.ts
示例9: Header
b.init(() => {
b.invalidate();
return [
Header({ content: 'Game of life' }),
GameController({
runing: true,
startLiveCell: startLiveCell
})
];
});
开发者ID:Bobris,项目名称:Bobril,代码行数:10,代码来源:app.ts
注:本文中的bobril.invalidate函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论