You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by MYoung <gi...@gmail.com> on 2008/03/06 01:28:23 UTC
Why PopupCloseLink doesn't close my popup?
I must be doing it wrong. I have this in my popup template:
<a wicket:id="closeMe">Close</a>
In java:
add(new PopupCloseLink("closeMe") {
@Override public void onClick() {
// HERE HERE
}
});
onClick() is called but the popup window stays.
Another question, how to get notify when the popup is close by clicking on
the close box on the browser window's title bar?
--
View this message in context: http://www.nabble.com/Why-PopupCloseLink-doesn%27t-close-my-popup--tp15863742p15863742.html
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Why PopupCloseLink doesn't close my popup?
Posted by Gin Yeah <gi...@gmail.com>.
Ok, I got it. I need to call super.onClick(). Thanks!
On Wed, Mar 5, 2008 at 10:22 PM, Igor Vaynberg <ig...@gmail.com>
wrote:
> ok, but do you see javascript errors after you press the link? because
> that outputs a window.close() javascript to close the window...
>
> -igor
>
>
> On Wed, Mar 5, 2008 at 9:03 PM, Gin Yeah <gi...@gmail.com> wrote:
> > There is no Javascript generated at the browser end at all:
> >
> > <a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
> > wicket:id="closeLink">Close</a>
> >
> > The popup is open with this:
> >
> > Java:
> >
> > PopupSettings ps = new PopupSettings()
> > .setHeight(200)
> > .setWidth(100)
> > .setTop(50)
> > .setLeft(200)
> > .setWindowName("Salumonunu");
> >
> > add(new PageLink("popupPageLink", AnotherPage.class
> > ).setPopupSettings(ps));
> >
> > html:
> >
> > <li><a wicket:id="popupPageLink">Popup another page</a></li>
> >
> >
> > AnotherPage.java:
> >
> > public class AnotherPage extends ExtendFromBasePage {
> > private static final long serialVersionUID = 1L;
> > public AnotherPage() {
> > add(new PopupCloseLink("closeLink") {
> > private static final long serialVersionUID = 1L;
> > @Override public void onClick() {
> > System.out.println("HERE HERE HERE");
> > }
> > });
> > }
> >
> >
> >
> > AnotherPage.html:
> >
> > <html>
> > <a wicket:id="closeLink">Close</a>
> > </html>
> >
> >
> >
> > The generated code in the browser:
> >
> > <a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
> > wicket:id="closeLink">Close</a>
> >
> >
> >
> >
> >
> > On Wed, Mar 5, 2008 at 5:37 PM, Igor Vaynberg <ig...@gmail.com>
> > wrote:
> >
> >
> >
> > > any javascript errors in your browser? is the popupcloselink inside
> > > the popup window - which is another window that is NOT a modal
> > > window...?
> > >
> > > -igor
> > >
> > >
> > > On Wed, Mar 5, 2008 at 4:28 PM, MYoung <gi...@gmail.com> wrote:
> > > >
> > > > I must be doing it wrong. I have this in my popup template:
> > > >
> > > > <a wicket:id="closeMe">Close</a>
> > > >
> > > >
> > > > In java:
> > > >
> > > > add(new PopupCloseLink("closeMe") {
> > > > @Override public void onClick() {
> > > > // HERE HERE
> > > > }
> > > > });
> > > >
> > > > onClick() is called but the popup window stays.
> > > >
> > > > Another question, how to get notify when the popup is close by
> > > clicking on
> > > > the close box on the browser window's title bar?
> > > > --
> > > > View this message in context:
> > >
> http://www.nabble.com/Why-PopupCloseLink-doesn%27t-close-my-popup--tp15863742p15863742.html
> > > > Sent from the Wicket - User mailing list archive at Nabble.com.
> > > >
> > > >
> > > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > > > For additional commands, e-mail: users-help@wicket.apache.org
> > > >
> > > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > > For additional commands, e-mail: users-help@wicket.apache.org
> > >
> > >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
Re: Why PopupCloseLink doesn't close my popup?
Posted by Gin Yeah <gi...@gmail.com>.
How to see Javascript error? Something to turn on in the browser?
On Wed, Mar 5, 2008 at 10:22 PM, Igor Vaynberg <ig...@gmail.com>
wrote:
> ok, but do you see javascript errors after you press the link? because
> that outputs a window.close() javascript to close the window...
>
> -igor
>
>
> On Wed, Mar 5, 2008 at 9:03 PM, Gin Yeah <gi...@gmail.com> wrote:
> > There is no Javascript generated at the browser end at all:
> >
> > <a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
> > wicket:id="closeLink">Close</a>
> >
> > The popup is open with this:
> >
> > Java:
> >
> > PopupSettings ps = new PopupSettings()
> > .setHeight(200)
> > .setWidth(100)
> > .setTop(50)
> > .setLeft(200)
> > .setWindowName("Salumonunu");
> >
> > add(new PageLink("popupPageLink", AnotherPage.class
> > ).setPopupSettings(ps));
> >
> > html:
> >
> > <li><a wicket:id="popupPageLink">Popup another page</a></li>
> >
> >
> > AnotherPage.java:
> >
> > public class AnotherPage extends ExtendFromBasePage {
> > private static final long serialVersionUID = 1L;
> > public AnotherPage() {
> > add(new PopupCloseLink("closeLink") {
> > private static final long serialVersionUID = 1L;
> > @Override public void onClick() {
> > System.out.println("HERE HERE HERE");
> > }
> > });
> > }
> >
> >
> >
> > AnotherPage.html:
> >
> > <html>
> > <a wicket:id="closeLink">Close</a>
> > </html>
> >
> >
> >
> > The generated code in the browser:
> >
> > <a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
> > wicket:id="closeLink">Close</a>
> >
> >
> >
> >
> >
> > On Wed, Mar 5, 2008 at 5:37 PM, Igor Vaynberg <ig...@gmail.com>
> > wrote:
> >
> >
> >
> > > any javascript errors in your browser? is the popupcloselink inside
> > > the popup window - which is another window that is NOT a modal
> > > window...?
> > >
> > > -igor
> > >
> > >
> > > On Wed, Mar 5, 2008 at 4:28 PM, MYoung <gi...@gmail.com> wrote:
> > > >
> > > > I must be doing it wrong. I have this in my popup template:
> > > >
> > > > <a wicket:id="closeMe">Close</a>
> > > >
> > > >
> > > > In java:
> > > >
> > > > add(new PopupCloseLink("closeMe") {
> > > > @Override public void onClick() {
> > > > // HERE HERE
> > > > }
> > > > });
> > > >
> > > > onClick() is called but the popup window stays.
> > > >
> > > > Another question, how to get notify when the popup is close by
> > > clicking on
> > > > the close box on the browser window's title bar?
> > > > --
> > > > View this message in context:
> > >
> http://www.nabble.com/Why-PopupCloseLink-doesn%27t-close-my-popup--tp15863742p15863742.html
> > > > Sent from the Wicket - User mailing list archive at Nabble.com.
> > > >
> > > >
> > > >
> ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > > > For additional commands, e-mail: users-help@wicket.apache.org
> > > >
> > > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > > For additional commands, e-mail: users-help@wicket.apache.org
> > >
> > >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
Re: Why PopupCloseLink doesn't close my popup?
Posted by Igor Vaynberg <ig...@gmail.com>.
ok, but do you see javascript errors after you press the link? because
that outputs a window.close() javascript to close the window...
-igor
On Wed, Mar 5, 2008 at 9:03 PM, Gin Yeah <gi...@gmail.com> wrote:
> There is no Javascript generated at the browser end at all:
>
> <a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
> wicket:id="closeLink">Close</a>
>
> The popup is open with this:
>
> Java:
>
> PopupSettings ps = new PopupSettings()
> .setHeight(200)
> .setWidth(100)
> .setTop(50)
> .setLeft(200)
> .setWindowName("Salumonunu");
>
> add(new PageLink("popupPageLink", AnotherPage.class
> ).setPopupSettings(ps));
>
> html:
>
> <li><a wicket:id="popupPageLink">Popup another page</a></li>
>
>
> AnotherPage.java:
>
> public class AnotherPage extends ExtendFromBasePage {
> private static final long serialVersionUID = 1L;
> public AnotherPage() {
> add(new PopupCloseLink("closeLink") {
> private static final long serialVersionUID = 1L;
> @Override public void onClick() {
> System.out.println("HERE HERE HERE");
> }
> });
> }
>
>
>
> AnotherPage.html:
>
> <html>
> <a wicket:id="closeLink">Close</a>
> </html>
>
>
>
> The generated code in the browser:
>
> <a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
> wicket:id="closeLink">Close</a>
>
>
>
>
>
> On Wed, Mar 5, 2008 at 5:37 PM, Igor Vaynberg <ig...@gmail.com>
> wrote:
>
>
>
> > any javascript errors in your browser? is the popupcloselink inside
> > the popup window - which is another window that is NOT a modal
> > window...?
> >
> > -igor
> >
> >
> > On Wed, Mar 5, 2008 at 4:28 PM, MYoung <gi...@gmail.com> wrote:
> > >
> > > I must be doing it wrong. I have this in my popup template:
> > >
> > > <a wicket:id="closeMe">Close</a>
> > >
> > >
> > > In java:
> > >
> > > add(new PopupCloseLink("closeMe") {
> > > @Override public void onClick() {
> > > // HERE HERE
> > > }
> > > });
> > >
> > > onClick() is called but the popup window stays.
> > >
> > > Another question, how to get notify when the popup is close by
> > clicking on
> > > the close box on the browser window's title bar?
> > > --
> > > View this message in context:
> > http://www.nabble.com/Why-PopupCloseLink-doesn%27t-close-my-popup--tp15863742p15863742.html
> > > Sent from the Wicket - User mailing list archive at Nabble.com.
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > > For additional commands, e-mail: users-help@wicket.apache.org
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > For additional commands, e-mail: users-help@wicket.apache.org
> >
> >
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org
Re: Why PopupCloseLink doesn't close my popup?
Posted by Gin Yeah <gi...@gmail.com>.
There is no Javascript generated at the browser end at all:
<a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
wicket:id="closeLink">Close</a>
The popup is open with this:
Java:
PopupSettings ps = new PopupSettings()
.setHeight(200)
.setWidth(100)
.setTop(50)
.setLeft(200)
.setWindowName("Salumonunu");
add(new PageLink("popupPageLink", AnotherPage.class
).setPopupSettings(ps));
html:
<li><a wicket:id="popupPageLink">Popup another page</a></li>
AnotherPage.java:
public class AnotherPage extends ExtendFromBasePage {
private static final long serialVersionUID = 1L;
public AnotherPage() {
add(new PopupCloseLink("closeLink") {
private static final long serialVersionUID = 1L;
@Override public void onClick() {
System.out.println("HERE HERE HERE");
}
});
}
AnotherPage.html:
<html>
<a wicket:id="closeLink">Close</a>
</html>
The generated code in the browser:
<a href="?wicket:interface=Salumonunu:0:closeLink::ILinkListener::"
wicket:id="closeLink">Close</a>
On Wed, Mar 5, 2008 at 5:37 PM, Igor Vaynberg <ig...@gmail.com>
wrote:
> any javascript errors in your browser? is the popupcloselink inside
> the popup window - which is another window that is NOT a modal
> window...?
>
> -igor
>
>
> On Wed, Mar 5, 2008 at 4:28 PM, MYoung <gi...@gmail.com> wrote:
> >
> > I must be doing it wrong. I have this in my popup template:
> >
> > <a wicket:id="closeMe">Close</a>
> >
> >
> > In java:
> >
> > add(new PopupCloseLink("closeMe") {
> > @Override public void onClick() {
> > // HERE HERE
> > }
> > });
> >
> > onClick() is called but the popup window stays.
> >
> > Another question, how to get notify when the popup is close by
> clicking on
> > the close box on the browser window's title bar?
> > --
> > View this message in context:
> http://www.nabble.com/Why-PopupCloseLink-doesn%27t-close-my-popup--tp15863742p15863742.html
> > Sent from the Wicket - User mailing list archive at Nabble.com.
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> > For additional commands, e-mail: users-help@wicket.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
Re: Why PopupCloseLink doesn't close my popup?
Posted by Igor Vaynberg <ig...@gmail.com>.
any javascript errors in your browser? is the popupcloselink inside
the popup window - which is another window that is NOT a modal
window...?
-igor
On Wed, Mar 5, 2008 at 4:28 PM, MYoung <gi...@gmail.com> wrote:
>
> I must be doing it wrong. I have this in my popup template:
>
> <a wicket:id="closeMe">Close</a>
>
>
> In java:
>
> add(new PopupCloseLink("closeMe") {
> @Override public void onClick() {
> // HERE HERE
> }
> });
>
> onClick() is called but the popup window stays.
>
> Another question, how to get notify when the popup is close by clicking on
> the close box on the browser window's title bar?
> --
> View this message in context: http://www.nabble.com/Why-PopupCloseLink-doesn%27t-close-my-popup--tp15863742p15863742.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org