| 429 | | // determine the size (did I mention that IE stinks?) |
| 430 | | var foobar = document.createElement("div"); |
| 431 | | foobar.className = "htmlarea-context-menu"; |
| 432 | | foobar.innerHTML = div.innerHTML; |
| 433 | | document.body.appendChild(foobar); |
| 434 | | var w = foobar.offsetWidth; |
| 435 | | var h = foobar.offsetHeight; |
| 436 | | document.body.removeChild(foobar); |
| | 429 | // To get the size we need to display the popup with some width/height |
| | 430 | // then we can get the actual size of the div and redisplay the popup at the |
| | 431 | // correct dimensions. |
| | 432 | this.iePopup.show(ev.screenX, ev.screenY, 300,50); |
| | 433 | var w = div.offsetWidth; |
| | 434 | var h = div.offsetHeight; |