315 Commits

Author SHA1 Message Date
Eloy Lafuente (stronk7)
dbaf9d448d Merge branch 'wip-MDL-22955-m24' of git://github.com/samhemelryk/moodle 2012-10-10 00:35:11 +02:00
Eloy Lafuente (stronk7)
b9570857db Merge branch 'MDL-35141-master' of git://github.com/sammarshallou/moodle 2012-10-09 00:46:49 +02:00
Sam Hemelryk
436dbeecda MDL-22955 theme: Added ability to use SVG format for icons 2012-10-08 09:16:14 +13:00
Rex Lorenzo
ff37d63c1b MDL-35376 - Shortcut/alias not working for Private file repo 2012-09-11 14:23:12 -07:00
sam marshall
ed0f5a9507 MDL-35141 Filelib: No icon for epub filetype 2012-08-30 12:13:56 +01:00
Marina Glancy
db02d84a40 MDL-34290 remove class cache_file as not used
in fact we have moodle filepool that can work perfectly for caching files, no need to create new class and storage
2012-08-29 11:56:17 +08:00
Marina Glancy
7e1e775fa4 MDL-34290 Allow to have several requests to the same instance of oauth_helper 2012-08-29 11:56:16 +08:00
Marina Glancy
bc6f241ca2 MDL-34290 repository API: add repository function to import referenced file
it must be independed from sync_external_file because sync often does not actually download contents, it is used just to retrieve
the size of the file. Besides the timeouts for get_file and sync requests are very different.

Also add option to send_stored_file() to ignore reference and send cached contents
2012-08-29 11:56:15 +08:00
Marina Glancy
14b7e50001 MDL-34290 update all references after the source is changed
- When several records in {files} have the same record in {files_reference} and the synchronisation is performed, we need to update
all records in {files} so all files know if source is changed and that sync was performed;
- also when local moodle file content is changed we immediately update all files referencing to it (therefore sync of references
to the local files is unnecessary);
2012-08-29 11:56:00 +08:00
Marina Glancy
a3c94686aa MDL-34290 curl class: add functions to return error code and to download one file 2012-08-28 10:23:36 +08:00
Eloy Lafuente (stronk7)
76b97631b0 Merge branch 'MDL-25012' of git://github.com/danpoltawski/moodle
Conflicts:
	lib/db/upgrade.php
	version.php
2012-08-15 00:41:04 +02:00
Dan Poltawski
850d2db82a MDL-25012 - blogs: introduce a specific 'enabled' config setting
Rather than overloading the $CFG->bloglevel setting which had a
confusing UI in the appearance subsystem.

In order to achieve this we modify take the defaults from the existing
bloglevel setting and set that for $CFG->enableblogs. Note that in order
to prevent a bad default settings from being set we also set
$CFG->bloglevel to a valid 'enabled' setting.
2012-08-06 11:25:22 +08:00
Petr Škoda
faf40ca3e3 MDL-34585 fix broken blog file access control 2012-08-02 09:58:16 +02:00
Adrian Greeve
b0c6dc1cac MDL-34465 - lib - Replacing get_context_instance with context_XXXX::instance (group 8) 2012-07-27 10:10:46 +08:00
David Balch
96aeb5be35 MDL-34143 Add file type information for .mdb .accdb (MS Access databases) 2012-07-06 09:44:25 +08:00
Eloy Lafuente (stronk7)
2fba8f5a92 Merge branch 'wip-MDL-34063-master' of git://github.com/marinaglancy/moodle 2012-07-05 18:34:27 +02:00
Sam Hemelryk
c425663c4c Merge branch 'MDL-27125_master_2' of git://git.catalyst.net.nz/moodle-r2 2012-07-04 09:32:45 +12:00
David Balch
c7aed1e11b MDL-34063 XHTML files should use the HTML icon, not the markup icon 2012-07-02 14:25:56 +08:00
Marina Glancy
3b6629c088 MDL-33948 file_save_draft_area_files() validates if references are allowed and allows unlimited file size 2012-07-02 14:11:55 +08:00
Martin Dougiamas
386a862f95 MDL-34004 - reinstate the custom HTML icon as separate from other markup icons, because it usually means a "page" to most people that displays in the browser. These icons are temporary (but workable) until Barbara can put in some nice ones that work as a set. The 16px one is from Moodle 2.2 and the others are copies of "unknown". 2012-06-25 23:05:44 +08:00
Barbara Ramiro
5a322c8cfc MDL-33381 Icon label removed for all file types to make it generic 2012-06-21 18:19:33 +08:00
Marina Glancy
83d2700ec9 MDL-33832 Fixed filling of files.source field
- also supress the error on unserialise (because people already may have broken files.source field)
- also display details about unparseable JSON error
- make source field look the same across repositories
2012-06-20 16:09:37 +08:00
Jonathan Harker
def4a8f5b7 MDL-27125 better manage file handles when downloading multiple files.
Based on Dongsheng Cai's branch: s11_MDL-27125_curl_file_handler_master
2012-06-20 16:46:29 +12:00
Dongsheng Cai
d6453211b6 MDL-33513: Make files->source field consistent 2012-06-15 14:51:07 +08:00
Dan Poltawski
4585e6ac98 Merge branch 'wip-MDL-33550-master' of git://github.com/marinaglancy/moodle 2012-06-14 16:23:08 +08:00
Dan Poltawski
414ce30812 Revert MDL-33513
This reverts commit b2cf2b807f7a7c8d1a02ebb52038c61cc63a1494.
This reverts commit 24b96f01702571989fa77a05c5cd11b9fedc2745.
This reverts commit 39c60294a6a027ae56f4b9eda159bb589b60c0c0.
This reverts commit 8a288971e25eaaa4c8cbd67e450cee0e12435d4e.
2012-06-14 13:57:45 +08:00
Dan Poltawski
cd925ac79b Merge branch 'dev_MDL-33513_files_source' of git://github.com/danpoltawski/moodle 2012-06-14 11:12:21 +08:00
Marina Glancy
0b2bfbd1c6 MDL-33550 Correctly process situation when file reference source is missing
- do not die with fatal error if source file in moodle internal repository is missing;
- moved code duplication for moodle repositories into class repository (functions send_file, get_reference_details, get_file_by_reference, get_file_reference);
- update file status after repository::sync_external_file so we know that it is missing (or not missing anymore). Do not run this function more than once for file within one request;
- display readable name for Private Files and Server files with the new format;
- display broken icon in filemanager if we know that source is missing, display information (for admin) where it was located before: see repository::get_reference_details() and extending classes;
- removed unnecessary queries in stored_file::sync_external_file();
- syncronize files before displaying it's size in mod_resource, do not query  directly
2012-06-13 12:11:06 +08:00
Marina Glancy
ff32444a7c MDL-33590 Correctly determine that file is an archive to enable unzip in filemanager 2012-06-13 08:57:10 +08:00
Dongsheng Cai
8a288971e2 MDL-33513: Make files->source field consistent 2012-06-10 17:47:00 +10:00
Sam Hemelryk
238858e362 MDL-26277: Fixed whitespace post integration 2012-06-06 09:15:18 +12:00
Sam Hemelryk
7df271d9b3 Merge branch 'MDL-27559-master-v2' of https://github.com/mackensen/moodle 2012-06-06 08:51:11 +12:00
Dan Poltawski
9856d05c26 Merge branch 'MDL-33378-tiff-thumb' of git://github.com/mudrd8mz/moodle 2012-05-29 15:00:21 +08:00
David Mudrak
77a439336f MDL-33378 file thumbnail falls back to the default mimetype icon
If for some reason the thumbnail generation fails, the default core
mimetype icon for the given file is sent to the browser.
2012-05-28 12:19:05 +02:00
Sam Hemelryk
c67b08828c MDL-18763 Fixed up typo in comments of new pic size 2012-05-28 16:52:53 +12:00
Sam Hemelryk
a2aba3f612 Merge branch 'w21_MDL-18763_m23_avatar512' of git://github.com/skodak/moodle 2012-05-28 16:50:46 +12:00
Charles Fulton
80c27aab8c MDL-27559 opendir: validate directory pointer on open 2012-05-25 08:52:12 -07:00
Dan Poltawski
0fb13aa3d8 Merge branch 'dev_MDL-33127_draft_storing' of git://github.com/dongsheng/moodle 2012-05-24 16:34:32 +08:00
Dan Poltawski
2625d99b52 Merge branch 'wip-MDL-33144-master' of git://github.com/marinaglancy/moodle 2012-05-24 16:32:32 +08:00
Marina Glancy
ae7f35b934 MDL-33144 display filetype icon and mimetype based on extension
- use finfo to determine mimetype of a file only when it is unknown from file extension
- display filetype icon and mimetype in filemanager based on file extension
- fixed a small issue with specifying extension instead of group in file_get_typegroup()
- allow only web-compartible image types when embedding into editor or using in database field
- created new groups web_video and web_audio to use in resource module
2012-05-23 14:51:55 +08:00
Rajesh Taneja
34b455fc98 MDL-32155 blocks: User can't access file, if block is hidden or doesn't have block:view capability 2012-05-23 12:52:27 +08:00
Dongsheng Cai
65fead53fb MDL-33127 Fixed the problem when storing draft files 2012-05-22 14:50:47 +08:00
Dan Poltawski
21878be7c8 Merge branch 'wip-files23-fixes' of git://github.com/marinaglancy/moodle 2012-05-22 14:32:35 +08:00
Marina Glancy
e563582760 MDL-33158 fixed bugs with restricting file typs in filepicker
- extension was returned without leading dot which resulted in improper validation
- fixed human-readable mime type in error message
- fixed youtube repository to support video files and pass filetype validation
2012-05-22 14:24:11 +08:00
Marina Glancy
ca9875db1b MDL-33160 fixed some icons and groups for file types 2012-05-22 14:18:06 +08:00
Dan Poltawski
1082e7daf7 MDL-31901: Fix trailing whitespace 2012-05-21 19:18:44 +08:00
Dan Poltawski
7d44f9c2a2 MDL-28666: filelib - remove unusused globals 2012-05-21 18:21:36 +08:00
Marina Glancy
a8d6dda4f2 MDL-32247 fixed bug with displaying icon for unknown filetype, fixed merge mistakes 2012-05-21 17:12:55 +08:00
Barbara Ramiro
0f1bdd0d2c MDL-32900 Change Icons to FileTypesIcons 2012-05-21 16:37:14 +08:00
Marina Glancy
559276b153 MDL-32247,MDL-32831,MDL-32900 Use correct url building of file type icons
- function get_mimetypes_array() now contains also information about filetype groups and language strings
- use 'smart' human-readable mimetype description
- never determine filetype group based on filetype icon image! remove function mimeinfo_from_icon()
- get rid of class filetype_parser and file lib/filestorage/file_types.mm, replaced with functions file_get_typegroup(), file_extension_in_typegroup() and file_mimetype_in_typegroup()
- support multiple icon sizes, not only 16 and 32
- retrieve filetype icon only using proper functions file_..._icon() from lib/filelib.php throughout the code
- increase size of repository thumbnails to 90 and icons to 24 (will take effect when new icons exist)
2012-05-21 16:01:04 +08:00