javazk+;Javascript JQuery Galleria IO全屏模式

javazk+;Javascript JQuery Galleria IO全屏模式,java,javascript,jquery,zk,galleria,Java,Javascript,Jquery,Zk,Galleria,我正在使用Galleria的JavaScript插件,我需要在全屏模式下显示图像我已经检查了API,并且有了一个方法 .enterFullscreen( [callback] ) returns Galleria This will set the gallery in fullscreen mode. It will temporary manipulate some document styles and blow up the gallery to cover the browser s

我正在使用Galleria的JavaScript插件,我需要在
全屏模式下显示图像
我已经检查了
API
,并且有了一个方法

.enterFullscreen( [callback] )
returns Galleria
This will set the gallery in fullscreen mode. It will temporary manipulate some document  styles and blow up the gallery to cover the browser screen. Note that it will only fill the browser window, not the client screen (javascript can’t do that).

我正在使用
ZK框架
响应使用此代码的按钮单击

public void imageZoomer()
{
        Clients.evalJavaScript("$('#galleria').data('galleria').enterFullscreen(function() {alert('full screen mode');})");     
}
但是什么都没发生我也试过用

Clients.evalJavaScript("imageZoomer()"); 
还有一个像这样的
javascript
函数

function imageZoomer()
{
alert('before');
$('#galleria').data('galleria').enterFullscreen(function(){alert('full screen mode');})
alert('after');
}
调用了上面的函数,但没有发生任何事情,但如果在firebug控制台上尝试此代码

$('#galleria').data('galleria').enterFullscreen(function(){alert('full screen mode');})

它工作顺利,我做错了,非常感谢。

最后,我可以使用ZK中的
xmhtml
按钮解决我的问题,并使用JQuery响应
onClick
事件。我无法使用
ZK按钮解决我的问题。这是我的代码,希望我真的能帮助一些人

<div xmlns:h="xhtml">
   <h:button onclick="$('#galleria').data('galleria').toggleFullscreen();">Full Screen.          </h:button>
</div>

全屏。
致以最良好的祝愿