mirror of
https://github.com/gsantner/dandelion
synced 2024-11-15 17:02:10 +01:00
Removed test Fragments and old SplashActivity related stuff
This commit is contained in:
parent
7ee5e0f39b
commit
88e4636e88
5 changed files with 2 additions and 118 deletions
|
@ -25,7 +25,6 @@ import android.content.DialogInterface;
|
|||
import android.content.Intent;
|
||||
import android.content.IntentFilter;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.res.Configuration;
|
||||
import android.graphics.drawable.LayerDrawable;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
|
@ -67,7 +66,6 @@ import com.github.dfa.diaspora_android.fragment.CustomFragment;
|
|||
import com.github.dfa.diaspora_android.fragment.DiasporaStreamFragment;
|
||||
import com.github.dfa.diaspora_android.fragment.HashtagListFragment;
|
||||
import com.github.dfa.diaspora_android.fragment.PodSelectionFragment;
|
||||
import com.github.dfa.diaspora_android.fragment.TestFragment;
|
||||
import com.github.dfa.diaspora_android.listener.WebUserProfileChangedListener;
|
||||
import com.github.dfa.diaspora_android.receiver.OpenExternalLinkReceiver;
|
||||
import com.github.dfa.diaspora_android.receiver.UpdateTitleReceiver;
|
||||
|
@ -75,7 +73,6 @@ import com.github.dfa.diaspora_android.ui.BadgeDrawable;
|
|||
import com.github.dfa.diaspora_android.util.AppLog;
|
||||
import com.github.dfa.diaspora_android.util.CustomTabHelpers.CustomTabActivityHelper;
|
||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||
import com.github.dfa.diaspora_android.util.Helpers;
|
||||
import com.github.dfa.diaspora_android.util.WebHelper;
|
||||
|
||||
import butterknife.BindView;
|
||||
|
@ -273,13 +270,10 @@ public class MainActivity extends AppCompatActivity
|
|||
PodSelectionFragment psf = new PodSelectionFragment();
|
||||
fm.beginTransaction().add(psf, fragmentTag).commit();
|
||||
return psf;
|
||||
case TestFragment.TAG:
|
||||
default:
|
||||
AppLog.e(this,"Invalid Fragment Tag: "+fragmentTag
|
||||
+"\nAdd Fragments Tag to getFragment()'s switch case.");
|
||||
TestFragment tf = new TestFragment();
|
||||
fm.beginTransaction().add(tf, fragmentTag).commit();
|
||||
return tf;
|
||||
return getTopFragment();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -592,11 +586,6 @@ public class MainActivity extends AppCompatActivity
|
|||
return true;
|
||||
}
|
||||
|
||||
case R.id.action_debug_button: {
|
||||
showFragment(getFragment(TestFragment.TAG));
|
||||
return true;
|
||||
}
|
||||
|
||||
case R.id.action_compose: {
|
||||
if (WebHelper.isOnline(MainActivity.this)) {
|
||||
openDiasporaUrl(urls.getNewPostUrl());
|
||||
|
@ -736,13 +725,12 @@ public class MainActivity extends AppCompatActivity
|
|||
}
|
||||
}
|
||||
|
||||
//TODO: Implement?
|
||||
//TODO: Implement some day
|
||||
private void handleSendImage(Intent intent) {
|
||||
AppLog.i(this, "handleSendImage()");
|
||||
final Uri imageUri = intent.getParcelableExtra(Intent.EXTRA_STREAM);
|
||||
if (imageUri != null) {
|
||||
AppLog.v(this, "imageUri is not null. Handle shared image");
|
||||
// TODO: Update UI to reflect text being shared
|
||||
} else {
|
||||
AppLog.w(this, "imageUri is null. Cannot precede.");
|
||||
}
|
||||
|
@ -800,17 +788,7 @@ public class MainActivity extends AppCompatActivity
|
|||
}
|
||||
break;
|
||||
|
||||
//TODO: Replace with fragment
|
||||
case R.id.nav_followed_tags: {
|
||||
/*DiasporaStreamFragment stream = (DiasporaStreamFragment) getFragment(DiasporaStreamFragment.TAG);
|
||||
if (WebHelper.isOnline(MainActivity.this)) {
|
||||
openDiasporaUrl(urls.getBlankUrl());
|
||||
WebHelper.showFollowedTagsList(stream.getWebView(), app);
|
||||
setTitle(R.string.nav_followed_tags);
|
||||
} else {
|
||||
snackbarNoInternet.show();
|
||||
}
|
||||
*/
|
||||
showFragment(getFragment(HashtagListFragment.TAG));
|
||||
}
|
||||
break;
|
||||
|
|
|
@ -1,39 +0,0 @@
|
|||
package com.github.dfa.diaspora_android.fragment;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
|
||||
import com.github.dfa.diaspora_android.R;
|
||||
import com.github.dfa.diaspora_android.util.AppLog;
|
||||
|
||||
/**
|
||||
* Created by vanitas on 23.09.16.
|
||||
*/
|
||||
|
||||
public class TestFragment extends CustomFragment {
|
||||
|
||||
public static final String TAG = "com.github.dfa.diaspora_android.TestFragment";
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
|
||||
AppLog.d(this, "onCreateView()");
|
||||
return inflater.inflate(R.layout.test__fragment, container, false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getFragmentTag() {
|
||||
return TAG;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreateBottomOptionsMenu(Menu menu, MenuInflater inflater) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBackPressed() {
|
||||
return false;
|
||||
}
|
||||
}
|
|
@ -1,37 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@color/primary"
|
||||
android:paddingBottom="@dimen/activity_vertical_margin"
|
||||
android:paddingLeft="@dimen/activity_horizontal_margin"
|
||||
android:paddingRight="@dimen/activity_horizontal_margin"
|
||||
android:paddingTop="@dimen/activity_vertical_margin"
|
||||
tools:context=".activity.SplashActivity">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:shadowColor="@color/black"
|
||||
android:text="*"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="120dp"
|
||||
android:textStyle="bold"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginBottom="30dp"
|
||||
android:text="@string/app_name"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="32dp"
|
||||
android:textStyle="bold"/>
|
||||
|
||||
</RelativeLayout>
|
|
@ -1,11 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:orientation="vertical" android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/lorem_ipsum"/>
|
||||
|
||||
</LinearLayout>
|
|
@ -35,11 +35,4 @@
|
|||
android:title="@string/action_exit_app"
|
||||
/>
|
||||
|
||||
<item
|
||||
android:id="@+id/action_debug_button"
|
||||
app:showAsAction="never"
|
||||
android:orderInCategory="1000"
|
||||
android:title="DEBUG"
|
||||
/>
|
||||
|
||||
</menu>
|
||||
|
|
Loading…
Reference in a new issue