1
0
Fork 0
mirror of https://github.com/gsantner/dandelion synced 2025-12-15 08:41:10 +01:00

Cleanup and release v0.1.3

This commit is contained in:
vanitasvitae 2016-07-04 11:19:09 +02:00
parent 91ac7aa33b
commit 2024f5d8fa
11 changed files with 27 additions and 44 deletions

View file

@ -171,7 +171,6 @@ public class MainActivity extends AppCompatActivity
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Intent startIntent = getIntent();
// Bind UI
setContentView(R.layout.main__activity);
ButterKnife.bind(this);
@ -710,7 +709,7 @@ public class MainActivity extends AppCompatActivity
Snackbar.make(swipeRefreshLayout, getString(R.string.toast_screenshot) + " " + fileSaveName, Snackbar.LENGTH_LONG).show();
}
Bitmap bitmap = null;
Bitmap bitmap;
webView.setDrawingCacheEnabled(true);
bitmap = Bitmap.createBitmap(webView.getDrawingCache());
webView.setDrawingCacheEnabled(false);
@ -727,8 +726,7 @@ public class MainActivity extends AppCompatActivity
if (bitmapWriter != null) {
try {
bitmapWriter.close();
} catch (IOException _ignored) {
}
} catch (IOException _ignored) {/* Nothing */}
}
}

View file

@ -3,9 +3,6 @@ package com.github.dfa.diaspora_android.data;
import android.annotation.SuppressLint;
import android.content.Context;
import android.content.SharedPreferences;
import android.util.Log;
import com.github.dfa.diaspora_android.App;
/**
* Created by gsantner on 20.03.16. Part of Diaspora for Android.

View file

@ -48,8 +48,7 @@ public class PodAspect {
j.put("id", id);
j.put("name", name);
j.put("selected", selected);
} catch (JSONException e) {
}
} catch (JSONException e) {/*Nothing*/}
return j.toString();
}
@ -67,10 +66,7 @@ public class PodAspect {
@Override
public boolean equals(Object o) {
if (o instanceof PodAspect) {
return ((PodAspect) o).id == id;
}
return false;
return o instanceof PodAspect && ((PodAspect) o).id == id;
}
public String toShareAbleText() {

View file

@ -54,9 +54,9 @@ public class CustomWebViewClient extends WebViewClient {
if (cookies != null) {
cookieManager.setCookie(url, cookies);
cookieManager.setCookie("https://" + app.getSettings().getPodDomain(), cookies);
for (String c : cookies.split(";")) {
//Log.d(App.TAG, "Cookie: " + c.split("=")[0] + " Value:" + c.split("=")[1]);
}
//for (String c : cookies.split(";")) {
// Log.d(App.TAG, "Cookie: " + c.split("=")[0] + " Value:" + c.split("=")[1]);
//}
//new ProfileFetchTask(app).execute();
}
}

View file

@ -20,10 +20,7 @@ public class AvatarImageLoader {
}
public boolean clearAvatarImage() {
if (isAvatarDownloaded()) {
return avatarFile.delete();
}
return true;
return (!isAvatarDownloaded() || avatarFile.delete());
}
public boolean loadToImageView(ImageView imageView) {