Remove unused code
This commit is contained in:
37 files changed
+49
-1845
No files matched your search
@@ -16,39 +16,16 @@
|
||||
|
||||
package com.hippo.ehviewer.ui;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.os.Bundle;
|
||||
import android.view.MenuItem;
|
||||
|
||||
import androidx.appcompat.app.ActionBar;
|
||||
import androidx.appcompat.app.ActionBarDrawerToggle;
|
||||
|
||||
import com.hippo.ehviewer.R;
|
||||
import com.hippo.ehviewer.ui.fragment.SettingsFragment;
|
||||
import com.hippo.util.DrawableManager;
|
||||
|
||||
public final class SettingsActivity extends EhActivity {
|
||||
|
||||
private static final int REQUEST_CODE_FRAGMENT = 0;
|
||||
|
||||
@Override
|
||||
protected int getThemeResId(int theme) {
|
||||
return R.style.AppTheme_Settings;
|
||||
}
|
||||
|
||||
private void setActionBarUpIndicator(Drawable drawable) {
|
||||
ActionBarDrawerToggle.Delegate delegate = getDrawerToggleDelegate();
|
||||
if (delegate != null) {
|
||||
delegate.setActionBarUpIndicator(drawable, 0);
|
||||
}
|
||||
ActionBar actionBar = getSupportActionBar();
|
||||
if (actionBar != null) {
|
||||
actionBar.setDisplayHomeAsUpEnabled(true);
|
||||
actionBar.setHomeButtonEnabled(true);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
@@ -63,7 +40,6 @@ public final class SettingsActivity extends EhActivity {
|
||||
if (bar != null) {
|
||||
bar.setDisplayHomeAsUpEnabled(true);
|
||||
}
|
||||
setActionBarUpIndicator(DrawableManager.getVectorDrawable(this, R.drawable.v_arrow_left_dark_x24));
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -76,15 +52,4 @@ public final class SettingsActivity extends EhActivity {
|
||||
return super.onOptionsItemSelected(item);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
|
||||
if (requestCode == REQUEST_CODE_FRAGMENT) {
|
||||
if (resultCode == RESULT_OK) {
|
||||
setResult(RESULT_OK);
|
||||
}
|
||||
} else {
|
||||
super.onActivityResult(requestCode, resultCode, data);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user