Dragging: I 0wnz j00 #

I finally managed to squash the bug. When dragging, if there is a selection, I have to merge it with the current icon contents, and put that into the drag image. After the drag I had a check to see if the temporary gworld was created (which contained the merged data) and it would dispose of it. The check for this was whether or not there was a floated selection. However when dragging to the current gworld, a floated selection wold be always created, so it would attempt to dispose of the temporary gworld (which wasn't there, and it was grabbing the source).

Then I worked on one of the final human interface additions, the "Do you want to save...." alert. This was rather simple, I used the StandardAlert function to display a movable dialog, and specified the buttons as "Save", "Cancel", and "Don't Save". The hardest part was writing a string search and replace function, so that I could include the file name in the prompt string. I also made it so that these dialogs show up when quitting, if an icon hasn't been saved.

Post a Comment