mirror of
https://github.com/FoggedLens/iD.git
synced 2026-02-12 16:52:50 +00:00
edit.* ControllerState documentation
This commit is contained in:
@@ -11,9 +11,14 @@ declare("iD.controller.edit.EditBaseState", [iD.controller.ControllerState], {
|
||||
editortooltip: null,
|
||||
|
||||
constructor:function() {
|
||||
// summary: Base state for the 'Edit object' states - where an object is selected and the user is making changes to it.
|
||||
},
|
||||
|
||||
openEditorTooltip:function(x,y,entity) {
|
||||
// summary: Open the initial 'Edit tags/Edit shape' tooltip.
|
||||
// x: Number Screen co-ordinate.
|
||||
// y: Number Screen co-ordinate.
|
||||
// entity: iD.Entity The entity to be edited.
|
||||
var h=entity.friendlyName(); h = (h=='') ? h : h+"<br/>";
|
||||
this.editortooltip = new dijit.TooltipDialog({
|
||||
content: h+"<button data-dojo-type='dijit.form.Button' type='submit'>Edit tags</button> "
|
||||
@@ -24,6 +29,7 @@ declare("iD.controller.edit.EditBaseState", [iD.controller.ControllerState], {
|
||||
},
|
||||
|
||||
closeEditorTooltip:function() {
|
||||
// summary: Close the tooltip.
|
||||
if (this.editortooltip) { dijit.popup.close(this.editortooltip); }
|
||||
},
|
||||
|
||||
|
||||
@@ -8,11 +8,12 @@ define(['dojo/_base/declare',
|
||||
], function(declare){
|
||||
|
||||
// ----------------------------------------------------------------------
|
||||
// ControllerState base class
|
||||
// edit.NoSelection class
|
||||
|
||||
declare("iD.controller.edit.NoSelection", [iD.controller.edit.EditBaseState], {
|
||||
|
||||
constructor:function() {
|
||||
// summary: In 'Edit object' mode but nothing selected.
|
||||
},
|
||||
|
||||
enterState:function() {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
define(['dojo/_base/declare','iD/controller/edit/EditBaseState'], function(declare){
|
||||
|
||||
// ----------------------------------------------------------------------
|
||||
// SelectedPOINode class
|
||||
// edit.SelectedPOINode class
|
||||
|
||||
declare("iD.controller.edit.SelectedPOINode", [iD.controller.edit.EditBaseState], {
|
||||
|
||||
@@ -11,6 +11,7 @@ declare("iD.controller.edit.SelectedPOINode", [iD.controller.edit.EditBaseState]
|
||||
nodeUI: null,
|
||||
|
||||
constructor:function(_node) {
|
||||
// summary: In 'Edit object' mode and a POI node is selected.
|
||||
this.node=_node;
|
||||
},
|
||||
enterState:function() {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
define(['dojo/_base/declare','iD/controller/edit/EditBaseState'], function(declare){
|
||||
|
||||
// ----------------------------------------------------------------------
|
||||
// SelectedWay class
|
||||
// edit.SelectedWay class
|
||||
|
||||
declare("iD.controller.edit.SelectedWay", [iD.controller.edit.EditBaseState], {
|
||||
|
||||
@@ -12,6 +12,7 @@ declare("iD.controller.edit.SelectedWay", [iD.controller.edit.EditBaseState], {
|
||||
entryevent: null,
|
||||
|
||||
constructor:function(_way,_event) {
|
||||
// summary: In 'Edit object' mode and a way is selected.
|
||||
this.way=_way;
|
||||
this.entryevent=_event;
|
||||
},
|
||||
|
||||
@@ -11,6 +11,7 @@ declare("iD.controller.edit.SelectedWayNode", [iD.controller.edit.EditBaseState]
|
||||
way: null,
|
||||
|
||||
constructor:function(_node,_way) {
|
||||
// summary: In 'Edit object' mode and a node in a way is selected.
|
||||
this.node=_node;
|
||||
this.way=_way;
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user