Skip to content

Commit 955e814

Browse files
committed
Release 0.9.2.
1 parent b48015a commit 955e814

File tree

4 files changed

+17
-15
lines changed

4 files changed

+17
-15
lines changed

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ allprojects {
1717

1818
ext {
1919
minSdkVersion = 19
20-
targetSdkVersion = 31
20+
targetSdkVersion = 33
2121
versionCode = 11
22-
versionName = '0.9.1'
22+
versionName = '0.9.2'
2323
}
2424

2525
task clean(type: Delete) {

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME
55
zipStorePath=wrapper/dists
6-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
6+
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip

worldwind-tutorials/src/main/java/gov/nasa/worldwindx/MainActivity.java

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
import android.view.MenuItem;
1818
import android.view.View;
1919

20+
import androidx.activity.OnBackPressedCallback;
2021
import androidx.annotation.NonNull;
2122
import androidx.appcompat.app.ActionBarDrawerToggle;
2223
import androidx.appcompat.app.AppCompatActivity;
@@ -132,6 +133,17 @@ protected void onCreateDrawer() {
132133
this.navigationView = findViewById(R.id.nav_view);
133134
this.navigationView.setNavigationItemSelectedListener(this);
134135
this.navigationView.setCheckedItem(selectedItemId);
136+
137+
getOnBackPressedDispatcher().addCallback(this, new OnBackPressedCallback(true) {
138+
@Override
139+
public void handleOnBackPressed() {
140+
if (drawer.isDrawerOpen(GravityCompat.START)) {
141+
drawer.closeDrawer(GravityCompat.START);
142+
} else {
143+
finish();
144+
}
145+
}
146+
});
135147
}
136148

137149
@Override
@@ -221,16 +233,6 @@ protected boolean printMetrics() {
221233
return this.handler.sendEmptyMessageDelayed(PRINT_METRICS, PRINT_METRICS_DELAY);
222234
}
223235

224-
@Override
225-
public void onBackPressed() {
226-
DrawerLayout drawer = findViewById(R.id.drawer_layout);
227-
if (drawer.isDrawerOpen(GravityCompat.START)) {
228-
drawer.closeDrawer(GravityCompat.START);
229-
} else {
230-
super.onBackPressed();
231-
}
232-
}
233-
234236
@Override
235237
protected void onPostCreate(Bundle savedInstanceState) {
236238
super.onPostCreate(savedInstanceState);

worldwind/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ android {
4242
}
4343

4444
dependencies {
45-
implementation 'androidx.annotation:annotation:1.3.0'
45+
implementation 'androidx.annotation:annotation:1.4.0'
4646
implementation 'androidx.appcompat:appcompat-resources:1.4.2'
4747
testImplementation 'junit:junit:4.13.2'
48-
testImplementation 'org.mockito:mockito-core:3.12.4'
48+
testImplementation 'org.mockito:mockito-core:4.7.0'
4949
// PowerMockito is required to mock static methods like Logger.log
5050
testImplementation('org.powermock:powermock-api-mockito2:2.0.9') {
5151
exclude module: 'hamcrest-core'

0 commit comments

Comments
 (0)