From ad0efa4931527c9da087148cfbaa2b688345faa9 Mon Sep 17 00:00:00 2001 From: John Firebaugh Date: Fri, 14 Dec 2012 14:39:38 -0800 Subject: [PATCH] Place -> Point We decided to use geometric terms for the modes. --- css/app.css | 8 ++++---- index.html | 2 +- js/id/id.js | 4 ++-- js/id/modes/{add_place.js => add_point.js} | 18 +++++++++--------- test/index.html | 4 ++-- test/index_packaged.html | 2 +- test/spec/modes/{add_place.js => add_point.js} | 4 ++-- 7 files changed, 21 insertions(+), 21 deletions(-) rename js/id/modes/{add_place.js => add_point.js} (64%) rename test/spec/modes/{add_place.js => add_point.js} (93%) diff --git a/css/app.css b/css/app.css index 10ebb095a..49008388d 100644 --- a/css/app.css +++ b/css/app.css @@ -126,7 +126,7 @@ a.selected { cursor:url(../img/cursor-draw.png) 9 9, auto; } -#map.add-place:hover { +#map.add-point:hover { cursor:url(../img/cursor-draw-marker.png) 18 18, auto; } @@ -295,7 +295,7 @@ button.action .label { /* Definitions for every icon */ .icon.browse { background-position: 0px 0px;} -.icon.add-place { background-position: -20px 0px;} +.icon.add-point { background-position: -20px 0px;} .icon.add-line { background-position: -40px 0px;} .icon.add-area { background-position: -60px 0px;} .icon.undo { background-position: -80px 0px;} @@ -312,7 +312,7 @@ button.action .label { .icon.layers { background-position: -300px 0px;} /*.active .icon.browse { background-position: 0px -20px;} -.active .icon.add-place { background-position: -20px -20px;} +.active .icon.add-point { background-position: -20px -20px;} .active .icon.add-line { background-position: -40px -20px;} .active .icon.add-area { background-position: -60px -20px;} .active .icon.undo { background-position: -80px -20px;} @@ -329,7 +329,7 @@ button.action .label { .active .icon.layers { background-position: -300px -20px;}*/ button[disabled] .icon.browse { background-position: 0px -40px;} -button[disabled] .icon.add-place { background-position: -20px -40px;} +button[disabled] .icon.add-point { background-position: -20px -40px;} button[disabled] .icon.add-line { background-position: -40px -40px;} button[disabled] .icon.add-area { background-position: -60px -40px;} button[disabled] .icon.undo { background-position: -80px -40px;} diff --git a/index.html b/index.html index 51ddec95d..7c7e3e703 100644 --- a/index.html +++ b/index.html @@ -64,7 +64,7 @@ - + diff --git a/js/id/id.js b/js/id/id.js index 853d258c8..9b7844a13 100644 --- a/js/id/id.js +++ b/js/id/id.js @@ -29,7 +29,7 @@ window.iD = function(container) { .attr('class', 'buttons-joined'); var buttons = buttons_joined.selectAll('button.add-button') - .data([iD.modes.Browse(), iD.modes.AddPlace(), iD.modes.AddLine(), iD.modes.AddArea()]) + .data([iD.modes.Browse(), iD.modes.AddPoint(), iD.modes.AddLine(), iD.modes.AddArea()]) .enter().append('button') .attr('class', function (mode) { return mode.title + ' add-button'; }) .attr('data-original-title', function (mode) { return mode.description; }) @@ -198,7 +198,7 @@ window.iD = function(container) { controller.enter(iD.modes.AddArea()); }) .on('p', function(evt, mods) { - controller.enter(iD.modes.AddPlace()); + controller.enter(iD.modes.AddPoint()); }) .on('r', function(evt, mods) { controller.enter(iD.modes.AddLine()); diff --git a/js/id/modes/add_place.js b/js/id/modes/add_point.js similarity index 64% rename from js/id/modes/add_place.js rename to js/id/modes/add_point.js index 153369ad7..87382d697 100644 --- a/js/id/modes/add_place.js +++ b/js/id/modes/add_point.js @@ -1,7 +1,7 @@ -iD.modes.AddPlace = function() { +iD.modes.AddPoint = function() { var mode = { - id: 'add-place', - title: 'Place', + id: 'add-point', + title: 'Point', description: 'Restaurants, monuments, and postal boxes are points.' }; @@ -12,27 +12,27 @@ iD.modes.AddPlace = function() { history = mode.history, controller = mode.controller; - map.hint('Click on the map to add a place.'); + map.hint('Click on the map to add a point.'); - map.surface.on('click.addplace', function() { + map.surface.on('click.addpoint', function() { var node = iD.Node({loc: map.mouseCoordinates(), _poi: true}); history.perform( iD.actions.AddNode(node), - 'added a place'); + 'added a point'); controller.enter(iD.modes.Select(node)); }); - map.keybinding().on('⎋.addplace', function() { + map.keybinding().on('⎋.addpoint', function() { controller.exit(); }); }; mode.exit = function() { mode.map.hint(false); - mode.map.surface.on('click.addplace', null); - mode.map.keybinding().on('⎋.addplace', null); + mode.map.surface.on('click.addpoint', null); + mode.map.keybinding().on('⎋.addpoint', null); d3.select('#map').attr('class', null); }; diff --git a/test/index.html b/test/index.html index c583acee9..cdff46673 100644 --- a/test/index.html +++ b/test/index.html @@ -63,7 +63,7 @@ - + @@ -110,7 +110,7 @@ - + diff --git a/test/index_packaged.html b/test/index_packaged.html index 2fdd8ab0f..5b99099b2 100644 --- a/test/index_packaged.html +++ b/test/index_packaged.html @@ -46,7 +46,7 @@ - + diff --git a/test/spec/modes/add_place.js b/test/spec/modes/add_point.js similarity index 93% rename from test/spec/modes/add_place.js rename to test/spec/modes/add_point.js index 71cbfccd6..fa1779545 100644 --- a/test/spec/modes/add_place.js +++ b/test/spec/modes/add_point.js @@ -1,4 +1,4 @@ -describe("iD.modes.AddPlace", function () { +describe("iD.modes.AddPoint", function () { var container, map, history, controller, mode; beforeEach(function () { @@ -9,7 +9,7 @@ describe("iD.modes.AddPlace", function () { container.call(map); - mode = iD.modes.AddPlace(); + mode = iD.modes.AddPoint(); controller.enter(mode); });