Changeset - c4caeca9dd66
[Not reviewed]
default
0 2 0
Marcin Kuzminski - 15 years ago 2010-06-14 00:17:08
marcin@python-works.com
fixed paragraphs wrapping for ultralong commit messages. Disabled tooltips for new repos without a last commit message. ie. when tooltip_title is empty (there is a strange bug on empty tooltip_title)
2 files changed with 11 insertions and 5 deletions:
0 comments (0 inline, 0 general)
pylons_app/lib/helpers.py
Show inline comments
 
@@ -103,29 +103,36 @@ class _ToolTip(object):
 
                }
 
                return ids        
 
            };
 
            var myToolTips = new YAHOO.widget.Tooltip("tooltip", { 
 
                context: toolTipsId(),
 
                monitorresize:false,
 
                xyoffset :[0,0],
 
                autodismissdelay:300000,
 
                hidedelay:5,
 
                showdelay:20,
 
            });
 
            
 
            //Mouse subscribe optional arguments
 
            //Mouse Over event disabled for new repositories since they dont
 
            //have last commit message
 
            myToolTips.contextMouseOverEvent.subscribe(
 
                function(type, args) {
 
                    var context = args[0];
 
                    return true;
 
                    var txt = context.getAttribute('tooltip_title');
 
                    if(txt){
 
                        return true;
 
                    }
 
                    else{
 
                        return false;
 
                    }
 
                });
 
            
 
            // Set the text for the tooltip just before we display it. Lazy method
 
            myToolTips.contextTriggerEvent.subscribe( 
 
                 function(type, args) { 
 
                        var context = args[0]; 
 
                        var txt = context.getAttribute('tooltip_title');
 
                        this.cfg.setProperty("text", txt);                     
 
                  });
 
        });
 
        '''         
 
        return literal(js)
pylons_app/templates/changelog/changelog.html
Show inline comments
 
@@ -31,27 +31,26 @@
 
		<div class="container_header">
 
			${h.form(h.url.current(),method='get')}
 
				${_('Show')}: ${h.text('size',size=2,value=c.size)} ${_('revisions')}
 
				${h.submit('','set')}
 
			${h.end_form()}
 
		</div>
 
	%for cnt,cs in enumerate(c.pagination):
 
		<div class="container">
 
			<div class="left">
 
				<div class="date">${_('commit')} ${cs.revision}: ${cs.raw_id}@${cs.date}</div>
 
				<div class="author">${cs.author}</div>
 
				<div id="chg_${cnt}" class="message">
 
					${h.link_to(cs.message,
 
					h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id),
 
					title=cs.message)}
 
					${h.link_to(h.wrap_paragraphs(cs.message),
 
					h.url('changeset_home',repo_name=c.repo_name,revision=cs.raw_id))}
 
				</div>
 
					<span class="logtags">
 
						<span class="branchtag">${cs.branch}</span>
 
						%for tag in cs.tags:
 
							<span class="tagtag">${tag}</span>
 
						%endfor
 
					</span>
 
			</div>	
 
			<div class="right">
 
						<div class="changes">
 
							<span class="removed" title="${_('removed')}">${len(cs.removed)}</span>
 
							<span class="changed" title="${_('changed')}">${len(cs.changed)}</span>
0 comments (0 inline, 0 general)