File: view.rb

package info (click to toggle)
ditz 0.5-1
  • links: PTS
  • area: main
  • in suites: squeeze, wheezy
  • size: 356 kB
  • ctags: 489
  • sloc: ruby: 3,664; sh: 15; makefile: 12
file content (16 lines) | stat: -rw-r--r-- 226 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
module Ditz

class View
  def self.add_to_view type, &block
    @views ||= {}
    @views[type] ||= []
    @views[type] << block
  end

  def self.view_additions_for type
    @views ||= {}
    @views[type] || []
  end
end

end