TouchDevelop/libwab/AdManager.ts

24 строки
886 B
TypeScript
Исходник Обычный вид История

2015-02-05 00:41:44 +03:00
///<reference path='refs.ts'/>
module TDev.RT.Wab {
export function AdManagerInit()
{
if (isSupportedAction(Action.SHOW_AD) &&
ApiManager.pubCenterApplicationId &&
ApiManager.pubCenterAdUnitId) {
Util.log('wab: boosting SHOW_AD');
AdManager.initialize = AdManagerWab.initialize;
}
}
export module AdManagerWab {
export function initialize(el: HTMLElement) {
Util.log('wab: initialize AdCenter, AdUnitId = ' + ApiManager.pubCenterAdUnitId + ', ApplicationId = ' + ApiManager.pubCenterApplicationId);
el.style.display = 'none';
sendRequest({
action: Action.SHOW_AD,
adUnitId:ApiManager.pubCenterAdUnitId,
applicationId:ApiManager.pubCenterApplicationId
}, (response: Response) => { });
}
}
2015-02-04 19:07:58 +03:00
}