@@ -22,7 +22,8 @@ public sealed record FrameworkModuleDescriptorSnapshot
2222 /// <param name="vendorId">The observed vendor ID, when available.</param>
2323 /// <param name="productId">The observed product ID, when available.</param>
2424 /// <param name="boardId">The board-specific numeric identifier, when available.</param>
25- public FrameworkModuleDescriptorSnapshot ( FrameworkModuleIdentity identity , FrameworkModuleBus bus , FrameworkModuleSlotKind slotKind , FrameworkModuleConfidence confidence , bool isPresent , int slotIndex , FrameworkModuleFlags flags , uint vendorId , uint productId , int boardId )
25+ /// <param name="position">The physical input-deck position, when the module is input-deck-mounted.</param>
26+ public FrameworkModuleDescriptorSnapshot ( FrameworkModuleIdentity identity , FrameworkModuleBus bus , FrameworkModuleSlotKind slotKind , FrameworkModuleConfidence confidence , bool isPresent , int slotIndex , FrameworkModuleFlags flags , uint vendorId , uint productId , int boardId , FrameworkInputModulePosition position = FrameworkInputModulePosition . Unknown )
2627 {
2728 Identity = identity ;
2829 Bus = bus ;
@@ -34,6 +35,7 @@ public FrameworkModuleDescriptorSnapshot(FrameworkModuleIdentity identity, Frame
3435 VendorId = vendorId ;
3536 ProductId = productId ;
3637 BoardId = boardId ;
38+ Position = position ;
3739 }
3840
3941 /// <summary>
@@ -86,8 +88,14 @@ public FrameworkModuleDescriptorSnapshot(FrameworkModuleIdentity identity, Frame
8688 /// </summary>
8789 public int BoardId { get ; init ; }
8890
91+ /// <summary>
92+ /// Gets the physical input-deck position (Framework Laptop 16), or
93+ /// <see cref="FrameworkInputModulePosition.Unknown"/> for modules that are not input-deck-mounted.
94+ /// </summary>
95+ public FrameworkInputModulePosition Position { get ; init ; }
96+
8997 public override string ToString ( )
9098 {
91- return $ "Module Descriptor: Identity: { Identity } , Present: { IsPresent } , Slot Kind: { SlotKind } , Slot Index: { SlotIndex . ToString ( CultureInfo . InvariantCulture ) } , Bus: { Bus } , Confidence: { Confidence } , Flags: { Flags } , Vendor ID: 0x{ VendorId . ToString ( "X" , CultureInfo . InvariantCulture ) } , Product ID: 0x{ ProductId . ToString ( "X" , CultureInfo . InvariantCulture ) } , Board ID: { BoardId . ToString ( CultureInfo . InvariantCulture ) } ";
99+ return $ "Module Descriptor: Identity: { Identity } , Present: { IsPresent } , Slot Kind: { SlotKind } , Slot Index: { SlotIndex . ToString ( CultureInfo . InvariantCulture ) } , Position: { Position } , Bus: { Bus } , Confidence: { Confidence } , Flags: { Flags } , Vendor ID: 0x{ VendorId . ToString ( "X" , CultureInfo . InvariantCulture ) } , Product ID: 0x{ ProductId . ToString ( "X" , CultureInfo . InvariantCulture ) } , Board ID: { BoardId . ToString ( CultureInfo . InvariantCulture ) } ";
92100 }
93101}
0 commit comments