From 5286dbbd51e18a404f2a42bb2bb68d9280b03b2c Mon Sep 17 00:00:00 2001 From: lrbalt Date: Sat, 24 May 2008 14:15:53 +0000 Subject: [PATCH 01/22] removed search box from menu bar as discussed on mailinglist git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@857 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/layouts/standard.html.erb | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/tracks/app/views/layouts/standard.html.erb b/tracks/app/views/layouts/standard.html.erb index 92e7bd1a..3c66fe1a 100644 --- a/tracks/app/views/layouts/standard.html.erb +++ b/tracks/app/views/layouts/standard.html.erb @@ -40,13 +40,7 @@ window.onload=function(){ page.select('body .todo_notes').each { |e| e.toggle } end -%> |  - <%= link_to "Logout (#{current_user.display_name}) »", logout_path %>
<% - form_tag({:controller => :search, :action => :results}, {:class => "inline-form"}) do %> -
<%= text_field_tag(:search, params[:search]) %> - - <% end %> + <%= link_to "Logout (#{current_user.display_name}) »", logout_path %> From e72d88585d9e73356b11894a3c7998039d0ab569 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Wed, 28 May 2008 09:29:46 +0000 Subject: [PATCH 02/22] removed some whitespace to reduce the download of the mobile view. git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@858 a4c988fc-2ded-0310-b66e-134b36920a42 --- .../app/views/contexts/_mobile_context.rhtml | 14 ++-- tracks/app/views/layouts/mobile.m.erb | 65 +++++++++---------- tracks/app/views/shared/_flash.rhtml | 10 ++- tracks/app/views/shared/_mobile_footer.rhtml | 4 +- tracks/app/views/todos/_mobile_actions.rhtml | 6 +- tracks/app/views/todos/_mobile_todo.rhtml | 38 +++++------ tracks/app/views/todos/index.m.erb | 2 +- 7 files changed, 64 insertions(+), 75 deletions(-) diff --git a/tracks/app/views/contexts/_mobile_context.rhtml b/tracks/app/views/contexts/_mobile_context.rhtml index f6a2a268..6510aeb4 100644 --- a/tracks/app/views/contexts/_mobile_context.rhtml +++ b/tracks/app/views/contexts/_mobile_context.rhtml @@ -4,11 +4,11 @@ if not @not_done.empty? # only show a context when there are actions in it - %> -

<%=mobile_context.name%>

- - <%= render :partial => "todos/mobile_todo", - :collection => @not_done, - :locals => { :parent_container_type => "context" }%> -
+ -%> +

<%=mobile_context.name%>

+ +<%= render :partial => "todos/mobile_todo", + :collection => @not_done, + :locals => { :parent_container_type => "context" }-%> +
<% end -%> \ No newline at end of file diff --git a/tracks/app/views/layouts/mobile.m.erb b/tracks/app/views/layouts/mobile.m.erb index 7902bd05..1be4d590 100644 --- a/tracks/app/views/layouts/mobile.m.erb +++ b/tracks/app/views/layouts/mobile.m.erb @@ -1,37 +1,32 @@ - - - - <%= stylesheet_link_tag "mobile" %> - <%= @page_title %> - - - <% if !(@new_mobile || @edit_mobile) - if !@prefs.nil? %> -

<%= @down_count %> <%= - user_time.strftime(@prefs.title_date_format) %>

- <%= (link_to("Add new action", formatted_new_todo_path(:m))+" | ") unless @new_mobile -%> - <%= (link_to("Home", formatted_todos_path(:m))+" | ") unless @home -%> - <%= (link_to("Contexts", formatted_contexts_path(:m))+" | ") %> - <%= (link_to("Projects", formatted_projects_path(:m))+" | ") %> - <%= (link_to("Starred", {:action => "tag", :controller => "todos", :id => "starred.m"})) -%> - <% end - end %> - <%= render_flash -%> -
- <%= yield %> -
- <% if !@prefs.nil? %> - <%= link_to "Logout", formatted_logout_path(:format => 'm') %> | - <%= (link_to("Add new action", formatted_new_todo_path(:m))+" | ") unless @new_mobile -%> - <%= (link_to("Home", formatted_todos_path(:m))+" | ") unless @home -%> - <%= (link_to("Contexts", formatted_contexts_path(:m))+" | ") %> - <%= (link_to("Projects", formatted_projects_path(:m))+" | ") %> - <%= (link_to("Starred", {:action => "tag", :controller => "todos", :id => "starred.m"})+" | ") -%> - <%= (link_to("Tickler", {:action => "index", :controller => "tickler.m"})+" | ") -%> - <%= (link_to("Feeds", {:action => "index", :controller => "feeds.m"})) %> - <% end %> - <%= render :partial => "shared/mobile_footer" %> - - + + + +<%= stylesheet_link_tag "mobile"%> +<%= @page_title %> + +<% if !(@new_mobile || @edit_mobile) + if !@prefs.nil? -%> +

<%= @down_count %> <%= + user_time.strftime(@prefs.title_date_format) -%>

+<%= (link_to("Add new action", formatted_new_todo_path(:m))+" | ") unless @new_mobile -%> +<%= (link_to("Home", formatted_todos_path(:m))+" | ") unless @home -%> +<%= (link_to("Contexts", formatted_contexts_path(:m))+" | ") -%> +<%= (link_to("Projects", formatted_projects_path(:m))+" | ") -%> +<%= (link_to("Starred", {:action => "tag", :controller => "todos", :id => "starred.m"})) -%> +<% end + end -%><%= render_flash -%> +
<%= yield -%> +
<% if !@prefs.nil? -%> +<%= (link_to("Logout", formatted_logout_path(:format => 'm')) +" | ") -%> +<%= (link_to("Add new action", formatted_new_todo_path(:m))+" | ") unless @new_mobile -%> +<%= (link_to("Home", formatted_todos_path(:m))+" | ") unless @home -%> +<%= (link_to("Contexts", formatted_contexts_path(:m))+" | ") -%> +<%= (link_to("Projects", formatted_projects_path(:m))+" | ") -%> +<%= (link_to("Starred", {:action => "tag", :controller => "todos", :id => "starred.m"})+" | ") -%> +<%= (link_to("Tickler", {:action => "index", :controller => "tickler.m"})+" | ") -%> +<%= (link_to("Feeds", {:action => "index", :controller => "feeds.m"})) -%> +<% end -%> +<%= render :partial => "shared/mobile_footer" -%> + \ No newline at end of file diff --git a/tracks/app/views/shared/_flash.rhtml b/tracks/app/views/shared/_flash.rhtml index 8e86733e..86f9fc2c 100644 --- a/tracks/app/views/shared/_flash.rhtml +++ b/tracks/app/views/shared/_flash.rhtml @@ -1,11 +1,9 @@
-<% if flash.empty? %> +<% if flash.empty? -%> -<% else %> +<% else -%> <% flash.each do |key,value| -%> -

- <%= value %> -

+

<%= value %>

<% end -%> -<% end %> +<% end -%>
\ No newline at end of file diff --git a/tracks/app/views/shared/_mobile_footer.rhtml b/tracks/app/views/shared/_mobile_footer.rhtml index 25b2b295..dca01d3d 100644 --- a/tracks/app/views/shared/_mobile_footer.rhtml +++ b/tracks/app/views/shared/_mobile_footer.rhtml @@ -1,3 +1 @@ - + \ No newline at end of file diff --git a/tracks/app/views/todos/_mobile_actions.rhtml b/tracks/app/views/todos/_mobile_actions.rhtml index 8c5c480f..861a981e 100644 --- a/tracks/app/views/todos/_mobile_actions.rhtml +++ b/tracks/app/views/todos/_mobile_actions.rhtml @@ -1,5 +1,5 @@ <% if @not_done_todos.empty? -%> -

There are no incomplete actions

+

There are no incomplete actions

<% else -%> - <%= render :partial => "contexts/mobile_context", :collection => @contexts_to_show %> -<% end -%> +<%= render :partial => "contexts/mobile_context", :collection => @contexts_to_show -%> +<% end -%> \ No newline at end of file diff --git a/tracks/app/views/todos/_mobile_todo.rhtml b/tracks/app/views/todos/_mobile_todo.rhtml index 43620bfc..6b8ebcaa 100644 --- a/tracks/app/views/todos/_mobile_todo.rhtml +++ b/tracks/app/views/todos/_mobile_todo.rhtml @@ -5,24 +5,22 @@ else bullet = "» " end -%>
- <%= bullet %> - <% if mobile_todo.completed? -%> - - <% else -%> - - <% end -%> - <%= date_span -%> - <%= link_to mobile_todo.description, formatted_todo_path(mobile_todo, :m) %> - <% if parent_container_type == 'context' or parent_container_type == 'tag' -%> - <%= "(" + - link_to(mobile_todo.project.name, formatted_project_path(mobile_todo.project, :m)) + - ")" unless mobile_todo.project.nil? %> - <% end +<%= bullet %><% + if mobile_todo.completed? +-%> +<% else +-%> +<% end -%> +<%= date_span -%><%= link_to mobile_todo.description, formatted_todo_path(mobile_todo, :m) -%> +<% if parent_container_type == 'context' or parent_container_type == 'tag' -%> +<%= " (" + + link_to(mobile_todo.project.name, formatted_project_path(mobile_todo.project, :m)) + + ")" unless mobile_todo.project.nil? -%> +<% end if parent_container_type == 'project' or parent_container_type == 'tag' -%> - <%= "(" + - link_to(mobile_todo.context.name, formatted_context_path(mobile_todo.context, :m)) + - ")" %> - <% end -%> - <%= tag_list_mobile %> - -
+<%= " (" + + link_to(mobile_todo.context.name, formatted_context_path(mobile_todo.context, :m)) + + ")" -%> +<% end -%> + <%= tag_list_mobile -%> + \ No newline at end of file diff --git a/tracks/app/views/todos/index.m.erb b/tracks/app/views/todos/index.m.erb index 92b55c5c..92e3f3f9 100644 --- a/tracks/app/views/todos/index.m.erb +++ b/tracks/app/views/todos/index.m.erb @@ -1 +1 @@ -<%= render :partial => 'mobile_actions' %> +<%= render :partial => 'mobile_actions' -%> \ No newline at end of file From 7936277455ddafa6844b2b08c237868c0276880b Mon Sep 17 00:00:00 2001 From: lrbalt Date: Wed, 28 May 2008 10:13:07 +0000 Subject: [PATCH 03/22] removed some more whitespace to reduce the download of the mobile view. git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@859 a4c988fc-2ded-0310-b66e-134b36920a42 --- .../contexts/_mobile_context_listing.rhtml | 4 +- tracks/app/views/contexts/index_mobile.rhtml | 8 +- tracks/app/views/feedlist/mobile_index.rhtml | 80 +++++++------------ .../projects/_mobile_project_listing.rhtml | 6 +- tracks/app/views/projects/index_mobile.rhtml | 14 ++-- tracks/app/views/todos/_mobile_todo.rhtml | 2 +- .../views/todos/mobile_list_deferred.rhtml | 3 +- tracks/app/views/todos/mobile_tag.rhtml | 45 +++++------ 8 files changed, 68 insertions(+), 94 deletions(-) diff --git a/tracks/app/views/contexts/_mobile_context_listing.rhtml b/tracks/app/views/contexts/_mobile_context_listing.rhtml index 6d792961..4f770186 100644 --- a/tracks/app/views/contexts/_mobile_context_listing.rhtml +++ b/tracks/app/views/contexts/_mobile_context_listing.rhtml @@ -1,2 +1,2 @@ -<% context = mobile_context_listing %> -
<%= link_to context.name, formatted_context_path(context, :m) %><%= " (" + count_undone_todos_phrase(context,"actions") + ")" %>
+<% context = mobile_context_listing -%> +
<%= link_to context.name, formatted_context_path(context, :m) %><%= " (" + count_undone_todos_phrase(context,"actions") + ")" %>
\ No newline at end of file diff --git a/tracks/app/views/contexts/index_mobile.rhtml b/tracks/app/views/contexts/index_mobile.rhtml index 35a1de9a..1edd16ed 100644 --- a/tracks/app/views/contexts/index_mobile.rhtml +++ b/tracks/app/views/contexts/index_mobile.rhtml @@ -1,6 +1,2 @@ -

Visible Contexts

-<%= render :partial => 'mobile_context_listing', :collection => @active_contexts%> - -

Hidden Contexts

-<%= render :partial => 'mobile_context_listing', :collection => @hidden_contexts %> - +

Visible Contexts

<%= render :partial => 'mobile_context_listing', :collection => @active_contexts %> +

Hidden Contexts

<%= render :partial => 'mobile_context_listing', :collection => @hidden_contexts %> \ No newline at end of file diff --git a/tracks/app/views/feedlist/mobile_index.rhtml b/tracks/app/views/feedlist/mobile_index.rhtml index a8511e75..b8c64398 100644 --- a/tracks/app/views/feedlist/mobile_index.rhtml +++ b/tracks/app/views/feedlist/mobile_index.rhtml @@ -1,50 +1,32 @@
    -
  • - <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :limit => 15 }) %> - <%= text_formatted_link({ :controller => 'todos', :action => 'index', :limit => 15 }) %> - <%= ical_formatted_link({ :controller => 'todos', :action => 'index', :limit => 15 }) %> - Last 15 actions -
  • -
  • - <%= rss_formatted_link( { :controller => 'todos', :action => 'index' } ) %> - <%= text_formatted_link( { :controller => 'todos', :action => 'index' } ) %> - <%= ical_formatted_link( { :controller => 'todos', :action => 'index' } ) %> - All actions -
  • -
  • - <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :due => 0 }) %> - <%= text_formatted_link({ :controller => 'todos', :action => 'index', :due => 0 }) %> - <%= ical_formatted_link({ :controller => 'todos', :action => 'index', :due => 0 }) %> - Actions due today or earlier -
  • -
  • - <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :due => 6 }) %> - <%= text_formatted_link({ :controller => 'todos', :action => 'index', :due => 6 }) %> - <%= ical_formatted_link({ :controller => 'todos', :action => 'index', :due => 6 }) %> - Actions due in 7 days or earlier -
  • -
  • - <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :done => 7 }) %> - <%= text_formatted_link({ :controller => 'todos', :action => 'index', :done => 7 }) %> - Actions completed in the last 7 days -
  • -
  • - <%= rss_formatted_link({:controller => 'contexts', :action => 'index'}) %> - <%= text_formatted_link({:controller => 'contexts', :action => 'index'}) %> - All Contexts -
  • -
  • - <%= rss_formatted_link({:controller => 'projects', :action => 'index'}) %> - <%= text_formatted_link({:controller => 'projects', :action => 'index'}) %> - All Projects -
  • -
  • - <%= rss_formatted_link({:controller => 'projects', :action => 'index', :only_active_with_no_next_actions => true}) %> - <%= text_formatted_link({:controller => 'projects', :action => 'index', :only_active_with_no_next_actions => true}) %> - Active projects with no next actions -
  • -
  • - <%= text_formatted_link({:controller => 'projects', :action => 'index', :projects_and_actions => true}) %> - Active projects with their actions -
  • -
+
  • <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :limit => 15 }) -%> + <%= text_formatted_link({ :controller => 'todos', :action => 'index', :limit => 15 }) -%> + <%= ical_formatted_link({ :controller => 'todos', :action => 'index', :limit => 15 }) -%> + Last 15 actions
  • +
  • <%= rss_formatted_link( { :controller => 'todos', :action => 'index' } ) -%> + <%= text_formatted_link( { :controller => 'todos', :action => 'index' } ) -%> + <%= ical_formatted_link( { :controller => 'todos', :action => 'index' } ) -%> + All actions
  • +
  • <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :due => 0 }) -%> + <%= text_formatted_link({ :controller => 'todos', :action => 'index', :due => 0 }) -%> + <%= ical_formatted_link({ :controller => 'todos', :action => 'index', :due => 0 }) -%> + Actions due today or earlier
  • +
  • <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :due => 6 }) -%> + <%= text_formatted_link({ :controller => 'todos', :action => 'index', :due => 6 }) -%> + <%= ical_formatted_link({ :controller => 'todos', :action => 'index', :due => 6 }) -%> + Actions due in 7 days or earlier
  • +
  • <%= rss_formatted_link({ :controller => 'todos', :action => 'index', :done => 7 }) -%> + <%= text_formatted_link({ :controller => 'todos', :action => 'index', :done => 7 }) -%> + Actions completed in the last 7 days
  • +
  • <%= rss_formatted_link({:controller => 'contexts', :action => 'index'}) -%> + <%= text_formatted_link({:controller => 'contexts', :action => 'index'}) -%> + All Contexts
  • +
  • <%= rss_formatted_link({:controller => 'projects', :action => 'index'}) -%> + <%= text_formatted_link({:controller => 'projects', :action => 'index'}) -%> + All Projects
  • +
  • <%= rss_formatted_link({:controller => 'projects', :action => 'index', :only_active_with_no_next_actions => true}) %> + <%= text_formatted_link({:controller => 'projects', :action => 'index', :only_active_with_no_next_actions => true}) %> + Active projects with no next actions
  • +
  • <%= text_formatted_link({:controller => 'projects', :action => 'index', :projects_and_actions => true}) %> + Active projects with their actions +
  • \ No newline at end of file diff --git a/tracks/app/views/projects/_mobile_project_listing.rhtml b/tracks/app/views/projects/_mobile_project_listing.rhtml index 4ea67a2c..803d2d8c 100644 --- a/tracks/app/views/projects/_mobile_project_listing.rhtml +++ b/tracks/app/views/projects/_mobile_project_listing.rhtml @@ -1,2 +1,4 @@ -<% project = mobile_project_listing %> -
    <%= link_to project.name, formatted_project_path(project) %><%= " (" + count_undone_todos_and_notes_phrase(project,"actions") + ")" %>
    +<% project = mobile_project_listing -%> +
    <%= + link_to project.name, formatted_project_path(project) + + " (" + count_undone_todos_and_notes_phrase(project,"actions") + ")" %>
    \ No newline at end of file diff --git a/tracks/app/views/projects/index_mobile.rhtml b/tracks/app/views/projects/index_mobile.rhtml index 3d7578cd..a33dce05 100644 --- a/tracks/app/views/projects/index_mobile.rhtml +++ b/tracks/app/views/projects/index_mobile.rhtml @@ -1,8 +1,6 @@ -

    Active projects

    -<%= render :partial => 'mobile_project_listing', :collection => @active_projects%> - -

    Hidden projects

    -<%= render :partial => 'mobile_project_listing', :collection => @hidden_projects %> - -

    Completed projects

    -<%= render :partial => 'mobile_project_listing', :collection => @completed_projects %> +

    Active projects

    <%= + render :partial => 'mobile_project_listing', :collection => @active_projects%> +

    Hidden projects

    <%= + render :partial => 'mobile_project_listing', :collection => @hidden_projects %> +

    Completed projects

    <%= + render :partial => 'mobile_project_listing', :collection => @completed_projects %> \ No newline at end of file diff --git a/tracks/app/views/todos/_mobile_todo.rhtml b/tracks/app/views/todos/_mobile_todo.rhtml index 6b8ebcaa..fafdd164 100644 --- a/tracks/app/views/todos/_mobile_todo.rhtml +++ b/tracks/app/views/todos/_mobile_todo.rhtml @@ -11,7 +11,7 @@ end -%> <% else -%> <% end -%> -<%= date_span -%><%= link_to mobile_todo.description, formatted_todo_path(mobile_todo, :m) -%> +<%= date_span -%> <%= link_to mobile_todo.description, formatted_todo_path(mobile_todo, :m) -%> <% if parent_container_type == 'context' or parent_container_type == 'tag' -%> <%= " (" + link_to(mobile_todo.project.name, formatted_project_path(mobile_todo.project, :m)) + diff --git a/tracks/app/views/todos/mobile_list_deferred.rhtml b/tracks/app/views/todos/mobile_list_deferred.rhtml index ebfcb4a9..4c04a2e3 100644 --- a/tracks/app/views/todos/mobile_list_deferred.rhtml +++ b/tracks/app/views/todos/mobile_list_deferred.rhtml @@ -1,6 +1,5 @@ <% if @count == 0 -%>

    Currently there are no deferred actions.

    <% end -%> - <%= render :partial => "contexts/mobile_context", :collection => @contexts, - :locals => { :collapsible => true } %> + :locals => { :collapsible => true } -%> \ No newline at end of file diff --git a/tracks/app/views/todos/mobile_tag.rhtml b/tracks/app/views/todos/mobile_tag.rhtml index 20dfe67c..0fb66f82 100644 --- a/tracks/app/views/todos/mobile_tag.rhtml +++ b/tracks/app/views/todos/mobile_tag.rhtml @@ -1,28 +1,25 @@
    -
    > -

    - No actions found -

    -

    Currently there are no incomplete actions with the tag '<%= @tag_name %>'

    -
    - - <%= render :partial => "contexts/mobile_context", :collection => @contexts_to_show %> - -

    Deferred actions with the tag <%= @tag_name %>

    - <% unless (@deferred.nil? or @deferred.size == 0) -%> - - <%= render :partial => "todos/mobile_todo", :collection => @deferred, :locals => { :parent_container_type => "tag" } %> -
    -<% else %> - No deferred actions with the tag <%= @tag_name %> +<% if @not_done_todos.empty? -%> +
    +

    No actions found

    +
    Currently there are no incomplete actions with the tag '<%= @tag_name %>'
    +
    <% end -%> - -

    Completed actions with the tag <%= @tag_name %>

    +<%= render :partial => "contexts/mobile_context", :collection => @contexts_to_show -%> +

    Deferred actions with the tag <%= @tag_name %>

    +<% unless (@deferred.nil? or @deferred.size == 0) -%> + +<%= render :partial => "todos/mobile_todo", :collection => @deferred, :locals => { :parent_container_type => "tag" } -%> +
    +<% else -%> +No deferred actions with the tag <%= @tag_name %> +<% end -%> +

    Completed actions with the tag <%= @tag_name %>

    <% unless (@done.nil? or @done.size == 0) -%> - - <%= render :partial => "todos/mobile_todo", :collection => @done, :locals => { :parent_container_type => "tag" } %> -
    -<% else %> - No completed actions with the tag <%= @tag_name %> + +<%= render :partial => "todos/mobile_todo", :collection => @done, :locals => { :parent_container_type => "tag" } %> +
    +<% else -%> +No completed actions with the tag <%= @tag_name %> <% end -%> -
    + \ No newline at end of file From 54841fd04463b901a039ef2a6b29db503ede1e69 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Wed, 28 May 2008 15:04:26 +0000 Subject: [PATCH 04/22] fixes #718. The link included the number of actions which resulted from last commit git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@860 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/projects/_mobile_project_listing.rhtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tracks/app/views/projects/_mobile_project_listing.rhtml b/tracks/app/views/projects/_mobile_project_listing.rhtml index 803d2d8c..167854bb 100644 --- a/tracks/app/views/projects/_mobile_project_listing.rhtml +++ b/tracks/app/views/projects/_mobile_project_listing.rhtml @@ -1,4 +1,4 @@ <% project = mobile_project_listing -%>
    <%= - link_to project.name, formatted_project_path(project) + + link_to(project.name, formatted_project_path(project)) + " (" + count_undone_todos_and_notes_phrase(project,"actions") + ")" %>
    \ No newline at end of file From f66d1d8da441b11241348e423506dfb2190dc462 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Sun, 1 Jun 2008 18:43:44 +0000 Subject: [PATCH 05/22] fixes #713. Adds behavior for edit/star/delete/check buttons of todo even if there is no todo to show. This makes sure that the behaviors are present when you add a new todo through AJAX. git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@861 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/helpers/todos_helper.rb | 48 ++++++++++++++++-------- tracks/app/views/contexts/_context.rhtml | 10 ++++- tracks/app/views/projects/_project.rhtml | 8 ++++ 3 files changed, 49 insertions(+), 17 deletions(-) diff --git a/tracks/app/helpers/todos_helper.rb b/tracks/app/helpers/todos_helper.rb index 7b9ca745..ec6fa272 100644 --- a/tracks/app/helpers/todos_helper.rb +++ b/tracks/app/helpers/todos_helper.rb @@ -22,55 +22,71 @@ module TodosHelper :prevent_default => true end - def remote_delete_icon + def set_behavior_for_delete_icon parameters = "_source_view=#{@source_view}" parameters += "&_tag_name=#{@tag_name}" if @source_view == 'tag' - str = link_to( image_tag_for_delete, - todo_path(@todo), :id => "delete_icon_"+@todo.id.to_s, - :class => "icon delete_icon", :title => "delete the action '#{@todo.description}'") apply_behavior '.item-container a.delete_icon:click', :prevent_default => true do |page| page.confirming "'Are you sure that you want to ' + this.title + '?'" do page << "itemContainer = this.up('.item-container'); itemContainer.startWaiting();" page << remote_to_href(:method => 'delete', :with => "'#{parameters}'", :complete => "itemContainer.stopWaiting();") - end + end end + end + + def remote_delete_icon + str = link_to( image_tag_for_delete, + todo_path(@todo), :id => "delete_icon_"+@todo.id.to_s, + :class => "icon delete_icon", :title => "delete the action '#{@todo.description}'") + set_behavior_for_delete_icon str end + def set_behavior_for_star_icon + apply_behavior '.item-container a.star_item:click', + remote_to_href(:method => 'put', :with => "{ _source_view : '#{@source_view}' }"), + :prevent_default => true + end + def remote_star_icon str = link_to( image_tag_for_star(@todo), toggle_star_todo_path(@todo), :class => "icon star_item", :title => "star the action '#{@todo.description}'") - apply_behavior '.item-container a.star_item:click', - remote_to_href(:method => 'put', :with => "{ _source_view : '#{@source_view}' }"), - :prevent_default => true + set_behavior_for_star_icon str end - def remote_edit_icon + def set_behavior_for_edit_icon parameters = "_source_view=#{@source_view}" parameters += "&_tag_name=#{@tag_name}" if @source_view == 'tag' + apply_behavior '.item-container a.edit_icon:click', :prevent_default => true do |page| + page << "Effect.Pulsate(this);" + page << remote_to_href(:method => 'get', :with => "'#{parameters}'") + end + end + + def remote_edit_icon if !@todo.completed? str = link_to( image_tag_for_edit, edit_todo_path(@todo), :class => "icon edit_icon") - apply_behavior '.item-container a.edit_icon:click', :prevent_default => true do |page| - page << "Effect.Pulsate(this);" - page << remote_to_href(:method => 'get', :with => "'#{parameters}'") - end + set_behavior_for_edit_icon else str = '' + image_tag("blank.png") + " " end str end - def remote_toggle_checkbox - str = check_box_tag('item_id', toggle_check_todo_path(@todo), @todo.completed?, :class => 'item-checkbox') + def set_behavior_for_toggle_checkbox parameters = "_source_view=#{@source_view}" parameters += "&_tag_name=#{@tag_name}" if @source_view == 'tag' apply_behavior '.item-container input.item-checkbox:click', remote_function(:url => javascript_variable('this.value'), :method => 'put', - :with => "'#{parameters}'") + :with => "'#{parameters}'") + end + + def remote_toggle_checkbox + str = check_box_tag('item_id', toggle_check_todo_path(@todo), @todo.completed?, :class => 'item-checkbox') + set_behavior_for_toggle_checkbox str end diff --git a/tracks/app/views/contexts/_context.rhtml b/tracks/app/views/contexts/_context.rhtml index 59809d23..0c26b469 100644 --- a/tracks/app/views/contexts/_context.rhtml +++ b/tracks/app/views/contexts/_context.rhtml @@ -31,6 +31,14 @@

    Currently there are no incomplete actions in this context

    -<%= render :partial => "todos/todo", :collection => @not_done, :locals => { :parent_container_type => "context" } %> + <%= render :partial => "todos/todo", :collection => @not_done, :locals => { :parent_container_type => "context" } %> + <% if @not_done.empty? + # fix (hack) for #713 + set_behavior_for_delete_icon + set_behavior_for_star_icon + set_behavior_for_edit_icon + set_behavior_for_toggle_checkbox + end + -%> diff --git a/tracks/app/views/projects/_project.rhtml b/tracks/app/views/projects/_project.rhtml index 14f36f9b..c2cd4036 100644 --- a/tracks/app/views/projects/_project.rhtml +++ b/tracks/app/views/projects/_project.rhtml @@ -22,5 +22,13 @@

    Currently there are no incomplete actions in this project

    <%= render :partial => "todos/todo", :collection => @not_done, :locals => { :parent_container_type => "project" } %> + <% if @not_done.empty? + # fix (hack) for #713 + set_behavior_for_delete_icon + set_behavior_for_star_icon + set_behavior_for_edit_icon + set_behavior_for_toggle_checkbox + end + -%> \ No newline at end of file From 8edcabf25e3758033fe499f44b2cf43246a861de Mon Sep 17 00:00:00 2001 From: lrbalt Date: Mon, 2 Jun 2008 08:21:03 +0000 Subject: [PATCH 06/22] prepares trunk for 1.6 release git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@862 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/README_FIRST | 4 ++-- tracks/config/environment.rb.tmpl | 8 +------- tracks/doc/CHANGELOG | 12 +++++++++--- tracks/doc/README_DEVELOPERS | 8 ++++++-- 4 files changed, 18 insertions(+), 14 deletions(-) diff --git a/tracks/README_FIRST b/tracks/README_FIRST index bbf1323f..dcc8f3ed 100644 --- a/tracks/README_FIRST +++ b/tracks/README_FIRST @@ -7,8 +7,8 @@ * Mailing list: http://lists.rousette.org.uk/mailman/listinfo/tracks-discuss * Original developer: bsag (http://www.rousette.org.uk/) * Contributors: http://dev.rousette.org.uk/wiki/Tracks/Contributing/Contributors -* Version: 1.5 -* Copyright: (cc) 2004-2006 rousette.org.uk. +* Version: 1.6 +* Copyright: (cc) 2004-2008 rousette.org.uk. * License: GNU GPL All the documentation for Tracks can be found within the /doc directory. It contains a manual in HTML (manual.html) or PDF format (manual.pdf), and this includes full instructions for both new installations and upgrades from older installations of Tracks. The instructions might appear long and intimidatingly complex, but that is mostly because of the number of different platforms supported, and the different configurations which can be used (e.g. running Tracks on your local computer or on a remote server). If you choose the appropriate section for your situation (installation vs. upgrade), and use the easiest (recommended) method, you should find the instructions easy to follow. If you encounter problems, try searching the wiki, forum or mailing list (URLs above), and ask a question if you cannot find a solution to your problem. diff --git a/tracks/config/environment.rb.tmpl b/tracks/config/environment.rb.tmpl index 745c83b7..e80b02db 100644 --- a/tracks/config/environment.rb.tmpl +++ b/tracks/config/environment.rb.tmpl @@ -98,10 +98,4 @@ end MOBILE_CONTENT_TYPE = 'tracks/mobile' Mime::Type.register(MOBILE_CONTENT_TYPE, :m) -tracks_version = '1.6-trunk' -info = `svn info #{RAILS_ROOT} --config-dir /etc/subversion`[/Last Changed Rev: (.*?)\n/] -if info - tracks_version += '-rev'+info[/(\d+)/] -end - -TRACKS_VERSION=tracks_version +TRACKS_VERSION='1.6' diff --git a/tracks/doc/CHANGELOG b/tracks/doc/CHANGELOG index 086543dc..ff31fb67 100644 --- a/tracks/doc/CHANGELOG +++ b/tracks/doc/CHANGELOG @@ -2,8 +2,8 @@ * Homepage: http://www.rousette.org.uk/projects/ * Author: bsag (http://www.rousette.org.uk/) -* Contributors: Nicholas Lee, Lolindrath, Jim Ray, Arnaud Limbourg, Timothy Martens, Luke Melia, John Leonard, Jim Strupp, Eric Lesh, Damien Cirotteau, Janet Riley, Reinier Balt, Jacqui Maher, James Kebinger -* Version: 1.5rc1 +* Contributors: Nicholas Lee, Lolindrath, Jim Ray, Arnaud Limbourg, Timothy Martens, Luke Melia, John Leonard, Jim Strupp, Eric Lesh, Damien Cirotteau, Janet Riley, Reinier Balt, Jacqui Maher, James Kebinger, Jeffrey Gipson +* Version: 1.6 * Copyright: (cc) 2004-2008 rousette.org.uk * License: GNU GPL @@ -13,7 +13,13 @@ Trac (for bug reports and feature requests): http://dev.rousette.org.uk/report/6 Wiki (deprecated - please use Trac): http://www.rousette.org.uk/projects/wiki/ -== Version 1.5rc1 +== Version 1.6 +1. upgrade to rails 2.0 +2. new mobile interface +3. new search functionality to search on todos, projects, contexts and notes +4. Bugfixes + +== Version 1.5 1. Show from date allows you to postpone the appearance of actions in the list until you can do something about them (like a 'tickler') 2. Tagging of actions 3. Simple management of users (deleting users through the web interface) diff --git a/tracks/doc/README_DEVELOPERS b/tracks/doc/README_DEVELOPERS index 2005ae3e..e8f9bde0 100644 --- a/tracks/doc/README_DEVELOPERS +++ b/tracks/doc/README_DEVELOPERS @@ -1,4 +1,8 @@ -1. SQLITE3 FOR TESTING +1. Wiki + +There are some pointers for setting up your Tracks copy for testing at http://dev.rousette.org.uk/wiki/Tracks/Testing + +2. SQLITE3 FOR TESTING By default, tests are configured to run using sqlite3 in memory mode to increase speed. You will need the sqlite3-ruby gem for this. @@ -8,7 +12,7 @@ To avoid showing the migrations as tests are run, add the following to your data If you want to run tests using another database, that's fine, too. Just change your database.yml accordingly. -2. SELENIUM TESTS +3. SELENIUM TESTS To run selenium tests, start Tracks in test mode using From d07d0c4f4d30b3dbf0d52c7669a533c0ba9badfc Mon Sep 17 00:00:00 2001 From: lrbalt Date: Tue, 3 Jun 2008 18:20:42 +0000 Subject: [PATCH 07/22] merges changes from tracks1.6 to trunk git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@866 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/README_FIRST | 2 + tracks/doc/CHANGELOG | 4 +- tracks/doc/manual.html | 70 +++++++++++++++++------------ tracks/doc/manual.markdown | 69 ++++++++++++++++------------ tracks/doc/manual.pdf | Bin 127175 -> 139328 bytes tracks/doc/manual.tex | 89 +++++++++++++++++++++++-------------- 6 files changed, 143 insertions(+), 91 deletions(-) diff --git a/tracks/README_FIRST b/tracks/README_FIRST index dcc8f3ed..ee67d7a4 100644 --- a/tracks/README_FIRST +++ b/tracks/README_FIRST @@ -11,6 +11,8 @@ * Copyright: (cc) 2004-2008 rousette.org.uk. * License: GNU GPL +**An important note for version 1.6: OpenID support is broken in this release. The fix isn't trivial because of changes to the `ruby-openid` gem, so we wanted to get this version out now and fix OpenID for the next release. If you depend on OpenID integration, we recommend waiting until the next release.** + All the documentation for Tracks can be found within the /doc directory. It contains a manual in HTML (manual.html) or PDF format (manual.pdf), and this includes full instructions for both new installations and upgrades from older installations of Tracks. The instructions might appear long and intimidatingly complex, but that is mostly because of the number of different platforms supported, and the different configurations which can be used (e.g. running Tracks on your local computer or on a remote server). If you choose the appropriate section for your situation (installation vs. upgrade), and use the easiest (recommended) method, you should find the instructions easy to follow. If you encounter problems, try searching the wiki, forum or mailing list (URLs above), and ask a question if you cannot find a solution to your problem. For those upgrading, change notes are available in /doc/CHANGELOG. If you are thinking about contributing towards the development of Tracks, please read /doc/README_DEVELOPERS for general information, or /doc/tracks_api_wrapper.rb for information on Tracks' API. diff --git a/tracks/doc/CHANGELOG b/tracks/doc/CHANGELOG index ff31fb67..1dd8e775 100644 --- a/tracks/doc/CHANGELOG +++ b/tracks/doc/CHANGELOG @@ -14,8 +14,8 @@ Trac (for bug reports and feature requests): http://dev.rousette.org.uk/report/6 Wiki (deprecated - please use Trac): http://www.rousette.org.uk/projects/wiki/ == Version 1.6 -1. upgrade to rails 2.0 -2. new mobile interface +1. upgrade to rails 2.0.2 +2. new mobile interface (with some iPhone compatibility fixes) 3. new search functionality to search on todos, projects, contexts and notes 4. Bugfixes diff --git a/tracks/doc/manual.html b/tracks/doc/manual.html index 8a3b4383..9e229608 100644 --- a/tracks/doc/manual.html +++ b/tracks/doc/manual.html @@ -14,22 +14,24 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" /> - - Tracks 1.5 Manual - + + Tracks 1.6 Manual + -

    Installing Tracks 1.5

    +

    Installing Tracks 1.6

    Introduction

    -

    Tracks 1.5 has been thoroughly beta tested by a large number of people, and should be fully stable for everyday use. However, once set up, Tracks will contain the majority of your plans for your work and personal life, so it’s only sensible to make sure that you have frequent, reliable backups of your data. Full changenotes on the release can be found in doc/CHANGELOG. Full API documentation can be found at doc/app/index.html, once you have run rake appdoc

    +

    An important note for version 1.6: OpenID support is broken in this release. The fix isn’t trivial because of changes to the ruby-openid gem, so we wanted to get this version out now and fix OpenID for the next release. If you depend on OpenID integration, we recommend waiting until the next release.

    -

    There are two methods of downloading Tracks 1.5 (N.B. These links will not work until Tracks 1.5 final is released)):

    +

    Tracks 1.6 has been thoroughly beta tested by a large number of people, and should be fully stable for everyday use. However, once set up, Tracks will contain the majority of your plans for your work and personal life, so it’s only sensible to make sure that you have frequent, reliable backups of your data. Full changenotes on the release can be found in doc/CHANGELOG. Full API documentation can be found at doc/app/index.html, once you have run rake appdoc

    + +

    There are two methods of downloading Tracks 1.6:

    1. (Recommended for most people) Download the zipped package, and unzip in your preferred location (e.g. ~/Sites for Mac OS X users).
    2. @@ -59,7 +61,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
      1. Tracks itself
      2. -
      3. Rails 1.2.5 (installed in the /vendor/rails directory, so you do not need to install Rails yourself)
      4. +
      5. Rails 2.0.2 (installed in the /vendor/rails directory, so you do not need to install Rails yourself)
      6. An empty SQLite3 database, set up with the correct database schema
      @@ -73,11 +75,11 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
    3. Database. The easiest option is to use SQLite3, as the database is included in the package. All you need then is the sqlite3-ruby gem, as described in step 2, and the SQLite3 libraries and binary (see sqlite.org for downloads and installation instructions). If you want to use MySQL, download and install a package for your platform from MySQL.com. The basic steps for Postgresql should be similar to those for MySQL, but they will not be discussed further here.
    -

    If you are using Unix, you might find this guide by c00i90wn helpful. It was written for Tracks 1.043, but it should work for Tracks 1.5.

    +

    If you are using Unix, you might find this guide by c00i90wn helpful. It was written for Tracks 1.043, but it should work for Tracks 1.6.

    Installation

    -

    This description is intended for people installing Tracks from scratch. If you would like to upgrade an existing installation, please see Upgrading to Tracks 1.5.

    +

    This description is intended for people installing Tracks from scratch. If you would like to upgrade an existing installation, please see Upgrading to Tracks 1.6.

    1. Unzip tracks and install in a directory
    2. @@ -85,7 +87,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
      1. SQLite3 - change database.yml to point to SQLite3 database
      2. MySQL - create new MySQL db and grant all privileges
    3. Configure some variables
    4. -
    5. Populate the database with the Tracks 1.5 schema
    6. +
    7. Populate the database with the Tracks 1.6 schema
    8. Start the server
    9. Visit Tracks in a browser
    10. Customise Tracks
    11. @@ -101,7 +103,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
      1. SQLite3. All you need to do is make sure that you point Tracks to the included SQLite3 database in /db in the next step, Configure variables.
      2. -
      3. MySQL. Once you have MySQL installed, you need to create a database to use with Tracks 1.5. Go into a terminal and issue the following commands:
      4. +
      5. MySQL. Once you have MySQL installed, you need to create a database to use with Tracks 1.6. Go into a terminal and issue the following commands:
      @@ -116,23 +118,23 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
       

      Configure variables

        -
      1. If you downloaded Tracks 1.5 via Subversion, you need to duplicate the files database.yml.tmpl and environment.yml.tmpl and remove the *.tmpl extension from the duplicates. Similarly, duplicate /log.tmpl and remove the *.tmpl extension, then edit the files as described in steps 2 and 3.
      2. +
      3. If you downloaded Tracks 1.6 via Subversion, you need to duplicate the files database.yml.tmpl and environment.yml.tmpl and remove the *.tmpl extension from the duplicates. Similarly, duplicate /log.tmpl and remove the *.tmpl extension, then edit the files as described in steps 2 and 3.
      4. Open the file /config/database.yml and edit the production: section with the details of your database. If you are using MySQL the adapter: line should read adapter: mysql, host: localhost (in the majority of cases), and your username and password should match those you assigned when you created the database. If you are using SQLite3, you should have only two lines under the production section: adapter: sqlite3 and database: db/tracks-15-blank.db. If you downloaded the zipped file, the database.yml file is already configured to use the provided SQLite3 file.
      5. Open the file /config/environment.rb, and read through the settings to make sure that they suit your setup. In most cases, all you need to change is the SALT = "change-me" line (change the string “change-me” to some other string of your choice), and the time zone setting.
      6. If you are using Windows, you may need to check the ‘shebang’ lines (#!/usr/bin/env ruby) of the /public/dispatch.* files and all the files in the /script directory. They are set to #!/usr/bin/env ruby by default. This should work for all *nix based setups (Linux or Mac OS X), but Windows users will probably have to change it to something like #c:/ruby/bin/ruby to point to the Ruby binary on your system.
      -

      Populate your database with the Tracks 1.5 schema

      +

      Populate your database with the Tracks 1.6 schema

      -

      Open a terminal and change into the root of your Tracks 1.5 directory. Enter the following command:

      +

      Open a terminal and change into the root of your Tracks 1.6 directory. Enter the following command:

      rake db:migrate RAILS_ENV=production

      -

      This will update your database with the required schema for Tracks 1.5. If you are using SQLite3, it is not strictly necessary, because the SQLite3 database included with Tracks already has the schema included in it, but it should not do any harm to run the command (nothing will happen if it is up to date).

      +

      This will update your database with the required schema for Tracks 1.6. If you are using SQLite3, it is not strictly necessary, because the SQLite3 database included with Tracks already has the schema included in it, but it should not do any harm to run the command (nothing will happen if it is up to date).

      Start the server

      -

      While still in the Terminal inside the Tracks 1.5 root directory, issue the following command:

      +

      While still in the Terminal inside the Tracks 1.6 root directory, issue the following command:

      script/server -e production

      @@ -146,7 +148,19 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />

      Once logged in, add some Contexts and Projects, and then go ahead and add your actions. You might also want to visit the Preferences page to edit various settings to your liking. Have fun!

      -

      Upgrading to Tracks 1.5

      +

      Upgrading to Tracks 1.6

      + +

      Upgrading from Tracks 1.5

      + +

      There are no changes to the database between 1.5 and 1.6, but you will need to upgrade your config/environment.rb with the new content from config/environment.rb.tmpl included in 1.6, as the format of this file has changed a great deal between 1.5 and 1.6.

      + +
        +
      1. Back up your existing database and installation of Tracks
      2. +
      3. Install Tracks 1.6 in a new directory
      4. +
      5. Copy over a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.6 directory
      6. +
      7. Run script/server inside your Tracks 1.6 directory to start up Tracks 1.6.
      8. +
      9. Once you are happy that everything is working well, delete your old Tracks directory.
      10. +

      Upgrading from Tracks 1.043

      @@ -154,10 +168,10 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
      1. Back up your existing database and installation of Tracks
      2. -
      3. Install Tracks 1.5 in a new directory
      4. -
      5. Copy over a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.5 directory
      6. +
      7. Install Tracks 1.6 in a new directory
      8. +
      9. Copy over a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.6 directory
      10. Run rake db:migrate RAILS_ENV=production to update your old database to the new schema – you did back up your database didn’t you?
      11. -
      12. Run script/server inside your Tracks 1.5 directory to start up Tracks 1.5.
      13. +
      14. Run script/server inside your Tracks 1.6 directory to start up Tracks 1.6.
      15. Once you are happy that everything is working well, delete your old Tracks directory.
      @@ -167,11 +181,11 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />

      mysqldump –-user [user name] –-password=[password] [database name] > [dump file]

      -

      Rename your old Tracks installation (e.g. to ‘tracks-old’) so that you can install Tracks 1.5 along side it.

      +

      Rename your old Tracks installation (e.g. to ‘tracks-old’) so that you can install Tracks 1.6 along side it.

      -

      Install Tracks 1.5

      +

      Install Tracks 1.6

      -

      There are two methods of downloading Tracks 1.5:

      +

      There are two methods of downloading Tracks 1.6:

      1. (Recommended for most people) Download the zipped package, and unzip in your preferred location (e.g. ~/Sites for Mac OS X users).
      2. @@ -191,7 +205,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
        1. Copy /config/database.yml from your old Tracks directory to the same location in the new one. Double check that the information there is still correct.
        2. -
        3. Duplicate /config/environment.rb.tmpl in the Tracks 1.5 directory, and rename the file to environment.rb. Open the file and alter the line SALT = "change-me" so that it matches what you had in this file in your old installation. You may also want to change the time zone setting as appropriate for your location (ENV['TZ'] = 'US/Eastern'). If you have made any other customisations to environment.rb in the past, copy those over, but the contents of the file have changed quite a lot since 1.043, so check it carefully.
        4. +
        5. Duplicate /config/environment.rb.tmpl in the Tracks 1.6 directory, and rename the file to environment.rb. Open the file and alter the line SALT = "change-me" so that it matches what you had in this file in your old installation. You may also want to change the time zone setting as appropriate for your location (ENV['TZ'] = 'US/Eastern'). If you have made any other customisations to environment.rb in the past, copy those over, but the contents of the file have changed quite a lot since 1.043, so check it carefully.
        6. Copy your /log directory over from your old installation to the root of the new one, or just rename /log.tmpl to log to start afresh.
        7. If you are using SQLite3, copy your database from /db in your old Tracks directory to the same location in the new one.
        8. If you are using Windows, you may need to check the ‘shebang’ lines (#!/usr/bin/env ruby)1 of the /public/dispatch.* files and all the files in the /script directory. They are set to #!/usr/bin/env ruby by default. Check the format of those lines in your old installation, and change the new ones as necessary.
        9. @@ -199,7 +213,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />

          Update your old database to the new format

          -

          In a terminal, change directories so that you are inside the Tracks 1.5 directory. Then issue the command to update your Tracks 1.043 database to the format required for Tracks 1.5:

          +

          In a terminal, change directories so that you are inside the Tracks 1.6 directory. Then issue the command to update your Tracks 1.043 database to the format required for Tracks 1.6:

          rake db:migrate RAILS_ENV=production

          @@ -207,7 +221,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />

          Start the server

          -

          If you’re still in the Tracks 1.5 root directory in a terminal, enter the following command to start up Tracks in production mode:

          +

          If you’re still in the Tracks 1.6 root directory in a terminal, enter the following command to start up Tracks in production mode:

          script/server -e production

          @@ -216,7 +230,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />

          Clean up your old installation

          -

          Once you’re certain that your new Tracks 1.5 installation is working perfectly, you can delete your old Tracks directory.

          +

          Once you’re certain that your new Tracks 1.6 installation is working perfectly, you can delete your old Tracks directory.

          Upgrading from versions prior to 1.043

          @@ -234,7 +248,7 @@ http://creativecommons.org/licenses/by-nc-sa/3.0/" />
        10. Run the command rake db_schema_import inside the Tracks directory. This should import the upgraded schema for 1.043 into your new database.
        11. Run the command rake load_exported_fixtures which will import the contents of your old database from the fixtures files in db/exported_fixtures.
        12. If you are using Windows, you may need to check the ‘shebang’ lines (#!/usr/bin/env ruby)2 of the /public/dispatch.* files and all the files in the /script directory. They are set to #!/usr/bin/env ruby by default. Check the format of those lines in your old installation, and change the new ones as necessary.
        13. -
        14. Try starting up the server with script/server to make sure that all your data has migrated successfully. If all is well, follow the instructions above to upgrade from version 1.043 to Tracks 1.5. If you need to access Tracks from a mobile/cellular phone browser, visit http://yourdomain.com/mobile/. This mobile version is a special, lightweight version of Tracks, designed to use on a mobile browser.
        15. +
        16. Try starting up the server with script/server to make sure that all your data has migrated successfully. If all is well, follow the instructions above to upgrade from version 1.043 to Tracks 1.6. If you need to access Tracks from a mobile/cellular phone browser, visit http://yourdomain.com/mobile/. This mobile version is a special, lightweight version of Tracks, designed to use on a mobile browser.
        diff --git a/tracks/doc/manual.markdown b/tracks/doc/manual.markdown index 2c375b69..9cfe855e 100644 --- a/tracks/doc/manual.markdown +++ b/tracks/doc/manual.markdown @@ -1,8 +1,8 @@ -Title: Tracks 1.5 Manual +Title: Tracks 1.6 Manual Author: Tracks Development Team Date: 2008-04-07 -Revision: $Id: manual.markdown 811 2008-04-07 20:21:00Z bsag $ -Version: 1.5 +Revision: $Id: manual.markdown 864 2008-06-03 17:01:00Z bsag $ +Version: 1.6 Copyright: 2008 rousette.org.uk This work is licensed under a Creative Commons License. http://creativecommons.org/licenses/by-nc-sa/3.0/ @@ -14,13 +14,15 @@ CSS: manual.css -# Installing Tracks 1.5 # +# Installing Tracks 1.6 # ## Introduction ## -Tracks 1.5 has been thoroughly beta tested by a large number of people, and should be fully stable for everyday use. However, once set up, Tracks will contain the majority of your plans for your work and personal life, so it's only sensible to make sure that you have frequent, reliable backups of your data. Full changenotes on the release can be found in `doc/CHANGELOG`. Full API documentation can be found at `doc/app/index.html`, once you have run `rake appdoc` +**An important note for version 1.6: OpenID support is broken in this release. The fix isn't trivial because of changes to the `ruby-openid` gem, so we wanted to get this version out now and fix OpenID for the next release. If you depend on OpenID integration, we recommend waiting until the next release.** -There are two methods of downloading Tracks 1.5 **(N.B. These links will not work until Tracks 1.5 final is released)**): +Tracks 1.6 has been thoroughly beta tested by a large number of people, and should be fully stable for everyday use. However, once set up, Tracks will contain the majority of your plans for your work and personal life, so it's only sensible to make sure that you have frequent, reliable backups of your data. Full changenotes on the release can be found in `doc/CHANGELOG`. Full API documentation can be found at `doc/app/index.html`, once you have run `rake appdoc` + +There are two methods of downloading Tracks 1.6: 1. (Recommended for most people) Download the [zipped package](http://www.rousette.org.uk/projects/files/tracks-current.zip), and unzip in your preferred location (e.g. `~/Sites` for Mac OS X users). 2. Download using Subversion: @@ -46,7 +48,7 @@ If you'd like an easy way to access Tracks from any internet-connected computer, ### What is included with the Tracks package ### 1. Tracks itself -2. Rails 1.2.5 (installed in the `/vendor/rails` directory, so you do not need to install Rails yourself) +2. Rails 2.0.2 (installed in the `/vendor/rails` directory, so you do not need to install Rails yourself) 3. An empty SQLite3 database, set up with the correct database schema ### What you need to install [whatyouneed] ### @@ -57,18 +59,18 @@ If you don't want to (or can't) use one of the all in one installations, you'll 2. **RubyGems**. The gems needed by Rails to interact with the database have to be compiled on the platform on which they will be run, so we cannot include them with the Tracks package, unlike some other gems. So you will need to [download](http://rubyforge.org/frs/?group_id=126) and install RubyGems (run `ruby setup.rb` after extracting the package). Note that once again, Mac OS X Leopard users get an easy life, because RubyGems and the SQLite3 gem is already installed. Once installed you can use RubyGems to install the gems you need for your database. If you are using SQLite3, run `sudo gem install sqlite3-ruby`, then select the appropriate package for your platform (version 1.2.1 recommended). You can use MySQL without installing a gem, but installing the gem can speed things up a bit: `sudo install gem mysql`. If you're using Leopard, there are a few work-arounds necessary, which are explained on [Mac OS Forge](http://trac.macosforge.org/projects/ruby/wiki/Troubleshooting#IcannotbuildrubymysqlonLeopardwithmysql.combinaries). The ruby-mysql bindings can sometimes be a bit troublesome to install, so to be honest, it's probably not worth the bother unless you are trying to wring maximum speed out of your system. If you are using PostgreSQL, then you can install a postgres gem: `gem install postgres`. 3. **Database**. The easiest option is to use SQLite3, as the database is included in the package. All you need then is the `sqlite3-ruby` gem, as described in step 2, and the SQLite3 libraries and binary (see [sqlite.org](http://sqlite.org/download.html) for downloads and installation instructions). If you want to use MySQL, download and install a package for your platform from [MySQL.com](http://dev.mysql.com/downloads/mysql/5.0.html). The basic steps for Postgresql should be similar to those for MySQL, but they will not be discussed further here. -If you are using Unix, you might find [this guide](http://www.cooldown.com.ar/2006/12/16/install-tracks-on-ubuntu-or-debian/) by c00i90wn helpful. It was written for Tracks 1.043, but it should work for Tracks 1.5. +If you are using Unix, you might find [this guide](http://www.cooldown.com.ar/2006/12/16/install-tracks-on-ubuntu-or-debian/) by c00i90wn helpful. It was written for Tracks 1.043, but it should work for Tracks 1.6. ## Installation ## -This description is intended for people installing Tracks from scratch. If you would like to upgrade an existing installation, please see [Upgrading to Tracks 1.5][upgrading]. +This description is intended for people installing Tracks from scratch. If you would like to upgrade an existing installation, please see [Upgrading to Tracks 1.6][upgrading]. 1. [Unzip tracks][unzip_install] and install in a directory 2. Decide on a [database][database_install] to use 1. SQLite3 - change database.yml to point to SQLite3 database 2. MySQL - create new MySQL db and grant all privileges 3. [Configure some variables][config_install] -4. Populate the database with the [Tracks 1.5 schema][rake_install] +4. Populate the database with the [Tracks 1.6 schema][rake_install] 5. [Start the server][startserver_install] 6. [Visit Tracks in a browser][signup_install] 7. [Customise Tracks][customise_install] @@ -82,7 +84,7 @@ Unzip the package and move Tracks into the directory you want to run it from. Fo Before you go any further, you need to decide which database you will use. See the [What you need to install][whatyouneed] section for details on installing the required components for you choice of database. 1. **SQLite3**. All you need to do is make sure that you point Tracks to the included SQLite3 database in `/db` in the next step, [Configure variables][config_install]. -2. **MySQL**. Once you have MySQL installed, you need to create a database to use with Tracks 1.5. Go into a terminal and issue the following commands: +2. **MySQL**. Once you have MySQL installed, you need to create a database to use with Tracks 1.6. Go into a terminal and issue the following commands:
         
             mysql -uroot -p
        @@ -94,22 +96,22 @@ Before you go any further, you need to decide which database you will use. See t
         
         ### Configure variables [config_install] ###
         
        -1. If you downloaded Tracks 1.5 via Subversion, you need to duplicate the files `database.yml.tmpl` and `environment.yml.tmpl` and remove the `*.tmpl` extension from the duplicates. Similarly, duplicate `/log.tmpl` and remove the `*.tmpl` extension, then edit the files as described in steps 2 and 3.
        +1. If you downloaded Tracks 1.6 via Subversion, you need to duplicate the files `database.yml.tmpl` and `environment.yml.tmpl` and remove the `*.tmpl` extension from the duplicates. Similarly, duplicate `/log.tmpl` and remove the `*.tmpl` extension, then edit the files as described in steps 2 and 3.
         2. Open the file `/config/database.yml` and edit the `production:` section with the details of your database. If you are using MySQL the `adapter:` line should read `adapter: mysql`, `host: localhost` (in the majority of cases), and your username and password should match those you assigned when you created the database. If you are using SQLite3, you should have only two lines under the production section: `adapter: sqlite3` and `database: db/tracks-15-blank.db`. If you downloaded the zipped file, the database.yml file is already configured to use the provided SQLite3 file.
         3. Open the file `/config/environment.rb`, and read through the settings to make sure that they suit your setup. In most cases, all you need to change is the `SALT = "change-me"` line (change the string "change-me" to some other string of your choice), and the time zone setting.
         4. If you are using Windows, you may need to check the 'shebang' lines (`#!/usr/bin/env ruby`) of the `/public/dispatch.*` files and all the files in the `/script` directory. They are set to `#!/usr/bin/env ruby` by default. This should work for all *nix based setups (Linux or Mac OS X), but Windows users will probably have to change it to something like `#c:/ruby/bin/ruby` to point to the Ruby binary on your system.
         
        -### Populate your database with the Tracks 1.5 schema [rake_install] ###
        +### Populate your database with the Tracks 1.6 schema [rake_install] ###
         
        -Open a terminal and change into the root of your Tracks 1.5 directory. Enter the following command:
        +Open a terminal and change into the root of your Tracks 1.6 directory. Enter the following command:
         
         `rake db:migrate RAILS_ENV=production`
         
        -This will update your database with the required schema for Tracks 1.5. If you are using SQLite3, it is not strictly necessary, because the SQLite3 database included with Tracks already has the schema included in it, but it should not do any harm to run the command (nothing will happen if it is up to date).
        +This will update your database with the required schema for Tracks 1.6. If you are using SQLite3, it is not strictly necessary, because the SQLite3 database included with Tracks already has the schema included in it, but it should not do any harm to run the command (nothing will happen if it is up to date).
         
         ### Start the server [startserver_install] ###
         
        -While still in the Terminal inside the Tracks 1.5 root directory, issue the following command:
        +While still in the Terminal inside the Tracks 1.6 root directory, issue the following command:
         
         `script/server -e production`
         
        @@ -123,17 +125,28 @@ Visit `http://0.0.0.0:3000/signup` in a browser (or whatever URL and port was re
         
         Once logged in, add some Contexts and Projects, and then go ahead and add your actions. You might also want to visit the Preferences page to edit various settings to your liking. Have fun!
         
        -# Upgrading to Tracks 1.5 [upgrading] #
        +# Upgrading to Tracks 1.6 [upgrading] #
        +
        +## Upgrading from Tracks 1.5 [upgrading_1.5] ##
        +
        +There are no changes to the database between 1.5 and 1.6, but you will need to upgrade your `config/environment.rb` with the new content from `config/environment.rb.tmpl` included in 1.6, as the format of this file has changed a great deal between 1.5 and 1.6.
        +
        +1. [Back up][backup_upgrade] your existing database and installation of Tracks
        +2. [Install Tracks 1.6][install_upgrade] in a new directory
        +3. [Copy over][config_upgrade] a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.6 directory
        +4. Run `script/server` inside your Tracks 1.6 directory to [start up Tracks 1.6][startserver_upgrade].
        +5. Once you are happy that everything is working well, [delete your old Tracks directory][cleanup_upgrade].
        +
         
         ## Upgrading from Tracks 1.043 [upgrading_1043] ##
         
         This should be a relatively straightforward, and involves the following main steps:
         
         1. [Back up][backup_upgrade] your existing database and installation of Tracks
        -2. [Install Tracks 1.5][install_upgrade] in a new directory
        -3. [Copy over][config_upgrade] a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.5 directory
        +2. [Install Tracks 1.6][install_upgrade] in a new directory
        +3. [Copy over][config_upgrade] a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.6 directory
         5. Run `rake db:migrate RAILS_ENV=production` to [update your old database][rake_upgrade] to the new schema -- you did back up your database didn't you?
        -6. Run `script/server` inside your Tracks 1.5 directory to [start up Tracks 1.5][startserver_upgrade].
        +6. Run `script/server` inside your Tracks 1.6 directory to [start up Tracks 1.6][startserver_upgrade].
         7. Once you are happy that everything is working well, [delete your old Tracks directory][cleanup_upgrade].
         
         ### Backing up [backup_upgrade] ###
        @@ -142,11 +155,11 @@ It's very important that you **back up your database** before you start the upgr
         
         `mysqldump –-user [user name] –-password=[password] [database name] > [dump file]`
         
        -Rename your old Tracks installation (e.g. to 'tracks-old') so that you can install Tracks 1.5 along side it.
        +Rename your old Tracks installation (e.g. to 'tracks-old') so that you can install Tracks 1.6 along side it.
         
        -### Install Tracks 1.5 [install_upgrade] ###
        +### Install Tracks 1.6 [install_upgrade] ###
         
        -There are two methods of downloading Tracks 1.5:
        +There are two methods of downloading Tracks 1.6:
         
         1. (Recommended for most people) Download the [zipped package](http://www.rousette.org.uk/projects/files/tracks-current.zip), and unzip in your preferred location (e.g. `~/Sites` for Mac OS X users).
         2. Download using Subversion:
        @@ -162,14 +175,14 @@ There are two methods of downloading Tracks 1.5:
         There are a few files you need to copy over from your old installation. If you copy them over rather than moving them, you can still run your old version of Tracks if anything goes awry with the installation process.
         
         1. Copy `/config/database.yml` from your old Tracks directory to the same location in the new one. Double check that the information there is still correct.
        -2. Duplicate `/config/environment.rb.tmpl` in the Tracks 1.5 directory, and rename the file to `environment.rb`. Open the file and alter the line `SALT = "change-me"` so that it matches what you had in this file in your old installation. You may also want to change the time zone setting as appropriate for your location (`ENV['TZ'] = 'US/Eastern'`). If you have made any other customisations to `environment.rb` in the past, copy those over, but the contents of the file have changed quite a lot since 1.043, so check it carefully.
        +2. Duplicate `/config/environment.rb.tmpl` in the Tracks 1.6 directory, and rename the file to `environment.rb`. Open the file and alter the line `SALT = "change-me"` so that it matches what you had in this file in your old installation. You may also want to change the time zone setting as appropriate for your location (`ENV['TZ'] = 'US/Eastern'`). If you have made any other customisations to `environment.rb` in the past, copy those over, but the contents of the file have changed quite a lot since 1.043, so check it carefully.
         3. Copy your `/log` directory over from your old installation to the root of the new one, or just rename `/log.tmpl` to `log` to start afresh.
         4. If you are using SQLite3, copy your database from `/db` in your old Tracks directory to the same location in the new one.
         5. If you are using Windows, you may need to check the 'shebang' lines (`#!/usr/bin/env ruby`)[^env] of the `/public/dispatch.*` files and all the files in the `/script` directory. They are set to `#!/usr/bin/env ruby` by default. Check the format of those lines in your old installation, and change the new ones as necessary.
         
         ### Update your old database to the new format [rake_upgrade] ###
         
        -In a terminal, change directories so that you are inside the Tracks 1.5 directory. Then issue the command to update your Tracks 1.043 database to the format required for Tracks 1.5:
        +In a terminal, change directories so that you are inside the Tracks 1.6 directory. Then issue the command to update your Tracks 1.043 database to the format required for Tracks 1.6:
         
         `rake db:migrate RAILS_ENV=production`
         
        @@ -177,7 +190,7 @@ Watch the output carefully for errors, but it should report at the end of the pr
         
         ### Start the server [startserver_upgrade] ###
         
        -If you're still in the Tracks 1.5 root directory in a terminal, enter the following command to start up Tracks in production mode:
        +If you're still in the Tracks 1.6 root directory in a terminal, enter the following command to start up Tracks in production mode:
         
         `script/server -e production`
         
        @@ -186,7 +199,7 @@ Visit the URL indicated by the output (e.g. `** Mongrel available at 0.0.0.0:300
         
         ### Clean up your old installation [cleanup_upgrade] ###
         
        -Once you're certain that your new Tracks 1.5 installation is working perfectly, you can delete your old Tracks directory.
        +Once you're certain that your new Tracks 1.6 installation is working perfectly, you can delete your old Tracks directory.
         
         [^env]: The `env` binary helps to locate other binaries, regardless of their location. If you don't have `env` installed, you'll need to change this line to point to the location of your Ruby binary.
         
        @@ -205,4 +218,4 @@ The best option for versions prior to 1.043 is to follow the instructions below
         9. Run the command `rake db_schema_import` inside the Tracks directory. This should import the upgraded schema for 1.043 into your new database.
         10. Run the command `rake load_exported_fixtures` which will import the contents of your old database from the fixtures files in `db/exported_fixtures`.
         11. If you are using Windows, you may need to check the 'shebang' lines (`#!/usr/bin/env ruby`)[^env] of the `/public/dispatch.*` files and all the files in the `/script` directory. They are set to `#!/usr/bin/env ruby` by default. Check the format of those lines in your old installation, and change the new ones as necessary.
        -12. Try starting up the server with `script/server` to make sure that all your data has migrated successfully. If all is well, follow the instructions above to [upgrade from version 1.043][upgrading_1043] to Tracks 1.5. If you need to access Tracks from a mobile/cellular phone browser, visit `http://yourdomain.com/mobile/`. This mobile version is a special, lightweight version of Tracks, designed to use on a mobile browser.
        \ No newline at end of file
        +12. Try starting up the server with `script/server` to make sure that all your data has migrated successfully. If all is well, follow the instructions above to [upgrade from version 1.043][upgrading_1043] to Tracks 1.6. If you need to access Tracks from a mobile/cellular phone browser, visit `http://yourdomain.com/mobile/`. This mobile version is a special, lightweight version of Tracks, designed to use on a mobile browser.
        \ No newline at end of file
        diff --git a/tracks/doc/manual.pdf b/tracks/doc/manual.pdf
        index 9153a77407792b6435954ccf062f9589702afccb..32a69dfcb7477e113ce956a1bdae23364b2ed647 100644
        GIT binary patch
        delta 62083
        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KkYU9i!uT;h9tdUM-34N)
        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O)sF
        zH-<}NHtAc4KKp0MuW3F};}$Ck(iv>x&{752rG3q@)OR_Xsf`(WBHOPCf4o{F))jsc
        zG^Ha!XuT
        z|D-PbE1WEnL2q~Q?WAu6kjP6mid&Q%g2%r2F&N%0O5dY8R0FTiek=g%N6AX%#OU?k
        zW@PYt0y+|96)zes&Fa!K}4I@A!>ttKpbP33N50CPkg
        zhMkgFC*+djCzG~Ijrn-7R9M
        zV~D=S%I(y|;3Qibyi0HGTtX&Du8p`^)Zdq#fQwSd
        zvnk}~D1|*WmlSIe94CkB2}!cOxtdtTx*@MZG5?It>G|467&RhqudZ5qvWY_&LxPED
        zbS$s}k-VJ_R*dbBmVYr=m%@CMXq{=HbhdNWxU*O7WJ$U6^KQ!%a;c6I@4j4@PQ=M;
        z2|Us*Nn1#w(T}Ak#8GeO-r2QjmPh7j%uk!ewtGto4%cYPLs^
        zWBKAO2IfX<2GOFA_iBm+zFBZGt|tm&68e(TIi*n7ZE+ha$%96fqi#Kx5xi_ex7Tb(
        zCUHl|p0W)eA7|JRo@RFJmMvhEanO9~0`hKYiNAr#Xwn;sYaNf5Vc3)sXShj}%|M

        F%PF*pQ8g$yvy*=uvq{#@6&XOPH5_AyBuGp-lo zVi+TExfGly9tbeg#E9UZjDF(fghg&i~9IdRTM+syatEBW?zJ^-n?=4&~IByEFnc#^d;PnIFNW zNyW-nJp^s7_zLRUGS`G0I?u?~Op#Hf_(gFL97|E* zeVJ#l$GLsf%p6{;zy3~5CHWwccYD%+G5b9`I72adIsyM4^MUXipQy!X1I%={a%AeI zFpYOFOqHLpjTZFRP_sYfhFs#Vk5=mlFJO7wwnu(hwAF`Vxwm((+!BIa4iWoIviXLa z+~TQfq&9gVda&98tsqu&jYM^QO(wiCRORxh+&jmgfnlcj+EU#)RFkHj+~(iDo!oB_ zXGA+{O?nnjIds;Y5Z_7lecFS$!r(iriw}MKl3Tf)HsF||P8nb7D5LnHacHb$H?up7 z0ENX`QRndxl04hz>9GZ#&ZZqfnJ10H+V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er8eC6S<8S{foG zdf`C8Si{?}Q(!PSI%me93DA`q)r1(ZSJ0~!Nf+$FlF&IZa2x8}8PY!h(uQLwX@KsN zsRP!A^H=)4{HI`mS41`ldG zN(&>AR;6?kf*qI^Mg#$t4u+!5I6zi|r^zmW{xRTGNk14z zI~a)}fuk5Lk^hm%VMt)7rojVUP3Zy_I4lrwWLiYBB0?8jV%B?5{^b&Ad3dKW3*#QAkv7g#=rkdo&X}2HuwM- z{(lUnI}rdp5^Y=nZ#Pz7RZuYvuBoAWlQkH5{b~bj{Iu%{1`}zc8Gw;!6K?Rrgf3eF zu+0mTT8b}Q!avuq;t&PDDkr-_(UIVAI52cA!75)E5IWDTI%I@cH Z=j$Kj>*UN1cmScComoms+enA~{{fNurhfnc diff --git a/tracks/doc/manual.tex b/tracks/doc/manual.tex index 59e6880b..ab9aae0e 100644 --- a/tracks/doc/manual.tex +++ b/tracks/doc/manual.tex @@ -112,11 +112,11 @@ \usepackage{booktabs} % Better tables \usepackage{tabulary} % Support longer table cells \usepackage[utf8]{inputenc} % For UTF-8 support -% \usepackage{xcolor} % Allow for color (annotations) +%\usepackage{xcolor} % Allow for color (annotations) %\geometry{landscape} % Activate for rotated page geometry -% \usepackage[parfill]{parskip} % Activate to begin paragraphs with an empty +%\usepackage[parfill]{parskip} % Activate to begin paragraphs with an empty % line rather than an indent @@ -133,11 +133,11 @@ \date{2008-04-07} \def\format{complete} \def\latexxslt{memoir-twosided-manual.xslt} -\def\revision{Revision: \$Id: manual.markdown 811 2008-04-07 20:21:00Z bsag \$} -\def\mytitle{Tracks 1.5 Manual} -\def\version{1.5} -\usepackage{xmpincl} -\includexmp{CCAttributionShareAlike} +\def\revision{Revision: \$Id: manual.markdown 864 2008-06-03 17:01:00Z bsag \$} +\def\mytitle{Tracks 1.6 Manual} +\def\version{1.6} +%%\usepackage{xmpincl} +%%\includexmp{CCAttributionShareAlike} % @@ -254,16 +254,19 @@ \setlength{\parskip}{\baselineskip/2} \mainmatter -\chapter{Installing Tracks 1.5} -\label{installingtracks1.5} +\chapter{Installing Tracks 1.6} +\label{installingtracks1.6} \section{Introduction} \label{introduction} -Tracks 1.5 has been thoroughly beta tested by a large number of people, and should be fully stable for everyday use. However, once set up, Tracks will contain the majority of your plans for your work and personal life, so it's only sensible to make sure that you have frequent, reliable backups of your data. Full changenotes on the release can be found in \texttt{doc/CHANGELOG}. Full API documentation can be found at \texttt{doc/app/index.html}, once you have run \texttt{rake appdoc} +\textbf{An important note for version 1.6: OpenID support is broken in this release. The fix isn't trivial because of changes to the \texttt{ruby-openid} gem, so we wanted to get this version out now and fix OpenID for the next release. If you depend on OpenID integration, we recommend waiting until the next release.} -There are two methods of downloading Tracks 1.5 \textbf{(N.B. These links will not work until Tracks 1.5 final is released)}): +Tracks 1.6 has been thoroughly beta tested by a large number of people, and should be fully stable for everyday use. However, once set up, Tracks will contain the majority of your plans for your work and personal life, so it's only sensible to make sure that you have frequent, reliable backups of your data. Full changenotes on the release can be found in \texttt{doc/CHANGELOG}. Full API documentation can be found at \texttt{doc/app/index.html}, once you have run \texttt{rake appdoc} + + +There are two methods of downloading Tracks 1.6: \begin{enumerate} @@ -311,7 +314,7 @@ If you'd like an easy way to access Tracks from any internet-connected computer, \item Tracks itself -\item Rails 1.2.5 (installed in the \texttt{/vendor/rails} directory, so you do not need to install Rails yourself) +\item Rails 2.0.2 (installed in the \texttt{/vendor/rails} directory, so you do not need to install Rails yourself) \item An empty SQLite3 database, set up with the correct database schema \end{enumerate} @@ -332,13 +335,13 @@ If you don't want to (or can't) use one of the all in one installations, you'll \item \textbf{Database}. The easiest option is to use SQLite3, as the database is included in the package. All you need then is the \texttt{sqlite3-ruby} gem, as described in step 2, and the SQLite3 libraries and binary (see \href{http://sqlite.org/download.html}{sqlite.org} for downloads and installation instructions). If you want to use MySQL, download and install a package for your platform from \href{http://dev.mysql.com/downloads/mysql/5.0.html}{MySQL.com}. The basic steps for Postgresql should be similar to those for MySQL, but they will not be discussed further here. \end{enumerate} -If you are using Unix, you might find \href{http://www.cooldown.com.ar/2006/12/16/install-tracks-on-ubuntu-or-debian/}{this guide} by c00i90wn helpful. It was written for Tracks 1.043, but it should work for Tracks 1.5. +If you are using Unix, you might find \href{http://www.cooldown.com.ar/2006/12/16/install-tracks-on-ubuntu-or-debian/}{this guide} by c00i90wn helpful. It was written for Tracks 1.043, but it should work for Tracks 1.6. \section{Installation} \label{installation} -This description is intended for people installing Tracks from scratch. If you would like to upgrade an existing installation, please see Upgrading to Tracks 1.5 (\autoref{upgrading}). +This description is intended for people installing Tracks from scratch. If you would like to upgrade an existing installation, please see Upgrading to Tracks 1.6 (\autoref{upgrading}). \begin{enumerate} @@ -359,7 +362,7 @@ This description is intended for people installing Tracks from scratch. If you w \item Configure some variables (\autoref{config_install}) -\item Populate the database with the Tracks 1.5 schema (\autoref{rake_install}) +\item Populate the database with the Tracks 1.6 schema (\autoref{rake_install}) \item Start the server (\autoref{startserver_install}) @@ -385,7 +388,7 @@ Before you go any further, you need to decide which database you will use. See t \item \textbf{SQLite3}. All you need to do is make sure that you point Tracks to the included SQLite3 database in \texttt{/db} in the next step, Configure variables (\autoref{config_install}). -\item \textbf{MySQL}. Once you have MySQL installed, you need to create a database to use with Tracks 1.5. Go into a terminal and issue the following commands: +\item \textbf{MySQL}. Once you have MySQL installed, you need to create a database to use with Tracks 1.6. Go into a terminal and issue the following commands: \end{enumerate} \begin{adjustwidth}{2.5em}{2.5em} @@ -407,7 +410,7 @@ Before you go any further, you need to decide which database you will use. See t \begin{enumerate} -\item If you downloaded Tracks 1.5 via Subversion, you need to duplicate the files \texttt{database.yml.tmpl} and \texttt{environment.yml.tmpl} and remove the \texttt{*.tmpl} extension from the duplicates. Similarly, duplicate \texttt{/log.tmpl} and remove the \texttt{*.tmpl} extension, then edit the files as described in steps 2 and 3. +\item If you downloaded Tracks 1.6 via Subversion, you need to duplicate the files \texttt{database.yml.tmpl} and \texttt{environment.yml.tmpl} and remove the \texttt{*.tmpl} extension from the duplicates. Similarly, duplicate \texttt{/log.tmpl} and remove the \texttt{*.tmpl} extension, then edit the files as described in steps 2 and 3. \item Open the file \texttt{/config/database.yml} and edit the \texttt{production:} section with the details of your database. If you are using MySQL the \texttt{adapter:} line should read \texttt{adapter: mysql}, \texttt{host: localhost} (in the majority of cases), and your username and password should match those you assigned when you created the database. If you are using SQLite3, you should have only two lines under the production section: \texttt{adapter: sqlite3} and \texttt{database: db/tracks-15-blank.db}. If you downloaded the zipped file, the database.yml file is already configured to use the provided SQLite3 file. @@ -416,22 +419,22 @@ Before you go any further, you need to decide which database you will use. See t \item If you are using Windows, you may need to check the `shebang' lines (\texttt{\#!/usr/bin/env ruby}) of the \texttt{/public/dispatch.*} files and all the files in the \texttt{/script} directory. They are set to \texttt{\#!/usr/bin/env ruby} by default. This should work for all *nix based setups (Linux or Mac OS X), but Windows users will probably have to change it to something like \texttt{\#c:/ruby/bin/ruby} to point to the Ruby binary on your system. \end{enumerate} -\subsection{Populate your database with the Tracks 1.5 schema} +\subsection{Populate your database with the Tracks 1.6 schema} \label{rake_install} -Open a terminal and change into the root of your Tracks 1.5 directory. Enter the following command: +Open a terminal and change into the root of your Tracks 1.6 directory. Enter the following command: \texttt{rake db:migrate RAILS\_ENV=production} -This will update your database with the required schema for Tracks 1.5. If you are using SQLite3, it is not strictly necessary, because the SQLite3 database included with Tracks already has the schema included in it, but it should not do any harm to run the command (nothing will happen if it is up to date). +This will update your database with the required schema for Tracks 1.6. If you are using SQLite3, it is not strictly necessary, because the SQLite3 database included with Tracks already has the schema included in it, but it should not do any harm to run the command (nothing will happen if it is up to date). \subsection{Start the server} \label{startserver_install} -While still in the Terminal inside the Tracks 1.5 root directory, issue the following command: +While still in the Terminal inside the Tracks 1.6 root directory, issue the following command: \texttt{script/server -e production} @@ -452,9 +455,29 @@ Visit \texttt{http://0.0.0.0:3000/signup} in a browser (or whatever URL and port Once logged in, add some Contexts and Projects, and then go ahead and add your actions. You might also want to visit the Preferences page to edit various settings to your liking. Have fun! -\chapter{Upgrading to Tracks 1.5} +\chapter{Upgrading to Tracks 1.6} \label{upgrading} +\section{Upgrading from Tracks 1.5} +\label{upgrading_1.5} + +There are no changes to the database between 1.5 and 1.6, but you will need to upgrade your \texttt{config/environment.rb} with the new content from \texttt{config/environment.rb.tmpl} included in 1.6, as the format of this file has changed a great deal between 1.5 and 1.6. + + +\begin{enumerate} + + +\item Back up (\autoref{backup_upgrade}) your existing database and installation of Tracks + +\item Install Tracks 1.6 (\autoref{install_upgrade}) in a new directory + +\item Copy over (\autoref{config_upgrade}) a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.6 directory + +\item Run \texttt{script/server} inside your Tracks 1.6 directory to start up Tracks 1.6 (\autoref{startserver_upgrade}). + +\item Once you are happy that everything is working well, delete your old Tracks directory (\autoref{cleanup_upgrade}). +\end{enumerate} + \section{Upgrading from Tracks 1.043} \label{upgrading_1043} @@ -466,13 +489,13 @@ This should be a relatively straightforward, and involves the following main ste \item Back up (\autoref{backup_upgrade}) your existing database and installation of Tracks -\item Install Tracks 1.5 (\autoref{install_upgrade}) in a new directory +\item Install Tracks 1.6 (\autoref{install_upgrade}) in a new directory -\item Copy over (\autoref{config_upgrade}) a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.5 directory +\item Copy over (\autoref{config_upgrade}) a few configuration files from your Tracks 1.043 directory. If using SQLite3, copy the old database into the new Tracks 1.6 directory \item Run \texttt{rake db:migrate RAILS\_ENV=production} to update your old database (\autoref{rake_upgrade}) to the new schema -- you did back up your database didn't you? -\item Run \texttt{script/server} inside your Tracks 1.5 directory to start up Tracks 1.5 (\autoref{startserver_upgrade}). +\item Run \texttt{script/server} inside your Tracks 1.6 directory to start up Tracks 1.6 (\autoref{startserver_upgrade}). \item Once you are happy that everything is working well, delete your old Tracks directory (\autoref{cleanup_upgrade}). \end{enumerate} @@ -486,13 +509,13 @@ It's very important that you \textbf{back up your database} before you start the \texttt{mysqldump ---user [user name] ---password=[password] [database name] $>$ [dump file]} -Rename your old Tracks installation (e.g.\ to `tracks-old') so that you can install Tracks 1.5 along side it. +Rename your old Tracks installation (e.g.\ to `tracks-old') so that you can install Tracks 1.6 along side it. -\subsection{Install Tracks 1.5} +\subsection{Install Tracks 1.6} \label{install_upgrade} -There are two methods of downloading Tracks 1.5: +There are two methods of downloading Tracks 1.6: \begin{enumerate} @@ -525,7 +548,7 @@ There are a few files you need to copy over from your old installation. If you c \item Copy \texttt{/config/database.yml} from your old Tracks directory to the same location in the new one. Double check that the information there is still correct. -\item Duplicate \texttt{/config/environment.rb.tmpl} in the Tracks 1.5 directory, and rename the file to \texttt{environment.rb}. Open the file and alter the line \texttt{SALT = "change-me"} so that it matches what you had in this file in your old installation. You may also want to change the time zone setting as appropriate for your location (\texttt{ENV['TZ'] = 'US/Eastern'}). If you have made any other customisations to \texttt{environment.rb} in the past, copy those over, but the contents of the file have changed quite a lot since 1.043, so check it carefully. +\item Duplicate \texttt{/config/environment.rb.tmpl} in the Tracks 1.6 directory, and rename the file to \texttt{environment.rb}. Open the file and alter the line \texttt{SALT = "change-me"} so that it matches what you had in this file in your old installation. You may also want to change the time zone setting as appropriate for your location (\texttt{ENV['TZ'] = 'US/Eastern'}). If you have made any other customisations to \texttt{environment.rb} in the past, copy those over, but the contents of the file have changed quite a lot since 1.043, so check it carefully. \item Copy your \texttt{/log} directory over from your old installation to the root of the new one, or just rename \texttt{/log.tmpl} to \texttt{log} to start afresh. @@ -537,7 +560,7 @@ There are a few files you need to copy over from your old installation. If you c \subsection{Update your old database to the new format} \label{rake_upgrade} -In a terminal, change directories so that you are inside the Tracks 1.5 directory. Then issue the command to update your Tracks 1.043 database to the format required for Tracks 1.5: +In a terminal, change directories so that you are inside the Tracks 1.6 directory. Then issue the command to update your Tracks 1.043 database to the format required for Tracks 1.6: \texttt{rake db:migrate RAILS\_ENV=production} @@ -549,7 +572,7 @@ Watch the output carefully for errors, but it should report at the end of the pr \subsection{Start the server} \label{startserver_upgrade} -If you're still in the Tracks 1.5 root directory in a terminal, enter the following command to start up Tracks in production mode: +If you're still in the Tracks 1.6 root directory in a terminal, enter the following command to start up Tracks in production mode: \texttt{script/server -e production} @@ -562,7 +585,7 @@ Visit the URL indicated by the output (e.g.\ \texttt{** Mongrel available at 0.0 \subsection{Clean up your old installation} \label{cleanup_upgrade} -Once you're certain that your new Tracks 1.5 installation is working perfectly, you can delete your old Tracks directory. +Once you're certain that your new Tracks 1.6 installation is working perfectly, you can delete your old Tracks directory. \section{Upgrading from versions prior to 1.043} @@ -596,7 +619,7 @@ The best option for versions prior to 1.043 is to follow the instructions below \item If you are using Windows, you may need to check the `shebang' lines (\texttt{\#!/usr/bin/env ruby})\footnote{The \texttt{env} binary helps to locate other binaries, regardless of their location. If you don't have \texttt{env} installed, you'll need to change this line to point to the location of your Ruby binary.The \texttt{env} binary helps to locate other binaries, regardless of their location. If you don't have \texttt{env} installed, you'll need to change this line to point to the location of your Ruby binary.} of the \texttt{/public/dispatch.*} files and all the files in the \texttt{/script} directory. They are set to \texttt{\#!/usr/bin/env ruby} by default. Check the format of those lines in your old installation, and change the new ones as necessary. -\item Try starting up the server with \texttt{script/server} to make sure that all your data has migrated successfully. If all is well, follow the instructions above to upgrade from version 1.043 (\autoref{upgrading_1043}) to Tracks 1.5. If you need to access Tracks from a mobile/cellular phone browser, visit \texttt{http://yourdomain.com/mobile/}. This mobile version is a special, lightweight version of Tracks, designed to use on a mobile browser. +\item Try starting up the server with \texttt{script/server} to make sure that all your data has migrated successfully. If all is well, follow the instructions above to upgrade from version 1.043 (\autoref{upgrading_1043}) to Tracks 1.6. If you need to access Tracks from a mobile/cellular phone browser, visit \texttt{http://yourdomain.com/mobile/}. This mobile version is a special, lightweight version of Tracks, designed to use on a mobile browser. \end{enumerate} % From b83a3b311c212a42fc747d5a766fcaca34fe0292 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Thu, 5 Jun 2008 06:59:09 +0000 Subject: [PATCH 08/22] fixes #726. Thanks Eric Pallen for the fix. The mobile view showed active todos from completed projects while the home page does not. git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@867 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/controllers/todos_controller.rb | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tracks/app/controllers/todos_controller.rb b/tracks/app/controllers/todos_controller.rb index a334e189..89fe11a4 100644 --- a/tracks/app/controllers/todos_controller.rb +++ b/tracks/app/controllers/todos_controller.rb @@ -461,7 +461,11 @@ class TodosController < ApplicationController @todos = Todo.find(:all, :conditions => ['todos.user_id = ?', current_user.id], :include => [ :project, :context, :tags ]) # Exclude hidden projects from the home page - @not_done_todos = Todo.find(:all, :conditions => ['todos.user_id = ? AND contexts.hide = ? AND (projects.state = ? OR todos.project_id IS NULL)', current_user.id, false, 'active'], :order => "todos.due IS NULL, todos.due ASC, todos.created_at ASC", :include => [ :project, :context, :tags ]) + @not_done_todos = Todo.find(:all, + :conditions => ['todos.user_id = ? AND contexts.hide = ? AND (projects.state = ? OR todos.project_id IS NULL)', + current_user.id, false, 'active'], + :order => "todos.due IS NULL, todos.due ASC, todos.created_at ASC", + :include => [ :project, :context, :tags ]) end end @@ -475,8 +479,8 @@ class TodosController < ApplicationController # Exclude hidden projects from the home page @not_done_todos = Todo.find(:all, - :conditions => ['todos.user_id = ? AND todos.state = ? AND contexts.hide = ?', - current_user.id, 'active', false], + :conditions => ['todos.user_id = ? AND todos.state = ? AND contexts.hide = ? AND (projects.state = ? OR todos.project_id IS NULL)', + current_user.id, 'active', false, 'active'], :order => "todos.due IS NULL, todos.due ASC, todos.created_at ASC", :include => [ :project, :context ]) end From 549d5e7a97c955ccb948563f7b5a8a7002b34184 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Thu, 5 Jun 2008 11:43:56 +0000 Subject: [PATCH 09/22] fixed small problem where updating a todo from mobile resulted in an error becase source_view was nil git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@868 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/controllers/todos_controller.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/tracks/app/controllers/todos_controller.rb b/tracks/app/controllers/todos_controller.rb index 89fe11a4..27f9d23d 100644 --- a/tracks/app/controllers/todos_controller.rb +++ b/tracks/app/controllers/todos_controller.rb @@ -154,6 +154,7 @@ class TodosController < ApplicationController end def update + @source_view = params['_source_view'] || 'todo' init_data_for_sidebar unless mobile? @todo.tag_with(params[:tag_list], current_user) if params[:tag_list] @original_item_context_id = @todo.context_id From 32b54383eefe9b9914930d056d52a77c1577780f Mon Sep 17 00:00:00 2001 From: lrbalt Date: Thu, 5 Jun 2008 19:47:20 +0000 Subject: [PATCH 10/22] fix #727. Adds a check to prevent expand/collapse while a previous expand/collaps is still animating git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@869 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/contexts/_context.rhtml | 27 +++++++++++++----------- tracks/public/javascripts/todo-items.js | 6 ++++-- 2 files changed, 19 insertions(+), 14 deletions(-) diff --git a/tracks/app/views/contexts/_context.rhtml b/tracks/app/views/contexts/_context.rhtml index 0c26b469..6191495c 100644 --- a/tracks/app/views/contexts/_context.rhtml +++ b/tracks/app/views/contexts/_context.rhtml @@ -4,18 +4,21 @@ <% if collapsible -%> <%= image_tag("collapse.png") %> <% apply_behavior '.container_toggle:click', :prevent_default => true do |page| - page << "containerElem = this.up('.container') - toggleTarget = containerElem.down('.toggle_target') - if (Element.visible(toggleTarget)) - { - todoItems.collapseNextActionListing(this, toggleTarget); - todoItems.contextCollapseCookieManager.setCookie(todoItems.buildCookieName(containerElem), true) - } - else - { - todoItems.expandNextActionListing(this, toggleTarget); - todoItems.contextCollapseCookieManager.clearCookie(todoItems.buildCookieName(containerElem)) - } + page << " /* only handle the click if a previous click had finished its animation */ + if (todoItems.lastEffect == null || todoItems.lastEffect.state!='running') { + containerElem = this.up('.container') + toggleTarget = containerElem.down('.toggle_target') + if (Element.visible(toggleTarget)) + { + todoItems.collapseNextActionListing(this, toggleTarget); + todoItems.contextCollapseCookieManager.setCookie(todoItems.buildCookieName(containerElem), true) + } + else + { + todoItems.expandNextActionListing(this, toggleTarget); + todoItems.contextCollapseCookieManager.clearCookie(todoItems.buildCookieName(containerElem)) + } + } " end %> diff --git a/tracks/public/javascripts/todo-items.js b/tracks/public/javascripts/todo-items.js index 09ee89f9..61efefbe 100644 --- a/tracks/public/javascripts/todo-items.js +++ b/tracks/public/javascripts/todo-items.js @@ -12,6 +12,8 @@ ToDoItems = Class.create(); ToDoItems.prototype = { initialize: function() { + /* keep track of last effect so you can check if the animation has finised */ + this.lastEffect= null; this.initialized = true; this.contextCollapseCookieManager = new CookieManager(); this.toggleItemsMap = {}; @@ -112,7 +114,7 @@ ToDoItems.prototype = { } else { - Effect.BlindDown(itemsElem, { duration: 0.4 }); + this.lastEffect = Effect.BlindDown(itemsElem, { duration: 0.4 }); } toggleElem.setAttribute('title', 'Collapse'); imgElem = this.findToggleImgElem(toggleElem); @@ -133,7 +135,7 @@ ToDoItems.prototype = { }, collapseNextActionListing: function(toggleElem, itemsElem) { - Effect.BlindUp(itemsElem, { duration: 0.4}); + this.lastEffect = Effect.BlindUp(itemsElem, { duration: 0.4}); toggleElem.setAttribute('title', 'Expand'); imgElem = this.findToggleImgElem(toggleElem); imgElem.src = imgElem.src.replace('collapse','expand'); From d875c5477db245721f072ac0c37692e7664f9d0c Mon Sep 17 00:00:00 2001 From: lrbalt Date: Fri, 6 Jun 2008 15:22:44 +0000 Subject: [PATCH 11/22] in the stats page you can downdrill to see the active todos in a certain week from the running time charts. This patch adds the option to see all active todos from the selected week and older. git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@870 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/controllers/stats_controller.rb | 4 ++++ .../views/stats/show_selection_from_chart.html.erb | 14 +++++++------- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/tracks/app/controllers/stats_controller.rb b/tracks/app/controllers/stats_controller.rb index c44f592e..c28490ca 100755 --- a/tracks/app/controllers/stats_controller.rb +++ b/tracks/app/controllers/stats_controller.rb @@ -481,8 +481,10 @@ class StatsController < ApplicationController @chart_name = "actions_visible_running_time_data" @page_title = "Actions selected from week " + @further = false if params['id'] == 'avrt_end' @page_title += week_from.to_s + " and further" + @further = true else @page_title += week_from.to_s + " - " + week_to.to_s + "" end @@ -512,8 +514,10 @@ class StatsController < ApplicationController @chart_name = "actions_running_time_data" @page_title = "Actions selected from week " + @further = false if params['id'] == 'art_end' @page_title += week_from.to_s + " and further" + @further = true else @page_title += week_from.to_s + " - " + week_to.to_s + "" end diff --git a/tracks/app/views/stats/show_selection_from_chart.html.erb b/tracks/app/views/stats/show_selection_from_chart.html.erb index 2ef5f4ec..3da85a4c 100644 --- a/tracks/app/views/stats/show_selection_from_chart.html.erb +++ b/tracks/app/views/stats/show_selection_from_chart.html.erb @@ -1,18 +1,18 @@ <%= render :partial => 'chart', :locals => {:width => @chart_width, :height => @chart_height, :data => url_for(:action => @chart_name)} -%>
        -

        Click on a bar in the chart to update the actions below. Click <%=link_to "here", {:controller => "stats", :action => "index"} %> to return to the statistics page

        +

        Click on a bar in the chart to update the actions below. Click <%=link_to "here", {:controller => "stats", :action => "index"} %> to return to the statistics page. <% + unless @further -%> <%= + "Click " + + link_to("here", {:controller => "stats", :action => "show_selected_actions_from_chart", :id=>"#{params[:id]}_end", :index => params[:index]})+ + " to show the actions from week " + params[:index] + " and further." -%> + <% end %>


        -

        - <%= @page_title -%> -

        - +

        <%= @page_title -%>

        There are no actions selected

        - <%= render :partial => "todos/todo", :collection => @selected_actions, :locals => { :parent_container_type => 'stats' } %> -
        \ No newline at end of file From 520cf48da215d46ef3f2a84436f3d565e4abd260 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Fri, 6 Jun 2008 15:37:22 +0000 Subject: [PATCH 12/22] forgot to create a new compressed js from the previous js changes git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@871 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/public/javascripts/tracks_869.js | 839 ++++++++++++++++++++++++ 1 file changed, 839 insertions(+) create mode 100644 tracks/public/javascripts/tracks_869.js diff --git a/tracks/public/javascripts/tracks_869.js b/tracks/public/javascripts/tracks_869.js new file mode 100644 index 00000000..920938bb --- /dev/null +++ b/tracks/public/javascripts/tracks_869.js @@ -0,0 +1,839 @@ +var Prototype={Version:'1.6.0.1',Browser:{IE:!!(window.attachEvent&&!window.opera),Opera:!!window.opera,WebKit:navigator.userAgent.indexOf('AppleWebKit/')>-1,Gecko:navigator.userAgent.indexOf('Gecko')>-1&&navigator.userAgent.indexOf('KHTML')==-1,MobileSafari:!!navigator.userAgent.match(/Apple.*Mobile.*Safari/)},BrowserFeatures:{XPath:!!document.evaluate,ElementExtensions:!!window.HTMLElement,SpecificElementExtensions:document.createElement('div').__proto__&&document.createElement('div').__proto__!==document.createElement('form').__proto__},ScriptFragment:']*>([\\S\\s]*?)<\/script>',JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(x){return x}};if(Prototype.Browser.MobileSafari) +Prototype.BrowserFeatures.SpecificElementExtensions=false;var Class={create:function(){var parent=null,properties=$A(arguments);if(Object.isFunction(properties[0])) +parent=properties.shift();function klass(){this.initialize.apply(this,arguments);} +Object.extend(klass,Class.Methods);klass.superclass=parent;klass.subclasses=[];if(parent){var subclass=function(){};subclass.prototype=parent.prototype;klass.prototype=new subclass;parent.subclasses.push(klass);} +for(var i=0;i0){if(match=source.match(pattern)){result+=source.slice(0,match.index);result+=String.interpret(replacement(match));source=source.slice(match.index+match[0].length);}else{result+=source,source='';}} +return result;},sub:function(pattern,replacement,count){replacement=this.gsub.prepareReplacement(replacement);count=Object.isUndefined(count)?1:count;return this.gsub(pattern,function(match){if(--count<0)return match[0];return replacement(match);});},scan:function(pattern,iterator){this.gsub(pattern,iterator);return String(this);},truncate:function(length,truncation){length=length||30;truncation=Object.isUndefined(truncation)?'...':truncation;return this.length>length?this.slice(0,length-truncation.length)+truncation:String(this);},strip:function(){return this.replace(/^\s+/,'').replace(/\s+$/,'');},stripTags:function(){return this.replace(/<\/?[^>]+>/gi,'');},stripScripts:function(){return this.replace(new RegExp(Prototype.ScriptFragment,'img'),'');},extractScripts:function(){var matchAll=new RegExp(Prototype.ScriptFragment,'img');var matchOne=new RegExp(Prototype.ScriptFragment,'im');return(this.match(matchAll)||[]).map(function(scriptTag){return(scriptTag.match(matchOne)||['',''])[1];});},evalScripts:function(){return this.extractScripts().map(function(script){return eval(script)});},escapeHTML:function(){var self=arguments.callee;self.text.data=this;return self.div.innerHTML;},unescapeHTML:function(){var div=new Element('div');div.innerHTML=this.stripTags();return div.childNodes[0]?(div.childNodes.length>1?$A(div.childNodes).inject('',function(memo,node){return memo+node.nodeValue}):div.childNodes[0].nodeValue):'';},toQueryParams:function(separator){var match=this.strip().match(/([^?#]*)(#.*)?$/);if(!match)return{};return match[1].split(separator||'&').inject({},function(hash,pair){if((pair=pair.split('='))[0]){var key=decodeURIComponent(pair.shift());var value=pair.length>1?pair.join('='):pair[0];if(value!=undefined)value=decodeURIComponent(value);if(key in hash){if(!Object.isArray(hash[key]))hash[key]=[hash[key]];hash[key].push(value);} +else hash[key]=value;} +return hash;});},toArray:function(){return this.split('');},succ:function(){return this.slice(0,this.length-1)+ +String.fromCharCode(this.charCodeAt(this.length-1)+1);},times:function(count){return count<1?'':new Array(count+1).join(this);},camelize:function(){var parts=this.split('-'),len=parts.length;if(len==1)return parts[0];var camelized=this.charAt(0)=='-'?parts[0].charAt(0).toUpperCase()+parts[0].substring(1):parts[0];for(var i=1;i-1;},startsWith:function(pattern){return this.indexOf(pattern)===0;},endsWith:function(pattern){var d=this.length-pattern.length;return d>=0&&this.lastIndexOf(pattern)===d;},empty:function(){return this=='';},blank:function(){return/^\s*$/.test(this);},interpolate:function(object,pattern){return new Template(this,pattern).evaluate(object);}});if(Prototype.Browser.WebKit||Prototype.Browser.IE)Object.extend(String.prototype,{escapeHTML:function(){return this.replace(/&/g,'&').replace(//g,'>');},unescapeHTML:function(){return this.replace(/&/g,'&').replace(/</g,'<').replace(/>/g,'>');}});String.prototype.gsub.prepareReplacement=function(replacement){if(Object.isFunction(replacement))return replacement;var template=new Template(replacement);return function(match){return template.evaluate(match)};};String.prototype.parseQuery=String.prototype.toQueryParams;Object.extend(String.prototype.escapeHTML,{div:document.createElement('div'),text:document.createTextNode('')});with(String.prototype.escapeHTML)div.appendChild(text);var Template=Class.create({initialize:function(template,pattern){this.template=template.toString();this.pattern=pattern||Template.Pattern;},evaluate:function(object){if(Object.isFunction(object.toTemplateReplacements)) +object=object.toTemplateReplacements();return this.template.gsub(this.pattern,function(match){if(object==null)return'';var before=match[1]||'';if(before=='\\')return match[2];var ctx=object,expr=match[3];var pattern=/^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/;match=pattern.exec(expr);if(match==null)return before;while(match!=null){var comp=match[1].startsWith('[')?match[2].gsub('\\\\]',']'):match[1];ctx=ctx[comp];if(null==ctx||''==match[3])break;expr=expr.substring('['==match[3]?match[1].length:match[0].length);match=pattern.exec(expr);} +return before+String.interpret(ctx);}.bind(this));}});Template.Pattern=/(^|.|\r|\n)(#\{(.*?)\})/;var $break={};var Enumerable={each:function(iterator,context){var index=0;iterator=iterator.bind(context);try{this._each(function(value){iterator(value,index++);});}catch(e){if(e!=$break)throw e;} +return this;},eachSlice:function(number,iterator,context){iterator=iterator?iterator.bind(context):Prototype.K;var index=-number,slices=[],array=this.toArray();while((index+=number)=result) +result=value;});return result;},min:function(iterator,context){iterator=iterator?iterator.bind(context):Prototype.K;var result;this.each(function(value,index){value=iterator(value,index);if(result==null||valueb?1:0;}).pluck('value');},toArray:function(){return this.map();},zip:function(){var iterator=Prototype.K,args=$A(arguments);if(Object.isFunction(args.last())) +iterator=args.pop();var collections=[this].concat(args).map($A);return this.map(function(value,index){return iterator(collections.pluck(index));});},size:function(){return this.toArray().length;},inspect:function(){return'#';}};Object.extend(Enumerable,{map:Enumerable.collect,find:Enumerable.detect,select:Enumerable.findAll,filter:Enumerable.findAll,member:Enumerable.include,entries:Enumerable.toArray,every:Enumerable.all,some:Enumerable.any});function $A(iterable){if(!iterable)return[];if(iterable.toArray)return iterable.toArray();var length=iterable.length,results=new Array(length);while(length--)results[length]=iterable[length];return results;} +if(Prototype.Browser.WebKit){function $A(iterable){if(!iterable)return[];if(!(Object.isFunction(iterable)&&iterable=='[object NodeList]')&&iterable.toArray)return iterable.toArray();var length=iterable.length,results=new Array(length);while(length--)results[length]=iterable[length];return results;}} +Array.from=$A;Object.extend(Array.prototype,Enumerable);if(!Array.prototype._reverse)Array.prototype._reverse=Array.prototype.reverse;Object.extend(Array.prototype,{_each:function(iterator){for(var i=0,length=this.length;i1?this:this[0];},uniq:function(sorted){return this.inject([],function(array,value,index){if(0==index||(sorted?array.last()!=value:!array.include(value))) +array.push(value);return array;});},intersect:function(array){return this.uniq().findAll(function(item){return array.detect(function(value){return item===value});});},clone:function(){return[].concat(this);},size:function(){return this.length;},inspect:function(){return'['+this.map(Object.inspect).join(', ')+']';},toJSON:function(){var results=[];this.each(function(object){var value=Object.toJSON(object);if(!Object.isUndefined(value))results.push(value);});return'['+results.join(', ')+']';}});if(Object.isFunction(Array.prototype.forEach)) +Array.prototype._each=Array.prototype.forEach;if(!Array.prototype.indexOf)Array.prototype.indexOf=function(item,i){i||(i=0);var length=this.length;if(i<0)i=length+i;for(;i';},toJSON:function(){return Object.toJSON(this.toObject());},clone:function(){return new Hash(this);}}})());Hash.prototype.toTemplateReplacements=Hash.prototype.toObject;Hash.from=$H;var ObjectRange=Class.create(Enumerable,{initialize:function(start,end,exclusive){this.start=start;this.end=end;this.exclusive=exclusive;},_each:function(iterator){var value=this.start;while(this.include(value)){iterator(value);value=value.succ();}},include:function(value){if(value1&&!((readyState==4)&&this._complete)) +this.respondToReadyState(this.transport.readyState);},setRequestHeaders:function(){var headers={'X-Requested-With':'XMLHttpRequest','X-Prototype-Version':Prototype.Version,'Accept':'text/javascript, text/html, application/xml, text/xml, */*'};if(this.method=='post'){headers['Content-type']=this.options.contentType+ +(this.options.encoding?'; charset='+this.options.encoding:'');if(this.transport.overrideMimeType&&(navigator.userAgent.match(/Gecko\/(\d{4})/)||[0,2005])[1]<2005) +headers['Connection']='close';} +if(typeof this.options.requestHeaders=='object'){var extras=this.options.requestHeaders;if(Object.isFunction(extras.push)) +for(var i=0,length=extras.length;i=200&&status<300);},getStatus:function(){try{return this.transport.status||0;}catch(e){return 0}},respondToReadyState:function(readyState){var state=Ajax.Request.Events[readyState],response=new Ajax.Response(this);if(state=='Complete'){try{this._complete=true;(this.options['on'+response.status]||this.options['on'+(this.success()?'Success':'Failure')]||Prototype.emptyFunction)(response,response.headerJSON);}catch(e){this.dispatchException(e);} +var contentType=response.getHeader('Content-type');if(this.options.evalJS=='force'||(this.options.evalJS&&contentType&&contentType.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s*$/i))) +this.evalResponse();} +try{(this.options['on'+state]||Prototype.emptyFunction)(response,response.headerJSON);Ajax.Responders.dispatch('on'+state,this,response,response.headerJSON);}catch(e){this.dispatchException(e);} +if(state=='Complete'){this.transport.onreadystatechange=Prototype.emptyFunction;}},getHeader:function(name){try{return this.transport.getResponseHeader(name);}catch(e){return null}},evalResponse:function(){try{return eval((this.transport.responseText||'').unfilterJSON());}catch(e){this.dispatchException(e);}},dispatchException:function(exception){(this.options.onException||Prototype.emptyFunction)(this,exception);Ajax.Responders.dispatch('onException',this,exception);}});Ajax.Request.Events=['Uninitialized','Loading','Loaded','Interactive','Complete'];Ajax.Response=Class.create({initialize:function(request){this.request=request;var transport=this.transport=request.transport,readyState=this.readyState=transport.readyState;if((readyState>2&&!Prototype.Browser.IE)||readyState==4){this.status=this.getStatus();this.statusText=this.getStatusText();this.responseText=String.interpret(transport.responseText);this.headerJSON=this._getHeaderJSON();} +if(readyState==4){var xml=transport.responseXML;this.responseXML=Object.isUndefined(xml)?null:xml;this.responseJSON=this._getResponseJSON();}},status:0,statusText:'',getStatus:Ajax.Request.prototype.getStatus,getStatusText:function(){try{return this.transport.statusText||'';}catch(e){return''}},getHeader:Ajax.Request.prototype.getHeader,getAllHeaders:function(){try{return this.getAllResponseHeaders();}catch(e){return null}},getResponseHeader:function(name){return this.transport.getResponseHeader(name);},getAllResponseHeaders:function(){return this.transport.getAllResponseHeaders();},_getHeaderJSON:function(){var json=this.getHeader('X-JSON');if(!json)return null;json=decodeURIComponent(escape(json));try{return json.evalJSON(this.request.options.sanitizeJSON);}catch(e){this.request.dispatchException(e);}},_getResponseJSON:function(){var options=this.request.options;if(!options.evalJSON||(options.evalJSON!='force'&&!(this.getHeader('Content-type')||'').include('application/json'))||this.responseText.blank()) +return null;try{return this.responseText.evalJSON(options.sanitizeJSON);}catch(e){this.request.dispatchException(e);}}});Ajax.Updater=Class.create(Ajax.Request,{initialize:function($super,container,url,options){this.container={success:(container.success||container),failure:(container.failure||(container.success?null:container))};options=Object.clone(options);var onComplete=options.onComplete;options.onComplete=(function(response,json){this.updateContent(response.responseText);if(Object.isFunction(onComplete))onComplete(response,json);}).bind(this);$super(url,options);},updateContent:function(responseText){var receiver=this.container[this.success()?'success':'failure'],options=this.options;if(!options.evalScripts)responseText=responseText.stripScripts();if(receiver=$(receiver)){if(options.insertion){if(Object.isString(options.insertion)){var insertion={};insertion[options.insertion]=responseText;receiver.insert(insertion);} +else options.insertion(receiver,responseText);} +else receiver.update(responseText);}}});Ajax.PeriodicalUpdater=Class.create(Ajax.Base,{initialize:function($super,container,url,options){$super(options);this.onComplete=this.options.onComplete;this.frequency=(this.options.frequency||2);this.decay=(this.options.decay||1);this.updater={};this.container=container;this.url=url;this.start();},start:function(){this.options.onComplete=this.updateComplete.bind(this);this.onTimerEvent();},stop:function(){this.updater.options.onComplete=undefined;clearTimeout(this.timer);(this.onComplete||Prototype.emptyFunction).apply(this,arguments);},updateComplete:function(response){if(this.options.decay){this.decay=(response.responseText==this.lastText?this.decay*this.options.decay:1);this.lastText=response.responseText;} +this.timer=this.onTimerEvent.bind(this).delay(this.decay*this.frequency);},onTimerEvent:function(){this.updater=new Ajax.Updater(this.container,this.url,this.options);}});function $(element){if(arguments.length>1){for(var i=0,elements=[],length=arguments.length;i';delete attributes.name;return Element.writeAttribute(document.createElement(tagName),attributes);} +if(!cache[tagName])cache[tagName]=Element.extend(document.createElement(tagName));return Element.writeAttribute(cache[tagName].cloneNode(false),attributes);};Object.extend(this.Element,element||{});}).call(window);Element.cache={};Element.Methods={visible:function(element){return $(element).style.display!='none';},toggle:function(element){element=$(element);Element[Element.visible(element)?'hide':'show'](element);return element;},hide:function(element){$(element).style.display='none';return element;},show:function(element){$(element).style.display='';return element;},remove:function(element){element=$(element);element.parentNode.removeChild(element);return element;},update:function(element,content){element=$(element);if(content&&content.toElement)content=content.toElement();if(Object.isElement(content))return element.update().insert(content);content=Object.toHTML(content);element.innerHTML=content.stripScripts();content.evalScripts.bind(content).defer();return element;},replace:function(element,content){element=$(element);if(content&&content.toElement)content=content.toElement();else if(!Object.isElement(content)){content=Object.toHTML(content);var range=element.ownerDocument.createRange();range.selectNode(element);content.evalScripts.bind(content).defer();content=range.createContextualFragment(content.stripScripts());} +element.parentNode.replaceChild(content,element);return element;},insert:function(element,insertions){element=$(element);if(Object.isString(insertions)||Object.isNumber(insertions)||Object.isElement(insertions)||(insertions&&(insertions.toElement||insertions.toHTML))) +insertions={bottom:insertions};var content,t,range;for(position in insertions){content=insertions[position];position=position.toLowerCase();t=Element._insertionTranslations[position];if(content&&content.toElement)content=content.toElement();if(Object.isElement(content)){t.insert(element,content);continue;} +content=Object.toHTML(content);range=element.ownerDocument.createRange();t.initializeRange(element,range);t.insert(element,range.createContextualFragment(content.stripScripts()));content.evalScripts.bind(content).defer();} +return element;},wrap:function(element,wrapper,attributes){element=$(element);if(Object.isElement(wrapper)) +$(wrapper).writeAttribute(attributes||{});else if(Object.isString(wrapper))wrapper=new Element(wrapper,attributes);else wrapper=new Element('div',wrapper);if(element.parentNode) +element.parentNode.replaceChild(wrapper,element);wrapper.appendChild(element);return wrapper;},inspect:function(element){element=$(element);var result='<'+element.tagName.toLowerCase();$H({'id':'id','className':'class'}).each(function(pair){var property=pair.first(),attribute=pair.last();var value=(element[property]||'').toString();if(value)result+=' '+attribute+'='+value.inspect(true);});return result+'>';},recursivelyCollect:function(element,property){element=$(element);var elements=[];while(element=element[property]) +if(element.nodeType==1) +elements.push(Element.extend(element));return elements;},ancestors:function(element){return $(element).recursivelyCollect('parentNode');},descendants:function(element){return $(element).getElementsBySelector("*");},firstDescendant:function(element){element=$(element).firstChild;while(element&&element.nodeType!=1)element=element.nextSibling;return $(element);},immediateDescendants:function(element){if(!(element=$(element).firstChild))return[];while(element&&element.nodeType!=1)element=element.nextSibling;if(element)return[element].concat($(element).nextSiblings());return[];},previousSiblings:function(element){return $(element).recursivelyCollect('previousSibling');},nextSiblings:function(element){return $(element).recursivelyCollect('nextSibling');},siblings:function(element){element=$(element);return element.previousSiblings().reverse().concat(element.nextSiblings());},match:function(element,selector){if(Object.isString(selector)) +selector=new Selector(selector);return selector.match($(element));},up:function(element,expression,index){element=$(element);if(arguments.length==1)return $(element.parentNode);var ancestors=element.ancestors();return expression?Selector.findElement(ancestors,expression,index):ancestors[index||0];},down:function(element,expression,index){element=$(element);if(arguments.length==1)return element.firstDescendant();var descendants=element.descendants();return expression?Selector.findElement(descendants,expression,index):descendants[index||0];},previous:function(element,expression,index){element=$(element);if(arguments.length==1)return $(Selector.handlers.previousElementSibling(element));var previousSiblings=element.previousSiblings();return expression?Selector.findElement(previousSiblings,expression,index):previousSiblings[index||0];},next:function(element,expression,index){element=$(element);if(arguments.length==1)return $(Selector.handlers.nextElementSibling(element));var nextSiblings=element.nextSiblings();return expression?Selector.findElement(nextSiblings,expression,index):nextSiblings[index||0];},select:function(){var args=$A(arguments),element=$(args.shift());return Selector.findChildElements(element,args);},adjacent:function(){var args=$A(arguments),element=$(args.shift());return Selector.findChildElements(element.parentNode,args).without(element);},identify:function(element){element=$(element);var id=element.readAttribute('id'),self=arguments.callee;if(id)return id;do{id='anonymous_element_'+self.counter++}while($(id));element.writeAttribute('id',id);return id;},readAttribute:function(element,name){element=$(element);if(Prototype.Browser.IE){var t=Element._attributeTranslations.read;if(t.values[name])return t.values[name](element,name);if(t.names[name])name=t.names[name];if(name.include(':')){return(!element.attributes||!element.attributes[name])?null:element.attributes[name].value;}} +return element.getAttribute(name);},writeAttribute:function(element,name,value){element=$(element);var attributes={},t=Element._attributeTranslations.write;if(typeof name=='object')attributes=name;else attributes[name]=Object.isUndefined(value)?true:value;for(var attr in attributes){name=t.names[attr]||attr;value=attributes[attr];if(t.values[attr])name=t.values[attr](element,value);if(value===false||value===null) +element.removeAttribute(name);else if(value===true) +element.setAttribute(name,name);else element.setAttribute(name,value);} +return element;},getHeight:function(element){return $(element).getDimensions().height;},getWidth:function(element){return $(element).getDimensions().width;},classNames:function(element){return new Element.ClassNames(element);},hasClassName:function(element,className){if(!(element=$(element)))return;var elementClassName=element.className;return(elementClassName.length>0&&(elementClassName==className||new RegExp("(^|\\s)"+className+"(\\s|$)").test(elementClassName)));},addClassName:function(element,className){if(!(element=$(element)))return;if(!element.hasClassName(className)) +element.className+=(element.className?' ':'')+className;return element;},removeClassName:function(element,className){if(!(element=$(element)))return;element.className=element.className.replace(new RegExp("(^|\\s+)"+className+"(\\s+|$)"),' ').strip();return element;},toggleClassName:function(element,className){if(!(element=$(element)))return;return element[element.hasClassName(className)?'removeClassName':'addClassName'](className);},cleanWhitespace:function(element){element=$(element);var node=element.firstChild;while(node){var nextNode=node.nextSibling;if(node.nodeType==3&&!/\S/.test(node.nodeValue)) +element.removeChild(node);node=nextNode;} +return element;},empty:function(element){return $(element).innerHTML.blank();},descendantOf:function(element,ancestor){element=$(element),ancestor=$(ancestor);var originalAncestor=ancestor;if(element.compareDocumentPosition) +return(element.compareDocumentPosition(ancestor)&8)===8;if(element.sourceIndex&&!Prototype.Browser.Opera){var e=element.sourceIndex,a=ancestor.sourceIndex,nextAncestor=ancestor.nextSibling;if(!nextAncestor){do{ancestor=ancestor.parentNode;} +while(!(nextAncestor=ancestor.nextSibling)&&ancestor.parentNode);} +if(nextAncestor)return(e>a&&e','',1],TBODY:['','
        ',2],TR:['','
        ',3],TD:['
        ','
        ',4],SELECT:['',1]}};(function(){this.bottom.initializeRange=this.top.initializeRange;Object.extend(this.tags,{THEAD:this.tags.TBODY,TFOOT:this.tags.TBODY,TH:this.tags.TD});}).call(Element._insertionTranslations);Element.Methods.Simulated={hasAttribute:function(element,attribute){attribute=Element._attributeTranslations.has[attribute]||attribute;var node=$(element).getAttributeNode(attribute);return node&&node.specified;}};Element.Methods.ByTag={};Object.extend(Element,Element.Methods);if(!Prototype.BrowserFeatures.ElementExtensions&&document.createElement('div').__proto__){window.HTMLElement={};window.HTMLElement.prototype=document.createElement('div').__proto__;Prototype.BrowserFeatures.ElementExtensions=true;} +Element.extend=(function(){if(Prototype.BrowserFeatures.SpecificElementExtensions) +return Prototype.K;var Methods={},ByTag=Element.Methods.ByTag;var extend=Object.extend(function(element){if(!element||element._extendedByPrototype||element.nodeType!=1||element==window)return element;var methods=Object.clone(Methods),tagName=element.tagName,property,value;if(ByTag[tagName])Object.extend(methods,ByTag[tagName]);for(property in methods){value=methods[property];if(Object.isFunction(value)&&!(property in element)) +element[property]=value.methodize();} +element._extendedByPrototype=Prototype.emptyFunction;return element;},{refresh:function(){if(!Prototype.BrowserFeatures.ElementExtensions){Object.extend(Methods,Element.Methods);Object.extend(Methods,Element.Methods.Simulated);}}});extend.refresh();return extend;})();Element.hasAttribute=function(element,attribute){if(element.hasAttribute)return element.hasAttribute(attribute);return Element.Methods.Simulated.hasAttribute(element,attribute);};Element.addMethods=function(methods){var F=Prototype.BrowserFeatures,T=Element.Methods.ByTag;if(!methods){Object.extend(Form,Form.Methods);Object.extend(Form.Element,Form.Element.Methods);Object.extend(Element.Methods.ByTag,{"FORM":Object.clone(Form.Methods),"INPUT":Object.clone(Form.Element.Methods),"SELECT":Object.clone(Form.Element.Methods),"TEXTAREA":Object.clone(Form.Element.Methods)});} +if(arguments.length==2){var tagName=methods;methods=arguments[1];} +if(!tagName)Object.extend(Element.Methods,methods||{});else{if(Object.isArray(tagName))tagName.each(extend);else extend(tagName);} +function extend(tagName){tagName=tagName.toUpperCase();if(!Element.Methods.ByTag[tagName]) +Element.Methods.ByTag[tagName]={};Object.extend(Element.Methods.ByTag[tagName],methods);} +function copy(methods,destination,onlyIfAbsent){onlyIfAbsent=onlyIfAbsent||false;for(var property in methods){var value=methods[property];if(!Object.isFunction(value))continue;if(!onlyIfAbsent||!(property in destination)) +destination[property]=value.methodize();}} +function findDOMClass(tagName){var klass;var trans={"OPTGROUP":"OptGroup","TEXTAREA":"TextArea","P":"Paragraph","FIELDSET":"FieldSet","UL":"UList","OL":"OList","DL":"DList","DIR":"Directory","H1":"Heading","H2":"Heading","H3":"Heading","H4":"Heading","H5":"Heading","H6":"Heading","Q":"Quote","INS":"Mod","DEL":"Mod","A":"Anchor","IMG":"Image","CAPTION":"TableCaption","COL":"TableCol","COLGROUP":"TableCol","THEAD":"TableSection","TFOOT":"TableSection","TBODY":"TableSection","TR":"TableRow","TH":"TableCell","TD":"TableCell","FRAMESET":"FrameSet","IFRAME":"IFrame"};if(trans[tagName])klass='HTML'+trans[tagName]+'Element';if(window[klass])return window[klass];klass='HTML'+tagName+'Element';if(window[klass])return window[klass];klass='HTML'+tagName.capitalize()+'Element';if(window[klass])return window[klass];window[klass]={};window[klass].prototype=document.createElement(tagName).__proto__;return window[klass];} +if(F.ElementExtensions){copy(Element.Methods,HTMLElement.prototype);copy(Element.Methods.Simulated,HTMLElement.prototype,true);} +if(F.SpecificElementExtensions){for(var tag in Element.Methods.ByTag){var klass=findDOMClass(tag);if(Object.isUndefined(klass))continue;copy(T[tag],klass.prototype);}} +Object.extend(Element,Element.Methods);delete Element.ByTag;if(Element.extend.refresh)Element.extend.refresh();Element.cache={};};document.viewport={getDimensions:function(){var dimensions={};var B=Prototype.Browser;$w('width height').each(function(d){var D=d.capitalize();dimensions[d]=(B.WebKit&&!document.evaluate)?self['inner'+D]:(B.Opera)?document.body['client'+D]:document.documentElement['client'+D];});return dimensions;},getWidth:function(){return this.getDimensions().width;},getHeight:function(){return this.getDimensions().height;},getScrollOffsets:function(){return Element._returnOffset(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft,window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop);}};var Selector=Class.create({initialize:function(expression){this.expression=expression.strip();this.compileMatcher();},shouldUseXPath:function(){if(!Prototype.BrowserFeatures.XPath)return false;var e=this.expression;if(Prototype.Browser.WebKit&&(e.include("-of-type")||e.include(":empty"))) +return false;if((/(\[[\w-]*?:|:checked)/).test(this.expression)) +return false;return true;},compileMatcher:function(){if(this.shouldUseXPath()) +return this.compileXPathMatcher();var e=this.expression,ps=Selector.patterns,h=Selector.handlers,c=Selector.criteria,le,p,m;if(Selector._cache[e]){this.matcher=Selector._cache[e];return;} +this.matcher=["this.matcher = function(root) {","var r = root, h = Selector.handlers, c = false, n;"];while(e&&le!=e&&(/\S/).test(e)){le=e;for(var i in ps){p=ps[i];if(m=e.match(p)){this.matcher.push(Object.isFunction(c[i])?c[i](m):new Template(c[i]).evaluate(m));e=e.replace(m[0],'');break;}}} +this.matcher.push("return h.unique(n);\n}");eval(this.matcher.join('\n'));Selector._cache[this.expression]=this.matcher;},compileXPathMatcher:function(){var e=this.expression,ps=Selector.patterns,x=Selector.xpath,le,m;if(Selector._cache[e]){this.xpath=Selector._cache[e];return;} +this.matcher=['.//*'];while(e&&le!=e&&(/\S/).test(e)){le=e;for(var i in ps){if(m=e.match(ps[i])){this.matcher.push(Object.isFunction(x[i])?x[i](m):new Template(x[i]).evaluate(m));e=e.replace(m[0],'');break;}}} +this.xpath=this.matcher.join('');Selector._cache[this.expression]=this.xpath;},findElements:function(root){root=root||document;if(this.xpath)return document._getElementsByXPath(this.xpath,root);return this.matcher(root);},match:function(element){this.tokens=[];var e=this.expression,ps=Selector.patterns,as=Selector.assertions;var le,p,m;while(e&&le!==e&&(/\S/).test(e)){le=e;for(var i in ps){p=ps[i];if(m=e.match(p)){if(as[i]){this.tokens.push([i,Object.clone(m)]);e=e.replace(m[0],'');}else{return this.findElements(document).include(element);}}}} +var match=true,name,matches;for(var i=0,token;token=this.tokens[i];i++){name=token[0],matches=token[1];if(!Selector.assertions[name](element,matches)){match=false;break;}} +return match;},toString:function(){return this.expression;},inspect:function(){return"#";}});Object.extend(Selector,{_cache:{},xpath:{descendant:"//*",child:"/*",adjacent:"/following-sibling::*[1]",laterSibling:'/following-sibling::*',tagName:function(m){if(m[1]=='*')return'';return"[local-name()='"+m[1].toLowerCase()+"' or local-name()='"+m[1].toUpperCase()+"']";},className:"[contains(concat(' ', @class, ' '), ' #{1} ')]",id:"[@id='#{1}']",attrPresence:function(m){m[1]=m[1].toLowerCase();return new Template("[@#{1}]").evaluate(m);},attr:function(m){m[1]=m[1].toLowerCase();m[3]=m[5]||m[6];return new Template(Selector.xpath.operators[m[2]]).evaluate(m);},pseudo:function(m){var h=Selector.xpath.pseudos[m[1]];if(!h)return'';if(Object.isFunction(h))return h(m);return new Template(Selector.xpath.pseudos[m[1]]).evaluate(m);},operators:{'=':"[@#{1}='#{3}']",'!=':"[@#{1}!='#{3}']",'^=':"[starts-with(@#{1}, '#{3}')]",'$=':"[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']",'*=':"[contains(@#{1}, '#{3}')]",'~=':"[contains(concat(' ', @#{1}, ' '), ' #{3} ')]",'|=':"[contains(concat('-', @#{1}, '-'), '-#{3}-')]"},pseudos:{'first-child':'[not(preceding-sibling::*)]','last-child':'[not(following-sibling::*)]','only-child':'[not(preceding-sibling::* or following-sibling::*)]','empty':"[count(*) = 0 and (count(text()) = 0 or translate(text(), ' \t\r\n', '') = '')]",'checked':"[@checked]",'disabled':"[@disabled]",'enabled':"[not(@disabled)]",'not':function(m){var e=m[6],p=Selector.patterns,x=Selector.xpath,le,v;var exclusion=[];while(e&&le!=e&&(/\S/).test(e)){le=e;for(var i in p){if(m=e.match(p[i])){v=Object.isFunction(x[i])?x[i](m):new Template(x[i]).evaluate(m);exclusion.push("("+v.substring(1,v.length-1)+")");e=e.replace(m[0],'');break;}}} +return"[not("+exclusion.join(" and ")+")]";},'nth-child':function(m){return Selector.xpath.pseudos.nth("(count(./preceding-sibling::*) + 1) ",m);},'nth-last-child':function(m){return Selector.xpath.pseudos.nth("(count(./following-sibling::*) + 1) ",m);},'nth-of-type':function(m){return Selector.xpath.pseudos.nth("position() ",m);},'nth-last-of-type':function(m){return Selector.xpath.pseudos.nth("(last() + 1 - position()) ",m);},'first-of-type':function(m){m[6]="1";return Selector.xpath.pseudos['nth-of-type'](m);},'last-of-type':function(m){m[6]="1";return Selector.xpath.pseudos['nth-last-of-type'](m);},'only-of-type':function(m){var p=Selector.xpath.pseudos;return p['first-of-type'](m)+p['last-of-type'](m);},nth:function(fragment,m){var mm,formula=m[6],predicate;if(formula=='even')formula='2n+0';if(formula=='odd')formula='2n+1';if(mm=formula.match(/^(\d+)$/)) +return'['+fragment+"= "+mm[1]+']';if(mm=formula.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(mm[1]=="-")mm[1]=-1;var a=mm[1]?Number(mm[1]):1;var b=mm[2]?Number(mm[2]):0;predicate="[((#{fragment} - #{b}) mod #{a} = 0) and "+"((#{fragment} - #{b}) div #{a} >= 0)]";return new Template(predicate).evaluate({fragment:fragment,a:a,b:b});}}}},criteria:{tagName:'n = h.tagName(n, r, "#{1}", c); c = false;',className:'n = h.className(n, r, "#{1}", c); c = false;',id:'n = h.id(n, r, "#{1}", c); c = false;',attrPresence:'n = h.attrPresence(n, r, "#{1}"); c = false;',attr:function(m){m[3]=(m[5]||m[6]);return new Template('n = h.attr(n, r, "#{1}", "#{3}", "#{2}"); c = false;').evaluate(m);},pseudo:function(m){if(m[6])m[6]=m[6].replace(/"/g,'\\"');return new Template('n = h.pseudo(n, "#{1}", "#{6}", r, c); c = false;').evaluate(m);},descendant:'c = "descendant";',child:'c = "child";',adjacent:'c = "adjacent";',laterSibling:'c = "laterSibling";'},patterns:{laterSibling:/^\s*~\s*/,child:/^\s*>\s*/,adjacent:/^\s*\+\s*/,descendant:/^\s/,tagName:/^\s*(\*|[\w\-]+)(\b|$)?/,id:/^#([\w\-\*]+)(\b|$)/,className:/^\.([\w\-\*]+)(\b|$)/,pseudo:/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|(?=\s)|(?=:))/,attrPresence:/^\[([\w]+)\]/,attr:/\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['"])([^\4]*?)\4|([^'"][^\]]*?)))?\]/},assertions:{tagName:function(element,matches){return matches[1].toUpperCase()==element.tagName.toUpperCase();},className:function(element,matches){return Element.hasClassName(element,matches[1]);},id:function(element,matches){return element.id===matches[1];},attrPresence:function(element,matches){return Element.hasAttribute(element,matches[1]);},attr:function(element,matches){var nodeValue=Element.readAttribute(element,matches[1]);return Selector.operators[matches[2]](nodeValue,matches[3]);}},handlers:{concat:function(a,b){for(var i=0,node;node=b[i];i++) +a.push(node);return a;},mark:function(nodes){for(var i=0,node;node=nodes[i];i++) +node._counted=true;return nodes;},unmark:function(nodes){for(var i=0,node;node=nodes[i];i++) +node._counted=undefined;return nodes;},index:function(parentNode,reverse,ofType){parentNode._counted=true;if(reverse){for(var nodes=parentNode.childNodes,i=nodes.length-1,j=1;i>=0;i--){var node=nodes[i];if(node.nodeType==1&&(!ofType||node._counted))node.nodeIndex=j++;}}else{for(var i=0,j=1,nodes=parentNode.childNodes;node=nodes[i];i++) +if(node.nodeType==1&&(!ofType||node._counted))node.nodeIndex=j++;}},unique:function(nodes){if(nodes.length==0)return nodes;var results=[],n;for(var i=0,l=nodes.length;i0?[b]:[];return $R(1,total).inject([],function(memo,i){if(0==(i-b)%a&&(i-b)/a>=0)memo.push(i);return memo;});},nth:function(nodes,formula,root,reverse,ofType){if(nodes.length==0)return[];if(formula=='even')formula='2n+0';if(formula=='odd')formula='2n+1';var h=Selector.handlers,results=[],indexed=[],m;h.mark(nodes);for(var i=0,node;node=nodes[i];i++){if(!node.parentNode._counted){h.index(node.parentNode,reverse,ofType);indexed.push(node.parentNode);}} +if(formula.match(/^\d+$/)){formula=Number(formula);for(var i=0,node;node=nodes[i];i++) +if(node.nodeIndex==formula)results.push(node);}else if(m=formula.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(m[1]=="-")m[1]=-1;var a=m[1]?Number(m[1]):1;var b=m[2]?Number(m[2]):0;var indices=Selector.pseudos.getIndices(a,b,nodes.length);for(var i=0,node,l=indices.length;node=nodes[i];i++){for(var j=0;j+()\s-]+|\*|\[.*?\])+)\s*(,|$)/,function(m){expressions.push(m[1].strip());});var results=[],h=Selector.handlers;for(var i=0,l=expressions.length,selector;i1)?h.unique(results):results;}});if(Prototype.Browser.IE){Selector.handlers.concat=function(a,b){for(var i=0,node;node=b[i];i++) +if(node.tagName!=="!")a.push(node);return a;};} +function $$(){return Selector.findChildElements(document,$A(arguments));} +var Form={reset:function(form){$(form).reset();return form;},serializeElements:function(elements,options){if(typeof options!='object')options={hash:!!options};else if(Object.isUndefined(options.hash))options.hash=true;var key,value,submitted=false,submit=options.submit;var data=elements.inject({},function(result,element){if(!element.disabled&&element.name){key=element.name;value=$(element).getValue();if(value!=null&&(element.type!='submit'||(!submitted&&submit!==false&&(!submit||key==submit)&&(submitted=true)))){if(key in result){if(!Object.isArray(result[key]))result[key]=[result[key]];result[key].push(value);} +else result[key]=value;}} +return result;});return options.hash?data:Object.toQueryString(data);}};Form.Methods={serialize:function(form,options){return Form.serializeElements(Form.getElements(form),options);},getElements:function(form){return $A($(form).getElementsByTagName('*')).inject([],function(elements,child){if(Form.Element.Serializers[child.tagName.toLowerCase()]) +elements.push(Element.extend(child));return elements;});},getInputs:function(form,typeName,name){form=$(form);var inputs=form.getElementsByTagName('input');if(!typeName&&!name)return $A(inputs).map(Element.extend);for(var i=0,matchingInputs=[],length=inputs.length;i=0;}).sortBy(function(element){return element.tabIndex}).first();return firstByIndex?firstByIndex:elements.find(function(element){return['input','select','textarea'].include(element.tagName.toLowerCase());});},focusFirstElement:function(form){form=$(form);form.findFirstElement().activate();return form;},request:function(form,options){form=$(form),options=Object.clone(options||{});var params=options.parameters,action=form.readAttribute('action')||'';if(action.blank())action=window.location.href;options.parameters=form.serialize(true);if(params){if(Object.isString(params))params=params.toQueryParams();Object.extend(options.parameters,params);} +if(form.hasAttribute('method')&&!options.method) +options.method=form.method;return new Ajax.Request(action,options);}};Form.Element={focus:function(element){$(element).focus();return element;},select:function(element){$(element).select();return element;}};Form.Element.Methods={serialize:function(element){element=$(element);if(!element.disabled&&element.name){var value=element.getValue();if(value!=undefined){var pair={};pair[element.name]=value;return Object.toQueryString(pair);}} +return'';},getValue:function(element){element=$(element);var method=element.tagName.toLowerCase();return Form.Element.Serializers[method](element);},setValue:function(element,value){element=$(element);var method=element.tagName.toLowerCase();Form.Element.Serializers[method](element,value);return element;},clear:function(element){$(element).value='';return element;},present:function(element){return $(element).value!='';},activate:function(element){element=$(element);try{element.focus();if(element.select&&(element.tagName.toLowerCase()!='input'||!['button','reset','submit'].include(element.type))) +element.select();}catch(e){} +return element;},disable:function(element){element=$(element);element.blur();element.disabled=true;return element;},enable:function(element){element=$(element);element.disabled=false;return element;}};var Field=Form.Element;var $F=Form.Element.Methods.getValue;Form.Element.Serializers={input:function(element,value){switch(element.type.toLowerCase()){case'checkbox':case'radio':return Form.Element.Serializers.inputSelector(element,value);default:return Form.Element.Serializers.textarea(element,value);}},inputSelector:function(element,value){if(Object.isUndefined(value))return element.checked?element.value:null;else element.checked=!!value;},textarea:function(element,value){if(Object.isUndefined(value))return element.value;else element.value=value;},select:function(element,index){if(Object.isUndefined(index)) +return this[element.type=='select-one'?'selectOne':'selectMany'](element);else{var opt,value,single=!Object.isArray(index);for(var i=0,length=element.length;i=0?this.optionValue(element.options[index]):null;},selectMany:function(element){var values,length=element.length;if(!length)return null;for(var i=0,values=[];i<\/script>");$("__onDOMContentLoaded").onreadystatechange=function(){if(this.readyState=="complete"){this.onreadystatechange=null;fireContentLoadedEvent();}};}})();Hash.toQueryString=Object.toQueryString;var Toggle={display:Element.toggle};Element.Methods.childOf=Element.Methods.descendantOf;var Insertion={Before:function(element,content){return Element.insert(element,{before:content});},Top:function(element,content){return Element.insert(element,{top:content});},Bottom:function(element,content){return Element.insert(element,{bottom:content});},After:function(element,content){return Element.insert(element,{after:content});}};var $continue=new Error('"throw $continue" is deprecated, use "return" instead');var Position={includeScrollOffsets:false,prepare:function(){this.deltaX=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;this.deltaY=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;},within:function(element,x,y){if(this.includeScrollOffsets) +return this.withinIncludingScrolloffsets(element,x,y);this.xcomp=x;this.ycomp=y;this.offset=Element.cumulativeOffset(element);return(y>=this.offset[1]&&y=this.offset[0]&&x=this.offset[1]&&this.ycomp=this.offset[0]&&this.xcomp0;})._each(iterator);},set:function(className){this.element.className=className;},add:function(classNameToAdd){if(this.include(classNameToAdd))return;this.set($A(this).concat(classNameToAdd).join(' '));},remove:function(classNameToRemove){if(!this.include(classNameToRemove))return;this.set($A(this).without(classNameToRemove).join(' '));},toString:function(){return $A(this).join(' ');}};Object.extend(Element.ClassNames.prototype,Enumerable);Element.addMethods();String.prototype.parseColor=function(){var color='#';if(this.slice(0,4)=='rgb('){var cols=this.slice(4,this.length-1).split(',');var i=0;do{color+=parseInt(cols[i]).toColorPart()}while(++i<3);}else{if(this.slice(0,1)=='#'){if(this.length==4)for(var i=1;i<4;i++)color+=(this.charAt(i)+this.charAt(i)).toLowerCase();if(this.length==7)color=this.toLowerCase();}} +return(color.length==7?color:(arguments[0]||this));};Element.collectTextNodes=function(element){return $A($(element).childNodes).collect(function(node){return(node.nodeType==3?node.nodeValue:(node.hasChildNodes()?Element.collectTextNodes(node):''));}).flatten().join('');};Element.collectTextNodesIgnoreClass=function(element,className){return $A($(element).childNodes).collect(function(node){return(node.nodeType==3?node.nodeValue:((node.hasChildNodes()&&!Element.hasClassName(node,className))?Element.collectTextNodesIgnoreClass(node,className):''));}).flatten().join('');};Element.setContentZoom=function(element,percent){element=$(element);element.setStyle({fontSize:(percent/100)+'em'});if(Prototype.Browser.WebKit)window.scrollBy(0,0);return element;};Element.getInlineOpacity=function(element){return $(element).style.opacity||'';};Element.forceRerendering=function(element){try{element=$(element);var n=document.createTextNode(' ');element.appendChild(n);element.removeChild(n);}catch(e){}};var Effect={_elementDoesNotExistError:{name:'ElementDoesNotExistError',message:'The specified DOM element does not exist, but is required for this effect to operate'},Transitions:{linear:Prototype.K,sinoidal:function(pos){return(-Math.cos(pos*Math.PI)/2)+0.5;},reverse:function(pos){return 1-pos;},flicker:function(pos){var pos=((-Math.cos(pos*Math.PI)/4)+0.75)+Math.random()/4;return pos>1?1:pos;},wobble:function(pos){return(-Math.cos(pos*Math.PI*(9*pos))/2)+0.5;},pulse:function(pos,pulses){pulses=pulses||5;return(((pos%(1/pulses))*pulses).round()==0?((pos*pulses*2)-(pos*pulses*2).floor()):1-((pos*pulses*2)-(pos*pulses*2).floor()));},spring:function(pos){return 1-(Math.cos(pos*4.5*Math.PI)*Math.exp(-pos*6));},none:function(pos){return 0;},full:function(pos){return 1;}},DefaultOptions:{duration:1.0,fps:100,sync:false,from:0.0,to:1.0,delay:0.0,queue:'parallel'},tagifyText:function(element){var tagifyStyle='position:relative';if(Prototype.Browser.IE)tagifyStyle+=';zoom:1';element=$(element);$A(element.childNodes).each(function(child){if(child.nodeType==3){child.nodeValue.toArray().each(function(character){element.insertBefore(new Element('span',{style:tagifyStyle}).update(character==' '?String.fromCharCode(160):character),child);});Element.remove(child);}});},multiple:function(element,effect){var elements;if(((typeof element=='object')||Object.isFunction(element))&&(element.length)) +elements=element;else +elements=$(element).childNodes;var options=Object.extend({speed:0.1,delay:0.0},arguments[2]||{});var masterDelay=options.delay;$A(elements).each(function(element,index){new effect(element,Object.extend(options,{delay:index*options.speed+masterDelay}));});},PAIRS:{'slide':['SlideDown','SlideUp'],'blind':['BlindDown','BlindUp'],'appear':['Appear','Fade']},toggle:function(element,effect){element=$(element);effect=(effect||'appear').toLowerCase();var options=Object.extend({queue:{position:'end',scope:(element.id||'global'),limit:1}},arguments[2]||{});Effect[element.visible()?Effect.PAIRS[effect][1]:Effect.PAIRS[effect][0]](element,options);}};Effect.DefaultOptions.transition=Effect.Transitions.sinoidal;Effect.ScopedQueue=Class.create(Enumerable,{initialize:function(){this.effects=[];this.interval=null;},_each:function(iterator){this.effects._each(iterator);},add:function(effect){var timestamp=new Date().getTime();var position=Object.isString(effect.options.queue)?effect.options.queue:effect.options.queue.position;switch(position){case'front':this.effects.findAll(function(e){return e.state=='idle'}).each(function(e){e.startOn+=effect.finishOn;e.finishOn+=effect.finishOn;});break;case'with-last':timestamp=this.effects.pluck('startOn').max()||timestamp;break;case'end':timestamp=this.effects.pluck('finishOn').max()||timestamp;break;} +effect.startOn+=timestamp;effect.finishOn+=timestamp;if(!effect.options.queue.limit||(this.effects.length=this.startOn){if(timePos>=this.finishOn){this.render(1.0);this.cancel();this.event('beforeFinish');if(this.finish)this.finish();this.event('afterFinish');return;} +var pos=(timePos-this.startOn)/this.totalTime,frame=(pos*this.totalFrames).round();if(frame>this.currentFrame){this.render(pos);this.currentFrame=frame;}}},cancel:function(){if(!this.options.sync) +Effect.Queues.get(Object.isString(this.options.queue)?'global':this.options.queue.scope).remove(this);this.state='finished';},event:function(eventName){if(this.options[eventName+'Internal'])this.options[eventName+'Internal'](this);if(this.options[eventName])this.options[eventName](this);},inspect:function(){var data=$H();for(property in this) +if(!Object.isFunction(this[property]))data.set(property,this[property]);return'#';}});Effect.Parallel=Class.create(Effect.Base,{initialize:function(effects){this.effects=effects||[];this.start(arguments[1]);},update:function(position){this.effects.invoke('render',position);},finish:function(position){this.effects.each(function(effect){effect.render(1.0);effect.cancel();effect.event('beforeFinish');if(effect.finish)effect.finish(position);effect.event('afterFinish');});}});Effect.Tween=Class.create(Effect.Base,{initialize:function(object,from,to){object=Object.isString(object)?$(object):object;var args=$A(arguments),method=args.last(),options=args.length==5?args[3]:null;this.method=Object.isFunction(method)?method.bind(object):Object.isFunction(object[method])?object[method].bind(object):function(value){object[method]=value};this.start(Object.extend({from:from,to:to},options||{}));},update:function(position){this.method(position);}});Effect.Event=Class.create(Effect.Base,{initialize:function(){this.start(Object.extend({duration:0},arguments[0]||{}));},update:Prototype.emptyFunction});Effect.Opacity=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);if(Prototype.Browser.IE&&(!this.element.currentStyle.hasLayout)) +this.element.setStyle({zoom:1});var options=Object.extend({from:this.element.getOpacity()||0.0,to:1.0},arguments[1]||{});this.start(options);},update:function(position){this.element.setOpacity(position);}});Effect.Move=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({x:0,y:0,mode:'relative'},arguments[1]||{});this.start(options);},setup:function(){this.element.makePositioned();this.originalLeft=parseFloat(this.element.getStyle('left')||'0');this.originalTop=parseFloat(this.element.getStyle('top')||'0');if(this.options.mode=='absolute'){this.options.x=this.options.x-this.originalLeft;this.options.y=this.options.y-this.originalTop;}},update:function(position){this.element.setStyle({left:(this.options.x*position+this.originalLeft).round()+'px',top:(this.options.y*position+this.originalTop).round()+'px'});}});Effect.MoveBy=function(element,toTop,toLeft){return new Effect.Move(element,Object.extend({x:toLeft,y:toTop},arguments[3]||{}));};Effect.Scale=Class.create(Effect.Base,{initialize:function(element,percent){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({scaleX:true,scaleY:true,scaleContent:true,scaleFromCenter:false,scaleMode:'box',scaleFrom:100.0,scaleTo:percent},arguments[2]||{});this.start(options);},setup:function(){this.restoreAfterFinish=this.options.restoreAfterFinish||false;this.elementPositioning=this.element.getStyle('position');this.originalStyle={};['top','left','width','height','fontSize'].each(function(k){this.originalStyle[k]=this.element.style[k];}.bind(this));this.originalTop=this.element.offsetTop;this.originalLeft=this.element.offsetLeft;var fontSize=this.element.getStyle('font-size')||'100%';['em','px','%','pt'].each(function(fontSizeType){if(fontSize.indexOf(fontSizeType)>0){this.fontSize=parseFloat(fontSize);this.fontSizeType=fontSizeType;}}.bind(this));this.factor=(this.options.scaleTo-this.options.scaleFrom)/100;this.dims=null;if(this.options.scaleMode=='box') +this.dims=[this.element.offsetHeight,this.element.offsetWidth];if(/^content/.test(this.options.scaleMode)) +this.dims=[this.element.scrollHeight,this.element.scrollWidth];if(!this.dims) +this.dims=[this.options.scaleMode.originalHeight,this.options.scaleMode.originalWidth];},update:function(position){var currentScale=(this.options.scaleFrom/100.0)+(this.factor*position);if(this.options.scaleContent&&this.fontSize) +this.element.setStyle({fontSize:this.fontSize*currentScale+this.fontSizeType});this.setDimensions(this.dims[0]*currentScale,this.dims[1]*currentScale);},finish:function(position){if(this.restoreAfterFinish)this.element.setStyle(this.originalStyle);},setDimensions:function(height,width){var d={};if(this.options.scaleX)d.width=width.round()+'px';if(this.options.scaleY)d.height=height.round()+'px';if(this.options.scaleFromCenter){var topd=(height-this.dims[0])/2;var leftd=(width-this.dims[1])/2;if(this.elementPositioning=='absolute'){if(this.options.scaleY)d.top=this.originalTop-topd+'px';if(this.options.scaleX)d.left=this.originalLeft-leftd+'px';}else{if(this.options.scaleY)d.top=-topd+'px';if(this.options.scaleX)d.left=-leftd+'px';}} +this.element.setStyle(d);}});Effect.Highlight=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({startcolor:'#ffff99'},arguments[1]||{});this.start(options);},setup:function(){if(this.element.getStyle('display')=='none'){this.cancel();return;} +this.oldStyle={};if(!this.options.keepBackgroundImage){this.oldStyle.backgroundImage=this.element.getStyle('background-image');this.element.setStyle({backgroundImage:'none'});} +if(!this.options.endcolor) +this.options.endcolor=this.element.getStyle('background-color').parseColor('#ffffff');if(!this.options.restorecolor) +this.options.restorecolor=this.element.getStyle('background-color');this._base=$R(0,2).map(function(i){return parseInt(this.options.startcolor.slice(i*2+1,i*2+3),16)}.bind(this));this._delta=$R(0,2).map(function(i){return parseInt(this.options.endcolor.slice(i*2+1,i*2+3),16)-this._base[i]}.bind(this));},update:function(position){this.element.setStyle({backgroundColor:$R(0,2).inject('#',function(m,v,i){return m+((this._base[i]+(this._delta[i]*position)).round().toColorPart());}.bind(this))});},finish:function(){this.element.setStyle(Object.extend(this.oldStyle,{backgroundColor:this.options.restorecolor}));}});Effect.ScrollTo=function(element){var options=arguments[1]||{},scrollOffsets=document.viewport.getScrollOffsets(),elementOffsets=$(element).cumulativeOffset(),max=(window.height||document.body.scrollHeight)-document.viewport.getHeight();if(options.offset)elementOffsets[1]+=options.offset;return new Effect.Tween(null,scrollOffsets.top,elementOffsets[1]>max?max:elementOffsets[1],options,function(p){scrollTo(scrollOffsets.left,p.round())});};Effect.Fade=function(element){element=$(element);var oldOpacity=element.getInlineOpacity();var options=Object.extend({from:element.getOpacity()||1.0,to:0.0,afterFinishInternal:function(effect){if(effect.options.to!=0)return;effect.element.hide().setStyle({opacity:oldOpacity});}},arguments[1]||{});return new Effect.Opacity(element,options);};Effect.Appear=function(element){element=$(element);var options=Object.extend({from:(element.getStyle('display')=='none'?0.0:element.getOpacity()||0.0),to:1.0,afterFinishInternal:function(effect){effect.element.forceRerendering();},beforeSetup:function(effect){effect.element.setOpacity(effect.options.from).show();}},arguments[1]||{});return new Effect.Opacity(element,options);};Effect.Puff=function(element){element=$(element);var oldStyle={opacity:element.getInlineOpacity(),position:element.getStyle('position'),top:element.style.top,left:element.style.left,width:element.style.width,height:element.style.height};return new Effect.Parallel([new Effect.Scale(element,200,{sync:true,scaleFromCenter:true,scaleContent:true,restoreAfterFinish:true}),new Effect.Opacity(element,{sync:true,to:0.0})],Object.extend({duration:1.0,beforeSetupInternal:function(effect){Position.absolutize(effect.effects[0].element)},afterFinishInternal:function(effect){effect.effects[0].element.hide().setStyle(oldStyle);}},arguments[1]||{}));};Effect.BlindUp=function(element){element=$(element);element.makeClipping();return new Effect.Scale(element,0,Object.extend({scaleContent:false,scaleX:false,restoreAfterFinish:true,afterFinishInternal:function(effect){effect.element.hide().undoClipping();}},arguments[1]||{}));};Effect.BlindDown=function(element){element=$(element);var elementDimensions=element.getDimensions();return new Effect.Scale(element,100,Object.extend({scaleContent:false,scaleX:false,scaleFrom:0,scaleMode:{originalHeight:elementDimensions.height,originalWidth:elementDimensions.width},restoreAfterFinish:true,afterSetup:function(effect){effect.element.makeClipping().setStyle({height:'0px'}).show();},afterFinishInternal:function(effect){effect.element.undoClipping();}},arguments[1]||{}));};Effect.SwitchOff=function(element){element=$(element);var oldOpacity=element.getInlineOpacity();return new Effect.Appear(element,Object.extend({duration:0.4,from:0,transition:Effect.Transitions.flicker,afterFinishInternal:function(effect){new Effect.Scale(effect.element,1,{duration:0.3,scaleFromCenter:true,scaleX:false,scaleContent:false,restoreAfterFinish:true,beforeSetup:function(effect){effect.element.makePositioned().makeClipping();},afterFinishInternal:function(effect){effect.element.hide().undoClipping().undoPositioned().setStyle({opacity:oldOpacity});}})}},arguments[1]||{}));};Effect.DropOut=function(element){element=$(element);var oldStyle={top:element.getStyle('top'),left:element.getStyle('left'),opacity:element.getInlineOpacity()};return new Effect.Parallel([new Effect.Move(element,{x:0,y:100,sync:true}),new Effect.Opacity(element,{sync:true,to:0.0})],Object.extend({duration:0.5,beforeSetup:function(effect){effect.effects[0].element.makePositioned();},afterFinishInternal:function(effect){effect.effects[0].element.hide().undoPositioned().setStyle(oldStyle);}},arguments[1]||{}));};Effect.Shake=function(element){element=$(element);var options=Object.extend({distance:20,duration:0.5},arguments[1]||{});var distance=parseFloat(options.distance);var split=parseFloat(options.duration)/10.0;var oldStyle={top:element.getStyle('top'),left:element.getStyle('left')};return new Effect.Move(element,{x:distance,y:0,duration:split,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:-distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:-distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:-distance,y:0,duration:split,afterFinishInternal:function(effect){effect.element.undoPositioned().setStyle(oldStyle);}})}})}})}})}})}});};Effect.SlideDown=function(element){element=$(element).cleanWhitespace();var oldInnerBottom=element.down().getStyle('bottom');var elementDimensions=element.getDimensions();return new Effect.Scale(element,100,Object.extend({scaleContent:false,scaleX:false,scaleFrom:window.opera?0:1,scaleMode:{originalHeight:elementDimensions.height,originalWidth:elementDimensions.width},restoreAfterFinish:true,afterSetup:function(effect){effect.element.makePositioned();effect.element.down().makePositioned();if(window.opera)effect.element.setStyle({top:''});effect.element.makeClipping().setStyle({height:'0px'}).show();},afterUpdateInternal:function(effect){effect.element.down().setStyle({bottom:(effect.dims[0]-effect.element.clientHeight)+'px'});},afterFinishInternal:function(effect){effect.element.undoClipping().undoPositioned();effect.element.down().undoPositioned().setStyle({bottom:oldInnerBottom});}},arguments[1]||{}));};Effect.SlideUp=function(element){element=$(element).cleanWhitespace();var oldInnerBottom=element.down().getStyle('bottom');var elementDimensions=element.getDimensions();return new Effect.Scale(element,window.opera?0:1,Object.extend({scaleContent:false,scaleX:false,scaleMode:'box',scaleFrom:100,scaleMode:{originalHeight:elementDimensions.height,originalWidth:elementDimensions.width},restoreAfterFinish:true,afterSetup:function(effect){effect.element.makePositioned();effect.element.down().makePositioned();if(window.opera)effect.element.setStyle({top:''});effect.element.makeClipping().show();},afterUpdateInternal:function(effect){effect.element.down().setStyle({bottom:(effect.dims[0]-effect.element.clientHeight)+'px'});},afterFinishInternal:function(effect){effect.element.hide().undoClipping().undoPositioned();effect.element.down().undoPositioned().setStyle({bottom:oldInnerBottom});}},arguments[1]||{}));};Effect.Squish=function(element){return new Effect.Scale(element,window.opera?1:0,{restoreAfterFinish:true,beforeSetup:function(effect){effect.element.makeClipping();},afterFinishInternal:function(effect){effect.element.hide().undoClipping();}});};Effect.Grow=function(element){element=$(element);var options=Object.extend({direction:'center',moveTransition:Effect.Transitions.sinoidal,scaleTransition:Effect.Transitions.sinoidal,opacityTransition:Effect.Transitions.full},arguments[1]||{});var oldStyle={top:element.style.top,left:element.style.left,height:element.style.height,width:element.style.width,opacity:element.getInlineOpacity()};var dims=element.getDimensions();var initialMoveX,initialMoveY;var moveX,moveY;switch(options.direction){case'top-left':initialMoveX=initialMoveY=moveX=moveY=0;break;case'top-right':initialMoveX=dims.width;initialMoveY=moveY=0;moveX=-dims.width;break;case'bottom-left':initialMoveX=moveX=0;initialMoveY=dims.height;moveY=-dims.height;break;case'bottom-right':initialMoveX=dims.width;initialMoveY=dims.height;moveX=-dims.width;moveY=-dims.height;break;case'center':initialMoveX=dims.width/2;initialMoveY=dims.height/2;moveX=-dims.width/2;moveY=-dims.height/2;break;} +return new Effect.Move(element,{x:initialMoveX,y:initialMoveY,duration:0.01,beforeSetup:function(effect){effect.element.hide().makeClipping().makePositioned();},afterFinishInternal:function(effect){new Effect.Parallel([new Effect.Opacity(effect.element,{sync:true,to:1.0,from:0.0,transition:options.opacityTransition}),new Effect.Move(effect.element,{x:moveX,y:moveY,sync:true,transition:options.moveTransition}),new Effect.Scale(effect.element,100,{scaleMode:{originalHeight:dims.height,originalWidth:dims.width},sync:true,scaleFrom:window.opera?1:0,transition:options.scaleTransition,restoreAfterFinish:true})],Object.extend({beforeSetup:function(effect){effect.effects[0].element.setStyle({height:'0px'}).show();},afterFinishInternal:function(effect){effect.effects[0].element.undoClipping().undoPositioned().setStyle(oldStyle);}},options))}});};Effect.Shrink=function(element){element=$(element);var options=Object.extend({direction:'center',moveTransition:Effect.Transitions.sinoidal,scaleTransition:Effect.Transitions.sinoidal,opacityTransition:Effect.Transitions.none},arguments[1]||{});var oldStyle={top:element.style.top,left:element.style.left,height:element.style.height,width:element.style.width,opacity:element.getInlineOpacity()};var dims=element.getDimensions();var moveX,moveY;switch(options.direction){case'top-left':moveX=moveY=0;break;case'top-right':moveX=dims.width;moveY=0;break;case'bottom-left':moveX=0;moveY=dims.height;break;case'bottom-right':moveX=dims.width;moveY=dims.height;break;case'center':moveX=dims.width/2;moveY=dims.height/2;break;} +return new Effect.Parallel([new Effect.Opacity(element,{sync:true,to:0.0,from:1.0,transition:options.opacityTransition}),new Effect.Scale(element,window.opera?1:0,{sync:true,transition:options.scaleTransition,restoreAfterFinish:true}),new Effect.Move(element,{x:moveX,y:moveY,sync:true,transition:options.moveTransition})],Object.extend({beforeStartInternal:function(effect){effect.effects[0].element.makePositioned().makeClipping();},afterFinishInternal:function(effect){effect.effects[0].element.hide().undoClipping().undoPositioned().setStyle(oldStyle);}},options));};Effect.Pulsate=function(element){element=$(element);var options=arguments[1]||{};var oldOpacity=element.getInlineOpacity();var transition=options.transition||Effect.Transitions.sinoidal;var reverser=function(pos){return transition(1-Effect.Transitions.pulse(pos,options.pulses))};reverser.bind(transition);return new Effect.Opacity(element,Object.extend(Object.extend({duration:2.0,from:0,afterFinishInternal:function(effect){effect.element.setStyle({opacity:oldOpacity});}},options),{transition:reverser}));};Effect.Fold=function(element){element=$(element);var oldStyle={top:element.style.top,left:element.style.left,width:element.style.width,height:element.style.height};element.makeClipping();return new Effect.Scale(element,5,Object.extend({scaleContent:false,scaleX:false,afterFinishInternal:function(effect){new Effect.Scale(element,1,{scaleContent:false,scaleY:false,afterFinishInternal:function(effect){effect.element.hide().undoClipping().setStyle(oldStyle);}});}},arguments[1]||{}));};Effect.Morph=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({style:{}},arguments[1]||{});if(!Object.isString(options.style))this.style=$H(options.style);else{if(options.style.include(':')) +this.style=options.style.parseStyle();else{this.element.addClassName(options.style);this.style=$H(this.element.getStyles());this.element.removeClassName(options.style);var css=this.element.getStyles();this.style=this.style.reject(function(style){return style.value==css[style.key];});options.afterFinishInternal=function(effect){effect.element.addClassName(effect.options.style);effect.transforms.each(function(transform){effect.element.style[transform.style]='';});}}} +this.start(options);},setup:function(){function parseColor(color){if(!color||['rgba(0, 0, 0, 0)','transparent'].include(color))color='#ffffff';color=color.parseColor();return $R(0,2).map(function(i){return parseInt(color.slice(i*2+1,i*2+3),16)});} +this.transforms=this.style.map(function(pair){var property=pair[0],value=pair[1],unit=null;if(value.parseColor('#zzzzzz')!='#zzzzzz'){value=value.parseColor();unit='color';}else if(property=='opacity'){value=parseFloat(value);if(Prototype.Browser.IE&&(!this.element.currentStyle.hasLayout)) +this.element.setStyle({zoom:1});}else if(Element.CSS_LENGTH.test(value)){var components=value.match(/^([\+\-]?[0-9\.]+)(.*)$/);value=parseFloat(components[1]);unit=(components.length==3)?components[2]:null;} +var originalValue=this.element.getStyle(property);return{style:property.camelize(),originalValue:unit=='color'?parseColor(originalValue):parseFloat(originalValue||0),targetValue:unit=='color'?parseColor(value):value,unit:unit};}.bind(this)).reject(function(transform){return((transform.originalValue==transform.targetValue)||(transform.unit!='color'&&(isNaN(transform.originalValue)||isNaN(transform.targetValue))))});},update:function(position){var style={},transform,i=this.transforms.length;while(i--) +style[(transform=this.transforms[i]).style]=transform.unit=='color'?'#'+ +(Math.round(transform.originalValue[0]+ +(transform.targetValue[0]-transform.originalValue[0])*position)).toColorPart()+ +(Math.round(transform.originalValue[1]+ +(transform.targetValue[1]-transform.originalValue[1])*position)).toColorPart()+ +(Math.round(transform.originalValue[2]+ +(transform.targetValue[2]-transform.originalValue[2])*position)).toColorPart():(transform.originalValue+ +(transform.targetValue-transform.originalValue)*position).toFixed(3)+ +(transform.unit===null?'':transform.unit);this.element.setStyle(style,true);}});Effect.Transform=Class.create({initialize:function(tracks){this.tracks=[];this.options=arguments[1]||{};this.addTracks(tracks);},addTracks:function(tracks){tracks.each(function(track){track=$H(track);var data=track.values().first();this.tracks.push($H({ids:track.keys().first(),effect:Effect.Morph,options:{style:data}}));}.bind(this));return this;},play:function(){return new Effect.Parallel(this.tracks.map(function(track){var ids=track.get('ids'),effect=track.get('effect'),options=track.get('options');var elements=[$(ids)||$$(ids)].flatten();return elements.map(function(e){return new effect(e,Object.extend({sync:true},options))});}).flatten(),this.options);}});Element.CSS_PROPERTIES=$w('backgroundColor backgroundPosition borderBottomColor borderBottomStyle '+'borderBottomWidth borderLeftColor borderLeftStyle borderLeftWidth '+'borderRightColor borderRightStyle borderRightWidth borderSpacing '+'borderTopColor borderTopStyle borderTopWidth bottom clip color '+'fontSize fontWeight height left letterSpacing lineHeight '+'marginBottom marginLeft marginRight marginTop markerOffset maxHeight '+'maxWidth minHeight minWidth opacity outlineColor outlineOffset '+'outlineWidth paddingBottom paddingLeft paddingRight paddingTop '+'right textIndent top width wordSpacing zIndex');Element.CSS_LENGTH=/^(([\+\-]?[0-9\.]+)(em|ex|px|in|cm|mm|pt|pc|\%))|0$/;String.__parseStyleElement=document.createElement('div');String.prototype.parseStyle=function(){var style,styleRules=$H();if(Prototype.Browser.WebKit) +style=new Element('div',{style:this}).style;else{String.__parseStyleElement.innerHTML='
        ';style=String.__parseStyleElement.childNodes[0].style;} +Element.CSS_PROPERTIES.each(function(property){if(style[property])styleRules.set(property,style[property]);});if(Prototype.Browser.IE&&this.include('opacity')) +styleRules.set('opacity',this.match(/opacity:\s*((?:0|1)?(?:\.\d*)?)/)[1]);return styleRules;};if(document.defaultView&&document.defaultView.getComputedStyle){Element.getStyles=function(element){var css=document.defaultView.getComputedStyle($(element),null);return Element.CSS_PROPERTIES.inject({},function(styles,property){styles[property]=css[property];return styles;});};}else{Element.getStyles=function(element){element=$(element);var css=element.currentStyle,styles;styles=Element.CSS_PROPERTIES.inject({},function(hash,property){hash.set(property,css[property]);return hash;});if(!styles.opacity)styles.set('opacity',element.getOpacity());return styles;};};Effect.Methods={morph:function(element,style){element=$(element);new Effect.Morph(element,Object.extend({style:style},arguments[2]||{}));return element;},visualEffect:function(element,effect,options){element=$(element) +var s=effect.dasherize().camelize(),klass=s.charAt(0).toUpperCase()+s.substring(1);new Effect[klass](element,options);return element;},highlight:function(element,options){element=$(element);new Effect.Highlight(element,options);return element;}};$w('fade appear grow shrink fold blindUp blindDown slideUp slideDown '+'pulsate shake puff squish switchOff dropOut').each(function(effect){Effect.Methods[effect]=function(element,options){element=$(element);Effect[effect.charAt(0).toUpperCase()+effect.substring(1)](element,options);return element;}});$w('getInlineOpacity forceRerendering setContentZoom collectTextNodes collectTextNodesIgnoreClass getStyles').each(function(f){Effect.Methods[f]=Element[f];});Element.addMethods(Effect.Methods);if(Object.isUndefined(Effect)) +throw("dragdrop.js requires including script.aculo.us' effects.js library");var Droppables={drops:[],remove:function(element){this.drops=this.drops.reject(function(d){return d.element==$(element)});},add:function(element){element=$(element);var options=Object.extend({greedy:true,hoverclass:null,tree:false},arguments[1]||{});if(options.containment){options._containers=[];var containment=options.containment;if(Object.isArray(containment)){containment.each(function(c){options._containers.push($(c))});}else{options._containers.push($(containment));}} +if(options.accept)options.accept=[options.accept].flatten();Element.makePositioned(element);options.element=element;this.drops.push(options);},findDeepestChild:function(drops){deepest=drops[0];for(i=1;i0) +drop=Droppables.findDeepestChild(affected);if(this.last_active&&this.last_active!=drop)this.deactivate(this.last_active);if(drop){Position.within(drop.element,point[0],point[1]);if(drop.onHover) +drop.onHover(element,drop.element,Position.overlap(drop.overlap,drop.element));if(drop!=this.last_active)Droppables.activate(drop);}},fire:function(event,element){if(!this.last_active)return;Position.prepare();if(this.isAffected([Event.pointerX(event),Event.pointerY(event)],element,this.last_active)) +if(this.last_active.onDrop){this.last_active.onDrop(element,this.last_active.element,event);return true;}},reset:function(){if(this.last_active) +this.deactivate(this.last_active);}} +var Draggables={drags:[],observers:[],register:function(draggable){if(this.drags.length==0){this.eventMouseUp=this.endDrag.bindAsEventListener(this);this.eventMouseMove=this.updateDrag.bindAsEventListener(this);this.eventKeypress=this.keyPress.bindAsEventListener(this);Event.observe(document,"mouseup",this.eventMouseUp);Event.observe(document,"mousemove",this.eventMouseMove);Event.observe(document,"keypress",this.eventKeypress);} +this.drags.push(draggable);},unregister:function(draggable){this.drags=this.drags.reject(function(d){return d==draggable});if(this.drags.length==0){Event.stopObserving(document,"mouseup",this.eventMouseUp);Event.stopObserving(document,"mousemove",this.eventMouseMove);Event.stopObserving(document,"keypress",this.eventKeypress);}},activate:function(draggable){if(draggable.options.delay){this._timeout=setTimeout(function(){Draggables._timeout=null;window.focus();Draggables.activeDraggable=draggable;}.bind(this),draggable.options.delay);}else{window.focus();this.activeDraggable=draggable;}},deactivate:function(){this.activeDraggable=null;},updateDrag:function(event){if(!this.activeDraggable)return;var pointer=[Event.pointerX(event),Event.pointerY(event)];if(this._lastPointer&&(this._lastPointer.inspect()==pointer.inspect()))return;this._lastPointer=pointer;this.activeDraggable.updateDrag(event,pointer);},endDrag:function(event){if(this._timeout){clearTimeout(this._timeout);this._timeout=null;} +if(!this.activeDraggable)return;this._lastPointer=null;this.activeDraggable.endDrag(event);this.activeDraggable=null;},keyPress:function(event){if(this.activeDraggable) +this.activeDraggable.keyPress(event);},addObserver:function(observer){this.observers.push(observer);this._cacheObserverCallbacks();},removeObserver:function(element){this.observers=this.observers.reject(function(o){return o.element==element});this._cacheObserverCallbacks();},notify:function(eventName,draggable,event){if(this[eventName+'Count']>0) +this.observers.each(function(o){if(o[eventName])o[eventName](eventName,draggable,event);});if(draggable.options[eventName])draggable.options[eventName](draggable,event);},_cacheObserverCallbacks:function(){['onStart','onEnd','onDrag'].each(function(eventName){Draggables[eventName+'Count']=Draggables.observers.select(function(o){return o[eventName];}).length;});}} +var Draggable=Class.create({initialize:function(element){var defaults={handle:false,reverteffect:function(element,top_offset,left_offset){var dur=Math.sqrt(Math.abs(top_offset^2)+Math.abs(left_offset^2))*0.02;new Effect.Move(element,{x:-left_offset,y:-top_offset,duration:dur,queue:{scope:'_draggable',position:'end'}});},endeffect:function(element){var toOpacity=Object.isNumber(element._opacity)?element._opacity:1.0;new Effect.Opacity(element,{duration:0.2,from:0.7,to:toOpacity,queue:{scope:'_draggable',position:'end'},afterFinish:function(){Draggable._dragging[element]=false}});},zindex:1000,revert:false,quiet:false,scroll:false,scrollSensitivity:20,scrollSpeed:15,snap:false,delay:0};if(!arguments[1]||Object.isUndefined(arguments[1].endeffect)) +Object.extend(defaults,{starteffect:function(element){element._opacity=Element.getOpacity(element);Draggable._dragging[element]=true;new Effect.Opacity(element,{duration:0.2,from:element._opacity,to:0.7});}});var options=Object.extend(defaults,arguments[1]||{});this.element=$(element);if(options.handle&&Object.isString(options.handle)) +this.handle=this.element.down('.'+options.handle,0);if(!this.handle)this.handle=$(options.handle);if(!this.handle)this.handle=this.element;if(options.scroll&&!options.scroll.scrollTo&&!options.scroll.outerHTML){options.scroll=$(options.scroll);this._isScrollChild=Element.childOf(this.element,options.scroll);} +Element.makePositioned(this.element);this.options=options;this.dragging=false;this.eventMouseDown=this.initDrag.bindAsEventListener(this);Event.observe(this.handle,"mousedown",this.eventMouseDown);Draggables.register(this);},destroy:function(){Event.stopObserving(this.handle,"mousedown",this.eventMouseDown);Draggables.unregister(this);},currentDelta:function(){return([parseInt(Element.getStyle(this.element,'left')||'0'),parseInt(Element.getStyle(this.element,'top')||'0')]);},initDrag:function(event){if(!Object.isUndefined(Draggable._dragging[this.element])&&Draggable._dragging[this.element])return;if(Event.isLeftClick(event)){var src=Event.element(event);if((tag_name=src.tagName.toUpperCase())&&(tag_name=='INPUT'||tag_name=='SELECT'||tag_name=='OPTION'||tag_name=='BUTTON'||tag_name=='TEXTAREA'))return;var pointer=[Event.pointerX(event),Event.pointerY(event)];var pos=Position.cumulativeOffset(this.element);this.offset=[0,1].map(function(i){return(pointer[i]-pos[i])});Draggables.activate(this);Event.stop(event);}},startDrag:function(event){this.dragging=true;if(!this.delta) +this.delta=this.currentDelta();if(this.options.zindex){this.originalZ=parseInt(Element.getStyle(this.element,'z-index')||0);this.element.style.zIndex=this.options.zindex;} +if(this.options.ghosting){this._clone=this.element.cloneNode(true);this.element._originallyAbsolute=(this.element.getStyle('position')=='absolute');if(!this.element._originallyAbsolute) +Position.absolutize(this.element);this.element.parentNode.insertBefore(this._clone,this.element);} +if(this.options.scroll){if(this.options.scroll==window){var where=this._getWindowScroll(this.options.scroll);this.originalScrollLeft=where.left;this.originalScrollTop=where.top;}else{this.originalScrollLeft=this.options.scroll.scrollLeft;this.originalScrollTop=this.options.scroll.scrollTop;}} +Draggables.notify('onStart',this,event);if(this.options.starteffect)this.options.starteffect(this.element);},updateDrag:function(event,pointer){if(!this.dragging)this.startDrag(event);if(!this.options.quiet){Position.prepare();Droppables.show(pointer,this.element);} +Draggables.notify('onDrag',this,event);this.draw(pointer);if(this.options.change)this.options.change(this);if(this.options.scroll){this.stopScrolling();var p;if(this.options.scroll==window){with(this._getWindowScroll(this.options.scroll)){p=[left,top,left+width,top+height];}}else{p=Position.page(this.options.scroll);p[0]+=this.options.scroll.scrollLeft+Position.deltaX;p[1]+=this.options.scroll.scrollTop+Position.deltaY;p.push(p[0]+this.options.scroll.offsetWidth);p.push(p[1]+this.options.scroll.offsetHeight);} +var speed=[0,0];if(pointer[0]<(p[0]+this.options.scrollSensitivity))speed[0]=pointer[0]-(p[0]+this.options.scrollSensitivity);if(pointer[1]<(p[1]+this.options.scrollSensitivity))speed[1]=pointer[1]-(p[1]+this.options.scrollSensitivity);if(pointer[0]>(p[2]-this.options.scrollSensitivity))speed[0]=pointer[0]-(p[2]-this.options.scrollSensitivity);if(pointer[1]>(p[3]-this.options.scrollSensitivity))speed[1]=pointer[1]-(p[3]-this.options.scrollSensitivity);this.startScrolling(speed);} +if(Prototype.Browser.WebKit)window.scrollBy(0,0);Event.stop(event);},finishDrag:function(event,success){this.dragging=false;if(this.options.quiet){Position.prepare();var pointer=[Event.pointerX(event),Event.pointerY(event)];Droppables.show(pointer,this.element);} +if(this.options.ghosting){if(!this.element._originallyAbsolute) +Position.relativize(this.element);delete this.element._originallyAbsolute;Element.remove(this._clone);this._clone=null;} +var dropped=false;if(success){dropped=Droppables.fire(event,this.element);if(!dropped)dropped=false;} +if(dropped&&this.options.onDropped)this.options.onDropped(this.element);Draggables.notify('onEnd',this,event);var revert=this.options.revert;if(revert&&Object.isFunction(revert))revert=revert(this.element);var d=this.currentDelta();if(revert&&this.options.reverteffect){if(dropped==0||revert!='failure') +this.options.reverteffect(this.element,d[1]-this.delta[1],d[0]-this.delta[0]);}else{this.delta=d;} +if(this.options.zindex) +this.element.style.zIndex=this.originalZ;if(this.options.endeffect) +this.options.endeffect(this.element);Draggables.deactivate(this);Droppables.reset();},keyPress:function(event){if(event.keyCode!=Event.KEY_ESC)return;this.finishDrag(event,false);Event.stop(event);},endDrag:function(event){if(!this.dragging)return;this.stopScrolling();this.finishDrag(event,true);Event.stop(event);},draw:function(point){var pos=Position.cumulativeOffset(this.element);if(this.options.ghosting){var r=Position.realOffset(this.element);pos[0]+=r[0]-Position.deltaX;pos[1]+=r[1]-Position.deltaY;} +var d=this.currentDelta();pos[0]-=d[0];pos[1]-=d[1];if(this.options.scroll&&(this.options.scroll!=window&&this._isScrollChild)){pos[0]-=this.options.scroll.scrollLeft-this.originalScrollLeft;pos[1]-=this.options.scroll.scrollTop-this.originalScrollTop;} +var p=[0,1].map(function(i){return(point[i]-pos[i]-this.offset[i])}.bind(this));if(this.options.snap){if(Object.isFunction(this.options.snap)){p=this.options.snap(p[0],p[1],this);}else{if(Object.isArray(this.options.snap)){p=p.map(function(v,i){return(v/this.options.snap[i]).round()*this.options.snap[i]}.bind(this))}else{p=p.map(function(v){return(v/this.options.snap).round()*this.options.snap}.bind(this))}}} +var style=this.element.style;if((!this.options.constraint)||(this.options.constraint=='horizontal')) +style.left=p[0]+"px";if((!this.options.constraint)||(this.options.constraint=='vertical')) +style.top=p[1]+"px";if(style.visibility=="hidden")style.visibility="";},stopScrolling:function(){if(this.scrollInterval){clearInterval(this.scrollInterval);this.scrollInterval=null;Draggables._lastScrollPointer=null;}},startScrolling:function(speed){if(!(speed[0]||speed[1]))return;this.scrollSpeed=[speed[0]*this.options.scrollSpeed,speed[1]*this.options.scrollSpeed];this.lastScrolled=new Date();this.scrollInterval=setInterval(this.scroll.bind(this),10);},scroll:function(){var current=new Date();var delta=current-this.lastScrolled;this.lastScrolled=current;if(this.options.scroll==window){with(this._getWindowScroll(this.options.scroll)){if(this.scrollSpeed[0]||this.scrollSpeed[1]){var d=delta/1000;this.options.scroll.scrollTo(left+d*this.scrollSpeed[0],top+d*this.scrollSpeed[1]);}}}else{this.options.scroll.scrollLeft+=this.scrollSpeed[0]*delta/1000;this.options.scroll.scrollTop+=this.scrollSpeed[1]*delta/1000;} +Position.prepare();Droppables.show(Draggables._lastPointer,this.element);Draggables.notify('onDrag',this);if(this._isScrollChild){Draggables._lastScrollPointer=Draggables._lastScrollPointer||$A(Draggables._lastPointer);Draggables._lastScrollPointer[0]+=this.scrollSpeed[0]*delta/1000;Draggables._lastScrollPointer[1]+=this.scrollSpeed[1]*delta/1000;if(Draggables._lastScrollPointer[0]<0) +Draggables._lastScrollPointer[0]=0;if(Draggables._lastScrollPointer[1]<0) +Draggables._lastScrollPointer[1]=0;this.draw(Draggables._lastScrollPointer);} +if(this.options.change)this.options.change(this);},_getWindowScroll:function(w){var T,L,W,H;with(w.document){if(w.document.documentElement&&documentElement.scrollTop){T=documentElement.scrollTop;L=documentElement.scrollLeft;}else if(w.document.body){T=body.scrollTop;L=body.scrollLeft;} +if(w.innerWidth){W=w.innerWidth;H=w.innerHeight;}else if(w.document.documentElement&&documentElement.clientWidth){W=documentElement.clientWidth;H=documentElement.clientHeight;}else{W=body.offsetWidth;H=body.offsetHeight}} +return{top:T,left:L,width:W,height:H};}});Draggable._dragging={};var SortableObserver=Class.create({initialize:function(element,observer){this.element=$(element);this.observer=observer;this.lastValue=Sortable.serialize(this.element);},onStart:function(){this.lastValue=Sortable.serialize(this.element);},onEnd:function(){Sortable.unmark();if(this.lastValue!=Sortable.serialize(this.element)) +this.observer(this.element)}});var Sortable={SERIALIZE_RULE:/^[^_\-](?:[A-Za-z0-9\-\_]*)[_](.*)$/,sortables:{},_findRootElement:function(element){while(element.tagName.toUpperCase()!="BODY"){if(element.id&&Sortable.sortables[element.id])return element;element=element.parentNode;}},options:function(element){element=Sortable._findRootElement($(element));if(!element)return;return Sortable.sortables[element.id];},destroy:function(element){var s=Sortable.options(element);if(s){Draggables.removeObserver(s.element);s.droppables.each(function(d){Droppables.remove(d)});s.draggables.invoke('destroy');delete Sortable.sortables[s.element.id];}},create:function(element){element=$(element);var options=Object.extend({element:element,tag:'li',dropOnEmpty:false,tree:false,treeTag:'ul',overlap:'vertical',constraint:'vertical',containment:element,handle:false,only:false,delay:0,hoverclass:null,ghosting:false,quiet:false,scroll:false,scrollSensitivity:20,scrollSpeed:15,format:this.SERIALIZE_RULE,elements:false,handles:false,onChange:Prototype.emptyFunction,onUpdate:Prototype.emptyFunction},arguments[1]||{});this.destroy(element);var options_for_draggable={revert:true,quiet:options.quiet,scroll:options.scroll,scrollSpeed:options.scrollSpeed,scrollSensitivity:options.scrollSensitivity,delay:options.delay,ghosting:options.ghosting,constraint:options.constraint,handle:options.handle};if(options.starteffect) +options_for_draggable.starteffect=options.starteffect;if(options.reverteffect) +options_for_draggable.reverteffect=options.reverteffect;else +if(options.ghosting)options_for_draggable.reverteffect=function(element){element.style.top=0;element.style.left=0;};if(options.endeffect) +options_for_draggable.endeffect=options.endeffect;if(options.zindex) +options_for_draggable.zindex=options.zindex;var options_for_droppable={overlap:options.overlap,containment:options.containment,tree:options.tree,hoverclass:options.hoverclass,onHover:Sortable.onHover} +var options_for_tree={onHover:Sortable.onEmptyHover,overlap:options.overlap,containment:options.containment,hoverclass:options.hoverclass} +Element.cleanWhitespace(element);options.draggables=[];options.droppables=[];if(options.dropOnEmpty||options.tree){Droppables.add(element,options_for_tree);options.droppables.push(element);} +(options.elements||this.findElements(element,options)||[]).each(function(e,i){var handle=options.handles?$(options.handles[i]):(options.handle?$(e).select('.'+options.handle)[0]:e);options.draggables.push(new Draggable(e,Object.extend(options_for_draggable,{handle:handle})));Droppables.add(e,options_for_droppable);if(options.tree)e.treeNode=element;options.droppables.push(e);});if(options.tree){(Sortable.findTreeElements(element,options)||[]).each(function(e){Droppables.add(e,options_for_tree);e.treeNode=element;options.droppables.push(e);});} +this.sortables[element.id]=options;Draggables.addObserver(new SortableObserver(element,options.onUpdate));},findElements:function(element,options){return Element.findChildren(element,options.only,options.tree?true:false,options.tag);},findTreeElements:function(element,options){return Element.findChildren(element,options.only,options.tree?true:false,options.treeTag);},onHover:function(element,dropon,overlap){if(Element.isParent(dropon,element))return;if(overlap>.33&&overlap<.66&&Sortable.options(dropon).tree){return;}else if(overlap>0.5){Sortable.mark(dropon,'before');if(dropon.previousSibling!=element){var oldParentNode=element.parentNode;element.style.visibility="hidden";dropon.parentNode.insertBefore(element,dropon);if(dropon.parentNode!=oldParentNode) +Sortable.options(oldParentNode).onChange(element);Sortable.options(dropon.parentNode).onChange(element);}}else{Sortable.mark(dropon,'after');var nextElement=dropon.nextSibling||null;if(nextElement!=element){var oldParentNode=element.parentNode;element.style.visibility="hidden";dropon.parentNode.insertBefore(element,nextElement);if(dropon.parentNode!=oldParentNode) +Sortable.options(oldParentNode).onChange(element);Sortable.options(dropon.parentNode).onChange(element);}}},onEmptyHover:function(element,dropon,overlap){var oldParentNode=element.parentNode;var droponOptions=Sortable.options(dropon);if(!Element.isParent(dropon,element)){var index;var children=Sortable.findElements(dropon,{tag:droponOptions.tag,only:droponOptions.only});var child=null;if(children){var offset=Element.offsetSize(dropon,droponOptions.overlap)*(1.0-overlap);for(index=0;index=0){offset-=Element.offsetSize(children[index],droponOptions.overlap);}else if(offset-(Element.offsetSize(children[index],droponOptions.overlap)/2)>=0){child=index+1');this.iefix=$(this.update.id+'_iefix');} +if(this.iefix)setTimeout(this.fixIEOverlapping.bind(this),50);},fixIEOverlapping:function(){Position.clone(this.update,this.iefix,{setTop:(!this.update.style.height)});this.iefix.style.zIndex=1;this.update.style.zIndex=2;Element.show(this.iefix);},hide:function(){this.stopIndicator();if(Element.getStyle(this.update,'display')!='none')this.options.onHide(this.element,this.update);if(this.iefix)Element.hide(this.iefix);},startIndicator:function(){if(this.options.indicator)Element.show(this.options.indicator);},stopIndicator:function(){if(this.options.indicator)Element.hide(this.options.indicator);},onKeyPress:function(event){if(this.active) +switch(event.keyCode){case Event.KEY_TAB:case Event.KEY_RETURN:this.selectEntry();Event.stop(event);case Event.KEY_ESC:this.hide();this.active=false;Event.stop(event);return;case Event.KEY_LEFT:case Event.KEY_RIGHT:return;case Event.KEY_UP:this.markPrevious();this.render();Event.stop(event);return;case Event.KEY_DOWN:this.markNext();this.render();Event.stop(event);return;} +else +if(event.keyCode==Event.KEY_TAB||event.keyCode==Event.KEY_RETURN||(Prototype.Browser.WebKit>0&&event.keyCode==0))return;this.changed=true;this.hasFocus=true;if(this.observer)clearTimeout(this.observer);this.observer=setTimeout(this.onObserverEvent.bind(this),this.options.frequency*1000);},activate:function(){this.changed=false;this.hasFocus=true;this.getUpdatedChoices();},onHover:function(event){var element=Event.findElement(event,'LI');if(this.index!=element.autocompleteIndex) +{this.index=element.autocompleteIndex;this.render();} +Event.stop(event);},onClick:function(event){var element=Event.findElement(event,'LI');this.index=element.autocompleteIndex;this.selectEntry();this.hide();},onBlur:function(event){setTimeout(this.hide.bind(this),250);this.hasFocus=false;this.active=false;},render:function(){if(this.entryCount>0){for(var i=0;i0)this.index-- +else this.index=this.entryCount-1;this.getEntry(this.index).scrollIntoView(true);},markNext:function(){if(this.index0)value=Element.collectTextNodes(nodes[0],this.options.select);}else +value=Element.collectTextNodesIgnoreClass(selectedElement,'informal');var bounds=this.getTokenBounds();if(bounds[0]!=-1){var newValue=this.element.value.substr(0,bounds[0]);var whitespace=this.element.value.substr(bounds[0]).match(/^\s+/);if(whitespace) +newValue+=whitespace[0];this.element.value=newValue+value+this.element.value.substr(bounds[1]);}else{this.element.value=value;} +this.oldElementValue=this.element.value;this.element.focus();if(this.options.afterUpdateElement) +this.options.afterUpdateElement(this.element,selectedElement);},updateChoices:function(choices){if(!this.changed&&this.hasFocus){this.update.innerHTML=choices;Element.cleanWhitespace(this.update);Element.cleanWhitespace(this.update.down());if(this.update.firstChild&&this.update.down().childNodes){this.entryCount=this.update.down().childNodes.length;for(var i=0;i=this.options.minChars){this.getUpdatedChoices();}else{this.active=false;this.hide();} +this.oldElementValue=this.element.value;},getToken:function(){var bounds=this.getTokenBounds();return this.element.value.substring(bounds[0],bounds[1]).strip();},getTokenBounds:function(){if(null!=this.tokenBounds)return this.tokenBounds;var value=this.element.value;if(value.strip().empty())return[-1,0];var diff=arguments.callee.getFirstDifferencePos(value,this.oldElementValue);var offset=(diff==this.oldElementValue.length?1:0);var prevTokenPos=-1,nextTokenPos=value.length;var tp;for(var index=0,l=this.options.tokens.length;indexprevTokenPos)prevTokenPos=tp;tp=value.indexOf(this.options.tokens[index],diff+offset);if(-1!=tp&&tp"+elem.substr(0,entry.length)+""+ +elem.substr(entry.length)+"");break;}else if(entry.length>=instance.options.partialChars&&instance.options.partialSearch&&foundPos!=-1){if(instance.options.fullSearch||/\s/.test(elem.substr(foundPos-1,1))){partial.push("
      3. "+elem.substr(0,foundPos)+""+ +elem.substr(foundPos,entry.length)+""+elem.substr(foundPos+entry.length)+"
      4. ");break;}} +foundPos=instance.options.ignoreCase?elem.toLowerCase().indexOf(entry.toLowerCase(),foundPos+1):elem.indexOf(entry,foundPos+1);}} +if(partial.length) +ret=ret.concat(partial.slice(0,instance.options.choices-ret.length)) +return"
          "+ret.join('')+"
        ";}},options||{});}});Field.scrollFreeActivate=function(field){setTimeout(function(){Field.activate(field);},1);} +Ajax.InPlaceEditor=Class.create({initialize:function(element,url,options){this.url=url;this.element=element=$(element);this.prepareOptions();this._controls={};arguments.callee.dealWithDeprecatedOptions(options);Object.extend(this.options,options||{});if(!this.options.formId&&this.element.id){this.options.formId=this.element.id+'-inplaceeditor';if($(this.options.formId)) +this.options.formId='';} +if(this.options.externalControl) +this.options.externalControl=$(this.options.externalControl);if(!this.options.externalControl) +this.options.externalControlOnly=false;this._originalBackground=this.element.getStyle('background-color')||'transparent';this.element.title=this.options.clickToEditText;this._boundCancelHandler=this.handleFormCancellation.bind(this);this._boundComplete=(this.options.onComplete||Prototype.emptyFunction).bind(this);this._boundFailureHandler=this.handleAJAXFailure.bind(this);this._boundSubmitHandler=this.handleFormSubmission.bind(this);this._boundWrapperHandler=this.wrapUp.bind(this);this.registerListeners();},checkForEscapeOrReturn:function(e){if(!this._editing||e.ctrlKey||e.altKey||e.shiftKey)return;if(Event.KEY_ESC==e.keyCode) +this.handleFormCancellation(e);else if(Event.KEY_RETURN==e.keyCode) +this.handleFormSubmission(e);},createControl:function(mode,handler,extraClasses){var control=this.options[mode+'Control'];var text=this.options[mode+'Text'];if('button'==control){var btn=document.createElement('input');btn.type='submit';btn.value=text;btn.className='editor_'+mode+'_button';if('cancel'==mode) +btn.onclick=this._boundCancelHandler;this._form.appendChild(btn);this._controls[mode]=btn;}else if('link'==control){var link=document.createElement('a');link.href='#';link.appendChild(document.createTextNode(text));link.onclick='cancel'==mode?this._boundCancelHandler:this._boundSubmitHandler;link.className='editor_'+mode+'_link';if(extraClasses) +link.className+=' '+extraClasses;this._form.appendChild(link);this._controls[mode]=link;}},createEditField:function(){var text=(this.options.loadTextURL?this.options.loadingText:this.getText());var fld;if(1>=this.options.rows&&!/\r|\n/.test(this.getText())){fld=document.createElement('input');fld.type='text';var size=this.options.size||this.options.cols||0;if(0=this.options.rows?this.options.autoRows:this.options.rows);fld.cols=this.options.cols||40;} +fld.name=this.options.paramName;fld.value=text;fld.className='editor_field';if(this.options.submitOnBlur) +fld.onblur=this._boundSubmitHandler;this._controls.editor=fld;if(this.options.loadTextURL) +this.loadExternalText();this._form.appendChild(this._controls.editor);},createForm:function(){var ipe=this;function addText(mode,condition){var text=ipe.options['text'+mode+'Controls'];if(!text||condition===false)return;ipe._form.appendChild(document.createTextNode(text));};this._form=$(document.createElement('form'));this._form.id=this.options.formId;this._form.addClassName(this.options.formClassName);this._form.onsubmit=this._boundSubmitHandler;this.createEditField();if('textarea'==this._controls.editor.tagName.toLowerCase()) +this._form.appendChild(document.createElement('br'));if(this.options.onFormCustomization) +this.options.onFormCustomization(this,this._form);addText('Before',this.options.okControl||this.options.cancelControl);this.createControl('ok',this._boundSubmitHandler);addText('Between',this.options.okControl&&this.options.cancelControl);this.createControl('cancel',this._boundCancelHandler,'editor_cancel');addText('After',this.options.okControl||this.options.cancelControl);},destroy:function(){if(this._oldInnerHTML) +this.element.innerHTML=this._oldInnerHTML;this.leaveEditMode();this.unregisterListeners();},enterEditMode:function(e){if(this._saving||this._editing)return;this._editing=true;this.triggerCallback('onEnterEditMode');if(this.options.externalControl) +this.options.externalControl.hide();this.element.hide();this.createForm();this.element.parentNode.insertBefore(this._form,this.element);if(!this.options.loadTextURL) +this.postProcessEditField();if(e)Event.stop(e);},enterHover:function(e){if(this.options.hoverClassName) +this.element.addClassName(this.options.hoverClassName);if(this._saving)return;this.triggerCallback('onEnterHover');},getText:function(){return this.element.innerHTML;},handleAJAXFailure:function(transport){this.triggerCallback('onFailure',transport);if(this._oldInnerHTML){this.element.innerHTML=this._oldInnerHTML;this._oldInnerHTML=null;}},handleFormCancellation:function(e){this.wrapUp();if(e)Event.stop(e);},handleFormSubmission:function(e){var form=this._form;var value=$F(this._controls.editor);this.prepareSubmission();var params=this.options.callback(form,value)||'';if(Object.isString(params)) +params=params.toQueryParams();params.editorId=this.element.id;if(this.options.htmlResponse){var options=Object.extend({evalScripts:true},this.options.ajaxOptions);Object.extend(options,{parameters:params,onComplete:this._boundWrapperHandler,onFailure:this._boundFailureHandler});new Ajax.Updater({success:this.element},this.url,options);}else{var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:params,onComplete:this._boundWrapperHandler,onFailure:this._boundFailureHandler});new Ajax.Request(this.url,options);} +if(e)Event.stop(e);},leaveEditMode:function(){this.element.removeClassName(this.options.savingClassName);this.removeForm();this.leaveHover();this.element.style.backgroundColor=this._originalBackground;this.element.show();if(this.options.externalControl) +this.options.externalControl.show();this._saving=false;this._editing=false;this._oldInnerHTML=null;this.triggerCallback('onLeaveEditMode');},leaveHover:function(e){if(this.options.hoverClassName) +this.element.removeClassName(this.options.hoverClassName);if(this._saving)return;this.triggerCallback('onLeaveHover');},loadExternalText:function(){this._form.addClassName(this.options.loadingClassName);this._controls.editor.disabled=true;var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:'editorId='+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){this._form.removeClassName(this.options.loadingClassName);var text=transport.responseText;if(this.options.stripLoadedTextTags) +text=text.stripTags();this._controls.editor.value=text;this._controls.editor.disabled=false;this.postProcessEditField();}.bind(this),onFailure:this._boundFailureHandler});new Ajax.Request(this.options.loadTextURL,options);},postProcessEditField:function(){var fpc=this.options.fieldPostCreation;if(fpc) +$(this._controls.editor)['focus'==fpc?'focus':'activate']();},prepareOptions:function(){this.options=Object.clone(Ajax.InPlaceEditor.DefaultOptions);Object.extend(this.options,Ajax.InPlaceEditor.DefaultCallbacks);[this._extraDefaultOptions].flatten().compact().each(function(defs){Object.extend(this.options,defs);}.bind(this));},prepareSubmission:function(){this._saving=true;this.removeForm();this.leaveHover();this.showSaving();},registerListeners:function(){this._listeners={};var listener;$H(Ajax.InPlaceEditor.Listeners).each(function(pair){listener=this[pair.value].bind(this);this._listeners[pair.key]=listener;if(!this.options.externalControlOnly) +this.element.observe(pair.key,listener);if(this.options.externalControl) +this.options.externalControl.observe(pair.key,listener);}.bind(this));},removeForm:function(){if(!this._form)return;this._form.remove();this._form=null;this._controls={};},showSaving:function(){this._oldInnerHTML=this.element.innerHTML;this.element.innerHTML=this.options.savingText;this.element.addClassName(this.options.savingClassName);this.element.style.backgroundColor=this._originalBackground;this.element.show();},triggerCallback:function(cbName,arg){if('function'==typeof this.options[cbName]){this.options[cbName](this,arg);}},unregisterListeners:function(){$H(this._listeners).each(function(pair){if(!this.options.externalControlOnly) +this.element.stopObserving(pair.key,pair.value);if(this.options.externalControl) +this.options.externalControl.stopObserving(pair.key,pair.value);}.bind(this));},wrapUp:function(transport){this.leaveEditMode();this._boundComplete(transport,this.element);}});Object.extend(Ajax.InPlaceEditor.prototype,{dispose:Ajax.InPlaceEditor.prototype.destroy});Ajax.InPlaceCollectionEditor=Class.create(Ajax.InPlaceEditor,{initialize:function($super,element,url,options){this._extraDefaultOptions=Ajax.InPlaceCollectionEditor.DefaultOptions;$super(element,url,options);},createEditField:function(){var list=document.createElement('select');list.name=this.options.paramName;list.size=1;this._controls.editor=list;this._collection=this.options.collection||[];if(this.options.loadCollectionURL) +this.loadCollection();else +this.checkForExternalText();this._form.appendChild(this._controls.editor);},loadCollection:function(){this._form.addClassName(this.options.loadingClassName);this.showLoadingText(this.options.loadingCollectionText);var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:'editorId='+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){var js=transport.responseText.strip();if(!/^\[.*\]$/.test(js)) +throw'Server returned an invalid collection representation.';this._collection=eval(js);this.checkForExternalText();}.bind(this),onFailure:this.onFailure});new Ajax.Request(this.options.loadCollectionURL,options);},showLoadingText:function(text){this._controls.editor.disabled=true;var tempOption=this._controls.editor.firstChild;if(!tempOption){tempOption=document.createElement('option');tempOption.value='';this._controls.editor.appendChild(tempOption);tempOption.selected=true;} +tempOption.update((text||'').stripScripts().stripTags());},checkForExternalText:function(){this._text=this.getText();if(this.options.loadTextURL) +this.loadExternalText();else +this.buildOptionList();},loadExternalText:function(){this.showLoadingText(this.options.loadingText);var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:'editorId='+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){this._text=transport.responseText.strip();this.buildOptionList();}.bind(this),onFailure:this.onFailure});new Ajax.Request(this.options.loadTextURL,options);},buildOptionList:function(){this._form.removeClassName(this.options.loadingClassName);this._collection=this._collection.map(function(entry){return 2===entry.length?entry:[entry,entry].flatten();});var marker=('value'in this.options)?this.options.value:this._text;var textFound=this._collection.any(function(entry){return entry[0]==marker;}.bind(this));this._controls.editor.update('');var option;this._collection.each(function(entry,index){option=document.createElement('option');option.value=entry[0];option.selected=textFound?entry[0]==marker:0==index;option.appendChild(document.createTextNode(entry[1]));this._controls.editor.appendChild(option);}.bind(this));this._controls.editor.disabled=false;Field.scrollFreeActivate(this._controls.editor);}});Ajax.InPlaceEditor.prototype.initialize.dealWithDeprecatedOptions=function(options){if(!options)return;function fallback(name,expr){if(name in options||expr===undefined)return;options[name]=expr;};fallback('cancelControl',(options.cancelLink?'link':(options.cancelButton?'button':options.cancelLink==options.cancelButton==false?false:undefined)));fallback('okControl',(options.okLink?'link':(options.okButton?'button':options.okLink==options.okButton==false?false:undefined)));fallback('highlightColor',options.highlightcolor);fallback('highlightEndColor',options.highlightendcolor);};Object.extend(Ajax.InPlaceEditor,{DefaultOptions:{ajaxOptions:{},autoRows:3,cancelControl:'link',cancelText:'cancel',clickToEditText:'Click to edit',externalControl:null,externalControlOnly:false,fieldPostCreation:'activate',formClassName:'inplaceeditor-form',formId:null,highlightColor:'#ffff99',highlightEndColor:'#ffffff',hoverClassName:'',htmlResponse:true,loadingClassName:'inplaceeditor-loading',loadingText:'Loading...',okControl:'button',okText:'ok',paramName:'value',rows:1,savingClassName:'inplaceeditor-saving',savingText:'Saving...',size:0,stripLoadedTextTags:false,submitOnBlur:false,textAfterControls:'',textBeforeControls:'',textBetweenControls:''},DefaultCallbacks:{callback:function(form){return Form.serialize(form);},onComplete:function(transport,element){new Effect.Highlight(element,{startcolor:this.options.highlightColor,keepBackgroundImage:true});},onEnterEditMode:null,onEnterHover:function(ipe){ipe.element.style.backgroundColor=ipe.options.highlightColor;if(ipe._effect) +ipe._effect.cancel();},onFailure:function(transport,ipe){alert('Error communication with the server: '+transport.responseText.stripTags());},onFormCustomization:null,onLeaveEditMode:null,onLeaveHover:function(ipe){ipe._effect=new Effect.Highlight(ipe.element,{startcolor:ipe.options.highlightColor,endcolor:ipe.options.highlightEndColor,restorecolor:ipe._originalBackground,keepBackgroundImage:true});}},Listeners:{click:'enterEditMode',keydown:'checkForEscapeOrReturn',mouseover:'enterHover',mouseout:'leaveHover'}});Ajax.InPlaceCollectionEditor.DefaultOptions={loadingCollectionText:'Loading options...'};Form.Element.DelayedObserver=Class.create({initialize:function(element,delay,callback){this.delay=delay||0.5;this.element=$(element);this.callback=callback;this.timer=null;this.lastValue=$F(this.element);Event.observe(this.element,'keyup',this.delayedListener.bindAsEventListener(this));},delayedListener:function(event){if(this.lastValue==$F(this.element))return;if(this.timer)clearTimeout(this.timer);this.timer=setTimeout(this.onTimerEvent.bind(this),this.delay*1000);this.lastValue=$F(this.element);},onTimerEvent:function(){this.timer=null;this.callback(this.element,$F(this.element));}});var Login={showOpenid:function(){if($('database_auth_form'))$('database_auth_form').hide();if($('openid_auth_form'))$('openid_auth_form').show();if($('alternate_auth_openid'))$('alternate_auth_openid').hide();if($('alternate_auth_database'))$('alternate_auth_database').show();if($('openid_url'))$('openid_url').focus();if($('openid_url'))$('openid_url').select();new CookieManager().setCookie('preferred_auth','openid');},showDatabase:function(container){if($('openid_auth_form'))$('openid_auth_form').hide();if($('database_auth_form'))$('database_auth_form').show();if($('alternate_auth_database'))$('alternate_auth_database').hide();if($('alternate_auth_openid'))$('alternate_auth_openid').show();if($('user_login'))$('user_login').focus();if($('user_login'))$('user_login').select();new CookieManager().setCookie('preferred_auth','database');}} +var TracksForm={toggle:function(toggleDivId,formContainerId,formId,hideLinkText,hideLinkTitle,showLinkText,showLinkTitle){$(formContainerId).toggle();toggleDiv=$(toggleDivId);toggleLink=toggleDiv.down('a');if(toggleDiv.hasClassName('hide_form')){toggleLink.update(showLinkText).setAttribute('title',showLinkTitle);} +else{toggleLink.update(hideLinkText).setAttribute('title',hideLinkTitle);Form.focusFirstElement(formId);} +toggleDiv.toggleClassName('hide_form');}} +Event.observe(window,'load',function(){$A(document.getElementsByClassName('alert')).each(function(o){o.opacity=100.0 +Effect.Fade(o,{duration:8.0})});});CookieManager=Class.create();CookieManager.prototype={BROWSER_IS_IE:(document.all&&window.ActiveXObject&&navigator.userAgent.toLowerCase().indexOf("msie")>-1&&navigator.userAgent.toLowerCase().indexOf("opera")==-1),BROWSER_IS_OPERA:(navigator.userAgent.toLowerCase().indexOf("opera")!=-1),initialize:function(options) +{this.options=Object.extend({shelfLife:365,userData:false},options||{});this.cookieShelfLife=this.options.shelfLife;this.userDataForIE=this.options.userData;if(this.BROWSER_IS_IE&&this.userDataForIE) +{this.IE_CACHE_NAME="storage";if($(this.IE_CACHE_NAME)==null) +{var div=document.createElement("DIV");div.id=this.IE_CACHE_NAME;document.body.appendChild(div);} +this.store=$(this.IE_CACHE_NAME);this.store.style.behavior="url('#default#userData')";}},getCookie:function(aCookieName) +{var result=null;if(this.BROWSER_IS_IE&&this.userDataForIE) +{this.store.load(this.IE_CACHE_NAME);result=this.store.getAttribute(aCookieName);} +else +{for(var i=0;i=0;i--){var s=["*","",[]];var t=stack[i];var cursor=t.length-1;do{var d=t.lastIndexOf("#");var p=t.lastIndexOf(".");cursor=Math.max(d,p);if(cursor==-1){s[0]=t.toUpperCase();}else if(d==-1||p==cursor){s[2].push(t.substring(p+1));}else if(!s[1]){s[1]=t.substring(d+1);} +t=t.substring(0,cursor);}while(cursor>0);this.s[i]=s;}},get:function(root){this.explore(root||document,this.i==(this.s.length-1));return this.r;},explore:function(elt,leaf){var s=this.s[this.i];var r=[];if(s[1]){e=$(s[1]);if(e&&(s[0]=="*"||e.tagName==s[0])&&e.childOf(elt)){r=[e];}}else{r=$A(elt.getElementsByTagName(s[0]));} +if(s[2].length==1){r=r.findAll(function(o){if(o.className.indexOf(" ")==-1){return o.className==s[2][0];}else{return o.className.split(/\s+/).include(s[2][0]);}});}else if(s[2].length>0){r=r.findAll(function(o){if(o.className.indexOf(" ")==-1){return false;}else{var q=o.className.split(/\s+/);return s[2].all(function(c){return q.include(c);});}});} +if(leaf){this.r=this.r.concat(r);}else{++this.i;r.each(function(o){this.explore(o,this.i==(this.s.length-1));}.bind(this));}}} +var $$old=$$;var $$=function(a,b){if(b||a.indexOf("[")>=0)return $$old.apply(this,arguments);return new SelectorLiteAddon(a.split(/\s+/)).get();} +Calendar=function(firstDayOfWeek,dateStr,onSelected,onClose){this.activeDiv=null;this.currentDateEl=null;this.getDateStatus=null;this.getDateToolTip=null;this.getDateText=null;this.timeout=null;this.onSelected=onSelected||null;this.onClose=onClose||null;this.dragging=false;this.hidden=false;this.minYear=1970;this.maxYear=2050;this.dateFormat=Calendar._TT["DEF_DATE_FORMAT"];this.ttDateFormat=Calendar._TT["TT_DATE_FORMAT"];this.isPopup=true;this.weekNumbers=true;this.firstDayOfWeek=typeof firstDayOfWeek=="number"?firstDayOfWeek:Calendar._FD;this.showsOtherMonths=false;this.dateStr=dateStr;this.ar_days=null;this.showsTime=false;this.time24=true;this.yearStep=2;this.hiliteToday=true;this.multiple=null;this.table=null;this.element=null;this.tbody=null;this.firstdayname=null;this.monthsCombo=null;this.yearsCombo=null;this.hilitedMonth=null;this.activeMonth=null;this.hilitedYear=null;this.activeYear=null;this.dateClicked=false;if(typeof Calendar._SDN=="undefined"){if(typeof Calendar._SDN_len=="undefined") +Calendar._SDN_len=3;var ar=new Array();for(var i=8;i>0;){ar[--i]=Calendar._DN[i].substr(0,Calendar._SDN_len);} +Calendar._SDN=ar;if(typeof Calendar._SMN_len=="undefined") +Calendar._SMN_len=3;ar=new Array();for(var i=12;i>0;){ar[--i]=Calendar._MN[i].substr(0,Calendar._SMN_len);} +Calendar._SMN=ar;}};Calendar._C=null;Calendar.is_ie=(/msie/i.test(navigator.userAgent)&&!/opera/i.test(navigator.userAgent));Calendar.is_ie5=(Calendar.is_ie&&/msie 5\.0/i.test(navigator.userAgent));Calendar.is_opera=/opera/i.test(navigator.userAgent);Calendar.is_khtml=/Konqueror|Safari|KHTML/i.test(navigator.userAgent);Calendar.getAbsolutePos=function(el){var SL=0,ST=0;var is_div=/^div$/i.test(el.tagName);if(is_div&&el.scrollLeft) +SL=el.scrollLeft;if(is_div&&el.scrollTop) +ST=el.scrollTop;var r={x:el.offsetLeft-SL,y:el.offsetTop-ST};if(el.offsetParent){var tmp=this.getAbsolutePos(el.offsetParent);r.x+=tmp.x;r.y+=tmp.y;} +return r;};Calendar.isRelated=function(el,evt){var related=evt.relatedTarget;if(!related){var type=evt.type;if(type=="mouseover"){related=evt.fromElement;}else if(type=="mouseout"){related=evt.toElement;}} +while(related){if(related==el){return true;} +related=related.parentNode;} +return false;};Calendar.removeClass=function(el,className){if(!(el&&el.className)){return;} +var cls=el.className.split(" ");var ar=new Array();for(var i=cls.length;i>0;){if(cls[--i]!=className){ar[ar.length]=cls[i];}} +el.className=ar.join(" ");};Calendar.addClass=function(el,className){Calendar.removeClass(el,className);el.className+=" "+className;};Calendar.getElement=function(ev){var f=Calendar.is_ie?window.event.srcElement:ev.currentTarget;while(f.nodeType!=1||/^div$/i.test(f.tagName)) +f=f.parentNode;return f;};Calendar.getTargetElement=function(ev){var f=Calendar.is_ie?window.event.srcElement:ev.target;while(f.nodeType!=1) +f=f.parentNode;return f;};Calendar.stopEvent=function(ev){ev||(ev=window.event);if(Calendar.is_ie){ev.cancelBubble=true;ev.returnValue=false;}else{ev.preventDefault();ev.stopPropagation();} +return false;};Calendar.addEvent=function(el,evname,func){if(el.attachEvent){el.attachEvent("on"+evname,func);}else if(el.addEventListener){el.addEventListener(evname,func,true);}else{el["on"+evname]=func;}};Calendar.removeEvent=function(el,evname,func){if(el.detachEvent){el.detachEvent("on"+evname,func);}else if(el.removeEventListener){el.removeEventListener(evname,func,true);}else{el["on"+evname]=null;}};Calendar.createElement=function(type,parent){var el=null;if(document.createElementNS){el=document.createElementNS("http://www.w3.org/1999/xhtml",type);}else{el=document.createElement(type);} +if(typeof parent!="undefined"){parent.appendChild(el);} +return el;};Calendar._add_evs=function(el){with(Calendar){addEvent(el,"mouseover",dayMouseOver);addEvent(el,"mousedown",dayMouseDown);addEvent(el,"mouseout",dayMouseOut);if(is_ie){addEvent(el,"dblclick",dayMouseDblClick);el.setAttribute("unselectable",true);}}};Calendar.findMonth=function(el){if(typeof el.month!="undefined"){return el;}else if(typeof el.parentNode.month!="undefined"){return el.parentNode;} +return null;};Calendar.findYear=function(el){if(typeof el.year!="undefined"){return el;}else if(typeof el.parentNode.year!="undefined"){return el.parentNode;} +return null;};Calendar.showMonthsCombo=function(){var cal=Calendar._C;if(!cal){return false;} +var cal=cal;var cd=cal.activeDiv;var mc=cal.monthsCombo;if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");} +if(cal.activeMonth){Calendar.removeClass(cal.activeMonth,"active");} +var mon=cal.monthsCombo.getElementsByTagName("div")[cal.date.getMonth()];Calendar.addClass(mon,"active");cal.activeMonth=mon;var s=mc.style;s.display="block";if(cd.navtype<0) +s.left=cd.offsetLeft+"px";else{var mcw=mc.offsetWidth;if(typeof mcw=="undefined") +mcw=50;s.left=(cd.offsetLeft+cd.offsetWidth-mcw)+"px";} +s.top=(cd.offsetTop+cd.offsetHeight)+"px";};Calendar.showYearsCombo=function(fwd){var cal=Calendar._C;if(!cal){return false;} +var cal=cal;var cd=cal.activeDiv;var yc=cal.yearsCombo;if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");} +if(cal.activeYear){Calendar.removeClass(cal.activeYear,"active");} +cal.activeYear=null;var Y=cal.date.getFullYear()+(fwd?1:-1);var yr=yc.firstChild;var show=false;for(var i=12;i>0;--i){if(Y>=cal.minYear&&Y<=cal.maxYear){yr.innerHTML=Y;yr.year=Y;yr.style.display="block";show=true;}else{yr.style.display="none";} +yr=yr.nextSibling;Y+=fwd?cal.yearStep:-cal.yearStep;} +if(show){var s=yc.style;s.display="block";if(cd.navtype<0) +s.left=cd.offsetLeft+"px";else{var ycw=yc.offsetWidth;if(typeof ycw=="undefined") +ycw=50;s.left=(cd.offsetLeft+cd.offsetWidth-ycw)+"px";} +s.top=(cd.offsetTop+cd.offsetHeight)+"px";}};Calendar.tableMouseUp=function(ev){var cal=Calendar._C;if(!cal){return false;} +if(cal.timeout){clearTimeout(cal.timeout);} +var el=cal.activeDiv;if(!el){return false;} +var target=Calendar.getTargetElement(ev);ev||(ev=window.event);Calendar.removeClass(el,"active");if(target==el||target.parentNode==el){Calendar.cellClick(el,ev);} +var mon=Calendar.findMonth(target);var date=null;if(mon){date=new Date(cal.date);if(mon.month!=date.getMonth()){date.setMonth(mon.month);cal.setDate(date);cal.dateClicked=false;cal.callHandler();}}else{var year=Calendar.findYear(target);if(year){date=new Date(cal.date);if(year.year!=date.getFullYear()){date.setFullYear(year.year);cal.setDate(date);cal.dateClicked=false;cal.callHandler();}}} +with(Calendar){removeEvent(document,"mouseup",tableMouseUp);removeEvent(document,"mouseover",tableMouseOver);removeEvent(document,"mousemove",tableMouseOver);cal._hideCombos();_C=null;return stopEvent(ev);}};Calendar.tableMouseOver=function(ev){var cal=Calendar._C;if(!cal){return;} +var el=cal.activeDiv;var target=Calendar.getTargetElement(ev);if(target==el||target.parentNode==el){Calendar.addClass(el,"hilite active");Calendar.addClass(el.parentNode,"rowhilite");}else{if(typeof el.navtype=="undefined"||(el.navtype!=50&&(el.navtype==0||Math.abs(el.navtype)>2))) +Calendar.removeClass(el,"active");Calendar.removeClass(el,"hilite");Calendar.removeClass(el.parentNode,"rowhilite");} +ev||(ev=window.event);if(el.navtype==50&&target!=el){var pos=Calendar.getAbsolutePos(el);var w=el.offsetWidth;var x=ev.clientX;var dx;var decrease=true;if(x>pos.x+w){dx=x-pos.x-w;decrease=false;}else +dx=pos.x-x;if(dx<0)dx=0;var range=el._range;var current=el._current;var count=Math.floor(dx/10)%range.length;for(var i=range.length;--i>=0;) +if(range[i]==current) +break;while(count-->0) +if(decrease){if(--i<0) +i=range.length-1;}else if(++i>=range.length) +i=0;var newval=range[i];el.innerHTML=newval;cal.onUpdateTime();} +var mon=Calendar.findMonth(target);if(mon){if(mon.month!=cal.date.getMonth()){if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");} +Calendar.addClass(mon,"hilite");cal.hilitedMonth=mon;}else if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");}}else{if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");} +var year=Calendar.findYear(target);if(year){if(year.year!=cal.date.getFullYear()){if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");} +Calendar.addClass(year,"hilite");cal.hilitedYear=year;}else if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");}}else if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");}} +return Calendar.stopEvent(ev);};Calendar.tableMouseDown=function(ev){if(Calendar.getTargetElement(ev)==Calendar.getElement(ev)){return Calendar.stopEvent(ev);}};Calendar.calDragIt=function(ev){var cal=Calendar._C;if(!(cal&&cal.dragging)){return false;} +var posX;var posY;if(Calendar.is_ie){posY=window.event.clientY+document.body.scrollTop;posX=window.event.clientX+document.body.scrollLeft;}else{posX=ev.pageX;posY=ev.pageY;} +cal.hideShowCovered();var st=cal.element.style;st.left=(posX-cal.xOffs)+"px";st.top=(posY-cal.yOffs)+"px";return Calendar.stopEvent(ev);};Calendar.calDragEnd=function(ev){var cal=Calendar._C;if(!cal){return false;} +cal.dragging=false;with(Calendar){removeEvent(document,"mousemove",calDragIt);removeEvent(document,"mouseup",calDragEnd);tableMouseUp(ev);} +cal.hideShowCovered();};Calendar.dayMouseDown=function(ev){var el=Calendar.getElement(ev);if(el.disabled){return false;} +var cal=el.calendar;cal.activeDiv=el;Calendar._C=cal;if(el.navtype!=300)with(Calendar){if(el.navtype==50){el._current=el.innerHTML;addEvent(document,"mousemove",tableMouseOver);}else +addEvent(document,Calendar.is_ie5?"mousemove":"mouseover",tableMouseOver);addClass(el,"hilite active");addEvent(document,"mouseup",tableMouseUp);}else if(cal.isPopup){cal._dragStart(ev);} +if(el.navtype==-1||el.navtype==1){if(cal.timeout)clearTimeout(cal.timeout);cal.timeout=setTimeout("Calendar.showMonthsCombo()",250);}else if(el.navtype==-2||el.navtype==2){if(cal.timeout)clearTimeout(cal.timeout);cal.timeout=setTimeout((el.navtype>0)?"Calendar.showYearsCombo(true)":"Calendar.showYearsCombo(false)",250);}else{cal.timeout=null;} +return Calendar.stopEvent(ev);};Calendar.dayMouseDblClick=function(ev){Calendar.cellClick(Calendar.getElement(ev),ev||window.event);if(Calendar.is_ie){document.selection.empty();}};Calendar.dayMouseOver=function(ev){var el=Calendar.getElement(ev);if(Calendar.isRelated(el,ev)||Calendar._C||el.disabled){return false;} +if(el.ttip){if(el.ttip.substr(0,1)=="_"){el.ttip=el.caldate.print(el.calendar.ttDateFormat)+el.ttip.substr(1);} +el.calendar.tooltips.innerHTML=el.ttip;} +if(el.navtype!=300){Calendar.addClass(el,"hilite");if(el.caldate){Calendar.addClass(el.parentNode,"rowhilite");}} +return Calendar.stopEvent(ev);};Calendar.dayMouseOut=function(ev){with(Calendar){var el=getElement(ev);if(isRelated(el,ev)||_C||el.disabled) +return false;removeClass(el,"hilite");if(el.caldate) +removeClass(el.parentNode,"rowhilite");if(el.calendar) +el.calendar.tooltips.innerHTML=_TT["SEL_DATE"];return stopEvent(ev);}};Calendar.cellClick=function(el,ev){var cal=el.calendar;var closing=false;var newdate=false;var date=null;if(typeof el.navtype=="undefined"){if(cal.currentDateEl){Calendar.removeClass(cal.currentDateEl,"selected");Calendar.addClass(el,"selected");closing=(cal.currentDateEl==el);if(!closing){cal.currentDateEl=el;}} +cal.date.setDateOnly(el.caldate);date=cal.date;var other_month=!(cal.dateClicked=!el.otherMonth);if(!other_month&&!cal.currentDateEl) +cal._toggleMultipleDate(new Date(date));else +newdate=!el.disabled;if(other_month) +cal._init(cal.firstDayOfWeek,date);}else{if(el.navtype==200){Calendar.removeClass(el,"hilite");cal.callCloseHandler();return;} +date=new Date(cal.date);if(el.navtype==0) +date.setDateOnly(new Date());cal.dateClicked=false;var year=date.getFullYear();var mon=date.getMonth();function setMonth(m){var day=date.getDate();var max=date.getMonthDays(m);if(day>max){date.setDate(max);} +date.setMonth(m);};switch(el.navtype){case 400:Calendar.removeClass(el,"hilite");var text=Calendar._TT["ABOUT"];if(typeof text!="undefined"){text+=cal.showsTime?Calendar._TT["ABOUT_TIME"]:"";}else{text="Help and about box text is not translated into this language.\n"+"If you know this language and you feel generous please update\n"+"the corresponding file in \"lang\" subdir to match calendar-en.js\n"+"and send it back to to get it into the distribution ;-)\n\n"+"Thank you!\n"+"http://dynarch.com/mishoo/calendar.epl\n";} +alert(text);return;case-2:if(year>cal.minYear){date.setFullYear(year-1);} +break;case-1:if(mon>0){setMonth(mon-1);}else if(year-->cal.minYear){date.setFullYear(year);setMonth(11);} +break;case 1:if(mon<11){setMonth(mon+1);}else if(year=0;) +if(range[i]==current) +break;if(ev&&ev.shiftKey){if(--i<0) +i=range.length-1;}else if(++i>=range.length) +i=0;var newval=range[i];el.innerHTML=newval;cal.onUpdateTime();return;case 0:if((typeof cal.getDateStatus=="function")&&cal.getDateStatus(date,date.getFullYear(),date.getMonth(),date.getDate())){return false;} +break;} +if(!date.equalsTo(cal.date)){cal.setDate(date);newdate=true;}else if(el.navtype==0) +newdate=closing=true;} +if(newdate){ev&&cal.callHandler();} +if(closing){Calendar.removeClass(el,"hilite");ev&&cal.callCloseHandler();}};Calendar.prototype.create=function(_par){var parent=null;if(!_par){parent=document.getElementsByTagName("body")[0];this.isPopup=true;}else{parent=_par;this.isPopup=false;} +this.date=this.dateStr?new Date(this.dateStr):new Date();var table=Calendar.createElement("table");this.table=table;table.cellSpacing=0;table.cellPadding=0;table.calendar=this;Calendar.addEvent(table,"mousedown",Calendar.tableMouseDown);var div=Calendar.createElement("div");this.element=div;div.className="calendar";if(this.isPopup){div.style.position="absolute";div.style.display="none";} +div.appendChild(table);var thead=Calendar.createElement("thead",table);var cell=null;var row=null;var cal=this;var hh=function(text,cs,navtype){cell=Calendar.createElement("td",row);cell.colSpan=cs;cell.className="button";if(navtype!=0&&Math.abs(navtype)<=2) +cell.className+=" nav";Calendar._add_evs(cell);cell.calendar=cal;cell.navtype=navtype;cell.innerHTML="
        "+text+"
        ";return cell;};row=Calendar.createElement("tr",thead);var title_length=6;(this.isPopup)&&--title_length;(this.weekNumbers)&&++title_length;hh("?",1,400).ttip=Calendar._TT["INFO"];this.title=hh("",title_length,300);this.title.className="title";if(this.isPopup){this.title.ttip=Calendar._TT["DRAG_TO_MOVE"];this.title.style.cursor="move";hh("×",1,200).ttip=Calendar._TT["CLOSE"];} +row=Calendar.createElement("tr",thead);row.className="headrow";this._nav_py=hh("«",1,-2);this._nav_py.ttip=Calendar._TT["PREV_YEAR"];this._nav_pm=hh("‹",1,-1);this._nav_pm.ttip=Calendar._TT["PREV_MONTH"];this._nav_now=hh(Calendar._TT["TODAY"],this.weekNumbers?4:3,0);this._nav_now.ttip=Calendar._TT["GO_TODAY"];this._nav_nm=hh("›",1,1);this._nav_nm.ttip=Calendar._TT["NEXT_MONTH"];this._nav_ny=hh("»",1,2);this._nav_ny.ttip=Calendar._TT["NEXT_YEAR"];row=Calendar.createElement("tr",thead);row.className="daynames";if(this.weekNumbers){cell=Calendar.createElement("td",row);cell.className="name wn";cell.innerHTML=Calendar._TT["WK"];} +for(var i=7;i>0;--i){cell=Calendar.createElement("td",row);if(!i){cell.navtype=100;cell.calendar=this;Calendar._add_evs(cell);}} +this.firstdayname=(this.weekNumbers)?row.firstChild.nextSibling:row.firstChild;this._displayWeekdays();var tbody=Calendar.createElement("tbody",table);this.tbody=tbody;for(i=6;i>0;--i){row=Calendar.createElement("tr",tbody);if(this.weekNumbers){cell=Calendar.createElement("td",row);} +for(var j=7;j>0;--j){cell=Calendar.createElement("td",row);cell.calendar=this;Calendar._add_evs(cell);}} +if(this.showsTime){row=Calendar.createElement("tr",tbody);row.className="time";cell=Calendar.createElement("td",row);cell.className="time";cell.colSpan=2;cell.innerHTML=Calendar._TT["TIME"]||" ";cell=Calendar.createElement("td",row);cell.className="time";cell.colSpan=this.weekNumbers?4:3;(function(){function makeTimePart(className,init,range_start,range_end){var part=Calendar.createElement("span",cell);part.className=className;part.innerHTML=init;part.calendar=cal;part.ttip=Calendar._TT["TIME_PART"];part.navtype=50;part._range=[];if(typeof range_start!="number") +part._range=range_start;else{for(var i=range_start;i<=range_end;++i){var txt;if(i<10&&range_end>=10)txt='0'+i;else txt=''+i;part._range[part._range.length]=txt;}} +Calendar._add_evs(part);return part;};var hrs=cal.date.getHours();var mins=cal.date.getMinutes();var t12=!cal.time24;var pm=(hrs>12);if(t12&&pm)hrs-=12;var H=makeTimePart("hour",hrs,t12?1:0,t12?12:23);var span=Calendar.createElement("span",cell);span.innerHTML=":";span.className="colon";var M=makeTimePart("minute",mins,0,59);var AP=null;cell=Calendar.createElement("td",row);cell.className="time";cell.colSpan=2;if(t12) +AP=makeTimePart("ampm",pm?"pm":"am",["am","pm"]);else +cell.innerHTML=" ";cal.onSetTime=function(){var pm,hrs=this.date.getHours(),mins=this.date.getMinutes();if(t12){pm=(hrs>=12);if(pm)hrs-=12;if(hrs==0)hrs=12;AP.innerHTML=pm?"pm":"am";} +H.innerHTML=(hrs<10)?("0"+hrs):hrs;M.innerHTML=(mins<10)?("0"+mins):mins;};cal.onUpdateTime=function(){var date=this.date;var h=parseInt(H.innerHTML,10);if(t12){if(/pm/i.test(AP.innerHTML)&&h<12) +h+=12;else if(/am/i.test(AP.innerHTML)&&h==12) +h=0;} +var d=date.getDate();var m=date.getMonth();var y=date.getFullYear();date.setHours(h);date.setMinutes(parseInt(M.innerHTML,10));date.setFullYear(y);date.setMonth(m);date.setDate(d);this.dateClicked=false;this.callHandler();};})();}else{this.onSetTime=this.onUpdateTime=function(){};} +var tfoot=Calendar.createElement("tfoot",table);row=Calendar.createElement("tr",tfoot);row.className="footrow";cell=hh(Calendar._TT["SEL_DATE"],this.weekNumbers?8:7,300);cell.className="ttip";if(this.isPopup){cell.ttip=Calendar._TT["DRAG_TO_MOVE"];cell.style.cursor="move";} +this.tooltips=cell;div=Calendar.createElement("div",this.element);this.monthsCombo=div;div.className="combo";for(i=0;i0;--i){var yr=Calendar.createElement("div");yr.className=Calendar.is_ie?"label-IEfix":"label";div.appendChild(yr);} +this._init(this.firstDayOfWeek,this.date);parent.appendChild(this.element);};Calendar._keyEvent=function(ev){var cal=window._dynarch_popupCalendar;if(!cal||cal.multiple) +return false;(Calendar.is_ie)&&(ev=window.event);var act=(Calendar.is_ie||ev.type=="keypress"),K=ev.keyCode;if(ev.ctrlKey){switch(K){case 37:act&&Calendar.cellClick(cal._nav_pm);break;case 38:act&&Calendar.cellClick(cal._nav_py);break;case 39:act&&Calendar.cellClick(cal._nav_nm);break;case 40:act&&Calendar.cellClick(cal._nav_ny);break;default:return false;}}else switch(K){case 32:Calendar.cellClick(cal._nav_now);break;case 27:act&&cal.callCloseHandler();break;case 37:case 38:case 39:case 40:if(act){var prev,x,y,ne,el,step;prev=K==37||K==38;step=(K==37||K==39)?1:7;function setVars(){el=cal.currentDateEl;var p=el.pos;x=p&15;y=p>>4;ne=cal.ar_days[y][x];};setVars();function prevMonth(){var date=new Date(cal.date);date.setDate(date.getDate()-step);cal.setDate(date);};function nextMonth(){var date=new Date(cal.date);date.setDate(date.getDate()+step);cal.setDate(date);};while(1){switch(K){case 37:if(--x>=0) +ne=cal.ar_days[y][x];else{x=6;K=38;continue;} +break;case 38:if(--y>=0) +ne=cal.ar_days[y][x];else{prevMonth();setVars();} +break;case 39:if(++x<7) +ne=cal.ar_days[y][x];else{x=0;K=40;continue;} +break;case 40:if(++ythis.maxYear){year=this.maxYear;date.setFullYear(year);} +this.firstDayOfWeek=firstDayOfWeek;this.date=new Date(date);var month=date.getMonth();var mday=date.getDate();var no_days=date.getMonthDays();date.setDate(1);var day1=(date.getDay()-this.firstDayOfWeek)%7;if(day1<0) +day1+=7;date.setDate(-day1);date.setDate(date.getDate()+1);var row=this.tbody.firstChild;var MN=Calendar._SMN[month];var ar_days=this.ar_days=new Array();var weekend=Calendar._TT["WEEKEND"];var dates=this.multiple?(this.datesCells={}):null;for(var i=0;i<6;++i,row=row.nextSibling){var cell=row.firstChild;if(this.weekNumbers){cell.className="day wn";cell.innerHTML=date.getWeekNumber();cell=cell.nextSibling;} +row.className="daysrow";var hasdays=false,iday,dpos=ar_days[i]=[];for(var j=0;j<7;++j,cell=cell.nextSibling,date.setDate(iday+1)){iday=date.getDate();var wday=date.getDay();cell.className="day";cell.pos=i<<4|j;dpos[j]=cell;var current_month=(date.getMonth()==month);if(!current_month){if(this.showsOtherMonths){cell.className+=" othermonth";cell.otherMonth=true;}else{cell.className="emptycell";cell.innerHTML=" ";cell.disabled=true;continue;}}else{cell.otherMonth=false;hasdays=true;} +cell.disabled=false;cell.innerHTML=this.getDateText?this.getDateText(date,iday):iday;if(dates) +dates[date.print("%Y%m%d")]=cell;if(this.getDateStatus){var status=this.getDateStatus(date,year,month,iday);if(this.getDateToolTip){var toolTip=this.getDateToolTip(date,year,month,iday);if(toolTip) +cell.title=toolTip;} +if(status===true){cell.className+=" disabled";cell.disabled=true;}else{if(/disabled/i.test(status)) +cell.disabled=true;cell.className+=" "+status;}} +if(!cell.disabled){cell.caldate=new Date(date);cell.ttip="_";if(!this.multiple&¤t_month&&iday==mday&&this.hiliteToday){cell.className+=" selected";this.currentDateEl=cell;} +if(date.getFullYear()==TY&&date.getMonth()==TM&&iday==TD){cell.className+=" today";cell.ttip+=Calendar._TT["PART_TODAY"];} +if(weekend.indexOf(wday.toString())!=-1) +cell.className+=cell.otherMonth?" oweekend":" weekend";}} +if(!(hasdays||this.showsOtherMonths)) +row.className="emptyrow";} +this.title.innerHTML=Calendar._MN[month]+", "+year;this.onSetTime();this.table.style.visibility="visible";this._initMultipleDates();};Calendar.prototype._initMultipleDates=function(){if(this.multiple){for(var i in this.multiple){var cell=this.datesCells[i];var d=this.multiple[i];if(!d) +continue;if(cell) +cell.className+=" selected";}}};Calendar.prototype._toggleMultipleDate=function(date){if(this.multiple){var ds=date.print("%Y%m%d");var cell=this.datesCells[ds];if(cell){var d=this.multiple[ds];if(!d){Calendar.addClass(cell,"selected");this.multiple[ds]=date;}else{Calendar.removeClass(cell,"selected");delete this.multiple[ds];}}}};Calendar.prototype.setDateToolTipHandler=function(unaryFunction){this.getDateToolTip=unaryFunction;};Calendar.prototype.setDate=function(date){if(!date.equalsTo(this.date)){this._init(this.firstDayOfWeek,date);}};Calendar.prototype.refresh=function(){this._init(this.firstDayOfWeek,this.date);};Calendar.prototype.setFirstDayOfWeek=function(firstDayOfWeek){this._init(firstDayOfWeek,this.date);this._displayWeekdays();};Calendar.prototype.setDateStatusHandler=Calendar.prototype.setDisabledHandler=function(unaryFunction){this.getDateStatus=unaryFunction;};Calendar.prototype.setRange=function(a,z){this.minYear=a;this.maxYear=z;};Calendar.prototype.callHandler=function(){if(this.onSelected){this.onSelected(this,this.date.print(this.dateFormat));}};Calendar.prototype.callCloseHandler=function(){if(this.onClose){this.onClose(this);} +this.hideShowCovered();};Calendar.prototype.destroy=function(){var el=this.element.parentNode;el.removeChild(this.element);Calendar._C=null;window._dynarch_popupCalendar=null;};Calendar.prototype.reparent=function(new_parent){var el=this.element;el.parentNode.removeChild(el);new_parent.appendChild(el);};Calendar._checkCalendar=function(ev){var calendar=window._dynarch_popupCalendar;if(!calendar){return false;} +var el=Calendar.is_ie?Calendar.getElement(ev):Calendar.getTargetElement(ev);for(;el!=null&&el!=calendar.element;el=el.parentNode);if(el==null){window._dynarch_popupCalendar.callCloseHandler();return Calendar.stopEvent(ev);}};Calendar.prototype.show=function(){var rows=this.table.getElementsByTagName("tr");for(var i=rows.length;i>0;){var row=rows[--i];Calendar.removeClass(row,"rowhilite");var cells=row.getElementsByTagName("td");for(var j=cells.length;j>0;){var cell=cells[--j];Calendar.removeClass(cell,"hilite");Calendar.removeClass(cell,"active");}} +this.element.style.display="block";this.hidden=false;if(this.isPopup){window._dynarch_popupCalendar=this;Calendar.addEvent(document,"keydown",Calendar._keyEvent);Calendar.addEvent(document,"keypress",Calendar._keyEvent);Calendar.addEvent(document,"mousedown",Calendar._checkCalendar);} +this.hideShowCovered();};Calendar.prototype.hide=function(){if(this.isPopup){Calendar.removeEvent(document,"keydown",Calendar._keyEvent);Calendar.removeEvent(document,"keypress",Calendar._keyEvent);Calendar.removeEvent(document,"mousedown",Calendar._checkCalendar);} +this.element.style.display="none";this.hidden=true;this.hideShowCovered();};Calendar.prototype.showAt=function(x,y){var s=this.element.style;s.left=x+"px";s.top=y+"px";this.show();};Calendar.prototype.showAtElement=function(el,opts){var self=this;var p=Calendar.getAbsolutePos(el);if(!opts||typeof opts!="string"){this.showAt(p.x,p.y+el.offsetHeight);return true;} +function fixPosition(box){if(box.x<0) +box.x=0;if(box.y<0) +box.y=0;var cp=document.createElement("div");var s=cp.style;s.position="absolute";s.right=s.bottom=s.width=s.height="0px";document.body.appendChild(cp);var br=Calendar.getAbsolutePos(cp);document.body.removeChild(cp);if(Calendar.is_ie){br.y+=document.body.scrollTop;br.x+=document.body.scrollLeft;}else{br.y+=window.scrollY;br.x+=window.scrollX;} +var tmp=box.x+box.width-br.x;if(tmp>0)box.x-=tmp;tmp=box.y+box.height-br.y;if(tmp>0)box.y-=tmp;};this.element.style.display="block";Calendar.continuation_for_the_fucking_khtml_browser=function(){var w=self.element.offsetWidth;var h=self.element.offsetHeight;self.element.style.display="none";var valign=opts.substr(0,1);var halign="l";if(opts.length>1){halign=opts.substr(1,1);} +switch(valign){case"T":p.y-=h;break;case"B":p.y+=el.offsetHeight;break;case"C":p.y+=(el.offsetHeight-h)/2;break;case"t":p.y+=el.offsetHeight-h;break;case"b":break;} +switch(halign){case"L":p.x-=w;break;case"R":p.x+=el.offsetWidth;break;case"C":p.x+=(el.offsetWidth-w)/2;break;case"l":p.x+=el.offsetWidth-w;break;case"r":break;} +p.width=w;p.height=h+40;self.monthsCombo.style.display="none";fixPosition(p);self.showAt(p.x,p.y);};if(Calendar.is_khtml) +setTimeout("Calendar.continuation_for_the_fucking_khtml_browser()",10);else +Calendar.continuation_for_the_fucking_khtml_browser();};Calendar.prototype.setDateFormat=function(str){this.dateFormat=str;};Calendar.prototype.setTtDateFormat=function(str){this.ttDateFormat=str;};Calendar.prototype.parseDate=function(str,fmt){if(!fmt) +fmt=this.dateFormat;this.setDate(Date.parseDate(str,fmt));};Calendar.prototype.hideShowCovered=function(){if(!Calendar.is_ie&&!Calendar.is_opera) +return;function getVisib(obj){var value=obj.style.visibility;if(!value){if(document.defaultView&&typeof(document.defaultView.getComputedStyle)=="function"){if(!Calendar.is_khtml) +value=document.defaultView.getComputedStyle(obj,"").getPropertyValue("visibility");else +value='';}else if(obj.currentStyle){value=obj.currentStyle.visibility;}else +value='';} +return value;};var tags=new Array("applet","iframe","select");var el=this.element;var p=Calendar.getAbsolutePos(el);var EX1=p.x;var EX2=el.offsetWidth+EX1;var EY1=p.y;var EY2=el.offsetHeight+EY1;for(var k=tags.length;k>0;){var ar=document.getElementsByTagName(tags[--k]);var cc=null;for(var i=ar.length;i>0;){cc=ar[--i];p=Calendar.getAbsolutePos(cc);var CX1=p.x;var CX2=cc.offsetWidth+CX1;var CY1=p.y;var CY2=cc.offsetHeight+CY1;if(this.hidden||(CX1>EX2)||(CX2EY2)||(CY229)?1900:2000);break;case"%b":case"%B":for(j=0;j<12;++j){if(Calendar._MN[j].substr(0,a[i].length).toLowerCase()==a[i].toLowerCase()){m=j;break;}} +break;case"%H":case"%I":case"%k":case"%l":hr=parseInt(a[i],10);break;case"%P":case"%p":if(/pm/i.test(a[i])&&hr<12) +hr+=12;else if(/am/i.test(a[i])&&hr>=12) +hr-=12;break;case"%M":min=parseInt(a[i],10);break;}} +if(isNaN(y))y=today.getFullYear();if(isNaN(m))m=today.getMonth();if(isNaN(d))d=today.getDate();if(isNaN(hr))hr=today.getHours();if(isNaN(min))min=today.getMinutes();if(y!=0&&m!=-1&&d!=0) +return new Date(y,m,d,hr,min,0);y=0;m=-1;d=0;for(i=0;i31&&y==0){y=parseInt(a[i],10);(y<100)&&(y+=(y>29)?1900:2000);}else if(d==0){d=a[i];}} +if(y==0) +y=today.getFullYear();if(m!=-1&&d!=0) +return new Date(y,m,d,hr,min,0);return today;};Date.prototype.getMonthDays=function(month){var year=this.getFullYear();if(typeof month=="undefined"){month=this.getMonth();} +if(((0==(year%4))&&((0!=(year%100))||(0==(year%400))))&&month==1){return 29;}else{return Date._MD[month];}};Date.prototype.getDayOfYear=function(){var now=new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0);var then=new Date(this.getFullYear(),0,0,0,0,0);var time=now-then;return Math.floor(time/Date.DAY);};Date.prototype.getWeekNumber=function(){var d=new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0);var DoW=d.getDay();d.setDate(d.getDate()-(DoW+6)%7+3);var ms=d.valueOf();d.setMonth(0);d.setDate(4);return Math.round((ms-d.valueOf())/(7*864e5))+1;};Date.prototype.equalsTo=function(date){return((this.getFullYear()==date.getFullYear())&&(this.getMonth()==date.getMonth())&&(this.getDate()==date.getDate())&&(this.getHours()==date.getHours())&&(this.getMinutes()==date.getMinutes()));};Date.prototype.setDateOnly=function(date){var tmp=new Date(date);this.setDate(1);this.setFullYear(tmp.getFullYear());this.setMonth(tmp.getMonth());this.setDate(tmp.getDate());};Date.prototype.print=function(str){var m=this.getMonth();var d=this.getDate();var y=this.getFullYear();var wn=this.getWeekNumber();var w=this.getDay();var s={};var hr=this.getHours();var pm=(hr>=12);var ir=(pm)?(hr-12):hr;var dy=this.getDayOfYear();if(ir==0) +ir=12;var min=this.getMinutes();var sec=this.getSeconds();s["%a"]=Calendar._SDN[w];s["%A"]=Calendar._DN[w];s["%b"]=Calendar._SMN[m];s["%B"]=Calendar._MN[m];s["%C"]=1+Math.floor(y/100);s["%d"]=(d<10)?("0"+d):d;s["%e"]=d;s["%H"]=(hr<10)?("0"+hr):hr;s["%I"]=(ir<10)?("0"+ir):ir;s["%j"]=(dy<100)?((dy<10)?("00"+dy):("0"+dy)):dy;s["%k"]=hr;s["%l"]=ir;s["%m"]=(m<9)?("0"+(1+m)):(1+m);s["%M"]=(min<10)?("0"+min):min;s["%n"]="\n";s["%p"]=pm?"PM":"AM";s["%P"]=pm?"pm":"am";s["%s"]=Math.floor(this.getTime()/1000);s["%S"]=(sec<10)?("0"+sec):sec;s["%t"]="\t";s["%U"]=s["%W"]=s["%V"]=(wn<10)?("0"+wn):wn;s["%u"]=w+1;s["%w"]=w;s["%y"]=(''+y).substr(2,2);s["%Y"]=y;s["%%"]="%";var re=/%./g;if(!Calendar.is_ie5&&!Calendar.is_khtml) +return str.replace(re,function(par){return s[par]||par;});var a=str.match(re);for(var i=0;i=0;){var d=params.multiple[i];var ds=d.print("%Y%m%d");cal.multiple[ds]=d;}} +cal.showsOtherMonths=params.showOthers;cal.yearStep=params.step;cal.setRange(params.range[0],params.range[1]);cal.params=params;cal.setDateStatusHandler(params.dateStatusFunc);cal.getDateText=params.dateText;cal.setDateFormat(dateFmt);if(mustCreate) +cal.create();cal.refresh();if(!params.position) +cal.showAtElement(params.button||params.displayArea||params.inputField,params.align);else +cal.showAt(params.position[0],params.position[1]);return false;};if(params.inputField){new DateDueKeyboardShortcutSupport(params.inputField,params.ifFormat,cal);} +return cal;};DateDueKeyboardShortcutSupport=Class.create();DateDueKeyboardShortcutSupport.prototype={initialize:function(element,dateFormat){this.element=$(element);this.dateFormat=dateFormat||"%Y/%m/%d";Event.observe(this.element,'keypress',this.onkeypress.bindAsEventListener(this));title=this.element.getAttributeNode("title");tooltip='Shortcuts: (t) today; (-) or (<) previous day; (+) or (>) next day; ([) previous week; (]) next week; ({) previous month; (}) next month; Click to show calendar';if(title&&title.value) +{this.element.setAttribute("title",title.value+' ('+tooltip+')');} +else +{this.element.setAttribute("title",tooltip);}},onkeypress:function(event){handled=true;switch(this.getCharFromKeyPressEvent(event)){case"t":this.setTextBoxToTodaysDate();break;case"+":case">":case"=":this.setTextBoxToNextDay();break;case"-":case"<":this.setTextBoxToPreviousDay();break;case"[":this.setTextBoxToPreviousWeek();break;case"]":this.setTextBoxToNextWeek();break;case"{":this.setTextBoxToPreviousMonth();break;case"}":this.setTextBoxToNextMonth();break;default:handled=false;break;} +if(handled){this.cancel(event);}},setTextBoxToChronicDate:function(){today=new Date();this.setDate(today);},setTextBoxToTodaysDate:function(){today=new Date();this.setDate(today);},setTextBoxToNextDay:function(){this.addDaysToTextBoxDate(1);},setTextBoxToPreviousDay:function(){this.addDaysToTextBoxDate(-1);},setTextBoxToNextWeek:function(){this.addDaysToTextBoxDate(7);},setTextBoxToPreviousWeek:function(){this.addDaysToTextBoxDate(-7);},addDaysToTextBoxDate:function(numDays){date=Date.parseDate(this.element.value,this.dateFormat);date.setDate(date.getDate()+numDays);this.setDate(date);},setTextBoxToNextMonth:function(){date=Date.parseDate(this.element.value,this.dateFormat);date.setMonth(date.getMonth()+1);this.setDate(date);},setTextBoxToPreviousMonth:function(){date=Date.parseDate(this.element.value,this.dateFormat);date.setMonth(date.getMonth()-1);this.setDate(date);},setDate:function(date){this.element.value=date.print(this.dateFormat);if(window.calendar){window.calendar.setDate(date);}},cancel:function(event){if(event.preventDefault){event.preventDefault();} +event.returnValue=false;},getCharFromKeyPressEvent:function(event){var charCode=(event.charCode)?event.charCode:((event.keyCode)?event.keyCode:((event.which)?event.which:0));return String.fromCharCode(charCode);}};var accessKeyHintsAdder={run:function(){var elemTypes=new Array('a','area','button','input','label','legend','textarea');for(var i=0;i=0?true:false);} +var oldonload=window.onload;if(typeof(NiftyLoad)!='function')NiftyLoad=function(){};if(typeof(oldonload)=='function') +window.onload=function(){oldonload();NiftyLoad()};else window.onload=function(){NiftyLoad()};function Nifty(selector,options){if(niftyOk==false)return;var i,v=selector.split(","),h=0;if(options==null)options="";if(options.find("fixed-height")) +h=getElementsBySelector(v[0])[0].offsetHeight;for(i=0;i0;i--) +d.appendChild(CreateStrip(i,side,color,border,btype));el.style.paddingBottom=0;el.appendChild(d);} +function CreateStrip(index,side,color,border,btype){var x=CreateEl("b");x.className=btype+index;x.style.backgroundColor=color;x.style.borderColor=border;if(side=="left"){x.style.borderRightWidth="0";x.style.marginRight="0";} +else if(side=="right"){x.style.borderLeftWidth="0";x.style.marginLeft="0";} +return(x);} +function CreateEl(x){return(document.createElement(x));} +function FixIE(el){if(el.currentStyle!=null&&el.currentStyle.hasLayout!=null&&el.currentStyle.hasLayout==false) +el.style.display="inline-block";} +function SameHeight(selector,maxh){var i,v=selector.split(","),t,j,els=[],gap;for(i=0;imaxh)maxh=els[i].offsetHeight;els[i].style.height="auto";} +for(i=0;i0){t=CreateEl("b");t.className="niftyfill";t.style.height=gap+"px";nc=els[i].lastChild;if(nc.className=="niftycorners") +els[i].insertBefore(t,nc);else els[i].appendChild(t);}}} +function getElementsBySelector(selector){var i,j,selid="",selclass="",tag=selector,tag2="",v2,k,f,a,s=[],objlist=[],c;if(selector.find("#")){if(selector.find(" ")){s=selector.split(" ");var fs=s[0].split("#");if(fs.length==1)return(objlist);f=document.getElementById(fs[1]);if(f){v=f.getElementsByTagName(s[1]);for(i=0;i=0;i--){var params={tag:'*',id:null,classes:[]};var selector=selectors[i];var needle=selector.length-1;do{var id=selector.lastIndexOf("#");var klass=selector.lastIndexOf(".");var cursor=Math.max(id,klass);if(cursor==-1)params.tag=selector.toUpperCase();else if(id==-1||klass==cursor)params.classes.push(selector.substring(klass+1)) +else if(!params.id)params.id=selector.substring(id+1);selector=selector.substring(0,cursor);}while(cursor>0);this.selectors[i]=params;}},get:function(root){this.findElements(root||document,this.index==(this.selectors.length-1));return this.results;},findElements:function(parent,descendant){var selector=this.selectors[this.index],results=[],element;if(selector.id){element=$(selector.id);if(element&&(selector.tag=='*'||element.tagName==selector.tag)&&(element.childOf(parent))){results=[element];}}else{results=$A(parent.getElementsByTagName(selector.tag));} +if(selector.classes.length==1){results=results.select(function(target){return $(target).hasClassName(selector.classes[0]);});}else if(selector.classes.length>1){results=results.select(function(target){var klasses=$(target).classNames();return selector.classes.all(function(klass){return klasses.include(klass);});});} +if(descendant){this.results=this.results.concat(results);}else{++this.index;results.each(function(target){this.findElements(target,this.index==(this.selectors.length-1));}.bind(this));}}} +LowPro.$$old=$$;LowPro.optimize$$=true;function $$(a,b){if(LowPro.optimize$$==false||b||a.indexOf("[")>=0) +return LowPro.$$old.apply(this,arguments);return new LowPro.SelectorLite(a.split(/\s+/)).get();} +if(typeof deconcept=="undefined"){var deconcept=new Object();}if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a){if(!document.getElementById){return;}this.DETECT_KEY=_a?_a:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1);}if(id){this.setAttribute("id",id);}if(w){this.setAttribute("width",w);}if(h){this.setAttribute("height",h);}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(c){this.addParam("bgcolor",c);}var q=_7?_7:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var _c=(_8)?_8:window.location;this.setAttribute("xiRedirectUrl",_c);this.setAttribute("redirectUrl","");if(_9){this.setAttribute("redirectUrl",_9);}};deconcept.SWFObject.prototype={useExpressInstall:function(_d){this.xiSWFPath=!_d?"expressinstall.swf":_d;this.setAttribute("useExpressInstall",true);},setAttribute:function(_e,_f){this.attributes[_e]=_f;},getAttribute:function(_10){return this.attributes[_10];},addParam:function(_11,_12){this.params[_11]=_12;},getParams:function(){return this.params;},addVariable:function(_13,_14){this.variables[_13]=_14;},getVariable:function(_15){return this.variables[_15];},getVariables:function(){return this.variables;},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){_16[_16.length]=key+"="+_18[key];}return _16;},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}_19="0){_19+="flashvars=\""+_1c+"\"";}_19+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}_19="";_19+="";var _1d=this.getParams();for(var key in _1d){_19+="";}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+="";}_19+="";}return _19;},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var _23=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_23=new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var axo=1;var _26=3;while(axo){try{_26++;axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_26);_23=new deconcept.PlayerVersion([_26,0,0]);}catch(e){axo=null;}}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(e){try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");_23=new deconcept.PlayerVersion([6,0,21]);axo.AllowScriptAccess="always";}catch(e){if(_23.major==6){return _23;}}try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(e){}}if(axo!=null){_23=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}}}return _23;};deconcept.PlayerVersion=function(_29){this.major=_29[0]!=null?parseInt(_29[0]):0;this.minor=_29[1]!=null?parseInt(_29[1]):0;this.rev=_29[2]!=null?parseInt(_29[2]):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.majorfv.major){return true;}if(this.minorfv.minor){return true;}if(this.rev=0;i--){_2f[i].style.display="none";for(var x in _2f[i]){if(typeof _2f[i][x]=="function"){_2f[i][x]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(id){return document.all[id];};}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject; \ No newline at end of file From 396008edc7ecfa24cc25883c6b4c633a1448e62c Mon Sep 17 00:00:00 2001 From: lrbalt Date: Fri, 6 Jun 2008 19:32:15 +0000 Subject: [PATCH 13/22] turns out that getElementsByClassName is removed from prototype and it therfore falls back to the function of the browser which has different semantics. Found here http://www.prototypejs.org/api/utility/getElementsByClassName git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@872 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/public/javascripts/todo-items.js | 4 +- tracks/public/javascripts/tracks_837.js | 839 ------------------------ 2 files changed, 2 insertions(+), 841 deletions(-) delete mode 100644 tracks/public/javascripts/tracks_837.js diff --git a/tracks/public/javascripts/todo-items.js b/tracks/public/javascripts/todo-items.js index 61efefbe..1cd7ff00 100644 --- a/tracks/public/javascripts/todo-items.js +++ b/tracks/public/javascripts/todo-items.js @@ -28,7 +28,7 @@ ToDoItems.prototype = { { toggleElem = this.containerToggles[i]; containerElem = toggleElem.parentNode.parentNode - itemsElem = document.getElementsByClassName('toggle_target',containerElem)[0]; + itemsElem = $(containerElem.id).select("div#"+containerElem.id+"items")[0]; this.toggleContainerMap[toggleElem.id] = containerElem; this.toggleItemsMap[toggleElem.id] = itemsElem; this.containerItemsMap[containerElem.id] = itemsElem; @@ -138,7 +138,7 @@ ToDoItems.prototype = { this.lastEffect = Effect.BlindUp(itemsElem, { duration: 0.4}); toggleElem.setAttribute('title', 'Expand'); imgElem = this.findToggleImgElem(toggleElem); - imgElem.src = imgElem.src.replace('collapse','expand'); +imgElem.src = imgElem.src.replace('collapse','expand'); imgElem.setAttribute('title','Expand'); }, findToggleImgElem: function(toggleElem) diff --git a/tracks/public/javascripts/tracks_837.js b/tracks/public/javascripts/tracks_837.js deleted file mode 100644 index b03ab25a..00000000 --- a/tracks/public/javascripts/tracks_837.js +++ /dev/null @@ -1,839 +0,0 @@ -var Prototype={Version:'1.6.0.1',Browser:{IE:!!(window.attachEvent&&!window.opera),Opera:!!window.opera,WebKit:navigator.userAgent.indexOf('AppleWebKit/')>-1,Gecko:navigator.userAgent.indexOf('Gecko')>-1&&navigator.userAgent.indexOf('KHTML')==-1,MobileSafari:!!navigator.userAgent.match(/Apple.*Mobile.*Safari/)},BrowserFeatures:{XPath:!!document.evaluate,ElementExtensions:!!window.HTMLElement,SpecificElementExtensions:document.createElement('div').__proto__&&document.createElement('div').__proto__!==document.createElement('form').__proto__},ScriptFragment:']*>([\\S\\s]*?)<\/script>',JSONFilter:/^\/\*-secure-([\s\S]*)\*\/\s*$/,emptyFunction:function(){},K:function(x){return x}};if(Prototype.Browser.MobileSafari) -Prototype.BrowserFeatures.SpecificElementExtensions=false;var Class={create:function(){var parent=null,properties=$A(arguments);if(Object.isFunction(properties[0])) -parent=properties.shift();function klass(){this.initialize.apply(this,arguments);} -Object.extend(klass,Class.Methods);klass.superclass=parent;klass.subclasses=[];if(parent){var subclass=function(){};subclass.prototype=parent.prototype;klass.prototype=new subclass;parent.subclasses.push(klass);} -for(var i=0;i0){if(match=source.match(pattern)){result+=source.slice(0,match.index);result+=String.interpret(replacement(match));source=source.slice(match.index+match[0].length);}else{result+=source,source='';}} -return result;},sub:function(pattern,replacement,count){replacement=this.gsub.prepareReplacement(replacement);count=Object.isUndefined(count)?1:count;return this.gsub(pattern,function(match){if(--count<0)return match[0];return replacement(match);});},scan:function(pattern,iterator){this.gsub(pattern,iterator);return String(this);},truncate:function(length,truncation){length=length||30;truncation=Object.isUndefined(truncation)?'...':truncation;return this.length>length?this.slice(0,length-truncation.length)+truncation:String(this);},strip:function(){return this.replace(/^\s+/,'').replace(/\s+$/,'');},stripTags:function(){return this.replace(/<\/?[^>]+>/gi,'');},stripScripts:function(){return this.replace(new RegExp(Prototype.ScriptFragment,'img'),'');},extractScripts:function(){var matchAll=new RegExp(Prototype.ScriptFragment,'img');var matchOne=new RegExp(Prototype.ScriptFragment,'im');return(this.match(matchAll)||[]).map(function(scriptTag){return(scriptTag.match(matchOne)||['',''])[1];});},evalScripts:function(){return this.extractScripts().map(function(script){return eval(script)});},escapeHTML:function(){var self=arguments.callee;self.text.data=this;return self.div.innerHTML;},unescapeHTML:function(){var div=new Element('div');div.innerHTML=this.stripTags();return div.childNodes[0]?(div.childNodes.length>1?$A(div.childNodes).inject('',function(memo,node){return memo+node.nodeValue}):div.childNodes[0].nodeValue):'';},toQueryParams:function(separator){var match=this.strip().match(/([^?#]*)(#.*)?$/);if(!match)return{};return match[1].split(separator||'&').inject({},function(hash,pair){if((pair=pair.split('='))[0]){var key=decodeURIComponent(pair.shift());var value=pair.length>1?pair.join('='):pair[0];if(value!=undefined)value=decodeURIComponent(value);if(key in hash){if(!Object.isArray(hash[key]))hash[key]=[hash[key]];hash[key].push(value);} -else hash[key]=value;} -return hash;});},toArray:function(){return this.split('');},succ:function(){return this.slice(0,this.length-1)+ -String.fromCharCode(this.charCodeAt(this.length-1)+1);},times:function(count){return count<1?'':new Array(count+1).join(this);},camelize:function(){var parts=this.split('-'),len=parts.length;if(len==1)return parts[0];var camelized=this.charAt(0)=='-'?parts[0].charAt(0).toUpperCase()+parts[0].substring(1):parts[0];for(var i=1;i-1;},startsWith:function(pattern){return this.indexOf(pattern)===0;},endsWith:function(pattern){var d=this.length-pattern.length;return d>=0&&this.lastIndexOf(pattern)===d;},empty:function(){return this=='';},blank:function(){return/^\s*$/.test(this);},interpolate:function(object,pattern){return new Template(this,pattern).evaluate(object);}});if(Prototype.Browser.WebKit||Prototype.Browser.IE)Object.extend(String.prototype,{escapeHTML:function(){return this.replace(/&/g,'&').replace(//g,'>');},unescapeHTML:function(){return this.replace(/&/g,'&').replace(/</g,'<').replace(/>/g,'>');}});String.prototype.gsub.prepareReplacement=function(replacement){if(Object.isFunction(replacement))return replacement;var template=new Template(replacement);return function(match){return template.evaluate(match)};};String.prototype.parseQuery=String.prototype.toQueryParams;Object.extend(String.prototype.escapeHTML,{div:document.createElement('div'),text:document.createTextNode('')});with(String.prototype.escapeHTML)div.appendChild(text);var Template=Class.create({initialize:function(template,pattern){this.template=template.toString();this.pattern=pattern||Template.Pattern;},evaluate:function(object){if(Object.isFunction(object.toTemplateReplacements)) -object=object.toTemplateReplacements();return this.template.gsub(this.pattern,function(match){if(object==null)return'';var before=match[1]||'';if(before=='\\')return match[2];var ctx=object,expr=match[3];var pattern=/^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/;match=pattern.exec(expr);if(match==null)return before;while(match!=null){var comp=match[1].startsWith('[')?match[2].gsub('\\\\]',']'):match[1];ctx=ctx[comp];if(null==ctx||''==match[3])break;expr=expr.substring('['==match[3]?match[1].length:match[0].length);match=pattern.exec(expr);} -return before+String.interpret(ctx);}.bind(this));}});Template.Pattern=/(^|.|\r|\n)(#\{(.*?)\})/;var $break={};var Enumerable={each:function(iterator,context){var index=0;iterator=iterator.bind(context);try{this._each(function(value){iterator(value,index++);});}catch(e){if(e!=$break)throw e;} -return this;},eachSlice:function(number,iterator,context){iterator=iterator?iterator.bind(context):Prototype.K;var index=-number,slices=[],array=this.toArray();while((index+=number)=result) -result=value;});return result;},min:function(iterator,context){iterator=iterator?iterator.bind(context):Prototype.K;var result;this.each(function(value,index){value=iterator(value,index);if(result==null||valueb?1:0;}).pluck('value');},toArray:function(){return this.map();},zip:function(){var iterator=Prototype.K,args=$A(arguments);if(Object.isFunction(args.last())) -iterator=args.pop();var collections=[this].concat(args).map($A);return this.map(function(value,index){return iterator(collections.pluck(index));});},size:function(){return this.toArray().length;},inspect:function(){return'#';}};Object.extend(Enumerable,{map:Enumerable.collect,find:Enumerable.detect,select:Enumerable.findAll,filter:Enumerable.findAll,member:Enumerable.include,entries:Enumerable.toArray,every:Enumerable.all,some:Enumerable.any});function $A(iterable){if(!iterable)return[];if(iterable.toArray)return iterable.toArray();var length=iterable.length,results=new Array(length);while(length--)results[length]=iterable[length];return results;} -if(Prototype.Browser.WebKit){function $A(iterable){if(!iterable)return[];if(!(Object.isFunction(iterable)&&iterable=='[object NodeList]')&&iterable.toArray)return iterable.toArray();var length=iterable.length,results=new Array(length);while(length--)results[length]=iterable[length];return results;}} -Array.from=$A;Object.extend(Array.prototype,Enumerable);if(!Array.prototype._reverse)Array.prototype._reverse=Array.prototype.reverse;Object.extend(Array.prototype,{_each:function(iterator){for(var i=0,length=this.length;i1?this:this[0];},uniq:function(sorted){return this.inject([],function(array,value,index){if(0==index||(sorted?array.last()!=value:!array.include(value))) -array.push(value);return array;});},intersect:function(array){return this.uniq().findAll(function(item){return array.detect(function(value){return item===value});});},clone:function(){return[].concat(this);},size:function(){return this.length;},inspect:function(){return'['+this.map(Object.inspect).join(', ')+']';},toJSON:function(){var results=[];this.each(function(object){var value=Object.toJSON(object);if(!Object.isUndefined(value))results.push(value);});return'['+results.join(', ')+']';}});if(Object.isFunction(Array.prototype.forEach)) -Array.prototype._each=Array.prototype.forEach;if(!Array.prototype.indexOf)Array.prototype.indexOf=function(item,i){i||(i=0);var length=this.length;if(i<0)i=length+i;for(;i';},toJSON:function(){return Object.toJSON(this.toObject());},clone:function(){return new Hash(this);}}})());Hash.prototype.toTemplateReplacements=Hash.prototype.toObject;Hash.from=$H;var ObjectRange=Class.create(Enumerable,{initialize:function(start,end,exclusive){this.start=start;this.end=end;this.exclusive=exclusive;},_each:function(iterator){var value=this.start;while(this.include(value)){iterator(value);value=value.succ();}},include:function(value){if(value1&&!((readyState==4)&&this._complete)) -this.respondToReadyState(this.transport.readyState);},setRequestHeaders:function(){var headers={'X-Requested-With':'XMLHttpRequest','X-Prototype-Version':Prototype.Version,'Accept':'text/javascript, text/html, application/xml, text/xml, */*'};if(this.method=='post'){headers['Content-type']=this.options.contentType+ -(this.options.encoding?'; charset='+this.options.encoding:'');if(this.transport.overrideMimeType&&(navigator.userAgent.match(/Gecko\/(\d{4})/)||[0,2005])[1]<2005) -headers['Connection']='close';} -if(typeof this.options.requestHeaders=='object'){var extras=this.options.requestHeaders;if(Object.isFunction(extras.push)) -for(var i=0,length=extras.length;i=200&&status<300);},getStatus:function(){try{return this.transport.status||0;}catch(e){return 0}},respondToReadyState:function(readyState){var state=Ajax.Request.Events[readyState],response=new Ajax.Response(this);if(state=='Complete'){try{this._complete=true;(this.options['on'+response.status]||this.options['on'+(this.success()?'Success':'Failure')]||Prototype.emptyFunction)(response,response.headerJSON);}catch(e){this.dispatchException(e);} -var contentType=response.getHeader('Content-type');if(this.options.evalJS=='force'||(this.options.evalJS&&contentType&&contentType.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s*$/i))) -this.evalResponse();} -try{(this.options['on'+state]||Prototype.emptyFunction)(response,response.headerJSON);Ajax.Responders.dispatch('on'+state,this,response,response.headerJSON);}catch(e){this.dispatchException(e);} -if(state=='Complete'){this.transport.onreadystatechange=Prototype.emptyFunction;}},getHeader:function(name){try{return this.transport.getResponseHeader(name);}catch(e){return null}},evalResponse:function(){try{return eval((this.transport.responseText||'').unfilterJSON());}catch(e){this.dispatchException(e);}},dispatchException:function(exception){(this.options.onException||Prototype.emptyFunction)(this,exception);Ajax.Responders.dispatch('onException',this,exception);}});Ajax.Request.Events=['Uninitialized','Loading','Loaded','Interactive','Complete'];Ajax.Response=Class.create({initialize:function(request){this.request=request;var transport=this.transport=request.transport,readyState=this.readyState=transport.readyState;if((readyState>2&&!Prototype.Browser.IE)||readyState==4){this.status=this.getStatus();this.statusText=this.getStatusText();this.responseText=String.interpret(transport.responseText);this.headerJSON=this._getHeaderJSON();} -if(readyState==4){var xml=transport.responseXML;this.responseXML=Object.isUndefined(xml)?null:xml;this.responseJSON=this._getResponseJSON();}},status:0,statusText:'',getStatus:Ajax.Request.prototype.getStatus,getStatusText:function(){try{return this.transport.statusText||'';}catch(e){return''}},getHeader:Ajax.Request.prototype.getHeader,getAllHeaders:function(){try{return this.getAllResponseHeaders();}catch(e){return null}},getResponseHeader:function(name){return this.transport.getResponseHeader(name);},getAllResponseHeaders:function(){return this.transport.getAllResponseHeaders();},_getHeaderJSON:function(){var json=this.getHeader('X-JSON');if(!json)return null;json=decodeURIComponent(escape(json));try{return json.evalJSON(this.request.options.sanitizeJSON);}catch(e){this.request.dispatchException(e);}},_getResponseJSON:function(){var options=this.request.options;if(!options.evalJSON||(options.evalJSON!='force'&&!(this.getHeader('Content-type')||'').include('application/json'))||this.responseText.blank()) -return null;try{return this.responseText.evalJSON(options.sanitizeJSON);}catch(e){this.request.dispatchException(e);}}});Ajax.Updater=Class.create(Ajax.Request,{initialize:function($super,container,url,options){this.container={success:(container.success||container),failure:(container.failure||(container.success?null:container))};options=Object.clone(options);var onComplete=options.onComplete;options.onComplete=(function(response,json){this.updateContent(response.responseText);if(Object.isFunction(onComplete))onComplete(response,json);}).bind(this);$super(url,options);},updateContent:function(responseText){var receiver=this.container[this.success()?'success':'failure'],options=this.options;if(!options.evalScripts)responseText=responseText.stripScripts();if(receiver=$(receiver)){if(options.insertion){if(Object.isString(options.insertion)){var insertion={};insertion[options.insertion]=responseText;receiver.insert(insertion);} -else options.insertion(receiver,responseText);} -else receiver.update(responseText);}}});Ajax.PeriodicalUpdater=Class.create(Ajax.Base,{initialize:function($super,container,url,options){$super(options);this.onComplete=this.options.onComplete;this.frequency=(this.options.frequency||2);this.decay=(this.options.decay||1);this.updater={};this.container=container;this.url=url;this.start();},start:function(){this.options.onComplete=this.updateComplete.bind(this);this.onTimerEvent();},stop:function(){this.updater.options.onComplete=undefined;clearTimeout(this.timer);(this.onComplete||Prototype.emptyFunction).apply(this,arguments);},updateComplete:function(response){if(this.options.decay){this.decay=(response.responseText==this.lastText?this.decay*this.options.decay:1);this.lastText=response.responseText;} -this.timer=this.onTimerEvent.bind(this).delay(this.decay*this.frequency);},onTimerEvent:function(){this.updater=new Ajax.Updater(this.container,this.url,this.options);}});function $(element){if(arguments.length>1){for(var i=0,elements=[],length=arguments.length;i';delete attributes.name;return Element.writeAttribute(document.createElement(tagName),attributes);} -if(!cache[tagName])cache[tagName]=Element.extend(document.createElement(tagName));return Element.writeAttribute(cache[tagName].cloneNode(false),attributes);};Object.extend(this.Element,element||{});}).call(window);Element.cache={};Element.Methods={visible:function(element){return $(element).style.display!='none';},toggle:function(element){element=$(element);Element[Element.visible(element)?'hide':'show'](element);return element;},hide:function(element){$(element).style.display='none';return element;},show:function(element){$(element).style.display='';return element;},remove:function(element){element=$(element);element.parentNode.removeChild(element);return element;},update:function(element,content){element=$(element);if(content&&content.toElement)content=content.toElement();if(Object.isElement(content))return element.update().insert(content);content=Object.toHTML(content);element.innerHTML=content.stripScripts();content.evalScripts.bind(content).defer();return element;},replace:function(element,content){element=$(element);if(content&&content.toElement)content=content.toElement();else if(!Object.isElement(content)){content=Object.toHTML(content);var range=element.ownerDocument.createRange();range.selectNode(element);content.evalScripts.bind(content).defer();content=range.createContextualFragment(content.stripScripts());} -element.parentNode.replaceChild(content,element);return element;},insert:function(element,insertions){element=$(element);if(Object.isString(insertions)||Object.isNumber(insertions)||Object.isElement(insertions)||(insertions&&(insertions.toElement||insertions.toHTML))) -insertions={bottom:insertions};var content,t,range;for(position in insertions){content=insertions[position];position=position.toLowerCase();t=Element._insertionTranslations[position];if(content&&content.toElement)content=content.toElement();if(Object.isElement(content)){t.insert(element,content);continue;} -content=Object.toHTML(content);range=element.ownerDocument.createRange();t.initializeRange(element,range);t.insert(element,range.createContextualFragment(content.stripScripts()));content.evalScripts.bind(content).defer();} -return element;},wrap:function(element,wrapper,attributes){element=$(element);if(Object.isElement(wrapper)) -$(wrapper).writeAttribute(attributes||{});else if(Object.isString(wrapper))wrapper=new Element(wrapper,attributes);else wrapper=new Element('div',wrapper);if(element.parentNode) -element.parentNode.replaceChild(wrapper,element);wrapper.appendChild(element);return wrapper;},inspect:function(element){element=$(element);var result='<'+element.tagName.toLowerCase();$H({'id':'id','className':'class'}).each(function(pair){var property=pair.first(),attribute=pair.last();var value=(element[property]||'').toString();if(value)result+=' '+attribute+'='+value.inspect(true);});return result+'>';},recursivelyCollect:function(element,property){element=$(element);var elements=[];while(element=element[property]) -if(element.nodeType==1) -elements.push(Element.extend(element));return elements;},ancestors:function(element){return $(element).recursivelyCollect('parentNode');},descendants:function(element){return $(element).getElementsBySelector("*");},firstDescendant:function(element){element=$(element).firstChild;while(element&&element.nodeType!=1)element=element.nextSibling;return $(element);},immediateDescendants:function(element){if(!(element=$(element).firstChild))return[];while(element&&element.nodeType!=1)element=element.nextSibling;if(element)return[element].concat($(element).nextSiblings());return[];},previousSiblings:function(element){return $(element).recursivelyCollect('previousSibling');},nextSiblings:function(element){return $(element).recursivelyCollect('nextSibling');},siblings:function(element){element=$(element);return element.previousSiblings().reverse().concat(element.nextSiblings());},match:function(element,selector){if(Object.isString(selector)) -selector=new Selector(selector);return selector.match($(element));},up:function(element,expression,index){element=$(element);if(arguments.length==1)return $(element.parentNode);var ancestors=element.ancestors();return expression?Selector.findElement(ancestors,expression,index):ancestors[index||0];},down:function(element,expression,index){element=$(element);if(arguments.length==1)return element.firstDescendant();var descendants=element.descendants();return expression?Selector.findElement(descendants,expression,index):descendants[index||0];},previous:function(element,expression,index){element=$(element);if(arguments.length==1)return $(Selector.handlers.previousElementSibling(element));var previousSiblings=element.previousSiblings();return expression?Selector.findElement(previousSiblings,expression,index):previousSiblings[index||0];},next:function(element,expression,index){element=$(element);if(arguments.length==1)return $(Selector.handlers.nextElementSibling(element));var nextSiblings=element.nextSiblings();return expression?Selector.findElement(nextSiblings,expression,index):nextSiblings[index||0];},select:function(){var args=$A(arguments),element=$(args.shift());return Selector.findChildElements(element,args);},adjacent:function(){var args=$A(arguments),element=$(args.shift());return Selector.findChildElements(element.parentNode,args).without(element);},identify:function(element){element=$(element);var id=element.readAttribute('id'),self=arguments.callee;if(id)return id;do{id='anonymous_element_'+self.counter++}while($(id));element.writeAttribute('id',id);return id;},readAttribute:function(element,name){element=$(element);if(Prototype.Browser.IE){var t=Element._attributeTranslations.read;if(t.values[name])return t.values[name](element,name);if(t.names[name])name=t.names[name];if(name.include(':')){return(!element.attributes||!element.attributes[name])?null:element.attributes[name].value;}} -return element.getAttribute(name);},writeAttribute:function(element,name,value){element=$(element);var attributes={},t=Element._attributeTranslations.write;if(typeof name=='object')attributes=name;else attributes[name]=Object.isUndefined(value)?true:value;for(var attr in attributes){name=t.names[attr]||attr;value=attributes[attr];if(t.values[attr])name=t.values[attr](element,value);if(value===false||value===null) -element.removeAttribute(name);else if(value===true) -element.setAttribute(name,name);else element.setAttribute(name,value);} -return element;},getHeight:function(element){return $(element).getDimensions().height;},getWidth:function(element){return $(element).getDimensions().width;},classNames:function(element){return new Element.ClassNames(element);},hasClassName:function(element,className){if(!(element=$(element)))return;var elementClassName=element.className;return(elementClassName.length>0&&(elementClassName==className||new RegExp("(^|\\s)"+className+"(\\s|$)").test(elementClassName)));},addClassName:function(element,className){if(!(element=$(element)))return;if(!element.hasClassName(className)) -element.className+=(element.className?' ':'')+className;return element;},removeClassName:function(element,className){if(!(element=$(element)))return;element.className=element.className.replace(new RegExp("(^|\\s+)"+className+"(\\s+|$)"),' ').strip();return element;},toggleClassName:function(element,className){if(!(element=$(element)))return;return element[element.hasClassName(className)?'removeClassName':'addClassName'](className);},cleanWhitespace:function(element){element=$(element);var node=element.firstChild;while(node){var nextNode=node.nextSibling;if(node.nodeType==3&&!/\S/.test(node.nodeValue)) -element.removeChild(node);node=nextNode;} -return element;},empty:function(element){return $(element).innerHTML.blank();},descendantOf:function(element,ancestor){element=$(element),ancestor=$(ancestor);var originalAncestor=ancestor;if(element.compareDocumentPosition) -return(element.compareDocumentPosition(ancestor)&8)===8;if(element.sourceIndex&&!Prototype.Browser.Opera){var e=element.sourceIndex,a=ancestor.sourceIndex,nextAncestor=ancestor.nextSibling;if(!nextAncestor){do{ancestor=ancestor.parentNode;} -while(!(nextAncestor=ancestor.nextSibling)&&ancestor.parentNode);} -if(nextAncestor)return(e>a&&e','',1],TBODY:['','
        ',2],TR:['','
        ',3],TD:['
        ','
        ',4],SELECT:['',1]}};(function(){this.bottom.initializeRange=this.top.initializeRange;Object.extend(this.tags,{THEAD:this.tags.TBODY,TFOOT:this.tags.TBODY,TH:this.tags.TD});}).call(Element._insertionTranslations);Element.Methods.Simulated={hasAttribute:function(element,attribute){attribute=Element._attributeTranslations.has[attribute]||attribute;var node=$(element).getAttributeNode(attribute);return node&&node.specified;}};Element.Methods.ByTag={};Object.extend(Element,Element.Methods);if(!Prototype.BrowserFeatures.ElementExtensions&&document.createElement('div').__proto__){window.HTMLElement={};window.HTMLElement.prototype=document.createElement('div').__proto__;Prototype.BrowserFeatures.ElementExtensions=true;} -Element.extend=(function(){if(Prototype.BrowserFeatures.SpecificElementExtensions) -return Prototype.K;var Methods={},ByTag=Element.Methods.ByTag;var extend=Object.extend(function(element){if(!element||element._extendedByPrototype||element.nodeType!=1||element==window)return element;var methods=Object.clone(Methods),tagName=element.tagName,property,value;if(ByTag[tagName])Object.extend(methods,ByTag[tagName]);for(property in methods){value=methods[property];if(Object.isFunction(value)&&!(property in element)) -element[property]=value.methodize();} -element._extendedByPrototype=Prototype.emptyFunction;return element;},{refresh:function(){if(!Prototype.BrowserFeatures.ElementExtensions){Object.extend(Methods,Element.Methods);Object.extend(Methods,Element.Methods.Simulated);}}});extend.refresh();return extend;})();Element.hasAttribute=function(element,attribute){if(element.hasAttribute)return element.hasAttribute(attribute);return Element.Methods.Simulated.hasAttribute(element,attribute);};Element.addMethods=function(methods){var F=Prototype.BrowserFeatures,T=Element.Methods.ByTag;if(!methods){Object.extend(Form,Form.Methods);Object.extend(Form.Element,Form.Element.Methods);Object.extend(Element.Methods.ByTag,{"FORM":Object.clone(Form.Methods),"INPUT":Object.clone(Form.Element.Methods),"SELECT":Object.clone(Form.Element.Methods),"TEXTAREA":Object.clone(Form.Element.Methods)});} -if(arguments.length==2){var tagName=methods;methods=arguments[1];} -if(!tagName)Object.extend(Element.Methods,methods||{});else{if(Object.isArray(tagName))tagName.each(extend);else extend(tagName);} -function extend(tagName){tagName=tagName.toUpperCase();if(!Element.Methods.ByTag[tagName]) -Element.Methods.ByTag[tagName]={};Object.extend(Element.Methods.ByTag[tagName],methods);} -function copy(methods,destination,onlyIfAbsent){onlyIfAbsent=onlyIfAbsent||false;for(var property in methods){var value=methods[property];if(!Object.isFunction(value))continue;if(!onlyIfAbsent||!(property in destination)) -destination[property]=value.methodize();}} -function findDOMClass(tagName){var klass;var trans={"OPTGROUP":"OptGroup","TEXTAREA":"TextArea","P":"Paragraph","FIELDSET":"FieldSet","UL":"UList","OL":"OList","DL":"DList","DIR":"Directory","H1":"Heading","H2":"Heading","H3":"Heading","H4":"Heading","H5":"Heading","H6":"Heading","Q":"Quote","INS":"Mod","DEL":"Mod","A":"Anchor","IMG":"Image","CAPTION":"TableCaption","COL":"TableCol","COLGROUP":"TableCol","THEAD":"TableSection","TFOOT":"TableSection","TBODY":"TableSection","TR":"TableRow","TH":"TableCell","TD":"TableCell","FRAMESET":"FrameSet","IFRAME":"IFrame"};if(trans[tagName])klass='HTML'+trans[tagName]+'Element';if(window[klass])return window[klass];klass='HTML'+tagName+'Element';if(window[klass])return window[klass];klass='HTML'+tagName.capitalize()+'Element';if(window[klass])return window[klass];window[klass]={};window[klass].prototype=document.createElement(tagName).__proto__;return window[klass];} -if(F.ElementExtensions){copy(Element.Methods,HTMLElement.prototype);copy(Element.Methods.Simulated,HTMLElement.prototype,true);} -if(F.SpecificElementExtensions){for(var tag in Element.Methods.ByTag){var klass=findDOMClass(tag);if(Object.isUndefined(klass))continue;copy(T[tag],klass.prototype);}} -Object.extend(Element,Element.Methods);delete Element.ByTag;if(Element.extend.refresh)Element.extend.refresh();Element.cache={};};document.viewport={getDimensions:function(){var dimensions={};var B=Prototype.Browser;$w('width height').each(function(d){var D=d.capitalize();dimensions[d]=(B.WebKit&&!document.evaluate)?self['inner'+D]:(B.Opera)?document.body['client'+D]:document.documentElement['client'+D];});return dimensions;},getWidth:function(){return this.getDimensions().width;},getHeight:function(){return this.getDimensions().height;},getScrollOffsets:function(){return Element._returnOffset(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft,window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop);}};var Selector=Class.create({initialize:function(expression){this.expression=expression.strip();this.compileMatcher();},shouldUseXPath:function(){if(!Prototype.BrowserFeatures.XPath)return false;var e=this.expression;if(Prototype.Browser.WebKit&&(e.include("-of-type")||e.include(":empty"))) -return false;if((/(\[[\w-]*?:|:checked)/).test(this.expression)) -return false;return true;},compileMatcher:function(){if(this.shouldUseXPath()) -return this.compileXPathMatcher();var e=this.expression,ps=Selector.patterns,h=Selector.handlers,c=Selector.criteria,le,p,m;if(Selector._cache[e]){this.matcher=Selector._cache[e];return;} -this.matcher=["this.matcher = function(root) {","var r = root, h = Selector.handlers, c = false, n;"];while(e&&le!=e&&(/\S/).test(e)){le=e;for(var i in ps){p=ps[i];if(m=e.match(p)){this.matcher.push(Object.isFunction(c[i])?c[i](m):new Template(c[i]).evaluate(m));e=e.replace(m[0],'');break;}}} -this.matcher.push("return h.unique(n);\n}");eval(this.matcher.join('\n'));Selector._cache[this.expression]=this.matcher;},compileXPathMatcher:function(){var e=this.expression,ps=Selector.patterns,x=Selector.xpath,le,m;if(Selector._cache[e]){this.xpath=Selector._cache[e];return;} -this.matcher=['.//*'];while(e&&le!=e&&(/\S/).test(e)){le=e;for(var i in ps){if(m=e.match(ps[i])){this.matcher.push(Object.isFunction(x[i])?x[i](m):new Template(x[i]).evaluate(m));e=e.replace(m[0],'');break;}}} -this.xpath=this.matcher.join('');Selector._cache[this.expression]=this.xpath;},findElements:function(root){root=root||document;if(this.xpath)return document._getElementsByXPath(this.xpath,root);return this.matcher(root);},match:function(element){this.tokens=[];var e=this.expression,ps=Selector.patterns,as=Selector.assertions;var le,p,m;while(e&&le!==e&&(/\S/).test(e)){le=e;for(var i in ps){p=ps[i];if(m=e.match(p)){if(as[i]){this.tokens.push([i,Object.clone(m)]);e=e.replace(m[0],'');}else{return this.findElements(document).include(element);}}}} -var match=true,name,matches;for(var i=0,token;token=this.tokens[i];i++){name=token[0],matches=token[1];if(!Selector.assertions[name](element,matches)){match=false;break;}} -return match;},toString:function(){return this.expression;},inspect:function(){return"#";}});Object.extend(Selector,{_cache:{},xpath:{descendant:"//*",child:"/*",adjacent:"/following-sibling::*[1]",laterSibling:'/following-sibling::*',tagName:function(m){if(m[1]=='*')return'';return"[local-name()='"+m[1].toLowerCase()+"' or local-name()='"+m[1].toUpperCase()+"']";},className:"[contains(concat(' ', @class, ' '), ' #{1} ')]",id:"[@id='#{1}']",attrPresence:function(m){m[1]=m[1].toLowerCase();return new Template("[@#{1}]").evaluate(m);},attr:function(m){m[1]=m[1].toLowerCase();m[3]=m[5]||m[6];return new Template(Selector.xpath.operators[m[2]]).evaluate(m);},pseudo:function(m){var h=Selector.xpath.pseudos[m[1]];if(!h)return'';if(Object.isFunction(h))return h(m);return new Template(Selector.xpath.pseudos[m[1]]).evaluate(m);},operators:{'=':"[@#{1}='#{3}']",'!=':"[@#{1}!='#{3}']",'^=':"[starts-with(@#{1}, '#{3}')]",'$=':"[substring(@#{1}, (string-length(@#{1}) - string-length('#{3}') + 1))='#{3}']",'*=':"[contains(@#{1}, '#{3}')]",'~=':"[contains(concat(' ', @#{1}, ' '), ' #{3} ')]",'|=':"[contains(concat('-', @#{1}, '-'), '-#{3}-')]"},pseudos:{'first-child':'[not(preceding-sibling::*)]','last-child':'[not(following-sibling::*)]','only-child':'[not(preceding-sibling::* or following-sibling::*)]','empty':"[count(*) = 0 and (count(text()) = 0 or translate(text(), ' \t\r\n', '') = '')]",'checked':"[@checked]",'disabled':"[@disabled]",'enabled':"[not(@disabled)]",'not':function(m){var e=m[6],p=Selector.patterns,x=Selector.xpath,le,v;var exclusion=[];while(e&&le!=e&&(/\S/).test(e)){le=e;for(var i in p){if(m=e.match(p[i])){v=Object.isFunction(x[i])?x[i](m):new Template(x[i]).evaluate(m);exclusion.push("("+v.substring(1,v.length-1)+")");e=e.replace(m[0],'');break;}}} -return"[not("+exclusion.join(" and ")+")]";},'nth-child':function(m){return Selector.xpath.pseudos.nth("(count(./preceding-sibling::*) + 1) ",m);},'nth-last-child':function(m){return Selector.xpath.pseudos.nth("(count(./following-sibling::*) + 1) ",m);},'nth-of-type':function(m){return Selector.xpath.pseudos.nth("position() ",m);},'nth-last-of-type':function(m){return Selector.xpath.pseudos.nth("(last() + 1 - position()) ",m);},'first-of-type':function(m){m[6]="1";return Selector.xpath.pseudos['nth-of-type'](m);},'last-of-type':function(m){m[6]="1";return Selector.xpath.pseudos['nth-last-of-type'](m);},'only-of-type':function(m){var p=Selector.xpath.pseudos;return p['first-of-type'](m)+p['last-of-type'](m);},nth:function(fragment,m){var mm,formula=m[6],predicate;if(formula=='even')formula='2n+0';if(formula=='odd')formula='2n+1';if(mm=formula.match(/^(\d+)$/)) -return'['+fragment+"= "+mm[1]+']';if(mm=formula.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(mm[1]=="-")mm[1]=-1;var a=mm[1]?Number(mm[1]):1;var b=mm[2]?Number(mm[2]):0;predicate="[((#{fragment} - #{b}) mod #{a} = 0) and "+"((#{fragment} - #{b}) div #{a} >= 0)]";return new Template(predicate).evaluate({fragment:fragment,a:a,b:b});}}}},criteria:{tagName:'n = h.tagName(n, r, "#{1}", c); c = false;',className:'n = h.className(n, r, "#{1}", c); c = false;',id:'n = h.id(n, r, "#{1}", c); c = false;',attrPresence:'n = h.attrPresence(n, r, "#{1}"); c = false;',attr:function(m){m[3]=(m[5]||m[6]);return new Template('n = h.attr(n, r, "#{1}", "#{3}", "#{2}"); c = false;').evaluate(m);},pseudo:function(m){if(m[6])m[6]=m[6].replace(/"/g,'\\"');return new Template('n = h.pseudo(n, "#{1}", "#{6}", r, c); c = false;').evaluate(m);},descendant:'c = "descendant";',child:'c = "child";',adjacent:'c = "adjacent";',laterSibling:'c = "laterSibling";'},patterns:{laterSibling:/^\s*~\s*/,child:/^\s*>\s*/,adjacent:/^\s*\+\s*/,descendant:/^\s/,tagName:/^\s*(\*|[\w\-]+)(\b|$)?/,id:/^#([\w\-\*]+)(\b|$)/,className:/^\.([\w\-\*]+)(\b|$)/,pseudo:/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis)abled|not)(\((.*?)\))?(\b|$|(?=\s)|(?=:))/,attrPresence:/^\[([\w]+)\]/,attr:/\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=)\s*((['"])([^\4]*?)\4|([^'"][^\]]*?)))?\]/},assertions:{tagName:function(element,matches){return matches[1].toUpperCase()==element.tagName.toUpperCase();},className:function(element,matches){return Element.hasClassName(element,matches[1]);},id:function(element,matches){return element.id===matches[1];},attrPresence:function(element,matches){return Element.hasAttribute(element,matches[1]);},attr:function(element,matches){var nodeValue=Element.readAttribute(element,matches[1]);return Selector.operators[matches[2]](nodeValue,matches[3]);}},handlers:{concat:function(a,b){for(var i=0,node;node=b[i];i++) -a.push(node);return a;},mark:function(nodes){for(var i=0,node;node=nodes[i];i++) -node._counted=true;return nodes;},unmark:function(nodes){for(var i=0,node;node=nodes[i];i++) -node._counted=undefined;return nodes;},index:function(parentNode,reverse,ofType){parentNode._counted=true;if(reverse){for(var nodes=parentNode.childNodes,i=nodes.length-1,j=1;i>=0;i--){var node=nodes[i];if(node.nodeType==1&&(!ofType||node._counted))node.nodeIndex=j++;}}else{for(var i=0,j=1,nodes=parentNode.childNodes;node=nodes[i];i++) -if(node.nodeType==1&&(!ofType||node._counted))node.nodeIndex=j++;}},unique:function(nodes){if(nodes.length==0)return nodes;var results=[],n;for(var i=0,l=nodes.length;i0?[b]:[];return $R(1,total).inject([],function(memo,i){if(0==(i-b)%a&&(i-b)/a>=0)memo.push(i);return memo;});},nth:function(nodes,formula,root,reverse,ofType){if(nodes.length==0)return[];if(formula=='even')formula='2n+0';if(formula=='odd')formula='2n+1';var h=Selector.handlers,results=[],indexed=[],m;h.mark(nodes);for(var i=0,node;node=nodes[i];i++){if(!node.parentNode._counted){h.index(node.parentNode,reverse,ofType);indexed.push(node.parentNode);}} -if(formula.match(/^\d+$/)){formula=Number(formula);for(var i=0,node;node=nodes[i];i++) -if(node.nodeIndex==formula)results.push(node);}else if(m=formula.match(/^(-?\d*)?n(([+-])(\d+))?/)){if(m[1]=="-")m[1]=-1;var a=m[1]?Number(m[1]):1;var b=m[2]?Number(m[2]):0;var indices=Selector.pseudos.getIndices(a,b,nodes.length);for(var i=0,node,l=indices.length;node=nodes[i];i++){for(var j=0;j+()\s-]+|\*|\[.*?\])+)\s*(,|$)/,function(m){expressions.push(m[1].strip());});var results=[],h=Selector.handlers;for(var i=0,l=expressions.length,selector;i1)?h.unique(results):results;}});if(Prototype.Browser.IE){Selector.handlers.concat=function(a,b){for(var i=0,node;node=b[i];i++) -if(node.tagName!=="!")a.push(node);return a;};} -function $$(){return Selector.findChildElements(document,$A(arguments));} -var Form={reset:function(form){$(form).reset();return form;},serializeElements:function(elements,options){if(typeof options!='object')options={hash:!!options};else if(Object.isUndefined(options.hash))options.hash=true;var key,value,submitted=false,submit=options.submit;var data=elements.inject({},function(result,element){if(!element.disabled&&element.name){key=element.name;value=$(element).getValue();if(value!=null&&(element.type!='submit'||(!submitted&&submit!==false&&(!submit||key==submit)&&(submitted=true)))){if(key in result){if(!Object.isArray(result[key]))result[key]=[result[key]];result[key].push(value);} -else result[key]=value;}} -return result;});return options.hash?data:Object.toQueryString(data);}};Form.Methods={serialize:function(form,options){return Form.serializeElements(Form.getElements(form),options);},getElements:function(form){return $A($(form).getElementsByTagName('*')).inject([],function(elements,child){if(Form.Element.Serializers[child.tagName.toLowerCase()]) -elements.push(Element.extend(child));return elements;});},getInputs:function(form,typeName,name){form=$(form);var inputs=form.getElementsByTagName('input');if(!typeName&&!name)return $A(inputs).map(Element.extend);for(var i=0,matchingInputs=[],length=inputs.length;i=0;}).sortBy(function(element){return element.tabIndex}).first();return firstByIndex?firstByIndex:elements.find(function(element){return['input','select','textarea'].include(element.tagName.toLowerCase());});},focusFirstElement:function(form){form=$(form);form.findFirstElement().activate();return form;},request:function(form,options){form=$(form),options=Object.clone(options||{});var params=options.parameters,action=form.readAttribute('action')||'';if(action.blank())action=window.location.href;options.parameters=form.serialize(true);if(params){if(Object.isString(params))params=params.toQueryParams();Object.extend(options.parameters,params);} -if(form.hasAttribute('method')&&!options.method) -options.method=form.method;return new Ajax.Request(action,options);}};Form.Element={focus:function(element){$(element).focus();return element;},select:function(element){$(element).select();return element;}};Form.Element.Methods={serialize:function(element){element=$(element);if(!element.disabled&&element.name){var value=element.getValue();if(value!=undefined){var pair={};pair[element.name]=value;return Object.toQueryString(pair);}} -return'';},getValue:function(element){element=$(element);var method=element.tagName.toLowerCase();return Form.Element.Serializers[method](element);},setValue:function(element,value){element=$(element);var method=element.tagName.toLowerCase();Form.Element.Serializers[method](element,value);return element;},clear:function(element){$(element).value='';return element;},present:function(element){return $(element).value!='';},activate:function(element){element=$(element);try{element.focus();if(element.select&&(element.tagName.toLowerCase()!='input'||!['button','reset','submit'].include(element.type))) -element.select();}catch(e){} -return element;},disable:function(element){element=$(element);element.blur();element.disabled=true;return element;},enable:function(element){element=$(element);element.disabled=false;return element;}};var Field=Form.Element;var $F=Form.Element.Methods.getValue;Form.Element.Serializers={input:function(element,value){switch(element.type.toLowerCase()){case'checkbox':case'radio':return Form.Element.Serializers.inputSelector(element,value);default:return Form.Element.Serializers.textarea(element,value);}},inputSelector:function(element,value){if(Object.isUndefined(value))return element.checked?element.value:null;else element.checked=!!value;},textarea:function(element,value){if(Object.isUndefined(value))return element.value;else element.value=value;},select:function(element,index){if(Object.isUndefined(index)) -return this[element.type=='select-one'?'selectOne':'selectMany'](element);else{var opt,value,single=!Object.isArray(index);for(var i=0,length=element.length;i=0?this.optionValue(element.options[index]):null;},selectMany:function(element){var values,length=element.length;if(!length)return null;for(var i=0,values=[];i<\/script>");$("__onDOMContentLoaded").onreadystatechange=function(){if(this.readyState=="complete"){this.onreadystatechange=null;fireContentLoadedEvent();}};}})();Hash.toQueryString=Object.toQueryString;var Toggle={display:Element.toggle};Element.Methods.childOf=Element.Methods.descendantOf;var Insertion={Before:function(element,content){return Element.insert(element,{before:content});},Top:function(element,content){return Element.insert(element,{top:content});},Bottom:function(element,content){return Element.insert(element,{bottom:content});},After:function(element,content){return Element.insert(element,{after:content});}};var $continue=new Error('"throw $continue" is deprecated, use "return" instead');var Position={includeScrollOffsets:false,prepare:function(){this.deltaX=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;this.deltaY=window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0;},within:function(element,x,y){if(this.includeScrollOffsets) -return this.withinIncludingScrolloffsets(element,x,y);this.xcomp=x;this.ycomp=y;this.offset=Element.cumulativeOffset(element);return(y>=this.offset[1]&&y=this.offset[0]&&x=this.offset[1]&&this.ycomp=this.offset[0]&&this.xcomp0;})._each(iterator);},set:function(className){this.element.className=className;},add:function(classNameToAdd){if(this.include(classNameToAdd))return;this.set($A(this).concat(classNameToAdd).join(' '));},remove:function(classNameToRemove){if(!this.include(classNameToRemove))return;this.set($A(this).without(classNameToRemove).join(' '));},toString:function(){return $A(this).join(' ');}};Object.extend(Element.ClassNames.prototype,Enumerable);Element.addMethods();String.prototype.parseColor=function(){var color='#';if(this.slice(0,4)=='rgb('){var cols=this.slice(4,this.length-1).split(',');var i=0;do{color+=parseInt(cols[i]).toColorPart()}while(++i<3);}else{if(this.slice(0,1)=='#'){if(this.length==4)for(var i=1;i<4;i++)color+=(this.charAt(i)+this.charAt(i)).toLowerCase();if(this.length==7)color=this.toLowerCase();}} -return(color.length==7?color:(arguments[0]||this));};Element.collectTextNodes=function(element){return $A($(element).childNodes).collect(function(node){return(node.nodeType==3?node.nodeValue:(node.hasChildNodes()?Element.collectTextNodes(node):''));}).flatten().join('');};Element.collectTextNodesIgnoreClass=function(element,className){return $A($(element).childNodes).collect(function(node){return(node.nodeType==3?node.nodeValue:((node.hasChildNodes()&&!Element.hasClassName(node,className))?Element.collectTextNodesIgnoreClass(node,className):''));}).flatten().join('');};Element.setContentZoom=function(element,percent){element=$(element);element.setStyle({fontSize:(percent/100)+'em'});if(Prototype.Browser.WebKit)window.scrollBy(0,0);return element;};Element.getInlineOpacity=function(element){return $(element).style.opacity||'';};Element.forceRerendering=function(element){try{element=$(element);var n=document.createTextNode(' ');element.appendChild(n);element.removeChild(n);}catch(e){}};var Effect={_elementDoesNotExistError:{name:'ElementDoesNotExistError',message:'The specified DOM element does not exist, but is required for this effect to operate'},Transitions:{linear:Prototype.K,sinoidal:function(pos){return(-Math.cos(pos*Math.PI)/2)+0.5;},reverse:function(pos){return 1-pos;},flicker:function(pos){var pos=((-Math.cos(pos*Math.PI)/4)+0.75)+Math.random()/4;return pos>1?1:pos;},wobble:function(pos){return(-Math.cos(pos*Math.PI*(9*pos))/2)+0.5;},pulse:function(pos,pulses){pulses=pulses||5;return(((pos%(1/pulses))*pulses).round()==0?((pos*pulses*2)-(pos*pulses*2).floor()):1-((pos*pulses*2)-(pos*pulses*2).floor()));},spring:function(pos){return 1-(Math.cos(pos*4.5*Math.PI)*Math.exp(-pos*6));},none:function(pos){return 0;},full:function(pos){return 1;}},DefaultOptions:{duration:1.0,fps:100,sync:false,from:0.0,to:1.0,delay:0.0,queue:'parallel'},tagifyText:function(element){var tagifyStyle='position:relative';if(Prototype.Browser.IE)tagifyStyle+=';zoom:1';element=$(element);$A(element.childNodes).each(function(child){if(child.nodeType==3){child.nodeValue.toArray().each(function(character){element.insertBefore(new Element('span',{style:tagifyStyle}).update(character==' '?String.fromCharCode(160):character),child);});Element.remove(child);}});},multiple:function(element,effect){var elements;if(((typeof element=='object')||Object.isFunction(element))&&(element.length)) -elements=element;else -elements=$(element).childNodes;var options=Object.extend({speed:0.1,delay:0.0},arguments[2]||{});var masterDelay=options.delay;$A(elements).each(function(element,index){new effect(element,Object.extend(options,{delay:index*options.speed+masterDelay}));});},PAIRS:{'slide':['SlideDown','SlideUp'],'blind':['BlindDown','BlindUp'],'appear':['Appear','Fade']},toggle:function(element,effect){element=$(element);effect=(effect||'appear').toLowerCase();var options=Object.extend({queue:{position:'end',scope:(element.id||'global'),limit:1}},arguments[2]||{});Effect[element.visible()?Effect.PAIRS[effect][1]:Effect.PAIRS[effect][0]](element,options);}};Effect.DefaultOptions.transition=Effect.Transitions.sinoidal;Effect.ScopedQueue=Class.create(Enumerable,{initialize:function(){this.effects=[];this.interval=null;},_each:function(iterator){this.effects._each(iterator);},add:function(effect){var timestamp=new Date().getTime();var position=Object.isString(effect.options.queue)?effect.options.queue:effect.options.queue.position;switch(position){case'front':this.effects.findAll(function(e){return e.state=='idle'}).each(function(e){e.startOn+=effect.finishOn;e.finishOn+=effect.finishOn;});break;case'with-last':timestamp=this.effects.pluck('startOn').max()||timestamp;break;case'end':timestamp=this.effects.pluck('finishOn').max()||timestamp;break;} -effect.startOn+=timestamp;effect.finishOn+=timestamp;if(!effect.options.queue.limit||(this.effects.length=this.startOn){if(timePos>=this.finishOn){this.render(1.0);this.cancel();this.event('beforeFinish');if(this.finish)this.finish();this.event('afterFinish');return;} -var pos=(timePos-this.startOn)/this.totalTime,frame=(pos*this.totalFrames).round();if(frame>this.currentFrame){this.render(pos);this.currentFrame=frame;}}},cancel:function(){if(!this.options.sync) -Effect.Queues.get(Object.isString(this.options.queue)?'global':this.options.queue.scope).remove(this);this.state='finished';},event:function(eventName){if(this.options[eventName+'Internal'])this.options[eventName+'Internal'](this);if(this.options[eventName])this.options[eventName](this);},inspect:function(){var data=$H();for(property in this) -if(!Object.isFunction(this[property]))data.set(property,this[property]);return'#';}});Effect.Parallel=Class.create(Effect.Base,{initialize:function(effects){this.effects=effects||[];this.start(arguments[1]);},update:function(position){this.effects.invoke('render',position);},finish:function(position){this.effects.each(function(effect){effect.render(1.0);effect.cancel();effect.event('beforeFinish');if(effect.finish)effect.finish(position);effect.event('afterFinish');});}});Effect.Tween=Class.create(Effect.Base,{initialize:function(object,from,to){object=Object.isString(object)?$(object):object;var args=$A(arguments),method=args.last(),options=args.length==5?args[3]:null;this.method=Object.isFunction(method)?method.bind(object):Object.isFunction(object[method])?object[method].bind(object):function(value){object[method]=value};this.start(Object.extend({from:from,to:to},options||{}));},update:function(position){this.method(position);}});Effect.Event=Class.create(Effect.Base,{initialize:function(){this.start(Object.extend({duration:0},arguments[0]||{}));},update:Prototype.emptyFunction});Effect.Opacity=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);if(Prototype.Browser.IE&&(!this.element.currentStyle.hasLayout)) -this.element.setStyle({zoom:1});var options=Object.extend({from:this.element.getOpacity()||0.0,to:1.0},arguments[1]||{});this.start(options);},update:function(position){this.element.setOpacity(position);}});Effect.Move=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({x:0,y:0,mode:'relative'},arguments[1]||{});this.start(options);},setup:function(){this.element.makePositioned();this.originalLeft=parseFloat(this.element.getStyle('left')||'0');this.originalTop=parseFloat(this.element.getStyle('top')||'0');if(this.options.mode=='absolute'){this.options.x=this.options.x-this.originalLeft;this.options.y=this.options.y-this.originalTop;}},update:function(position){this.element.setStyle({left:(this.options.x*position+this.originalLeft).round()+'px',top:(this.options.y*position+this.originalTop).round()+'px'});}});Effect.MoveBy=function(element,toTop,toLeft){return new Effect.Move(element,Object.extend({x:toLeft,y:toTop},arguments[3]||{}));};Effect.Scale=Class.create(Effect.Base,{initialize:function(element,percent){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({scaleX:true,scaleY:true,scaleContent:true,scaleFromCenter:false,scaleMode:'box',scaleFrom:100.0,scaleTo:percent},arguments[2]||{});this.start(options);},setup:function(){this.restoreAfterFinish=this.options.restoreAfterFinish||false;this.elementPositioning=this.element.getStyle('position');this.originalStyle={};['top','left','width','height','fontSize'].each(function(k){this.originalStyle[k]=this.element.style[k];}.bind(this));this.originalTop=this.element.offsetTop;this.originalLeft=this.element.offsetLeft;var fontSize=this.element.getStyle('font-size')||'100%';['em','px','%','pt'].each(function(fontSizeType){if(fontSize.indexOf(fontSizeType)>0){this.fontSize=parseFloat(fontSize);this.fontSizeType=fontSizeType;}}.bind(this));this.factor=(this.options.scaleTo-this.options.scaleFrom)/100;this.dims=null;if(this.options.scaleMode=='box') -this.dims=[this.element.offsetHeight,this.element.offsetWidth];if(/^content/.test(this.options.scaleMode)) -this.dims=[this.element.scrollHeight,this.element.scrollWidth];if(!this.dims) -this.dims=[this.options.scaleMode.originalHeight,this.options.scaleMode.originalWidth];},update:function(position){var currentScale=(this.options.scaleFrom/100.0)+(this.factor*position);if(this.options.scaleContent&&this.fontSize) -this.element.setStyle({fontSize:this.fontSize*currentScale+this.fontSizeType});this.setDimensions(this.dims[0]*currentScale,this.dims[1]*currentScale);},finish:function(position){if(this.restoreAfterFinish)this.element.setStyle(this.originalStyle);},setDimensions:function(height,width){var d={};if(this.options.scaleX)d.width=width.round()+'px';if(this.options.scaleY)d.height=height.round()+'px';if(this.options.scaleFromCenter){var topd=(height-this.dims[0])/2;var leftd=(width-this.dims[1])/2;if(this.elementPositioning=='absolute'){if(this.options.scaleY)d.top=this.originalTop-topd+'px';if(this.options.scaleX)d.left=this.originalLeft-leftd+'px';}else{if(this.options.scaleY)d.top=-topd+'px';if(this.options.scaleX)d.left=-leftd+'px';}} -this.element.setStyle(d);}});Effect.Highlight=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({startcolor:'#ffff99'},arguments[1]||{});this.start(options);},setup:function(){if(this.element.getStyle('display')=='none'){this.cancel();return;} -this.oldStyle={};if(!this.options.keepBackgroundImage){this.oldStyle.backgroundImage=this.element.getStyle('background-image');this.element.setStyle({backgroundImage:'none'});} -if(!this.options.endcolor) -this.options.endcolor=this.element.getStyle('background-color').parseColor('#ffffff');if(!this.options.restorecolor) -this.options.restorecolor=this.element.getStyle('background-color');this._base=$R(0,2).map(function(i){return parseInt(this.options.startcolor.slice(i*2+1,i*2+3),16)}.bind(this));this._delta=$R(0,2).map(function(i){return parseInt(this.options.endcolor.slice(i*2+1,i*2+3),16)-this._base[i]}.bind(this));},update:function(position){this.element.setStyle({backgroundColor:$R(0,2).inject('#',function(m,v,i){return m+((this._base[i]+(this._delta[i]*position)).round().toColorPart());}.bind(this))});},finish:function(){this.element.setStyle(Object.extend(this.oldStyle,{backgroundColor:this.options.restorecolor}));}});Effect.ScrollTo=function(element){var options=arguments[1]||{},scrollOffsets=document.viewport.getScrollOffsets(),elementOffsets=$(element).cumulativeOffset(),max=(window.height||document.body.scrollHeight)-document.viewport.getHeight();if(options.offset)elementOffsets[1]+=options.offset;return new Effect.Tween(null,scrollOffsets.top,elementOffsets[1]>max?max:elementOffsets[1],options,function(p){scrollTo(scrollOffsets.left,p.round())});};Effect.Fade=function(element){element=$(element);var oldOpacity=element.getInlineOpacity();var options=Object.extend({from:element.getOpacity()||1.0,to:0.0,afterFinishInternal:function(effect){if(effect.options.to!=0)return;effect.element.hide().setStyle({opacity:oldOpacity});}},arguments[1]||{});return new Effect.Opacity(element,options);};Effect.Appear=function(element){element=$(element);var options=Object.extend({from:(element.getStyle('display')=='none'?0.0:element.getOpacity()||0.0),to:1.0,afterFinishInternal:function(effect){effect.element.forceRerendering();},beforeSetup:function(effect){effect.element.setOpacity(effect.options.from).show();}},arguments[1]||{});return new Effect.Opacity(element,options);};Effect.Puff=function(element){element=$(element);var oldStyle={opacity:element.getInlineOpacity(),position:element.getStyle('position'),top:element.style.top,left:element.style.left,width:element.style.width,height:element.style.height};return new Effect.Parallel([new Effect.Scale(element,200,{sync:true,scaleFromCenter:true,scaleContent:true,restoreAfterFinish:true}),new Effect.Opacity(element,{sync:true,to:0.0})],Object.extend({duration:1.0,beforeSetupInternal:function(effect){Position.absolutize(effect.effects[0].element)},afterFinishInternal:function(effect){effect.effects[0].element.hide().setStyle(oldStyle);}},arguments[1]||{}));};Effect.BlindUp=function(element){element=$(element);element.makeClipping();return new Effect.Scale(element,0,Object.extend({scaleContent:false,scaleX:false,restoreAfterFinish:true,afterFinishInternal:function(effect){effect.element.hide().undoClipping();}},arguments[1]||{}));};Effect.BlindDown=function(element){element=$(element);var elementDimensions=element.getDimensions();return new Effect.Scale(element,100,Object.extend({scaleContent:false,scaleX:false,scaleFrom:0,scaleMode:{originalHeight:elementDimensions.height,originalWidth:elementDimensions.width},restoreAfterFinish:true,afterSetup:function(effect){effect.element.makeClipping().setStyle({height:'0px'}).show();},afterFinishInternal:function(effect){effect.element.undoClipping();}},arguments[1]||{}));};Effect.SwitchOff=function(element){element=$(element);var oldOpacity=element.getInlineOpacity();return new Effect.Appear(element,Object.extend({duration:0.4,from:0,transition:Effect.Transitions.flicker,afterFinishInternal:function(effect){new Effect.Scale(effect.element,1,{duration:0.3,scaleFromCenter:true,scaleX:false,scaleContent:false,restoreAfterFinish:true,beforeSetup:function(effect){effect.element.makePositioned().makeClipping();},afterFinishInternal:function(effect){effect.element.hide().undoClipping().undoPositioned().setStyle({opacity:oldOpacity});}})}},arguments[1]||{}));};Effect.DropOut=function(element){element=$(element);var oldStyle={top:element.getStyle('top'),left:element.getStyle('left'),opacity:element.getInlineOpacity()};return new Effect.Parallel([new Effect.Move(element,{x:0,y:100,sync:true}),new Effect.Opacity(element,{sync:true,to:0.0})],Object.extend({duration:0.5,beforeSetup:function(effect){effect.effects[0].element.makePositioned();},afterFinishInternal:function(effect){effect.effects[0].element.hide().undoPositioned().setStyle(oldStyle);}},arguments[1]||{}));};Effect.Shake=function(element){element=$(element);var options=Object.extend({distance:20,duration:0.5},arguments[1]||{});var distance=parseFloat(options.distance);var split=parseFloat(options.duration)/10.0;var oldStyle={top:element.getStyle('top'),left:element.getStyle('left')};return new Effect.Move(element,{x:distance,y:0,duration:split,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:-distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:-distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:distance*2,y:0,duration:split*2,afterFinishInternal:function(effect){new Effect.Move(effect.element,{x:-distance,y:0,duration:split,afterFinishInternal:function(effect){effect.element.undoPositioned().setStyle(oldStyle);}})}})}})}})}})}});};Effect.SlideDown=function(element){element=$(element).cleanWhitespace();var oldInnerBottom=element.down().getStyle('bottom');var elementDimensions=element.getDimensions();return new Effect.Scale(element,100,Object.extend({scaleContent:false,scaleX:false,scaleFrom:window.opera?0:1,scaleMode:{originalHeight:elementDimensions.height,originalWidth:elementDimensions.width},restoreAfterFinish:true,afterSetup:function(effect){effect.element.makePositioned();effect.element.down().makePositioned();if(window.opera)effect.element.setStyle({top:''});effect.element.makeClipping().setStyle({height:'0px'}).show();},afterUpdateInternal:function(effect){effect.element.down().setStyle({bottom:(effect.dims[0]-effect.element.clientHeight)+'px'});},afterFinishInternal:function(effect){effect.element.undoClipping().undoPositioned();effect.element.down().undoPositioned().setStyle({bottom:oldInnerBottom});}},arguments[1]||{}));};Effect.SlideUp=function(element){element=$(element).cleanWhitespace();var oldInnerBottom=element.down().getStyle('bottom');var elementDimensions=element.getDimensions();return new Effect.Scale(element,window.opera?0:1,Object.extend({scaleContent:false,scaleX:false,scaleMode:'box',scaleFrom:100,scaleMode:{originalHeight:elementDimensions.height,originalWidth:elementDimensions.width},restoreAfterFinish:true,afterSetup:function(effect){effect.element.makePositioned();effect.element.down().makePositioned();if(window.opera)effect.element.setStyle({top:''});effect.element.makeClipping().show();},afterUpdateInternal:function(effect){effect.element.down().setStyle({bottom:(effect.dims[0]-effect.element.clientHeight)+'px'});},afterFinishInternal:function(effect){effect.element.hide().undoClipping().undoPositioned();effect.element.down().undoPositioned().setStyle({bottom:oldInnerBottom});}},arguments[1]||{}));};Effect.Squish=function(element){return new Effect.Scale(element,window.opera?1:0,{restoreAfterFinish:true,beforeSetup:function(effect){effect.element.makeClipping();},afterFinishInternal:function(effect){effect.element.hide().undoClipping();}});};Effect.Grow=function(element){element=$(element);var options=Object.extend({direction:'center',moveTransition:Effect.Transitions.sinoidal,scaleTransition:Effect.Transitions.sinoidal,opacityTransition:Effect.Transitions.full},arguments[1]||{});var oldStyle={top:element.style.top,left:element.style.left,height:element.style.height,width:element.style.width,opacity:element.getInlineOpacity()};var dims=element.getDimensions();var initialMoveX,initialMoveY;var moveX,moveY;switch(options.direction){case'top-left':initialMoveX=initialMoveY=moveX=moveY=0;break;case'top-right':initialMoveX=dims.width;initialMoveY=moveY=0;moveX=-dims.width;break;case'bottom-left':initialMoveX=moveX=0;initialMoveY=dims.height;moveY=-dims.height;break;case'bottom-right':initialMoveX=dims.width;initialMoveY=dims.height;moveX=-dims.width;moveY=-dims.height;break;case'center':initialMoveX=dims.width/2;initialMoveY=dims.height/2;moveX=-dims.width/2;moveY=-dims.height/2;break;} -return new Effect.Move(element,{x:initialMoveX,y:initialMoveY,duration:0.01,beforeSetup:function(effect){effect.element.hide().makeClipping().makePositioned();},afterFinishInternal:function(effect){new Effect.Parallel([new Effect.Opacity(effect.element,{sync:true,to:1.0,from:0.0,transition:options.opacityTransition}),new Effect.Move(effect.element,{x:moveX,y:moveY,sync:true,transition:options.moveTransition}),new Effect.Scale(effect.element,100,{scaleMode:{originalHeight:dims.height,originalWidth:dims.width},sync:true,scaleFrom:window.opera?1:0,transition:options.scaleTransition,restoreAfterFinish:true})],Object.extend({beforeSetup:function(effect){effect.effects[0].element.setStyle({height:'0px'}).show();},afterFinishInternal:function(effect){effect.effects[0].element.undoClipping().undoPositioned().setStyle(oldStyle);}},options))}});};Effect.Shrink=function(element){element=$(element);var options=Object.extend({direction:'center',moveTransition:Effect.Transitions.sinoidal,scaleTransition:Effect.Transitions.sinoidal,opacityTransition:Effect.Transitions.none},arguments[1]||{});var oldStyle={top:element.style.top,left:element.style.left,height:element.style.height,width:element.style.width,opacity:element.getInlineOpacity()};var dims=element.getDimensions();var moveX,moveY;switch(options.direction){case'top-left':moveX=moveY=0;break;case'top-right':moveX=dims.width;moveY=0;break;case'bottom-left':moveX=0;moveY=dims.height;break;case'bottom-right':moveX=dims.width;moveY=dims.height;break;case'center':moveX=dims.width/2;moveY=dims.height/2;break;} -return new Effect.Parallel([new Effect.Opacity(element,{sync:true,to:0.0,from:1.0,transition:options.opacityTransition}),new Effect.Scale(element,window.opera?1:0,{sync:true,transition:options.scaleTransition,restoreAfterFinish:true}),new Effect.Move(element,{x:moveX,y:moveY,sync:true,transition:options.moveTransition})],Object.extend({beforeStartInternal:function(effect){effect.effects[0].element.makePositioned().makeClipping();},afterFinishInternal:function(effect){effect.effects[0].element.hide().undoClipping().undoPositioned().setStyle(oldStyle);}},options));};Effect.Pulsate=function(element){element=$(element);var options=arguments[1]||{};var oldOpacity=element.getInlineOpacity();var transition=options.transition||Effect.Transitions.sinoidal;var reverser=function(pos){return transition(1-Effect.Transitions.pulse(pos,options.pulses))};reverser.bind(transition);return new Effect.Opacity(element,Object.extend(Object.extend({duration:2.0,from:0,afterFinishInternal:function(effect){effect.element.setStyle({opacity:oldOpacity});}},options),{transition:reverser}));};Effect.Fold=function(element){element=$(element);var oldStyle={top:element.style.top,left:element.style.left,width:element.style.width,height:element.style.height};element.makeClipping();return new Effect.Scale(element,5,Object.extend({scaleContent:false,scaleX:false,afterFinishInternal:function(effect){new Effect.Scale(element,1,{scaleContent:false,scaleY:false,afterFinishInternal:function(effect){effect.element.hide().undoClipping().setStyle(oldStyle);}});}},arguments[1]||{}));};Effect.Morph=Class.create(Effect.Base,{initialize:function(element){this.element=$(element);if(!this.element)throw(Effect._elementDoesNotExistError);var options=Object.extend({style:{}},arguments[1]||{});if(!Object.isString(options.style))this.style=$H(options.style);else{if(options.style.include(':')) -this.style=options.style.parseStyle();else{this.element.addClassName(options.style);this.style=$H(this.element.getStyles());this.element.removeClassName(options.style);var css=this.element.getStyles();this.style=this.style.reject(function(style){return style.value==css[style.key];});options.afterFinishInternal=function(effect){effect.element.addClassName(effect.options.style);effect.transforms.each(function(transform){effect.element.style[transform.style]='';});}}} -this.start(options);},setup:function(){function parseColor(color){if(!color||['rgba(0, 0, 0, 0)','transparent'].include(color))color='#ffffff';color=color.parseColor();return $R(0,2).map(function(i){return parseInt(color.slice(i*2+1,i*2+3),16)});} -this.transforms=this.style.map(function(pair){var property=pair[0],value=pair[1],unit=null;if(value.parseColor('#zzzzzz')!='#zzzzzz'){value=value.parseColor();unit='color';}else if(property=='opacity'){value=parseFloat(value);if(Prototype.Browser.IE&&(!this.element.currentStyle.hasLayout)) -this.element.setStyle({zoom:1});}else if(Element.CSS_LENGTH.test(value)){var components=value.match(/^([\+\-]?[0-9\.]+)(.*)$/);value=parseFloat(components[1]);unit=(components.length==3)?components[2]:null;} -var originalValue=this.element.getStyle(property);return{style:property.camelize(),originalValue:unit=='color'?parseColor(originalValue):parseFloat(originalValue||0),targetValue:unit=='color'?parseColor(value):value,unit:unit};}.bind(this)).reject(function(transform){return((transform.originalValue==transform.targetValue)||(transform.unit!='color'&&(isNaN(transform.originalValue)||isNaN(transform.targetValue))))});},update:function(position){var style={},transform,i=this.transforms.length;while(i--) -style[(transform=this.transforms[i]).style]=transform.unit=='color'?'#'+ -(Math.round(transform.originalValue[0]+ -(transform.targetValue[0]-transform.originalValue[0])*position)).toColorPart()+ -(Math.round(transform.originalValue[1]+ -(transform.targetValue[1]-transform.originalValue[1])*position)).toColorPart()+ -(Math.round(transform.originalValue[2]+ -(transform.targetValue[2]-transform.originalValue[2])*position)).toColorPart():(transform.originalValue+ -(transform.targetValue-transform.originalValue)*position).toFixed(3)+ -(transform.unit===null?'':transform.unit);this.element.setStyle(style,true);}});Effect.Transform=Class.create({initialize:function(tracks){this.tracks=[];this.options=arguments[1]||{};this.addTracks(tracks);},addTracks:function(tracks){tracks.each(function(track){track=$H(track);var data=track.values().first();this.tracks.push($H({ids:track.keys().first(),effect:Effect.Morph,options:{style:data}}));}.bind(this));return this;},play:function(){return new Effect.Parallel(this.tracks.map(function(track){var ids=track.get('ids'),effect=track.get('effect'),options=track.get('options');var elements=[$(ids)||$$(ids)].flatten();return elements.map(function(e){return new effect(e,Object.extend({sync:true},options))});}).flatten(),this.options);}});Element.CSS_PROPERTIES=$w('backgroundColor backgroundPosition borderBottomColor borderBottomStyle '+'borderBottomWidth borderLeftColor borderLeftStyle borderLeftWidth '+'borderRightColor borderRightStyle borderRightWidth borderSpacing '+'borderTopColor borderTopStyle borderTopWidth bottom clip color '+'fontSize fontWeight height left letterSpacing lineHeight '+'marginBottom marginLeft marginRight marginTop markerOffset maxHeight '+'maxWidth minHeight minWidth opacity outlineColor outlineOffset '+'outlineWidth paddingBottom paddingLeft paddingRight paddingTop '+'right textIndent top width wordSpacing zIndex');Element.CSS_LENGTH=/^(([\+\-]?[0-9\.]+)(em|ex|px|in|cm|mm|pt|pc|\%))|0$/;String.__parseStyleElement=document.createElement('div');String.prototype.parseStyle=function(){var style,styleRules=$H();if(Prototype.Browser.WebKit) -style=new Element('div',{style:this}).style;else{String.__parseStyleElement.innerHTML='
        ';style=String.__parseStyleElement.childNodes[0].style;} -Element.CSS_PROPERTIES.each(function(property){if(style[property])styleRules.set(property,style[property]);});if(Prototype.Browser.IE&&this.include('opacity')) -styleRules.set('opacity',this.match(/opacity:\s*((?:0|1)?(?:\.\d*)?)/)[1]);return styleRules;};if(document.defaultView&&document.defaultView.getComputedStyle){Element.getStyles=function(element){var css=document.defaultView.getComputedStyle($(element),null);return Element.CSS_PROPERTIES.inject({},function(styles,property){styles[property]=css[property];return styles;});};}else{Element.getStyles=function(element){element=$(element);var css=element.currentStyle,styles;styles=Element.CSS_PROPERTIES.inject({},function(hash,property){hash.set(property,css[property]);return hash;});if(!styles.opacity)styles.set('opacity',element.getOpacity());return styles;};};Effect.Methods={morph:function(element,style){element=$(element);new Effect.Morph(element,Object.extend({style:style},arguments[2]||{}));return element;},visualEffect:function(element,effect,options){element=$(element) -var s=effect.dasherize().camelize(),klass=s.charAt(0).toUpperCase()+s.substring(1);new Effect[klass](element,options);return element;},highlight:function(element,options){element=$(element);new Effect.Highlight(element,options);return element;}};$w('fade appear grow shrink fold blindUp blindDown slideUp slideDown '+'pulsate shake puff squish switchOff dropOut').each(function(effect){Effect.Methods[effect]=function(element,options){element=$(element);Effect[effect.charAt(0).toUpperCase()+effect.substring(1)](element,options);return element;}});$w('getInlineOpacity forceRerendering setContentZoom collectTextNodes collectTextNodesIgnoreClass getStyles').each(function(f){Effect.Methods[f]=Element[f];});Element.addMethods(Effect.Methods);if(Object.isUndefined(Effect)) -throw("dragdrop.js requires including script.aculo.us' effects.js library");var Droppables={drops:[],remove:function(element){this.drops=this.drops.reject(function(d){return d.element==$(element)});},add:function(element){element=$(element);var options=Object.extend({greedy:true,hoverclass:null,tree:false},arguments[1]||{});if(options.containment){options._containers=[];var containment=options.containment;if(Object.isArray(containment)){containment.each(function(c){options._containers.push($(c))});}else{options._containers.push($(containment));}} -if(options.accept)options.accept=[options.accept].flatten();Element.makePositioned(element);options.element=element;this.drops.push(options);},findDeepestChild:function(drops){deepest=drops[0];for(i=1;i0) -drop=Droppables.findDeepestChild(affected);if(this.last_active&&this.last_active!=drop)this.deactivate(this.last_active);if(drop){Position.within(drop.element,point[0],point[1]);if(drop.onHover) -drop.onHover(element,drop.element,Position.overlap(drop.overlap,drop.element));if(drop!=this.last_active)Droppables.activate(drop);}},fire:function(event,element){if(!this.last_active)return;Position.prepare();if(this.isAffected([Event.pointerX(event),Event.pointerY(event)],element,this.last_active)) -if(this.last_active.onDrop){this.last_active.onDrop(element,this.last_active.element,event);return true;}},reset:function(){if(this.last_active) -this.deactivate(this.last_active);}} -var Draggables={drags:[],observers:[],register:function(draggable){if(this.drags.length==0){this.eventMouseUp=this.endDrag.bindAsEventListener(this);this.eventMouseMove=this.updateDrag.bindAsEventListener(this);this.eventKeypress=this.keyPress.bindAsEventListener(this);Event.observe(document,"mouseup",this.eventMouseUp);Event.observe(document,"mousemove",this.eventMouseMove);Event.observe(document,"keypress",this.eventKeypress);} -this.drags.push(draggable);},unregister:function(draggable){this.drags=this.drags.reject(function(d){return d==draggable});if(this.drags.length==0){Event.stopObserving(document,"mouseup",this.eventMouseUp);Event.stopObserving(document,"mousemove",this.eventMouseMove);Event.stopObserving(document,"keypress",this.eventKeypress);}},activate:function(draggable){if(draggable.options.delay){this._timeout=setTimeout(function(){Draggables._timeout=null;window.focus();Draggables.activeDraggable=draggable;}.bind(this),draggable.options.delay);}else{window.focus();this.activeDraggable=draggable;}},deactivate:function(){this.activeDraggable=null;},updateDrag:function(event){if(!this.activeDraggable)return;var pointer=[Event.pointerX(event),Event.pointerY(event)];if(this._lastPointer&&(this._lastPointer.inspect()==pointer.inspect()))return;this._lastPointer=pointer;this.activeDraggable.updateDrag(event,pointer);},endDrag:function(event){if(this._timeout){clearTimeout(this._timeout);this._timeout=null;} -if(!this.activeDraggable)return;this._lastPointer=null;this.activeDraggable.endDrag(event);this.activeDraggable=null;},keyPress:function(event){if(this.activeDraggable) -this.activeDraggable.keyPress(event);},addObserver:function(observer){this.observers.push(observer);this._cacheObserverCallbacks();},removeObserver:function(element){this.observers=this.observers.reject(function(o){return o.element==element});this._cacheObserverCallbacks();},notify:function(eventName,draggable,event){if(this[eventName+'Count']>0) -this.observers.each(function(o){if(o[eventName])o[eventName](eventName,draggable,event);});if(draggable.options[eventName])draggable.options[eventName](draggable,event);},_cacheObserverCallbacks:function(){['onStart','onEnd','onDrag'].each(function(eventName){Draggables[eventName+'Count']=Draggables.observers.select(function(o){return o[eventName];}).length;});}} -var Draggable=Class.create({initialize:function(element){var defaults={handle:false,reverteffect:function(element,top_offset,left_offset){var dur=Math.sqrt(Math.abs(top_offset^2)+Math.abs(left_offset^2))*0.02;new Effect.Move(element,{x:-left_offset,y:-top_offset,duration:dur,queue:{scope:'_draggable',position:'end'}});},endeffect:function(element){var toOpacity=Object.isNumber(element._opacity)?element._opacity:1.0;new Effect.Opacity(element,{duration:0.2,from:0.7,to:toOpacity,queue:{scope:'_draggable',position:'end'},afterFinish:function(){Draggable._dragging[element]=false}});},zindex:1000,revert:false,quiet:false,scroll:false,scrollSensitivity:20,scrollSpeed:15,snap:false,delay:0};if(!arguments[1]||Object.isUndefined(arguments[1].endeffect)) -Object.extend(defaults,{starteffect:function(element){element._opacity=Element.getOpacity(element);Draggable._dragging[element]=true;new Effect.Opacity(element,{duration:0.2,from:element._opacity,to:0.7});}});var options=Object.extend(defaults,arguments[1]||{});this.element=$(element);if(options.handle&&Object.isString(options.handle)) -this.handle=this.element.down('.'+options.handle,0);if(!this.handle)this.handle=$(options.handle);if(!this.handle)this.handle=this.element;if(options.scroll&&!options.scroll.scrollTo&&!options.scroll.outerHTML){options.scroll=$(options.scroll);this._isScrollChild=Element.childOf(this.element,options.scroll);} -Element.makePositioned(this.element);this.options=options;this.dragging=false;this.eventMouseDown=this.initDrag.bindAsEventListener(this);Event.observe(this.handle,"mousedown",this.eventMouseDown);Draggables.register(this);},destroy:function(){Event.stopObserving(this.handle,"mousedown",this.eventMouseDown);Draggables.unregister(this);},currentDelta:function(){return([parseInt(Element.getStyle(this.element,'left')||'0'),parseInt(Element.getStyle(this.element,'top')||'0')]);},initDrag:function(event){if(!Object.isUndefined(Draggable._dragging[this.element])&&Draggable._dragging[this.element])return;if(Event.isLeftClick(event)){var src=Event.element(event);if((tag_name=src.tagName.toUpperCase())&&(tag_name=='INPUT'||tag_name=='SELECT'||tag_name=='OPTION'||tag_name=='BUTTON'||tag_name=='TEXTAREA'))return;var pointer=[Event.pointerX(event),Event.pointerY(event)];var pos=Position.cumulativeOffset(this.element);this.offset=[0,1].map(function(i){return(pointer[i]-pos[i])});Draggables.activate(this);Event.stop(event);}},startDrag:function(event){this.dragging=true;if(!this.delta) -this.delta=this.currentDelta();if(this.options.zindex){this.originalZ=parseInt(Element.getStyle(this.element,'z-index')||0);this.element.style.zIndex=this.options.zindex;} -if(this.options.ghosting){this._clone=this.element.cloneNode(true);this.element._originallyAbsolute=(this.element.getStyle('position')=='absolute');if(!this.element._originallyAbsolute) -Position.absolutize(this.element);this.element.parentNode.insertBefore(this._clone,this.element);} -if(this.options.scroll){if(this.options.scroll==window){var where=this._getWindowScroll(this.options.scroll);this.originalScrollLeft=where.left;this.originalScrollTop=where.top;}else{this.originalScrollLeft=this.options.scroll.scrollLeft;this.originalScrollTop=this.options.scroll.scrollTop;}} -Draggables.notify('onStart',this,event);if(this.options.starteffect)this.options.starteffect(this.element);},updateDrag:function(event,pointer){if(!this.dragging)this.startDrag(event);if(!this.options.quiet){Position.prepare();Droppables.show(pointer,this.element);} -Draggables.notify('onDrag',this,event);this.draw(pointer);if(this.options.change)this.options.change(this);if(this.options.scroll){this.stopScrolling();var p;if(this.options.scroll==window){with(this._getWindowScroll(this.options.scroll)){p=[left,top,left+width,top+height];}}else{p=Position.page(this.options.scroll);p[0]+=this.options.scroll.scrollLeft+Position.deltaX;p[1]+=this.options.scroll.scrollTop+Position.deltaY;p.push(p[0]+this.options.scroll.offsetWidth);p.push(p[1]+this.options.scroll.offsetHeight);} -var speed=[0,0];if(pointer[0]<(p[0]+this.options.scrollSensitivity))speed[0]=pointer[0]-(p[0]+this.options.scrollSensitivity);if(pointer[1]<(p[1]+this.options.scrollSensitivity))speed[1]=pointer[1]-(p[1]+this.options.scrollSensitivity);if(pointer[0]>(p[2]-this.options.scrollSensitivity))speed[0]=pointer[0]-(p[2]-this.options.scrollSensitivity);if(pointer[1]>(p[3]-this.options.scrollSensitivity))speed[1]=pointer[1]-(p[3]-this.options.scrollSensitivity);this.startScrolling(speed);} -if(Prototype.Browser.WebKit)window.scrollBy(0,0);Event.stop(event);},finishDrag:function(event,success){this.dragging=false;if(this.options.quiet){Position.prepare();var pointer=[Event.pointerX(event),Event.pointerY(event)];Droppables.show(pointer,this.element);} -if(this.options.ghosting){if(!this.element._originallyAbsolute) -Position.relativize(this.element);delete this.element._originallyAbsolute;Element.remove(this._clone);this._clone=null;} -var dropped=false;if(success){dropped=Droppables.fire(event,this.element);if(!dropped)dropped=false;} -if(dropped&&this.options.onDropped)this.options.onDropped(this.element);Draggables.notify('onEnd',this,event);var revert=this.options.revert;if(revert&&Object.isFunction(revert))revert=revert(this.element);var d=this.currentDelta();if(revert&&this.options.reverteffect){if(dropped==0||revert!='failure') -this.options.reverteffect(this.element,d[1]-this.delta[1],d[0]-this.delta[0]);}else{this.delta=d;} -if(this.options.zindex) -this.element.style.zIndex=this.originalZ;if(this.options.endeffect) -this.options.endeffect(this.element);Draggables.deactivate(this);Droppables.reset();},keyPress:function(event){if(event.keyCode!=Event.KEY_ESC)return;this.finishDrag(event,false);Event.stop(event);},endDrag:function(event){if(!this.dragging)return;this.stopScrolling();this.finishDrag(event,true);Event.stop(event);},draw:function(point){var pos=Position.cumulativeOffset(this.element);if(this.options.ghosting){var r=Position.realOffset(this.element);pos[0]+=r[0]-Position.deltaX;pos[1]+=r[1]-Position.deltaY;} -var d=this.currentDelta();pos[0]-=d[0];pos[1]-=d[1];if(this.options.scroll&&(this.options.scroll!=window&&this._isScrollChild)){pos[0]-=this.options.scroll.scrollLeft-this.originalScrollLeft;pos[1]-=this.options.scroll.scrollTop-this.originalScrollTop;} -var p=[0,1].map(function(i){return(point[i]-pos[i]-this.offset[i])}.bind(this));if(this.options.snap){if(Object.isFunction(this.options.snap)){p=this.options.snap(p[0],p[1],this);}else{if(Object.isArray(this.options.snap)){p=p.map(function(v,i){return(v/this.options.snap[i]).round()*this.options.snap[i]}.bind(this))}else{p=p.map(function(v){return(v/this.options.snap).round()*this.options.snap}.bind(this))}}} -var style=this.element.style;if((!this.options.constraint)||(this.options.constraint=='horizontal')) -style.left=p[0]+"px";if((!this.options.constraint)||(this.options.constraint=='vertical')) -style.top=p[1]+"px";if(style.visibility=="hidden")style.visibility="";},stopScrolling:function(){if(this.scrollInterval){clearInterval(this.scrollInterval);this.scrollInterval=null;Draggables._lastScrollPointer=null;}},startScrolling:function(speed){if(!(speed[0]||speed[1]))return;this.scrollSpeed=[speed[0]*this.options.scrollSpeed,speed[1]*this.options.scrollSpeed];this.lastScrolled=new Date();this.scrollInterval=setInterval(this.scroll.bind(this),10);},scroll:function(){var current=new Date();var delta=current-this.lastScrolled;this.lastScrolled=current;if(this.options.scroll==window){with(this._getWindowScroll(this.options.scroll)){if(this.scrollSpeed[0]||this.scrollSpeed[1]){var d=delta/1000;this.options.scroll.scrollTo(left+d*this.scrollSpeed[0],top+d*this.scrollSpeed[1]);}}}else{this.options.scroll.scrollLeft+=this.scrollSpeed[0]*delta/1000;this.options.scroll.scrollTop+=this.scrollSpeed[1]*delta/1000;} -Position.prepare();Droppables.show(Draggables._lastPointer,this.element);Draggables.notify('onDrag',this);if(this._isScrollChild){Draggables._lastScrollPointer=Draggables._lastScrollPointer||$A(Draggables._lastPointer);Draggables._lastScrollPointer[0]+=this.scrollSpeed[0]*delta/1000;Draggables._lastScrollPointer[1]+=this.scrollSpeed[1]*delta/1000;if(Draggables._lastScrollPointer[0]<0) -Draggables._lastScrollPointer[0]=0;if(Draggables._lastScrollPointer[1]<0) -Draggables._lastScrollPointer[1]=0;this.draw(Draggables._lastScrollPointer);} -if(this.options.change)this.options.change(this);},_getWindowScroll:function(w){var T,L,W,H;with(w.document){if(w.document.documentElement&&documentElement.scrollTop){T=documentElement.scrollTop;L=documentElement.scrollLeft;}else if(w.document.body){T=body.scrollTop;L=body.scrollLeft;} -if(w.innerWidth){W=w.innerWidth;H=w.innerHeight;}else if(w.document.documentElement&&documentElement.clientWidth){W=documentElement.clientWidth;H=documentElement.clientHeight;}else{W=body.offsetWidth;H=body.offsetHeight}} -return{top:T,left:L,width:W,height:H};}});Draggable._dragging={};var SortableObserver=Class.create({initialize:function(element,observer){this.element=$(element);this.observer=observer;this.lastValue=Sortable.serialize(this.element);},onStart:function(){this.lastValue=Sortable.serialize(this.element);},onEnd:function(){Sortable.unmark();if(this.lastValue!=Sortable.serialize(this.element)) -this.observer(this.element)}});var Sortable={SERIALIZE_RULE:/^[^_\-](?:[A-Za-z0-9\-\_]*)[_](.*)$/,sortables:{},_findRootElement:function(element){while(element.tagName.toUpperCase()!="BODY"){if(element.id&&Sortable.sortables[element.id])return element;element=element.parentNode;}},options:function(element){element=Sortable._findRootElement($(element));if(!element)return;return Sortable.sortables[element.id];},destroy:function(element){var s=Sortable.options(element);if(s){Draggables.removeObserver(s.element);s.droppables.each(function(d){Droppables.remove(d)});s.draggables.invoke('destroy');delete Sortable.sortables[s.element.id];}},create:function(element){element=$(element);var options=Object.extend({element:element,tag:'li',dropOnEmpty:false,tree:false,treeTag:'ul',overlap:'vertical',constraint:'vertical',containment:element,handle:false,only:false,delay:0,hoverclass:null,ghosting:false,quiet:false,scroll:false,scrollSensitivity:20,scrollSpeed:15,format:this.SERIALIZE_RULE,elements:false,handles:false,onChange:Prototype.emptyFunction,onUpdate:Prototype.emptyFunction},arguments[1]||{});this.destroy(element);var options_for_draggable={revert:true,quiet:options.quiet,scroll:options.scroll,scrollSpeed:options.scrollSpeed,scrollSensitivity:options.scrollSensitivity,delay:options.delay,ghosting:options.ghosting,constraint:options.constraint,handle:options.handle};if(options.starteffect) -options_for_draggable.starteffect=options.starteffect;if(options.reverteffect) -options_for_draggable.reverteffect=options.reverteffect;else -if(options.ghosting)options_for_draggable.reverteffect=function(element){element.style.top=0;element.style.left=0;};if(options.endeffect) -options_for_draggable.endeffect=options.endeffect;if(options.zindex) -options_for_draggable.zindex=options.zindex;var options_for_droppable={overlap:options.overlap,containment:options.containment,tree:options.tree,hoverclass:options.hoverclass,onHover:Sortable.onHover} -var options_for_tree={onHover:Sortable.onEmptyHover,overlap:options.overlap,containment:options.containment,hoverclass:options.hoverclass} -Element.cleanWhitespace(element);options.draggables=[];options.droppables=[];if(options.dropOnEmpty||options.tree){Droppables.add(element,options_for_tree);options.droppables.push(element);} -(options.elements||this.findElements(element,options)||[]).each(function(e,i){var handle=options.handles?$(options.handles[i]):(options.handle?$(e).select('.'+options.handle)[0]:e);options.draggables.push(new Draggable(e,Object.extend(options_for_draggable,{handle:handle})));Droppables.add(e,options_for_droppable);if(options.tree)e.treeNode=element;options.droppables.push(e);});if(options.tree){(Sortable.findTreeElements(element,options)||[]).each(function(e){Droppables.add(e,options_for_tree);e.treeNode=element;options.droppables.push(e);});} -this.sortables[element.id]=options;Draggables.addObserver(new SortableObserver(element,options.onUpdate));},findElements:function(element,options){return Element.findChildren(element,options.only,options.tree?true:false,options.tag);},findTreeElements:function(element,options){return Element.findChildren(element,options.only,options.tree?true:false,options.treeTag);},onHover:function(element,dropon,overlap){if(Element.isParent(dropon,element))return;if(overlap>.33&&overlap<.66&&Sortable.options(dropon).tree){return;}else if(overlap>0.5){Sortable.mark(dropon,'before');if(dropon.previousSibling!=element){var oldParentNode=element.parentNode;element.style.visibility="hidden";dropon.parentNode.insertBefore(element,dropon);if(dropon.parentNode!=oldParentNode) -Sortable.options(oldParentNode).onChange(element);Sortable.options(dropon.parentNode).onChange(element);}}else{Sortable.mark(dropon,'after');var nextElement=dropon.nextSibling||null;if(nextElement!=element){var oldParentNode=element.parentNode;element.style.visibility="hidden";dropon.parentNode.insertBefore(element,nextElement);if(dropon.parentNode!=oldParentNode) -Sortable.options(oldParentNode).onChange(element);Sortable.options(dropon.parentNode).onChange(element);}}},onEmptyHover:function(element,dropon,overlap){var oldParentNode=element.parentNode;var droponOptions=Sortable.options(dropon);if(!Element.isParent(dropon,element)){var index;var children=Sortable.findElements(dropon,{tag:droponOptions.tag,only:droponOptions.only});var child=null;if(children){var offset=Element.offsetSize(dropon,droponOptions.overlap)*(1.0-overlap);for(index=0;index=0){offset-=Element.offsetSize(children[index],droponOptions.overlap);}else if(offset-(Element.offsetSize(children[index],droponOptions.overlap)/2)>=0){child=index+1');this.iefix=$(this.update.id+'_iefix');} -if(this.iefix)setTimeout(this.fixIEOverlapping.bind(this),50);},fixIEOverlapping:function(){Position.clone(this.update,this.iefix,{setTop:(!this.update.style.height)});this.iefix.style.zIndex=1;this.update.style.zIndex=2;Element.show(this.iefix);},hide:function(){this.stopIndicator();if(Element.getStyle(this.update,'display')!='none')this.options.onHide(this.element,this.update);if(this.iefix)Element.hide(this.iefix);},startIndicator:function(){if(this.options.indicator)Element.show(this.options.indicator);},stopIndicator:function(){if(this.options.indicator)Element.hide(this.options.indicator);},onKeyPress:function(event){if(this.active) -switch(event.keyCode){case Event.KEY_TAB:case Event.KEY_RETURN:this.selectEntry();Event.stop(event);case Event.KEY_ESC:this.hide();this.active=false;Event.stop(event);return;case Event.KEY_LEFT:case Event.KEY_RIGHT:return;case Event.KEY_UP:this.markPrevious();this.render();Event.stop(event);return;case Event.KEY_DOWN:this.markNext();this.render();Event.stop(event);return;} -else -if(event.keyCode==Event.KEY_TAB||event.keyCode==Event.KEY_RETURN||(Prototype.Browser.WebKit>0&&event.keyCode==0))return;this.changed=true;this.hasFocus=true;if(this.observer)clearTimeout(this.observer);this.observer=setTimeout(this.onObserverEvent.bind(this),this.options.frequency*1000);},activate:function(){this.changed=false;this.hasFocus=true;this.getUpdatedChoices();},onHover:function(event){var element=Event.findElement(event,'LI');if(this.index!=element.autocompleteIndex) -{this.index=element.autocompleteIndex;this.render();} -Event.stop(event);},onClick:function(event){var element=Event.findElement(event,'LI');this.index=element.autocompleteIndex;this.selectEntry();this.hide();},onBlur:function(event){setTimeout(this.hide.bind(this),250);this.hasFocus=false;this.active=false;},render:function(){if(this.entryCount>0){for(var i=0;i0)this.index-- -else this.index=this.entryCount-1;this.getEntry(this.index).scrollIntoView(true);},markNext:function(){if(this.index0)value=Element.collectTextNodes(nodes[0],this.options.select);}else -value=Element.collectTextNodesIgnoreClass(selectedElement,'informal');var bounds=this.getTokenBounds();if(bounds[0]!=-1){var newValue=this.element.value.substr(0,bounds[0]);var whitespace=this.element.value.substr(bounds[0]).match(/^\s+/);if(whitespace) -newValue+=whitespace[0];this.element.value=newValue+value+this.element.value.substr(bounds[1]);}else{this.element.value=value;} -this.oldElementValue=this.element.value;this.element.focus();if(this.options.afterUpdateElement) -this.options.afterUpdateElement(this.element,selectedElement);},updateChoices:function(choices){if(!this.changed&&this.hasFocus){this.update.innerHTML=choices;Element.cleanWhitespace(this.update);Element.cleanWhitespace(this.update.down());if(this.update.firstChild&&this.update.down().childNodes){this.entryCount=this.update.down().childNodes.length;for(var i=0;i=this.options.minChars){this.getUpdatedChoices();}else{this.active=false;this.hide();} -this.oldElementValue=this.element.value;},getToken:function(){var bounds=this.getTokenBounds();return this.element.value.substring(bounds[0],bounds[1]).strip();},getTokenBounds:function(){if(null!=this.tokenBounds)return this.tokenBounds;var value=this.element.value;if(value.strip().empty())return[-1,0];var diff=arguments.callee.getFirstDifferencePos(value,this.oldElementValue);var offset=(diff==this.oldElementValue.length?1:0);var prevTokenPos=-1,nextTokenPos=value.length;var tp;for(var index=0,l=this.options.tokens.length;indexprevTokenPos)prevTokenPos=tp;tp=value.indexOf(this.options.tokens[index],diff+offset);if(-1!=tp&&tp"+elem.substr(0,entry.length)+""+ -elem.substr(entry.length)+"");break;}else if(entry.length>=instance.options.partialChars&&instance.options.partialSearch&&foundPos!=-1){if(instance.options.fullSearch||/\s/.test(elem.substr(foundPos-1,1))){partial.push("
      5. "+elem.substr(0,foundPos)+""+ -elem.substr(foundPos,entry.length)+""+elem.substr(foundPos+entry.length)+"
      6. ");break;}} -foundPos=instance.options.ignoreCase?elem.toLowerCase().indexOf(entry.toLowerCase(),foundPos+1):elem.indexOf(entry,foundPos+1);}} -if(partial.length) -ret=ret.concat(partial.slice(0,instance.options.choices-ret.length)) -return"
          "+ret.join('')+"
        ";}},options||{});}});Field.scrollFreeActivate=function(field){setTimeout(function(){Field.activate(field);},1);} -Ajax.InPlaceEditor=Class.create({initialize:function(element,url,options){this.url=url;this.element=element=$(element);this.prepareOptions();this._controls={};arguments.callee.dealWithDeprecatedOptions(options);Object.extend(this.options,options||{});if(!this.options.formId&&this.element.id){this.options.formId=this.element.id+'-inplaceeditor';if($(this.options.formId)) -this.options.formId='';} -if(this.options.externalControl) -this.options.externalControl=$(this.options.externalControl);if(!this.options.externalControl) -this.options.externalControlOnly=false;this._originalBackground=this.element.getStyle('background-color')||'transparent';this.element.title=this.options.clickToEditText;this._boundCancelHandler=this.handleFormCancellation.bind(this);this._boundComplete=(this.options.onComplete||Prototype.emptyFunction).bind(this);this._boundFailureHandler=this.handleAJAXFailure.bind(this);this._boundSubmitHandler=this.handleFormSubmission.bind(this);this._boundWrapperHandler=this.wrapUp.bind(this);this.registerListeners();},checkForEscapeOrReturn:function(e){if(!this._editing||e.ctrlKey||e.altKey||e.shiftKey)return;if(Event.KEY_ESC==e.keyCode) -this.handleFormCancellation(e);else if(Event.KEY_RETURN==e.keyCode) -this.handleFormSubmission(e);},createControl:function(mode,handler,extraClasses){var control=this.options[mode+'Control'];var text=this.options[mode+'Text'];if('button'==control){var btn=document.createElement('input');btn.type='submit';btn.value=text;btn.className='editor_'+mode+'_button';if('cancel'==mode) -btn.onclick=this._boundCancelHandler;this._form.appendChild(btn);this._controls[mode]=btn;}else if('link'==control){var link=document.createElement('a');link.href='#';link.appendChild(document.createTextNode(text));link.onclick='cancel'==mode?this._boundCancelHandler:this._boundSubmitHandler;link.className='editor_'+mode+'_link';if(extraClasses) -link.className+=' '+extraClasses;this._form.appendChild(link);this._controls[mode]=link;}},createEditField:function(){var text=(this.options.loadTextURL?this.options.loadingText:this.getText());var fld;if(1>=this.options.rows&&!/\r|\n/.test(this.getText())){fld=document.createElement('input');fld.type='text';var size=this.options.size||this.options.cols||0;if(0=this.options.rows?this.options.autoRows:this.options.rows);fld.cols=this.options.cols||40;} -fld.name=this.options.paramName;fld.value=text;fld.className='editor_field';if(this.options.submitOnBlur) -fld.onblur=this._boundSubmitHandler;this._controls.editor=fld;if(this.options.loadTextURL) -this.loadExternalText();this._form.appendChild(this._controls.editor);},createForm:function(){var ipe=this;function addText(mode,condition){var text=ipe.options['text'+mode+'Controls'];if(!text||condition===false)return;ipe._form.appendChild(document.createTextNode(text));};this._form=$(document.createElement('form'));this._form.id=this.options.formId;this._form.addClassName(this.options.formClassName);this._form.onsubmit=this._boundSubmitHandler;this.createEditField();if('textarea'==this._controls.editor.tagName.toLowerCase()) -this._form.appendChild(document.createElement('br'));if(this.options.onFormCustomization) -this.options.onFormCustomization(this,this._form);addText('Before',this.options.okControl||this.options.cancelControl);this.createControl('ok',this._boundSubmitHandler);addText('Between',this.options.okControl&&this.options.cancelControl);this.createControl('cancel',this._boundCancelHandler,'editor_cancel');addText('After',this.options.okControl||this.options.cancelControl);},destroy:function(){if(this._oldInnerHTML) -this.element.innerHTML=this._oldInnerHTML;this.leaveEditMode();this.unregisterListeners();},enterEditMode:function(e){if(this._saving||this._editing)return;this._editing=true;this.triggerCallback('onEnterEditMode');if(this.options.externalControl) -this.options.externalControl.hide();this.element.hide();this.createForm();this.element.parentNode.insertBefore(this._form,this.element);if(!this.options.loadTextURL) -this.postProcessEditField();if(e)Event.stop(e);},enterHover:function(e){if(this.options.hoverClassName) -this.element.addClassName(this.options.hoverClassName);if(this._saving)return;this.triggerCallback('onEnterHover');},getText:function(){return this.element.innerHTML;},handleAJAXFailure:function(transport){this.triggerCallback('onFailure',transport);if(this._oldInnerHTML){this.element.innerHTML=this._oldInnerHTML;this._oldInnerHTML=null;}},handleFormCancellation:function(e){this.wrapUp();if(e)Event.stop(e);},handleFormSubmission:function(e){var form=this._form;var value=$F(this._controls.editor);this.prepareSubmission();var params=this.options.callback(form,value)||'';if(Object.isString(params)) -params=params.toQueryParams();params.editorId=this.element.id;if(this.options.htmlResponse){var options=Object.extend({evalScripts:true},this.options.ajaxOptions);Object.extend(options,{parameters:params,onComplete:this._boundWrapperHandler,onFailure:this._boundFailureHandler});new Ajax.Updater({success:this.element},this.url,options);}else{var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:params,onComplete:this._boundWrapperHandler,onFailure:this._boundFailureHandler});new Ajax.Request(this.url,options);} -if(e)Event.stop(e);},leaveEditMode:function(){this.element.removeClassName(this.options.savingClassName);this.removeForm();this.leaveHover();this.element.style.backgroundColor=this._originalBackground;this.element.show();if(this.options.externalControl) -this.options.externalControl.show();this._saving=false;this._editing=false;this._oldInnerHTML=null;this.triggerCallback('onLeaveEditMode');},leaveHover:function(e){if(this.options.hoverClassName) -this.element.removeClassName(this.options.hoverClassName);if(this._saving)return;this.triggerCallback('onLeaveHover');},loadExternalText:function(){this._form.addClassName(this.options.loadingClassName);this._controls.editor.disabled=true;var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:'editorId='+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){this._form.removeClassName(this.options.loadingClassName);var text=transport.responseText;if(this.options.stripLoadedTextTags) -text=text.stripTags();this._controls.editor.value=text;this._controls.editor.disabled=false;this.postProcessEditField();}.bind(this),onFailure:this._boundFailureHandler});new Ajax.Request(this.options.loadTextURL,options);},postProcessEditField:function(){var fpc=this.options.fieldPostCreation;if(fpc) -$(this._controls.editor)['focus'==fpc?'focus':'activate']();},prepareOptions:function(){this.options=Object.clone(Ajax.InPlaceEditor.DefaultOptions);Object.extend(this.options,Ajax.InPlaceEditor.DefaultCallbacks);[this._extraDefaultOptions].flatten().compact().each(function(defs){Object.extend(this.options,defs);}.bind(this));},prepareSubmission:function(){this._saving=true;this.removeForm();this.leaveHover();this.showSaving();},registerListeners:function(){this._listeners={};var listener;$H(Ajax.InPlaceEditor.Listeners).each(function(pair){listener=this[pair.value].bind(this);this._listeners[pair.key]=listener;if(!this.options.externalControlOnly) -this.element.observe(pair.key,listener);if(this.options.externalControl) -this.options.externalControl.observe(pair.key,listener);}.bind(this));},removeForm:function(){if(!this._form)return;this._form.remove();this._form=null;this._controls={};},showSaving:function(){this._oldInnerHTML=this.element.innerHTML;this.element.innerHTML=this.options.savingText;this.element.addClassName(this.options.savingClassName);this.element.style.backgroundColor=this._originalBackground;this.element.show();},triggerCallback:function(cbName,arg){if('function'==typeof this.options[cbName]){this.options[cbName](this,arg);}},unregisterListeners:function(){$H(this._listeners).each(function(pair){if(!this.options.externalControlOnly) -this.element.stopObserving(pair.key,pair.value);if(this.options.externalControl) -this.options.externalControl.stopObserving(pair.key,pair.value);}.bind(this));},wrapUp:function(transport){this.leaveEditMode();this._boundComplete(transport,this.element);}});Object.extend(Ajax.InPlaceEditor.prototype,{dispose:Ajax.InPlaceEditor.prototype.destroy});Ajax.InPlaceCollectionEditor=Class.create(Ajax.InPlaceEditor,{initialize:function($super,element,url,options){this._extraDefaultOptions=Ajax.InPlaceCollectionEditor.DefaultOptions;$super(element,url,options);},createEditField:function(){var list=document.createElement('select');list.name=this.options.paramName;list.size=1;this._controls.editor=list;this._collection=this.options.collection||[];if(this.options.loadCollectionURL) -this.loadCollection();else -this.checkForExternalText();this._form.appendChild(this._controls.editor);},loadCollection:function(){this._form.addClassName(this.options.loadingClassName);this.showLoadingText(this.options.loadingCollectionText);var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:'editorId='+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){var js=transport.responseText.strip();if(!/^\[.*\]$/.test(js)) -throw'Server returned an invalid collection representation.';this._collection=eval(js);this.checkForExternalText();}.bind(this),onFailure:this.onFailure});new Ajax.Request(this.options.loadCollectionURL,options);},showLoadingText:function(text){this._controls.editor.disabled=true;var tempOption=this._controls.editor.firstChild;if(!tempOption){tempOption=document.createElement('option');tempOption.value='';this._controls.editor.appendChild(tempOption);tempOption.selected=true;} -tempOption.update((text||'').stripScripts().stripTags());},checkForExternalText:function(){this._text=this.getText();if(this.options.loadTextURL) -this.loadExternalText();else -this.buildOptionList();},loadExternalText:function(){this.showLoadingText(this.options.loadingText);var options=Object.extend({method:'get'},this.options.ajaxOptions);Object.extend(options,{parameters:'editorId='+encodeURIComponent(this.element.id),onComplete:Prototype.emptyFunction,onSuccess:function(transport){this._text=transport.responseText.strip();this.buildOptionList();}.bind(this),onFailure:this.onFailure});new Ajax.Request(this.options.loadTextURL,options);},buildOptionList:function(){this._form.removeClassName(this.options.loadingClassName);this._collection=this._collection.map(function(entry){return 2===entry.length?entry:[entry,entry].flatten();});var marker=('value'in this.options)?this.options.value:this._text;var textFound=this._collection.any(function(entry){return entry[0]==marker;}.bind(this));this._controls.editor.update('');var option;this._collection.each(function(entry,index){option=document.createElement('option');option.value=entry[0];option.selected=textFound?entry[0]==marker:0==index;option.appendChild(document.createTextNode(entry[1]));this._controls.editor.appendChild(option);}.bind(this));this._controls.editor.disabled=false;Field.scrollFreeActivate(this._controls.editor);}});Ajax.InPlaceEditor.prototype.initialize.dealWithDeprecatedOptions=function(options){if(!options)return;function fallback(name,expr){if(name in options||expr===undefined)return;options[name]=expr;};fallback('cancelControl',(options.cancelLink?'link':(options.cancelButton?'button':options.cancelLink==options.cancelButton==false?false:undefined)));fallback('okControl',(options.okLink?'link':(options.okButton?'button':options.okLink==options.okButton==false?false:undefined)));fallback('highlightColor',options.highlightcolor);fallback('highlightEndColor',options.highlightendcolor);};Object.extend(Ajax.InPlaceEditor,{DefaultOptions:{ajaxOptions:{},autoRows:3,cancelControl:'link',cancelText:'cancel',clickToEditText:'Click to edit',externalControl:null,externalControlOnly:false,fieldPostCreation:'activate',formClassName:'inplaceeditor-form',formId:null,highlightColor:'#ffff99',highlightEndColor:'#ffffff',hoverClassName:'',htmlResponse:true,loadingClassName:'inplaceeditor-loading',loadingText:'Loading...',okControl:'button',okText:'ok',paramName:'value',rows:1,savingClassName:'inplaceeditor-saving',savingText:'Saving...',size:0,stripLoadedTextTags:false,submitOnBlur:false,textAfterControls:'',textBeforeControls:'',textBetweenControls:''},DefaultCallbacks:{callback:function(form){return Form.serialize(form);},onComplete:function(transport,element){new Effect.Highlight(element,{startcolor:this.options.highlightColor,keepBackgroundImage:true});},onEnterEditMode:null,onEnterHover:function(ipe){ipe.element.style.backgroundColor=ipe.options.highlightColor;if(ipe._effect) -ipe._effect.cancel();},onFailure:function(transport,ipe){alert('Error communication with the server: '+transport.responseText.stripTags());},onFormCustomization:null,onLeaveEditMode:null,onLeaveHover:function(ipe){ipe._effect=new Effect.Highlight(ipe.element,{startcolor:ipe.options.highlightColor,endcolor:ipe.options.highlightEndColor,restorecolor:ipe._originalBackground,keepBackgroundImage:true});}},Listeners:{click:'enterEditMode',keydown:'checkForEscapeOrReturn',mouseover:'enterHover',mouseout:'leaveHover'}});Ajax.InPlaceCollectionEditor.DefaultOptions={loadingCollectionText:'Loading options...'};Form.Element.DelayedObserver=Class.create({initialize:function(element,delay,callback){this.delay=delay||0.5;this.element=$(element);this.callback=callback;this.timer=null;this.lastValue=$F(this.element);Event.observe(this.element,'keyup',this.delayedListener.bindAsEventListener(this));},delayedListener:function(event){if(this.lastValue==$F(this.element))return;if(this.timer)clearTimeout(this.timer);this.timer=setTimeout(this.onTimerEvent.bind(this),this.delay*1000);this.lastValue=$F(this.element);},onTimerEvent:function(){this.timer=null;this.callback(this.element,$F(this.element));}});var Login={showOpenid:function(){if($('database_auth_form'))$('database_auth_form').hide();if($('openid_auth_form'))$('openid_auth_form').show();if($('alternate_auth_openid'))$('alternate_auth_openid').hide();if($('alternate_auth_database'))$('alternate_auth_database').show();if($('openid_url'))$('openid_url').focus();if($('openid_url'))$('openid_url').select();new CookieManager().setCookie('preferred_auth','openid');},showDatabase:function(container){if($('openid_auth_form'))$('openid_auth_form').hide();if($('database_auth_form'))$('database_auth_form').show();if($('alternate_auth_database'))$('alternate_auth_database').hide();if($('alternate_auth_openid'))$('alternate_auth_openid').show();if($('user_login'))$('user_login').focus();if($('user_login'))$('user_login').select();new CookieManager().setCookie('preferred_auth','database');}} -var TracksForm={toggle:function(toggleDivId,formContainerId,formId,hideLinkText,hideLinkTitle,showLinkText,showLinkTitle){$(formContainerId).toggle();toggleDiv=$(toggleDivId);toggleLink=toggleDiv.down('a');if(toggleDiv.hasClassName('hide_form')){toggleLink.update(showLinkText).setAttribute('title',showLinkTitle);} -else{toggleLink.update(hideLinkText).setAttribute('title',hideLinkTitle);Form.focusFirstElement(formId);} -toggleDiv.toggleClassName('hide_form');}} -Event.observe(window,'load',function(){$A(document.getElementsByClassName('alert')).each(function(o){o.opacity=100.0 -Effect.Fade(o,{duration:8.0})});});CookieManager=Class.create();CookieManager.prototype={BROWSER_IS_IE:(document.all&&window.ActiveXObject&&navigator.userAgent.toLowerCase().indexOf("msie")>-1&&navigator.userAgent.toLowerCase().indexOf("opera")==-1),BROWSER_IS_OPERA:(navigator.userAgent.toLowerCase().indexOf("opera")!=-1),initialize:function(options) -{this.options=Object.extend({shelfLife:365,userData:false},options||{});this.cookieShelfLife=this.options.shelfLife;this.userDataForIE=this.options.userData;if(this.BROWSER_IS_IE&&this.userDataForIE) -{this.IE_CACHE_NAME="storage";if($(this.IE_CACHE_NAME)==null) -{var div=document.createElement("DIV");div.id=this.IE_CACHE_NAME;document.body.appendChild(div);} -this.store=$(this.IE_CACHE_NAME);this.store.style.behavior="url('#default#userData')";}},getCookie:function(aCookieName) -{var result=null;if(this.BROWSER_IS_IE&&this.userDataForIE) -{this.store.load(this.IE_CACHE_NAME);result=this.store.getAttribute(aCookieName);} -else -{for(var i=0;i=0;i--){var s=["*","",[]];var t=stack[i];var cursor=t.length-1;do{var d=t.lastIndexOf("#");var p=t.lastIndexOf(".");cursor=Math.max(d,p);if(cursor==-1){s[0]=t.toUpperCase();}else if(d==-1||p==cursor){s[2].push(t.substring(p+1));}else if(!s[1]){s[1]=t.substring(d+1);} -t=t.substring(0,cursor);}while(cursor>0);this.s[i]=s;}},get:function(root){this.explore(root||document,this.i==(this.s.length-1));return this.r;},explore:function(elt,leaf){var s=this.s[this.i];var r=[];if(s[1]){e=$(s[1]);if(e&&(s[0]=="*"||e.tagName==s[0])&&e.childOf(elt)){r=[e];}}else{r=$A(elt.getElementsByTagName(s[0]));} -if(s[2].length==1){r=r.findAll(function(o){if(o.className.indexOf(" ")==-1){return o.className==s[2][0];}else{return o.className.split(/\s+/).include(s[2][0]);}});}else if(s[2].length>0){r=r.findAll(function(o){if(o.className.indexOf(" ")==-1){return false;}else{var q=o.className.split(/\s+/);return s[2].all(function(c){return q.include(c);});}});} -if(leaf){this.r=this.r.concat(r);}else{++this.i;r.each(function(o){this.explore(o,this.i==(this.s.length-1));}.bind(this));}}} -var $$old=$$;var $$=function(a,b){if(b||a.indexOf("[")>=0)return $$old.apply(this,arguments);return new SelectorLiteAddon(a.split(/\s+/)).get();} -Calendar=function(firstDayOfWeek,dateStr,onSelected,onClose){this.activeDiv=null;this.currentDateEl=null;this.getDateStatus=null;this.getDateToolTip=null;this.getDateText=null;this.timeout=null;this.onSelected=onSelected||null;this.onClose=onClose||null;this.dragging=false;this.hidden=false;this.minYear=1970;this.maxYear=2050;this.dateFormat=Calendar._TT["DEF_DATE_FORMAT"];this.ttDateFormat=Calendar._TT["TT_DATE_FORMAT"];this.isPopup=true;this.weekNumbers=true;this.firstDayOfWeek=typeof firstDayOfWeek=="number"?firstDayOfWeek:Calendar._FD;this.showsOtherMonths=false;this.dateStr=dateStr;this.ar_days=null;this.showsTime=false;this.time24=true;this.yearStep=2;this.hiliteToday=true;this.multiple=null;this.table=null;this.element=null;this.tbody=null;this.firstdayname=null;this.monthsCombo=null;this.yearsCombo=null;this.hilitedMonth=null;this.activeMonth=null;this.hilitedYear=null;this.activeYear=null;this.dateClicked=false;if(typeof Calendar._SDN=="undefined"){if(typeof Calendar._SDN_len=="undefined") -Calendar._SDN_len=3;var ar=new Array();for(var i=8;i>0;){ar[--i]=Calendar._DN[i].substr(0,Calendar._SDN_len);} -Calendar._SDN=ar;if(typeof Calendar._SMN_len=="undefined") -Calendar._SMN_len=3;ar=new Array();for(var i=12;i>0;){ar[--i]=Calendar._MN[i].substr(0,Calendar._SMN_len);} -Calendar._SMN=ar;}};Calendar._C=null;Calendar.is_ie=(/msie/i.test(navigator.userAgent)&&!/opera/i.test(navigator.userAgent));Calendar.is_ie5=(Calendar.is_ie&&/msie 5\.0/i.test(navigator.userAgent));Calendar.is_opera=/opera/i.test(navigator.userAgent);Calendar.is_khtml=/Konqueror|Safari|KHTML/i.test(navigator.userAgent);Calendar.getAbsolutePos=function(el){var SL=0,ST=0;var is_div=/^div$/i.test(el.tagName);if(is_div&&el.scrollLeft) -SL=el.scrollLeft;if(is_div&&el.scrollTop) -ST=el.scrollTop;var r={x:el.offsetLeft-SL,y:el.offsetTop-ST};if(el.offsetParent){var tmp=this.getAbsolutePos(el.offsetParent);r.x+=tmp.x;r.y+=tmp.y;} -return r;};Calendar.isRelated=function(el,evt){var related=evt.relatedTarget;if(!related){var type=evt.type;if(type=="mouseover"){related=evt.fromElement;}else if(type=="mouseout"){related=evt.toElement;}} -while(related){if(related==el){return true;} -related=related.parentNode;} -return false;};Calendar.removeClass=function(el,className){if(!(el&&el.className)){return;} -var cls=el.className.split(" ");var ar=new Array();for(var i=cls.length;i>0;){if(cls[--i]!=className){ar[ar.length]=cls[i];}} -el.className=ar.join(" ");};Calendar.addClass=function(el,className){Calendar.removeClass(el,className);el.className+=" "+className;};Calendar.getElement=function(ev){var f=Calendar.is_ie?window.event.srcElement:ev.currentTarget;while(f.nodeType!=1||/^div$/i.test(f.tagName)) -f=f.parentNode;return f;};Calendar.getTargetElement=function(ev){var f=Calendar.is_ie?window.event.srcElement:ev.target;while(f.nodeType!=1) -f=f.parentNode;return f;};Calendar.stopEvent=function(ev){ev||(ev=window.event);if(Calendar.is_ie){ev.cancelBubble=true;ev.returnValue=false;}else{ev.preventDefault();ev.stopPropagation();} -return false;};Calendar.addEvent=function(el,evname,func){if(el.attachEvent){el.attachEvent("on"+evname,func);}else if(el.addEventListener){el.addEventListener(evname,func,true);}else{el["on"+evname]=func;}};Calendar.removeEvent=function(el,evname,func){if(el.detachEvent){el.detachEvent("on"+evname,func);}else if(el.removeEventListener){el.removeEventListener(evname,func,true);}else{el["on"+evname]=null;}};Calendar.createElement=function(type,parent){var el=null;if(document.createElementNS){el=document.createElementNS("http://www.w3.org/1999/xhtml",type);}else{el=document.createElement(type);} -if(typeof parent!="undefined"){parent.appendChild(el);} -return el;};Calendar._add_evs=function(el){with(Calendar){addEvent(el,"mouseover",dayMouseOver);addEvent(el,"mousedown",dayMouseDown);addEvent(el,"mouseout",dayMouseOut);if(is_ie){addEvent(el,"dblclick",dayMouseDblClick);el.setAttribute("unselectable",true);}}};Calendar.findMonth=function(el){if(typeof el.month!="undefined"){return el;}else if(typeof el.parentNode.month!="undefined"){return el.parentNode;} -return null;};Calendar.findYear=function(el){if(typeof el.year!="undefined"){return el;}else if(typeof el.parentNode.year!="undefined"){return el.parentNode;} -return null;};Calendar.showMonthsCombo=function(){var cal=Calendar._C;if(!cal){return false;} -var cal=cal;var cd=cal.activeDiv;var mc=cal.monthsCombo;if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");} -if(cal.activeMonth){Calendar.removeClass(cal.activeMonth,"active");} -var mon=cal.monthsCombo.getElementsByTagName("div")[cal.date.getMonth()];Calendar.addClass(mon,"active");cal.activeMonth=mon;var s=mc.style;s.display="block";if(cd.navtype<0) -s.left=cd.offsetLeft+"px";else{var mcw=mc.offsetWidth;if(typeof mcw=="undefined") -mcw=50;s.left=(cd.offsetLeft+cd.offsetWidth-mcw)+"px";} -s.top=(cd.offsetTop+cd.offsetHeight)+"px";};Calendar.showYearsCombo=function(fwd){var cal=Calendar._C;if(!cal){return false;} -var cal=cal;var cd=cal.activeDiv;var yc=cal.yearsCombo;if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");} -if(cal.activeYear){Calendar.removeClass(cal.activeYear,"active");} -cal.activeYear=null;var Y=cal.date.getFullYear()+(fwd?1:-1);var yr=yc.firstChild;var show=false;for(var i=12;i>0;--i){if(Y>=cal.minYear&&Y<=cal.maxYear){yr.innerHTML=Y;yr.year=Y;yr.style.display="block";show=true;}else{yr.style.display="none";} -yr=yr.nextSibling;Y+=fwd?cal.yearStep:-cal.yearStep;} -if(show){var s=yc.style;s.display="block";if(cd.navtype<0) -s.left=cd.offsetLeft+"px";else{var ycw=yc.offsetWidth;if(typeof ycw=="undefined") -ycw=50;s.left=(cd.offsetLeft+cd.offsetWidth-ycw)+"px";} -s.top=(cd.offsetTop+cd.offsetHeight)+"px";}};Calendar.tableMouseUp=function(ev){var cal=Calendar._C;if(!cal){return false;} -if(cal.timeout){clearTimeout(cal.timeout);} -var el=cal.activeDiv;if(!el){return false;} -var target=Calendar.getTargetElement(ev);ev||(ev=window.event);Calendar.removeClass(el,"active");if(target==el||target.parentNode==el){Calendar.cellClick(el,ev);} -var mon=Calendar.findMonth(target);var date=null;if(mon){date=new Date(cal.date);if(mon.month!=date.getMonth()){date.setMonth(mon.month);cal.setDate(date);cal.dateClicked=false;cal.callHandler();}}else{var year=Calendar.findYear(target);if(year){date=new Date(cal.date);if(year.year!=date.getFullYear()){date.setFullYear(year.year);cal.setDate(date);cal.dateClicked=false;cal.callHandler();}}} -with(Calendar){removeEvent(document,"mouseup",tableMouseUp);removeEvent(document,"mouseover",tableMouseOver);removeEvent(document,"mousemove",tableMouseOver);cal._hideCombos();_C=null;return stopEvent(ev);}};Calendar.tableMouseOver=function(ev){var cal=Calendar._C;if(!cal){return;} -var el=cal.activeDiv;var target=Calendar.getTargetElement(ev);if(target==el||target.parentNode==el){Calendar.addClass(el,"hilite active");Calendar.addClass(el.parentNode,"rowhilite");}else{if(typeof el.navtype=="undefined"||(el.navtype!=50&&(el.navtype==0||Math.abs(el.navtype)>2))) -Calendar.removeClass(el,"active");Calendar.removeClass(el,"hilite");Calendar.removeClass(el.parentNode,"rowhilite");} -ev||(ev=window.event);if(el.navtype==50&&target!=el){var pos=Calendar.getAbsolutePos(el);var w=el.offsetWidth;var x=ev.clientX;var dx;var decrease=true;if(x>pos.x+w){dx=x-pos.x-w;decrease=false;}else -dx=pos.x-x;if(dx<0)dx=0;var range=el._range;var current=el._current;var count=Math.floor(dx/10)%range.length;for(var i=range.length;--i>=0;) -if(range[i]==current) -break;while(count-->0) -if(decrease){if(--i<0) -i=range.length-1;}else if(++i>=range.length) -i=0;var newval=range[i];el.innerHTML=newval;cal.onUpdateTime();} -var mon=Calendar.findMonth(target);if(mon){if(mon.month!=cal.date.getMonth()){if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");} -Calendar.addClass(mon,"hilite");cal.hilitedMonth=mon;}else if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");}}else{if(cal.hilitedMonth){Calendar.removeClass(cal.hilitedMonth,"hilite");} -var year=Calendar.findYear(target);if(year){if(year.year!=cal.date.getFullYear()){if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");} -Calendar.addClass(year,"hilite");cal.hilitedYear=year;}else if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");}}else if(cal.hilitedYear){Calendar.removeClass(cal.hilitedYear,"hilite");}} -return Calendar.stopEvent(ev);};Calendar.tableMouseDown=function(ev){if(Calendar.getTargetElement(ev)==Calendar.getElement(ev)){return Calendar.stopEvent(ev);}};Calendar.calDragIt=function(ev){var cal=Calendar._C;if(!(cal&&cal.dragging)){return false;} -var posX;var posY;if(Calendar.is_ie){posY=window.event.clientY+document.body.scrollTop;posX=window.event.clientX+document.body.scrollLeft;}else{posX=ev.pageX;posY=ev.pageY;} -cal.hideShowCovered();var st=cal.element.style;st.left=(posX-cal.xOffs)+"px";st.top=(posY-cal.yOffs)+"px";return Calendar.stopEvent(ev);};Calendar.calDragEnd=function(ev){var cal=Calendar._C;if(!cal){return false;} -cal.dragging=false;with(Calendar){removeEvent(document,"mousemove",calDragIt);removeEvent(document,"mouseup",calDragEnd);tableMouseUp(ev);} -cal.hideShowCovered();};Calendar.dayMouseDown=function(ev){var el=Calendar.getElement(ev);if(el.disabled){return false;} -var cal=el.calendar;cal.activeDiv=el;Calendar._C=cal;if(el.navtype!=300)with(Calendar){if(el.navtype==50){el._current=el.innerHTML;addEvent(document,"mousemove",tableMouseOver);}else -addEvent(document,Calendar.is_ie5?"mousemove":"mouseover",tableMouseOver);addClass(el,"hilite active");addEvent(document,"mouseup",tableMouseUp);}else if(cal.isPopup){cal._dragStart(ev);} -if(el.navtype==-1||el.navtype==1){if(cal.timeout)clearTimeout(cal.timeout);cal.timeout=setTimeout("Calendar.showMonthsCombo()",250);}else if(el.navtype==-2||el.navtype==2){if(cal.timeout)clearTimeout(cal.timeout);cal.timeout=setTimeout((el.navtype>0)?"Calendar.showYearsCombo(true)":"Calendar.showYearsCombo(false)",250);}else{cal.timeout=null;} -return Calendar.stopEvent(ev);};Calendar.dayMouseDblClick=function(ev){Calendar.cellClick(Calendar.getElement(ev),ev||window.event);if(Calendar.is_ie){document.selection.empty();}};Calendar.dayMouseOver=function(ev){var el=Calendar.getElement(ev);if(Calendar.isRelated(el,ev)||Calendar._C||el.disabled){return false;} -if(el.ttip){if(el.ttip.substr(0,1)=="_"){el.ttip=el.caldate.print(el.calendar.ttDateFormat)+el.ttip.substr(1);} -el.calendar.tooltips.innerHTML=el.ttip;} -if(el.navtype!=300){Calendar.addClass(el,"hilite");if(el.caldate){Calendar.addClass(el.parentNode,"rowhilite");}} -return Calendar.stopEvent(ev);};Calendar.dayMouseOut=function(ev){with(Calendar){var el=getElement(ev);if(isRelated(el,ev)||_C||el.disabled) -return false;removeClass(el,"hilite");if(el.caldate) -removeClass(el.parentNode,"rowhilite");if(el.calendar) -el.calendar.tooltips.innerHTML=_TT["SEL_DATE"];return stopEvent(ev);}};Calendar.cellClick=function(el,ev){var cal=el.calendar;var closing=false;var newdate=false;var date=null;if(typeof el.navtype=="undefined"){if(cal.currentDateEl){Calendar.removeClass(cal.currentDateEl,"selected");Calendar.addClass(el,"selected");closing=(cal.currentDateEl==el);if(!closing){cal.currentDateEl=el;}} -cal.date.setDateOnly(el.caldate);date=cal.date;var other_month=!(cal.dateClicked=!el.otherMonth);if(!other_month&&!cal.currentDateEl) -cal._toggleMultipleDate(new Date(date));else -newdate=!el.disabled;if(other_month) -cal._init(cal.firstDayOfWeek,date);}else{if(el.navtype==200){Calendar.removeClass(el,"hilite");cal.callCloseHandler();return;} -date=new Date(cal.date);if(el.navtype==0) -date.setDateOnly(new Date());cal.dateClicked=false;var year=date.getFullYear();var mon=date.getMonth();function setMonth(m){var day=date.getDate();var max=date.getMonthDays(m);if(day>max){date.setDate(max);} -date.setMonth(m);};switch(el.navtype){case 400:Calendar.removeClass(el,"hilite");var text=Calendar._TT["ABOUT"];if(typeof text!="undefined"){text+=cal.showsTime?Calendar._TT["ABOUT_TIME"]:"";}else{text="Help and about box text is not translated into this language.\n"+"If you know this language and you feel generous please update\n"+"the corresponding file in \"lang\" subdir to match calendar-en.js\n"+"and send it back to to get it into the distribution ;-)\n\n"+"Thank you!\n"+"http://dynarch.com/mishoo/calendar.epl\n";} -alert(text);return;case-2:if(year>cal.minYear){date.setFullYear(year-1);} -break;case-1:if(mon>0){setMonth(mon-1);}else if(year-->cal.minYear){date.setFullYear(year);setMonth(11);} -break;case 1:if(mon<11){setMonth(mon+1);}else if(year=0;) -if(range[i]==current) -break;if(ev&&ev.shiftKey){if(--i<0) -i=range.length-1;}else if(++i>=range.length) -i=0;var newval=range[i];el.innerHTML=newval;cal.onUpdateTime();return;case 0:if((typeof cal.getDateStatus=="function")&&cal.getDateStatus(date,date.getFullYear(),date.getMonth(),date.getDate())){return false;} -break;} -if(!date.equalsTo(cal.date)){cal.setDate(date);newdate=true;}else if(el.navtype==0) -newdate=closing=true;} -if(newdate){ev&&cal.callHandler();} -if(closing){Calendar.removeClass(el,"hilite");ev&&cal.callCloseHandler();}};Calendar.prototype.create=function(_par){var parent=null;if(!_par){parent=document.getElementsByTagName("body")[0];this.isPopup=true;}else{parent=_par;this.isPopup=false;} -this.date=this.dateStr?new Date(this.dateStr):new Date();var table=Calendar.createElement("table");this.table=table;table.cellSpacing=0;table.cellPadding=0;table.calendar=this;Calendar.addEvent(table,"mousedown",Calendar.tableMouseDown);var div=Calendar.createElement("div");this.element=div;div.className="calendar";if(this.isPopup){div.style.position="absolute";div.style.display="none";} -div.appendChild(table);var thead=Calendar.createElement("thead",table);var cell=null;var row=null;var cal=this;var hh=function(text,cs,navtype){cell=Calendar.createElement("td",row);cell.colSpan=cs;cell.className="button";if(navtype!=0&&Math.abs(navtype)<=2) -cell.className+=" nav";Calendar._add_evs(cell);cell.calendar=cal;cell.navtype=navtype;cell.innerHTML="
        "+text+"
        ";return cell;};row=Calendar.createElement("tr",thead);var title_length=6;(this.isPopup)&&--title_length;(this.weekNumbers)&&++title_length;hh("?",1,400).ttip=Calendar._TT["INFO"];this.title=hh("",title_length,300);this.title.className="title";if(this.isPopup){this.title.ttip=Calendar._TT["DRAG_TO_MOVE"];this.title.style.cursor="move";hh("×",1,200).ttip=Calendar._TT["CLOSE"];} -row=Calendar.createElement("tr",thead);row.className="headrow";this._nav_py=hh("«",1,-2);this._nav_py.ttip=Calendar._TT["PREV_YEAR"];this._nav_pm=hh("‹",1,-1);this._nav_pm.ttip=Calendar._TT["PREV_MONTH"];this._nav_now=hh(Calendar._TT["TODAY"],this.weekNumbers?4:3,0);this._nav_now.ttip=Calendar._TT["GO_TODAY"];this._nav_nm=hh("›",1,1);this._nav_nm.ttip=Calendar._TT["NEXT_MONTH"];this._nav_ny=hh("»",1,2);this._nav_ny.ttip=Calendar._TT["NEXT_YEAR"];row=Calendar.createElement("tr",thead);row.className="daynames";if(this.weekNumbers){cell=Calendar.createElement("td",row);cell.className="name wn";cell.innerHTML=Calendar._TT["WK"];} -for(var i=7;i>0;--i){cell=Calendar.createElement("td",row);if(!i){cell.navtype=100;cell.calendar=this;Calendar._add_evs(cell);}} -this.firstdayname=(this.weekNumbers)?row.firstChild.nextSibling:row.firstChild;this._displayWeekdays();var tbody=Calendar.createElement("tbody",table);this.tbody=tbody;for(i=6;i>0;--i){row=Calendar.createElement("tr",tbody);if(this.weekNumbers){cell=Calendar.createElement("td",row);} -for(var j=7;j>0;--j){cell=Calendar.createElement("td",row);cell.calendar=this;Calendar._add_evs(cell);}} -if(this.showsTime){row=Calendar.createElement("tr",tbody);row.className="time";cell=Calendar.createElement("td",row);cell.className="time";cell.colSpan=2;cell.innerHTML=Calendar._TT["TIME"]||" ";cell=Calendar.createElement("td",row);cell.className="time";cell.colSpan=this.weekNumbers?4:3;(function(){function makeTimePart(className,init,range_start,range_end){var part=Calendar.createElement("span",cell);part.className=className;part.innerHTML=init;part.calendar=cal;part.ttip=Calendar._TT["TIME_PART"];part.navtype=50;part._range=[];if(typeof range_start!="number") -part._range=range_start;else{for(var i=range_start;i<=range_end;++i){var txt;if(i<10&&range_end>=10)txt='0'+i;else txt=''+i;part._range[part._range.length]=txt;}} -Calendar._add_evs(part);return part;};var hrs=cal.date.getHours();var mins=cal.date.getMinutes();var t12=!cal.time24;var pm=(hrs>12);if(t12&&pm)hrs-=12;var H=makeTimePart("hour",hrs,t12?1:0,t12?12:23);var span=Calendar.createElement("span",cell);span.innerHTML=":";span.className="colon";var M=makeTimePart("minute",mins,0,59);var AP=null;cell=Calendar.createElement("td",row);cell.className="time";cell.colSpan=2;if(t12) -AP=makeTimePart("ampm",pm?"pm":"am",["am","pm"]);else -cell.innerHTML=" ";cal.onSetTime=function(){var pm,hrs=this.date.getHours(),mins=this.date.getMinutes();if(t12){pm=(hrs>=12);if(pm)hrs-=12;if(hrs==0)hrs=12;AP.innerHTML=pm?"pm":"am";} -H.innerHTML=(hrs<10)?("0"+hrs):hrs;M.innerHTML=(mins<10)?("0"+mins):mins;};cal.onUpdateTime=function(){var date=this.date;var h=parseInt(H.innerHTML,10);if(t12){if(/pm/i.test(AP.innerHTML)&&h<12) -h+=12;else if(/am/i.test(AP.innerHTML)&&h==12) -h=0;} -var d=date.getDate();var m=date.getMonth();var y=date.getFullYear();date.setHours(h);date.setMinutes(parseInt(M.innerHTML,10));date.setFullYear(y);date.setMonth(m);date.setDate(d);this.dateClicked=false;this.callHandler();};})();}else{this.onSetTime=this.onUpdateTime=function(){};} -var tfoot=Calendar.createElement("tfoot",table);row=Calendar.createElement("tr",tfoot);row.className="footrow";cell=hh(Calendar._TT["SEL_DATE"],this.weekNumbers?8:7,300);cell.className="ttip";if(this.isPopup){cell.ttip=Calendar._TT["DRAG_TO_MOVE"];cell.style.cursor="move";} -this.tooltips=cell;div=Calendar.createElement("div",this.element);this.monthsCombo=div;div.className="combo";for(i=0;i0;--i){var yr=Calendar.createElement("div");yr.className=Calendar.is_ie?"label-IEfix":"label";div.appendChild(yr);} -this._init(this.firstDayOfWeek,this.date);parent.appendChild(this.element);};Calendar._keyEvent=function(ev){var cal=window._dynarch_popupCalendar;if(!cal||cal.multiple) -return false;(Calendar.is_ie)&&(ev=window.event);var act=(Calendar.is_ie||ev.type=="keypress"),K=ev.keyCode;if(ev.ctrlKey){switch(K){case 37:act&&Calendar.cellClick(cal._nav_pm);break;case 38:act&&Calendar.cellClick(cal._nav_py);break;case 39:act&&Calendar.cellClick(cal._nav_nm);break;case 40:act&&Calendar.cellClick(cal._nav_ny);break;default:return false;}}else switch(K){case 32:Calendar.cellClick(cal._nav_now);break;case 27:act&&cal.callCloseHandler();break;case 37:case 38:case 39:case 40:if(act){var prev,x,y,ne,el,step;prev=K==37||K==38;step=(K==37||K==39)?1:7;function setVars(){el=cal.currentDateEl;var p=el.pos;x=p&15;y=p>>4;ne=cal.ar_days[y][x];};setVars();function prevMonth(){var date=new Date(cal.date);date.setDate(date.getDate()-step);cal.setDate(date);};function nextMonth(){var date=new Date(cal.date);date.setDate(date.getDate()+step);cal.setDate(date);};while(1){switch(K){case 37:if(--x>=0) -ne=cal.ar_days[y][x];else{x=6;K=38;continue;} -break;case 38:if(--y>=0) -ne=cal.ar_days[y][x];else{prevMonth();setVars();} -break;case 39:if(++x<7) -ne=cal.ar_days[y][x];else{x=0;K=40;continue;} -break;case 40:if(++ythis.maxYear){year=this.maxYear;date.setFullYear(year);} -this.firstDayOfWeek=firstDayOfWeek;this.date=new Date(date);var month=date.getMonth();var mday=date.getDate();var no_days=date.getMonthDays();date.setDate(1);var day1=(date.getDay()-this.firstDayOfWeek)%7;if(day1<0) -day1+=7;date.setDate(-day1);date.setDate(date.getDate()+1);var row=this.tbody.firstChild;var MN=Calendar._SMN[month];var ar_days=this.ar_days=new Array();var weekend=Calendar._TT["WEEKEND"];var dates=this.multiple?(this.datesCells={}):null;for(var i=0;i<6;++i,row=row.nextSibling){var cell=row.firstChild;if(this.weekNumbers){cell.className="day wn";cell.innerHTML=date.getWeekNumber();cell=cell.nextSibling;} -row.className="daysrow";var hasdays=false,iday,dpos=ar_days[i]=[];for(var j=0;j<7;++j,cell=cell.nextSibling,date.setDate(iday+1)){iday=date.getDate();var wday=date.getDay();cell.className="day";cell.pos=i<<4|j;dpos[j]=cell;var current_month=(date.getMonth()==month);if(!current_month){if(this.showsOtherMonths){cell.className+=" othermonth";cell.otherMonth=true;}else{cell.className="emptycell";cell.innerHTML=" ";cell.disabled=true;continue;}}else{cell.otherMonth=false;hasdays=true;} -cell.disabled=false;cell.innerHTML=this.getDateText?this.getDateText(date,iday):iday;if(dates) -dates[date.print("%Y%m%d")]=cell;if(this.getDateStatus){var status=this.getDateStatus(date,year,month,iday);if(this.getDateToolTip){var toolTip=this.getDateToolTip(date,year,month,iday);if(toolTip) -cell.title=toolTip;} -if(status===true){cell.className+=" disabled";cell.disabled=true;}else{if(/disabled/i.test(status)) -cell.disabled=true;cell.className+=" "+status;}} -if(!cell.disabled){cell.caldate=new Date(date);cell.ttip="_";if(!this.multiple&¤t_month&&iday==mday&&this.hiliteToday){cell.className+=" selected";this.currentDateEl=cell;} -if(date.getFullYear()==TY&&date.getMonth()==TM&&iday==TD){cell.className+=" today";cell.ttip+=Calendar._TT["PART_TODAY"];} -if(weekend.indexOf(wday.toString())!=-1) -cell.className+=cell.otherMonth?" oweekend":" weekend";}} -if(!(hasdays||this.showsOtherMonths)) -row.className="emptyrow";} -this.title.innerHTML=Calendar._MN[month]+", "+year;this.onSetTime();this.table.style.visibility="visible";this._initMultipleDates();};Calendar.prototype._initMultipleDates=function(){if(this.multiple){for(var i in this.multiple){var cell=this.datesCells[i];var d=this.multiple[i];if(!d) -continue;if(cell) -cell.className+=" selected";}}};Calendar.prototype._toggleMultipleDate=function(date){if(this.multiple){var ds=date.print("%Y%m%d");var cell=this.datesCells[ds];if(cell){var d=this.multiple[ds];if(!d){Calendar.addClass(cell,"selected");this.multiple[ds]=date;}else{Calendar.removeClass(cell,"selected");delete this.multiple[ds];}}}};Calendar.prototype.setDateToolTipHandler=function(unaryFunction){this.getDateToolTip=unaryFunction;};Calendar.prototype.setDate=function(date){if(!date.equalsTo(this.date)){this._init(this.firstDayOfWeek,date);}};Calendar.prototype.refresh=function(){this._init(this.firstDayOfWeek,this.date);};Calendar.prototype.setFirstDayOfWeek=function(firstDayOfWeek){this._init(firstDayOfWeek,this.date);this._displayWeekdays();};Calendar.prototype.setDateStatusHandler=Calendar.prototype.setDisabledHandler=function(unaryFunction){this.getDateStatus=unaryFunction;};Calendar.prototype.setRange=function(a,z){this.minYear=a;this.maxYear=z;};Calendar.prototype.callHandler=function(){if(this.onSelected){this.onSelected(this,this.date.print(this.dateFormat));}};Calendar.prototype.callCloseHandler=function(){if(this.onClose){this.onClose(this);} -this.hideShowCovered();};Calendar.prototype.destroy=function(){var el=this.element.parentNode;el.removeChild(this.element);Calendar._C=null;window._dynarch_popupCalendar=null;};Calendar.prototype.reparent=function(new_parent){var el=this.element;el.parentNode.removeChild(el);new_parent.appendChild(el);};Calendar._checkCalendar=function(ev){var calendar=window._dynarch_popupCalendar;if(!calendar){return false;} -var el=Calendar.is_ie?Calendar.getElement(ev):Calendar.getTargetElement(ev);for(;el!=null&&el!=calendar.element;el=el.parentNode);if(el==null){window._dynarch_popupCalendar.callCloseHandler();return Calendar.stopEvent(ev);}};Calendar.prototype.show=function(){var rows=this.table.getElementsByTagName("tr");for(var i=rows.length;i>0;){var row=rows[--i];Calendar.removeClass(row,"rowhilite");var cells=row.getElementsByTagName("td");for(var j=cells.length;j>0;){var cell=cells[--j];Calendar.removeClass(cell,"hilite");Calendar.removeClass(cell,"active");}} -this.element.style.display="block";this.hidden=false;if(this.isPopup){window._dynarch_popupCalendar=this;Calendar.addEvent(document,"keydown",Calendar._keyEvent);Calendar.addEvent(document,"keypress",Calendar._keyEvent);Calendar.addEvent(document,"mousedown",Calendar._checkCalendar);} -this.hideShowCovered();};Calendar.prototype.hide=function(){if(this.isPopup){Calendar.removeEvent(document,"keydown",Calendar._keyEvent);Calendar.removeEvent(document,"keypress",Calendar._keyEvent);Calendar.removeEvent(document,"mousedown",Calendar._checkCalendar);} -this.element.style.display="none";this.hidden=true;this.hideShowCovered();};Calendar.prototype.showAt=function(x,y){var s=this.element.style;s.left=x+"px";s.top=y+"px";this.show();};Calendar.prototype.showAtElement=function(el,opts){var self=this;var p=Calendar.getAbsolutePos(el);if(!opts||typeof opts!="string"){this.showAt(p.x,p.y+el.offsetHeight);return true;} -function fixPosition(box){if(box.x<0) -box.x=0;if(box.y<0) -box.y=0;var cp=document.createElement("div");var s=cp.style;s.position="absolute";s.right=s.bottom=s.width=s.height="0px";document.body.appendChild(cp);var br=Calendar.getAbsolutePos(cp);document.body.removeChild(cp);if(Calendar.is_ie){br.y+=document.body.scrollTop;br.x+=document.body.scrollLeft;}else{br.y+=window.scrollY;br.x+=window.scrollX;} -var tmp=box.x+box.width-br.x;if(tmp>0)box.x-=tmp;tmp=box.y+box.height-br.y;if(tmp>0)box.y-=tmp;};this.element.style.display="block";Calendar.continuation_for_the_fucking_khtml_browser=function(){var w=self.element.offsetWidth;var h=self.element.offsetHeight;self.element.style.display="none";var valign=opts.substr(0,1);var halign="l";if(opts.length>1){halign=opts.substr(1,1);} -switch(valign){case"T":p.y-=h;break;case"B":p.y+=el.offsetHeight;break;case"C":p.y+=(el.offsetHeight-h)/2;break;case"t":p.y+=el.offsetHeight-h;break;case"b":break;} -switch(halign){case"L":p.x-=w;break;case"R":p.x+=el.offsetWidth;break;case"C":p.x+=(el.offsetWidth-w)/2;break;case"l":p.x+=el.offsetWidth-w;break;case"r":break;} -p.width=w;p.height=h+40;self.monthsCombo.style.display="none";fixPosition(p);self.showAt(p.x,p.y);};if(Calendar.is_khtml) -setTimeout("Calendar.continuation_for_the_fucking_khtml_browser()",10);else -Calendar.continuation_for_the_fucking_khtml_browser();};Calendar.prototype.setDateFormat=function(str){this.dateFormat=str;};Calendar.prototype.setTtDateFormat=function(str){this.ttDateFormat=str;};Calendar.prototype.parseDate=function(str,fmt){if(!fmt) -fmt=this.dateFormat;this.setDate(Date.parseDate(str,fmt));};Calendar.prototype.hideShowCovered=function(){if(!Calendar.is_ie&&!Calendar.is_opera) -return;function getVisib(obj){var value=obj.style.visibility;if(!value){if(document.defaultView&&typeof(document.defaultView.getComputedStyle)=="function"){if(!Calendar.is_khtml) -value=document.defaultView.getComputedStyle(obj,"").getPropertyValue("visibility");else -value='';}else if(obj.currentStyle){value=obj.currentStyle.visibility;}else -value='';} -return value;};var tags=new Array("applet","iframe","select");var el=this.element;var p=Calendar.getAbsolutePos(el);var EX1=p.x;var EX2=el.offsetWidth+EX1;var EY1=p.y;var EY2=el.offsetHeight+EY1;for(var k=tags.length;k>0;){var ar=document.getElementsByTagName(tags[--k]);var cc=null;for(var i=ar.length;i>0;){cc=ar[--i];p=Calendar.getAbsolutePos(cc);var CX1=p.x;var CX2=cc.offsetWidth+CX1;var CY1=p.y;var CY2=cc.offsetHeight+CY1;if(this.hidden||(CX1>EX2)||(CX2EY2)||(CY229)?1900:2000);break;case"%b":case"%B":for(j=0;j<12;++j){if(Calendar._MN[j].substr(0,a[i].length).toLowerCase()==a[i].toLowerCase()){m=j;break;}} -break;case"%H":case"%I":case"%k":case"%l":hr=parseInt(a[i],10);break;case"%P":case"%p":if(/pm/i.test(a[i])&&hr<12) -hr+=12;else if(/am/i.test(a[i])&&hr>=12) -hr-=12;break;case"%M":min=parseInt(a[i],10);break;}} -if(isNaN(y))y=today.getFullYear();if(isNaN(m))m=today.getMonth();if(isNaN(d))d=today.getDate();if(isNaN(hr))hr=today.getHours();if(isNaN(min))min=today.getMinutes();if(y!=0&&m!=-1&&d!=0) -return new Date(y,m,d,hr,min,0);y=0;m=-1;d=0;for(i=0;i31&&y==0){y=parseInt(a[i],10);(y<100)&&(y+=(y>29)?1900:2000);}else if(d==0){d=a[i];}} -if(y==0) -y=today.getFullYear();if(m!=-1&&d!=0) -return new Date(y,m,d,hr,min,0);return today;};Date.prototype.getMonthDays=function(month){var year=this.getFullYear();if(typeof month=="undefined"){month=this.getMonth();} -if(((0==(year%4))&&((0!=(year%100))||(0==(year%400))))&&month==1){return 29;}else{return Date._MD[month];}};Date.prototype.getDayOfYear=function(){var now=new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0);var then=new Date(this.getFullYear(),0,0,0,0,0);var time=now-then;return Math.floor(time/Date.DAY);};Date.prototype.getWeekNumber=function(){var d=new Date(this.getFullYear(),this.getMonth(),this.getDate(),0,0,0);var DoW=d.getDay();d.setDate(d.getDate()-(DoW+6)%7+3);var ms=d.valueOf();d.setMonth(0);d.setDate(4);return Math.round((ms-d.valueOf())/(7*864e5))+1;};Date.prototype.equalsTo=function(date){return((this.getFullYear()==date.getFullYear())&&(this.getMonth()==date.getMonth())&&(this.getDate()==date.getDate())&&(this.getHours()==date.getHours())&&(this.getMinutes()==date.getMinutes()));};Date.prototype.setDateOnly=function(date){var tmp=new Date(date);this.setDate(1);this.setFullYear(tmp.getFullYear());this.setMonth(tmp.getMonth());this.setDate(tmp.getDate());};Date.prototype.print=function(str){var m=this.getMonth();var d=this.getDate();var y=this.getFullYear();var wn=this.getWeekNumber();var w=this.getDay();var s={};var hr=this.getHours();var pm=(hr>=12);var ir=(pm)?(hr-12):hr;var dy=this.getDayOfYear();if(ir==0) -ir=12;var min=this.getMinutes();var sec=this.getSeconds();s["%a"]=Calendar._SDN[w];s["%A"]=Calendar._DN[w];s["%b"]=Calendar._SMN[m];s["%B"]=Calendar._MN[m];s["%C"]=1+Math.floor(y/100);s["%d"]=(d<10)?("0"+d):d;s["%e"]=d;s["%H"]=(hr<10)?("0"+hr):hr;s["%I"]=(ir<10)?("0"+ir):ir;s["%j"]=(dy<100)?((dy<10)?("00"+dy):("0"+dy)):dy;s["%k"]=hr;s["%l"]=ir;s["%m"]=(m<9)?("0"+(1+m)):(1+m);s["%M"]=(min<10)?("0"+min):min;s["%n"]="\n";s["%p"]=pm?"PM":"AM";s["%P"]=pm?"pm":"am";s["%s"]=Math.floor(this.getTime()/1000);s["%S"]=(sec<10)?("0"+sec):sec;s["%t"]="\t";s["%U"]=s["%W"]=s["%V"]=(wn<10)?("0"+wn):wn;s["%u"]=w+1;s["%w"]=w;s["%y"]=(''+y).substr(2,2);s["%Y"]=y;s["%%"]="%";var re=/%./g;if(!Calendar.is_ie5&&!Calendar.is_khtml) -return str.replace(re,function(par){return s[par]||par;});var a=str.match(re);for(var i=0;i=0;){var d=params.multiple[i];var ds=d.print("%Y%m%d");cal.multiple[ds]=d;}} -cal.showsOtherMonths=params.showOthers;cal.yearStep=params.step;cal.setRange(params.range[0],params.range[1]);cal.params=params;cal.setDateStatusHandler(params.dateStatusFunc);cal.getDateText=params.dateText;cal.setDateFormat(dateFmt);if(mustCreate) -cal.create();cal.refresh();if(!params.position) -cal.showAtElement(params.button||params.displayArea||params.inputField,params.align);else -cal.showAt(params.position[0],params.position[1]);return false;};if(params.inputField){new DateDueKeyboardShortcutSupport(params.inputField,params.ifFormat,cal);} -return cal;};DateDueKeyboardShortcutSupport=Class.create();DateDueKeyboardShortcutSupport.prototype={initialize:function(element,dateFormat){this.element=$(element);this.dateFormat=dateFormat||"%Y/%m/%d";Event.observe(this.element,'keypress',this.onkeypress.bindAsEventListener(this));title=this.element.getAttributeNode("title");tooltip='Shortcuts: (t) today; (-) or (<) previous day; (+) or (>) next day; ([) previous week; (]) next week; ({) previous month; (}) next month; Click to show calendar';if(title&&title.value) -{this.element.setAttribute("title",title.value+' ('+tooltip+')');} -else -{this.element.setAttribute("title",tooltip);}},onkeypress:function(event){handled=true;switch(this.getCharFromKeyPressEvent(event)){case"t":this.setTextBoxToTodaysDate();break;case"+":case">":case"=":this.setTextBoxToNextDay();break;case"-":case"<":this.setTextBoxToPreviousDay();break;case"[":this.setTextBoxToPreviousWeek();break;case"]":this.setTextBoxToNextWeek();break;case"{":this.setTextBoxToPreviousMonth();break;case"}":this.setTextBoxToNextMonth();break;default:handled=false;break;} -if(handled){this.cancel(event);}},setTextBoxToChronicDate:function(){today=new Date();this.setDate(today);},setTextBoxToTodaysDate:function(){today=new Date();this.setDate(today);},setTextBoxToNextDay:function(){this.addDaysToTextBoxDate(1);},setTextBoxToPreviousDay:function(){this.addDaysToTextBoxDate(-1);},setTextBoxToNextWeek:function(){this.addDaysToTextBoxDate(7);},setTextBoxToPreviousWeek:function(){this.addDaysToTextBoxDate(-7);},addDaysToTextBoxDate:function(numDays){date=Date.parseDate(this.element.value,this.dateFormat);date.setDate(date.getDate()+numDays);this.setDate(date);},setTextBoxToNextMonth:function(){date=Date.parseDate(this.element.value,this.dateFormat);date.setMonth(date.getMonth()+1);this.setDate(date);},setTextBoxToPreviousMonth:function(){date=Date.parseDate(this.element.value,this.dateFormat);date.setMonth(date.getMonth()-1);this.setDate(date);},setDate:function(date){this.element.value=date.print(this.dateFormat);if(window.calendar){window.calendar.setDate(date);}},cancel:function(event){if(event.preventDefault){event.preventDefault();} -event.returnValue=false;},getCharFromKeyPressEvent:function(event){var charCode=(event.charCode)?event.charCode:((event.keyCode)?event.keyCode:((event.which)?event.which:0));return String.fromCharCode(charCode);}};var accessKeyHintsAdder={run:function(){var elemTypes=new Array('a','area','button','input','label','legend','textarea');for(var i=0;i=0?true:false);} -var oldonload=window.onload;if(typeof(NiftyLoad)!='function')NiftyLoad=function(){};if(typeof(oldonload)=='function') -window.onload=function(){oldonload();NiftyLoad()};else window.onload=function(){NiftyLoad()};function Nifty(selector,options){if(niftyOk==false)return;var i,v=selector.split(","),h=0;if(options==null)options="";if(options.find("fixed-height")) -h=getElementsBySelector(v[0])[0].offsetHeight;for(i=0;i0;i--) -d.appendChild(CreateStrip(i,side,color,border,btype));el.style.paddingBottom=0;el.appendChild(d);} -function CreateStrip(index,side,color,border,btype){var x=CreateEl("b");x.className=btype+index;x.style.backgroundColor=color;x.style.borderColor=border;if(side=="left"){x.style.borderRightWidth="0";x.style.marginRight="0";} -else if(side=="right"){x.style.borderLeftWidth="0";x.style.marginLeft="0";} -return(x);} -function CreateEl(x){return(document.createElement(x));} -function FixIE(el){if(el.currentStyle!=null&&el.currentStyle.hasLayout!=null&&el.currentStyle.hasLayout==false) -el.style.display="inline-block";} -function SameHeight(selector,maxh){var i,v=selector.split(","),t,j,els=[],gap;for(i=0;imaxh)maxh=els[i].offsetHeight;els[i].style.height="auto";} -for(i=0;i0){t=CreateEl("b");t.className="niftyfill";t.style.height=gap+"px";nc=els[i].lastChild;if(nc.className=="niftycorners") -els[i].insertBefore(t,nc);else els[i].appendChild(t);}}} -function getElementsBySelector(selector){var i,j,selid="",selclass="",tag=selector,tag2="",v2,k,f,a,s=[],objlist=[],c;if(selector.find("#")){if(selector.find(" ")){s=selector.split(" ");var fs=s[0].split("#");if(fs.length==1)return(objlist);f=document.getElementById(fs[1]);if(f){v=f.getElementsByTagName(s[1]);for(i=0;i=0;i--){var params={tag:'*',id:null,classes:[]};var selector=selectors[i];var needle=selector.length-1;do{var id=selector.lastIndexOf("#");var klass=selector.lastIndexOf(".");var cursor=Math.max(id,klass);if(cursor==-1)params.tag=selector.toUpperCase();else if(id==-1||klass==cursor)params.classes.push(selector.substring(klass+1)) -else if(!params.id)params.id=selector.substring(id+1);selector=selector.substring(0,cursor);}while(cursor>0);this.selectors[i]=params;}},get:function(root){this.findElements(root||document,this.index==(this.selectors.length-1));return this.results;},findElements:function(parent,descendant){var selector=this.selectors[this.index],results=[],element;if(selector.id){element=$(selector.id);if(element&&(selector.tag=='*'||element.tagName==selector.tag)&&(element.childOf(parent))){results=[element];}}else{results=$A(parent.getElementsByTagName(selector.tag));} -if(selector.classes.length==1){results=results.select(function(target){return $(target).hasClassName(selector.classes[0]);});}else if(selector.classes.length>1){results=results.select(function(target){var klasses=$(target).classNames();return selector.classes.all(function(klass){return klasses.include(klass);});});} -if(descendant){this.results=this.results.concat(results);}else{++this.index;results.each(function(target){this.findElements(target,this.index==(this.selectors.length-1));}.bind(this));}}} -LowPro.$$old=$$;LowPro.optimize$$=true;function $$(a,b){if(LowPro.optimize$$==false||b||a.indexOf("[")>=0) -return LowPro.$$old.apply(this,arguments);return new LowPro.SelectorLite(a.split(/\s+/)).get();} -if(typeof deconcept=="undefined"){var deconcept=new Object();}if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a){if(!document.getElementById){return;}this.DETECT_KEY=_a?_a:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1);}if(id){this.setAttribute("id",id);}if(w){this.setAttribute("width",w);}if(h){this.setAttribute("height",h);}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(c){this.addParam("bgcolor",c);}var q=_7?_7:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var _c=(_8)?_8:window.location;this.setAttribute("xiRedirectUrl",_c);this.setAttribute("redirectUrl","");if(_9){this.setAttribute("redirectUrl",_9);}};deconcept.SWFObject.prototype={useExpressInstall:function(_d){this.xiSWFPath=!_d?"expressinstall.swf":_d;this.setAttribute("useExpressInstall",true);},setAttribute:function(_e,_f){this.attributes[_e]=_f;},getAttribute:function(_10){return this.attributes[_10];},addParam:function(_11,_12){this.params[_11]=_12;},getParams:function(){return this.params;},addVariable:function(_13,_14){this.variables[_13]=_14;},getVariable:function(_15){return this.variables[_15];},getVariables:function(){return this.variables;},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){_16[_16.length]=key+"="+_18[key];}return _16;},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}_19="0){_19+="flashvars=\""+_1c+"\"";}_19+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}_19="";_19+="";var _1d=this.getParams();for(var key in _1d){_19+="";}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+="";}_19+="";}return _19;},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var _23=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_23=new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var axo=1;var _26=3;while(axo){try{_26++;axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_26);_23=new deconcept.PlayerVersion([_26,0,0]);}catch(e){axo=null;}}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(e){try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");_23=new deconcept.PlayerVersion([6,0,21]);axo.AllowScriptAccess="always";}catch(e){if(_23.major==6){return _23;}}try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(e){}}if(axo!=null){_23=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}}}return _23;};deconcept.PlayerVersion=function(_29){this.major=_29[0]!=null?parseInt(_29[0]):0;this.minor=_29[1]!=null?parseInt(_29[1]):0;this.rev=_29[2]!=null?parseInt(_29[2]):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.majorfv.major){return true;}if(this.minorfv.minor){return true;}if(this.rev=0;i--){_2f[i].style.display="none";for(var x in _2f[i]){if(typeof _2f[i][x]=="function"){_2f[i][x]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(id){return document.all[id];};}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject; \ No newline at end of file From cfb69cd4cd0df2269415e37cd01d337f25851991 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Fri, 6 Jun 2008 19:37:07 +0000 Subject: [PATCH 14/22] regenerate compressed js and cleanup whitespace git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@873 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/public/javascripts/todo-items.js | 264 +++++++++--------- .../{tracks_869.js => tracks_872.js} | 2 +- 2 files changed, 133 insertions(+), 133 deletions(-) rename tracks/public/javascripts/{tracks_869.js => tracks_872.js} (99%) diff --git a/tracks/public/javascripts/todo-items.js b/tracks/public/javascripts/todo-items.js index 1cd7ff00..4b188ca7 100644 --- a/tracks/public/javascripts/todo-items.js +++ b/tracks/public/javascripts/todo-items.js @@ -10,161 +10,161 @@ ToDoItems = Class.create(); ToDoItems.prototype = { - initialize: function() - { - /* keep track of last effect so you can check if the animation has finised */ - this.lastEffect= null; - this.initialized = true; - this.contextCollapseCookieManager = new CookieManager(); - this.toggleItemsMap = {}; - this.toggleContainerMap = {}; - this.containerItemsMap = {}; - }, - addNextActionListingToggles: function() - { - this.containerToggles = $$('.container_toggle'); - containerTogglesClick = this.toggleNextActionListing.bindAsEventListener(this); - for(i=0; i < this.containerToggles.length; i++) + initialize: function() { - toggleElem = this.containerToggles[i]; - containerElem = toggleElem.parentNode.parentNode - itemsElem = $(containerElem.id).select("div#"+containerElem.id+"items")[0]; - this.toggleContainerMap[toggleElem.id] = containerElem; - this.toggleItemsMap[toggleElem.id] = itemsElem; - this.containerItemsMap[containerElem.id] = itemsElem; - } - this.setNextActionListingTogglesToCookiedState(); - }, - setNextActionListingTogglesToCookiedState: function() - { - for(i=0; i < this.containerToggles.length; i++) + /* keep track of last effect so you can check if the animation has finised */ + this.lastEffect= null; + this.initialized = true; + this.contextCollapseCookieManager = new CookieManager(); + this.toggleItemsMap = {}; + this.toggleContainerMap = {}; + this.containerItemsMap = {}; + }, + addNextActionListingToggles: function() { - toggleElem = this.containerToggles[i]; - containerElem = this.toggleContainerMap[toggleElem.id]; - collapsedCookie = this.contextCollapseCookieManager.getCookie(this.buildCookieName(containerElem)); - itemsElem = this.toggleItemsMap[toggleElem.id]; - isExpanded = Element.visible(itemsElem); - if (collapsedCookie && isExpanded) - { - this.collapseNextActionListing(toggleElem, itemsElem); - } - else if (!collapsedCookie && !isExpanded) - { - this.expandNextActionListing(toggleElem, itemsElem); - } - } - }, - collapseAllNextActionListing: function(except) - { - for(i=0; i < this.containerToggles.length; i++) - { - toggleElem = this.containerToggles[i]; - if (toggleElem != except) - { - itemsElem = this.toggleItemsMap[toggleElem.id]; - isExpanded = Element.visible(itemsElem); - if (isExpanded) + this.containerToggles = $$('.container_toggle'); + containerTogglesClick = this.toggleNextActionListing.bindAsEventListener(this); + for(i=0; i < this.containerToggles.length; i++) { - this.collapseNextActionListing(toggleElem, itemsElem); + toggleElem = this.containerToggles[i]; + containerElem = toggleElem.parentNode.parentNode + itemsElem = $(containerElem.id).select("div#"+containerElem.id+"items")[0]; + this.toggleContainerMap[toggleElem.id] = containerElem; + this.toggleItemsMap[toggleElem.id] = itemsElem; + this.containerItemsMap[containerElem.id] = itemsElem; } - } - } - }, - ensureVisibleWithEffectAppear: function(elemId) - { + this.setNextActionListingTogglesToCookiedState(); + }, + setNextActionListingTogglesToCookiedState: function() + { + for(i=0; i < this.containerToggles.length; i++) + { + toggleElem = this.containerToggles[i]; + containerElem = this.toggleContainerMap[toggleElem.id]; + collapsedCookie = this.contextCollapseCookieManager.getCookie(this.buildCookieName(containerElem)); + itemsElem = this.toggleItemsMap[toggleElem.id]; + isExpanded = Element.visible(itemsElem); + if (collapsedCookie && isExpanded) + { + this.collapseNextActionListing(toggleElem, itemsElem); + } + else if (!collapsedCookie && !isExpanded) + { + this.expandNextActionListing(toggleElem, itemsElem); + } + } + }, + collapseAllNextActionListing: function(except) + { + for(i=0; i < this.containerToggles.length; i++) + { + toggleElem = this.containerToggles[i]; + if (toggleElem != except) + { + itemsElem = this.toggleItemsMap[toggleElem.id]; + isExpanded = Element.visible(itemsElem); + if (isExpanded) + { + this.collapseNextActionListing(toggleElem, itemsElem); + } + } + } + }, + ensureVisibleWithEffectAppear: function(elemId) + { if ($(elemId).style.display == 'none') { - new Effect.Appear(elemId,{duration:0.4}); + new Effect.Appear(elemId,{duration:0.4}); } - }, - fadeAndRemoveItem: function(itemContainerElemId) - { + }, + fadeAndRemoveItem: function(itemContainerElemId) + { var fadingElemId = itemContainerElemId + '-fading'; $(itemContainerElemId).setAttribute('id',fadingElemId); Element.removeClassName($(fadingElemId),'item-container'); new Effect.Fade(fadingElemId,{afterFinish:function(effect) { Element.remove(fadingElemId); }, duration:0.4}); - }, - toggleNextActionListing: function(event) - { - Event.stop(event); - toggleElem = Event.element(event).parentNode; - itemsElem = this.toggleItemsMap[toggleElem.id]; + }, + toggleNextActionListing: function(event) + { + Event.stop(event); + toggleElem = Event.element(event).parentNode; + itemsElem = this.toggleItemsMap[toggleElem.id]; containerElem = this.toggleContainerMap[toggleElem.id]; - if (Element.visible(itemsElem)) + if (Element.visible(itemsElem)) + { + this.collapseNextActionListing(toggleElem, itemsElem); + this.contextCollapseCookieManager.setCookie(this.buildCookieName(containerElem), true) + } + else + { + this.expandNextActionListing(toggleElem, itemsElem); + this.contextCollapseCookieManager.clearCookie(this.buildCookieName(containerElem)) + } + }, + findToggleElemForContext : function(contextElem) { - this.collapseNextActionListing(toggleElem, itemsElem); - this.contextCollapseCookieManager.setCookie(this.buildCookieName(containerElem), true) - } - else + childElems = $A($(contextElem).getElementsByTagName('a')); + return childElems.detect(function(childElem) { return childElem.className == 'container_toggle' }); + }, + expandNextActionListing: function(toggleElem, itemsElem, skipAnimation) { - this.expandNextActionListing(toggleElem, itemsElem); - this.contextCollapseCookieManager.clearCookie(this.buildCookieName(containerElem)) - } - }, - findToggleElemForContext : function(contextElem) - { - childElems = $A($(contextElem).getElementsByTagName('a')); - return childElems.detect(function(childElem) { return childElem.className == 'container_toggle' }); - }, - expandNextActionListing: function(toggleElem, itemsElem, skipAnimation) - { - itemsElem = $(itemsElem) - if (skipAnimation == true) { - itemsElem.style.display = 'block'; - } - else - { - this.lastEffect = Effect.BlindDown(itemsElem, { duration: 0.4 }); - } - toggleElem.setAttribute('title', 'Collapse'); - imgElem = this.findToggleImgElem(toggleElem); + itemsElem = $(itemsElem) + if (skipAnimation == true) { + itemsElem.style.display = 'block'; + } + else + { + this.lastEffect = Effect.BlindDown(itemsElem, { duration: 0.4 }); + } + toggleElem.setAttribute('title', 'Collapse'); + imgElem = this.findToggleImgElem(toggleElem); imgElem.src = imgElem.src.replace('expand','collapse'); - imgElem.setAttribute('title','Collapse'); - }, - ensureContainerHeight: function(itemsElem) - { - itemsElem = $(itemsElem); - Element.setStyle(itemsElem, {height : ''}); - Element.setStyle(itemsElem, {overflow : ''}); - }, - expandNextActionListingByContext: function(itemsElem, skipAnimation) - { - contextElem = this.findNearestParentByClassName($(itemsElem), "context"); - toggleElem = this.findToggleElemForContext(contextElem); - this.expandNextActionListing(toggleElem, itemsElem, skipAnimation); - }, - collapseNextActionListing: function(toggleElem, itemsElem) - { - this.lastEffect = Effect.BlindUp(itemsElem, { duration: 0.4}); - toggleElem.setAttribute('title', 'Expand'); - imgElem = this.findToggleImgElem(toggleElem); -imgElem.src = imgElem.src.replace('collapse','expand'); + imgElem.setAttribute('title','Collapse'); + }, + ensureContainerHeight: function(itemsElem) + { + itemsElem = $(itemsElem); + Element.setStyle(itemsElem, {height : ''}); + Element.setStyle(itemsElem, {overflow : ''}); + }, + expandNextActionListingByContext: function(itemsElem, skipAnimation) + { + contextElem = this.findNearestParentByClassName($(itemsElem), "context"); + toggleElem = this.findToggleElemForContext(contextElem); + this.expandNextActionListing(toggleElem, itemsElem, skipAnimation); + }, + collapseNextActionListing: function(toggleElem, itemsElem) + { + this.lastEffect = Effect.BlindUp(itemsElem, { duration: 0.4}); + toggleElem.setAttribute('title', 'Expand'); + imgElem = this.findToggleImgElem(toggleElem); + imgElem.src = imgElem.src.replace('collapse','expand'); imgElem.setAttribute('title','Expand'); - }, - findToggleImgElem: function(toggleElem) - { - childImgElems = $A(toggleElem.getElementsByTagName('img')); - return childImgElems[0]; - }, - buildCookieName: function(containerElem) - { + }, + findToggleImgElem: function(toggleElem) + { + childImgElems = $A(toggleElem.getElementsByTagName('img')); + return childImgElems[0]; + }, + buildCookieName: function(containerElem) + { tracks_login = this.contextCollapseCookieManager.getCookie('tracks_login'); - return 'tracks_'+tracks_login+'_context_' + containerElem.id + '_collapsed'; - }, + return 'tracks_'+tracks_login+'_context_' + containerElem.id + '_collapsed'; + }, - findNearestParentByClassName: function(elem, parentClassName) - { + findNearestParentByClassName: function(elem, parentClassName) + { var parentElem = elem.parentNode; while(parentElem) { - if (Element.hasClassName(parentElem, parentClassName)) - { - return parentElem; - } - parentElem = parentElem.parentNode; + if (Element.hasClassName(parentElem, parentClassName)) + { + return parentElem; + } + parentElem = parentElem.parentNode; } return null; - } + } } todoItems = new ToDoItems(); diff --git a/tracks/public/javascripts/tracks_869.js b/tracks/public/javascripts/tracks_872.js similarity index 99% rename from tracks/public/javascripts/tracks_869.js rename to tracks/public/javascripts/tracks_872.js index 920938bb..c42d387e 100644 --- a/tracks/public/javascripts/tracks_869.js +++ b/tracks/public/javascripts/tracks_872.js @@ -726,7 +726,7 @@ Event.observe(window,"load",accessKeyHintsAdder.run.bindAsEventListener(accessKe {this.lastEffect=null;this.initialized=true;this.contextCollapseCookieManager=new CookieManager();this.toggleItemsMap={};this.toggleContainerMap={};this.containerItemsMap={};},addNextActionListingToggles:function() {this.containerToggles=$$('.container_toggle');containerTogglesClick=this.toggleNextActionListing.bindAsEventListener(this);for(i=0;i Date: Fri, 6 Jun 2008 20:06:23 +0000 Subject: [PATCH 15/22] hopefully fixes #727.Changes the check on running animation to finished animation git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@874 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/contexts/_context.rhtml | 2 +- tracks/public/javascripts/{tracks_872.js => tracks_873.js} | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename tracks/public/javascripts/{tracks_872.js => tracks_873.js} (100%) diff --git a/tracks/app/views/contexts/_context.rhtml b/tracks/app/views/contexts/_context.rhtml index 6191495c..7fb2e942 100644 --- a/tracks/app/views/contexts/_context.rhtml +++ b/tracks/app/views/contexts/_context.rhtml @@ -5,7 +5,7 @@ <%= image_tag("collapse.png") %> <% apply_behavior '.container_toggle:click', :prevent_default => true do |page| page << " /* only handle the click if a previous click had finished its animation */ - if (todoItems.lastEffect == null || todoItems.lastEffect.state!='running') { + if (todoItems.lastEffect == null || todoItems.lastEffect.state=='finished') { containerElem = this.up('.container') toggleTarget = containerElem.down('.toggle_target') if (Element.visible(toggleTarget)) diff --git a/tracks/public/javascripts/tracks_872.js b/tracks/public/javascripts/tracks_873.js similarity index 100% rename from tracks/public/javascripts/tracks_872.js rename to tracks/public/javascripts/tracks_873.js From 53e57f1632e9ecd007f835032aaa9c668451cff4 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Wed, 11 Jun 2008 08:56:12 +0000 Subject: [PATCH 16/22] explain that yaml cannot yet be used for backup as importing is not implemented yet. from mailinglist. git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@875 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/data/index.html.erb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tracks/app/views/data/index.html.erb b/tracks/app/views/data/index.html.erb index a1edbda7..5fb93294 100644 --- a/tracks/app/views/data/index.html.erb +++ b/tracks/app/views/data/index.html.erb @@ -3,10 +3,10 @@

        Exporting data

        You can choose between the following formats:

          -
        • YAML: Best for porting data between Tracks installations
        • +
        • YAML: Best for exporting data.
          Please note that Tracks currently does not support importing YAML files. Do not use this (yet) to backup your Tracks database.
        • CSV: Best for importing into spreadsheet or data analysis software
        • XML: Best for importing or repurposing the data
        • -

        From 7134482ec454f1ff40429f462d3c01fd968a26a1 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Thu, 12 Jun 2008 07:31:25 +0000 Subject: [PATCH 17/22] Applied patch from Eric Pallen whcih automatically converts url's to links. Thanks Eric! git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@876 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/notes/_notes.rhtml | 50 +++++++++++----------- tracks/app/views/todos/_toggle_notes.rhtml | 11 +++-- 2 files changed, 30 insertions(+), 31 deletions(-) diff --git a/tracks/app/views/notes/_notes.rhtml b/tracks/app/views/notes/_notes.rhtml index c99812fc..9d71eec5 100644 --- a/tracks/app/views/notes/_notes.rhtml +++ b/tracks/app/views/notes/_notes.rhtml @@ -1,39 +1,39 @@ <% note = notes -%>

        -

        <%= link_to("Note #{note.id}", note_path(note), :title => "Show note #{note.id}" ) %>

        +

        <%= link_to("Note #{note.id}", note_path(note), :title => "Show note #{note.id}" ) %>

        - <%= sanitize(textilize(note.body)) %> - - + +
        - - -
        <% note = nil -%> diff --git a/tracks/app/views/todos/_toggle_notes.rhtml b/tracks/app/views/todos/_toggle_notes.rhtml index 524871a7..1993e7ae 100644 --- a/tracks/app/views/todos/_toggle_notes.rhtml +++ b/tracks/app/views/todos/_toggle_notes.rhtml @@ -1,8 +1,7 @@ <%= link_to(image_tag( 'blank.png', :width=>'16', :height=>'16', :border=>'0' ), "#", {:class => 'show_notes', :title => 'Show notes'}) %> <% apply_behavior 'a.show_notes:click', :prevent_default => true do |page, element| - element.next('.todo_notes').toggle - end --%> - \ No newline at end of file + element.next('.todo_notes').toggle +end -%> + \ No newline at end of file From e75309edea65e5a364ad18fc3433fd4cdab2c893 Mon Sep 17 00:00:00 2001 From: lrbalt Date: Fri, 13 Jun 2008 06:25:42 +0000 Subject: [PATCH 18/22] fixes #724 where editing todos truncates the project name of the todo when the project name contains quotes (") git-svn-id: http://www.rousette.org.uk/svn/tracks-repos/trunk@877 a4c988fc-2ded-0310-b66e-134b36920a42 --- tracks/app/views/todos/_edit_form.rhtml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tracks/app/views/todos/_edit_form.rhtml b/tracks/app/views/todos/_edit_form.rhtml index f0006730..8dc5beb9 100644 --- a/tracks/app/views/todos/_edit_form.rhtml +++ b/tracks/app/views/todos/_edit_form.rhtml @@ -11,7 +11,7 @@
        - +" />