summaryrefslogtreecommitdiff
path: root/stack.go
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-03-17 14:09:09 -0400
committerPietro Gagliardi <[email protected]>2014-03-17 14:09:09 -0400
commit0e8680c04f3b364352a57e686bc93d018c6140e3 (patch)
treefbbab88400e8a6060cb59180aa63f2d958b2af52 /stack.go
parentbdb26046b6e91b1cf1a3d752fc36edd059ee5a58 (diff)
Dumped the mutex locks from the other controls and elaborated/asked for help in the README.
Diffstat (limited to 'stack.go')
-rw-r--r--stack.go6
1 files changed, 0 insertions, 6 deletions
diff --git a/stack.go b/stack.go
index c6335ef..b37b935 100644
--- a/stack.go
+++ b/stack.go
@@ -78,9 +78,6 @@ func (s *Stack) make(window *sysData) error {
}
func (s *Stack) setRect(x int, y int, width int, height int, winheight int) error {
- s.lock.Lock()
- defer s.lock.Unlock()
-
var stretchywid, stretchyht int
if len(s.controls) == 0 { // do nothing if there's nothing to do
@@ -138,9 +135,6 @@ func (s *Stack) setRect(x int, y int, width int, height int, winheight int) erro
// The preferred size of a Stack is the sum of the preferred sizes of non-stretchy controls + (the number of stretchy controls * the largest preferred size among all stretchy controls).
func (s *Stack) preferredSize() (width int, height int) {
- s.lock.Lock()
- defer s.lock.Unlock()
-
max := func(a int, b int) int {
if a > b {
return a