AW: Loading content of IFrames only when displayed

2013-10-24 Thread Christian Schröter
Now why didn't I think oft hat. Thank you Martin.

Maybe we can remove the final declaration in the next release (if there is no 
objections)

Cheers,

Christian

-Ursprüngliche Nachricht-
Von: Martin Grigorov [mailto:mgrigo...@apache.org] 
Gesendet: Montag, 21. Oktober 2013 10:18
An: users@wicket.apache.org
Betreff: Re: Loading content of IFrames only when displayed

Hi,

You can use custom Behavior that removes the 'url' attribute in its
#onComponentTag() and adds 'data-url' instead.
Component#onComponentTag() is executed before Behavior#onComponentTag() so it 
should work OK.


On Thu, Oct 17, 2013 at 5:29 PM, Christian Schröter  
christian.schroe...@1und1.de wrote:

 Hello,

 I'm using the InlineFrame class to display an IFrame. Now the IFrame 
 is added in a dialog prompt, which is not visible by default. The user 
 has to click a certain link to see the IFrame in the dialog prompt.

 Unfortunately the browser loads the URL defined in the source 
 attribute, no matter if the IFrame is visible or not. In my opinion, 
 it would be better to load the content only if the iframe is visible.

 A solution to achieve this goal is explained here:
 http://stackoverflow.com/**questions/13437091/is-it-**
 possible-to-not-load-an-**iframe-in-a-hidden-div-until-**
 the-div-is-displayedhttp://stackoverflow.com/questions/13437091/is-it
 -possible-to-not-load-an-iframe-in-a-hidden-div-until-the-div-is-displ
 ayed

 But for some reason the onComponentTag(ComonentTag tag) is declared 
 final in the InlineFrame class.
 I don't understand why the method is final and I'm a bit clueless how 
 to proceed.

 Hopefully someone can help me.

 Thanks,
 Christian



Re: Loading content of IFrames only when displayed

2013-10-24 Thread Martin Grigorov
https://issues.apache.org/jira/browse/WICKET-5393
Done


On Thu, Oct 24, 2013 at 5:08 PM, Christian Schröter 
christian.schroe...@1und1.de wrote:

 Now why didn't I think oft hat. Thank you Martin.

 Maybe we can remove the final declaration in the next release (if there is
 no objections)

 Cheers,

 Christian

 -Ursprüngliche Nachricht-
 Von: Martin Grigorov [mailto:mgrigo...@apache.org]
 Gesendet: Montag, 21. Oktober 2013 10:18
 An: users@wicket.apache.org
 Betreff: Re: Loading content of IFrames only when displayed

 Hi,

 You can use custom Behavior that removes the 'url' attribute in its
 #onComponentTag() and adds 'data-url' instead.
 Component#onComponentTag() is executed before Behavior#onComponentTag() so
 it should work OK.


 On Thu, Oct 17, 2013 at 5:29 PM, Christian Schröter 
 christian.schroe...@1und1.de wrote:

  Hello,
 
  I'm using the InlineFrame class to display an IFrame. Now the IFrame
  is added in a dialog prompt, which is not visible by default. The user
  has to click a certain link to see the IFrame in the dialog prompt.
 
  Unfortunately the browser loads the URL defined in the source
  attribute, no matter if the IFrame is visible or not. In my opinion,
  it would be better to load the content only if the iframe is visible.
 
  A solution to achieve this goal is explained here:
  http://stackoverflow.com/**questions/13437091/is-it-**
  possible-to-not-load-an-**iframe-in-a-hidden-div-until-**
  the-div-is-displayedhttp://stackoverflow.com/questions/13437091/is-it
  -possible-to-not-load-an-iframe-in-a-hidden-div-until-the-div-is-displ
  ayed
 
  But for some reason the onComponentTag(ComonentTag tag) is declared
  final in the InlineFrame class.
  I don't understand why the method is final and I'm a bit clueless how
  to proceed.
 
  Hopefully someone can help me.
 
  Thanks,
  Christian
 



Re: Loading content of IFrames only when displayed

2013-10-21 Thread Martin Grigorov
Hi,

You can use custom Behavior that removes the 'url' attribute in its
#onComponentTag() and adds 'data-url' instead.
Component#onComponentTag() is executed before Behavior#onComponentTag() so
it should work OK.


On Thu, Oct 17, 2013 at 5:29 PM, Christian Schröter 
christian.schroe...@1und1.de wrote:

 Hello,

 I'm using the InlineFrame class to display an IFrame. Now the IFrame is
 added in a dialog prompt, which is not visible by default. The user has to
 click a certain link to see the IFrame in the dialog prompt.

 Unfortunately the browser loads the URL defined in the source attribute,
 no matter if the IFrame is visible or not. In my opinion, it would be
 better to load the content only if the iframe is visible.

 A solution to achieve this goal is explained here:
 http://stackoverflow.com/**questions/13437091/is-it-**
 possible-to-not-load-an-**iframe-in-a-hidden-div-until-**
 the-div-is-displayedhttp://stackoverflow.com/questions/13437091/is-it-possible-to-not-load-an-iframe-in-a-hidden-div-until-the-div-is-displayed

 But for some reason the onComponentTag(ComonentTag tag) is declared final
 in the InlineFrame class.
 I don't understand why the method is final and I'm a bit clueless how to
 proceed.

 Hopefully someone can help me.

 Thanks,
 Christian



Loading content of IFrames only when displayed

2013-10-17 Thread Christian Schröter

Hello,

I'm using the InlineFrame class to display an IFrame. Now the IFrame is 
added in a dialog prompt, which is not visible by default. The user has 
to click a certain link to see the IFrame in the dialog prompt.


Unfortunately the browser loads the URL defined in the source attribute, 
no matter if the IFrame is visible or not. In my opinion, it would be 
better to load the content only if the iframe is visible.


A solution to achieve this goal is explained here: 
http://stackoverflow.com/questions/13437091/is-it-possible-to-not-load-an-iframe-in-a-hidden-div-until-the-div-is-displayed


But for some reason the onComponentTag(ComonentTag tag) is declared 
final in the InlineFrame class.
I don't understand why the method is final and I'm a bit clueless how to 
proceed.


Hopefully someone can help me.

Thanks,
Christian