May 15, 2024, 09:23:58 AM

News:

IonicWind Snippit Manager 2.xx Released!  Install it on a memory stick and take it with you!  With or without IWBasic!


Question 05-27-2012

Started by LarryMc, May 27, 2012, 09:06:47 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

LarryMc

When the user clicks the "compile and execute" button in the current IDE:
If a project is open:
 the user is prompted to save every modified, currently open file in the IDE regardless of whether it is a part of the project or not
if no project is open and the current file has an opts file
 the source file is automatically saved, if needed, with no prompting.

I have never liked that.

I intend to have the new IDE, when a project is open, to automatically save any of the project's files that have been modified with no prompting just like a single file compile.
Any non project files will simply be ignored at that time.

The one option I will consider, if someone gives me a good enough reason, is to make the autosaving of project files, in the above situation, a user selectable IDE option.
LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library

Bruce Peaslee

This has always bugged me, too. My only concern is how do you want to handle inc files? I often have one open in the IDE. Will they be considered part of a project?
Bruce Peaslee
"Born too loose."
iTired (There's a nap for that.)
Well, I headed for Las Vegas
Only made it out to Needles

LarryMc

Good question Bruce
When a project is loaded all the project's file names are loaded in one of the tabs of the Project Files List window.
In the process all the files are scanned for $include and the include file names are listed in another tab in the Project Files List window.

So when the user clicks compile I will scan all the open files regadless of type.  I will then compare the filenames against the two list in the Project Files List window.  If the name of an open file is a match then it will be saved, if it has been modified.

I have one area of contention though.  Let's say you have a "global" include open (one from iwbdev\includes) and you accidently modify it while copying something.  The point being it is open in the IDE and its modified flag is set.  Do we really want to auto save it?
I think not.
I think what i'll do is autosave modified inc files if their location is the same as the location of the project.  If they are not the same then I will  popup a message saying something like "Modified Include file is not project unique. Are you sure you want to save changes? Yes/NO/ABORT"
LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library