Fix OP image expanding if there is not reply, fix #53
This commit is contained in:
parent
4949d707c4
commit
a683331a9e
@ -1999,10 +1999,11 @@
|
|||||||
foo: function() {
|
foo: function() {
|
||||||
var crap, formWidth, left, table, td;
|
var crap, formWidth, left, table, td;
|
||||||
formWidth = $('form[name=delform]').getBoundingClientRect().width;
|
formWidth = $('form[name=delform]').getBoundingClientRect().width;
|
||||||
td = $('td.reply');
|
if (td = $('td.reply')) {
|
||||||
table = td.parentNode.parentNode.parentNode;
|
table = td.parentNode.parentNode.parentNode;
|
||||||
left = td.getBoundingClientRect().left - table.getBoundingClientRect().left;
|
left = td.getBoundingClientRect().left - table.getBoundingClientRect().left;
|
||||||
crap = td.getBoundingClientRect().width - parseInt(getComputedStyle(td).width);
|
crap = td.getBoundingClientRect().width - parseInt(getComputedStyle(td).width);
|
||||||
|
}
|
||||||
imgExpand.maxWidthOP = formWidth;
|
imgExpand.maxWidthOP = formWidth;
|
||||||
imgExpand.maxWidthReply = formWidth - left - crap;
|
imgExpand.maxWidthReply = formWidth - left - crap;
|
||||||
imgExpand.maxHeight = d.body.clientHeight;
|
imgExpand.maxHeight = d.body.clientHeight;
|
||||||
|
|||||||
@ -1518,10 +1518,10 @@ imgExpand =
|
|||||||
|
|
||||||
foo: ->
|
foo: ->
|
||||||
formWidth = $('form[name=delform]').getBoundingClientRect().width
|
formWidth = $('form[name=delform]').getBoundingClientRect().width
|
||||||
td = $('td.reply')
|
if td = $('td.reply')
|
||||||
table = td.parentNode.parentNode.parentNode
|
table = td.parentNode.parentNode.parentNode
|
||||||
left = td.getBoundingClientRect().left - table.getBoundingClientRect().left
|
left = td.getBoundingClientRect().left - table.getBoundingClientRect().left
|
||||||
crap = td.getBoundingClientRect().width - parseInt(getComputedStyle(td).width)
|
crap = td.getBoundingClientRect().width - parseInt(getComputedStyle(td).width)
|
||||||
|
|
||||||
imgExpand.maxWidthOP = formWidth
|
imgExpand.maxWidthOP = formWidth
|
||||||
imgExpand.maxWidthReply = formWidth - left - crap
|
imgExpand.maxWidthReply = formWidth - left - crap
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user