Author: damoxc

Revision: 5560

Log:
        add a property to the field object since we can't use a bi directional 
lookup in javascript :(

Diff:
Modified: trunk/deluge/ui/web/js/Deluge.OptionsManager.js
===================================================================
--- trunk/deluge/ui/web/js/Deluge.OptionsManager.js     2009-07-28 21:51:58 UTC 
(rev 5559)
+++ trunk/deluge/ui/web/js/Deluge.OptionsManager.js     2009-07-28 22:04:00 UTC 
(rev 5560)
@@ -79,7 +79,7 @@
         */
        bind: function(option, field) {
                this.binds[option] = field;
-               this.binds[field] = option;
+               field._doption = option;
                
                field.on('focus', this.onFieldFocus, this);
                field.on('blur', this.onFieldBlur, this);
@@ -218,8 +218,7 @@
         * @private
         */
        onFieldChange: function(field, event) {
-               var option = this.binds[field];
-               this.update(option, field.getValue());
+               this.update(field._doption, field.getValue());
        },
        
        /**



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"deluge-commit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/deluge-commit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to