Refactoring changed method

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Refactoring changed method

Vitor Medina Cruz
Hello,

While I was editing a method, if I do a rename temporary refactoring the system rollbacks every change I did to the method in order to apply the refactoring. Is that the correct behavior? Shouldn't It at least asks me if I want to save my changes before I apply the refactoring? It was really confusing the first time it happened and it took some time before I could understand what happened.

Regards,
Vitor
Reply | Threaded
Open this post in threaded view
|

Re: Refactoring changed method

Nicolai Hess-3-2


2016-10-19 15:19 GMT+02:00 Vitor Medina Cruz <[hidden email]>:
Hello,

While I was editing a method, if I do a rename temporary refactoring the system rollbacks every change I did to the method in order to apply the refactoring. Is that the correct behavior? Shouldn't It at least asks me if I want to save my changes before I apply the refactoring? It was really confusing the first time it happened and it took some time before I could understand what happened.

Yes, it does not care about current edited method, refactoring is applied the the existing method source.
Does it show a changes browser before applying the change (it should).
I would expect that nautilus indicates the current edited method with a little red corner, indicating that this method changed outside of the browser, but I guess this behavior is broken since we introduced rubric for
the code text pane.
 

Regards,
Vitor

Reply | Threaded
Open this post in threaded view
|

Re: Refactoring changed method

Vitor Medina Cruz
It indicates with a little yellow (for me :) ) corner yes (also, if I cntr+z all changes the corner does not goes away). It shows a changes browser also, but it doesn't help much, usually I just click Ok if only my code is affected. Wouldn't be good if a warn popup is prompted telling me I have changes that will be lost?

On Wed, Oct 19, 2016 at 11:33 AM, Nicolai Hess <[hidden email]> wrote:


2016-10-19 15:19 GMT+02:00 Vitor Medina Cruz <[hidden email]>:
Hello,

While I was editing a method, if I do a rename temporary refactoring the system rollbacks every change I did to the method in order to apply the refactoring. Is that the correct behavior? Shouldn't It at least asks me if I want to save my changes before I apply the refactoring? It was really confusing the first time it happened and it took some time before I could understand what happened.

Yes, it does not care about current edited method, refactoring is applied the the existing method source.
Does it show a changes browser before applying the change (it should).
I would expect that nautilus indicates the current edited method with a little red corner, indicating that this method changed outside of the browser, but I guess this behavior is broken since we introduced rubric for
the code text pane.
 

Regards,
Vitor


Reply | Threaded
Open this post in threaded view
|

Re: Refactoring changed method

Nicolai Hess-3-2


2016-10-19 16:00 GMT+02:00 Vitor Medina Cruz <[hidden email]>:
It indicates with a little yellow (for me :) ) corner yes (also, if I cntr+z all changes the corner does not goes away). It shows a changes browser also, but it doesn't help much, usually I just click Ok if only my code is affected. Wouldn't be good if a warn popup is prompted telling me I have changes that will be lost?

Yes, maybe. Actually the browser should get notified about the changed method, it either should indicate the method by replaceing the orange (unsaved-editings) with a red one (conflicting-edits), or show a confirmation dialog
as it (sometimes) does for chnages if the editor window has unsaved edits.
 

On Wed, Oct 19, 2016 at 11:33 AM, Nicolai Hess <[hidden email]> wrote:


2016-10-19 15:19 GMT+02:00 Vitor Medina Cruz <[hidden email]>:
Hello,

While I was editing a method, if I do a rename temporary refactoring the system rollbacks every change I did to the method in order to apply the refactoring. Is that the correct behavior? Shouldn't It at least asks me if I want to save my changes before I apply the refactoring? It was really confusing the first time it happened and it took some time before I could understand what happened.

Yes, it does not care about current edited method, refactoring is applied the the existing method source.
Does it show a changes browser before applying the change (it should).
I would expect that nautilus indicates the current edited method with a little red corner, indicating that this method changed outside of the browser, but I guess this behavior is broken since we introduced rubric for
the code text pane.
 

Regards,
Vitor



Reply | Threaded
Open this post in threaded view
|

Re: Refactoring changed method

Vitor Medina Cruz
Yes, something like that would be good. 

On Wed, Oct 19, 2016 at 12:10 PM, Nicolai Hess <[hidden email]> wrote:


2016-10-19 16:00 GMT+02:00 Vitor Medina Cruz <[hidden email]>:
It indicates with a little yellow (for me :) ) corner yes (also, if I cntr+z all changes the corner does not goes away). It shows a changes browser also, but it doesn't help much, usually I just click Ok if only my code is affected. Wouldn't be good if a warn popup is prompted telling me I have changes that will be lost?

Yes, maybe. Actually the browser should get notified about the changed method, it either should indicate the method by replaceing the orange (unsaved-editings) with a red one (conflicting-edits), or show a confirmation dialog
as it (sometimes) does for chnages if the editor window has unsaved edits.
 

On Wed, Oct 19, 2016 at 11:33 AM, Nicolai Hess <[hidden email]> wrote:


2016-10-19 15:19 GMT+02:00 Vitor Medina Cruz <[hidden email]>:
Hello,

While I was editing a method, if I do a rename temporary refactoring the system rollbacks every change I did to the method in order to apply the refactoring. Is that the correct behavior? Shouldn't It at least asks me if I want to save my changes before I apply the refactoring? It was really confusing the first time it happened and it took some time before I could understand what happened.

Yes, it does not care about current edited method, refactoring is applied the the existing method source.
Does it show a changes browser before applying the change (it should).
I would expect that nautilus indicates the current edited method with a little red corner, indicating that this method changed outside of the browser, but I guess this behavior is broken since we introduced rubric for
the code text pane.
 

Regards,
Vitor