Home | History | Annotate | Download | only in globaltime

Lines Matching full:city

82      * in order to sort the city database.
118 * Geometry of the city lights
159 // City search string
163 private List<City> mClockCities;
166 private List<City> mCityNameMatches = new ArrayList<City>();
168 private List<City> mCities;
183 // City-to-city flight animation parameters
248 * @param am an AssetManager to retrieve the city database from
383 * Returns the offset from UTC for the given city. If USE_RAW_OFFSETS
386 private static float getOffset(City c) {
401 * Load the city and lights databases.
420 // Use English city names by default
429 City.loadCities(cis);
430 City[] cities;
432 cities = City.getCitiesByRawOffset();
434 cities = City.getCitiesByOffset();
437 mClockCities = new ArrayList<City>(cities.length);
543 // If only 1 city in the current set, there's nowhere to go
559 * Returns true if there is another city within the current time zone
560 * that is the given increment away from the current city.
593 * Returns true if the city name matches the given prefix, ignoring spaces.
595 private boolean nameMatches(City city, String prefix) {
596 String cityName = city.getName().replaceAll("[ ]", "");
607 City city = mClockCities.get(i);
608 if (nameMatches(city, prefix)) {
617 * Shifts to the nearest city that matches the new prefix.
620 // Attempt to keep current city if it matches
621 City finalCity = null;
622 City currCity = mCities.get(mCityIndex);
629 City city = mClockCities.get(i);
630 if (nameMatches(city, mCityName)) {
631 mCityNameMatches.add(city);
645 // Find the closest matching city
664 * the current city.
667 // Determine the global city index that matches the current city
669 City city = mCityNameMatches.get(mCityIndex);
671 City ncity = mClockCities.get(i);
672 if (city.equals(ncity)) {
694 // Find the closest matching city
874 // The 'L' key toggles the city lights
916 // Handle letters in city names
919 // Add a letter to the city name prefix
954 // Remove a letter from the city name prefix
965 // Clear the city name prefix
1072 * Locates the closest city to the currently displayed center point,
1079 City city = mCities.get(i);
1080 if (useOffset && !tzEqual(getOffset(city), offset)) {
1083 float dist = distance(city.getLatitude(), city.getLongitude(),
1095 * Animates the earth to be centered at the current city.
1098 City city = mCities.get(mCityIndex);
1099 float dist = distance(city.getLatitude(), city.getLongitude(),
1106 mRotAngleDest = city.getLongitude() + 90;
1115 mTiltAngleDest = city.getLatitude();
1127 * Draws the city lights, using a clip plane to restrict the lights
1239 City city = mCities.get(mCityIndex);
1240 mClock.setCity(city);