Commit Graph

489 Commits

Author SHA1 Message Date
Bryan Housel
6aa4b3a873 Merge branch 'keyboard_shortcuts' of https://github.com/rhokbrisbane/iD into rhokbrisbane-keyboard_shortcuts 2015-06-15 22:32:20 -04:00
Rowan Hogan
336f7420e5 Merge branch master into add-task-outline-to-minimap 2015-06-15 10:14:07 +10:00
Rowan Hogan
42c99a4400 Merge branch 'master' into keyboard_shortcuts 2015-06-15 10:12:31 +10:00
Denys Digtiar
be1e3738f1 Error handling is added to the GPX loading callback.
Previously erroneous response was corrupting the GpxLayer, which could
potential corrupt the whole Map, if user were to use 'Zoom to GPX'
feature. Callback logic is wrapped in the error guard to fix this.
2015-06-14 16:46:20 -07:00
Rowan Hogan
5c860be877 Moved minimap gpx layer methods to the background gpx layer handlers 2015-06-14 12:37:37 +10:00
Rowan Hogan
9aa1ffa227 Adds increased zoom keyboard shortcuts. 2015-06-13 15:24:48 +10:00
Pierre GIRAUD
71061a4f5e Better look for mapillary markers 2015-06-12 16:52:20 +02:00
Bryan Housel
00c0641f06 Make view extent include both local and remote versions of the change 2015-04-27 10:16:47 -04:00
Olaf Veerman
89b354ddba Allow overzoom to be set on overlays
The default behaviour is to overzoom overlays past their max
scaleExtent. When 'overzoom':false is defined in imagery.json,
the layer will disappear on the max scaleExtent.
2015-03-26 12:04:54 -07:00
Bryan Housel
05ff86e5c2 Prevent no-match parent relations from breaking getMatches
(e.g. a site relation with a fence in it)
Also, updated the test graph to contain one of these.
see https://github.com/openstreetmap/iD/pull/2554#issuecomment-78517442
2015-03-12 13:59:48 -04:00
Bryan Housel
3308b5507b Feature Filtering: don't match multipolygon lines as 'others'
(fixes #2548)

If the entity is a way that is a member of a parent relation,
use that parent relation's matches instead of matching 'other'
2015-03-10 00:06:29 -04:00
Bryan Housel
848d19a116 Don't cache array lengths
see https://github.com/openstreetmap/iD/pull/2489#discussion_r22489237
2015-03-09 18:02:05 -04:00
Bryan Housel
2485d74d5b Use interpolated D3 zooming for zoomIn/zoomOut 2015-03-09 16:34:07 -04:00
Bryan Housel
b4cd1d67d8 Adjust double click handler for new D3 zoom behavior
D3 v3.5+ has changed the zoom behavior to emit tweened zoom events
rather than a single zoom event with a dblclick source event.
2015-03-07 15:22:37 -05:00
Bryan Housel
1f0087d133 Merge pull request #2525 from openstreetmap/conflict-resolution
Merge Conflict Resolution
2015-03-05 19:49:15 -05:00
Bryan Housel
98665fef91 Don't allow zoomTo on an entity with degenrate extent
(because sending the map to NaN/NaN/NaN is not cool)
2015-02-28 23:00:00 -05:00
Bryan Housel
29e1554d5f accessor to expose _features internals 2015-02-26 16:08:39 -05:00
Bryan Housel
861bd14903 map#trimmedExtentZoom
Like map#extentZoom, but uses trimmed viewport instead of full viewport
to avoid putting the extent under UI buttons and border elements.

This is because in conflict resolution the user will be extentZooming to see
their changes and it was annoying to have the change appear under the UI.

Also using this in zoomToGPXLayer.
2015-02-20 14:59:40 -05:00
samanpwbb
d141827c3e Merge branch 'master' into conflict-resolution-ui 2015-02-06 19:08:50 -05:00
peterneubauer
2c732d5ed7 removing log 2015-02-06 10:39:42 +02:00
peterneubauer
f3e9b0f434 upgrading to Mapillary API v2 cals 2015-02-06 10:37:30 +02:00
Bryan Housel
ef2d6e75cf Add minzoom check to map.zoom() (closes #2499) 2015-01-13 23:09:19 -05:00
Bryan Housel
ed4929273d Return entities from iD.Connection via callbacks
(instead of dispatching `load` event to merge them into `history`)

This is cleaner becuase now `context` doesn't need to keep an
`altGraph` state used only for Conflict Resolution.

The conflict resolution code calls the `iD.Connection` methods directly,
and other places in the code call `loadEntity` and `loadTiles` wrappers
that merge the entities into the main history.
2015-01-08 14:44:58 -05:00
Bryan Housel
93b505259f Mode change code in editOff no longer needed..
(because iD.modes.Select listens for drawn event and knows to exit itself)
2014-12-15 16:16:46 -05:00
Bryan Housel
3e391e87df don't try to call Entity#geometry for midpoints 2014-11-21 10:58:32 -05:00
Bryan Housel
dfe8fd1e90 features performance enhancements
1. reusue entity.geometry where possible
2. cache entity parents
2014-11-18 22:05:08 -05:00
John Firebaugh
d444c907e8 Style 2014-11-11 15:12:08 -08:00
Sajjad Anwar
17fb2f64e5 Configurable minimum editable zoom 2014-11-11 14:37:11 -08:00
John Firebaugh
916a901b8f Show all features as auto-hidden when map is not editable 2014-11-11 14:16:16 -08:00
Bryan Housel
2024e2333d Exit select mode if selected DOM elements have disappeared 2014-11-10 23:23:28 -05:00
Bryan Housel
af3c307b17 cache invalidation and naming things 2014-11-10 22:47:07 -05:00
Bryan Housel
c6ca68ce80 create feature _cache to store matches per entity
also remove old commented code
2014-11-08 00:19:36 -05:00
Bryan Housel
d5879fa855 reuse _stats, don't count vertices and relations 2014-11-06 23:04:25 -05:00
Bryan Housel
55e6f9ec93 faster tests for certain geometry (vertex, point) 2014-11-06 12:54:58 -05:00
Bryan Housel
0d6d4b3d24 remove footer "features hidden" warning in editOff 2014-11-06 00:33:45 -05:00
Bryan Housel
788dedc595 more performance improvements for feature filters
* use named filter functions for easier profiling
* remove some unnecessary line/area geometry checks
* replace some lodash code with for loops
* reorder some tests to put cheap condition early
2014-11-06 00:18:45 -05:00
Bryan Housel
2f6004fcfa performance tuning work-in-progress
* store entity's matched features in a graph transient
* replace fn calls to get commonly used _keys and _hidden arrays
* replace lodash calls with faster for loops (in some places)
* always pass graph/resolver as a param
2014-11-05 00:27:14 -05:00
Bryan Housel
c941bd5a4b 2 things related to gatherStats auto-hiding..
* skip gatherStats on differenced redraws..
* force full redraw when gatherStats autohides/unhides features
  (before: extent redraws would happen, counts would update,
   but buildings/points would stay on the screen)
2014-10-31 11:58:02 -04:00
Bryan Housel
6b31eab5a7 Deselect features that are hidden.. 2014-10-30 15:01:03 -04:00
Bryan Housel
b20f1495de restore toggle function and add test 2014-10-29 15:06:43 -04:00
Bryan Housel
927c533bb4 add feature tests for auto-hiding 2014-10-28 21:37:04 -04:00
Bryan Housel
43f1cdd3eb decoupled graph from context for better testing
fixed feature matching tests for vertices and relations
2014-10-28 21:37:04 -04:00
Bryan Housel
2b260f9a6c added tests for feature filtering
(some tests failing because I need to decouple graph from context)
2014-10-28 21:37:04 -04:00
Bryan Housel
6b6ca8d523 initial checkin of features unit tests 2014-10-28 21:37:04 -04:00
Bryan Housel
7d9b267858 Show auto-hidden features as disabled checkboxes with tooltip
also rearrange map data panel to put features last
2014-10-28 21:37:03 -04:00
Bryan Housel
a085ce6dc8 Don't hide features that the user just created 2014-10-28 21:37:03 -04:00
Bryan Housel
9666af30c6 better point/building culling based on viewport size 2014-10-28 21:37:03 -04:00
Bryan Housel
e761414a15 'Rail' feature filter should not match if it is also a highway. 2014-10-28 21:37:02 -04:00
Bryan Housel
dcc9812986 prevent most operations on things connected to hidden features.. 2014-10-28 21:37:02 -04:00
Bryan Housel
670c228fc7 put layer-gpx after layer-data
(closes #2352, #2335)
2014-10-28 21:37:01 -04:00