Compare commits

...

7 Commits

Author SHA1 Message Date
bartvde
39e8fc6aa4 Tagging the Final 2.9.1 Release
git-svn-id: http://svn.openlayers.org/tags/openlayers/release-2.9.1@10291 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-06 13:06:56 +00:00
bartvde
91c3396a5d pullup r10278 to the 2.9 branch (closes #2414)
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.9@10279 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-04 10:14:01 +00:00
bartvde
2db48d9bea pullup fix for reopened ticket:2414 to 2.9 branch
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.9@10277 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-04 09:48:34 +00:00
bartvde
31225b5e3b pulling up fix for reopened ticket:2393 to 2.9 branch
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.9@10275 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-04 04:43:23 +00:00
bartvde
1e7129b463 pull up #2613 to the 2.9 branch
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.9@10274 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-04 04:38:53 +00:00
bartvde
fa86eabd7a pullup #2596 to 2.9 branch
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.9@10265 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-03 13:08:16 +00:00
bartvde
39d002488c pullup #2611 to 2.9 branch
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.9@10264 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
2010-05-03 11:11:33 +00:00
6 changed files with 68 additions and 6 deletions

View File

@@ -106,8 +106,8 @@ OpenLayers.Layer.Vector = OpenLayers.Class(OpenLayers.Layer, {
/**
* APIProperty: isBaseLayer
* {Boolean} The layer is a base layer. Default is true. Set this property
* in the layer options
* {Boolean} The layer is a base layer. Default is false. Set this property
* in the layer options.
*/
isBaseLayer: false,

View File

@@ -1402,6 +1402,10 @@ OpenLayers.Map = OpenLayers.Class({
var size = new OpenLayers.Size(this.div.clientWidth,
this.div.clientHeight);
if (size.w == 0 && size.h == 0 || isNaN(size.w) && isNaN(size.h)) {
size.w = this.div.offsetWidth;
size.h = this.div.offsetHeight;
}
if (size.w == 0 && size.h == 0 || isNaN(size.w) && isNaN(size.h)) {
size.w = parseInt(this.div.style.width);
size.h = parseInt(this.div.style.height);

View File

@@ -358,10 +358,11 @@ OpenLayers.Protocol.HTTP = OpenLayers.Class(OpenLayers.Protocol, {
* the feature received from the server.
*/
update: function(feature, options) {
options = OpenLayers.Util.applyDefaults(options, this.options);
options = options || {};
var url = options.url ||
feature.url ||
this.options.url + "/" + feature.fid;
options = OpenLayers.Util.applyDefaults(options, this.options);
var resp = new OpenLayers.Protocol.Response({
reqFeatures: feature,
@@ -408,10 +409,11 @@ OpenLayers.Protocol.HTTP = OpenLayers.Class(OpenLayers.Protocol, {
* completes.
*/
"delete": function(feature, options) {
options = OpenLayers.Util.applyDefaults(options, this.options);
options = options || {};
var url = options.url ||
feature.url ||
this.options.url + "/" + feature.fid;
options = OpenLayers.Util.applyDefaults(options, this.options);
var resp = new OpenLayers.Protocol.Response({
reqFeatures: feature,

View File

@@ -340,7 +340,7 @@ OpenLayers.Renderer.SVG = OpenLayers.Class(OpenLayers.Renderer.Elements, {
}
var rotation = style.rotation;
if (node._rotation !== rotation && pos) {
if ((rotation !== undefined || node._rotation !== undefined) && pos) {
node._rotation = rotation;
rotation |= 0;
if(node.nodeName !== "svg") {

View File

@@ -19,7 +19,7 @@ OpenLayers.Strategy.Fixed = OpenLayers.Class(OpenLayers.Strategy, {
* APIProperty: preload
* {Boolean} Load data before layer made visible. Enabling this may result
* in considerable overhead if your application loads many data layers
* that are not visible by default. Default is true.
* that are not visible by default. Default is false.
*/
preload: false,

View File

@@ -696,6 +696,34 @@
OpenLayers.Request.PUT = _put;
}
function test_update_featureurl(t) {
// test that OpenLayers.Request.PUT receives the URL
// set in the feature
// http://trac.openlayers.org/ticket/2393#comment:11
t.plan(1);
var protocol = new OpenLayers.Protocol.HTTP({
'url': 'foo_url',
'format': {'write': function() {}}
});
// feature to pass to update
var feature = {'feature':'feature', 'url': 'bar_url'};
var _put = OpenLayers.Request.PUT;
OpenLayers.Request.PUT = function(options) {
t.eq(options.url, feature.url,
'PUT called with correct url in options');
};
protocol.update(feature);
OpenLayers.Request.PUT = _put;
}
function test_handleResponse(t) {
t.plan(6);
@@ -817,6 +845,34 @@
OpenLayers.Request.DELETE = _delete;
}
function test_delete_featureurl(t) {
// test that OpenLayers.Request.DELETE receives the URL
// set in the feature
// http://trac.openlayers.org/ticket/2393#comment:11
t.plan(1);
var protocol = new OpenLayers.Protocol.HTTP({
'url': 'foo_url',
'format': {'write': function() {}}
});
// feature to pass to update
var feature = {'feature':'feature', 'url': 'bar_url'};
var _delete = OpenLayers.Request.DELETE;
OpenLayers.Request.DELETE = function(options) {
t.eq(options.url, feature.url,
'DELETE called with correct url in options');
};
protocol['delete'](feature);
OpenLayers.Request.DELETE = _delete;
}
function test_handleDelete(t) {
t.plan(4);