output: pre-compute OutputId hash
This commit is contained in:
parent
9bd7e14b08
commit
6e9adc487e
8 changed files with 88 additions and 40 deletions
|
|
@ -1311,12 +1311,7 @@ fn create_connector_display_data(
|
|||
}
|
||||
}
|
||||
}
|
||||
let output_id = Rc::new(OutputId::new(
|
||||
connector_id.to_string(),
|
||||
manufacturer,
|
||||
name,
|
||||
serial_number,
|
||||
));
|
||||
let output_id = OutputId::new(connector_id.to_string(), manufacturer, name, serial_number);
|
||||
let first_mode = info
|
||||
.modes
|
||||
.first()
|
||||
|
|
|
|||
|
|
@ -591,12 +591,12 @@ impl XBackend {
|
|||
.push(BackendEvent::NewConnector(output.clone()));
|
||||
output.events.push(ConnectorEvent::Connected(MonitorInfo {
|
||||
modes: Some(vec![]),
|
||||
output_id: Rc::new(OutputId::new(
|
||||
String::new(),
|
||||
"X.Org Foundation".to_string(),
|
||||
output_id: OutputId::new(
|
||||
"",
|
||||
"X.Org Foundation",
|
||||
format!("X-Window-{}", output.window),
|
||||
output.window.to_string(),
|
||||
)),
|
||||
),
|
||||
width_mm: output.width.get(),
|
||||
height_mm: output.height.get(),
|
||||
non_desktop: false,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue