Bug - shell extensions not handled correctly

Discussion & Support for xplorer² professional

Moderators: fgagnon, nikos, Site Mods

Post Reply
Luther
Member
Member
Posts: 38
Joined: 2004 May 02, 04:47

Bug - shell extensions not handled correctly

Post by Luther »

I have been working on a shell extension for a client. Since the client hasn't decided on a name yet, I just called my development version "Rename" (because I knew I would have to rename it). Windows Explorer had no problem with having two "Rename" menu entries, and would execute my shell extension when I clicked on it. I knew it was my shell extension, because it had a bmp next to it in the menu.

However, xplorer seems to use the *name* to determine the action. When I popped the right-click menu in xplorer, there were two "Rename" entries, and both of them did the same thing: highlighted the file name in an edit box for renaming.

The correct shell extension should be called regardless of its name.
User avatar
nikos
Site Admin
Site Admin
Posts: 15801
Joined: 2002 Feb 07, 15:57
Location: UK
Contact:

Post by nikos »

x2 takes over the "rename" verb otherwise nothing would have happened
but it doesn't rely on the menu name, it uses the "language independent" verb

you shouldn't be using reserved verbs!
Luther
Member
Member
Posts: 38
Joined: 2004 May 02, 04:47

Post by Luther »

As I said in my post, Windows Explorer worked fine with this - it correctly called my shell extension. xplorer does not conform to the way Windows Explorer works in this regard.
User avatar
fgagnon
Site Admin
Site Admin
Posts: 3737
Joined: 2003 Sep 08, 19:56
Location: Springfield

Post by fgagnon »

a tangential observation ...
This looks like a case where the m$ folks have bent the reserved verb "rule" a bit to make their product more user-friendly for a case where syntax makes it unlikely that the user meant to specify a verb. Of couse they also have a history in their apps of badly mis-guessing what the user wants, too. It's a double-edged sword, this attempt at user-friendliness.

Even so, nikos, maybe you could start a list of "special cases" (for consideration in v2, of course) where usage should logically override strict imposition of a 1-dimensional syntax rule.
User avatar
JRz
Gold Member
Gold Member
Posts: 560
Joined: 2003 Jun 10, 23:19
Location: NL

Post by JRz »

Luther wrote:As I said in my post, Windows Explorer worked fine with this - it correctly called my shell extension. xplorer does not conform to the way Windows Explorer works in this regard.
This doesn't necessarily mean we have to adopt all the 'bad' behaviour M$ Explorer is giving us. In this case (as Fred stated in his post preview to this one) the 'bad' behaviour is such that it coincidently leads to something you like.

The observation Nikos makes is still valid, I think. You shouldn't use reserved words, even though M$ Explorer 'allows' you to do this. Making use of such loopholes is usually the beginning of the end.... :cry:
Dumb questions are the ones that are never asked :turn:
Luther
Member
Member
Posts: 38
Joined: 2004 May 02, 04:47

Post by Luther »

I agree with Nikos and others who have pointed out that using reserved verbs is bad practice.

But however dumb that may be, let me ask everyone a question: if you had to come up with a spec for xplorer, where would you start? My point is very simple: xplorer does not conform to the "spec" in this area. And how can you or I (or anybody) know what else will be broken because of this discrepancy?
User avatar
JRz
Gold Member
Gold Member
Posts: 560
Joined: 2003 Jun 10, 23:19
Location: NL

Post by JRz »

Luther wrote:I agree with Nikos and others who have pointed out that using reserved verbs is bad practice.

But however dumb that may be, let me ask everyone a question: if you had to come up with a spec for xplorer, where would you start? My point is very simple: xplorer does not conform to the "spec" in this area. And how can you or I (or anybody) know what else will be broken because of this discrepancy?
Well, here is my answer, FWIIW: Why try to use a fault in M$ Explorer as starting point, while you have the opportunity to specify a non-reserved word as verb, with no difference in functionality at all, except that it now works in too?? Using a different name for the verb than 'Rename' will make it work in both M$ Explorer and X². So do not try to 'use' the anomaly created by Bill G. and co, just because it is there... :?

is designed to be a better Explorer than the version from M$. It is so in all cases in my view, including the way it handles shell extensions, because it confirms to the original specs, not the crooked ones which can be derived from behaviour of the implementation M$ has made out of it. :)

Next you'll have Nikos implement searching the same way M$ Explorer does (which is a disaster under Win XP) :evil:
Dumb questions are the ones that are never asked :turn:
User avatar
nikos
Site Admin
Site Admin
Posts: 15801
Joined: 2002 Feb 07, 15:57
Location: UK
Contact:

Post by nikos »

this is surely a storm in a teacup :)
it's just one little verb "rename" and nothing more
x2 has to detect it otherwise inplace rename won't work

people that use it for their own extensions do so at their own risk!
Bez
Member
Member
Posts: 14
Joined: 2004 Apr 26, 15:19
Contact:

Post by Bez »

If we're all using xplorer², haven't we decided that using Windows Explorer is a bad idea, so copying the way it does things is also bad?

Breaking rules and guidelines when coding is always a bad idea, and the first step towards a product that'll have odd bugs :/

And if the name is really a problem, I'd suggest a thesaurus. :)
Post Reply