[squeak-dev] FileDirectory fails

Thiede, Christoph Christoph.Thiede at student.hpi.uni-potsdam.de
Fri Jun 19 18:37:18 UTC 2020


Quick objection regarding path format: Network paths should work, too. If I drop a file from a network share (\\MY-DEVICE\c\path\to\file.txt) into Squeak, FileStream cannot load this file. But PNGReadWriter class >> #formFromFileNamed: can load this file. So should the DropPlugin convert the paths or the image?


Best,

Christoph

________________________________
Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von Taeumel, Marcel
Gesendet: Sonntag, 14. Juni 2020 12:19:38
An: squeak-dev
Betreff: Re: [squeak-dev] FileDirectory fails

> It actually forces them when necessary…

You mean "also", not "actually". :-)

So, from within Squeak you can either use UNC paths directly or provide a too long path string to the plugin, which will then convert it automatically to its UNC representation, if it isn't already in such a form.

Here are working examples:

PNGReadWriter formFromFileNamed: '\\?\C:\Tools\squeak_trunk\ffi-icons\ffi-union.png'
PNGReadWriter formFromFileNamed: 'C:\Tools\squeak_trunk\ffi-icons\ffi-union.png'
PNGReadWriter formFromFileNamed: 'C:\Tools\squeak_trunk\way-too-long-path\way-too-long-path\way-too-long-path\way-too-long-path\way-too-long-path\way-too-long-path\way-too-long-path\way-too-long-path\ffi-icons\ffi-union.png'

Best,
Marcel

Am 14.06.2020 12:13:51 schrieb Tobias Pape <das.linux at gmx.de>:

> On 14.06.2020, at 12:06, Marcel Taeumel wrote:
>
> > This would be handled in the Windows FilePlugin.
>
> It supports UNC paths already.
>
It actually forces them when necessary…
-t

> Best,
> Marcel
>> Am 14.06.2020 10:36:43 schrieb K K Subbu :
>>
>> On 14/06/20 1:50 pm, Marcel Taeumel wrote:
>> >
>> > > On Windows, you need a triple (drive, dirname, entry).
>> >
>> > You could treat the "drive" as part of the "dirname", just like the
>> > leading "/" on Unix for the root path. The drive letter itself could be
>> > treated as a directory. Cygwin does this already (/cygdrive/c/...)
>> >
>> > On Windows UNC paths can be used to denote the "root" in a similar fashion:
>> > \\?\C:\...
>> >
>> > So, every path that begins with "\\" can be treated as root.
>>
>> Yes. With UNC, Windows paths may also be treated as (container, entry)
>> pairs. This would be handled in the Windows FilePlugin.
>>
>> Regards .. Subbu
>>
>



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20200619/7c624806/attachment.html>


More information about the Squeak-dev mailing list