I don't like the solution that looks for the $. It assumes that there
are only dots in resources (which is not necessarily the case).
Why don't you create the image in your component through a correct
context? Something along ...
html image src: (self context structure: aImageResource) url
Not sure if I recall the exact API.
On 18 May 2011 20:03, Nick Ager <nick.ager(a)gmail.com> wrote:
The change doesn't require the "random refactoring" I
> Assuming others think this is a reasonable idea, a problem arises in that
> WARequest doesn't implement #mimeType. I'd propose
> refactoring WAExternalFileLibrary>>#mimetypeForRequest: and
> Does that seem a reasonable course of action?
Instead I implement
| path |
path := self requestContext request url path.
^ (path notEmpty and: [ path last includes: $. ])
and modify PRPierFrame>>#notFound to read:
"This method is called whenever the current request cannot be resolved to a
self isFileRequest ifTrue: [ self requestContext respond: [: response |
response notFound ] ].
self context: (self context
structure: self context root
Anyone think this is a bad idea? If not I'll check it in.
Magritte, Pier and Related Tools ...