Removed redundant util functions addProperty
and twipToPixel in several Calc related classes.
Change-Id: I169be2edf74e662d5c3e3fcbd80265e9a694598d
Reviewed-on: https://gerrit.libreoffice.org/41372
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Added insert/delete/hide/show/optimal width or height
/adjust width or heigth to Calc. These options
show in a floating menu near the headers when the
user taps on the headers. Also added selection on
headers, i.e., user can drag on headers to select
multiple columns/rows.
Change-Id: I7e1994d1fa81d80c110def035c2c065e838b49ac
Reviewed-on: https://gerrit.libreoffice.org/40684
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Added cell selection to Calc docs in Android Viewer with a
similar behavior to LOOL wrt. row/column selection.
The user can tap on any header to select whole row/column
or select all by tapping the top left corner of the header.
Change-Id: I34bdbb1aacc5fc0ed9175908936a8a5e6eec4ff4
Reviewed-on: https://gerrit.libreoffice.org/39694
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Fixed the crash after save dialog caused by
a possible null pointer related to presentation
mode.
Change-Id: I2fcf254f4382eaa5b565e25679486a5158d56eac
Reviewed-on: https://gerrit.libreoffice.org/39847
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Corrected the accidentally named inner class in
PresentationActivity.java from camel case to
Upper case.
Change-Id: I0c27efe371611959e40cd656628a0fa2c9c0cdce
Reviewed-on: https://gerrit.libreoffice.org/39832
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Adding Calc UI. Two blank views are added as
row and column headers. CommonCanvasElement
is used to draw header cells on the views. [WIP]
Change-Id: I37eaa82805045ab650fd127e54c8421c61a4ea27
Reviewed-on: https://gerrit.libreoffice.org/38936
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
This commit gives the ability to listen for changes in
editing preference settings to LibreOfficeMainActivity.
This makes sure that value of mIsExperimentalMode
boolean is correct in any condition.
Change-Id: Ie2a931e63fad30262ad2f870b6c06f707db96618
Reviewed-on: https://gerrit.libreoffice.org/37033
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Added function of updating zoom constraints
whenever device rotates. This is achieved by
calculating min zoom factor every time the
size change function is called.
Change-Id: I6d795c1eb79faa36b4f5dabedd2d4b8c87dcf7d7
Reviewed-on: https://gerrit.libreoffice.org/37847
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Fix the behavior of double tap zoom. Previously
double tap zooms to the viewport whose
top left point is the point of double touch. Now
double tap behaves such that the point of
doule touch does not move on the screen, and
the rest part of the view zooms in or out. This
behavior is more UX friendly and correct.
Change-Id: Ifccc337631d523be1cd870f892235899d0fc5dfe
Reviewed-on: https://gerrit.libreoffice.org/37046
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Rearranged activity_main.xml in order to fix the bug
of app bar invisible on lower versions of Android
devices.
Change-Id: Ic4ec9435ce9ef55a2596600c143114c899c30ac2
Reviewed-on: https://gerrit.libreoffice.org/36950
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
This commit adds the BottomSheetBehavior to the
formatting toolbar appearing from bottom.
CoordinatorLayout replaces the RelativeLayout in activity_main
and bottom toolbar is made the child of it.
Also, Add 'adjustPan' option to LibreOfficeMainActivity's
windowSoftInputMode flag so as to prevent soft keyboard
from pushing the views up
Change-Id: Ic9999c1177ac238bc7c482a69daec4e629fe6d93
Reviewed-on: https://gerrit.libreoffice.org/35768
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Added a checking of whether edit mode is on or off
before making a switch between edit and view modes.
Change-Id: I69043bc8694b605a517e16385abfa91d86d34d30
Reviewed-on: https://gerrit.libreoffice.org/36541
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Added double tap action in
JavaPanZoomController. This commit depends
on "restrict zoom to page width".
Change-Id: Ifbe13f698ea01af2223beede9211a13b4970a3d5
Reviewed-on: https://gerrit.libreoffice.org/36164
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
This commit adds the ability to create a new document using
existing file system browsing in the app.
Usage of StorageAccessFramework to create new document
has been ditched as it is not backward compatible.
Change-Id: I852c3de337613cb01e689d532476d2c5f932c1b3
Reviewed-on: https://gerrit.libreoffice.org/36195
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Added page number display in text documents. The page
nunmber calculation in handled on Java side and the
work only involves calls to LOKit when necessary.
Majority of the work is done in DocumentOverlayView.
java, including calculation and displaying. The page
number information is updated whenever a page number
change callback is caught (from LOkit).
Change-Id: I52014806cd647fa805b329825ac29b0e337c11a1
Reviewed-on: https://gerrit.libreoffice.org/36178
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Added the function of focusing on the word you search. Two
methods were added. The first one is searchResultSelection,
which parses a JSONObject passed from LOK and focuses
on the text selection. The second one is
moveViewportToMakeSelectionVisible. It handles well both
documents and spreadsheets. I also tried to add a
search not found toast message. Also corrected a typo.
Change-Id: I4453c01afc520bf4deae4c2bd71adea2fe856d7e
Reviewed-on: https://gerrit.libreoffice.org/35715
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Created an overloaded constructor for ZoomConstraints class that
takes in minZoom and maxZoom. Added calculation of minZoom
according to page width and screen width and assigned the
minZoom to ZoomConstraints in LOKitThread class. Deleted
minZoom checking in the onScale method in JavaPanZoomController
class because the checking prevented zoom-in from functioning.
(Update: I also removed the old constructor because it is not
used any more.)
Change-Id: I89e80761efc093b3738970d4482dd735532c0397
Reviewed-on: https://gerrit.libreoffice.org/35308
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
This commit will add the ability to create a new document.
A FAB is used in home screen which on expansion gives
four options namely new writer document, new impress,
new Sheet or new Draw. Two new events loadNewDocument
and saveDocumentAs have been added.
Another major change includes the use of constraint layout
in LOUIActivity layout as it decreases nesting of views and
improves the app performance. This was needed because
of the new FAB layouts being added.
Support for vector drawables has been enabled.
Change-Id: Ia3ea17f73c0d8514f8ddb7b9a1cbd2ce7de6ac08
Reviewed-on: https://gerrit.libreoffice.org/35183
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
- added some initial implementation of the bottom tab-bar, which
has 3 tabs - character, paragraph, insert
- insert has not (completely) working insert line and rect shapes
- add ability to shring/grow font as alternative to select its size
Change-Id: If039f985403a8155d1e011953043f2979b4bfa91
It uses the name of the current directory, and if the directory is the
root directory, it uses the app name instead.
Change-Id: I1d8ac2545acb3e75be5b19fb5c208a8cb242de11
Reviewed-on: https://gerrit.libreoffice.org/35201
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
Editing toolbar_bottom to include two more options:
1- Inserting numbering format lists
2- Inserting bullets format lists
Change-Id: I35f9238c45ab253ea75c693f7a76601408e36f9a
Reviewed-on: https://gerrit.libreoffice.org/35106
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
This makes it MUCH easier to see what sort option is currently
selected. Removed the mechanism of switching between labels when
the option is toggled, and instead put all the options into a menu.
Change-Id: I44142dc842d983d5438faeb06b67046bad235308
Reviewed-on: https://gerrit.libreoffice.org/34640
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
This commit will combine the code of ListItemAdapter &
GridItemAdapter in LibreOfficeUIActivity to one
ExplorerItemAdapter which will handle both the view
types.
Change-Id: I45c1f5124afee82ff0b78f13609acd37be87fde1
Reviewed-on: https://gerrit.libreoffice.org/34680
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
This commit improves the user experience of different
Document Providers in the app.
In case ext sd card is not present, the option is disabled
in Navigation Menu.
If the device does not support USB OTG,
the option is disabled.
LibreOfficeUIActivity registers a broadcast receiver
in onCreate which detects if a USB device is connected
and directs the user to Settings page to configure it.
In case of errors in configuration in any case,
user is directed to Settings activity after appropriate toast.
Change-Id: I680f78a679e2071ce8330c8168d7aa4e95041723
Reviewed-on: https://gerrit.libreoffice.org/34650
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
I made them add programatically before, because I was unsure
whether the list was dynamic, but when I found out that the five
items on the list are actually static, I realized that it's better
to declare menu items in XML, because of the performance and
readibility.
Change-Id: I044abe356e51b26ac13328fcf451cabc9e70a3ea
Reviewed-on: https://gerrit.libreoffice.org/34342
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
Steps to reproduce crash: Click on remote server option in navigation menu, in case of invalid server URL it will show a toast. Then click on Storage Provider Settings once and press back, app will crash throwing runtime exception.
The exception is not catched anywhere so Java runtime exits the app
Change-Id: I2bccca633e62fec82c868661f14765596c4b83f1
Reviewed-on: https://gerrit.libreoffice.org/34166
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
Moved file filtering from a toolbar spinner to a menu option.
The toolbar title is now free to display some other information.
The options are grouped, so they display radio buttons, and show
which item is selected. The radio group default selection is the
one defined in the settings.
Change-Id: Ib8d8716ec0038d2cd273423c756563680b84ae55
Reviewed-on: https://gerrit.libreoffice.org/34019
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>
Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
Moved "storage provider settings" to the navigation drawer, because
it makes more sense to put it below the storage options, than in a
overflow menu. Also, switched positions of "Settings" and "About",
because About is always the last item, by convention.
Change-Id: If6d621abfee7a3bdda28311a9cadf35ea674f852
Reviewed-on: https://gerrit.libreoffice.org/34073
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>