ui: rename block to macro

It is a more precise name.

Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
Elias Naur
2019-07-15 20:31:11 +02:00
parent f36070f716
commit 3b5fcfe2bb
10 changed files with 77 additions and 76 deletions
+7 -7
View File
@@ -6,8 +6,8 @@ type OpType byte
const firstOpIndex = 200
const (
TypeBlockDef OpType = iota + firstOpIndex
TypeBlock
TypeMacroDef OpType = iota + firstOpIndex
TypeMacro
TypeTransform
TypeLayer
TypeInvalidate
@@ -27,8 +27,8 @@ const (
)
const (
TypeBlockDefLen = 1 + 4 + 4
TypeBlockLen = 1 + 4 + 4 + 4
TypeMacroDefLen = 1 + 4 + 4
TypeMacroLen = 1 + 4 + 4 + 4
TypeTransformLen = 1 + 4*2
TypeLayerLen = 1
TypeRedrawLen = 1 + 8
@@ -49,8 +49,8 @@ const (
func (t OpType) Size() int {
return [...]int{
TypeBlockDefLen,
TypeBlockLen,
TypeMacroDefLen,
TypeMacroLen,
TypeTransformLen,
TypeLayerLen,
TypeRedrawLen,
@@ -72,7 +72,7 @@ func (t OpType) Size() int {
func (t OpType) NumRefs() int {
switch t {
case TypeBlock, TypeImage, TypeKeyHandler, TypePointerHandler, TypeProfile:
case TypeMacro, TypeImage, TypeKeyHandler, TypePointerHandler, TypeProfile:
return 1
default:
return 0