From 483d0b71c5a34264c3ad22c09601c3865fdef7b3 Mon Sep 17 00:00:00 2001 From: Wizzup? Date: Sun, 20 Dec 2009 17:32:25 +0000 Subject: [PATCH] Few fixes when it comes to detection is there was a change to the xml file. git-svn-id: http://www.villavu.com/repositories/merlijn/mufasa@301 3f818213-9676-44b0-a9b4-5e4c4e03d09d --- Projects/SAMufasaGUI/colourhistory.pas | 8 ++-- Projects/SAMufasaGUI/project1.lpi | 64 +++++++++++++------------- 2 files changed, 37 insertions(+), 35 deletions(-) diff --git a/Projects/SAMufasaGUI/colourhistory.pas b/Projects/SAMufasaGUI/colourhistory.pas index 9feab90..d044897 100644 --- a/Projects/SAMufasaGUI/colourhistory.pas +++ b/Projects/SAMufasaGUI/colourhistory.pas @@ -174,6 +174,7 @@ begin CHImages.Delete(i); ColourTree.Selected.Delete; + TreeChanged:=True; end; end; @@ -312,9 +313,11 @@ begin if not assigned(Node) then begin ColourTree.Selected.MoveTo(nil, naAdd); + TreeChanged:=True; exit; end; ColourTree.Selected.MoveTo(Node, naAddChild); + TreeChanged:=True; writeln('Dragging from: ' + ColourTree.Selected.Text); writeln('Dragging to: ' + Node.Text); end; @@ -423,7 +426,7 @@ var begin if TreeChanged then begin - case MessageBox(0,pchar('Do you want to save the colors?'), Pchar('Colours have been modified.'), + case MessageBox(0,pchar('Do you want to save the colours?'), Pchar('Colours have been modified.'), MB_YESNOCANCEL or MB_ICONQUESTION) of IDCANCEL : Exit; @@ -440,7 +443,6 @@ begin if CHOpenDialog.Execute then if FileExists(CHOpenDialog.FileName) then begin - writeln('Loading from file: ' + CHOpenDialog.FileName); ReadXMLFile(XMLDoc, CHOpenDialog.FileName); // Clear Tree and Images @@ -449,7 +451,7 @@ begin CHImages.Clear; XML2Tree(XMLDoc); ColourTree.EndUpdate; - + TreeChanged:=False; XMLDoc.Free; end; end; diff --git a/Projects/SAMufasaGUI/project1.lpi b/Projects/SAMufasaGUI/project1.lpi index e6be159..875d2ba 100644 --- a/Projects/SAMufasaGUI/project1.lpi +++ b/Projects/SAMufasaGUI/project1.lpi @@ -1451,8 +1451,8 @@ - - + + @@ -1883,123 +1883,123 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - +