Sha256: 7ed61caffd62554f7bc794dc7e046e8afc5c9934cd7c46f47ced942e2fd4fd68

Contents?: true

Size: 568 Bytes

Versions: 41

Compression:

Stored size: 568 Bytes

Contents

class Shoes
  class Mask
    def initialize app, &blk
      @app = app
      @parent = app.cslot
      @real = nil
      app.cslot.masked = true
      mask_block_call &blk
    end

    attr_reader :parent
    attr_accessor :contents, :real

    def clear &blk
      @real.clear
      @contents.each &:clear
      mask_block_call &blk
      Shoes.call_back_procs @app
    end

    def mask_block_call &blk
      @contents = []
      @app.cmask = self
      blk.call if blk
      @app.cmask = nil
      @contents.each &:hide
    end
  end
end

Version data entries

41 entries across 41 versions & 1 rubygems

Version Path
green_shoes-1.1.374 lib/shoes/mask.rb
green_shoes-1.1.373 lib/shoes/mask.rb
green_shoes-1.1.367 lib/shoes/mask.rb
green_shoes-1.1.366 lib/shoes/mask.rb
green_shoes-1.1.365 lib/shoes/mask.rb
green_shoes-1.1.364 lib/shoes/mask.rb
green_shoes-1.1.363 lib/shoes/mask.rb
green_shoes-1.1.362 lib/shoes/mask.rb
green_shoes-1.1.358 lib/shoes/mask.rb
green_shoes-1.1.357 lib/shoes/mask.rb
green_shoes-1.1.354 lib/shoes/mask.rb
green_shoes-1.1.348 lib/shoes/mask.rb
green_shoes-1.0.337 lib/shoes/mask.rb
green_shoes-1.0.331 lib/shoes/mask.rb
green_shoes-1.0.322 lib/shoes/mask.rb
green_shoes-1.0.320 lib/shoes/mask.rb
green_shoes-1.0.309 lib/shoes/mask.rb
green_shoes-1.0.303 lib/shoes/mask.rb
green_shoes-1.0.282 lib/shoes/mask.rb
green_shoes-1.0.273 lib/shoes/mask.rb