mirror of
https://github.com/FliegendeWurst/cursive.git
synced 2024-11-23 17:35:00 +00:00
Reformat & fix clippy
This commit is contained in:
parent
1b10ea154d
commit
31b8e1f515
@ -523,7 +523,7 @@ impl IndexedCow {
|
|||||||
|
|
||||||
/// Returns the embedded text content if `self` is `IndexedCow::Owned`.
|
/// Returns the embedded text content if `self` is `IndexedCow::Owned`.
|
||||||
pub fn as_owned(&self) -> Option<&str> {
|
pub fn as_owned(&self) -> Option<&str> {
|
||||||
if let &IndexedCow::Owned(ref content) = self {
|
if let IndexedCow::Owned(ref content) = *self {
|
||||||
Some(content)
|
Some(content)
|
||||||
} else {
|
} else {
|
||||||
None
|
None
|
||||||
|
@ -7,7 +7,8 @@ fn main() {
|
|||||||
siv.load_theme_file("assets/style.toml").unwrap();
|
siv.load_theme_file("assets/style.toml").unwrap();
|
||||||
|
|
||||||
// Or you can directly load it from a string for easy deployment.
|
// Or you can directly load it from a string for easy deployment.
|
||||||
siv.load_toml(include_str!("../../assets/style.toml")).unwrap();
|
siv.load_toml(include_str!("../../assets/style.toml"))
|
||||||
|
.unwrap();
|
||||||
|
|
||||||
siv.add_layer(
|
siv.add_layer(
|
||||||
Dialog::around(TextView::new(
|
Dialog::around(TextView::new(
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
unstable_features = true
|
|
||||||
max_width = 79
|
max_width = 79
|
||||||
reorder_imports = true
|
reorder_imports = true
|
||||||
fn_args_layout = "Tall"
|
fn_args_layout = "Tall"
|
||||||
|
Loading…
Reference in New Issue
Block a user