parent
e2678e524b
commit
c05ba531c0
|
@ -65,19 +65,19 @@ public class User extends TwitterResponseObject implements Comparable<User> {
|
|||
boolean isProtected;
|
||||
|
||||
@JsonField(name = "followers_count")
|
||||
long followersCount;
|
||||
long followersCount = -1;
|
||||
|
||||
@JsonField(name = "friends_count")
|
||||
long friendsCount;
|
||||
long friendsCount = -1;
|
||||
|
||||
@JsonField(name = "listed_count")
|
||||
long listedCount;
|
||||
long listedCount = -1;
|
||||
|
||||
@JsonField(name = "created_at", typeConverter = TwitterDateConverter.class)
|
||||
Date createdAt;
|
||||
|
||||
@JsonField(name = "favourites_count")
|
||||
long favouritesCount;
|
||||
long favouritesCount = -1;
|
||||
|
||||
@JsonField(name = "utc_offset")
|
||||
int utcOffset;
|
||||
|
@ -92,10 +92,10 @@ public class User extends TwitterResponseObject implements Comparable<User> {
|
|||
boolean isVerified;
|
||||
|
||||
@JsonField(name = "statuses_count")
|
||||
long statusesCount;
|
||||
long statusesCount = -1;
|
||||
|
||||
@JsonField(name = "media_count")
|
||||
long mediaCount;
|
||||
long mediaCount = -1;
|
||||
|
||||
@JsonField(name = "lang")
|
||||
String lang;
|
||||
|
|
|
@ -129,27 +129,27 @@ public class ParcelableUser implements Parcelable, Comparable<ParcelableUser> {
|
|||
@ParcelableThisPlease
|
||||
@JsonField(name = "followers_count")
|
||||
@CursorField(CachedUsers.FOLLOWERS_COUNT)
|
||||
public long followers_count;
|
||||
public long followers_count = -1;
|
||||
@ParcelableThisPlease
|
||||
@JsonField(name = "friends_count")
|
||||
@CursorField(CachedUsers.FRIENDS_COUNT)
|
||||
public long friends_count;
|
||||
public long friends_count = -1;
|
||||
@ParcelableThisPlease
|
||||
@JsonField(name = "statuses_count")
|
||||
@CursorField(CachedUsers.STATUSES_COUNT)
|
||||
public long statuses_count;
|
||||
public long statuses_count = -1;
|
||||
@ParcelableThisPlease
|
||||
@JsonField(name = "favorites_count")
|
||||
@CursorField(CachedUsers.FAVORITES_COUNT)
|
||||
public long favorites_count;
|
||||
public long favorites_count = -1;
|
||||
@ParcelableThisPlease
|
||||
@JsonField(name = "listed_count")
|
||||
@CursorField(CachedUsers.LISTED_COUNT)
|
||||
public long listed_count;
|
||||
public long listed_count = -1;
|
||||
@ParcelableThisPlease
|
||||
@JsonField(name = "media_count")
|
||||
@CursorField(CachedUsers.MEDIA_COUNT)
|
||||
public long media_count;
|
||||
public long media_count = -1;
|
||||
|
||||
@ParcelableThisPlease
|
||||
@JsonField(name = "background_color")
|
||||
|
|
|
@ -24,6 +24,7 @@ import android.app.FragmentManager;
|
|||
import android.content.ActivityNotFoundException;
|
||||
import android.content.Intent;
|
||||
import android.content.res.Configuration;
|
||||
import android.media.AudioAttributes;
|
||||
import android.media.AudioManager;
|
||||
import android.media.MediaPlayer;
|
||||
import android.net.Uri;
|
||||
|
@ -927,7 +928,6 @@ public final class MediaViewerActivity extends AbsMediaViewerActivity implements
|
|||
if (getUserVisibleHint()) {
|
||||
mMediaPlayer = mp;
|
||||
mMediaPlayerError = 0;
|
||||
mp.setAudioStreamType(AudioManager.STREAM_MUSIC);
|
||||
mp.setScreenOnWhilePlaying(true);
|
||||
updateVolume();
|
||||
mp.setLooping(isLoopEnabled());
|
||||
|
|
|
@ -441,8 +441,12 @@ public class UserFragment extends BaseSupportFragment implements OnClickListener
|
|||
break;
|
||||
}
|
||||
case TAB_TYPE_MEDIA: {
|
||||
actionBar.setSubtitle(getResources().getQuantityString(R.plurals.N_media,
|
||||
(int) user.media_count, user.media_count));
|
||||
if (user.media_count < 0) {
|
||||
actionBar.setSubtitle(R.string.recent_media);
|
||||
} else {
|
||||
actionBar.setSubtitle(getResources().getQuantityString(R.plurals.N_media,
|
||||
(int) user.media_count, user.media_count));
|
||||
}
|
||||
break;
|
||||
}
|
||||
case TAB_TYPE_FAVORITES: {
|
||||
|
|
|
@ -78,9 +78,9 @@ public class MediaTimelineLoader extends TwitterAPIStatusesLoader {
|
|||
}
|
||||
final SearchQuery query;
|
||||
if (mTwitterOptimizedSearches) {
|
||||
query = new SearchQuery("from:" + screenName + " filter:media");
|
||||
query = new SearchQuery("from:" + screenName + " filter:media exclude:retweets");
|
||||
} else {
|
||||
query = new SearchQuery("@" + screenName + " pic.twitter.com");
|
||||
query = new SearchQuery("@" + screenName + " pic.twitter.com -RT");
|
||||
}
|
||||
query.paging(paging);
|
||||
final ResponseList<Status> result = new ResponseList<>();
|
||||
|
|
|
@ -850,4 +850,5 @@
|
|||
<string name="builtin_dns_resolver">Builtin DNS resolver</string>
|
||||
<string name="bandwidth_saving_mode">Bandwidth saving mode</string>
|
||||
<string name="bandwidth_saving_mode_summary">Disable media preview on metered network</string>
|
||||
<string name="recent_media">Recent media</string>
|
||||
</resources>
|
|
@ -35,6 +35,19 @@
|
|||
android:name="notify_change"
|
||||
android:value="true"/>
|
||||
</org.mariotaku.twidere.preference.AutoFixSwitchPreference>
|
||||
|
||||
<org.mariotaku.twidere.preference.SummaryListPreference
|
||||
android:defaultValue="@string/default_profile_image_style"
|
||||
android:entries="@array/entries_profile_image_style"
|
||||
android:entryValues="@array/values_profile_image_style"
|
||||
android:key="profile_image_style"
|
||||
android:order="24"
|
||||
android:title="@string/profile_image_style">
|
||||
<extra
|
||||
android:name="notify_change"
|
||||
android:value="true"/>
|
||||
</org.mariotaku.twidere.preference.SummaryListPreference>
|
||||
|
||||
<org.mariotaku.twidere.preference.AutoFixSwitchPreference
|
||||
android:defaultValue="false"
|
||||
android:key="media_preview"
|
||||
|
|
|
@ -20,17 +20,6 @@
|
|||
|
||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<org.mariotaku.twidere.preference.SummaryListPreference
|
||||
android:defaultValue="@string/default_profile_image_style"
|
||||
android:entries="@array/entries_profile_image_style"
|
||||
android:entryValues="@array/values_profile_image_style"
|
||||
android:key="profile_image_style"
|
||||
android:title="@string/profile_image_style">
|
||||
<extra
|
||||
android:name="notify_change"
|
||||
android:value="true"/>
|
||||
</org.mariotaku.twidere.preference.SummaryListPreference>
|
||||
|
||||
<org.mariotaku.twidere.preference.SummaryListPreference
|
||||
android:defaultValue="crop"
|
||||
android:entries="@array/entries_media_preview_style"
|
||||
|
|
Loading…
Reference in New Issue