Well I'll tell you....you can't grovel at her feet....you have to look like the better man....NO MATTER WHAT! You have to realize after this wake up call that all was not what it seemed......she was bored with what you two were doing or lack there of...she saw herself in a rut and now is not....There are a lot of things that drove her away.....it was just not one certain thing....it may have been the nail in the coffin but hey....we all make mistakes and learn from them.
So....what do you do....take a deep breath.....and start realizing what the past year was like...what same things did you do to make her realize that she needed a change....a change so drastic that she decided to go outside of your marriage.
You can't fix the past....but you CAN improve the future....and if she cannot be part of the new future...well....it her loss because you will be a better person regardless.