我使用Sencha Touch 2.3.X和Architect制作的移动应用程序不想在我的Android设备上启动(显示蓝色待处理的sencha屏幕),但它在我的桌面浏览器中运行良好。
这是我的app.js:
// @require @packageOverrides
Ext.Loader.setConfig({
});
Ext.application({
models: [
'Business'
],
stores: [
'BusinessStore'
],
views: [
'MainView',
'LoginForm',
'MainNavInterventions',
'ListContainerInterventions',
'ListContainerMaintenances',
'MainNavMaintenances',
'Carousel',
'HomeContainer',
'MainNavHome',
'DetailPanelView',
'MainNavPetitstravaux',
'ListContainerPetitsTravaux'
],
requires: [
'Ext.MessageBox'
],
controllers: [
'Account',
'Business'
],
name: 'Kone',
launch: function() {
Ext.create('Kone.view.Carousel', {fullscreen: true});
}
});
这是我的观点:Carousel.js:
Ext.define('Kone.view.Carousel', {
extend: 'Ext.carousel.Carousel',
alias: 'widget.carousel',
requires: [
'Kone.view.MainNavHome',
'Kone.view.MainNavInterventions',
'Kone.view.MainNavMaintenances',
'Kone.view.MainNavPetitstravaux'
],
config: {
id: 'carousel',
itemId: 'carousel',
items: [
{
xtype: 'mainnavhome',
centered: false
},
{
xtype: 'mainnavinterventions'
},
{
xtype: 'mainnavmaintenances',
itemId: 'mainnavmaintenances'
},
{
xtype: 'mainnavpetitstravaux',
itemId: 'mainnavpetitstravaux'
}
]
}
});
这是我的轮播项目观点:
MainNavHome.js:
Ext.define('Kone.view.MainNavHome', {
extend: 'Ext.navigation.View',
alias: 'widget.mainnavhome',
requires: [
'Kone.view.HomeContainer'
],
config: {
id: '',
items: [
{
xtype: 'homecontainer',
title: 'Tableau de bord'
}
]
}
});
MainNavInterventions.js:
Ext.define('Kone.view.MainNavInterventions', {
extend: 'Ext.navigation.View',
alias: 'widget.mainnavinterventions',
requires: [
'Kone.view.ListContainerInterventions'
],
config: {
id: 'mainnavinterventions',
itemId: 'mainnavinterventions',
useTitleForBackButtonText: true,
items: [
{
xtype: 'listcontainerinterventions',
title: 'Interventions'
}
]
}
});
MainNavMaintenances.js:
Ext.define('Kone.view.MainNavMaintenances', {
extend: 'Ext.navigation.View',
alias: 'widget.mainnavmaintenances',
requires: [
'Kone.view.ListContainerMaintenances'
],
config: {
itemId: 'mynavigationview1',
useTitleForBackButtonText: true,
items: [
{
xtype: 'listcontainermaintenances',
title: 'Maintenances'
}
]
}
});
MainNavPetitsTravaux.js:
Ext.define('Kone.view.MainNavPetitstravaux', {
extend: 'Ext.navigation.View',
alias: 'widget.mainnavpetitstravaux',
requires: [
'Kone.view.ListContainerPetitsTravaux'
],
config: {
useTitleForBackButtonText: true,
items: [
{
xtype: 'listContainerPetitsTravaux',
title: 'Petits Travaux'
}
]
}
});
这是我得到的Eclipse Android错误:
01-02 14:18:50.015: D/CordovaActivity(8109): CordovaActivity.init()
01-02 14:18:50.020: D/CordovaWebView(8109): >>> loadUrl(file:///android_asset/www/index.html)
01-02 14:18:50.020: D/PluginManager(8109): init()
01-02 14:18:50.025: D/CordovaWebView(8109): >>> loadUrlNow()
01-02 14:18:50.025: D/Whitelist(8109): Unlimited access to network resources
01-02 14:18:50.030: I/CordovaLog(8109): Found start page location: index.html
01-02 14:18:50.030: I/CordovaLog(8109): Changing log level to DEBUG(3)
01-02 14:18:50.030: D/CordovaActivity(8109): Resuming the App
01-02 14:18:50.030: D/CordovaActivity(8109): CB-3064: The errorUrl is null
01-02 14:18:50.050: D/SoftKeyboardDetect(8109): Ignore this event
01-02 14:18:50.060: D/libEGL(8109): loaded /system/lib/egl/libEGL_mali.so
01-02 14:18:50.065: D/libEGL(8109): loaded /system/lib/egl/libGLESv1_CM_mali.so
01-02 14:18:50.070: D/libEGL(8109): loaded /system/lib/egl/libGLESv2_mali.so
01-02 14:18:50.075: E/(8109): Device driver API match
01-02 14:18:50.075: E/(8109): Device driver API version: 17
01-02 14:18:50.075: E/(8109): User space API version: 17
01-02 14:18:50.075: E/(8109): mali: REVISION=Linux-r3p1-01rel1 BUILD_DATE=Tue Jul 2 15:06:24 KST 2013
01-02 14:18:50.115: E/(8109): netstack: LIB_MGR - Error loading lib libdnshostprio.so
01-02 14:18:50.115: E/(8109): netstack: STAT_HUB - Failed to load plugin: libdnshostprio.so
01-02 14:18:50.115: E/(8109): netstack: LIB_MGR - Error loading lib spl_proc_plugin.so
01-02 14:18:50.115: E/(8109): netstack: STAT_HUB - Failed to load plugin: spl_proc_plugin.so
01-02 14:18:50.115: E/(8109): netstack: LIB_MGR - Error loading lib pp_proc_plugin.so
01-02 14:18:50.115: E/(8109): netstack: STAT_HUB - Failed to load plugin: pp_proc_plugin.so
01-02 14:18:50.115: E/(8109): netstack: STAT_HUB - App com.capgemini.poc.kone isn't supported
01-02 14:18:50.115: D/(8109): dl error message dlopen failed: library "libtcpfinaggr.so" not found
01-02 14:18:50.115: D/Socket_Pool(8109): Failed to create TCP Fin Aggregation interface.
01-02 14:18:50.115: D/Socket_Pool(8109): netstack: CloseUnusedSockets is ON
01-02 14:18:50.115: D/Socket_Pool(8109): netstack: system net.statistics value: 0
01-02 14:18:50.115: D/Socket_Pool(8109): Failed to create TCP Fin Aggregation interface.
01-02 14:18:50.115: D/Socket_Pool(8109): netstack: CloseUnusedSockets is ON
01-02 14:18:50.115: D/Socket_Pool(8109): netstack: system net.statistics value: 0
01-02 14:18:50.120: D/(8109): external/chromium/net/http/http_getzip_factory.cc: Failed to construct GETzip manager, didn't find the library!
01-02 14:18:50.130: D/OpenGLRenderer(8109): Enabling debug mode 0
01-02 14:18:50.160: D/CordovaActivity(8109): onMessage(onPageStarted,file:///android_asset/www/index.html)
01-02 14:18:50.160: D/SoftKeyboardDetect(8109): Ignore this event
01-02 14:18:50.570: D/SoftKeyboardDetect(8109): Ignore this event
01-02 14:18:51.665: D/CordovaWebViewClient(8109): onPageFinished(file:///android_asset/www/index.html)
01-02 14:18:51.665: D/CordovaActivity(8109): onMessage(onPageFinished,file:///android_asset/www/index.html)
01-02 14:18:52.300: D/CordovaLog(8109): file:///android_asset/www/app.js: Line 1 : Uncaught TypeError: Cannot call method 'substring' of undefined
01-02 14:18:52.300: E/Web Console(8109): Uncaught TypeError: Cannot call method 'substring' of undefined at file:///android_asset/www/app.js:1
01-02 14:18:52.310: E/cutils-trace(8109): Error opening trace file: No such file or directory (2)
01-02 14:18:53.670: D/CordovaActivity(8109): onMessage(spinner,stop)
01-02 14:18:53.755: D/TilesManager(8109): Starting TG #0, 0x5905f970
01-02 14:18:53.755: D/TilesManager(8109): new EGLContext from framework: 57a892f8
01-02 14:18:53.755: D/GLWebViewState(8109): Reinit shader
01-02 14:18:53.820: D/GLWebViewState(8109): Reinit transferQueue
我没有发布我的控制器,因为应用程序在禁用我的数据提取时也不想显示DOM ..
奇怪但是当我将我的sencha应用程序复制到Android Web服务器并尝试使用谷歌Chrome Android启动我的应用程序时,它可以工作..
可能是我的sencha应用程序生成使用phonegap做得很糟糕,我这样做是为了生成一个sencha / phonegap应用程序:
我错了吗?
答案 0 :(得分:0)
解决了它重新安装Sencha CMD并获得最新版本的Architect并使用WAMP服务器而不是Sencha CMD Server ..
坏。
答案 1 :(得分:0)
可能修复的是,最新版本的Architect恰当地包含了之前未包含的基类。在浏览器中,应用程序能够延迟加载依赖项,但正如人们所期望的那样,这在设备上不起作用。