From 7f0dad901bef6512357a7a768fda1cb3106ac864 Mon Sep 17 00:00:00 2001 From: Eric Guzman Date: Thu, 17 May 2012 19:55:18 -0700 Subject: CSS Panel - Fix style declaration interaction --- js/panels/css-panel/styles-view-delegate.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'js/panels/css-panel/styles-view-delegate.js') diff --git a/js/panels/css-panel/styles-view-delegate.js b/js/panels/css-panel/styles-view-delegate.js index e00d7fca..38b0fcc6 100644 --- a/js/panels/css-panel/styles-view-delegate.js +++ b/js/panels/css-panel/styles-view-delegate.js @@ -125,7 +125,7 @@ exports.StylesViewMediator = Montage.create(Component, { nextFocus = style.getSiblingStyle('next'); if(nextFocus) { nextFocus.propertyField.start(); - } else { + } else if(style.dirty) { style.parentComponent.parentComponent.addNewStyle(); style.editingNewStyle = false; setTimeout(function() { @@ -189,11 +189,6 @@ exports.StylesViewMediator = Montage.create(Component, { style.invalid = (browserValue === null); this._dispatchChange(property, browserValue); - - if(style.editingNewStyle) { - style.parentComponent.parentComponent.addNewStyle(); - style.editingNewStyle = false; - } } }, -- cgit v1.2.3