-
Notifications
You must be signed in to change notification settings - Fork 389
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
RHEL-69075: Formatting vioinput driver with clang-format [HLK-SANITY] #1245
base: master
Are you sure you want to change the base?
RHEL-69075: Formatting vioinput driver with clang-format [HLK-SANITY] #1245
Conversation
{ | ||
sprintf_s(buffer, sizeof(buffer), "%02x", pDescriptor[i]); | ||
i++; | ||
break; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@YanVugenfirer Do we need {} in case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not really needed, but it was here before. No reason to have it here as there are no local variables.
{ | ||
TraceEvents(TRACE_LEVEL_INFORMATION, DBG_INIT, "Got axis-based vertical wheel\n"); | ||
pMouseDesc->uFlags |= CLASS_MOUSE_SUPPORTS_REL_WHEEL; | ||
pMouseDesc->uFlags |= CLASS_MOUSE_HAS_V_WHEEL; | ||
break; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can be removed. But I think better in another PR
vioinput/sys/HidTablet.c
Outdated
pTabletDesc->Common.cbHidReportSize = 1 + // report ID | ||
sizeof(INPUT_CLASS_TABLET_SLOT) * pTabletDesc->uMaxContacts + // max contacts | ||
// * per-contact | ||
// packet. See | ||
// INPUT_CLASS_TABLET_SLOT | ||
// and | ||
// INPUT_CLASS_TABLET | ||
// for layout | ||
// details. | ||
1 + // Actual contact count | ||
(pTabletDesc->bMscTs ? sizeof(LONG) : 0) // Scan time | ||
; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@YanVugenfirer Maybe rewrite this part or disable the format?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably better re-write
vioinput/sys/KeyMap.c
Outdated
static const ULONG ReportCodeToUsageCodeTable[] = { | ||
/* KEY_RESERVED */ | ||
0x00, | ||
/* KEY_ESC */ 0x29, | ||
/* KEY_1 */ 0x1E, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The same problem as in vioserial
vioinput/sys/Hid.c
Outdated
0x01, // number of HID class descriptors | ||
{ | ||
// DescriptorList[0] | ||
0x22, // report descriptor type 0x22 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indentation issues again
{ | ||
sprintf_s(buffer, sizeof(buffer), "%02x", pDescriptor[i]); | ||
i++; | ||
break; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not really needed, but it was here before. No reason to have it here as there are no local variables.
{ | ||
TraceEvents(TRACE_LEVEL_INFORMATION, DBG_INIT, "Got axis-based vertical wheel\n"); | ||
pMouseDesc->uFlags |= CLASS_MOUSE_SUPPORTS_REL_WHEEL; | ||
pMouseDesc->uFlags |= CLASS_MOUSE_HAS_V_WHEEL; | ||
break; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can be removed. But I think better in another PR
vioinput/sys/HidTablet.c
Outdated
pTabletDesc->Common.cbHidReportSize = 1 + // report ID | ||
sizeof(INPUT_CLASS_TABLET_SLOT) * pTabletDesc->uMaxContacts + // max contacts | ||
// * per-contact | ||
// packet. See | ||
// INPUT_CLASS_TABLET_SLOT | ||
// and | ||
// INPUT_CLASS_TABLET | ||
// for layout | ||
// details. | ||
1 + // Actual contact count | ||
(pTabletDesc->bMscTs ? sizeof(LONG) : 0) // Scan time | ||
; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably better re-write
3cfce7e
to
9576343
Compare
Signed-off-by: Vitalii Chulak <[email protected]>
Signed-off-by: Vitalii Chulak <[email protected]>
9576343
to
6e99148
Compare
No description provided.