Closed Bug 323321 Opened 14 years ago Closed 14 years ago
Drag'n'drop of events via right mouse button confuses the views
Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9a1) Gecko/20060113 Mozilla Sunbird/0.3a1+ Currently the new Day / Week views allow Drag'n'Drop of events via right mouse button too. This gives confusing results if you use an operation of the context menu afterwards. Example 1: After dragging an event to a new position via right mouse button the context menu for that event pops up. Select "Edit Event" and open the Edit dialog. Error: You will notice that the dialog still displays the old date/time of the event. Press "Ok" and you will see two event boxes in the view: one at the old position and one at the new position. Example 2: Try to resize with the right mouse button. Error: You will move the event instead of resizing. If you play around you will find several other problems based on this principle. I think the views drag'n'drop feature should only work via left mouse button.
Content of patch: - drag'n'drop of events or event borders only react on left mouse button - inline editing only react on left mouse button (it was very confusing when you right clicked a selected event and edit mode started and context menu poped up) - double click to create a new event only react on left mouse button - ensure that we select the event on right mouse button by adding a new handler
Attachment #209505 - Flags: first-review?(jminta)
Comment on attachment 209505 [details] [diff] [review] patch, v1 - <handler event="dblclick"><![CDATA[ + <handler event="click" button="2"><![CDATA[ + // only select item if right mouse button pressed + this.calendarView.selectedItem = this.mOccurrence; + ]]></handler> I have a third button on my mouse. I'm concerned that only addressing left and right clicks will create problems for more complex input-pointers. Perhaps just adding an if (event.button != 0) return; clause would work better?
Attachment #209505 - Flags: first-review?(jminta) → first-review-
Little changes after some chitchat on IRC.
Comment on attachment 209627 [details] [diff] [review] patch, v3 Very nice. r=jminta Any idea if there are other areas of our code where these sort of mouse-button issues haven't been addressed? I remember I fixed something like this in the minimonth not too long ago.
Attachment #209627 - Flags: first-review?(jminta) → first-review+
patch checked in
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.