diff --git a/tracks/app/helpers/application_helper.rb b/tracks/app/helpers/application_helper.rb index 4a266a3b..b35ac97d 100644 --- a/tracks/app/helpers/application_helper.rb +++ b/tracks/app/helpers/application_helper.rb @@ -115,8 +115,8 @@ module ApplicationHelper link_to( descriptor, project_path(project), :title => "View project: #{project.name}" ) end - def link_to_project_mobile(project, descriptor = sanitize(project.name)) - link_to( descriptor, formatted_project_path(project, :m), :title => "View project: #{project.name}" ) + def link_to_project_mobile(project, accesskey, descriptor = sanitize(project.name)) + link_to( descriptor, formatted_project_path(project, :m), {:title => "View project: #{project.name}", :accesskey => accesskey} ) end def item_link_to_context(item) diff --git a/tracks/app/helpers/projects_helper.rb b/tracks/app/helpers/projects_helper.rb index 9193e019..ce2c0364 100644 --- a/tracks/app/helpers/projects_helper.rb +++ b/tracks/app/helpers/projects_helper.rb @@ -35,12 +35,12 @@ module ProjectsHelper html = '' unless @previous_project.nil? project_name = truncate(@previous_project.name, 40, "...") - html << link_to_project_mobile(@previous_project, "« #{project_name}") + html << link_to_project_mobile(@previous_project, "5", "« 5-#{project_name}") end html << ' | ' if @previous_project && @next_project unless @next_project.nil? project_name = truncate(@next_project.name, 40, "...") - html << link_to_project_mobile(@next_project, "#{project_name} »") + html << link_to_project_mobile(@next_project, "6", "6-#{project_name} »") end html end diff --git a/tracks/app/views/layouts/mobile.rhtml b/tracks/app/views/layouts/mobile.rhtml index 12cb7333..cb0bcff3 100644 --- a/tracks/app/views/layouts/mobile.rhtml +++ b/tracks/app/views/layouts/mobile.rhtml @@ -11,11 +11,11 @@ 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"})) -%> + <%= (link_to("0-Add new action", formatted_new_todo_path(:m))+" | ") unless @new_mobile -%> + <%= (link_to("1-Home", formatted_todos_path(:m))+" | ") unless @home -%> + <%= (link_to("2-Contexts", formatted_contexts_path(:m))+" | ") %> + <%= (link_to("3-Projects", formatted_projects_path(:m))+" | ") %> + <%= (link_to("4-Starred", {:action => "tag", :controller => "todos", :id => "starred.m"})) -%> <% end end %> <%= render_flash -%> @@ -24,11 +24,11 @@
<% 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("0-Add new action", formatted_new_todo_path(:m), {:accesskey => "0"})+" | ") unless @new_mobile -%> + <%= (link_to("1-Home", formatted_todos_path(:m), {:accesskey => "1"})+" | ") unless @home -%> + <%= (link_to("2-Contexts", formatted_contexts_path(:m), {:accesskey => "2"})+" | ") %> + <%= (link_to("3-Projects", formatted_projects_path(:m), {:accesskey => "3"})+" | ") %> + <%= (link_to("4-Starred", {:action => "tag", :controller => "todos", :id => "starred.m"}, {:accesskey => "4"})+" | ") -%> <%= (link_to("Tickler", {:action => "index", :controller => "tickler.m"})+"| ") -%> <%= (link_to("Feeds", {:action => "index", :controller => "feeds.m"})) %> <% end %> diff --git a/tracks/app/views/projects/project_mobile.rhtml b/tracks/app/views/projects/project_mobile.rhtml index 77338280..15296102 100644 --- a/tracks/app/views/projects/project_mobile.rhtml +++ b/tracks/app/views/projects/project_mobile.rhtml @@ -1,6 +1,5 @@ <% project = @project %> <%= project_next_prev_mobile %> -

<%=project.name%>

<% unless @project.description.blank? -%>
<%= sanitize(@project.description) %>