[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-15 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16650956#comment-16650956
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon closed the pull request at:

https://github.com/apache/wicket/pull/294


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Assignee: Sven Meier
>Priority: Minor
>  Labels: javascript, modalwindow
> Fix For: 8.2.0
>
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-15 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16650852#comment-16650852
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user svenmeier commented on the issue:

https://github.com/apache/wicket/pull/294
  
I've fixed WICKET-5552, please open a new pull request if you think 
ModalWindow is in need of further extensibility.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Assignee: Sven Meier
>Priority: Minor
>  Labels: javascript, modalwindow
> Fix For: 8.2.0
>
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-15 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16650837#comment-16650837
 ] 

ASF subversion and git services commented on WICKET-5552:
-

Commit ace845c412d6ea3117c6f366d9bd91b06c6270da in wicket's branch 
refs/heads/master from [~svenmeier]
[ https://git-wip-us.apache.org/repos/asf?p=wicket.git;h=ace845c ]

WICKET-5552 allow prevention of drags

used by ModalWindow to prevent dragging on window content

> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Assignee: Sven Meier
>Priority: Minor
>  Labels: javascript, modalwindow
> Fix For: 8.2.0
>
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-15 Thread ASF subversion and git services (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16650825#comment-16650825
 ] 

ASF subversion and git services commented on WICKET-5552:
-

Commit 03412f18eeab8954cc60f5532585993ae1f012d0 in wicket's branch 
refs/heads/wicket-8.x from [~svenmeier]
[ https://git-wip-us.apache.org/repos/asf?p=wicket.git;h=03412f1 ]

WICKET-5552 allow prevention of drags

used by ModalWindow to prevent dragging on window content

> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Minor
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-13 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16649055#comment-16649055
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user svenmeier commented on the issue:

https://github.com/apache/wicket/pull/294
  
It is used by ModalWindow and the Ajax debug console only - if we can agree 
to remove the latter (has been discussed a few years already), we can just move 
the code to modal.js
But that's a separate discussion.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Minor
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-12 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16648566#comment-16648566
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on the issue:

https://github.com/apache/wicket/pull/294
  
@svenmeier Do you plan to completely remove the drag handling from 
wicket-ajax or just to allow the modal.js control it by itself?


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Minor
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-12 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16648519#comment-16648519
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user svenmeier commented on the issue:

https://github.com/apache/wicket/pull/294
  
I'm still not happy about the change :/.

Note that for Wicket 9 I want to move all Drag-handling from wicket-ajax to 
modal.js - we don't need it really in the former and for modal we'll have it 
easier to adjust it.

For now we could allow the start handler to veto the drag:

```
diff --git 
a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js 
b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
index 18ab6bd..e71b4e8 100644
--- 
a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
+++ 
b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
@@ -2476,14 +2476,16 @@
 
var element = this;
 
+   if (element.wicketOnDragBegin(element, e) === 
false) {
+   return;
+   }
+
Wicket.Event.stop(e);
 
if (e.preventDefault) {
e.preventDefault();
}
 
-   element.wicketOnDragBegin(element);
-
element.lastMouseX = e.clientX;
element.lastMouseY = e.clientY;
 
diff --git 
a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
 
b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
index b00ceec..6d63807 100644
--- 
a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
+++ 
b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
@@ -901,7 +901,12 @@
/**
 * Called when dragging has started.
 */
-   onBegin: function(object) {
+   onBegin: function(element, event) {
+   // ignore anything inside the content
+   if (jQuery(event.target).closest('.w_content_2').size() 
) {
+   return false;
+   }
+   
if (this.isIframe() && (Wicket.Browser.isGecko() || 
Wicket.Browser.isIELessThan11() || Wicket.Browser.isSafari())) {
this.revertList = [];
Wicket.Iframe.documentFix(document, 
this.revertList);
@@ -1183,7 +1188,7 @@
""+
""+
""+
-   ""+
+   ""+
""+

""+

""+

```


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Minor
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been 

[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-12 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16648443#comment-16648443
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on the issue:

https://github.com/apache/wicket/pull/294
  
Shoud I create a new PR without a ticket name or rewording commit is enough?


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 7.10.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Minor
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-11 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16646990#comment-16646990
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on the issue:

https://github.com/apache/wicket/pull/294
  
@svenmeier it still exists in 7, 8 and in 9 snapshot. Are there jiras for 
appropriate versions? Didn't find them.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-11 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16646862#comment-16646862
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user svenmeier commented on the issue:

https://github.com/apache/wicket/pull/294
  
Ha, that's really some crufty code :)

Just noticed that you filed the issue for Wicket 6.x - note that we will 
only apply security fixes for that version.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-10 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16645740#comment-16645740
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on the issue:

https://github.com/apache/wicket/pull/294
  
@svenmeier sure, it was the first thing I tried. Unfortunately it prevents 
the w_captionText of the popup from working as a drag area, which I think is 
undesired effect.

Potentially can be done as something like `e.target !== this && 
e.target.className.indexOf('w_captionText') == -1`, but it makes the 
mouseDownHandler know about css classes of modal so I think the approach with 
some general stopper class is more universal.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-10 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16645346#comment-16645346
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user svenmeier commented on the issue:

https://github.com/apache/wicket/pull/294
  
Why so complicated - I've fixed the issue by removing the mouse blocker 
from modal.js and restricting any dragging on the element itself:

```
diff --git 
a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js 
b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
index 64852de..8d94b36 100644
--- 
a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
+++ 
b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
@@ -2485,6 +2485,10 @@
 
mouseDownHandler: function (e) {
e = Wicket.Event.fix(e);
+   
+   if (e.target !== this) {
+   return;
+   }
 
var element = this;
 
diff --git 
a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
 
b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
index f683119..5a0f122 100644
--- 
a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
+++ 
b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/modal/res/modal.js
@@ -1189,7 +1189,7 @@
""+
""+
""+
-   ""+
+   ""+
""+

""+

""+
```
Can you try that instead?


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-10-08 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16642682#comment-16642682
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on the issue:

https://github.com/apache/wicket/pull/294
  
Is there anything else I should rework here?


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-09-26 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16628304#comment-16628304
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on the issue:

https://github.com/apache/wicket/pull/294
  
Updated with typeof object check.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-09-25 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16628260#comment-16628260
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user andruhon commented on a diff in the pull request:

https://github.com/apache/wicket/pull/294#discussion_r220427102
  
--- Diff: 
wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js 
---
@@ -2301,6 +2302,10 @@
onDrag = jQuery.noop;
}
 
+   if (typeof(settings) !== "undefined" && 
settings.stopDragOnCssSelector) {
--- End diff --

True. I'll change it to === 'object'. Will check that it still works and 
push.


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-09-25 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16628259#comment-16628259
 ] 

ASF GitHub Bot commented on WICKET-5552:


Github user solomax commented on a diff in the pull request:

https://github.com/apache/wicket/pull/294#discussion_r220426844
  
--- Diff: 
wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js 
---
@@ -2301,6 +2302,10 @@
onDrag = jQuery.noop;
}
 
+   if (typeof(settings) !== "undefined" && 
settings.stopDragOnCssSelector) {
--- End diff --

According to the code `settings` should be `object`
Maybe it would be better to change this line to be
`typeof(settings) === 'object'` ?


> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2018-09-25 Thread ASF GitHub Bot (JIRA)


[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16628211#comment-16628211
 ] 

ASF GitHub Bot commented on WICKET-5552:


GitHub user andruhon opened a pull request:

https://github.com/apache/wicket/pull/294

WICKET-5552 fix modal mousedown and make modal more extendable

Demo to reproduce the issue 
https://github.com/andruhon/wicket-modal-mousedown-issue

Demo using 9.0.0-SNAPSHOT from maven local to demonstrate the fix:

https://github.com/andruhon/wicket-modal-mousedown-issue/tree/fix-WICKET-5552

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/andruhon/wicket 
WICKET-5552-fix-modal-mousedown-and-make-it-more-extendable

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/wicket/pull/294.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #294


commit 3adf1b5144b5948c45100129c6279fa183d85420
Author: Andrew Kondratev 
Date:   2018-09-26T02:58:11Z

WICKET-5552 fix modal mousedown and make it more extendable




> Events to close pop-up on Modal Window are not propagated
> -
>
> Key: WICKET-5552
> URL: https://issues.apache.org/jira/browse/WICKET-5552
> Project: Wicket
>  Issue Type: Bug
>  Components: wicket-extensions
>Affects Versions: 6.14.0
> Environment: Windows/Eclipse/JRE7
>Reporter: Neil Bennett
>Priority: Major
>  Labels: javascript, modalwindow
> Attachments: quickstart.zip
>
>
> When using a field on a modal window that shows a pop-up window, like a time 
> picker, when clicking outside of the pop-up window but over the modal window, 
> mousedown/click events are not propagated. Clicks outside of the modal window 
> are propagated.
> This is due to Wicket.Event.stop(event) being called on mousedown on the 
> w_content_1 component. Removal of this leads to the Drag javascript being 
> executed which itself calls Wicket.Event.stop(event), disabling this then 
> propagates the event which leads to the pop-up window being closed but causes 
> any field on the modalwindow to get focus.
> I have a quickstart that demonstrates the modalwindow behavior vs that on a 
> page. You will see that launching the modal window and clicking on the time 
> component opens the pop-up window. However, you can only get this to close 
> when clicking outside of the modal window. The same component has been put on 
> the main page as a comparison which does close when clicking outside of the 
> pop-up window.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (WICKET-5552) Events to close pop-up on Modal Window are not propagated

2014-04-22 Thread Martin Grigorov (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-5552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13976852#comment-13976852
 ] 

Martin Grigorov commented on WICKET-5552:
-

Removing Wicket.Event.stop(event) or return false from 
Wicket.Drag.mouseDownHandler() breaks the dragging behavior.
To reproduce it just use wicket-examples  ajax  modal window  with a page.

 Events to close pop-up on Modal Window are not propagated
 -

 Key: WICKET-5552
 URL: https://issues.apache.org/jira/browse/WICKET-5552
 Project: Wicket
  Issue Type: Bug
  Components: wicket-extensions
Affects Versions: 6.14.0
 Environment: Windows/Eclipse/JRE7
Reporter: Neil Bennett
  Labels: javascript, modalwindow
 Attachments: quickstart.zip


 When using a field on a modal window that shows a pop-up window, like a time 
 picker, when clicking outside of the pop-up window but over the modal window, 
 mousedown/click events are not propagated. Clicks outside of the modal window 
 are propagated.
 This is due to Wicket.Event.stop(event) being called on mousedown on the 
 w_content_1 component. Removal of this leads to the Drag javascript being 
 executed which itself calls Wicket.Event.stop(event), disabling this then 
 propagates the event which leads to the pop-up window being closed but causes 
 any field on the modalwindow to get focus.
 I have a quickstart that demonstrates the modalwindow behavior vs that on a 
 page. You will see that launching the modal window and clicking on the time 
 component opens the pop-up window. However, you can only get this to close 
 when clicking outside of the modal window. The same component has been put on 
 the main page as a comparison which does close when clicking outside of the 
 pop-up window.



--
This message was sent by Atlassian JIRA
(v6.2#6252)