Use AppCompatActivity
This commit is contained in:
parent
3cbe0a6ae9
commit
47f53cafa2
5 changed files with 18 additions and 26 deletions
|
@ -1,19 +1,17 @@
|
|||
package org.ligi.passandroid.ui;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.app.ActionBarActivity;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.text.Html;
|
||||
import android.text.method.LinkMovementMethod;
|
||||
import android.text.util.Linkify;
|
||||
import android.view.MenuItem;
|
||||
import android.widget.TextView;
|
||||
|
||||
import org.ligi.passandroid.R;
|
||||
|
||||
import butterknife.ButterKnife;
|
||||
import butterknife.InjectView;
|
||||
import org.ligi.passandroid.R;
|
||||
|
||||
public class HelpActivity extends ActionBarActivity {
|
||||
public class HelpActivity extends AppCompatActivity {
|
||||
|
||||
@InjectView(R.id.help_tv)
|
||||
TextView helpTextView;
|
||||
|
|
|
@ -5,33 +5,27 @@ import android.support.v4.app.Fragment;
|
|||
import android.support.v4.app.FragmentManager;
|
||||
import android.support.v4.app.FragmentPagerAdapter;
|
||||
import android.support.v4.view.ViewPager;
|
||||
import android.support.v7.app.ActionBarActivity;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuItem;
|
||||
|
||||
import butterknife.ButterKnife;
|
||||
import butterknife.InjectView;
|
||||
import com.google.common.base.Optional;
|
||||
import com.squareup.otto.Subscribe;
|
||||
import com.viewpagerindicator.TitlePageIndicator;
|
||||
|
||||
import org.ligi.axt.AXT;
|
||||
import org.ligi.passandroid.App;
|
||||
import org.ligi.passandroid.R;
|
||||
import org.ligi.passandroid.events.PassRefreshEvent;
|
||||
import org.ligi.passandroid.model.Pass;
|
||||
import org.ligi.passandroid.model.PassImpl;
|
||||
import org.ligi.passandroid.model.PassWriter;
|
||||
import org.ligi.passandroid.ui.edit_fragments.BarcodeEditFragment;
|
||||
import org.ligi.passandroid.ui.edit_fragments.CategoryPickFragment;
|
||||
import org.ligi.passandroid.ui.edit_fragments.ColorPickFragment;
|
||||
import org.ligi.passandroid.ui.edit_fragments.ImageEditFragment;
|
||||
import org.ligi.passandroid.ui.edit_fragments.MetaDataFragment;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
import butterknife.ButterKnife;
|
||||
import butterknife.InjectView;
|
||||
|
||||
public class PassEditActivity extends ActionBarActivity {
|
||||
public class PassEditActivity extends AppCompatActivity {
|
||||
|
||||
@InjectView(R.id.passEditPager)
|
||||
ViewPager viewPager;
|
||||
|
|
|
@ -5,16 +5,15 @@ import android.app.ProgressDialog;
|
|||
import android.net.Uri;
|
||||
import android.os.AsyncTask;
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.app.ActionBarActivity;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.view.Menu;
|
||||
|
||||
import org.ligi.axt.AXT;
|
||||
import org.ligi.passandroid.App;
|
||||
import org.ligi.passandroid.R;
|
||||
import org.ligi.passandroid.model.InputStreamWithSource;
|
||||
import org.ligi.passandroid.model.PassStore;
|
||||
|
||||
public class PassImportActivity extends ActionBarActivity {
|
||||
public class PassImportActivity extends AppCompatActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
|
@ -22,7 +21,7 @@ public class PassImportActivity extends ActionBarActivity {
|
|||
new ImportAndShowAsyncTask(this, getIntent().getData()).execute();
|
||||
}
|
||||
|
||||
class ImportAndShowAsyncTask extends AsyncTask<Void,Void,InputStreamWithSource> {
|
||||
class ImportAndShowAsyncTask extends AsyncTask<Void, Void, InputStreamWithSource> {
|
||||
|
||||
private final ProgressDialog progressDialog;
|
||||
final Activity passImportActivity;
|
||||
|
@ -39,7 +38,7 @@ public class PassImportActivity extends ActionBarActivity {
|
|||
|
||||
@Override
|
||||
protected InputStreamWithSource doInBackground(Void... params) {
|
||||
return InputStreamProvider.fromURI(passImportActivity,intent_uri);
|
||||
return InputStreamProvider.fromURI(passImportActivity, intent_uri);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -9,8 +9,8 @@ import android.os.Build;
|
|||
import android.os.Bundle;
|
||||
import android.support.v4.widget.DrawerLayout;
|
||||
import android.support.v7.app.ActionBar;
|
||||
import android.support.v7.app.ActionBarActivity;
|
||||
import android.support.v7.app.ActionBarDrawerToggle;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.support.v7.widget.LinearLayoutManager;
|
||||
import android.support.v7.widget.RecyclerView;
|
||||
import android.view.Menu;
|
||||
|
@ -40,7 +40,7 @@ import org.ligi.passandroid.model.PassStore;
|
|||
import org.ligi.tracedroid.TraceDroid;
|
||||
import org.ligi.tracedroid.sending.TraceDroidEmailSender;
|
||||
|
||||
public class PassListActivity extends ActionBarActivity {
|
||||
public class PassListActivity extends AppCompatActivity {
|
||||
|
||||
private static final int OPEN_FILE_READ_REQUEST_CODE = 1000;
|
||||
private PassAdapter passAdapter;
|
||||
|
@ -86,7 +86,7 @@ public class PassListActivity extends ActionBarActivity {
|
|||
@InjectView(R.id.fab_action_open_file)
|
||||
FloatingActionButton openFileFAB;
|
||||
|
||||
public final static int VERSION_STARTING_TO_SUPPORT_STORAGE_FRAMEWORK =19;
|
||||
public final static int VERSION_STARTING_TO_SUPPORT_STORAGE_FRAMEWORK = 19;
|
||||
|
||||
@OnClick(R.id.fab_action_open_file)
|
||||
@TargetApi(VERSION_STARTING_TO_SUPPORT_STORAGE_FRAMEWORK)
|
||||
|
|
|
@ -3,8 +3,8 @@ package org.ligi.passandroid.ui;
|
|||
import android.app.ProgressDialog;
|
||||
import android.content.DialogInterface;
|
||||
import android.os.Bundle;
|
||||
import android.support.v7.app.ActionBarActivity;
|
||||
import android.support.v7.app.AlertDialog;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuItem;
|
||||
import android.view.ViewConfiguration;
|
||||
|
@ -26,7 +26,7 @@ import org.ligi.passandroid.model.Pass;
|
|||
import org.ligi.passandroid.model.PassStore;
|
||||
import org.ligi.passandroid.ui.UnzipPassController.InputStreamUnzipControllerSpec;
|
||||
|
||||
public class PassViewActivityBase extends ActionBarActivity {
|
||||
public class PassViewActivityBase extends AppCompatActivity {
|
||||
|
||||
public static final String EXTRA_KEY_UUID = "uuid";
|
||||
public Optional<Pass> optionalPass;
|
||||
|
@ -103,7 +103,8 @@ public class PassViewActivityBase extends ActionBarActivity {
|
|||
.setNeutralButton(getString(R.string.send), new DialogInterface.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(DialogInterface dialog, int which) {
|
||||
new ExportProblemPassToLigiAndFinishTask(PassViewActivityBase.this, pass.getId(),
|
||||
new ExportProblemPassToLigiAndFinishTask(PassViewActivityBase.this,
|
||||
pass.getId(),
|
||||
App.getShareDir(),
|
||||
"share",
|
||||
reason).execute();
|
||||
|
|
Loading…
Reference in a new issue