Permalink
Browse files

Inital opensource commit.

  • Loading branch information...
0 parents commit 71d73b2dbb29abf6ee11631cc74c4276e1d960b1 @ondrap committed Jan 28, 2010
Showing with 289,971 additions and 0 deletions.
  1. +11 −0 .gitignore
  2. +6 −0 LINUX-udev
  3. +32 −0 Makefile
  4. +14,976 −0 cities/austria.txt
  5. +41 −0 cities/builddb.py
  6. BIN cities/cities.csv.bz2
  7. +17,219 −0 cities/czech.txt
  8. +66,349 −0 cities/french.txt
  9. +70,457 −0 cities/germany.txt
  10. +18,627 −0 cities/hungary.txt
  11. +20,560 −0 cities/italy.txt
  12. +17,341 −0 cities/lithuania.txt
  13. +6,775 −0 cities/slovakia.txt
  14. +4,901 −0 cities/slovenia.txt
  15. +31,486 −0 cities/spain.txt
  16. +3,603 −0 cities/switzerland.txt
  17. +11 −0 extension/chrome.manifest
  18. +18 −0 extension/chrome/content/about.xul
  19. BIN extension/chrome/content/cbox-check.png
  20. BIN extension/chrome/content/cbox-uncheck.png
  21. BIN extension/chrome/content/cil.png
  22. +241 −0 extension/chrome/content/countries.js
  23. BIN extension/chrome/content/down.png
  24. +562 −0 extension/chrome/content/fgmap.xbl
  25. +13 −0 extension/chrome/content/firsthelp.xul
  26. +263 −0 extension/chrome/content/flightclaim.js
  27. +610 −0 extension/chrome/content/flighttree.js
  28. +100 −0 extension/chrome/content/fprofile.css
  29. +1,552 −0 extension/chrome/content/fprofile.xbl
  30. BIN extension/chrome/content/glider.png
  31. +1 −0 extension/chrome/content/gliders.js
  32. +50 −0 extension/chrome/content/gps_linux.html
  33. +244 −0 extension/chrome/content/gpstree.js
  34. +32 −0 extension/chrome/content/help.xul
  35. BIN extension/chrome/content/left.png
  36. +45 −0 extension/chrome/content/main.css
  37. +231 −0 extension/chrome/content/main.js
  38. +394 −0 extension/chrome/content/main.xul
  39. +7 −0 extension/chrome/content/newtrack.css
  40. +510 −0 extension/chrome/content/newtrack.js
  41. +313 −0 extension/chrome/content/newtrack.xul
  42. +29 −0 extension/chrome/content/not_loaded.html
  43. +12 −0 extension/chrome/content/not_sql.html
  44. +16 −0 extension/chrome/content/overlays-ff.xul
  45. +26 −0 extension/chrome/content/passwd.xul
  46. +23 −0 extension/chrome/content/plaintext.js
  47. +19 −0 extension/chrome/content/plaintext.xul
  48. +54 −0 extension/chrome/content/preferences.js
  49. +55 −0 extension/chrome/content/preferences.xul
  50. +92 −0 extension/chrome/content/properties.js
  51. +74 −0 extension/chrome/content/properties.xul
  52. BIN extension/chrome/content/right.png
  53. BIN extension/chrome/content/start.png
  54. +1 −0 extension/chrome/content/svg.js
  55. +81 −0 extension/chrome/content/synchro.js
  56. +66 −0 extension/chrome/content/synchro.xul
  57. BIN extension/chrome/content/up.png
  58. +277 −0 extension/chrome/content/util.js
  59. BIN extension/chrome/content/zoomin.png
  60. BIN extension/chrome/content/zoomout.png
  61. +137 −0 extension/chrome/locale/cs-CZ/main.dtd
  62. +25 −0 extension/chrome/locale/cs-CZ/main.properties
  63. +137 −0 extension/chrome/locale/de-DE/main.dtd
  64. +25 −0 extension/chrome/locale/de-DE/main.properties
  65. +135 −0 extension/chrome/locale/en-US/main.dtd
  66. +25 −0 extension/chrome/locale/en-US/main.properties
  67. +137 −0 extension/chrome/locale/fr-FR/main.dtd
  68. +25 −0 extension/chrome/locale/fr-FR/main.properties
  69. +137 −0 extension/chrome/locale/hu-HU/main.dtd
  70. +25 −0 extension/chrome/locale/hu-HU/main.properties
  71. +135 −0 extension/chrome/locale/it-IT/main.dtd
  72. +25 −0 extension/chrome/locale/it-IT/main.properties
  73. +137 −0 extension/chrome/locale/pl-PL/main.dtd
  74. +25 −0 extension/chrome/locale/pl-PL/main.properties
  75. +193 −0 extension/components/GPSCity.js
  76. +893 −0 extension/components/GPSGpx.js
  77. +998 −0 extension/components/GPSStore.js
  78. +13 −0 extension/defaults/preferences/gipsy.js
  79. +25 −0 extension/install.rdf
  80. +25 −0 extension/install_full.rdf
  81. +24 −0 extension/install_lite.rdf
  82. +4 −0 maps.txt
  83. +38 −0 release
  84. +13 −0 xpc/.depend
  85. +187 −0 xpc/IGPSScanner.idl
  86. +6 −0 xpc/Makefile
  87. +25 −0 xpc/Makefile.Linux.i686
  88. +23 −0 xpc/Makefile.Linux.x86_64
  89. +154 −0 xpc/cp1250.cpp
  90. +12 −0 xpc/cp1250.h
  91. +789 −0 xpc/gipsy.cpp
  92. +117 −0 xpc/gipsy.h
  93. +20 −0 xpc/gipsy.sln
  94. +333 −0 xpc/gipsy.vcproj
  95. +34 −0 xpc/gipsymodule.cpp
  96. +1 −0 xpc/gipsyversion.h
  97. +1 −0 xpc/gpslib/.gitignore
  98. +30 −0 xpc/gpslib/Makefile
  99. +184 −0 xpc/gpslib/aircotec.cpp
  100. +30 −0 xpc/gpslib/aircotec.h
  101. +171 −0 xpc/gpslib/compeo.cpp
  102. +33 −0 xpc/gpslib/compeo.h
  103. +186 −0 xpc/gpslib/data.cpp
  104. +48 −0 xpc/gpslib/data.h
  105. +44 −0 xpc/gpslib/endian.h
  106. +68 −0 xpc/gpslib/foreignigc.cpp
  107. +22 −0 xpc/gpslib/foreignigc.h
  108. +273 −0 xpc/gpslib/garmin.cpp
  109. +165 −0 xpc/gpslib/garmin.h
  110. +39 −0 xpc/gpslib/genkey.cc
  111. +458 −0 xpc/gpslib/gps.cpp
  112. +94 −0 xpc/gpslib/gps.h
  113. +32 −0 xpc/gpslib/gpstest.cpp
  114. +539 −0 xpc/gpslib/igc.cpp
  115. +67 −0 xpc/gpslib/igc.h
  116. +97 −0 xpc/gpslib/igcparser.rl
  117. +218 −0 xpc/gpslib/mlr.cpp
  118. +33 −0 xpc/gpslib/mlr.h
  119. +775 −0 xpc/gpslib/phys.cpp
  120. +230 −0 xpc/gpslib/phys.h
  121. +79 −0 xpc/gpslib/point.h
  122. +40 −0 xpc/gpslib/vali.cpp
  123. +13 −0 xpc/prefcommon.rl
  124. +99 −0 xpc/prefparser.rl
  125. +29 −0 xpc/purify.py
  126. +53 −0 xpc/rules.makefile
  127. +1,433 −0 xpc/tracklog.cpp
  128. +67 −0 xpc/tracklog.h
  129. +183 −0 xpc/win_stdint.h
  130. +479 −0 xpc/win_strptime.cpp
  131. +194 −0 xpc/win_strptime.h
  132. +2 −0 xpc/xpidl-build.bat
@@ -0,0 +1,11 @@
+*.o
+*.so
+*.xpt
+*~
+*.db
+xpc/IGPSScanner.h
+gipsy.xpi
+xpc/gpslib/igcparser.inc
+xpc/Makefile.bak
+extension/components/Gipsy.dll
+
@@ -0,0 +1,6 @@
+/etc/udev/rules.d/60-garmin.rules
+SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device",SYSFS{idVendor}=="091e", MODE="0666"
+
+Novy debian:
+/etc/udev/rules.d/60-garmin.rules
+SUBSYSTEM=="usb", ENV{DEVTYPE}=="usb_device", ATTRS{idVendor}=="091e", MODE="0666"
@@ -0,0 +1,32 @@
+#
+
+all: gipsy.xpi gipsy_lite.xpi
+
+ia32:
+ $(MAKE) -C xpc
+ cp xpc/IGPSScanner.xpt extension/components/
+ #mkdir -p extension/platform/linux-gnu_x86-gcc3/components/
+ mkdir -p extension/platform/Linux_x86-gcc3/components/
+ mkdir -p extension/platform/Linux_x86-gcc4/components/
+ mkdir -p extension/platform/Linux_x86_64-gcc3/components/
+ mkdir -p extension/platform/WINNT_x86-msvc/components/
+ #cp xpc/gipsy.so extension/platform/linux-gnu_x86-gcc3/components/
+ cp xpc/gipsy.so extension/platform/Linux_x86-gcc3/components/
+ cp xpc/gipsy.so extension/platform/Linux_x86-gcc4/components/
+
+
+gipsy.xpi: extension/chrome/content/cities.db
+ cp extension/install_full.rdf extension/install.rdf
+ (cd extension;find . \! -regex ".*\\.svn.*" \! -regex ".*~\$$" | zip -@ ../gipsy.xpi)
+
+gipsy_lite.xpi:
+ cp extension/install_lite.rdf extension/install.rdf
+ (cd extension;find . \! -regex ".*\\.svn.*" \! -regex ".*~\$$" \! -name cities.db | zip -@ ../gipsy_lite.xpi)
+
+extension/chrome/content/cities.db:
+ (cd cities; rm cities.db; cat *.txt | ./builddb.py )
+ cp cities/cities.db extension/chrome/content/cities.db
+
+clean:
+ $(MAKE) -C xpc clean
+ -rm gipsy.xpi

Large diffs are not rendered by default.

Oops, something went wrong.
@@ -0,0 +1,41 @@
+#!/usr/bin/python
+
+from pysqlite2 import dbapi2 as sqlite
+import sys
+
+def test(lat,lon):
+ lat = round((lat+0.25) * 2) / 2.0 - 0.25
+ lon = round((lon+0.25) * 2) / 2.0 - 0.25
+ sec1 = int((lat-0.25) * 2 * 1000 + 2 * (lon - 0.25))
+ sec2 = int((lat-0.25) * 2 * 1000 + 2 * (lon + 0.25))
+ sec3 = int((lat+0.25) * 2 * 1000 + 2 * (lon - 0.25))
+ sec4 = int((lat+0.25) * 2 * 1000 + 2 * (lon + 0.25))
+ print sec1, sec2, sec3, sec4
+
+def main():
+ db = sqlite.connect('cities.db')
+ c = db.cursor()
+ c.execute('create table cities (country text, city text, lat real, lon real, sector integer)')
+ c.execute('create index sec_idx on cities (sector)');
+
+ seen = set()
+
+ for line in sys.stdin:
+ country,t,city,t,lat,lon = line.split(',')
+ country = country.upper()
+ city = unicode(city, 'latin1').encode('utf8')
+ lat = float(lat)
+ lon = float(lon)
+
+ sector = int(round(lat * 2)*1000 + round(lon * 2))
+
+ if (lat,lon) not in seen:
+ seen.add((lat,lon))
+ c.execute('insert into cities (country,city,lat,lon,sector) values (?,?,?,?,?)',
+ (country, city, lat, lon, sector))
+ db.commit()
+
+
+
+if __name__ == '__main__':
+ main()
Binary file not shown.
Oops, something went wrong.

0 comments on commit 71d73b2

Please sign in to comment.