Commit graph

30 commits

Author SHA1 Message Date
Matthew Tretter
8a35b3a3dd Registration and connection of sources 2012-10-12 23:08:26 -04:00
Matthew Tretter
fe803f8981 Beginning to move functionality into "sources"
Before this is applied, we're going to have to make it so that the
image cache strategies are passed the source file, not the other file.
2012-10-10 00:18:54 -04:00
Matthew Tretter
06e5f45904 Remove unused imports 2012-10-04 23:43:02 -04:00
Matthew Tretter
436a73dc9a Remove image cache backend field registration 2012-10-04 23:28:55 -04:00
Matthew Tretter
ce08448207 Rename register_spec() to set_spec_id() 2012-10-04 23:22:25 -04:00
Matthew Tretter
56c66f4883 Back ProcessedImageField with spec registry 2012-10-04 23:15:16 -04:00
Matthew Tretter
82d0e4be73 Remove unused imports 2012-10-04 23:03:22 -04:00
Matthew Tretter
f289ff3199 Back ImageSpecFields with spec registry
This marks a major step towards centralizing some of the "spec" logic
and creating a single access point for them. Because `ImageSpecFields`
are just alternative interfaces for defining and registering specs,
they can be accessed and overridden in the same manner as other specs
(like those used by template tags): via the spec registry.
2012-10-04 22:56:26 -04:00
Matthew Tretter
0cc7938400 Re-integrate receivers module
Somewhere along the line, a change got merged that stopped using the
receivers module. This re-integrates it and moves changes made to the
old receivers (static methods on ImageSpecField) to them.
2012-10-04 21:44:55 -04:00
Matthew Tretter
d2087aa168 Create ImageSpecs; remove generators 2012-10-04 21:37:20 -04:00
Matthew Tretter
ba9bf1f877 Add image cache strategies
This new feature gives the user more control over *when* their images
are validated. Image cache backends are now exclusively for controlling
the *how*. This means you won't have to write a lot of code when you
just want to change one or the other.
2012-10-03 22:23:11 -04:00
Matthew Tretter
8a2738ca8a Add backend for caching image state 2012-09-06 22:11:23 -04:00
Matthew Tretter
2ad3791d9d Reorganize image cache backends 2012-09-06 09:11:18 -04:00
Matthew Tretter
197dfb3485 Add VALIDATE_ON_ACCESS setting 2012-09-06 09:08:45 -04:00
Matthew Tretter
7ad5cf4db5 Use hashes for generated image filenames
While this change means users can no longer specify their own filenames,
changing a property of a processor, for example, will now result in a
new image. This solves a lot of the previous invalidation issues.
2012-07-19 23:48:28 -04:00
Matthew Tretter
becee54c03 Fix pickling of ImageSpecFieldFile
Code now passes the test added in 118f6e4. Hopefully this will
address #97.
2012-07-18 22:25:26 -04:00
German M. Bravo
784afcc95d Simplified path join for the cache 2012-05-12 15:39:12 -04:00
Matthew Tretter
af7c12cb68 Tell people to import fields from the models module 2012-04-20 21:43:59 -04:00
Matthew Tretter
667e265c94 Refactored AutoConvert into prepare_image
Because of its need to return kwargs for ``Image.save()``, it never
really fit the mold of a processor.
2012-04-20 21:37:43 -04:00
Matthew Tretter
8044b97a33 Extract suggest_extension util from generator 2012-04-19 21:33:52 -04:00
Matthew Tretter
6e4a8d1b58 Woah, globals 2012-04-09 21:27:09 -04:00
Matthew Tretter
3a5d7da0d8 Validate the image any time the file is required
This means that accessing `path` or `size` will also validate,
closing #109
2012-02-23 17:46:57 -05:00
Matthew Tretter
b016065807 Fix inheritance of ImageKitMeta objects
Fixes #100
2012-02-17 21:10:09 -05:00
Matthew Tretter
84d36791b8 Pass the pickle test; should fix #97 2012-02-17 20:07:50 -05:00
Matthew Tretter
677c52b730 Rename descriptor and file to match Django 2012-02-17 18:39:51 -05:00
Matthew Tretter
6816196da7 Use "super" 2012-02-17 18:22:05 -05:00
Eduard Iskandarov
fa244cdcc9 fix unicode error 2012-02-16 19:47:22 +06:00
Timothée Peignier
98066eea93 fix import and formatting 2012-02-14 17:34:51 +01:00
Matthew Tretter
3a3f941e2c Pull field utilities out into their own module 2012-02-13 21:47:53 -05:00
Matthew Tretter
8cdbd96a1f Add files module 2012-02-13 21:44:29 -05:00