clean up whitespace from project

This commit is contained in:
Nihad Abbasov 2011-11-15 12:34:30 +04:00
parent 415eddaf39
commit 368deb5992
50 changed files with 356 additions and 413 deletions

View file

@ -22,9 +22,9 @@ $(function(){
$('select#branch').selectmenu({style:'popup', width:200});
$('select#tag').selectmenu({style:'popup', width:200});
$(".account-box").mouseenter(showMenu);
$(".account-box").mouseleave(resetMenu);
$(".account-box").mouseenter(showMenu);
$(".account-box").mouseleave(resetMenu);
});
function updatePage(data){
@ -32,9 +32,9 @@ function updatePage(data){
}
function showMenu() {
$(this).toggleClass('hover');
$(this).toggleClass('hover');
}
function resetMenu() {
$(this).removeClass("hover");
$(this).removeClass("hover");
}

View file

@ -8,25 +8,23 @@ $(document).ready(function(){
});
});
var CommitsList = {
var CommitsList = {
ref:null,
limit:0,
offset:0,
init:
function(ref, limit) {
this.ref=ref;
this.limit=limit;
this.offset=limit;
init:
function(ref, limit) {
this.ref=ref;
this.limit=limit;
this.offset=limit;
this.initLoadMore();
$('.loading').show();
},
getOld:
function() {
function() {
$('.loading').show();
$.ajax({
type: "GET",
@ -39,14 +37,14 @@ getOld:
append:
function(count, html) {
$("#commits_list").append(html);
if(count > 0) {
if(count > 0) {
this.offset += count;
this.initLoadMore();
}
}
},
initLoadMore:
function() {
function() {
$(window).bind('scroll', function(){
if($(window).scrollTop() == $(document).height() - $(window).height()){
$(window).unbind('scroll');

View file

@ -1,20 +1,20 @@
var NoteList = {
var NoteList = {
first_id: 0,
last_id: 0,
resource_name: null,
init:
function(resource_name, first_id, last_id) {
this.resource_name = resource_name;
this.first_id = first_id;
this.last_id = last_id;
init:
function(resource_name, first_id, last_id) {
this.resource_name = resource_name;
this.first_id = first_id;
this.last_id = last_id;
this.initRefresh();
this.initLoadMore();
},
getOld:
function() {
function() {
$('.loading').show();
$.ajax({
type: "GET",
@ -31,7 +31,7 @@ append:
this.initLoadMore();
},
replace:
replace:
function(fid, lid, html) {
this.first_id = fid;
this.last_id = lid;
@ -39,17 +39,16 @@ replace:
this.initLoadMore();
},
prepend:
function(id, html) {
if(id != this.last_id) {
if(id != this.last_id) {
this.last_id = id;
$("#notes-list").prepend(html);
}
},
getNew:
function() {
function() {
// refersh notes list
$.ajax({
type: "GET",
@ -59,7 +58,7 @@ getNew:
},
refresh:
function() {
function() {
// refersh notes list
$.ajax({
type: "GET",
@ -68,8 +67,6 @@ refresh:
dataType: "script"});
},
initRefresh:
function() {
// init timer
@ -78,7 +75,7 @@ initRefresh:
},
initLoadMore:
function() {
function() {
$(window).bind('scroll', function(){
if($(window).scrollTop() == $(document).height() - $(window).height()){
$(window).unbind('scroll');

View file

@ -48,7 +48,6 @@ function taggifyForm(){
source: '/tags.json'
});
$('form').submit( function() {
var tag_field = $('#tag_field')
tag_field.val( tag_field.tagify('serialize') );