Skip to content

Commit

Permalink
Fix if you jump straight to chat tab
Browse files Browse the repository at this point in the history
  • Loading branch information
daneren2005 committed May 24, 2013
1 parent 70a04be commit 011a7e2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion subsonic-android/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="github.daneren2005.dsub"
android:installLocation="internalOnly"
android:versionCode="49"
android:versionCode="50"
android:versionName="4.0.1">

<uses-permission android:name="android.permission.INTERNET"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,14 @@ public Fragment getItem(int i) {
SubsonicFragment frag = (SubsonicFragment) Fragment.instantiate(activity, tabInfo.fragmentClass.getName(), tabInfo.args);
List<SubsonicFragment> fragStack = new ArrayList<SubsonicFragment>();
fragStack.add(frag);
frags.add(i, fragStack);
while(i > frags.size()) {
frags.add(null);
}
if(i == frags.size()) {
frags.add(i, fragStack);
} else {
frags.set(i, fragStack);
}
if(currentFragment == null) {
currentFragment = frag;
currentFragment.setPrimaryFragment(true);
Expand Down

0 comments on commit 011a7e2

Please sign in to comment.