Automatically initialize formatButtons internal object to
preclude the possibility of one forgetting to enter the id of the
button in formatButtons object.
Fix 'id' of default numbering/bullet button after which it is
correctly showing the state now.
Change-Id: I57247e1b0e6d462153a47d31a883ceb04ecff74b
Reviewed-on: https://gerrit.libreoffice.org/32101
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
It is insertannotation, not just annotation
Change-Id: I1bc01e87da963d0e07d670ffec261e33b45062d2
Reviewed-on: https://gerrit.libreoffice.org/32096
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
If we get a true/false, assume its enabled.
Change-Id: I364c7cd611481757b674877ed44ac6ee0f6b0e58
Reviewed-on: https://gerrit.libreoffice.org/32089
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
... as these are now printed only when compiled with
--enable-debug, so they shouldn't be polluting the release build.
Change-Id: I3169fb39cea298b001a4d576632a1634ff35e004
loleaflet_logging defaults to true with compiled with
--enable-debug otherwise false.
Browser will print additional debug info when this property is
set to true.
Change-Id: Id9fabf134bd8d19fa1a09ca8c0987df46d4f1a4c
After all, why would you have the console open unless when debugging
(even just following console.log() output), so it is
counter-productive to have the code behave differently in that case.
Change-Id: I2aa7cf095e249a4c87f920aa0f1911be76a348ca
(The greying-out without focus happens, as before, already after 30
seconds.)
Factor out the dimming code to a separate function _dim. When we have
focus, check once a minute if ten minutes has passed without user
activity. Keep track of when last user activity happened.
There is a bug left: When greyed-out while having focus, you need to
click on the background layer, not in the layer with the 'Inactive
document ...' text, to wake it up.
Change-Id: I19160a82f5de860fc609dad391b168acfba560ce
window.PointerEvent is available even on non-touch devices in
chrome and Edge (and maybe others too, firefox doesn't have it).
So it results in L.Browser.pointer resulting in true on Chrome,
Edge while false in firefox which leads to click event not
working on these browsers.
Fallout from a0036f24ba
Change-Id: I73b5824882e1cc1f87cdfbc9e7e31f22320367b1
MS Edge seems to be very problematic when one tries to load the
pdf blob into the print iframe and issue a print command to it.
Lets fallback to print prompt as we have in firefox
Change-Id: I97fc394d0053030231c524efb6bf808d32a9aa07
Removing this._printIframe may still cause leakage here as
this._printIframe is overwritten everytime user issues a print
command.
Change-Id: I06f45604940380b809bc262f07b9b6a8aa7d9a87
Top level make would now build loleaflet too if necessary.
Respect value of ENABLE_DEBUG and if present add debug-info to
generated js bundles too.
Add new rule, clean-local in loleaflet.
Change-Id: I3a9b727824f2877fc72719a8bfdeebed5448cb7d
This always takes ~2 seconds irrespective of whether node_modules
needs updating or not. Lets add appropriate dependencies and save
these precious 2 seconds.
Change-Id: Ided4ff334316c16521e5ea7a69d15736a1cc170f
Use events, 'hidebusy', 'showbusy' to interact with toolbar.
In some cases, it may happen that w2ui usage in loleaflet happens
before browser loads w2ui.js (as it is in <script> tag after the
one which loads loleaflet).
Change-Id: I9b1b249ede72ed01f97cf31fd3f93780312530bc
No point in building things that are already built, create
different jake tasks, enclose whole of the build process in a
single jake task - 'build' which would call other various tasks
depending on whether they needs building.
Change-Id: I4b26834440ef638d697aa0793d2ced1e2c49784a
Compression is most expensive in terms of time; if we detect
early that there are no changes between oldSrc and newSrc, lets
return early and skip the compression.
Change-Id: Id3d7c1d4bf89a33819907ff735e01629581627a3
Start searching as you type
Press enter to search forward
Shift + enter to search backwards
Esc to get back to editing
Change-Id: Id366069aea9eb0e96e8d73fa4b57f972b0ce78e5
Use a new protocol message, 'resetidle' to inform Admin clients
whenever a user has done anything in a document view. This is a
message that Admin clients need to subscribe to.
Also add the current idle time for each document to the 'documents'
message.
To reduce protocol chatter, the idle time is updated at most once per
10 s.
Change-Id: I418e82b05048a3628f21dcd240ccd974b3a01356
Reviewed-on: https://gerrit.libreoffice.org/31653
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Tested-by: Tor Lillqvist <tml@collabora.com>
When the connection is slow and tiles are received after a good
amount of lag in between them, one tile load can prune tiles (of
earlier zoom level) for which we have not yet received the tile
response from the server - so there's nothing we have yet to
overlap these tiles completely, leading to grey-ish patches when zooming
in or out.
Pruning these tiles later ensures that we do not remove any tiles
of earlier zoom levels until all the tiles have been loaded.
Change-Id: Ibb03f0c6bf2031741f0b8a4584c1821539587e88
Due to a bug in w2ui library, w2overlay doesn't popup when it is
near the edge of the screen (reproduceable only when no. of users
are greater than 3). Lets disable zoom controls in case of
spreadsheets so that userlist is not near the edge of the screen,
and hence pops up.
Change-Id: I6f2647d124484235afe6c92da18be38ed8e2b9ce
Reviewed-on: https://gerrit.libreoffice.org/31621
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Set a timer in loleaflet 15 minutes before access token expiry
date (access_token_ttl value) to prompt the user to save and
refresh the session.
Change-Id: I98c3e47c9b7031e29e002f653d488747b9c17df8
Reviewed-on: https://gerrit.libreoffice.org/31381
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
This patch fixes the following bug:
Create blank sheet:
enter "." ie. just a period into A1
enter a "." into A2
now switch virtual desktop away and back again.
hit enter in A2
now switch virtual desktop away and back again.
You should have a blinking edit cursor in A2 - but the focus in A3.
Change-Id: Icda0123f35ecda04559fec859b6bbe6ff3ac33e8
Reviewed-on: https://gerrit.libreoffice.org/31541
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
This patch fixes two problems for spreadsheets:
- one pixel alignment offset btw grid and column header
- a one pixel horizontal auto-scrolling issue
Change-Id: Ifd6a3b47863d345656d0dcf3fba2d253c43ba9b1
Reviewed-on: https://gerrit.libreoffice.org/31542
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
... as we handle it already during 'keydown' by sending keyboard
event to core which changes the slide for us.
Change-Id: Id61584ffa0ec5ff3aca098e3dcade664c306c6c3
Reviewed-on: https://gerrit.libreoffice.org/31475
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
We regressed on chrome with
47699cd908 as 'textInput' event
clubbed with 'keypress' event started emitting double-spaces.
Tweak the hack to keep IME working on chrome while not regressing
when it is not enabled.
Change-Id: I0901724bf2db1794078fef3eb7283663b6f6a13b
Reviewed-on: https://gerrit.libreoffice.org/31469
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
When IME is enabled and user presses the space button, firefox
sends 'compositionend' event with data = ' '. However, chrome
instead fires 'textInput'
event. Lets listen for 'textInput' event too and treat it like
'compositionend' event when data = ' '.
Change-Id: Icbebdf2e89f608f790e6ce68c49f474364e7d5ab
Parse the compositionend event's string, convert each into a char
code and pass them individually to server.
Change-Id: If79d538ccaebaa29749a5ca48a1f6ed5e0689ed5
Have a new event 'warn' which doesn't change the document
permission but just show the user dialog with some message.
Change-Id: I455168e4f7315acdcccfb31fc8c70b86bbc6caad
The new behavior is to warn the user when we try to save to
storage and set all the sessions of
the opened document to readonly, if storage server has no disk
space left. In case of WOPI, this is intimated by HTTP response code 413 -
request entity too large.
If save operation to storage failed due to reasons other than
413, just warn the user and let it continue editing the document.
We can add more reasons of failure and act accordingly in future.
Change-Id: I4b046fc38bbc0d752c89d90acb5991a958b76670
Amazingly, this (my third attempt) seems to work.
Add a boolean 'forAllClients' parameter to the loleafget getPreview()
function, and pass it as true in the location where a new preview of
an edited slide is requested.
Add a parameter 'broadcast' to the 'tile' (request) message. Set to
'yes' in the above case. When subscribing to a such tile rendering,
subscribe all sessions of the document.
While at it, drop the default values for the parameters of the
TileDesc constructor. I dislike default values...
Change-Id: Idb438f11c953d791fafe4c890e0497d8dfbaa733
Reviewed-on: https://gerrit.libreoffice.org/29591
Reviewed-by: pranavk <pranavk@collabora.co.uk>
Tested-by: pranavk <pranavk@collabora.co.uk>
Users aren't bothered with connection errors when inactive.
Instead, when they try to re-activate, the connection is
re-established, and only if that is not possible does
the user see the disconnection notice. Otherwise,
the connection is re-established semi-transparently
(the is a small "connecting" status shown at the bottom).
Change-Id: If4735cc1593c6e29c65d3c9686a8f2861365c583
Reviewed-on: https://gerrit.libreoffice.org/31026
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
This leads to emission of 'docsize' event somewhere down the line
which leads inconsistencies while navigating the document.
Change-Id: Iffabac66153e7b32c9b2af041282ef82b813bef3
'status' message can well be sent after document has already been
loaded. Eg: when the doc size is changed. We don't want this code
to execute in all such cases.
Change-Id: Ia69ab70edddda1a4e27618101eaff35bd0e5eb65
This also introduced a regression where upon reconnection of the
document, tiles were not updated. This was because calling
setView leads to calling 'canceltiles' down the line which would
cancel the the 'tilecombine' request for fetching all tiles
leading to stale tiles in the UI
Change-Id: Ib0f583c92802195384ea10f328c0ba2eafc82ffd
Additionally, change the variable name for presentation-toolbar
to avoid any future confusion.
Also, put the code hiding the save button in onRefresh event so that
save button doesn't show up in the UI as soon as we get the wopi
properties object from the server.
Change-Id: Ib168010c509f55a69aae9752e11321d319f59e99
Post App_LoadingStatus with 'Status' field as Frame_Ready when
we are ready to show the UI.
Post Document_Loaded when document is completely loaded after
which loleaflet is ready to respond to more document specific
queries through post message API.
Change-Id: I60a4e9b75e115c748fcee8d449bc8c2d4ffa34a9
When we add more server controls (restart, f.e.)
we will need to move this to a separate page.
Also, we need to prompt the admin for reason,
which we can broadcast to all users when the server
goes down.
Change-Id: Ide92e58b5b64a5107b6556aef6b1a88191d5d21b
Reviewed-on: https://gerrit.libreoffice.org/30832
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
Accessing the parent iframe, atleast on my local box, where
parent frame and loleaflet frame have different origin, is not
allowed by browser security policy.
Change-Id: Ia3a356fa1d8a81f38bbc27d256471302be8b6729
WOPI hosts can now send above mentioned messages to loleaflet so
that loleaflet does stuff accordingly.
Change-Id: I50e10a62c5b629bd12f7d9ce51bcd13cb13cdd8a
Add more WOPI extensions for this - HidePrintOption,
HideSaveOption, HideExportOption. Setting HideExportOption to
'true' in WOPI CheckFileInfo response would hide the 'Download
as' option from the File menu.
Change-Id: Ia2259ee9525cc6c4331a52e2221af4df188eab07
This implements a new feature 'OwnerTermination' for WOPI based
hosts. WOPI hosts now have to enable this feature by mentioning
'EnableOwnerTermination' as 'true' in their CheckFileInfo
response. If the OwnerId of the file matches that of the UserId
of the session, this session would be able to terminate all other
sessions currently editing the same document.
The reason for this kind of document termination is sent to all
sessions in a new application-level 'close:' message. This new message is
similar to the CLOSE frame of WebSocket protocol which doesn't
seem to work across all browsers as of now. Eg: Chrome -
https://bugs.chromium.org/p/chromium/issues/detail?id=426798
After receiving this 'close: ' message, loleaflet acts
accordingly and tells the WOPI host why the websocket was closed
via post message API.
Change-Id: I997aa2e7805157ed599a3946a877fd32477cee1b
Abstract all the WOPI related logic in a map handler which is
enabled only if map.options.wopi is set during map
initialization.
Change-Id: I54c5d6eecf33f88e4fd4d2b5ac9e8cf9dd001966
This fixes regression to the hackish fix done
in b26f2f2738 -
loleaflet: prevent the zoomlevel from changing on connect/disconnect
Change-Id: I09c899546d0d8bfbe4c274b0774fd30008cbcfa5
Reviewed-on: https://gerrit.libreoffice.org/30400
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
When a client connects or disconnects ViewInfo message is sent.
The handler for this updates the number of users via addView
and removeView. Unfortunately when the toolbar control is
updated, it resets the zoomlevel to 100% (the initial value).
This is an ugly hack to change it back to the correct
value, since nothing really visually changes. It certainly
could be improved by only correcting the toolbar.
Change-Id: I37294da2d9d1bc84e8cb3b7f634aadcfd80d6497
Reviewed-on: https://gerrit.libreoffice.org/30218
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
- show outgoing and incoming network messages with some
highlighting in Javascript console (default in tile
debug mode)
- add optional automatic typing
- add layer controls for overlays and automatic typing
- differentiate rectangle borders (newer is more opaque)
- fixes:
- fix function call at cancelled tiles
- hide all attribution control when disabling debug mode
permission= parameter in URL is still supported, but overridden
by UserCanWrite parameter.
Also, introduce a new protocol message, perm: which dictates
loleaflet about the permission rather than the other way around
(only in case of WOPI)
It is to be noted that by default loolwsd assumes very
restrictive permissions, so not providing UserCanWrite in WOPI
implementation by a WOPI host would lead to opening of only
readonly session.
Change-Id: I2013c1661fd491c79bb367a41e1a7036fa03f984
Use the previously unused UnauthorizedRequestException for this, and
throw a such in StorageBase::create() when the WOPI host doesn't match
any of those configured.
In a developer debug build, without access to any real WOPI
functionality, you can test by setting the FAKE_UNAUTHORIZED
environment variable and attempting to edit a plain local file:
URI. That will cause such an exception to be thrown in that function.
Catch that UnauthorizedRequestException in
ClientRequestHandler::handleGetRequest(), and send an 'error:
cmd=internal kind=unauthorized' message to the client. Handle that in
loleaflet in the same place where the 'error: cmd=internal
kild=diskfull' message is handled, and in the same fashion, giving up
on the document.
Actually, using exceptions for relatively non-exceptional situations
like this is lame and makes understanding the code harder, but that is
just my personal preference...
FIXME: By the time StorageBase::create() gets called we have already
sent three 'statusindicator:' messages ('find', 'connect', and
'ready') to the client. We should ideally do the checks we do in
StorageBase::create() much earlier.
Also consider that ClientRequestHandler::handleClientRequest() has
code that catches UnauthorizedRequestException and
BadRequestException, and tries to set the HTTP response in those
cases. I am not sure if that functionality has ever been exercised,
though. Currently, we upgrade the HTTP connection to WebSocket early,
and only after that we check whether the WOPI host is authorized
etc. By that time it is too late to return an HTTP response to the
user. If that even is what we ideally should do? If not, then we
probably should drop the code that constructs HTTP responses and
attempts to send them.
Also, if I, as a test, force an HTTPResponse::HTTP_BAD_REQUEST to be
sent before the HTTP connection is upgraded to WebSocket, loleaflet
throws up the generic "Well, this is embarrassing" dialog anyway. At
least in Firefox on Linux. (Instead of the browser showing some own
dialog, which I was half-expecting to happen.)
- show total number of the rendered tiles of the document, also
the difference between the previous number in the client
- show cached tiles in transparent yellow color (in debug build)
- send ping messages after every invalidation message instead of
keypressing
- fix memory leak: remove unused leaflet rectangle overlays on the
tiles
.uno:TrackedChangeAuthors doesn't give correct colors for
documents other than writer, lets use our old algorithm for color
assignment for these documents.
Change-Id: If865788154a80da2637aad84183a0e947bb4b7e8
No need to fire it if nothing happens. Just confuses a reader of the
code.
I don't really understand JavsScript events etc, so if I have
misunderstood something, feel free to revert.
Set the mode to viewonly after the error so that user can still
see the tiles downloaded from the server, but cannot interact
anymore before server administrator fixes the disk space.
Change-Id: If03f4fabe93458672a631c020d09dcebecbb955c
From
/lool/ws/docurl
to
/lool/docurl/ws
The main purpose behind changing this and other related urls is
to help in load-balancing. The first two parts of the URL can now
be used in a hash-based load-balancing algorithm which decides which
slave gets to serve the requests. Requests such as insertfile,
downloadas need to end up in the same slave in which document was opened.
/lool/docurl/ i.e first two parts of the URL are constant for all
the requests that should be served by a single slave.
Change-Id: Ibc605ca1251957b8b32b376cf19b78f6178fadfa
- show best, average, worst, last times of
- server ping round trip
- times between key press and invalidation message
- tile based and total tile update latencies
- show data of the last five invalidation:
- tilecombine messages, if they exist
- otherwise the invalidation message
- border of the last five invalidation rectangles
- visual fixes:
- more transparent red color for better text typing
- small letters over tiles with transparent background
- black attribution text instead of gray + bottomleft position
- show invalidated rectangles with fading effect
- show last tilecombine message and cancelled tile count
- show received/requested tile updates
- fix popup handling
- custom popup style (transparent, big numbers)
- clean up
This code throws sometimes. Rather than investigating what makes
it actually throw, lets kill it because we don't want any
editlock functionality anyways now.
Change-Id: I8a484ba9e3a658ca739122bb6d2d0c92c4180ff5
Otherwise if you edit a different part of the document and somebody else
selects a shape, you get an unexpected, annoying jump.
Change-Id: I161a27c8a69e0873de0ebe3a020e2868cbe0afca
... so that one can use the factored-out rule, build-l10n, to
install these translation .json files in dist/ and start using
them, without having to do 'make dist' first and then extract the
package.
Change-Id: Ie2814a9f2596246b487799968f3027aa48475e7b
The behavior has changed to include .pot files in git as well in
7839aecac6
So, don't try to delete these .pot files now
Change-Id: I6f5d015596ff1f2d98adca426b1458f66bc7d4b4
Reviewed-on: https://gerrit.libreoffice.org/29130
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Tested-by: Andras Timar <andras.timar@collabora.com>
Location was changed in 6c69b63be5
in an effort to modularize everything including these l10n
strings.
Change-Id: I4d7538a6e6d1370a45326bc163a496cf7c681259
Extending the document URL with debug=1 option will switch
- visible tile boundaries
- update numbers over tiles
and invalidated tiles will be blue during waiting for an update.
Editlock buttons have already been removed; most of this code is
unreachable/useless anyways.
Don't listen to editlock messages anymore, and always set the map
permission to edit unless specified.
Change-Id: I2ee672e72beaa48a7c6cd0bbd1c548ff10a251d1
Iterating viewCursor object won't give correct number of live
viewids because inactive views don't receive any viewcursor
messages.
Rather use map._viewInfo object because as of now, we do receive
these 'addview' message for inactive views, so this place should
always remain updated and prevent giving inconsistent view counts
across different clients.
Change-Id: If210049e76b5f2b91371a21863f6019cbccdb9ca
Text messages are already utf8 decoded, so we only need to decode
if its a binary message, not otherwise.
This also fixes context menu invocation on the UI as in some
cases double-decoding of utf8 strings would throw a URI malformed
error. This problem started to appear after we explicitly started
sending context menu payload as text message rather than binary
message in ecd33e1b07
L.Polygon can take array of latlng pairs. Lets pass the full
array instead of passing each array element one by one and
creating Polygon instances everytime.
Minifiying the js code was taking too much time. Minifying is not
really needed on developer's machine, so lets disable it by
default, otherwise it gets annoying during development having to
wait for so many seconds for it to build.
A simple 'make' now means no debug-info and non-minified
bundle.js. To add debug-info(source-maps), do 'make DEBUG=true'.
And to minify, similarly use the MINIFY=true variable with make.
'make dist' forcefully minifies the js code.
This command is intended to be used when re-activating a
client. It is intended to be sent prior to sending the
list of active views, including the re-activating
client's own view.
A client UI must maintain its own view ID and info
when receiving this command.
Change-Id: Iea58c01fb30af139888e746b5cf9e7ba7e7eeab1
Reviewed-on: https://gerrit.libreoffice.org/28132
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
The new commands help the UI update the cursors and other
visual elements that track views and clients.
Currently, when remview is received loleaflet removes
the associated cursor from the screen.
Change-Id: I03e2f9e3485166adae31de84ae7ac6bd1c85b05d
Reviewed-on: https://gerrit.libreoffice.org/28131
Reviewed-by: Ashod Nakashian <ashnakash@gmail.com>
Tested-by: Ashod Nakashian <ashnakash@gmail.com>
This should give more fine-grained control as now we are sure
what version of browserify, or any other tool we are using to bundle
our assets. Installing browserify globally is also not required now.
This will also be helpful when we add more complicated transforms
and other tools to our build process, as otherwise it would keep
complicating our command used currently for the build process.
Use browserify for admin console scripts too.
Modularize needed files such as l10n strings for console.
Use npm for managing bootstrap as dependency of admin console.
Let the whole compiled admin bundle export a variable 'Admin' and
attach various classes to this global variable, similar to how we
have in Leaflet having a global L variable and other things
attached to this variable.
Changed "make pot" to deliver files in po/template, so the .pot files
are committed as well as the resulting .po files.
Added a README to explain, that styles is not part of translation.
View callbacks with viewid = 0 seems strange; it always lurks
around but is never attached to any view.
Also, view callbacks with viewid = our own viewid should not be
sent from the server, lets ignore them for now.
With current version, position of context menu is not set at
specified position. 2.2.3 fixes the issue.
Also udpate tarballs in node_shrinkwrap and dep. tree in
npm-shrinkwrap.json
Using npm-shrinkwrap, we are locking in our dependency tree
completely, leaving no scope of being affected by any
regression in any of the dependencies. In other words, all of the
dependency tree is dumped in npm-shrinkwrap.json file.
Using shrinkpack, we are also committing these tarballs of
dependencies in node_shrinkwrap/, so that, we are not
depending on npm registry at all during our build process. Since these
are just tarballs, its also better space-wise than committing
node_modules/ per se.
Developers when want to update any dependency should bump the
version in package.json, and also commit the new copy of
tarballs in node_shrinkwrap/.
See: https://github.com/JamieMason/shrinkpack for more info.
Commented out devDependencies; these are required for testing framework
inherited from upstream leaflet, but we do not have such tests as of
now for loleaflet.
Move them to devDependencies when need arises.
Don't include each third party script in a separate <script> tag,
rather have one single main.js file require'ing these different
scripts. Then `browserify' on main.js which bundles everything
into a single bundle.js containing all of the dependencies.
Also add these 3rd party scripts such as jquery, jquery-ui,
select2 etc. using npm, rather than manually downloading their
files from the internet. This should ease the process of managing
these front-end dependencies; upgrade process should be very easy
now.
... instead of setting a httpOnly cookie for admin websocket
endpoint which can be CSRFed.
With this, we remove the httpOnly tag on jwt cookie so that
scripts in admin html pages can access the jwt cookie and
authenticates after opening websocket endpoint. Until
authenticated using 'auth authToken' command, admin will not
respond to any admin command.
Also, adapt admin test these changes
Saving this way, key sequences are forwarded to core directly, so
loolwsd is not aware if a save operation is going on or not. This
leads to problem as loolwsd might want to upload to storage.
Change-Id: I32d10012064a0dda7fff0c3ac4848f140b1b6fb8
Specified when websocket is initialized. Documents once
opened in readonly mode cannot edit throughout the life of the session.
This is very much like present view mode except the ability to
change to edit mode.
Change-Id: I176e3bbf210c3383268d1a5b50dc17f0cbfb26b8
In cp-5.1 branch, the state table cell reports the string "Sum=0"
for empty cells, the client side splits the string with a separator '=',
so the status item shows "Sum".
A bug was found: Slide was translated to Slide in pt_BR, while Slide was
translated to Diapositivo in pt. The identical translation was ignored,
and browser fell back to pt translation, which was wrong in pt_BR UI.
Assigning this._graphicMarker to visibleCursor leads to problems
as graphicMarker is not the same kind of object as visibleCursor.
Change-Id: Ic0aa1d7d2a8d11fa38a86e2c143342c9a16d507e
OnInsertFile is triggered on onchange event, but this event is
not triggered if same image is choosen again from file chooser
dialog. Reset the value everytime so that onchange event is
always triggered.
Change-Id: I1efb76122b3a9437622754d28d0c55d4adbf32e8
There is still one problem though, that if already opened
document is opened in a different browser window, it doesn't
receive any command states which shows enable/disable states of
menubar items incorrectly.
Change-Id: Ib03f1becfb6585fed075bb5f1bf9c587063323a6
Remove direct usage of editlock; instead change loleaflet
permission from view to edit when editlock message is received.
By default, map would be in 'view' mode and only get to 'edit'
when server asks it to switch to.
Use a new event 'doclayerinit' for actions that are directly
dependent on intialization of doclayer.
Change-Id: Iaceb95ad85721ddcd675c75cfeb1504ab2759ad4
... easy to differentiate on client side among various version
info parts, especially for LOKit version information.
Change-Id: I4ba18c60367fb9166462b535bc46953a82a8435d