use of org.videolan.vlc.gui.browser.StorageBrowserFragment in project vlc-android by videolan.
the class AudioPlayerContainerActivity method onOptionsItemSelected.
@Override
public boolean onOptionsItemSelected(MenuItem item) {
// Handle item selection
switch(item.getItemId()) {
case android.R.id.home:
// Current fragment loaded
final Fragment current = getCurrentFragment();
if (current instanceof StorageBrowserFragment && ((StorageBrowserFragment) current).goBack())
return true;
finish();
return true;
default:
return super.onOptionsItemSelected(item);
}
}
use of org.videolan.vlc.gui.browser.StorageBrowserFragment in project vlc-android by GeoffreyMetais.
the class SecondaryActivity method fetchSecondaryFragment.
public void fetchSecondaryFragment(String id) {
switch(id) {
case ALBUMS_SONGS:
mFragment = new AudioAlbumsSongsFragment();
Bundle args = new Bundle();
args.putParcelable(AudioBrowserFragment.TAG_ITEM, getIntent().getParcelableExtra(AudioBrowserFragment.TAG_ITEM));
mFragment.setArguments(args);
break;
case ABOUT:
mFragment = new AboutFragment();
break;
case VIDEO_GROUP_LIST:
mFragment = new VideoGridFragment();
((VideoGridFragment) mFragment).setGroup(getIntent().getStringExtra("param"));
break;
case STORAGE_BROWSER:
mFragment = new StorageBrowserFragment();
break;
default:
throw new IllegalArgumentException("Wrong fragment id.");
}
}
use of org.videolan.vlc.gui.browser.StorageBrowserFragment in project vlc-android by GeoffreyMetais.
the class AudioPlayerContainerActivity method onOptionsItemSelected.
@Override
public boolean onOptionsItemSelected(MenuItem item) {
// Handle item selection
switch(item.getItemId()) {
case android.R.id.home:
// Current fragment loaded
final Fragment current = getCurrentFragment();
if (current instanceof StorageBrowserFragment && ((StorageBrowserFragment) current).goBack())
return true;
finish();
return true;
default:
return super.onOptionsItemSelected(item);
}
}
use of org.videolan.vlc.gui.browser.StorageBrowserFragment in project vlc-android by videolan.
the class SecondaryActivity method fetchSecondaryFragment.
public void fetchSecondaryFragment(String id) {
switch(id) {
case ALBUMS_SONGS:
mFragment = new AudioAlbumsSongsFragment();
Bundle args = new Bundle();
args.putParcelable(AudioBrowserFragment.TAG_ITEM, getIntent().getParcelableExtra(AudioBrowserFragment.TAG_ITEM));
mFragment.setArguments(args);
break;
case ABOUT:
mFragment = new AboutFragment();
break;
case VIDEO_GROUP_LIST:
mFragment = new VideoGridFragment();
((VideoGridFragment) mFragment).setGroup(getIntent().getStringExtra("param"));
break;
case STORAGE_BROWSER:
mFragment = new StorageBrowserFragment();
break;
default:
throw new IllegalArgumentException("Wrong fragment id.");
}
}
Aggregations