Loading...

          java .net

          Gwt 中為加載中的Frame加上wait(二)


          private void showWaitMess(Frame window){
              final MessageBox box = MessageBox.wait("等待", "正在查詢數據,請稍后...", "查詢中...");
              final Element frame = window.getElement();
              final Timer t = new Timer() {
                  @Override
                  public void run() {
                      if (ready(frame)) {
                          this.cancel();
                          box.close();
                      }
                  }
              };
              t.scheduleRepeating(100);
          }
          private native boolean ready(Element frame)/*-{
              return frame.contentWindow.document.readyState=="complete";
          }-*/;

          posted on 2010-05-19 10:15 閱讀(312) 評論(0)  編輯  收藏 所屬分類: jsgwt

          公告

          希望有一天

          我能用鼠標雙擊我的錢包

          然后選中一張100元

          按住“ctrl+c”

          接著不停的“ctrl+v”

          嘻嘻~~~笑醒~~~



          導航

          <2010年5月>
          2526272829301
          2345678
          9101112131415
          16171819202122
          23242526272829
          303112345

          統計

          常用鏈接

          留言簿(6)

          隨筆分類(102)

          隨筆檔案(398)

          文章分類

          文章檔案(10)

          有趣網絡

          搜索

          積分與排名

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 河北区| 定西市| 始兴县| 谷城县| 宜城市| 沾化县| 景洪市| 石渠县| 汉阴县| 湟中县| 福贡县| 沙河市| 弋阳县| 济宁市| 咸宁市| 广汉市| 上杭县| 衡水市| 磐石市| 镶黄旗| 富民县| 高密市| 嘉义县| 雅江县| 北票市| 新兴县| 海林市| 旺苍县| 海伦市| 五指山市| 新巴尔虎右旗| 苏尼特左旗| 界首市| 昌宁县| 甘谷县| 万荣县| 云霄县| 平阳县| 余江县| 万宁市| 青川县|