76 m_address.setValueBypassingBindings(
new QDeclarativeGeoAddress(src.address(),
this));
91void QDeclarativeGeoLocation::setLocation(
const QGeoLocation &src)
93 if (m_address && m_address->parent() ==
this) {
94 m_address->setAddress(src.address());
95 }
else if (!m_address || m_address->parent() !=
this) {
96 m_address.setValue(
new QDeclarativeGeoAddress(src.address(),
this));
100 setCoordinate(src.coordinate());
101 setBoundingShape(src.boundingShape());
102 setExtendedAttributes(src.extendedAttributes());
105QGeoLocation QDeclarativeGeoLocation::location()
const
107 QGeoLocation retValue;
108 retValue.setAddress(m_address ? m_address->address() : QGeoAddress());
109 retValue.setCoordinate(m_coordinate);
110 retValue.setBoundingShape(m_boundingShape);
111 retValue.setExtendedAttributes(m_extendedAttributes);
120void QDeclarativeGeoLocation::setAddress(QDeclarativeGeoAddress *address)
122 m_address.removeBindingUnlessInWrapper();
124 const QDeclarativeGeoAddress *oldAddress = m_address.valueBypassingBindings();
125 if (oldAddress == address)
131 m_address.setValueBypassingBindings(address);
133 if (oldAddress && (oldAddress->parent() ==
this))