39070 - can't dnd images or <areas>. r=ben sr=hewitt

git-svn-id: svn://10.0.0.236/trunk@113544 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
blakeross%telocity.com 2002-02-03 00:06:12 +00:00
parent 1a11ac5be2
commit 6a2f5ed18a
3 changed files with 17 additions and 2 deletions

View File

@ -404,6 +404,10 @@ hr {
cursor: pointer;
}
img, area {
-moz-user-select: none !important;
}
img[usemap], object[usemap] {
color: blue;
-moz-user-focus: normal;

View File

@ -404,6 +404,10 @@ hr {
cursor: pointer;
}
img, area {
-moz-user-select: none !important;
}
img[usemap], object[usemap] {
color: blue;
-moz-user-focus: normal;

View File

@ -97,13 +97,20 @@ var contentAreaDNDObserver = {
switch (local_name)
{
case 'AREA':
var areasrc = draggedNode.getAttribute("href");
// use alt text as the title of the area, if it's there
titlestring = draggedNode.getAttribute("alt");
urlstring = areasrc;
htmlstring = "<img src=\"" + urlstring + "\">";
break;
case 'IMG':
var imgsrc = draggedNode.getAttribute("src");
var baseurl = window._content.location.href;
// var baseurl = window._content.location.href;
// need to do some stuff with the window._content.location
// (path?) to get base URL for image.
// use alt text as the title of the image, if it's there
// use alt text as the title of the image, if it's there
titlestring = draggedNode.getAttribute("alt");
urlstring = imgsrc;
htmlstring = "<img src=\"" + urlstring + "\">";