Currently Re#er has 'Move type' feature, which is capable of moving a single
type from one namespace to another. That's useful however not powerful enough.
1) Do you have any plans to add an ability to drag-and-drop a type from one
namespace to another (using Class View or some similar tool)? In most cases
that would much more convinient (this kind of refactoring actually affects
the 'model' of the application, not the code itself; thus a visual representation
of the model is more appropriate)
I had some experience with built in Class View (in VS2003, haven't tested
it in VS2005 though...), and it seems it cannot reflect the changes in the
code on-the-fly. There is a noticable delay (for which I failed to find a
reasonable upper bound) between the moment when the code is changed and the
moment when the tree is updated. So having such kind of view from Re#er would
be very nice.
2) Even if the answer to the previous question is negative still we can improve
the existing feature. One aspect, which I currently dislike, is the neccessity
to invoke the refactoring for each type is the source code file. Yes, usually
we have a 'one type -- one file' relation, but sometimes this rule is violated
(e.g. when I have XXXEventArgs and XXXEventHandler types -- these are often
put in the same file). Besides being inconvinient, the doulble refactoring
produces very strange-looking code like
-- the namespace declarations are not merged. Thus the code requires manual
correction -- the thing which definitely should be avoided.
Just to summarize, my suggestions are:
1) (Possibly hard to implement) Drag-and-drop functionality for ClassView
(either existing one or a completely custom)
2) 'Move all types' refactoring -- should be applicable when all types in
the current source file are in the same namespace. The expected result is:
all types are moved to the given destination namespace.
3) Automatically merge namespace declarations after 'Move type' refactoring.