diaspora/public/javascripts/mobile.js
2011-02-01 22:27:07 -08:00

28 lines
664 B
JavaScript

/* Copyright (c) 2010, Diaspora Inc. This file is
* licensed under the Affero General Public License version 3 or later. See
* the COPYRIGHT file.
*/
var Mobile = {
initialize: function() {
$("abbr.timeago").timeago();
$('#main_stream + .pagination').hide();
$('#aspect_picker').change(Mobile.changeAspect);
$('a').live('tap',function(){
$(this).addClass('tapped');
})
},
changeAspect: function() {
Mobile.windowLocation('/aspects/' + $('#aspect_picker option:selected').val());
},
windowLocation: function(url) {
window.location = url;
}
};
$(document).ready(function() {
Mobile.initialize();
});