Permalink
Browse files

Resetting settings should not close dialog.

  • Loading branch information...
1 parent 6af7010 commit 40798ea87364762382e41972ec1d0cbcef035722 @mikaeljorhult committed May 4, 2015
Showing with 8 additions and 4 deletions.
  1. +1 −1 html/settings-dialog.html
  2. +1 −1 main.js
  3. +6 −2 modules/SettingsDialog.js
@@ -26,7 +26,7 @@ <h1 class="dialog-title">{{ Strings.SETTINGS_TITLE }}</h1>
</div>
<div class="modal-footer">
- <button data-button-id="reset" class="dialog-button reset-preferences btn left">{{ Strings.RESET }}</button>
+ <button data-button-id="reset" class="reset-preferences btn left">{{ Strings.RESET }}</button>
<button data-button-id="ok" class="dialog-button btn primary">{{ Strings.OK }}</button>
<button data-button-id="cancel" class="dialog-button btn">{{ Strings.CANCEL }}</button>
View
@@ -1,5 +1,5 @@
/*!
- * Brackets Autoprefixer 0.5.20
+ * Brackets Autoprefixer 0.6.0
* Parse CSS and add vendor prefixes automatically.
*
* @author Mikael Jorhult
@@ -7,7 +7,6 @@ define( function( require, exports ) {
// Extension modules.
Defaults = require( 'modules/Defaults' ),
Strings = require( 'modules/Strings' ),
- autoprefixer = require( 'modules/vendor/autoprefixer/Autoprefixer' ),
// Templates.
settingsDialogTemplate = require( 'text!../html/settings-dialog.html' ),
@@ -24,15 +23,20 @@ define( function( require, exports ) {
function resetValues() {
preferences.set( 'visualCascade', false );
preferences.set( 'browsers', Defaults.browsers );
-
preferences.save();
+
+ init();
}
/**
* Set each value of the preferences in dialog.
*/
function setValues( values ) {
$( '#autoprefixer-settings-visualCascade' ).prop( 'checked', values.visualCascade );
+
+ $dialog.find( '#autoprefixer-settings-browsers' ).html( Mustache.render( settingsDialogBrowser, {
+ browsers: preferences.get( 'browsers' )
+ } ) );
}
/**

0 comments on commit 40798ea

Please sign in to comment.