… | |
… | |
949 | if (slr != NULL) |
949 | if (slr != NULL) |
950 | { |
950 | { |
951 | if (slr->street != NULL) |
951 | if (slr->street != NULL) |
952 | if ((street_name != NULL)&&(slr->street->name != NULL)) |
952 | if ((street_name != NULL)&&(slr->street->name != NULL)) |
953 | { |
953 | { |
|
|
954 | |
954 | if (strcmp(slr->street->name, street_name)==0) |
955 | if (strcmp(slr->street->name, street_name)==0) |
955 | { |
956 | { |
956 | char *buffer; |
957 | char *buffer; |
957 | // coords of result |
958 | // coords of result |
958 | c.x=slr->house_number->common.c->x; |
959 | c.x=slr->house_number->common.c->x; |
… | |
… | |
1541 | } |
1542 | } |
1542 | else |
1543 | else |
1543 | { |
1544 | { |
1544 | buffer=g_strdup_printf("TWN:H%dL%d:%f:%f:%.7s %.101s",p->common.item.id_hi,p->common.item.id_lo,g.lat,g.lng,p->common.postal,p->common.town_name); |
1545 | buffer=g_strdup_printf("TWN:H%dL%d:%f:%f:%.7s %.101s",p->common.item.id_hi,p->common.item.id_lo,g.lat,g.lng,p->common.postal,p->common.town_name); |
1545 | } |
1546 | } |
1546 | #ifdef HAVE_API_ANDROID |
1547 | #ifdef HAVE_API_ANDROID |
1547 | // return results to android as they come in ... |
1548 | // return results to android as they come in ... |
1548 | android_return_search_result(jni,buffer); |
1549 | android_return_search_result(jni,buffer); |
1549 | #endif |
1550 | #endif |
1550 | } |
1551 | } |
1551 | phrases=g_list_next(phrases); |
1552 | phrases=g_list_next(phrases); |
1552 | |
1553 | |
1553 | } |
1554 | } |
1554 | if (buffer) |
1555 | if (buffer) |
… | |
… | |
1597 | else |
1598 | else |
1598 | { |
1599 | { |
1599 | buffer=g_strdup_printf("STR:H%dL%d:%f:%f:%.7s %.101s",p->common.item.id_hi,p->common.item.id_lo,g.lat,g.lng,p->common.postal,attr.u.str); |
1600 | buffer=g_strdup_printf("STR:H%dL%d:%f:%f:%.7s %.101s",p->common.item.id_hi,p->common.item.id_lo,g.lat,g.lng,p->common.postal,attr.u.str); |
1600 | } |
1601 | } |
1601 | //dbg(0,"street3=%s\n",buffer); |
1602 | //dbg(0,"street3=%s\n",buffer); |
1602 | #ifdef HAVE_API_ANDROID |
1603 | #ifdef HAVE_API_ANDROID |
1603 | // return results to android as they come in ... |
1604 | // return results to android as they come in ... |
1604 | android_return_search_result(jni,buffer); |
1605 | android_return_search_result(jni,buffer); |
1605 | #endif |
1606 | #endif |
1606 | } |
1607 | } |
1607 | phrases=g_list_next(phrases); |
1608 | phrases=g_list_next(phrases); |
1608 | } |
1609 | } |
1609 | if (buffer) |
1610 | if (buffer) |
1610 | { |
1611 | { |
… | |
… | |
1642 | } |
1643 | } |
1643 | else |
1644 | else |
1644 | { |
1645 | { |
1645 | buffer=g_strdup_printf("STR:H%dL%d:%f:%f:%.7s %.101s",p->common.item.id_hi,p->common.item.id_lo,g.lat,g.lng,p->common.postal,attr.u.str); |
1646 | buffer=g_strdup_printf("STR:H%dL%d:%f:%f:%.7s %.101s",p->common.item.id_hi,p->common.item.id_lo,g.lat,g.lng,p->common.postal,attr.u.str); |
1646 | } |
1647 | } |
1647 | #ifdef HAVE_API_ANDROID |
1648 | #ifdef HAVE_API_ANDROID |
1648 | // return results to android as they come in ... |
1649 | // return results to android as they come in ... |
1649 | android_return_search_result(jni,buffer); |
1650 | android_return_search_result(jni,buffer); |
1650 | #endif |
1651 | #endif |
1651 | } |
1652 | } |
1652 | phrases=g_list_next(phrases); |
1653 | phrases=g_list_next(phrases); |
1653 | } |
1654 | } |
1654 | if (buffer) |
1655 | if (buffer) |
1655 | { |
1656 | { |