Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-2722

Selected "text" is not copied from drop-down menu

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • core
    • None
    • Platform: All, OS: All

      Steps to reproduce :

      1. Create a new job
      2. Select "Copy from existing job"
      3. List appears in drop-down menu
      4. Select"job" from drop-down-menu
      5. It is not copied to the text field.
      6. You will have to type it on your own.

      Will be nice to have this working .

          [JENKINS-2722] Selected "text" is not copied from drop-down menu

          Code changed in hudson
          User: : kohsuke
          Path:
          branches/autocomplete-mess/core/src/main/java/hudson/model/Hudson.java
          branches/autocomplete-mess/core/src/main/java/hudson/scm/CVSSCM.java
          branches/autocomplete-mess/core/src/main/java/hudson/search/Search.java
          branches/autocomplete-mess/core/src/main/resources/hudson/model/Hudson/projectRelationship.jelly
          branches/autocomplete-mess/core/src/main/resources/hudson/model/View/newJob.jelly
          branches/autocomplete-mess/core/src/main/resources/hudson/scm/CVSSCM/config.jelly
          branches/autocomplete-mess/core/src/main/resources/lib/form/editableComboBox.jelly
          branches/autocomplete-mess/core/src/main/resources/lib/layout/layout.jelly
          http://fisheye4.cenqua.com/changelog/hudson/?cs=13662
          Log:
          JENKINS-2722

          SCM/JIRA link daemon added a comment - Code changed in hudson User: : kohsuke Path: branches/autocomplete-mess/core/src/main/java/hudson/model/Hudson.java branches/autocomplete-mess/core/src/main/java/hudson/scm/CVSSCM.java branches/autocomplete-mess/core/src/main/java/hudson/search/Search.java branches/autocomplete-mess/core/src/main/resources/hudson/model/Hudson/projectRelationship.jelly branches/autocomplete-mess/core/src/main/resources/hudson/model/View/newJob.jelly branches/autocomplete-mess/core/src/main/resources/hudson/scm/CVSSCM/config.jelly branches/autocomplete-mess/core/src/main/resources/lib/form/editableComboBox.jelly branches/autocomplete-mess/core/src/main/resources/lib/layout/layout.jelly http://fisheye4.cenqua.com/changelog/hudson/?cs=13662 Log: JENKINS-2722

          This works most of the times, so I'm lowering the priority, especially given
          that I've already spent several hours on this to no avail.

          Kohsuke Kawaguchi added a comment - This works most of the times, so I'm lowering the priority, especially given that I've already spent several hours on this to no avail.

          Alan Harder added a comment -

          I have seen this from time to time.. finally figured out what it is: when you click on the desired job name, if you hold the mouse button too long then it does not actually put the job name in the text box. It seems to work reliably with keyboard selection (arrow keys, enter or tab) or if you quick-click the job to copy.

          Alan Harder added a comment - I have seen this from time to time.. finally figured out what it is: when you click on the desired job name, if you hold the mouse button too long then it does not actually put the job name in the text box. It seems to work reliably with keyboard selection (arrow keys, enter or tab) or if you quick-click the job to copy.

          Alan Harder added a comment -

          Here's what happens: when you press the mouse button on one of the items the textfield loses focus, so field.onblur does a setTimeout to hide the dropdown in 100ms. If you release the mouse button before then, the onclick event happens and the item is properly placed into the text field. If you hold down the mouse too long, the setTimeout hides the dropdown and the onclick never happens.

          Alan Harder added a comment - Here's what happens: when you press the mouse button on one of the items the textfield loses focus, so field.onblur does a setTimeout to hide the dropdown in 100ms. If you release the mouse button before then, the onclick event happens and the item is properly placed into the text field. If you hold down the mouse too long, the setTimeout hides the dropdown and the onclick never happens.

          Code changed in hudson
          User: : mindless
          Path:
          trunk/hudson/main/war/resources/scripts/combobox.js
          trunk/www/changelog.html
          http://jenkins-ci.org/commit/28703
          Log:
          [FIXED JENKINS-2722] Fix editableComboBox to select item even when mouse click
          takes more than 100ms. (mousedown on item makes text field lose focus, which
          does a setTimeout to hide dropdown after 100ms.. it mouseup doesn't happen
          before this, onclick is never triggered. Now using onmousedown to immediately
          trigger select of item)

          SCM/JIRA link daemon added a comment - Code changed in hudson User: : mindless Path: trunk/hudson/main/war/resources/scripts/combobox.js trunk/www/changelog.html http://jenkins-ci.org/commit/28703 Log: [FIXED JENKINS-2722] Fix editableComboBox to select item even when mouse click takes more than 100ms. (mousedown on item makes text field lose focus, which does a setTimeout to hide dropdown after 100ms.. it mouseup doesn't happen before this, onclick is never triggered. Now using onmousedown to immediately trigger select of item)

          Code changed in hudson
          User: : mindless
          Path:
          http://jenkins-ci.org/commit/28704
          Log:
          JENKINS-2722 is fixed, so removing this branch.

          SCM/JIRA link daemon added a comment - Code changed in hudson User: : mindless Path: http://jenkins-ci.org/commit/28704 Log: JENKINS-2722 is fixed, so removing this branch.

            mindless Alan Harder
            sb110099 sb110099
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: