Hi Simon !
Calling repaintEverything() does not seem to have any effect
whatsoever...
My test results so far:
Internet Explorer 11 (Win8)��� Lines are drawn correctly��� ��� ���
�� �� ��� ��� ��� ��� ��� � ��� ��� ���� (PASS)
Internet Explorer 11 (Win7)��� All lines are drawn from a top left
corner point�� ��� ��� ���� (FAIL)
Firefox 26 (Win7)��� ��� ��� ��� ��� � All lines are drawn from a
top left corner point�� �� ��� ��� � (FAIL)
Safari 5.1 (Win7)��� ��� ��� ��� ��� �� All lines are drawn from a
top left corner point��� ��� ��� ��� (FAIL)
Chrome 31 (Win8)��� ��� ��� ��� ��� Lines are drawn correctly��� ���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� (PASS)
iOS 7��� ��� ��� ��� ��� ��� ��� ��� ��� ��� �� All lines are drawn
from a top left corner point��� ��� ��� � (FAIL)
Android 4.2.2 Stock Browser�� Lines are drawn correctly on second
play only�� ��� ���� ��� (FAIL)
Chome for Android��� ��� ��� ��� �� Lines are drawn correctly��� ���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� �� (PASS)
Firefox for Android��� ��� ��� ��� ��� All lines are drawn from a
top left corner point��� ��� � ��� (FAIL)
Chrome 32 (Win7)��� ��� ��� ���� ��� All lines are drawn from a top
left corner point��� ��� ��� � (FAIL)
Firefox 26 (Win8)��� ��� ��� ��� ��� �� Lines are drawn correctly���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� �� � � (PASS)
I don't know what to conclude from these results. It appears that
some common library (SVG? )
contains some kind of bug in my Win7 ???
This is the function that calls connect():
function draw_arrows() {
������� setTimeout(
��������������� function()
��������������� {
����������������������� $('.pin_outer_question').each(function()
����������������������� {
������������������������������� var answer = $(this).attr('id');
������������������������������� var varName���� = "sta" + answer;
������������������������������� this[varName] =
jsPlumb.getInstance();
������������������������������� var url =
window.location.toString();
������������������������������� var frameid =
parent.getUrlParts(url)['frameid'];
������������������������������� var zoom =
parent.gamemanager_getZoomFactor(document, frameid);
������������������������������� this[varName].setZoom( zoom );���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
// Don't know if this has side effects
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
��� ��� ��� ��� ��� ��� // It is used since the IFRAME containing
the game has its contents
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
��� ��� ��� ��� ��� ��� // scaled to fit the screen dimensions
(using CSS3 scale() )
������������������������������� this[varName].connect(
������������������������������� {
��������������������������������������� source:answer,��� ��� ���
��� �� �� ��� �� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
��� ��� ��� // The source is an absolutely positioned div containing
an image
��������������������������������������� target:'answer_'+answer,���
��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ��� ���
��� // The target is an absolutely posited div contain an image
���������������������������������������
paintStyle:{lineWidth:2,strokeStyle:'rgb(255,255,255)'},
��������������������������������������� maxConnections: 1,
��������������������������������������� anchor:[ 0.5, 0.89, 0, 1 ],
��������������������������������������� endpointStyle:{radius:1},
��������������������������������������� container: "div_questions",
��������������������������������������� connector:"Straight",
��������������������������������������� overlays:[["PlainArrow",
{location:0.999999, width:5, length:3} ]],
������������������������������� });
����������������������� });
����������������������� //ajax_load_answers();
�����������������������
jsPlumb.getInstance().repaintEverything();��� ��� ��� // Does not
seem to have an effect...
��������������� }
��������������� ,200
������� );
}
Note: The URL changed was changed to:
http://dev.henrik.commutenet.dk/?id=game-map
I will try to re-test after upgrading to 1.5.5 - These results are
from 1.4.1
Maybe you could test in browsers available to you and send back your
results ?
/Henrik
Den 11-01-2014 21:47, Simon Porritt
skrev:
I noticed that IE11 on Win7 had the
same problem, actually, but repaintEverything
didn�t fix it for me. You may want to upgrade to jsPlumb
1.5.5 in case it�s an old bug or something.