Skip to content

Commit

Permalink
Updated for SDK 2.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
sshie committed Dec 7, 2017
1 parent 6d7db1b commit a2ed077
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 38 deletions.
64 changes: 32 additions & 32 deletions AerisDemo/AerisDemo.iml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_7" inherit-compiler-output="false">
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_7">
<output url="file://$MODULE_DIR$/build/intermediates/classes/debug" />
<output-test url="file://$MODULE_DIR$/build/intermediates/classes/test/debug" />
<exclude-output />
Expand Down Expand Up @@ -89,37 +89,37 @@
</content>
<orderEntry type="jdk" jdkName="Android API 25 Platform" jdkType="Android SDK" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" exported="" name="runner-0.5" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="espresso-idling-resource-2.2.2" level="project" />
<orderEntry type="library" exported="" name="picasso-2.5.2" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="hamcrest-library-1.3" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="hamcrest-integration-1.3" level="project" />
<orderEntry type="library" exported="" name="support-core-ui-25.3.1" level="project" />
<orderEntry type="library" exported="" name="play-services-basement-11.0.4" level="project" />
<orderEntry type="library" exported="" name="aeris-maps-lib-2.1.1" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="jsr305-2.0.1" level="project" />
<orderEntry type="library" exported="" name="play-services-base-11.0.4" level="project" />
<orderEntry type="library" exported="" name="support-core-utils-25.3.1" level="project" />
<orderEntry type="library" exported="" name="support-fragment-25.3.1" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="espresso-core-2.2.2" level="project" />
<orderEntry type="library" exported="" name="aeris-core-lib-2.1.1" level="project" />
<orderEntry type="library" exported="" name="play-services-maps-11.0.4" level="project" />
<orderEntry type="library" exported="" name="exposed-instrumentation-api-publish-0.5" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="rules-0.5" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="javax.annotation-api-1.2" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="javax.inject-1" level="project" />
<orderEntry type="library" exported="" name="gson-2.7" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="javawriter-2.1.1" level="project" />
<orderEntry type="library" exported="" name="support-v4-25.3.1" level="project" />
<orderEntry type="library" exported="" name="support-media-compat-25.3.1" level="project" />
<orderEntry type="library" exported="" name="hamcrest-core-1.3" level="project" />
<orderEntry type="library" exported="" name="junit-4.12" level="project" />
<orderEntry type="library" exported="" name="support-annotations-25.3.1" level="project" />
<orderEntry type="library" exported="" name="appcompat-v7-25.3.1" level="project" />
<orderEntry type="library" exported="" name="support-vector-drawable-25.3.1" level="project" />
<orderEntry type="library" exported="" name="support-compat-25.3.1" level="project" />
<orderEntry type="library" exported="" name="play-services-tasks-11.0.4" level="project" />
<orderEntry type="library" exported="" name="animated-vector-drawable-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.android.support.test:exposed-instrumentation-api-publish-0.5" level="project" />
<orderEntry type="library" exported="" name="junit:junit:4.12@jar" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="javax.inject:javax.inject:1@jar" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-core-ui-25.3.1" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="com.squareup:javawriter:2.1.1@jar" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-compat-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.google.android.gms:play-services-basement-11.0.4" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-core-utils-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.google.code.gson:gson:2.7@jar" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-v4-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-fragment-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.aerisweather:aeris-core-lib-2.2.0" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-media-compat-25.3.1" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="com.google.code.findbugs:jsr305:2.0.1@jar" level="project" />
<orderEntry type="library" exported="" name="org.hamcrest:hamcrest-core:1.3@jar" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="com.android.support.test.espresso:espresso-core-2.2.2" level="project" />
<orderEntry type="library" exported="" name="com.android.support:animated-vector-drawable-25.3.1" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="com.android.support.test:rules-0.5" level="project" />
<orderEntry type="library" exported="" name="com.google.android.gms:play-services-tasks-11.0.4" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="org.hamcrest:hamcrest-library:1.3@jar" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="org.hamcrest:hamcrest-integration:1.3@jar" level="project" />
<orderEntry type="library" exported="" name="com.android.support.test:runner-0.5" level="project" />
<orderEntry type="library" exported="" name="com.android.support:appcompat-v7-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.google.android.gms:play-services-maps-11.0.4" level="project" />
<orderEntry type="library" exported="" name="com.aerisweather:aeris-maps-lib-2.2.0" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="com.android.support.test.espresso:espresso-idling-resource-2.2.2" level="project" />
<orderEntry type="library" exported="" name="com.squareup.picasso:picasso:2.5.2@jar" level="project" />
<orderEntry type="library" exported="" scope="TEST" name="javax.annotation:javax.annotation-api:1.2@jar" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-vector-drawable-25.3.1" level="project" />
<orderEntry type="library" exported="" name="com.android.support:support-annotations:25.3.1@jar" level="project" />
<orderEntry type="library" exported="" name="com.google.android.gms:play-services-base-11.0.4" level="project" />
<orderEntry type="library" exported="" name="android-android-25" level="project" />
</component>
</module>
6 changes: 3 additions & 3 deletions AerisDemo/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ buildscript {
repositories {
mavenCentral()
jcenter()
//maven { url "https://oss.sonatype.org/content/repositories/comaerisweather-1460" }
maven { url "https://oss.sonatype.org/content/repositories/comaerisweather-1467" }
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
Expand All @@ -67,11 +67,11 @@ buildscript {
repositories {
mavenCentral()
jcenter()
//maven { url "https://oss.sonatype.org/content/repositories/comaerisweather-1460" }
maven { url "https://oss.sonatype.org/content/repositories/comaerisweather-1467" }
}
dependencies {
testCompile 'junit:junit:4.12'
compile ('com.aerisweather:aeris-maps-lib:2.1.1@aar') {
compile ('com.aerisweather:aeris-maps-lib:2.2.0@aar') {
transitive true
}
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
Expand Down
8 changes: 5 additions & 3 deletions AerisDemo/src/com/example/fragment/MyMapFragment.java
Original file line number Diff line number Diff line change
Expand Up @@ -284,18 +284,20 @@ private void initMap()
//get a stored location if there is one
MyPlacesDb db = new MyPlacesDb(getActivity());
MyPlace place = db.getMyPlace();
Location myLocation = null;

if (place == null)
{
//we didn't find a stored location, so get the current location
m_locHelper = new LocationHelper(getActivity());
Location myLocation = m_locHelper.getCurrentLocation();
myLocation = m_locHelper.getCurrentLocation();

//move the map to the location
m_aerisMapView.moveToLocation(myLocation, 9);

//set the marker location
markerOptions.position(new LatLng(myLocation.getLatitude(), myLocation.getLongitude()));
if (myLocation != null)
markerOptions.position(new LatLng(myLocation.getLatitude(), myLocation.getLongitude()));
}
else
{
Expand All @@ -307,7 +309,7 @@ private void initMap()
}

//add the marker with specified options
if (m_googleMap != null)
if ((m_googleMap != null) && (myLocation != null))
m_googleMap.addMarker(markerOptions);

//do something when a user makes a long click
Expand Down

0 comments on commit a2ed077

Please sign in to comment.