[wx-dev] Re: checking that a wxFileSystem handler is registered
Vadim Zeitlin
vadim at wxwindows.org
Mon Jul 10 19:19:00 PDT 2006
On Mon, 10 Jul 2006 11:09:25 +0200 Francesco Montorsi <f18m_cpp217828 at yahoo.it> wrote:
FM> Vadim Zeitlin ha scritto:
FM> > On Mon, 03 Jul 2006 14:08:39 +0200 Francesco Montorsi <f18m_cpp217828 at yahoo.it> wrote:
FM> >
FM> > FM> BTW, also on this subject, I think that, since wxFileSystem uses the
FM> > FM> list of handlers sequentially, it may be very useful to:
FM> > FM>
FM> > FM> 1) add an InsertHandler() function which just calls m_Handlers.Insert()
FM> > FM> function
FM> >
FM> > Does it make sense to have 2 handlers for the same URI schema?
FM> some times it could as I could create a custom handler which opens the
FM> "http://mywebsite.com" and "http://mywebsite.net" URLs only in a special
FM> way and leaves all others http:// addresses to handle to
FM> wxInternetFSHandler.
FM>
FM> I know this is a rare situation but it could still be useful for some
FM> users ;)
Yes, it's a good point which I failed to see, thanks for the explanation!
FM> > BTW, another possibility would be to just make AddHandler() add the new
FM> > handler in the beginning of the list because I think most (all?) of the
FM> > time you want the last added handler to be the most prioritary one.
FM> yes, I think this could be a good choice.
...
FM> Ok - then let me know which function (Insert/AddHandler) should be
FM> added/changed and I'll submit this small patch.
If both prefer to change AddHandler() as described above I think it's
better to do it like this.
TIA!
VZ
More information about the wx-dev
mailing list