From 6a2f5ed18a8e307d2433f02fbff14137e02a3e9c Mon Sep 17 00:00:00 2001 From: "blakeross%telocity.com" Date: Sun, 3 Feb 2002 00:06:12 +0000 Subject: [PATCH] 39070 - can't dnd images or . r=ben sr=hewitt git-svn-id: svn://10.0.0.236/trunk@113544 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/layout/html/document/src/html.css | 4 ++++ mozilla/layout/style/html.css | 4 ++++ .../communicator/resources/content/contentAreaDD.js | 11 +++++++++-- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/mozilla/layout/html/document/src/html.css b/mozilla/layout/html/document/src/html.css index d5846a4bc5c..a501e25a540 100644 --- a/mozilla/layout/html/document/src/html.css +++ b/mozilla/layout/html/document/src/html.css @@ -404,6 +404,10 @@ hr { cursor: pointer; } +img, area { + -moz-user-select: none !important; +} + img[usemap], object[usemap] { color: blue; -moz-user-focus: normal; diff --git a/mozilla/layout/style/html.css b/mozilla/layout/style/html.css index d5846a4bc5c..a501e25a540 100644 --- a/mozilla/layout/style/html.css +++ b/mozilla/layout/style/html.css @@ -404,6 +404,10 @@ hr { cursor: pointer; } +img, area { + -moz-user-select: none !important; +} + img[usemap], object[usemap] { color: blue; -moz-user-focus: normal; diff --git a/mozilla/xpfe/communicator/resources/content/contentAreaDD.js b/mozilla/xpfe/communicator/resources/content/contentAreaDD.js index 9007c15f3dd..c3628f3e8fa 100644 --- a/mozilla/xpfe/communicator/resources/content/contentAreaDD.js +++ b/mozilla/xpfe/communicator/resources/content/contentAreaDD.js @@ -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 = ""; + 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 = "";