MCPcopy Index your code
hub / github.com/lxn/walk / SetVisible

Method SetVisible

tableviewcolumn.go:222–245  ·  view source on GitHub ↗

SetVisible sets if the column is visible.

(visible bool)

Source from the content-addressed store, hash-verified

220
221// SetVisible sets if the column is visible.
222func (tvc *TableViewColumn) SetVisible(visible bool) (err error) {
223 if visible == tvc.visible {
224 return nil
225 }
226
227 old := tvc.visible
228 defer func() {
229 if err != nil {
230 tvc.visible = old
231 }
232 }()
233
234 tvc.visible = visible
235
236 if tvc.tv == nil {
237 return nil
238 }
239
240 if visible {
241 return tvc.create()
242 }
243
244 return tvc.destroy()
245}
246
247// Frozen returns if the column is frozen.
248func (tvc *TableViewColumn) Frozen() bool {

Callers 1

CreateMethod · 0.95

Calls 2

createMethod · 0.95
destroyMethod · 0.95

Tested by

no test coverage detected