Sha256: a182e6a1198515e65e3ccc7b2f93fbebc84257c15098614fa37b71c25faa6958

Contents?: true

Size: 931 Bytes

Versions: 4

Compression:

Stored size: 931 Bytes

Contents

$: << File.dirname(__FILE__) unless $:.include?(File.dirname(__FILE__))
require 'haml'
require 'lolita'

module Lolita
  module Menu
    module Autocomplete
      autoload :LinkSet, "lolita-menu/autocomplete/link_set"
      autoload :FileBuilder, "lolita-menu/autocomplete/file_builder"
      autoload :Collector, "lolita-menu/autocomplete/collector"

      def self.generate_urls
        file = Lolita::Menu::Autocomplete::FileBuilder.input_file
        instance_eval(File.read(file),file)
      end
    end
    # took this from sitemap_generator
    Urls = (Class.new do
      def method_missing(*args, &block)
        (@link_set ||= reset!).send(*args, &block)
      end

      # Use a new LinkSet instance
      def reset!
        @link_set = Autocomplete::LinkSet.new
      end
    end).new
  end
end


require 'lolita-menu/module'
require 'lolita-menu/nested_tree'
require 'lolita-menu/rails'
#require 'lolita-menu/railtie'

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
lolita-menu-0.2.2 lib/lolita-menu.rb
lolita-menu-0.2.1 lib/lolita-menu.rb
lolita-menu-0.2.0 lib/lolita-menu.rb
lolita-menu-0.1.7 lib/lolita-menu.rb