|
Re: avoid automatic "save changes" dialog in a plug-in: msg#00238java.imagej
Thanks a lot! 2006/3/24, Wayne Rasband <wsr@xxxxxxx>: > > > I'm writing a plug-in and the way I use to close windows > > I don't need anymore is: > > > > imp.getWindow().close(); where imp is an ImagePlus > > > > this happens to display a dialog asking if I want to save cahnges > > in images. What do I have to do to avoid this dialog? I don't need > > to save the changes. > > Use > > imp.changes = false; > imp.getWindow().close(); > > Note that this method generates an exception if your plugin as called > from a macro running in batch mode. With ImageJ 1.36 and later, you can > use > > imp.changes = false; > imp.close(); > > which does not have this problem. > > -wayne >
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Curve Fitting in a macro, Michael Cammer |
|---|---|
| Next by Date: | Re: Curve Fitting in a macro, Wayne Rasband |
| Previous by Thread: | Re: avoid automatic "save changes" dialog in a plug-in, Wayne Rasband |
| Next by Thread: | Re: avoid automatic "save changes" dialog in a plug-in, Albert Cardona |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |