Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VLC-Android
Manage
Activity
Members
Labels
Plan
Issues
530
Issue boards
Milestones
Wiki
Code
Merge requests
15
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
VideoLAN
VLC-Android
Commits
5c14f14f
Commit
5c14f14f
authored
7 years ago
by
Geoffrey Métais
Browse files
Options
Downloads
Patches
Plain Diff
Save selected audio tab
parent
e7d4b9a3
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
vlc-android/src/org/videolan/vlc/gui/audio/AudioBrowserFragment.java
+2
-0
2 additions, 0 deletions
.../src/org/videolan/vlc/gui/audio/AudioBrowserFragment.java
vlc-android/src/org/videolan/vlc/util/Constants.java
+3
-0
3 additions, 0 deletions
vlc-android/src/org/videolan/vlc/util/Constants.java
with
5 additions
and
0 deletions
vlc-android/src/org/videolan/vlc/gui/audio/AudioBrowserFragment.java
+
2
−
0
View file @
5c14f14f
...
...
@@ -137,6 +137,7 @@ public class AudioBrowserFragment extends BaseAudioBrowser implements SwipeRefre
};
mViewPager
.
setOffscreenPageLimit
(
MODE_TOTAL
-
1
);
mViewPager
.
setAdapter
(
new
AudioPagerAdapter
(
mLists
,
titles
));
mViewPager
.
setCurrentItem
(
VLCApplication
.
getSettings
().
getInt
(
Constants
.
KEY_AUDIO_CURRENT_TAB
,
0
));
final
RecyclerView
.
RecycledViewPool
rvp
=
new
RecyclerView
.
RecycledViewPool
();
for
(
int
i
=
0
;
i
<
MODE_TOTAL
;
++
i
)
{
final
LinearLayoutManager
llm
=
new
LinearLayoutManager
(
getActivity
());
...
...
@@ -421,6 +422,7 @@ public class AudioBrowserFragment extends BaseAudioBrowser implements SwipeRefre
public
void
onTabSelected
(
TabLayout
.
Tab
tab
)
{
getActivity
().
supportInvalidateOptionsMenu
();
mFastScroller
.
setRecyclerView
(
mLists
[
tab
.
getPosition
()]);
VLCApplication
.
getSettings
().
edit
().
putInt
(
Constants
.
KEY_AUDIO_CURRENT_TAB
,
tab
.
getPosition
()).
apply
();
}
@Override
...
...
This diff is collapsed.
Click to expand it.
vlc-android/src/org/videolan/vlc/util/Constants.java
+
3
−
0
View file @
5c14f14f
...
...
@@ -85,4 +85,7 @@ public class Constants {
// Preferences
public
final
static
String
KEY_ARTISTS_SHOW_ALL
=
"artists_show_all"
;
// AUDIO category
public
final
static
String
KEY_AUDIO_CURRENT_TAB
=
"key_audio_current_tab"
;
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment