Renaming utilties for clarity

This commit is contained in:
Ramya Achutha Rao
2017-07-24 14:45:02 -07:00
parent 76392ae91f
commit bf634bf4e7
13 changed files with 33 additions and 33 deletions

View File

@@ -4,7 +4,7 @@
*--------------------------------------------------------------------------------------------*/
import { Range, window, TextEditor } from 'vscode';
import { getCssProperty, getCssPropertyNode } from './util';
import { getCssPropertyFromRule, getCssPropertyFromDocument } from './util';
import { Property, Rule } from 'EmmetNode';
const vendorPrefixes = ['-webkit-', '-moz-', '-ms-', '-o-', ''];
@@ -16,7 +16,7 @@ export function reflectCssValue() {
return;
}
let node = getCssPropertyNode(editor, editor.selection.active);
let node = getCssPropertyFromDocument(editor, editor.selection.active);
if (!node) {
return;
}
@@ -45,7 +45,7 @@ function updateCSSNode(editor: TextEditor, property: Property) {
if (prefix === currentPrefix) {
return;
}
let vendorProperty = getCssProperty(rule, prefix + propertyName);
let vendorProperty = getCssPropertyFromRule(rule, prefix + propertyName);
if (vendorProperty) {
builder.replace(new Range(vendorProperty.valueToken.start, vendorProperty.valueToken.end), propertyValue);
}