Rename _ol_style_Fill_ to Fill

This commit is contained in:
Tim Schaub
2018-01-11 13:23:27 -07:00
parent 4f4c90fc20
commit dc6ae2293d
65 changed files with 268 additions and 268 deletions

View File

@@ -10,7 +10,7 @@ import _ol_geom_flat_geodesic_ from './geom/flat/geodesic.js';
import {clamp} from './math.js';
import {get as getProjection, equivalent as equivalentProjection, getTransform, transformExtent} from './proj.js';
import RenderEventType from './render/EventType.js';
import _ol_style_Fill_ from './style/Fill.js';
import Fill from './style/Fill.js';
import _ol_style_Stroke_ from './style/Stroke.js';
import _ol_style_Text_ from './style/Text.js';
@@ -286,7 +286,7 @@ var Graticule = function(opt_options) {
new _ol_style_Text_({
font: '12px Calibri,sans-serif',
textBaseline: 'bottom',
fill: new _ol_style_Fill_({
fill: new Fill({
color: 'rgba(0,0,0,1)'
}),
stroke: new _ol_style_Stroke_({
@@ -303,7 +303,7 @@ var Graticule = function(opt_options) {
new _ol_style_Text_({
font: '12px Calibri,sans-serif',
textAlign: 'end',
fill: new _ol_style_Fill_({
fill: new Fill({
color: 'rgba(0,0,0,1)'
}),
stroke: new _ol_style_Stroke_({

View File

@@ -20,7 +20,7 @@ import Point from '../geom/Point.js';
import Polygon from '../geom/Polygon.js';
import {toRadians} from '../math.js';
import {get as getProjection} from '../proj.js';
import _ol_style_Fill_ from '../style/Fill.js';
import Fill from '../style/Fill.js';
import _ol_style_Icon_ from '../style/Icon.js';
import IconAnchorUnits from '../style/IconAnchorUnits.js';
import IconOrigin from '../style/IconOrigin.js';
@@ -145,7 +145,7 @@ KML.createStyleDefaults_ = function() {
* @type {ol.style.Fill}
* @private
*/
KML.DEFAULT_FILL_STYLE_ = new _ol_style_Fill_({
KML.DEFAULT_FILL_STYLE_ = new Fill({
color: KML.DEFAULT_COLOR_
});
@@ -666,7 +666,7 @@ KML.LabelStyleParser_ = function(node, objectStack) {
}
var styleObject = objectStack[objectStack.length - 1];
var textStyle = new _ol_style_Text_({
fill: new _ol_style_Fill_({
fill: new Fill({
color: /** @type {ol.Color} */
('color' in object ? object['color'] : KML.DEFAULT_COLOR_)
}),
@@ -716,7 +716,7 @@ KML.PolyStyleParser_ = function(node, objectStack) {
return;
}
var styleObject = objectStack[objectStack.length - 1];
var fillStyle = new _ol_style_Fill_({
var fillStyle = new Fill({
color: /** @type {ol.Color} */
('color' in object ? object['color'] : KML.DEFAULT_COLOR_)
});

View File

@@ -12,7 +12,7 @@ import {asString} from '../color.js';
* @param {olx.style.FillOptions=} opt_options Options.
* @api
*/
var _ol_style_Fill_ = function(opt_options) {
var Fill = function(opt_options) {
var options = opt_options || {};
@@ -35,9 +35,9 @@ var _ol_style_Fill_ = function(opt_options) {
* @return {ol.style.Fill} The cloned style.
* @api
*/
_ol_style_Fill_.prototype.clone = function() {
Fill.prototype.clone = function() {
var color = this.getColor();
return new _ol_style_Fill_({
return new Fill({
color: (color && color.slice) ? color.slice() : color || undefined
});
};
@@ -48,7 +48,7 @@ _ol_style_Fill_.prototype.clone = function() {
* @return {ol.Color|ol.ColorLike} Color.
* @api
*/
_ol_style_Fill_.prototype.getColor = function() {
Fill.prototype.getColor = function() {
return this.color_;
};
@@ -59,7 +59,7 @@ _ol_style_Fill_.prototype.getColor = function() {
* @param {ol.Color|ol.ColorLike} color Color.
* @api
*/
_ol_style_Fill_.prototype.setColor = function(color) {
Fill.prototype.setColor = function(color) {
this.color_ = color;
this.checksum_ = undefined;
};
@@ -68,7 +68,7 @@ _ol_style_Fill_.prototype.setColor = function(color) {
/**
* @return {string} The checksum.
*/
_ol_style_Fill_.prototype.getChecksum = function() {
Fill.prototype.getChecksum = function() {
if (this.checksum_ === undefined) {
if (
this.color_ instanceof CanvasPattern ||
@@ -82,4 +82,4 @@ _ol_style_Fill_.prototype.getChecksum = function() {
return this.checksum_;
};
export default _ol_style_Fill_;
export default Fill;

View File

@@ -4,7 +4,7 @@
import {assert} from '../asserts.js';
import GeometryType from '../geom/GeometryType.js';
import _ol_style_Circle_ from '../style/Circle.js';
import _ol_style_Fill_ from '../style/Fill.js';
import Fill from '../style/Fill.js';
import _ol_style_Stroke_ from '../style/Stroke.js';
/**
@@ -322,7 +322,7 @@ Style.defaultFunction = function(feature, resolution) {
// canvas.getContext('2d') at construction time, which will cause an.error
// in such browsers.)
if (!Style.default_) {
var fill = new _ol_style_Fill_({
var fill = new Fill({
color: 'rgba(255,255,255,0.4)'
});
var stroke = new _ol_style_Stroke_({
@@ -357,7 +357,7 @@ Style.createDefaultEditing = function() {
var width = 3;
styles[GeometryType.POLYGON] = [
new Style({
fill: new _ol_style_Fill_({
fill: new Fill({
color: [255, 255, 255, 0.5]
})
})
@@ -392,7 +392,7 @@ Style.createDefaultEditing = function() {
new Style({
image: new _ol_style_Circle_({
radius: width * 2,
fill: new _ol_style_Fill_({
fill: new Fill({
color: blue
}),
stroke: new _ol_style_Stroke_({

View File

@@ -1,7 +1,7 @@
/**
* @module ol/style/Text
*/
import _ol_style_Fill_ from '../style/Fill.js';
import Fill from '../style/Fill.js';
import TextPlacement from '../style/TextPlacement.js';
/**
@@ -63,7 +63,7 @@ var _ol_style_Text_ = function(opt_options) {
* @type {ol.style.Fill}
*/
this.fill_ = options.fill !== undefined ? options.fill :
new _ol_style_Fill_({color: _ol_style_Text_.DEFAULT_FILL_COLOR_});
new Fill({color: _ol_style_Text_.DEFAULT_FILL_COLOR_});
/**
* @private