Author: assaf
Date: Thu May 15 12:42:55 2008
New Revision: 656809

URL: http://svn.apache.org/viewvc?rev=656809&view=rev
Log:
Added links for feed and iCal.

Added:
    ode/sandbox/singleshot/public/images/calendar.png
    ode/sandbox/singleshot/public/images/feed.png
Modified:
    ode/sandbox/singleshot/app/views/layouts/application.html.erb
    ode/sandbox/singleshot/app/views/tasks/index.html.erb
    ode/sandbox/singleshot/config/routes.rb
    ode/sandbox/singleshot/public/stylesheets/default.css

Modified: ode/sandbox/singleshot/app/views/layouts/application.html.erb
URL: 
http://svn.apache.org/viewvc/ode/sandbox/singleshot/app/views/layouts/application.html.erb?rev=656809&r1=656808&r2=656809&view=diff
==============================================================================
--- ode/sandbox/singleshot/app/views/layouts/application.html.erb (original)
+++ ode/sandbox/singleshot/app/views/layouts/application.html.erb Thu May 15 
12:42:55 2008
@@ -23,6 +23,12 @@
         <li><%= link_to 'Activity', activity_url %></a></li>
         <li><a href='#'>Start &hellip;</a></li>
       </ul>
+      <% if @alternate %>
+        <ul class='alternate'>
+          <li id='atom'><%= link_to image_tag('feed.png') + ' Feed', 
@alternate[Mime::ATOM], :title=>'Subscribe with your feed reader' %></li>
+          <li id='ical'><%= link_to image_tag('calendar.png') + ' Calendar', 
@alternate[Mime::ICS], :title=>'Add this link to your calendar' %></li>
+        </ul>
+      <% end %>
     </div>
     <div id='main'>
 <%= yield %>

Modified: ode/sandbox/singleshot/app/views/tasks/index.html.erb
URL: 
http://svn.apache.org/viewvc/ode/sandbox/singleshot/app/views/tasks/index.html.erb?rev=656809&r1=656808&r2=656809&view=diff
==============================================================================
--- ode/sandbox/singleshot/app/views/tasks/index.html.erb (original)
+++ ode/sandbox/singleshot/app/views/tasks/index.html.erb Thu May 15 12:42:55 
2008
@@ -1,3 +1,4 @@
+<% @alternate = { Mime::ATOM=>feed_tasks_url, Mime::ICS=>ical_tasks_url } %>
 <ol class='tasks'>
   <% @tasks.each do |task| %>
     <% content_tag_for 'li', task do %>

Modified: ode/sandbox/singleshot/config/routes.rb
URL: 
http://svn.apache.org/viewvc/ode/sandbox/singleshot/config/routes.rb?rev=656809&r1=656808&r2=656809&view=diff
==============================================================================
--- ode/sandbox/singleshot/config/routes.rb (original)
+++ ode/sandbox/singleshot/config/routes.rb Thu May 15 12:42:55 2008
@@ -1,7 +1,7 @@
 ActionController::Routing::Routes.draw do |map|
 
   map.resource 'session'
-  map.resources 'tasks', :collection=>{ 'following'=>:get, 'completed'=>:get }
+  map.resources 'tasks', :collection=>{ 'following'=>:get, 'completed'=>:get, 
'feed'=>:get, 'ical'=>:get }
   map.resource 'activity'
   map.root :controller=>'tasks'
   map.resource 'sandwich'

Added: ode/sandbox/singleshot/public/images/calendar.png
URL: 
http://svn.apache.org/viewvc/ode/sandbox/singleshot/public/images/calendar.png?rev=656809&view=auto
==============================================================================
Files ode/sandbox/singleshot/public/images/calendar.png (added) and 
ode/sandbox/singleshot/public/images/calendar.png Thu May 15 12:42:55 2008 
differ

Added: ode/sandbox/singleshot/public/images/feed.png
URL: 
http://svn.apache.org/viewvc/ode/sandbox/singleshot/public/images/feed.png?rev=656809&view=auto
==============================================================================
Files ode/sandbox/singleshot/public/images/feed.png (added) and 
ode/sandbox/singleshot/public/images/feed.png Thu May 15 12:42:55 2008 differ

Modified: ode/sandbox/singleshot/public/stylesheets/default.css
URL: 
http://svn.apache.org/viewvc/ode/sandbox/singleshot/public/stylesheets/default.css?rev=656809&r1=656808&r2=656809&view=diff
==============================================================================
--- ode/sandbox/singleshot/public/stylesheets/default.css (original)
+++ ode/sandbox/singleshot/public/stylesheets/default.css Thu May 15 12:42:55 
2008
@@ -205,6 +205,26 @@
   -webkit-border-top-left-radius: 0.3em;
 }
 
+ul.alternate {
+  list-style: none;
+  float: right;
+  position: relative;
+  margin-top: -1.3em;
+  font-size: 1.2em;
+}
+ul.alternate li {
+  display: inline;
+}
+ul.alternate a {
+  padding-left: 1em;
+  text-decoration: none;
+}
+ul.alternate img {
+  border: none;
+  vertical-align: bottom;
+  margin: 0.1em;
+}
+
 ol.tasks {
   list-style: none;
   margin: 2em 3.5em 0 3.5em;


Reply via email to