mirror of
https://gitlab.com/asus-linux/asusctl.git
synced 2026-01-22 17:33:19 +01:00
Chore: ignore push-blocking features that would make older rust toolchains error
This commit is contained in:
@@ -181,6 +181,7 @@ pub struct TwoColourSpeed {
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Default, Options)]
|
||||
#[allow(dead_code)]
|
||||
pub struct MultiZone {
|
||||
#[options(help = "print help message")]
|
||||
help: bool,
|
||||
@@ -195,6 +196,7 @@ pub struct MultiZone {
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Default, Options)]
|
||||
#[allow(dead_code)]
|
||||
pub struct MultiColourSpeed {
|
||||
#[options(help = "print help message")]
|
||||
help: bool,
|
||||
|
||||
@@ -1184,11 +1184,12 @@ fn print_firmware_attr(attr: &AsusArmouryProxyBlocking) -> Result<(), Box<dyn st
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[allow(clippy::manual_is_multiple_of, clippy::nonminimal_bool)]
|
||||
fn handle_armoury_command(cmd: &ArmouryCommand) -> Result<(), Box<dyn std::error::Error>> {
|
||||
{
|
||||
if cmd.free.is_empty() || !cmd.free.len().is_multiple_of(2) || cmd.help {
|
||||
if cmd.free.is_empty() || (cmd.free.len() % 2 != 0) || cmd.help {
|
||||
const USAGE: &str = "Usage: asusctl platform panel_overdrive 1 nv_dynamic_boost 5";
|
||||
if !(cmd.free.len() % 2 == 0) {
|
||||
if cmd.free.len() % 2 != 0 {
|
||||
println!(
|
||||
"Incorrect number of args, each attribute label must be paired with a setting:"
|
||||
);
|
||||
|
||||
@@ -102,6 +102,7 @@ pub struct DeviceManager {
|
||||
}
|
||||
|
||||
impl DeviceManager {
|
||||
#[allow(clippy::type_complexity)]
|
||||
async fn get_or_create_hid_handle(
|
||||
handles: &Arc<Mutex<HashMap<String, Arc<Mutex<HidRaw>>>>>,
|
||||
endpoint: &Device,
|
||||
|
||||
@@ -51,6 +51,7 @@ pub struct CtrlPlatform {
|
||||
}
|
||||
|
||||
impl CtrlPlatform {
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
pub fn new(
|
||||
platform: RogPlatform,
|
||||
power: AsusPower,
|
||||
|
||||
@@ -157,8 +157,9 @@ fn main() -> Result<(), Box<dyn Error>> {
|
||||
for (x_count, b) in dev.buffer[start..=end].iter().enumerate() {
|
||||
canvas.set_draw_color(Color::RGB(*b, *b, *b));
|
||||
|
||||
#[allow(clippy::manual_is_multiple_of)]
|
||||
let x: i32 = w + x_count as i32 * w
|
||||
- if !((y_count + y_offset as usize) % 2 == 0) {
|
||||
- if (y_count + y_offset as usize) % 2 != 0 {
|
||||
0
|
||||
} else {
|
||||
w / 2
|
||||
|
||||
Reference in New Issue
Block a user