Android имеет некоторые проблемы с динамической загрузкой.Это означает, что вам нужно сделать пользовательскую сборку dojo 1.7.1.
. Чтобы создать пользовательскую сборку, вам нужна src версия dojo .
Я расширилФайл профиля "baseplus.profile.js" находится в каталоге "dojo / util / builsscripts / profile /" следующим образом:
dependencies = {
selectorEngine: "acme",
layers: [
{
// This is a specially named layer, literally 'dojo.js'
// adding dependencies to this layer will include the modules
// in addition to the standard dojo.js base APIs.
name: "dojo.js",
dependencies: [
"dijit._Widget",
"dijit._Templated",
"dojo.fx",
"dojo.NodeList-fx",
//this wasn't included in the standard build but necessary
"dojo._firebug.firebug",
//my used dojo requirements
"dojox.mobile.parser",
"dojox.mobile",
"dojox.mobile.Button",
"dojox.mobile.SwapView",
"dojox.mobile.ScrollableView",
"dojox.mobile.TabBar",
"dojox.mobile.SpinWheelTimePicker",
"dojox.mobile.compat"
]
}
],
prefixes: [
["dijit", "../dijit" ],
["dojox", "../dojox" ]
]
}
вам необходимо выполнить build.sh (Unix / OSx) или build.bat (Windows) в оболочке с помощью команды "./build.sh action = release profile = profile / myBaseplus.profile.js -r"
После успешной сборки вы найдете файл dojo.js в"додзе / релиз / djojo / dojo.js".
Вам нужен только этот файл.
Тем не менее, в вашем html-файле вам также понадобится следующее утверждение:
require([
"dojox/mobile/parser", // (Optional) This mobile app uses declarative programming with fast mobile parser
"dojox/mobile", // (Required) This is a mobile app.
"dojox/mobile/Button",
"dojox/mobile/SwapView",
"dojox/mobile/ScrollableView",
"dojox/mobile/TabBar",
"dojox/mobile/SpinWheelTimePicker",
"dojox/mobile/compat" // (Optional) This mobile app supports running on desktop browsers
],
function(parser, mobile, compat){
//Optional module aliases that can then be referenced inside callback block
}
);