Skip to content

Commit

Permalink
Rename to clarify HIDDescriptor report item methods
Browse files Browse the repository at this point in the history
Renamed to clarify that the HIDDescriptor convenience functions add
report items, not full reports.
  • Loading branch information
TiltMeSenpai committed Aug 9, 2020
1 parent cef2b8b commit 2e7f95f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions usb_protocol/emitters/descriptors/hid.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
class HIDDescriptor(ComplexDescriptorEmitter):
DESCRIPTOR_FORMAT = HIDDescriptorType

def add_report(self, report_enum, *report_data):
def add_report_item(self, report_enum, *report_data):
hid_report = ReportDescriptorEmitter()
report_len = _hid_item_length.index(len(report_data))
hid_report.bHeader = {
Expand All @@ -25,7 +25,7 @@ def add_report(self, report_enum, *report_data):
hid_report.data = report_data
self._reports.append(hid_report)

def add_input(self,
def add_input_item(self,
data_constant = False,
array_variable = True,
absolute_relative = False,
Expand All @@ -46,7 +46,7 @@ def add_input(self,
})
self.add_report(HIDPrefixes.INPUT, ord(item_flags))

def add_output(self,
def add_output_item(self,
data_constant = False,
array_variable = True,
absolute_relative = False,
Expand Down

0 comments on commit 2e7f95f

Please sign in to comment.