BIG REFACTORING - 0.1.6-next edition
|
@ -14,11 +14,11 @@
|
||||||
android:theme="@style/DiasporaLight" >
|
android:theme="@style/DiasporaLight" >
|
||||||
|
|
||||||
<provider
|
<provider
|
||||||
android:name="com.github.dfa.diaspora_android.data.HashtagProvider"
|
android:name="com.github.dfa.diaspora_android.service.HashtagContentProvider"
|
||||||
android:authorities="com.github.dfa.diaspora_android.mainactivity" />
|
android:authorities="com.github.dfa.diaspora_android.mainactivity" />
|
||||||
|
|
||||||
<service
|
<service
|
||||||
android:name="com.github.dfa.diaspora_android.task.GetPodsService"
|
android:name="com.github.dfa.diaspora_android.service.FetchPodsService"
|
||||||
android:enabled="true"
|
android:enabled="true"
|
||||||
android:exported="false" />
|
android:exported="false" />
|
||||||
|
|
||||||
|
|
BIN
app/src/main/ic_launcher-web.png
Normal file
After Width: | Height: | Size: 16 KiB |
|
@ -27,10 +27,10 @@ import android.webkit.CookieManager;
|
||||||
import android.webkit.CookieSyncManager;
|
import android.webkit.CookieSyncManager;
|
||||||
import android.webkit.WebView;
|
import android.webkit.WebView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.data.DiasporaUserProfile;
|
||||||
import com.github.dfa.diaspora_android.data.PodUserProfile;
|
import com.github.dfa.diaspora_android.service.AvatarImageLoader;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.AvatarImageLoader;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
|
|
||||||
public class App extends Application {
|
public class App extends Application {
|
||||||
|
@ -38,7 +38,7 @@ public class App extends Application {
|
||||||
private AppSettings appSettings;
|
private AppSettings appSettings;
|
||||||
private AvatarImageLoader avatarImageLoader;
|
private AvatarImageLoader avatarImageLoader;
|
||||||
private CookieManager cookieManager;
|
private CookieManager cookieManager;
|
||||||
private PodUserProfile podUserProfile;
|
private DiasporaUserProfile diasporaUserProfile;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCreate() {
|
public void onCreate() {
|
||||||
|
@ -52,7 +52,7 @@ public class App extends Application {
|
||||||
|
|
||||||
// Init pod profile
|
// Init pod profile
|
||||||
avatarImageLoader = new AvatarImageLoader(c);
|
avatarImageLoader = new AvatarImageLoader(c);
|
||||||
podUserProfile = new PodUserProfile(this);
|
diasporaUserProfile = new DiasporaUserProfile(this);
|
||||||
|
|
||||||
|
|
||||||
// Get cookie manager
|
// Get cookie manager
|
||||||
|
@ -87,8 +87,8 @@ public class App extends Application {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public PodUserProfile getPodUserProfile() {
|
public DiasporaUserProfile getDiasporaUserProfile() {
|
||||||
return podUserProfile;
|
return diasporaUserProfile;
|
||||||
}
|
}
|
||||||
|
|
||||||
public AppSettings getSettings() {
|
public AppSettings getSettings() {
|
||||||
|
|
|
@ -43,15 +43,15 @@ import android.widget.Toast;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.listener.IntellihideToolbarActivityListener;
|
||||||
import com.github.dfa.diaspora_android.fragment.ThemedFragment;
|
|
||||||
import com.github.dfa.diaspora_android.ui.HtmlTextView;
|
import com.github.dfa.diaspora_android.ui.HtmlTextView;
|
||||||
import com.github.dfa.diaspora_android.ui.IntellihideToolbarActivityListener;
|
import com.github.dfa.diaspora_android.ui.theme.ThemeHelper;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedActivity;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedFragment;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.Helpers;
|
import com.github.dfa.diaspora_android.util.Helpers;
|
||||||
import com.github.dfa.diaspora_android.util.Log;
|
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
import java.util.Observable;
|
import java.util.Observable;
|
||||||
import java.util.Observer;
|
import java.util.Observer;
|
||||||
|
@ -316,7 +316,7 @@ public class AboutActivity extends ThemedActivity
|
||||||
public boolean onLongClick(View view) {
|
public boolean onLongClick(View view) {
|
||||||
if (isAdded()) {
|
if (isAdded()) {
|
||||||
ClipboardManager clipboard = (ClipboardManager) getActivity().getSystemService(CLIPBOARD_SERVICE);
|
ClipboardManager clipboard = (ClipboardManager) getActivity().getSystemService(CLIPBOARD_SERVICE);
|
||||||
ClipData clip = ClipData.newPlainText("DEBUG_LOG", Log.getLogBuffer());
|
ClipData clip = ClipData.newPlainText("DEBUG_LOG", AppLog.Log.getLogBuffer());
|
||||||
clipboard.setPrimaryClip(clip);
|
clipboard.setPrimaryClip(clip);
|
||||||
Toast.makeText(DebugFragment.this.getActivity(), R.string.fragment_debug__toast_log_copied, Toast.LENGTH_SHORT).show();
|
Toast.makeText(DebugFragment.this.getActivity(), R.string.fragment_debug__toast_log_copied, Toast.LENGTH_SHORT).show();
|
||||||
} else {
|
} else {
|
||||||
|
@ -325,8 +325,8 @@ public class AboutActivity extends ThemedActivity
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Log.addLogObserver(this);
|
AppLog.Log.addLogObserver(this);
|
||||||
update(Log.getInstance(), null);
|
update(AppLog.Log.getInstance(), null);
|
||||||
|
|
||||||
if (isAdded()) {
|
if (isAdded()) {
|
||||||
try {
|
try {
|
||||||
|
@ -353,14 +353,14 @@ public class AboutActivity extends ThemedActivity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onDestroyView() {
|
public void onDestroyView() {
|
||||||
Log.removeLogObserver(this);
|
AppLog.Log.removeLogObserver(this);
|
||||||
super.onDestroyView();
|
super.onDestroyView();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void update(Observable observable, Object o) {
|
public void update(Observable observable, Object o) {
|
||||||
if (logBox != null) {
|
if (logBox != null) {
|
||||||
logBox.setText(Log.getLogBuffer());
|
logBox.setText(AppLog.Log.getLogBuffer());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.activity;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.PorterDuff;
|
import android.graphics.PorterDuff;
|
||||||
|
@ -34,11 +34,11 @@ import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.data.DiasporaAspect;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.data.PodAspect;
|
|
||||||
import com.github.dfa.diaspora_android.listener.OnSomethingClickListener;
|
import com.github.dfa.diaspora_android.listener.OnSomethingClickListener;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedFragment;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.Helpers;
|
import com.github.dfa.diaspora_android.util.Helpers;
|
||||||
|
|
||||||
|
@ -114,7 +114,7 @@ public class AspectListFragment extends ThemedFragment implements OnSomethingCli
|
||||||
|
|
||||||
public static class AspectAdapter extends RecyclerView.Adapter<AspectAdapter.ViewHolder> {
|
public static class AspectAdapter extends RecyclerView.Adapter<AspectAdapter.ViewHolder> {
|
||||||
private AppSettings appSettings;
|
private AppSettings appSettings;
|
||||||
private PodAspect[] aspectList;
|
private DiasporaAspect[] aspectList;
|
||||||
private List<String> aspectFavsList;
|
private List<String> aspectFavsList;
|
||||||
private OnSomethingClickListener<Object> aspectClickedListener;
|
private OnSomethingClickListener<Object> aspectClickedListener;
|
||||||
|
|
||||||
|
@ -148,7 +148,7 @@ public class AspectListFragment extends ThemedFragment implements OnSomethingCli
|
||||||
@Override
|
@Override
|
||||||
public AspectAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
public AspectAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
||||||
View v = LayoutInflater.from(parent.getContext())
|
View v = LayoutInflater.from(parent.getContext())
|
||||||
.inflate(R.layout.recycler_view__list_item, parent, false);
|
.inflate(R.layout.recycler_list__list_item_with_fav, parent, false);
|
||||||
return new ViewHolder(v);
|
return new ViewHolder(v);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -156,10 +156,10 @@ public class AspectListFragment extends ThemedFragment implements OnSomethingCli
|
||||||
public void onBindViewHolder(final ViewHolder holder, int position) {
|
public void onBindViewHolder(final ViewHolder holder, int position) {
|
||||||
// Alternating colors
|
// Alternating colors
|
||||||
final Context c = holder.root.getContext();
|
final Context c = holder.root.getContext();
|
||||||
final PodAspect aspect = aspectList[position];
|
final DiasporaAspect aspect = aspectList[position];
|
||||||
holder.title.setText(aspect.name);
|
holder.title.setText(aspect.name);
|
||||||
if (position % 2 == 1) {
|
if (position % 2 == 1) {
|
||||||
holder.root.setBackgroundColor(Helpers.getColorFromRessource(c, R.color.md_grey_300));
|
holder.root.setBackgroundColor(Helpers.getColorFromRessource(c, R.color.alternate_row_color));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Favourite (Star) Image
|
// Favourite (Star) Image
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.activity;
|
||||||
|
|
||||||
import android.Manifest;
|
import android.Manifest;
|
||||||
import android.animation.ObjectAnimator;
|
import android.animation.ObjectAnimator;
|
||||||
|
@ -42,14 +42,14 @@ import android.webkit.WebView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.data.DiasporaUserProfile;
|
||||||
import com.github.dfa.diaspora_android.data.PodUserProfile;
|
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.Helpers;
|
import com.github.dfa.diaspora_android.util.Helpers;
|
||||||
import com.github.dfa.diaspora_android.util.WebHelper;
|
import com.github.dfa.diaspora_android.web.BrowserFragment;
|
||||||
import com.github.dfa.diaspora_android.webview.DiasporaStreamWebChromeClient;
|
import com.github.dfa.diaspora_android.web.DiasporaStreamWebChromeClient;
|
||||||
import com.github.dfa.diaspora_android.webview.FileUploadWebChromeClient;
|
import com.github.dfa.diaspora_android.web.FileUploadWebChromeClient;
|
||||||
|
import com.github.dfa.diaspora_android.web.WebHelper;
|
||||||
|
|
||||||
import org.json.JSONException;
|
import org.json.JSONException;
|
||||||
|
|
||||||
|
@ -328,13 +328,13 @@ public class DiasporaStreamFragment extends BrowserFragment {
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
@JavascriptInterface
|
@JavascriptInterface
|
||||||
public void setUserProfile(final String webMessage) throws JSONException {
|
public void setUserProfile(final String webMessage) throws JSONException {
|
||||||
PodUserProfile pup = ((App) getActivity().getApplication()).getPodUserProfile();
|
DiasporaUserProfile pup = ((App) getActivity().getApplication()).getDiasporaUserProfile();
|
||||||
AppLog.spam(this, "StreamFragment.JavaScriptInterface.setUserProfile()");
|
AppLog.spam(this, "StreamFragment.JavaScriptInterface.setUserProfile()");
|
||||||
if (pup.isRefreshNeeded()) {
|
if (pup.isRefreshNeeded()) {
|
||||||
AppLog.v(this, "PodUserProfile needs refresh; Try to parse JSON");
|
AppLog.v(this, "DiasporaUserProfile needs refresh; Try to parse JSON");
|
||||||
pup.parseJson(webMessage);
|
pup.parseJson(webMessage);
|
||||||
} else {
|
} else {
|
||||||
AppLog.spam(this, "No PodUserProfile refresh needed");
|
AppLog.spam(this, "No DiasporaUserProfile refresh needed");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -59,37 +59,34 @@ import android.widget.Toast;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList;
|
||||||
import com.github.dfa.diaspora_android.data.PodUserProfile;
|
import com.github.dfa.diaspora_android.data.DiasporaUserProfile;
|
||||||
import com.github.dfa.diaspora_android.fragment.AspectListFragment;
|
import com.github.dfa.diaspora_android.listener.DiasporaUserProfileChangedListener;
|
||||||
import com.github.dfa.diaspora_android.fragment.BrowserFragment;
|
import com.github.dfa.diaspora_android.listener.IntellihideToolbarActivityListener;
|
||||||
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.listener.WebUserProfileChangedListener;
|
|
||||||
import com.github.dfa.diaspora_android.receiver.OpenExternalLinkReceiver;
|
import com.github.dfa.diaspora_android.receiver.OpenExternalLinkReceiver;
|
||||||
import com.github.dfa.diaspora_android.receiver.UpdateTitleReceiver;
|
import com.github.dfa.diaspora_android.receiver.UpdateTitleReceiver;
|
||||||
import com.github.dfa.diaspora_android.ui.BadgeDrawable;
|
import com.github.dfa.diaspora_android.ui.BadgeDrawable;
|
||||||
import com.github.dfa.diaspora_android.ui.IntellihideToolbarActivityListener;
|
|
||||||
import com.github.dfa.diaspora_android.ui.PodSelectionDialog;
|
import com.github.dfa.diaspora_android.ui.PodSelectionDialog;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.CustomFragment;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemeHelper;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedActivity;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.CustomTabHelpers.CustomTabActivityHelper;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.ProxyHandler;
|
import com.github.dfa.diaspora_android.web.BrowserFragment;
|
||||||
import com.github.dfa.diaspora_android.util.WebHelper;
|
import com.github.dfa.diaspora_android.web.ProxyHandler;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
import com.github.dfa.diaspora_android.web.WebHelper;
|
||||||
|
import com.github.dfa.diaspora_android.web.custom_tab.CustomTabActivityHelper;
|
||||||
|
|
||||||
import butterknife.BindView;
|
import butterknife.BindView;
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
|
|
||||||
public class MainActivity extends ThemedActivity
|
public class MainActivity extends ThemedActivity
|
||||||
implements NavigationView.OnNavigationItemSelectedListener,
|
implements NavigationView.OnNavigationItemSelectedListener,
|
||||||
WebUserProfileChangedListener,
|
DiasporaUserProfileChangedListener,
|
||||||
CustomTabActivityHelper.ConnectionCallback,
|
CustomTabActivityHelper.ConnectionCallback,
|
||||||
IntellihideToolbarActivityListener,
|
IntellihideToolbarActivityListener,
|
||||||
PodSelectionDialog.PodSelectionDialogResultListener{
|
PodSelectionDialog.PodSelectionDialogResultListener {
|
||||||
|
|
||||||
|
|
||||||
public static final int REQUEST_CODE_ASK_PERMISSIONS = 123;
|
public static final int REQUEST_CODE_ASK_PERMISSIONS = 123;
|
||||||
|
@ -110,7 +107,7 @@ public class MainActivity extends ThemedActivity
|
||||||
private CustomTabActivityHelper customTabActivityHelper;
|
private CustomTabActivityHelper customTabActivityHelper;
|
||||||
private AppSettings appSettings;
|
private AppSettings appSettings;
|
||||||
private DiasporaUrlHelper urls;
|
private DiasporaUrlHelper urls;
|
||||||
private PodUserProfile podUserProfile;
|
private DiasporaUserProfile diasporaUserProfile;
|
||||||
private final Handler uiHandler = new Handler();
|
private final Handler uiHandler = new Handler();
|
||||||
private OpenExternalLinkReceiver brOpenExternalLink;
|
private OpenExternalLinkReceiver brOpenExternalLink;
|
||||||
private BroadcastReceiver brSetTitle;
|
private BroadcastReceiver brSetTitle;
|
||||||
|
@ -168,10 +165,10 @@ public class MainActivity extends ThemedActivity
|
||||||
|
|
||||||
if ((app = (App) getApplication()) == null) AppLog.e(this, "App is null!");
|
if ((app = (App) getApplication()) == null) AppLog.e(this, "App is null!");
|
||||||
if ((appSettings = app.getSettings()) == null) AppLog.e(this, "AppSettings is null!");
|
if ((appSettings = app.getSettings()) == null) AppLog.e(this, "AppSettings is null!");
|
||||||
if ((podUserProfile = app.getPodUserProfile()) == null)
|
if ((diasporaUserProfile = app.getDiasporaUserProfile()) == null)
|
||||||
AppLog.e(this, "PodUserProfile is null!");
|
AppLog.e(this, "DiasporaUserProfile is null!");
|
||||||
podUserProfile.setCallbackHandler(uiHandler);
|
diasporaUserProfile.setCallbackHandler(uiHandler);
|
||||||
podUserProfile.setListener(this);
|
diasporaUserProfile.setListener(this);
|
||||||
urls = new DiasporaUrlHelper(appSettings);
|
urls = new DiasporaUrlHelper(appSettings);
|
||||||
customTabActivityHelper = new CustomTabActivityHelper();
|
customTabActivityHelper = new CustomTabActivityHelper();
|
||||||
customTabActivityHelper.setConnectionCallback(this);
|
customTabActivityHelper.setConnectionCallback(this);
|
||||||
|
@ -283,8 +280,8 @@ public class MainActivity extends ThemedActivity
|
||||||
BrowserFragment bf = new BrowserFragment();
|
BrowserFragment bf = new BrowserFragment();
|
||||||
fm.beginTransaction().add(bf, fragmentTag).commit();
|
fm.beginTransaction().add(bf, fragmentTag).commit();
|
||||||
return bf;
|
return bf;
|
||||||
case HashtagListFragment.TAG:
|
case TagListFragment.TAG:
|
||||||
HashtagListFragment hlf = new HashtagListFragment();
|
TagListFragment hlf = new TagListFragment();
|
||||||
fm.beginTransaction().add(hlf, fragmentTag).commit();
|
fm.beginTransaction().add(hlf, fragmentTag).commit();
|
||||||
return hlf;
|
return hlf;
|
||||||
case AspectListFragment.TAG:
|
case AspectListFragment.TAG:
|
||||||
|
@ -627,12 +624,12 @@ public class MainActivity extends ThemedActivity
|
||||||
|
|
||||||
if ((item = menu.findItem(R.id.action_notifications)) != null) {
|
if ((item = menu.findItem(R.id.action_notifications)) != null) {
|
||||||
LayerDrawable icon = (LayerDrawable) item.getIcon();
|
LayerDrawable icon = (LayerDrawable) item.getIcon();
|
||||||
BadgeDrawable.setBadgeCount(this, icon, podUserProfile.getNotificationCount());
|
BadgeDrawable.setBadgeCount(this, icon, diasporaUserProfile.getNotificationCount());
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((item = menu.findItem(R.id.action_conversations)) != null) {
|
if ((item = menu.findItem(R.id.action_conversations)) != null) {
|
||||||
LayerDrawable icon = (LayerDrawable) item.getIcon();
|
LayerDrawable icon = (LayerDrawable) item.getIcon();
|
||||||
BadgeDrawable.setBadgeCount(this, icon, podUserProfile.getUnreadMessagesCount());
|
BadgeDrawable.setBadgeCount(this, icon, diasporaUserProfile.getUnreadMessagesCount());
|
||||||
}
|
}
|
||||||
return super.onPrepareOptionsMenu(menu);
|
return super.onPrepareOptionsMenu(menu);
|
||||||
}
|
}
|
||||||
|
@ -648,7 +645,7 @@ public class MainActivity extends ThemedActivity
|
||||||
AppLog.i(this, "onOptionsItemSelected()");
|
AppLog.i(this, "onOptionsItemSelected()");
|
||||||
switch (item.getItemId()) {
|
switch (item.getItemId()) {
|
||||||
case R.id.action_notifications: {
|
case R.id.action_notifications: {
|
||||||
if(appSettings.isExtendedNotificationsActivated()) {
|
if (appSettings.isExtendedNotificationsActivated()) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
//Otherwise we execute the action of action_notifications_all
|
//Otherwise we execute the action of action_notifications_all
|
||||||
|
@ -803,25 +800,17 @@ public class MainActivity extends ThemedActivity
|
||||||
return super.onOptionsItemSelected(item);
|
return super.onOptionsItemSelected(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Update the profile name in the navigation slider
|
|
||||||
*
|
|
||||||
* @param name name
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public void onUserProfileNameChanged(String name) {
|
public void onUserProfileNameChanged(DiasporaUserProfile diasporaUserProfile, String name) {
|
||||||
AppLog.i(this, "onUserProfileNameChanged()");
|
AppLog.i(this, "onUserProfileNameChanged()");
|
||||||
|
// Update the profile name in the navigation slider
|
||||||
navheaderTitle.setText(name);
|
navheaderTitle.setText(name);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Update the profile picture in the navigation slider
|
|
||||||
*
|
|
||||||
* @param avatarUrl url of the new profile pic
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public void onUserProfileAvatarChanged(String avatarUrl) {
|
public void onUserProfileAvatarChanged(DiasporaUserProfile diasporaUserProfile, String avatarUrl) {
|
||||||
AppLog.i(this, "onUserProfileAvatarChanged()");
|
AppLog.i(this, "onUserProfileAvatarChanged()");
|
||||||
|
// Update the profile picture in the navigation slider
|
||||||
app.getAvatarImageLoader().startImageDownload(navheaderImage, avatarUrl);
|
app.getAvatarImageLoader().startImageDownload(navheaderImage, avatarUrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -916,27 +905,20 @@ public class MainActivity extends ThemedActivity
|
||||||
Toast.makeText(this, "Not yet implemented.", Toast.LENGTH_SHORT).show();
|
Toast.makeText(this, "Not yet implemented.", Toast.LENGTH_SHORT).show();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Invalidate the top toolbar to update the notification counter
|
|
||||||
*
|
|
||||||
* @param notificationCount new notification count
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public void onNotificationCountChanged(int notificationCount) {
|
public void onNotificationCountChanged(DiasporaUserProfile diasporaUserProfile, int notificationCount) {
|
||||||
AppLog.i(this, "onNotificationCountChanged()");
|
AppLog.i(this, "onNotificationCountChanged()");
|
||||||
// Count saved in PodUserProfile
|
// Count saved in DiasporaUserProfile
|
||||||
|
// Invalidate the top toolbar to update the unread messages counter
|
||||||
invalidateOptionsMenu();
|
invalidateOptionsMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Invalidate the top toolbar to update the unread messages counter
|
|
||||||
*
|
|
||||||
* @param unreadMessageCount new unread messages count
|
|
||||||
*/
|
|
||||||
@Override
|
@Override
|
||||||
public void onUnreadMessageCountChanged(int unreadMessageCount) {
|
public void onUnreadMessageCountChanged(DiasporaUserProfile diasporaUserProfile, int unreadMessageCount) {
|
||||||
AppLog.i(this, "onUnreadMessageCountChanged()");
|
AppLog.i(this, "onUnreadMessageCountChanged()");
|
||||||
// Count saved in PodUserProfile
|
// Count saved in DiasporaUserProfile
|
||||||
|
// Invalidate the top toolbar to update the unread messages counter
|
||||||
invalidateOptionsMenu();
|
invalidateOptionsMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -950,7 +932,7 @@ public class MainActivity extends ThemedActivity
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onPodSelectionDialogResult(DiasporaPodList.DiasporaPod pod, boolean accepted) {
|
public void onPodSelectionDialogResult(DiasporaPodList.DiasporaPod pod, boolean accepted) {
|
||||||
if(accepted) {
|
if (accepted) {
|
||||||
invalidateOptionsMenu();
|
invalidateOptionsMenu();
|
||||||
navheaderDescription.setText(pod.getName());
|
navheaderDescription.setText(pod.getName());
|
||||||
}
|
}
|
||||||
|
@ -986,7 +968,7 @@ public class MainActivity extends ThemedActivity
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case R.id.nav_followed_tags: {
|
case R.id.nav_followed_tags: {
|
||||||
showFragment(getFragment(HashtagListFragment.TAG));
|
showFragment(getFragment(TagListFragment.TAG));
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -997,7 +979,7 @@ public class MainActivity extends ThemedActivity
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case R.id.nav_contacts: {
|
case R.id.nav_contacts: {
|
||||||
if(WebHelper.isOnline(MainActivity.this)) {
|
if (WebHelper.isOnline(MainActivity.this)) {
|
||||||
openDiasporaUrl(urls.getManageContactsUrl());
|
openDiasporaUrl(urls.getManageContactsUrl());
|
||||||
} else {
|
} else {
|
||||||
snackbarNoInternet.show();
|
snackbarNoInternet.show();
|
||||||
|
|
|
@ -16,13 +16,12 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.activity;
|
||||||
|
|
||||||
import android.content.BroadcastReceiver;
|
import android.content.BroadcastReceiver;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.content.IntentFilter;
|
import android.content.IntentFilter;
|
||||||
import android.content.res.Resources;
|
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.design.widget.Snackbar;
|
import android.support.design.widget.Snackbar;
|
||||||
|
@ -43,16 +42,15 @@ import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList;
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
||||||
import com.github.dfa.diaspora_android.task.GetPodsService;
|
import com.github.dfa.diaspora_android.service.FetchPodsService;
|
||||||
import com.github.dfa.diaspora_android.ui.PodSelectionDialog;
|
import com.github.dfa.diaspora_android.ui.PodSelectionDialog;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedFragment;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.Helpers;
|
import com.github.dfa.diaspora_android.util.Helpers;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
import org.json.JSONException;
|
import org.json.JSONException;
|
||||||
import org.json.JSONObject;
|
import org.json.JSONObject;
|
||||||
|
@ -117,7 +115,7 @@ public class PodSelectionFragment extends ThemedFragment implements SearchView.O
|
||||||
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
LocalBroadcastManager.getInstance(getContext()).registerReceiver(podListReceiver, new IntentFilter(GetPodsService.MESSAGE_PODS_RECEIVED));
|
LocalBroadcastManager.getInstance(getContext()).registerReceiver(podListReceiver, new IntentFilter(FetchPodsService.MESSAGE_PODS_RECEIVED));
|
||||||
Helpers.showInfoIfUserNotConnectedToInternet(getContext(), listViewPod);
|
Helpers.showInfoIfUserNotConnectedToInternet(getContext(), listViewPod);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -144,9 +142,9 @@ public class PodSelectionFragment extends ThemedFragment implements SearchView.O
|
||||||
private final BroadcastReceiver podListReceiver = new BroadcastReceiver() {
|
private final BroadcastReceiver podListReceiver = new BroadcastReceiver() {
|
||||||
@Override
|
@Override
|
||||||
public void onReceive(Context context, Intent intent) {
|
public void onReceive(Context context, Intent intent) {
|
||||||
if (intent.hasExtra(GetPodsService.EXTRA_PODLIST)) {
|
if (intent.hasExtra(FetchPodsService.EXTRA_PODLIST)) {
|
||||||
Bundle extras = intent.getExtras();
|
Bundle extras = intent.getExtras();
|
||||||
DiasporaPodList newPods = (DiasporaPodList) extras.get(GetPodsService.EXTRA_PODLIST);
|
DiasporaPodList newPods = (DiasporaPodList) extras.get(FetchPodsService.EXTRA_PODLIST);
|
||||||
if (newPods != null && newPods.getPods().size() > 0) {
|
if (newPods != null && newPods.getPods().size() > 0) {
|
||||||
try {
|
try {
|
||||||
podList.mergeWithNewerEntries(newPods);
|
podList.mergeWithNewerEntries(newPods);
|
||||||
|
@ -168,7 +166,7 @@ public class PodSelectionFragment extends ThemedFragment implements SearchView.O
|
||||||
@Override
|
@Override
|
||||||
public void onResume() {
|
public void onResume() {
|
||||||
super.onResume();
|
super.onResume();
|
||||||
Intent i = new Intent(getContext(), GetPodsService.class);
|
Intent i = new Intent(getContext(), FetchPodsService.class);
|
||||||
getContext().startService(i);
|
getContext().startService(i);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -222,7 +220,7 @@ public class PodSelectionFragment extends ThemedFragment implements SearchView.O
|
||||||
switch (item.getItemId()) {
|
switch (item.getItemId()) {
|
||||||
case R.id.action_reload: {
|
case R.id.action_reload: {
|
||||||
if (!Helpers.showInfoIfUserNotConnectedToInternet(getContext(), listViewPod)) {
|
if (!Helpers.showInfoIfUserNotConnectedToInternet(getContext(), listViewPod)) {
|
||||||
Intent i = new Intent(getContext(), GetPodsService.class);
|
Intent i = new Intent(getContext(), FetchPodsService.class);
|
||||||
getContext().startService(i);
|
getContext().startService(i);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
|
@ -22,13 +22,14 @@ import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.ui.theme.ColorPalette;
|
||||||
import com.github.dfa.diaspora_android.fragment.ThemedPreferenceFragment;
|
import com.github.dfa.diaspora_android.ui.theme.ThemeHelper;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedActivity;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceFragment;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.ProxyHandler;
|
import com.github.dfa.diaspora_android.web.ProxyHandler;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ColorPalette;
|
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
import butterknife.BindView;
|
import butterknife.BindView;
|
||||||
import butterknife.ButterKnife;
|
import butterknife.ButterKnife;
|
||||||
|
@ -72,7 +73,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
|
|
||||||
protected void showFragment(String tag, boolean addToBackStack) {
|
protected void showFragment(String tag, boolean addToBackStack) {
|
||||||
PreferenceFragment fragment = (PreferenceFragment) getFragmentManager().findFragmentByTag(tag);
|
PreferenceFragment fragment = (PreferenceFragment) getFragmentManager().findFragmentByTag(tag);
|
||||||
if(fragment == null) {
|
if (fragment == null) {
|
||||||
switch (tag) {
|
switch (tag) {
|
||||||
case SettingsFragmentThemes.TAG:
|
case SettingsFragmentThemes.TAG:
|
||||||
fragment = new SettingsFragmentThemes();
|
fragment = new SettingsFragmentThemes();
|
||||||
|
@ -93,7 +94,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FragmentTransaction t = getFragmentManager().beginTransaction();
|
FragmentTransaction t = getFragmentManager().beginTransaction();
|
||||||
if(addToBackStack) {
|
if (addToBackStack) {
|
||||||
t.addToBackStack(tag);
|
t.addToBackStack(tag);
|
||||||
}
|
}
|
||||||
t.replace(R.id.settings__fragment_container, fragment, tag).commit();
|
t.replace(R.id.settings__fragment_container, fragment, tag).commit();
|
||||||
|
@ -142,26 +143,26 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
||||||
if(isAdded() && preference.hasKey()) {
|
if (isAdded() && preference.hasKey()) {
|
||||||
AppSettings settings = ((App)getActivity().getApplication()).getSettings();
|
AppSettings settings = ((App) getActivity().getApplication()).getSettings();
|
||||||
DiasporaUrlHelper diasporaUrlHelper = new DiasporaUrlHelper(settings);
|
DiasporaUrlHelper diasporaUrlHelper = new DiasporaUrlHelper(settings);
|
||||||
String key = preference.getKey();
|
String key = preference.getKey();
|
||||||
/** Sub-Categories */
|
/** Sub-Categories */
|
||||||
if(settings.isKeyEqual(key,R.string.pref_key__cat_themes)) {
|
if (settings.isKeyEqual(key, R.string.pref_key__cat_themes)) {
|
||||||
((SettingsActivity) getActivity()).showFragment(SettingsFragmentThemes.TAG, true);
|
((SettingsActivity) getActivity()).showFragment(SettingsFragmentThemes.TAG, true);
|
||||||
return true;
|
return true;
|
||||||
} else if (settings.isKeyEqual(key,R.string.pref_key__cat_nav_slider)) {
|
} else if (settings.isKeyEqual(key, R.string.pref_key__cat_nav_slider)) {
|
||||||
((SettingsActivity) getActivity()).showFragment(SettingsFragmentNavSlider.TAG, true);
|
((SettingsActivity) getActivity()).showFragment(SettingsFragmentNavSlider.TAG, true);
|
||||||
return true;
|
return true;
|
||||||
} else if (settings.isKeyEqual(key,R.string.pref_key__cat_proxy)) {
|
} else if (settings.isKeyEqual(key, R.string.pref_key__cat_proxy)) {
|
||||||
((SettingsActivity)getActivity()).showFragment(SettingsFragmentProxy.TAG, true);
|
((SettingsActivity) getActivity()).showFragment(SettingsFragmentProxy.TAG, true);
|
||||||
return true;
|
return true;
|
||||||
} else if (settings.isKeyEqual(key,R.string.pref_key__cat_debugging)) {
|
} else if (settings.isKeyEqual(key, R.string.pref_key__cat_debugging)) {
|
||||||
((SettingsActivity)getActivity()).showFragment(SettingsFragmentDebugging.TAG, true);
|
((SettingsActivity) getActivity()).showFragment(SettingsFragmentDebugging.TAG, true);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
/** Network */
|
/** Network */
|
||||||
else if (settings.isKeyEqual(key,R.string.pref_key__clear_cache)) {
|
else if (settings.isKeyEqual(key, R.string.pref_key__clear_cache)) {
|
||||||
Intent intent = new Intent(getActivity(), MainActivity.class);
|
Intent intent = new Intent(getActivity(), MainActivity.class);
|
||||||
intent.setAction(MainActivity.ACTION_CLEAR_CACHE);
|
intent.setAction(MainActivity.ACTION_CLEAR_CACHE);
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
|
@ -169,28 +170,28 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
/** Pod Settings */
|
/** Pod Settings */
|
||||||
if (settings.isKeyEqual(key,R.string.pref_key__personal_settings)) {
|
if (settings.isKeyEqual(key, R.string.pref_key__personal_settings)) {
|
||||||
Intent intent = new Intent(getActivity(), MainActivity.class);
|
Intent intent = new Intent(getActivity(), MainActivity.class);
|
||||||
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
||||||
intent.putExtra(MainActivity.URL_MESSAGE, diasporaUrlHelper.getPersonalSettingsUrl());
|
intent.putExtra(MainActivity.URL_MESSAGE, diasporaUrlHelper.getPersonalSettingsUrl());
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
getActivity().finish();
|
getActivity().finish();
|
||||||
return true;
|
return true;
|
||||||
} else if (settings.isKeyEqual(key,R.string.pref_key__manage_tags)) {
|
} else if (settings.isKeyEqual(key, R.string.pref_key__manage_tags)) {
|
||||||
Intent intent = new Intent(getActivity(), MainActivity.class);
|
Intent intent = new Intent(getActivity(), MainActivity.class);
|
||||||
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
||||||
intent.putExtra(MainActivity.URL_MESSAGE, diasporaUrlHelper.getManageTagsUrl());
|
intent.putExtra(MainActivity.URL_MESSAGE, diasporaUrlHelper.getManageTagsUrl());
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
getActivity().finish();
|
getActivity().finish();
|
||||||
return true;
|
return true;
|
||||||
} else if (settings.isKeyEqual(key,R.string.pref_key__manage_contacts)) {
|
} else if (settings.isKeyEqual(key, R.string.pref_key__manage_contacts)) {
|
||||||
Intent intent = new Intent(getActivity(), MainActivity.class);
|
Intent intent = new Intent(getActivity(), MainActivity.class);
|
||||||
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
||||||
intent.putExtra(MainActivity.URL_MESSAGE, diasporaUrlHelper.getManageContactsUrl());
|
intent.putExtra(MainActivity.URL_MESSAGE, diasporaUrlHelper.getManageContactsUrl());
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
getActivity().finish();
|
getActivity().finish();
|
||||||
return true;
|
return true;
|
||||||
} else if (settings.isKeyEqual(key,R.string.pref_key__change_account)) {
|
} else if (settings.isKeyEqual(key, R.string.pref_key__change_account)) {
|
||||||
new AlertDialog.Builder(getActivity())
|
new AlertDialog.Builder(getActivity())
|
||||||
.setTitle(getString(R.string.confirmation))
|
.setTitle(getString(R.string.confirmation))
|
||||||
.setMessage(getString(R.string.pref_warning__change_account))
|
.setMessage(getString(R.string.pref_warning__change_account))
|
||||||
|
@ -224,7 +225,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updateViewColors() {
|
public void updateViewColors() {
|
||||||
if(isAdded()) {
|
if (isAdded()) {
|
||||||
//Trigger redraw of whole preference screen in order to reflect changes
|
//Trigger redraw of whole preference screen in order to reflect changes
|
||||||
setPreferenceScreen(null);
|
setPreferenceScreen(null);
|
||||||
addPreferencesFromResource(R.xml.preferences__sub_themes);
|
addPreferencesFromResource(R.xml.preferences__sub_themes);
|
||||||
|
@ -235,7 +236,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
||||||
if (isAdded() && preference.hasKey()) {
|
if (isAdded() && preference.hasKey()) {
|
||||||
String key = preference.getKey();
|
String key = preference.getKey();
|
||||||
if(key.equals(getString(R.string.pref_key__primary_color__preference_click))) {
|
if (key.equals(getString(R.string.pref_key__primary_color__preference_click))) {
|
||||||
showColorPickerDialog(1);
|
showColorPickerDialog(1);
|
||||||
return true;
|
return true;
|
||||||
} else if (key.equals(getString(R.string.pref_key__accent_color__preference_click))) {
|
} else if (key.equals(getString(R.string.pref_key__accent_color__preference_click))) {
|
||||||
|
@ -257,7 +258,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
|
|
||||||
//Inflate dialog layout
|
//Inflate dialog layout
|
||||||
LayoutInflater inflater = getActivity().getLayoutInflater();
|
LayoutInflater inflater = getActivity().getLayoutInflater();
|
||||||
View dialogLayout = inflater.inflate(R.layout.color_picker__dialog, null);
|
View dialogLayout = inflater.inflate(R.layout.ui__dialog__color_picker, null);
|
||||||
final android.support.v7.app.AlertDialog.Builder builder = new android.support.v7.app.AlertDialog.Builder(context);
|
final android.support.v7.app.AlertDialog.Builder builder = new android.support.v7.app.AlertDialog.Builder(context);
|
||||||
builder.setView(dialogLayout);
|
builder.setView(dialogLayout);
|
||||||
|
|
||||||
|
@ -305,7 +306,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
if (Build.VERSION.SDK_INT >= 21) {
|
if (Build.VERSION.SDK_INT >= 21) {
|
||||||
getActivity().getWindow().setStatusBarColor(ThemeHelper.getPrimaryDarkColor());
|
getActivity().getWindow().setStatusBarColor(ThemeHelper.getPrimaryDarkColor());
|
||||||
}
|
}
|
||||||
((ThemedActivity) getActivity()).applyColorToViews();
|
((SettingsActivity) getActivity()).applyColorToViews();
|
||||||
} else {
|
} else {
|
||||||
appSettings.setAccentColorSettings(base.getColor(), shade.getColor());
|
appSettings.setAccentColorSettings(base.getColor(), shade.getColor());
|
||||||
}
|
}
|
||||||
|
@ -348,7 +349,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void updateSummaries() {
|
public void updateSummaries() {
|
||||||
if(isAdded()) {
|
if (isAdded()) {
|
||||||
AppSettings settings = ((App) getActivity().getApplication()).getSettings();
|
AppSettings settings = ((App) getActivity().getApplication()).getSettings();
|
||||||
findPreference(settings.getKey(R.string.pref_key__http_proxy_host)).setSummary(settings.getProxyHttpHost());
|
findPreference(settings.getKey(R.string.pref_key__http_proxy_host)).setSummary(settings.getProxyHttpHost());
|
||||||
findPreference(settings.getKey(R.string.pref_key__http_proxy_port)).setSummary(Integer.toString(settings.getProxyHttpPort()));
|
findPreference(settings.getKey(R.string.pref_key__http_proxy_port)).setSummary(Integer.toString(settings.getProxyHttpPort()));
|
||||||
|
@ -360,7 +361,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
if (isAdded() && preference.hasKey()) {
|
if (isAdded() && preference.hasKey()) {
|
||||||
AppSettings appSettings = ((App) getActivity().getApplication()).getSettings();
|
AppSettings appSettings = ((App) getActivity().getApplication()).getSettings();
|
||||||
String key = preference.getKey();
|
String key = preference.getKey();
|
||||||
if(appSettings.isKeyEqual(key, R.string.pref_key__http_proxy_load_tor_preset)) {
|
if (appSettings.isKeyEqual(key, R.string.pref_key__http_proxy_load_tor_preset)) {
|
||||||
appSettings.setProxyHttpHost("127.0.0.1");
|
appSettings.setProxyHttpHost("127.0.0.1");
|
||||||
appSettings.setProxyHttpPort(8118);
|
appSettings.setProxyHttpPort(8118);
|
||||||
return true;
|
return true;
|
||||||
|
@ -376,7 +377,7 @@ public class SettingsActivity extends ThemedActivity {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
|
public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
|
||||||
if(isAdded()) {
|
if (isAdded()) {
|
||||||
if (key.equals(getString(R.string.pref_key__http_proxy_host)) ||
|
if (key.equals(getString(R.string.pref_key__http_proxy_host)) ||
|
||||||
key.equals(getString(R.string.pref_key__http_proxy_port))) {
|
key.equals(getString(R.string.pref_key__http_proxy_port))) {
|
||||||
updateSummaries();
|
updateSummaries();
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.activity;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.PorterDuff;
|
import android.graphics.PorterDuff;
|
||||||
|
@ -34,10 +34,10 @@ import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.listener.OnSomethingClickListener;
|
import com.github.dfa.diaspora_android.listener.OnSomethingClickListener;
|
||||||
|
import com.github.dfa.diaspora_android.ui.theme.ThemedFragment;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
import com.github.dfa.diaspora_android.util.Helpers;
|
import com.github.dfa.diaspora_android.util.Helpers;
|
||||||
|
|
||||||
|
@ -51,9 +51,9 @@ import butterknife.ButterKnife;
|
||||||
/**
|
/**
|
||||||
* Fragment that shows a list of the HashTags the user follows
|
* Fragment that shows a list of the HashTags the user follows
|
||||||
*/
|
*/
|
||||||
public class HashtagListFragment extends ThemedFragment implements OnSomethingClickListener<Object> {
|
public class TagListFragment extends ThemedFragment implements OnSomethingClickListener<Object> {
|
||||||
|
|
||||||
public static final String TAG = "com.github.dfa.diaspora_android.HashtagListFragment";
|
public static final String TAG = "com.github.dfa.diaspora_android.TagListFragment";
|
||||||
|
|
||||||
protected RecyclerView followedTagsRecyclerView;
|
protected RecyclerView followedTagsRecyclerView;
|
||||||
protected App app;
|
protected App app;
|
||||||
|
@ -147,7 +147,7 @@ public class HashtagListFragment extends ThemedFragment implements OnSomethingCl
|
||||||
@Override
|
@Override
|
||||||
public FollowedTagsAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
public FollowedTagsAdapter.ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
|
||||||
View v = LayoutInflater.from(parent.getContext())
|
View v = LayoutInflater.from(parent.getContext())
|
||||||
.inflate(R.layout.recycler_view__list_item, parent, false);
|
.inflate(R.layout.recycler_list__list_item_with_fav, parent, false);
|
||||||
return new ViewHolder(v);
|
return new ViewHolder(v);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -158,7 +158,7 @@ public class HashtagListFragment extends ThemedFragment implements OnSomethingCl
|
||||||
final String tag = followedTagsList[position];
|
final String tag = followedTagsList[position];
|
||||||
holder.title.setText(tag);
|
holder.title.setText(tag);
|
||||||
if (position % 2 == 1) {
|
if (position % 2 == 1) {
|
||||||
holder.root.setBackgroundColor(Helpers.getColorFromRessource(c, R.color.md_grey_300));
|
holder.root.setBackgroundColor(Helpers.getColorFromRessource(c, R.color.alternate_row_color));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Favourite (Star) Image
|
// Favourite (Star) Image
|
|
@ -19,25 +19,26 @@
|
||||||
package com.github.dfa.diaspora_android.data;
|
package com.github.dfa.diaspora_android.data;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
|
|
||||||
import org.json.JSONException;
|
import org.json.JSONException;
|
||||||
import org.json.JSONObject;
|
import org.json.JSONObject;
|
||||||
|
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
|
|
||||||
public class PodAspect {
|
public class DiasporaAspect {
|
||||||
public long id;
|
public long id;
|
||||||
public String name;
|
public String name;
|
||||||
public boolean selected;
|
public boolean selected;
|
||||||
|
|
||||||
public PodAspect(long id, String name, boolean selected) {
|
public DiasporaAspect(long id, String name, boolean selected) {
|
||||||
this.id = id;
|
this.id = id;
|
||||||
this.name = name;
|
this.name = name;
|
||||||
this.selected = selected;
|
this.selected = selected;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public PodAspect(String shareabletext) {
|
public DiasporaAspect(String shareabletext) {
|
||||||
// fromShareAbleText
|
// fromShareAbleText
|
||||||
String[] str = shareabletext.split("%");
|
String[] str = shareabletext.split("%");
|
||||||
selected = Integer.parseInt(str[0]) == 1;
|
selected = Integer.parseInt(str[0]) == 1;
|
||||||
|
@ -45,7 +46,7 @@ public class PodAspect {
|
||||||
name = shareabletext.substring(shareabletext.indexOf(str[1]) + str[1].length() + 1);
|
name = shareabletext.substring(shareabletext.indexOf(str[1]) + str[1].length() + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
public PodAspect(JSONObject json) throws JSONException {
|
public DiasporaAspect(JSONObject json) throws JSONException {
|
||||||
if (json.has("id")) {
|
if (json.has("id")) {
|
||||||
id = json.getLong("id");
|
id = json.getLong("id");
|
||||||
}
|
}
|
||||||
|
@ -81,7 +82,7 @@ public class PodAspect {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(Object o) {
|
public boolean equals(Object o) {
|
||||||
return o instanceof PodAspect && ((PodAspect) o).id == id;
|
return o instanceof DiasporaAspect && ((DiasporaAspect) o).id == id;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String toShareAbleText() {
|
public String toShareAbleText() {
|
|
@ -21,8 +21,9 @@ package com.github.dfa.diaspora_android.data;
|
||||||
import android.os.Handler;
|
import android.os.Handler;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.listener.WebUserProfileChangedListener;
|
import com.github.dfa.diaspora_android.listener.DiasporaUserProfileChangedListener;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
|
|
||||||
import org.json.JSONArray;
|
import org.json.JSONArray;
|
||||||
import org.json.JSONException;
|
import org.json.JSONException;
|
||||||
|
@ -32,47 +33,47 @@ import org.json.JSONObject;
|
||||||
* User profile
|
* User profile
|
||||||
* Created by gsantner (https://gsantner.github.io/) on 24.03.16. Part of Diaspora for Android.
|
* Created by gsantner (https://gsantner.github.io/) on 24.03.16. Part of Diaspora for Android.
|
||||||
*/
|
*/
|
||||||
public class PodUserProfile {
|
public class DiasporaUserProfile {
|
||||||
private static final int MINIMUM_WEBUSERPROFILE_LOAD_TIMEDIFF = 5000;
|
private static final int MINIMUM_USERPROFILE_LOAD_TIMEDIFF = 5000;
|
||||||
|
|
||||||
private Handler callbackHandler;
|
private Handler callbackHandler;
|
||||||
private WebUserProfileChangedListener listener;
|
private DiasporaUserProfileChangedListener listener;
|
||||||
private final App app;
|
private final App app;
|
||||||
private final AppSettings appSettings;
|
private final AppSettings appSettings;
|
||||||
private JSONObject json;
|
private JSONObject json;
|
||||||
private long lastLoaded;
|
private long userProfileLastLoadedTimestamp;
|
||||||
private boolean isWebUserProfileLoaded;
|
private boolean isWebUserProfileLoaded;
|
||||||
|
|
||||||
private String avatarUrl;
|
private String avatarUrl;
|
||||||
private String guid;
|
private String guid;
|
||||||
private String name;
|
private String name;
|
||||||
private PodAspect[] podAspects;
|
private DiasporaAspect[] aspects;
|
||||||
private String[] followedTags;
|
private String[] followedTags;
|
||||||
private int notificationCount;
|
private int notificationCount;
|
||||||
private int unreadMessagesCount;
|
private int unreadMessagesCount;
|
||||||
|
|
||||||
|
|
||||||
public PodUserProfile(App app) {
|
public DiasporaUserProfile(App app) {
|
||||||
this.app = app;
|
this.app = app;
|
||||||
appSettings = app.getSettings();
|
appSettings = app.getSettings();
|
||||||
|
|
||||||
avatarUrl = appSettings.getAvatarUrl();
|
avatarUrl = appSettings.getAvatarUrl();
|
||||||
guid = appSettings.getProfileId();
|
guid = appSettings.getProfileId();
|
||||||
name = appSettings.getName();
|
name = appSettings.getName();
|
||||||
podAspects = appSettings.getAspects();
|
aspects = appSettings.getAspects();
|
||||||
followedTags = appSettings.getFollowedTags();
|
followedTags = appSettings.getFollowedTags();
|
||||||
notificationCount = appSettings.getNotificationCount();
|
notificationCount = appSettings.getNotificationCount();
|
||||||
unreadMessagesCount = appSettings.getUnreadMessageCount();
|
unreadMessagesCount = appSettings.getUnreadMessageCount();
|
||||||
}
|
}
|
||||||
|
|
||||||
public PodUserProfile(App app, Handler callbackHandler, WebUserProfileChangedListener listener) {
|
public DiasporaUserProfile(App app, Handler callbackHandler, DiasporaUserProfileChangedListener listener) {
|
||||||
this(app);
|
this(app);
|
||||||
this.listener = listener;
|
this.listener = listener;
|
||||||
this.callbackHandler = callbackHandler;
|
this.callbackHandler = callbackHandler;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isRefreshNeeded() {
|
public boolean isRefreshNeeded() {
|
||||||
return (System.currentTimeMillis() - lastLoaded) >= MINIMUM_WEBUSERPROFILE_LOAD_TIMEDIFF;
|
return (System.currentTimeMillis() - userProfileLastLoadedTimestamp) >= MINIMUM_USERPROFILE_LOAD_TIMEDIFF;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isWebUserProfileLoaded() {
|
public boolean isWebUserProfileLoaded() {
|
||||||
|
@ -82,7 +83,7 @@ public class PodUserProfile {
|
||||||
public boolean parseJson(String jsonStr) {
|
public boolean parseJson(String jsonStr) {
|
||||||
try {
|
try {
|
||||||
json = new JSONObject(jsonStr);
|
json = new JSONObject(jsonStr);
|
||||||
lastLoaded = System.currentTimeMillis();
|
userProfileLastLoadedTimestamp = System.currentTimeMillis();
|
||||||
|
|
||||||
// Avatar
|
// Avatar
|
||||||
if (json.has("avatar")) {
|
if (json.has("avatar")) {
|
||||||
|
@ -115,7 +116,7 @@ public class PodUserProfile {
|
||||||
|
|
||||||
// Aspect
|
// Aspect
|
||||||
if (json.has("aspects") && loadAspects(json.getJSONArray("aspects"))) {
|
if (json.has("aspects") && loadAspects(json.getJSONArray("aspects"))) {
|
||||||
appSettings.setPodAspects(podAspects);
|
appSettings.setPodAspects(aspects);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Followed tags
|
// Followed tags
|
||||||
|
@ -129,7 +130,7 @@ public class PodUserProfile {
|
||||||
AppLog.d(this, e.getMessage());
|
AppLog.d(this, e.getMessage());
|
||||||
isWebUserProfileLoaded = false;
|
isWebUserProfileLoaded = false;
|
||||||
}
|
}
|
||||||
lastLoaded = System.currentTimeMillis();
|
userProfileLastLoadedTimestamp = System.currentTimeMillis();
|
||||||
return isWebUserProfileLoaded;
|
return isWebUserProfileLoaded;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -157,8 +158,8 @@ public class PodUserProfile {
|
||||||
return unreadMessagesCount;
|
return unreadMessagesCount;
|
||||||
}
|
}
|
||||||
|
|
||||||
public PodAspect[] getAspects() {
|
public DiasporaAspect[] getAspects() {
|
||||||
return podAspects;
|
return aspects;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String[] getFollowedTags() {
|
public String[] getFollowedTags() {
|
||||||
|
@ -181,7 +182,7 @@ public class PodUserProfile {
|
||||||
if (listener != null && callbackHandler != null) {
|
if (listener != null && callbackHandler != null) {
|
||||||
callbackHandler.post(new Runnable() {
|
callbackHandler.post(new Runnable() {
|
||||||
public void run() {
|
public void run() {
|
||||||
listener.onUserProfileAvatarChanged(avatarUrl);
|
listener.onUserProfileAvatarChanged(DiasporaUserProfile.this, avatarUrl);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -204,7 +205,7 @@ public class PodUserProfile {
|
||||||
if (listener != null && callbackHandler != null) {
|
if (listener != null && callbackHandler != null) {
|
||||||
callbackHandler.post(new Runnable() {
|
callbackHandler.post(new Runnable() {
|
||||||
public void run() {
|
public void run() {
|
||||||
listener.onUserProfileNameChanged(name);
|
listener.onUserProfileNameChanged(DiasporaUserProfile.this, name);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -219,7 +220,7 @@ public class PodUserProfile {
|
||||||
if (listener != null && callbackHandler != null) {
|
if (listener != null && callbackHandler != null) {
|
||||||
callbackHandler.post(new Runnable() {
|
callbackHandler.post(new Runnable() {
|
||||||
public void run() {
|
public void run() {
|
||||||
listener.onNotificationCountChanged(notificationCount);
|
listener.onNotificationCountChanged(DiasporaUserProfile.this, notificationCount);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -229,9 +230,9 @@ public class PodUserProfile {
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean loadAspects(final JSONArray jsonAspects) throws JSONException {
|
private boolean loadAspects(final JSONArray jsonAspects) throws JSONException {
|
||||||
podAspects = new PodAspect[jsonAspects.length()];
|
aspects = new DiasporaAspect[jsonAspects.length()];
|
||||||
for (int i = 0; i < jsonAspects.length(); i++) {
|
for (int i = 0; i < jsonAspects.length(); i++) {
|
||||||
podAspects[i] = new PodAspect(jsonAspects.getJSONObject(i));
|
aspects[i] = new DiasporaAspect(jsonAspects.getJSONObject(i));
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -250,7 +251,7 @@ public class PodUserProfile {
|
||||||
if (listener != null && callbackHandler != null) {
|
if (listener != null && callbackHandler != null) {
|
||||||
callbackHandler.post(new Runnable() {
|
callbackHandler.post(new Runnable() {
|
||||||
public void run() {
|
public void run() {
|
||||||
listener.onUnreadMessageCountChanged(unreadMessagesCount);
|
listener.onUnreadMessageCountChanged(DiasporaUserProfile.this, unreadMessagesCount);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -267,11 +268,11 @@ public class PodUserProfile {
|
||||||
this.callbackHandler = callbackHandler;
|
this.callbackHandler = callbackHandler;
|
||||||
}
|
}
|
||||||
|
|
||||||
public WebUserProfileChangedListener getListener() {
|
public DiasporaUserProfileChangedListener getListener() {
|
||||||
return listener;
|
return listener;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setListener(WebUserProfileChangedListener listener) {
|
public void setListener(DiasporaUserProfileChangedListener listener) {
|
||||||
this.listener = listener;
|
this.listener = listener;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,55 @@
|
||||||
|
/*
|
||||||
|
This file is part of the Diaspora for Android.
|
||||||
|
|
||||||
|
Diaspora for Android is free software: you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 3 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
Diaspora for Android is distributed in the hope that it will be useful,
|
||||||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
GNU General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with the Diaspora for Android.
|
||||||
|
|
||||||
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
package com.github.dfa.diaspora_android.listener;
|
||||||
|
|
||||||
|
import com.github.dfa.diaspora_android.data.DiasporaUserProfile;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Created by gsantner (https://gsantner.github.io/) on 26.03.16.
|
||||||
|
* Interface that needs to be implemented by classes that listen for Profile related changes
|
||||||
|
*/
|
||||||
|
public interface DiasporaUserProfileChangedListener {
|
||||||
|
/**
|
||||||
|
* Called when the DiasporaUserProfile name changed
|
||||||
|
* @param diasporaUserProfile The profile
|
||||||
|
* @param name The new name
|
||||||
|
*/
|
||||||
|
void onUserProfileNameChanged(DiasporaUserProfile diasporaUserProfile, String name);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the DiasporaUserProfile avatarUrl changed
|
||||||
|
* @param diasporaUserProfile The profile
|
||||||
|
* @param avatarUrl The new name
|
||||||
|
*/
|
||||||
|
void onUserProfileAvatarChanged(DiasporaUserProfile diasporaUserProfile, String avatarUrl);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the DiasporaUserProfile notificationCount changed
|
||||||
|
* @param diasporaUserProfile The profile
|
||||||
|
* @param notificationCount The new notificationCount
|
||||||
|
*/
|
||||||
|
void onNotificationCountChanged(DiasporaUserProfile diasporaUserProfile, int notificationCount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Called when the DiasporaUserProfile unreadMessageCount changed
|
||||||
|
* @param diasporaUserProfile The profile
|
||||||
|
* @param unreadMessageCount The new unreadMessageCount
|
||||||
|
*/
|
||||||
|
void onUnreadMessageCountChanged(DiasporaUserProfile diasporaUserProfile, int unreadMessageCount);
|
||||||
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.listener;
|
||||||
|
|
||||||
import android.support.design.widget.AppBarLayout;
|
import android.support.design.widget.AppBarLayout;
|
||||||
|
|
|
@ -1,33 +0,0 @@
|
||||||
/*
|
|
||||||
This file is part of the Diaspora for Android.
|
|
||||||
|
|
||||||
Diaspora for Android is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
Diaspora for Android is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with the Diaspora for Android.
|
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
*/
|
|
||||||
package com.github.dfa.diaspora_android.listener;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Created by gsantner (https://gsantner.github.io/) on 26.03.16.
|
|
||||||
* Interface that needs to be implemented by classes that listen for Profile related changes
|
|
||||||
*/
|
|
||||||
public interface WebUserProfileChangedListener {
|
|
||||||
void onUserProfileNameChanged(String name);
|
|
||||||
|
|
||||||
void onUserProfileAvatarChanged(String avatarUrl);
|
|
||||||
|
|
||||||
void onNotificationCountChanged(int notificationCount);
|
|
||||||
|
|
||||||
void onUnreadMessageCountChanged(int unreadMessageCount);
|
|
||||||
}
|
|
|
@ -29,11 +29,11 @@ import android.support.customtabs.CustomTabsIntent;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.activity.MainActivity;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.ui.theme.ThemeHelper;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.CustomTabHelpers.BrowserFallback;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.CustomTabHelpers.CustomTabActivityHelper;
|
import com.github.dfa.diaspora_android.web.custom_tab.BrowserFallback;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
import com.github.dfa.diaspora_android.web.custom_tab.CustomTabActivityHelper;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* BroadcastReceiver that opens links in a Chrome CustomTab
|
* BroadcastReceiver that opens links in a Chrome CustomTab
|
||||||
|
|
|
@ -25,8 +25,8 @@ import android.content.Intent;
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.activity.MainActivity;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -17,15 +17,13 @@
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package com.github.dfa.diaspora_android.util;
|
package com.github.dfa.diaspora_android.service;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.Bitmap;
|
import android.graphics.Bitmap;
|
||||||
import android.graphics.BitmapFactory;
|
import android.graphics.BitmapFactory;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.task.ImageDownloadTask;
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
|
||||||
public class AvatarImageLoader {
|
public class AvatarImageLoader {
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.task;
|
package com.github.dfa.diaspora_android.service;
|
||||||
|
|
||||||
import android.app.Service;
|
import android.app.Service;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
|
@ -38,12 +38,12 @@ import javax.net.ssl.HttpsURLConnection;
|
||||||
|
|
||||||
import info.guardianproject.netcipher.NetCipher;
|
import info.guardianproject.netcipher.NetCipher;
|
||||||
|
|
||||||
public class GetPodsService extends Service {
|
public class FetchPodsService extends Service {
|
||||||
public static final String EXTRA_PODLIST = "pods";
|
public static final String EXTRA_PODLIST = "pods";
|
||||||
public static final String MESSAGE_PODS_RECEIVED = "com.github.dfa.diaspora.podsreceived";
|
public static final String MESSAGE_PODS_RECEIVED = "com.github.dfa.diaspora.podsreceived";
|
||||||
public static final String PODDY_PODLIST_URL = "https://raw.githubusercontent.com/Diaspora-for-Android/diaspora-android-extras/master/podList/podlist.json";
|
public static final String PODDY_PODLIST_URL = "https://raw.githubusercontent.com/Diaspora-for-Android/diaspora-android-extras/master/podList/podlist.json";
|
||||||
|
|
||||||
public GetPodsService() {
|
public FetchPodsService() {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
|
@ -18,14 +18,14 @@
|
||||||
|
|
||||||
This file is inspired from sourabhsoni.com/implementing-hashtags-in-android-application/
|
This file is inspired from sourabhsoni.com/implementing-hashtags-in-android-application/
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.data;
|
package com.github.dfa.diaspora_android.service;
|
||||||
|
|
||||||
import android.content.ContentProvider;
|
import android.content.ContentProvider;
|
||||||
import android.content.ContentValues;
|
import android.content.ContentValues;
|
||||||
import android.database.Cursor;
|
import android.database.Cursor;
|
||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
|
|
||||||
public class HashtagProvider extends ContentProvider {
|
public class HashtagContentProvider extends ContentProvider {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int delete(Uri arg0, String arg1, String[] arg2) {
|
public int delete(Uri arg0, String arg1, String[] arg2) {
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.task;
|
package com.github.dfa.diaspora_android.service;
|
||||||
|
|
||||||
import android.graphics.Bitmap;
|
import android.graphics.Bitmap;
|
||||||
import android.graphics.BitmapFactory;
|
import android.graphics.BitmapFactory;
|
|
@ -16,14 +16,14 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.task;
|
package com.github.dfa.diaspora_android.service;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.os.AsyncTask;
|
import android.os.AsyncTask;
|
||||||
import android.webkit.CookieManager;
|
import android.webkit.CookieManager;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.data.PodUserProfile;
|
import com.github.dfa.diaspora_android.data.DiasporaUserProfile;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
import com.github.dfa.diaspora_android.util.DiasporaUrlHelper;
|
||||||
|
|
||||||
|
@ -99,7 +99,7 @@ public class ProfileFetchTask extends AsyncTask<Void, Void, Void> {
|
||||||
|
|
||||||
|
|
||||||
if (extractedProfileData != null) {
|
if (extractedProfileData != null) {
|
||||||
PodUserProfile profile = new PodUserProfile(app);
|
DiasporaUserProfile profile = new DiasporaUserProfile(app);
|
||||||
profile.parseJson(extractedProfileData);
|
profile.parseJson(extractedProfileData);
|
||||||
AppLog.d(this, "Extracted new_messages (service):" + profile.getUnreadMessagesCount());
|
AppLog.d(this, "Extracted new_messages (service):" + profile.getUnreadMessagesCount());
|
||||||
}
|
}
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.task;
|
package com.github.dfa.diaspora_android.service;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.os.AsyncTask;
|
import android.os.AsyncTask;
|
|
@ -31,7 +31,7 @@ import android.graphics.drawable.LayerDrawable;
|
||||||
import android.support.v4.content.ContextCompat;
|
import android.support.v4.content.ContextCompat;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
|
|
||||||
public class BadgeDrawable extends Drawable {
|
public class BadgeDrawable extends Drawable {
|
||||||
// Source: http://mobikul.com/adding-badge-count-on-menu-items-like-cart-notification-etc/
|
// Source: http://mobikul.com/adding-badge-count-on-menu-items-like-cart-notification-etc/
|
||||||
|
|
|
@ -36,7 +36,7 @@ import java.util.regex.Pattern;
|
||||||
* TextView, that renders HTML with highlited and clickable links and hashtags.
|
* TextView, that renders HTML with highlited and clickable links and hashtags.
|
||||||
* Links are opened in a webbrowser.
|
* Links are opened in a webbrowser.
|
||||||
* Hashtags open the MainActivity, load the new-post site of the selected pod and insert the
|
* Hashtags open the MainActivity, load the new-post site of the selected pod and insert the
|
||||||
* hashtag into the post editor. See data/HashtagProvider.
|
* hashtag into the post editor. See data/HashtagContentProvider.
|
||||||
*/
|
*/
|
||||||
public class HtmlTextView extends TextView {
|
public class HtmlTextView extends TextView {
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,6 @@ import android.app.Dialog;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.annotation.NonNull;
|
import android.support.annotation.NonNull;
|
||||||
import android.support.v7.app.AlertDialog;
|
import android.support.v7.app.AlertDialog;
|
||||||
import android.support.v7.app.AppCompatDialogFragment;
|
|
||||||
import android.text.TextUtils;
|
import android.text.TextUtils;
|
||||||
import android.view.LayoutInflater;
|
import android.view.LayoutInflater;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
|
@ -18,12 +17,12 @@ import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod.DiasporaPodUrl;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod.DiasporaPodUrl;
|
||||||
import com.github.dfa.diaspora_android.fragment.ThemedAppCompatDialogFragment;
|
import com.github.dfa.diaspora_android.ui.theme.ThemeHelper;
|
||||||
import com.github.dfa.diaspora_android.util.ProxyHandler;
|
import com.github.dfa.diaspora_android.ui.theme.ThemedAppCompatDialogFragment;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
|
import com.github.dfa.diaspora_android.web.ProxyHandler;
|
||||||
|
|
||||||
import org.json.JSONException;
|
import org.json.JSONException;
|
||||||
|
|
||||||
|
@ -38,7 +37,7 @@ import butterknife.OnItemSelected;
|
||||||
* Created by gsantner (https://gsantner.github.io) on 06.10.16.
|
* Created by gsantner (https://gsantner.github.io) on 06.10.16.
|
||||||
*/
|
*/
|
||||||
public class PodSelectionDialog extends ThemedAppCompatDialogFragment {
|
public class PodSelectionDialog extends ThemedAppCompatDialogFragment {
|
||||||
public static final String TAG = "com.github.dfa.diaspora_android.PodSelectionDialog";
|
public static final String TAG = "com.github.dfa.diaspora_android.ui.PodSelectionDialog";
|
||||||
|
|
||||||
public static interface PodSelectionDialogResultListener {
|
public static interface PodSelectionDialogResultListener {
|
||||||
void onPodSelectionDialogResult(DiasporaPod pod, boolean accepted);
|
void onPodSelectionDialogResult(DiasporaPod pod, boolean accepted);
|
||||||
|
@ -145,7 +144,7 @@ public class PodSelectionDialog extends ThemedAppCompatDialogFragment {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected AppSettings getAppSettings() {
|
protected AppSettings getAppSettings() {
|
||||||
if(isAdded()) {
|
if (isAdded()) {
|
||||||
return ((App) getActivity().getApplication()).getSettings();
|
return ((App) getActivity().getApplication()).getSettings();
|
||||||
} else {
|
} else {
|
||||||
return new AppSettings(getContext().getApplicationContext());
|
return new AppSettings(getContext().getApplicationContext());
|
||||||
|
@ -202,7 +201,7 @@ public class PodSelectionDialog extends ThemedAppCompatDialogFragment {
|
||||||
pod.getPodUrls().add(podUrl);
|
pod.getPodUrls().add(podUrl);
|
||||||
|
|
||||||
// Load Tor preset
|
// Load Tor preset
|
||||||
if(pod.getPodUrl().getHost().endsWith(".onion") && checkboxTorPreset.isChecked()){
|
if (pod.getPodUrl().getHost().endsWith(".onion") && checkboxTorPreset.isChecked()) {
|
||||||
AppSettings settings = app.getSettings();
|
AppSettings settings = app.getSettings();
|
||||||
settings.setProxyHttpEnabled(true);
|
settings.setProxyHttpEnabled(true);
|
||||||
settings.setProxyWasEnabled(false);
|
settings.setProxyWasEnabled(false);
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.util.theming;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.Color;
|
import android.graphics.Color;
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.v4.app.Fragment;
|
import android.support.v4.app.Fragment;
|
||||||
|
@ -30,7 +30,7 @@ import android.view.MenuInflater;
|
||||||
|
|
||||||
public abstract class CustomFragment extends Fragment {
|
public abstract class CustomFragment extends Fragment {
|
||||||
|
|
||||||
public static final String TAG = "com.github.dfa.diaspora_android.CustomFragment";
|
public static final String TAG = "com.github.dfa.diaspora_android.ui.theme.CustomFragment";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* We have an optionsMenu
|
* We have an optionsMenu
|
|
@ -17,7 +17,7 @@
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
This class is inspired by org.horasapps.LeafPic
|
This class is inspired by org.horasapps.LeafPic
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.util.theming;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.content.res.ColorStateList;
|
import android.content.res.ColorStateList;
|
||||||
import android.graphics.Color;
|
import android.graphics.Color;
|
||||||
|
@ -37,7 +37,7 @@ import android.widget.RadioGroup;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Singleton that can be used to color views
|
* Singleton that can be used to color views
|
||||||
|
@ -68,7 +68,7 @@ public class ThemeHelper {
|
||||||
public static void updateEditTextColor(EditText editText) {
|
public static void updateEditTextColor(EditText editText) {
|
||||||
if (editText != null) {
|
if (editText != null) {
|
||||||
editText.setHighlightColor(getInstance().appSettings.getAccentColor());
|
editText.setHighlightColor(getInstance().appSettings.getAccentColor());
|
||||||
if(Build.VERSION.SDK_INT >= 21) {
|
if (Build.VERSION.SDK_INT >= 21) {
|
||||||
editText.getBackground().mutate().setColorFilter(getAccentColor(), PorterDuff.Mode.SRC_ATOP);
|
editText.getBackground().mutate().setColorFilter(getAccentColor(), PorterDuff.Mode.SRC_ATOP);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -97,7 +97,7 @@ public class ThemeHelper {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void updateTextViewTextColor(TextView textView) {
|
public static void updateTextViewTextColor(TextView textView) {
|
||||||
if(textView != null) {
|
if (textView != null) {
|
||||||
textView.setTextColor(getInstance().appSettings.getAccentColor());
|
textView.setTextColor(getInstance().appSettings.getAccentColor());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -139,12 +139,12 @@ public class ThemeHelper {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void updateRadioGroupColor(RadioGroup radioGroup) {
|
public static void updateRadioGroupColor(RadioGroup radioGroup) {
|
||||||
if(radioGroup != null && Build.VERSION.SDK_INT >= 21) {
|
if (radioGroup != null && Build.VERSION.SDK_INT >= 21) {
|
||||||
for (int i = 0; i < radioGroup.getChildCount(); ++i) {
|
for (int i = 0; i < radioGroup.getChildCount(); ++i) {
|
||||||
RadioButton btn = ((RadioButton) radioGroup.getChildAt(i));
|
RadioButton btn = ((RadioButton) radioGroup.getChildAt(i));
|
||||||
btn.setButtonTintList(new ColorStateList(
|
btn.setButtonTintList(new ColorStateList(
|
||||||
new int[][]{ new int[]{-android.R.attr.state_enabled}, new int[]{android.R.attr.state_enabled} },
|
new int[][]{new int[]{-android.R.attr.state_enabled}, new int[]{android.R.attr.state_enabled}},
|
||||||
new int[] { Color.BLACK ,ThemeHelper.getAccentColor() }));
|
new int[]{Color.BLACK, ThemeHelper.getAccentColor()}));
|
||||||
btn.invalidate();
|
btn.invalidate();
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface that allows setting Theme colors
|
* Interface that allows setting Theme colors
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.activity;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.annotation.TargetApi;
|
import android.annotation.TargetApi;
|
||||||
import android.app.ActivityManager;
|
import android.app.ActivityManager;
|
||||||
|
@ -26,8 +26,7 @@ import android.support.v7.app.AppCompatActivity;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Activity that supports color schemes
|
* Activity that supports color schemes
|
|
@ -1,11 +1,10 @@
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.app.Dialog;
|
import android.app.Dialog;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.support.v7.app.AppCompatDialogFragment;
|
import android.support.v7.app.AppCompatDialogFragment;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Themed DialogFragment
|
* Themed DialogFragment
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.preference.CheckBoxPreference;
|
import android.preference.CheckBoxPreference;
|
||||||
|
@ -7,9 +7,7 @@ import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.CheckBox;
|
import android.widget.CheckBox;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by vanitas on 24.10.16.
|
* Created by vanitas on 24.10.16.
|
||||||
|
@ -17,14 +15,17 @@ import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
||||||
|
|
||||||
public class ThemedCheckBoxPreference extends CheckBoxPreference implements Themeable {
|
public class ThemedCheckBoxPreference extends CheckBoxPreference implements Themeable {
|
||||||
protected View rootLayout;
|
protected View rootLayout;
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public ThemedCheckBoxPreference(Context context) {
|
public ThemedCheckBoxPreference(Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public ThemedCheckBoxPreference(Context context, AttributeSet attrs) {
|
public ThemedCheckBoxPreference(Context context, AttributeSet attrs) {
|
||||||
super(context, attrs);
|
super(context, attrs);
|
||||||
}
|
}
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public ThemedCheckBoxPreference(Context context, AttributeSet attrs, int defStyle) {
|
public ThemedCheckBoxPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||||
super(context, attrs, defStyle);
|
super(context, attrs, defStyle);
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.graphics.PorterDuff;
|
import android.graphics.PorterDuff;
|
||||||
|
@ -9,7 +9,7 @@ import android.view.View;
|
||||||
import android.widget.ImageView;
|
import android.widget.ImageView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.Helpers;
|
import com.github.dfa.diaspora_android.util.Helpers;
|
||||||
|
|
||||||
/**
|
/**
|
|
@ -16,11 +16,10 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Fragment that supports color schemes
|
* Fragment that supports color schemes
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.preference.PreferenceCategory;
|
import android.preference.PreferenceCategory;
|
||||||
|
@ -7,8 +7,7 @@ import android.view.View;
|
||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.TextView;
|
import android.widget.TextView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* PreferenceCategory with a colored title
|
* PreferenceCategory with a colored title
|
||||||
|
@ -17,14 +16,17 @@ import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
||||||
|
|
||||||
public class ThemedPreferenceCategory extends PreferenceCategory implements Themeable {
|
public class ThemedPreferenceCategory extends PreferenceCategory implements Themeable {
|
||||||
protected TextView titleTextView;
|
protected TextView titleTextView;
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public ThemedPreferenceCategory(Context context) {
|
public ThemedPreferenceCategory(Context context) {
|
||||||
super(context);
|
super(context);
|
||||||
}
|
}
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public ThemedPreferenceCategory(Context context, AttributeSet attrs) {
|
public ThemedPreferenceCategory(Context context, AttributeSet attrs) {
|
||||||
super(context, attrs);
|
super(context, attrs);
|
||||||
}
|
}
|
||||||
|
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
public ThemedPreferenceCategory(Context context, AttributeSet attrs,
|
public ThemedPreferenceCategory(Context context, AttributeSet attrs,
|
||||||
int defStyle) {
|
int defStyle) {
|
||||||
|
@ -41,7 +43,7 @@ public class ThemedPreferenceCategory extends PreferenceCategory implements Them
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setColors() {
|
public void setColors() {
|
||||||
if(titleTextView != null) {
|
if (titleTextView != null) {
|
||||||
ThemeHelper.getInstance(new AppSettings(getContext()));
|
ThemeHelper.getInstance(new AppSettings(getContext()));
|
||||||
ThemeHelper.updateTextViewTextColor(titleTextView);
|
ThemeHelper.updateTextViewTextColor(titleTextView);
|
||||||
}
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.os.Build;
|
import android.os.Build;
|
||||||
import android.preference.Preference;
|
import android.preference.Preference;
|
||||||
|
@ -7,8 +7,7 @@ import android.preference.PreferenceScreen;
|
||||||
import android.view.Window;
|
import android.view.Window;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by vanitas on 24.10.16.
|
* Created by vanitas on 24.10.16.
|
||||||
|
@ -16,6 +15,7 @@ import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
||||||
|
|
||||||
public abstract class ThemedPreferenceFragment extends PreferenceFragment {
|
public abstract class ThemedPreferenceFragment extends PreferenceFragment {
|
||||||
public abstract void updateViewColors();
|
public abstract void updateViewColors();
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onResume() {
|
public void onResume() {
|
||||||
super.onResume();
|
super.onResume();
|
||||||
|
@ -24,7 +24,7 @@ public abstract class ThemedPreferenceFragment extends PreferenceFragment {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
||||||
if(isAdded()) {
|
if (isAdded()) {
|
||||||
App app = ((App) getActivity().getApplication());
|
App app = ((App) getActivity().getApplication());
|
||||||
AppSettings appSettings = app.getSettings();
|
AppSettings appSettings = app.getSettings();
|
||||||
if (Build.VERSION.SDK_INT >= 21) {
|
if (Build.VERSION.SDK_INT >= 21) {
|
|
@ -1,12 +1,11 @@
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.ui.theme;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.util.AttributeSet;
|
import android.util.AttributeSet;
|
||||||
import android.widget.CheckBox;
|
import android.widget.CheckBox;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ThemedCheckBoxPreference with visibility icons instead of checkbox. TODO: Make more flexible?
|
* ThemedCheckBoxPreference with visibility icons instead of checkbox. TODO: Make more flexible?
|
|
@ -18,6 +18,12 @@
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.util;
|
package com.github.dfa.diaspora_android.util;
|
||||||
|
|
||||||
|
import java.text.SimpleDateFormat;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.Observable;
|
||||||
|
import java.util.Observer;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by gregor on 18.09.16.
|
* Created by gregor on 18.09.16.
|
||||||
*/
|
*/
|
||||||
|
@ -86,4 +92,126 @@ public class AppLog {
|
||||||
Log.v(getLogPrefix(source), _text);
|
Log.v(getLogPrefix(source), _text);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Class that saves logs eg. for later debugging.
|
||||||
|
* TODO: Differentiate log types (error/debug/info...)
|
||||||
|
*/
|
||||||
|
public static class Log extends Observable {
|
||||||
|
public static final int MAX_BUFFER_SIZE = 100;
|
||||||
|
|
||||||
|
public static Log instance;
|
||||||
|
private AppSettings appSettings;
|
||||||
|
private SimpleDateFormat dateFormat;
|
||||||
|
private ArrayList<String> logBuffer;
|
||||||
|
private ArrayList<Observer> observers;
|
||||||
|
|
||||||
|
private Log() {
|
||||||
|
this(null);
|
||||||
|
}
|
||||||
|
|
||||||
|
private Log(AppSettings appSettings) {
|
||||||
|
if (appSettings != null) {
|
||||||
|
//TODO: Store/Restore logBuffer between app starts
|
||||||
|
logBuffer = new ArrayList<>();
|
||||||
|
} else {
|
||||||
|
logBuffer = new ArrayList<>();
|
||||||
|
}
|
||||||
|
dateFormat = new SimpleDateFormat("HH:mm:ss");
|
||||||
|
observers = new ArrayList<>();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Log getInstance() {
|
||||||
|
if (instance == null) instance = new Log();
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Log getInstance(AppSettings appSettings) {
|
||||||
|
if (instance == null) instance = new Log(appSettings);
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String time() {
|
||||||
|
return getInstance().dateFormat.format(new Date()) + ": ";
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void d(String tag, String msg) {
|
||||||
|
Log l = getInstance();
|
||||||
|
android.util.Log.d(tag, msg);
|
||||||
|
l.addLogEntry(msg);
|
||||||
|
l.notifyLogBufferChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void e(String tag, String msg) {
|
||||||
|
Log l = getInstance();
|
||||||
|
android.util.Log.e(tag, msg);
|
||||||
|
l.addLogEntry(msg);
|
||||||
|
l.notifyLogBufferChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void i(String tag, String msg) {
|
||||||
|
Log l = getInstance();
|
||||||
|
android.util.Log.i(tag, msg);
|
||||||
|
l.addLogEntry(msg);
|
||||||
|
l.notifyLogBufferChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void v(String tag, String msg) {
|
||||||
|
Log l = getInstance();
|
||||||
|
android.util.Log.v(tag, msg);
|
||||||
|
l.addLogEntry(msg);
|
||||||
|
l.notifyLogBufferChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void w(String tag, String msg) {
|
||||||
|
Log l = getInstance();
|
||||||
|
android.util.Log.w(tag, msg);
|
||||||
|
l.addLogEntry(msg);
|
||||||
|
l.notifyLogBufferChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void wtf(String tag, String msg) {
|
||||||
|
Log l = getInstance();
|
||||||
|
android.util.Log.wtf(tag, msg);
|
||||||
|
l.addLogEntry(msg);
|
||||||
|
l.notifyLogBufferChanged();
|
||||||
|
}
|
||||||
|
|
||||||
|
public synchronized static ArrayList<String> getLogBufferArray() {
|
||||||
|
return getInstance().logBuffer;
|
||||||
|
}
|
||||||
|
|
||||||
|
public synchronized static String getLogBuffer() {
|
||||||
|
String out = "";
|
||||||
|
for (String s : getInstance().logBuffer) {
|
||||||
|
out = out + s + "\n";
|
||||||
|
}
|
||||||
|
return out;
|
||||||
|
}
|
||||||
|
|
||||||
|
private void notifyLogBufferChanged() {
|
||||||
|
if (observers == null) return;
|
||||||
|
for (Observer o : observers) {
|
||||||
|
if (o != null) {
|
||||||
|
o.update(this, null);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private synchronized void addLogEntry(String msg) {
|
||||||
|
logBuffer.add(time() + msg);
|
||||||
|
while (logBuffer.size() > MAX_BUFFER_SIZE) {
|
||||||
|
logBuffer.remove(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void addLogObserver(Observer observer) {
|
||||||
|
getInstance().observers.add(observer);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void removeLogObserver(Observer o) {
|
||||||
|
getInstance().observers.remove(o);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
along with the Diaspora for Android.
|
along with the Diaspora for Android.
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.data;
|
package com.github.dfa.diaspora_android.util;
|
||||||
|
|
||||||
import android.annotation.SuppressLint;
|
import android.annotation.SuppressLint;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
|
@ -21,7 +21,8 @@ import android.content.SharedPreferences;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod.DiasporaPodUrl;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod.DiasporaPodUrl;
|
||||||
import com.github.dfa.diaspora_android.util.ProxyHandler;
|
import com.github.dfa.diaspora_android.data.DiasporaAspect;
|
||||||
|
import com.github.dfa.diaspora_android.web.ProxyHandler;
|
||||||
|
|
||||||
import org.json.JSONException;
|
import org.json.JSONException;
|
||||||
import org.json.JSONObject;
|
import org.json.JSONObject;
|
||||||
|
@ -56,11 +57,11 @@ public class AppSettings {
|
||||||
prefApp.edit().clear().apply();
|
prefApp.edit().clear().apply();
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getKey(int stringKeyRessourceId){
|
public String getKey(int stringKeyRessourceId) {
|
||||||
return context.getString(stringKeyRessourceId);
|
return context.getString(stringKeyRessourceId);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean isKeyEqual(String key, int stringKeyRessourceId){
|
public boolean isKeyEqual(String key, int stringKeyRessourceId) {
|
||||||
return key.equals(getKey(stringKeyRessourceId));
|
return key.equals(getKey(stringKeyRessourceId));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -195,15 +196,15 @@ public class AppSettings {
|
||||||
return !getString(prefPod, R.string.pref_key__current_pod_0, "").equals("");
|
return !getString(prefPod, R.string.pref_key__current_pod_0, "").equals("");
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setPodAspects(PodAspect[] aspects) {
|
public void setPodAspects(DiasporaAspect[] aspects) {
|
||||||
setStringArray(prefPod, R.string.pref_key__podprofile_aspects, aspects);
|
setStringArray(prefPod, R.string.pref_key__podprofile_aspects, aspects);
|
||||||
}
|
}
|
||||||
|
|
||||||
public PodAspect[] getAspects() {
|
public DiasporaAspect[] getAspects() {
|
||||||
String[] s = getStringArray(prefPod, R.string.pref_key__podprofile_aspects);
|
String[] s = getStringArray(prefPod, R.string.pref_key__podprofile_aspects);
|
||||||
PodAspect[] aspects = new PodAspect[s.length];
|
DiasporaAspect[] aspects = new DiasporaAspect[s.length];
|
||||||
for (int i = 0; i < aspects.length; i++) {
|
for (int i = 0; i < aspects.length; i++) {
|
||||||
aspects[i] = new PodAspect(s[i]);
|
aspects[i] = new DiasporaAspect(s[i]);
|
||||||
}
|
}
|
||||||
return aspects;
|
return aspects;
|
||||||
}
|
}
|
|
@ -20,9 +20,8 @@ package com.github.dfa.diaspora_android.util;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
import com.github.dfa.diaspora_android.data.DiasporaPodList.DiasporaPod;
|
||||||
import com.github.dfa.diaspora_android.data.PodAspect;
|
import com.github.dfa.diaspora_android.data.DiasporaAspect;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Helper class that provides easy access to specific urls related to diaspora
|
* Helper class that provides easy access to specific urls related to diaspora
|
||||||
|
@ -315,7 +314,7 @@ public class DiasporaUrlHelper {
|
||||||
url = url.replace(getPodUrl() + "/aspects?a_ids[]=", "").split(",")[0];
|
url = url.replace(getPodUrl() + "/aspects?a_ids[]=", "").split(",")[0];
|
||||||
try {
|
try {
|
||||||
int id = Integer.parseInt(url);
|
int id = Integer.parseInt(url);
|
||||||
for (PodAspect aspect : app.getPodUserProfile().getAspects()) {
|
for (DiasporaAspect aspect : app.getDiasporaUserProfile().getAspects()) {
|
||||||
if (aspect.id == id) {
|
if (aspect.id == id) {
|
||||||
return aspect.name;
|
return aspect.name;
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,6 +30,7 @@ import android.support.design.widget.Snackbar;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
|
import com.github.dfa.diaspora_android.web.WebHelper;
|
||||||
|
|
||||||
import java.io.BufferedReader;
|
import java.io.BufferedReader;
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
|
|
@ -1,149 +0,0 @@
|
||||||
/*
|
|
||||||
This file is part of the Diaspora for Android.
|
|
||||||
|
|
||||||
Diaspora for Android is free software: you can redistribute it and/or modify
|
|
||||||
it under the terms of the GNU General Public License as published by
|
|
||||||
the Free Software Foundation, either version 3 of the License, or
|
|
||||||
(at your option) any later version.
|
|
||||||
|
|
||||||
Diaspora for Android is distributed in the hope that it will be useful,
|
|
||||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
GNU General Public License for more details.
|
|
||||||
|
|
||||||
You should have received a copy of the GNU General Public License
|
|
||||||
along with the Diaspora for Android.
|
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
|
||||||
*/
|
|
||||||
package com.github.dfa.diaspora_android.util;
|
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
|
||||||
|
|
||||||
import java.text.SimpleDateFormat;
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.Date;
|
|
||||||
import java.util.Observable;
|
|
||||||
import java.util.Observer;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Class that saves logs eg. for later debugging.
|
|
||||||
* TODO: Differentiate log types (error/debug/info...)
|
|
||||||
* Created by vanitas on 09.09.16.
|
|
||||||
*/
|
|
||||||
public class Log extends Observable {
|
|
||||||
public static final int MAX_BUFFER_SIZE = 100;
|
|
||||||
|
|
||||||
public static Log instance;
|
|
||||||
private AppSettings appSettings;
|
|
||||||
private SimpleDateFormat dateFormat;
|
|
||||||
private ArrayList<String> logBuffer;
|
|
||||||
private ArrayList<Observer> observers;
|
|
||||||
|
|
||||||
private Log() {
|
|
||||||
this(null);
|
|
||||||
}
|
|
||||||
|
|
||||||
private Log(AppSettings appSettings) {
|
|
||||||
if (appSettings != null) {
|
|
||||||
//TODO: Store/Restore logBuffer between app starts
|
|
||||||
logBuffer = new ArrayList<>();
|
|
||||||
} else {
|
|
||||||
logBuffer = new ArrayList<>();
|
|
||||||
}
|
|
||||||
dateFormat = new SimpleDateFormat("HH:mm:ss");
|
|
||||||
observers = new ArrayList<>();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Log getInstance() {
|
|
||||||
if (instance == null) instance = new Log();
|
|
||||||
return instance;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static Log getInstance(AppSettings appSettings) {
|
|
||||||
if (instance == null) instance = new Log(appSettings);
|
|
||||||
return instance;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static String time() {
|
|
||||||
return getInstance().dateFormat.format(new Date()) + ": ";
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void d(String tag, String msg) {
|
|
||||||
Log l = getInstance();
|
|
||||||
android.util.Log.d(tag, msg);
|
|
||||||
l.addLogEntry(msg);
|
|
||||||
l.notifyLogBufferChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void e(String tag, String msg) {
|
|
||||||
Log l = getInstance();
|
|
||||||
android.util.Log.e(tag, msg);
|
|
||||||
l.addLogEntry(msg);
|
|
||||||
l.notifyLogBufferChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void i(String tag, String msg) {
|
|
||||||
Log l = getInstance();
|
|
||||||
android.util.Log.i(tag, msg);
|
|
||||||
l.addLogEntry(msg);
|
|
||||||
l.notifyLogBufferChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void v(String tag, String msg) {
|
|
||||||
Log l = getInstance();
|
|
||||||
android.util.Log.v(tag, msg);
|
|
||||||
l.addLogEntry(msg);
|
|
||||||
l.notifyLogBufferChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void w(String tag, String msg) {
|
|
||||||
Log l = getInstance();
|
|
||||||
android.util.Log.w(tag, msg);
|
|
||||||
l.addLogEntry(msg);
|
|
||||||
l.notifyLogBufferChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void wtf(String tag, String msg) {
|
|
||||||
Log l = getInstance();
|
|
||||||
android.util.Log.wtf(tag, msg);
|
|
||||||
l.addLogEntry(msg);
|
|
||||||
l.notifyLogBufferChanged();
|
|
||||||
}
|
|
||||||
|
|
||||||
public synchronized static ArrayList<String> getLogBufferArray() {
|
|
||||||
return getInstance().logBuffer;
|
|
||||||
}
|
|
||||||
|
|
||||||
public synchronized static String getLogBuffer() {
|
|
||||||
String out = "";
|
|
||||||
for (String s : getInstance().logBuffer) {
|
|
||||||
out = out + s + "\n";
|
|
||||||
}
|
|
||||||
return out;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void notifyLogBufferChanged() {
|
|
||||||
if (observers == null) return;
|
|
||||||
for (Observer o : observers) {
|
|
||||||
if (o != null) {
|
|
||||||
o.update(this, null);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private synchronized void addLogEntry(String msg) {
|
|
||||||
logBuffer.add(time() + msg);
|
|
||||||
while (logBuffer.size() > MAX_BUFFER_SIZE) {
|
|
||||||
logBuffer.remove(0);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void addLogObserver(Observer observer) {
|
|
||||||
getInstance().observers.add(observer);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void removeLogObserver(Observer o) {
|
|
||||||
getInstance().observers.remove(o);
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.fragment;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.Manifest;
|
import android.Manifest;
|
||||||
import android.content.DialogInterface;
|
import android.content.DialogInterface;
|
||||||
|
@ -40,13 +40,10 @@ import android.widget.ProgressBar;
|
||||||
import com.github.dfa.diaspora_android.App;
|
import com.github.dfa.diaspora_android.App;
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.activity.MainActivity;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.ui.theme.ThemeHelper;
|
||||||
import com.github.dfa.diaspora_android.ui.ContextMenuWebView;
|
import com.github.dfa.diaspora_android.ui.theme.ThemedFragment;
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.ProxyHandler;
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
import com.github.dfa.diaspora_android.util.theming.ThemeHelper;
|
|
||||||
import com.github.dfa.diaspora_android.webview.CustomWebViewClient;
|
|
||||||
import com.github.dfa.diaspora_android.webview.ProgressBarWebChromeClient;
|
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.FileOutputStream;
|
import java.io.FileOutputStream;
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.Manifest;
|
import android.Manifest;
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
|
@ -39,7 +39,7 @@ import android.widget.Toast;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.R;
|
import com.github.dfa.diaspora_android.R;
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.activity.MainActivity;
|
||||||
import com.github.dfa.diaspora_android.task.ImageDownloadTask;
|
import com.github.dfa.diaspora_android.service.ImageDownloadTask;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.webview;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
||||||
import android.support.v4.content.LocalBroadcastManager;
|
import android.support.v4.content.LocalBroadcastManager;
|
|
@ -16,13 +16,12 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.webview;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.webkit.WebView;
|
import android.webkit.WebView;
|
||||||
import android.widget.ProgressBar;
|
import android.widget.ProgressBar;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.util.AppLog;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
import com.github.dfa.diaspora_android.util.WebHelper;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Created by vanitas on 26.09.16.
|
* Created by vanitas on 26.09.16.
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.webview;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.net.Uri;
|
import android.net.Uri;
|
||||||
import android.webkit.ValueCallback;
|
import android.webkit.ValueCallback;
|
|
@ -14,7 +14,7 @@
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package com.github.dfa.diaspora_android.ui;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.support.v4.view.MotionEventCompat;
|
import android.support.v4.view.MotionEventCompat;
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.webview;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
import android.webkit.WebChromeClient;
|
import android.webkit.WebChromeClient;
|
|
@ -16,14 +16,15 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.util;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.os.StrictMode;
|
import android.os.StrictMode;
|
||||||
import android.webkit.WebView;
|
import android.webkit.WebView;
|
||||||
|
|
||||||
import com.github.dfa.diaspora_android.activity.MainActivity;
|
import com.github.dfa.diaspora_android.activity.MainActivity;
|
||||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
import com.github.dfa.diaspora_android.util.AppLog;
|
||||||
|
import com.github.dfa.diaspora_android.util.AppSettings;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package com.github.dfa.diaspora_android.util;
|
package com.github.dfa.diaspora_android.web;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.net.ConnectivityManager;
|
import android.net.ConnectivityManager;
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.util.CustomTabHelpers;
|
package com.github.dfa.diaspora_android.web.custom_tab;
|
||||||
|
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.util.CustomTabHelpers;
|
package com.github.dfa.diaspora_android.web.custom_tab;
|
||||||
|
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
import android.content.ComponentName;
|
import android.content.ComponentName;
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
If not, see <http://www.gnu.org/licenses/>.
|
If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
package com.github.dfa.diaspora_android.util.CustomTabHelpers;
|
package com.github.dfa.diaspora_android.web.custom_tab;
|
||||||
|
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
import android.content.Intent;
|
import android.content.Intent;
|
Before Width: | Height: | Size: 3.3 KiB After Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 929 B |
Before Width: | Height: | Size: 4.5 KiB After Width: | Height: | Size: 2 KiB |
Before Width: | Height: | Size: 7 KiB After Width: | Height: | Size: 3.2 KiB |
Before Width: | Height: | Size: 9.4 KiB After Width: | Height: | Size: 4.4 KiB |
|
@ -3,7 +3,7 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent">
|
android:layout_height="match_parent">
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ContextMenuWebView
|
<com.github.dfa.diaspora_android.web.ContextMenuWebView
|
||||||
android:id="@+id/webView"
|
android:id="@+id/webView"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent" />
|
android:layout_height="match_parent" />
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:id="@+id/recycler_view__list_item__root"
|
android:id="@+id/recycler_view__list_item__root"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
|
@ -7,32 +7,31 @@
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_search"
|
android:id="@+id/action_search"
|
||||||
android:icon="@drawable/ic_search_white_48px"
|
android:icon="@drawable/ic_search_white_48px"
|
||||||
app:showAsAction="always"
|
|
||||||
android:orderInCategory="100"
|
android:orderInCategory="100"
|
||||||
android:title="@string/action_search_by_tags_or_persons" />
|
android:title="@string/action_search_by_tags_or_persons"
|
||||||
|
app:showAsAction="always" />
|
||||||
|
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_compose"
|
android:id="@+id/action_compose"
|
||||||
android:icon="@drawable/ic_mode_edit_white_48px"
|
android:icon="@drawable/ic_mode_edit_white_48px"
|
||||||
app:showAsAction="always"
|
|
||||||
android:orderInCategory="200"
|
android:orderInCategory="200"
|
||||||
android:title="@string/action_compose_new_post" />
|
android:title="@string/action_compose_new_post"
|
||||||
|
app:showAsAction="always" />
|
||||||
|
|
||||||
<!-- Keep right most -->
|
<!-- Keep right most -->
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_go_to_top"
|
android:id="@+id/action_go_to_top"
|
||||||
android:icon="@drawable/ic_arrow_upward_white_48px"
|
android:icon="@drawable/ic_arrow_upward_white_48px"
|
||||||
app:showAsAction="always"
|
|
||||||
android:orderInCategory="400"
|
android:orderInCategory="400"
|
||||||
android:title="@string/action_go_to_top" />
|
android:title="@string/action_go_to_top"
|
||||||
|
app:showAsAction="always" />
|
||||||
|
|
||||||
<!-- overflow menu -->
|
<!-- overflow menu -->
|
||||||
|
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_exit"
|
android:id="@+id/action_exit"
|
||||||
app:showAsAction="never"
|
|
||||||
android:orderInCategory="600"
|
android:orderInCategory="600"
|
||||||
android:title="@string/action_exit_app"
|
android:title="@string/action_exit_app"
|
||||||
/>
|
app:showAsAction="never" />
|
||||||
|
|
||||||
</menu>
|
</menu>
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
android:icon="@drawable/ic_notifications_white_48px__layer"
|
android:icon="@drawable/ic_notifications_white_48px__layer"
|
||||||
android:orderInCategory="100"
|
android:orderInCategory="100"
|
||||||
android:title="@string/notifications"
|
android:title="@string/notifications"
|
||||||
app:showAsAction="always"/>
|
app:showAsAction="always" />
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_conversations"
|
android:id="@+id/action_conversations"
|
||||||
android:icon="@drawable/ic_mail_white_48px__layer"
|
android:icon="@drawable/ic_mail_white_48px__layer"
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
<group android:checkableBehavior="none" android:id="@+id/nav_group__pod">
|
<group
|
||||||
|
android:id="@+id/nav_group__pod"
|
||||||
|
android:checkableBehavior="none">
|
||||||
<item
|
<item
|
||||||
android:id="@+id/nav_stream"
|
android:id="@+id/nav_stream"
|
||||||
android:icon="@drawable/ic_stream"
|
android:icon="@drawable/ic_stream"
|
||||||
|
@ -55,7 +57,7 @@
|
||||||
android:id="@+id/nav_exit"
|
android:id="@+id/nav_exit"
|
||||||
android:icon="@drawable/ic_cancel_black_48px"
|
android:icon="@drawable/ic_cancel_black_48px"
|
||||||
android:title="@string/action_exit_app"
|
android:title="@string/action_exit_app"
|
||||||
android:visible="false"/>
|
android:visible="false" />
|
||||||
</group>
|
</group>
|
||||||
|
|
||||||
<item android:title="@string/nav_menu_more">
|
<item android:title="@string/nav_menu_more">
|
||||||
|
|
|
@ -4,13 +4,19 @@
|
||||||
|
|
||||||
<item
|
<item
|
||||||
android:icon="@drawable/ic_share_white_48px"
|
android:icon="@drawable/ic_share_white_48px"
|
||||||
app:showAsAction="always"
|
|
||||||
android:orderInCategory="300"
|
android:orderInCategory="300"
|
||||||
android:title="@string/action_share_dotdotdot">
|
android:title="@string/action_share_dotdotdot"
|
||||||
|
app:showAsAction="always">
|
||||||
<menu>
|
<menu>
|
||||||
<item android:id="@+id/action_share_screenshot" android:title="@string/share__share_screenshot"/>
|
<item
|
||||||
<item android:id="@+id/action_take_screenshot" android:title="@string/share__take_screenshot"/>
|
android:id="@+id/action_share_screenshot"
|
||||||
<item android:id="@+id/action_share_link" android:title="@string/share__share_link_as_text"/>
|
android:title="@string/share__share_screenshot" />
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_take_screenshot"
|
||||||
|
android:title="@string/share__take_screenshot" />
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_share_link"
|
||||||
|
android:title="@string/share__share_link_as_text" />
|
||||||
</menu>
|
</menu>
|
||||||
</item>
|
</item>
|
||||||
|
|
||||||
|
|
|
@ -5,8 +5,8 @@
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_reload"
|
android:id="@+id/action_reload"
|
||||||
android:icon="@drawable/ic_refresh_white_48px"
|
android:icon="@drawable/ic_refresh_white_48px"
|
||||||
app:showAsAction="always"
|
|
||||||
android:orderInCategory="1000"
|
android:orderInCategory="1000"
|
||||||
android:title="@string/reload"/>
|
android:title="@string/reload"
|
||||||
|
app:showAsAction="always" />
|
||||||
|
|
||||||
</menu>
|
</menu>
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"pods": [
|
"pods": [
|
||||||
{
|
{
|
||||||
"active6": 12442,
|
"active6": 12476,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [
|
"podUrls": [
|
||||||
{"host": "joindiaspora.com"},
|
{"host": "joindiaspora.com"},
|
||||||
|
@ -16,7 +16,7 @@
|
||||||
"id": 38077
|
"id": 38077
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 7170,
|
"active6": 7155,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "pod.geraspora.de"}],
|
"podUrls": [{"host": "pod.geraspora.de"}],
|
||||||
"name": "Geraspora",
|
"name": "Geraspora",
|
||||||
|
@ -24,7 +24,7 @@
|
||||||
"id": 24783
|
"id": 24783
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 3726,
|
"active6": 3723,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diasp.org"}],
|
"podUrls": [{"host": "diasp.org"}],
|
||||||
"name": "diasporg*",
|
"name": "diasporg*",
|
||||||
|
@ -32,7 +32,7 @@
|
||||||
"id": 12688
|
"id": 12688
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 10298,
|
"active6": 10321,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "framasphere.org"}],
|
"podUrls": [{"host": "framasphere.org"}],
|
||||||
"name": "Framasphere",
|
"name": "Framasphere",
|
||||||
|
@ -48,7 +48,7 @@
|
||||||
"id": 17343
|
"id": 17343
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 853,
|
"active6": 854,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "despora.de"}],
|
"podUrls": [{"host": "despora.de"}],
|
||||||
"name": "Despora*",
|
"name": "Despora*",
|
||||||
|
@ -95,7 +95,7 @@
|
||||||
"id": 38327
|
"id": 38327
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 47,
|
"active6": 48,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "canfly.org"}],
|
"podUrls": [{"host": "canfly.org"}],
|
||||||
"name": "canfly.org",
|
"name": "canfly.org",
|
||||||
|
@ -119,7 +119,7 @@
|
||||||
"id": 46568
|
"id": 46568
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 72,
|
"active6": 73,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "d.consumium.org"}],
|
"podUrls": [{"host": "d.consumium.org"}],
|
||||||
"name": "d.consumium.org",
|
"name": "d.consumium.org",
|
||||||
|
@ -199,7 +199,7 @@
|
||||||
"id": 4343
|
"id": 4343
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 196,
|
"active6": 179,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diasp.nl"}],
|
"podUrls": [{"host": "diasp.nl"}],
|
||||||
"name": "diasp.nl",
|
"name": "diasp.nl",
|
||||||
|
@ -207,7 +207,7 @@
|
||||||
"id": 33262
|
"id": 33262
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 185,
|
"active6": 177,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diaspod.de"}],
|
"podUrls": [{"host": "diaspod.de"}],
|
||||||
"name": "diaspod.de",
|
"name": "diaspod.de",
|
||||||
|
@ -375,7 +375,7 @@
|
||||||
"id": 9863
|
"id": 9863
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 257,
|
"active6": 256,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diaspora.permutationsofchaos.com"}],
|
"podUrls": [{"host": "diaspora.permutationsofchaos.com"}],
|
||||||
"name": "permutationsofchaos.com",
|
"name": "permutationsofchaos.com",
|
||||||
|
@ -479,7 +479,7 @@
|
||||||
"id": 39183
|
"id": 39183
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 36,
|
"active6": 37,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diaspora.subsignal.org"}],
|
"podUrls": [{"host": "diaspora.subsignal.org"}],
|
||||||
"name": "subsignal.org",
|
"name": "subsignal.org",
|
||||||
|
@ -495,7 +495,7 @@
|
||||||
"id": 46672
|
"id": 46672
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 35,
|
"active6": 37,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diaspora.u4u.org"}],
|
"podUrls": [{"host": "diaspora.u4u.org"}],
|
||||||
"name": "u4u.org",
|
"name": "u4u.org",
|
||||||
|
@ -535,7 +535,7 @@
|
||||||
"id": 27412
|
"id": 27412
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 1169,
|
"active6": 1168,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diasporabr.com.br"}],
|
"podUrls": [{"host": "diasporabr.com.br"}],
|
||||||
"name": "diasporabr.com.br",
|
"name": "diasporabr.com.br",
|
||||||
|
@ -543,7 +543,7 @@
|
||||||
"id": 18248
|
"id": 18248
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 365,
|
"active6": 364,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diasporabrazil.org"}],
|
"podUrls": [{"host": "diasporabrazil.org"}],
|
||||||
"name": "diasporabrazil.org",
|
"name": "diasporabrazil.org",
|
||||||
|
@ -559,8 +559,8 @@
|
||||||
"id": 27962
|
"id": 27962
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 0,
|
"active6": 7,
|
||||||
"score": 0,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diasporapr.tk"}],
|
"podUrls": [{"host": "diasporapr.tk"}],
|
||||||
"name": "diasporapr.tk",
|
"name": "diasporapr.tk",
|
||||||
"mainLangs": [],
|
"mainLangs": [],
|
||||||
|
@ -575,7 +575,7 @@
|
||||||
"id": 46740
|
"id": 46740
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 29,
|
"active6": 30,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diasporing.ch"}],
|
"podUrls": [{"host": "diasporing.ch"}],
|
||||||
"name": "Diasporing.ch",
|
"name": "Diasporing.ch",
|
||||||
|
@ -639,7 +639,7 @@
|
||||||
"id": 41690
|
"id": 41690
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 168,
|
"active6": 169,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "flokk.no"}],
|
"podUrls": [{"host": "flokk.no"}],
|
||||||
"name": "flokk.no",
|
"name": "flokk.no",
|
||||||
|
@ -671,7 +671,7 @@
|
||||||
"id": 13758
|
"id": 13758
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 73,
|
"active6": 72,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "idoru.pl"}],
|
"podUrls": [{"host": "idoru.pl"}],
|
||||||
"name": "idoru.pl",
|
"name": "idoru.pl",
|
||||||
|
@ -727,7 +727,7 @@
|
||||||
"id": 32393
|
"id": 32393
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 140,
|
"active6": 139,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "liberdade.digital"}],
|
"podUrls": [{"host": "liberdade.digital"}],
|
||||||
"name": "liberdade.digital",
|
"name": "liberdade.digital",
|
||||||
|
@ -775,7 +775,7 @@
|
||||||
"id": 16366
|
"id": 16366
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 616,
|
"active6": 614,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "mondiaspora.net"}],
|
"podUrls": [{"host": "mondiaspora.net"}],
|
||||||
"name": "mondiaspora.net",
|
"name": "mondiaspora.net",
|
||||||
|
@ -959,7 +959,7 @@
|
||||||
"id": 36615
|
"id": 36615
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 57,
|
"active6": 56,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "pod.hashtagueule.fr"}],
|
"podUrls": [{"host": "pod.hashtagueule.fr"}],
|
||||||
"name": "hashtagueule.fr",
|
"name": "hashtagueule.fr",
|
||||||
|
@ -1031,7 +1031,7 @@
|
||||||
"id": 9248
|
"id": 9248
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 98,
|
"active6": 99,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "pod.nomorestars.com"}],
|
"podUrls": [{"host": "pod.nomorestars.com"}],
|
||||||
"name": "nomorestars.com",
|
"name": "nomorestars.com",
|
||||||
|
@ -1039,7 +1039,7 @@
|
||||||
"id": 31958
|
"id": 31958
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 404,
|
"active6": 405,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "pod.orkz.net"}],
|
"podUrls": [{"host": "pod.orkz.net"}],
|
||||||
"name": "orkz.net",
|
"name": "orkz.net",
|
||||||
|
@ -1048,7 +1048,7 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 37,
|
"active6": 37,
|
||||||
"score": 20,
|
"score": -1,
|
||||||
"podUrls": [{"host": "pod.ponk.pink"}],
|
"podUrls": [{"host": "pod.ponk.pink"}],
|
||||||
"name": "ponk.pink",
|
"name": "ponk.pink",
|
||||||
"mainLangs": [],
|
"mainLangs": [],
|
||||||
|
@ -1063,8 +1063,8 @@
|
||||||
"id": 21338
|
"id": 21338
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 86,
|
"active6": 85,
|
||||||
"score": 20,
|
"score": 11,
|
||||||
"podUrls": [{"host": "pod.psynet.su"}],
|
"podUrls": [{"host": "pod.psynet.su"}],
|
||||||
"name": "psynet.su",
|
"name": "psynet.su",
|
||||||
"mainLangs": [],
|
"mainLangs": [],
|
||||||
|
@ -1135,7 +1135,7 @@
|
||||||
"id": 33181
|
"id": 33181
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 73,
|
"active6": 74,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "pod.tchncs.de"}],
|
"podUrls": [{"host": "pod.tchncs.de"}],
|
||||||
"name": "tchncs.de",
|
"name": "tchncs.de",
|
||||||
|
@ -1175,7 +1175,7 @@
|
||||||
"id": 16270
|
"id": 16270
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 386,
|
"active6": 392,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "poddery.com"}],
|
"podUrls": [{"host": "poddery.com"}],
|
||||||
"name": "poddery.com",
|
"name": "poddery.com",
|
||||||
|
@ -1215,7 +1215,7 @@
|
||||||
"id": 41788
|
"id": 41788
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 100,
|
"active6": 101,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "ruhrspora.de"}],
|
"podUrls": [{"host": "ruhrspora.de"}],
|
||||||
"name": "ruhrspora.de",
|
"name": "ruhrspora.de",
|
||||||
|
@ -1263,7 +1263,7 @@
|
||||||
"id": 37517
|
"id": 37517
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 84,
|
"active6": 85,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "social.elaon.de"}],
|
"podUrls": [{"host": "social.elaon.de"}],
|
||||||
"name": "elaon.de",
|
"name": "elaon.de",
|
||||||
|
@ -1319,7 +1319,7 @@
|
||||||
"id": 29359
|
"id": 29359
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 39,
|
"active6": 37,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "sysad.org"}],
|
"podUrls": [{"host": "sysad.org"}],
|
||||||
"name": "sysad.org",
|
"name": "sysad.org",
|
||||||
|
@ -1335,7 +1335,7 @@
|
||||||
"id": 5276
|
"id": 5276
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 3982,
|
"active6": 3964,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "therealtalk.org"}],
|
"podUrls": [{"host": "therealtalk.org"}],
|
||||||
"name": "therealtalk.org",
|
"name": "therealtalk.org",
|
||||||
|
@ -1439,7 +1439,7 @@
|
||||||
"id": 33317
|
"id": 33317
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 11,
|
"active6": 14,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "diaspora.zone"}],
|
"podUrls": [{"host": "diaspora.zone"}],
|
||||||
"name": "zone",
|
"name": "zone",
|
||||||
|
@ -1447,7 +1447,7 @@
|
||||||
"id": 41976
|
"id": 41976
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"active6": 1,
|
"active6": 2,
|
||||||
"score": 20,
|
"score": 20,
|
||||||
"podUrls": [{"host": "pod.userzap.de"}],
|
"podUrls": [{"host": "pod.userzap.de"}],
|
||||||
"name": "userzap.de",
|
"name": "userzap.de",
|
||||||
|
@ -1455,5 +1455,5 @@
|
||||||
"id": 12816
|
"id": 12816
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"timestamp": 1477430185319
|
"timestamp": 1477491769316
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,45 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<string name="pref_cat__visuals">Vormgeving</string>
|
|
||||||
<string name="pref_cat__network">Netwerk</string>
|
|
||||||
<string name="pref_cat__pod_settings">Pod-instellingen</string>
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<string name="pref_title__sub_nav_slider">Navigatie Slider</string>
|
|
||||||
<string name="pref_cat__visibility_nav_items">Item Zichtbaarheid</string>
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<string name="pref_title__font_size">Lettergrootte</string>
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<string name="pref_title__load_images">Afbeeldingen laden</string>
|
|
||||||
<string name="pref_desc__load_images">Afbeelding laden uitschakelen om mobiele data te besparen</string>
|
|
||||||
<!-- Proxy -->
|
|
||||||
<string name="pref_title__proxy_enabled">Proxy inschakelen</string>
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<string name="pref_title__personal_settings">Persoonlijke instellingen</string>
|
|
||||||
<string name="pref_desc__manage_contacts">Uw lijst met contactpersonen beheren</string>
|
|
||||||
<string name="pref_title__manage_tags">Beheren van Hashtags</string>
|
|
||||||
<string name="pref_desc__manage_tags">Toevoegen en verwijderen van de hashtags die u volgt</string>
|
|
||||||
<string name="pref_title__change_account">Account wijzigen</string>
|
|
||||||
<string name="pref_desc__change_account">Lokale sessiegegevens wissen en schakel over naar een andere Diaspora pod/account</string>
|
|
||||||
<string name="pref_warning__change_account">Dit zal alle cookies en sessiegegevens wissen. Wilt u echt uw account wijzigen?</string>
|
|
||||||
<string name="pref_title__clear_cache">Cache wissen</string>
|
|
||||||
<string name="pref_desc__clear_cache">WebView-cache leegmaken</string>
|
|
||||||
<string name="pref_desc__intellihide_toolbars">Boven- en onderkant werkbalken automatisch verbergen tijdens het scrollen</string>
|
|
||||||
<string name="pref_title__intellihide_toolbars">Werkbalken slim wegwerken</string>
|
|
||||||
<string name="pref_title__append_shared_via_app">Gedeeld-via-aankondiging toevoegen</string>
|
|
||||||
<string name="pref_desc__append_shared_via_app">Een verwijzing naar dit app (\"gedeeld door…\") toevoegen aan gedeelde teksten</string>
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,64 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<string name="shared_by_diaspora_android">*[gedeeld door #DiasporaForAndroid]*</string>
|
|
||||||
<!-- Application -->
|
|
||||||
<string name="reload">Opnieuw Laden</string>
|
|
||||||
<string name="new_notifications">Ongelezen bericht. Wilt u het lezen?</string>
|
|
||||||
<!-- Common Words -->
|
|
||||||
<string name="settings">Instellingen</string>
|
|
||||||
<string name="notifications">Meldingen</string>
|
|
||||||
<string name="conversations">Gesprekken</string>
|
|
||||||
<string name="stream">Stream</string>
|
|
||||||
<string name="profile">Profiel</string>
|
|
||||||
<string name="aspects">Aspecten</string>
|
|
||||||
<string name="activities">Activiteiten</string>
|
|
||||||
<string name="liked">Leuk gevonden</string>
|
|
||||||
<string name="commented">Gereageerd</string>
|
|
||||||
<string name="mentions">Vermeldingen</string>
|
|
||||||
<string name="public_">Openbaar</string>
|
|
||||||
<string name="search">Zoeken</string>
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<string name="title_activity_pods">Selecteer Pod</string>
|
|
||||||
<string name="filter_hint">Voer pod domein</string>
|
|
||||||
<string name="confirm_url">Bevestigen pod url</string>
|
|
||||||
<string name="podlist_source_note">Opmerking: De podlijst is gevuld met beveiligde pods vermeld op https://podupti.me. U kunt in het bewerk veld elke pod invullen die niet in de lijst staat.</string>
|
|
||||||
<string name="valid_pod">Voer een geldige domeinnaam in</string>
|
|
||||||
<string name="podlist_error">Fout: Kan niet de podlijst ophalen!</string>
|
|
||||||
<string name="no_internet">Sorry, u moet verbinding met internet hebben om verder te gaan</string>
|
|
||||||
<string name="confirmation">Bevestiging</string>
|
|
||||||
<string name="confirm_pod">Wilt u echt \nhttps://%1$s\n als uw Diaspora pod gebruiken?</string>
|
|
||||||
<string name="confirm_exit">Wilt u afsluiten?</string>
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<string name="nav_followed_tags">Gevolgde Tags</string>
|
|
||||||
<string name="nav_public_activities">Publieke activiteiten</string>
|
|
||||||
<string name="share__share_link_as_text">Link delen als tekst</string>
|
|
||||||
<string name="share__share_screenshot">Screenshot van de webpagina delen</string>
|
|
||||||
<string name="share__take_screenshot">Neem screenshot van de webpagina</string>
|
|
||||||
<string name="share__toast_saved_image_to_location">Afbeelding opslaan</string>
|
|
||||||
<string name="share__toast_screenshot">Screenshot oplaan als:</string>
|
|
||||||
<string name="share__toast_link_address_copied">Link adres gekopieerd…</string>
|
|
||||||
<string name="new_post">Nieuw Bericht</string>
|
|
||||||
<string name="action_go_to_top">Terug naar boven</string>
|
|
||||||
<string name="action_search_by_tags_or_persons">Zoeken op tags of personen</string>
|
|
||||||
<string name="action_exit_app">App afsluiten</string>
|
|
||||||
<string name="action_toggle_desktop_page">Desktop weergave in-/uitschakelen</string>
|
|
||||||
<string name="action_share_dotdotdot">Delen…</string>
|
|
||||||
<string name="search_alert_tag">viaTags</string>
|
|
||||||
<string name="search_alert_people">via mensen</string>
|
|
||||||
<string name="search_alert_bypeople_validate_needsomedata">Voeg een naam toe</string>
|
|
||||||
<string name="context_menu_share_link">Deel adreslink</string>
|
|
||||||
<string name="context_menu_save_image">Afbeelding opslaan</string>
|
|
||||||
<string name="context_menu_share_image">Deel afbeelding</string>
|
|
||||||
<string name="context_menu_open_external_browser">Geopend in externe browser…</string>
|
|
||||||
<string name="context_menu_copy_link">Link-adres kopiëren naar Klembord</string>
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<string name="toast_set_proxy_failed">Waarschuwing: Kan niet netwerk proxy instellen…</string>
|
|
||||||
<string name="unable_to_load_image">Niet in staat om afbeelding te laden</string>
|
|
||||||
<string name="all_tags">Alle tags</string>
|
|
||||||
<!-- Permissions -->
|
|
||||||
<string name="permission_denied">Toestemming geweigerd.</string>
|
|
||||||
<string name="permission_granted_try_again">Toestemming verleend. Probeer het opnieuw.</string>
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -1,7 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- License & help (large amount of text) -->
|
|
||||||
<!-- About (large amount of text) -->
|
|
||||||
<!-- Lorem ipsum -->
|
|
||||||
</resources>
|
|
|
@ -1,23 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- Key Names (Untranslatable) -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- PodProfile -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Category Titles -->
|
|
||||||
<!-- Visuals -->
|
|
||||||
<!-- Navigiation Slider -->
|
|
||||||
<!-- Themes -->
|
|
||||||
<!-- Notifications dropdown -->
|
|
||||||
<!-- Font size -->
|
|
||||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
|
||||||
<!-- Load images -->
|
|
||||||
<!-- Proxy -->
|
|
||||||
<!-- Chrome custom tabs -->
|
|
||||||
<!-- Diaspora Settings -->
|
|
||||||
<!-- More -->
|
|
||||||
<!-- Recently added - Please move to right section-->
|
|
||||||
<!-- Sorry -->
|
|
||||||
</resources>
|
|
|
@ -1,12 +0,0 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<!--Generated by crowdin.com-->
|
|
||||||
<resources>
|
|
||||||
<!-- App - AppName specific -->
|
|
||||||
<!-- Application -->
|
|
||||||
<!-- Common Words -->
|
|
||||||
<!-- Notifications dropdown menu -->
|
|
||||||
<!-- Pod Activity -->
|
|
||||||
<!-- Drawer, Menu, Toolbar, ContextMenu -->
|
|
||||||
<!-- More from MainActivity -->
|
|
||||||
<!-- Permissions -->
|
|
||||||
</resources>
|
|
|
@ -17,9 +17,12 @@
|
||||||
|
|
||||||
<color name="white">#ffffff</color>
|
<color name="white">#ffffff</color>
|
||||||
<color name="black">#000000</color>
|
<color name="black">#000000</color>
|
||||||
|
<color name="actvitiy_white">#eeeeee</color>
|
||||||
|
<color name="transparent_black">#c4000000</color>
|
||||||
|
<color name="alternate_row_color">@color/md_grey_200</color>
|
||||||
|
|
||||||
<!-- Taken from org.horaapps.leafpic -->
|
<!-- Accent Color Collection
|
||||||
<!--Accent Color Collection-->
|
Taken from org.horaapps.leafpic -->
|
||||||
<color name="accent_red">#f44336</color>
|
<color name="accent_red">#f44336</color>
|
||||||
<color name="accent_pink">#e91e63</color>
|
<color name="accent_pink">#e91e63</color>
|
||||||
<color name="accent_purple">#9c27b0</color>
|
<color name="accent_purple">#9c27b0</color>
|
||||||
|
@ -37,7 +40,14 @@
|
||||||
<color name="accent_grey">#9e9e9e</color>
|
<color name="accent_grey">#9e9e9e</color>
|
||||||
<color name="accent_black">#000000</color>
|
<color name="accent_black">#000000</color>
|
||||||
|
|
||||||
<!--MATERIAL COLORS-->
|
<!--
|
||||||
|
███╗ ███╗ █████╗ ████████╗███████╗██████╗ ██╗ █████╗ ██╗
|
||||||
|
████╗ ████║██╔══██╗╚══██╔══╝██╔════╝██╔══██╗██║██╔══██╗██║
|
||||||
|
██╔████╔██║███████║ ██║ █████╗ ██████╔╝██║███████║██║
|
||||||
|
██║╚██╔╝██║██╔══██║ ██║ ██╔══╝ ██╔══██╗██║██╔══██║██║
|
||||||
|
██║ ╚═╝ ██║██║ ██║ ██║ ███████╗██║ ██║██║██║ ██║███████╗
|
||||||
|
╚═╝ ╚═╝╚═╝ ╚═╝ ╚═╝ ╚══════╝╚═╝ ╚═╝╚═╝╚═╝ ╚═╝╚══════╝
|
||||||
|
-->
|
||||||
<color name="md_black_1000">#000000</color>
|
<color name="md_black_1000">#000000</color>
|
||||||
|
|
||||||
<color name="md_light_primary_icon">#8A000000</color>
|
<color name="md_light_primary_icon">#8A000000</color>
|
||||||
|
@ -133,7 +143,6 @@
|
||||||
<color name="md_cyan_A700">#00B8D4</color>
|
<color name="md_cyan_A700">#00B8D4</color>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<color name="md_deep_orange_100">#FFCCBC</color>
|
<color name="md_deep_orange_100">#FFCCBC</color>
|
||||||
<color name="md_deep_orange_200">#FFAB91</color>
|
<color name="md_deep_orange_200">#FFAB91</color>
|
||||||
<color name="md_deep_orange_300">#FF8A65</color>
|
<color name="md_deep_orange_300">#FF8A65</color>
|
||||||
|
@ -342,6 +351,4 @@
|
||||||
<color name="md_yellow_A200">#FFFF00</color>
|
<color name="md_yellow_A200">#FFFF00</color>
|
||||||
<color name="md_yellow_A400">#FFEA00</color>
|
<color name="md_yellow_A400">#FFEA00</color>
|
||||||
<color name="md_yellow_A700">#FFD600</color>
|
<color name="md_yellow_A700">#FFD600</color>
|
||||||
|
|
||||||
<color name="transparent_black">#c4000000</color>
|
|
||||||
</resources>
|
</resources>
|
|
@ -1,7 +1,7 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<!-- Appearance -->
|
<!-- Appearance -->
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory
|
<com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory
|
||||||
android:key="@string/pref_key__title__appearance"
|
android:key="@string/pref_key__title__appearance"
|
||||||
android:title="@string/pref_cat__visuals">
|
android:title="@string/pref_cat__visuals">
|
||||||
|
|
||||||
|
@ -23,34 +23,34 @@
|
||||||
android:summary="%s"
|
android:summary="%s"
|
||||||
android:title="@string/pref_title__font_size"/>
|
android:title="@string/pref_title__font_size"/>
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__intellihide_toolbars"
|
android:key="@string/pref_key__intellihide_toolbars"
|
||||||
android:summary="@string/pref_desc__intellihide_toolbars"
|
android:summary="@string/pref_desc__intellihide_toolbars"
|
||||||
android:title="@string/pref_title__intellihide_toolbars"/>
|
android:title="@string/pref_title__intellihide_toolbars"/>
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__extended_notifications"
|
android:key="@string/pref_key__extended_notifications"
|
||||||
android:summary="@string/pref_desc__extended_notifications"
|
android:summary="@string/pref_desc__extended_notifications"
|
||||||
android:title="@string/pref_title__extended_notifications"/>
|
android:title="@string/pref_title__extended_notifications"/>
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__append_shared_via_app"
|
android:key="@string/pref_key__append_shared_via_app"
|
||||||
android:summary="@string/pref_desc__append_shared_via_app"
|
android:summary="@string/pref_desc__append_shared_via_app"
|
||||||
android:title="@string/pref_title__append_shared_via_app"/>
|
android:title="@string/pref_title__append_shared_via_app"/>
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__chrome_custom_tabs_enabled"
|
android:key="@string/pref_key__chrome_custom_tabs_enabled"
|
||||||
android:summary="@string/pref_desc__chrome_custom_tabs_enabled"
|
android:summary="@string/pref_desc__chrome_custom_tabs_enabled"
|
||||||
android:title="@string/pref_title__chrome_custom_tabs_enabled"/>
|
android:title="@string/pref_title__chrome_custom_tabs_enabled"/>
|
||||||
|
|
||||||
</com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory>
|
</com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory>
|
||||||
|
|
||||||
<!-- Diaspora Pod Settings -->
|
<!-- Diaspora Pod Settings -->
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory
|
<com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory
|
||||||
android:key="@string/pref_key__title__pod_settings"
|
android:key="@string/pref_key__title__pod_settings"
|
||||||
android:title="@string/pref_cat__pod_settings">
|
android:title="@string/pref_cat__pod_settings">
|
||||||
<Preference
|
<Preference
|
||||||
|
@ -72,13 +72,13 @@
|
||||||
android:key="@string/pref_key__change_account"
|
android:key="@string/pref_key__change_account"
|
||||||
android:summary="@string/pref_desc__change_account"
|
android:summary="@string/pref_desc__change_account"
|
||||||
android:title="@string/pref_title__change_account"/>
|
android:title="@string/pref_title__change_account"/>
|
||||||
</com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory>
|
</com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory>
|
||||||
|
|
||||||
<!-- Networking -->
|
<!-- Networking -->
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory
|
<com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory
|
||||||
android:key="@string/pref_key__title__network"
|
android:key="@string/pref_key__title__network"
|
||||||
android:title="@string/pref_cat__network">
|
android:title="@string/pref_cat__network">
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__load_images"
|
android:key="@string/pref_key__load_images"
|
||||||
android:summary="@string/pref_desc__load_images"
|
android:summary="@string/pref_desc__load_images"
|
||||||
|
@ -94,10 +94,10 @@
|
||||||
android:summary="@string/pref_desc__sub_proxy"
|
android:summary="@string/pref_desc__sub_proxy"
|
||||||
android:title="@string/pref_title__sub_proxy" />
|
android:title="@string/pref_title__sub_proxy" />
|
||||||
|
|
||||||
</com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory>
|
</com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory>
|
||||||
|
|
||||||
<!-- More -->
|
<!-- More -->
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory
|
<com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory
|
||||||
android:key="@string/pref_key__title__more"
|
android:key="@string/pref_key__title__more"
|
||||||
android:title="@string/pref_cat__more">
|
android:title="@string/pref_cat__more">
|
||||||
|
|
||||||
|
@ -106,5 +106,5 @@
|
||||||
android:summary="@string/pref_desc__sub_logging"
|
android:summary="@string/pref_desc__sub_logging"
|
||||||
android:title="@string/pref_title__sub_logging" />
|
android:title="@string/pref_title__sub_logging" />
|
||||||
|
|
||||||
</com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory>
|
</com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory>
|
||||||
</PreferenceScreen>
|
</PreferenceScreen>
|
|
@ -1,16 +1,16 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory
|
<com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory
|
||||||
android:key="@string/pref_key__title__debugging"
|
android:key="@string/pref_key__title__debugging"
|
||||||
android:title="@string/pref_title__sub_logging">
|
android:title="@string/pref_title__sub_logging">
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__logging_enabled"
|
android:key="@string/pref_key__logging_enabled"
|
||||||
android:title="@string/pref_title__logging_enabled"/>
|
android:title="@string/pref_title__logging_enabled"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedCheckBoxPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedCheckBoxPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__logging_spam_enabled"
|
android:key="@string/pref_key__logging_spam_enabled"
|
||||||
android:title="@string/pref_title__logging_spam_enabled"/>
|
android:title="@string/pref_title__logging_spam_enabled"/>
|
||||||
</com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory>
|
</com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory>
|
||||||
</PreferenceScreen>
|
</PreferenceScreen>
|
|
@ -1,54 +1,54 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory
|
<com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory
|
||||||
android:key="@string/pref_key__title__visibility_nav"
|
android:key="@string/pref_key__title__visibility_nav"
|
||||||
android:title="@string/pref_cat__visibility_nav_items">
|
android:title="@string/pref_cat__visibility_nav_items">
|
||||||
|
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__visibility_nav__profile"
|
android:key="@string/pref_key__visibility_nav__profile"
|
||||||
android:title="@string/nav_profile"/>
|
android:title="@string/nav_profile"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__visibility_nav__followed_tags"
|
android:key="@string/pref_key__visibility_nav__followed_tags"
|
||||||
android:title="@string/nav_followed_tags"/>
|
android:title="@string/nav_followed_tags"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__visibility_nav__aspects"
|
android:key="@string/pref_key__visibility_nav__aspects"
|
||||||
android:title="@string/nav_aspects"/>
|
android:title="@string/nav_aspects"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__visibility_nav__contacts"
|
android:key="@string/pref_key__visibility_nav__contacts"
|
||||||
android:title="@string/nav_contacts" />
|
android:title="@string/nav_contacts" />
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__visibility_nav__activities"
|
android:key="@string/pref_key__visibility_nav__activities"
|
||||||
android:title="@string/nav_activities"/>
|
android:title="@string/nav_activities"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__visibility_nav__liked"
|
android:key="@string/pref_key__visibility_nav__liked"
|
||||||
android:title="@string/nav_liked"/>
|
android:title="@string/nav_liked"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__visibility_nav__commented"
|
android:key="@string/pref_key__visibility_nav__commented"
|
||||||
android:title="@string/nav_commented"/>
|
android:title="@string/nav_commented"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__visibility_nav__mentions"
|
android:key="@string/pref_key__visibility_nav__mentions"
|
||||||
android:title="@string/nav_mentions"/>
|
android:title="@string/nav_mentions"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__visibility_nav__public_activities"
|
android:key="@string/pref_key__visibility_nav__public_activities"
|
||||||
android:title="@string/nav_public_activities"/>
|
android:title="@string/nav_public_activities"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="@string/pref_key__visibility_nav__exit"
|
android:key="@string/pref_key__visibility_nav__exit"
|
||||||
android:title="@string/action_exit_app"/>
|
android:title="@string/action_exit_app"/>
|
||||||
<com.github.dfa.diaspora_android.ui.ThemedVisibilityPreference
|
<com.github.dfa.diaspora_android.ui.theme.ThemedVisibilityPreference
|
||||||
android:defaultValue="true"
|
android:defaultValue="true"
|
||||||
android:key="@string/pref_key__visibility_nav__help_license"
|
android:key="@string/pref_key__visibility_nav__help_license"
|
||||||
android:title="@string/nav_help_license"/>
|
android:title="@string/nav_help_license"/>
|
||||||
|
|
||||||
</com.github.dfa.diaspora_android.ui.ThemedPreferenceCategory>
|
</com.github.dfa.diaspora_android.ui.theme.ThemedPreferenceCategory>
|
||||||
</PreferenceScreen>
|
</PreferenceScreen>
|