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


TypeScript ionic-angular.Content類代碼示例

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


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

示例1:

 this.notificationService.getNotificationListForTop(position, isNeedRegistNotExistsReadStatus, this.keyWord).then((data: any) => {
     this.notificationListForTop = data;
     this.isLoadCompleted = true;
     this.isScrollToTopButtonVisible = false;
     if (isRefresh) {
         refresher.complete();
     }
     if (this.isFirstTimeLoad && data.length > 9) {
         this.pageContent.scrollTo(0, 46);
         this.isShowSearchBar = true;
         this.isFirstTimeLoad = false;
     }
 });
開發者ID:intasect,項目名稱:intalinx-mobile,代碼行數:13,代碼來源:index.ts

示例2:

      medias => {
        // if (medias.length > 0) {
          this.mediaList = medias;
          // this.mediaList = [];
          // for (var i = 0; i < medias.length; i++) {
          //   this.mediaList.push({
          //     Id: medias.item(i).Id,
          //     Author: medias.item(i).Author,
          //     Title: medias.item(i).Title,
          //     Description: medias.item(i).Description,
          //     Location: medias.item(i).Location,
          //     MediaDate: medias.item(i).MediaDate,
          //     UploadDate: medias.item(i).UploadDate,
          //     Active: medias.item(i).Active,
          //     SubCategoryId: medias.item(i).SubCategoryId,
          //     Downloaded: medias.item(i).Downloaded
          //   });

          // }
        // }

        // this.mediaList = medias;
        this.activeSC == subCategory.Id ? this.activeSC = 0 : this.activeSC = subCategory.Id;
        // setTimeout(
        //   () => {
            var pos = this.findPos(event.target);
            this.content.scrollTo(pos.left, pos.top - 1, 100);
          // }
          // , 0);
        return this.mediaList;
      }
開發者ID:davidkirolos,項目名稱:RolApp,代碼行數:31,代碼來源:subcategoryList.ts

示例3: setTimeout

      ).subscribe(([section, isFullscreen]) => {
        this.content.resize();

        // Hack to make it happen after resize is done
        setTimeout(() => {
          this.calculateOffset(section, isFullscreen);
        }, 0);
      });
開發者ID:bGraphic,項目名稱:varsom-hybrid,代碼行數:8,代碼來源:overview.ts

示例4:

 (childNodes: TreeNode[]) => {
     this.folderItems = {};
     // we found all children of the node we're
     // traversing to (key)
     for (let i in childNodes) {
         let childNode: TreeNode = childNodes[i],
             childKey: number = childNode[DB_KEY_PATH];
         newFolderItems[childKey] = childNode;
     } // for
     this.folderNode = folderNode;
     this.folderItems = newFolderItems;
     // resize content, because a change in this.folderNode
     // can affect the header's visibility
     this.content.resize();
 },
開發者ID:zhu04303661,項目名稱:ionic-recorder,代碼行數:15,代碼來源:library-page.ts

示例5: ionViewDidEnter

  //Function called once the view is full loaded
  ionViewDidEnter() {

    //Scroll to the bottom of the messages (Request below is for polling, not getting messages)
    this.content.scrollToBottom(this.scrollDuration);

    //Grab our user from localstorage
    let user = JSON.parse(localStorage.getItem(AppSettings.shushItemName));

    //Start polling to get messages
    let poll = this.appMessaging.conversationRequestPoll(user.access_token);

    //Get a reference to this
    let self = this;

    this.pollingRequest = poll.subscribe(function(success) {
      //Success!

      //Stop loading
      self.appNotify.stopLoading().then(function() {

        //Add our messages/Get our conversation
        self.appMessaging.conversations = success;

        //Update our conversations
        self.updateConversation();
      });
    }, function(error) {
      //Error!

      //Stop Loading
      self.appNotify.stopLoading().then(function() {
        //Pass to Error Handler
        self.appNotify.handleError(error, [{
          status: 404,
          callback: function() {
            //Pop back to the All conversations view

            self.navCtrl.pop();
          }
        }]);
      });

    }, function() {
      //Completed
    })
  }
開發者ID:pro-to-tip,項目名稱:pro-to-tip.github.io,代碼行數:47,代碼來源:conversation.ts

示例6: setTimeout

        setTimeout(() => {
            let screenHeight: number = this.maincontent.getNativeElement().clientHeight;
            let sizes: PosterPercentageItem[] = [];

            for (let i = 0; i < this.tmdbConfig.images.poster_sizes.length; i++) {
                let posterSize: string = this.tmdbConfig.images.poster_sizes[i];
                let size: number = +posterSize.substring(1, posterSize.length);
                let percentage: number = (size / screenHeight) * 100;

                if (!isNaN(percentage)) {
                    sizes.push({ percentage: percentage, posterSize: posterSize, size: size });
                }
            }

            var closestPercentage = findClosest(sizes.map(x => x.percentage), 40);
            this.posterWidth = sizes.find(x => x.percentage == closestPercentage).posterSize;
            this.imageHeight = this.scrollHeight = screenHeight * 0.4;
        }, 0);
開發者ID:KajB,項目名稱:WatchIT,代碼行數:18,代碼來源:home.ts

示例7: updateConversation

  //Function to update our conversation
  updateConversation() {

    //Find and update our current conversation
    for (let i = 0; i < this.appMessaging.conversations.length; ++i) {
      if (this.convoId == this.appMessaging.conversations[i]._id) {

        //Update the conversation
        this.convo = this.appMessaging.conversations[i];

        //Break from the loop
        i = this.appMessaging.conversations.length;
      }
    }

    //Update the UI
    this.changeDetector.detectChanges();

    //Scroll to the bottom of the messages
    this.content.scrollToBottom(this.scrollDuration);
  }
開發者ID:pro-to-tip,項目名稱:pro-to-tip.github.io,代碼行數:21,代碼來源:conversation.ts

示例8: scrollToBottom

 scrollToBottom(){
   this.content.scrollToBottom(300);//300ms animation speed
 }
開發者ID:thomas1511,項目名稱:ionicScrollProblem,代碼行數:3,代碼來源:hello-ionic.ts

示例9: tapEvent

 //點擊到頂部
 tapEvent(e) {
   this.content.scrollToTop();
 }
開發者ID:,項目名稱:,代碼行數:4,代碼來源:

示例10:

 this._scrollToTopSubscription = this.section$.subscribe(() => {
   this.content.scrollToTop();
 });
開發者ID:bGraphic,項目名稱:varsom-hybrid,代碼行數:3,代碼來源:overview.ts


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