mirror of
https://gitlab.freedesktop.org/dabrain34/GstPipelineStudio.git
synced 2024-11-22 09:00:59 +00:00
about: display GStreamer version
This commit is contained in:
parent
6cc908c109
commit
57160b3bce
3 changed files with 11 additions and 1 deletions
1
TODO.md
1
TODO.md
|
@ -93,6 +93,7 @@
|
||||||
### GStreamer:
|
### GStreamer:
|
||||||
|
|
||||||
- [ ] Implement pipeline unit test
|
- [ ] Implement pipeline unit test
|
||||||
|
- [x] Display GStreamer version in the about dialog
|
||||||
|
|
||||||
### app
|
### app
|
||||||
|
|
||||||
|
|
|
@ -82,6 +82,10 @@ impl Player {
|
||||||
Ok(pipeline)
|
Ok(pipeline)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn get_version() -> String {
|
||||||
|
gst::version_string().to_string()
|
||||||
|
}
|
||||||
|
|
||||||
pub fn set_app(&self, app: GPSAppWeak) {
|
pub fn set_app(&self, app: GPSAppWeak) {
|
||||||
*self.app.borrow_mut() = Some(app.upgrade().unwrap());
|
*self.app.borrow_mut() = Some(app.upgrade().unwrap());
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,6 +8,7 @@
|
||||||
|
|
||||||
use crate::app::GPSApp;
|
use crate::app::GPSApp;
|
||||||
use crate::config;
|
use crate::config;
|
||||||
|
use crate::gps as GPS;
|
||||||
use gettextrs::gettext;
|
use gettextrs::gettext;
|
||||||
use gtk::builders::AboutDialogBuilder;
|
use gtk::builders::AboutDialogBuilder;
|
||||||
use gtk::prelude::*;
|
use gtk::prelude::*;
|
||||||
|
@ -23,7 +24,11 @@ pub fn display_about_dialog(app: &GPSApp) {
|
||||||
.modal(true)
|
.modal(true)
|
||||||
.program_name("GstPipelineStudio")
|
.program_name("GstPipelineStudio")
|
||||||
.version(config::VERSION)
|
.version(config::VERSION)
|
||||||
.comments(&gettext("Draw your own GStreamer pipeline"))
|
.comments(&format!(
|
||||||
|
"{}\n\n{}",
|
||||||
|
&gettext("Draw your own GStreamer pipeline"),
|
||||||
|
GPS::Player::get_version()
|
||||||
|
))
|
||||||
.website("https://gitlab.freedesktop.org/dabrain34/GstPipelineStudio")
|
.website("https://gitlab.freedesktop.org/dabrain34/GstPipelineStudio")
|
||||||
.authors(vec!["Stéphane Cerveau".to_string()])
|
.authors(vec!["Stéphane Cerveau".to_string()])
|
||||||
.artists(vec!["Stéphane Cerveau".to_string()])
|
.artists(vec!["Stéphane Cerveau".to_string()])
|
||||||
|
|
Loading…
Reference in a new issue