Updated to include Component with D port int list.

This commit is contained in:
Giorgos Vyronos 2022-03-14 14:56:53 +00:00
parent 64f5654fdc
commit f658ba9a59
3 changed files with 3 additions and 1 deletions

View file

@ -319,6 +319,7 @@ module CommonTypes
Y : int
H : int
W : int
D : int list
}
/// JSConnection mapped to F# record.

View file

@ -285,6 +285,7 @@ let createComponent (pos: XYPos) (comptype: ComponentType) (id:string) (label:st
Y = int (pos.Y - float h / 2.0)
H = h
W = w
D = [0]
}
createComponent' characteristics label

View file

@ -423,7 +423,7 @@ let viewSelectedComponent (model: ModelType.Model) dispatch : ReactElement =
dispatch (ReloadSelectedComponent model.LastUsedDialogWidth) // reload the new component
)
// Control when the namesPortRaw map can be accessed else return normal name of port
let allowedDescription = match comp.Type with | NbitsAdder _ | Decode4 | Register _ |DFF| RegisterE _ |DFFE| ROM1 _ |AsyncROM1 _ | RAM1 _ | AsyncRAM1 _ | Mux2 | Demux2 | NbitsXor _ | Custom _ -> true | _ -> false
let allowedDescription = match comp.Type with | Custom _ -> true | _ -> false
let ports =
sym.APortOffsetsMap
|> Map.toList