[Mono-bugs] [Bug 582902] New: When ImageMap.HotSpotMode is set to HotSpotMode.NotSet, no default behavior is adopted and no navigation link is rendered to client.
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Wed Feb 24 15:33:09 EST 2010
http://bugzilla.novell.com/show_bug.cgi?id=582902
http://bugzilla.novell.com/show_bug.cgi?id=582902#c0
Summary: When ImageMap.HotSpotMode is set to
HotSpotMode.NotSet, no default behavior is adopted and
no navigation link is rendered to client.
Classification: Mono
Product: Mono: Class Libraries
Version: 2.6.x
Platform: All
OS/Version: All
Status: NEW
Severity: Normal
Priority: P5 - None
Component: Sys.Web
AssignedTo: mhabersack at novell.com
ReportedBy: kuritsu at gmail.com
QAContact: mono-bugs at lists.ximian.com
Found By: ---
Blocker: ---
Created an attachment (id=344583)
--> (http://bugzilla.novell.com/attachment.cgi?id=344583)
This a MonoDevelop project with the test case.
User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; es-MX; rv:1.9.1.5)
Gecko/20091109 Ubuntu/9.10 (karmic) Firefox/3.5.5
According to this page:
http://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.imagemap.hotspotmode.aspx
If an ImageMap control's ImageMap.HotSpotMode property or the
HotSpot.HotSpotMode property on any of the HotSpot objects it contains is
either set to HotSpotMode.NotSet or not set to a value, by default the behavior
is HotSpotMode.Navigate.
This behavior is not followed, so no navigation link is sent to the client when
both the HotSpot and ImageMap have HotSpotMode = HotSpotMode.NotSet.
Reproducible: Always
Steps to Reproduce:
1. Create a C# ASP.NET project using MonoDevelop.
2. Add an image (.jpg, .bmp, .png, etc.) with resolution no less than 100
pixels width and height to your project. Let's say it's myimage.jpg.
3. In Default.aspx, create a ImageMap tag inside the form, using this code:
<asp:ImageMap ID="imgMap" runat="server" ImageUrl="~/myimage.jpg" />
4. In the Default.aspx.cs code behind, add this code inside the Default class:
protected void Page_Load(object sender, EventArgs args)
{
RectangleHotSpot spot = new RectangleHotSpot();
spot.Left = 0;
spot.Right = 100;
spot.Top = 0;
spot.Bottom = 100;
spot.NavigateUrl = "http://www.mono-project.com";
imgMap.HotSpots.Add(spot);
}
5. Compile and run the project. Remember to type the correct URL of the page in
your browser.
Actual Results:
When the page is displayed, you click everywhere in the image and no response,
no postbacks, no nothing.
This is what is rendered:
<img id="imgMap" src="myimage.jpg" usemap="#ImageMapimgMap"
style="border-width:0px;" />
<map name="ImageMapimgMap">
<area shape="rect" coords="0,0,100,100" title="" alt="">
</area>
</map>
Expected Results:
When the page display, you click on the image and then navigate to the Mono
Project site (or where the link points).
This is what should be rendered:
<img id="imgMap" src="DB9.jpg" usemap="#ImageMapimgMap"
style="border-width:0px;" />
<map name="ImageMapimgMap">
<area shape="rect" coords="0,0,100,100" title="" alt=""
href="http://www.mono-project.com">
</area>
</map>
--
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
More information about the mono-bugs
mailing list