Merged [47102]: Optimization for Behaviour sheets that allows you to provide a unique identifier so that duplicate sheets aren't applied twice.

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@60556 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Hayden Smith 2008-08-12 23:53:08 +00:00
parent 5cd507ecaa
commit 8bf45c52e2
2 changed files with 4 additions and 4 deletions

View File

@ -8,7 +8,7 @@ LeftPane.prototype = {
effectDuration: .7,
initialize: function() {
Behaviour.register({
Behaviour.register('LeftPane',{
'#Form_CreationForm_action_createRecord': {
onclick: this.addNewRecord.bind(this)
},
@ -49,7 +49,7 @@ LeftPane.prototype = {
var toggleLinks = document.getElementsBySelector('div#LeftPane .ToggleAdvancedSearchFields');
if(toggleLinks && toggleLinks[0]) toggleLinks[0].style.display = "block";
Behaviour.register({
Behaviour.register('LeftPane_initAdvancedSearch',{
"div#LeftPane .ToggleAdvancedSearchFields a":{
onclick: function(e){
var el = Event.element(e);
@ -153,7 +153,7 @@ ResultTable = Class.create();
ResultTable.applyTo('#ResultTable_holder');
ResultTable.prototype = {
initialize: function() {
Behaviour.register({
Behaviour.register('ResultTable',{
"#LeftPane a.show":{
onclick: function(e){
var openTab = $('Form_EditForm').getCurrentTab();

View File

@ -3,7 +3,7 @@ MemberTableFieldPopupForm.prototype = {
initialize: function() {
this.ComplexTableFieldPopupForm.initialize();
Behaviour.register({
Behaviour.register('MemberTableFieldPopupForm',{
"div.MemberTableField_Popup .Actions input.action": {
onclick: this.submitForm.bind(this)
}