當前位置: 首頁>>代碼示例>>TypeScript>>正文


TypeScript grid-layout.GridLayout類代碼示例

本文整理匯總了TypeScript中ui/layouts/grid-layout.GridLayout的典型用法代碼示例。如果您正苦於以下問題:TypeScript GridLayout類的具體用法?TypeScript GridLayout怎麽用?TypeScript GridLayout使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了GridLayout類的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。

示例1: pluckViews

	public static pluckViews(parent: GridLayout): View[] {
		let returnViews: View[] = [];
		parent.eachLayoutChild((child: View) => {
			returnViews.push(child);
		});
		parent.removeChildren();
		return returnViews;
	}
開發者ID:wbeater,項目名稱:nativescript-parallax,代碼行數:8,代碼來源:utilities.ts

示例2: ResetGridRows

 public ResetGridRows(value: number){
   let grid : GridLayout = this.gridRef.nativeElement;
  
   grid.removeRows();
   
   for(let i =0; i<value; i++){
     console.log("add row defintion");
     grid.addRow(new ItemSpec(1, "star"));
   }
   
   let rows = grid.getRows();
   console.log("grid-row count: " + rows.length);
 }
開發者ID:matt4446,項目名稱:NS-Angular-GridTest,代碼行數:13,代碼來源:grid.directive.ts

示例3: ResetGridColumns

    public ResetGridColumns(value: number){
      let grid : GridLayout = this.gridRef.nativeElement;

      grid.removeColumns();
     
      for(let i =0; i<value; i++){
        console.log("add column defintion");
        grid.addColumn(new ItemSpec(1, "star"));
      }
      
      let columns = grid.getColumns();
      console.log("grid-column counts: " + columns.length);
    }
開發者ID:matt4446,項目名稱:NS-Angular-GridTest,代碼行數:13,代碼來源:grid.directive.ts

示例4: loginPageFunc

    public loginPageFunc() {
        let wv = new TnsOauthWebView(this._cancelEventHandler);

        TnsOAuthWebViewHelper.initWithWebViewAndIntercept(wv, this._checkCodeIntercept);

        let grid = new GridLayout();
        grid.addChild(wv);

        let stack = new StackLayout();
        stack.addChild(grid);

        let page = new Page();
        page.content = stack;

        if (isAndroid) {
            page.actionBarHidden = true;
        }

        wv.src = this._authUrl;

        return page;
    };
開發者ID:alexziskind1,項目名稱:nativescript-oauth,代碼行數:22,代碼來源:tns-oauth-page-provider.ts

示例5: displayDevWarning

	public static displayDevWarning(parent:GridLayout, message: string, ...viewsToCollapse: View[]): void {
		let warningText = new Label();
		warningText.text = message;
		warningText.color = new Color('red');
		warningText.textWrap = true;
		warningText.marginTop = 50;
		parent.addChild(warningText);
		viewsToCollapse.forEach((view: View) => {
			if (view != null) {
				view.visibility = 'collapse';
			}
		});
	}
開發者ID:katturajam,項目名稱:nativescript-parallax,代碼行數:13,代碼來源:utilities.ts

示例6: onClearCache

export function onClearCache(args: EventData) {
    var imagePipeLine = frescoModel.getImagePipeline();
    imagePipeLine.clearCaches();
    layout.removeChildren();
    toggleBusyIndicator(true);
    setContent();
}
開發者ID:triniwiz,項目名稱:nativescript-fresco,代碼行數:7,代碼來源:main-page.ts

示例7: setContent

function setContent() {
    myComponentInstance = builderModule.load({
        path: "~/examples/",
        name: xmlFileName
    });
    if (tabViewItem && tabViewItem.view) {
        if (layout && layout.getChildrenCount() <= 0) {
            timerId = timerModule.setInterval(function () {
                toggleBusyIndicator(false);
                layout.addChild(myComponentInstance);
                timerModule.clearInterval(timerId);
            }, 800);
        }
    }
}
開發者ID:triniwiz,項目名稱:nativescript-fresco,代碼行數:15,代碼來源:main-page.ts

示例8: toggleBusyIndicator

 timerId = timerModule.setInterval(function () {
     toggleBusyIndicator(false);
     layout.addChild(myComponentInstance);
     timerModule.clearInterval(timerId);
 }, 800);
開發者ID:triniwiz,項目名稱:nativescript-fresco,代碼行數:5,代碼來源:main-page.ts


注:本文中的ui/layouts/grid-layout.GridLayout類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。