aboutsummaryrefslogtreecommitdiff
path: root/src/com/cyanogenmod/filemanager/ui/widgets/NavigationView.java
Commit message (Collapse)AuthorAgeFilesLines
* Refresh icons view when switching between portrait and landscapeKamaljeet Maini2016-05-091-0/+12
| | | | | | | | | | | | When switching between portrait and landscape modes, the icons view needs to be updated to re-arrange the icons based on updated width. Added a new method for refreshing icons view mode. This method is called during orientation changes. Issue-Id: FEIJ-492 Change-Id: I9c95357a7d4f57b223147e774838e4fdc19f5e89
* Thumbnail update on copy and overwrite issue of picturesroot2015-10-211-1/+7
| | | | | issue-id: QRDL-1077 Change-Id: I10d3c861141590806a8e5b9c665b4f4f4b74141a
* Use System Resolverherriojr2015-10-161-2/+2
| | | | | | | | | | | | | | | | | | | | | Converting to using the system resolver. The logic has changed slightly in the following cases: Open -- Tries to start activity, falls back to EditorActivity on failure Open With -- Uses Chooser and populates Editor if not already there Falls back to EditorActivity on failure Click on FSObject -- Same as Open Sending Object -- Same as Open Cleaned up code around this a little since there were unused parameters. Note: The Chooser will only show EXTRA_INITIAL_INTENTS if there are other options as well, which is why we have to do the check up front to see if we need to add it, and falling back to just using the Editor if nothing exists to handle it. Issue-Id: CYNGNOS-1236 Change-Id: I803b86cf6bfec80bbc886025be43ce800afd3be1
* FileManager: Fix shortcutsRichard MacGregor2015-08-211-0/+7
| | | | | | | | | | | | | | | | | | | | Fix shortcuts behavior when FileManager is already open. Repro: 1) Open FileManager 2) Create shortcut for folder 3) Navigate to another folder (not including new folder) 4) Switch to homescreen (launcher) 5) Select the shortcut created in step 2 Expected behavior: Navigate to shortcut folder Observed behavior: FileManager shows last navigated directory (before going to launcher) Change-Id: I1db814a8990073f8d2de88f90b23b51a1e77cf8e Ticket: QRDL-1034
* Fix Navigation back from Searchherriojr2015-08-181-6/+17
| | | | | | | | | When entering a search result and then backing out all the way, a history item wasn't being added for the directory the search was happening in. This fixes it. Change-Id: I28d5b290a18076f1156f699426420ca78fb3eee6 Cherry-Pick: b4fc75077143de0ff9e26d8d2644d879ccdc0e84
* Refresh: stop refreshes in actionStephen Bird2015-08-171-15/+18
| | | | | | | | | | | If a refresh happens while another refresh is occuring, make sure that that old refresh is cancelled. In addition to this, remove some old logic that conflicted with itself. Also, keep ahold of the previous directory before running the task. Ticket: QRDL-1002 Change-Id: Ibc1f3d468243bc124d3baf259af21464f3c03c84 (cherry picked from commit 080405b548865e6b118b56ca29ed6a6f0d10bcc5)
* Fixed search to actually open the clicked folderherriojr2015-08-051-3/+7
| | | | | | | | | | | | | When a folder was clicked in a search, what was happening is the refresh() in onStart() was being executed after onActivityResult(), so the changeCurrentDir() executed in onActivityResult() was being overriden by the refresh in onStart(). Since the mCurrentDir wasn't being set until the NavigationTask ends, it would always go back to the original directory. The change is to make the refresh not happen if a NavigationTask is currently under way. Change-Id: I5c354554c9b15fc9d14b4665852b40fb6a1f8853 Ticket: QRDL-932
* Revert "Made NavigationView reliant on FileObserver to keep up to date."herriojr2015-08-051-69/+43
| | | | | | This reverts commit 7b09bb0f1390b72d0ac18484721998eaf805e605. Change-Id: I24b6115c89e568f6895a3a9d0c074151b85c0be2
* Made NavigationView reliant on FileObserver to keep up to date.herriojr2015-07-311-43/+69
| | | | | | | | | | | | | We no longer deal with having to refresh a directory upon reentering. Instead we now just listen on the directory for changes and update as necessary. This will make it much more difficult to get out of sync with the file system in pretty much all situations. Changed per comments on patch to no longer do refreshes for the list when items change as the FileObserver handles all of this. Change-Id: I28a6af965708ce76107a09d6b931f4c7bafb8365 Ticket: QRDL-932
* Moved the sort of the data set off the UI Thread.herriojr2015-07-221-9/+15
| | | | | | | | For large data sets, this can cause slowdown on older devices or if you have a significant data set size. Change-Id: I1eeea9132df0d4e5c8dad17009b648826e3386c6 Ticket: QRDL-931
* [CMFileManager]Fix the FileManager Crash.kai.cao2015-05-211-0/+3
| | | | | | the file manager crash sometimes. Change-Id: I775d30f4f81c97a178c93c05ae83a3336fb4caa4
* Prevent possible OutOfBoundsExceptionMartin Brabham2015-05-191-0/+6
| | | | Change-Id: I8fc90a2ade069764732c35b71c5ae450d5d3cc5a
* Implement a dialog that warns the user that we must expose the content of ↵Martin Brabham2015-04-171-0/+5
| | | | | | | | | | the file by copying it out to an unsecure location in order to allow the external applications to read the files. Change-Id: I163ccd21678f413170e44cf3e8d341cd4747b1ac (cherry picked from commit 58928e7facbdd63d4320748b277e94417fe402bb)
* Fix support for USB OTG.Matt Garnes2015-04-021-2/+2
| | | | | | | | | | | Properly listen for the Broadcast with an IntentFilter that includes the path data scheme. Reload the mounted volumes upon ACTION_MEDIA_MOUNTED AND ACTION_MEDIA_UNMOUNTED. Change-Id: I71d90978fef05419d912ef2398bf99c23fdefee6 (cherry picked from commit e3922e43c8988c499c85115f1f14bef8c925e1ee) (cherry picked from commit 8656db649d0a88fc126e468b7ac81d8d3ea091ae) (cherry picked from commit 860ef9fbf513e1a4267e391453a2021d0ac20f63)
* cmfm: secure storage and other improvementsJorge Ruesga2014-11-101-0/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for virtual filesystems and implements a SecureStorage filesystem (a password protected area) mounted in /storage or /sdcard/storage (in chrooted environments). Also includes a better print support and a cleanup of the code and design of the menu drawer. Bump version to 2.0.0 Required: https://github.com/jruesga/android_external_libtruezip located in external/libtruezip Patchset 4: Fix selection of unmounted virtual storages. Fix actions on virtual mount points folders. Fix strings and typos. Change drop for delete secure storage. Patchset 5: Move actionbar buttons to navigation drawer Remove history position Patchset 6: Update theme preview images Fix filesystem status image on theme change Patchset 7: Fix binary file detection in editor (including unicode files) Patchset 8: Fix unsafe operations in virtual mountpoint logic Patchset 9: Rebase Change-Id: I65511352ca649dcbf238c8b07cf8c22465296e8e Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
* Save scrolling position and restore it when going backKirill Rakhman2013-12-171-59/+81
| | | | | | | | Patch 1-3: Clean up Patch 4: Don't scroll in the wrong direction Patch 5: Remove logging and fix indentation Change-Id: I5dfa92829a11ce94c4df9bb9891715b48f2b0900
* CMFM: Fix more deadlocksJorge Ruesga2013-11-291-301/+281
| | | | | Change-Id: Iad7042126436c26f93f384358082d4fb0e780352 Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
* CMFM: Fix deadlockJorge Ruesga2013-11-151-0/+4
| | | | | | | Change-Id: I89c45f03b2ce94666764fc63ca8c4668a71ef7e5 JIRA: CYAN-2650 Issue: https://jira.cyanogenmod.org/browse/CYAN-2650 Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
* Some optimizations spotted during profiling.Danny Baumann2013-09-201-4/+2
| | | | Change-Id: Ice5cc24d2574894798370eaaae144713414eb6cf
* Implement showing of apk icon and image and video thumbs in listingJo De Boeck2013-09-201-153/+191
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patchset 8: Move some stuff to MimeTypeHelper Add cache Add image and thumbail support Add setting for this (defaul false for improve performance) Patchset 9: Fixed icon derp display Same size for all drawables Patchset 10: Async drawable load Shrink cache Patchset 11: Use layout's width and height to scale the images Patchset 12: Music album thumbs Patchset 13: Added suggestions Fixed FC Patchset 14: Use content observer for icons Keep context in icon holder Fix scroll position being reset on thumbnail load Patchset 15: Additional fixes and optimizations Patchset 16: Do not saturate the ui with constants redrawing Do not send back events while changing to a new directory Fix FC on HistoryActivity (creation of a ContentObserver inside of a non-ui thread) Added normalized media paths Patchset 17: Use a HandlerThread to handle the preview loads Patchset 18: Optimizations Patchset 19: Fix deadlock Patchset 20: Remove debug leftover Patchset 21: Fix whitespace Patchset 22: Misc. cleanup Change-Id: I0a4ea801ff0cfbf31dda125b8925e7d35f4c3c99
* CMFM: Editor initial highlight support + props syntax processor + others ↵Jorge Ruesga2013-03-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | features - This change enables support of syntax highlight in editor. Adds also the next syntax processors: * PropertiesSyntaxHighlightProcessor - Option for toggle "no suggestion" in editor - CleanUp Patchset 2: Theme color scheme support Patchset 3: Hexdump binary editor preference No suggestions editor preference Syntax Highlight color scheme Add android-syntax-highlight (CMFM) and color-picker-view libraries ColorPickerDialog and ColorPickerPreference Separate preference to its own file Extract themes strings from dark_theme.xml to strings.xml Rebased Change-Id: I9df65e6193d46ebafadee5d545dcde1fc5ce20e9 Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
* Allow picking of directories.Danny Baumann2013-01-231-1/+28
| | | | | | | | | | | | | | | | | This is used e.g. by k-9 to select an attachment storage path. There are a number of intent filter conventions for picking directories. In k-9's code I found the following: - action org.openintents.action.PICK_DIRECTORY, scheme file - action com.estrongs.action.PICK_DIRECTORY, scheme file - action Intent.ACTION_PICK, scheme folder - action com.androidworkz.action.PICK_DIRECTORY, scheme file Implemented is the third variant, as it's the most generic way to describe the intention. Change-Id: I8752fe0db923a9ca169cc09eeee6a13bb5236626
* CMFM: Properly handle async task exceptionJorge Ruesga2013-01-131-13/+17
| | | | | | | Use onPostExecute method for drawing in the UI thread Change-Id: I2a3731f5888789e8e151f63f562c7beee244a350 Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
* CMFM: Fix FC caused by accessing ui outside of UI threadJorge Ruesga2013-01-071-8/+14
| | | | | | | Patchset 2: Formatting Change-Id: I1323b4f92a64dd23afe4aa28d3569ce01d72c039 Signed-off-by: jruesga <jorge@ruesga.com>
* CMFM: Fix navigation view fade effectJorge Ruesga2013-01-061-6/+22
| | | | | | | | Use OnRelaunchCommandResult listener to finish the fade effect instead of doing in the async task, to ensure that cancels and failures results will finalize the fade effect. Change-Id: I872a4f468670dc425d96c9c7dfd5fe05b8d86b89 Signed-off-by: jruesga <jorge@ruesga.com>
* CMFM: Fixes and ImprovementsJorge Ruesga2013-01-051-25/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Some performance improvements: - Use stat instead of ls. This allow improve listing of directories with symlinks. Symlinks are resolved by File.getCanonicalFile. - Simplify ls, fileinfo, find and readlink command - Simplify the parsing of FolderUsage (only type, size and category is required), and avoid to load a lot of on unused objects - Add new file datetime information from stat: access, change and modify - Improve list, find and resolvelink java commands * FadeEffect and symlink handling * Remove context from AIDHelper and add new helpful methods * New getAbsolutePath method * Use file separator for paths and ROOT_DIRECTORY for root directory path * Organize startup - Initialize variables prior to register receivers - Load AID data for improve performance through caching - Load the theme base used by AOSP widgets * Allow Editor to show zero-length files Allow the editor to load zero-length files (like /proc/mounts) and change the buffer type to no editable in binary files. * Invert allowed mount points detection. This change inverts the algorithm for prevent unmount needed rw filesystems. Now uses known restricted filesystems instead of known allowed filesystems. Now filesystems like yaffs2, fuse, and other linux filesystems are allowed by default. * Remove unused xliff namespace * Add flagNoFullscreen to EditText widgets * Fix listview selectors of history and bookmarks * Fix race condition When the command was executed prior to block the execution, the thread wait for the timeout. Add a sync access check to ensure that prior to lock and wait the program executed is not finished. * Fix for async programs When the partial buffer received for an async program is not complete (ends with a EOL), the partial buffer was discarded. Add a new buffer with this lost chars to complete this bytes next time * Fix list command Use -n1 for xargs in list command to prevent "argument line too long" * If parent is null then assume that it is the root folder * Use only name and parent for equals method on FileSystemObject A FileSystemObject is the same if his name and path are the same. * Increase performance of adapters Use argument data when possible to avoid call the adapter methods * Do not clear selection on some actions Actions like create new file/folder, show properties and other actions that explicit requires clear the active selection, shouldn't removed the active selection. * Add a new additional line to dialog messages to fill the dialog * Fix spanish translations * Fix theme roulette on tablets * Clean NLS and Override warnings * Fix parse size data with dots * Add listeners after set the values to avoid raising triggers * Increase performance of adapters. Notify the data changed at the end of the changes, and only to super adapters (the internal structure has already been updated) * Ensure that all the Cursor references were closed after used them. * Remove unused SuppressLint * Clean up Change-Id: I4326e97cbc942c767829f1a0ff6b380ad768cfef Signed-off-by: jruesga <jorge@ruesga.com>
* CMFileManager: AOSP GET_CONTENT_DATA compatibilityJorge Ruesga2012-12-111-13/+17
| | | | | | | | | | | | | | | This change brings compatibility to GET_CONTENT_DATA for AOSP apps when using the PickerActivity: * Detect crop extra; use the com.android.camera.action.CROP action of Gallery3d to crop and return the requested image. This gets compatilibity for example with the contacts app, when a user try to set the image of a contact. * Detect android.provider.MediaStore.Audio.Media.EXTRA_MAX_BYTES; when this extra is present the PickerActivity only display (and allow select) files with a size lower than requested. * Detect Intent.EXTRA_LOCAL_ONLY; useless until CMFM allow access remote file systems. Change-Id: I1020458505b236653e869ec1c1f532dd6d686633
* CMFileManager: Themes support + Dark themeJorge Ruesga2012-11-111-6/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change enabled the theme support, and added a new dark theme under the package CMFileManagerThemes. To compile under build system, it must be enabled in vendor/cm/config/common.mk or vendor/cm/config/themes_common.mk (this was requested in change http://review.cyanogenmod.org/#/c/26311/) Themes were enabled in a new settings option. Under this setting the application show the user the available themes installed in the system. -------------------- For build new themes, developers should: - Create a new package that contains an activity with: * Permission: com.cyanogenmod.filemanager.permissions.READ_THEME * Action: com.cyanogenmod.filemanager.actions.MAIN_THEME * Category: com.cyanogenmod.filemanager.categories.THEME - Define the themes_ids, themes_names and themes_descriptions arrays-strings definitions for the themes that the package support. - Create a xxx_theme.xml for every theme that the package support, where the xxx is the id of the theme. Put your resources in this file, prefixing the resource with the id of the theme (xxx_). For a list of all supported resources see theme.xml in res/values of CMFileManager project. ------------------- Other fixes: * Protect console buffers from NPE * Fix code style of xmls (layouts, drawables, ...) Patchset 2: Fixed code style and added Christian suggestion Patchset 3: Added forgotten READ_THEME permission check as described in the note above. Patchset 4: Use centerInside in theme preview for better image fit Change-Id: I4142da6d9ed1b06318e47ff9c05f9a874c62f3ae
* Update the internal array when a item was removejruesga2012-10-281-7/+18
|
* Flinger gesture detection support (issue #8)jruesga2012-10-281-2/+112
| | | | | This allow the use of left to right swipe gesture to delete files or folders. Add a new setting to control this behaviour (active by default)
* Remove console selection (Issue #17) - Part II (Settings & Code)jruesga2012-10-271-1/+3
|
* Remove console selection (Issue #17) - Part I (UX)jruesga2012-10-261-1/+1
|
* Remove actions menu icon (issue #21)jruesga2012-10-261-83/+15
| | | | Remove the action menu icon and the default long-click action setting. Now, long-click always shows the action menu
* Change application name to 'File Manager' (issue #20)jruesga2012-10-261-0/+1154
Full refactoring of package from explorer to filemanager