That is expected behavior.
Have you tried doing only Build not "Clean & Build"option for building the project.
Hello anks, yes, i have tried that and most of the times it works. But sometimes the file seems to be rebuild and my editing is deleted. Will the project be cleaned after adding new components?
Any editing done in generated source files will be deleted after a Clean or Clean & Build.That is expected behavior.
Please look for callback functions in the I2C component, those are available for user to edit and do not get cleaned after a rebuild in Generated Source.