changed look of geocoder results a bit (vertical alignment, debug

messages)
This commit is contained in:
DennisSchiefer 2012-07-04 16:15:04 +01:00
parent 314ff97ca0
commit 052f7060c1
2 changed files with 4 additions and 6 deletions

View File

@ -106,8 +106,6 @@ _showResults: function(response, parameters) {
if(i%2==0) { rowstyle='results-body-even'; } if(i%2==0) { rowstyle='results-body-even'; }
html += '<tr class="'+rowstyle+'">'; html += '<tr class="'+rowstyle+'">';
// html += '<td class="results-body-counter"><span">'+(i+1)+'.</span></td>';
// optimally show Nominatim icons instead of numbers
if(!result.icon) if(!result.icon)
result.icon = "http://nominatim.openstreetmap.org/images/mapicons/poi_point_of_interest.glow.12.png"; result.icon = "http://nominatim.openstreetmap.org/images/mapicons/poi_point_of_interest.glow.12.png";
html += '<td class="results-body-counter"><img src="'+ result.icon + '" alt=""/></td>'; html += '<td class="results-body-counter"><img src="'+ result.icon + '" alt=""/></td>';
@ -115,8 +113,8 @@ _showResults: function(response, parameters) {
if(result.display_name){ if(result.display_name){
html += '<div class="results-body-item" onclick="OSRM.Geocoder._onclickResult(\''+parameters.marker_id+'\', '+result.lat+', '+result.lon+');">'+result.display_name; html += '<div class="results-body-item" onclick="OSRM.Geocoder._onclickResult(\''+parameters.marker_id+'\', '+result.lat+', '+result.lon+');">'+result.display_name;
// optionally show osm_type, class, type // debug output to show osm_type, class, type
html += '<br/><span class="results-body-item-remark small-font">[osm_type: ' + result.osm_type + ', class: ' + result.class + ', type: ' + result.type + ']</span>'; // html += '<br/><span class="results-body-item-remark small-font">[osm_type: ' + result.osm_type + ', class: ' + result.class + ', type: ' + result.type + ']</span>';
html += '</div>'; html += '</div>';
} }
html += "</td></tr>"; html += "</td></tr>";

View File

@ -327,14 +327,14 @@ html, body {
.results-body-counter .results-body-counter
{ {
text-align:right; text-align:right;
vertical-align:top; vertical-align:middle;
font-weight:bold; font-weight:bold;
padding:1px 5px 1px 5px; padding:1px 5px 1px 5px;
} }
.results-body-items .results-body-items
{ {
text-align:left; text-align:left;
vertical-align: middle; vertical-align:top;
width:100%; width:100%;
padding:1px; padding:1px;
} }