mirror of
https://gitlab.com/asus-linux/asusctl.git
synced 2026-02-06 00:15:04 +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)]
|
#[derive(Debug, Clone, Default, Options)]
|
||||||
|
#[allow(dead_code)]
|
||||||
pub struct MultiZone {
|
pub struct MultiZone {
|
||||||
#[options(help = "print help message")]
|
#[options(help = "print help message")]
|
||||||
help: bool,
|
help: bool,
|
||||||
@@ -195,6 +196,7 @@ pub struct MultiZone {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, Default, Options)]
|
#[derive(Debug, Clone, Default, Options)]
|
||||||
|
#[allow(dead_code)]
|
||||||
pub struct MultiColourSpeed {
|
pub struct MultiColourSpeed {
|
||||||
#[options(help = "print help message")]
|
#[options(help = "print help message")]
|
||||||
help: bool,
|
help: bool,
|
||||||
|
|||||||
@@ -1184,11 +1184,12 @@ fn print_firmware_attr(attr: &AsusArmouryProxyBlocking) -> Result<(), Box<dyn st
|
|||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[allow(clippy::manual_is_multiple_of, clippy::nonminimal_bool)]
|
||||||
fn handle_armoury_command(cmd: &ArmouryCommand) -> Result<(), Box<dyn std::error::Error>> {
|
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";
|
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!(
|
println!(
|
||||||
"Incorrect number of args, each attribute label must be paired with a setting:"
|
"Incorrect number of args, each attribute label must be paired with a setting:"
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -102,6 +102,7 @@ pub struct DeviceManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl DeviceManager {
|
impl DeviceManager {
|
||||||
|
#[allow(clippy::type_complexity)]
|
||||||
async fn get_or_create_hid_handle(
|
async fn get_or_create_hid_handle(
|
||||||
handles: &Arc<Mutex<HashMap<String, Arc<Mutex<HidRaw>>>>>,
|
handles: &Arc<Mutex<HashMap<String, Arc<Mutex<HidRaw>>>>>,
|
||||||
endpoint: &Device,
|
endpoint: &Device,
|
||||||
|
|||||||
@@ -51,6 +51,7 @@ pub struct CtrlPlatform {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl CtrlPlatform {
|
impl CtrlPlatform {
|
||||||
|
#[allow(clippy::too_many_arguments)]
|
||||||
pub fn new(
|
pub fn new(
|
||||||
platform: RogPlatform,
|
platform: RogPlatform,
|
||||||
power: AsusPower,
|
power: AsusPower,
|
||||||
|
|||||||
@@ -157,8 +157,9 @@ fn main() -> Result<(), Box<dyn Error>> {
|
|||||||
for (x_count, b) in dev.buffer[start..=end].iter().enumerate() {
|
for (x_count, b) in dev.buffer[start..=end].iter().enumerate() {
|
||||||
canvas.set_draw_color(Color::RGB(*b, *b, *b));
|
canvas.set_draw_color(Color::RGB(*b, *b, *b));
|
||||||
|
|
||||||
|
#[allow(clippy::manual_is_multiple_of)]
|
||||||
let x: i32 = w + x_count as i32 * w
|
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
|
0
|
||||||
} else {
|
} else {
|
||||||
w / 2
|
w / 2
|
||||||
|
|||||||
Reference in New Issue
Block a user