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


TypeScript Platform.ready方法代碼示例

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


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

示例1: trackEvent

trackEvent(data: GAEvent): any {
        this.platform.ready().then(() => {
      GoogleAnalytics.trackEvent(data.category, data.action, data.label, data.value);
    });
    }
開發者ID:offlineprogrammer,項目名稱:kidsTokens,代碼行數:5,代碼來源:googleAnalyticsService.ts

示例2: constructor

 @ViewChild('mapCanvas') mapElement: ElementRef;/*通過模版變量注入,但類型是元素類型*/
 constructor(public confData: ConferenceData, public platform: Platform) {
    this.platform.ready().then((readySource) => {
     this.locate();
     // Platform now ready, execute any required native code
   });
 }
開發者ID:qwb0920,項目名稱:ionic-bianqian-app,代碼行數:7,代碼來源:map.ts

示例3: constructor

 constructor(private platform: Platform, private storage: Storage, private transfer: FileTransfer, private file: File) {
   this.platform.ready().then(_ => {
     this.fileTransfer = this.transfer.create();
   });
 }
開發者ID:CIRDLES,項目名稱:CHRONI,代碼行數:5,代碼來源:FileUtility.ts

示例4: constructor

//     constructor(public navCtrl: NavController, public platform: Platform, public navParams: NavParams) {
//       this.post = navParams.get('post');
        

        
//     }
 
// ngAfterViewInit() {
// this.platform.ready().then(() => {
//             this.loadMap();
//         });
// }

//     loadMap(){

//       GoogleMap.isAvailable().then(() => {
 
//         let location = new GoogleMapsLatLng(this.post.latitude, this.post.longitude);
 
//         this.map = new GoogleMap('map', {
//           'backgroundColor': 'white',
//           'controls': {
//             'compass': true,
//             'myLocationButton': true,
//             'indoorPicker': true,
//             'zoom': true
//           },
//           'gestures': {
//             'scroll': true,
//             'tilt': true,
//             'rotate': true,
//             'zoom': true
//           },
//           'camera': {
//             'latLng': location,
//             'tilt': 30,
//             'zoom': 15,
//             'bearing': 50
//           }
//         });
//       });
 
//         this.map.on(GoogleMapsEvent.MAP_READY).subscribe(() => {
//             console.log('Map is ready!');
//         });
 
//     }
constructor(public _navController: NavController, public platform: Platform, public navParams: NavParams) {
  this.post = navParams.get('post');
    this.platform.ready().then(() => this.onPlatformReady());
  }
開發者ID:michaeldemille,項目名稱:SouthernUtahCares,代碼行數:51,代碼來源:maps.ts

示例5: launch

 launch(url) {
   this.platform.ready().then(() => {
     this.inAppBrowser.create(url, '_system');
   });
 }
開發者ID:Rodrigo54,項目名稱:Ola-Mundo-Ionic,代碼行數:5,代碼來源:home.ts

示例6: constructor

  public constructor(platform: Platform) {
    super();
    this.rootPage = SearchPage;
    platform.ready().then(() => this.onReady());

  }
開發者ID:lefreire,項目名稱:ionic,代碼行數:6,代碼來源:app.ts

示例7: constructor

 constructor(public platform: Platform, public storage: Storage, public db: SQLite) {
   console.log("in constructor");
   this.platform.ready().then(() => {
     this.initDB();
   });
 }
開發者ID:alexandrastoica,項目名稱:ionic2-dementia-test-app,代碼行數:6,代碼來源:sqlite.ts

示例8: mailto

 /**
  * opens the mail app with new email to "email"
  * @param email email adress for the message
  */
 mailto(email) {
     this.platform.ready().then(() => {
         open(`mailto:${email}`, '_system', "location=true");
     });
 }
開發者ID:GSE-Project,項目名稱:SS2016-group3,代碼行數:9,代碼來源:about.ts

示例9: openURL

 /**
  * opens the url with the system app if installed or in the browser
  * @param url url of the website
  */
 openURL(url) {
     this.platform.ready().then(() => {
         open(url, "_system", "location=true");
     });
 }
開發者ID:GSE-Project,項目名稱:SS2016-group3,代碼行數:9,代碼來源:about.ts

示例10: initializeApp

  initializeApp() {
   this.platform.ready().then(() => {
     StatusBar.styleDefault();
     Splashscreen.hide();
   });
 }
開發者ID:dekonunes,項目名稱:ConneCT-App,代碼行數:6,代碼來源:app.component.ts


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