• 
      

    Disable drag & drop attachment upload when modal dialog is shown

    Review Request #10108 — Created July 29, 2018 and updated

    Information

    Review Board
    release-3.0.x
    c6a4dba...

    Reviewers

    The previous behavior could be very annoying when trying to update a
    diff using drag & drop. Also, when using the "Add File" dialog the
    behavior was confusing.

    Chose "Update Diff", dragged file onto browser window
    -> drag & drop overlay did not appear
    Chose "Add File", dragged file onto browser window
    -> drag & drop overlay did not appear
    Dragged file onto review request view (Reviews/Diff)
    -> drag & drop overlay appeared

    Description From Last Updated

    There's no guarantee that this class name will be used in the future. I think an option that would help …

    chipx86chipx86
    easyb
    Review request changed
    Description:
    ~  

    The behavior can be very annoying when trying to update a diff using

    ~   drag & drop. Also, when using the "Add File" dialog the behavior is
    ~   confusing.

      ~

    The previous behavior could be very annoying when trying to update a

      ~ diff using drag & drop. Also, when using the "Add File" dialog the
      ~ behavior was confusing.

    chipx86
    1. 
        
    2. Show all issues

      There's no guarantee that this class name will be used in the future.

      I think an option that would help future-proof would be to introduce signals that RB.DialogView subclasses would automatically emit when showing/hiding to indicate to callers that a dialog is or is not on screen. The file upload area could then listen to this, disabling/re-enabling the upload support as needed.

      1. Makes sense. But, I am a little confused here. To me it seems that RB.UploadAttachmentView and RB.UpdateDiffView do not inherit from RB.DialogView. Further, I do not get how I can trigger an event when $.modalBox is being hidden.

    3.