Project

General

Profile

Bug #19985 » 10377.diff

Administrator Admin, 2009-02-07 14:23

View differences:

typo3/js/backend.js (working copy)
*/
function jump(url, modName, mainModName) {
// clear information about which entry in nav. tree that might have been highlighted.
top.fsMod.navFrameHighlightedID = new Array();
top.fsMod.navFrameHighlightedID = [];
if (top.content && top.content.nav_frame && top.content.nav_frame.refresh_nav) {
top.content.nav_frame.refresh_nav();
......
}
}
}
}
};
typo3/js/backendsearch.js (working copy)
var keyCode;
if(!event) {
var event = window.event;
event = window.event;
}
if(event.keyCode) {
......
}
}.bindAsEventListener(this));
$$('#backend-search-menu .toolbar-item')[0].observe('click', this.toggleMenu)
$$('#backend-search-menu .toolbar-item')[0].observe('click', this.toggleMenu);
}.bindAsEventListener(this));
},
......
top.loadEditId(jsonResponse.editRecord);
break;
case 'alternative':
top.content.window.location.href = 'alt_doc.php?returnUrl=dummy.php&edit[' + jsonResponse.alternativeTable + '][' + jsonResponse.alternativeUid + ']=edit'
top.content.window.location.href = 'alt_doc.php?returnUrl=dummy.php&edit[' + jsonResponse.alternativeTable + '][' + jsonResponse.alternativeUid + ']=edit';
break;
case 'search':
this.jump(
......
*/
jump: function(url, modName, mainModName) {
// Clear information about which entry in nav. tree that might have been highlighted.
top.fsMod.navFrameHighlightedID = new Array();
top.fsMod.navFrameHighlightedID = [];
if(top.content && top.content.nav_frame && top.content.nav_frame.refresh_nav) {
top.content.nav_frame.refresh_nav();
}
typo3/js/browse_links.js (working copy)
parent.close();
}
}
}
};
BrowseLinks.File = {
insertElement: function(index, close) {
......
element = this.getParentElement(element);
return Element.select(element, '.typo3-bulk-item');
}
};
};
typo3/js/clearcachemenu.js (working copy)
this.positionMenu();
this.toolbarItemIcon = $$('#clear-cache-actions-menu .toolbar-item img')[0].src;
Event.observe('clear-cache-actions-menu', 'click', this.toggleMenu)
Event.observe('clear-cache-actions-menu', 'click', this.toggleMenu);
// observe all clicks on clear cache actions in the menu
$$('#clear-cache-actions-menu li a').each(function(element) {
typo3/js/clickmenu.js (working copy)
parameters: params,
onComplete: function(xhr) {
var response = xhr.responseXML;
if (!response.getElementsByTagName('data')[0]) return;
if (!response.getElementsByTagName('data')[0]) {
return;
}
var menu = response.getElementsByTagName('data')[0].getElementsByTagName('clickmenu')[0];
var data = menu.getElementsByTagName('htmltable')[0].firstChild.data;
var level = menu.getElementsByTagName('cmlevel')[0].firstChild.data;
......
* @param level the depth of the clickmenu
*/
populateData: function(data, level) {
if (!$('contentMenu0')) this.addClickmenuItem();
if (!$('contentMenu0')) {
this.addClickmenuItem();
}
level = parseInt(level) || 0;
var obj = $('contentMenu' + level);
if (obj && (level == 0 || Element.visible('contentMenu' + (level-1)))) {
if (obj && (level === 0 || Element.visible('contentMenu' + (level-1)))) {
obj.innerHTML = data;
var x = this.mousePos.X;
var y = this.mousePos.Y;
......
var code = '<div id="contentMenu0" style="display: block;"></div><div id="contentMenu1" style="display: block;"></div>';
new Insertion.Bottom(document.getElementsByTagName('body')[0], code);
}
}
};
// register mouse movement inside the document
Event.observe(document, 'mousemove', Clickmenu.calcMousePosEvent.bindAsEventListener(Clickmenu), true);
......
return false;
}
function hideSpecific(level) {
if (level == 0 || level == 1) {
if (level === 0 || level === 1) {
Clickmenu.hide('contentMenu'+level);
}
}
typo3/js/common.js (working copy)
// Please make sure that prototype.js is loaded before loading this
// file in your script, the responder is only added if prototype was loaded
var T3AJAX = {};
if (Prototype) {
// adding generic a responder to use when a AJAX request is done
Ajax.Responders.register({
......
} else {
origSuccess(xhr, json);
}
}
};
}
// hooking "onComplete", using T3Error handler if available
......
} else {
origComplete(xhr, json);
}
}
};
}
}
});
}
var T3AJAX = new Object();
T3AJAX.showError = function(xhr, json) {
if (typeof xhr.responseText != 'undefined' && xhr.responseText) {
if (typeof Ext.MessageBox != 'undefined') {
......
alert(xhr.responseText);
}
}
}
};
typo3/js/modulemenu.js (working copy)
var mainMenuId = mainModuleHeader.up().identify();
var subModulesMenu = mainModuleHeader.next('ul');
if (!subModulesMenu) return;
if (!subModulesMenu) {
return;
}
var state = subModulesMenu.visible();
// save state
......
// highlight the new one
$(moduleId).addClassName('highlighted');
if(undefined != mainModule) {
if(undefined !== mainModule) {
this.currentlyHighLightedMainModule = mainModule;
}
this.currentlyHighlightedModuleId = moduleId;
typo3/js/shortcutmenu.js (working copy)
firstInGroup = shortcut.previous('.first-row');
}
if(undefined != firstInGroup) {
if(undefined !== firstInGroup) {
shortcutGroupId = firstInGroup.previous().identify().slice(15);
}
......
// first create an option for "no group"
option = document.createElement('option');
option.value = 0;
option.selected = (shortcutGroupId == 0 ? true : false);
option.selected = (shortcutGroupId === 0 ? true : false);
option.appendChild(document.createTextNode('No Group'));
selectField.appendChild(option);
......
shortcutGroups = $H(json.shortcutGroups);
shortcutGroups.each(function(group) {
option = document.createElement('option');
option.value = group.key
option.value = group.key;
option.selected = (shortcutGroupId == group.key ? true : false);
option.appendChild(document.createTextNode(group.value));
selectField.appendChild(option);
......
reRenderMenu: function(transport, element, backPath) {
var container = $$('#shortcut-menu .toolbar-item-menu')[0];
if(!backPath) {
var backPath = '';
backPath = '';
}
typo3/js/tree.js (working copy)
// attaches the events to the elements needed for the drag and drop (for the titles and the icons)
registerDragDropHandlers: function() {
if (!this.activateDragDrop) return;
if (!this.activateDragDrop) {
return;
}
this._registerDragDropHandlers('dragTitle');
this._registerDragDropHandlers('dragIcon');
},
......
var searchFieldContent = $F(this.field);
var resetButton = $(this.resetfield);
if (searchFieldContent != '' && resetButton.getStyle('visibility') == 'hidden') {
if (searchFieldContent !== '' && resetButton.getStyle('visibility') === 'hidden') {
resetButton.setStyle({ visibility: 'visible'} );
} else if (searchFieldContent == '' && resetButton.getStyle('visibility') == 'visible') {
} else if (searchFieldContent === '' && resetButton.getStyle('visibility') === 'visible') {
resetButton.setStyle( {visibility: 'hidden'} );
}
},
(1-1/2)