dojo

dojo 1.8: Error: Tried to register widget with id==main_bContainer but that id is already registered

匿名 (未验证) 提交于 2019-12-03 02:33:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: Hi I have a simple one as shown below that displays bordercontainer and contentpane. I do not understand why the bordercontainer's id is registered twice since I only have one id defined for bordercontainer. The error stated: Error: Tried to register widget with id==main_bContainer but that id is already registered Please advise where I got it wrong. <!DOCTYPE html> <html> <head> <title>Hello</title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link rel="stylesheet" href="../dojo1_8/dijit/themes/soria/soria.css"/>

MultiSelectCombobox issue in dojo

匿名 (未验证) 提交于 2019-12-03 02:23:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I needed the combobox with checkboxes in front of each option, to select multiple options. I tried using CheckedMultiSelect using "dropdown:true", It shows the value in the combobox like, 2 item(s) selected, 1 item(s) selected,etc when I select items. How to show the values selected in the text area of combobox separated by delimiter?? Should css or HTML or someotherthing has to be changed for checkedMultiSelect?? Thanks in advance. 回答1: As for your second question, you have to extend dojox.form.CheckedMultiSelect class and override

DOJO error when using this.inherited(arguments) in strict mode

匿名 (未验证) 提交于 2019-12-03 02:20:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I am declaring a base "Class" for a Dijit Custom widget. When in 'strict mode' routine this.inherited(arguments) ; is being called, I receive this error: Uncaught TypeError: 'caller', 'callee', and 'arguments' properties may not be accessed on strict mode functions or the arguments objects for calls to them I need to keep the usage 'strict mode'. Any idea how to solve it? define ([ 'dojo/_base/declare' , 'dojo/topic' , 'dojo/_base/lang' ], function ( declare , topic , lang ) { 'use strict' ; var attachTo = 'myPanels' ; return

Dojo require() and AMD (1.7)

允我心安 提交于 2019-12-03 02:07:15
I'm having a heckuva time transitioning to Dojo and the new AMD structure, and I'm really hoping someone can shed some light on the whole concept. I've been living on Google for the last few weeks trying to find information on not the usage, but the structure and design pattern trends in using this. I find it strange that for a relatively complex javascript application, such as for a main page where Dijits need to be created and styled, DOM elements created, etc, that I need to require, and therefore use, a TON of different modules that were otherwise available in the dojo namespace before the

Dojo Toggle Hide and Show Divs

匿名 (未验证) 提交于 2019-12-03 01:47:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I've done some searching and come up with a lot of mixed results for using Dojo to toggle divs showing vs hidden. Some use dojo.style which it looks like might have been replaced by dojo.fx Some use dijit but thus cannot access a DOM node. Some make use of show() and hide() Some change the CSS I can't seem to get any of them to work. Can someone please point me towards an up-to-date walkthru on this. Solved Used a combination of the following... dojo . addOnLoad ( function () { dojo . style ( dojo . byId ( 'myDiv' ), "display" ,

Dojo textBox doesn&#039;t accept whitespace

匿名 (未验证) 提交于 2019-12-03 01:44:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I'm working with no experience on a Dojo project and don't know which version I'm working on. There is a textBox for a search form which doesn't accept whitespace. I searched in this documentation for a solution, but no method seems to be applicable. http://dojotoolkit.org/api/dijit/form/TextBox So my question is: is it possible to accept whitespace in a textBox form or is it just possible with a ValidationTextBox? me.filterBox = new TextBox({ style: 'margin-bottom: 0', class: 'STQuicksearch', trim: false, intermediateChanges: true,

time to display in dropdown lists

匿名 (未验证) 提交于 2019-12-03 01:26:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 由 翻译 强力驱动 问题: I can use jquery or dojo or simple HTML to show hours and minutes in separate dropdown list. Please suggest. Below is the sample code: <input id = "time" data-dojo-type = "dijit/form/TimeTextBox" required = "true" data-dojo-props = "constraints: { timePattern: 'HH:mm:ss', clickableIncrement: 'T00:05:00', visibleIncrement: 'T00:05:00', visibleRange: 'T01:00:00' }" /> 回答1: I don't know much about dojo but i got this far if it helps: Time : < input id = "timeHours" data - dojo - type = "dijit/form/TimeTextBox" required = "true" data -

dojo 1.9: what annotation does declare.safeMixin add?

匿名 (未验证) 提交于 2019-12-03 00:59:01
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I have been reading through the dojo 1.9 documentation about declare.safeMixin() , focusing on the difference between it and lang.mixin . Here is the explanation I found... safeMixin() is a function defined in dojo/declare. It has the same functionality as dojo/_base/lang::mixin(), but additionally it annotates all copied methods compatibly with dojo/declare. This decoration can affect how this.inherited() works in mixed-in methods. I can follow the example but it doesn't really explain exactly what is added and where, can anyone give any

How to update dojo tree data dynamically

血红的双手。 提交于 2019-12-03 00:08:32
I would like to know how ot update the data of the dojo.dijit.tree component dynamically. At the moment I'm creating the tree using dojo.data.ItemFileReadStore and dijit.tree.ForestStoreModel. Once I create the tree, I would like to reload it periodically with new JSON data. This is how I create the tree at the moment: <div dojoType="dojo.data.ItemFileReadStore" jsId="myStore" url=getJSONResult></div> <div dojoType="dijit.tree.ForestStoreModel" jsId="myModel" store="myStore" query="{type:'cat'}" rootId="myRoot" rootLabel="Data" childrenAttrs="children"></div> <div dojoType="dijit.Tree" model=

arcgis投影测试

匿名 (未验证) 提交于 2019-12-02 23:47:01
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>坐标转换测试</title> <link rel="stylesheet" href="http://js.arcgis.com/3.9/js/dojo/dijit/themes/soria/soria.css" /> <link rel="stylesheet" href="http://js.arcgis.com/3.9/js/esri/css/esri.css" /> <style> html, body, #main { padding: 0; margin: 0; width: 100%; height: 100%; } </style> <script src="http://js.arcgis.com/3.9/"></script> <script> var map, gsvc; require(["dojo/parser", "esri/geometry/Extent", "esri/map", "esri/layers/ArcGISTiledMapServiceLayer", "esri/SpatialReference", "esri/tasks/GeometryService", "esri/geometry/webMercatorUtils