You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The above code breaks the initial nice, centering of a window, when you don't specify an initial position. All such windows end up at 0,0 rather than in the center of the screen. The useful windowjs code
The above code expects position to be an object (fair enough) and also wants the x and y values to be objects too? - which isn't right. x and y are actually numbers e.g. position : {x: 20, y: 20}. Perhaps the code should be checking for type "number", though if the user hasn't specified position as an option this code will break, so the two matters raised in this GitHub issue are related.
The windowjs library seems to work better without these two changes!
The text was updated successfully, but these errors were encountered:
A couple of bugs re window positioning seem to have been introduced recently.
Centering a window by omitting position option no longer works
Setting the window position to be the center of the screen, by omitting the
position
option no longer works after 19b62deThe above code breaks the initial nice, centering of a window, when you don't specify an initial position. All such windows end up at 0,0 rather than in the center of the screen. The useful windowjs code
is thus wasted.
Setting the initial window position is broken
Setting the initial window position e.g.
is broken after f417b38 and no longer works - every window appears at 0,0 due to the introduction of this code:
The above code expects
position
to be an object (fair enough) and also wants thex
andy
values to be objects too? - which isn't right.x
andy
are actually numbers e.g.position : {x: 20, y: 20}
. Perhaps the code should be checking for type"number"
, though if the user hasn't specified position as an option this code will break, so the two matters raised in this GitHub issue are related.The windowjs library seems to work better without these two changes!
The text was updated successfully, but these errors were encountered: