MCPcopy Create free account
hub / github.com/baumgarr/nixnote2 / locationText

Method locationText

dialog/locationdialog.cpp:91–108  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89}
90
91QString LocationDialog::locationText() {
92 double lat = latitude.text().toDouble();
93 QString p1 = calculateDegrees(lat);
94 if (lat>=0)
95 p1 = p1+" N ";
96 else
97 p1 = p1+" S ";
98
99 double lon = longitude.text().toDouble();
100 QString p2 = calculateDegrees(lon);
101 if (lon>=0)
102 p2 = p2+" E";
103 else
104 p2 = p2+" W";
105 return p1+p2;
106
107
108}
109
110
111QString LocationDialog::calculateDegrees(double value) {

Callers 2

buttonClickedMethod · 0.80
setGeographyMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected