window.open的时间问题?

时间:2014-10-27 15:51:54

标签: javascript

我有以下代码:

var WindowObject = window.open("/cur/cases-c-print", "PrintWindow");
WindowObject.SettingsStore = SettingsStore; 

但是,在WindowObject的init()中,它需要具有SettingsStore。我相信以下情况正在发生:

  1. 窗口打开,并初始化
  2. 设置了SettingsStore(我们此时已经太晚了)
  3. 相反,我需要做类似的事情:

    var WindowObject = new window("/cur/cases-c-print", "PrintWindow");
    WindowObject.SettingsStore = SettingsStore; 
    WindowObject.open();
    

    OR

    var WindowObject = window.open("/cur/cases-c-print", "PrintWindow", SettingsStore);
    

    这可能吗?

0 个答案:

没有答案