Changeset - 1294f2baf2bc
[Not reviewed]
beta
0 3 0
Marcin Kuzminski - 15 years ago 2011-01-01 22:43:37
marcin@python-works.com
added wrapping of long tooltips in index page
3 files changed with 6 insertions and 6 deletions:
0 comments (0 inline, 0 general)
rhodecode/lib/helpers.py
Show inline comments
 
@@ -89,15 +89,15 @@ def recursive_replace(str, replace=' '):
 
        str = str.replace(replace * 2, replace)
 
        return recursive_replace(str, replace)
 

	
 
class _ToolTip(object):
 

	
 
    def __call__(self, tooltip_title, trim_at=50):
 
        """
 
        Special function just to wrap our text into nice formatted autowrapped
 
        text
 
        """Special function just to wrap our text into nice formatted 
 
        autowrapped text
 
        
 
        :param tooltip_title:
 
        """
 

	
 
        return wrap_paragraphs(escape(tooltip_title), trim_at)\
 
                       .replace('\n', '<br/>')
 

	
rhodecode/templates/base/base.html
Show inline comments
 
@@ -350,23 +350,23 @@ function onSuccess(){
 
        f.setAttribute('title',"${_('Start following this repository')}");
 
    }
 
}
 

	
 
function toggleFollowingUser(fallows_user_id,token){
 
    args = 'follows_user_id='+fallows_user_id;
 
    args+= '&auth_token='+token;
 
    args+= '&amp;auth_token='+token;
 
    YUC.asyncRequest('POST',base_url,{
 
        success:function(o){
 
        	onSuccess();
 
        }
 
    },args); return false;
 
}
 

	
 
function toggleFollowingRepo(fallows_repo_id,token){
 
    args = 'follows_repo_id='+fallows_repo_id;
 
    args+= '&auth_token='+token;
 
    args+= '&amp;auth_token='+token;
 
    YUC.asyncRequest('POST',base_url,{
 
        success:function(o){
 
        	onSuccess();
 
        }
 
    },args); return false;
 
}    
rhodecode/templates/index.html
Show inline comments
 
@@ -84,13 +84,13 @@
 
		            	title="${_('Fork of')} ${repo['repo'].dbrepo.fork.repo_name}" 
 
		            	src="/images/icons/arrow_divide.png"/></a>
 
		            %endif
 
		            </div>
 
		            </td>
 
		            ##DESCRIPTION
 
		            <td><span class="tooltip" title="${repo['description']}">
 
		            <td><span class="tooltip" title="${h.tooltip(repo['description'])}">
 
		               ${h.truncate(repo['description'],60)}</span>
 
		            </td>
 
		            ##LAST CHANGE
 
		            <td>
 
		              <span class="tooltip" title="${repo['last_change']}">
 
		              ${h.age(repo['last_change'])}</span>
0 comments (0 inline, 0 general)