本文整理匯總了TypeScript中tns-core-modules/ui/frame.Frame.getViewById方法的典型用法代碼示例。如果您正苦於以下問題:TypeScript Frame.getViewById方法的具體用法?TypeScript Frame.getViewById怎麽用?TypeScript Frame.getViewById使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類tns-core-modules/ui/frame.Frame
的用法示例。
在下文中一共展示了Frame.getViewById方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: wireEvents
function wireEvents(){
page.getViewById("genstureSwipe").on("swipe", (args: SwipeGestureEventData) => {
googleAnalytics.logEvent({
category: "Gestures",
action: "Swipe",
label: "Direction: " + args.direction,
value: args.direction
});
showMessage("Swipe Direction: " + args.direction);
console.log("Swipe Direction: " + args.direction);
});
page.getViewById("genstureLongTap").on("longPress", args => {
googleAnalytics.logEvent({
category: "Gestures",
action: "Long Press",
label: "Long press on screen"
});
showMessage("Long Press");
console.log("Long Press");
});
}