Use closures for ProgressBar::style
This commit is contained in:
parent
fd7a23ca47
commit
7a5f5b0be7
2 changed files with 21 additions and 21 deletions
|
|
@ -340,12 +340,12 @@ where
|
|||
/// * the current value of the [`ProgressBar`].
|
||||
///
|
||||
/// [`ProgressBar`]: crate::ProgressBar
|
||||
pub fn progress_bar<Theme>(
|
||||
pub fn progress_bar<'a, Theme>(
|
||||
range: RangeInclusive<f32>,
|
||||
value: f32,
|
||||
) -> ProgressBar<Theme>
|
||||
) -> ProgressBar<'a, Theme>
|
||||
where
|
||||
Theme: progress_bar::DefaultStyle,
|
||||
Theme: progress_bar::DefaultStyle + 'a,
|
||||
{
|
||||
ProgressBar::new(range, value)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue