You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: decorations.go
    path of file: ./repos/caire/vendor/gioui.org/widget
    
    the code of the file until where you have to start completion: package widget

import (
	"fmt"
	"math/bits"

	"gioui.org/gesture"
	"gioui.org/io/system"
	"gioui.org/layout"
	"gioui.org/op/clip"
)

// Decorations handles the states of window decorations.
type Decorations struct {
	clicks []Clickable
	resize [8]struct {
		gesture.Hover
		gesture.Drag
	}
	actions   system.Action
	maximized bool
}

// LayoutMove lays out the widget that makes a window movable.
f
    
func (d *Decorations) Clickable(action system.Action) *Clickable {
	if bits.OnesCount(uint(action)) != 1 {
		panic(fmt.Errorf("not a single action"))
	}
	idx := bits.TrailingZeros(uint(action))
	if n := idx - len(d.clicks); n >= 0 {
		d.clicks = append(d.clicks, make([]Clickable, n+1)...)
	}
	click := &d.clicks[idx]
	if click.Clicked() {
		if action == system.ActionMaximize {
			if d.maximized {
				d.maximized = false
				d.actions |= system.ActionUnmaximize
			} else {
				d.maximized = true
				d.actions |= system.ActionMaximize
			}
		} else {
			d.actions |= action
		}
	}
	return click
}