mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
feat: bundle workflow support (#7337)
This commit is contained in:
committed by
Vasil Chimev
parent
5f9eabdf17
commit
ecd9fc3e9d
17
e2e/ui-tests-app/app/layouts/stack-page.ts
Normal file
17
e2e/ui-tests-app/app/layouts/stack-page.ts
Normal file
@@ -0,0 +1,17 @@
|
||||
import * as enums from "tns-core-modules/ui/enums";
|
||||
import * as pageModule from "tns-core-modules/ui/page";
|
||||
import * as model from "./myview";
|
||||
|
||||
export function onLoaded(args: { eventName: string, object: any }) {
|
||||
var page = <pageModule.Page>args.object;
|
||||
page.bindingContext = new model.ViewModel();
|
||||
}
|
||||
|
||||
export function onOrientation(args: { eventName: string, object: any }) {
|
||||
var layout = args.object.parent;
|
||||
if (layout.orientation === enums.Orientation.vertical) {
|
||||
layout.orientation = enums.Orientation.horizontal;
|
||||
} else {
|
||||
layout.orientation = enums.Orientation.vertical;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user