summaryrefslogtreecommitdiff
path: root/android
AgeCommit message (Collapse)AuthorFilesLines
2017-05-09Fix behavior of double tap zoom in and outXimeng Zu1-10/+12
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>
2017-05-09tdf#107415 android: appbar invisible on lower versionXimeng Zu2-14/+21
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>
2017-05-05Fix typosAndrea Gelmini1-1/+1
To complete commit 0ef94e2b559547bc4e906e7f24e57ff5d642e108 and f12096272e684ddcd8ffa4e34dcb0a680cc594c2 Change-Id: Ie86bbfbd58dd728a013bef221e4d5c8fbcaf8e03 Reviewed-on: https://gerrit.libreoffice.org/37199 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2017-04-19Add BottomSheetBehavior to formatting toolbarbrainbreaker4-21/+29
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>
2017-04-18tdf#96770 android: disable 'parts' in text documentsXimeng Zu2-1/+2
Text documents only have one part, so 'parts' button in the menu should be disabled. Change-Id: Id36a57bcf35bc6347136dda82d8da2d7ca308285 Reviewed-on: https://gerrit.libreoffice.org/36538 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2017-04-18tdf#96799 android: does not switch edit mode to viewXimeng Zu2-3/+18
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>
2017-04-18Double tap zooms in and outXimeng Zu1-0/+13
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>
2017-04-18Discard StorageAccessFramework for creating new documentsbrainbreaker5-102/+97
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>
2017-04-18tdf#96764 - Android Viewer does not show page countXimeng Zu8-2/+198
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>
2017-04-18tdf#96811 Android Viewer doesn't focus on the word you search.Ximeng Zu2-1/+81
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>
2017-04-18tdf#106368 android: restrict zoom to page widthXimeng Zu5-10/+11
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>
2017-04-10Fix typos to complete commit b35552f39503Andrea Gelmini1-1/+1
Change-Id: I2a10f9989e682dfc88f3b1d5864bfce1637933ab Reviewed-on: https://gerrit.libreoffice.org/36359 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2017-04-10Fix typo: 'forgeround' in multiple filesXimeng Zu19-19/+19
Fixed typo: forgeround --> foreground in 19 files. Change-Id: Idb4c9ccd98a949a2574cdbd5b44f91509b9856a9 Reviewed-on: https://gerrit.libreoffice.org/36154 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Gautam Prajapati <gautamprajapati06@gmail.com> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2017-04-05android: simplify some if statements, remove redundant variablesChristian Lohmaier7-37/+13
Change-Id: I55a866ac66ffeab5fe2ebb45d86f68558b468650
2017-04-05android: getDrawable(int) is deprecatedChristian Lohmaier2-9/+9
additionally reduce scope of to package-private Change-Id: I46ca55c5ef7daf992407beef53f5da939bf9066a
2017-04-05android: otg_missing_error is not a format stringChristian Lohmaier1-1/+1
Change-Id: I8d06218b595f619c12d0402f8d8319a35a37daa1
2017-04-05android: using VectorCompat requires to use app:srcCompatChristian Lohmaier1-6/+6
Change-Id: Ifd66e104519ace4d1d27f1312b66d873476ed2c3
2017-04-05android: position in RecyclerView must not be treated as fixedChristian Lohmaier1-2/+2
Change-Id: I162428edb00550d496a5cf580d00189d17ea2587
2017-04-05android: prevent NullPointerException in RecyclerViewChristian Lohmaier1-1/+1
Change-Id: I31ffaf62ce470630556db3cf3f4d7a643ad39f5a
2017-04-05android: defaultValue is not the same as a hintChristian Lohmaier1-4/+3
also flag the password field as password entry Change-Id: I91d74335ac63ea6ddbe8df274a9b0e130fc14744
2017-04-05Fix typo: inticator -> indicatorXimeng Zu1-3/+3
The related code is not being used now... So, it's safe to just correct it before it is put to use. Change-Id: I1ba5f1d6d511c965c0ce08dd08bfcabc567da2c3 Reviewed-on: https://gerrit.libreoffice.org/36103 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-03-30android: restore tabbed toolbar removed by accidentTomaž Vajngerl1-0/+19
commit 1503769fe15c122ff2bb8f6f7e7b4ab72656ddc2 removed tabbed toolbar by mistake Change-Id: I72e408d8e67b846e227d4563a8cd8455c1e73c29
2017-03-30tdf#96816 android: top part unreachable with soft keyboardXimeng Zu1-2/+2
Uncomment in Manifest file the line related to input method: android:windowSoftInputMode="adjustResize" This allows for panning and zooming to the top part of the document. Change-Id: Ic75489071add6b52948d381f4f8b7205148b78ef Reviewed-on: https://gerrit.libreoffice.org/35721 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> Tested-by: Tomaž Vajngerl <quikee@gmail.com>
2017-03-30Add superscript and subscript text formatting optionsbrainbreaker4-1/+60
This commit adds superscript and subscript text formatting options in formatting toolbar Change-Id: Id6966eb11b71b269431a21f46bd7c597fdcdb08c Reviewed-on: https://gerrit.libreoffice.org/35778 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2017-03-30tdf#106325 - No way to create a new Documentbrainbreaker16-67/+585
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>
2017-03-26Fix typosAndrea Gelmini1-1/+1
Change-Id: Idbf0aa261b829e83d4c08a2e989a4ced871dc6de Reviewed-on: https://gerrit.libreoffice.org/35616 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-03-19tdf#106317 bottom tabbar, grow/shrink font, insert line,rectTomaž Vajngerl8-162/+386
- 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
2017-03-19tdf#106369 added toggle status ability for the list buttonsMert Tumer3-0/+12
Change-Id: Ic3132441bac57abf36e3588e6871c5b14a47c25d Reviewed-on: https://gerrit.libreoffice.org/35427 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2017-03-19fix typo/grammar: "the the" --> thedennisroczek1-1/+1
* also removing pointless ASCII art (tdf#62475) * truncate ending whitespace in Doxyfile Change-Id: I59b012f41ac0d170216229da85a49aa41689dee5 Reviewed-on: https://gerrit.libreoffice.org/35151 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2017-03-17Made toolbar title use the name of the current diraleksandar-stefanovic1-2/+5
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>
2017-03-16tdf#106369, New feature, Inserting numbering/bullets format listsAtef hares6-0/+42
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>
2017-03-14Bumped Gradle version to 3.3, gradle plugin to 2.3aleksandar-stefanovic2-3/+3
Change-Id: Ieb5c9a7855a57db5659c7f97902a12bd3afab328 Reviewed-on: https://gerrit.libreoffice.org/35200 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
2017-03-12Made sort menu use radio buttonsaleksandar-stefanovic2-63/+83
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>
2017-03-12Combine List Item & Grid Item Adapters of File Explorer Viewbrainbreaker4-125/+41
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>
2017-02-27Improve the Document Provider UXbrainbreaker9-2/+78
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>
2017-02-25Moved navigation items to XMLaleksandar-stefanovic2-49/+57
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>
2017-02-25Fixed text alignment in listaleksandar-stefanovic2-1/+2
Changed text alignment in file browser to not center horizontally, because it should be glanceable and therefore should be left-aligned (ideally the start-aligned). See https://material.io/guidelines/components/lists.html . Change-Id: I383141bc2f49b63927c136d911f50cfd15bdef45 Reviewed-on: https://gerrit.libreoffice.org/34290 Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com> Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
2017-02-17tdf#99967 Drop Web WizardSamuel Mehrbrodt1-1/+0
Change-Id: Ibc0f45a03e16f3fe4ee54b24de30ba88e43a4aab Reviewed-on: https://gerrit.libreoffice.org/26381 Reviewed-by: Julien Nabet <serval2412@yahoo.fr> Tested-by: Julien Nabet <serval2412@yahoo.fr>
2017-02-16Fixed the runtime crash of app by catching exceptionbrainbreaker1-0/+2
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>
2017-02-15Fixed the margins of list items of File Recycler Viewbrainbreaker4-12/+28
Screenshots of the change:- Before: 1. https://s19.postimg.org/bbs91keyr/Screenshot_20170212_182941.png 2. https://s19.postimg.org/k5j5io1xf/Screenshot_20170212_183334.png Now: 1. https://s19.postimg.org/4o08spkub/Screenshot_20170212_222359.png 2. https://s19.postimg.org/5p0hhu1tv/Screenshot_20170212_222406.png Change-Id: I3137ce2648c4dda30d7bbe93245618a83e9048c0 Reviewed-on: https://gerrit.libreoffice.org/34175 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com> Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
2017-02-14Moved file filtering to a menu optionaleksandar-stefanovic7-53/+110
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>
2017-02-13Fix typosAndrea Gelmini1-1/+1
Change-Id: Iaf6bbe81f519d49b82f624282d786c8cc18d641c Reviewed-on: https://gerrit.libreoffice.org/34199 Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com> Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
2017-02-12Changed description of setting entriesaleksandar-stefanovic3-7/+12
Changed to make more sense to non-tech-savvy users. See https://material.io/guidelines/style/writing.html for writing guidelines. Changed grid default value from string to integer, since the value is effectively an integer, and no point in being a string. Change-Id: I6c1737927e7f9d20536756c3cb8b7059cf49500b Reviewed-on: https://gerrit.libreoffice.org/34074 Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com> Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
2017-02-11Moved "storage provider settings" to nav draweraleksandar-stefanovic4-9/+26
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>
2017-02-10Default Value added to File Explorer View Preferencebrainbreaker2-0/+3
Change-Id: Ibbca76cae7fb189d94c37397ad49e9cff2755cd2 Reviewed-on: https://gerrit.libreoffice.org/34082 Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com> Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
2017-02-09Explorer File View option in Settings working nowbrainbreaker5-44/+90
Explorer file view option in Settings is working now. To listen to the preference updates in the app a custom class SettingsListernerModel has been added. SettingsListenerModel.java file contains the methods to instantiate and set OnSettingPreferenceChangedListener in the implementing class. LibreOfficeUIActivity implements this listener and it is triggered by onSharedPreferenceChanged() method in SettingsActivity. This class can also be used to listen to other preference changes in Settings. Change-Id: I063024df01cf183d2a6211648e32805795af20a9 Reviewed-on: https://gerrit.libreoffice.org/34012 Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com> Tested-by: Aleksandar Stefanović <theonewithideas@gmail.com>
2017-02-07android: move sort options to separate menualeksandar-stefanovic3-6/+36
This is one in a series of commits of trying to unclutter the context menu, which was pretty unorganized. Change-Id: I8a9473041730492a0b60c6b71fd7fd7996cedd89 Reviewed-on: https://gerrit.libreoffice.org/33768 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2017-02-07Add recents files to the document browseraleksandar-stefanovic5-23/+313
The recents mechanism works like this: Every time the file is opened, it saves that file to the shared preferences set, by putting it in the first place, and removing the oldest file from the list, if there are more than 4 recent files. It also adds dynamic App Shortcuts if the device is 7.0 and above. Screenshot: http://imgur.com/a/7kWOl Edited the layout to add a new RecyclerView for recent items, as well as the headers for both the recycler view's. Recent files appear only if in home directory, below app bar and above the file browser. This could be subjected to change in the future. Screenshot of the recents section: http://imgur.com/a/qrqZq Change-Id: I5c99aa26351d9ad2313e18b5b696d04a782e6155 Reviewed-on: https://gerrit.libreoffice.org/33759 Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> Tested-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2017-02-07Removed static context from DisplayPortCalculatoraleksandar-stefanovic3-31/+37
Refactored many fields of DisplayPortCalculator to not be static, so that they could use the Context object from the constructor. Once refactored, the static context object could be removed from LibreOfficeMainActivity. Change-Id: Ic23030b74a24c753a4a2d2086fc6301eeb9d8728 Reviewed-on: https://gerrit.libreoffice.org/33765 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
2017-02-06Retaining the default file explorer viewbrainbreaker1-0/+2
Change-Id: I273ee17fc94e9d6e3b73ca0b9a4853a632123bd0 Reviewed-on: https://gerrit.libreoffice.org/33946 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Aleksandar Stefanović <theonewithideas@gmail.com>