Added "History" link.
modelFirstFlashMessageChanged: function(property, value) {
this.element.fadeOut('slow', function() {
+ this.element.css({'z-index': 0});
this.shownMessage = value;
this.render();
- this.element.fadeIn('slow');
+
+ if(this.shownMessage) {
+ this.element.css({'z-index': 1000});
+ this.element.fadeIn('slow');
+ }
}.bind(this));
}
});
getHotkey: function(event) {
var code = event.keyCode;
+ if(!((code >= 97 && code <= 122)
+ || (code >= 65 && code <= 90)) ) return null;
+
var ch = String.fromCharCode(code & 0xff).toLowerCase();
- var button = $('.buttontoolbarview-button[title='+ch+']', this.element)[0]
+ console.log(ch.charCodeAt(0), '#', buttons);
- console.log(ch, '#', button);
+ var buttons = $('.buttontoolbarview-button[title='+ch+']', this.element);
var mod = 0;
if(event.altKey) mod |= 0x01;
if(event.ctrlKey) mod |= 0x02;
if(event.shiftKey) mod |= 0x04;
- if(button) {
+ if(buttons.length) {
var match = null;
- $(button).each(function() {
+ buttons.each(function() {
if( parseInt($(this).attr('ui:hotkey_mod')) == mod ) {
match = this;
return;
{% block breadcrumbs %}<a href="{% url file_list %}">Platforma Redakcyjna</a> > {{ fileid }}{% endblock breadcrumbs %}
{% block header-toolbar %}
- <button id="action-merge">Merge</button> <button id="action-update">Update</button> <button id="action-commit">Commit</button> <button id="action-quick-save">Quick Save</button>
+ <a href="http://stigma.nowoczesnapolska.org.pl/platforma-hg/ksiazki/log/tip/{{ fileid }}.xml" target="_new" >Historia</a>
+ <button id="action-merge">Merge</button>
+ <button id="action-update">Update</button>
+ <button id="action-commit">Commit</button>
+ <button id="action-quick-save">Quick Save</button>
{% endblock %}
{% block maincontent %}
{% endblock maincontent %}
{% block extrabody %}
- <div style="position: absolute; left: 35%; right: 35%; top: 0; height: 20px; z-index: 1000" id="flashview"></div>
+ <div style="position: absolute; left: 35%; right: 35%; top: 0; height: 20px; z-index: 0" id="flashview"></div>
{% endblock %}
\ No newline at end of file