The following question arose. For example, I need to implement file playback by link, but the structure is as follows:
List of artists - Artist - Album - Tracks
The track will be uploaded to the database, and, as intended, will be played by the link.
The question is as follows. How can I try to display a list of artists on the screen first, then by clicking on a certain artist to get to the list of his albums, and from there to the list of album tracks and play it.
Please help me, I can't think of a way to implement this, if at all...
Related
I have array list of videos so users can watch video in android app. I would like to add Next and Previous button for playing next or previous video after current video is ended. I googled it but to no avail. I need your help. Thanks in advance. 🙏🏾
If you're using the MediaPlayer class then maybe try adding logic to the callback for setOnCompletionListener(android.media.MediaPlayer.OnCompletionListener) that takes the user to the next video by getting what's next from the list and starting playback.
See Android Docs for more information. Without knowing what you're trying it's almost impossible to help you solve your problem. Please share the code from your solution related to your question.
How can I create a ListView of videos?
I explain myself a little better, I want to make an app with a listview that contains short videos.
I create an activity list_item where I want to put images and text. For example in the first list item I want you to put a thumbnail and a description, for example: horse accident and in the second list_item put another thumbnail with another description, for example: squirrel attack.
I know how to create a list view that shows the same image in all the list_items, but I don't know how to make a list view that contains different videos, images and text for each list_item.
The images, the video and are stored in the assets and raw folder, respectively.
Do you have any idea how to fix this?
Use this library for videos using ListView :
implementation 'cn.jzvd:jiaozivideoplayer:6.2.12'
use this link for documentation : https://github.com/lipangit/JiaoZiVideoPlayer
I have recently started automating iOS apps on iPhone real devices with the XCUI test setup.
I got a scenario where my app contains 5 screens in the home page, each screen contains a unique card number and its balance so i have to fetch the card number from the screen and verify it with my input(expected) card number, if both are same then i have to click on the card screen otherwise if both are not same then i have to swipe right to the second screen and do the same process.
I was able to automate this scenrio in android perfectly because in android each screen is clearly differentiated with a unique card number but when i inspect the card number screen on iOS app it was showing all the list of cards attached to the app. in this case its getting difficult for me to get the card number from the app and verify it with my input card number . please see the below code which am already using it for android
String oysterCardVisibleNumberOnApp= data.get("PrestigeCardNumber");
while(!action.getText(HomePage.oysterCardNumber,"oysterCardNumber").equalsIgnorecase(oysterCardVisibleNumberOnApp))){
action.swipeRightToLeft();
}
it would be great if any one has any idea how to retrieve the list of elements/cards from the iOS app please let me know. or if you know any new methods in XCUI setup will help me to achieve this then please let me know. your help will be much appreciated :)
Please see the below Android Screen & iOS Screen pictures for getting more clarity
Android Screen
iOS Screen
Thank you
If you stop at a breakpoint for instance and you use:
po XCUIApplication().descendants(matching: .any)
in the debug console, you will get a list of all descendant elements from the main Application element. It will also give you a loose view of the structure.
You can then change .any to more specific element types e.g. .textField or .buttons.
You might be able to use the Accessibility Inspector in xcode for this:
https://developer.apple.com/library/content/documentation/Accessibility/Conceptual/AccessibilityMacOSX/OSXAXTestingApps.html
Based on areas you select in your app, it gives back detailed descriptions on each one. But what it brings back depends on the structure of your application. I was trying to do something similar in my own ios application and this helped me a bit.
You can use XCUIApplication().debugDescription to get a print out of the UI tree that XCUITest sees. You can also update the application code to set custom identifiers for your UI elements (these are only seen by XCUITest). for example card-1, etc.
I'm trying to create a scrollabe friends list. I'm grabbing the information for each friend off of a text file (profile pic, name, age, etc.)
So in my prototype I used different nested layouts to create one single friend entry. And to fill the list I just copied the most parent layout of my first friend and changed or adjusted the profile pic and the other text information.
What if, while the app is running, I need to update my friendslist and add another friend to the list.
How do you realise something like that?
Go for a recycler view or a scrollable list view to make a list and dynamic. You can check slidenerd's video tutorial on youtube. They are really helpful for a beginner to start any kind of app.
I have created a media player and it is working. The issue I have is that only the video names are displayed in my list view. How can I see the name and a thumbnail image of the video in my list view?
Came across this SO Thread while searching to answer your question. Not sure if that will work on Android or not. You give it a try.