kkpowar / gmaps-utility-library-dev

Automatically exported from code.google.com/p/gmaps-utility-library-dev
0 stars 0 forks source link

LabeledMarker is always clickable #91

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
Create a LabeledMarker with "clickable: false" in the options object

What is the expected output? What do you see instead?
The marker's label should not be clickable, nor should it show a "pointer" 
cursor, but I still get a 
hand pointer cursor and the label is clickable. The marker itself behaves 
correctly.

What version of the product are you using? On what operating system?
labeledmarker.js version 1.3 (but this bug also exists in the developer version)

Please provide any additional information below.
In the LabeledMarker constructor, the line:

  this.clickable_ = opt_opts.clickable || true;

set this.clickable_ to true, if opt_opts.clickable == false (false || true == 
true). I think this should 
be changed to:

  this.clickable_ = opt_opts.clickable && true;

Also, the line:

  this.div_.style.cursor = "pointer";

set the cursor to a hand pointer, regardless of the clickable option. I think a 
check should be 
added:

  if (this.clickable_)
    this.div_.style.cursor = "pointer";

Kind regards,
Kris Breuker

Original issue reported on code.google.com by kris.bre...@gmail.com on 24 Feb 2009 at 4:40

GoogleCodeExporter commented 8 years ago
Fixed in r933, by roughly following suggestions. Added example to check 
behavior as 
well.
http://gmaps-utility-library-
dev.googlecode.com/svn/trunk/labeledmarker/examples/unclickable.html

Original comment by pamela.fox on 28 Feb 2009 at 7:33

GoogleCodeExporter commented 8 years ago
This is released in 1.4

Original comment by pamela.fox on 23 Jun 2009 at 9:57