Compare commits

..

No commits in common. "9cccb7af898d773201b071a201a3066309c58f65" and "61dd0f22a9efe1ccef1370bf7f91cb753c607bab" have entirely different histories.

3 changed files with 6 additions and 11 deletions

2
.gitignore vendored
View File

@ -1,2 +1,2 @@
/target /target
Cargo.lock cargo.lock

View File

@ -7,7 +7,7 @@ pub fn inv() -> Result<(), Box<dyn Error>> {
let client = Client::new(String::from("https://invidious.projectsegfau.lt")); let client = Client::new(String::from("https://invidious.projectsegfau.lt"));
let search_results = client.search(Some("q=rust programming"))?.items; let search_results = client.search(Some("q=rust programming"))?.items;
let video = client.video("5C_HPTJg5ek", None)?; let video = client.video("5C_HPTJg5ek", None)?;
//println!("{:?}", video); println!("{:?}", video.title);
println!("{:?}", video.format_streams[2].url); println!("{:?}", video.views);
Ok(()) Ok(())
} }

View File

@ -19,14 +19,13 @@ fn main() {
// Connect to "activate" signal of `app` // Connect to "activate" signal of `app`
app.connect_activate(build_ui); app.connect_activate(build_ui);
let output = inv::inv();
//print!("{:?}", output); print!("{:?}", output);
// Run the application // Run the application
app.run(); app.run();
} }
fn build_ui(app: &Application) { fn build_ui(app: &Application) {
// Create a button // Create a button
let button = Button::builder() let button = Button::builder()
@ -42,11 +41,7 @@ fn build_ui(app: &Application) {
//button.connect_clicked(move |_| trig_play()); //button.connect_clicked(move |_| trig_play());
let video = Video::for_file(Some(&gio::File::for_path("/home/midou/Vidéos/miui.mp4"))); let video = Video::for_file(Some(&gio::File::for_path("/home/midou/Vidéos/miui.mp4")));
//let output = inv::inv();
//let video = Video::for_media_stream(Some(&output));
/* /*
// Set a listBox // Set a listBox