Commit graph

258 commits

Author SHA1 Message Date
Dennis Francis
13c6f68438 migrate cursor and view-cursor to TS Cursor implementation
and remove L.Cursor class.

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I96fa158cbbe90ddc0f0b3cdd98cfc6615c2dfd4f
2021-03-04 15:06:02 +05:30
Dennis Francis
11bddcb3d1 Introduce TS Cursor class based on L.Cursor
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I1c9c0c9ed50956e9151b8028b5c5fe38f73a8097
2021-03-04 15:06:02 +05:30
Dennis Francis
675963f22b migrate splitter lines to canvas overlay section
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I983eedbb946d640498e63660e948d09dd838f2b1
2021-03-04 15:06:02 +05:30
Gökay Şatır
52759920a5 mCustomScrollBar: Remove.
It's not used anymore.

Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: I4424018e6b1820de0d86c9058207fe19f46e0c16
2021-03-03 14:04:11 +03:00
Gökay Şatır
b9e50b7de6 Control.Scroll.js: Removed.
ScrollSection.ts is the updated version of this file.

Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: I484dcb7eafdc3ca62ba4d8ad864e0de711567d66
2021-03-03 14:04:11 +03:00
Gökay Şatır
1bf9a9a9e9 scroll-container: Remove references.
This class was used by mCustomScrollBar.

Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: Id912677c3fa2cfdfa6cd5824975d8630ec6a2ac7
2021-03-03 14:04:11 +03:00
Gökay Şatır
3d507fb3a5 Control.Scroll.js: Move to typescript.
Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: Iac7c15fa5ea1fb8fe78119ea28032017552d93d4
2021-03-02 09:25:41 +03:00
Gökay Şatır
84e1d855d0 loleaflet: Makefile bug.
All ts files were being compiled upon a change on one of them. Bug
solved.

Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: I3137d07e7ddf43076bf8b55fbacba1caef6f19cd
2021-03-02 09:25:41 +03:00
Szymon Kłos
bf62ad5acb notebookbar: added for draw
Change-Id: I9caf00f1b02ebbf0820051d8e44721a8eb4549fd
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2021-03-01 13:58:14 +03:00
Dennis Francis
02c64ead85 mocha-tests: compile only the changed test files
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I99b033888006370c4511f54c8fd7312007a4c984
2021-02-15 16:38:53 +05:30
Dennis Francis
8b2eae423c setup mocha framework for testing TS classes/functions
... and add a few test-cases for CPointSet.empty()

* The tests are written in TS and compiled to JS before Mocha framework
  runs them using 'npm test' via 'make check'.

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I16e28404af76754b6bbb67c6743ca7d0f2701233
2021-02-12 12:02:13 +05:30
Gökay Şatır
310bd0e234 CanvasTileLayer: Move TilesSection to a typescript file.
Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: I305615e0fc4d9adddb2cedc7a2860e741d467dd4
2021-02-10 19:05:15 +03:00
Gökay Şatır
91094acbf5 loleaflet: Update makefile for typescript files.
It now detects and compiles ts files in specified directories.

Signed-off-by: Gökay Şatır <gokay.satir@collabora.com>
Change-Id: Ia8a399650480001193be7177b05b5cbb195a98c7
2021-02-10 19:05:15 +03:00
Dennis Francis
0b3b3fa69e make 'build-loleaflet' depend on dist version of ts -> js
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I04c5f6770e4d58cdca2cbebf24656b280b906988
2021-02-08 14:32:57 +05:30
Dennis Francis
dac8d84efa CanvasOverlay.js depends on all typescript files in vector/
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I235a2dcd681476331cf4224d368eca7a8547e0e8
2021-02-08 14:32:57 +05:30
Dennis Francis
d28b66df7a CanvasOverlay.js is dependant on layer/vector/*.ts
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I87640e81fe11dee7b87eb376a9c9871977bc6710
2021-02-08 14:32:57 +05:30
Dennis Francis
c5800a676e Add CPath.ts based on L.Path
The generated js for CPath.ts is added to the generated CanvasOver.js
for now using

/// <reference path="CPath.ts" />

as there is no support for modules in ES5.

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I72bf2ab6f299641925c72b484f63e755ba4e61d4
2021-02-08 14:32:57 +05:30
Dennis Francis
0d75324379 introduce CanvasOverlay and its section
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I47d2f739b0d98c3926208358951e7240e632153f
2021-02-08 14:32:57 +05:30
Gökay Şatır
18c4ad5584 Calc: GroupBase.js is added for shared functions.
Row and column groups share some of the functions. They are moved into a file.

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I268daf2c293f0cac150587a23001f873e23b4dfc
2021-02-02 20:31:37 +03:00
Gökay Şatır
d576895c57 Calc: Add Row Group and Column Group sections.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: Ib44e5e6a9e047c347a239a155b86f091467f5149
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
2021-02-02 09:49:48 +01:00
Gökay Şatır
2d8df66167 Calc: Draw Column & Row Headers on tiles canvas.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
2021-02-02 09:49:48 +01:00
Henry Castro
7e0186600d loleaflet: makefile: fix builddir != srcdir
Change-Id: I97083c0a093a4038cb91dd618096eeb4292463fe
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-01-18 17:31:19 -04:00
Gökay Şatır
137a757d72 CanvasSectionProps: Add an overview of sections.
We are drawing things from different files onto the same canvas.
CanvasSectionContainer is organising them. When they are too many, it is difficult to know about sections' important properties.
CanvasSectionProps keeps sections maintainable.

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I9e81104c30f30a47c02625ce9d6716a98958317c
2021-01-18 15:17:07 +03:00
Michael Meeks
136f20b386 Use jsdom to load and execute our CSS, HTML and JS.
Change-Id: Ia7414e1fd19bf7ebfa29274d1acac5cee4837341
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-01-16 12:18:47 +00:00
Michael Meeks
c7d0de0877 Start of using NodeJS to do load simulation.
Change-Id: Id27ff406adc2269665aca0bbb54dd2102a4c7c74
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2021-01-16 12:18:47 +00:00
Henry Castro
85912b9100 loleaflet: makefile: fix override recipe
Makefile:815: warning: overriding recipe for target 'dist/vex.css'
Makefile:815: warning: ignoring old recipe for target 'dist/vex.css'

Change-Id: I31083acc17b89df4f02bfbd55696725dc04f275d
Signed-off-by: Henry Castro <hcastro@collabora.com>
2021-01-08 15:19:50 -04:00
Gökay Şatır
2871e1d3b7 Control.Header: Bring non-shared functions from rows and columns into header class.
Rebased with master.
gitignore file is updated.

Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I07c9f8e38db0dce7b50238e2c013d3521091ab25
2021-01-06 20:43:54 +03:00
Gökay Şatır
07c2f7dc67 Introduce CanvasSectionContainer class.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I69929595450c48ed45326c21743fbde3babc9803
2021-01-06 20:43:54 +03:00
Jan Holesovsky
08f0e99bca Remove unused functions.
Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Change-Id: I79d9a5028a64e30b68b6a9aeb3389dfb7d083bc9
2020-12-22 17:55:00 +01:00
Pedro Pinto Silva
30846b341d JSDialog: style btns, add generic btns file and reuse, fix font-family..
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ib4518c60a6304ac175290e5231ed25738c0d44ef
2020-12-08 20:05:19 +01:00
Szymon Kłos
b71ebc0011 jsdialog: make MobileWizardBuilder a separate thing
We need JSDialogBuilder to be a common class for other builders.
MobileWizardBuilder will handle mobile specific cases only.

Change-Id: Icff024fe70d0e5386c92bdd106b6db2e74a584b5
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2020-11-26 12:15:43 +01:00
Szymon Kłos
4fa83a4761 jsdialog: create container for desktop dialogs
Change-Id: I68bc6f5afeccdf2642e117d59ac17fe5e83e5824
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2020-11-24 13:01:16 +01:00
Szymon Kłos
7b82f9a9b4 jsdialog: handle autofilter dropdown
Change-Id: Ib47185359526f030a80aa9f7d7f9ef6e2ab93b34
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2020-11-24 13:01:16 +01:00
Andras Timar
b820e9991d Updated UI pot file
Change-Id: I262ac7f5cce317ec9229fc7654562ad83b2cf89c
2020-10-21 14:30:42 +02:00
Andras Timar
88774fa3df Silence po2json.py
Change-Id: I029e77a602f61810e91167f03d2b0e08e6263d35
2020-10-20 12:50:00 +02:00
Andras Timar
1e5701aa0c Weblate will translate iOS resource directly, we do not need the po files.
Change-Id: I1a67fd822d060cb234cd186c6ac97c74b0b8f91a
2020-10-09 12:36:08 +02:00
Henry Castro
bbca1243a8 loleaflet: Makefile: avoid the node_module path distribution
it gives an error:
"execvp: /bin/sh: Argument list too long"

Change-Id: Iffbf6d6f9ce46cba550dde9baf9ab8cbaddc3678
2020-10-01 21:10:30 -04:00
Jan Holesovsky
26fc803a0e Use the CanvasTileLayer for all rendering.
Fixes problems particularly with the new Chrome where the original
approach to tiles can be causing blurry text.

Change-Id: Icf598df0e997d493b111fad1c59e7dcb5f376801
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103681
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2020-09-30 20:16:45 +02:00
Henry Castro
3d0a27636c loleaflet: move the file "viamapi-client.js"
The file is not part of the leaflet files.
It is better to move it to the external library location

Change-Id: I12fb9684571db360b03a2e7c343725fd42b6848a
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103419
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-09-28 14:29:30 +02:00
Andras Timar
1064870312 loleaflet: makefile: add back welcome message
Change-Id: I387a247da2e0c2d6f6f3813d47f1a635691a34df
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/103338
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
2020-09-25 15:34:29 +02:00
Henry Castro
d7353acf96 loleaflet: introduce "stylelint" a modern linter for CSS
Change-Id: I8a7427eeb3b838baac8a6669d5313dc0d53d9ddd
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/102199
Tested-by: Pedro Silva <pedro.silva@collabora.com>
Reviewed-by: Pedro Silva <pedro.silva@collabora.com>
2020-09-08 17:33:12 +02:00
Henry Castro
22fd4ebaa6 admin: fix build when builddir != srcdir
Change-Id: If29863c06a8c296d5d4b7c37f0f6473e949e4371
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98223
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-08-14 15:42:13 +02:00
gokaysatir
30dfb54ca4 loleaflet: Admin console overview details.
Change-Id: Ia796d457e26a5867547fb4b2b4b78b10c64d7c95
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/99689
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Henry Castro <hcastro@collabora.com>
2020-08-07 16:03:39 +02:00
Tomaž Vajngerl
3141ba2403 AnnotationManagerImpress to manage annotations for Impress
and move thefunctionallity from ImpressTileLayer.js

Change-Id: I646432b677652983384ba53197b5a7af6dd035e0
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/99019
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-07-21 14:46:34 +02:00
Tomaž Vajngerl
2b313af4f3 add AnnotationManagerBase to share code with other modules
Currently AnnotationManager is meant for Writer only, but it makes
sense to share the code with other modules too. This adds a new
base class AnnotationManagerBase which will contain the common
code for the annotation management. Other modules currently have
the annotations implemented in TileLayer, but this is the first
step to move them into its own annotation managers too.

Change-Id: I5131337aa95e43ce0844d57e2cc020239af5f100
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/99018
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2020-07-20 22:49:11 +02:00
Mike Kaganski
0c99f6830b Warn user when the document could not be locked
Change-Id: I66b584f5e95fd82dc5cb27d10d9629cf19cb61bd
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98782
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2020-07-20 15:47:53 +02:00
Dennis Francis
3c3adc3f5d add draggable splitters that controls the split-panes
Change-Id: I7d6f681fbacfd8b1a6699c52a8bd9d007f20b99d
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98355
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Jenkins
Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2020-07-08 16:59:04 +02:00
Dennis Francis
a59076e1ca add split-panes support for overlay layer
(This is only for svg renderer)

There are separate svg DOM-nodes for each split-pane with view-box set
appropriately. The L.Path based objects are shared for each
split-pane, but there will be separate identical 'path' DOM-nodes for
each svg container.

This patch introduces L.SplitPanesRenderer/L.SplitPanesSVG (has
same external api as L.Renderer/L.SVG). These are wrapper classes to host
child renderers, one per split-pane and delegate calls to them
appropriately.

Change-Id: Id44e9a1312500e6b43cdd8e4f42e235b43d22772
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98354
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Tested-by: Jenkins
Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2020-07-08 16:57:44 +02:00
Dennis Francis
4b2ff56750 introduce CanvasTileLayer with support for split-panes
which is derived from TileLayer but renders tiles on a canvas instead.

TODO: Generalize certain methods of TileLayer instead of a complete
re-implementation in CanvasTileLayer just because a few things need to
change.

Change-Id: I51001f83f8f663d194bc9c4b018fa9950c40f420
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98351
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2020-07-08 16:50:42 +02:00
Dennis Francis
5f17407548 introduce SplitPanesContext class
This will store the split position and notify others and update the
splitters when someone changes this.

Change-Id: Ic1a2d665c972c369ce4e1362d0add50f72125d8a
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/98350
Tested-by: Jenkins
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Dennis Francis <dennis.francis@collabora.com>
2020-07-08 16:49:59 +02:00