Bug Tracker


Ticket #2918 (closed bug: invalid)

Opened 6 years ago

Last modified 4 years ago

DRAG object causes extra CLICK event in Mozilla - simple code example included

Reported by: chrishandorf Owned by: paul
Priority: major Milestone: 1.3
Component: ui Version: 1.2.5
Keywords: draggable Cc:
Blocking: Blocked by:


Run code below in Safari or I.E. When you drag the yellow box on the screen you will see a series of mousedown/dragstart/dragstop events.

When running in Mozilla (winxp) however, you will occasionally get both MOUSEUP and CLICK events at the conclusion of a DRAG/DROP sequence.

This example is a condensed version of a real application that needs to handle DRAG and CLICK events differently on the yellow box. Unfortunately, Mozilla is combining them so the DRAG also causes a CLICK which breaks the interface.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

.folder {              
   background: yellow;
   width: 200px;

.folderLabel {
   overflow: hidden;
   width: 150px;

  <div class="folder" id="Folder1">
     <div class="folderLabel">Folder1</div>

  <div class="log"></div>  

<script src="jquery-1.2.4b.js"       type="text/javascript"></script>
<script src="jquery.ui-all-1.5b4.js" type="text/javascript"></script>
<script type="text/javascript">


   var debug           = $(".log");

   function md() {debug.append("mousedown<br>")  }
   function mu() {debug.append("mouseup<br>")    }
   function ck() {debug.append("click<br>")      }
   function ds() {debug.append("dragstart<br>"); }
   function dt() {debug.append("dragstop<br>");  }



Change History

comment:1 Changed 6 years ago by flesler

  • Keywords draggable added
  • Owner set to paul
  • Component changed from core to ui

comment:2 Changed 4 years ago by dmethvin

  • Status changed from new to closed
  • Resolution set to invalid

This should be filed in the UI bug tracker if still relevant.


Please follow the  bug reporting guidlines and use  jsFiddle when providing test cases and demonstrations instead of pasting the code in the ticket.


Add a comment

Modify Ticket

as closed

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.