0

Window display with applet

asked 2008-05-30 17:03:33 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=4996901

By: lyndacarey

I have a zk page comprised of several windows. One window is a simple grid display of live data. The other window contains an applet. The issue is that any window that pops up from the page, does not display properly over the applet.
The popups look fine and behave properly if they popup over the grid display, but for some reason are not properly rendered over top of the applet.

Any ideas what I can do to fix this behavior?

delete flag offensive retag edit

10 Replies

Sort by » oldest newest

answered 2008-06-03 03:33:17 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5003833

By: waterbottle

Hi, could you provide some screen shoot?


link publish delete flag offensive edit

answered 2008-06-10 22:06:39 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5021847

By: sekrup

Hi,

I am using ZK 3.0.5 and I am experiencing the same thing.

Please see the picture here:

http://members.shaw.ca/sekrup/popup_applet_overlap.JPG

The cat picture is actually a Java applet loaded with java.awt.Image.
The "popup" is actually a ZK window popped-up using doOverlapped(). I am attaching the window's zul file.

As you can see, the window is shown "behind" the applet except the listbox, which is "on top" of the applet.


Any help/hint is greatly appreciated;


Thanks,
sekrup

----------------------------
POPUP WINDOW ZUL FILE:
----------------------------

<zk>
<window d="printWin" border="normal" width="370px" position="center"
xmlns:h="http://www.w3.org/1999/xhtml" closable="true">
<vbox>
<label value="Drag and drop here:"></label>
<listbox id="testlistbox" width="350px" height="100px" droppable="true"
onDrop="someEvent()">
</listbox>
<hbox>
<button label="Print"></button>
<button label="Close"></button>
</hbox>
</vbox>
</window>
</zk>

----------------------------



link publish delete flag offensive edit

answered 2008-06-11 08:01:56 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5022688

By: waterbottle

ZK doesn't process applet when a float component over on it.

I don't have applect to try,
could give following step a try, might be it works.

1.add a script
<script>
zk._actg1 = ["IFRAME","EMBED","APPLET"];
</script>
2.add z.autohide="true" in your APPLET tag.

if it success, then , when a window over the APPLET, the APPLET will be hidden.

link publish delete flag offensive edit

answered 2008-06-11 22:47:20 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5024838

By: sekrup

Hi Dennis,

Hmm.. I tried those but it's still overlapping.. This is what I did:


<vbox> <!-- some zk vbox -->
<n:html xmlns:n="http://www.zkoss.org/2005/zk/native"> <n:title>Applet
Title</n:title>
<n:script type="text/javascript">zk._actg1 = ["IFRAME","EMBED","APPLET"];</n:script>
<n:applet codebase="applets" code="Test.class" width="330" height="530"
z.autohide="true">
<n:param name="image_file" value="applets/picture.jpg"/> </n:applet> </n:html> </vbox>


Am I missing something or maybe we need another way to do this?

Thanks,
sekrup

link publish delete flag offensive edit

answered 2008-06-12 06:32:51 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5025493

By: waterbottle

you don't need to use native prefix(n:) at script tag.
use zul script component to override zk._actg1

link publish delete flag offensive edit

answered 2008-06-12 19:43:08 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5027356

By: sekrup

Hi Dennis,

Thanks! It worked! :)

cheers~
sekrup


-------------
For future references only/other people that had the same problem; this is what I did:
-------------
1. Added script:

<script type="text/javascript">zk._actg1 = ["IFRAME","EMBED","APPLET"];</script>

somewhere in my main .zul file

2. Added attribute z.autohide="true" in my <applet> tag

The result:
Whenever there is zk popup window over an applet, the applet will be hidden.
When window is dragged around so that it's not on top of the applet, the applet is redrawn again.

Tags: (for searching)
popup applet pop-up overlap

link publish delete flag offensive edit

answered 2008-06-13 03:09:32 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5028007

By: henrichen

Hi sekrup,

Would you write the final solution in ZK's How-TO wiki? The community will appreciate it very mcuh. It is even better if you would like to write an article about the issues regarding embedding applet in ZK application. We will be more than happy to publish it on our web site. If you are interested, please contact robbiecheng AT zkoss.org when your article is done. Thanks.

The How-TO wiki: http://en.wikibooks.org/wiki/ZK/How-Tos
/henri

link publish delete flag offensive edit

answered 2008-06-13 15:48:54 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5029524

By: sekrup

Hi Henri,

Sure, why not? I can do it during my free time; and I'd be happy to contribute too. :)

cheers~
sekrup


link publish delete flag offensive edit

answered 2008-06-14 09:57:34 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=5031037

By: henrichen

Thanks. Looking forward to your article.

/henri

link publish delete flag offensive edit

answered 2008-11-11 11:34:29 +0800

lavillorar gravatar image lavillorar
31 1

hi all, I do this but It doesn´t work. My code is :

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script type="text/javascript">
zk._actg1 = ["IFRAME","EMBED","APPLET"];
</script>
</head>
<body>
<applet name="player" class="avapplet" z.autohide="true" codebase="anything"/>
...

any idea?

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2008-05-30 17:03:33 +0800

Seen: 393 times

Last updated: Nov 11 '08

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More