Instead of asking for individual tiles, try to find rectangular areas in the
tile requests, and ask for the large rectangles using tilecombine, instead of
asking for individual tiles.
This test requires the renderid parameter to be present in the 'tile:'
response messages, and that is the case only when ENABLE_DEBUG, so we
can run the test only in a debug build.
In a debug build it contains also the parameter renderid. (And in the
future, might be extended in other ways, too.) Construct a new request
message that has exactly and only the parameters we want.
loleaflet can now send userinactive when the user
has switched tabs or the browser window loses
focus. Similarly, it can send useractive when
focus is regained.
Change-Id: Id3186949b10a8263e29ada1a790d3123a79e8f08
Reviewed-on: https://gerrit.libreoffice.org/24272
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Will be used in unit test to verify that several clients of the same
document asking for the same tile simultaneously indeed do cause just
one tile rendering to take place.
For some reason, text cursor gets stuck making it impossible to
type in the document. This only happens with firefox + owncloud.
Lets keep the editlock state separately in map, and do not yet
mix the permissions with editlock state.
Change-Id: If4193d08b7228cde510321ec5b4c892b8617d8a7
It is still possible to access them directly via loleaflet/dist/<something>,
but such use can lead to unexpected behaviour due to various caching in the
browsers etc.
Implement this for tilecombine, and do tile writes in each client's
thread separately. Add env-var. to trigger sleep, and tune it to 1
second; easily long enough to exercise this code-path.
It is incorrect to add the <div> elements with parent as w2ui
toolbar outside of onRefresh() method because toolbar can
refresh multiple times during its lifetime meaning that all such
added elements will be removed after first refresh breaking the
font/back color feedback javascript code.
Hence, this also fixes the font/back color feedback.
Change-Id: Iacd4f8a5c8ebb64e5bba5e7f05ceef8b77051534
Keep track of tiles being rendered in TileCache, and when asked to
render the same tile as is already being rendered, just "subscribe" to
the existing ongoing rendering. When a tile has been rendered and is
being sent out to clients, check if there are "subscriptions" and send
it to them, too.
One problem is that if the client that caused a tile rendering to be
initiated goes away before the rendering has completed, it will never
complete, and the subscribers are left without the tile.
Change-Id: Icca237876a0f466c29eb5bf60ffd4da3d9d68600
Reviewed-on: https://gerrit.libreoffice.org/24228
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>